PluginProbe
FluentCommunity – Ultra-Fast High-Performance Social Network, Community, LMS & Online Courses / 1.0.91
FluentCommunity – Ultra-Fast High-Performance Social Network, Community, LMS & Online Courses v1.0.91
2.10.0 2.10.01 2.9.1 2.9.0 2.8.1 2.8.0 2.7.7 2.7.5 2.7.0 2.6.01 2.6.0 2.5.0 2.4.01 trunk 1.0.90 1.0.91 1.0.92 1.0.93 1.0.94 1.0.95 1.0.96 1.0.97 1.0.98 1.0.99 1.1.0 All 77 releases
fluent-community / assets / admin_app.js

admin_app.js in FluentCommunity – Ultra-Fast High-Performance Social Network, Community, LMS & Online Courses 1.0.91, at assets/admin_app.js

509 lines 1.5 MB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 var CR=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var Yk=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)};var kt=(e,t,n)=>(Yk(e,t,"read from private field"),n?n.call(e):t.get(e)),xs=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},Lo=(e,t,n,o)=>(Yk(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n);var EFe=CR((fr,pr)=>{const kR="modulepreload",SR=function(e){return"/"+e},Zk={},Yd=function(t,n,o){if(!n||n.length===0)return t();const r=document.getElementsByTagName("link");return Promise.all(n.map(s=>{if(s=SR(s),s in Zk)return;Zk[s]=!0;const i=s.endsWith(".css"),l=i?'[rel="stylesheet"]':"";if(!!o)for(let c=r.length-1;c>=0;c--){const d=r[c];if(d.href===s&&(!i||d.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${s}"]${l}`))return;const u=document.createElement("link");if(u.rel=i?"stylesheet":kR,i||(u.as="script",u.crossOrigin=""),u.href=s,document.head.appendChild(u),i)return new Promise((c,d)=>{u.addEventListener("load",c),u.addEventListener("error",()=>d(new Error(`Unable to preload CSS for ${s}`)))})})).then(()=>t()).catch(s=>{const i=new Event("vite:preloadError",{cancelable:!0});if(i.payload=s,window.dispatchEvent(i),!i.defaultPrevented)throw s})};/**
2 * @vue/shared v3.4.23
3 * (c) 2018-present Yuxi (Evan) You and Vue contributors
4 * @license MIT
5 **//*! #__NO_SIDE_EFFECTS__ */function yr(e,t){const n=new Set(e.split(","));return t?o=>n.has(o.toLowerCase()):o=>n.has(o)}const Wt={},mc=[],yt=()=>{},Dm=()=>!1,vu=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),K2=e=>e.startsWith("onUpdate:"),Bt=Object.assign,q2=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},$R=Object.prototype.hasOwnProperty,vt=(e,t)=>$R.call(e,t),Me=Array.isArray,gc=e=>vd(e)==="[object Map]",yu=e=>vd(e)==="[object Set]",og=e=>vd(e)==="[object Date]",ER=e=>vd(e)==="[object RegExp]",Xe=e=>typeof e=="function",tt=e=>typeof e=="string",Fr=e=>typeof e=="symbol",ft=e=>e!==null&&typeof e=="object",G2=e=>(ft(e)||Xe(e))&&Xe(e.then)&&Xe(e.catch),b$=Object.prototype.toString,vd=e=>b$.call(e),Fm=e=>vd(e).slice(8,-1),rg=e=>vd(e)==="[object Object]",Y2=e=>tt(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Al=yr(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),xR=yr("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"),u0=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},MR=/-(\w)/g,yn=u0(e=>e.replace(MR,(t,n)=>n?n.toUpperCase():"")),TR=/\B([A-Z])/g,zo=u0(e=>e.replace(TR,"-$1").toLowerCase()),ql=u0(e=>e.charAt(0).toUpperCase()+e.slice(1)),vc=u0(e=>e?`on${ql(e)}`:""),ps=(e,t)=>!Object.is(e,t),yc=(e,t)=>{for(let n=0;n<e.length;n++)e[n](t)},w$=(e,t,n)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},sg=e=>{const t=parseFloat(e);return isNaN(t)?e:t},ig=e=>{const t=tt(e)?Number(e):NaN;return isNaN(t)?e:t};let Jk;const C$=()=>Jk||(Jk=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}),OR="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error",IR=yr(OR);function Qe(e){if(Me(e)){const t={};for(let n=0;n<e.length;n++){const o=e[n],r=tt(o)?k$(o):Qe(o);if(r)for(const s in r)t[s]=r[s]}return t}else if(tt(e)||ft(e))return e}const AR=/;(?![^(]*\))/g,NR=/:([^]+)/,PR=/\/\*[^]*?\*\//g;function k$(e){const t={};return e.replace(PR,"").split(AR).forEach(n=>{if(n){const o=n.split(NR);o.length>1&&(t[o[0].trim()]=o[1].trim())}}),t}function D(e){let t="";if(tt(e))t=e;else if(Me(e))for(let n=0;n<e.length;n++){const o=D(e[n]);o&&(t+=o+" ")}else if(ft(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}function Z2(e){if(!e)return null;let{class:t,style:n}=e;return t&&!tt(t)&&(e.class=D(t)),n&&(e.style=Qe(n)),e}const LR="html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot",RR="svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,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,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view",DR="annotation,annotation-xml,maction,maligngroup,malignmark,math,menclose,merror,mfenced,mfrac,mfraction,mglyph,mi,mlabeledtr,mlongdiv,mmultiscripts,mn,mo,mover,mpadded,mphantom,mprescripts,mroot,mrow,ms,mscarries,mscarry,msgroup,msline,mspace,msqrt,msrow,mstack,mstyle,msub,msubsup,msup,mtable,mtd,mtext,mtr,munder,munderover,none,semantics",FR="area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr",VR=yr(LR),BR=yr(RR),zR=yr(DR),jR=yr(FR),HR="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",UR=yr(HR);function S$(e){return!!e||e===""}function WR(e,t){if(e.length!==t.length)return!1;let n=!0;for(let o=0;n&&o<e.length;o++)n=Vl(e[o],t[o]);return n}function Vl(e,t){if(e===t)return!0;let n=og(e),o=og(t);if(n||o)return n&&o?e.getTime()===t.getTime():!1;if(n=Fr(e),o=Fr(t),n||o)return e===t;if(n=Me(e),o=Me(t),n||o)return n&&o?WR(e,t):!1;if(n=ft(e),o=ft(t),n||o){if(!n||!o)return!1;const r=Object.keys(e).length,s=Object.keys(t).length;if(r!==s)return!1;for(const i in e){const l=e.hasOwnProperty(i),a=t.hasOwnProperty(i);if(l&&!a||!l&&a||!Vl(e[i],t[i]))return!1}}return String(e)===String(t)}function c0(e,t){return e.findIndex(n=>Vl(n,t))}const A=e=>tt(e)?e:e==null?"":Me(e)||ft(e)&&(e.toString===b$||!Xe(e.toString))?JSON.stringify(e,$$,2):String(e),$$=(e,t)=>t&&t.__v_isRef?$$(e,t.value):gc(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[o,r],s)=>(n[Av(o,s)+" =>"]=r,n),{})}:yu(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>Av(n))}:Fr(t)?Av(t):ft(t)&&!Me(t)&&!rg(t)?String(t):t,Av=(e,t="")=>{var n;return Fr(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/**
6 * @vue/reactivity v3.4.23
7 * (c) 2018-present Yuxi (Evan) You and Vue contributors
8 * @license MIT
9 **/let ir;class J2{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this.parent=ir,!t&&ir&&(this.index=(ir.scopes||(ir.scopes=[])).push(this)-1)}get active(){return this._active}run(t){if(this._active){const n=ir;try{return ir=this,t()}finally{ir=n}}}on(){ir=this}off(){ir=this.parent}stop(t){if(this._active){let n,o;for(n=0,o=this.effects.length;n<o;n++)this.effects[n].stop();for(n=0,o=this.cleanups.length;n<o;n++)this.cleanups[n]();if(this.scopes)for(n=0,o=this.scopes.length;n<o;n++)this.scopes[n].stop(!0);if(!this.detached&&this.parent&&!t){const r=this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0,this._active=!1}}}function E$(e){return new J2(e)}function x$(e,t=ir){t&&t.active&&t.effects.push(e)}function X2(){return ir}function Q2(e){ir&&ir.cleanups.push(e)}let Va;class Rc{constructor(t,n,o,r){this.fn=t,this.trigger=n,this.scheduler=o,this.active=!0,this.deps=[],this._dirtyLevel=4,this._trackId=0,this._runnings=0,this._shouldSchedule=!1,this._depsLength=0,x$(this,r)}get dirty(){if(this._dirtyLevel===2||this._dirtyLevel===3){this._dirtyLevel=1,Gl();for(let t=0;t<this._depsLength;t++){const n=this.deps[t];if(n.computed&&(KR(n.computed),this._dirtyLevel>=4))break}this._dirtyLevel===1&&(this._dirtyLevel=0),Yl()}return this._dirtyLevel>=4}set dirty(t){this._dirtyLevel=t?4:0}run(){if(this._dirtyLevel=0,!this.active)return this.fn();let t=Nl,n=Va;try{return Nl=!0,Va=this,this._runnings++,Xk(this),this.fn()}finally{Qk(this),this._runnings--,Va=n,Nl=t}}stop(){var t;this.active&&(Xk(this),Qk(this),(t=this.onStop)==null||t.call(this),this.active=!1)}}function KR(e){return e.value}function Xk(e){e._trackId++,e._depsLength=0}function Qk(e){if(e.deps.length>e._depsLength){for(let t=e._depsLength;t<e.deps.length;t++)M$(e.deps[t],e);e.deps.length=e._depsLength}}function M$(e,t){const n=e.get(t);n!==void 0&&t._trackId!==n&&(e.delete(t),e.size===0&&e.cleanup())}function qR(e,t){e.effect instanceof Rc&&(e=e.effect.fn);const n=new Rc(e,yt,()=>{n.dirty&&n.run()});t&&(Bt(n,t),t.scope&&x$(n,t.scope)),(!t||!t.lazy)&&n.run();const o=n.run.bind(n);return o.effect=n,o}function GR(e){e.effect.stop()}let Nl=!0,a_=0;const T$=[];function Gl(){T$.push(Nl),Nl=!1}function Yl(){const e=T$.pop();Nl=e===void 0?!0:e}function ew(){a_++}function tw(){for(a_--;!a_&&u_.length;)u_.shift()()}function O$(e,t,n){if(t.get(e)!==e._trackId){t.set(e,e._trackId);const o=e.deps[e._depsLength];o!==t?(o&&M$(o,e),e.deps[e._depsLength++]=t):e._depsLength++}}const u_=[];function I$(e,t,n){ew();for(const o of e.keys()){let r;o._dirtyLevel<t&&(r??(r=e.get(o)===o._trackId))&&(o._shouldSchedule||(o._shouldSchedule=o._dirtyLevel===0),o._dirtyLevel=t),o._shouldSchedule&&(r??(r=e.get(o)===o._trackId))&&(o.trigger(),(!o._runnings||o.allowRecurse)&&o._dirtyLevel!==2&&(o._shouldSchedule=!1,o.scheduler&&u_.push(o.scheduler)))}tw()}const A$=(e,t)=>{const n=new Map;return n.cleanup=e,n.computed=t,n},lg=new WeakMap,Ba=Symbol(""),c_=Symbol("");function Yo(e,t,n){if(Nl&&Va){let o=lg.get(e);o||lg.set(e,o=new Map);let r=o.get(n);r||o.set(n,r=A$(()=>o.delete(n))),O$(Va,r)}}function Ei(e,t,n,o,r,s){const i=lg.get(e);if(!i)return;let l=[];if(t==="clear")l=[...i.values()];else if(n==="length"&&Me(e)){const a=Number(o);i.forEach((u,c)=>{(c==="length"||!Fr(c)&&c>=a)&&l.push(u)})}else switch(n!==void 0&&l.push(i.get(n)),t){case"add":Me(e)?Y2(n)&&l.push(i.get("length")):(l.push(i.get(Ba)),gc(e)&&l.push(i.get(c_)));break;case"delete":Me(e)||(l.push(i.get(Ba)),gc(e)&&l.push(i.get(c_)));break;case"set":gc(e)&&l.push(i.get(Ba));break}ew();for(const a of l)a&&I$(a,4);tw()}function YR(e,t){var n;return(n=lg.get(e))==null?void 0:n.get(t)}const ZR=yr("__proto__,__v_isRef,__isVue"),N$=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Fr)),e4=JR();function JR(){const e={};return["includes","indexOf","lastIndexOf"].forEach(t=>{e[t]=function(...n){const o=Mt(this);for(let s=0,i=this.length;s<i;s++)Yo(o,"get",s+"");const r=o[t](...n);return r===-1||r===!1?o[t](...n.map(Mt)):r}}),["push","pop","shift","unshift","splice"].forEach(t=>{e[t]=function(...n){Gl(),ew();const o=Mt(this)[t].apply(this,n);return tw(),Yl(),o}}),e}function XR(e){Fr(e)||(e=String(e));const t=Mt(this);return Yo(t,"has",e),t.hasOwnProperty(e)}class P${constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,o){const r=this._isReadonly,s=this._isShallow;if(n==="__v_isReactive")return!r;if(n==="__v_isReadonly")return r;if(n==="__v_isShallow")return s;if(n==="__v_raw")return o===(r?s?B$:V$:s?F$:D$).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(o)?t:void 0;const i=Me(t);if(!r){if(i&&vt(e4,n))return Reflect.get(e4,n,o);if(n==="hasOwnProperty")return XR}const l=Reflect.get(t,n,o);return(Fr(n)?N$.has(n):ZR(n))||(r||Yo(t,"get",n),s)?l:on(l)?i&&Y2(n)?l:l.value:ft(l)?r?_u(l):Dn(l):l}}class L$ extends P${constructor(t=!1){super(!1,t)}set(t,n,o,r){let s=t[n];if(!this._isShallow){const a=Dc(s);if(!fp(o)&&!Dc(o)&&(s=Mt(s),o=Mt(o)),!Me(t)&&on(s)&&!on(o))return a?!1:(s.value=o,!0)}const i=Me(t)&&Y2(n)?Number(n)<t.length:vt(t,n),l=Reflect.set(t,n,o,r);return t===Mt(r)&&(i?ps(o,s)&&Ei(t,"set",n,o):Ei(t,"add",n,o)),l}deleteProperty(t,n){const o=vt(t,n);t[n];const r=Reflect.deleteProperty(t,n);return r&&o&&Ei(t,"delete",n,void 0),r}has(t,n){const o=Reflect.has(t,n);return(!Fr(n)||!N$.has(n))&&Yo(t,"has",n),o}ownKeys(t){return Yo(t,"iterate",Me(t)?"length":Ba),Reflect.ownKeys(t)}}class R$ extends P${constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const QR=new L$,eD=new R$,tD=new L$(!0),nD=new R$(!0),nw=e=>e,d0=e=>Reflect.getPrototypeOf(e);function Wh(e,t,n=!1,o=!1){e=e.__v_raw;const r=Mt(e),s=Mt(t);n||(ps(t,s)&&Yo(r,"get",t),Yo(r,"get",s));const{has:i}=d0(r),l=o?nw:n?sw:pp;if(i.call(r,t))return l(e.get(t));if(i.call(r,s))return l(e.get(s));e!==r&&e.get(t)}function Kh(e,t=!1){const n=this.__v_raw,o=Mt(n),r=Mt(e);return t||(ps(e,r)&&Yo(o,"has",e),Yo(o,"has",r)),e===r?n.has(e):n.has(e)||n.has(r)}function qh(e,t=!1){return e=e.__v_raw,!t&&Yo(Mt(e),"iterate",Ba),Reflect.get(e,"size",e)}function t4(e){e=Mt(e);const t=Mt(this);return d0(t).has.call(t,e)||(t.add(e),Ei(t,"add",e,e)),this}function n4(e,t){t=Mt(t);const n=Mt(this),{has:o,get:r}=d0(n);let s=o.call(n,e);s||(e=Mt(e),s=o.call(n,e));const i=r.call(n,e);return n.set(e,t),s?ps(t,i)&&Ei(n,"set",e,t):Ei(n,"add",e,t),this}function o4(e){const t=Mt(this),{has:n,get:o}=d0(t);let r=n.call(t,e);r||(e=Mt(e),r=n.call(t,e)),o&&o.call(t,e);const s=t.delete(e);return r&&Ei(t,"delete",e,void 0),s}function r4(){const e=Mt(this),t=e.size!==0,n=e.clear();return t&&Ei(e,"clear",void 0,void 0),n}function Gh(e,t){return function(o,r){const s=this,i=s.__v_raw,l=Mt(i),a=t?nw:e?sw:pp;return!e&&Yo(l,"iterate",Ba),i.forEach((u,c)=>o.call(r,a(u),a(c),s))}}function Yh(e,t,n){return function(...o){const r=this.__v_raw,s=Mt(r),i=gc(s),l=e==="entries"||e===Symbol.iterator&&i,a=e==="keys"&&i,u=r[e](...o),c=n?nw:t?sw:pp;return!t&&Yo(s,"iterate",a?c_:Ba),{next(){const{value:d,done:f}=u.next();return f?{value:d,done:f}:{value:l?[c(d[0]),c(d[1])]:c(d),done:f}},[Symbol.iterator](){return this}}}}function Wi(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function oD(){const e={get(s){return Wh(this,s)},get size(){return qh(this)},has:Kh,add:t4,set:n4,delete:o4,clear:r4,forEach:Gh(!1,!1)},t={get(s){return Wh(this,s,!1,!0)},get size(){return qh(this)},has:Kh,add:t4,set:n4,delete:o4,clear:r4,forEach:Gh(!1,!0)},n={get(s){return Wh(this,s,!0)},get size(){return qh(this,!0)},has(s){return Kh.call(this,s,!0)},add:Wi("add"),set:Wi("set"),delete:Wi("delete"),clear:Wi("clear"),forEach:Gh(!0,!1)},o={get(s){return Wh(this,s,!0,!0)},get size(){return qh(this,!0)},has(s){return Kh.call(this,s,!0)},add:Wi("add"),set:Wi("set"),delete:Wi("delete"),clear:Wi("clear"),forEach:Gh(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(s=>{e[s]=Yh(s,!1,!1),n[s]=Yh(s,!0,!1),t[s]=Yh(s,!1,!0),o[s]=Yh(s,!0,!0)}),[e,n,t,o]}const[rD,sD,iD,lD]=oD();function f0(e,t){const n=t?e?lD:iD:e?sD:rD;return(o,r,s)=>r==="__v_isReactive"?!e:r==="__v_isReadonly"?e:r==="__v_raw"?o:Reflect.get(vt(n,r)&&r in o?n:o,r,s)}const aD={get:f0(!1,!1)},uD={get:f0(!1,!0)},cD={get:f0(!0,!1)},dD={get:f0(!0,!0)},D$=new WeakMap,F$=new WeakMap,V$=new WeakMap,B$=new WeakMap;function fD(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function pD(e){return e.__v_skip||!Object.isExtensible(e)?0:fD(Fm(e))}function Dn(e){return Dc(e)?e:p0(e,!1,QR,aD,D$)}function ow(e){return p0(e,!1,tD,uD,F$)}function _u(e){return p0(e,!0,eD,cD,V$)}function hD(e){return p0(e,!0,nD,dD,B$)}function p0(e,t,n,o,r){if(!ft(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const s=r.get(e);if(s)return s;const i=pD(e);if(i===0)return e;const l=new Proxy(e,i===2?o:n);return r.set(e,l),l}function _c(e){return Dc(e)?_c(e.__v_raw):!!(e&&e.__v_isReactive)}function Dc(e){return!!(e&&e.__v_isReadonly)}function fp(e){return!!(e&&e.__v_isShallow)}function rw(e){return e?!!e.__v_raw:!1}function Mt(e){const t=e&&e.__v_raw;return t?Mt(t):e}function Ii(e){return Object.isExtensible(e)&&w$(e,"__v_skip",!0),e}const pp=e=>ft(e)?Dn(e):e,sw=e=>ft(e)?_u(e):e;class z${constructor(t,n,o,r){this.getter=t,this._setter=n,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this.effect=new Rc(()=>t(this._value),()=>bc(this,this.effect._dirtyLevel===2?2:3)),this.effect.computed=this,this.effect.active=this._cacheable=!r,this.__v_isReadonly=o}get value(){const t=Mt(this);return(!t._cacheable||t.effect.dirty)&&ps(t._value,t._value=t.effect.run())&&bc(t,4),iw(t),t.effect._dirtyLevel>=2&&bc(t,2),t._value}set value(t){this._setter(t)}get _dirty(){return this.effect.dirty}set _dirty(t){this.effect.dirty=t}}function j$(e,t,n=!1){let o,r;const s=Xe(e);return s?(o=e,r=yt):(o=e.get,r=e.set),new z$(o,r,s||!r,n)}function iw(e){var t;Nl&&Va&&(e=Mt(e),O$(Va,(t=e.dep)!=null?t:e.dep=A$(()=>e.dep=void 0,e instanceof z$?e:void 0)))}function bc(e,t=4,n){e=Mt(e);const o=e.dep;o&&I$(o,t)}function on(e){return!!(e&&e.__v_isRef===!0)}function K(e){return H$(e,!1)}function Tn(e){return H$(e,!0)}function H$(e,t){return on(e)?e:new mD(e,t)}class mD{constructor(t,n){this.__v_isShallow=n,this.dep=void 0,this.__v_isRef=!0,this._rawValue=n?t:Mt(t),this._value=n?t:pp(t)}get value(){return iw(this),this._value}set value(t){const n=this.__v_isShallow||fp(t)||Dc(t);t=n?t:Mt(t),ps(t,this._rawValue)&&(this._rawValue=t,this._value=n?t:pp(t),bc(this,4))}}function gD(e){bc(e,4)}function g(e){return on(e)?e.value:e}function vD(e){return Xe(e)?e():g(e)}const yD={get:(e,t,n)=>g(Reflect.get(e,t,n)),set:(e,t,n,o)=>{const r=e[t];return on(r)&&!on(n)?(r.value=n,!0):Reflect.set(e,t,n,o)}};function lw(e){return _c(e)?e:new Proxy(e,yD)}class _D{constructor(t){this.dep=void 0,this.__v_isRef=!0;const{get:n,set:o}=t(()=>iw(this),()=>bc(this));this._get=n,this._set=o}get value(){return this._get()}set value(t){this._set(t)}}function U$(e){return new _D(e)}function ei(e){const t=Me(e)?new Array(e.length):{};for(const n in e)t[n]=W$(e,n);return t}class bD{constructor(t,n,o){this._object=t,this._key=n,this._defaultValue=o,this.__v_isRef=!0}get value(){const t=this._object[this._key];return t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return YR(Mt(this._object),this._key)}}class wD{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function pn(e,t,n){return on(e)?e:Xe(e)?new wD(e):ft(e)&&arguments.length>1?W$(e,t,n):K(e)}function W$(e,t,n){const o=e[t];return on(o)?o:new bD(e,t,n)}const CD={GET:"get",HAS:"has",ITERATE:"iterate"},kD={SET:"set",ADD:"add",DELETE:"delete",CLEAR:"clear"};/**
10 * @vue/runtime-core v3.4.23
11 * (c) 2018-present Yuxi (Evan) You and Vue contributors
12 * @license MIT
13 **/function SD(e,t){}const $D={SETUP_FUNCTION:0,0:"SETUP_FUNCTION",RENDER_FUNCTION:1,1:"RENDER_FUNCTION",WATCH_GETTER:2,2:"WATCH_GETTER",WATCH_CALLBACK:3,3:"WATCH_CALLBACK",WATCH_CLEANUP:4,4:"WATCH_CLEANUP",NATIVE_EVENT_HANDLER:5,5:"NATIVE_EVENT_HANDLER",COMPONENT_EVENT_HANDLER:6,6:"COMPONENT_EVENT_HANDLER",VNODE_HOOK:7,7:"VNODE_HOOK",DIRECTIVE_HOOK:8,8:"DIRECTIVE_HOOK",TRANSITION_HOOK:9,9:"TRANSITION_HOOK",APP_ERROR_HANDLER:10,10:"APP_ERROR_HANDLER",APP_WARN_HANDLER:11,11:"APP_WARN_HANDLER",FUNCTION_REF:12,12:"FUNCTION_REF",ASYNC_COMPONENT_LOADER:13,13:"ASYNC_COMPONENT_LOADER",SCHEDULER:14,14:"SCHEDULER"},ED={sp:"serverPrefetch hook",bc:"beforeCreate hook",c:"created hook",bm:"beforeMount hook",m:"mounted hook",bu:"beforeUpdate hook",u:"updated",bum:"beforeUnmount hook",um:"unmounted hook",a:"activated hook",da:"deactivated hook",ec:"errorCaptured hook",rtc:"renderTracked hook",rtg:"renderTriggered hook",0:"setup function",1:"render function",2:"watcher getter",3:"watcher callback",4:"watcher cleanup function",5:"native event handler",6:"component event handler",7:"vnode hook",8:"directive hook",9:"transition hook",10:"app errorHandler",11:"app warnHandler",12:"ref function",13:"async component loader",14:"scheduler flush. This is likely a Vue internals bug. Please open an issue at https://github.com/vuejs/core ."};function xi(e,t,n,o){try{return o?e(...o):e()}catch(r){bu(r,t,n)}}function hr(e,t,n,o){if(Xe(e)){const r=xi(e,t,n,o);return r&&G2(r)&&r.catch(s=>{bu(s,t,n)}),r}if(Me(e)){const r=[];for(let s=0;s<e.length;s++)r.push(hr(e[s],t,n,o));return r}}function bu(e,t,n,o=!0){const r=t?t.vnode:null;if(t){let s=t.parent;const i=t.proxy,l=`https://vuejs.org/error-reference/#runtime-${n}`;for(;s;){const u=s.ec;if(u){for(let c=0;c<u.length;c++)if(u[c](e,i,l)===!1)return}s=s.parent}const a=t.appContext.config.errorHandler;if(a){Gl(),xi(a,null,10,[e,i,l]),Yl();return}}xD(e,n,r,o)}function xD(e,t,n,o=!0){console.error(e)}let hp=!1,d_=!1;const ho=[];let Vs=0;const wc=[];let pl=null,$a=0;const K$=Promise.resolve();let aw=null;function ot(e){const t=aw||K$;return e?t.then(this?e.bind(this):e):t}function MD(e){let t=Vs+1,n=ho.length;for(;t<n;){const o=t+n>>>1,r=ho[o],s=mp(r);s<e||s===e&&r.pre?t=o+1:n=o}return t}function h0(e){(!ho.length||!ho.includes(e,hp&&e.allowRecurse?Vs+1:Vs))&&(e.id==null?ho.push(e):ho.splice(MD(e.id),0,e),q$())}function q$(){!hp&&!d_&&(d_=!0,aw=K$.then(G$))}function TD(e){const t=ho.indexOf(e);t>Vs&&ho.splice(t,1)}function ag(e){Me(e)?wc.push(...e):(!pl||!pl.includes(e,e.allowRecurse?$a+1:$a))&&wc.push(e),q$()}function s4(e,t,n=hp?Vs+1:0){for(;n<ho.length;n++){const o=ho[n];if(o&&o.pre){if(e&&o.id!==e.uid)continue;ho.splice(n,1),n--,o()}}}function ug(e){if(wc.length){const t=[...new Set(wc)].sort((n,o)=>mp(n)-mp(o));if(wc.length=0,pl){pl.push(...t);return}for(pl=t,$a=0;$a<pl.length;$a++)pl[$a]();pl=null,$a=0}}const mp=e=>e.id==null?1/0:e.id,OD=(e,t)=>{const n=mp(e)-mp(t);if(n===0){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function G$(e){d_=!1,hp=!0,ho.sort(OD);const t=yt;try{for(Vs=0;Vs<ho.length;Vs++){const n=ho[Vs];n&&n.active!==!1&&xi(n,null,14)}}finally{Vs=0,ho.length=0,ug(),hp=!1,aw=null,(ho.length||wc.length)&&G$()}}let Uu,Zh=[];function Y$(e,t){var n,o;Uu=e,Uu?(Uu.enabled=!0,Zh.forEach(({event:r,args:s})=>Uu.emit(r,...s)),Zh=[]):typeof window<"u"&&window.HTMLElement&&!((o=(n=window.navigator)==null?void 0:n.userAgent)!=null&&o.includes("jsdom"))?((t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(s=>{Y$(s,t)}),setTimeout(()=>{Uu||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,Zh=[])},3e3)):Zh=[]}function ID(e,t,...n){if(e.isUnmounted)return;const o=e.vnode.props||Wt;let r=n;const s=t.startsWith("update:"),i=s&&t.slice(7);if(i&&i in o){const c=`${i==="modelValue"?"model":i}Modifiers`,{number:d,trim:f}=o[c]||Wt;f&&(r=n.map(p=>tt(p)?p.trim():p)),d&&(r=n.map(sg))}let l,a=o[l=vc(t)]||o[l=vc(yn(t))];!a&&s&&(a=o[l=vc(zo(t))]),a&&hr(a,e,6,r);const u=o[l+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[l])return;e.emitted[l]=!0,hr(u,e,6,r)}}function Z$(e,t,n=!1){const o=t.emitsCache,r=o.get(e);if(r!==void 0)return r;const s=e.emits;let i={},l=!1;if(!Xe(e)){const a=u=>{const c=Z$(u,t,!0);c&&(l=!0,Bt(i,c))};!n&&t.mixins.length&&t.mixins.forEach(a),e.extends&&a(e.extends),e.mixins&&e.mixins.forEach(a)}return!s&&!l?(ft(e)&&o.set(e,null),null):(Me(s)?s.forEach(a=>i[a]=null):Bt(i,s),ft(e)&&o.set(e,i),i)}function m0(e,t){return!e||!vu(t)?!1:(t=t.slice(2).replace(/Once$/,""),vt(e,t[0].toLowerCase()+t.slice(1))||vt(e,zo(t))||vt(e,t))}let Pn=null,g0=null;function gp(e){const t=Pn;return Pn=e,g0=e&&e.type.__scopeId||null,t}function J$(e){g0=e}function X$(){g0=null}const AD=e=>$;function $(e,t=Pn,n){if(!t||e._n)return e;const o=(...r)=>{o._d&&b_(-1);const s=gp(t);let i;try{i=e(...r)}finally{gp(s),o._d&&b_(1)}return i};return o._n=!0,o._c=!0,o._d=!0,o}function Vm(e){const{type:t,vnode:n,proxy:o,withProxy:r,props:s,propsOptions:[i],slots:l,attrs:a,emit:u,render:c,renderCache:d,data:f,setupState:p,ctx:h,inheritAttrs:m}=e;let y,v;const w=gp(e);try{if(n.shapeFlag&4){const S=r||o,x=S;y=ur(c.call(x,S,d,s,p,f,h)),v=a}else{const S=t;y=ur(S.length>1?S(s,{attrs:a,slots:l,emit:u}):S(s,null)),v=t.props?a:PD(a)}}catch(S){Rf.length=0,bu(S,e,1),y=k(Kn)}let _=y;if(v&&m!==!1){const S=Object.keys(v),{shapeFlag:x}=_;S.length&&x&7&&(i&&S.some(K2)&&(v=LD(v,i)),_=hs(_,v))}return n.dirs&&(_=hs(_),_.dirs=_.dirs?_.dirs.concat(n.dirs):n.dirs),n.transition&&(_.transition=n.transition),y=_,gp(w),y}function ND(e,t=!0){let n;for(let o=0;o<e.length;o++){const r=e[o];if(yo(r)){if(r.type!==Kn||r.children==="v-if"){if(n)return;n=r}}else return}return n}const PD=e=>{let t;for(const n in e)(n==="class"||n==="style"||vu(n))&&((t||(t={}))[n]=e[n]);return t},LD=(e,t)=>{const n={};for(const o in e)(!K2(o)||!(o.slice(9)in t))&&(n[o]=e[o]);return n};function RD(e,t,n){const{props:o,children:r,component:s}=e,{props:i,children:l,patchFlag:a}=t,u=s.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&a>=0){if(a&1024)return!0;if(a&16)return o?i4(o,i,u):!!i;if(a&8){const c=t.dynamicProps;for(let d=0;d<c.length;d++){const f=c[d];if(i[f]!==o[f]&&!m0(u,f))return!0}}}else return(r||l)&&(!l||!l.$stable)?!0:o===i?!1:o?i?i4(o,i,u):!0:!!i;return!1}function i4(e,t,n){const o=Object.keys(t);if(o.length!==Object.keys(e).length)return!0;for(let r=0;r<o.length;r++){const s=o[r];if(t[s]!==e[s]&&!m0(n,s))return!0}return!1}function uw({vnode:e,parent:t},n){for(;t;){const o=t.subTree;if(o.suspense&&o.suspense.activeBranch===e&&(o.el=e.el),o===e)(e=t.vnode).el=n,t=t.parent;else break}}const cw="components",DD="directives";function re(e,t){return dw(cw,e,!0,t)||e}const Q$=Symbol.for("v-ndc");function Lt(e){return tt(e)?dw(cw,e,!1)||e:e||Q$}function zt(e){return dw(DD,e)}function dw(e,t,n=!0,o=!1){const r=Pn||Bn;if(r){const s=r.type;if(e===cw){const l=$_(s,!1);if(l&&(l===t||l===yn(t)||l===ql(yn(t))))return s}const i=l4(r[e]||s[e],t)||l4(r.appContext[e],t);return!i&&o?s:i}}function l4(e,t){return e&&(e[t]||e[yn(t)]||e[ql(yn(t))])}const eE=e=>e.__isSuspense;let f_=0;const FD={name:"Suspense",__isSuspense:!0,process(e,t,n,o,r,s,i,l,a,u){if(e==null)BD(t,n,o,r,s,i,l,a,u);else{if(s&&s.deps>0&&!e.suspense.isInFallback){t.suspense=e.suspense,t.suspense.vnode=t,t.el=e.el;return}zD(e,t,n,o,r,i,l,a,u)}},hydrate:jD,create:fw,normalize:HD},VD=FD;function vp(e,t){const n=e.props&&e.props[t];Xe(n)&&n()}function BD(e,t,n,o,r,s,i,l,a){const{p:u,o:{createElement:c}}=a,d=c("div"),f=e.suspense=fw(e,r,o,t,d,n,s,i,l,a);u(null,f.pendingBranch=e.ssContent,d,null,o,f,s,i),f.deps>0?(vp(e,"onPending"),vp(e,"onFallback"),u(null,e.ssFallback,t,n,o,null,s,i),Cc(f,e.ssFallback)):f.resolve(!1,!0)}function zD(e,t,n,o,r,s,i,l,{p:a,um:u,o:{createElement:c}}){const d=t.suspense=e.suspense;d.vnode=t,t.el=e.el;const f=t.ssContent,p=t.ssFallback,{activeBranch:h,pendingBranch:m,isInFallback:y,isHydrating:v}=d;if(m)d.pendingBranch=f,ss(f,m)?(a(m,f,d.hiddenContainer,null,r,d,s,i,l),d.deps<=0?d.resolve():y&&(v||(a(h,p,n,o,r,null,s,i,l),Cc(d,p)))):(d.pendingId=f_++,v?(d.isHydrating=!1,d.activeBranch=m):u(m,r,d),d.deps=0,d.effects.length=0,d.hiddenContainer=c("div"),y?(a(null,f,d.hiddenContainer,null,r,d,s,i,l),d.deps<=0?d.resolve():(a(h,p,n,o,r,null,s,i,l),Cc(d,p))):h&&ss(f,h)?(a(h,f,n,o,r,d,s,i,l),d.resolve(!0)):(a(null,f,d.hiddenContainer,null,r,d,s,i,l),d.deps<=0&&d.resolve()));else if(h&&ss(f,h))a(h,f,n,o,r,d,s,i,l),Cc(d,f);else if(vp(t,"onPending"),d.pendingBranch=f,f.shapeFlag&512?d.pendingId=f.component.suspenseId:d.pendingId=f_++,a(null,f,d.hiddenContainer,null,r,d,s,i,l),d.deps<=0)d.resolve();else{const{timeout:w,pendingId:_}=d;w>0?setTimeout(()=>{d.pendingId===_&&d.fallback(p)},w):w===0&&d.fallback(p)}}function fw(e,t,n,o,r,s,i,l,a,u,c=!1){const{p:d,m:f,um:p,n:h,o:{parentNode:m,remove:y}}=u;let v;const w=UD(e);w&&t!=null&&t.pendingBranch&&(v=t.pendingId,t.deps++);const _=e.props?ig(e.props.timeout):void 0,S=s,x={vnode:e,parent:t,parentComponent:n,namespace:i,container:o,hiddenContainer:r,deps:0,pendingId:f_++,timeout:typeof _=="number"?_:-1,activeBranch:null,pendingBranch:null,isInFallback:!c,isHydrating:c,isUnmounted:!1,effects:[],resolve(E=!1,T=!1){const{vnode:O,activeBranch:P,pendingBranch:N,pendingId:F,effects:B,parentComponent:Y,container:Z}=x;let U=!1;x.isHydrating?x.isHydrating=!1:E||(U=P&&N.transition&&N.transition.mode==="out-in",U&&(P.transition.afterLeave=()=>{F===x.pendingId&&(f(N,Z,s===S?h(P):s,0),ag(B))}),P&&(m(P.el)!==x.hiddenContainer&&(s=h(P)),p(P,Y,x,!0)),U||f(N,Z,s,0)),Cc(x,N),x.pendingBranch=null,x.isInFallback=!1;let j=x.parent,V=!1;for(;j;){if(j.pendingBranch){j.effects.push(...B),V=!0;break}j=j.parent}!V&&!U&&ag(B),x.effects=[],w&&t&&t.pendingBranch&&v===t.pendingId&&(t.deps--,t.deps===0&&!T&&t.resolve()),vp(O,"onResolve")},fallback(E){if(!x.pendingBranch)return;const{vnode:T,activeBranch:O,parentComponent:P,container:N,namespace:F}=x;vp(T,"onFallback");const B=h(O),Y=()=>{x.isInFallback&&(d(null,E,N,B,P,null,F,l,a),Cc(x,E))},Z=E.transition&&E.transition.mode==="out-in";Z&&(O.transition.afterLeave=Y),x.isInFallback=!0,p(O,P,null,!0),Z||Y()},move(E,T,O){x.activeBranch&&f(x.activeBranch,E,T,O),x.container=E},next(){return x.activeBranch&&h(x.activeBranch)},registerDep(E,T){const O=!!x.pendingBranch;O&&x.deps++;const P=E.vnode.el;E.asyncDep.catch(N=>{bu(N,E,0)}).then(N=>{if(E.isUnmounted||x.isUnmounted||x.pendingId!==E.suspenseId)return;E.asyncResolved=!0;const{vnode:F}=E;k_(E,N,!1),P&&(F.el=P);const B=!P&&E.subTree.el;T(E,F,m(P||E.subTree.el),P?null:h(E.subTree),x,i,a),B&&y(B),uw(E,F.el),O&&--x.deps===0&&x.resolve()})},unmount(E,T){x.isUnmounted=!0,x.activeBranch&&p(x.activeBranch,n,E,T),x.pendingBranch&&p(x.pendingBranch,n,E,T)}};return x}function jD(e,t,n,o,r,s,i,l,a){const u=t.suspense=fw(t,o,n,e.parentNode,document.createElement("div"),null,r,s,i,l,!0),c=a(e,u.pendingBranch=t.ssContent,n,u,s,i);return u.deps===0&&u.resolve(!1,!0),c}function HD(e){const{shapeFlag:t,children:n}=e,o=t&32;e.ssContent=a4(o?n.default:n),e.ssFallback=o?a4(n.fallback):k(Kn)}function a4(e){let t;if(Xe(e)){const n=nu&&e._c;n&&(e._d=!1,C()),e=e(),n&&(e._d=!0,t=jo,PE())}return Me(e)&&(e=ND(e)),e=ur(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(n=>n!==e)),e}function tE(e,t){t&&t.pendingBranch?Me(e)?t.effects.push(...e):t.effects.push(e):ag(e)}function Cc(e,t){e.activeBranch=t;const{vnode:n,parentComponent:o}=e;let r=t.el;for(;!r&&t.component;)t=t.component.subTree,r=t.el;n.el=r,o&&o.subTree===n&&(o.vnode.el=r,uw(o,r))}function UD(e){var t;return((t=e.props)==null?void 0:t.suspensible)!=null&&e.props.suspensible!==!1}const nE=Symbol.for("v-scx"),oE=()=>Be(nE);function ls(e,t){return Yp(e,null,t)}function rE(e,t){return Yp(e,null,{flush:"post"})}function sE(e,t){return Yp(e,null,{flush:"sync"})}const Jh={};function Te(e,t,n){return Yp(e,t,n)}function Yp(e,t,{immediate:n,deep:o,flush:r,once:s,onTrack:i,onTrigger:l}=Wt){if(t&&s){const E=t;t=(...T)=>{E(...T),x()}}const a=Bn,u=E=>o===!0?E:Ma(E,o===!1?1:void 0);let c,d=!1,f=!1;if(on(e)?(c=()=>e.value,d=fp(e)):_c(e)?(c=()=>u(e),d=!0):Me(e)?(f=!0,d=e.some(E=>_c(E)||fp(E)),c=()=>e.map(E=>{if(on(E))return E.value;if(_c(E))return u(E);if(Xe(E))return xi(E,a,2)})):Xe(e)?t?c=()=>xi(e,a,2):c=()=>(p&&p(),hr(e,a,3,[h])):c=yt,t&&o){const E=c;c=()=>Ma(E())}let p,h=E=>{p=_.onStop=()=>{xi(E,a,4),p=_.onStop=void 0}},m;if(Jp)if(h=yt,t?n&&hr(t,a,3,[c(),f?[]:void 0,h]):c(),r==="sync"){const E=oE();m=E.__watcherHandles||(E.__watcherHandles=[])}else return yt;let y=f?new Array(e.length).fill(Jh):Jh;const v=()=>{if(!(!_.active||!_.dirty))if(t){const E=_.run();(o||d||(f?E.some((T,O)=>ps(T,y[O])):ps(E,y)))&&(p&&p(),hr(t,a,3,[E,y===Jh?void 0:f&&y[0]===Jh?[]:y,h]),y=E)}else _.run()};v.allowRecurse=!!t;let w;r==="sync"?w=v:r==="post"?w=()=>Qn(v,a&&a.suspense):(v.pre=!0,a&&(v.id=a.uid),w=()=>h0(v));const _=new Rc(c,yt,w),S=X2(),x=()=>{_.stop(),S&&q2(S.effects,_)};return t?n?v():y=_.run():r==="post"?Qn(_.run.bind(_),a&&a.suspense):_.run(),m&&m.push(x),x}function WD(e,t,n){const o=this.proxy,r=tt(e)?e.includes(".")?iE(o,e):()=>o[e]:e.bind(o,o);let s;Xe(t)?s=t:(s=t.handler,n=t);const i=ou(this),l=Yp(r,s.bind(o),n);return i(),l}function iE(e,t){const n=t.split(".");return()=>{let o=e;for(let r=0;r<n.length&&o;r++)o=o[n[r]];return o}}function Ma(e,t,n=0,o){if(!ft(e)||e.__v_skip)return e;if(t&&t>0){if(n>=t)return e;n++}if(o=o||new Set,o.has(e))return e;if(o.add(e),on(e))Ma(e.value,t,n,o);else if(Me(e))for(let r=0;r<e.length;r++)Ma(e[r],t,n,o);else if(yu(e)||gc(e))e.forEach(r=>{Ma(r,t,n,o)});else if(rg(e))for(const r in e)Ma(e[r],t,n,o);return e}function He(e,t){if(Pn===null)return e;const n=_0(Pn)||Pn.proxy,o=e.dirs||(e.dirs=[]);for(let r=0;r<t.length;r++){let[s,i,l,a=Wt]=t[r];s&&(Xe(s)&&(s={mounted:s,updated:s}),s.deep&&Ma(i),o.push({dir:s,instance:n,value:i,oldValue:void 0,arg:l,modifiers:a}))}return e}function Ds(e,t,n,o){const r=e.dirs,s=t&&t.dirs;for(let i=0;i<r.length;i++){const l=r[i];s&&(l.oldValue=s[i].value);let a=l.dir[o];a&&(Gl(),hr(a,n,8,[e.el,l,e,t]),Yl())}}const hl=Symbol("_leaveCb"),Xh=Symbol("_enterCb");function pw(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Ct(()=>{e.isMounted=!0}),En(()=>{e.isUnmounting=!0}),e}const kr=[Function,Array],hw={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:kr,onEnter:kr,onAfterEnter:kr,onEnterCancelled:kr,onBeforeLeave:kr,onLeave:kr,onAfterLeave:kr,onLeaveCancelled:kr,onBeforeAppear:kr,onAppear:kr,onAfterAppear:kr,onAppearCancelled:kr},KD={name:"BaseTransition",props:hw,setup(e,{slots:t}){const n=at(),o=pw();return()=>{const r=t.default&&v0(t.default(),!0);if(!r||!r.length)return;let s=r[0];if(r.length>1){for(const f of r)if(f.type!==Kn){s=f;break}}const i=Mt(e),{mode:l}=i;if(o.isLeaving)return Nv(s);const a=u4(s);if(!a)return Nv(s);const u=Fc(a,i,o,n);eu(a,u);const c=n.subTree,d=c&&u4(c);if(d&&d.type!==Kn&&!ss(a,d)){const f=Fc(d,i,o,n);if(eu(d,f),l==="out-in")return o.isLeaving=!0,f.afterLeave=()=>{o.isLeaving=!1,n.update.active!==!1&&(n.effect.dirty=!0,n.update())},Nv(s);l==="in-out"&&a.type!==Kn&&(f.delayLeave=(p,h,m)=>{const y=aE(o,d);y[String(d.key)]=d,p[hl]=()=>{h(),p[hl]=void 0,delete u.delayedLeave},u.delayedLeave=m})}return s}}},lE=KD;function aE(e,t){const{leavingVNodes:n}=e;let o=n.get(t.type);return o||(o=Object.create(null),n.set(t.type,o)),o}function Fc(e,t,n,o){const{appear:r,mode:s,persisted:i=!1,onBeforeEnter:l,onEnter:a,onAfterEnter:u,onEnterCancelled:c,onBeforeLeave:d,onLeave:f,onAfterLeave:p,onLeaveCancelled:h,onBeforeAppear:m,onAppear:y,onAfterAppear:v,onAppearCancelled:w}=t,_=String(e.key),S=aE(n,e),x=(O,P)=>{O&&hr(O,o,9,P)},E=(O,P)=>{const N=P[1];x(O,P),Me(O)?O.every(F=>F.length<=1)&&N():O.length<=1&&N()},T={mode:s,persisted:i,beforeEnter(O){let P=l;if(!n.isMounted)if(r)P=m||l;else return;O[hl]&&O[hl](!0);const N=S[_];N&&ss(e,N)&&N.el[hl]&&N.el[hl](),x(P,[O])},enter(O){let P=a,N=u,F=c;if(!n.isMounted)if(r)P=y||a,N=v||u,F=w||c;else return;let B=!1;const Y=O[Xh]=Z=>{B||(B=!0,Z?x(F,[O]):x(N,[O]),T.delayedLeave&&T.delayedLeave(),O[Xh]=void 0)};P?E(P,[O,Y]):Y()},leave(O,P){const N=String(e.key);if(O[Xh]&&O[Xh](!0),n.isUnmounting)return P();x(d,[O]);let F=!1;const B=O[hl]=Y=>{F||(F=!0,P(),Y?x(h,[O]):x(p,[O]),O[hl]=void 0,S[N]===e&&delete S[N])};S[N]=e,f?E(f,[O,B]):B()},clone(O){return Fc(O,t,n,o)}};return T}function Nv(e){if(Zp(e))return e=hs(e),e.children=null,e}function u4(e){return Zp(e)?e.children?e.children[0]:void 0:e}function eu(e,t){e.shapeFlag&6&&e.component?eu(e.component.subTree,t):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function v0(e,t=!1,n){let o=[],r=0;for(let s=0;s<e.length;s++){let i=e[s];const l=n==null?i.key:String(n)+String(i.key!=null?i.key:s);i.type===fe?(i.patchFlag&128&&r++,o=o.concat(v0(i.children,t,l))):(t||i.type!==Kn)&&o.push(l!=null?hs(i,{key:l}):i)}if(r>1)for(let s=0;s<o.length;s++)o[s].patchFlag=-2;return o}/*! #__NO_SIDE_EFFECTS__ */function Q(e,t){return Xe(e)?(()=>Bt({name:e.name},t,{setup:e}))():e}const za=e=>!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function qD(e){Xe(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:o,delay:r=200,timeout:s,suspensible:i=!0,onError:l}=e;let a=null,u,c=0;const d=()=>(c++,a=null,f()),f=()=>{let p;return a||(p=a=t().catch(h=>{if(h=h instanceof Error?h:new Error(String(h)),l)return new Promise((m,y)=>{l(h,()=>m(d()),()=>y(h),c+1)});throw h}).then(h=>p!==a&&a?a:(h&&(h.__esModule||h[Symbol.toStringTag]==="Module")&&(h=h.default),u=h,h)))};return Q({name:"AsyncComponentWrapper",__asyncLoader:f,get __asyncResolved(){return u},setup(){const p=Bn;if(u)return()=>Pv(u,p);const h=w=>{a=null,bu(w,p,13,!o)};if(i&&p.suspense||Jp)return f().then(w=>()=>Pv(w,p)).catch(w=>(h(w),()=>o?k(o,{error:w}):null));const m=K(!1),y=K(),v=K(!!r);return r&&setTimeout(()=>{v.value=!1},r),s!=null&&setTimeout(()=>{if(!m.value&&!y.value){const w=new Error(`Async component timed out after ${s}ms.`);h(w),y.value=w}},s),f().then(()=>{m.value=!0,p.parent&&Zp(p.parent.vnode)&&(p.parent.effect.dirty=!0,h0(p.parent.update))}).catch(w=>{h(w),y.value=w}),()=>{if(m.value&&u)return Pv(u,p);if(y.value&&o)return k(o,{error:y.value});if(n&&!v.value)return k(n)}}})}function Pv(e,t){const{ref:n,props:o,children:r,ce:s}=t.vnode,i=k(e,o,r);return i.ref=n,i.ce=s,delete t.vnode.ce,i}const Zp=e=>e.type.__isKeepAlive,GD={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const n=at(),o=n.ctx;if(!o.renderer)return()=>{const w=t.default&&t.default();return w&&w.length===1?w[0]:w};const r=new Map,s=new Set;let i=null;const l=n.suspense,{renderer:{p:a,m:u,um:c,o:{createElement:d}}}=o,f=d("div");o.activate=(w,_,S,x,E)=>{const T=w.component;u(w,_,S,0,l),a(T.vnode,w,_,S,T,l,x,w.slotScopeIds,E),Qn(()=>{T.isDeactivated=!1,T.a&&yc(T.a);const O=w.props&&w.props.onVnodeMounted;O&&Vo(O,T.parent,w)},l)},o.deactivate=w=>{const _=w.component;u(w,f,null,1,l),Qn(()=>{_.da&&yc(_.da);const S=w.props&&w.props.onVnodeUnmounted;S&&Vo(S,_.parent,w),_.isDeactivated=!0},l)};function p(w){Lv(w),c(w,n,l,!0)}function h(w){r.forEach((_,S)=>{const x=$_(_.type);x&&(!w||!w(x))&&m(S)})}function m(w){const _=r.get(w);!i||!ss(_,i)?p(_):i&&Lv(i),r.delete(w),s.delete(w)}Te(()=>[e.include,e.exclude],([w,_])=>{w&&h(S=>Zd(w,S)),_&&h(S=>!Zd(_,S))},{flush:"post",deep:!0});let y=null;const v=()=>{y!=null&&r.set(y,Rv(n.subTree))};return Ct(v),Fi(v),En(()=>{r.forEach(w=>{const{subTree:_,suspense:S}=n,x=Rv(_);if(w.type===x.type&&w.key===x.key){Lv(x);const E=x.component.da;E&&Qn(E,S);return}p(w)})}),()=>{if(y=null,!t.default)return i=null;const w=t.default(),_=w[0];if(w.length>1)return i=null,w;if(!yo(_)||!(_.shapeFlag&4)&&!(_.shapeFlag&128))return i=null,_;let S=Rv(_);const x=S.type,E=$_(za(S)?S.type.__asyncResolved||{}:x),{include:T,exclude:O,max:P}=e;if(T&&(!E||!Zd(T,E))||O&&E&&Zd(O,E))return i=S,_;const N=S.key==null?x:S.key,F=r.get(N);return S.el&&(S=hs(S),_.shapeFlag&128&&(_.ssContent=S)),y=N,F?(S.el=F.el,S.component=F.component,S.transition&&eu(S,S.transition),S.shapeFlag|=512,s.delete(N),s.add(N)):(s.add(N),P&&s.size>parseInt(P,10)&&m(s.values().next().value)),S.shapeFlag|=256,i=S,eE(_.type)?_:S}}},YD=GD;function Zd(e,t){return Me(e)?e.some(n=>Zd(n,t)):tt(e)?e.split(",").includes(t):ER(e)?e.test(t):!1}function uE(e,t){cE(e,"a",t)}function mw(e,t){cE(e,"da",t)}function cE(e,t,n=Bn){const o=e.__wdc||(e.__wdc=()=>{let r=n;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(y0(t,o,n),n){let r=n.parent;for(;r&&r.parent;)Zp(r.parent.vnode)&&ZD(o,t,n,r),r=r.parent}}function ZD(e,t,n,o){const r=y0(t,e,o,!0);ti(()=>{q2(o[t],r)},n)}function Lv(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function Rv(e){return e.shapeFlag&128?e.ssContent:e}function y0(e,t,n=Bn,o=!1){if(n){const r=n[e]||(n[e]=[]),s=t.__weh||(t.__weh=(...i)=>{if(n.isUnmounted)return;Gl();const l=ou(n),a=hr(t,n,e,i);return l(),Yl(),a});return o?r.unshift(s):r.push(s),s}}const Di=e=>(t,n=Bn)=>(!Jp||e==="sp")&&y0(e,(...o)=>t(...o),n),yd=Di("bm"),Ct=Di("m"),dE=Di("bu"),Fi=Di("u"),En=Di("bum"),ti=Di("um"),fE=Di("sp"),pE=Di("rtg"),hE=Di("rtc");function mE(e,t=Bn){y0("ec",e,t)}function nt(e,t,n,o){let r;const s=n&&n[o];if(Me(e)||tt(e)){r=new Array(e.length);for(let i=0,l=e.length;i<l;i++)r[i]=t(e[i],i,void 0,s&&s[i])}else if(typeof e=="number"){r=new Array(e);for(let i=0;i<e;i++)r[i]=t(i+1,i,void 0,s&&s[i])}else if(ft(e))if(e[Symbol.iterator])r=Array.from(e,(i,l)=>t(i,l,void 0,s&&s[l]));else{const i=Object.keys(e);r=new Array(i.length);for(let l=0,a=i.length;l<a;l++){const u=i[l];r[l]=t(e[u],u,l,s&&s[l])}}else r=[];return n&&(n[o]=r),r}function tu(e,t){for(let n=0;n<t.length;n++){const o=t[n];if(Me(o))for(let r=0;r<o.length;r++)e[o[r].name]=o[r].fn;else o&&(e[o.name]=o.key?(...r)=>{const s=o.fn(...r);return s&&(s.key=o.key),s}:o.fn)}return e}function he(e,t,n={},o,r){if(Pn.isCE||Pn.parent&&za(Pn.parent)&&Pn.parent.isCE)return t!=="default"&&(n.name=t),k("slot",n,o&&o());let s=e[t];s&&s._c&&(s._d=!1),C();const i=s&&gE(s(n)),l=q(fe,{key:n.key||i&&i.key||`_${t}`},i||(o?o():[]),i&&e._===1?64:-2);return!r&&l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),s&&s._c&&(s._d=!0),l}function gE(e){return e.some(t=>yo(t)?!(t.type===Kn||t.type===fe&&!gE(t.children)):!0)?e:null}function vE(e,t){const n={};for(const o in e)n[t&&/[A-Z]/.test(o)?`on:${o}`:vc(o)]=e[o];return n}const p_=e=>e?VE(e)?_0(e)||e.proxy:p_(e.parent):null,Pf=Bt(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>p_(e.parent),$root:e=>p_(e.root),$emit:e=>e.emit,$options:e=>gw(e),$forceUpdate:e=>e.f||(e.f=()=>{e.effect.dirty=!0,h0(e.update)}),$nextTick:e=>e.n||(e.n=ot.bind(e.proxy)),$watch:e=>WD.bind(e)}),Dv=(e,t)=>e!==Wt&&!e.__isScriptSetup&&vt(e,t),h_={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:o,data:r,props:s,accessCache:i,type:l,appContext:a}=e;let u;if(t[0]!=="$"){const p=i[t];if(p!==void 0)switch(p){case 1:return o[t];case 2:return r[t];case 4:return n[t];case 3:return s[t]}else{if(Dv(o,t))return i[t]=1,o[t];if(r!==Wt&&vt(r,t))return i[t]=2,r[t];if((u=e.propsOptions[0])&&vt(u,t))return i[t]=3,s[t];if(n!==Wt&&vt(n,t))return i[t]=4,n[t];m_&&(i[t]=0)}}const c=Pf[t];let d,f;if(c)return t==="$attrs"&&Yo(e.attrs,"get",""),c(e);if((d=l.__cssModules)&&(d=d[t]))return d;if(n!==Wt&&vt(n,t))return i[t]=4,n[t];if(f=a.config.globalProperties,vt(f,t))return f[t]},set({_:e},t,n){const{data:o,setupState:r,ctx:s}=e;return Dv(r,t)?(r[t]=n,!0):o!==Wt&&vt(o,t)?(o[t]=n,!0):vt(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(s[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:o,appContext:r,propsOptions:s}},i){let l;return!!n[i]||e!==Wt&&vt(e,i)||Dv(t,i)||(l=s[0])&&vt(l,i)||vt(o,i)||vt(Pf,i)||vt(r.config.globalProperties,i)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:vt(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}},JD=Bt({},h_,{get(e,t){if(t!==Symbol.unscopables)return h_.get(e,t,e)},has(e,t){return t[0]!=="_"&&!IR(t)}});function XD(){return null}function QD(){return null}function eF(e){}function tF(e){}function nF(){return null}function oF(){}function rF(e,t){return null}function Kr(){return yE().slots}function _d(){return yE().attrs}function yE(){const e=at();return e.setupContext||(e.setupContext=HE(e))}function yp(e){return Me(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function sF(e,t){const n=yp(e);for(const o in t){if(o.startsWith("__skip"))continue;let r=n[o];r?Me(r)||Xe(r)?r=n[o]={type:r,default:t[o]}:r.default=t[o]:r===null&&(r=n[o]={default:t[o]}),r&&t[`__skip_${o}`]&&(r.skipFactory=!0)}return n}function iF(e,t){return!e||!t?e||t:Me(e)&&Me(t)?e.concat(t):Bt({},yp(e),yp(t))}function lF(e,t){const n={};for(const o in e)t.includes(o)||Object.defineProperty(n,o,{enumerable:!0,get:()=>e[o]});return n}function aF(e){const t=at();let n=e();return C_(),G2(n)&&(n=n.catch(o=>{throw ou(t),o})),[n,()=>ou(t)]}let m_=!0;function uF(e){const t=gw(e),n=e.proxy,o=e.ctx;m_=!1,t.beforeCreate&&c4(t.beforeCreate,e,"bc");const{data:r,computed:s,methods:i,watch:l,provide:a,inject:u,created:c,beforeMount:d,mounted:f,beforeUpdate:p,updated:h,activated:m,deactivated:y,beforeDestroy:v,beforeUnmount:w,destroyed:_,unmounted:S,render:x,renderTracked:E,renderTriggered:T,errorCaptured:O,serverPrefetch:P,expose:N,inheritAttrs:F,components:B,directives:Y,filters:Z}=t;if(u&&cF(u,o,null),i)for(const V in i){const H=i[V];Xe(H)&&(o[V]=H.bind(n))}if(r){const V=r.call(n,n);ft(V)&&(e.data=Dn(V))}if(m_=!0,s)for(const V in s){const H=s[V],L=Xe(H)?H.bind(n,n):Xe(H.get)?H.get.bind(n,n):yt,I=!Xe(H)&&Xe(H.set)?H.set.bind(n):yt,X=R({get:L,set:I});Object.defineProperty(o,V,{enumerable:!0,configurable:!0,get:()=>X.value,set:oe=>X.value=oe})}if(l)for(const V in l)_E(l[V],o,n,V);if(a){const V=Xe(a)?a.call(n):a;Reflect.ownKeys(V).forEach(H=>{wt(H,V[H])})}c&&c4(c,e,"c");function j(V,H){Me(H)?H.forEach(L=>V(L.bind(n))):H&&V(H.bind(n))}if(j(yd,d),j(Ct,f),j(dE,p),j(Fi,h),j(uE,m),j(mw,y),j(mE,O),j(hE,E),j(pE,T),j(En,w),j(ti,S),j(fE,P),Me(N))if(N.length){const V=e.exposed||(e.exposed={});N.forEach(H=>{Object.defineProperty(V,H,{get:()=>n[H],set:L=>n[H]=L})})}else e.exposed||(e.exposed={});x&&e.render===yt&&(e.render=x),F!=null&&(e.inheritAttrs=F),B&&(e.components=B),Y&&(e.directives=Y)}function cF(e,t,n=yt){Me(e)&&(e=g_(e));for(const o in e){const r=e[o];let s;ft(r)?"default"in r?s=Be(r.from||o,r.default,!0):s=Be(r.from||o):s=Be(r),on(s)?Object.defineProperty(t,o,{enumerable:!0,configurable:!0,get:()=>s.value,set:i=>s.value=i}):t[o]=s}}function c4(e,t,n){hr(Me(e)?e.map(o=>o.bind(t.proxy)):e.bind(t.proxy),t,n)}function _E(e,t,n,o){const r=o.includes(".")?iE(n,o):()=>n[o];if(tt(e)){const s=t[e];Xe(s)&&Te(r,s)}else if(Xe(e))Te(r,e.bind(n));else if(ft(e))if(Me(e))e.forEach(s=>_E(s,t,n,o));else{const s=Xe(e.handler)?e.handler.bind(n):t[e.handler];Xe(s)&&Te(r,s,e)}}function gw(e){const t=e.type,{mixins:n,extends:o}=t,{mixins:r,optionsCache:s,config:{optionMergeStrategies:i}}=e.appContext,l=s.get(t);let a;return l?a=l:!r.length&&!n&&!o?a=t:(a={},r.length&&r.forEach(u=>cg(a,u,i,!0)),cg(a,t,i)),ft(t)&&s.set(t,a),a}function cg(e,t,n,o=!1){const{mixins:r,extends:s}=t;s&&cg(e,s,n,!0),r&&r.forEach(i=>cg(e,i,n,!0));for(const i in t)if(!(o&&i==="expose")){const l=dF[i]||n&&n[i];e[i]=l?l(e[i],t[i]):t[i]}return e}const dF={data:d4,props:f4,emits:f4,methods:Jd,computed:Jd,beforeCreate:Co,created:Co,beforeMount:Co,mounted:Co,beforeUpdate:Co,updated:Co,beforeDestroy:Co,beforeUnmount:Co,destroyed:Co,unmounted:Co,activated:Co,deactivated:Co,errorCaptured:Co,serverPrefetch:Co,components:Jd,directives:Jd,watch:pF,provide:d4,inject:fF};function d4(e,t){return t?e?function(){return Bt(Xe(e)?e.call(this,this):e,Xe(t)?t.call(this,this):t)}:t:e}function fF(e,t){return Jd(g_(e),g_(t))}function g_(e){if(Me(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function Co(e,t){return e?[...new Set([].concat(e,t))]:t}function Jd(e,t){return e?Bt(Object.create(null),e,t):t}function f4(e,t){return e?Me(e)&&Me(t)?[...new Set([...e,...t])]:Bt(Object.create(null),yp(e),yp(t??{})):t}function pF(e,t){if(!e)return t;if(!t)return e;const n=Bt(Object.create(null),e);for(const o in t)n[o]=Co(e[o],t[o]);return n}function bE(){return{app:null,config:{isNativeTag:Dm,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let hF=0;function mF(e,t){return function(o,r=null){Xe(o)||(o=Bt({},o)),r!=null&&!ft(r)&&(r=null);const s=bE(),i=new WeakSet;let l=!1;const a=s.app={_uid:hF++,_component:o,_props:r,_container:null,_context:s,_instance:null,version:WE,get config(){return s.config},set config(u){},use(u,...c){return i.has(u)||(u&&Xe(u.install)?(i.add(u),u.install(a,...c)):Xe(u)&&(i.add(u),u(a,...c))),a},mixin(u){return s.mixins.includes(u)||s.mixins.push(u),a},component(u,c){return c?(s.components[u]=c,a):s.components[u]},directive(u,c){return c?(s.directives[u]=c,a):s.directives[u]},mount(u,c,d){if(!l){const f=k(o,r);return f.appContext=s,d===!0?d="svg":d===!1&&(d=void 0),c&&t?t(f,u):e(f,u,d),l=!0,a._container=u,u.__vue_app__=a,_0(f.component)||f.component.proxy}},unmount(){l&&(e(null,a._container),delete a._container.__vue_app__)},provide(u,c){return s.provides[u]=c,a},runWithContext(u){const c=kc;kc=a;try{return u()}finally{kc=c}}};return a}}let kc=null;function wt(e,t){if(Bn){let n=Bn.provides;const o=Bn.parent&&Bn.parent.provides;o===n&&(n=Bn.provides=Object.create(o)),n[e]=t}}function Be(e,t,n=!1){const o=Bn||Pn;if(o||kc){const r=o?o.parent==null?o.vnode.appContext&&o.vnode.appContext.provides:o.parent.provides:kc._context.provides;if(r&&e in r)return r[e];if(arguments.length>1)return n&&Xe(t)?t.call(o&&o.proxy):t}}function gF(){return!!(Bn||Pn||kc)}const wE=Object.create(null),v_=()=>Object.create(wE),CE=e=>Object.getPrototypeOf(e)===wE;function vF(e,t,n,o=!1){const r={},s=v_();e.propsDefaults=Object.create(null),kE(e,t,r,s);for(const i in e.propsOptions[0])i in r||(r[i]=void 0);n?e.props=o?r:ow(r):e.type.props?e.props=r:e.props=s,e.attrs=s}function yF(e,t,n,o){const{props:r,attrs:s,vnode:{patchFlag:i}}=e,l=Mt(r),[a]=e.propsOptions;let u=!1;if((o||i>0)&&!(i&16)){if(i&8){const c=e.vnode.dynamicProps;for(let d=0;d<c.length;d++){let f=c[d];if(m0(e.emitsOptions,f))continue;const p=t[f];if(a)if(vt(s,f))p!==s[f]&&(s[f]=p,u=!0);else{const h=yn(f);r[h]=y_(a,l,h,p,e,!1)}else p!==s[f]&&(s[f]=p,u=!0)}}}else{kE(e,t,r,s)&&(u=!0);let c;for(const d in l)(!t||!vt(t,d)&&((c=zo(d))===d||!vt(t,c)))&&(a?n&&(n[d]!==void 0||n[c]!==void 0)&&(r[d]=y_(a,l,d,void 0,e,!0)):delete r[d]);if(s!==l)for(const d in s)(!t||!vt(t,d))&&(delete s[d],u=!0)}u&&Ei(e.attrs,"set","")}function kE(e,t,n,o){const[r,s]=e.propsOptions;let i=!1,l;if(t)for(let a in t){if(Al(a))continue;const u=t[a];let c;r&&vt(r,c=yn(a))?!s||!s.includes(c)?n[c]=u:(l||(l={}))[c]=u:m0(e.emitsOptions,a)||(!(a in o)||u!==o[a])&&(o[a]=u,i=!0)}if(s){const a=Mt(n),u=l||Wt;for(let c=0;c<s.length;c++){const d=s[c];n[d]=y_(r,a,d,u[d],e,!vt(u,d))}}return i}function y_(e,t,n,o,r,s){const i=e[n];if(i!=null){const l=vt(i,"default");if(l&&o===void 0){const a=i.default;if(i.type!==Function&&!i.skipFactory&&Xe(a)){const{propsDefaults:u}=r;if(n in u)o=u[n];else{const c=ou(r);o=u[n]=a.call(null,t),c()}}else o=a}i[0]&&(s&&!l?o=!1:i[1]&&(o===""||o===zo(n))&&(o=!0))}return o}function SE(e,t,n=!1){const o=t.propsCache,r=o.get(e);if(r)return r;const s=e.props,i={},l=[];let a=!1;if(!Xe(e)){const c=d=>{a=!0;const[f,p]=SE(d,t,!0);Bt(i,f),p&&l.push(...p)};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!s&&!a)return ft(e)&&o.set(e,mc),mc;if(Me(s))for(let c=0;c<s.length;c++){const d=yn(s[c]);p4(d)&&(i[d]=Wt)}else if(s)for(const c in s){const d=yn(c);if(p4(d)){const f=s[c],p=i[d]=Me(f)||Xe(f)?{type:f}:Bt({},f);if(p){const h=g4(Boolean,p.type),m=g4(String,p.type);p[0]=h>-1,p[1]=m<0||h<m,(h>-1||vt(p,"default"))&&l.push(d)}}}const u=[i,l];return ft(e)&&o.set(e,u),u}function p4(e){return e[0]!=="$"&&!Al(e)}function h4(e){return e===null?"null":typeof e=="function"?e.name||"":typeof e=="object"&&e.constructor&&e.constructor.name||""}function m4(e,t){return h4(e)===h4(t)}function g4(e,t){return Me(t)?t.findIndex(n=>m4(n,e)):Xe(t)&&m4(t,e)?0:-1}const $E=e=>e[0]==="_"||e==="$stable",vw=e=>Me(e)?e.map(ur):[ur(e)],_F=(e,t,n)=>{if(t._n)return t;const o=$((...r)=>vw(t(...r)),n);return o._c=!1,o},EE=(e,t,n)=>{const o=e._ctx;for(const r in e){if($E(r))continue;const s=e[r];if(Xe(s))t[r]=_F(r,s,o);else if(s!=null){const i=vw(s);t[r]=()=>i}}},xE=(e,t)=>{const n=vw(t);e.slots.default=()=>n},bF=(e,t)=>{if(e.vnode.shapeFlag&32){const n=t._;n?(e.slots=Mt(t),w$(e.slots,"_",n)):EE(t,e.slots=v_())}else e.slots=v_(),t&&xE(e,t)},wF=(e,t,n)=>{const{vnode:o,slots:r}=e;let s=!0,i=Wt;if(o.shapeFlag&32){const l=t._;l?n&&l===1?s=!1:(Bt(r,t),!n&&l===1&&delete r._):(s=!t.$stable,EE(t,r)),i=t}else t&&(xE(e,t),i={default:1});if(s)for(const l in r)!$E(l)&&i[l]==null&&delete r[l]};function dg(e,t,n,o,r=!1){if(Me(e)){e.forEach((f,p)=>dg(f,t&&(Me(t)?t[p]:t),n,o,r));return}if(za(o)&&!r)return;const s=o.shapeFlag&4?_0(o.component)||o.component.proxy:o.el,i=r?null:s,{i:l,r:a}=e,u=t&&t.r,c=l.refs===Wt?l.refs={}:l.refs,d=l.setupState;if(u!=null&&u!==a&&(tt(u)?(c[u]=null,vt(d,u)&&(d[u]=null)):on(u)&&(u.value=null)),Xe(a))xi(a,l,12,[i,c]);else{const f=tt(a),p=on(a);if(f||p){const h=()=>{if(e.f){const m=f?vt(d,a)?d[a]:c[a]:a.value;r?Me(m)&&q2(m,s):Me(m)?m.includes(s)||m.push(s):f?(c[a]=[s],vt(d,a)&&(d[a]=c[a])):(a.value=[s],e.k&&(c[e.k]=a.value))}else f?(c[a]=i,vt(d,a)&&(d[a]=i)):p&&(a.value=i,e.k&&(c[e.k]=i))};i?(h.id=-1,Qn(h,n)):h()}}}let Ki=!1;const CF=e=>e.namespaceURI.includes("svg")&&e.tagName!=="foreignObject",kF=e=>e.namespaceURI.includes("MathML"),Qh=e=>{if(CF(e))return"svg";if(kF(e))return"mathml"},em=e=>e.nodeType===8;function SF(e){const{mt:t,p:n,o:{patchProp:o,createText:r,nextSibling:s,parentNode:i,remove:l,insert:a,createComment:u}}=e,c=(_,S)=>{if(!S.hasChildNodes()){n(null,_,S),ug(),S._vnode=_;return}Ki=!1,d(S.firstChild,_,null,null,null),ug(),S._vnode=_,Ki&&console.error("Hydration completed but contains mismatches.")},d=(_,S,x,E,T,O=!1)=>{O=O||!!S.dynamicChildren;const P=em(_)&&_.data==="[",N=()=>m(_,S,x,E,T,P),{type:F,ref:B,shapeFlag:Y,patchFlag:Z}=S;let U=_.nodeType;S.el=_,Z===-2&&(O=!1,S.dynamicChildren=null);let j=null;switch(F){case Ai:U!==3?S.children===""?(a(S.el=r(""),i(_),_),j=_):j=N():(_.data!==S.children&&(Ki=!0,_.data=S.children),j=s(_));break;case Kn:w(_)?(j=s(_),v(S.el=_.content.firstChild,_,x)):U!==8||P?j=N():j=s(_);break;case ja:if(P&&(_=s(_),U=_.nodeType),U===1||U===3){j=_;const V=!S.children.length;for(let H=0;H<S.staticCount;H++)V&&(S.children+=j.nodeType===1?j.outerHTML:j.data),H===S.staticCount-1&&(S.anchor=j),j=s(j);return P?s(j):j}else N();break;case fe:P?j=h(_,S,x,E,T,O):j=N();break;default:if(Y&1)(U!==1||S.type.toLowerCase()!==_.tagName.toLowerCase())&&!w(_)?j=N():j=f(_,S,x,E,T,O);else if(Y&6){S.slotScopeIds=T;const V=i(_);if(P?j=y(_):em(_)&&_.data==="teleport start"?j=y(_,_.data,"teleport end"):j=s(_),t(S,V,null,x,E,Qh(V),O),za(S)){let H;P?(H=k(fe),H.anchor=j?j.previousSibling:V.lastChild):H=_.nodeType===3?ne(""):k("div"),H.el=_,S.component.subTree=H}}else Y&64?U!==8?j=N():j=S.type.hydrate(_,S,x,E,T,O,e,p):Y&128&&(j=S.type.hydrate(_,S,x,E,Qh(i(_)),T,O,e,d))}return B!=null&&dg(B,null,E,S),j},f=(_,S,x,E,T,O)=>{O=O||!!S.dynamicChildren;const{type:P,props:N,patchFlag:F,shapeFlag:B,dirs:Y,transition:Z}=S,U=P==="input"||P==="option";if(U||F!==-1){Y&&Ds(S,null,x,"created");let j=!1;if(w(_)){j=IE(E,Z)&&x&&x.vnode.props&&x.vnode.props.appear;const H=_.content.firstChild;j&&Z.beforeEnter(H),v(H,_,x),S.el=_=H}if(B&16&&!(N&&(N.innerHTML||N.textContent))){let H=p(_.firstChild,S,_,x,E,T,O);for(;H;){Ki=!0;const L=H;H=H.nextSibling,l(L)}}else B&8&&_.textContent!==S.children&&(Ki=!0,_.textContent=S.children);if(N)if(U||!O||F&48)for(const H in N)(U&&(H.endsWith("value")||H==="indeterminate")||vu(H)&&!Al(H)||H[0]===".")&&o(_,H,null,N[H],void 0,void 0,x);else N.onClick&&o(_,"onClick",null,N.onClick,void 0,void 0,x);let V;(V=N&&N.onVnodeBeforeMount)&&Vo(V,x,S),Y&&Ds(S,null,x,"beforeMount"),((V=N&&N.onVnodeMounted)||Y||j)&&tE(()=>{V&&Vo(V,x,S),j&&Z.enter(_),Y&&Ds(S,null,x,"mounted")},E)}return _.nextSibling},p=(_,S,x,E,T,O,P)=>{P=P||!!S.dynamicChildren;const N=S.children,F=N.length;for(let B=0;B<F;B++){const Y=P?N[B]:N[B]=ur(N[B]);if(_)_=d(_,Y,E,T,O,P);else{if(Y.type===Ai&&!Y.children)continue;Ki=!0,n(null,Y,x,null,E,T,Qh(x),O)}}return _},h=(_,S,x,E,T,O)=>{const{slotScopeIds:P}=S;P&&(T=T?T.concat(P):P);const N=i(_),F=p(s(_),S,N,x,E,T,O);return F&&em(F)&&F.data==="]"?s(S.anchor=F):(Ki=!0,a(S.anchor=u("]"),N,F),F)},m=(_,S,x,E,T,O)=>{if(Ki=!0,S.el=null,O){const F=y(_);for(;;){const B=s(_);if(B&&B!==F)l(B);else break}}const P=s(_),N=i(_);return l(_),n(null,S,N,P,x,E,Qh(N),T),P},y=(_,S="[",x="]")=>{let E=0;for(;_;)if(_=s(_),_&&em(_)&&(_.data===S&&E++,_.data===x)){if(E===0)return s(_);E--}return _},v=(_,S,x)=>{const E=S.parentNode;E&&E.replaceChild(_,S);let T=x;for(;T;)T.vnode.el===S&&(T.vnode.el=T.subTree.el=_),T=T.parent},w=_=>_.nodeType===1&&_.tagName.toLowerCase()==="template";return[c,d]}const Qn=tE;function ME(e){return OE(e)}function TE(e){return OE(e,SF)}function OE(e,t){const n=C$();n.__VUE__=!0;const{insert:o,remove:r,patchProp:s,createElement:i,createText:l,createComment:a,setText:u,setElementText:c,parentNode:d,nextSibling:f,setScopeId:p=yt,insertStaticContent:h}=e,m=(G,J,ue,_e=null,ye=null,Ae=null,Le=void 0,Ee=null,Pe=!!J.dynamicChildren)=>{if(G===J)return;G&&!ss(G,J)&&(_e=ee(G),oe(G,ye,Ae,!0),G=null),J.patchFlag===-2&&(Pe=!1,J.dynamicChildren=null);const{type:me,ref:je,shapeFlag:Ze}=J;switch(me){case Ai:y(G,J,ue,_e);break;case Kn:v(G,J,ue,_e);break;case ja:G==null&&w(J,ue,_e,Le);break;case fe:B(G,J,ue,_e,ye,Ae,Le,Ee,Pe);break;default:Ze&1?x(G,J,ue,_e,ye,Ae,Le,Ee,Pe):Ze&6?Y(G,J,ue,_e,ye,Ae,Le,Ee,Pe):(Ze&64||Ze&128)&&me.process(G,J,ue,_e,ye,Ae,Le,Ee,Pe,le)}je!=null&&ye&&dg(je,G&&G.ref,Ae,J||G,!J)},y=(G,J,ue,_e)=>{if(G==null)o(J.el=l(J.children),ue,_e);else{const ye=J.el=G.el;J.children!==G.children&&u(ye,J.children)}},v=(G,J,ue,_e)=>{G==null?o(J.el=a(J.children||""),ue,_e):J.el=G.el},w=(G,J,ue,_e)=>{[G.el,G.anchor]=h(G.children,J,ue,_e,G.el,G.anchor)},_=({el:G,anchor:J},ue,_e)=>{let ye;for(;G&&G!==J;)ye=f(G),o(G,ue,_e),G=ye;o(J,ue,_e)},S=({el:G,anchor:J})=>{let ue;for(;G&&G!==J;)ue=f(G),r(G),G=ue;r(J)},x=(G,J,ue,_e,ye,Ae,Le,Ee,Pe)=>{J.type==="svg"?Le="svg":J.type==="math"&&(Le="mathml"),G==null?E(J,ue,_e,ye,Ae,Le,Ee,Pe):P(G,J,ye,Ae,Le,Ee,Pe)},E=(G,J,ue,_e,ye,Ae,Le,Ee)=>{let Pe,me;const{props:je,shapeFlag:Ze,transition:ce,dirs:te}=G;if(Pe=G.el=i(G.type,Ae,je&&je.is,je),Ze&8?c(Pe,G.children):Ze&16&&O(G.children,Pe,null,_e,ye,Fv(G,Ae),Le,Ee),te&&Ds(G,null,_e,"created"),T(Pe,G,G.scopeId,Le,_e),je){for(const Ve in je)Ve!=="value"&&!Al(Ve)&&s(Pe,Ve,null,je[Ve],Ae,G.children,_e,ye,xe);"value"in je&&s(Pe,"value",null,je.value,Ae),(me=je.onVnodeBeforeMount)&&Vo(me,_e,G)}te&&Ds(G,null,_e,"beforeMount");const pe=IE(ye,ce);pe&&ce.beforeEnter(Pe),o(Pe,J,ue),((me=je&&je.onVnodeMounted)||pe||te)&&Qn(()=>{me&&Vo(me,_e,G),pe&&ce.enter(Pe),te&&Ds(G,null,_e,"mounted")},ye)},T=(G,J,ue,_e,ye)=>{if(ue&&p(G,ue),_e)for(let Ae=0;Ae<_e.length;Ae++)p(G,_e[Ae]);if(ye){let Ae=ye.subTree;if(J===Ae){const Le=ye.vnode;T(G,Le,Le.scopeId,Le.slotScopeIds,ye.parent)}}},O=(G,J,ue,_e,ye,Ae,Le,Ee,Pe=0)=>{for(let me=Pe;me<G.length;me++){const je=G[me]=Ee?ml(G[me]):ur(G[me]);m(null,je,J,ue,_e,ye,Ae,Le,Ee)}},P=(G,J,ue,_e,ye,Ae,Le)=>{const Ee=J.el=G.el;let{patchFlag:Pe,dynamicChildren:me,dirs:je}=J;Pe|=G.patchFlag&16;const Ze=G.props||Wt,ce=J.props||Wt;let te;if(ue&&aa(ue,!1),(te=ce.onVnodeBeforeUpdate)&&Vo(te,ue,J,G),je&&Ds(J,G,ue,"beforeUpdate"),ue&&aa(ue,!0),me?N(G.dynamicChildren,me,Ee,ue,_e,Fv(J,ye),Ae):Le||H(G,J,Ee,null,ue,_e,Fv(J,ye),Ae,!1),Pe>0){if(Pe&16)F(Ee,J,Ze,ce,ue,_e,ye);else if(Pe&2&&Ze.class!==ce.class&&s(Ee,"class",null,ce.class,ye),Pe&4&&s(Ee,"style",Ze.style,ce.style,ye),Pe&8){const pe=J.dynamicProps;for(let Ve=0;Ve<pe.length;Ve++){const Je=pe[Ve],$e=Ze[Je],ie=ce[Je];(ie!==$e||Je==="value")&&s(Ee,Je,$e,ie,ye,G.children,ue,_e,xe)}}Pe&1&&G.children!==J.children&&c(Ee,J.children)}else!Le&&me==null&&F(Ee,J,Ze,ce,ue,_e,ye);((te=ce.onVnodeUpdated)||je)&&Qn(()=>{te&&Vo(te,ue,J,G),je&&Ds(J,G,ue,"updated")},_e)},N=(G,J,ue,_e,ye,Ae,Le)=>{for(let Ee=0;Ee<J.length;Ee++){const Pe=G[Ee],me=J[Ee],je=Pe.el&&(Pe.type===fe||!ss(Pe,me)||Pe.shapeFlag&70)?d(Pe.el):ue;m(Pe,me,je,null,_e,ye,Ae,Le,!0)}},F=(G,J,ue,_e,ye,Ae,Le)=>{if(ue!==_e){if(ue!==Wt)for(const Ee in ue)!Al(Ee)&&!(Ee in _e)&&s(G,Ee,ue[Ee],null,Le,J.children,ye,Ae,xe);for(const Ee in _e){if(Al(Ee))continue;const Pe=_e[Ee],me=ue[Ee];Pe!==me&&Ee!=="value"&&s(G,Ee,me,Pe,Le,J.children,ye,Ae,xe)}"value"in _e&&s(G,"value",ue.value,_e.value,Le)}},B=(G,J,ue,_e,ye,Ae,Le,Ee,Pe)=>{const me=J.el=G?G.el:l(""),je=J.anchor=G?G.anchor:l("");let{patchFlag:Ze,dynamicChildren:ce,slotScopeIds:te}=J;te&&(Ee=Ee?Ee.concat(te):te),G==null?(o(me,ue,_e),o(je,ue,_e),O(J.children||[],ue,je,ye,Ae,Le,Ee,Pe)):Ze>0&&Ze&64&&ce&&G.dynamicChildren?(N(G.dynamicChildren,ce,ue,ye,Ae,Le,Ee),(J.key!=null||ye&&J===ye.subTree)&&yw(G,J,!0)):H(G,J,ue,je,ye,Ae,Le,Ee,Pe)},Y=(G,J,ue,_e,ye,Ae,Le,Ee,Pe)=>{J.slotScopeIds=Ee,G==null?J.shapeFlag&512?ye.ctx.activate(J,ue,_e,Le,Pe):Z(J,ue,_e,ye,Ae,Le,Pe):U(G,J,Pe)},Z=(G,J,ue,_e,ye,Ae,Le)=>{const Ee=G.component=FE(G,_e,ye);if(Zp(G)&&(Ee.ctx.renderer=le),BE(Ee),Ee.asyncDep){if(ye&&ye.registerDep(Ee,j),!G.el){const Pe=Ee.subTree=k(Kn);v(null,Pe,J,ue)}}else j(Ee,G,J,ue,ye,Ae,Le)},U=(G,J,ue)=>{const _e=J.component=G.component;if(RD(G,J,ue))if(_e.asyncDep&&!_e.asyncResolved){V(_e,J,ue);return}else _e.next=J,TD(_e.update),_e.effect.dirty=!0,_e.update();else J.el=G.el,_e.vnode=J},j=(G,J,ue,_e,ye,Ae,Le)=>{const Ee=()=>{if(G.isMounted){let{next:je,bu:Ze,u:ce,parent:te,vnode:pe}=G;{const we=AE(G);if(we){je&&(je.el=pe.el,V(G,je,Le)),we.asyncDep.then(()=>{G.isUnmounted||Ee()});return}}let Ve=je,Je;aa(G,!1),je?(je.el=pe.el,V(G,je,Le)):je=pe,Ze&&yc(Ze),(Je=je.props&&je.props.onVnodeBeforeUpdate)&&Vo(Je,te,je,pe),aa(G,!0);const $e=Vm(G),ie=G.subTree;G.subTree=$e,m(ie,$e,d(ie.el),ee(ie),G,ye,Ae),je.el=$e.el,Ve===null&&uw(G,$e.el),ce&&Qn(ce,ye),(Je=je.props&&je.props.onVnodeUpdated)&&Qn(()=>Vo(Je,te,je,pe),ye)}else{let je;const{el:Ze,props:ce}=J,{bm:te,m:pe,parent:Ve}=G,Je=za(J);if(aa(G,!1),te&&yc(te),!Je&&(je=ce&&ce.onVnodeBeforeMount)&&Vo(je,Ve,J),aa(G,!0),Ze&&Ge){const $e=()=>{G.subTree=Vm(G),Ge(Ze,G.subTree,G,ye,null)};Je?J.type.__asyncLoader().then(()=>!G.isUnmounted&&$e()):$e()}else{const $e=G.subTree=Vm(G);m(null,$e,ue,_e,G,ye,Ae),J.el=$e.el}if(pe&&Qn(pe,ye),!Je&&(je=ce&&ce.onVnodeMounted)){const $e=J;Qn(()=>Vo(je,Ve,$e),ye)}(J.shapeFlag&256||Ve&&za(Ve.vnode)&&Ve.vnode.shapeFlag&256)&&G.a&&Qn(G.a,ye),G.isMounted=!0,J=ue=_e=null}},Pe=G.effect=new Rc(Ee,yt,()=>h0(me),G.scope),me=G.update=()=>{Pe.dirty&&Pe.run()};me.id=G.uid,aa(G,!0),me()},V=(G,J,ue)=>{J.component=G;const _e=G.vnode.props;G.vnode=J,G.next=null,yF(G,J.props,_e,ue),wF(G,J.children,ue),Gl(),s4(G),Yl()},H=(G,J,ue,_e,ye,Ae,Le,Ee,Pe=!1)=>{const me=G&&G.children,je=G?G.shapeFlag:0,Ze=J.children,{patchFlag:ce,shapeFlag:te}=J;if(ce>0){if(ce&128){I(me,Ze,ue,_e,ye,Ae,Le,Ee,Pe);return}else if(ce&256){L(me,Ze,ue,_e,ye,Ae,Le,Ee,Pe);return}}te&8?(je&16&&xe(me,ye,Ae),Ze!==me&&c(ue,Ze)):je&16?te&16?I(me,Ze,ue,_e,ye,Ae,Le,Ee,Pe):xe(me,ye,Ae,!0):(je&8&&c(ue,""),te&16&&O(Ze,ue,_e,ye,Ae,Le,Ee,Pe))},L=(G,J,ue,_e,ye,Ae,Le,Ee,Pe)=>{G=G||mc,J=J||mc;const me=G.length,je=J.length,Ze=Math.min(me,je);let ce;for(ce=0;ce<Ze;ce++){const te=J[ce]=Pe?ml(J[ce]):ur(J[ce]);m(G[ce],te,ue,null,ye,Ae,Le,Ee,Pe)}me>je?xe(G,ye,Ae,!0,!1,Ze):O(J,ue,_e,ye,Ae,Le,Ee,Pe,Ze)},I=(G,J,ue,_e,ye,Ae,Le,Ee,Pe)=>{let me=0;const je=J.length;let Ze=G.length-1,ce=je-1;for(;me<=Ze&&me<=ce;){const te=G[me],pe=J[me]=Pe?ml(J[me]):ur(J[me]);if(ss(te,pe))m(te,pe,ue,null,ye,Ae,Le,Ee,Pe);else break;me++}for(;me<=Ze&&me<=ce;){const te=G[Ze],pe=J[ce]=Pe?ml(J[ce]):ur(J[ce]);if(ss(te,pe))m(te,pe,ue,null,ye,Ae,Le,Ee,Pe);else break;Ze--,ce--}if(me>Ze){if(me<=ce){const te=ce+1,pe=te<je?J[te].el:_e;for(;me<=ce;)m(null,J[me]=Pe?ml(J[me]):ur(J[me]),ue,pe,ye,Ae,Le,Ee,Pe),me++}}else if(me>ce)for(;me<=Ze;)oe(G[me],ye,Ae,!0),me++;else{const te=me,pe=me,Ve=new Map;for(me=pe;me<=ce;me++){const st=J[me]=Pe?ml(J[me]):ur(J[me]);st.key!=null&&Ve.set(st.key,me)}let Je,$e=0;const ie=ce-pe+1;let we=!1,ae=0;const Se=new Array(ie);for(me=0;me<ie;me++)Se[me]=0;for(me=te;me<=Ze;me++){const st=G[me];if($e>=ie){oe(st,ye,Ae,!0);continue}let se;if(st.key!=null)se=Ve.get(st.key);else for(Je=pe;Je<=ce;Je++)if(Se[Je-pe]===0&&ss(st,J[Je])){se=Je;break}se===void 0?oe(st,ye,Ae,!0):(Se[se-pe]=me+1,se>=ae?ae=se:we=!0,m(st,J[se],ue,null,ye,Ae,Le,Ee,Pe),$e++)}const Fe=we?$F(Se):mc;for(Je=Fe.length-1,me=ie-1;me>=0;me--){const st=pe+me,se=J[st],De=st+1<je?J[st+1].el:_e;Se[me]===0?m(null,se,ue,De,ye,Ae,Le,Ee,Pe):we&&(Je<0||me!==Fe[Je]?X(se,ue,De,2):Je--)}}},X=(G,J,ue,_e,ye=null)=>{const{el:Ae,type:Le,transition:Ee,children:Pe,shapeFlag:me}=G;if(me&6){X(G.component.subTree,J,ue,_e);return}if(me&128){G.suspense.move(J,ue,_e);return}if(me&64){Le.move(G,J,ue,le);return}if(Le===fe){o(Ae,J,ue);for(let Ze=0;Ze<Pe.length;Ze++)X(Pe[Ze],J,ue,_e);o(G.anchor,J,ue);return}if(Le===ja){_(G,J,ue);return}if(_e!==2&&me&1&&Ee)if(_e===0)Ee.beforeEnter(Ae),o(Ae,J,ue),Qn(()=>Ee.enter(Ae),ye);else{const{leave:Ze,delayLeave:ce,afterLeave:te}=Ee,pe=()=>o(Ae,J,ue),Ve=()=>{Ze(Ae,()=>{pe(),te&&te()})};ce?ce(Ae,pe,Ve):Ve()}else o(Ae,J,ue)},oe=(G,J,ue,_e=!1,ye=!1)=>{const{type:Ae,props:Le,ref:Ee,children:Pe,dynamicChildren:me,shapeFlag:je,patchFlag:Ze,dirs:ce}=G;if(Ee!=null&&dg(Ee,null,ue,G,!0),je&256){J.ctx.deactivate(G);return}const te=je&1&&ce,pe=!za(G);let Ve;if(pe&&(Ve=Le&&Le.onVnodeBeforeUnmount)&&Vo(Ve,J,G),je&6)Oe(G.component,ue,_e);else{if(je&128){G.suspense.unmount(ue,_e);return}te&&Ds(G,null,J,"beforeUnmount"),je&64?G.type.remove(G,J,ue,ye,le,_e):me&&(Ae!==fe||Ze>0&&Ze&64)?xe(me,J,ue,!1,!0):(Ae===fe&&Ze&384||!ye&&je&16)&&xe(Pe,J,ue),_e&&z(G)}(pe&&(Ve=Le&&Le.onVnodeUnmounted)||te)&&Qn(()=>{Ve&&Vo(Ve,J,G),te&&Ds(G,null,J,"unmounted")},ue)},z=G=>{const{type:J,el:ue,anchor:_e,transition:ye}=G;if(J===fe){ge(ue,_e);return}if(J===ja){S(G);return}const Ae=()=>{r(ue),ye&&!ye.persisted&&ye.afterLeave&&ye.afterLeave()};if(G.shapeFlag&1&&ye&&!ye.persisted){const{leave:Le,delayLeave:Ee}=ye,Pe=()=>Le(ue,Ae);Ee?Ee(G.el,Ae,Pe):Pe()}else Ae()},ge=(G,J)=>{let ue;for(;G!==J;)ue=f(G),r(G),G=ue;r(J)},Oe=(G,J,ue)=>{const{bum:_e,scope:ye,update:Ae,subTree:Le,um:Ee}=G;_e&&yc(_e),ye.stop(),Ae&&(Ae.active=!1,oe(Le,G,J,ue)),Ee&&Qn(Ee,J),Qn(()=>{G.isUnmounted=!0},J),J&&J.pendingBranch&&!J.isUnmounted&&G.asyncDep&&!G.asyncResolved&&G.suspenseId===J.pendingId&&(J.deps--,J.deps===0&&J.resolve())},xe=(G,J,ue,_e=!1,ye=!1,Ae=0)=>{for(let Le=Ae;Le<G.length;Le++)oe(G[Le],J,ue,_e,ye)},ee=G=>G.shapeFlag&6?ee(G.component.subTree):G.shapeFlag&128?G.suspense.next():f(G.anchor||G.el);let de=!1;const ve=(G,J,ue)=>{G==null?J._vnode&&oe(J._vnode,null,null,!0):m(J._vnode||null,G,J,null,null,null,ue),de||(de=!0,s4(),ug(),de=!1),J._vnode=G},le={p:m,um:oe,m:X,r:z,mt:Z,mc:O,pc:H,pbc:N,n:ee,o:e};let Ie,Ge;return t&&([Ie,Ge]=t(le)),{render:ve,hydrate:Ie,createApp:mF(ve,Ie)}}function Fv({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function aa({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function IE(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function yw(e,t,n=!1){const o=e.children,r=t.children;if(Me(o)&&Me(r))for(let s=0;s<o.length;s++){const i=o[s];let l=r[s];l.shapeFlag&1&&!l.dynamicChildren&&((l.patchFlag<=0||l.patchFlag===32)&&(l=r[s]=ml(r[s]),l.el=i.el),n||yw(i,l)),l.type===Ai&&(l.el=i.el)}}function $F(e){const t=e.slice(),n=[0];let o,r,s,i,l;const a=e.length;for(o=0;o<a;o++){const u=e[o];if(u!==0){if(r=n[n.length-1],e[r]<u){t[o]=r,n.push(o);continue}for(s=0,i=n.length-1;s<i;)l=s+i>>1,e[n[l]]<u?s=l+1:i=l;u<e[n[s]]&&(s>0&&(t[o]=n[s-1]),n[s]=o)}}for(s=n.length,i=n[s-1];s-- >0;)n[s]=i,i=t[i];return n}function AE(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:AE(t)}const EF=e=>e.__isTeleport,Lf=e=>e&&(e.disabled||e.disabled===""),v4=e=>typeof SVGElement<"u"&&e instanceof SVGElement,y4=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,__=(e,t)=>{const n=e&&e.to;return tt(n)?t?t(n):null:n},xF={name:"Teleport",__isTeleport:!0,process(e,t,n,o,r,s,i,l,a,u){const{mc:c,pc:d,pbc:f,o:{insert:p,querySelector:h,createText:m,createComment:y}}=u,v=Lf(t.props);let{shapeFlag:w,children:_,dynamicChildren:S}=t;if(e==null){const x=t.el=m(""),E=t.anchor=m("");p(x,n,o),p(E,n,o);const T=t.target=__(t.props,h),O=t.targetAnchor=m("");T&&(p(O,T),i==="svg"||v4(T)?i="svg":(i==="mathml"||y4(T))&&(i="mathml"));const P=(N,F)=>{w&16&&c(_,N,F,r,s,i,l,a)};v?P(n,E):T&&P(T,O)}else{t.el=e.el;const x=t.anchor=e.anchor,E=t.target=e.target,T=t.targetAnchor=e.targetAnchor,O=Lf(e.props),P=O?n:E,N=O?x:T;if(i==="svg"||v4(E)?i="svg":(i==="mathml"||y4(E))&&(i="mathml"),S?(f(e.dynamicChildren,S,P,r,s,i,l),yw(e,t,!0)):a||d(e,t,P,N,r,s,i,l,!1),v)O?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):tm(t,n,x,u,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const F=t.target=__(t.props,h);F&&tm(t,F,null,u,0)}else O&&tm(t,E,T,u,1)}NE(t)},remove(e,t,n,o,{um:r,o:{remove:s}},i){const{shapeFlag:l,children:a,anchor:u,targetAnchor:c,target:d,props:f}=e;if(d&&s(c),i&&s(u),l&16){const p=i||!Lf(f);for(let h=0;h<a.length;h++){const m=a[h];r(m,t,n,p,!!m.dynamicChildren)}}},move:tm,hydrate:MF};function tm(e,t,n,{o:{insert:o},m:r},s=2){s===0&&o(e.targetAnchor,t,n);const{el:i,anchor:l,shapeFlag:a,children:u,props:c}=e,d=s===2;if(d&&o(i,t,n),(!d||Lf(c))&&a&16)for(let f=0;f<u.length;f++)r(u[f],t,n,2);d&&o(l,t,n)}function MF(e,t,n,o,r,s,{o:{nextSibling:i,parentNode:l,querySelector:a}},u){const c=t.target=__(t.props,a);if(c){const d=c._lpa||c.firstChild;if(t.shapeFlag&16)if(Lf(t.props))t.anchor=u(i(e),t,l(e),n,o,r,s),t.targetAnchor=d;else{t.anchor=i(e);let f=d;for(;f;)if(f=i(f),f&&f.nodeType===8&&f.data==="teleport anchor"){t.targetAnchor=f,c._lpa=t.targetAnchor&&i(t.targetAnchor);break}u(d,t,c,n,o,r,s)}NE(t)}return t.anchor&&i(t.anchor)}const _s=xF;function NE(e){const t=e.ctx;if(t&&t.ut){let n=e.children[0].el;for(;n&&n!==e.targetAnchor;)n.nodeType===1&&n.setAttribute("data-v-owner",t.uid),n=n.nextSibling;t.ut()}}const fe=Symbol.for("v-fgt"),Ai=Symbol.for("v-txt"),Kn=Symbol.for("v-cmt"),ja=Symbol.for("v-stc"),Rf=[];let jo=null;function C(e=!1){Rf.push(jo=e?null:[])}function PE(){Rf.pop(),jo=Rf[Rf.length-1]||null}let nu=1;function b_(e){nu+=e}function LE(e){return e.dynamicChildren=nu>0?jo||mc:null,PE(),nu>0&&jo&&jo.push(e),e}function M(e,t,n,o,r,s){return LE(b(e,t,n,o,r,s,!0))}function q(e,t,n,o,r){return LE(k(e,t,n,o,r,!0))}function yo(e){return e?e.__v_isVNode===!0:!1}function ss(e,t){return e.type===t.type&&e.key===t.key}function TF(e){}const RE=({key:e})=>e??null,Bm=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?tt(e)||on(e)||Xe(e)?{i:Pn,r:e,k:t,f:!!n}:e:null);function b(e,t=null,n=null,o=0,r=null,s=e===fe?0:1,i=!1,l=!1){const a={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&RE(t),ref:t&&Bm(t),scopeId:g0,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:s,patchFlag:o,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:Pn};return l?(bw(a,n),s&128&&e.normalize(a)):n&&(a.shapeFlag|=tt(n)?8:16),nu>0&&!i&&jo&&(a.patchFlag>0||s&6)&&a.patchFlag!==32&&jo.push(a),a}const k=OF;function OF(e,t=null,n=null,o=0,r=null,s=!1){if((!e||e===Q$)&&(e=Kn),yo(e)){const l=hs(e,t,!0);return n&&bw(l,n),nu>0&&!s&&jo&&(l.shapeFlag&6?jo[jo.indexOf(e)]=l:jo.push(l)),l.patchFlag|=-2,l}if(RF(e)&&(e=e.__vccOpts),t){t=_w(t);let{class:l,style:a}=t;l&&!tt(l)&&(t.class=D(l)),ft(a)&&(rw(a)&&!Me(a)&&(a=Bt({},a)),t.style=Qe(a))}const i=tt(e)?1:eE(e)?128:EF(e)?64:ft(e)?4:Xe(e)?2:0;return b(e,t,n,o,r,i,s,!0)}function _w(e){return e?rw(e)||CE(e)?Bt({},e):e:null}function hs(e,t,n=!1){const{props:o,ref:r,patchFlag:s,children:i}=e,l=t?un(o||{},t):o;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&RE(l),ref:t&&t.ref?n&&r?Me(r)?r.concat(Bm(t)):[r,Bm(t)]:Bm(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==fe?s===-1?16:s|16:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&hs(e.ssContent),ssFallback:e.ssFallback&&hs(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce}}function ne(e=" ",t=0){return k(Ai,null,e,t)}function DE(e,t){const n=k(ja,null,e);return n.staticCount=t,n}function W(e="",t=!1){return t?(C(),q(Kn,null,e)):k(Kn,null,e)}function ur(e){return e==null||typeof e=="boolean"?k(Kn):Me(e)?k(fe,null,e.slice()):typeof e=="object"?ml(e):k(Ai,null,String(e))}function ml(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:hs(e)}function bw(e,t){let n=0;const{shapeFlag:o}=e;if(t==null)t=null;else if(Me(t))n=16;else if(typeof t=="object")if(o&65){const r=t.default;r&&(r._c&&(r._d=!1),bw(e,r()),r._c&&(r._d=!0));return}else{n=32;const r=t._;!r&&!CE(t)?t._ctx=Pn:r===3&&Pn&&(Pn.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else Xe(t)?(t={default:t,_ctx:Pn},n=32):(t=String(t),o&64?(n=16,t=[ne(t)]):n=8);e.children=t,e.shapeFlag|=n}function un(...e){const t={};for(let n=0;n<e.length;n++){const o=e[n];for(const r in o)if(r==="class")t.class!==o.class&&(t.class=D([t.class,o.class]));else if(r==="style")t.style=Qe([t.style,o.style]);else if(vu(r)){const s=t[r],i=o[r];i&&s!==i&&!(Me(s)&&s.includes(i))&&(t[r]=s?[].concat(s,i):i)}else r!==""&&(t[r]=o[r])}return t}function Vo(e,t,n,o=null){hr(e,t,7,[n,o])}const IF=bE();let AF=0;function FE(e,t,n){const o=e.type,r=(t?t.appContext:e.appContext)||IF,s={uid:AF++,vnode:e,type:o,parent:t,appContext:r,root:null,next:null,subTree:null,effect:null,update:null,scope:new J2(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(r.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:SE(o,r),emitsOptions:Z$(o,r),emit:null,emitted:null,propsDefaults:Wt,inheritAttrs:o.inheritAttrs,ctx:Wt,data:Wt,props:Wt,attrs:Wt,slots:Wt,refs:Wt,setupState:Wt,setupContext:null,attrsProxy:null,slotsProxy:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return s.ctx={_:s},s.root=t?t.root:s,s.emit=ID.bind(null,s),e.ce&&e.ce(s),s}let Bn=null;const at=()=>Bn||Pn;let fg,w_;{const e=C$(),t=(n,o)=>{let r;return(r=e[n])||(r=e[n]=[]),r.push(o),s=>{r.length>1?r.forEach(i=>i(s)):r[0](s)}};fg=t("__VUE_INSTANCE_SETTERS__",n=>Bn=n),w_=t("__VUE_SSR_SETTERS__",n=>Jp=n)}const ou=e=>{const t=Bn;return fg(e),e.scope.on(),()=>{e.scope.off(),fg(t)}},C_=()=>{Bn&&Bn.scope.off(),fg(null)};function VE(e){return e.vnode.shapeFlag&4}let Jp=!1;function BE(e,t=!1){t&&w_(t);const{props:n,children:o}=e.vnode,r=VE(e);vF(e,n,r,t),bF(e,o);const s=r?NF(e,t):void 0;return t&&w_(!1),s}function NF(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,h_);const{setup:o}=n;if(o){const r=e.setupContext=o.length>1?HE(e):null,s=ou(e);Gl();const i=xi(o,e,0,[e.props,r]);if(Yl(),s(),G2(i)){if(i.then(C_,C_),t)return i.then(l=>{k_(e,l,t)}).catch(l=>{bu(l,e,0)});e.asyncDep=i}else k_(e,i,t)}else jE(e,t)}function k_(e,t,n){Xe(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:ft(t)&&(e.setupState=lw(t)),jE(e,n)}let pg,S_;function zE(e){pg=e,S_=t=>{t.render._rc&&(t.withProxy=new Proxy(t.ctx,JD))}}const PF=()=>!pg;function jE(e,t,n){const o=e.type;if(!e.render){if(!t&&pg&&!o.render){const r=o.template||gw(e).template;if(r){const{isCustomElement:s,compilerOptions:i}=e.appContext.config,{delimiters:l,compilerOptions:a}=o,u=Bt(Bt({isCustomElement:s,delimiters:l},i),a);o.render=pg(r,u)}}e.render=o.render||yt,S_&&S_(e)}{const r=ou(e);Gl();try{uF(e)}finally{Yl(),r()}}}const LF={get(e,t){return Yo(e,"get",""),e[t]}};function HE(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,LF),slots:e.slots,emit:e.emit,expose:t}}function _0(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(lw(Ii(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Pf)return Pf[n](e)},has(t,n){return n in t||n in Pf}}))}function $_(e,t=!0){return Xe(e)?e.displayName||e.name:e.name||t&&e.__name}function RF(e){return Xe(e)&&"__vccOpts"in e}const R=(e,t)=>j$(e,t,Jp);function DF(e,t,n=Wt){const o=at(),r=yn(t),s=zo(t),i=U$((a,u)=>{let c;return sE(()=>{const d=e[t];ps(c,d)&&(c=d,u())}),{get(){return a(),n.get?n.get(c):c},set(d){const f=o.vnode.props;!(f&&(t in f||r in f||s in f)&&(`onUpdate:${t}`in f||`onUpdate:${r}`in f||`onUpdate:${s}`in f))&&ps(d,c)&&(c=d,u()),o.emit(`update:${t}`,n.set?n.set(d):d)}}}),l=t==="modelValue"?"modelModifiers":`${t}Modifiers`;return i[Symbol.iterator]=()=>{let a=0;return{next(){return a<2?{value:a++?e[l]||{}:i,done:!1}:{done:!0}}}},i}function lt(e,t,n){const o=arguments.length;return o===2?ft(t)&&!Me(t)?yo(t)?k(e,null,[t]):k(e,t):k(e,null,t):(o>3?n=Array.prototype.slice.call(arguments,2):o===3&&yo(n)&&(n=[n]),k(e,t,n))}function FF(){}function VF(e,t,n,o){const r=n[o];if(r&&UE(r,e))return r;const s=t();return s.memo=e.slice(),n[o]=s}function UE(e,t){const n=e.memo;if(n.length!=t.length)return!1;for(let o=0;o<n.length;o++)if(ps(n[o],t[o]))return!1;return nu>0&&jo&&jo.push(e),!0}const WE="3.4.23",KE=yt,BF=ED,zF=Uu,jF=Y$,HF={createComponentInstance:FE,setupComponent:BE,renderComponentRoot:Vm,setCurrentRenderingInstance:gp,isVNode:yo,normalizeVNode:ur},UF=HF,WF=null,KF=null,qF=null;/**
14 * @vue/runtime-dom v3.4.23
15 * (c) 2018-present Yuxi (Evan) You and Vue contributors
16 * @license MIT
17 **/const GF="http://www.w3.org/2000/svg",YF="http://www.w3.org/1998/Math/MathML",gl=typeof document<"u"?document:null,_4=gl&&gl.createElement("template"),ZF={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,o)=>{const r=t==="svg"?gl.createElementNS(GF,e):t==="mathml"?gl.createElementNS(YF,e):gl.createElement(e,n?{is:n}:void 0);return e==="select"&&o&&o.multiple!=null&&r.setAttribute("multiple",o.multiple),r},createText:e=>gl.createTextNode(e),createComment:e=>gl.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>gl.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,o,r,s){const i=n?n.previousSibling:t.lastChild;if(r&&(r===s||r.nextSibling))for(;t.insertBefore(r.cloneNode(!0),n),!(r===s||!(r=r.nextSibling)););else{_4.innerHTML=o==="svg"?`<svg>${e}</svg>`:o==="mathml"?`<math>${e}</math>`:e;const l=_4.content;if(o==="svg"||o==="mathml"){const a=l.firstChild;for(;a.firstChild;)l.appendChild(a.firstChild);l.removeChild(a)}t.insertBefore(l,n)}return[i?i.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},qi="transition",Bd="animation",Vc=Symbol("_vtc"),_r=(e,{slots:t})=>lt(lE,GE(e),t);_r.displayName="Transition";const qE={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},JF=_r.props=Bt({},hw,qE),ua=(e,t=[])=>{Me(e)?e.forEach(n=>n(...t)):e&&e(...t)},b4=e=>e?Me(e)?e.some(t=>t.length>1):e.length>1:!1;function GE(e){const t={};for(const B in e)B in qE||(t[B]=e[B]);if(e.css===!1)return t;const{name:n="v",type:o,duration:r,enterFromClass:s=`${n}-enter-from`,enterActiveClass:i=`${n}-enter-active`,enterToClass:l=`${n}-enter-to`,appearFromClass:a=s,appearActiveClass:u=i,appearToClass:c=l,leaveFromClass:d=`${n}-leave-from`,leaveActiveClass:f=`${n}-leave-active`,leaveToClass:p=`${n}-leave-to`}=e,h=XF(r),m=h&&h[0],y=h&&h[1],{onBeforeEnter:v,onEnter:w,onEnterCancelled:_,onLeave:S,onLeaveCancelled:x,onBeforeAppear:E=v,onAppear:T=w,onAppearCancelled:O=_}=t,P=(B,Y,Z)=>{Qi(B,Y?c:l),Qi(B,Y?u:i),Z&&Z()},N=(B,Y)=>{B._isLeaving=!1,Qi(B,d),Qi(B,p),Qi(B,f),Y&&Y()},F=B=>(Y,Z)=>{const U=B?T:w,j=()=>P(Y,B,Z);ua(U,[Y,j]),w4(()=>{Qi(Y,B?a:s),fi(Y,B?c:l),b4(U)||C4(Y,o,m,j)})};return Bt(t,{onBeforeEnter(B){ua(v,[B]),fi(B,s),fi(B,i)},onBeforeAppear(B){ua(E,[B]),fi(B,a),fi(B,u)},onEnter:F(!1),onAppear:F(!0),onLeave(B,Y){B._isLeaving=!0;const Z=()=>N(B,Y);fi(B,d),ZE(),fi(B,f),w4(()=>{B._isLeaving&&(Qi(B,d),fi(B,p),b4(S)||C4(B,o,y,Z))}),ua(S,[B,Z])},onEnterCancelled(B){P(B,!1),ua(_,[B])},onAppearCancelled(B){P(B,!0),ua(O,[B])},onLeaveCancelled(B){N(B),ua(x,[B])}})}function XF(e){if(e==null)return null;if(ft(e))return[Vv(e.enter),Vv(e.leave)];{const t=Vv(e);return[t,t]}}function Vv(e){return ig(e)}function fi(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Vc]||(e[Vc]=new Set)).add(t)}function Qi(e,t){t.split(/\s+/).forEach(o=>o&&e.classList.remove(o));const n=e[Vc];n&&(n.delete(t),n.size||(e[Vc]=void 0))}function w4(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let QF=0;function C4(e,t,n,o){const r=e._endId=++QF,s=()=>{r===e._endId&&o()};if(n)return setTimeout(s,n);const{type:i,timeout:l,propCount:a}=YE(e,t);if(!i)return o();const u=i+"end";let c=0;const d=()=>{e.removeEventListener(u,f),s()},f=p=>{p.target===e&&++c>=a&&d()};setTimeout(()=>{c<a&&d()},l+1),e.addEventListener(u,f)}function YE(e,t){const n=window.getComputedStyle(e),o=h=>(n[h]||"").split(", "),r=o(`${qi}Delay`),s=o(`${qi}Duration`),i=k4(r,s),l=o(`${Bd}Delay`),a=o(`${Bd}Duration`),u=k4(l,a);let c=null,d=0,f=0;t===qi?i>0&&(c=qi,d=i,f=s.length):t===Bd?u>0&&(c=Bd,d=u,f=a.length):(d=Math.max(i,u),c=d>0?i>u?qi:Bd:null,f=c?c===qi?s.length:a.length:0);const p=c===qi&&/\b(transform|all)(,|$)/.test(o(`${qi}Property`).toString());return{type:c,timeout:d,propCount:f,hasTransform:p}}function k4(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,o)=>S4(n)+S4(e[o])))}function S4(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function ZE(){return document.body.offsetHeight}function eV(e,t,n){const o=e[Vc];o&&(t=(t?[t,...o]:[...o]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const hg=Symbol("_vod"),JE=Symbol("_vsh"),en={beforeMount(e,{value:t},{transition:n}){e[hg]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):zd(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:o}){!t!=!n&&(o?t?(o.beforeEnter(e),zd(e,!0),o.enter(e)):o.leave(e,()=>{zd(e,!1)}):zd(e,t))},beforeUnmount(e,{value:t}){zd(e,t)}};function zd(e,t){e.style.display=t?e[hg]:"none",e[JE]=!t}function tV(){en.getSSRProps=({value:e})=>{if(!e)return{style:{display:"none"}}}}const XE=Symbol("");function nV(e){const t=at();if(!t)return;const n=t.ut=(r=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach(s=>x_(s,r))},o=()=>{const r=e(t.proxy);E_(t.subTree,r),n(r)};Ct(()=>{rE(o);const r=new MutationObserver(o);r.observe(t.subTree.el.parentNode,{childList:!0}),ti(()=>r.disconnect())})}function E_(e,t){if(e.shapeFlag&128){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push(()=>{E_(n.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(e.shapeFlag&1&&e.el)x_(e.el,t);else if(e.type===fe)e.children.forEach(n=>E_(n,t));else if(e.type===ja){let{el:n,anchor:o}=e;for(;n&&(x_(n,t),n!==o);)n=n.nextSibling}}function x_(e,t){if(e.nodeType===1){const n=e.style;let o="";for(const r in t)n.setProperty(`--${r}`,t[r]),o+=`--${r}: ${t[r]};`;n[XE]=o}}const oV=/(^|;)\s*display\s*:/;function rV(e,t,n){const o=e.style,r=tt(n);let s=!1;if(n&&!r){if(t)if(tt(t))for(const i of t.split(";")){const l=i.slice(0,i.indexOf(":")).trim();n[l]==null&&zm(o,l,"")}else for(const i in t)n[i]==null&&zm(o,i,"");for(const i in n)i==="display"&&(s=!0),zm(o,i,n[i])}else if(r){if(t!==n){const i=o[XE];i&&(n+=";"+i),o.cssText=n,s=oV.test(n)}}else t&&e.removeAttribute("style");hg in e&&(e[hg]=s?o.display:"",e[JE]&&(o.display="none"))}const $4=/\s*!important$/;function zm(e,t,n){if(Me(n))n.forEach(o=>zm(e,t,o));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const o=sV(e,t);$4.test(n)?e.setProperty(zo(o),n.replace($4,""),"important"):e[o]=n}}const E4=["Webkit","Moz","ms"],Bv={};function sV(e,t){const n=Bv[t];if(n)return n;let o=yn(t);if(o!=="filter"&&o in e)return Bv[t]=o;o=ql(o);for(let r=0;r<E4.length;r++){const s=E4[r]+o;if(s in e)return Bv[t]=s}return t}const x4="http://www.w3.org/1999/xlink";function iV(e,t,n,o,r){if(o&&t.startsWith("xlink:"))n==null?e.removeAttributeNS(x4,t.slice(6,t.length)):e.setAttributeNS(x4,t,n);else{const s=UR(t);n==null||s&&!S$(n)?e.removeAttribute(t):e.setAttribute(t,s?"":n)}}function lV(e,t,n,o,r,s,i){if(t==="innerHTML"||t==="textContent"){o&&i(o,r,s),e[t]=n??"";return}const l=e.tagName;if(t==="value"&&l!=="PROGRESS"&&!l.includes("-")){const u=l==="OPTION"?e.getAttribute("value")||"":e.value,c=n??"";(u!==c||!("_value"in e))&&(e.value=c),n==null&&e.removeAttribute(t),e._value=n;return}let a=!1;if(n===""||n==null){const u=typeof e[t];u==="boolean"?n=S$(n):n==null&&u==="string"?(n="",a=!0):u==="number"&&(n=0,a=!0)}try{e[t]=n}catch{}a&&e.removeAttribute(t)}function bi(e,t,n,o){e.addEventListener(t,n,o)}function aV(e,t,n,o){e.removeEventListener(t,n,o)}const M4=Symbol("_vei");function uV(e,t,n,o,r=null){const s=e[M4]||(e[M4]={}),i=s[t];if(o&&i)i.value=o;else{const[l,a]=cV(t);if(o){const u=s[t]=pV(o,r);bi(e,l,u,a)}else i&&(aV(e,l,i,a),s[t]=void 0)}}const T4=/(?:Once|Passive|Capture)$/;function cV(e){let t;if(T4.test(e)){t={};let o;for(;o=e.match(T4);)e=e.slice(0,e.length-o[0].length),t[o[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):zo(e.slice(2)),t]}let zv=0;const dV=Promise.resolve(),fV=()=>zv||(dV.then(()=>zv=0),zv=Date.now());function pV(e,t){const n=o=>{if(!o._vts)o._vts=Date.now();else if(o._vts<=n.attached)return;hr(hV(o,n.value),t,5,[o])};return n.value=e,n.attached=fV(),n}function hV(e,t){if(Me(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(o=>r=>!r._stopped&&o&&o(r))}else return t}const O4=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,mV=(e,t,n,o,r,s,i,l,a)=>{const u=r==="svg";t==="class"?eV(e,o,u):t==="style"?rV(e,n,o):vu(t)?K2(t)||uV(e,t,n,o,i):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):gV(e,t,o,u))?lV(e,t,o,s,i,l,a):(t==="true-value"?e._trueValue=o:t==="false-value"&&(e._falseValue=o),iV(e,t,o,u))};function gV(e,t,n,o){if(o)return!!(t==="innerHTML"||t==="textContent"||t in e&&O4(t)&&Xe(n));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const r=e.tagName;if(r==="IMG"||r==="VIDEO"||r==="CANVAS"||r==="SOURCE")return!1}return O4(t)&&tt(n)?!1:t in e}/*! #__NO_SIDE_EFFECTS__ */function QE(e,t){const n=Q(e);class o extends b0{constructor(s){super(n,s,t)}}return o.def=n,o}/*! #__NO_SIDE_EFFECTS__ */const vV=e=>QE(e,c7),yV=typeof HTMLElement<"u"?HTMLElement:class{};class b0 extends yV{constructor(t,n={},o){super(),this._def=t,this._props=n,this._instance=null,this._connected=!1,this._resolved=!1,this._numberProps=null,this._ob=null,this.shadowRoot&&o?o(this._createVNode(),this.shadowRoot):(this.attachShadow({mode:"open"}),this._def.__asyncLoader||this._resolveProps(this._def))}connectedCallback(){this._connected=!0,this._instance||(this._resolved?this._update():this._resolveDef())}disconnectedCallback(){this._connected=!1,this._ob&&(this._ob.disconnect(),this._ob=null),ot(()=>{this._connected||(Ni(null,this.shadowRoot),this._instance=null)})}_resolveDef(){this._resolved=!0;for(let o=0;o<this.attributes.length;o++)this._setAttr(this.attributes[o].name);this._ob=new MutationObserver(o=>{for(const r of o)this._setAttr(r.attributeName)}),this._ob.observe(this,{attributes:!0});const t=(o,r=!1)=>{const{props:s,styles:i}=o;let l;if(s&&!Me(s))for(const a in s){const u=s[a];(u===Number||u&&u.type===Number)&&(a in this._props&&(this._props[a]=ig(this._props[a])),(l||(l=Object.create(null)))[yn(a)]=!0)}this._numberProps=l,r&&this._resolveProps(o),this._applyStyles(i),this._update()},n=this._def.__asyncLoader;n?n().then(o=>t(o,!0)):t(this._def)}_resolveProps(t){const{props:n}=t,o=Me(n)?n:Object.keys(n||{});for(const r of Object.keys(this))r[0]!=="_"&&o.includes(r)&&this._setProp(r,this[r],!0,!1);for(const r of o.map(yn))Object.defineProperty(this,r,{get(){return this._getProp(r)},set(s){this._setProp(r,s)}})}_setAttr(t){let n=this.hasAttribute(t)?this.getAttribute(t):void 0;const o=yn(t);this._numberProps&&this._numberProps[o]&&(n=ig(n)),this._setProp(o,n,!1)}_getProp(t){return this._props[t]}_setProp(t,n,o=!0,r=!0){n!==this._props[t]&&(this._props[t]=n,r&&this._instance&&this._update(),o&&(n===!0?this.setAttribute(zo(t),""):typeof n=="string"||typeof n=="number"?this.setAttribute(zo(t),n+""):n||this.removeAttribute(zo(t))))}_update(){Ni(this._createVNode(),this.shadowRoot)}_createVNode(){const t=k(this._def,Bt({},this._props));return this._instance||(t.ce=n=>{this._instance=n,n.isCE=!0;const o=(s,i)=>{this.dispatchEvent(new CustomEvent(s,{detail:i}))};n.emit=(s,...i)=>{o(s,i),zo(s)!==s&&o(zo(s),i)};let r=this;for(;r=r&&(r.parentNode||r.host);)if(r instanceof b0){n.parent=r._instance,n.provides=r._instance.provides;break}}),t}_applyStyles(t){t&&t.forEach(n=>{const o=document.createElement("style");o.textContent=n,this.shadowRoot.appendChild(o)})}}function _V(e="$style"){{const t=at();if(!t)return Wt;const n=t.type.__cssModules;if(!n)return Wt;const o=n[e];return o||Wt}}const e7=new WeakMap,t7=new WeakMap,mg=Symbol("_moveCb"),I4=Symbol("_enterCb"),n7={name:"TransitionGroup",props:Bt({},JF,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=at(),o=pw();let r,s;return Fi(()=>{if(!r.length)return;const i=e.moveClass||`${e.name||"v"}-move`;if(!SV(r[0].el,n.vnode.el,i))return;r.forEach(wV),r.forEach(CV);const l=r.filter(kV);ZE(),l.forEach(a=>{const u=a.el,c=u.style;fi(u,i),c.transform=c.webkitTransform=c.transitionDuration="";const d=u[mg]=f=>{f&&f.target!==u||(!f||/transform$/.test(f.propertyName))&&(u.removeEventListener("transitionend",d),u[mg]=null,Qi(u,i))};u.addEventListener("transitionend",d)})}),()=>{const i=Mt(e),l=GE(i);let a=i.tag||fe;if(r=[],s)for(let u=0;u<s.length;u++){const c=s[u];c.el&&c.el instanceof Element&&(r.push(c),eu(c,Fc(c,l,o,n)),e7.set(c,c.el.getBoundingClientRect()))}s=t.default?v0(t.default()):[];for(let u=0;u<s.length;u++){const c=s[u];c.key!=null&&eu(c,Fc(c,l,o,n))}return k(a,null,s)}}},bV=e=>delete e.mode;n7.props;const w0=n7;function wV(e){const t=e.el;t[mg]&&t[mg](),t[I4]&&t[I4]()}function CV(e){t7.set(e,e.el.getBoundingClientRect())}function kV(e){const t=e7.get(e),n=t7.get(e),o=t.left-n.left,r=t.top-n.top;if(o||r){const s=e.el.style;return s.transform=s.webkitTransform=`translate(${o}px,${r}px)`,s.transitionDuration="0s",e}}function SV(e,t,n){const o=e.cloneNode(),r=e[Vc];r&&r.forEach(l=>{l.split(/\s+/).forEach(a=>a&&o.classList.remove(a))}),n.split(/\s+/).forEach(l=>l&&o.classList.add(l)),o.style.display="none";const s=t.nodeType===1?t:t.parentNode;s.appendChild(o);const{hasTransform:i}=YE(o);return s.removeChild(o),i}const Bl=e=>{const t=e.props["onUpdate:modelValue"]||!1;return Me(t)?n=>yc(t,n):t};function $V(e){e.target.composing=!0}function A4(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Pr=Symbol("_assign"),Bc={created(e,{modifiers:{lazy:t,trim:n,number:o}},r){e[Pr]=Bl(r);const s=o||r.props&&r.props.type==="number";bi(e,t?"change":"input",i=>{if(i.target.composing)return;let l=e.value;n&&(l=l.trim()),s&&(l=sg(l)),e[Pr](l)}),n&&bi(e,"change",()=>{e.value=e.value.trim()}),t||(bi(e,"compositionstart",$V),bi(e,"compositionend",A4),bi(e,"change",A4))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,modifiers:{lazy:n,trim:o,number:r}},s){if(e[Pr]=Bl(s),e.composing)return;const i=(r||e.type==="number")&&!/^0\d/.test(e.value)?sg(e.value):e.value,l=t??"";i!==l&&(document.activeElement===e&&e.type!=="range"&&(n||o&&e.value.trim()===l)||(e.value=l))}},ru={deep:!0,created(e,t,n){e[Pr]=Bl(n),bi(e,"change",()=>{const o=e._modelValue,r=zc(e),s=e.checked,i=e[Pr];if(Me(o)){const l=c0(o,r),a=l!==-1;if(s&&!a)i(o.concat(r));else if(!s&&a){const u=[...o];u.splice(l,1),i(u)}}else if(yu(o)){const l=new Set(o);s?l.add(r):l.delete(r),i(l)}else i(r7(e,s))})},mounted:N4,beforeUpdate(e,t,n){e[Pr]=Bl(n),N4(e,t,n)}};function N4(e,{value:t,oldValue:n},o){e._modelValue=t,Me(t)?e.checked=c0(t,o.props.value)>-1:yu(t)?e.checked=t.has(o.props.value):t!==n&&(e.checked=Vl(t,r7(e,!0)))}const Xp={created(e,{value:t},n){e.checked=Vl(t,n.props.value),e[Pr]=Bl(n),bi(e,"change",()=>{e[Pr](zc(e))})},beforeUpdate(e,{value:t,oldValue:n},o){e[Pr]=Bl(o),t!==n&&(e.checked=Vl(t,o.props.value))}},o7={deep:!0,created(e,{value:t,modifiers:{number:n}},o){const r=yu(t);bi(e,"change",()=>{const s=Array.prototype.filter.call(e.options,i=>i.selected).map(i=>n?sg(zc(i)):zc(i));e[Pr](e.multiple?r?new Set(s):s:s[0]),e._assigning=!0,ot(()=>{e._assigning=!1})}),e[Pr]=Bl(o)},mounted(e,{value:t,modifiers:{number:n}}){P4(e,t)},beforeUpdate(e,t,n){e[Pr]=Bl(n)},updated(e,{value:t,modifiers:{number:n}}){e._assigning||P4(e,t)}};function P4(e,t,n){const o=e.multiple,r=Me(t);if(!(o&&!r&&!yu(t))){for(let s=0,i=e.options.length;s<i;s++){const l=e.options[s],a=zc(l);if(o)if(r){const u=typeof a;u==="string"||u==="number"?l.selected=t.some(c=>String(c)===String(a)):l.selected=c0(t,a)>-1}else l.selected=t.has(a);else if(Vl(zc(l),t)){e.selectedIndex!==s&&(e.selectedIndex=s);return}}!o&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function zc(e){return"_value"in e?e._value:e.value}function r7(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const s7={created(e,t,n){nm(e,t,n,null,"created")},mounted(e,t,n){nm(e,t,n,null,"mounted")},beforeUpdate(e,t,n,o){nm(e,t,n,o,"beforeUpdate")},updated(e,t,n,o){nm(e,t,n,o,"updated")}};function i7(e,t){switch(e){case"SELECT":return o7;case"TEXTAREA":return Bc;default:switch(t){case"checkbox":return ru;case"radio":return Xp;default:return Bc}}}function nm(e,t,n,o,r){const i=i7(e.tagName,n.props&&n.props.type)[r];i&&i(e,t,n,o)}function EV(){Bc.getSSRProps=({value:e})=>({value:e}),Xp.getSSRProps=({value:e},t)=>{if(t.props&&Vl(t.props.value,e))return{checked:!0}},ru.getSSRProps=({value:e},t)=>{if(Me(e)){if(t.props&&c0(e,t.props.value)>-1)return{checked:!0}}else if(yu(e)){if(t.props&&e.has(t.props.value))return{checked:!0}}else if(e)return{checked:!0}},s7.getSSRProps=(e,t)=>{if(typeof t.type!="string")return;const n=i7(t.type.toUpperCase(),t.props&&t.props.type);if(n.getSSRProps)return n.getSSRProps(e,t)}}const xV=["ctrl","shift","alt","meta"],MV={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>xV.some(n=>e[`${n}Key`]&&!t.includes(n))},et=(e,t)=>{const n=e._withMods||(e._withMods={}),o=t.join(".");return n[o]||(n[o]=(r,...s)=>{for(let i=0;i<t.length;i++){const l=MV[t[i]];if(l&&l(r,t))return}return e(r,...s)})},TV={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Pt=(e,t)=>{const n=e._withKeys||(e._withKeys={}),o=t.join(".");return n[o]||(n[o]=r=>{if(!("key"in r))return;const s=zo(r.key);if(t.some(i=>i===s||TV[i]===s))return e(r)})},l7=Bt({patchProp:mV},ZF);let Df,L4=!1;function a7(){return Df||(Df=ME(l7))}function u7(){return Df=L4?Df:TE(l7),L4=!0,Df}const Ni=(...e)=>{a7().render(...e)},c7=(...e)=>{u7().hydrate(...e)},ww=(...e)=>{const t=a7().createApp(...e),{mount:n}=t;return t.mount=o=>{const r=f7(o);if(!r)return;const s=t._component;!Xe(s)&&!s.render&&!s.template&&(s.template=r.innerHTML),r.innerHTML="";const i=n(r,!1,d7(r));return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),i},t},OV=(...e)=>{const t=u7().createApp(...e),{mount:n}=t;return t.mount=o=>{const r=f7(o);if(r)return n(r,!0,d7(r))},t};function d7(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function f7(e){return tt(e)?document.querySelector(e):e}let R4=!1;const IV=()=>{R4||(R4=!0,EV(),tV())},AV=Object.freeze(Object.defineProperty({__proto__:null,BaseTransition:lE,BaseTransitionPropsValidators:hw,Comment:Kn,DeprecationTypes:qF,EffectScope:J2,ErrorCodes:$D,ErrorTypeStrings:BF,Fragment:fe,KeepAlive:YD,ReactiveEffect:Rc,Static:ja,Suspense:VD,Teleport:_s,Text:Ai,TrackOpTypes:CD,Transition:_r,TransitionGroup:w0,TriggerOpTypes:kD,VueElement:b0,assertNumber:SD,callWithAsyncErrorHandling:hr,callWithErrorHandling:xi,camelize:yn,capitalize:ql,cloneVNode:hs,compatUtils:KF,computed:R,createApp:ww,createBlock:q,createCommentVNode:W,createElementBlock:M,createElementVNode:b,createHydrationRenderer:TE,createPropsRestProxy:lF,createRenderer:ME,createSSRApp:OV,createSlots:tu,createStaticVNode:DE,createTextVNode:ne,createVNode:k,customRef:U$,defineAsyncComponent:qD,defineComponent:Q,defineCustomElement:QE,defineEmits:QD,defineExpose:eF,defineModel:oF,defineOptions:tF,defineProps:XD,defineSSRCustomElement:vV,defineSlots:nF,devtools:zF,effect:qR,effectScope:E$,getCurrentInstance:at,getCurrentScope:X2,getTransitionRawChildren:v0,guardReactiveProps:_w,h:lt,handleError:bu,hasInjectionContext:gF,hydrate:c7,initCustomFormatter:FF,initDirectivesForSSR:IV,inject:Be,isMemoSame:UE,isProxy:rw,isReactive:_c,isReadonly:Dc,isRef:on,isRuntimeOnly:PF,isShallow:fp,isVNode:yo,markRaw:Ii,mergeDefaults:sF,mergeModels:iF,mergeProps:un,nextTick:ot,normalizeClass:D,normalizeProps:Z2,normalizeStyle:Qe,onActivated:uE,onBeforeMount:yd,onBeforeUnmount:En,onBeforeUpdate:dE,onDeactivated:mw,onErrorCaptured:mE,onMounted:Ct,onRenderTracked:hE,onRenderTriggered:pE,onScopeDispose:Q2,onServerPrefetch:fE,onUnmounted:ti,onUpdated:Fi,openBlock:C,popScopeId:X$,provide:wt,proxyRefs:lw,pushScopeId:J$,queuePostFlushCb:ag,reactive:Dn,readonly:_u,ref:K,registerRuntimeCompiler:zE,render:Ni,renderList:nt,renderSlot:he,resolveComponent:re,resolveDirective:zt,resolveDynamicComponent:Lt,resolveFilter:WF,resolveTransitionHooks:Fc,setBlockTracking:b_,setDevtoolsHook:jF,setTransitionHooks:eu,shallowReactive:ow,shallowReadonly:hD,shallowRef:Tn,ssrContextKey:nE,ssrUtils:UF,stop:GR,toDisplayString:A,toHandlerKey:vc,toHandlers:vE,toRaw:Mt,toRef:pn,toRefs:ei,toValue:vD,transformVNodeArgs:TF,triggerRef:gD,unref:g,useAttrs:_d,useCssModule:_V,useCssVars:nV,useModel:DF,useSSRContext:oE,useSlots:Kr,useTransitionState:pw,vModelCheckbox:ru,vModelDynamic:s7,vModelRadio:Xp,vModelSelect:o7,vModelText:Bc,vShow:en,version:WE,warn:KE,watch:Te,watchEffect:ls,watchPostEffect:rE,watchSyncEffect:sE,withAsyncContext:aF,withCtx:$,withDefaults:rF,withDirectives:He,withKeys:Pt,withMemo:VF,withModifiers:et,withScopeId:AD},Symbol.toStringTag,{value:"Module"}));/**
18 * @vue/compiler-core v3.4.23
19 * (c) 2018-present Yuxi (Evan) You and Vue contributors
20 * @license MIT
21 **/const _p=Symbol(""),Ff=Symbol(""),Cw=Symbol(""),gg=Symbol(""),p7=Symbol(""),su=Symbol(""),h7=Symbol(""),m7=Symbol(""),kw=Symbol(""),Sw=Symbol(""),Qp=Symbol(""),$w=Symbol(""),g7=Symbol(""),Ew=Symbol(""),xw=Symbol(""),Mw=Symbol(""),Tw=Symbol(""),Ow=Symbol(""),Iw=Symbol(""),v7=Symbol(""),y7=Symbol(""),C0=Symbol(""),vg=Symbol(""),Aw=Symbol(""),Nw=Symbol(""),bp=Symbol(""),eh=Symbol(""),Pw=Symbol(""),M_=Symbol(""),NV=Symbol(""),T_=Symbol(""),yg=Symbol(""),PV=Symbol(""),LV=Symbol(""),Lw=Symbol(""),RV=Symbol(""),DV=Symbol(""),Rw=Symbol(""),_7=Symbol(""),jc={[_p]:"Fragment",[Ff]:"Teleport",[Cw]:"Suspense",[gg]:"KeepAlive",[p7]:"BaseTransition",[su]:"openBlock",[h7]:"createBlock",[m7]:"createElementBlock",[kw]:"createVNode",[Sw]:"createElementVNode",[Qp]:"createCommentVNode",[$w]:"createTextVNode",[g7]:"createStaticVNode",[Ew]:"resolveComponent",[xw]:"resolveDynamicComponent",[Mw]:"resolveDirective",[Tw]:"resolveFilter",[Ow]:"withDirectives",[Iw]:"renderList",[v7]:"renderSlot",[y7]:"createSlots",[C0]:"toDisplayString",[vg]:"mergeProps",[Aw]:"normalizeClass",[Nw]:"normalizeStyle",[bp]:"normalizeProps",[eh]:"guardReactiveProps",[Pw]:"toHandlers",[M_]:"camelize",[NV]:"capitalize",[T_]:"toHandlerKey",[yg]:"setBlockTracking",[PV]:"pushScopeId",[LV]:"popScopeId",[Lw]:"withCtx",[RV]:"unref",[DV]:"isRef",[Rw]:"withMemo",[_7]:"isMemoSame"};function FV(e){Object.getOwnPropertySymbols(e).forEach(t=>{jc[t]=e[t]})}const br={start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0},source:""};function VV(e,t=""){return{type:0,source:t,children:e,helpers:new Set,components:[],directives:[],hoists:[],imports:[],cached:0,temps:0,codegenNode:void 0,loc:br}}function wp(e,t,n,o,r,s,i,l=!1,a=!1,u=!1,c=br){return e&&(l?(e.helper(su),e.helper(Wc(e.inSSR,u))):e.helper(Uc(e.inSSR,u)),i&&e.helper(Ow)),{type:13,tag:t,props:n,children:o,patchFlag:r,dynamicProps:s,directives:i,isBlock:l,disableTracking:a,isComponent:u,loc:c}}function th(e,t=br){return{type:17,loc:t,elements:e}}function Ir(e,t=br){return{type:15,loc:t,properties:e}}function $n(e,t){return{type:16,loc:br,key:tt(e)?St(e,!0):e,value:t}}function St(e,t=!1,n=br,o=0){return{type:4,loc:n,content:e,isStatic:t,constType:t?3:o}}function as(e,t=br){return{type:8,loc:t,children:e}}function Vn(e,t=[],n=br){return{type:14,loc:n,callee:e,arguments:t}}function Hc(e,t=void 0,n=!1,o=!1,r=br){return{type:18,params:e,returns:t,newline:n,isSlot:o,loc:r}}function O_(e,t,n,o=!0){return{type:19,test:e,consequent:t,alternate:n,newline:o,loc:br}}function BV(e,t,n=!1){return{type:20,index:e,value:t,isVNode:n,loc:br}}function zV(e){return{type:21,body:e,loc:br}}function Uc(e,t){return e||t?kw:Sw}function Wc(e,t){return e||t?h7:m7}function Dw(e,{helper:t,removeHelper:n,inSSR:o}){e.isBlock||(e.isBlock=!0,n(Uc(o,e.isComponent)),t(su),t(Wc(o,e.isComponent)))}const D4=new Uint8Array([123,123]),F4=new Uint8Array([125,125]);function V4(e){return e>=97&&e<=122||e>=65&&e<=90}function lr(e){return e===32||e===10||e===9||e===12||e===13}function Gi(e){return e===47||e===62||lr(e)}function _g(e){const t=new Uint8Array(e.length);for(let n=0;n<e.length;n++)t[n]=e.charCodeAt(n);return t}const uo={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101]),TextareaEnd:new Uint8Array([60,47,116,101,120,116,97,114,101,97])};class jV{constructor(t,n){this.stack=t,this.cbs=n,this.state=1,this.buffer="",this.sectionStart=0,this.index=0,this.entityStart=0,this.baseState=1,this.inRCDATA=!1,this.inXML=!1,this.inVPre=!1,this.newlines=[],this.mode=0,this.delimiterOpen=D4,this.delimiterClose=F4,this.delimiterIndex=-1,this.currentSequence=void 0,this.sequenceIndex=0}get inSFCRoot(){return this.mode===2&&this.stack.length===0}reset(){this.state=1,this.mode=0,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=1,this.inRCDATA=!1,this.currentSequence=void 0,this.newlines.length=0,this.delimiterOpen=D4,this.delimiterClose=F4}getPos(t){let n=1,o=t+1;for(let r=this.newlines.length-1;r>=0;r--){const s=this.newlines[r];if(t>s){n=r+2,o=t-s;break}}return{column:o,line:n,offset:t}}peek(){return this.buffer.charCodeAt(this.index+1)}stateText(t){t===60?(this.index>this.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=5,this.sectionStart=this.index):!this.inVPre&&t===this.delimiterOpen[0]&&(this.state=2,this.delimiterIndex=0,this.stateInterpolationOpen(t))}stateInterpolationOpen(t){if(t===this.delimiterOpen[this.delimiterIndex])if(this.delimiterIndex===this.delimiterOpen.length-1){const n=this.index+1-this.delimiterOpen.length;n>this.sectionStart&&this.cbs.ontext(this.sectionStart,n),this.state=3,this.sectionStart=n}else this.delimiterIndex++;else this.inRCDATA?(this.state=32,this.stateInRCDATA(t)):(this.state=1,this.stateText(t))}stateInterpolation(t){t===this.delimiterClose[0]&&(this.state=4,this.delimiterIndex=0,this.stateInterpolationClose(t))}stateInterpolationClose(t){t===this.delimiterClose[this.delimiterIndex]?this.delimiterIndex===this.delimiterClose.length-1?(this.cbs.oninterpolation(this.sectionStart,this.index+1),this.inRCDATA?this.state=32:this.state=1,this.sectionStart=this.index+1):this.delimiterIndex++:(this.state=3,this.stateInterpolation(t))}stateSpecialStartSequence(t){const n=this.sequenceIndex===this.currentSequence.length;if(!(n?Gi(t):(t|32)===this.currentSequence[this.sequenceIndex]))this.inRCDATA=!1;else if(!n){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=6,this.stateInTagName(t)}stateInRCDATA(t){if(this.sequenceIndex===this.currentSequence.length){if(t===62||lr(t)){const n=this.index-this.currentSequence.length;if(this.sectionStart<n){const o=this.index;this.index=n,this.cbs.ontext(this.sectionStart,n),this.index=o}this.sectionStart=n+2,this.stateInClosingTagName(t),this.inRCDATA=!1;return}this.sequenceIndex=0}(t|32)===this.currentSequence[this.sequenceIndex]?this.sequenceIndex+=1:this.sequenceIndex===0?this.currentSequence===uo.TitleEnd||this.currentSequence===uo.TextareaEnd&&!this.inSFCRoot?t===this.delimiterOpen[0]&&(this.state=2,this.delimiterIndex=0,this.stateInterpolationOpen(t)):this.fastForwardTo(60)&&(this.sequenceIndex=1):this.sequenceIndex=+(t===60)}stateCDATASequence(t){t===uo.Cdata[this.sequenceIndex]?++this.sequenceIndex===uo.Cdata.length&&(this.state=28,this.currentSequence=uo.CdataEnd,this.sequenceIndex=0,this.sectionStart=this.index+1):(this.sequenceIndex=0,this.state=23,this.stateInDeclaration(t))}fastForwardTo(t){for(;++this.index<this.buffer.length;){const n=this.buffer.charCodeAt(this.index);if(n===10&&this.newlines.push(this.index),n===t)return!0}return this.index=this.buffer.length-1,!1}stateInCommentLike(t){t===this.currentSequence[this.sequenceIndex]?++this.sequenceIndex===this.currentSequence.length&&(this.currentSequence===uo.CdataEnd?this.cbs.oncdata(this.sectionStart,this.index-2):this.cbs.oncomment(this.sectionStart,this.index-2),this.sequenceIndex=0,this.sectionStart=this.index+1,this.state=1):this.sequenceIndex===0?this.fastForwardTo(this.currentSequence[0])&&(this.sequenceIndex=1):t!==this.currentSequence[this.sequenceIndex-1]&&(this.sequenceIndex=0)}startSpecial(t,n){this.enterRCDATA(t,n),this.state=31}enterRCDATA(t,n){this.inRCDATA=!0,this.currentSequence=t,this.sequenceIndex=n}stateBeforeTagName(t){t===33?(this.state=22,this.sectionStart=this.index+1):t===63?(this.state=24,this.sectionStart=this.index+1):V4(t)?(this.sectionStart=this.index,this.mode===0?this.state=6:this.inSFCRoot?this.state=34:this.inXML?this.state=6:t===116?this.state=30:this.state=t===115?29:6):t===47?this.state=8:(this.state=1,this.stateText(t))}stateInTagName(t){Gi(t)&&this.handleTagName(t)}stateInSFCRootTagName(t){if(Gi(t)){const n=this.buffer.slice(this.sectionStart,this.index);n!=="template"&&this.enterRCDATA(_g("</"+n),0),this.handleTagName(t)}}handleTagName(t){this.cbs.onopentagname(this.sectionStart,this.index),this.sectionStart=-1,this.state=11,this.stateBeforeAttrName(t)}stateBeforeClosingTagName(t){lr(t)||(t===62?(this.state=1,this.sectionStart=this.index+1):(this.state=V4(t)?9:27,this.sectionStart=this.index))}stateInClosingTagName(t){(t===62||lr(t))&&(this.cbs.onclosetag(this.sectionStart,this.index),this.sectionStart=-1,this.state=10,this.stateAfterClosingTagName(t))}stateAfterClosingTagName(t){t===62&&(this.state=1,this.sectionStart=this.index+1)}stateBeforeAttrName(t){t===62?(this.cbs.onopentagend(this.index),this.inRCDATA?this.state=32:this.state=1,this.sectionStart=this.index+1):t===47?this.state=7:t===60&&this.peek()===47?(this.cbs.onopentagend(this.index),this.state=5,this.sectionStart=this.index):lr(t)||this.handleAttrStart(t)}handleAttrStart(t){t===118&&this.peek()===45?(this.state=13,this.sectionStart=this.index):t===46||t===58||t===64||t===35?(this.cbs.ondirname(this.index,this.index+1),this.state=14,this.sectionStart=this.index+1):(this.state=12,this.sectionStart=this.index)}stateInSelfClosingTag(t){t===62?(this.cbs.onselfclosingtag(this.index),this.state=1,this.sectionStart=this.index+1,this.inRCDATA=!1):lr(t)||(this.state=11,this.stateBeforeAttrName(t))}stateInAttrName(t){(t===61||Gi(t))&&(this.cbs.onattribname(this.sectionStart,this.index),this.handleAttrNameEnd(t))}stateInDirName(t){t===61||Gi(t)?(this.cbs.ondirname(this.sectionStart,this.index),this.handleAttrNameEnd(t)):t===58?(this.cbs.ondirname(this.sectionStart,this.index),this.state=14,this.sectionStart=this.index+1):t===46&&(this.cbs.ondirname(this.sectionStart,this.index),this.state=16,this.sectionStart=this.index+1)}stateInDirArg(t){t===61||Gi(t)?(this.cbs.ondirarg(this.sectionStart,this.index),this.handleAttrNameEnd(t)):t===91?this.state=15:t===46&&(this.cbs.ondirarg(this.sectionStart,this.index),this.state=16,this.sectionStart=this.index+1)}stateInDynamicDirArg(t){t===93?this.state=14:(t===61||Gi(t))&&(this.cbs.ondirarg(this.sectionStart,this.index+1),this.handleAttrNameEnd(t))}stateInDirModifier(t){t===61||Gi(t)?(this.cbs.ondirmodifier(this.sectionStart,this.index),this.handleAttrNameEnd(t)):t===46&&(this.cbs.ondirmodifier(this.sectionStart,this.index),this.sectionStart=this.index+1)}handleAttrNameEnd(t){this.sectionStart=this.index,this.state=17,this.cbs.onattribnameend(this.index),this.stateAfterAttrName(t)}stateAfterAttrName(t){t===61?this.state=18:t===47||t===62?(this.cbs.onattribend(0,this.sectionStart),this.sectionStart=-1,this.state=11,this.stateBeforeAttrName(t)):lr(t)||(this.cbs.onattribend(0,this.sectionStart),this.handleAttrStart(t))}stateBeforeAttrValue(t){t===34?(this.state=19,this.sectionStart=this.index+1):t===39?(this.state=20,this.sectionStart=this.index+1):lr(t)||(this.sectionStart=this.index,this.state=21,this.stateInAttrValueNoQuotes(t))}handleInAttrValue(t,n){(t===n||this.fastForwardTo(n))&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=-1,this.cbs.onattribend(n===34?3:2,this.index+1),this.state=11)}stateInAttrValueDoubleQuotes(t){this.handleInAttrValue(t,34)}stateInAttrValueSingleQuotes(t){this.handleInAttrValue(t,39)}stateInAttrValueNoQuotes(t){lr(t)||t===62?(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=-1,this.cbs.onattribend(1,this.index),this.state=11,this.stateBeforeAttrName(t)):(t===39||t===60||t===61||t===96)&&this.cbs.onerr(18,this.index)}stateBeforeDeclaration(t){t===91?(this.state=26,this.sequenceIndex=0):this.state=t===45?25:23}stateInDeclaration(t){(t===62||this.fastForwardTo(62))&&(this.state=1,this.sectionStart=this.index+1)}stateInProcessingInstruction(t){(t===62||this.fastForwardTo(62))&&(this.cbs.onprocessinginstruction(this.sectionStart,this.index),this.state=1,this.sectionStart=this.index+1)}stateBeforeComment(t){t===45?(this.state=28,this.currentSequence=uo.CommentEnd,this.sequenceIndex=2,this.sectionStart=this.index+1):this.state=23}stateInSpecialComment(t){(t===62||this.fastForwardTo(62))&&(this.cbs.oncomment(this.sectionStart,this.index),this.state=1,this.sectionStart=this.index+1)}stateBeforeSpecialS(t){t===uo.ScriptEnd[3]?this.startSpecial(uo.ScriptEnd,4):t===uo.StyleEnd[3]?this.startSpecial(uo.StyleEnd,4):(this.state=6,this.stateInTagName(t))}stateBeforeSpecialT(t){t===uo.TitleEnd[3]?this.startSpecial(uo.TitleEnd,4):t===uo.TextareaEnd[3]?this.startSpecial(uo.TextareaEnd,4):(this.state=6,this.stateInTagName(t))}startEntity(){}stateInEntity(){}parse(t){for(this.buffer=t;this.index<this.buffer.length;){const n=this.buffer.charCodeAt(this.index);switch(n===10&&this.newlines.push(this.index),this.state){case 1:{this.stateText(n);break}case 2:{this.stateInterpolationOpen(n);break}case 3:{this.stateInterpolation(n);break}case 4:{this.stateInterpolationClose(n);break}case 31:{this.stateSpecialStartSequence(n);break}case 32:{this.stateInRCDATA(n);break}case 26:{this.stateCDATASequence(n);break}case 19:{this.stateInAttrValueDoubleQuotes(n);break}case 12:{this.stateInAttrName(n);break}case 13:{this.stateInDirName(n);break}case 14:{this.stateInDirArg(n);break}case 15:{this.stateInDynamicDirArg(n);break}case 16:{this.stateInDirModifier(n);break}case 28:{this.stateInCommentLike(n);break}case 27:{this.stateInSpecialComment(n);break}case 11:{this.stateBeforeAttrName(n);break}case 6:{this.stateInTagName(n);break}case 34:{this.stateInSFCRootTagName(n);break}case 9:{this.stateInClosingTagName(n);break}case 5:{this.stateBeforeTagName(n);break}case 17:{this.stateAfterAttrName(n);break}case 20:{this.stateInAttrValueSingleQuotes(n);break}case 18:{this.stateBeforeAttrValue(n);break}case 8:{this.stateBeforeClosingTagName(n);break}case 10:{this.stateAfterClosingTagName(n);break}case 29:{this.stateBeforeSpecialS(n);break}case 30:{this.stateBeforeSpecialT(n);break}case 21:{this.stateInAttrValueNoQuotes(n);break}case 7:{this.stateInSelfClosingTag(n);break}case 23:{this.stateInDeclaration(n);break}case 22:{this.stateBeforeDeclaration(n);break}case 25:{this.stateBeforeComment(n);break}case 24:{this.stateInProcessingInstruction(n);break}case 33:{this.stateInEntity();break}}this.index++}this.cleanup(),this.finish()}cleanup(){this.sectionStart!==this.index&&(this.state===1||this.state===32&&this.sequenceIndex===0?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):(this.state===19||this.state===20||this.state===21)&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))}finish(){this.handleTrailingData(),this.cbs.onend()}handleTrailingData(){const t=this.buffer.length;this.sectionStart>=t||(this.state===28?this.currentSequence===uo.CdataEnd?this.cbs.oncdata(this.sectionStart,t):this.cbs.oncomment(this.sectionStart,t):this.state===6||this.state===11||this.state===18||this.state===17||this.state===12||this.state===13||this.state===14||this.state===15||this.state===16||this.state===20||this.state===19||this.state===21||this.state===9||this.cbs.ontext(this.sectionStart,t))}emitCodePoint(t,n){}}function B4(e,{compatConfig:t}){const n=t&&t[e];return e==="MODE"?n||3:n}function Ha(e,t){const n=B4("MODE",t),o=B4(e,t);return n===3?o===!0:o!==!1}function Cp(e,t,n,...o){return Ha(e,t)}function Fw(e){throw e}function b7(e){}function vn(e,t,n,o){const r=`https://vuejs.org/error-reference/#compiler-${e}`,s=new SyntaxError(String(r));return s.code=e,s.loc=t,s}const Ho=e=>e.type===4&&e.isStatic;function w7(e){switch(e){case"Teleport":case"teleport":return Ff;case"Suspense":case"suspense":return Cw;case"KeepAlive":case"keep-alive":return gg;case"BaseTransition":case"base-transition":return p7}}const HV=/^\d|[^\$\w]/,Vw=e=>!HV.test(e),UV=/[A-Za-z_$\xA0-\uFFFF]/,WV=/[\.\?\w$\xA0-\uFFFF]/,KV=/\s+[.[]\s*|\s*[.[]\s+/g,qV=e=>{e=e.trim().replace(KV,i=>i.trim());let t=0,n=[],o=0,r=0,s=null;for(let i=0;i<e.length;i++){const l=e.charAt(i);switch(t){case 0:if(l==="[")n.push(t),t=1,o++;else if(l==="(")n.push(t),t=2,r++;else if(!(i===0?UV:WV).test(l))return!1;break;case 1:l==="'"||l==='"'||l==="`"?(n.push(t),t=3,s=l):l==="["?o++:l==="]"&&(--o||(t=n.pop()));break;case 2:if(l==="'"||l==='"'||l==="`")n.push(t),t=3,s=l;else if(l==="(")r++;else if(l===")"){if(i===e.length-1)return!1;--r||(t=n.pop())}break;case 3:l===s&&(t=n.pop(),s=null);break}}return!o&&!r},C7=qV;function ts(e,t,n=!1){for(let o=0;o<e.props.length;o++){const r=e.props[o];if(r.type===7&&(n||r.exp)&&(tt(t)?r.name===t:t.test(r.name)))return r}}function k0(e,t,n=!1,o=!1){for(let r=0;r<e.props.length;r++){const s=e.props[r];if(s.type===6){if(n)continue;if(s.name===t&&(s.value||o))return s}else if(s.name==="bind"&&(s.exp||o)&&Ta(s.arg,t))return s}}function Ta(e,t){return!!(e&&Ho(e)&&e.content===t)}function GV(e){return e.props.some(t=>t.type===7&&t.name==="bind"&&(!t.arg||t.arg.type!==4||!t.arg.isStatic))}function jv(e){return e.type===5||e.type===2}function YV(e){return e.type===7&&e.name==="slot"}function bg(e){return e.type===1&&e.tagType===3}function wg(e){return e.type===1&&e.tagType===2}const ZV=new Set([bp,eh]);function k7(e,t=[]){if(e&&!tt(e)&&e.type===14){const n=e.callee;if(!tt(n)&&ZV.has(n))return k7(e.arguments[0],t.concat(e))}return[e,t]}function Cg(e,t,n){let o,r=e.type===13?e.props:e.arguments[2],s=[],i;if(r&&!tt(r)&&r.type===14){const l=k7(r);r=l[0],s=l[1],i=s[s.length-1]}if(r==null||tt(r))o=Ir([t]);else if(r.type===14){const l=r.arguments[0];!tt(l)&&l.type===15?z4(t,l)||l.properties.unshift(t):r.callee===Pw?o=Vn(n.helper(vg),[Ir([t]),r]):r.arguments.unshift(Ir([t])),!o&&(o=r)}else r.type===15?(z4(t,r)||r.properties.unshift(t),o=r):(o=Vn(n.helper(vg),[Ir([t]),r]),i&&i.callee===eh&&(i=s[s.length-2]));e.type===13?i?i.arguments[0]=o:e.props=o:i?i.arguments[0]=o:e.arguments[2]=o}function z4(e,t){let n=!1;if(e.key.type===4){const o=e.key.content;n=t.properties.some(r=>r.key.type===4&&r.key.content===o)}return n}function kp(e,t){return`_${t}_${e.replace(/[^\w]/g,(n,o)=>n==="-"?"_":e.charCodeAt(o).toString())}`}function JV(e){return e.type===14&&e.callee===Rw?e.arguments[1].returns:e}const XV=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,S7={parseMode:"base",ns:0,delimiters:["{{","}}"],getNamespace:()=>0,isVoidTag:Dm,isPreTag:Dm,isCustomElement:Dm,onError:Fw,onWarn:b7,comments:!1,prefixIdentifiers:!1};let Gt=S7,Sp=null,Mi="",po=null,Ft=null,Do="",pi=-1,ga=-1,kg=0,vl=!1,I_=null;const Cn=[],Sn=new jV(Cn,{onerr:ai,ontext(e,t){om(Jn(e,t),e,t)},ontextentity(e,t,n){om(e,t,n)},oninterpolation(e,t){if(vl)return om(Jn(e,t),e,t);let n=e+Sn.delimiterOpen.length,o=t-Sn.delimiterClose.length;for(;lr(Mi.charCodeAt(n));)n++;for(;lr(Mi.charCodeAt(o-1));)o--;let r=Jn(n,o);r.includes("&")&&(r=Gt.decodeEntities(r,!1)),A_({type:5,content:Hm(r,!1,Fn(n,o)),loc:Fn(e,t)})},onopentagname(e,t){const n=Jn(e,t);po={type:1,tag:n,ns:Gt.getNamespace(n,Cn[0],Gt.ns),tagType:0,props:[],children:[],loc:Fn(e-1,t),codegenNode:void 0}},onopentagend(e){H4(e)},onclosetag(e,t){const n=Jn(e,t);if(!Gt.isVoidTag(n)){let o=!1;for(let r=0;r<Cn.length;r++)if(Cn[r].tag.toLowerCase()===n.toLowerCase()){o=!0,r>0&&ai(24,Cn[0].loc.start.offset);for(let i=0;i<=r;i++){const l=Cn.shift();jm(l,t,i<r)}break}o||ai(23,$7(e,60))}},onselfclosingtag(e){var t;const n=po.tag;po.isSelfClosing=!0,H4(e),((t=Cn[0])==null?void 0:t.tag)===n&&jm(Cn.shift(),e)},onattribname(e,t){Ft={type:6,name:Jn(e,t),nameLoc:Fn(e,t),value:void 0,loc:Fn(e)}},ondirname(e,t){const n=Jn(e,t),o=n==="."||n===":"?"bind":n==="@"?"on":n==="#"?"slot":n.slice(2);if(!vl&&o===""&&ai(26,e),vl||o==="")Ft={type:6,name:n,nameLoc:Fn(e,t),value:void 0,loc:Fn(e)};else if(Ft={type:7,name:o,rawName:n,exp:void 0,arg:void 0,modifiers:n==="."?["prop"]:[],loc:Fn(e)},o==="pre"){vl=Sn.inVPre=!0,I_=po;const r=po.props;for(let s=0;s<r.length;s++)r[s].type===7&&(r[s]=aB(r[s]))}},ondirarg(e,t){if(e===t)return;const n=Jn(e,t);if(vl)Ft.name+=n,Oa(Ft.nameLoc,t);else{const o=n[0]!=="[";Ft.arg=Hm(o?n:n.slice(1,-1),o,Fn(e,t),o?3:0)}},ondirmodifier(e,t){const n=Jn(e,t);if(vl)Ft.name+="."+n,Oa(Ft.nameLoc,t);else if(Ft.name==="slot"){const o=Ft.arg;o&&(o.content+="."+n,Oa(o.loc,t))}else Ft.modifiers.push(n)},onattribdata(e,t){Do+=Jn(e,t),pi<0&&(pi=e),ga=t},onattribentity(e,t,n){Do+=e,pi<0&&(pi=t),ga=n},onattribnameend(e){const t=Ft.loc.start.offset,n=Jn(t,e);Ft.type===7&&(Ft.rawName=n),po.props.some(o=>(o.type===7?o.rawName:o.name)===n)&&ai(2,t)},onattribend(e,t){if(po&&Ft){if(Oa(Ft.loc,t),e!==0)if(Do.includes("&")&&(Do=Gt.decodeEntities(Do,!0)),Ft.type===6)Ft.name==="class"&&(Do=x7(Do).trim()),e===1&&!Do&&ai(13,t),Ft.value={type:2,content:Do,loc:e===1?Fn(pi,ga):Fn(pi-1,ga+1)},Sn.inSFCRoot&&po.tag==="template"&&Ft.name==="lang"&&Do&&Do!=="html"&&Sn.enterRCDATA(_g("</template"),0);else{let n=0;Ft.exp=Hm(Do,!1,Fn(pi,ga),0,n),Ft.name==="for"&&(Ft.forParseResult=eB(Ft.exp));let o=-1;Ft.name==="bind"&&(o=Ft.modifiers.indexOf("sync"))>-1&&Cp("COMPILER_V_BIND_SYNC",Gt,Ft.loc,Ft.rawName)&&(Ft.name="model",Ft.modifiers.splice(o,1))}(Ft.type!==7||Ft.name!=="pre")&&po.props.push(Ft)}Do="",pi=ga=-1},oncomment(e,t){Gt.comments&&A_({type:3,content:Jn(e,t),loc:Fn(e-4,t+3)})},onend(){const e=Mi.length;for(let t=0;t<Cn.length;t++)jm(Cn[t],e-1),ai(24,Cn[t].loc.start.offset)},oncdata(e,t){Cn[0].ns!==0?om(Jn(e,t),e,t):ai(1,e-9)},onprocessinginstruction(e){(Cn[0]?Cn[0].ns:Gt.ns)===0&&ai(21,e-1)}}),j4=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,QV=/^\(|\)$/g;function eB(e){const t=e.loc,n=e.content,o=n.match(XV);if(!o)return;const[,r,s]=o,i=(d,f,p=!1)=>{const h=t.start.offset+f,m=h+d.length;return Hm(d,!1,Fn(h,m),0,p?1:0)},l={source:i(s.trim(),n.indexOf(s,r.length)),value:void 0,key:void 0,index:void 0,finalized:!1};let a=r.trim().replace(QV,"").trim();const u=r.indexOf(a),c=a.match(j4);if(c){a=a.replace(j4,"").trim();const d=c[1].trim();let f;if(d&&(f=n.indexOf(d,u+a.length),l.key=i(d,f,!0)),c[2]){const p=c[2].trim();p&&(l.index=i(p,n.indexOf(p,l.key?f+d.length:u+a.length),!0))}}return a&&(l.value=i(a,u,!0)),l}function Jn(e,t){return Mi.slice(e,t)}function H4(e){Sn.inSFCRoot&&(po.innerLoc=Fn(e+1,e+1)),A_(po);const{tag:t,ns:n}=po;n===0&&Gt.isPreTag(t)&&kg++,Gt.isVoidTag(t)?jm(po,e):(Cn.unshift(po),(n===1||n===2)&&(Sn.inXML=!0)),po=null}function om(e,t,n){var o;{const i=(o=Cn[0])==null?void 0:o.tag;i!=="script"&&i!=="style"&&e.includes("&")&&(e=Gt.decodeEntities(e,!1))}const r=Cn[0]||Sp,s=r.children[r.children.length-1];(s==null?void 0:s.type)===2?(s.content+=e,Oa(s.loc,n)):r.children.push({type:2,content:e,loc:Fn(t,n)})}function jm(e,t,n=!1){n?Oa(e.loc,$7(t,60)):Oa(e.loc,tB(t,62)+1),Sn.inSFCRoot&&(e.children.length?e.innerLoc.end=Bt({},e.children[e.children.length-1].loc.end):e.innerLoc.end=Bt({},e.innerLoc.start),e.innerLoc.source=Jn(e.innerLoc.start.offset,e.innerLoc.end.offset));const{tag:o,ns:r}=e;vl||(o==="slot"?e.tagType=2:U4(e)?e.tagType=3:oB(e)&&(e.tagType=1)),Sn.inRCDATA||(e.children=E7(e.children,e.tag)),r===0&&Gt.isPreTag(o)&&kg--,I_===e&&(vl=Sn.inVPre=!1,I_=null),Sn.inXML&&(Cn[0]?Cn[0].ns:Gt.ns)===0&&(Sn.inXML=!1);{const s=e.props;if(!Sn.inSFCRoot&&Ha("COMPILER_NATIVE_TEMPLATE",Gt)&&e.tag==="template"&&!U4(e)){const l=Cn[0]||Sp,a=l.children.indexOf(e);l.children.splice(a,1,...e.children)}const i=s.find(l=>l.type===6&&l.name==="inline-template");i&&Cp("COMPILER_INLINE_TEMPLATE",Gt,i.loc)&&e.children.length&&(i.value={type:2,content:Jn(e.children[0].loc.start.offset,e.children[e.children.length-1].loc.end.offset),loc:i.loc})}}function tB(e,t){let n=e;for(;Mi.charCodeAt(n)!==t&&n<Mi.length-1;)n++;return n}function $7(e,t){let n=e;for(;Mi.charCodeAt(n)!==t&&n>=0;)n--;return n}const nB=new Set(["if","else","else-if","for","slot"]);function U4({tag:e,props:t}){if(e==="template"){for(let n=0;n<t.length;n++)if(t[n].type===7&&nB.has(t[n].name))return!0}return!1}function oB({tag:e,props:t}){var n;if(Gt.isCustomElement(e))return!1;if(e==="component"||rB(e.charCodeAt(0))||w7(e)||(n=Gt.isBuiltInComponent)!=null&&n.call(Gt,e)||Gt.isNativeTag&&!Gt.isNativeTag(e))return!0;for(let o=0;o<t.length;o++){const r=t[o];if(r.type===6){if(r.name==="is"&&r.value){if(r.value.content.startsWith("vue:"))return!0;if(Cp("COMPILER_IS_ON_ELEMENT",Gt,r.loc))return!0}}else if(r.name==="bind"&&Ta(r.arg,"is")&&Cp("COMPILER_IS_ON_ELEMENT",Gt,r.loc))return!0}return!1}function rB(e){return e>64&&e<91}const sB=/\r\n/g;function E7(e,t){var n,o;const r=Gt.whitespace!=="preserve";let s=!1;for(let i=0;i<e.length;i++){const l=e[i];if(l.type===2)if(kg)l.content=l.content.replace(sB,`
22 `);else if(iB(l.content)){const a=(n=e[i-1])==null?void 0:n.type,u=(o=e[i+1])==null?void 0:o.type;!a||!u||r&&(a===3&&(u===3||u===1)||a===1&&(u===3||u===1&&lB(l.content)))?(s=!0,e[i]=null):l.content=" "}else r&&(l.content=x7(l.content))}if(kg&&t&&Gt.isPreTag(t)){const i=e[0];i&&i.type===2&&(i.content=i.content.replace(/^\r?\n/,""))}return s?e.filter(Boolean):e}function iB(e){for(let t=0;t<e.length;t++)if(!lr(e.charCodeAt(t)))return!1;return!0}function lB(e){for(let t=0;t<e.length;t++){const n=e.charCodeAt(t);if(n===10||n===13)return!0}return!1}function x7(e){let t="",n=!1;for(let o=0;o<e.length;o++)lr(e.charCodeAt(o))?n||(t+=" ",n=!0):(t+=e[o],n=!1);return t}function A_(e){(Cn[0]||Sp).children.push(e)}function Fn(e,t){return{start:Sn.getPos(e),end:t==null?t:Sn.getPos(t),source:t==null?t:Jn(e,t)}}function Oa(e,t){e.end=Sn.getPos(t),e.source=Jn(e.start.offset,t)}function aB(e){const t={type:6,name:e.rawName,nameLoc:Fn(e.loc.start.offset,e.loc.start.offset+e.rawName.length),value:void 0,loc:e.loc};if(e.exp){const n=e.exp.loc;n.end.offset<e.loc.end.offset&&(n.start.offset--,n.start.column--,n.end.offset++,n.end.column++),t.value={type:2,content:e.exp.content,loc:n}}return t}function Hm(e,t=!1,n,o=0,r=0){return St(e,t,n,o)}function ai(e,t,n){Gt.onError(vn(e,Fn(t,t)))}function uB(){Sn.reset(),po=null,Ft=null,Do="",pi=-1,ga=-1,Cn.length=0}function cB(e,t){if(uB(),Mi=e,Gt=Bt({},S7),t){let r;for(r in t)t[r]!=null&&(Gt[r]=t[r])}Sn.mode=Gt.parseMode==="html"?1:Gt.parseMode==="sfc"?2:0,Sn.inXML=Gt.ns===1||Gt.ns===2;const n=t==null?void 0:t.delimiters;n&&(Sn.delimiterOpen=_g(n[0]),Sn.delimiterClose=_g(n[1]));const o=Sp=VV([],e);return Sn.parse(Mi),o.loc=Fn(0,e.length),o.children=E7(o.children),Sp=null,o}function dB(e,t){Um(e,t,M7(e,e.children[0]))}function M7(e,t){const{children:n}=e;return n.length===1&&t.type===1&&!wg(t)}function Um(e,t,n=!1){const{children:o}=e,r=o.length;let s=0;for(let i=0;i<o.length;i++){const l=o[i];if(l.type===1&&l.tagType===0){const a=n?0:Ar(l,t);if(a>0){if(a>=2){l.codegenNode.patchFlag="-1",l.codegenNode=t.hoist(l.codegenNode),s++;continue}}else{const u=l.codegenNode;if(u.type===13){const c=A7(u);if((!c||c===512||c===1)&&O7(l,t)>=2){const d=I7(l);d&&(u.props=t.hoist(d))}u.dynamicProps&&(u.dynamicProps=t.hoist(u.dynamicProps))}}}if(l.type===1){const a=l.tagType===1;a&&t.scopes.vSlot++,Um(l,t),a&&t.scopes.vSlot--}else if(l.type===11)Um(l,t,l.children.length===1);else if(l.type===9)for(let a=0;a<l.branches.length;a++)Um(l.branches[a],t,l.branches[a].children.length===1)}if(s&&t.transformHoist&&t.transformHoist(o,t,e),s&&s===r&&e.type===1&&e.tagType===0&&e.codegenNode&&e.codegenNode.type===13&&Me(e.codegenNode.children)){const i=t.hoist(th(e.codegenNode.children));t.hmr&&(i.content=`[...${i.content}]`),e.codegenNode.children=i}}function Ar(e,t){const{constantCache:n}=t;switch(e.type){case 1:if(e.tagType!==0)return 0;const o=n.get(e);if(o!==void 0)return o;const r=e.codegenNode;if(r.type!==13||r.isBlock&&e.tag!=="svg"&&e.tag!=="foreignObject")return 0;if(A7(r))return n.set(e,0),0;{let l=3;const a=O7(e,t);if(a===0)return n.set(e,0),0;a<l&&(l=a);for(let u=0;u<e.children.length;u++){const c=Ar(e.children[u],t);if(c===0)return n.set(e,0),0;c<l&&(l=c)}if(l>1)for(let u=0;u<e.props.length;u++){const c=e.props[u];if(c.type===7&&c.name==="bind"&&c.exp){const d=Ar(c.exp,t);if(d===0)return n.set(e,0),0;d<l&&(l=d)}}if(r.isBlock){for(let u=0;u<e.props.length;u++)if(e.props[u].type===7)return n.set(e,0),0;t.removeHelper(su),t.removeHelper(Wc(t.inSSR,r.isComponent)),r.isBlock=!1,t.helper(Uc(t.inSSR,r.isComponent))}return n.set(e,l),l}case 2:case 3:return 3;case 9:case 11:case 10:return 0;case 5:case 12:return Ar(e.content,t);case 4:return e.constType;case 8:let i=3;for(let l=0;l<e.children.length;l++){const a=e.children[l];if(tt(a)||Fr(a))continue;const u=Ar(a,t);if(u===0)return 0;u<i&&(i=u)}return i;default:return 0}}const fB=new Set([Aw,Nw,bp,eh]);function T7(e,t){if(e.type===14&&!tt(e.callee)&&fB.has(e.callee)){const n=e.arguments[0];if(n.type===4)return Ar(n,t);if(n.type===14)return T7(n,t)}return 0}function O7(e,t){let n=3;const o=I7(e);if(o&&o.type===15){const{properties:r}=o;for(let s=0;s<r.length;s++){const{key:i,value:l}=r[s],a=Ar(i,t);if(a===0)return a;a<n&&(n=a);let u;if(l.type===4?u=Ar(l,t):l.type===14?u=T7(l,t):u=0,u===0)return u;u<n&&(n=u)}}return n}function I7(e){const t=e.codegenNode;if(t.type===13)return t.props}function A7(e){const t=e.patchFlag;return t?parseInt(t,10):void 0}function pB(e,{filename:t="",prefixIdentifiers:n=!1,hoistStatic:o=!1,hmr:r=!1,cacheHandlers:s=!1,nodeTransforms:i=[],directiveTransforms:l={},transformHoist:a=null,isBuiltInComponent:u=yt,isCustomElement:c=yt,expressionPlugins:d=[],scopeId:f=null,slotted:p=!0,ssr:h=!1,inSSR:m=!1,ssrCssVars:y="",bindingMetadata:v=Wt,inline:w=!1,isTS:_=!1,onError:S=Fw,onWarn:x=b7,compatConfig:E}){const T=t.replace(/\?.*$/,"").match(/([^/\\]+)\.\w+$/),O={filename:t,selfName:T&&ql(yn(T[1])),prefixIdentifiers:n,hoistStatic:o,hmr:r,cacheHandlers:s,nodeTransforms:i,directiveTransforms:l,transformHoist:a,isBuiltInComponent:u,isCustomElement:c,expressionPlugins:d,scopeId:f,slotted:p,ssr:h,inSSR:m,ssrCssVars:y,bindingMetadata:v,inline:w,isTS:_,onError:S,onWarn:x,compatConfig:E,root:e,helpers:new Map,components:new Set,directives:new Set,hoists:[],imports:[],constantCache:new WeakMap,temps:0,cached:0,identifiers:Object.create(null),scopes:{vFor:0,vSlot:0,vPre:0,vOnce:0},parent:null,currentNode:e,childIndex:0,inVOnce:!1,helper(P){const N=O.helpers.get(P)||0;return O.helpers.set(P,N+1),P},removeHelper(P){const N=O.helpers.get(P);if(N){const F=N-1;F?O.helpers.set(P,F):O.helpers.delete(P)}},helperString(P){return`_${jc[O.helper(P)]}`},replaceNode(P){O.parent.children[O.childIndex]=O.currentNode=P},removeNode(P){const N=O.parent.children,F=P?N.indexOf(P):O.currentNode?O.childIndex:-1;!P||P===O.currentNode?(O.currentNode=null,O.onNodeRemoved()):O.childIndex>F&&(O.childIndex--,O.onNodeRemoved()),O.parent.children.splice(F,1)},onNodeRemoved:yt,addIdentifiers(P){},removeIdentifiers(P){},hoist(P){tt(P)&&(P=St(P)),O.hoists.push(P);const N=St(`_hoisted_${O.hoists.length}`,!1,P.loc,2);return N.hoisted=P,N},cache(P,N=!1){return BV(O.cached++,P,N)}};return O.filters=new Set,O}function hB(e,t){const n=pB(e,t);S0(e,n),t.hoistStatic&&dB(e,n),t.ssr||mB(e,n),e.helpers=new Set([...n.helpers.keys()]),e.components=[...n.components],e.directives=[...n.directives],e.imports=n.imports,e.hoists=n.hoists,e.temps=n.temps,e.cached=n.cached,e.transformed=!0,e.filters=[...n.filters]}function mB(e,t){const{helper:n}=t,{children:o}=e;if(o.length===1){const r=o[0];if(M7(e,r)&&r.codegenNode){const s=r.codegenNode;s.type===13&&Dw(s,t),e.codegenNode=s}else e.codegenNode=r}else if(o.length>1){let r=64;e.codegenNode=wp(t,n(_p),void 0,e.children,r+"",void 0,void 0,!0,void 0,!1)}}function gB(e,t){let n=0;const o=()=>{n--};for(;n<e.children.length;n++){const r=e.children[n];tt(r)||(t.parent=e,t.childIndex=n,t.onNodeRemoved=o,S0(r,t))}}function S0(e,t){t.currentNode=e;const{nodeTransforms:n}=t,o=[];for(let s=0;s<n.length;s++){const i=n[s](e,t);if(i&&(Me(i)?o.push(...i):o.push(i)),t.currentNode)e=t.currentNode;else return}switch(e.type){case 3:t.ssr||t.helper(Qp);break;case 5:t.ssr||t.helper(C0);break;case 9:for(let s=0;s<e.branches.length;s++)S0(e.branches[s],t);break;case 10:case 11:case 1:case 0:gB(e,t);break}t.currentNode=e;let r=o.length;for(;r--;)o[r]()}function N7(e,t){const n=tt(e)?o=>o===e:o=>e.test(o);return(o,r)=>{if(o.type===1){const{props:s}=o;if(o.tagType===3&&s.some(YV))return;const i=[];for(let l=0;l<s.length;l++){const a=s[l];if(a.type===7&&n(a.name)){s.splice(l,1),l--;const u=t(o,a,r);u&&i.push(u)}}return i}}}const $0="/*#__PURE__*/",P7=e=>`${jc[e]}: _${jc[e]}`;function vB(e,{mode:t="function",prefixIdentifiers:n=t==="module",sourceMap:o=!1,filename:r="template.vue.html",scopeId:s=null,optimizeImports:i=!1,runtimeGlobalName:l="Vue",runtimeModuleName:a="vue",ssrRuntimeModuleName:u="vue/server-renderer",ssr:c=!1,isTS:d=!1,inSSR:f=!1}){const p={mode:t,prefixIdentifiers:n,sourceMap:o,filename:r,scopeId:s,optimizeImports:i,runtimeGlobalName:l,runtimeModuleName:a,ssrRuntimeModuleName:u,ssr:c,isTS:d,inSSR:f,source:e.source,code:"",column:1,line:1,offset:0,indentLevel:0,pure:!1,map:void 0,helper(m){return`_${jc[m]}`},push(m,y=-2,v){p.code+=m},indent(){h(++p.indentLevel)},deindent(m=!1){m?--p.indentLevel:h(--p.indentLevel)},newline(){h(p.indentLevel)}};function h(m){p.push(`
23 `+" ".repeat(m),0)}return p}function yB(e,t={}){const n=vB(e,t);t.onContextCreated&&t.onContextCreated(n);const{mode:o,push:r,prefixIdentifiers:s,indent:i,deindent:l,newline:a,scopeId:u,ssr:c}=n,d=Array.from(e.helpers),f=d.length>0,p=!s&&o!=="module";_B(e,n);const m=c?"ssrRender":"render",v=(c?["_ctx","_push","_parent","_attrs"]:["_ctx","_cache"]).join(", ");if(r(`function ${m}(${v}) {`),i(),p&&(r("with (_ctx) {"),i(),f&&(r(`const { ${d.map(P7).join(", ")} } = _Vue
24 `,-1),a())),e.components.length&&(Hv(e.components,"component",n),(e.directives.length||e.temps>0)&&a()),e.directives.length&&(Hv(e.directives,"directive",n),e.temps>0&&a()),e.filters&&e.filters.length&&(a(),Hv(e.filters,"filter",n),a()),e.temps>0){r("let ");for(let w=0;w<e.temps;w++)r(`${w>0?", ":""}_temp${w}`)}return(e.components.length||e.directives.length||e.temps)&&(r(`
25 `,0),a()),c||r("return "),e.codegenNode?go(e.codegenNode,n):r("null"),p&&(l(),r("}")),l(),r("}"),{ast:e,code:n.code,preamble:"",map:n.map?n.map.toJSON():void 0}}function _B(e,t){const{ssr:n,prefixIdentifiers:o,push:r,newline:s,runtimeModuleName:i,runtimeGlobalName:l,ssrRuntimeModuleName:a}=t,u=l,c=Array.from(e.helpers);if(c.length>0&&(r(`const _Vue = ${u}
26 `,-1),e.hoists.length)){const d=[kw,Sw,Qp,$w,g7].filter(f=>c.includes(f)).map(P7).join(", ");r(`const { ${d} } = _Vue
27 `,-1)}bB(e.hoists,t),s(),r("return ")}function Hv(e,t,{helper:n,push:o,newline:r,isTS:s}){const i=n(t==="filter"?Tw:t==="component"?Ew:Mw);for(let l=0;l<e.length;l++){let a=e[l];const u=a.endsWith("__self");u&&(a=a.slice(0,-6)),o(`const ${kp(a,t)} = ${i}(${JSON.stringify(a)}${u?", true":""})${s?"!":""}`),l<e.length-1&&r()}}function bB(e,t){if(!e.length)return;t.pure=!0;const{push:n,newline:o,helper:r,scopeId:s,mode:i}=t;o();for(let l=0;l<e.length;l++){const a=e[l];a&&(n(`const _hoisted_${l+1} = `),go(a,t),o())}t.pure=!1}function Bw(e,t){const n=e.length>3||!1;t.push("["),n&&t.indent(),nh(e,t,n),n&&t.deindent(),t.push("]")}function nh(e,t,n=!1,o=!0){const{push:r,newline:s}=t;for(let i=0;i<e.length;i++){const l=e[i];tt(l)?r(l,-3):Me(l)?Bw(l,t):go(l,t),i<e.length-1&&(n?(o&&r(","),s()):o&&r(", "))}}function go(e,t){if(tt(e)){t.push(e,-3);return}if(Fr(e)){t.push(t.helper(e));return}switch(e.type){case 1:case 9:case 11:go(e.codegenNode,t);break;case 2:wB(e,t);break;case 4:L7(e,t);break;case 5:CB(e,t);break;case 12:go(e.codegenNode,t);break;case 8:R7(e,t);break;case 3:SB(e,t);break;case 13:$B(e,t);break;case 14:xB(e,t);break;case 15:MB(e,t);break;case 17:TB(e,t);break;case 18:OB(e,t);break;case 19:IB(e,t);break;case 20:AB(e,t);break;case 21:nh(e.body,t,!0,!1);break}}function wB(e,t){t.push(JSON.stringify(e.content),-3,e)}function L7(e,t){const{content:n,isStatic:o}=e;t.push(o?JSON.stringify(n):n,-3,e)}function CB(e,t){const{push:n,helper:o,pure:r}=t;r&&n($0),n(`${o(C0)}(`),go(e.content,t),n(")")}function R7(e,t){for(let n=0;n<e.children.length;n++){const o=e.children[n];tt(o)?t.push(o,-3):go(o,t)}}function kB(e,t){const{push:n}=t;if(e.type===8)n("["),R7(e,t),n("]");else if(e.isStatic){const o=Vw(e.content)?e.content:JSON.stringify(e.content);n(o,-2,e)}else n(`[${e.content}]`,-3,e)}function SB(e,t){const{push:n,helper:o,pure:r}=t;r&&n($0),n(`${o(Qp)}(${JSON.stringify(e.content)})`,-3,e)}function $B(e,t){const{push:n,helper:o,pure:r}=t,{tag:s,props:i,children:l,patchFlag:a,dynamicProps:u,directives:c,isBlock:d,disableTracking:f,isComponent:p}=e;c&&n(o(Ow)+"("),d&&n(`(${o(su)}(${f?"true":""}), `),r&&n($0);const h=d?Wc(t.inSSR,p):Uc(t.inSSR,p);n(o(h)+"(",-2,e),nh(EB([s,i,l,a,u]),t),n(")"),d&&n(")"),c&&(n(", "),go(c,t),n(")"))}function EB(e){let t=e.length;for(;t--&&e[t]==null;);return e.slice(0,t+1).map(n=>n||"null")}function xB(e,t){const{push:n,helper:o,pure:r}=t,s=tt(e.callee)?e.callee:o(e.callee);r&&n($0),n(s+"(",-2,e),nh(e.arguments,t),n(")")}function MB(e,t){const{push:n,indent:o,deindent:r,newline:s}=t,{properties:i}=e;if(!i.length){n("{}",-2,e);return}const l=i.length>1||!1;n(l?"{":"{ "),l&&o();for(let a=0;a<i.length;a++){const{key:u,value:c}=i[a];kB(u,t),n(": "),go(c,t),a<i.length-1&&(n(","),s())}l&&r(),n(l?"}":" }")}function TB(e,t){Bw(e.elements,t)}function OB(e,t){const{push:n,indent:o,deindent:r}=t,{params:s,returns:i,body:l,newline:a,isSlot:u}=e;u&&n(`_${jc[Lw]}(`),n("(",-2,e),Me(s)?nh(s,t):s&&go(s,t),n(") => "),(a||l)&&(n("{"),o()),i?(a&&n("return "),Me(i)?Bw(i,t):go(i,t)):l&&go(l,t),(a||l)&&(r(),n("}")),u&&(e.isNonScopedSlot&&n(", undefined, true"),n(")"))}function IB(e,t){const{test:n,consequent:o,alternate:r,newline:s}=e,{push:i,indent:l,deindent:a,newline:u}=t;if(n.type===4){const d=!Vw(n.content);d&&i("("),L7(n,t),d&&i(")")}else i("("),go(n,t),i(")");s&&l(),t.indentLevel++,s||i(" "),i("? "),go(o,t),t.indentLevel--,s&&u(),s||i(" "),i(": ");const c=r.type===19;c||t.indentLevel++,go(r,t),c||t.indentLevel--,s&&a(!0)}function AB(e,t){const{push:n,helper:o,indent:r,deindent:s,newline:i}=t;n(`_cache[${e.index}] || (`),e.isVNode&&(r(),n(`${o(yg)}(-1),`),i()),n(`_cache[${e.index}] = `),go(e.value,t),e.isVNode&&(n(","),i(),n(`${o(yg)}(1),`),i(),n(`_cache[${e.index}]`),s()),n(")")}new RegExp("\\b"+"arguments,await,break,case,catch,class,const,continue,debugger,default,delete,do,else,export,extends,finally,for,function,if,import,let,new,return,super,switch,throw,try,var,void,while,with,yield".split(",").join("\\b|\\b")+"\\b");const NB=N7(/^(if|else|else-if)$/,(e,t,n)=>PB(e,t,n,(o,r,s)=>{const i=n.parent.children;let l=i.indexOf(o),a=0;for(;l-->=0;){const u=i[l];u&&u.type===9&&(a+=u.branches.length)}return()=>{if(s)o.codegenNode=K4(r,a,n);else{const u=LB(o.codegenNode);u.alternate=K4(r,a+o.branches.length-1,n)}}}));function PB(e,t,n,o){if(t.name!=="else"&&(!t.exp||!t.exp.content.trim())){const r=t.exp?t.exp.loc:e.loc;n.onError(vn(28,t.loc)),t.exp=St("true",!1,r)}if(t.name==="if"){const r=W4(e,t),s={type:9,loc:e.loc,branches:[r]};if(n.replaceNode(s),o)return o(s,r,!0)}else{const r=n.parent.children;let s=r.indexOf(e);for(;s-->=-1;){const i=r[s];if(i&&i.type===3){n.removeNode(i);continue}if(i&&i.type===2&&!i.content.trim().length){n.removeNode(i);continue}if(i&&i.type===9){t.name==="else-if"&&i.branches[i.branches.length-1].condition===void 0&&n.onError(vn(30,e.loc)),n.removeNode();const l=W4(e,t);i.branches.push(l);const a=o&&o(i,l,!1);S0(l,n),a&&a(),n.currentNode=null}else n.onError(vn(30,e.loc));break}}}function W4(e,t){const n=e.tagType===3;return{type:10,loc:e.loc,condition:t.name==="else"?void 0:t.exp,children:n&&!ts(e,"for")?e.children:[e],userKey:k0(e,"key"),isTemplateIf:n}}function K4(e,t,n){return e.condition?O_(e.condition,q4(e,t,n),Vn(n.helper(Qp),['""',"true"])):q4(e,t,n)}function q4(e,t,n){const{helper:o}=n,r=$n("key",St(`${t}`,!1,br,2)),{children:s}=e,i=s[0];if(s.length!==1||i.type!==1)if(s.length===1&&i.type===11){const a=i.codegenNode;return Cg(a,r,n),a}else{let a=64;return wp(n,o(_p),Ir([r]),s,a+"",void 0,void 0,!0,!1,!1,e.loc)}else{const a=i.codegenNode,u=JV(a);return u.type===13&&Dw(u,n),Cg(u,r,n),a}}function LB(e){for(;;)if(e.type===19)if(e.alternate.type===19)e=e.alternate;else return e;else e.type===20&&(e=e.value)}const RB=N7("for",(e,t,n)=>{const{helper:o,removeHelper:r}=n;return DB(e,t,n,s=>{const i=Vn(o(Iw),[s.source]),l=bg(e),a=ts(e,"memo"),u=k0(e,"key"),c=u&&(u.type===6?St(u.value.content,!0):u.exp),d=u?$n("key",c):null,f=s.source.type===4&&s.source.constType>0,p=f?64:u?128:256;return s.codegenNode=wp(n,o(_p),void 0,i,p+"",void 0,void 0,!0,!f,!1,e.loc),()=>{let h;const{children:m}=s,y=m.length!==1||m[0].type!==1,v=wg(e)?e:l&&e.children.length===1&&wg(e.children[0])?e.children[0]:null;if(v?(h=v.codegenNode,l&&d&&Cg(h,d,n)):y?h=wp(n,o(_p),d?Ir([d]):void 0,e.children,"64",void 0,void 0,!0,void 0,!1):(h=m[0].codegenNode,l&&d&&Cg(h,d,n),h.isBlock!==!f&&(h.isBlock?(r(su),r(Wc(n.inSSR,h.isComponent))):r(Uc(n.inSSR,h.isComponent))),h.isBlock=!f,h.isBlock?(o(su),o(Wc(n.inSSR,h.isComponent))):o(Uc(n.inSSR,h.isComponent))),a){const w=Hc(N_(s.parseResult,[St("_cached")]));w.body=zV([as(["const _memo = (",a.exp,")"]),as(["if (_cached",...c?[" && _cached.key === ",c]:[],` && ${n.helperString(_7)}(_cached, _memo)) return _cached`]),as(["const _item = ",h]),St("_item.memo = _memo"),St("return _item")]),i.arguments.push(w,St("_cache"),St(String(n.cached++)))}else i.arguments.push(Hc(N_(s.parseResult),h,!0))}})});function DB(e,t,n,o){if(!t.exp){n.onError(vn(31,t.loc));return}const r=t.forParseResult;if(!r){n.onError(vn(32,t.loc));return}D7(r);const{addIdentifiers:s,removeIdentifiers:i,scopes:l}=n,{source:a,value:u,key:c,index:d}=r,f={type:11,loc:t.loc,source:a,valueAlias:u,keyAlias:c,objectIndexAlias:d,parseResult:r,children:bg(e)?e.children:[e]};n.replaceNode(f),l.vFor++;const p=o&&o(f);return()=>{l.vFor--,p&&p()}}function D7(e,t){e.finalized||(e.finalized=!0)}function N_({value:e,key:t,index:n},o=[]){return FB([e,t,n,...o])}function FB(e){let t=e.length;for(;t--&&!e[t];);return e.slice(0,t+1).map((n,o)=>n||St("_".repeat(o+1),!1))}const G4=St("undefined",!1),VB=(e,t)=>{if(e.type===1&&(e.tagType===1||e.tagType===3)){const n=ts(e,"slot");if(n)return n.exp,t.scopes.vSlot++,()=>{t.scopes.vSlot--}}},BB=(e,t,n,o)=>Hc(e,n,!1,!0,n.length?n[0].loc:o);function zB(e,t,n=BB){t.helper(Lw);const{children:o,loc:r}=e,s=[],i=[];let l=t.scopes.vSlot>0||t.scopes.vFor>0;const a=ts(e,"slot",!0);if(a){const{arg:y,exp:v}=a;y&&!Ho(y)&&(l=!0),s.push($n(y||St("default",!0),n(v,void 0,o,r)))}let u=!1,c=!1;const d=[],f=new Set;let p=0;for(let y=0;y<o.length;y++){const v=o[y];let w;if(!bg(v)||!(w=ts(v,"slot",!0))){v.type!==3&&d.push(v);continue}if(a){t.onError(vn(37,w.loc));break}u=!0;const{children:_,loc:S}=v,{arg:x=St("default",!0),exp:E,loc:T}=w;let O;Ho(x)?O=x?x.content:"default":l=!0;const P=ts(v,"for"),N=n(E,P,_,S);let F,B;if(F=ts(v,"if"))l=!0,i.push(O_(F.exp,rm(x,N,p++),G4));else if(B=ts(v,/^else(-if)?$/,!0)){let Y=y,Z;for(;Y--&&(Z=o[Y],Z.type===3););if(Z&&bg(Z)&&ts(Z,"if")){o.splice(y,1),y--;let U=i[i.length-1];for(;U.alternate.type===19;)U=U.alternate;U.alternate=B.exp?O_(B.exp,rm(x,N,p++),G4):rm(x,N,p++)}else t.onError(vn(30,B.loc))}else if(P){l=!0;const Y=P.forParseResult;Y?(D7(Y),i.push(Vn(t.helper(Iw),[Y.source,Hc(N_(Y),rm(x,N),!0)]))):t.onError(vn(32,P.loc))}else{if(O){if(f.has(O)){t.onError(vn(38,T));continue}f.add(O),O==="default"&&(c=!0)}s.push($n(x,N))}}if(!a){const y=(v,w)=>{const _=n(v,void 0,w,r);return t.compatConfig&&(_.isNonScopedSlot=!0),$n("default",_)};u?d.length&&d.some(v=>F7(v))&&(c?t.onError(vn(39,d[0].loc)):s.push(y(void 0,d))):s.push(y(void 0,o))}const h=l?2:Wm(e.children)?3:1;let m=Ir(s.concat($n("_",St(h+"",!1))),r);return i.length&&(m=Vn(t.helper(y7),[m,th(i)])),{slots:m,hasDynamicSlots:l}}function rm(e,t,n){const o=[$n("name",e),$n("fn",t)];return n!=null&&o.push($n("key",St(String(n),!0))),Ir(o)}function Wm(e){for(let t=0;t<e.length;t++){const n=e[t];switch(n.type){case 1:if(n.tagType===2||Wm(n.children))return!0;break;case 9:if(Wm(n.branches))return!0;break;case 10:case 11:if(Wm(n.children))return!0;break}}return!1}function F7(e){return e.type!==2&&e.type!==12?!0:e.type===2?!!e.content.trim():F7(e.content)}const V7=new WeakMap,jB=(e,t)=>function(){if(e=t.currentNode,!(e.type===1&&(e.tagType===0||e.tagType===1)))return;const{tag:o,props:r}=e,s=e.tagType===1;let i=s?HB(e,t):`"${o}"`;const l=ft(i)&&i.callee===xw;let a,u,c,d=0,f,p,h,m=l||i===Ff||i===Cw||!s&&(o==="svg"||o==="foreignObject");if(r.length>0){const y=B7(e,t,void 0,s,l);a=y.props,d=y.patchFlag,p=y.dynamicPropNames;const v=y.directives;h=v&&v.length?th(v.map(w=>WB(w,t))):void 0,y.shouldUseBlock&&(m=!0)}if(e.children.length>0)if(i===gg&&(m=!0,d|=1024),s&&i!==Ff&&i!==gg){const{slots:v,hasDynamicSlots:w}=zB(e,t);u=v,w&&(d|=1024)}else if(e.children.length===1&&i!==Ff){const v=e.children[0],w=v.type,_=w===5||w===8;_&&Ar(v,t)===0&&(d|=1),_||w===2?u=v:u=e.children}else u=e.children;d!==0&&(c=String(d),p&&p.length&&(f=KB(p))),e.codegenNode=wp(t,i,a,u,c,f,h,!!m,!1,s,e.loc)};function HB(e,t,n=!1){let{tag:o}=e;const r=P_(o),s=k0(e,"is",!1,!0);if(s)if(r||Ha("COMPILER_IS_ON_ELEMENT",t)){let l;if(s.type===6?l=s.value&&St(s.value.content,!0):(l=s.exp,l||(l=St("is",!1,s.loc))),l)return Vn(t.helper(xw),[l])}else s.type===6&&s.value.content.startsWith("vue:")&&(o=s.value.content.slice(4));const i=w7(o)||t.isBuiltInComponent(o);return i?(n||t.helper(i),i):(t.helper(Ew),t.components.add(o),kp(o,"component"))}function B7(e,t,n=e.props,o,r,s=!1){const{tag:i,loc:l,children:a}=e;let u=[];const c=[],d=[],f=a.length>0;let p=!1,h=0,m=!1,y=!1,v=!1,w=!1,_=!1,S=!1;const x=[],E=P=>{u.length&&(c.push(Ir(Y4(u),l)),u=[]),P&&c.push(P)},T=({key:P,value:N})=>{if(Ho(P)){const F=P.content,B=vu(F);if(B&&(!o||r)&&F.toLowerCase()!=="onclick"&&F!=="onUpdate:modelValue"&&!Al(F)&&(w=!0),B&&Al(F)&&(S=!0),B&&N.type===14&&(N=N.arguments[0]),N.type===20||(N.type===4||N.type===8)&&Ar(N,t)>0)return;F==="ref"?m=!0:F==="class"?y=!0:F==="style"?v=!0:F!=="key"&&!x.includes(F)&&x.push(F),o&&(F==="class"||F==="style")&&!x.includes(F)&&x.push(F)}else _=!0};for(let P=0;P<n.length;P++){const N=n[P];if(N.type===6){const{loc:F,name:B,nameLoc:Y,value:Z}=N;let U=!0;if(B==="ref"&&(m=!0,t.scopes.vFor>0&&u.push($n(St("ref_for",!0),St("true")))),B==="is"&&(P_(i)||Z&&Z.content.startsWith("vue:")||Ha("COMPILER_IS_ON_ELEMENT",t)))continue;u.push($n(St(B,!0,Y),St(Z?Z.content:"",U,Z?Z.loc:F)))}else{const{name:F,arg:B,exp:Y,loc:Z,modifiers:U}=N,j=F==="bind",V=F==="on";if(F==="slot"){o||t.onError(vn(40,Z));continue}if(F==="once"||F==="memo"||F==="is"||j&&Ta(B,"is")&&(P_(i)||Ha("COMPILER_IS_ON_ELEMENT",t))||V&&s)continue;if((j&&Ta(B,"key")||V&&f&&Ta(B,"vue:before-update"))&&(p=!0),j&&Ta(B,"ref")&&t.scopes.vFor>0&&u.push($n(St("ref_for",!0),St("true"))),!B&&(j||V)){if(_=!0,Y)if(j){if(E(),Ha("COMPILER_V_BIND_OBJECT_ORDER",t)){c.unshift(Y);continue}c.push(Y)}else E({type:14,loc:Z,callee:t.helper(Pw),arguments:o?[Y]:[Y,"true"]});else t.onError(vn(j?34:35,Z));continue}j&&U.includes("prop")&&(h|=32);const H=t.directiveTransforms[F];if(H){const{props:L,needRuntime:I}=H(N,e,t);!s&&L.forEach(T),V&&B&&!Ho(B)?E(Ir(L,l)):u.push(...L),I&&(d.push(N),Fr(I)&&V7.set(N,I))}else xR(F)||(d.push(N),f&&(p=!0))}}let O;if(c.length?(E(),c.length>1?O=Vn(t.helper(vg),c,l):O=c[0]):u.length&&(O=Ir(Y4(u),l)),_?h|=16:(y&&!o&&(h|=2),v&&!o&&(h|=4),x.length&&(h|=8),w&&(h|=32)),!p&&(h===0||h===32)&&(m||S||d.length>0)&&(h|=512),!t.inSSR&&O)switch(O.type){case 15:let P=-1,N=-1,F=!1;for(let Z=0;Z<O.properties.length;Z++){const U=O.properties[Z].key;Ho(U)?U.content==="class"?P=Z:U.content==="style"&&(N=Z):U.isHandlerKey||(F=!0)}const B=O.properties[P],Y=O.properties[N];F?O=Vn(t.helper(bp),[O]):(B&&!Ho(B.value)&&(B.value=Vn(t.helper(Aw),[B.value])),Y&&(v||Y.value.type===4&&Y.value.content.trim()[0]==="["||Y.value.type===17)&&(Y.value=Vn(t.helper(Nw),[Y.value])));break;case 14:break;default:O=Vn(t.helper(bp),[Vn(t.helper(eh),[O])]);break}return{props:O,directives:d,patchFlag:h,dynamicPropNames:x,shouldUseBlock:p}}function Y4(e){const t=new Map,n=[];for(let o=0;o<e.length;o++){const r=e[o];if(r.key.type===8||!r.key.isStatic){n.push(r);continue}const s=r.key.content,i=t.get(s);i?(s==="style"||s==="class"||vu(s))&&UB(i,r):(t.set(s,r),n.push(r))}return n}function UB(e,t){e.value.type===17?e.value.elements.push(t.value):e.value=th([e.value,t.value],e.loc)}function WB(e,t){const n=[],o=V7.get(e);o?n.push(t.helperString(o)):(t.helper(Mw),t.directives.add(e.name),n.push(kp(e.name,"directive")));const{loc:r}=e;if(e.exp&&n.push(e.exp),e.arg&&(e.exp||n.push("void 0"),n.push(e.arg)),Object.keys(e.modifiers).length){e.arg||(e.exp||n.push("void 0"),n.push("void 0"));const s=St("true",!1,r);n.push(Ir(e.modifiers.map(i=>$n(i,s)),r))}return th(n,e.loc)}function KB(e){let t="[";for(let n=0,o=e.length;n<o;n++)t+=JSON.stringify(e[n]),n<o-1&&(t+=", ");return t+"]"}function P_(e){return e==="component"||e==="Component"}const qB=(e,t)=>{if(wg(e)){const{children:n,loc:o}=e,{slotName:r,slotProps:s}=GB(e,t),i=[t.prefixIdentifiers?"_ctx.$slots":"$slots",r,"{}","undefined","true"];let l=2;s&&(i[2]=s,l=3),n.length&&(i[3]=Hc([],n,!1,!1,o),l=4),t.scopeId&&!t.slotted&&(l=5),i.splice(l),e.codegenNode=Vn(t.helper(v7),i,o)}};function GB(e,t){let n='"default"',o;const r=[];for(let s=0;s<e.props.length;s++){const i=e.props[s];if(i.type===6)i.value&&(i.name==="name"?n=JSON.stringify(i.value.content):(i.name=yn(i.name),r.push(i)));else if(i.name==="bind"&&Ta(i.arg,"name")){if(i.exp)n=i.exp;else if(i.arg&&i.arg.type===4){const l=yn(i.arg.content);n=i.exp=St(l,!1,i.arg.loc)}}else i.name==="bind"&&i.arg&&Ho(i.arg)&&(i.arg.content=yn(i.arg.content)),r.push(i)}if(r.length>0){const{props:s,directives:i}=B7(e,t,r,!1,!1);o=s,i.length&&t.onError(vn(36,i[0].loc))}return{slotName:n,slotProps:o}}const YB=/^\s*([\w$_]+|(async\s*)?\([^)]*?\))\s*(:[^=]+)?=>|^\s*(async\s+)?function(?:\s+[\w$]+)?\s*\(/,z7=(e,t,n,o)=>{const{loc:r,modifiers:s,arg:i}=e;!e.exp&&!s.length&&n.onError(vn(35,r));let l;if(i.type===4)if(i.isStatic){let d=i.content;d.startsWith("vue:")&&(d=`vnode-${d.slice(4)}`);const f=t.tagType!==0||d.startsWith("vnode")||!/[A-Z]/.test(d)?vc(yn(d)):`on:${d}`;l=St(f,!0,i.loc)}else l=as([`${n.helperString(T_)}(`,i,")"]);else l=i,l.children.unshift(`${n.helperString(T_)}(`),l.children.push(")");let a=e.exp;a&&!a.content.trim()&&(a=void 0);let u=n.cacheHandlers&&!a&&!n.inVOnce;if(a){const d=C7(a.content),f=!(d||YB.test(a.content)),p=a.content.includes(";");(f||u&&d)&&(a=as([`${f?"$event":"(...args)"} => ${p?"{":"("}`,a,p?"}":")"]))}let c={props:[$n(l,a||St("() => {}",!1,r))]};return o&&(c=o(c)),u&&(c.props[0].value=n.cache(c.props[0].value)),c.props.forEach(d=>d.key.isHandlerKey=!0),c},ZB=(e,t,n)=>{const{modifiers:o,loc:r}=e,s=e.arg;let{exp:i}=e;if(i&&i.type===4&&!i.content.trim()&&(i=void 0),!i){if(s.type!==4||!s.isStatic)return n.onError(vn(52,s.loc)),{props:[$n(s,St("",!0,r))]};const l=yn(s.content);i=e.exp=St(l,!1,s.loc)}return s.type!==4?(s.children.unshift("("),s.children.push(') || ""')):s.isStatic||(s.content=`${s.content} || ""`),o.includes("camel")&&(s.type===4?s.isStatic?s.content=yn(s.content):s.content=`${n.helperString(M_)}(${s.content})`:(s.children.unshift(`${n.helperString(M_)}(`),s.children.push(")"))),n.inSSR||(o.includes("prop")&&Z4(s,"."),o.includes("attr")&&Z4(s,"^")),{props:[$n(s,i)]}},Z4=(e,t)=>{e.type===4?e.isStatic?e.content=t+e.content:e.content=`\`${t}\${${e.content}}\``:(e.children.unshift(`'${t}' + (`),e.children.push(")"))},JB=(e,t)=>{if(e.type===0||e.type===1||e.type===11||e.type===10)return()=>{const n=e.children;let o,r=!1;for(let s=0;s<n.length;s++){const i=n[s];if(jv(i)){r=!0;for(let l=s+1;l<n.length;l++){const a=n[l];if(jv(a))o||(o=n[s]=as([i],i.loc)),o.children.push(" + ",a),n.splice(l,1),l--;else{o=void 0;break}}}}if(!(!r||n.length===1&&(e.type===0||e.type===1&&e.tagType===0&&!e.props.find(s=>s.type===7&&!t.directiveTransforms[s.name])&&e.tag!=="template")))for(let s=0;s<n.length;s++){const i=n[s];if(jv(i)||i.type===8){const l=[];(i.type!==2||i.content!==" ")&&l.push(i),!t.ssr&&Ar(i,t)===0&&l.push("1"),n[s]={type:12,content:i,loc:i.loc,codegenNode:Vn(t.helper($w),l)}}}}},J4=new WeakSet,XB=(e,t)=>{if(e.type===1&&ts(e,"once",!0))return J4.has(e)||t.inVOnce||t.inSSR?void 0:(J4.add(e),t.inVOnce=!0,t.helper(yg),()=>{t.inVOnce=!1;const n=t.currentNode;n.codegenNode&&(n.codegenNode=t.cache(n.codegenNode,!0))})},j7=(e,t,n)=>{const{exp:o,arg:r}=e;if(!o)return n.onError(vn(41,e.loc)),sm();const s=o.loc.source,i=o.type===4?o.content:s,l=n.bindingMetadata[s];if(l==="props"||l==="props-aliased")return n.onError(vn(44,o.loc)),sm();const a=!1;if(!i.trim()||!C7(i)&&!a)return n.onError(vn(42,o.loc)),sm();const u=r||St("modelValue",!0),c=r?Ho(r)?`onUpdate:${yn(r.content)}`:as(['"onUpdate:" + ',r]):"onUpdate:modelValue";let d;const f=n.isTS?"($event: any)":"$event";d=as([`${f} => ((`,o,") = $event)"]);const p=[$n(u,e.exp),$n(c,d)];if(e.modifiers.length&&t.tagType===1){const h=e.modifiers.map(y=>(Vw(y)?y:JSON.stringify(y))+": true").join(", "),m=r?Ho(r)?`${r.content}Modifiers`:as([r,' + "Modifiers"']):"modelModifiers";p.push($n(m,St(`{ ${h} }`,!1,e.loc,2)))}return sm(p)};function sm(e=[]){return{props:e}}const QB=/[\w).+\-_$\]]/,ez=(e,t)=>{Ha("COMPILER_FILTERS",t)&&(e.type===5&&Sg(e.content,t),e.type===1&&e.props.forEach(n=>{n.type===7&&n.name!=="for"&&n.exp&&Sg(n.exp,t)}))};function Sg(e,t){if(e.type===4)X4(e,t);else for(let n=0;n<e.children.length;n++){const o=e.children[n];typeof o=="object"&&(o.type===4?X4(o,t):o.type===8?Sg(e,t):o.type===5&&Sg(o.content,t))}}function X4(e,t){const n=e.content;let o=!1,r=!1,s=!1,i=!1,l=0,a=0,u=0,c=0,d,f,p,h,m=[];for(p=0;p<n.length;p++)if(f=d,d=n.charCodeAt(p),o)d===39&&f!==92&&(o=!1);else if(r)d===34&&f!==92&&(r=!1);else if(s)d===96&&f!==92&&(s=!1);else if(i)d===47&&f!==92&&(i=!1);else if(d===124&&n.charCodeAt(p+1)!==124&&n.charCodeAt(p-1)!==124&&!l&&!a&&!u)h===void 0?(c=p+1,h=n.slice(0,p).trim()):y();else{switch(d){case 34:r=!0;break;case 39:o=!0;break;case 96:s=!0;break;case 40:u++;break;case 41:u--;break;case 91:a++;break;case 93:a--;break;case 123:l++;break;case 125:l--;break}if(d===47){let v=p-1,w;for(;v>=0&&(w=n.charAt(v),w===" ");v--);(!w||!QB.test(w))&&(i=!0)}}h===void 0?h=n.slice(0,p).trim():c!==0&&y();function y(){m.push(n.slice(c,p).trim()),c=p+1}if(m.length){for(p=0;p<m.length;p++)h=tz(h,m[p],t);e.content=h}}function tz(e,t,n){n.helper(Tw);const o=t.indexOf("(");if(o<0)return n.filters.add(t),`${kp(t,"filter")}(${e})`;{const r=t.slice(0,o),s=t.slice(o+1);return n.filters.add(r),`${kp(r,"filter")}(${e}${s!==")"?","+s:s}`}}const Q4=new WeakSet,nz=(e,t)=>{if(e.type===1){const n=ts(e,"memo");return!n||Q4.has(e)?void 0:(Q4.add(e),()=>{const o=e.codegenNode||t.currentNode.codegenNode;o&&o.type===13&&(e.tagType!==1&&Dw(o,t),e.codegenNode=Vn(t.helper(Rw),[n.exp,Hc(void 0,o),"_cache",String(t.cached++)]))})}};function oz(e){return[[XB,NB,nz,RB,ez,qB,jB,VB,JB],{on:z7,bind:ZB,model:j7}]}function rz(e,t={}){const n=t.onError||Fw,o=t.mode==="module";t.prefixIdentifiers===!0?n(vn(47)):o&&n(vn(48));const r=!1;t.cacheHandlers&&n(vn(49)),t.scopeId&&!o&&n(vn(50));const s=Bt({},t,{prefixIdentifiers:r}),i=tt(e)?cB(e,s):e,[l,a]=oz();return hB(i,Bt({},s,{nodeTransforms:[...l,...t.nodeTransforms||[]],directiveTransforms:Bt({},a,t.directiveTransforms||{})})),yB(i,s)}const sz=()=>({props:[]});/**
28 * @vue/compiler-dom v3.4.23
29 * (c) 2018-present Yuxi (Evan) You and Vue contributors
30 * @license MIT
31 **/const H7=Symbol(""),U7=Symbol(""),W7=Symbol(""),K7=Symbol(""),L_=Symbol(""),q7=Symbol(""),G7=Symbol(""),Y7=Symbol(""),Z7=Symbol(""),J7=Symbol("");FV({[H7]:"vModelRadio",[U7]:"vModelCheckbox",[W7]:"vModelText",[K7]:"vModelSelect",[L_]:"vModelDynamic",[q7]:"withModifiers",[G7]:"withKeys",[Y7]:"vShow",[Z7]:"Transition",[J7]:"TransitionGroup"});let Au;function iz(e,t=!1){return Au||(Au=document.createElement("div")),t?(Au.innerHTML=`<div foo="${e.replace(/"/g,"&quot;")}">`,Au.children[0].getAttribute("foo")):(Au.innerHTML=e,Au.textContent)}const lz={parseMode:"html",isVoidTag:jR,isNativeTag:e=>VR(e)||BR(e)||zR(e),isPreTag:e=>e==="pre",decodeEntities:iz,isBuiltInComponent:e=>{if(e==="Transition"||e==="transition")return Z7;if(e==="TransitionGroup"||e==="transition-group")return J7},getNamespace(e,t,n){let o=t?t.ns:n;if(t&&o===2)if(t.tag==="annotation-xml"){if(e==="svg")return 1;t.props.some(r=>r.type===6&&r.name==="encoding"&&r.value!=null&&(r.value.content==="text/html"||r.value.content==="application/xhtml+xml"))&&(o=0)}else/^m(?:[ions]|text)$/.test(t.tag)&&e!=="mglyph"&&e!=="malignmark"&&(o=0);else t&&o===1&&(t.tag==="foreignObject"||t.tag==="desc"||t.tag==="title")&&(o=0);if(o===0){if(e==="svg")return 1;if(e==="math")return 2}return o}},az=e=>{e.type===1&&e.props.forEach((t,n)=>{t.type===6&&t.name==="style"&&t.value&&(e.props[n]={type:7,name:"bind",arg:St("style",!0,t.loc),exp:uz(t.value.content,t.loc),modifiers:[],loc:t.loc})})},uz=(e,t)=>{const n=k$(e);return St(JSON.stringify(n),!1,t,3)};function Pl(e,t){return vn(e,t)}const cz=(e,t,n)=>{const{exp:o,loc:r}=e;return o||n.onError(Pl(53,r)),t.children.length&&(n.onError(Pl(54,r)),t.children.length=0),{props:[$n(St("innerHTML",!0,r),o||St("",!0))]}},dz=(e,t,n)=>{const{exp:o,loc:r}=e;return o||n.onError(Pl(55,r)),t.children.length&&(n.onError(Pl(56,r)),t.children.length=0),{props:[$n(St("textContent",!0),o?Ar(o,n)>0?o:Vn(n.helperString(C0),[o],r):St("",!0))]}},fz=(e,t,n)=>{const o=j7(e,t,n);if(!o.props.length||t.tagType===1)return o;e.arg&&n.onError(Pl(58,e.arg.loc));const{tag:r}=t,s=n.isCustomElement(r);if(r==="input"||r==="textarea"||r==="select"||s){let i=W7,l=!1;if(r==="input"||s){const a=k0(t,"type");if(a){if(a.type===7)i=L_;else if(a.value)switch(a.value.content){case"radio":i=H7;break;case"checkbox":i=U7;break;case"file":l=!0,n.onError(Pl(59,e.loc));break}}else GV(t)&&(i=L_)}else r==="select"&&(i=K7);l||(o.needRuntime=n.helper(i))}else n.onError(Pl(57,e.loc));return o.props=o.props.filter(i=>!(i.key.type===4&&i.key.content==="modelValue")),o},pz=yr("passive,once,capture"),hz=yr("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),mz=yr("left,right"),X7=yr("onkeyup,onkeydown,onkeypress",!0),gz=(e,t,n,o)=>{const r=[],s=[],i=[];for(let l=0;l<t.length;l++){const a=t[l];a==="native"&&Cp("COMPILER_V_ON_NATIVE",n)||pz(a)?i.push(a):mz(a)?Ho(e)?X7(e.content)?r.push(a):s.push(a):(r.push(a),s.push(a)):hz(a)?s.push(a):r.push(a)}return{keyModifiers:r,nonKeyModifiers:s,eventOptionModifiers:i}},e6=(e,t)=>Ho(e)&&e.content.toLowerCase()==="onclick"?St(t,!0):e.type!==4?as(["(",e,`) === "onClick" ? "${t}" : (`,e,")"]):e,vz=(e,t,n)=>z7(e,t,n,o=>{const{modifiers:r}=e;if(!r.length)return o;let{key:s,value:i}=o.props[0];const{keyModifiers:l,nonKeyModifiers:a,eventOptionModifiers:u}=gz(s,r,n,e.loc);if(a.includes("right")&&(s=e6(s,"onContextmenu")),a.includes("middle")&&(s=e6(s,"onMouseup")),a.length&&(i=Vn(n.helper(q7),[i,JSON.stringify(a)])),l.length&&(!Ho(s)||X7(s.content))&&(i=Vn(n.helper(G7),[i,JSON.stringify(l)])),u.length){const c=u.map(ql).join("");s=Ho(s)?St(`${s.content}${c}`,!0):as(["(",s,`) + "${c}"`])}return{props:[$n(s,i)]}}),yz=(e,t,n)=>{const{exp:o,loc:r}=e;return o||n.onError(Pl(61,r)),{props:[],needRuntime:n.helper(Y7)}},_z=(e,t)=>{e.type===1&&e.tagType===0&&(e.tag==="script"||e.tag==="style")&&t.removeNode()},bz=[az],wz={cloak:sz,html:cz,text:dz,model:fz,on:vz,show:yz};function Cz(e,t={}){return rz(e,Bt({},lz,t,{nodeTransforms:[_z,...bz,...t.nodeTransforms||[]],directiveTransforms:Bt({},wz,t.directiveTransforms||{}),transformHoist:null}))}/**
32 * vue v3.4.23
33 * (c) 2018-present Yuxi (Evan) You and Vue contributors
34 * @license MIT
35 **/const t6=new WeakMap;function kz(e){let t=t6.get(e??Wt);return t||(t=Object.create(null),t6.set(e??Wt,t)),t}function Sz(e,t){if(!tt(e))if(e.nodeType)e=e.innerHTML;else return yt;const n=e,o=kz(t),r=o[n];if(r)return r;if(e[0]==="#"){const a=document.querySelector(e);e=a?a.innerHTML:""}const s=Bt({hoistStatic:!0,onError:void 0,onWarn:yt},t);!s.isCustomElement&&typeof customElements<"u"&&(s.isCustomElement=a=>!!customElements.get(a));const{code:i}=Cz(e,s),l=new Function("Vue",i)(AV);return l._rc=!0,o[n]=l}zE(Sz);/*!
36 * vue-router v4.3.2
37 * (c) 2024 Eduardo San Martin Morote
38 * @license MIT
39 */const Wu=typeof document<"u";function $z(e){return e.__esModule||e[Symbol.toStringTag]==="Module"}const Qt=Object.assign;function Uv(e,t){const n={};for(const o in t){const r=t[o];n[o]=ms(r)?r.map(e):e(r)}return n}const Vf=()=>{},ms=Array.isArray,Q7=/#/g,Ez=/&/g,xz=/\//g,Mz=/=/g,Tz=/\?/g,ex=/\+/g,Oz=/%5B/g,Iz=/%5D/g,tx=/%5E/g,Az=/%60/g,nx=/%7B/g,Nz=/%7C/g,ox=/%7D/g,Pz=/%20/g;function zw(e){return encodeURI(""+e).replace(Nz,"|").replace(Oz,"[").replace(Iz,"]")}function Lz(e){return zw(e).replace(nx,"{").replace(ox,"}").replace(tx,"^")}function R_(e){return zw(e).replace(ex,"%2B").replace(Pz,"+").replace(Q7,"%23").replace(Ez,"%26").replace(Az,"`").replace(nx,"{").replace(ox,"}").replace(tx,"^")}function Rz(e){return R_(e).replace(Mz,"%3D")}function Dz(e){return zw(e).replace(Q7,"%23").replace(Tz,"%3F")}function Fz(e){return e==null?"":Dz(e).replace(xz,"%2F")}function $p(e){try{return decodeURIComponent(""+e)}catch{}return""+e}const Vz=/\/$/,Bz=e=>e.replace(Vz,"");function Wv(e,t,n="/"){let o,r={},s="",i="";const l=t.indexOf("#");let a=t.indexOf("?");return l<a&&l>=0&&(a=-1),a>-1&&(o=t.slice(0,a),s=t.slice(a+1,l>-1?l:t.length),r=e(s)),l>-1&&(o=o||t.slice(0,l),i=t.slice(l,t.length)),o=Uz(o??t,n),{fullPath:o+(s&&"?")+s+i,path:o,query:r,hash:$p(i)}}function zz(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function n6(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function jz(e,t,n){const o=t.matched.length-1,r=n.matched.length-1;return o>-1&&o===r&&Kc(t.matched[o],n.matched[r])&&rx(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function Kc(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function rx(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!Hz(e[n],t[n]))return!1;return!0}function Hz(e,t){return ms(e)?o6(e,t):ms(t)?o6(t,e):e===t}function o6(e,t){return ms(t)?e.length===t.length&&e.every((n,o)=>n===t[o]):e.length===1&&e[0]===t}function Uz(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),o=e.split("/"),r=o[o.length-1];(r===".."||r===".")&&o.push("");let s=n.length-1,i,l;for(i=0;i<o.length;i++)if(l=o[i],l!==".")if(l==="..")s>1&&s--;else break;return n.slice(0,s).join("/")+"/"+o.slice(i).join("/")}var Ep;(function(e){e.pop="pop",e.push="push"})(Ep||(Ep={}));var Bf;(function(e){e.back="back",e.forward="forward",e.unknown=""})(Bf||(Bf={}));function Wz(e){if(!e)if(Wu){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),Bz(e)}const Kz=/^[^#]+#/;function qz(e,t){return e.replace(Kz,"#")+t}function Gz(e,t){const n=document.documentElement.getBoundingClientRect(),o=e.getBoundingClientRect();return{behavior:t.behavior,left:o.left-n.left-(t.left||0),top:o.top-n.top-(t.top||0)}}const E0=()=>({left:window.scrollX,top:window.scrollY});function Yz(e){let t;if("el"in e){const n=e.el,o=typeof n=="string"&&n.startsWith("#"),r=typeof n=="string"?o?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!r)return;t=Gz(r,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.scrollX,t.top!=null?t.top:window.scrollY)}function r6(e,t){return(history.state?history.state.position-t:-1)+e}const D_=new Map;function Zz(e,t){D_.set(e,t)}function Jz(e){const t=D_.get(e);return D_.delete(e),t}let Xz=()=>location.protocol+"//"+location.host;function sx(e,t){const{pathname:n,search:o,hash:r}=t,s=e.indexOf("#");if(s>-1){let l=r.includes(e.slice(s))?e.slice(s).length:1,a=r.slice(l);return a[0]!=="/"&&(a="/"+a),n6(a,"")}return n6(n,e)+o+r}function Qz(e,t,n,o){let r=[],s=[],i=null;const l=({state:f})=>{const p=sx(e,location),h=n.value,m=t.value;let y=0;if(f){if(n.value=p,t.value=f,i&&i===h){i=null;return}y=m?f.position-m.position:0}else o(p);r.forEach(v=>{v(n.value,h,{delta:y,type:Ep.pop,direction:y?y>0?Bf.forward:Bf.back:Bf.unknown})})};function a(){i=n.value}function u(f){r.push(f);const p=()=>{const h=r.indexOf(f);h>-1&&r.splice(h,1)};return s.push(p),p}function c(){const{history:f}=window;f.state&&f.replaceState(Qt({},f.state,{scroll:E0()}),"")}function d(){for(const f of s)f();s=[],window.removeEventListener("popstate",l),window.removeEventListener("beforeunload",c)}return window.addEventListener("popstate",l),window.addEventListener("beforeunload",c,{passive:!0}),{pauseListeners:a,listen:u,destroy:d}}function s6(e,t,n,o=!1,r=!1){return{back:e,current:t,forward:n,replaced:o,position:window.history.length,scroll:r?E0():null}}function ej(e){const{history:t,location:n}=window,o={value:sx(e,n)},r={value:t.state};r.value||s(o.value,{back:null,current:o.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function s(a,u,c){const d=e.indexOf("#"),f=d>-1?(n.host&&document.querySelector("base")?e:e.slice(d))+a:Xz()+e+a;try{t[c?"replaceState":"pushState"](u,"",f),r.value=u}catch(p){console.error(p),n[c?"replace":"assign"](f)}}function i(a,u){const c=Qt({},t.state,s6(r.value.back,a,r.value.forward,!0),u,{position:r.value.position});s(a,c,!0),o.value=a}function l(a,u){const c=Qt({},r.value,t.state,{forward:a,scroll:E0()});s(c.current,c,!0);const d=Qt({},s6(o.value,a,null),{position:c.position+1},u);s(a,d,!1),o.value=a}return{location:o,state:r,push:l,replace:i}}function ix(e){e=Wz(e);const t=ej(e),n=Qz(e,t.state,t.location,t.replace);function o(s,i=!0){i||n.pauseListeners(),history.go(s)}const r=Qt({location:"",base:e,go:o,createHref:qz.bind(null,e)},t,n);return Object.defineProperty(r,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(r,"state",{enumerable:!0,get:()=>t.state.value}),r}function tj(e){return e=location.host?e||location.pathname+location.search:"",e.includes("#")||(e+="#"),ix(e)}function nj(e){return typeof e=="string"||e&&typeof e=="object"}function lx(e){return typeof e=="string"||typeof e=="symbol"}const Yi={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},ax=Symbol("");var i6;(function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"})(i6||(i6={}));function qc(e,t){return Qt(new Error,{type:e,[ax]:!0},t)}function ui(e,t){return e instanceof Error&&ax in e&&(t==null||!!(e.type&t))}const l6="[^/]+?",oj={sensitive:!1,strict:!1,start:!0,end:!0},rj=/[.+*?^${}()[\]/\\]/g;function sj(e,t){const n=Qt({},oj,t),o=[];let r=n.start?"^":"";const s=[];for(const u of e){const c=u.length?[]:[90];n.strict&&!u.length&&(r+="/");for(let d=0;d<u.length;d++){const f=u[d];let p=40+(n.sensitive?.25:0);if(f.type===0)d||(r+="/"),r+=f.value.replace(rj,"\\$&"),p+=40;else if(f.type===1){const{value:h,repeatable:m,optional:y,regexp:v}=f;s.push({name:h,repeatable:m,optional:y});const w=v||l6;if(w!==l6){p+=10;try{new RegExp(`(${w})`)}catch(S){throw new Error(`Invalid custom RegExp for param "${h}" (${w}): `+S.message)}}let _=m?`((?:${w})(?:/(?:${w}))*)`:`(${w})`;d||(_=y&&u.length<2?`(?:/${_})`:"/"+_),y&&(_+="?"),r+=_,p+=20,y&&(p+=-8),m&&(p+=-20),w===".*"&&(p+=-50)}c.push(p)}o.push(c)}if(n.strict&&n.end){const u=o.length-1;o[u][o[u].length-1]+=.7000000000000001}n.strict||(r+="/?"),n.end?r+="$":n.strict&&(r+="(?:/|$)");const i=new RegExp(r,n.sensitive?"":"i");function l(u){const c=u.match(i),d={};if(!c)return null;for(let f=1;f<c.length;f++){const p=c[f]||"",h=s[f-1];d[h.name]=p&&h.repeatable?p.split("/"):p}return d}function a(u){let c="",d=!1;for(const f of e){(!d||!c.endsWith("/"))&&(c+="/"),d=!1;for(const p of f)if(p.type===0)c+=p.value;else if(p.type===1){const{value:h,repeatable:m,optional:y}=p,v=h in u?u[h]:"";if(ms(v)&&!m)throw new Error(`Provided param "${h}" is an array but it is not repeatable (* or + modifiers)`);const w=ms(v)?v.join("/"):v;if(!w)if(y)f.length<2&&(c.endsWith("/")?c=c.slice(0,-1):d=!0);else throw new Error(`Missing required param "${h}"`);c+=w}}return c||"/"}return{re:i,score:o,keys:s,parse:l,stringify:a}}function ij(e,t){let n=0;for(;n<e.length&&n<t.length;){const o=t[n]-e[n];if(o)return o;n++}return e.length<t.length?e.length===1&&e[0]===40+40?-1:1:e.length>t.length?t.length===1&&t[0]===40+40?1:-1:0}function lj(e,t){let n=0;const o=e.score,r=t.score;for(;n<o.length&&n<r.length;){const s=ij(o[n],r[n]);if(s)return s;n++}if(Math.abs(r.length-o.length)===1){if(a6(o))return 1;if(a6(r))return-1}return r.length-o.length}function a6(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const aj={type:0,value:""},uj=/[a-zA-Z0-9_]/;function cj(e){if(!e)return[[]];if(e==="/")return[[aj]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(p){throw new Error(`ERR (${n})/"${u}": ${p}`)}let n=0,o=n;const r=[];let s;function i(){s&&r.push(s),s=[]}let l=0,a,u="",c="";function d(){u&&(n===0?s.push({type:0,value:u}):n===1||n===2||n===3?(s.length>1&&(a==="*"||a==="+")&&t(`A repeatable param (${u}) must be alone in its segment. eg: '/:ids+.`),s.push({type:1,value:u,regexp:c,repeatable:a==="*"||a==="+",optional:a==="*"||a==="?"})):t("Invalid state to consume buffer"),u="")}function f(){u+=a}for(;l<e.length;){if(a=e[l++],a==="\\"&&n!==2){o=n,n=4;continue}switch(n){case 0:a==="/"?(u&&d(),i()):a===":"?(d(),n=1):f();break;case 4:f(),n=o;break;case 1:a==="("?n=2:uj.test(a)?f():(d(),n=0,a!=="*"&&a!=="?"&&a!=="+"&&l--);break;case 2:a===")"?c[c.length-1]=="\\"?c=c.slice(0,-1)+a:n=3:c+=a;break;case 3:d(),n=0,a!=="*"&&a!=="?"&&a!=="+"&&l--,c="";break;default:t("Unknown state");break}}return n===2&&t(`Unfinished custom RegExp for param "${u}"`),d(),i(),r}function dj(e,t,n){const o=sj(cj(e.path),n),r=Qt(o,{record:e,parent:t,children:[],alias:[]});return t&&!r.record.aliasOf==!t.record.aliasOf&&t.children.push(r),r}function fj(e,t){const n=[],o=new Map;t=d6({strict:!1,end:!0,sensitive:!1},t);function r(c){return o.get(c)}function s(c,d,f){const p=!f,h=pj(c);h.aliasOf=f&&f.record;const m=d6(t,c),y=[h];if("alias"in c){const _=typeof c.alias=="string"?[c.alias]:c.alias;for(const S of _)y.push(Qt({},h,{components:f?f.record.components:h.components,path:S,aliasOf:f?f.record:h}))}let v,w;for(const _ of y){const{path:S}=_;if(d&&S[0]!=="/"){const x=d.record.path,E=x[x.length-1]==="/"?"":"/";_.path=d.record.path+(S&&E+S)}if(v=dj(_,d,m),f?f.alias.push(v):(w=w||v,w!==v&&w.alias.push(v),p&&c.name&&!c6(v)&&i(c.name)),h.children){const x=h.children;for(let E=0;E<x.length;E++)s(x[E],v,f&&f.children[E])}f=f||v,(v.record.components&&Object.keys(v.record.components).length||v.record.name||v.record.redirect)&&a(v)}return w?()=>{i(w)}:Vf}function i(c){if(lx(c)){const d=o.get(c);d&&(o.delete(c),n.splice(n.indexOf(d),1),d.children.forEach(i),d.alias.forEach(i))}else{const d=n.indexOf(c);d>-1&&(n.splice(d,1),c.record.name&&o.delete(c.record.name),c.children.forEach(i),c.alias.forEach(i))}}function l(){return n}function a(c){let d=0;for(;d<n.length&&lj(c,n[d])>=0&&(c.record.path!==n[d].record.path||!ux(c,n[d]));)d++;n.splice(d,0,c),c.record.name&&!c6(c)&&o.set(c.record.name,c)}function u(c,d){let f,p={},h,m;if("name"in c&&c.name){if(f=o.get(c.name),!f)throw qc(1,{location:c});m=f.record.name,p=Qt(u6(d.params,f.keys.filter(w=>!w.optional).concat(f.parent?f.parent.keys.filter(w=>w.optional):[]).map(w=>w.name)),c.params&&u6(c.params,f.keys.map(w=>w.name))),h=f.stringify(p)}else if(c.path!=null)h=c.path,f=n.find(w=>w.re.test(h)),f&&(p=f.parse(h),m=f.record.name);else{if(f=d.name?o.get(d.name):n.find(w=>w.re.test(d.path)),!f)throw qc(1,{location:c,currentLocation:d});m=f.record.name,p=Qt({},d.params,c.params),h=f.stringify(p)}const y=[];let v=f;for(;v;)y.unshift(v.record),v=v.parent;return{name:m,path:h,params:p,matched:y,meta:mj(y)}}return e.forEach(c=>s(c)),{addRoute:s,resolve:u,removeRoute:i,getRoutes:l,getRecordMatcher:r}}function u6(e,t){const n={};for(const o of t)o in e&&(n[o]=e[o]);return n}function pj(e){return{path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:void 0,beforeEnter:e.beforeEnter,props:hj(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}}}function hj(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const o in e.components)t[o]=typeof n=="object"?n[o]:n;return t}function c6(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function mj(e){return e.reduce((t,n)=>Qt(t,n.meta),{})}function d6(e,t){const n={};for(const o in e)n[o]=o in t?t[o]:e[o];return n}function ux(e,t){return t.children.some(n=>n===e||ux(e,n))}function gj(e){const t={};if(e===""||e==="?")return t;const o=(e[0]==="?"?e.slice(1):e).split("&");for(let r=0;r<o.length;++r){const s=o[r].replace(ex," "),i=s.indexOf("="),l=$p(i<0?s:s.slice(0,i)),a=i<0?null:$p(s.slice(i+1));if(l in t){let u=t[l];ms(u)||(u=t[l]=[u]),u.push(a)}else t[l]=a}return t}function f6(e){let t="";for(let n in e){const o=e[n];if(n=Rz(n),o==null){o!==void 0&&(t+=(t.length?"&":"")+n);continue}(ms(o)?o.map(s=>s&&R_(s)):[o&&R_(o)]).forEach(s=>{s!==void 0&&(t+=(t.length?"&":"")+n,s!=null&&(t+="="+s))})}return t}function vj(e){const t={};for(const n in e){const o=e[n];o!==void 0&&(t[n]=ms(o)?o.map(r=>r==null?null:""+r):o==null?o:""+o)}return t}const yj=Symbol(""),p6=Symbol(""),jw=Symbol(""),cx=Symbol(""),F_=Symbol("");function jd(){let e=[];function t(o){return e.push(o),()=>{const r=e.indexOf(o);r>-1&&e.splice(r,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function yl(e,t,n,o,r,s=i=>i()){const i=o&&(o.enterCallbacks[r]=o.enterCallbacks[r]||[]);return()=>new Promise((l,a)=>{const u=f=>{f===!1?a(qc(4,{from:n,to:t})):f instanceof Error?a(f):nj(f)?a(qc(2,{from:t,to:f})):(i&&o.enterCallbacks[r]===i&&typeof f=="function"&&i.push(f),l())},c=s(()=>e.call(o&&o.instances[r],t,n,u));let d=Promise.resolve(c);e.length<3&&(d=d.then(u)),d.catch(f=>a(f))})}function Kv(e,t,n,o,r=s=>s()){const s=[];for(const i of e)for(const l in i.components){let a=i.components[l];if(!(t!=="beforeRouteEnter"&&!i.instances[l]))if(_j(a)){const c=(a.__vccOpts||a)[t];c&&s.push(yl(c,n,o,i,l,r))}else{let u=a();s.push(()=>u.then(c=>{if(!c)return Promise.reject(new Error(`Couldn't resolve component "${l}" at "${i.path}"`));const d=$z(c)?c.default:c;i.components[l]=d;const p=(d.__vccOpts||d)[t];return p&&yl(p,n,o,i,l,r)()}))}}return s}function _j(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function h6(e){const t=Be(jw),n=Be(cx),o=R(()=>{const a=g(e.to);return t.resolve(a)}),r=R(()=>{const{matched:a}=o.value,{length:u}=a,c=a[u-1],d=n.matched;if(!c||!d.length)return-1;const f=d.findIndex(Kc.bind(null,c));if(f>-1)return f;const p=m6(a[u-2]);return u>1&&m6(c)===p&&d[d.length-1].path!==p?d.findIndex(Kc.bind(null,a[u-2])):f}),s=R(()=>r.value>-1&&kj(n.params,o.value.params)),i=R(()=>r.value>-1&&r.value===n.matched.length-1&&rx(n.params,o.value.params));function l(a={}){return Cj(a)?t[g(e.replace)?"replace":"push"](g(e.to)).catch(Vf):Promise.resolve()}return{route:o,href:R(()=>o.value.href),isActive:s,isExactActive:i,navigate:l}}const bj=Q({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:h6,setup(e,{slots:t}){const n=Dn(h6(e)),{options:o}=Be(jw),r=R(()=>({[g6(e.activeClass,o.linkActiveClass,"router-link-active")]:n.isActive,[g6(e.exactActiveClass,o.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const s=t.default&&t.default(n);return e.custom?s:lt("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:r.value},s)}}}),wj=bj;function Cj(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){const t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function kj(e,t){for(const n in t){const o=t[n],r=e[n];if(typeof o=="string"){if(o!==r)return!1}else if(!ms(r)||r.length!==o.length||o.some((s,i)=>s!==r[i]))return!1}return!0}function m6(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const g6=(e,t,n)=>e??t??n,Sj=Q({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const o=Be(F_),r=R(()=>e.route||o.value),s=Be(p6,0),i=R(()=>{let u=g(s);const{matched:c}=r.value;let d;for(;(d=c[u])&&!d.components;)u++;return u}),l=R(()=>r.value.matched[i.value]);wt(p6,R(()=>i.value+1)),wt(yj,l),wt(F_,r);const a=K();return Te(()=>[a.value,l.value,e.name],([u,c,d],[f,p,h])=>{c&&(c.instances[d]=u,p&&p!==c&&u&&u===f&&(c.leaveGuards.size||(c.leaveGuards=p.leaveGuards),c.updateGuards.size||(c.updateGuards=p.updateGuards))),u&&c&&(!p||!Kc(c,p)||!f)&&(c.enterCallbacks[d]||[]).forEach(m=>m(u))},{flush:"post"}),()=>{const u=r.value,c=e.name,d=l.value,f=d&&d.components[c];if(!f)return v6(n.default,{Component:f,route:u});const p=d.props[c],h=p?p===!0?u.params:typeof p=="function"?p(u):p:null,y=lt(f,Qt({},h,t,{onVnodeUnmounted:v=>{v.component.isUnmounted&&(d.instances[c]=null)},ref:a}));return v6(n.default,{Component:y,route:u})||y}}});function v6(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const $j=Sj;function y6(e){const t=fj(e.routes,e),n=e.parseQuery||gj,o=e.stringifyQuery||f6,r=e.history,s=jd(),i=jd(),l=jd(),a=Tn(Yi);let u=Yi;Wu&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const c=Uv.bind(null,ee=>""+ee),d=Uv.bind(null,Fz),f=Uv.bind(null,$p);function p(ee,de){let ve,le;return lx(ee)?(ve=t.getRecordMatcher(ee),le=de):le=ee,t.addRoute(le,ve)}function h(ee){const de=t.getRecordMatcher(ee);de&&t.removeRoute(de)}function m(){return t.getRoutes().map(ee=>ee.record)}function y(ee){return!!t.getRecordMatcher(ee)}function v(ee,de){if(de=Qt({},de||a.value),typeof ee=="string"){const J=Wv(n,ee,de.path),ue=t.resolve({path:J.path},de),_e=r.createHref(J.fullPath);return Qt(J,ue,{params:f(ue.params),hash:$p(J.hash),redirectedFrom:void 0,href:_e})}let ve;if(ee.path!=null)ve=Qt({},ee,{path:Wv(n,ee.path,de.path).path});else{const J=Qt({},ee.params);for(const ue in J)J[ue]==null&&delete J[ue];ve=Qt({},ee,{params:d(J)}),de.params=d(de.params)}const le=t.resolve(ve,de),Ie=ee.hash||"";le.params=c(f(le.params));const Ge=zz(o,Qt({},ee,{hash:Lz(Ie),path:le.path})),G=r.createHref(Ge);return Qt({fullPath:Ge,hash:Ie,query:o===f6?vj(ee.query):ee.query||{}},le,{redirectedFrom:void 0,href:G})}function w(ee){return typeof ee=="string"?Wv(n,ee,a.value.path):Qt({},ee)}function _(ee,de){if(u!==ee)return qc(8,{from:de,to:ee})}function S(ee){return T(ee)}function x(ee){return S(Qt(w(ee),{replace:!0}))}function E(ee){const de=ee.matched[ee.matched.length-1];if(de&&de.redirect){const{redirect:ve}=de;let le=typeof ve=="function"?ve(ee):ve;return typeof le=="string"&&(le=le.includes("?")||le.includes("#")?le=w(le):{path:le},le.params={}),Qt({query:ee.query,hash:ee.hash,params:le.path!=null?{}:ee.params},le)}}function T(ee,de){const ve=u=v(ee),le=a.value,Ie=ee.state,Ge=ee.force,G=ee.replace===!0,J=E(ve);if(J)return T(Qt(w(J),{state:typeof J=="object"?Qt({},Ie,J.state):Ie,force:Ge,replace:G}),de||ve);const ue=ve;ue.redirectedFrom=de;let _e;return!Ge&&jz(o,le,ve)&&(_e=qc(16,{to:ue,from:le}),X(le,le,!0,!1)),(_e?Promise.resolve(_e):N(ue,le)).catch(ye=>ui(ye)?ui(ye,2)?ye:I(ye):H(ye,ue,le)).then(ye=>{if(ye){if(ui(ye,2))return T(Qt({replace:G},w(ye.to),{state:typeof ye.to=="object"?Qt({},Ie,ye.to.state):Ie,force:Ge}),de||ue)}else ye=B(ue,le,!0,G,Ie);return F(ue,le,ye),ye})}function O(ee,de){const ve=_(ee,de);return ve?Promise.reject(ve):Promise.resolve()}function P(ee){const de=ge.values().next().value;return de&&typeof de.runWithContext=="function"?de.runWithContext(ee):ee()}function N(ee,de){let ve;const[le,Ie,Ge]=Ej(ee,de);ve=Kv(le.reverse(),"beforeRouteLeave",ee,de);for(const J of le)J.leaveGuards.forEach(ue=>{ve.push(yl(ue,ee,de))});const G=O.bind(null,ee,de);return ve.push(G),xe(ve).then(()=>{ve=[];for(const J of s.list())ve.push(yl(J,ee,de));return ve.push(G),xe(ve)}).then(()=>{ve=Kv(Ie,"beforeRouteUpdate",ee,de);for(const J of Ie)J.updateGuards.forEach(ue=>{ve.push(yl(ue,ee,de))});return ve.push(G),xe(ve)}).then(()=>{ve=[];for(const J of Ge)if(J.beforeEnter)if(ms(J.beforeEnter))for(const ue of J.beforeEnter)ve.push(yl(ue,ee,de));else ve.push(yl(J.beforeEnter,ee,de));return ve.push(G),xe(ve)}).then(()=>(ee.matched.forEach(J=>J.enterCallbacks={}),ve=Kv(Ge,"beforeRouteEnter",ee,de,P),ve.push(G),xe(ve))).then(()=>{ve=[];for(const J of i.list())ve.push(yl(J,ee,de));return ve.push(G),xe(ve)}).catch(J=>ui(J,8)?J:Promise.reject(J))}function F(ee,de,ve){l.list().forEach(le=>P(()=>le(ee,de,ve)))}function B(ee,de,ve,le,Ie){const Ge=_(ee,de);if(Ge)return Ge;const G=de===Yi,J=Wu?history.state:{};ve&&(le||G?r.replace(ee.fullPath,Qt({scroll:G&&J&&J.scroll},Ie)):r.push(ee.fullPath,Ie)),a.value=ee,X(ee,de,ve,G),I()}let Y;function Z(){Y||(Y=r.listen((ee,de,ve)=>{if(!Oe.listening)return;const le=v(ee),Ie=E(le);if(Ie){T(Qt(Ie,{replace:!0}),le).catch(Vf);return}u=le;const Ge=a.value;Wu&&Zz(r6(Ge.fullPath,ve.delta),E0()),N(le,Ge).catch(G=>ui(G,12)?G:ui(G,2)?(T(G.to,le).then(J=>{ui(J,20)&&!ve.delta&&ve.type===Ep.pop&&r.go(-1,!1)}).catch(Vf),Promise.reject()):(ve.delta&&r.go(-ve.delta,!1),H(G,le,Ge))).then(G=>{G=G||B(le,Ge,!1),G&&(ve.delta&&!ui(G,8)?r.go(-ve.delta,!1):ve.type===Ep.pop&&ui(G,20)&&r.go(-1,!1)),F(le,Ge,G)}).catch(Vf)}))}let U=jd(),j=jd(),V;function H(ee,de,ve){I(ee);const le=j.list();return le.length?le.forEach(Ie=>Ie(ee,de,ve)):console.error(ee),Promise.reject(ee)}function L(){return V&&a.value!==Yi?Promise.resolve():new Promise((ee,de)=>{U.add([ee,de])})}function I(ee){return V||(V=!ee,Z(),U.list().forEach(([de,ve])=>ee?ve(ee):de()),U.reset()),ee}function X(ee,de,ve,le){const{scrollBehavior:Ie}=e;if(!Wu||!Ie)return Promise.resolve();const Ge=!ve&&Jz(r6(ee.fullPath,0))||(le||!ve)&&history.state&&history.state.scroll||null;return ot().then(()=>Ie(ee,de,Ge)).then(G=>G&&Yz(G)).catch(G=>H(G,ee,de))}const oe=ee=>r.go(ee);let z;const ge=new Set,Oe={currentRoute:a,listening:!0,addRoute:p,removeRoute:h,hasRoute:y,getRoutes:m,resolve:v,options:e,push:S,replace:x,go:oe,back:()=>oe(-1),forward:()=>oe(1),beforeEach:s.add,beforeResolve:i.add,afterEach:l.add,onError:j.add,isReady:L,install(ee){const de=this;ee.component("RouterLink",wj),ee.component("RouterView",$j),ee.config.globalProperties.$router=de,Object.defineProperty(ee.config.globalProperties,"$route",{enumerable:!0,get:()=>g(a)}),Wu&&!z&&a.value===Yi&&(z=!0,S(r.location).catch(Ie=>{}));const ve={};for(const Ie in Yi)Object.defineProperty(ve,Ie,{get:()=>a.value[Ie],enumerable:!0});ee.provide(jw,de),ee.provide(cx,ow(ve)),ee.provide(F_,a);const le=ee.unmount;ge.add(ee),ee.unmount=function(){ge.delete(ee),ge.size<1&&(u=Yi,Y&&Y(),Y=null,a.value=Yi,z=!1,V=!1),le()}}};function xe(ee){return ee.reduce((de,ve)=>de.then(()=>P(ve)),Promise.resolve())}return Oe}function Ej(e,t){const n=[],o=[],r=[],s=Math.max(t.matched.length,e.matched.length);for(let i=0;i<s;i++){const l=t.matched[i];l&&(e.matched.find(u=>Kc(u,l))?o.push(l):n.push(l));const a=e.matched[i];a&&(t.matched.find(u=>Kc(u,a))||r.push(a))}return[n,o,r]}const xj='a[href],button:not([disabled]),button:not([hidden]),:not([tabindex="-1"]),input:not([disabled]),input:not([type="hidden"]),select:not([disabled]),textarea:not([disabled])',Mj=e=>getComputedStyle(e).position==="fixed"?!1:e.offsetParent!==null,_6=e=>Array.from(e.querySelectorAll(xj)).filter(t=>Tj(t)&&Mj(t)),Tj=e=>{if(e.tabIndex>0||e.tabIndex===0&&e.getAttribute("tabIndex")!==null)return!0;if(e.disabled)return!1;switch(e.nodeName){case"A":return!!e.href&&e.rel!=="ignore";case"INPUT":return!(e.type==="hidden"||e.type==="file");case"BUTTON":case"SELECT":case"TEXTAREA":return!0;default:return!1}},Nn=(e,t,{checkForDefaultPrevented:n=!0}={})=>r=>{const s=e==null?void 0:e(r);if(n===!1||!s)return t==null?void 0:t(r)},b6=e=>t=>t.pointerType==="mouse"?e(t):void 0;var Oj=Object.defineProperty,Ij=Object.defineProperties,Aj=Object.getOwnPropertyDescriptors,w6=Object.getOwnPropertySymbols,Nj=Object.prototype.hasOwnProperty,Pj=Object.prototype.propertyIsEnumerable,C6=(e,t,n)=>t in e?Oj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Lj=(e,t)=>{for(var n in t||(t={}))Nj.call(t,n)&&C6(e,n,t[n]);if(w6)for(var n of w6(t))Pj.call(t,n)&&C6(e,n,t[n]);return e},Rj=(e,t)=>Ij(e,Aj(t));function k6(e,t){var n;const o=Tn();return ls(()=>{o.value=e()},Rj(Lj({},t),{flush:(n=t==null?void 0:t.flush)!=null?n:"sync"})),_u(o)}var S6;const xt=typeof window<"u",Dj=e=>typeof e<"u",Fj=e=>typeof e=="function",Vj=e=>typeof e=="string",Gc=()=>{},Bj=xt&&((S6=window==null?void 0:window.navigator)==null?void 0:S6.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function Yc(e){return typeof e=="function"?e():g(e)}function dx(e,t){function n(...o){return new Promise((r,s)=>{Promise.resolve(e(()=>t.apply(this,o),{fn:t,thisArg:this,args:o})).then(r).catch(s)})}return n}function zj(e,t={}){let n,o,r=Gc;const s=l=>{clearTimeout(l),r(),r=Gc};return l=>{const a=Yc(e),u=Yc(t.maxWait);return n&&s(n),a<=0||u!==void 0&&u<=0?(o&&(s(o),o=null),Promise.resolve(l())):new Promise((c,d)=>{r=t.rejectOnCancel?d:c,u&&!o&&(o=setTimeout(()=>{n&&s(n),o=null,c(l())},u)),n=setTimeout(()=>{o&&s(o),o=null,c(l())},a)})}}function jj(e,t=!0,n=!0,o=!1){let r=0,s,i=!0,l=Gc,a;const u=()=>{s&&(clearTimeout(s),s=void 0,l(),l=Gc)};return d=>{const f=Yc(e),p=Date.now()-r,h=()=>a=d();return u(),f<=0?(r=Date.now(),h()):(p>f&&(n||!i)?(r=Date.now(),h()):t&&(a=new Promise((m,y)=>{l=o?y:m,s=setTimeout(()=>{r=Date.now(),i=!0,m(h()),u()},Math.max(0,f-p))})),!n&&!s&&(s=setTimeout(()=>i=!0,f)),i=!1,a)}}function Hj(e){return e}function oh(e){return X2()?(Q2(e),!0):!1}function Uj(e,t=200,n={}){return dx(zj(t,n),e)}function Wj(e,t=200,n={}){const o=K(e.value),r=Uj(()=>{o.value=e.value},t,n);return Te(e,()=>r()),o}function Kj(e,t=200,n=!1,o=!0,r=!1){return dx(jj(t,n,o,r),e)}function qj(e,t=!0){at()?Ct(e):t?e():ot(e)}function V_(e,t,n={}){const{immediate:o=!0}=n,r=K(!1);let s=null;function i(){s&&(clearTimeout(s),s=null)}function l(){r.value=!1,i()}function a(...u){i(),r.value=!0,s=setTimeout(()=>{r.value=!1,s=null,e(...u)},Yc(t))}return o&&(r.value=!0,xt&&a()),oh(l),{isPending:_u(r),start:a,stop:l}}function ki(e){var t;const n=Yc(e);return(t=n==null?void 0:n.$el)!=null?t:n}const rh=xt?window:void 0,Gj=xt?window.document:void 0;function Ln(...e){let t,n,o,r;if(Vj(e[0])||Array.isArray(e[0])?([n,o,r]=e,t=rh):[t,n,o,r]=e,!t)return Gc;Array.isArray(n)||(n=[n]),Array.isArray(o)||(o=[o]);const s=[],i=()=>{s.forEach(c=>c()),s.length=0},l=(c,d,f,p)=>(c.addEventListener(d,f,p),()=>c.removeEventListener(d,f,p)),a=Te(()=>[ki(t),Yc(r)],([c,d])=>{i(),c&&s.push(...n.flatMap(f=>o.map(p=>l(c,f,p,d))))},{immediate:!0,flush:"post"}),u=()=>{a(),i()};return oh(u),u}let $6=!1;function fx(e,t,n={}){const{window:o=rh,ignore:r=[],capture:s=!0,detectIframe:i=!1}=n;if(!o)return;Bj&&!$6&&($6=!0,Array.from(o.document.body.children).forEach(f=>f.addEventListener("click",Gc)));let l=!0;const a=f=>r.some(p=>{if(typeof p=="string")return Array.from(o.document.querySelectorAll(p)).some(h=>h===f.target||f.composedPath().includes(h));{const h=ki(p);return h&&(f.target===h||f.composedPath().includes(h))}}),c=[Ln(o,"click",f=>{const p=ki(e);if(!(!p||p===f.target||f.composedPath().includes(p))){if(f.detail===0&&(l=!a(f)),!l){l=!0;return}t(f)}},{passive:!0,capture:s}),Ln(o,"pointerdown",f=>{const p=ki(e);p&&(l=!f.composedPath().includes(p)&&!a(f))},{passive:!0}),i&&Ln(o,"blur",f=>{var p;const h=ki(e);((p=o.document.activeElement)==null?void 0:p.tagName)==="IFRAME"&&!(h!=null&&h.contains(o.document.activeElement))&&t(f)})].filter(Boolean);return()=>c.forEach(f=>f())}function px(e,t=!1){const n=K(),o=()=>n.value=!!e();return o(),qj(o,t),n}function Yj(e){return JSON.parse(JSON.stringify(e))}const E6=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},x6="__vueuse_ssr_handlers__";E6[x6]=E6[x6]||{};function Zj({document:e=Gj}={}){if(!e)return K("visible");const t=K(e.visibilityState);return Ln(e,"visibilitychange",()=>{t.value=e.visibilityState}),t}var M6=Object.getOwnPropertySymbols,Jj=Object.prototype.hasOwnProperty,Xj=Object.prototype.propertyIsEnumerable,Qj=(e,t)=>{var n={};for(var o in e)Jj.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(e!=null&&M6)for(var o of M6(e))t.indexOf(o)<0&&Xj.call(e,o)&&(n[o]=e[o]);return n};function Bo(e,t,n={}){const o=n,{window:r=rh}=o,s=Qj(o,["window"]);let i;const l=px(()=>r&&"ResizeObserver"in r),a=()=>{i&&(i.disconnect(),i=void 0)},u=Te(()=>ki(e),d=>{a(),l.value&&r&&d&&(i=new ResizeObserver(t),i.observe(d,s))},{immediate:!0,flush:"post"}),c=()=>{a(),u()};return oh(c),{isSupported:l,stop:c}}var T6=Object.getOwnPropertySymbols,eH=Object.prototype.hasOwnProperty,tH=Object.prototype.propertyIsEnumerable,nH=(e,t)=>{var n={};for(var o in e)eH.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(e!=null&&T6)for(var o of T6(e))t.indexOf(o)<0&&tH.call(e,o)&&(n[o]=e[o]);return n};function oH(e,t,n={}){const o=n,{window:r=rh}=o,s=nH(o,["window"]);let i;const l=px(()=>r&&"MutationObserver"in r),a=()=>{i&&(i.disconnect(),i=void 0)},u=Te(()=>ki(e),d=>{a(),l.value&&r&&d&&(i=new MutationObserver(t),i.observe(d,s))},{immediate:!0}),c=()=>{a(),u()};return oh(c),{isSupported:l,stop:c}}var O6;(function(e){e.UP="UP",e.RIGHT="RIGHT",e.DOWN="DOWN",e.LEFT="LEFT",e.NONE="NONE"})(O6||(O6={}));var rH=Object.defineProperty,I6=Object.getOwnPropertySymbols,sH=Object.prototype.hasOwnProperty,iH=Object.prototype.propertyIsEnumerable,A6=(e,t,n)=>t in e?rH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,lH=(e,t)=>{for(var n in t||(t={}))sH.call(t,n)&&A6(e,n,t[n]);if(I6)for(var n of I6(t))iH.call(t,n)&&A6(e,n,t[n]);return e};const aH={easeInSine:[.12,0,.39,0],easeOutSine:[.61,1,.88,1],easeInOutSine:[.37,0,.63,1],easeInQuad:[.11,0,.5,0],easeOutQuad:[.5,1,.89,1],easeInOutQuad:[.45,0,.55,1],easeInCubic:[.32,0,.67,0],easeOutCubic:[.33,1,.68,1],easeInOutCubic:[.65,0,.35,1],easeInQuart:[.5,0,.75,0],easeOutQuart:[.25,1,.5,1],easeInOutQuart:[.76,0,.24,1],easeInQuint:[.64,0,.78,0],easeOutQuint:[.22,1,.36,1],easeInOutQuint:[.83,0,.17,1],easeInExpo:[.7,0,.84,0],easeOutExpo:[.16,1,.3,1],easeInOutExpo:[.87,0,.13,1],easeInCirc:[.55,0,1,.45],easeOutCirc:[0,.55,.45,1],easeInOutCirc:[.85,0,.15,1],easeInBack:[.36,0,.66,-.56],easeOutBack:[.34,1.56,.64,1],easeInOutBack:[.68,-.6,.32,1.6]};lH({linear:Hj},aH);function uH(e,t,n,o={}){var r,s,i;const{clone:l=!1,passive:a=!1,eventName:u,deep:c=!1,defaultValue:d}=o,f=at(),p=n||(f==null?void 0:f.emit)||((r=f==null?void 0:f.$emit)==null?void 0:r.bind(f))||((i=(s=f==null?void 0:f.proxy)==null?void 0:s.$emit)==null?void 0:i.bind(f==null?void 0:f.proxy));let h=u;t||(t="modelValue"),h=u||h||`update:${t.toString()}`;const m=v=>l?Fj(l)?l(v):Yj(v):v,y=()=>Dj(e[t])?m(e[t]):d;if(a){const v=y(),w=K(v);return Te(()=>e[t],_=>w.value=m(_)),Te(w,_=>{(_!==e[t]||c)&&p(h,_)},{deep:c}),w}else return R({get(){return y()},set(v){p(h,v)}})}function cH({window:e=rh}={}){if(!e)return K(!1);const t=K(e.document.hasFocus());return Ln(e,"blur",()=>{t.value=!1}),Ln(e,"focus",()=>{t.value=!0}),t}const dH=()=>xt&&/firefox/i.test(window.navigator.userAgent),fH=(e,t)=>{if(!xt||!e||!t)return!1;const n=e.getBoundingClientRect();let o;return t instanceof Element?o=t.getBoundingClientRect():o={top:0,right:window.innerWidth,bottom:window.innerHeight,left:0},n.top<o.bottom&&n.bottom>o.top&&n.right>o.left&&n.left<o.right},Hw=e=>{let t,n;return e.type==="touchend"?(n=e.changedTouches[0].clientY,t=e.changedTouches[0].clientX):e.type.startsWith("touch")?(n=e.touches[0].clientY,t=e.touches[0].clientX):(n=e.clientY,t=e.clientX),{clientX:t,clientY:n}};var pH=typeof global=="object"&&global&&global.Object===Object&&global;const hx=pH;var hH=typeof self=="object"&&self&&self.Object===Object&&self,mH=hx||hH||Function("return this")();const bs=mH;var gH=bs.Symbol;const Vr=gH;var mx=Object.prototype,vH=mx.hasOwnProperty,yH=mx.toString,Hd=Vr?Vr.toStringTag:void 0;function _H(e){var t=vH.call(e,Hd),n=e[Hd];try{e[Hd]=void 0;var o=!0}catch{}var r=yH.call(e);return o&&(t?e[Hd]=n:delete e[Hd]),r}var bH=Object.prototype,wH=bH.toString;function CH(e){return wH.call(e)}var kH="[object Null]",SH="[object Undefined]",N6=Vr?Vr.toStringTag:void 0;function wu(e){return e==null?e===void 0?SH:kH:N6&&N6 in Object(e)?_H(e):CH(e)}function Ks(e){return e!=null&&typeof e=="object"}var $H="[object Symbol]";function x0(e){return typeof e=="symbol"||Ks(e)&&wu(e)==$H}function gx(e,t){for(var n=-1,o=e==null?0:e.length,r=Array(o);++n<o;)r[n]=t(e[n],n,e);return r}var EH=Array.isArray;const Mo=EH;var xH=1/0,P6=Vr?Vr.prototype:void 0,L6=P6?P6.toString:void 0;function vx(e){if(typeof e=="string")return e;if(Mo(e))return gx(e,vx)+"";if(x0(e))return L6?L6.call(e):"";var t=e+"";return t=="0"&&1/e==-xH?"-0":t}var MH=/\s/;function TH(e){for(var t=e.length;t--&&MH.test(e.charAt(t)););return t}var OH=/^\s+/;function IH(e){return e&&e.slice(0,TH(e)+1).replace(OH,"")}function To(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var R6=0/0,AH=/^[-+]0x[0-9a-f]+$/i,NH=/^0b[01]+$/i,PH=/^0o[0-7]+$/i,LH=parseInt;function B_(e){if(typeof e=="number")return e;if(x0(e))return R6;if(To(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=To(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=IH(e);var n=NH.test(e);return n||PH.test(e)?LH(e.slice(2),n?2:8):AH.test(e)?R6:+e}var D6=1/0,RH=17976931348623157e292;function DH(e){if(!e)return e===0?e:0;if(e=B_(e),e===D6||e===-D6){var t=e<0?-1:1;return t*RH}return e===e?e:0}function FH(e){var t=DH(e),n=t%1;return t===t?n?t-n:t:0}function Uw(e){return e}var VH="[object AsyncFunction]",BH="[object Function]",zH="[object GeneratorFunction]",jH="[object Proxy]";function Ww(e){if(!To(e))return!1;var t=wu(e);return t==BH||t==zH||t==VH||t==jH}var HH=bs["__core-js_shared__"];const qv=HH;var F6=function(){var e=/[^.]+$/.exec(qv&&qv.keys&&qv.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function UH(e){return!!F6&&F6 in e}var WH=Function.prototype,KH=WH.toString;function Cu(e){if(e!=null){try{return KH.call(e)}catch{}try{return e+""}catch{}}return""}var qH=/[\\^$.*+?()[\]{}|]/g,GH=/^\[object .+?Constructor\]$/,YH=Function.prototype,ZH=Object.prototype,JH=YH.toString,XH=ZH.hasOwnProperty,QH=RegExp("^"+JH.call(XH).replace(qH,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function eU(e){if(!To(e)||UH(e))return!1;var t=Ww(e)?QH:GH;return t.test(Cu(e))}function tU(e,t){return e==null?void 0:e[t]}function ku(e,t){var n=tU(e,t);return eU(n)?n:void 0}var nU=ku(bs,"WeakMap");const z_=nU;var V6=Object.create,oU=function(){function e(){}return function(t){if(!To(t))return{};if(V6)return V6(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();const rU=oU;function sU(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function yx(e,t){var n=-1,o=e.length;for(t||(t=Array(o));++n<o;)t[n]=e[n];return t}var iU=800,lU=16,aU=Date.now;function uU(e){var t=0,n=0;return function(){var o=aU(),r=lU-(o-n);if(n=o,r>0){if(++t>=iU)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function cU(e){return function(){return e}}var dU=function(){try{var e=ku(Object,"defineProperty");return e({},"",{}),e}catch{}}();const $g=dU;var fU=$g?function(e,t){return $g(e,"toString",{configurable:!0,enumerable:!1,value:cU(t),writable:!0})}:Uw;const pU=fU;var hU=uU(pU);const _x=hU;function mU(e,t){for(var n=-1,o=e==null?0:e.length;++n<o&&t(e[n],n,e)!==!1;);return e}function gU(e,t,n,o){for(var r=e.length,s=n+(o?1:-1);o?s--:++s<r;)if(t(e[s],s,e))return s;return-1}var vU=9007199254740991,yU=/^(?:0|[1-9]\d*)$/;function M0(e,t){var n=typeof e;return t=t??vU,!!t&&(n=="number"||n!="symbol"&&yU.test(e))&&e>-1&&e%1==0&&e<t}function Kw(e,t,n){t=="__proto__"&&$g?$g(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function sh(e,t){return e===t||e!==e&&t!==t}var _U=Object.prototype,bU=_U.hasOwnProperty;function qw(e,t,n){var o=e[t];(!(bU.call(e,t)&&sh(o,n))||n===void 0&&!(t in e))&&Kw(e,t,n)}function ih(e,t,n,o){var r=!n;n||(n={});for(var s=-1,i=t.length;++s<i;){var l=t[s],a=o?o(n[l],e[l],l,n,e):void 0;a===void 0&&(a=e[l]),r?Kw(n,l,a):qw(n,l,a)}return n}var B6=Math.max;function bx(e,t,n){return t=B6(t===void 0?e.length-1:t,0),function(){for(var o=arguments,r=-1,s=B6(o.length-t,0),i=Array(s);++r<s;)i[r]=o[t+r];r=-1;for(var l=Array(t+1);++r<t;)l[r]=o[r];return l[t]=n(i),sU(e,this,l)}}function wU(e,t){return _x(bx(e,t,Uw),e+"")}var CU=9007199254740991;function Gw(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=CU}function bd(e){return e!=null&&Gw(e.length)&&!Ww(e)}function kU(e,t,n){if(!To(n))return!1;var o=typeof t;return(o=="number"?bd(n)&&M0(t,n.length):o=="string"&&t in n)?sh(n[t],e):!1}function SU(e){return wU(function(t,n){var o=-1,r=n.length,s=r>1?n[r-1]:void 0,i=r>2?n[2]:void 0;for(s=e.length>3&&typeof s=="function"?(r--,s):void 0,i&&kU(n[0],n[1],i)&&(s=r<3?void 0:s,r=1),t=Object(t);++o<r;){var l=n[o];l&&e(t,l,o,s)}return t})}var $U=Object.prototype;function Yw(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||$U;return e===n}function EU(e,t){for(var n=-1,o=Array(e);++n<e;)o[n]=t(n);return o}var xU="[object Arguments]";function z6(e){return Ks(e)&&wu(e)==xU}var wx=Object.prototype,MU=wx.hasOwnProperty,TU=wx.propertyIsEnumerable,OU=z6(function(){return arguments}())?z6:function(e){return Ks(e)&&MU.call(e,"callee")&&!TU.call(e,"callee")};const xp=OU;function IU(){return!1}var Cx=typeof fr=="object"&&fr&&!fr.nodeType&&fr,j6=Cx&&typeof pr=="object"&&pr&&!pr.nodeType&&pr,AU=j6&&j6.exports===Cx,H6=AU?bs.Buffer:void 0,NU=H6?H6.isBuffer:void 0,PU=NU||IU;const Mp=PU;var LU="[object Arguments]",RU="[object Array]",DU="[object Boolean]",FU="[object Date]",VU="[object Error]",BU="[object Function]",zU="[object Map]",jU="[object Number]",HU="[object Object]",UU="[object RegExp]",WU="[object Set]",KU="[object String]",qU="[object WeakMap]",GU="[object ArrayBuffer]",YU="[object DataView]",ZU="[object Float32Array]",JU="[object Float64Array]",XU="[object Int8Array]",QU="[object Int16Array]",eW="[object Int32Array]",tW="[object Uint8Array]",nW="[object Uint8ClampedArray]",oW="[object Uint16Array]",rW="[object Uint32Array]",cn={};cn[ZU]=cn[JU]=cn[XU]=cn[QU]=cn[eW]=cn[tW]=cn[nW]=cn[oW]=cn[rW]=!0;cn[LU]=cn[RU]=cn[GU]=cn[DU]=cn[YU]=cn[FU]=cn[VU]=cn[BU]=cn[zU]=cn[jU]=cn[HU]=cn[UU]=cn[WU]=cn[KU]=cn[qU]=!1;function sW(e){return Ks(e)&&Gw(e.length)&&!!cn[wu(e)]}function Zw(e){return function(t){return e(t)}}var kx=typeof fr=="object"&&fr&&!fr.nodeType&&fr,zf=kx&&typeof pr=="object"&&pr&&!pr.nodeType&&pr,iW=zf&&zf.exports===kx,Gv=iW&&hx.process,lW=function(){try{var e=zf&&zf.require&&zf.require("util").types;return e||Gv&&Gv.binding&&Gv.binding("util")}catch{}}();const Zc=lW;var U6=Zc&&Zc.isTypedArray,aW=U6?Zw(U6):sW;const Jw=aW;var uW=Object.prototype,cW=uW.hasOwnProperty;function Sx(e,t){var n=Mo(e),o=!n&&xp(e),r=!n&&!o&&Mp(e),s=!n&&!o&&!r&&Jw(e),i=n||o||r||s,l=i?EU(e.length,String):[],a=l.length;for(var u in e)(t||cW.call(e,u))&&!(i&&(u=="length"||r&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||M0(u,a)))&&l.push(u);return l}function $x(e,t){return function(n){return e(t(n))}}var dW=$x(Object.keys,Object);const fW=dW;var pW=Object.prototype,hW=pW.hasOwnProperty;function mW(e){if(!Yw(e))return fW(e);var t=[];for(var n in Object(e))hW.call(e,n)&&n!="constructor"&&t.push(n);return t}function lh(e){return bd(e)?Sx(e):mW(e)}function gW(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var vW=Object.prototype,yW=vW.hasOwnProperty;function _W(e){if(!To(e))return gW(e);var t=Yw(e),n=[];for(var o in e)o=="constructor"&&(t||!yW.call(e,o))||n.push(o);return n}function ah(e){return bd(e)?Sx(e,!0):_W(e)}var bW=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,wW=/^\w*$/;function Xw(e,t){if(Mo(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||x0(e)?!0:wW.test(e)||!bW.test(e)||t!=null&&e in Object(t)}var CW=ku(Object,"create");const Tp=CW;function kW(){this.__data__=Tp?Tp(null):{},this.size=0}function SW(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var $W="__lodash_hash_undefined__",EW=Object.prototype,xW=EW.hasOwnProperty;function MW(e){var t=this.__data__;if(Tp){var n=t[e];return n===$W?void 0:n}return xW.call(t,e)?t[e]:void 0}var TW=Object.prototype,OW=TW.hasOwnProperty;function IW(e){var t=this.__data__;return Tp?t[e]!==void 0:OW.call(t,e)}var AW="__lodash_hash_undefined__";function NW(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Tp&&t===void 0?AW:t,this}function iu(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}iu.prototype.clear=kW;iu.prototype.delete=SW;iu.prototype.get=MW;iu.prototype.has=IW;iu.prototype.set=NW;function PW(){this.__data__=[],this.size=0}function T0(e,t){for(var n=e.length;n--;)if(sh(e[n][0],t))return n;return-1}var LW=Array.prototype,RW=LW.splice;function DW(e){var t=this.__data__,n=T0(t,e);if(n<0)return!1;var o=t.length-1;return n==o?t.pop():RW.call(t,n,1),--this.size,!0}function FW(e){var t=this.__data__,n=T0(t,e);return n<0?void 0:t[n][1]}function VW(e){return T0(this.__data__,e)>-1}function BW(e,t){var n=this.__data__,o=T0(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}function Vi(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}Vi.prototype.clear=PW;Vi.prototype.delete=DW;Vi.prototype.get=FW;Vi.prototype.has=VW;Vi.prototype.set=BW;var zW=ku(bs,"Map");const Op=zW;function jW(){this.size=0,this.__data__={hash:new iu,map:new(Op||Vi),string:new iu}}function HW(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function O0(e,t){var n=e.__data__;return HW(t)?n[typeof t=="string"?"string":"hash"]:n.map}function UW(e){var t=O0(this,e).delete(e);return this.size-=t?1:0,t}function WW(e){return O0(this,e).get(e)}function KW(e){return O0(this,e).has(e)}function qW(e,t){var n=O0(this,e),o=n.size;return n.set(e,t),this.size+=n.size==o?0:1,this}function Bi(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var o=e[t];this.set(o[0],o[1])}}Bi.prototype.clear=jW;Bi.prototype.delete=UW;Bi.prototype.get=WW;Bi.prototype.has=KW;Bi.prototype.set=qW;var GW="Expected a function";function Qw(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(GW);var n=function(){var o=arguments,r=t?t.apply(this,o):o[0],s=n.cache;if(s.has(r))return s.get(r);var i=e.apply(this,o);return n.cache=s.set(r,i)||s,i};return n.cache=new(Qw.Cache||Bi),n}Qw.Cache=Bi;var YW=500;function ZW(e){var t=Qw(e,function(o){return n.size===YW&&n.clear(),o}),n=t.cache;return t}var JW=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,XW=/\\(\\)?/g,QW=ZW(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(JW,function(n,o,r,s){t.push(r?s.replace(XW,"$1"):o||n)}),t});const eK=QW;function tK(e){return e==null?"":vx(e)}function I0(e,t){return Mo(e)?e:Xw(e,t)?[e]:eK(tK(e))}var nK=1/0;function uh(e){if(typeof e=="string"||x0(e))return e;var t=e+"";return t=="0"&&1/e==-nK?"-0":t}function e3(e,t){t=I0(t,e);for(var n=0,o=t.length;e!=null&&n<o;)e=e[uh(t[n++])];return n&&n==o?e:void 0}function Tr(e,t,n){var o=e==null?void 0:e3(e,t);return o===void 0?n:o}function t3(e,t){for(var n=-1,o=t.length,r=e.length;++n<o;)e[r+n]=t[n];return e}var W6=Vr?Vr.isConcatSpreadable:void 0;function oK(e){return Mo(e)||xp(e)||!!(W6&&e&&e[W6])}function n3(e,t,n,o,r){var s=-1,i=e.length;for(n||(n=oK),r||(r=[]);++s<i;){var l=e[s];t>0&&n(l)?t>1?n3(l,t-1,n,o,r):t3(r,l):o||(r[r.length]=l)}return r}function Ex(e){var t=e==null?0:e.length;return t?n3(e,1):[]}function rK(e){return _x(bx(e,void 0,Ex),e+"")}var sK=$x(Object.getPrototypeOf,Object);const o3=sK;var iK="[object Object]",lK=Function.prototype,aK=Object.prototype,xx=lK.toString,uK=aK.hasOwnProperty,cK=xx.call(Object);function dK(e){if(!Ks(e)||wu(e)!=iK)return!1;var t=o3(e);if(t===null)return!0;var n=uK.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&xx.call(n)==cK}function Eg(){if(!arguments.length)return[];var e=arguments[0];return Mo(e)?e:[e]}function fK(){this.__data__=new Vi,this.size=0}function pK(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function hK(e){return this.__data__.get(e)}function mK(e){return this.__data__.has(e)}var gK=200;function vK(e,t){var n=this.__data__;if(n instanceof Vi){var o=n.__data__;if(!Op||o.length<gK-1)return o.push([e,t]),this.size=++n.size,this;n=this.__data__=new Bi(o)}return n.set(e,t),this.size=n.size,this}function us(e){var t=this.__data__=new Vi(e);this.size=t.size}us.prototype.clear=fK;us.prototype.delete=pK;us.prototype.get=hK;us.prototype.has=mK;us.prototype.set=vK;function yK(e,t){return e&&ih(t,lh(t),e)}function _K(e,t){return e&&ih(t,ah(t),e)}var Mx=typeof fr=="object"&&fr&&!fr.nodeType&&fr,K6=Mx&&typeof pr=="object"&&pr&&!pr.nodeType&&pr,bK=K6&&K6.exports===Mx,q6=bK?bs.Buffer:void 0,G6=q6?q6.allocUnsafe:void 0;function Tx(e,t){if(t)return e.slice();var n=e.length,o=G6?G6(n):new e.constructor(n);return e.copy(o),o}function wK(e,t){for(var n=-1,o=e==null?0:e.length,r=0,s=[];++n<o;){var i=e[n];t(i,n,e)&&(s[r++]=i)}return s}function Ox(){return[]}var CK=Object.prototype,kK=CK.propertyIsEnumerable,Y6=Object.getOwnPropertySymbols,SK=Y6?function(e){return e==null?[]:(e=Object(e),wK(Y6(e),function(t){return kK.call(e,t)}))}:Ox;const r3=SK;function $K(e,t){return ih(e,r3(e),t)}var EK=Object.getOwnPropertySymbols,xK=EK?function(e){for(var t=[];e;)t3(t,r3(e)),e=o3(e);return t}:Ox;const Ix=xK;function MK(e,t){return ih(e,Ix(e),t)}function Ax(e,t,n){var o=t(e);return Mo(e)?o:t3(o,n(e))}function j_(e){return Ax(e,lh,r3)}function TK(e){return Ax(e,ah,Ix)}var OK=ku(bs,"DataView");const H_=OK;var IK=ku(bs,"Promise");const U_=IK;var AK=ku(bs,"Set");const W_=AK;var Z6="[object Map]",NK="[object Object]",J6="[object Promise]",X6="[object Set]",Q6="[object WeakMap]",e5="[object DataView]",PK=Cu(H_),LK=Cu(Op),RK=Cu(U_),DK=Cu(W_),FK=Cu(z_),va=wu;(H_&&va(new H_(new ArrayBuffer(1)))!=e5||Op&&va(new Op)!=Z6||U_&&va(U_.resolve())!=J6||W_&&va(new W_)!=X6||z_&&va(new z_)!=Q6)&&(va=function(e){var t=wu(e),n=t==NK?e.constructor:void 0,o=n?Cu(n):"";if(o)switch(o){case PK:return e5;case LK:return Z6;case RK:return J6;case DK:return X6;case FK:return Q6}return t});const Ip=va;var VK=Object.prototype,BK=VK.hasOwnProperty;function zK(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]=="string"&&BK.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var jK=bs.Uint8Array;const xg=jK;function s3(e){var t=new e.constructor(e.byteLength);return new xg(t).set(new xg(e)),t}function HK(e,t){var n=t?s3(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var UK=/\w*$/;function WK(e){var t=new e.constructor(e.source,UK.exec(e));return t.lastIndex=e.lastIndex,t}var t5=Vr?Vr.prototype:void 0,n5=t5?t5.valueOf:void 0;function KK(e){return n5?Object(n5.call(e)):{}}function Nx(e,t){var n=t?s3(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var qK="[object Boolean]",GK="[object Date]",YK="[object Map]",ZK="[object Number]",JK="[object RegExp]",XK="[object Set]",QK="[object String]",eq="[object Symbol]",tq="[object ArrayBuffer]",nq="[object DataView]",oq="[object Float32Array]",rq="[object Float64Array]",sq="[object Int8Array]",iq="[object Int16Array]",lq="[object Int32Array]",aq="[object Uint8Array]",uq="[object Uint8ClampedArray]",cq="[object Uint16Array]",dq="[object Uint32Array]";function fq(e,t,n){var o=e.constructor;switch(t){case tq:return s3(e);case qK:case GK:return new o(+e);case nq:return HK(e,n);case oq:case rq:case sq:case iq:case lq:case aq:case uq:case cq:case dq:return Nx(e,n);case YK:return new o;case ZK:case QK:return new o(e);case JK:return WK(e);case XK:return new o;case eq:return KK(e)}}function Px(e){return typeof e.constructor=="function"&&!Yw(e)?rU(o3(e)):{}}var pq="[object Map]";function hq(e){return Ks(e)&&Ip(e)==pq}var o5=Zc&&Zc.isMap,mq=o5?Zw(o5):hq;const gq=mq;var vq="[object Set]";function yq(e){return Ks(e)&&Ip(e)==vq}var r5=Zc&&Zc.isSet,_q=r5?Zw(r5):yq;const bq=_q;var wq=1,Cq=2,kq=4,Lx="[object Arguments]",Sq="[object Array]",$q="[object Boolean]",Eq="[object Date]",xq="[object Error]",Rx="[object Function]",Mq="[object GeneratorFunction]",Tq="[object Map]",Oq="[object Number]",Dx="[object Object]",Iq="[object RegExp]",Aq="[object Set]",Nq="[object String]",Pq="[object Symbol]",Lq="[object WeakMap]",Rq="[object ArrayBuffer]",Dq="[object DataView]",Fq="[object Float32Array]",Vq="[object Float64Array]",Bq="[object Int8Array]",zq="[object Int16Array]",jq="[object Int32Array]",Hq="[object Uint8Array]",Uq="[object Uint8ClampedArray]",Wq="[object Uint16Array]",Kq="[object Uint32Array]",ln={};ln[Lx]=ln[Sq]=ln[Rq]=ln[Dq]=ln[$q]=ln[Eq]=ln[Fq]=ln[Vq]=ln[Bq]=ln[zq]=ln[jq]=ln[Tq]=ln[Oq]=ln[Dx]=ln[Iq]=ln[Aq]=ln[Nq]=ln[Pq]=ln[Hq]=ln[Uq]=ln[Wq]=ln[Kq]=!0;ln[xq]=ln[Rx]=ln[Lq]=!1;function jf(e,t,n,o,r,s){var i,l=t&wq,a=t&Cq,u=t&kq;if(n&&(i=r?n(e,o,r,s):n(e)),i!==void 0)return i;if(!To(e))return e;var c=Mo(e);if(c){if(i=zK(e),!l)return yx(e,i)}else{var d=Ip(e),f=d==Rx||d==Mq;if(Mp(e))return Tx(e,l);if(d==Dx||d==Lx||f&&!r){if(i=a||f?{}:Px(e),!l)return a?MK(e,_K(i,e)):$K(e,yK(i,e))}else{if(!ln[d])return r?e:{};i=fq(e,d,l)}}s||(s=new us);var p=s.get(e);if(p)return p;s.set(e,i),bq(e)?e.forEach(function(y){i.add(jf(y,t,n,y,e,s))}):gq(e)&&e.forEach(function(y,v){i.set(v,jf(y,t,n,v,e,s))});var h=u?a?TK:j_:a?ah:lh,m=c?void 0:h(e);return mU(m||e,function(y,v){m&&(v=y,y=e[v]),qw(i,v,jf(y,t,n,v,e,s))}),i}var qq=4;function s5(e){return jf(e,qq)}var Gq=1,Yq=4;function i5(e){return jf(e,Gq|Yq)}var Zq="__lodash_hash_undefined__";function Jq(e){return this.__data__.set(e,Zq),this}function Xq(e){return this.__data__.has(e)}function Mg(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new Bi;++t<n;)this.add(e[t])}Mg.prototype.add=Mg.prototype.push=Jq;Mg.prototype.has=Xq;function Qq(e,t){for(var n=-1,o=e==null?0:e.length;++n<o;)if(t(e[n],n,e))return!0;return!1}function eG(e,t){return e.has(t)}var tG=1,nG=2;function Fx(e,t,n,o,r,s){var i=n&tG,l=e.length,a=t.length;if(l!=a&&!(i&&a>l))return!1;var u=s.get(e),c=s.get(t);if(u&&c)return u==t&&c==e;var d=-1,f=!0,p=n&nG?new Mg:void 0;for(s.set(e,t),s.set(t,e);++d<l;){var h=e[d],m=t[d];if(o)var y=i?o(m,h,d,t,e,s):o(h,m,d,e,t,s);if(y!==void 0){if(y)continue;f=!1;break}if(p){if(!Qq(t,function(v,w){if(!eG(p,w)&&(h===v||r(h,v,n,o,s)))return p.push(w)})){f=!1;break}}else if(!(h===m||r(h,m,n,o,s))){f=!1;break}}return s.delete(e),s.delete(t),f}function oG(e){var t=-1,n=Array(e.size);return e.forEach(function(o,r){n[++t]=[r,o]}),n}function rG(e){var t=-1,n=Array(e.size);return e.forEach(function(o){n[++t]=o}),n}var sG=1,iG=2,lG="[object Boolean]",aG="[object Date]",uG="[object Error]",cG="[object Map]",dG="[object Number]",fG="[object RegExp]",pG="[object Set]",hG="[object String]",mG="[object Symbol]",gG="[object ArrayBuffer]",vG="[object DataView]",l5=Vr?Vr.prototype:void 0,Yv=l5?l5.valueOf:void 0;function yG(e,t,n,o,r,s,i){switch(n){case vG:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case gG:return!(e.byteLength!=t.byteLength||!s(new xg(e),new xg(t)));case lG:case aG:case dG:return sh(+e,+t);case uG:return e.name==t.name&&e.message==t.message;case fG:case hG:return e==t+"";case cG:var l=oG;case pG:var a=o&sG;if(l||(l=rG),e.size!=t.size&&!a)return!1;var u=i.get(e);if(u)return u==t;o|=iG,i.set(e,t);var c=Fx(l(e),l(t),o,r,s,i);return i.delete(e),c;case mG:if(Yv)return Yv.call(e)==Yv.call(t)}return!1}var _G=1,bG=Object.prototype,wG=bG.hasOwnProperty;function CG(e,t,n,o,r,s){var i=n&_G,l=j_(e),a=l.length,u=j_(t),c=u.length;if(a!=c&&!i)return!1;for(var d=a;d--;){var f=l[d];if(!(i?f in t:wG.call(t,f)))return!1}var p=s.get(e),h=s.get(t);if(p&&h)return p==t&&h==e;var m=!0;s.set(e,t),s.set(t,e);for(var y=i;++d<a;){f=l[d];var v=e[f],w=t[f];if(o)var _=i?o(w,v,f,t,e,s):o(v,w,f,e,t,s);if(!(_===void 0?v===w||r(v,w,n,o,s):_)){m=!1;break}y||(y=f=="constructor")}if(m&&!y){var S=e.constructor,x=t.constructor;S!=x&&"constructor"in e&&"constructor"in t&&!(typeof S=="function"&&S instanceof S&&typeof x=="function"&&x instanceof x)&&(m=!1)}return s.delete(e),s.delete(t),m}var kG=1,a5="[object Arguments]",u5="[object Array]",im="[object Object]",SG=Object.prototype,c5=SG.hasOwnProperty;function $G(e,t,n,o,r,s){var i=Mo(e),l=Mo(t),a=i?u5:Ip(e),u=l?u5:Ip(t);a=a==a5?im:a,u=u==a5?im:u;var c=a==im,d=u==im,f=a==u;if(f&&Mp(e)){if(!Mp(t))return!1;i=!0,c=!1}if(f&&!c)return s||(s=new us),i||Jw(e)?Fx(e,t,n,o,r,s):yG(e,t,a,n,o,r,s);if(!(n&kG)){var p=c&&c5.call(e,"__wrapped__"),h=d&&c5.call(t,"__wrapped__");if(p||h){var m=p?e.value():e,y=h?t.value():t;return s||(s=new us),r(m,y,n,o,s)}}return f?(s||(s=new us),CG(e,t,n,o,r,s)):!1}function A0(e,t,n,o,r){return e===t?!0:e==null||t==null||!Ks(e)&&!Ks(t)?e!==e&&t!==t:$G(e,t,n,o,A0,r)}var EG=1,xG=2;function MG(e,t,n,o){var r=n.length,s=r,i=!o;if(e==null)return!s;for(e=Object(e);r--;){var l=n[r];if(i&&l[2]?l[1]!==e[l[0]]:!(l[0]in e))return!1}for(;++r<s;){l=n[r];var a=l[0],u=e[a],c=l[1];if(i&&l[2]){if(u===void 0&&!(a in e))return!1}else{var d=new us;if(o)var f=o(u,c,a,e,t,d);if(!(f===void 0?A0(c,u,EG|xG,o,d):f))return!1}}return!0}function Vx(e){return e===e&&!To(e)}function TG(e){for(var t=lh(e),n=t.length;n--;){var o=t[n],r=e[o];t[n]=[o,r,Vx(r)]}return t}function Bx(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}function OG(e){var t=TG(e);return t.length==1&&t[0][2]?Bx(t[0][0],t[0][1]):function(n){return n===e||MG(n,e,t)}}function IG(e,t){return e!=null&&t in Object(e)}function AG(e,t,n){t=I0(t,e);for(var o=-1,r=t.length,s=!1;++o<r;){var i=uh(t[o]);if(!(s=e!=null&&n(e,i)))break;e=e[i]}return s||++o!=r?s:(r=e==null?0:e.length,!!r&&Gw(r)&&M0(i,r)&&(Mo(e)||xp(e)))}function zx(e,t){return e!=null&&AG(e,t,IG)}var NG=1,PG=2;function LG(e,t){return Xw(e)&&Vx(t)?Bx(uh(e),t):function(n){var o=Tr(n,e);return o===void 0&&o===t?zx(n,e):A0(t,o,NG|PG)}}function RG(e){return function(t){return t==null?void 0:t[e]}}function DG(e){return function(t){return e3(t,e)}}function FG(e){return Xw(e)?RG(uh(e)):DG(e)}function jx(e){return typeof e=="function"?e:e==null?Uw:typeof e=="object"?Mo(e)?LG(e[0],e[1]):OG(e):FG(e)}function VG(e){return function(t,n,o){for(var r=-1,s=Object(t),i=o(t),l=i.length;l--;){var a=i[e?l:++r];if(n(s[a],a,s)===!1)break}return t}}var BG=VG();const Hx=BG;function zG(e,t){return e&&Hx(e,t,lh)}function jG(e,t){return function(n,o){if(n==null)return n;if(!bd(n))return e(n,o);for(var r=n.length,s=t?r:-1,i=Object(n);(t?s--:++s<r)&&o(i[s],s,i)!==!1;);return n}}var HG=jG(zG);const UG=HG;var WG=function(){return bs.Date.now()};const Zv=WG;var KG="Expected a function",qG=Math.max,GG=Math.min;function zl(e,t,n){var o,r,s,i,l,a,u=0,c=!1,d=!1,f=!0;if(typeof e!="function")throw new TypeError(KG);t=B_(t)||0,To(n)&&(c=!!n.leading,d="maxWait"in n,s=d?qG(B_(n.maxWait)||0,t):s,f="trailing"in n?!!n.trailing:f);function p(E){var T=o,O=r;return o=r=void 0,u=E,i=e.apply(O,T),i}function h(E){return u=E,l=setTimeout(v,t),c?p(E):i}function m(E){var T=E-a,O=E-u,P=t-T;return d?GG(P,s-O):P}function y(E){var T=E-a,O=E-u;return a===void 0||T>=t||T<0||d&&O>=s}function v(){var E=Zv();if(y(E))return w(E);l=setTimeout(v,m(E))}function w(E){return l=void 0,f&&o?p(E):(o=r=void 0,i)}function _(){l!==void 0&&clearTimeout(l),u=0,o=a=r=l=void 0}function S(){return l===void 0?i:w(Zv())}function x(){var E=Zv(),T=y(E);if(o=arguments,r=this,a=E,T){if(l===void 0)return h(a);if(d)return clearTimeout(l),l=setTimeout(v,t),p(a)}return l===void 0&&(l=setTimeout(v,t)),i}return x.cancel=_,x.flush=S,x}function K_(e,t,n){(n!==void 0&&!sh(e[t],n)||n===void 0&&!(t in e))&&Kw(e,t,n)}function YG(e){return Ks(e)&&bd(e)}function q_(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function ZG(e){return ih(e,ah(e))}function JG(e,t,n,o,r,s,i){var l=q_(e,n),a=q_(t,n),u=i.get(a);if(u){K_(e,n,u);return}var c=s?s(l,a,n+"",e,t,i):void 0,d=c===void 0;if(d){var f=Mo(a),p=!f&&Mp(a),h=!f&&!p&&Jw(a);c=a,f||p||h?Mo(l)?c=l:YG(l)?c=yx(l):p?(d=!1,c=Tx(a,!0)):h?(d=!1,c=Nx(a,!0)):c=[]:dK(a)||xp(a)?(c=l,xp(l)?c=ZG(l):(!To(l)||Ww(l))&&(c=Px(a))):d=!1}d&&(i.set(a,c),r(c,a,o,s,i),i.delete(a)),K_(e,n,c)}function Ux(e,t,n,o,r){e!==t&&Hx(t,function(s,i){if(r||(r=new us),To(s))JG(e,t,i,n,Ux,o,r);else{var l=o?o(q_(e,i),s,i+"",e,t,r):void 0;l===void 0&&(l=s),K_(e,i,l)}},ah)}var XG=Math.max,QG=Math.min;function eY(e,t,n){var o=e==null?0:e.length;if(!o)return-1;var r=o-1;return n!==void 0&&(r=FH(n),r=n<0?XG(o+r,0):QG(r,o-1)),gU(e,jx(t),r,!0)}function tY(e,t){var n=-1,o=bd(e)?Array(e.length):[];return UG(e,function(r,s,i){o[++n]=t(r,s,i)}),o}function nY(e,t){var n=Mo(e)?gx:tY;return n(e,jx(t))}function oY(e,t){return n3(nY(e,t),1)}function Tg(e){for(var t=-1,n=e==null?0:e.length,o={};++t<n;){var r=e[t];o[r[0]]=r[1]}return o}function jl(e,t){return A0(e,t)}function xo(e){return e==null}function Wx(e){return e===void 0}var rY=SU(function(e,t,n){Ux(e,t,n)});const sY=rY;function Kx(e,t,n,o){if(!To(e))return e;t=I0(t,e);for(var r=-1,s=t.length,i=s-1,l=e;l!=null&&++r<s;){var a=uh(t[r]),u=n;if(a==="__proto__"||a==="constructor"||a==="prototype")return e;if(r!=i){var c=l[a];u=o?o(c,a,l):void 0,u===void 0&&(u=To(c)?c:M0(t[r+1])?[]:{})}qw(l,a,u),l=l[a]}return e}function iY(e,t,n){for(var o=-1,r=t.length,s={};++o<r;){var i=t[o],l=e3(e,i);n(l,i)&&Kx(s,I0(i,e),l)}return s}function lY(e,t){return iY(e,t,function(n,o){return zx(e,o)})}var aY=rK(function(e,t){return e==null?{}:lY(e,t)});const uY=aY;function cY(e,t,n){return e==null?e:Kx(e,t,n)}var dY="Expected a function";function Jv(e,t,n){var o=!0,r=!0;if(typeof e!="function")throw new TypeError(dY);return To(n)&&(o="leading"in n?!!n.leading:o,r="trailing"in n?!!n.trailing:r),zl(e,t,{leading:o,maxWait:t,trailing:r})}const Uo=e=>e===void 0,Br=e=>typeof e=="boolean",_t=e=>typeof e=="number",qx=e=>!e&&e!==0||Me(e)&&e.length===0||ft(e)&&!Object.keys(e).length,gs=e=>typeof Element>"u"?!1:e instanceof Element,Ap=e=>xo(e),fY=e=>tt(e)?!Number.isNaN(Number(e)):!1,pY=e=>xt?window.requestAnimationFrame(e):setTimeout(e,16),hY=(e="")=>e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d"),Cl=e=>ql(e),G_=e=>Object.keys(e),mY=e=>Object.entries(e),Km=(e,t,n)=>({get value(){return Tr(e,t,n)},set value(o){cY(e,t,o)}});class gY extends Error{constructor(t){super(t),this.name="ElementPlusError"}}function ws(e,t){throw new gY(`[${e}] ${t}`)}const Gx=(e="")=>e.split(" ").filter(t=>!!t.trim()),Ti=(e,t)=>{if(!e||!t)return!1;if(t.includes(" "))throw new Error("className should not contain space.");return e.classList.contains(t)},lu=(e,t)=>{!e||!t.trim()||e.classList.add(...Gx(t))},qs=(e,t)=>{!e||!t.trim()||e.classList.remove(...Gx(t))},kl=(e,t)=>{var n;if(!xt||!e||!t)return"";let o=yn(t);o==="float"&&(o="cssFloat");try{const r=e.style[o];if(r)return r;const s=(n=document.defaultView)==null?void 0:n.getComputedStyle(e,"");return s?s[o]:""}catch{return e.style[o]}};function Zo(e,t="px"){if(!e)return"";if(_t(e)||fY(e))return`${e}${t}`;if(tt(e))return e}const vY=(e,t)=>{if(!xt)return!1;const n={undefined:"overflow",true:"overflow-y",false:"overflow-x"}[String(t)],o=kl(e,n);return["scroll","auto","overlay"].some(r=>o.includes(r))},yY=(e,t)=>{if(!xt)return;let n=e;for(;n;){if([window,document,document.documentElement].includes(n))return window;if(vY(n,t))return n;n=n.parentNode}return n};let lm;const _Y=e=>{var t;if(!xt)return 0;if(lm!==void 0)return lm;const n=document.createElement("div");n.className=`${e}-scrollbar__wrap`,n.style.visibility="hidden",n.style.width="100px",n.style.position="absolute",n.style.top="-9999px",document.body.appendChild(n);const o=n.offsetWidth;n.style.overflow="scroll";const r=document.createElement("div");r.style.width="100%",n.appendChild(r);const s=r.offsetWidth;return(t=n.parentNode)==null||t.removeChild(n),lm=o-s,lm};function bY(e,t){if(!xt)return;if(!t){e.scrollTop=0;return}const n=[];let o=t.offsetParent;for(;o!==null&&e!==o&&e.contains(o);)n.push(o),o=o.offsetParent;const r=t.offsetTop+n.reduce((a,u)=>a+u.offsetTop,0),s=r+t.offsetHeight,i=e.scrollTop,l=i+e.clientHeight;r<i?e.scrollTop=r:s>l&&(e.scrollTop=s-e.clientHeight)}/*! Element Plus Icons Vue v2.3.1 */var wY=Q({name:"ArrowDown",__name:"arrow-down",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M831.872 340.864 512 652.672 192.128 340.864a30.592 30.592 0 0 0-42.752 0 29.12 29.12 0 0 0 0 41.6L489.664 714.24a32 32 0 0 0 44.672 0l340.288-331.712a29.12 29.12 0 0 0 0-41.728 30.592 30.592 0 0 0-42.752 0z"})]))}}),Su=wY,CY=Q({name:"ArrowLeft",__name:"arrow-left",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M609.408 149.376 277.76 489.6a32 32 0 0 0 0 44.672l331.648 340.352a29.12 29.12 0 0 0 41.728 0 30.592 30.592 0 0 0 0-42.752L339.264 511.936l311.872-319.872a30.592 30.592 0 0 0 0-42.688 29.12 29.12 0 0 0-41.728 0z"})]))}}),au=CY,kY=Q({name:"ArrowRight",__name:"arrow-right",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M340.864 149.312a30.592 30.592 0 0 0 0 42.752L652.736 512 340.864 831.872a30.592 30.592 0 0 0 0 42.752 29.12 29.12 0 0 0 41.728 0L714.24 534.336a32 32 0 0 0 0-44.672L382.592 149.376a29.12 29.12 0 0 0-41.728 0z"})]))}}),js=kY,SY=Q({name:"ArrowUp",__name:"arrow-up",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m488.832 344.32-339.84 356.672a32 32 0 0 0 0 44.16l.384.384a29.44 29.44 0 0 0 42.688 0l320-335.872 319.872 335.872a29.44 29.44 0 0 0 42.688 0l.384-.384a32 32 0 0 0 0-44.16L535.168 344.32a32 32 0 0 0-46.336 0"})]))}}),N0=SY,$Y=Q({name:"Avatar",__name:"avatar",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M628.736 528.896A416 416 0 0 1 928 928H96a415.872 415.872 0 0 1 299.264-399.104L512 704zM720 304a208 208 0 1 1-416 0 208 208 0 0 1 416 0"})]))}}),EY=$Y,xY=Q({name:"Back",__name:"back",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M224 480h640a32 32 0 1 1 0 64H224a32 32 0 0 1 0-64"}),b("path",{fill:"currentColor",d:"m237.248 512 265.408 265.344a32 32 0 0 1-45.312 45.312l-288-288a32 32 0 0 1 0-45.312l288-288a32 32 0 1 1 45.312 45.312z"})]))}}),MY=xY,TY=Q({name:"Bell",__name:"bell",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 64a64 64 0 0 1 64 64v64H448v-64a64 64 0 0 1 64-64"}),b("path",{fill:"currentColor",d:"M256 768h512V448a256 256 0 1 0-512 0zm256-640a320 320 0 0 1 320 320v384H192V448a320 320 0 0 1 320-320"}),b("path",{fill:"currentColor",d:"M96 768h832q32 0 32 32t-32 32H96q-32 0-32-32t32-32m352 128h128a64 64 0 0 1-128 0"})]))}}),OY=TY,IY=Q({name:"Bottom",__name:"bottom",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M544 805.888V168a32 32 0 1 0-64 0v637.888L246.656 557.952a30.72 30.72 0 0 0-45.312 0 35.52 35.52 0 0 0 0 48.064l288 306.048a30.72 30.72 0 0 0 45.312 0l288-306.048a35.52 35.52 0 0 0 0-48 30.72 30.72 0 0 0-45.312 0L544 805.824z"})]))}}),AY=IY,NY=Q({name:"Calendar",__name:"calendar",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M128 384v512h768V192H768v32a32 32 0 1 1-64 0v-32H320v32a32 32 0 0 1-64 0v-32H128v128h768v64zm192-256h384V96a32 32 0 1 1 64 0v32h160a32 32 0 0 1 32 32v768a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32h160V96a32 32 0 0 1 64 0zm-32 384h64a32 32 0 0 1 0 64h-64a32 32 0 0 1 0-64m0 192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64m192-192h64a32 32 0 0 1 0 64h-64a32 32 0 0 1 0-64m0 192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64m192-192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64m0 192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64"})]))}}),PY=NY,LY=Q({name:"CameraFilled",__name:"camera-filled",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M160 224a64 64 0 0 0-64 64v512a64 64 0 0 0 64 64h704a64 64 0 0 0 64-64V288a64 64 0 0 0-64-64H748.416l-46.464-92.672A64 64 0 0 0 644.736 96H379.328a64 64 0 0 0-57.216 35.392L275.776 224zm352 435.2a115.2 115.2 0 1 0 0-230.4 115.2 115.2 0 0 0 0 230.4m0 140.8a256 256 0 1 1 0-512 256 256 0 0 1 0 512"})]))}}),RY=LY,DY=Q({name:"CaretBottom",__name:"caret-bottom",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m192 384 320 384 320-384z"})]))}}),FY=DY,VY=Q({name:"ChatDotRound",__name:"chat-dot-round",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m174.72 855.68 135.296-45.12 23.68 11.84C388.096 849.536 448.576 864 512 864c211.84 0 384-166.784 384-352S723.84 160 512 160 128 326.784 128 512c0 69.12 24.96 139.264 70.848 199.232l22.08 28.8-46.272 115.584zm-45.248 82.56A32 32 0 0 1 89.6 896l58.368-145.92C94.72 680.32 64 596.864 64 512 64 299.904 256 96 512 96s448 203.904 448 416-192 416-448 416a461.056 461.056 0 0 1-206.912-48.384l-175.616 58.56z"}),b("path",{fill:"currentColor",d:"M512 563.2a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4m192 0a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4m-384 0a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4"})]))}}),BY=VY,zY=Q({name:"ChatDotSquare",__name:"chat-dot-square",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M273.536 736H800a64 64 0 0 0 64-64V256a64 64 0 0 0-64-64H224a64 64 0 0 0-64 64v570.88zM296 800 147.968 918.4A32 32 0 0 1 96 893.44V256a128 128 0 0 1 128-128h576a128 128 0 0 1 128 128v416a128 128 0 0 1-128 128z"}),b("path",{fill:"currentColor",d:"M512 499.2a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4zm192 0a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4zm-384 0a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4z"})]))}}),jY=zY,HY=Q({name:"Check",__name:"check",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M406.656 706.944 195.84 496.256a32 32 0 1 0-45.248 45.248l256 256 512-512a32 32 0 0 0-45.248-45.248L406.592 706.944z"})]))}}),Yx=HY,UY=Q({name:"CircleCheck",__name:"circle-check",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768m0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896"}),b("path",{fill:"currentColor",d:"M745.344 361.344a32 32 0 0 1 45.312 45.312l-288 288a32 32 0 0 1-45.312 0l-160-160a32 32 0 1 1 45.312-45.312L480 626.752l265.344-265.408z"})]))}}),i3=UY,WY=Q({name:"CircleCloseFilled",__name:"circle-close-filled",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m0 393.664L407.936 353.6a38.4 38.4 0 1 0-54.336 54.336L457.664 512 353.6 616.064a38.4 38.4 0 1 0 54.336 54.336L512 566.336 616.064 670.4a38.4 38.4 0 1 0 54.336-54.336L566.336 512 670.4 407.936a38.4 38.4 0 1 0-54.336-54.336z"})]))}}),Zx=WY,KY=Q({name:"CircleClose",__name:"circle-close",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m466.752 512-90.496-90.496a32 32 0 0 1 45.248-45.248L512 466.752l90.496-90.496a32 32 0 1 1 45.248 45.248L557.248 512l90.496 90.496a32 32 0 1 1-45.248 45.248L512 557.248l-90.496 90.496a32 32 0 0 1-45.248-45.248z"}),b("path",{fill:"currentColor",d:"M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768m0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896"})]))}}),wd=KY,qY=Q({name:"Clock",__name:"clock",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768m0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896"}),b("path",{fill:"currentColor",d:"M480 256a32 32 0 0 1 32 32v256a32 32 0 0 1-64 0V288a32 32 0 0 1 32-32"}),b("path",{fill:"currentColor",d:"M480 512h256q32 0 32 32t-32 32H480q-32 0-32-32t32-32"})]))}}),Jx=qY,GY=Q({name:"CloseBold",__name:"close-bold",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M195.2 195.2a64 64 0 0 1 90.496 0L512 421.504 738.304 195.2a64 64 0 0 1 90.496 90.496L602.496 512 828.8 738.304a64 64 0 0 1-90.496 90.496L512 602.496 285.696 828.8a64 64 0 0 1-90.496-90.496L421.504 512 195.2 285.696a64 64 0 0 1 0-90.496z"})]))}}),YY=GY,ZY=Q({name:"Close",__name:"close",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M764.288 214.592 512 466.88 259.712 214.592a31.936 31.936 0 0 0-45.12 45.12L466.752 512 214.528 764.224a31.936 31.936 0 1 0 45.12 45.184L512 557.184l252.288 252.288a31.936 31.936 0 0 0 45.12-45.12L557.12 512.064l252.288-252.352a31.936 31.936 0 1 0-45.12-45.184z"})]))}}),Gs=ZY,JY=Q({name:"Comment",__name:"comment",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M736 504a56 56 0 1 1 0-112 56 56 0 0 1 0 112m-224 0a56 56 0 1 1 0-112 56 56 0 0 1 0 112m-224 0a56 56 0 1 1 0-112 56 56 0 0 1 0 112M128 128v640h192v160l224-160h352V128z"})]))}}),XY=JY,QY=Q({name:"CopyDocument",__name:"copy-document",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M768 832a128 128 0 0 1-128 128H192A128 128 0 0 1 64 832V384a128 128 0 0 1 128-128v64a64 64 0 0 0-64 64v448a64 64 0 0 0 64 64h448a64 64 0 0 0 64-64z"}),b("path",{fill:"currentColor",d:"M384 128a64 64 0 0 0-64 64v448a64 64 0 0 0 64 64h448a64 64 0 0 0 64-64V192a64 64 0 0 0-64-64zm0-64h448a128 128 0 0 1 128 128v448a128 128 0 0 1-128 128H384a128 128 0 0 1-128-128V192A128 128 0 0 1 384 64"})]))}}),eZ=QY,tZ=Q({name:"DArrowLeft",__name:"d-arrow-left",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M529.408 149.376a29.12 29.12 0 0 1 41.728 0 30.592 30.592 0 0 1 0 42.688L259.264 511.936l311.872 319.936a30.592 30.592 0 0 1-.512 43.264 29.12 29.12 0 0 1-41.216-.512L197.76 534.272a32 32 0 0 1 0-44.672l331.648-340.224zm256 0a29.12 29.12 0 0 1 41.728 0 30.592 30.592 0 0 1 0 42.688L515.264 511.936l311.872 319.936a30.592 30.592 0 0 1-.512 43.264 29.12 29.12 0 0 1-41.216-.512L453.76 534.272a32 32 0 0 1 0-44.672l331.648-340.224z"})]))}}),Jc=tZ,nZ=Q({name:"DArrowRight",__name:"d-arrow-right",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M452.864 149.312a29.12 29.12 0 0 1 41.728.064L826.24 489.664a32 32 0 0 1 0 44.672L494.592 874.624a29.12 29.12 0 0 1-41.728 0 30.592 30.592 0 0 1 0-42.752L764.736 512 452.864 192a30.592 30.592 0 0 1 0-42.688m-256 0a29.12 29.12 0 0 1 41.728.064L570.24 489.664a32 32 0 0 1 0 44.672L238.592 874.624a29.12 29.12 0 0 1-41.728 0 30.592 30.592 0 0 1 0-42.752L508.736 512 196.864 192a30.592 30.592 0 0 1 0-42.688z"})]))}}),Xc=nZ,oZ=Q({name:"DeleteFilled",__name:"delete-filled",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M352 192V95.936a32 32 0 0 1 32-32h256a32 32 0 0 1 32 32V192h256a32 32 0 1 1 0 64H96a32 32 0 0 1 0-64zm64 0h192v-64H416zM192 960a32 32 0 0 1-32-32V256h704v672a32 32 0 0 1-32 32zm224-192a32 32 0 0 0 32-32V416a32 32 0 0 0-64 0v320a32 32 0 0 0 32 32m192 0a32 32 0 0 0 32-32V416a32 32 0 0 0-64 0v320a32 32 0 0 0 32 32"})]))}}),rZ=oZ,sZ=Q({name:"Delete",__name:"delete",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M160 256H96a32 32 0 0 1 0-64h256V95.936a32 32 0 0 1 32-32h256a32 32 0 0 1 32 32V192h256a32 32 0 1 1 0 64h-64v672a32 32 0 0 1-32 32H192a32 32 0 0 1-32-32zm448-64v-64H416v64zM224 896h576V256H224zm192-128a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32m192 0a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32"})]))}}),Xx=sZ,iZ=Q({name:"Document",__name:"document",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M832 384H576V128H192v768h640zm-26.496-64L640 154.496V320zM160 64h480l256 256v608a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32m160 448h384v64H320zm0-192h160v64H320zm0 384h384v64H320z"})]))}}),lZ=iZ,aZ=Q({name:"EditPen",__name:"edit-pen",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m199.04 672.64 193.984 112 224-387.968-193.92-112-224 388.032zm-23.872 60.16 32.896 148.288 144.896-45.696zM455.04 229.248l193.92 112 56.704-98.112-193.984-112-56.64 98.112zM104.32 708.8l384-665.024 304.768 175.936L409.152 884.8h.064l-248.448 78.336zm384 254.272v-64h448v64h-448z"})]))}}),uZ=aZ,cZ=Q({name:"Expand",__name:"expand",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M128 192h768v128H128zm0 256h512v128H128zm0 256h768v128H128zm576-352 192 160-192 128z"})]))}}),dZ=cZ,fZ=Q({name:"FullScreen",__name:"full-screen",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m160 96.064 192 .192a32 32 0 0 1 0 64l-192-.192V352a32 32 0 0 1-64 0V96h64zm0 831.872V928H96V672a32 32 0 1 1 64 0v191.936l192-.192a32 32 0 1 1 0 64zM864 96.064V96h64v256a32 32 0 1 1-64 0V160.064l-192 .192a32 32 0 1 1 0-64l192-.192zm0 831.872-192-.192a32 32 0 0 1 0-64l192 .192V672a32 32 0 1 1 64 0v256h-64z"})]))}}),Qx=fZ,pZ=Q({name:"Guide",__name:"guide",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M640 608h-64V416h64zm0 160v160a32 32 0 0 1-32 32H416a32 32 0 0 1-32-32V768h64v128h128V768zM384 608V416h64v192zm256-352h-64V128H448v128h-64V96a32 32 0 0 1 32-32h192a32 32 0 0 1 32 32z"}),b("path",{fill:"currentColor",d:"m220.8 256-71.232 80 71.168 80H768V256H220.8zm-14.4-64H800a32 32 0 0 1 32 32v224a32 32 0 0 1-32 32H206.4a32 32 0 0 1-23.936-10.752l-99.584-112a32 32 0 0 1 0-42.496l99.584-112A32 32 0 0 1 206.4 192m678.784 496-71.104 80H266.816V608h547.2l71.168 80zm-56.768-144H234.88a32 32 0 0 0-32 32v224a32 32 0 0 0 32 32h593.6a32 32 0 0 0 23.936-10.752l99.584-112a32 32 0 0 0 0-42.496l-99.584-112A32 32 0 0 0 828.48 544z"})]))}}),hZ=pZ,mZ=Q({name:"Hide",__name:"hide",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M876.8 156.8c0-9.6-3.2-16-9.6-22.4-6.4-6.4-12.8-9.6-22.4-9.6-9.6 0-16 3.2-22.4 9.6L736 220.8c-64-32-137.6-51.2-224-60.8-160 16-288 73.6-377.6 176C44.8 438.4 0 496 0 512s48 73.6 134.4 176c22.4 25.6 44.8 48 73.6 67.2l-86.4 89.6c-6.4 6.4-9.6 12.8-9.6 22.4 0 9.6 3.2 16 9.6 22.4 6.4 6.4 12.8 9.6 22.4 9.6 9.6 0 16-3.2 22.4-9.6l704-710.4c3.2-6.4 6.4-12.8 6.4-22.4Zm-646.4 528c-76.8-70.4-128-128-153.6-172.8 28.8-48 80-105.6 153.6-172.8C304 272 400 230.4 512 224c64 3.2 124.8 19.2 176 44.8l-54.4 54.4C598.4 300.8 560 288 512 288c-64 0-115.2 22.4-160 64s-64 96-64 160c0 48 12.8 89.6 35.2 124.8L256 707.2c-9.6-6.4-19.2-16-25.6-22.4Zm140.8-96c-12.8-22.4-19.2-48-19.2-76.8 0-44.8 16-83.2 48-112 32-28.8 67.2-48 112-48 28.8 0 54.4 6.4 73.6 19.2zM889.599 336c-12.8-16-28.8-28.8-41.6-41.6l-48 48c73.6 67.2 124.8 124.8 150.4 169.6-28.8 48-80 105.6-153.6 172.8-73.6 67.2-172.8 108.8-284.8 115.2-51.2-3.2-99.2-12.8-140.8-28.8l-48 48c57.6 22.4 118.4 38.4 188.8 44.8 160-16 288-73.6 377.6-176C979.199 585.6 1024 528 1024 512s-48.001-73.6-134.401-176Z"}),b("path",{fill:"currentColor",d:"M511.998 672c-12.8 0-25.6-3.2-38.4-6.4l-51.2 51.2c28.8 12.8 57.6 19.2 89.6 19.2 64 0 115.2-22.4 160-64 41.6-41.6 64-96 64-160 0-32-6.4-64-19.2-89.6l-51.2 51.2c3.2 12.8 6.4 25.6 6.4 38.4 0 44.8-16 83.2-48 112-32 28.8-67.2 48-112 48Z"})]))}}),eM=mZ,gZ=Q({name:"HomeFilled",__name:"home-filled",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 128 128 447.936V896h255.936V640H640v256h255.936V447.936z"})]))}}),vZ=gZ,yZ=Q({name:"InfoFilled",__name:"info-filled",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896.064A448 448 0 0 1 512 64m67.2 275.072c33.28 0 60.288-23.104 60.288-57.344s-27.072-57.344-60.288-57.344c-33.28 0-60.16 23.104-60.16 57.344s26.88 57.344 60.16 57.344M590.912 699.2c0-6.848 2.368-24.64 1.024-34.752l-52.608 60.544c-10.88 11.456-24.512 19.392-30.912 17.28a12.992 12.992 0 0 1-8.256-14.72l87.68-276.992c7.168-35.136-12.544-67.2-54.336-71.296-44.096 0-108.992 44.736-148.48 101.504 0 6.784-1.28 23.68.064 33.792l52.544-60.608c10.88-11.328 23.552-19.328 29.952-17.152a12.8 12.8 0 0 1 7.808 16.128L388.48 728.576c-10.048 32.256 8.96 63.872 55.04 71.04 67.84 0 107.904-43.648 147.456-100.416z"})]))}}),l3=yZ,_Z=Q({name:"Iphone",__name:"iphone",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M224 768v96.064a64 64 0 0 0 64 64h448a64 64 0 0 0 64-64V768zm0-64h576V160a64 64 0 0 0-64-64H288a64 64 0 0 0-64 64zm32 288a96 96 0 0 1-96-96V128a96 96 0 0 1 96-96h512a96 96 0 0 1 96 96v768a96 96 0 0 1-96 96zm304-144a48 48 0 1 1-96 0 48 48 0 0 1 96 0"})]))}}),bZ=_Z,wZ=Q({name:"Loading",__name:"loading",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32m0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32m448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32m-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32M195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248zm452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248zM828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0m-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0z"})]))}}),a3=wZ,CZ=Q({name:"Lock",__name:"lock",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M224 448a32 32 0 0 0-32 32v384a32 32 0 0 0 32 32h576a32 32 0 0 0 32-32V480a32 32 0 0 0-32-32zm0-64h576a96 96 0 0 1 96 96v384a96 96 0 0 1-96 96H224a96 96 0 0 1-96-96V480a96 96 0 0 1 96-96"}),b("path",{fill:"currentColor",d:"M512 544a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V576a32 32 0 0 1 32-32m192-160v-64a192 192 0 1 0-384 0v64zM512 64a256 256 0 0 1 256 256v128H256V320A256 256 0 0 1 512 64"})]))}}),kZ=CZ,SZ=Q({name:"Memo",__name:"memo",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg","xml:space":"preserve",style:{"enable-background":"new 0 0 1024 1024"},viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M480 320h192c21.33 0 32-10.67 32-32s-10.67-32-32-32H480c-21.33 0-32 10.67-32 32s10.67 32 32 32"}),b("path",{fill:"currentColor",d:"M887.01 72.99C881.01 67 873.34 64 864 64H160c-9.35 0-17.02 3-23.01 8.99C131 78.99 128 86.66 128 96v832c0 9.35 2.99 17.02 8.99 23.01S150.66 960 160 960h704c9.35 0 17.02-2.99 23.01-8.99S896 937.34 896 928V96c0-9.35-3-17.02-8.99-23.01M192 896V128h96v768zm640 0H352V128h480z"}),b("path",{fill:"currentColor",d:"M480 512h192c21.33 0 32-10.67 32-32s-10.67-32-32-32H480c-21.33 0-32 10.67-32 32s10.67 32 32 32m0 192h192c21.33 0 32-10.67 32-32s-10.67-32-32-32H480c-21.33 0-32 10.67-32 32s10.67 32 32 32"})]))}}),$Z=SZ,EZ=Q({name:"Message",__name:"message",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M128 224v512a64 64 0 0 0 64 64h640a64 64 0 0 0 64-64V224zm0-64h768a64 64 0 0 1 64 64v512a128 128 0 0 1-128 128H192A128 128 0 0 1 64 736V224a64 64 0 0 1 64-64"}),b("path",{fill:"currentColor",d:"M904 224 656.512 506.88a192 192 0 0 1-289.024 0L120 224zm-698.944 0 210.56 240.704a128 128 0 0 0 192.704 0L818.944 224H205.056"})]))}}),xZ=EZ,MZ=Q({name:"Minus",__name:"minus",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M128 544h768a32 32 0 1 0 0-64H128a32 32 0 0 0 0 64"})]))}}),TZ=MZ,OZ=Q({name:"MoreFilled",__name:"more-filled",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M176 416a112 112 0 1 1 0 224 112 112 0 0 1 0-224m336 0a112 112 0 1 1 0 224 112 112 0 0 1 0-224m336 0a112 112 0 1 1 0 224 112 112 0 0 1 0-224"})]))}}),Y_=OZ,IZ=Q({name:"More",__name:"more",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M176 416a112 112 0 1 0 0 224 112 112 0 0 0 0-224m0 64a48 48 0 1 1 0 96 48 48 0 0 1 0-96m336-64a112 112 0 1 1 0 224 112 112 0 0 1 0-224m0 64a48 48 0 1 0 0 96 48 48 0 0 0 0-96m336-64a112 112 0 1 1 0 224 112 112 0 0 1 0-224m0 64a48 48 0 1 0 0 96 48 48 0 0 0 0-96"})]))}}),AZ=IZ,NZ=Q({name:"Notebook",__name:"notebook",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M192 128v768h640V128zm-32-64h704a32 32 0 0 1 32 32v832a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32"}),b("path",{fill:"currentColor",d:"M672 128h64v768h-64zM96 192h128q32 0 32 32t-32 32H96q-32 0-32-32t32-32m0 192h128q32 0 32 32t-32 32H96q-32 0-32-32t32-32m0 192h128q32 0 32 32t-32 32H96q-32 0-32-32t32-32m0 192h128q32 0 32 32t-32 32H96q-32 0-32-32t32-32"})]))}}),PZ=NZ,LZ=Q({name:"Operation",__name:"operation",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M389.44 768a96.064 96.064 0 0 1 181.12 0H896v64H570.56a96.064 96.064 0 0 1-181.12 0H128v-64zm192-288a96.064 96.064 0 0 1 181.12 0H896v64H762.56a96.064 96.064 0 0 1-181.12 0H128v-64zm-320-288a96.064 96.064 0 0 1 181.12 0H896v64H442.56a96.064 96.064 0 0 1-181.12 0H128v-64z"})]))}}),RZ=LZ,DZ=Q({name:"PictureFilled",__name:"picture-filled",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M96 896a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32h832a32 32 0 0 1 32 32v704a32 32 0 0 1-32 32zm315.52-228.48-68.928-68.928a32 32 0 0 0-45.248 0L128 768.064h778.688l-242.112-290.56a32 32 0 0 0-49.216 0L458.752 665.408a32 32 0 0 1-47.232 2.112M256 384a96 96 0 1 0 192.064-.064A96 96 0 0 0 256 384"})]))}}),FZ=DZ,VZ=Q({name:"Picture",__name:"picture",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M160 160v704h704V160zm-32-64h768a32 32 0 0 1 32 32v768a32 32 0 0 1-32 32H128a32 32 0 0 1-32-32V128a32 32 0 0 1 32-32"}),b("path",{fill:"currentColor",d:"M384 288q64 0 64 64t-64 64q-64 0-64-64t64-64M185.408 876.992l-50.816-38.912L350.72 556.032a96 96 0 0 1 134.592-17.856l1.856 1.472 122.88 99.136a32 32 0 0 0 44.992-4.864l216-269.888 49.92 39.936-215.808 269.824-.256.32a96 96 0 0 1-135.04 14.464l-122.88-99.072-.64-.512a32 32 0 0 0-44.8 5.952z"})]))}}),BZ=VZ,zZ=Q({name:"Plus",__name:"plus",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M480 480V128a32 32 0 0 1 64 0v352h352a32 32 0 1 1 0 64H544v352a32 32 0 1 1-64 0V544H128a32 32 0 0 1 0-64z"})]))}}),u3=zZ,jZ=Q({name:"Postcard",__name:"postcard",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M160 224a32 32 0 0 0-32 32v512a32 32 0 0 0 32 32h704a32 32 0 0 0 32-32V256a32 32 0 0 0-32-32zm0-64h704a96 96 0 0 1 96 96v512a96 96 0 0 1-96 96H160a96 96 0 0 1-96-96V256a96 96 0 0 1 96-96"}),b("path",{fill:"currentColor",d:"M704 320a64 64 0 1 1 0 128 64 64 0 0 1 0-128M288 448h256q32 0 32 32t-32 32H288q-32 0-32-32t32-32m0 128h256q32 0 32 32t-32 32H288q-32 0-32-32t32-32"})]))}}),HZ=jZ,UZ=Q({name:"Reading",__name:"reading",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m512 863.36 384-54.848v-638.72L525.568 222.72a96 96 0 0 1-27.136 0L128 169.792v638.72zM137.024 106.432l370.432 52.928a32 32 0 0 0 9.088 0l370.432-52.928A64 64 0 0 1 960 169.792v638.72a64 64 0 0 1-54.976 63.36l-388.48 55.488a32 32 0 0 1-9.088 0l-388.48-55.488A64 64 0 0 1 64 808.512v-638.72a64 64 0 0 1 73.024-63.36z"}),b("path",{fill:"currentColor",d:"M480 192h64v704h-64z"})]))}}),WZ=UZ,KZ=Q({name:"RefreshLeft",__name:"refresh-left",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M289.088 296.704h92.992a32 32 0 0 1 0 64H232.96a32 32 0 0 1-32-32V179.712a32 32 0 0 1 64 0v50.56a384 384 0 0 1 643.84 282.88 384 384 0 0 1-383.936 384 384 384 0 0 1-384-384h64a320 320 0 1 0 640 0 320 320 0 0 0-555.712-216.448z"})]))}}),tM=KZ,qZ=Q({name:"RefreshRight",__name:"refresh-right",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M784.512 230.272v-50.56a32 32 0 1 1 64 0v149.056a32 32 0 0 1-32 32H667.52a32 32 0 1 1 0-64h92.992A320 320 0 1 0 524.8 833.152a320 320 0 0 0 320-320h64a384 384 0 0 1-384 384 384 384 0 0 1-384-384 384 384 0 0 1 643.712-282.88z"})]))}}),GZ=qZ,YZ=Q({name:"ScaleToOriginal",__name:"scale-to-original",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M813.176 180.706a60.235 60.235 0 0 1 60.236 60.235v481.883a60.235 60.235 0 0 1-60.236 60.235H210.824a60.235 60.235 0 0 1-60.236-60.235V240.94a60.235 60.235 0 0 1 60.236-60.235h602.352zm0-60.235H210.824A120.47 120.47 0 0 0 90.353 240.94v481.883a120.47 120.47 0 0 0 120.47 120.47h602.353a120.47 120.47 0 0 0 120.471-120.47V240.94a120.47 120.47 0 0 0-120.47-120.47zm-120.47 180.705a30.118 30.118 0 0 0-30.118 30.118v301.177a30.118 30.118 0 0 0 60.236 0V331.294a30.118 30.118 0 0 0-30.118-30.118zm-361.412 0a30.118 30.118 0 0 0-30.118 30.118v301.177a30.118 30.118 0 1 0 60.236 0V331.294a30.118 30.118 0 0 0-30.118-30.118M512 361.412a30.118 30.118 0 0 0-30.118 30.117v30.118a30.118 30.118 0 0 0 60.236 0V391.53A30.118 30.118 0 0 0 512 361.412M512 512a30.118 30.118 0 0 0-30.118 30.118v30.117a30.118 30.118 0 0 0 60.236 0v-30.117A30.118 30.118 0 0 0 512 512"})]))}}),ZZ=YZ,JZ=Q({name:"Search",__name:"search",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704"})]))}}),XZ=JZ,QZ=Q({name:"SuccessFilled",__name:"success-filled",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m-55.808 536.384-99.52-99.584a38.4 38.4 0 1 0-54.336 54.336l126.72 126.72a38.272 38.272 0 0 0 54.336 0l262.4-262.464a38.4 38.4 0 1 0-54.272-54.336z"})]))}}),c3=QZ,eJ=Q({name:"Tickets",__name:"tickets",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M192 128v768h640V128zm-32-64h704a32 32 0 0 1 32 32v832a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32m160 448h384v64H320zm0-192h192v64H320zm0 384h384v64H320z"})]))}}),tJ=eJ,nJ=Q({name:"Timer",__name:"timer",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 896a320 320 0 1 0 0-640 320 320 0 0 0 0 640m0 64a384 384 0 1 1 0-768 384 384 0 0 1 0 768"}),b("path",{fill:"currentColor",d:"M512 320a32 32 0 0 1 32 32l-.512 224a32 32 0 1 1-64 0L480 352a32 32 0 0 1 32-32"}),b("path",{fill:"currentColor",d:"M448 576a64 64 0 1 0 128 0 64 64 0 1 0-128 0m96-448v128h-64V128h-96a32 32 0 0 1 0-64h256a32 32 0 1 1 0 64z"})]))}}),oJ=nJ,rJ=Q({name:"Top",__name:"top",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M572.235 205.282v600.365a30.118 30.118 0 1 1-60.235 0V205.282L292.382 438.633a28.913 28.913 0 0 1-42.646 0 33.43 33.43 0 0 1 0-45.236l271.058-288.045a28.913 28.913 0 0 1 42.647 0L834.5 393.397a33.43 33.43 0 0 1 0 45.176 28.913 28.913 0 0 1-42.647 0l-219.618-233.23z"})]))}}),sJ=rJ,iJ=Q({name:"UploadFilled",__name:"upload-filled",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M544 864V672h128L512 480 352 672h128v192H320v-1.6c-5.376.32-10.496 1.6-16 1.6A240 240 0 0 1 64 624c0-123.136 93.12-223.488 212.608-237.248A239.808 239.808 0 0 1 512 192a239.872 239.872 0 0 1 235.456 194.752c119.488 13.76 212.48 114.112 212.48 237.248a240 240 0 0 1-240 240c-5.376 0-10.56-1.28-16-1.6v1.6z"})]))}}),lJ=iJ,aJ=Q({name:"View",__name:"view",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 160c320 0 512 352 512 352S832 864 512 864 0 512 0 512s192-352 512-352m0 64c-225.28 0-384.128 208.064-436.8 288 52.608 79.872 211.456 288 436.8 288 225.28 0 384.128-208.064 436.8-288-52.608-79.872-211.456-288-436.8-288zm0 64a224 224 0 1 1 0 448 224 224 0 0 1 0-448m0 64a160.192 160.192 0 0 0-160 160c0 88.192 71.744 160 160 160s160-71.808 160-160-71.744-160-160-160"})]))}}),nM=aJ,uJ=Q({name:"WarningFilled",__name:"warning-filled",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896m0 192a58.432 58.432 0 0 0-58.24 63.744l23.36 256.384a35.072 35.072 0 0 0 69.76 0l23.296-256.384A58.432 58.432 0 0 0 512 256m0 512a51.2 51.2 0 1 0 0-102.4 51.2 51.2 0 0 0 0 102.4"})]))}}),d3=uJ,cJ=Q({name:"ZoomIn",__name:"zoom-in",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704m-32-384v-96a32 32 0 0 1 64 0v96h96a32 32 0 0 1 0 64h-96v96a32 32 0 0 1-64 0v-96h-96a32 32 0 0 1 0-64z"})]))}}),oM=cJ,dJ=Q({name:"ZoomOut",__name:"zoom-out",setup(e){return(t,n)=>(C(),M("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704M352 448h256a32 32 0 0 1 0 64H352a32 32 0 0 1 0-64"})]))}}),fJ=dJ;const rM="__epPropKey",Ce=e=>e,pJ=e=>ft(e)&&!!e[rM],P0=(e,t)=>{if(!ft(e)||pJ(e))return e;const{values:n,required:o,default:r,type:s,validator:i}=e,a={type:s,required:!!o,validator:n||i?u=>{let c=!1,d=[];if(n&&(d=Array.from(n),vt(e,"default")&&d.push(r),c||(c=d.includes(u))),i&&(c||(c=i(u))),!c&&d.length>0){const f=[...new Set(d)].map(p=>JSON.stringify(p)).join(", ");KE(`Invalid prop: validation failed${t?` for prop "${t}"`:""}. Expected one of [${f}], got value ${JSON.stringify(u)}.`)}return c}:void 0,[rM]:!0};return vt(e,"default")&&(a.default=r),a},We=e=>Tg(Object.entries(e).map(([t,n])=>[t,P0(n,t)])),Oo=Ce([String,Object,Function]),sM={Close:Gs},hJ={Close:Gs,SuccessFilled:c3,InfoFilled:l3,WarningFilled:d3,CircleCloseFilled:Zx},Og={success:c3,warning:d3,error:Zx,info:l3},iM={validating:a3,success:i3,error:wd},Zt=(e,t)=>{if(e.install=n=>{for(const o of[e,...Object.values(t??{})])n.component(o.name,o)},t)for(const[n,o]of Object.entries(t))e[n]=o;return e},mJ=(e,t)=>(e.install=n=>{e._context=n._context,n.config.globalProperties[t]=e},e),gJ=(e,t)=>(e.install=n=>{n.directive(t,e)},e),Gn=e=>(e.install=yt,e),f3=(...e)=>t=>{e.forEach(n=>{Xe(n)?n(t):n.value=t})},rt={tab:"Tab",enter:"Enter",space:"Space",left:"ArrowLeft",up:"ArrowUp",right:"ArrowRight",down:"ArrowDown",esc:"Escape",delete:"Delete",backspace:"Backspace",numpadEnter:"NumpadEnter",pageUp:"PageUp",pageDown:"PageDown",home:"Home",end:"End"},vJ=["year","years","month","date","dates","week","datetime","datetimerange","daterange","monthrange"],Jt="update:modelValue",Cd="change",qm="input",Zl=["","default","small","large"],yJ=e=>["",...Zl].includes(e);var Gm=(e=>(e[e.TEXT=1]="TEXT",e[e.CLASS=2]="CLASS",e[e.STYLE=4]="STYLE",e[e.PROPS=8]="PROPS",e[e.FULL_PROPS=16]="FULL_PROPS",e[e.HYDRATE_EVENTS=32]="HYDRATE_EVENTS",e[e.STABLE_FRAGMENT=64]="STABLE_FRAGMENT",e[e.KEYED_FRAGMENT=128]="KEYED_FRAGMENT",e[e.UNKEYED_FRAGMENT=256]="UNKEYED_FRAGMENT",e[e.NEED_PATCH=512]="NEED_PATCH",e[e.DYNAMIC_SLOTS=1024]="DYNAMIC_SLOTS",e[e.HOISTED=-1]="HOISTED",e[e.BAIL=-2]="BAIL",e))(Gm||{});const Ym=e=>{const t=Me(e)?e:[e],n=[];return t.forEach(o=>{var r;Me(o)?n.push(...Ym(o)):yo(o)&&Me(o.children)?n.push(...Ym(o.children)):(n.push(o),yo(o)&&((r=o.component)!=null&&r.subTree)&&n.push(...Ym(o.component.subTree)))}),n},ns=e=>!e&&e!==0?[]:Array.isArray(e)?e:[e],lM=e=>/([\uAC00-\uD7AF\u3130-\u318F])+/gi.test(e),$o=e=>e,_J=["class","style"],bJ=/^on[A-Z]/,aM=(e={})=>{const{excludeListeners:t=!1,excludeKeys:n}=e,o=R(()=>((n==null?void 0:n.value)||[]).concat(_J)),r=at();return R(r?()=>{var s;return Tg(Object.entries((s=r.proxy)==null?void 0:s.$attrs).filter(([i])=>!o.value.includes(i)&&!(t&&bJ.test(i))))}:()=>({}))},Ua=({from:e,replacement:t,scope:n,version:o,ref:r,type:s="API"},i)=>{Te(()=>g(i),l=>{},{immediate:!0})},uM=(e,t,n,o)=>{let r={offsetX:0,offsetY:0};const s=a=>{const u=a.clientX,c=a.clientY,{offsetX:d,offsetY:f}=r,p=e.value.getBoundingClientRect(),h=p.left,m=p.top,y=p.width,v=p.height,w=document.documentElement.clientWidth,_=document.documentElement.clientHeight,S=-h+d,x=-m+f,E=w-h-y+d,T=_-m-v+f,O=N=>{let F=d+N.clientX-u,B=f+N.clientY-c;o!=null&&o.value||(F=Math.min(Math.max(F,S),E),B=Math.min(Math.max(B,x),T)),r={offsetX:F,offsetY:B},e.value&&(e.value.style.transform=`translate(${Zo(F)}, ${Zo(B)})`)},P=()=>{document.removeEventListener("mousemove",O),document.removeEventListener("mouseup",P)};document.addEventListener("mousemove",O),document.addEventListener("mouseup",P)},i=()=>{t.value&&e.value&&t.value.addEventListener("mousedown",s)},l=()=>{t.value&&e.value&&t.value.removeEventListener("mousedown",s)};Ct(()=>{ls(()=>{n.value?i():l()})}),En(()=>{l()})};var wJ={name:"en",el:{breadcrumb:{label:"Breadcrumb"},colorpicker:{confirm:"OK",clear:"Clear",defaultLabel:"color picker",description:"current color is {color}. press enter to select a new color."},datepicker:{now:"Now",today:"Today",cancel:"Cancel",clear:"Clear",confirm:"OK",dateTablePrompt:"Use the arrow keys and enter to select the day of the month",monthTablePrompt:"Use the arrow keys and enter to select the month",yearTablePrompt:"Use the arrow keys and enter to select the year",selectedDate:"Selected date",selectDate:"Select date",selectTime:"Select time",startDate:"Start Date",startTime:"Start Time",endDate:"End Date",endTime:"End Time",prevYear:"Previous Year",nextYear:"Next Year",prevMonth:"Previous Month",nextMonth:"Next Month",year:"",month1:"January",month2:"February",month3:"March",month4:"April",month5:"May",month6:"June",month7:"July",month8:"August",month9:"September",month10:"October",month11:"November",month12:"December",week:"week",weeks:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},weeksFull:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"},months:{jan:"Jan",feb:"Feb",mar:"Mar",apr:"Apr",may:"May",jun:"Jun",jul:"Jul",aug:"Aug",sep:"Sep",oct:"Oct",nov:"Nov",dec:"Dec"}},inputNumber:{decrease:"decrease number",increase:"increase number"},select:{loading:"Loading",noMatch:"No matching data",noData:"No data",placeholder:"Select"},dropdown:{toggleDropdown:"Toggle Dropdown"},cascader:{noMatch:"No matching data",loading:"Loading",placeholder:"Select",noData:"No data"},pagination:{goto:"Go to",pagesize:"/page",total:"Total {total}",pageClassifier:"",page:"Page",prev:"Go to previous page",next:"Go to next page",currentPage:"page {pager}",prevPages:"Previous {pager} pages",nextPages:"Next {pager} pages",deprecationWarning:"Deprecated usages detected, please refer to the el-pagination documentation for more details"},dialog:{close:"Close this dialog"},drawer:{close:"Close this dialog"},messagebox:{title:"Message",confirm:"OK",cancel:"Cancel",error:"Illegal input",close:"Close this dialog"},upload:{deleteTip:"press delete to remove",delete:"Delete",preview:"Preview",continue:"Continue"},slider:{defaultLabel:"slider between {min} and {max}",defaultRangeStartLabel:"pick start value",defaultRangeEndLabel:"pick end value"},table:{emptyText:"No Data",confirmFilter:"Confirm",resetFilter:"Reset",clearFilter:"All",sumText:"Sum"},tour:{next:"Next",previous:"Previous",finish:"Finish"},tree:{emptyText:"No Data"},transfer:{noMatch:"No matching data",noData:"No data",titles:["List 1","List 2"],filterPlaceholder:"Enter keyword",noCheckedFormat:"{total} items",hasCheckedFormat:"{checked}/{total} checked"},image:{error:"FAILED"},pageHeader:{title:"Back"},popconfirm:{confirmButtonText:"Yes",cancelButtonText:"No"},carousel:{leftArrow:"Carousel arrow left",rightArrow:"Carousel arrow right",indicator:"Carousel switch to index {index}"}}};const CJ=e=>(t,n)=>kJ(t,n,g(e)),kJ=(e,t,n)=>Tr(n,e,e).replace(/\{(\w+)\}/g,(o,r)=>{var s;return`${(s=t==null?void 0:t[r])!=null?s:`{${r}}`}`}),SJ=e=>{const t=R(()=>g(e).name),n=on(e)?e:K(e);return{lang:t,locale:n,t:CJ(e)}},cM=Symbol("localeContextKey"),Kt=e=>{const t=e||Be(cM,K());return SJ(R(()=>t.value||wJ))},Hf="el",$J="is-",ca=(e,t,n,o,r)=>{let s=`${e}-${t}`;return n&&(s+=`-${n}`),o&&(s+=`__${o}`),r&&(s+=`--${r}`),s},dM=Symbol("namespaceContextKey"),p3=e=>{const t=e||(at()?Be(dM,K(Hf)):K(Hf));return R(()=>g(t)||Hf)},Re=(e,t)=>{const n=p3(t);return{namespace:n,b:(m="")=>ca(n.value,e,m,"",""),e:m=>m?ca(n.value,e,"",m,""):"",m:m=>m?ca(n.value,e,"","",m):"",be:(m,y)=>m&&y?ca(n.value,e,m,y,""):"",em:(m,y)=>m&&y?ca(n.value,e,"",m,y):"",bm:(m,y)=>m&&y?ca(n.value,e,m,"",y):"",bem:(m,y,v)=>m&&y&&v?ca(n.value,e,m,y,v):"",is:(m,...y)=>{const v=y.length>=1?y[0]:!0;return m&&v?`${$J}${m}`:""},cssVar:m=>{const y={};for(const v in m)m[v]&&(y[`--${n.value}-${v}`]=m[v]);return y},cssVarName:m=>`--${n.value}-${m}`,cssVarBlock:m=>{const y={};for(const v in m)m[v]&&(y[`--${n.value}-${e}-${v}`]=m[v]);return y},cssVarBlockName:m=>`--${n.value}-${e}-${m}`}},fM=(e,t={})=>{on(e)||ws("[useLockscreen]","You need to pass a ref param to this function");const n=t.ns||Re("popup"),o=j$(()=>n.bm("parent","hidden"));if(!xt||Ti(document.body,o.value))return;let r=0,s=!1,i="0";const l=()=>{setTimeout(()=>{qs(document==null?void 0:document.body,o.value),s&&document&&(document.body.style.width=i)},200)};Te(e,a=>{if(!a){l();return}s=!Ti(document.body,o.value),s&&(i=document.body.style.width),r=_Y(n.namespace.value);const u=document.documentElement.clientHeight<document.body.scrollHeight,c=kl(document.body,"overflowY");r>0&&(u||c==="scroll")&&s&&(document.body.style.width=`calc(100% - ${r}px)`),lu(document.body,o.value)}),Q2(()=>l())},EJ=P0({type:Ce(Boolean),default:null}),xJ=P0({type:Ce(Function)}),pM=e=>{const t=`update:${e}`,n=`onUpdate:${e}`,o=[t],r={[e]:EJ,[n]:xJ};return{useModelToggle:({indicator:i,toggleReason:l,shouldHideWhenRouteChanges:a,shouldProceed:u,onShow:c,onHide:d})=>{const f=at(),{emit:p}=f,h=f.props,m=R(()=>Xe(h[n])),y=R(()=>h[e]===null),v=T=>{i.value!==!0&&(i.value=!0,l&&(l.value=T),Xe(c)&&c(T))},w=T=>{i.value!==!1&&(i.value=!1,l&&(l.value=T),Xe(d)&&d(T))},_=T=>{if(h.disabled===!0||Xe(u)&&!u())return;const O=m.value&&xt;O&&p(t,!0),(y.value||!O)&&v(T)},S=T=>{if(h.disabled===!0||!xt)return;const O=m.value&&xt;O&&p(t,!1),(y.value||!O)&&w(T)},x=T=>{Br(T)&&(h.disabled&&T?m.value&&p(t,!1):i.value!==T&&(T?v():w()))},E=()=>{i.value?S():_()};return Te(()=>h[e],x),a&&f.appContext.config.globalProperties.$route!==void 0&&Te(()=>({...f.proxy.$route}),()=>{a.value&&i.value&&S()}),Ct(()=>{x(h[e])}),{hide:S,show:_,toggle:E,hasUpdateHandler:m}},useModelToggleProps:r,useModelToggleEmits:o}};pM("modelValue");const hM=e=>{const t=at();return R(()=>{var n,o;return(o=(n=t==null?void 0:t.proxy)==null?void 0:n.$props)==null?void 0:o[e]})};var Ko="top",zr="bottom",jr="right",qo="left",h3="auto",ch=[Ko,zr,jr,qo],Qc="start",Np="end",MJ="clippingParents",mM="viewport",Ud="popper",TJ="reference",d5=ch.reduce(function(e,t){return e.concat([t+"-"+Qc,t+"-"+Np])},[]),L0=[].concat(ch,[h3]).reduce(function(e,t){return e.concat([t,t+"-"+Qc,t+"-"+Np])},[]),OJ="beforeRead",IJ="read",AJ="afterRead",NJ="beforeMain",PJ="main",LJ="afterMain",RJ="beforeWrite",DJ="write",FJ="afterWrite",VJ=[OJ,IJ,AJ,NJ,PJ,LJ,RJ,DJ,FJ];function Ys(e){return e?(e.nodeName||"").toLowerCase():null}function Cs(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function ed(e){var t=Cs(e).Element;return e instanceof t||e instanceof Element}function Lr(e){var t=Cs(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function m3(e){if(typeof ShadowRoot>"u")return!1;var t=Cs(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function BJ(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var o=t.styles[n]||{},r=t.attributes[n]||{},s=t.elements[n];!Lr(s)||!Ys(s)||(Object.assign(s.style,o),Object.keys(r).forEach(function(i){var l=r[i];l===!1?s.removeAttribute(i):s.setAttribute(i,l===!0?"":l)}))})}function zJ(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(o){var r=t.elements[o],s=t.attributes[o]||{},i=Object.keys(t.styles.hasOwnProperty(o)?t.styles[o]:n[o]),l=i.reduce(function(a,u){return a[u]="",a},{});!Lr(r)||!Ys(r)||(Object.assign(r.style,l),Object.keys(s).forEach(function(a){r.removeAttribute(a)}))})}}var gM={name:"applyStyles",enabled:!0,phase:"write",fn:BJ,effect:zJ,requires:["computeStyles"]};function Hs(e){return e.split("-")[0]}var Wa=Math.max,Ig=Math.min,td=Math.round;function nd(e,t){t===void 0&&(t=!1);var n=e.getBoundingClientRect(),o=1,r=1;if(Lr(e)&&t){var s=e.offsetHeight,i=e.offsetWidth;i>0&&(o=td(n.width)/i||1),s>0&&(r=td(n.height)/s||1)}return{width:n.width/o,height:n.height/r,top:n.top/r,right:n.right/o,bottom:n.bottom/r,left:n.left/o,x:n.left/o,y:n.top/r}}function g3(e){var t=nd(e),n=e.offsetWidth,o=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-o)<=1&&(o=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:o}}function vM(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&m3(n)){var o=t;do{if(o&&e.isSameNode(o))return!0;o=o.parentNode||o.host}while(o)}return!1}function Pi(e){return Cs(e).getComputedStyle(e)}function jJ(e){return["table","td","th"].indexOf(Ys(e))>=0}function Jl(e){return((ed(e)?e.ownerDocument:e.document)||window.document).documentElement}function R0(e){return Ys(e)==="html"?e:e.assignedSlot||e.parentNode||(m3(e)?e.host:null)||Jl(e)}function f5(e){return!Lr(e)||Pi(e).position==="fixed"?null:e.offsetParent}function HJ(e){var t=navigator.userAgent.toLowerCase().indexOf("firefox")!==-1,n=navigator.userAgent.indexOf("Trident")!==-1;if(n&&Lr(e)){var o=Pi(e);if(o.position==="fixed")return null}var r=R0(e);for(m3(r)&&(r=r.host);Lr(r)&&["html","body"].indexOf(Ys(r))<0;){var s=Pi(r);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return r;r=r.parentNode}return null}function dh(e){for(var t=Cs(e),n=f5(e);n&&jJ(n)&&Pi(n).position==="static";)n=f5(n);return n&&(Ys(n)==="html"||Ys(n)==="body"&&Pi(n).position==="static")?t:n||HJ(e)||t}function v3(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Uf(e,t,n){return Wa(e,Ig(t,n))}function UJ(e,t,n){var o=Uf(e,t,n);return o>n?n:o}function yM(){return{top:0,right:0,bottom:0,left:0}}function _M(e){return Object.assign({},yM(),e)}function bM(e,t){return t.reduce(function(n,o){return n[o]=e,n},{})}var WJ=function(e,t){return e=typeof e=="function"?e(Object.assign({},t.rects,{placement:t.placement})):e,_M(typeof e!="number"?e:bM(e,ch))};function KJ(e){var t,n=e.state,o=e.name,r=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Hs(n.placement),a=v3(l),u=[qo,jr].indexOf(l)>=0,c=u?"height":"width";if(!(!s||!i)){var d=WJ(r.padding,n),f=g3(s),p=a==="y"?Ko:qo,h=a==="y"?zr:jr,m=n.rects.reference[c]+n.rects.reference[a]-i[a]-n.rects.popper[c],y=i[a]-n.rects.reference[a],v=dh(s),w=v?a==="y"?v.clientHeight||0:v.clientWidth||0:0,_=m/2-y/2,S=d[p],x=w-f[c]-d[h],E=w/2-f[c]/2+_,T=Uf(S,E,x),O=a;n.modifiersData[o]=(t={},t[O]=T,t.centerOffset=T-E,t)}}function qJ(e){var t=e.state,n=e.options,o=n.element,r=o===void 0?"[data-popper-arrow]":o;r!=null&&(typeof r=="string"&&(r=t.elements.popper.querySelector(r),!r)||!vM(t.elements.popper,r)||(t.elements.arrow=r))}var GJ={name:"arrow",enabled:!0,phase:"main",fn:KJ,effect:qJ,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function od(e){return e.split("-")[1]}var YJ={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ZJ(e){var t=e.x,n=e.y,o=window,r=o.devicePixelRatio||1;return{x:td(t*r)/r||0,y:td(n*r)/r||0}}function p5(e){var t,n=e.popper,o=e.popperRect,r=e.placement,s=e.variation,i=e.offsets,l=e.position,a=e.gpuAcceleration,u=e.adaptive,c=e.roundOffsets,d=e.isFixed,f=i.x,p=f===void 0?0:f,h=i.y,m=h===void 0?0:h,y=typeof c=="function"?c({x:p,y:m}):{x:p,y:m};p=y.x,m=y.y;var v=i.hasOwnProperty("x"),w=i.hasOwnProperty("y"),_=qo,S=Ko,x=window;if(u){var E=dh(n),T="clientHeight",O="clientWidth";if(E===Cs(n)&&(E=Jl(n),Pi(E).position!=="static"&&l==="absolute"&&(T="scrollHeight",O="scrollWidth")),E=E,r===Ko||(r===qo||r===jr)&&s===Np){S=zr;var P=d&&E===x&&x.visualViewport?x.visualViewport.height:E[T];m-=P-o.height,m*=a?1:-1}if(r===qo||(r===Ko||r===zr)&&s===Np){_=jr;var N=d&&E===x&&x.visualViewport?x.visualViewport.width:E[O];p-=N-o.width,p*=a?1:-1}}var F=Object.assign({position:l},u&&YJ),B=c===!0?ZJ({x:p,y:m}):{x:p,y:m};if(p=B.x,m=B.y,a){var Y;return Object.assign({},F,(Y={},Y[S]=w?"0":"",Y[_]=v?"0":"",Y.transform=(x.devicePixelRatio||1)<=1?"translate("+p+"px, "+m+"px)":"translate3d("+p+"px, "+m+"px, 0)",Y))}return Object.assign({},F,(t={},t[S]=w?m+"px":"",t[_]=v?p+"px":"",t.transform="",t))}function JJ(e){var t=e.state,n=e.options,o=n.gpuAcceleration,r=o===void 0?!0:o,s=n.adaptive,i=s===void 0?!0:s,l=n.roundOffsets,a=l===void 0?!0:l,u={placement:Hs(t.placement),variation:od(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:r,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,p5(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:i,roundOffsets:a})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,p5(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:a})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}var wM={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:JJ,data:{}},am={passive:!0};function XJ(e){var t=e.state,n=e.instance,o=e.options,r=o.scroll,s=r===void 0?!0:r,i=o.resize,l=i===void 0?!0:i,a=Cs(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&u.forEach(function(c){c.addEventListener("scroll",n.update,am)}),l&&a.addEventListener("resize",n.update,am),function(){s&&u.forEach(function(c){c.removeEventListener("scroll",n.update,am)}),l&&a.removeEventListener("resize",n.update,am)}}var CM={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:XJ,data:{}},QJ={left:"right",right:"left",bottom:"top",top:"bottom"};function Zm(e){return e.replace(/left|right|bottom|top/g,function(t){return QJ[t]})}var eX={start:"end",end:"start"};function h5(e){return e.replace(/start|end/g,function(t){return eX[t]})}function y3(e){var t=Cs(e),n=t.pageXOffset,o=t.pageYOffset;return{scrollLeft:n,scrollTop:o}}function _3(e){return nd(Jl(e)).left+y3(e).scrollLeft}function tX(e){var t=Cs(e),n=Jl(e),o=t.visualViewport,r=n.clientWidth,s=n.clientHeight,i=0,l=0;return o&&(r=o.width,s=o.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(i=o.offsetLeft,l=o.offsetTop)),{width:r,height:s,x:i+_3(e),y:l}}function nX(e){var t,n=Jl(e),o=y3(e),r=(t=e.ownerDocument)==null?void 0:t.body,s=Wa(n.scrollWidth,n.clientWidth,r?r.scrollWidth:0,r?r.clientWidth:0),i=Wa(n.scrollHeight,n.clientHeight,r?r.scrollHeight:0,r?r.clientHeight:0),l=-o.scrollLeft+_3(e),a=-o.scrollTop;return Pi(r||n).direction==="rtl"&&(l+=Wa(n.clientWidth,r?r.clientWidth:0)-s),{width:s,height:i,x:l,y:a}}function b3(e){var t=Pi(e),n=t.overflow,o=t.overflowX,r=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+r+o)}function kM(e){return["html","body","#document"].indexOf(Ys(e))>=0?e.ownerDocument.body:Lr(e)&&b3(e)?e:kM(R0(e))}function Wf(e,t){var n;t===void 0&&(t=[]);var o=kM(e),r=o===((n=e.ownerDocument)==null?void 0:n.body),s=Cs(o),i=r?[s].concat(s.visualViewport||[],b3(o)?o:[]):o,l=t.concat(i);return r?l:l.concat(Wf(R0(i)))}function Z_(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function oX(e){var t=nd(e);return t.top=t.top+e.clientTop,t.left=t.left+e.clientLeft,t.bottom=t.top+e.clientHeight,t.right=t.left+e.clientWidth,t.width=e.clientWidth,t.height=e.clientHeight,t.x=t.left,t.y=t.top,t}function m5(e,t){return t===mM?Z_(tX(e)):ed(t)?oX(t):Z_(nX(Jl(e)))}function rX(e){var t=Wf(R0(e)),n=["absolute","fixed"].indexOf(Pi(e).position)>=0,o=n&&Lr(e)?dh(e):e;return ed(o)?t.filter(function(r){return ed(r)&&vM(r,o)&&Ys(r)!=="body"}):[]}function sX(e,t,n){var o=t==="clippingParents"?rX(e):[].concat(t),r=[].concat(o,[n]),s=r[0],i=r.reduce(function(l,a){var u=m5(e,a);return l.top=Wa(u.top,l.top),l.right=Ig(u.right,l.right),l.bottom=Ig(u.bottom,l.bottom),l.left=Wa(u.left,l.left),l},m5(e,s));return i.width=i.right-i.left,i.height=i.bottom-i.top,i.x=i.left,i.y=i.top,i}function SM(e){var t=e.reference,n=e.element,o=e.placement,r=o?Hs(o):null,s=o?od(o):null,i=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,a;switch(r){case Ko:a={x:i,y:t.y-n.height};break;case zr:a={x:i,y:t.y+t.height};break;case jr:a={x:t.x+t.width,y:l};break;case qo:a={x:t.x-n.width,y:l};break;default:a={x:t.x,y:t.y}}var u=r?v3(r):null;if(u!=null){var c=u==="y"?"height":"width";switch(s){case Qc:a[u]=a[u]-(t[c]/2-n[c]/2);break;case Np:a[u]=a[u]+(t[c]/2-n[c]/2);break}}return a}function Pp(e,t){t===void 0&&(t={});var n=t,o=n.placement,r=o===void 0?e.placement:o,s=n.boundary,i=s===void 0?MJ:s,l=n.rootBoundary,a=l===void 0?mM:l,u=n.elementContext,c=u===void 0?Ud:u,d=n.altBoundary,f=d===void 0?!1:d,p=n.padding,h=p===void 0?0:p,m=_M(typeof h!="number"?h:bM(h,ch)),y=c===Ud?TJ:Ud,v=e.rects.popper,w=e.elements[f?y:c],_=sX(ed(w)?w:w.contextElement||Jl(e.elements.popper),i,a),S=nd(e.elements.reference),x=SM({reference:S,element:v,strategy:"absolute",placement:r}),E=Z_(Object.assign({},v,x)),T=c===Ud?E:S,O={top:_.top-T.top+m.top,bottom:T.bottom-_.bottom+m.bottom,left:_.left-T.left+m.left,right:T.right-_.right+m.right},P=e.modifiersData.offset;if(c===Ud&&P){var N=P[r];Object.keys(O).forEach(function(F){var B=[jr,zr].indexOf(F)>=0?1:-1,Y=[Ko,zr].indexOf(F)>=0?"y":"x";O[F]+=N[Y]*B})}return O}function iX(e,t){t===void 0&&(t={});var n=t,o=n.placement,r=n.boundary,s=n.rootBoundary,i=n.padding,l=n.flipVariations,a=n.allowedAutoPlacements,u=a===void 0?L0:a,c=od(o),d=c?l?d5:d5.filter(function(h){return od(h)===c}):ch,f=d.filter(function(h){return u.indexOf(h)>=0});f.length===0&&(f=d);var p=f.reduce(function(h,m){return h[m]=Pp(e,{placement:m,boundary:r,rootBoundary:s,padding:i})[Hs(m)],h},{});return Object.keys(p).sort(function(h,m){return p[h]-p[m]})}function lX(e){if(Hs(e)===h3)return[];var t=Zm(e);return[h5(e),t,h5(t)]}function aX(e){var t=e.state,n=e.options,o=e.name;if(!t.modifiersData[o]._skip){for(var r=n.mainAxis,s=r===void 0?!0:r,i=n.altAxis,l=i===void 0?!0:i,a=n.fallbackPlacements,u=n.padding,c=n.boundary,d=n.rootBoundary,f=n.altBoundary,p=n.flipVariations,h=p===void 0?!0:p,m=n.allowedAutoPlacements,y=t.options.placement,v=Hs(y),w=v===y,_=a||(w||!h?[Zm(y)]:lX(y)),S=[y].concat(_).reduce(function(ge,Oe){return ge.concat(Hs(Oe)===h3?iX(t,{placement:Oe,boundary:c,rootBoundary:d,padding:u,flipVariations:h,allowedAutoPlacements:m}):Oe)},[]),x=t.rects.reference,E=t.rects.popper,T=new Map,O=!0,P=S[0],N=0;N<S.length;N++){var F=S[N],B=Hs(F),Y=od(F)===Qc,Z=[Ko,zr].indexOf(B)>=0,U=Z?"width":"height",j=Pp(t,{placement:F,boundary:c,rootBoundary:d,altBoundary:f,padding:u}),V=Z?Y?jr:qo:Y?zr:Ko;x[U]>E[U]&&(V=Zm(V));var H=Zm(V),L=[];if(s&&L.push(j[B]<=0),l&&L.push(j[V]<=0,j[H]<=0),L.every(function(ge){return ge})){P=F,O=!1;break}T.set(F,L)}if(O)for(var I=h?3:1,X=function(ge){var Oe=S.find(function(xe){var ee=T.get(xe);if(ee)return ee.slice(0,ge).every(function(de){return de})});if(Oe)return P=Oe,"break"},oe=I;oe>0;oe--){var z=X(oe);if(z==="break")break}t.placement!==P&&(t.modifiersData[o]._skip=!0,t.placement=P,t.reset=!0)}}var uX={name:"flip",enabled:!0,phase:"main",fn:aX,requiresIfExists:["offset"],data:{_skip:!1}};function g5(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function v5(e){return[Ko,jr,zr,qo].some(function(t){return e[t]>=0})}function cX(e){var t=e.state,n=e.name,o=t.rects.reference,r=t.rects.popper,s=t.modifiersData.preventOverflow,i=Pp(t,{elementContext:"reference"}),l=Pp(t,{altBoundary:!0}),a=g5(i,o),u=g5(l,r,s),c=v5(a),d=v5(u);t.modifiersData[n]={referenceClippingOffsets:a,popperEscapeOffsets:u,isReferenceHidden:c,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":d})}var dX={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:cX};function fX(e,t,n){var o=Hs(e),r=[qo,Ko].indexOf(o)>=0?-1:1,s=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,i=s[0],l=s[1];return i=i||0,l=(l||0)*r,[qo,jr].indexOf(o)>=0?{x:l,y:i}:{x:i,y:l}}function pX(e){var t=e.state,n=e.options,o=e.name,r=n.offset,s=r===void 0?[0,0]:r,i=L0.reduce(function(c,d){return c[d]=fX(d,t.rects,s),c},{}),l=i[t.placement],a=l.x,u=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=a,t.modifiersData.popperOffsets.y+=u),t.modifiersData[o]=i}var hX={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:pX};function mX(e){var t=e.state,n=e.name;t.modifiersData[n]=SM({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}var $M={name:"popperOffsets",enabled:!0,phase:"read",fn:mX,data:{}};function gX(e){return e==="x"?"y":"x"}function vX(e){var t=e.state,n=e.options,o=e.name,r=n.mainAxis,s=r===void 0?!0:r,i=n.altAxis,l=i===void 0?!1:i,a=n.boundary,u=n.rootBoundary,c=n.altBoundary,d=n.padding,f=n.tether,p=f===void 0?!0:f,h=n.tetherOffset,m=h===void 0?0:h,y=Pp(t,{boundary:a,rootBoundary:u,padding:d,altBoundary:c}),v=Hs(t.placement),w=od(t.placement),_=!w,S=v3(v),x=gX(S),E=t.modifiersData.popperOffsets,T=t.rects.reference,O=t.rects.popper,P=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,N=typeof P=="number"?{mainAxis:P,altAxis:P}:Object.assign({mainAxis:0,altAxis:0},P),F=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,B={x:0,y:0};if(E){if(s){var Y,Z=S==="y"?Ko:qo,U=S==="y"?zr:jr,j=S==="y"?"height":"width",V=E[S],H=V+y[Z],L=V-y[U],I=p?-O[j]/2:0,X=w===Qc?T[j]:O[j],oe=w===Qc?-O[j]:-T[j],z=t.elements.arrow,ge=p&&z?g3(z):{width:0,height:0},Oe=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:yM(),xe=Oe[Z],ee=Oe[U],de=Uf(0,T[j],ge[j]),ve=_?T[j]/2-I-de-xe-N.mainAxis:X-de-xe-N.mainAxis,le=_?-T[j]/2+I+de+ee+N.mainAxis:oe+de+ee+N.mainAxis,Ie=t.elements.arrow&&dh(t.elements.arrow),Ge=Ie?S==="y"?Ie.clientTop||0:Ie.clientLeft||0:0,G=(Y=F==null?void 0:F[S])!=null?Y:0,J=V+ve-G-Ge,ue=V+le-G,_e=Uf(p?Ig(H,J):H,V,p?Wa(L,ue):L);E[S]=_e,B[S]=_e-V}if(l){var ye,Ae=S==="x"?Ko:qo,Le=S==="x"?zr:jr,Ee=E[x],Pe=x==="y"?"height":"width",me=Ee+y[Ae],je=Ee-y[Le],Ze=[Ko,qo].indexOf(v)!==-1,ce=(ye=F==null?void 0:F[x])!=null?ye:0,te=Ze?me:Ee-T[Pe]-O[Pe]-ce+N.altAxis,pe=Ze?Ee+T[Pe]+O[Pe]-ce-N.altAxis:je,Ve=p&&Ze?UJ(te,Ee,pe):Uf(p?te:me,Ee,p?pe:je);E[x]=Ve,B[x]=Ve-Ee}t.modifiersData[o]=B}}var yX={name:"preventOverflow",enabled:!0,phase:"main",fn:vX,requiresIfExists:["offset"]};function _X(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function bX(e){return e===Cs(e)||!Lr(e)?y3(e):_X(e)}function wX(e){var t=e.getBoundingClientRect(),n=td(t.width)/e.offsetWidth||1,o=td(t.height)/e.offsetHeight||1;return n!==1||o!==1}function CX(e,t,n){n===void 0&&(n=!1);var o=Lr(t),r=Lr(t)&&wX(t),s=Jl(t),i=nd(e,r),l={scrollLeft:0,scrollTop:0},a={x:0,y:0};return(o||!o&&!n)&&((Ys(t)!=="body"||b3(s))&&(l=bX(t)),Lr(t)?(a=nd(t,!0),a.x+=t.clientLeft,a.y+=t.clientTop):s&&(a.x=_3(s))),{x:i.left+l.scrollLeft-a.x,y:i.top+l.scrollTop-a.y,width:i.width,height:i.height}}function kX(e){var t=new Map,n=new Set,o=[];e.forEach(function(s){t.set(s.name,s)});function r(s){n.add(s.name);var i=[].concat(s.requires||[],s.requiresIfExists||[]);i.forEach(function(l){if(!n.has(l)){var a=t.get(l);a&&r(a)}}),o.push(s)}return e.forEach(function(s){n.has(s.name)||r(s)}),o}function SX(e){var t=kX(e);return VJ.reduce(function(n,o){return n.concat(t.filter(function(r){return r.phase===o}))},[])}function $X(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function EX(e){var t=e.reduce(function(n,o){var r=n[o.name];return n[o.name]=r?Object.assign({},r,o,{options:Object.assign({},r.options,o.options),data:Object.assign({},r.data,o.data)}):o,n},{});return Object.keys(t).map(function(n){return t[n]})}var y5={placement:"bottom",modifiers:[],strategy:"absolute"};function _5(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(o){return!(o&&typeof o.getBoundingClientRect=="function")})}function w3(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,o=n===void 0?[]:n,r=t.defaultOptions,s=r===void 0?y5:r;return function(i,l,a){a===void 0&&(a=s);var u={placement:"bottom",orderedModifiers:[],options:Object.assign({},y5,s),modifiersData:{},elements:{reference:i,popper:l},attributes:{},styles:{}},c=[],d=!1,f={state:u,setOptions:function(m){var y=typeof m=="function"?m(u.options):m;h(),u.options=Object.assign({},s,u.options,y),u.scrollParents={reference:ed(i)?Wf(i):i.contextElement?Wf(i.contextElement):[],popper:Wf(l)};var v=SX(EX([].concat(o,u.options.modifiers)));return u.orderedModifiers=v.filter(function(w){return w.enabled}),p(),f.update()},forceUpdate:function(){if(!d){var m=u.elements,y=m.reference,v=m.popper;if(_5(y,v)){u.rects={reference:CX(y,dh(v),u.options.strategy==="fixed"),popper:g3(v)},u.reset=!1,u.placement=u.options.placement,u.orderedModifiers.forEach(function(O){return u.modifiersData[O.name]=Object.assign({},O.data)});for(var w=0;w<u.orderedModifiers.length;w++){if(u.reset===!0){u.reset=!1,w=-1;continue}var _=u.orderedModifiers[w],S=_.fn,x=_.options,E=x===void 0?{}:x,T=_.name;typeof S=="function"&&(u=S({state:u,options:E,name:T,instance:f})||u)}}}},update:$X(function(){return new Promise(function(m){f.forceUpdate(),m(u)})}),destroy:function(){h(),d=!0}};if(!_5(i,l))return f;f.setOptions(a).then(function(m){!d&&a.onFirstUpdate&&a.onFirstUpdate(m)});function p(){u.orderedModifiers.forEach(function(m){var y=m.name,v=m.options,w=v===void 0?{}:v,_=m.effect;if(typeof _=="function"){var S=_({state:u,name:y,instance:f,options:w}),x=function(){};c.push(S||x)}})}function h(){c.forEach(function(m){return m()}),c=[]}return f}}w3();var xX=[CM,$M,wM,gM];w3({defaultModifiers:xX});var MX=[CM,$M,wM,gM,hX,uX,yX,GJ,dX],TX=w3({defaultModifiers:MX});const OX=(e,t,n={})=>{const o={name:"updateState",enabled:!0,phase:"write",fn:({state:a})=>{const u=IX(a);Object.assign(i.value,u)},requires:["computeStyles"]},r=R(()=>{const{onFirstUpdate:a,placement:u,strategy:c,modifiers:d}=g(n);return{onFirstUpdate:a,placement:u||"bottom",strategy:c||"absolute",modifiers:[...d||[],o,{name:"applyStyles",enabled:!1}]}}),s=Tn(),i=K({styles:{popper:{position:g(r).strategy,left:"0",top:"0"},arrow:{position:"absolute"}},attributes:{}}),l=()=>{s.value&&(s.value.destroy(),s.value=void 0)};return Te(r,a=>{const u=g(s);u&&u.setOptions(a)},{deep:!0}),Te([e,t],([a,u])=>{l(),!(!a||!u)&&(s.value=TX(a,u,g(r)))}),En(()=>{l()}),{state:R(()=>{var a;return{...((a=g(s))==null?void 0:a.state)||{}}}),styles:R(()=>g(i).styles),attributes:R(()=>g(i).attributes),update:()=>{var a;return(a=g(s))==null?void 0:a.update()},forceUpdate:()=>{var a;return(a=g(s))==null?void 0:a.forceUpdate()},instanceRef:R(()=>g(s))}};function IX(e){const t=Object.keys(e.elements),n=Tg(t.map(r=>[r,e.styles[r]||{}])),o=Tg(t.map(r=>[r,e.attributes[r]]));return{styles:n,attributes:o}}const C3=e=>{if(!e)return{onClick:yt,onMousedown:yt,onMouseup:yt};let t=!1,n=!1;return{onClick:i=>{t&&n&&e(i),t=n=!1},onMousedown:i=>{t=i.target===i.currentTarget},onMouseup:i=>{n=i.target===i.currentTarget}}},AX=(e,t=0)=>{if(t===0)return e;const n=K(!1);let o=0;const r=()=>{o&&clearTimeout(o),o=window.setTimeout(()=>{n.value=e.value},t)};return Ct(r),Te(()=>e.value,s=>{s?r():n.value=s}),n};function b5(){let e;const t=(o,r)=>{n(),e=window.setTimeout(o,r)},n=()=>window.clearTimeout(e);return oh(()=>n()),{registerTimeout:t,cancelTimeout:n}}const w5={prefix:Math.floor(Math.random()*1e4),current:0},NX=Symbol("elIdInjection"),EM=()=>at()?Be(NX,w5):w5,Hr=e=>{const t=EM(),n=p3();return R(()=>g(e)||`${n.value}-id-${t.prefix}-${t.current++}`)};let Ku=[];const C5=e=>{const t=e;t.key===rt.esc&&Ku.forEach(n=>n(t))},PX=e=>{Ct(()=>{Ku.length===0&&document.addEventListener("keydown",C5),xt&&Ku.push(e)}),En(()=>{Ku=Ku.filter(t=>t!==e),Ku.length===0&&xt&&document.removeEventListener("keydown",C5)})};let k5;const xM=()=>{const e=p3(),t=EM(),n=R(()=>`${e.value}-popper-container-${t.prefix}`),o=R(()=>`#${n.value}`);return{id:n,selector:o}},LX=e=>{const t=document.createElement("div");return t.id=e,document.body.appendChild(t),t},RX=()=>{const{id:e,selector:t}=xM();return yd(()=>{xt&&!k5&&!document.body.querySelector(t.value)&&(k5=LX(e.value))}),{id:e,selector:t}},DX=We({showAfter:{type:Number,default:0},hideAfter:{type:Number,default:200},autoClose:{type:Number,default:0}}),FX=({showAfter:e,hideAfter:t,autoClose:n,open:o,close:r})=>{const{registerTimeout:s}=b5(),{registerTimeout:i,cancelTimeout:l}=b5();return{onOpen:c=>{s(()=>{o(c);const d=g(n);_t(d)&&d>0&&i(()=>{r(c)},d)},g(e))},onClose:c=>{l(),s(()=>{r(c)},g(t))}}},MM=Symbol("elForwardRef"),VX=e=>{wt(MM,{setForwardRef:n=>{e.value=n}})},BX=e=>({mounted(t){e(t)},updated(t){e(t)},unmounted(){e(null)}}),S5={current:0},$5=K(0),TM=2e3,E5=Symbol("elZIndexContextKey"),OM=Symbol("zIndexContextKey"),D0=e=>{const t=at()?Be(E5,S5):S5,n=e||(at()?Be(OM,void 0):void 0),o=R(()=>{const i=g(n);return _t(i)?i:TM}),r=R(()=>o.value+$5.value),s=()=>(t.current++,$5.value=t.current,r.value);return!xt&&Be(E5),{initialZIndex:o,currentZIndex:r,nextZIndex:s}},x5=Math.min,Kf=Math.max,Ag=Math.round,Hl=e=>({x:e,y:e}),zX={left:"right",right:"left",bottom:"top",top:"bottom"},jX={start:"end",end:"start"};function k3(e,t){return typeof e=="function"?e(t):e}function rd(e){return e.split("-")[0]}function F0(e){return e.split("-")[1]}function HX(e){return e==="x"?"y":"x"}function IM(e){return e==="y"?"height":"width"}function S3(e){return["top","bottom"].includes(rd(e))?"y":"x"}function AM(e){return HX(S3(e))}function UX(e,t,n){n===void 0&&(n=!1);const o=F0(e),r=AM(e),s=IM(r);let i=r==="x"?o===(n?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=Ng(i)),[i,Ng(i)]}function WX(e){const t=Ng(e);return[J_(e),t,J_(t)]}function J_(e){return e.replace(/start|end/g,t=>jX[t])}function KX(e,t,n){const o=["left","right"],r=["right","left"],s=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return n?t?r:o:t?o:r;case"left":case"right":return t?s:i;default:return[]}}function qX(e,t,n,o){const r=F0(e);let s=KX(rd(e),n==="start",o);return r&&(s=s.map(i=>i+"-"+r),t&&(s=s.concat(s.map(J_)))),s}function Ng(e){return e.replace(/left|right|bottom|top/g,t=>zX[t])}function GX(e){return{top:0,right:0,bottom:0,left:0,...e}}function YX(e){return typeof e!="number"?GX(e):{top:e,right:e,bottom:e,left:e}}function Pg(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function M5(e,t,n){let{reference:o,floating:r}=e;const s=S3(t),i=AM(t),l=IM(i),a=rd(t),u=s==="y",c=o.x+o.width/2-r.width/2,d=o.y+o.height/2-r.height/2,f=o[l]/2-r[l]/2;let p;switch(a){case"top":p={x:c,y:o.y-r.height};break;case"bottom":p={x:c,y:o.y+o.height};break;case"right":p={x:o.x+o.width,y:d};break;case"left":p={x:o.x-r.width,y:d};break;default:p={x:o.x,y:o.y}}switch(F0(t)){case"start":p[i]-=f*(n&&u?-1:1);break;case"end":p[i]+=f*(n&&u?-1:1);break}return p}const ZX=async(e,t,n)=>{const{placement:o="bottom",strategy:r="absolute",middleware:s=[],platform:i}=n,l=s.filter(Boolean),a=await(i.isRTL==null?void 0:i.isRTL(t));let u=await i.getElementRects({reference:e,floating:t,strategy:r}),{x:c,y:d}=M5(u,o,a),f=o,p={},h=0;for(let m=0;m<l.length;m++){const{name:y,fn:v}=l[m],{x:w,y:_,data:S,reset:x}=await v({x:c,y:d,initialPlacement:o,placement:f,strategy:r,middlewareData:p,rects:u,platform:i,elements:{reference:e,floating:t}});c=w??c,d=_??d,p={...p,[y]:{...p[y],...S}},x&&h<=50&&(h++,typeof x=="object"&&(x.placement&&(f=x.placement),x.rects&&(u=x.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:r}):x.rects),{x:c,y:d}=M5(u,f,a)),m=-1)}return{x:c,y:d,placement:f,strategy:r,middlewareData:p}};async function JX(e,t){var n;t===void 0&&(t={});const{x:o,y:r,platform:s,rects:i,elements:l,strategy:a}=e,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=k3(t,e),h=YX(p),y=l[f?d==="floating"?"reference":"floating":d],v=Pg(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(y)))==null||n?y:y.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(l.floating)),boundary:u,rootBoundary:c,strategy:a})),w=d==="floating"?{...i.floating,x:o,y:r}:i.reference,_=await(s.getOffsetParent==null?void 0:s.getOffsetParent(l.floating)),S=await(s.isElement==null?void 0:s.isElement(_))?await(s.getScale==null?void 0:s.getScale(_))||{x:1,y:1}:{x:1,y:1},x=Pg(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:w,offsetParent:_,strategy:a}):w);return{top:(v.top-x.top+h.top)/S.y,bottom:(x.bottom-v.bottom+h.bottom)/S.y,left:(v.left-x.left+h.left)/S.x,right:(x.right-v.right+h.right)/S.x}}const XX=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,o;const{placement:r,middlewareData:s,rects:i,initialPlacement:l,platform:a,elements:u}=t,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:h="none",flipAlignment:m=!0,...y}=k3(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const v=rd(r),w=rd(l)===l,_=await(a.isRTL==null?void 0:a.isRTL(u.floating)),S=f||(w||!m?[Ng(l)]:WX(l));!f&&h!=="none"&&S.push(...qX(l,m,h,_));const x=[l,...S],E=await JX(t,y),T=[];let O=((o=s.flip)==null?void 0:o.overflows)||[];if(c&&T.push(E[v]),d){const B=UX(r,i,_);T.push(E[B[0]],E[B[1]])}if(O=[...O,{placement:r,overflows:T}],!T.every(B=>B<=0)){var P,N;const B=(((P=s.flip)==null?void 0:P.index)||0)+1,Y=x[B];if(Y)return{data:{index:B,overflows:O},reset:{placement:Y}};let Z=(N=O.filter(U=>U.overflows[0]<=0).sort((U,j)=>U.overflows[1]-j.overflows[1])[0])==null?void 0:N.placement;if(!Z)switch(p){case"bestFit":{var F;const U=(F=O.map(j=>[j.placement,j.overflows.filter(V=>V>0).reduce((V,H)=>V+H,0)]).sort((j,V)=>j[1]-V[1])[0])==null?void 0:F[0];U&&(Z=U);break}case"initialPlacement":Z=l;break}if(r!==Z)return{reset:{placement:Z}}}return{}}}};async function QX(e,t){const{placement:n,platform:o,elements:r}=e,s=await(o.isRTL==null?void 0:o.isRTL(r.floating)),i=rd(n),l=F0(n),a=S3(n)==="y",u=["left","top"].includes(i)?-1:1,c=s&&a?-1:1,d=k3(t,e);let{mainAxis:f,crossAxis:p,alignmentAxis:h}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...d};return l&&typeof h=="number"&&(p=l==="end"?h*-1:h),a?{x:p*c,y:f*u}:{x:f*u,y:p*c}}const X_=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,o;const{x:r,y:s,placement:i,middlewareData:l}=t,a=await QX(t,e);return i===((n=l.offset)==null?void 0:n.placement)&&(o=l.arrow)!=null&&o.alignmentOffset?{}:{x:r+a.x,y:s+a.y,data:{...a,placement:i}}}}};function Ul(e){return NM(e)?(e.nodeName||"").toLowerCase():"#document"}function mr(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Xl(e){var t;return(t=(NM(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function NM(e){return e instanceof Node||e instanceof mr(e).Node}function Li(e){return e instanceof Element||e instanceof mr(e).Element}function Zs(e){return e instanceof HTMLElement||e instanceof mr(e).HTMLElement}function T5(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof mr(e).ShadowRoot}function fh(e){const{overflow:t,overflowX:n,overflowY:o,display:r}=Ur(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+n)&&!["inline","contents"].includes(r)}function eQ(e){return["table","td","th"].includes(Ul(e))}function $3(e){const t=E3(),n=Ur(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(o=>(n.willChange||"").includes(o))||["paint","layout","strict","content"].some(o=>(n.contain||"").includes(o))}function tQ(e){let t=sd(e);for(;Zs(t)&&!V0(t);){if($3(t))return t;t=sd(t)}return null}function E3(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function V0(e){return["html","body","#document"].includes(Ul(e))}function Ur(e){return mr(e).getComputedStyle(e)}function B0(e){return Li(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function sd(e){if(Ul(e)==="html")return e;const t=e.assignedSlot||e.parentNode||T5(e)&&e.host||Xl(e);return T5(t)?t.host:t}function PM(e){const t=sd(e);return V0(t)?e.ownerDocument?e.ownerDocument.body:e.body:Zs(t)&&fh(t)?t:PM(t)}function Q_(e,t,n){var o;t===void 0&&(t=[]),n===void 0&&(n=!0);const r=PM(e),s=r===((o=e.ownerDocument)==null?void 0:o.body),i=mr(r);return s?t.concat(i,i.visualViewport||[],fh(r)?r:[],i.frameElement&&n?Q_(i.frameElement):[]):t.concat(r,Q_(r,[],n))}function LM(e){const t=Ur(e);let n=parseFloat(t.width)||0,o=parseFloat(t.height)||0;const r=Zs(e),s=r?e.offsetWidth:n,i=r?e.offsetHeight:o,l=Ag(n)!==s||Ag(o)!==i;return l&&(n=s,o=i),{width:n,height:o,$:l}}function RM(e){return Li(e)?e:e.contextElement}function Sc(e){const t=RM(e);if(!Zs(t))return Hl(1);const n=t.getBoundingClientRect(),{width:o,height:r,$:s}=LM(t);let i=(s?Ag(n.width):n.width)/o,l=(s?Ag(n.height):n.height)/r;return(!i||!Number.isFinite(i))&&(i=1),(!l||!Number.isFinite(l))&&(l=1),{x:i,y:l}}const nQ=Hl(0);function DM(e){const t=mr(e);return!E3()||!t.visualViewport?nQ:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function oQ(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==mr(e)?!1:t}function Lp(e,t,n,o){t===void 0&&(t=!1),n===void 0&&(n=!1);const r=e.getBoundingClientRect(),s=RM(e);let i=Hl(1);t&&(o?Li(o)&&(i=Sc(o)):i=Sc(e));const l=oQ(s,n,o)?DM(s):Hl(0);let a=(r.left+l.x)/i.x,u=(r.top+l.y)/i.y,c=r.width/i.x,d=r.height/i.y;if(s){const f=mr(s),p=o&&Li(o)?mr(o):o;let h=f,m=h.frameElement;for(;m&&o&&p!==h;){const y=Sc(m),v=m.getBoundingClientRect(),w=Ur(m),_=v.left+(m.clientLeft+parseFloat(w.paddingLeft))*y.x,S=v.top+(m.clientTop+parseFloat(w.paddingTop))*y.y;a*=y.x,u*=y.y,c*=y.x,d*=y.y,a+=_,u+=S,h=mr(m),m=h.frameElement}}return Pg({width:c,height:d,x:a,y:u})}const rQ=[":popover-open",":modal"];function FM(e){return rQ.some(t=>{try{return e.matches(t)}catch{return!1}})}function sQ(e){let{elements:t,rect:n,offsetParent:o,strategy:r}=e;const s=r==="fixed",i=Xl(o),l=t?FM(t.floating):!1;if(o===i||l&&s)return n;let a={scrollLeft:0,scrollTop:0},u=Hl(1);const c=Hl(0),d=Zs(o);if((d||!d&&!s)&&((Ul(o)!=="body"||fh(i))&&(a=B0(o)),Zs(o))){const f=Lp(o);u=Sc(o),c.x=f.x+o.clientLeft,c.y=f.y+o.clientTop}return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-a.scrollLeft*u.x+c.x,y:n.y*u.y-a.scrollTop*u.y+c.y}}function iQ(e){return Array.from(e.getClientRects())}function VM(e){return Lp(Xl(e)).left+B0(e).scrollLeft}function lQ(e){const t=Xl(e),n=B0(e),o=e.ownerDocument.body,r=Kf(t.scrollWidth,t.clientWidth,o.scrollWidth,o.clientWidth),s=Kf(t.scrollHeight,t.clientHeight,o.scrollHeight,o.clientHeight);let i=-n.scrollLeft+VM(e);const l=-n.scrollTop;return Ur(o).direction==="rtl"&&(i+=Kf(t.clientWidth,o.clientWidth)-r),{width:r,height:s,x:i,y:l}}function aQ(e,t){const n=mr(e),o=Xl(e),r=n.visualViewport;let s=o.clientWidth,i=o.clientHeight,l=0,a=0;if(r){s=r.width,i=r.height;const u=E3();(!u||u&&t==="fixed")&&(l=r.offsetLeft,a=r.offsetTop)}return{width:s,height:i,x:l,y:a}}function uQ(e,t){const n=Lp(e,!0,t==="fixed"),o=n.top+e.clientTop,r=n.left+e.clientLeft,s=Zs(e)?Sc(e):Hl(1),i=e.clientWidth*s.x,l=e.clientHeight*s.y,a=r*s.x,u=o*s.y;return{width:i,height:l,x:a,y:u}}function O5(e,t,n){let o;if(t==="viewport")o=aQ(e,n);else if(t==="document")o=lQ(Xl(e));else if(Li(t))o=uQ(t,n);else{const r=DM(e);o={...t,x:t.x-r.x,y:t.y-r.y}}return Pg(o)}function BM(e,t){const n=sd(e);return n===t||!Li(n)||V0(n)?!1:Ur(n).position==="fixed"||BM(n,t)}function cQ(e,t){const n=t.get(e);if(n)return n;let o=Q_(e,[],!1).filter(l=>Li(l)&&Ul(l)!=="body"),r=null;const s=Ur(e).position==="fixed";let i=s?sd(e):e;for(;Li(i)&&!V0(i);){const l=Ur(i),a=$3(i);!a&&l.position==="fixed"&&(r=null),(s?!a&&!r:!a&&l.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||fh(i)&&!a&&BM(e,i))?o=o.filter(c=>c!==i):r=l,i=sd(i)}return t.set(e,o),o}function dQ(e){let{element:t,boundary:n,rootBoundary:o,strategy:r}=e;const i=[...n==="clippingAncestors"?cQ(t,this._c):[].concat(n),o],l=i[0],a=i.reduce((u,c)=>{const d=O5(t,c,r);return u.top=Kf(d.top,u.top),u.right=x5(d.right,u.right),u.bottom=x5(d.bottom,u.bottom),u.left=Kf(d.left,u.left),u},O5(t,l,r));return{width:a.right-a.left,height:a.bottom-a.top,x:a.left,y:a.top}}function fQ(e){const{width:t,height:n}=LM(e);return{width:t,height:n}}function pQ(e,t,n){const o=Zs(t),r=Xl(t),s=n==="fixed",i=Lp(e,!0,s,t);let l={scrollLeft:0,scrollTop:0};const a=Hl(0);if(o||!o&&!s)if((Ul(t)!=="body"||fh(r))&&(l=B0(t)),o){const d=Lp(t,!0,s,t);a.x=d.x+t.clientLeft,a.y=d.y+t.clientTop}else r&&(a.x=VM(r));const u=i.left+l.scrollLeft-a.x,c=i.top+l.scrollTop-a.y;return{x:u,y:c,width:i.width,height:i.height}}function I5(e,t){return!Zs(e)||Ur(e).position==="fixed"?null:t?t(e):e.offsetParent}function zM(e,t){const n=mr(e);if(!Zs(e)||FM(e))return n;let o=I5(e,t);for(;o&&eQ(o)&&Ur(o).position==="static";)o=I5(o,t);return o&&(Ul(o)==="html"||Ul(o)==="body"&&Ur(o).position==="static"&&!$3(o))?n:o||tQ(e)||n}const hQ=async function(e){const t=this.getOffsetParent||zM,n=this.getDimensions;return{reference:pQ(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,...await n(e.floating)}}};function mQ(e){return Ur(e).direction==="rtl"}const gQ={convertOffsetParentRelativeRectToViewportRelativeRect:sQ,getDocumentElement:Xl,getClippingRect:dQ,getOffsetParent:zM,getElementRects:hQ,getClientRects:iQ,getDimensions:fQ,getScale:Sc,isElement:Li,isRTL:mQ},eb=XX,tb=(e,t,n)=>{const o=new Map,r={platform:gQ,...n},s={...r.platform,_c:o};return ZX(e,t,{...r,platform:s})};function vQ(e){const t=K();function n(){if(e.value==null)return;const{selectionStart:r,selectionEnd:s,value:i}=e.value;if(r==null||s==null)return;const l=i.slice(0,Math.max(0,r)),a=i.slice(Math.max(0,s));t.value={selectionStart:r,selectionEnd:s,value:i,beforeTxt:l,afterTxt:a}}function o(){if(e.value==null||t.value==null)return;const{value:r}=e.value,{beforeTxt:s,afterTxt:i,selectionStart:l}=t.value;if(s==null||i==null||l==null)return;let a=r.length;if(r.endsWith(i))a=r.length-i.length;else if(r.startsWith(s))a=s.length;else{const u=s[l-1],c=r.indexOf(u,l-1);c!==-1&&(a=c+1)}e.value.setSelectionRange(a,a)}return[n,o]}const yQ=(e,t,n)=>Ym(e.subTree).filter(s=>{var i;return yo(s)&&((i=s.type)==null?void 0:i.name)===t&&!!s.component}).map(s=>s.component.uid).map(s=>n[s]).filter(s=>!!s),_Q=(e,t)=>{const n={},o=Tn([]);return{children:o,addChild:i=>{n[i.uid]=i,o.value=yQ(e,t,n)},removeChild:i=>{delete n[i],o.value=o.value.filter(l=>l.uid!==i)}}},qr=P0({type:String,values:Zl,required:!1}),jM=Symbol("size"),bQ=()=>{const e=Be(jM,{});return R(()=>g(e.size)||"")};function x3(e,{afterFocus:t,beforeBlur:n,afterBlur:o}={}){const r=at(),{emit:s}=r,i=Tn(),l=K(!1),a=d=>{l.value||(l.value=!0,s("focus",d),t==null||t())},u=d=>{var f;Xe(n)&&n(d)||d.relatedTarget&&((f=i.value)!=null&&f.contains(d.relatedTarget))||(l.value=!1,s("blur",d),o==null||o())},c=()=>{var d;(d=e.value)==null||d.focus()};return Te(i,d=>{d&&d.setAttribute("tabindex","-1")}),Ln(i,"click",c),{wrapperRef:i,isFocused:l,handleFocus:a,handleBlur:u}}const wQ=["",void 0,null],CQ=void 0,M3=We({emptyValues:Array,valueOnClear:{type:[String,Number,Boolean,Function],default:void 0,validator:e=>Xe(e)?!e():!e}}),HM=(e,t)=>{const n=ph();n.value=n.value||{};const o=R(()=>e.emptyValues||n.value.emptyValues||wQ),r=R(()=>Xe(e.valueOnClear)?e.valueOnClear():e.valueOnClear!==void 0?e.valueOnClear:Xe(n.value.valueOnClear)?n.value.valueOnClear():n.value.valueOnClear!==void 0?n.value.valueOnClear:t!==void 0?t:CQ),s=i=>o.value.includes(i);return o.value.includes(r.value),{emptyValues:o,valueOnClear:r,isEmptyValue:s}},UM=Symbol(),Lg=K();function ph(e,t=void 0){const n=at()?Be(UM,Lg):Lg;return e?R(()=>{var o,r;return(r=(o=n.value)==null?void 0:o[e])!=null?r:t}):n}function T3(e,t){const n=ph(),o=Re(e,R(()=>{var l;return((l=n.value)==null?void 0:l.namespace)||Hf})),r=Kt(R(()=>{var l;return(l=n.value)==null?void 0:l.locale})),s=D0(R(()=>{var l;return((l=n.value)==null?void 0:l.zIndex)||TM})),i=R(()=>{var l;return g(t)||((l=n.value)==null?void 0:l.size)||""});return kQ(R(()=>g(n)||{})),{ns:o,locale:r,zIndex:s,size:i}}const kQ=(e,t,n=!1)=>{var o;const r=!!at(),s=r?ph():void 0,i=(o=t==null?void 0:t.provide)!=null?o:r?wt:void 0;if(!i)return;const l=R(()=>{const a=g(e);return s!=null&&s.value?SQ(s.value,a):a});return i(UM,l),i(cM,R(()=>l.value.locale)),i(dM,R(()=>l.value.namespace)),i(OM,R(()=>l.value.zIndex)),i(jM,{size:R(()=>l.value.size||"")}),(n||!Lg.value)&&(Lg.value=l.value),l},SQ=(e,t)=>{const n=[...new Set([...G_(e),...G_(t)])],o={};for(const r of n)o[r]=t[r]!==void 0?t[r]:e[r];return o};var ze=(e,t)=>{const n=e.__vccOpts||e;for(const[o,r]of t)n[o]=r;return n};const $Q=We({size:{type:Ce([Number,String])},color:{type:String}}),EQ=Q({name:"ElIcon",inheritAttrs:!1}),xQ=Q({...EQ,props:$Q,setup(e){const t=e,n=Re("icon"),o=R(()=>{const{size:r,color:s}=t;return!r&&!s?{}:{fontSize:Uo(r)?void 0:Zo(r),"--color":s}});return(r,s)=>(C(),M("i",un({class:g(n).b(),style:g(o)},r.$attrs),[he(r.$slots,"default")],16))}});var MQ=ze(xQ,[["__file","icon.vue"]]);const Ne=Zt(MQ),kd=Symbol("formContextKey"),uu=Symbol("formItemContextKey"),Jo=(e,t={})=>{const n=K(void 0),o=t.prop?n:hM("size"),r=t.global?n:bQ(),s=t.form?{size:void 0}:Be(kd,void 0),i=t.formItem?{size:void 0}:Be(uu,void 0);return R(()=>o.value||g(e)||(i==null?void 0:i.size)||(s==null?void 0:s.size)||r.value||"")},Gr=e=>{const t=hM("disabled"),n=Be(kd,void 0);return R(()=>t.value||g(e)||(n==null?void 0:n.disabled)||!1)},ni=()=>{const e=Be(kd,void 0),t=Be(uu,void 0);return{form:e,formItem:t}},Sd=(e,{formItemContext:t,disableIdGeneration:n,disableIdManagement:o})=>{n||(n=K(!1)),o||(o=K(!1));const r=K();let s;const i=R(()=>{var l;return!!(!e.label&&t&&t.inputIds&&((l=t.inputIds)==null?void 0:l.length)<=1)});return Ct(()=>{s=Te([pn(e,"id"),n],([l,a])=>{const u=l??(a?void 0:Hr().value);u!==r.value&&(t!=null&&t.removeInputId&&(r.value&&t.removeInputId(r.value),!(o!=null&&o.value)&&!a&&u&&t.addInputId(u)),r.value=u)},{immediate:!0})}),ti(()=>{s&&s(),t!=null&&t.removeInputId&&r.value&&t.removeInputId(r.value)}),{isLabeledByFormItem:i,inputId:r}},TQ=We({size:{type:String,values:Zl},disabled:Boolean}),OQ=We({...TQ,model:Object,rules:{type:Ce(Object)},labelPosition:{type:String,values:["left","right","top"],default:"right"},requireAsteriskPosition:{type:String,values:["left","right"],default:"left"},labelWidth:{type:[String,Number],default:""},labelSuffix:{type:String,default:""},inline:Boolean,inlineMessage:Boolean,statusIcon:Boolean,showMessage:{type:Boolean,default:!0},validateOnRuleChange:{type:Boolean,default:!0},hideRequiredAsterisk:Boolean,scrollToError:Boolean,scrollIntoViewOptions:{type:[Object,Boolean]}}),IQ={validate:(e,t,n)=>(Me(e)||tt(e))&&Br(t)&&tt(n)};function AQ(){const e=K([]),t=R(()=>{if(!e.value.length)return"0";const s=Math.max(...e.value);return s?`${s}px`:""});function n(s){const i=e.value.indexOf(s);return i===-1&&t.value,i}function o(s,i){if(s&&i){const l=n(i);e.value.splice(l,1,s)}else s&&e.value.push(s)}function r(s){const i=n(s);i>-1&&e.value.splice(i,1)}return{autoLabelWidth:t,registerLabelWidth:o,deregisterLabelWidth:r}}const um=(e,t)=>{const n=Eg(t);return n.length>0?e.filter(o=>o.prop&&n.includes(o.prop)):e},NQ="ElForm",PQ=Q({name:NQ}),LQ=Q({...PQ,props:OQ,emits:IQ,setup(e,{expose:t,emit:n}){const o=e,r=[],s=Jo(),i=Re("form"),l=R(()=>{const{labelPosition:_,inline:S}=o;return[i.b(),i.m(s.value||"default"),{[i.m(`label-${_}`)]:_,[i.m("inline")]:S}]}),a=_=>r.find(S=>S.prop===_),u=_=>{r.push(_)},c=_=>{_.prop&&r.splice(r.indexOf(_),1)},d=(_=[])=>{o.model&&um(r,_).forEach(S=>S.resetField())},f=(_=[])=>{um(r,_).forEach(S=>S.clearValidate())},p=R(()=>!!o.model),h=_=>{if(r.length===0)return[];const S=um(r,_);return S.length?S:[]},m=async _=>v(void 0,_),y=async(_=[])=>{if(!p.value)return!1;const S=h(_);if(S.length===0)return!0;let x={};for(const E of S)try{await E.validate("")}catch(T){x={...x,...T}}return Object.keys(x).length===0?!0:Promise.reject(x)},v=async(_=[],S)=>{const x=!Xe(S);try{const E=await y(_);return E===!0&&(S==null||S(E)),E}catch(E){if(E instanceof Error)throw E;const T=E;return o.scrollToError&&w(Object.keys(T)[0]),S==null||S(!1,T),x&&Promise.reject(T)}},w=_=>{var S;const x=um(r,_)[0];x&&((S=x.$el)==null||S.scrollIntoView(o.scrollIntoViewOptions))};return Te(()=>o.rules,()=>{o.validateOnRuleChange&&m().catch(_=>void 0)},{deep:!0}),wt(kd,Dn({...ei(o),emit:n,resetFields:d,clearValidate:f,validateField:v,getField:a,addField:u,removeField:c,...AQ()})),t({validate:m,validateField:v,resetFields:d,clearValidate:f,scrollToField:w}),(_,S)=>(C(),M("form",{class:D(g(l))},[he(_.$slots,"default")],2))}});var RQ=ze(LQ,[["__file","form.vue"]]);function Ia(){return Ia=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e},Ia.apply(this,arguments)}function DQ(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Rp(e,t)}function nb(e){return nb=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},nb(e)}function Rp(e,t){return Rp=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(o,r){return o.__proto__=r,o},Rp(e,t)}function FQ(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Jm(e,t,n){return FQ()?Jm=Reflect.construct.bind():Jm=function(r,s,i){var l=[null];l.push.apply(l,s);var a=Function.bind.apply(r,l),u=new a;return i&&Rp(u,i.prototype),u},Jm.apply(null,arguments)}function VQ(e){return Function.toString.call(e).indexOf("[native code]")!==-1}function ob(e){var t=typeof Map=="function"?new Map:void 0;return ob=function(o){if(o===null||!VQ(o))return o;if(typeof o!="function")throw new TypeError("Super expression must either be null or a function");if(typeof t<"u"){if(t.has(o))return t.get(o);t.set(o,r)}function r(){return Jm(o,arguments,nb(this).constructor)}return r.prototype=Object.create(o.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),Rp(r,o)},ob(e)}var BQ=/%[sdj%]/g,zQ=function(){};typeof process<"u"&&process.env;function rb(e){if(!e||!e.length)return null;var t={};return e.forEach(function(n){var o=n.field;t[o]=t[o]||[],t[o].push(n)}),t}function dr(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];var r=0,s=n.length;if(typeof e=="function")return e.apply(null,n);if(typeof e=="string"){var i=e.replace(BQ,function(l){if(l==="%%")return"%";if(r>=s)return l;switch(l){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch{return"[Circular]"}break;default:return l}});return i}return e}function jQ(e){return e==="string"||e==="url"||e==="hex"||e==="email"||e==="date"||e==="pattern"}function jn(e,t){return!!(e==null||t==="array"&&Array.isArray(e)&&!e.length||jQ(t)&&typeof e=="string"&&!e)}function HQ(e,t,n){var o=[],r=0,s=e.length;function i(l){o.push.apply(o,l||[]),r++,r===s&&n(o)}e.forEach(function(l){t(l,i)})}function A5(e,t,n){var o=0,r=e.length;function s(i){if(i&&i.length){n(i);return}var l=o;o=o+1,l<r?t(e[l],s):n([])}s([])}function UQ(e){var t=[];return Object.keys(e).forEach(function(n){t.push.apply(t,e[n]||[])}),t}var N5=function(e){DQ(t,e);function t(n,o){var r;return r=e.call(this,"Async Validation Error")||this,r.errors=n,r.fields=o,r}return t}(ob(Error));function WQ(e,t,n,o,r){if(t.first){var s=new Promise(function(f,p){var h=function(v){return o(v),v.length?p(new N5(v,rb(v))):f(r)},m=UQ(e);A5(m,n,h)});return s.catch(function(f){return f}),s}var i=t.firstFields===!0?Object.keys(e):t.firstFields||[],l=Object.keys(e),a=l.length,u=0,c=[],d=new Promise(function(f,p){var h=function(y){if(c.push.apply(c,y),u++,u===a)return o(c),c.length?p(new N5(c,rb(c))):f(r)};l.length||(o(c),f(r)),l.forEach(function(m){var y=e[m];i.indexOf(m)!==-1?A5(y,n,h):HQ(y,n,h)})});return d.catch(function(f){return f}),d}function KQ(e){return!!(e&&e.message!==void 0)}function qQ(e,t){for(var n=e,o=0;o<t.length;o++){if(n==null)return n;n=n[t[o]]}return n}function P5(e,t){return function(n){var o;return e.fullFields?o=qQ(t,e.fullFields):o=t[n.field||e.fullField],KQ(n)?(n.field=n.field||e.fullField,n.fieldValue=o,n):{message:typeof n=="function"?n():n,fieldValue:o,field:n.field||e.fullField}}}function L5(e,t){if(t){for(var n in t)if(t.hasOwnProperty(n)){var o=t[n];typeof o=="object"&&typeof e[n]=="object"?e[n]=Ia({},e[n],o):e[n]=o}}return e}var WM=function(t,n,o,r,s,i){t.required&&(!o.hasOwnProperty(t.field)||jn(n,i||t.type))&&r.push(dr(s.messages.required,t.fullField))},GQ=function(t,n,o,r,s){(/^\s+$/.test(n)||n==="")&&r.push(dr(s.messages.whitespace,t.fullField))},cm,YQ=function(){if(cm)return cm;var e="[a-fA-F\\d:]",t=function(S){return S&&S.includeBoundaries?"(?:(?<=\\s|^)(?="+e+")|(?<="+e+")(?=\\s|$))":""},n="(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}",o="[a-fA-F\\d]{1,4}",r=(`
40 (?:
41 (?:`+o+":){7}(?:"+o+`|:)| // 1:2:3:4:5:6:7:: 1:2:3:4:5:6:7:8
42 (?:`+o+":){6}(?:"+n+"|:"+o+`|:)| // 1:2:3:4:5:6:: 1:2:3:4:5:6::8 1:2:3:4:5:6::8 1:2:3:4:5:6::1.2.3.4
43 (?:`+o+":){5}(?::"+n+"|(?::"+o+`){1,2}|:)| // 1:2:3:4:5:: 1:2:3:4:5::7:8 1:2:3:4:5::8 1:2:3:4:5::7:1.2.3.4
44 (?:`+o+":){4}(?:(?::"+o+"){0,1}:"+n+"|(?::"+o+`){1,3}|:)| // 1:2:3:4:: 1:2:3:4::6:7:8 1:2:3:4::8 1:2:3:4::6:7:1.2.3.4
45 (?:`+o+":){3}(?:(?::"+o+"){0,2}:"+n+"|(?::"+o+`){1,4}|:)| // 1:2:3:: 1:2:3::5:6:7:8 1:2:3::8 1:2:3::5:6:7:1.2.3.4
46 (?:`+o+":){2}(?:(?::"+o+"){0,3}:"+n+"|(?::"+o+`){1,5}|:)| // 1:2:: 1:2::4:5:6:7:8 1:2::8 1:2::4:5:6:7:1.2.3.4
47 (?:`+o+":){1}(?:(?::"+o+"){0,4}:"+n+"|(?::"+o+`){1,6}|:)| // 1:: 1::3:4:5:6:7:8 1::8 1::3:4:5:6:7:1.2.3.4
48 (?::(?:(?::`+o+"){0,5}:"+n+"|(?::"+o+`){1,7}|:)) // ::2:3:4:5:6:7:8 ::2:3:4:5:6:7:8 ::8 ::1.2.3.4
49 )(?:%[0-9a-zA-Z]{1,})? // %eth0 %1
50 `).replace(/\s*\/\/.*$/gm,"").replace(/\n/g,"").trim(),s=new RegExp("(?:^"+n+"$)|(?:^"+r+"$)"),i=new RegExp("^"+n+"$"),l=new RegExp("^"+r+"$"),a=function(S){return S&&S.exact?s:new RegExp("(?:"+t(S)+n+t(S)+")|(?:"+t(S)+r+t(S)+")","g")};a.v4=function(_){return _&&_.exact?i:new RegExp(""+t(_)+n+t(_),"g")},a.v6=function(_){return _&&_.exact?l:new RegExp(""+t(_)+r+t(_),"g")};var u="(?:(?:[a-z]+:)?//)",c="(?:\\S+(?::\\S*)?@)?",d=a.v4().source,f=a.v6().source,p="(?:(?:[a-z\\u00a1-\\uffff0-9][-_]*)*[a-z\\u00a1-\\uffff0-9]+)",h="(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*",m="(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))",y="(?::\\d{2,5})?",v='(?:[/?#][^\\s"]*)?',w="(?:"+u+"|www\\.)"+c+"(?:localhost|"+d+"|"+f+"|"+p+h+m+")"+y+v;return cm=new RegExp("(?:^"+w+"$)","i"),cm},R5={email:/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+\.)+[a-zA-Z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}))$/,hex:/^#?([a-f0-9]{6}|[a-f0-9]{3})$/i},Xd={integer:function(t){return Xd.number(t)&&parseInt(t,10)===t},float:function(t){return Xd.number(t)&&!Xd.integer(t)},array:function(t){return Array.isArray(t)},regexp:function(t){if(t instanceof RegExp)return!0;try{return!!new RegExp(t)}catch{return!1}},date:function(t){return typeof t.getTime=="function"&&typeof t.getMonth=="function"&&typeof t.getYear=="function"&&!isNaN(t.getTime())},number:function(t){return isNaN(t)?!1:typeof t=="number"},object:function(t){return typeof t=="object"&&!Xd.array(t)},method:function(t){return typeof t=="function"},email:function(t){return typeof t=="string"&&t.length<=320&&!!t.match(R5.email)},url:function(t){return typeof t=="string"&&t.length<=2048&&!!t.match(YQ())},hex:function(t){return typeof t=="string"&&!!t.match(R5.hex)}},ZQ=function(t,n,o,r,s){if(t.required&&n===void 0){WM(t,n,o,r,s);return}var i=["integer","float","array","regexp","object","method","email","number","date","url","hex"],l=t.type;i.indexOf(l)>-1?Xd[l](n)||r.push(dr(s.messages.types[l],t.fullField,t.type)):l&&typeof n!==t.type&&r.push(dr(s.messages.types[l],t.fullField,t.type))},JQ=function(t,n,o,r,s){var i=typeof t.len=="number",l=typeof t.min=="number",a=typeof t.max=="number",u=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,c=n,d=null,f=typeof n=="number",p=typeof n=="string",h=Array.isArray(n);if(f?d="number":p?d="string":h&&(d="array"),!d)return!1;h&&(c=n.length),p&&(c=n.replace(u,"_").length),i?c!==t.len&&r.push(dr(s.messages[d].len,t.fullField,t.len)):l&&!a&&c<t.min?r.push(dr(s.messages[d].min,t.fullField,t.min)):a&&!l&&c>t.max?r.push(dr(s.messages[d].max,t.fullField,t.max)):l&&a&&(c<t.min||c>t.max)&&r.push(dr(s.messages[d].range,t.fullField,t.min,t.max))},Nu="enum",XQ=function(t,n,o,r,s){t[Nu]=Array.isArray(t[Nu])?t[Nu]:[],t[Nu].indexOf(n)===-1&&r.push(dr(s.messages[Nu],t.fullField,t[Nu].join(", ")))},QQ=function(t,n,o,r,s){if(t.pattern){if(t.pattern instanceof RegExp)t.pattern.lastIndex=0,t.pattern.test(n)||r.push(dr(s.messages.pattern.mismatch,t.fullField,n,t.pattern));else if(typeof t.pattern=="string"){var i=new RegExp(t.pattern);i.test(n)||r.push(dr(s.messages.pattern.mismatch,t.fullField,n,t.pattern))}}},Rt={required:WM,whitespace:GQ,type:ZQ,range:JQ,enum:XQ,pattern:QQ},eee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n,"string")&&!t.required)return o();Rt.required(t,n,r,i,s,"string"),jn(n,"string")||(Rt.type(t,n,r,i,s),Rt.range(t,n,r,i,s),Rt.pattern(t,n,r,i,s),t.whitespace===!0&&Rt.whitespace(t,n,r,i,s))}o(i)},tee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&Rt.type(t,n,r,i,s)}o(i)},nee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(n===""&&(n=void 0),jn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&(Rt.type(t,n,r,i,s),Rt.range(t,n,r,i,s))}o(i)},oee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&Rt.type(t,n,r,i,s)}o(i)},ree=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),jn(n)||Rt.type(t,n,r,i,s)}o(i)},see=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&(Rt.type(t,n,r,i,s),Rt.range(t,n,r,i,s))}o(i)},iee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&(Rt.type(t,n,r,i,s),Rt.range(t,n,r,i,s))}o(i)},lee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(n==null&&!t.required)return o();Rt.required(t,n,r,i,s,"array"),n!=null&&(Rt.type(t,n,r,i,s),Rt.range(t,n,r,i,s))}o(i)},aee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&Rt.type(t,n,r,i,s)}o(i)},uee="enum",cee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&Rt[uee](t,n,r,i,s)}o(i)},dee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n,"string")&&!t.required)return o();Rt.required(t,n,r,i,s),jn(n,"string")||Rt.pattern(t,n,r,i,s)}o(i)},fee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n,"date")&&!t.required)return o();if(Rt.required(t,n,r,i,s),!jn(n,"date")){var a;n instanceof Date?a=n:a=new Date(n),Rt.type(t,a,r,i,s),a&&Rt.range(t,a.getTime(),r,i,s)}}o(i)},pee=function(t,n,o,r,s){var i=[],l=Array.isArray(n)?"array":typeof n;Rt.required(t,n,r,i,s,l),o(i)},Xv=function(t,n,o,r,s){var i=t.type,l=[],a=t.required||!t.required&&r.hasOwnProperty(t.field);if(a){if(jn(n,i)&&!t.required)return o();Rt.required(t,n,r,l,s,i),jn(n,i)||Rt.type(t,n,r,l,s)}o(l)},hee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(jn(n)&&!t.required)return o();Rt.required(t,n,r,i,s)}o(i)},qf={string:eee,method:tee,number:nee,boolean:oee,regexp:ree,integer:see,float:iee,array:lee,object:aee,enum:cee,pattern:dee,date:fee,url:Xv,hex:Xv,email:Xv,required:pee,any:hee};function sb(){return{default:"Validation error on field %s",required:"%s is required",enum:"%s must be one of %s",whitespace:"%s cannot be empty",date:{format:"%s date %s is invalid for format %s",parse:"%s date could not be parsed, %s is invalid ",invalid:"%s date %s is invalid"},types:{string:"%s is not a %s",method:"%s is not a %s (function)",array:"%s is not an %s",object:"%s is not an %s",number:"%s is not a %s",date:"%s is not a %s",boolean:"%s is not a %s",integer:"%s is not an %s",float:"%s is not a %s",regexp:"%s is not a valid %s",email:"%s is not a valid %s",url:"%s is not a valid %s",hex:"%s is not a valid %s"},string:{len:"%s must be exactly %s characters",min:"%s must be at least %s characters",max:"%s cannot be longer than %s characters",range:"%s must be between %s and %s characters"},number:{len:"%s must equal %s",min:"%s cannot be less than %s",max:"%s cannot be greater than %s",range:"%s must be between %s and %s"},array:{len:"%s must be exactly %s in length",min:"%s cannot be less than %s in length",max:"%s cannot be greater than %s in length",range:"%s must be between %s and %s in length"},pattern:{mismatch:"%s value %s does not match pattern %s"},clone:function(){var t=JSON.parse(JSON.stringify(this));return t.clone=this.clone,t}}}var ib=sb(),hh=function(){function e(n){this.rules=null,this._messages=ib,this.define(n)}var t=e.prototype;return t.define=function(o){var r=this;if(!o)throw new Error("Cannot configure a schema with no rules");if(typeof o!="object"||Array.isArray(o))throw new Error("Rules must be an object");this.rules={},Object.keys(o).forEach(function(s){var i=o[s];r.rules[s]=Array.isArray(i)?i:[i]})},t.messages=function(o){return o&&(this._messages=L5(sb(),o)),this._messages},t.validate=function(o,r,s){var i=this;r===void 0&&(r={}),s===void 0&&(s=function(){});var l=o,a=r,u=s;if(typeof a=="function"&&(u=a,a={}),!this.rules||Object.keys(this.rules).length===0)return u&&u(null,l),Promise.resolve(l);function c(m){var y=[],v={};function w(S){if(Array.isArray(S)){var x;y=(x=y).concat.apply(x,S)}else y.push(S)}for(var _=0;_<m.length;_++)w(m[_]);y.length?(v=rb(y),u(y,v)):u(null,l)}if(a.messages){var d=this.messages();d===ib&&(d=sb()),L5(d,a.messages),a.messages=d}else a.messages=this.messages();var f={},p=a.keys||Object.keys(this.rules);p.forEach(function(m){var y=i.rules[m],v=l[m];y.forEach(function(w){var _=w;typeof _.transform=="function"&&(l===o&&(l=Ia({},l)),v=l[m]=_.transform(v)),typeof _=="function"?_={validator:_}:_=Ia({},_),_.validator=i.getValidationMethod(_),_.validator&&(_.field=m,_.fullField=_.fullField||m,_.type=i.getType(_),f[m]=f[m]||[],f[m].push({rule:_,value:v,source:l,field:m}))})});var h={};return WQ(f,a,function(m,y){var v=m.rule,w=(v.type==="object"||v.type==="array")&&(typeof v.fields=="object"||typeof v.defaultField=="object");w=w&&(v.required||!v.required&&m.value),v.field=m.field;function _(E,T){return Ia({},T,{fullField:v.fullField+"."+E,fullFields:v.fullFields?[].concat(v.fullFields,[E]):[E]})}function S(E){E===void 0&&(E=[]);var T=Array.isArray(E)?E:[E];!a.suppressWarning&&T.length&&e.warning("async-validator:",T),T.length&&v.message!==void 0&&(T=[].concat(v.message));var O=T.map(P5(v,l));if(a.first&&O.length)return h[v.field]=1,y(O);if(!w)y(O);else{if(v.required&&!m.value)return v.message!==void 0?O=[].concat(v.message).map(P5(v,l)):a.error&&(O=[a.error(v,dr(a.messages.required,v.field))]),y(O);var P={};v.defaultField&&Object.keys(m.value).map(function(B){P[B]=v.defaultField}),P=Ia({},P,m.rule.fields);var N={};Object.keys(P).forEach(function(B){var Y=P[B],Z=Array.isArray(Y)?Y:[Y];N[B]=Z.map(_.bind(null,B))});var F=new e(N);F.messages(a.messages),m.rule.options&&(m.rule.options.messages=a.messages,m.rule.options.error=a.error),F.validate(m.value,m.rule.options||a,function(B){var Y=[];O&&O.length&&Y.push.apply(Y,O),B&&B.length&&Y.push.apply(Y,B),y(Y.length?Y:null)})}}var x;if(v.asyncValidator)x=v.asyncValidator(v,m.value,S,m.source,a);else if(v.validator){try{x=v.validator(v,m.value,S,m.source,a)}catch(E){console.error==null||console.error(E),a.suppressValidatorError||setTimeout(function(){throw E},0),S(E.message)}x===!0?S():x===!1?S(typeof v.message=="function"?v.message(v.fullField||v.field):v.message||(v.fullField||v.field)+" fails"):x instanceof Array?S(x):x instanceof Error&&S(x.message)}x&&x.then&&x.then(function(){return S()},function(E){return S(E)})},function(m){c(m)},l)},t.getType=function(o){if(o.type===void 0&&o.pattern instanceof RegExp&&(o.type="pattern"),typeof o.validator!="function"&&o.type&&!qf.hasOwnProperty(o.type))throw new Error(dr("Unknown rule type %s",o.type));return o.type||"string"},t.getValidationMethod=function(o){if(typeof o.validator=="function")return o.validator;var r=Object.keys(o),s=r.indexOf("message");return s!==-1&&r.splice(s,1),r.length===1&&r[0]==="required"?qf.required:qf[this.getType(o)]||void 0},e}();hh.register=function(t,n){if(typeof n!="function")throw new Error("Cannot register a validator by type, validator is not a function");qf[t]=n};hh.warning=zQ;hh.messages=ib;hh.validators=qf;const mee=["","error","validating","success"],gee=We({label:String,labelWidth:{type:[String,Number],default:""},prop:{type:Ce([String,Array])},required:{type:Boolean,default:void 0},rules:{type:Ce([Object,Array])},error:String,validateStatus:{type:String,values:mee},for:String,inlineMessage:{type:[String,Boolean],default:""},showMessage:{type:Boolean,default:!0},size:{type:String,values:Zl}}),D5="ElLabelWrap";var vee=Q({name:D5,props:{isAutoWidth:Boolean,updateAll:Boolean},setup(e,{slots:t}){const n=Be(kd,void 0),o=Be(uu);o||ws(D5,"usage: <el-form-item><label-wrap /></el-form-item>");const r=Re("form"),s=K(),i=K(0),l=()=>{var c;if((c=s.value)!=null&&c.firstElementChild){const d=window.getComputedStyle(s.value.firstElementChild).width;return Math.ceil(Number.parseFloat(d))}else return 0},a=(c="update")=>{ot(()=>{t.default&&e.isAutoWidth&&(c==="update"?i.value=l():c==="remove"&&(n==null||n.deregisterLabelWidth(i.value)))})},u=()=>a("update");return Ct(()=>{u()}),En(()=>{a("remove")}),Fi(()=>u()),Te(i,(c,d)=>{e.updateAll&&(n==null||n.registerLabelWidth(c,d))}),Bo(R(()=>{var c,d;return(d=(c=s.value)==null?void 0:c.firstElementChild)!=null?d:null}),u),()=>{var c,d;if(!t)return null;const{isAutoWidth:f}=e;if(f){const p=n==null?void 0:n.autoLabelWidth,h=o==null?void 0:o.hasLabel,m={};if(h&&p&&p!=="auto"){const y=Math.max(0,Number.parseInt(p,10)-i.value),v=n.labelPosition==="left"?"marginRight":"marginLeft";y&&(m[v]=`${y}px`)}return k("div",{ref:s,class:[r.be("item","label-wrap")],style:m},[(c=t.default)==null?void 0:c.call(t)])}else return k(fe,{ref:s},[(d=t.default)==null?void 0:d.call(t)])}}});const yee=["role","aria-labelledby"],_ee=Q({name:"ElFormItem"}),bee=Q({..._ee,props:gee,setup(e,{expose:t}){const n=e,o=Kr(),r=Be(kd,void 0),s=Be(uu,void 0),i=Jo(void 0,{formItem:!1}),l=Re("form-item"),a=Hr().value,u=K([]),c=K(""),d=Wj(c,100),f=K(""),p=K();let h,m=!1;const y=R(()=>{if((r==null?void 0:r.labelPosition)==="top")return{};const ee=Zo(n.labelWidth||(r==null?void 0:r.labelWidth)||"");return ee?{width:ee}:{}}),v=R(()=>{if((r==null?void 0:r.labelPosition)==="top"||r!=null&&r.inline)return{};if(!n.label&&!n.labelWidth&&P)return{};const ee=Zo(n.labelWidth||(r==null?void 0:r.labelWidth)||"");return!n.label&&!o.label?{marginLeft:ee}:{}}),w=R(()=>[l.b(),l.m(i.value),l.is("error",c.value==="error"),l.is("validating",c.value==="validating"),l.is("success",c.value==="success"),l.is("required",Z.value||n.required),l.is("no-asterisk",r==null?void 0:r.hideRequiredAsterisk),(r==null?void 0:r.requireAsteriskPosition)==="right"?"asterisk-right":"asterisk-left",{[l.m("feedback")]:r==null?void 0:r.statusIcon}]),_=R(()=>Br(n.inlineMessage)?n.inlineMessage:(r==null?void 0:r.inlineMessage)||!1),S=R(()=>[l.e("error"),{[l.em("error","inline")]:_.value}]),x=R(()=>n.prop?tt(n.prop)?n.prop:n.prop.join("."):""),E=R(()=>!!(n.label||o.label)),T=R(()=>n.for||(u.value.length===1?u.value[0]:void 0)),O=R(()=>!T.value&&E.value),P=!!s,N=R(()=>{const ee=r==null?void 0:r.model;if(!(!ee||!n.prop))return Km(ee,n.prop).value}),F=R(()=>{const{required:ee}=n,de=[];n.rules&&de.push(...Eg(n.rules));const ve=r==null?void 0:r.rules;if(ve&&n.prop){const le=Km(ve,n.prop).value;le&&de.push(...Eg(le))}if(ee!==void 0){const le=de.map((Ie,Ge)=>[Ie,Ge]).filter(([Ie])=>Object.keys(Ie).includes("required"));if(le.length>0)for(const[Ie,Ge]of le)Ie.required!==ee&&(de[Ge]={...Ie,required:ee});else de.push({required:ee})}return de}),B=R(()=>F.value.length>0),Y=ee=>F.value.filter(ve=>!ve.trigger||!ee?!0:Array.isArray(ve.trigger)?ve.trigger.includes(ee):ve.trigger===ee).map(({trigger:ve,...le})=>le),Z=R(()=>F.value.some(ee=>ee.required)),U=R(()=>{var ee;return d.value==="error"&&n.showMessage&&((ee=r==null?void 0:r.showMessage)!=null?ee:!0)}),j=R(()=>`${n.label||""}${(r==null?void 0:r.labelSuffix)||""}`),V=ee=>{c.value=ee},H=ee=>{var de,ve;const{errors:le,fields:Ie}=ee;(!le||!Ie)&&console.error(ee),V("error"),f.value=le?(ve=(de=le==null?void 0:le[0])==null?void 0:de.message)!=null?ve:`${n.prop} is required`:"",r==null||r.emit("validate",n.prop,!1,f.value)},L=()=>{V("success"),r==null||r.emit("validate",n.prop,!0,"")},I=async ee=>{const de=x.value;return new hh({[de]:ee}).validate({[de]:N.value},{firstFields:!0}).then(()=>(L(),!0)).catch(le=>(H(le),Promise.reject(le)))},X=async(ee,de)=>{if(m||!n.prop)return!1;const ve=Xe(de);if(!B.value)return de==null||de(!1),!1;const le=Y(ee);return le.length===0?(de==null||de(!0),!0):(V("validating"),I(le).then(()=>(de==null||de(!0),!0)).catch(Ie=>{const{fields:Ge}=Ie;return de==null||de(!1,Ge),ve?!1:Promise.reject(Ge)}))},oe=()=>{V(""),f.value="",m=!1},z=async()=>{const ee=r==null?void 0:r.model;if(!ee||!n.prop)return;const de=Km(ee,n.prop);m=!0,de.value=s5(h),await ot(),oe(),m=!1},ge=ee=>{u.value.includes(ee)||u.value.push(ee)},Oe=ee=>{u.value=u.value.filter(de=>de!==ee)};Te(()=>n.error,ee=>{f.value=ee||"",V(ee?"error":"")},{immediate:!0}),Te(()=>n.validateStatus,ee=>V(ee||""));const xe=Dn({...ei(n),$el:p,size:i,validateState:c,labelId:a,inputIds:u,isGroup:O,hasLabel:E,fieldValue:N,addInputId:ge,removeInputId:Oe,resetField:z,clearValidate:oe,validate:X});return wt(uu,xe),Ct(()=>{n.prop&&(r==null||r.addField(xe),h=s5(N.value))}),En(()=>{r==null||r.removeField(xe)}),t({size:i,validateMessage:f,validateState:c,validate:X,clearValidate:oe,resetField:z}),(ee,de)=>{var ve;return C(),M("div",{ref_key:"formItemRef",ref:p,class:D(g(w)),role:g(O)?"group":void 0,"aria-labelledby":g(O)?g(a):void 0},[k(g(vee),{"is-auto-width":g(y).width==="auto","update-all":((ve=g(r))==null?void 0:ve.labelWidth)==="auto"},{default:$(()=>[g(E)?(C(),q(Lt(g(T)?"label":"div"),{key:0,id:g(a),for:g(T),class:D(g(l).e("label")),style:Qe(g(y))},{default:$(()=>[he(ee.$slots,"label",{label:g(j)},()=>[ne(A(g(j)),1)])]),_:3},8,["id","for","class","style"])):W("v-if",!0)]),_:3},8,["is-auto-width","update-all"]),b("div",{class:D(g(l).e("content")),style:Qe(g(v))},[he(ee.$slots,"default"),k(w0,{name:`${g(l).namespace.value}-zoom-in-top`},{default:$(()=>[g(U)?he(ee.$slots,"error",{key:0,error:f.value},()=>[b("div",{class:D(g(S))},A(f.value),3)]):W("v-if",!0)]),_:3},8,["name"])],6)],10,yee)}}});var KM=ze(bee,[["__file","form-item.vue"]]);const so=Zt(RQ,{FormItem:KM}),io=Gn(KM);let Jr;const wee=`
51 height:0 !important;
52 visibility:hidden !important;
53 ${dH()?"":"overflow:hidden !important;"}
54 position:absolute !important;
55 z-index:-1000 !important;
56 top:0 !important;
57 right:0 !important;
58 `,Cee=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing"];function kee(e){const t=window.getComputedStyle(e),n=t.getPropertyValue("box-sizing"),o=Number.parseFloat(t.getPropertyValue("padding-bottom"))+Number.parseFloat(t.getPropertyValue("padding-top")),r=Number.parseFloat(t.getPropertyValue("border-bottom-width"))+Number.parseFloat(t.getPropertyValue("border-top-width"));return{contextStyle:Cee.map(i=>`${i}:${t.getPropertyValue(i)}`).join(";"),paddingSize:o,borderSize:r,boxSizing:n}}function F5(e,t=1,n){var o;Jr||(Jr=document.createElement("textarea"),document.body.appendChild(Jr));const{paddingSize:r,borderSize:s,boxSizing:i,contextStyle:l}=kee(e);Jr.setAttribute("style",`${l};${wee}`),Jr.value=e.value||e.placeholder||"";let a=Jr.scrollHeight;const u={};i==="border-box"?a=a+s:i==="content-box"&&(a=a-r),Jr.value="";const c=Jr.scrollHeight-r;if(_t(t)){let d=c*t;i==="border-box"&&(d=d+r+s),a=Math.max(d,a),u.minHeight=`${d}px`}if(_t(n)){let d=c*n;i==="border-box"&&(d=d+r+s),a=Math.min(d,a)}return u.height=`${a}px`,(o=Jr.parentNode)==null||o.removeChild(Jr),Jr=void 0,u}const See=We({id:{type:String,default:void 0},size:qr,disabled:Boolean,modelValue:{type:Ce([String,Number,Object]),default:""},maxlength:{type:[String,Number]},minlength:{type:[String,Number]},type:{type:String,default:"text"},resize:{type:String,values:["none","both","horizontal","vertical"]},autosize:{type:Ce([Boolean,Object]),default:!1},autocomplete:{type:String,default:"off"},formatter:{type:Function},parser:{type:Function},placeholder:{type:String},form:{type:String},readonly:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1},showPassword:{type:Boolean,default:!1},showWordLimit:{type:Boolean,default:!1},suffixIcon:{type:Oo},prefixIcon:{type:Oo},containerRole:{type:String,default:void 0},label:{type:String,default:void 0},tabindex:{type:[String,Number],default:0},validateEvent:{type:Boolean,default:!0},inputStyle:{type:Ce([Object,Array,String]),default:()=>$o({})},autofocus:{type:Boolean,default:!1}}),$ee={[Jt]:e=>tt(e),input:e=>tt(e),change:e=>tt(e),focus:e=>e instanceof FocusEvent,blur:e=>e instanceof FocusEvent,clear:()=>!0,mouseleave:e=>e instanceof MouseEvent,mouseenter:e=>e instanceof MouseEvent,keydown:e=>e instanceof Event,compositionstart:e=>e instanceof CompositionEvent,compositionupdate:e=>e instanceof CompositionEvent,compositionend:e=>e instanceof CompositionEvent},Eee=["role"],xee=["id","minlength","maxlength","type","disabled","readonly","autocomplete","tabindex","aria-label","placeholder","form","autofocus"],Mee=["id","minlength","maxlength","tabindex","disabled","readonly","autocomplete","aria-label","placeholder","form","autofocus"],Tee=Q({name:"ElInput",inheritAttrs:!1}),Oee=Q({...Tee,props:See,emits:$ee,setup(e,{expose:t,emit:n}){const o=e,r=_d(),s=Kr(),i=R(()=>{const ce={};return o.containerRole==="combobox"&&(ce["aria-haspopup"]=r["aria-haspopup"],ce["aria-owns"]=r["aria-owns"],ce["aria-expanded"]=r["aria-expanded"]),ce}),l=R(()=>[o.type==="textarea"?y.b():m.b(),m.m(p.value),m.is("disabled",h.value),m.is("exceed",ge.value),{[m.b("group")]:s.prepend||s.append,[m.bm("group","append")]:s.append,[m.bm("group","prepend")]:s.prepend,[m.m("prefix")]:s.prefix||o.prefixIcon,[m.m("suffix")]:s.suffix||o.suffixIcon||o.clearable||o.showPassword,[m.bm("suffix","password-clear")]:I.value&&X.value,[m.b("hidden")]:o.type==="hidden"},r.class]),a=R(()=>[m.e("wrapper"),m.is("focus",N.value)]),u=aM({excludeKeys:R(()=>Object.keys(i.value))}),{form:c,formItem:d}=ni(),{inputId:f}=Sd(o,{formItemContext:d}),p=Jo(),h=Gr(),m=Re("input"),y=Re("textarea"),v=Tn(),w=Tn(),_=K(!1),S=K(!1),x=K(!1),E=K(),T=Tn(o.inputStyle),O=R(()=>v.value||w.value),{wrapperRef:P,isFocused:N,handleFocus:F,handleBlur:B}=x3(O,{afterBlur(){var ce;o.validateEvent&&((ce=d==null?void 0:d.validate)==null||ce.call(d,"blur").catch(te=>void 0))}}),Y=R(()=>{var ce;return(ce=c==null?void 0:c.statusIcon)!=null?ce:!1}),Z=R(()=>(d==null?void 0:d.validateState)||""),U=R(()=>Z.value&&iM[Z.value]),j=R(()=>x.value?nM:eM),V=R(()=>[r.style]),H=R(()=>[o.inputStyle,T.value,{resize:o.resize}]),L=R(()=>xo(o.modelValue)?"":String(o.modelValue)),I=R(()=>o.clearable&&!h.value&&!o.readonly&&!!L.value&&(N.value||_.value)),X=R(()=>o.showPassword&&!h.value&&!o.readonly&&!!L.value&&(!!L.value||N.value)),oe=R(()=>o.showWordLimit&&!!o.maxlength&&(o.type==="text"||o.type==="textarea")&&!h.value&&!o.readonly&&!o.showPassword),z=R(()=>L.value.length),ge=R(()=>!!oe.value&&z.value>Number(o.maxlength)),Oe=R(()=>!!s.suffix||!!o.suffixIcon||I.value||o.showPassword||oe.value||!!Z.value&&Y.value),[xe,ee]=vQ(v);Bo(w,ce=>{if(le(),!oe.value||o.resize!=="both")return;const te=ce[0],{width:pe}=te.contentRect;E.value={right:`calc(100% - ${pe+15+6}px)`}});const de=()=>{const{type:ce,autosize:te}=o;if(!(!xt||ce!=="textarea"||!w.value))if(te){const pe=ft(te)?te.minRows:void 0,Ve=ft(te)?te.maxRows:void 0,Je=F5(w.value,pe,Ve);T.value={overflowY:"hidden",...Je},ot(()=>{w.value.offsetHeight,T.value=Je})}else T.value={minHeight:F5(w.value).minHeight}},le=(ce=>{let te=!1;return()=>{var pe;if(te||!o.autosize)return;((pe=w.value)==null?void 0:pe.offsetParent)===null||(ce(),te=!0)}})(de),Ie=()=>{const ce=O.value,te=o.formatter?o.formatter(L.value):L.value;!ce||ce.value===te||(ce.value=te)},Ge=async ce=>{xe();let{value:te}=ce.target;if(o.formatter&&(te=o.parser?o.parser(te):te),!S.value){if(te===L.value){Ie();return}n(Jt,te),n("input",te),await ot(),Ie(),ee()}},G=ce=>{n("change",ce.target.value)},J=ce=>{n("compositionstart",ce),S.value=!0},ue=ce=>{var te;n("compositionupdate",ce);const pe=(te=ce.target)==null?void 0:te.value,Ve=pe[pe.length-1]||"";S.value=!lM(Ve)},_e=ce=>{n("compositionend",ce),S.value&&(S.value=!1,Ge(ce))},ye=()=>{x.value=!x.value,Ae()},Ae=async()=>{var ce;await ot(),(ce=O.value)==null||ce.focus()},Le=()=>{var ce;return(ce=O.value)==null?void 0:ce.blur()},Ee=ce=>{_.value=!1,n("mouseleave",ce)},Pe=ce=>{_.value=!0,n("mouseenter",ce)},me=ce=>{n("keydown",ce)},je=()=>{var ce;(ce=O.value)==null||ce.select()},Ze=()=>{n(Jt,""),n("change",""),n("clear"),n("input","")};return Te(()=>o.modelValue,()=>{var ce;ot(()=>de()),o.validateEvent&&((ce=d==null?void 0:d.validate)==null||ce.call(d,"change").catch(te=>void 0))}),Te(L,()=>Ie()),Te(()=>o.type,async()=>{await ot(),Ie(),de()}),Ct(()=>{!o.formatter&&o.parser,Ie(),ot(de)}),t({input:v,textarea:w,ref:O,textareaStyle:H,autosize:pn(o,"autosize"),focus:Ae,blur:Le,select:je,clear:Ze,resizeTextarea:de}),(ce,te)=>(C(),M("div",un(g(i),{class:g(l),style:g(V),role:ce.containerRole,onMouseenter:Pe,onMouseleave:Ee}),[W(" input "),ce.type!=="textarea"?(C(),M(fe,{key:0},[W(" prepend slot "),ce.$slots.prepend?(C(),M("div",{key:0,class:D(g(m).be("group","prepend"))},[he(ce.$slots,"prepend")],2)):W("v-if",!0),b("div",{ref_key:"wrapperRef",ref:P,class:D(g(a))},[W(" prefix slot "),ce.$slots.prefix||ce.prefixIcon?(C(),M("span",{key:0,class:D(g(m).e("prefix"))},[b("span",{class:D(g(m).e("prefix-inner"))},[he(ce.$slots,"prefix"),ce.prefixIcon?(C(),q(g(Ne),{key:0,class:D(g(m).e("icon"))},{default:$(()=>[(C(),q(Lt(ce.prefixIcon)))]),_:1},8,["class"])):W("v-if",!0)],2)],2)):W("v-if",!0),b("input",un({id:g(f),ref_key:"input",ref:v,class:g(m).e("inner")},g(u),{minlength:ce.minlength,maxlength:ce.maxlength,type:ce.showPassword?x.value?"text":"password":ce.type,disabled:g(h),readonly:ce.readonly,autocomplete:ce.autocomplete,tabindex:ce.tabindex,"aria-label":ce.label,placeholder:ce.placeholder,style:ce.inputStyle,form:ce.form,autofocus:ce.autofocus,onCompositionstart:J,onCompositionupdate:ue,onCompositionend:_e,onInput:Ge,onFocus:te[0]||(te[0]=(...pe)=>g(F)&&g(F)(...pe)),onBlur:te[1]||(te[1]=(...pe)=>g(B)&&g(B)(...pe)),onChange:G,onKeydown:me}),null,16,xee),W(" suffix slot "),g(Oe)?(C(),M("span",{key:1,class:D(g(m).e("suffix"))},[b("span",{class:D(g(m).e("suffix-inner"))},[!g(I)||!g(X)||!g(oe)?(C(),M(fe,{key:0},[he(ce.$slots,"suffix"),ce.suffixIcon?(C(),q(g(Ne),{key:0,class:D(g(m).e("icon"))},{default:$(()=>[(C(),q(Lt(ce.suffixIcon)))]),_:1},8,["class"])):W("v-if",!0)],64)):W("v-if",!0),g(I)?(C(),q(g(Ne),{key:1,class:D([g(m).e("icon"),g(m).e("clear")]),onMousedown:et(g(yt),["prevent"]),onClick:Ze},{default:$(()=>[k(g(wd))]),_:1},8,["class","onMousedown"])):W("v-if",!0),g(X)?(C(),q(g(Ne),{key:2,class:D([g(m).e("icon"),g(m).e("password")]),onClick:ye},{default:$(()=>[(C(),q(Lt(g(j))))]),_:1},8,["class"])):W("v-if",!0),g(oe)?(C(),M("span",{key:3,class:D(g(m).e("count"))},[b("span",{class:D(g(m).e("count-inner"))},A(g(z))+" / "+A(ce.maxlength),3)],2)):W("v-if",!0),g(Z)&&g(U)&&g(Y)?(C(),q(g(Ne),{key:4,class:D([g(m).e("icon"),g(m).e("validateIcon"),g(m).is("loading",g(Z)==="validating")])},{default:$(()=>[(C(),q(Lt(g(U))))]),_:1},8,["class"])):W("v-if",!0)],2)],2)):W("v-if",!0)],2),W(" append slot "),ce.$slots.append?(C(),M("div",{key:1,class:D(g(m).be("group","append"))},[he(ce.$slots,"append")],2)):W("v-if",!0)],64)):(C(),M(fe,{key:1},[W(" textarea "),b("textarea",un({id:g(f),ref_key:"textarea",ref:w,class:g(y).e("inner")},g(u),{minlength:ce.minlength,maxlength:ce.maxlength,tabindex:ce.tabindex,disabled:g(h),readonly:ce.readonly,autocomplete:ce.autocomplete,style:g(H),"aria-label":ce.label,placeholder:ce.placeholder,form:ce.form,autofocus:ce.autofocus,onCompositionstart:J,onCompositionupdate:ue,onCompositionend:_e,onInput:Ge,onFocus:te[2]||(te[2]=(...pe)=>g(F)&&g(F)(...pe)),onBlur:te[3]||(te[3]=(...pe)=>g(B)&&g(B)(...pe)),onChange:G,onKeydown:me}),null,16,Mee),g(oe)?(C(),M("span",{key:0,style:Qe(E.value),class:D(g(m).e("count"))},A(g(z))+" / "+A(ce.maxlength),7)):W("v-if",!0)],64))],16,Eee))}});var Iee=ze(Oee,[["__file","input.vue"]]);const At=Zt(Iee),Pu=4,Aee={vertical:{offset:"offsetHeight",scroll:"scrollTop",scrollSize:"scrollHeight",size:"height",key:"vertical",axis:"Y",client:"clientY",direction:"top"},horizontal:{offset:"offsetWidth",scroll:"scrollLeft",scrollSize:"scrollWidth",size:"width",key:"horizontal",axis:"X",client:"clientX",direction:"left"}},Nee=({move:e,size:t,bar:n})=>({[n.size]:t,transform:`translate${n.axis}(${e}%)`}),O3=Symbol("scrollbarContextKey"),Pee=We({vertical:Boolean,size:String,move:Number,ratio:{type:Number,required:!0},always:Boolean}),Lee="Thumb",Ree=Q({__name:"thumb",props:Pee,setup(e){const t=e,n=Be(O3),o=Re("scrollbar");n||ws(Lee,"can not inject scrollbar context");const r=K(),s=K(),i=K({}),l=K(!1);let a=!1,u=!1,c=xt?document.onselectstart:null;const d=R(()=>Aee[t.vertical?"vertical":"horizontal"]),f=R(()=>Nee({size:t.size,move:t.move,bar:d.value})),p=R(()=>r.value[d.value.offset]**2/n.wrapElement[d.value.scrollSize]/t.ratio/s.value[d.value.offset]),h=E=>{var T;if(E.stopPropagation(),E.ctrlKey||[1,2].includes(E.button))return;(T=window.getSelection())==null||T.removeAllRanges(),y(E);const O=E.currentTarget;O&&(i.value[d.value.axis]=O[d.value.offset]-(E[d.value.client]-O.getBoundingClientRect()[d.value.direction]))},m=E=>{if(!s.value||!r.value||!n.wrapElement)return;const T=Math.abs(E.target.getBoundingClientRect()[d.value.direction]-E[d.value.client]),O=s.value[d.value.offset]/2,P=(T-O)*100*p.value/r.value[d.value.offset];n.wrapElement[d.value.scroll]=P*n.wrapElement[d.value.scrollSize]/100},y=E=>{E.stopImmediatePropagation(),a=!0,document.addEventListener("mousemove",v),document.addEventListener("mouseup",w),c=document.onselectstart,document.onselectstart=()=>!1},v=E=>{if(!r.value||!s.value||a===!1)return;const T=i.value[d.value.axis];if(!T)return;const O=(r.value.getBoundingClientRect()[d.value.direction]-E[d.value.client])*-1,P=s.value[d.value.offset]-T,N=(O-P)*100*p.value/r.value[d.value.offset];n.wrapElement[d.value.scroll]=N*n.wrapElement[d.value.scrollSize]/100},w=()=>{a=!1,i.value[d.value.axis]=0,document.removeEventListener("mousemove",v),document.removeEventListener("mouseup",w),x(),u&&(l.value=!1)},_=()=>{u=!1,l.value=!!t.size},S=()=>{u=!0,l.value=a};En(()=>{x(),document.removeEventListener("mouseup",w)});const x=()=>{document.onselectstart!==c&&(document.onselectstart=c)};return Ln(pn(n,"scrollbarElement"),"mousemove",_),Ln(pn(n,"scrollbarElement"),"mouseleave",S),(E,T)=>(C(),q(_r,{name:g(o).b("fade"),persisted:""},{default:$(()=>[He(b("div",{ref_key:"instance",ref:r,class:D([g(o).e("bar"),g(o).is(g(d).key)]),onMousedown:m},[b("div",{ref_key:"thumb",ref:s,class:D(g(o).e("thumb")),style:Qe(g(f)),onMousedown:h},null,38)],34),[[en,E.always||l.value]])]),_:1},8,["name"]))}});var V5=ze(Ree,[["__file","thumb.vue"]]);const Dee=We({always:{type:Boolean,default:!0},minSize:{type:Number,required:!0}}),Fee=Q({__name:"bar",props:Dee,setup(e,{expose:t}){const n=e,o=Be(O3),r=K(0),s=K(0),i=K(""),l=K(""),a=K(1),u=K(1);return t({handleScroll:f=>{if(f){const p=f.offsetHeight-Pu,h=f.offsetWidth-Pu;s.value=f.scrollTop*100/p*a.value,r.value=f.scrollLeft*100/h*u.value}},update:()=>{const f=o==null?void 0:o.wrapElement;if(!f)return;const p=f.offsetHeight-Pu,h=f.offsetWidth-Pu,m=p**2/f.scrollHeight,y=h**2/f.scrollWidth,v=Math.max(m,n.minSize),w=Math.max(y,n.minSize);a.value=m/(p-m)/(v/(p-v)),u.value=y/(h-y)/(w/(h-w)),l.value=v+Pu<p?`${v}px`:"",i.value=w+Pu<h?`${w}px`:""}}),(f,p)=>(C(),M(fe,null,[k(V5,{move:r.value,ratio:u.value,size:i.value,always:f.always},null,8,["move","ratio","size","always"]),k(V5,{move:s.value,ratio:a.value,size:l.value,vertical:"",always:f.always},null,8,["move","ratio","size","always"])],64))}});var Vee=ze(Fee,[["__file","bar.vue"]]);const Bee=We({height:{type:[String,Number],default:""},maxHeight:{type:[String,Number],default:""},native:{type:Boolean,default:!1},wrapStyle:{type:Ce([String,Object,Array]),default:""},wrapClass:{type:[String,Array],default:""},viewClass:{type:[String,Array],default:""},viewStyle:{type:[String,Array,Object],default:""},noresize:Boolean,tag:{type:String,default:"div"},always:Boolean,minSize:{type:Number,default:20},id:String,role:String,ariaLabel:String,ariaOrientation:{type:String,values:["horizontal","vertical"]}}),zee={scroll:({scrollTop:e,scrollLeft:t})=>[e,t].every(_t)},jee="ElScrollbar",Hee=Q({name:jee}),Uee=Q({...Hee,props:Bee,emits:zee,setup(e,{expose:t,emit:n}){const o=e,r=Re("scrollbar");let s,i;const l=K(),a=K(),u=K(),c=K(),d=R(()=>{const _={};return o.height&&(_.height=Zo(o.height)),o.maxHeight&&(_.maxHeight=Zo(o.maxHeight)),[o.wrapStyle,_]}),f=R(()=>[o.wrapClass,r.e("wrap"),{[r.em("wrap","hidden-default")]:!o.native}]),p=R(()=>[r.e("view"),o.viewClass]),h=()=>{var _;a.value&&((_=c.value)==null||_.handleScroll(a.value),n("scroll",{scrollTop:a.value.scrollTop,scrollLeft:a.value.scrollLeft}))};function m(_,S){ft(_)?a.value.scrollTo(_):_t(_)&&_t(S)&&a.value.scrollTo(_,S)}const y=_=>{_t(_)&&(a.value.scrollTop=_)},v=_=>{_t(_)&&(a.value.scrollLeft=_)},w=()=>{var _;(_=c.value)==null||_.update()};return Te(()=>o.noresize,_=>{_?(s==null||s(),i==null||i()):({stop:s}=Bo(u,w),i=Ln("resize",w))},{immediate:!0}),Te(()=>[o.maxHeight,o.height],()=>{o.native||ot(()=>{var _;w(),a.value&&((_=c.value)==null||_.handleScroll(a.value))})}),wt(O3,Dn({scrollbarElement:l,wrapElement:a})),Ct(()=>{o.native||ot(()=>{w()})}),Fi(()=>w()),t({wrapRef:a,update:w,scrollTo:m,setScrollTop:y,setScrollLeft:v,handleScroll:h}),(_,S)=>(C(),M("div",{ref_key:"scrollbarRef",ref:l,class:D(g(r).b())},[b("div",{ref_key:"wrapRef",ref:a,class:D(g(f)),style:Qe(g(d)),onScroll:h},[(C(),q(Lt(_.tag),{id:_.id,ref_key:"resizeRef",ref:u,class:D(g(p)),style:Qe(_.viewStyle),role:_.role,"aria-label":_.ariaLabel,"aria-orientation":_.ariaOrientation},{default:$(()=>[he(_.$slots,"default")]),_:3},8,["id","class","style","role","aria-label","aria-orientation"]))],38),_.native?W("v-if",!0):(C(),q(Vee,{key:0,ref_key:"barRef",ref:c,always:_.always,"min-size":_.minSize},null,8,["always","min-size"]))],2))}});var Wee=ze(Uee,[["__file","scrollbar.vue"]]);const ks=Zt(Wee),I3=Symbol("popper"),qM=Symbol("popperContent"),Kee=["dialog","grid","group","listbox","menu","navigation","tooltip","tree"],GM=We({role:{type:String,values:Kee,default:"tooltip"}}),qee=Q({name:"ElPopper",inheritAttrs:!1}),Gee=Q({...qee,props:GM,setup(e,{expose:t}){const n=e,o=K(),r=K(),s=K(),i=K(),l=R(()=>n.role),a={triggerRef:o,popperInstanceRef:r,contentRef:s,referenceRef:i,role:l};return t(a),wt(I3,a),(u,c)=>he(u.$slots,"default")}});var Yee=ze(Gee,[["__file","popper.vue"]]);const YM=We({arrowOffset:{type:Number,default:5}}),Zee=Q({name:"ElPopperArrow",inheritAttrs:!1}),Jee=Q({...Zee,props:YM,setup(e,{expose:t}){const n=e,o=Re("popper"),{arrowOffset:r,arrowRef:s,arrowStyle:i}=Be(qM,void 0);return Te(()=>n.arrowOffset,l=>{r.value=l}),En(()=>{s.value=void 0}),t({arrowRef:s}),(l,a)=>(C(),M("span",{ref_key:"arrowRef",ref:s,class:D(g(o).e("arrow")),style:Qe(g(i)),"data-popper-arrow":""},null,6))}});var Xee=ze(Jee,[["__file","arrow.vue"]]);const Qee="ElOnlyChild",ZM=Q({name:Qee,setup(e,{slots:t,attrs:n}){var o;const r=Be(MM),s=BX((o=r==null?void 0:r.setForwardRef)!=null?o:yt);return()=>{var i;const l=(i=t.default)==null?void 0:i.call(t,n);if(!l||l.length>1)return null;const a=JM(l);return a?He(hs(a,n),[[s]]):null}}});function JM(e){if(!e)return null;const t=e;for(const n of t){if(ft(n))switch(n.type){case Kn:continue;case Ai:case"svg":return B5(n);case fe:return JM(n.children);default:return n}return B5(n)}return null}function B5(e){const t=Re("only-child");return k("span",{class:t.e("content")},[e])}const XM=We({virtualRef:{type:Ce(Object)},virtualTriggering:Boolean,onMouseenter:{type:Ce(Function)},onMouseleave:{type:Ce(Function)},onClick:{type:Ce(Function)},onKeydown:{type:Ce(Function)},onFocus:{type:Ce(Function)},onBlur:{type:Ce(Function)},onContextmenu:{type:Ce(Function)},id:String,open:Boolean}),ete=Q({name:"ElPopperTrigger",inheritAttrs:!1}),tte=Q({...ete,props:XM,setup(e,{expose:t}){const n=e,{role:o,triggerRef:r}=Be(I3,void 0);VX(r);const s=R(()=>l.value?n.id:void 0),i=R(()=>{if(o&&o.value==="tooltip")return n.open&&n.id?n.id:void 0}),l=R(()=>{if(o&&o.value!=="tooltip")return o.value}),a=R(()=>l.value?`${n.open}`:void 0);let u;return Ct(()=>{Te(()=>n.virtualRef,c=>{c&&(r.value=ki(c))},{immediate:!0}),Te(r,(c,d)=>{u==null||u(),u=void 0,gs(c)&&(["onMouseenter","onMouseleave","onClick","onKeydown","onFocus","onBlur","onContextmenu"].forEach(f=>{var p;const h=n[f];h&&(c.addEventListener(f.slice(2).toLowerCase(),h),(p=d==null?void 0:d.removeEventListener)==null||p.call(d,f.slice(2).toLowerCase(),h))}),u=Te([s,i,l,a],f=>{["aria-controls","aria-describedby","aria-haspopup","aria-expanded"].forEach((p,h)=>{xo(f[h])?c.removeAttribute(p):c.setAttribute(p,f[h])})},{immediate:!0})),gs(d)&&["aria-controls","aria-describedby","aria-haspopup","aria-expanded"].forEach(f=>d.removeAttribute(f))},{immediate:!0})}),En(()=>{u==null||u(),u=void 0}),t({triggerRef:r}),(c,d)=>c.virtualTriggering?W("v-if",!0):(C(),q(g(ZM),un({key:0},c.$attrs,{"aria-controls":g(s),"aria-describedby":g(i),"aria-expanded":g(a),"aria-haspopup":g(l)}),{default:$(()=>[he(c.$slots,"default")]),_:3},16,["aria-controls","aria-describedby","aria-expanded","aria-haspopup"]))}});var nte=ze(tte,[["__file","trigger.vue"]]);const Qv="focus-trap.focus-after-trapped",ey="focus-trap.focus-after-released",ote="focus-trap.focusout-prevented",z5={cancelable:!0,bubbles:!1},rte={cancelable:!0,bubbles:!1},j5="focusAfterTrapped",H5="focusAfterReleased",A3=Symbol("elFocusTrap"),N3=K(),z0=K(0),P3=K(0);let dm=0;const QM=e=>{const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:o=>{const r=o.tagName==="INPUT"&&o.type==="hidden";return o.disabled||o.hidden||r?NodeFilter.FILTER_SKIP:o.tabIndex>=0||o===document.activeElement?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t},U5=(e,t)=>{for(const n of e)if(!ste(n,t))return n},ste=(e,t)=>{if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1},ite=e=>{const t=QM(e),n=U5(t,e),o=U5(t.reverse(),e);return[n,o]},lte=e=>e instanceof HTMLInputElement&&"select"in e,el=(e,t)=>{if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),P3.value=window.performance.now(),e!==n&&lte(e)&&t&&e.select()}};function W5(e,t){const n=[...e],o=e.indexOf(t);return o!==-1&&n.splice(o,1),n}const ate=()=>{let e=[];return{push:o=>{const r=e[0];r&&o!==r&&r.pause(),e=W5(e,o),e.unshift(o)},remove:o=>{var r,s;e=W5(e,o),(s=(r=e[0])==null?void 0:r.resume)==null||s.call(r)}}},ute=(e,t=!1)=>{const n=document.activeElement;for(const o of e)if(el(o,t),document.activeElement!==n)return},K5=ate(),cte=()=>z0.value>P3.value,fm=()=>{N3.value="pointer",z0.value=window.performance.now()},q5=()=>{N3.value="keyboard",z0.value=window.performance.now()},dte=()=>(Ct(()=>{dm===0&&(document.addEventListener("mousedown",fm),document.addEventListener("touchstart",fm),document.addEventListener("keydown",q5)),dm++}),En(()=>{dm--,dm<=0&&(document.removeEventListener("mousedown",fm),document.removeEventListener("touchstart",fm),document.removeEventListener("keydown",q5))}),{focusReason:N3,lastUserFocusTimestamp:z0,lastAutomatedFocusTimestamp:P3}),pm=e=>new CustomEvent(ote,{...rte,detail:e}),fte=Q({name:"ElFocusTrap",inheritAttrs:!1,props:{loop:Boolean,trapped:Boolean,focusTrapEl:Object,focusStartEl:{type:[Object,String],default:"first"}},emits:[j5,H5,"focusin","focusout","focusout-prevented","release-requested"],setup(e,{emit:t}){const n=K();let o,r;const{focusReason:s}=dte();PX(h=>{e.trapped&&!i.paused&&t("release-requested",h)});const i={paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}},l=h=>{if(!e.loop&&!e.trapped||i.paused)return;const{key:m,altKey:y,ctrlKey:v,metaKey:w,currentTarget:_,shiftKey:S}=h,{loop:x}=e,E=m===rt.tab&&!y&&!v&&!w,T=document.activeElement;if(E&&T){const O=_,[P,N]=ite(O);if(P&&N){if(!S&&T===N){const B=pm({focusReason:s.value});t("focusout-prevented",B),B.defaultPrevented||(h.preventDefault(),x&&el(P,!0))}else if(S&&[P,O].includes(T)){const B=pm({focusReason:s.value});t("focusout-prevented",B),B.defaultPrevented||(h.preventDefault(),x&&el(N,!0))}}else if(T===O){const B=pm({focusReason:s.value});t("focusout-prevented",B),B.defaultPrevented||h.preventDefault()}}};wt(A3,{focusTrapRef:n,onKeydown:l}),Te(()=>e.focusTrapEl,h=>{h&&(n.value=h)},{immediate:!0}),Te([n],([h],[m])=>{h&&(h.addEventListener("keydown",l),h.addEventListener("focusin",c),h.addEventListener("focusout",d)),m&&(m.removeEventListener("keydown",l),m.removeEventListener("focusin",c),m.removeEventListener("focusout",d))});const a=h=>{t(j5,h)},u=h=>t(H5,h),c=h=>{const m=g(n);if(!m)return;const y=h.target,v=h.relatedTarget,w=y&&m.contains(y);e.trapped||v&&m.contains(v)||(o=v),w&&t("focusin",h),!i.paused&&e.trapped&&(w?r=y:el(r,!0))},d=h=>{const m=g(n);if(!(i.paused||!m))if(e.trapped){const y=h.relatedTarget;!xo(y)&&!m.contains(y)&&setTimeout(()=>{if(!i.paused&&e.trapped){const v=pm({focusReason:s.value});t("focusout-prevented",v),v.defaultPrevented||el(r,!0)}},0)}else{const y=h.target;y&&m.contains(y)||t("focusout",h)}};async function f(){await ot();const h=g(n);if(h){K5.push(i);const m=h.contains(document.activeElement)?o:document.activeElement;if(o=m,!h.contains(m)){const v=new Event(Qv,z5);h.addEventListener(Qv,a),h.dispatchEvent(v),v.defaultPrevented||ot(()=>{let w=e.focusStartEl;tt(w)||(el(w),document.activeElement!==w&&(w="first")),w==="first"&&ute(QM(h),!0),(document.activeElement===m||w==="container")&&el(h)})}}}function p(){const h=g(n);if(h){h.removeEventListener(Qv,a);const m=new CustomEvent(ey,{...z5,detail:{focusReason:s.value}});h.addEventListener(ey,u),h.dispatchEvent(m),!m.defaultPrevented&&(s.value=="keyboard"||!cte()||h.contains(document.activeElement))&&el(o??document.body),h.removeEventListener(ey,u),K5.remove(i)}}return Ct(()=>{e.trapped&&f(),Te(()=>e.trapped,h=>{h?f():p()})}),En(()=>{e.trapped&&p()}),{onKeydown:l}}});function pte(e,t,n,o,r,s){return he(e.$slots,"default",{handleKeydown:e.onKeydown})}var j0=ze(fte,[["render",pte],["__file","focus-trap.vue"]]);const hte=["fixed","absolute"],mte=We({boundariesPadding:{type:Number,default:0},fallbackPlacements:{type:Ce(Array),default:void 0},gpuAcceleration:{type:Boolean,default:!0},offset:{type:Number,default:12},placement:{type:String,values:L0,default:"bottom"},popperOptions:{type:Ce(Object),default:()=>({})},strategy:{type:String,values:hte,default:"absolute"}}),eT=We({...mte,id:String,style:{type:Ce([String,Array,Object])},className:{type:Ce([String,Array,Object])},effect:{type:String,default:"dark"},visible:Boolean,enterable:{type:Boolean,default:!0},pure:Boolean,focusOnShow:{type:Boolean,default:!1},trapping:{type:Boolean,default:!1},popperClass:{type:Ce([String,Array,Object])},popperStyle:{type:Ce([String,Array,Object])},referenceEl:{type:Ce(Object)},triggerTargetEl:{type:Ce(Object)},stopPopperMouseEvent:{type:Boolean,default:!0},ariaLabel:{type:String,default:void 0},virtualTriggering:Boolean,zIndex:Number}),gte={mouseenter:e=>e instanceof MouseEvent,mouseleave:e=>e instanceof MouseEvent,focus:()=>!0,blur:()=>!0,close:()=>!0},vte=(e,t=[])=>{const{placement:n,strategy:o,popperOptions:r}=e,s={placement:n,strategy:o,...r,modifiers:[..._te(e),...t]};return bte(s,r==null?void 0:r.modifiers),s},yte=e=>{if(xt)return ki(e)};function _te(e){const{offset:t,gpuAcceleration:n,fallbackPlacements:o}=e;return[{name:"offset",options:{offset:[0,t??12]}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5,fallbackPlacements:o}},{name:"computeStyles",options:{gpuAcceleration:n}}]}function bte(e,t){t&&(e.modifiers=[...e.modifiers,...t??[]])}const wte=0,Cte=e=>{const{popperInstanceRef:t,contentRef:n,triggerRef:o,role:r}=Be(I3,void 0),s=K(),i=K(),l=R(()=>({name:"eventListeners",enabled:!!e.visible})),a=R(()=>{var v;const w=g(s),_=(v=g(i))!=null?v:wte;return{name:"arrow",enabled:!Wx(w),options:{element:w,padding:_}}}),u=R(()=>({onFirstUpdate:()=>{h()},...vte(e,[g(a),g(l)])})),c=R(()=>yte(e.referenceEl)||g(o)),{attributes:d,state:f,styles:p,update:h,forceUpdate:m,instanceRef:y}=OX(c,n,u);return Te(y,v=>t.value=v),Ct(()=>{Te(()=>{var v;return(v=g(c))==null?void 0:v.getBoundingClientRect()},()=>{h()})}),{attributes:d,arrowRef:s,contentRef:n,instanceRef:y,state:f,styles:p,role:r,forceUpdate:m,update:h}},kte=(e,{attributes:t,styles:n,role:o})=>{const{nextZIndex:r}=D0(),s=Re("popper"),i=R(()=>g(t).popper),l=K(_t(e.zIndex)?e.zIndex:r()),a=R(()=>[s.b(),s.is("pure",e.pure),s.is(e.effect),e.popperClass]),u=R(()=>[{zIndex:g(l)},g(n).popper,e.popperStyle||{}]),c=R(()=>o.value==="dialog"?"false":void 0),d=R(()=>g(n).arrow||{});return{ariaModal:c,arrowStyle:d,contentAttrs:i,contentClass:a,contentStyle:u,contentZIndex:l,updateZIndex:()=>{l.value=_t(e.zIndex)?e.zIndex:r()}}},Ste=(e,t)=>{const n=K(!1),o=K();return{focusStartRef:o,trapped:n,onFocusAfterReleased:u=>{var c;((c=u.detail)==null?void 0:c.focusReason)!=="pointer"&&(o.value="first",t("blur"))},onFocusAfterTrapped:()=>{t("focus")},onFocusInTrap:u=>{e.visible&&!n.value&&(u.target&&(o.value=u.target),n.value=!0)},onFocusoutPrevented:u=>{e.trapping||(u.detail.focusReason==="pointer"&&u.preventDefault(),n.value=!1)},onReleaseRequested:()=>{n.value=!1,t("close")}}},$te=Q({name:"ElPopperContent"}),Ete=Q({...$te,props:eT,emits:gte,setup(e,{expose:t,emit:n}){const o=e,{focusStartRef:r,trapped:s,onFocusAfterReleased:i,onFocusAfterTrapped:l,onFocusInTrap:a,onFocusoutPrevented:u,onReleaseRequested:c}=Ste(o,n),{attributes:d,arrowRef:f,contentRef:p,styles:h,instanceRef:m,role:y,update:v}=Cte(o),{ariaModal:w,arrowStyle:_,contentAttrs:S,contentClass:x,contentStyle:E,updateZIndex:T}=kte(o,{styles:h,attributes:d,role:y}),O=Be(uu,void 0),P=K();wt(qM,{arrowStyle:_,arrowRef:f,arrowOffset:P}),O&&(O.addInputId||O.removeInputId)&&wt(uu,{...O,addInputId:yt,removeInputId:yt});let N;const F=(Y=!0)=>{v(),Y&&T()},B=()=>{F(!1),o.visible&&o.focusOnShow?s.value=!0:o.visible===!1&&(s.value=!1)};return Ct(()=>{Te(()=>o.triggerTargetEl,(Y,Z)=>{N==null||N(),N=void 0;const U=g(Y||p.value),j=g(Z||p.value);gs(U)&&(N=Te([y,()=>o.ariaLabel,w,()=>o.id],V=>{["role","aria-label","aria-modal","id"].forEach((H,L)=>{xo(V[L])?U.removeAttribute(H):U.setAttribute(H,V[L])})},{immediate:!0})),j!==U&&gs(j)&&["role","aria-label","aria-modal","id"].forEach(V=>{j.removeAttribute(V)})},{immediate:!0}),Te(()=>o.visible,B,{immediate:!0})}),En(()=>{N==null||N(),N=void 0}),t({popperContentRef:p,popperInstanceRef:m,updatePopper:F,contentStyle:E}),(Y,Z)=>(C(),M("div",un({ref_key:"contentRef",ref:p},g(S),{style:g(E),class:g(x),tabindex:"-1",onMouseenter:Z[0]||(Z[0]=U=>Y.$emit("mouseenter",U)),onMouseleave:Z[1]||(Z[1]=U=>Y.$emit("mouseleave",U))}),[k(g(j0),{trapped:g(s),"trap-on-focus-in":!0,"focus-trap-el":g(p),"focus-start-el":g(r),onFocusAfterTrapped:g(l),onFocusAfterReleased:g(i),onFocusin:g(a),onFocusoutPrevented:g(u),onReleaseRequested:g(c)},{default:$(()=>[he(Y.$slots,"default")]),_:3},8,["trapped","focus-trap-el","focus-start-el","onFocusAfterTrapped","onFocusAfterReleased","onFocusin","onFocusoutPrevented","onReleaseRequested"])],16))}});var xte=ze(Ete,[["__file","content.vue"]]);const Mte=Zt(Yee),H0=Symbol("elTooltip"),ar=We({...DX,...eT,appendTo:{type:Ce([String,Object])},content:{type:String,default:""},rawContent:{type:Boolean,default:!1},persistent:Boolean,ariaLabel:String,visible:{type:Ce(Boolean),default:null},transition:String,teleported:{type:Boolean,default:!0},disabled:Boolean}),Dp=We({...XM,disabled:Boolean,trigger:{type:Ce([String,Array]),default:"hover"},triggerKeys:{type:Ce(Array),default:()=>[rt.enter,rt.space]}}),{useModelToggleProps:Tte,useModelToggleEmits:Ote,useModelToggle:Ite}=pM("visible"),Ate=We({...GM,...Tte,...ar,...Dp,...YM,showArrow:{type:Boolean,default:!0}}),Nte=[...Ote,"before-show","before-hide","show","hide","open","close"],Pte=(e,t)=>Me(e)?e.includes(t):e===t,Lu=(e,t,n)=>o=>{Pte(g(e),t)&&n(o)},Lte=Q({name:"ElTooltipTrigger"}),Rte=Q({...Lte,props:Dp,setup(e,{expose:t}){const n=e,o=Re("tooltip"),{controlled:r,id:s,open:i,onOpen:l,onClose:a,onToggle:u}=Be(H0,void 0),c=K(null),d=()=>{if(g(r)||n.disabled)return!0},f=pn(n,"trigger"),p=Nn(d,Lu(f,"hover",l)),h=Nn(d,Lu(f,"hover",a)),m=Nn(d,Lu(f,"click",S=>{S.button===0&&u(S)})),y=Nn(d,Lu(f,"focus",l)),v=Nn(d,Lu(f,"focus",a)),w=Nn(d,Lu(f,"contextmenu",S=>{S.preventDefault(),u(S)})),_=Nn(d,S=>{const{code:x}=S;n.triggerKeys.includes(x)&&(S.preventDefault(),u(S))});return t({triggerRef:c}),(S,x)=>(C(),q(g(nte),{id:g(s),"virtual-ref":S.virtualRef,open:g(i),"virtual-triggering":S.virtualTriggering,class:D(g(o).e("trigger")),onBlur:g(v),onClick:g(m),onContextmenu:g(w),onFocus:g(y),onMouseenter:g(p),onMouseleave:g(h),onKeydown:g(_)},{default:$(()=>[he(S.$slots,"default")]),_:3},8,["id","virtual-ref","open","virtual-triggering","class","onBlur","onClick","onContextmenu","onFocus","onMouseenter","onMouseleave","onKeydown"]))}});var Dte=ze(Rte,[["__file","trigger.vue"]]);const Fte=Q({name:"ElTooltipContent",inheritAttrs:!1}),Vte=Q({...Fte,props:ar,setup(e,{expose:t}){const n=e,{selector:o}=xM(),r=Re("tooltip"),s=K(null),i=K(!1),{controlled:l,id:a,open:u,trigger:c,onClose:d,onOpen:f,onShow:p,onHide:h,onBeforeShow:m,onBeforeHide:y}=Be(H0,void 0),v=R(()=>n.transition||`${r.namespace.value}-fade-in-linear`),w=R(()=>n.persistent);En(()=>{i.value=!0});const _=R(()=>g(w)?!0:g(u)),S=R(()=>n.disabled?!1:g(u)),x=R(()=>n.appendTo||o.value),E=R(()=>{var V;return(V=n.style)!=null?V:{}}),T=R(()=>!g(u)),O=()=>{h()},P=()=>{if(g(l))return!0},N=Nn(P,()=>{n.enterable&&g(c)==="hover"&&f()}),F=Nn(P,()=>{g(c)==="hover"&&d()}),B=()=>{var V,H;(H=(V=s.value)==null?void 0:V.updatePopper)==null||H.call(V),m==null||m()},Y=()=>{y==null||y()},Z=()=>{p(),j=fx(R(()=>{var V;return(V=s.value)==null?void 0:V.popperContentRef}),()=>{if(g(l))return;g(c)!=="hover"&&d()})},U=()=>{n.virtualTriggering||d()};let j;return Te(()=>g(u),V=>{V||j==null||j()},{flush:"post"}),Te(()=>n.content,()=>{var V,H;(H=(V=s.value)==null?void 0:V.updatePopper)==null||H.call(V)}),t({contentRef:s}),(V,H)=>(C(),q(_s,{disabled:!V.teleported,to:g(x)},[k(_r,{name:g(v),onAfterLeave:O,onBeforeEnter:B,onAfterEnter:Z,onBeforeLeave:Y},{default:$(()=>[g(_)?He((C(),q(g(xte),un({key:0,id:g(a),ref_key:"contentRef",ref:s},V.$attrs,{"aria-label":V.ariaLabel,"aria-hidden":g(T),"boundaries-padding":V.boundariesPadding,"fallback-placements":V.fallbackPlacements,"gpu-acceleration":V.gpuAcceleration,offset:V.offset,placement:V.placement,"popper-options":V.popperOptions,strategy:V.strategy,effect:V.effect,enterable:V.enterable,pure:V.pure,"popper-class":V.popperClass,"popper-style":[V.popperStyle,g(E)],"reference-el":V.referenceEl,"trigger-target-el":V.triggerTargetEl,visible:g(S),"z-index":V.zIndex,onMouseenter:g(N),onMouseleave:g(F),onBlur:U,onClose:g(d)}),{default:$(()=>[i.value?W("v-if",!0):he(V.$slots,"default",{key:0})]),_:3},16,["id","aria-label","aria-hidden","boundaries-padding","fallback-placements","gpu-acceleration","offset","placement","popper-options","strategy","effect","enterable","pure","popper-class","popper-style","reference-el","trigger-target-el","visible","z-index","onMouseenter","onMouseleave","onClose"])),[[en,g(S)]]):W("v-if",!0)]),_:3},8,["name"])],8,["disabled","to"]))}});var Bte=ze(Vte,[["__file","content.vue"]]);const zte=["innerHTML"],jte={key:1},Hte=Q({name:"ElTooltip"}),Ute=Q({...Hte,props:Ate,emits:Nte,setup(e,{expose:t,emit:n}){const o=e;RX();const r=Hr(),s=K(),i=K(),l=()=>{var v;const w=g(s);w&&((v=w.popperInstanceRef)==null||v.update())},a=K(!1),u=K(),{show:c,hide:d,hasUpdateHandler:f}=Ite({indicator:a,toggleReason:u}),{onOpen:p,onClose:h}=FX({showAfter:pn(o,"showAfter"),hideAfter:pn(o,"hideAfter"),autoClose:pn(o,"autoClose"),open:c,close:d}),m=R(()=>Br(o.visible)&&!f.value);wt(H0,{controlled:m,id:r,open:_u(a),trigger:pn(o,"trigger"),onOpen:v=>{p(v)},onClose:v=>{h(v)},onToggle:v=>{g(a)?h(v):p(v)},onShow:()=>{n("show",u.value)},onHide:()=>{n("hide",u.value)},onBeforeShow:()=>{n("before-show",u.value)},onBeforeHide:()=>{n("before-hide",u.value)},updatePopper:l}),Te(()=>o.disabled,v=>{v&&a.value&&(a.value=!1)});const y=v=>{var w,_;const S=(_=(w=i.value)==null?void 0:w.contentRef)==null?void 0:_.popperContentRef,x=(v==null?void 0:v.relatedTarget)||document.activeElement;return S&&S.contains(x)};return mw(()=>a.value&&d()),t({popperRef:s,contentRef:i,isFocusInsideContent:y,updatePopper:l,onOpen:p,onClose:h,hide:d}),(v,w)=>(C(),q(g(Mte),{ref_key:"popperRef",ref:s,role:v.role},{default:$(()=>[k(Dte,{disabled:v.disabled,trigger:v.trigger,"trigger-keys":v.triggerKeys,"virtual-ref":v.virtualRef,"virtual-triggering":v.virtualTriggering},{default:$(()=>[v.$slots.default?he(v.$slots,"default",{key:0}):W("v-if",!0)]),_:3},8,["disabled","trigger","trigger-keys","virtual-ref","virtual-triggering"]),k(Bte,{ref_key:"contentRef",ref:i,"aria-label":v.ariaLabel,"boundaries-padding":v.boundariesPadding,content:v.content,disabled:v.disabled,effect:v.effect,enterable:v.enterable,"fallback-placements":v.fallbackPlacements,"hide-after":v.hideAfter,"gpu-acceleration":v.gpuAcceleration,offset:v.offset,persistent:v.persistent,"popper-class":v.popperClass,"popper-style":v.popperStyle,placement:v.placement,"popper-options":v.popperOptions,pure:v.pure,"raw-content":v.rawContent,"reference-el":v.referenceEl,"trigger-target-el":v.triggerTargetEl,"show-after":v.showAfter,strategy:v.strategy,teleported:v.teleported,transition:v.transition,"virtual-triggering":v.virtualTriggering,"z-index":v.zIndex,"append-to":v.appendTo},{default:$(()=>[he(v.$slots,"content",{},()=>[v.rawContent?(C(),M("span",{key:0,innerHTML:v.content},null,8,zte)):(C(),M("span",jte,A(v.content),1))]),v.showArrow?(C(),q(g(Xee),{key:0,"arrow-offset":v.arrowOffset},null,8,["arrow-offset"])):W("v-if",!0)]),_:3},8,["aria-label","boundaries-padding","content","disabled","effect","enterable","fallback-placements","hide-after","gpu-acceleration","offset","persistent","popper-class","popper-style","placement","popper-options","pure","raw-content","reference-el","trigger-target-el","show-after","strategy","teleported","transition","virtual-triggering","z-index","append-to"])]),_:3},8,["role"]))}});var Wte=ze(Ute,[["__file","tooltip.vue"]]);const $u=Zt(Wte),Kte=We({size:{type:[Number,String],values:Zl,default:"",validator:e=>_t(e)},shape:{type:String,values:["circle","square"],default:"circle"},icon:{type:Oo},src:{type:String,default:""},alt:String,srcSet:String,fit:{type:Ce(String),default:"cover"}}),qte={error:e=>e instanceof Event},Gte=["src","alt","srcset"],Yte=Q({name:"ElAvatar"}),Zte=Q({...Yte,props:Kte,emits:qte,setup(e,{emit:t}){const n=e,o=Re("avatar"),r=K(!1),s=R(()=>{const{size:u,icon:c,shape:d}=n,f=[o.b()];return tt(u)&&f.push(o.m(u)),c&&f.push(o.m("icon")),d&&f.push(o.m(d)),f}),i=R(()=>{const{size:u}=n;return _t(u)?o.cssVarBlock({size:Zo(u)||""}):void 0}),l=R(()=>({objectFit:n.fit}));Te(()=>n.src,()=>r.value=!1);function a(u){r.value=!0,t("error",u)}return(u,c)=>(C(),M("span",{class:D(g(s)),style:Qe(g(i))},[(u.src||u.srcSet)&&!r.value?(C(),M("img",{key:0,src:u.src,alt:u.alt,srcset:u.srcSet,style:Qe(g(l)),onError:a},null,44,Gte)):u.icon?(C(),q(g(Ne),{key:1},{default:$(()=>[(C(),q(Lt(u.icon)))]),_:1})):he(u.$slots,"default",{key:2})],6))}});var Jte=ze(Zte,[["__file","avatar.vue"]]);const Xte=Zt(Jte),tT=Symbol("breadcrumbKey"),Qte=We({separator:{type:String,default:"/"},separatorIcon:{type:Oo}}),ene=["aria-label"],tne=Q({name:"ElBreadcrumb"}),nne=Q({...tne,props:Qte,setup(e){const t=e,{t:n}=Kt(),o=Re("breadcrumb"),r=K();return wt(tT,t),Ct(()=>{const s=r.value.querySelectorAll(`.${o.e("item")}`);s.length&&s[s.length-1].setAttribute("aria-current","page")}),(s,i)=>(C(),M("div",{ref_key:"breadcrumb",ref:r,class:D(g(o).b()),"aria-label":g(n)("el.breadcrumb.label"),role:"navigation"},[he(s.$slots,"default")],10,ene))}});var one=ze(nne,[["__file","breadcrumb.vue"]]);const rne=We({to:{type:Ce([String,Object]),default:""},replace:{type:Boolean,default:!1}}),sne=Q({name:"ElBreadcrumbItem"}),ine=Q({...sne,props:rne,setup(e){const t=e,n=at(),o=Be(tT,void 0),r=Re("breadcrumb"),s=n.appContext.config.globalProperties.$router,i=K(),l=()=>{!t.to||!s||(t.replace?s.replace(t.to):s.push(t.to))};return(a,u)=>{var c,d;return C(),M("span",{class:D(g(r).e("item"))},[b("span",{ref_key:"link",ref:i,class:D([g(r).e("inner"),g(r).is("link",!!a.to)]),role:"link",onClick:l},[he(a.$slots,"default")],2),(c=g(o))!=null&&c.separatorIcon?(C(),q(g(Ne),{key:0,class:D(g(r).e("separator"))},{default:$(()=>[(C(),q(Lt(g(o).separatorIcon)))]),_:1},8,["class"])):(C(),M("span",{key:1,class:D(g(r).e("separator")),role:"presentation"},A((d=g(o))==null?void 0:d.separator),3))],2)}}});var nT=ze(ine,[["__file","breadcrumb-item.vue"]]);const lne=Zt(one,{BreadcrumbItem:nT}),ane=Gn(nT),oT=Symbol("buttonGroupContextKey"),une=(e,t)=>{Ua({from:"type.text",replacement:"link",version:"3.0.0",scope:"props",ref:"https://element-plus.org/en-US/component/button.html#button-attributes"},R(()=>e.type==="text"));const n=Be(oT,void 0),o=ph("button"),{form:r}=ni(),s=Jo(R(()=>n==null?void 0:n.size)),i=Gr(),l=K(),a=Kr(),u=R(()=>e.type||(n==null?void 0:n.type)||""),c=R(()=>{var h,m,y;return(y=(m=e.autoInsertSpace)!=null?m:(h=o.value)==null?void 0:h.autoInsertSpace)!=null?y:!1}),d=R(()=>e.tag==="button"?{ariaDisabled:i.value||e.loading,disabled:i.value||e.loading,autofocus:e.autofocus,type:e.nativeType}:{}),f=R(()=>{var h;const m=(h=a.default)==null?void 0:h.call(a);if(c.value&&(m==null?void 0:m.length)===1){const y=m[0];if((y==null?void 0:y.type)===Ai){const v=y.children;return/^\p{Unified_Ideograph}{2}$/u.test(v.trim())}}return!1});return{_disabled:i,_size:s,_type:u,_ref:l,_props:d,shouldAddSpace:f,handleClick:h=>{e.nativeType==="reset"&&(r==null||r.resetFields()),t("click",h)}}},cne=["default","primary","success","warning","info","danger","text",""],dne=["button","submit","reset"],lb=We({size:qr,disabled:Boolean,type:{type:String,values:cne,default:""},icon:{type:Oo},nativeType:{type:String,values:dne,default:"button"},loading:Boolean,loadingIcon:{type:Oo,default:()=>a3},plain:Boolean,text:Boolean,link:Boolean,bg:Boolean,autofocus:Boolean,round:Boolean,circle:Boolean,color:String,dark:Boolean,autoInsertSpace:{type:Boolean,default:void 0},tag:{type:Ce([String,Object]),default:"button"}}),fne={click:e=>e instanceof MouseEvent};function ro(e,t){pne(e)&&(e="100%");var n=hne(e);return e=t===360?e:Math.min(t,Math.max(0,parseFloat(e))),n&&(e=parseInt(String(e*t),10)/100),Math.abs(e-t)<1e-6?1:(t===360?e=(e<0?e%t+t:e%t)/parseFloat(String(t)):e=e%t/parseFloat(String(t)),e)}function hm(e){return Math.min(1,Math.max(0,e))}function pne(e){return typeof e=="string"&&e.indexOf(".")!==-1&&parseFloat(e)===1}function hne(e){return typeof e=="string"&&e.indexOf("%")!==-1}function rT(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function mm(e){return e<=1?"".concat(Number(e)*100,"%"):e}function Aa(e){return e.length===1?"0"+e:String(e)}function mne(e,t,n){return{r:ro(e,255)*255,g:ro(t,255)*255,b:ro(n,255)*255}}function G5(e,t,n){e=ro(e,255),t=ro(t,255),n=ro(n,255);var o=Math.max(e,t,n),r=Math.min(e,t,n),s=0,i=0,l=(o+r)/2;if(o===r)i=0,s=0;else{var a=o-r;switch(i=l>.5?a/(2-o-r):a/(o+r),o){case e:s=(t-n)/a+(t<n?6:0);break;case t:s=(n-e)/a+2;break;case n:s=(e-t)/a+4;break}s/=6}return{h:s,s:i,l}}function ty(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*(6*n):n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function gne(e,t,n){var o,r,s;if(e=ro(e,360),t=ro(t,100),n=ro(n,100),t===0)r=n,s=n,o=n;else{var i=n<.5?n*(1+t):n+t-n*t,l=2*n-i;o=ty(l,i,e+1/3),r=ty(l,i,e),s=ty(l,i,e-1/3)}return{r:o*255,g:r*255,b:s*255}}function Y5(e,t,n){e=ro(e,255),t=ro(t,255),n=ro(n,255);var o=Math.max(e,t,n),r=Math.min(e,t,n),s=0,i=o,l=o-r,a=o===0?0:l/o;if(o===r)s=0;else{switch(o){case e:s=(t-n)/l+(t<n?6:0);break;case t:s=(n-e)/l+2;break;case n:s=(e-t)/l+4;break}s/=6}return{h:s,s:a,v:i}}function vne(e,t,n){e=ro(e,360)*6,t=ro(t,100),n=ro(n,100);var o=Math.floor(e),r=e-o,s=n*(1-t),i=n*(1-r*t),l=n*(1-(1-r)*t),a=o%6,u=[n,i,s,s,l,n][a],c=[l,n,n,i,s,s][a],d=[s,s,l,n,n,i][a];return{r:u*255,g:c*255,b:d*255}}function Z5(e,t,n,o){var r=[Aa(Math.round(e).toString(16)),Aa(Math.round(t).toString(16)),Aa(Math.round(n).toString(16))];return o&&r[0].startsWith(r[0].charAt(1))&&r[1].startsWith(r[1].charAt(1))&&r[2].startsWith(r[2].charAt(1))?r[0].charAt(0)+r[1].charAt(0)+r[2].charAt(0):r.join("")}function yne(e,t,n,o,r){var s=[Aa(Math.round(e).toString(16)),Aa(Math.round(t).toString(16)),Aa(Math.round(n).toString(16)),Aa(_ne(o))];return r&&s[0].startsWith(s[0].charAt(1))&&s[1].startsWith(s[1].charAt(1))&&s[2].startsWith(s[2].charAt(1))&&s[3].startsWith(s[3].charAt(1))?s[0].charAt(0)+s[1].charAt(0)+s[2].charAt(0)+s[3].charAt(0):s.join("")}function _ne(e){return Math.round(parseFloat(e)*255).toString(16)}function J5(e){return or(e)/255}function or(e){return parseInt(e,16)}function bne(e){return{r:e>>16,g:(e&65280)>>8,b:e&255}}var ab={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};function wne(e){var t={r:0,g:0,b:0},n=1,o=null,r=null,s=null,i=!1,l=!1;return typeof e=="string"&&(e=Sne(e)),typeof e=="object"&&(ci(e.r)&&ci(e.g)&&ci(e.b)?(t=mne(e.r,e.g,e.b),i=!0,l=String(e.r).substr(-1)==="%"?"prgb":"rgb"):ci(e.h)&&ci(e.s)&&ci(e.v)?(o=mm(e.s),r=mm(e.v),t=vne(e.h,o,r),i=!0,l="hsv"):ci(e.h)&&ci(e.s)&&ci(e.l)&&(o=mm(e.s),s=mm(e.l),t=gne(e.h,o,s),i=!0,l="hsl"),Object.prototype.hasOwnProperty.call(e,"a")&&(n=e.a)),n=rT(n),{ok:i,format:e.format||l,r:Math.min(255,Math.max(t.r,0)),g:Math.min(255,Math.max(t.g,0)),b:Math.min(255,Math.max(t.b,0)),a:n}}var Cne="[-\\+]?\\d+%?",kne="[-\\+]?\\d*\\.\\d+%?",Tl="(?:".concat(kne,")|(?:").concat(Cne,")"),ny="[\\s|\\(]+(".concat(Tl,")[,|\\s]+(").concat(Tl,")[,|\\s]+(").concat(Tl,")\\s*\\)?"),oy="[\\s|\\(]+(".concat(Tl,")[,|\\s]+(").concat(Tl,")[,|\\s]+(").concat(Tl,")[,|\\s]+(").concat(Tl,")\\s*\\)?"),Xr={CSS_UNIT:new RegExp(Tl),rgb:new RegExp("rgb"+ny),rgba:new RegExp("rgba"+oy),hsl:new RegExp("hsl"+ny),hsla:new RegExp("hsla"+oy),hsv:new RegExp("hsv"+ny),hsva:new RegExp("hsva"+oy),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function Sne(e){if(e=e.trim().toLowerCase(),e.length===0)return!1;var t=!1;if(ab[e])e=ab[e],t=!0;else if(e==="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var n=Xr.rgb.exec(e);return n?{r:n[1],g:n[2],b:n[3]}:(n=Xr.rgba.exec(e),n?{r:n[1],g:n[2],b:n[3],a:n[4]}:(n=Xr.hsl.exec(e),n?{h:n[1],s:n[2],l:n[3]}:(n=Xr.hsla.exec(e),n?{h:n[1],s:n[2],l:n[3],a:n[4]}:(n=Xr.hsv.exec(e),n?{h:n[1],s:n[2],v:n[3]}:(n=Xr.hsva.exec(e),n?{h:n[1],s:n[2],v:n[3],a:n[4]}:(n=Xr.hex8.exec(e),n?{r:or(n[1]),g:or(n[2]),b:or(n[3]),a:J5(n[4]),format:t?"name":"hex8"}:(n=Xr.hex6.exec(e),n?{r:or(n[1]),g:or(n[2]),b:or(n[3]),format:t?"name":"hex"}:(n=Xr.hex4.exec(e),n?{r:or(n[1]+n[1]),g:or(n[2]+n[2]),b:or(n[3]+n[3]),a:J5(n[4]+n[4]),format:t?"name":"hex8"}:(n=Xr.hex3.exec(e),n?{r:or(n[1]+n[1]),g:or(n[2]+n[2]),b:or(n[3]+n[3]),format:t?"name":"hex"}:!1)))))))))}function ci(e){return!!Xr.CSS_UNIT.exec(String(e))}var $ne=function(){function e(t,n){t===void 0&&(t=""),n===void 0&&(n={});var o;if(t instanceof e)return t;typeof t=="number"&&(t=bne(t)),this.originalInput=t;var r=wne(t);this.originalInput=t,this.r=r.r,this.g=r.g,this.b=r.b,this.a=r.a,this.roundA=Math.round(100*this.a)/100,this.format=(o=n.format)!==null&&o!==void 0?o:r.format,this.gradientType=n.gradientType,this.r<1&&(this.r=Math.round(this.r)),this.g<1&&(this.g=Math.round(this.g)),this.b<1&&(this.b=Math.round(this.b)),this.isValid=r.ok}return e.prototype.isDark=function(){return this.getBrightness()<128},e.prototype.isLight=function(){return!this.isDark()},e.prototype.getBrightness=function(){var t=this.toRgb();return(t.r*299+t.g*587+t.b*114)/1e3},e.prototype.getLuminance=function(){var t=this.toRgb(),n,o,r,s=t.r/255,i=t.g/255,l=t.b/255;return s<=.03928?n=s/12.92:n=Math.pow((s+.055)/1.055,2.4),i<=.03928?o=i/12.92:o=Math.pow((i+.055)/1.055,2.4),l<=.03928?r=l/12.92:r=Math.pow((l+.055)/1.055,2.4),.2126*n+.7152*o+.0722*r},e.prototype.getAlpha=function(){return this.a},e.prototype.setAlpha=function(t){return this.a=rT(t),this.roundA=Math.round(100*this.a)/100,this},e.prototype.isMonochrome=function(){var t=this.toHsl().s;return t===0},e.prototype.toHsv=function(){var t=Y5(this.r,this.g,this.b);return{h:t.h*360,s:t.s,v:t.v,a:this.a}},e.prototype.toHsvString=function(){var t=Y5(this.r,this.g,this.b),n=Math.round(t.h*360),o=Math.round(t.s*100),r=Math.round(t.v*100);return this.a===1?"hsv(".concat(n,", ").concat(o,"%, ").concat(r,"%)"):"hsva(".concat(n,", ").concat(o,"%, ").concat(r,"%, ").concat(this.roundA,")")},e.prototype.toHsl=function(){var t=G5(this.r,this.g,this.b);return{h:t.h*360,s:t.s,l:t.l,a:this.a}},e.prototype.toHslString=function(){var t=G5(this.r,this.g,this.b),n=Math.round(t.h*360),o=Math.round(t.s*100),r=Math.round(t.l*100);return this.a===1?"hsl(".concat(n,", ").concat(o,"%, ").concat(r,"%)"):"hsla(".concat(n,", ").concat(o,"%, ").concat(r,"%, ").concat(this.roundA,")")},e.prototype.toHex=function(t){return t===void 0&&(t=!1),Z5(this.r,this.g,this.b,t)},e.prototype.toHexString=function(t){return t===void 0&&(t=!1),"#"+this.toHex(t)},e.prototype.toHex8=function(t){return t===void 0&&(t=!1),yne(this.r,this.g,this.b,this.a,t)},e.prototype.toHex8String=function(t){return t===void 0&&(t=!1),"#"+this.toHex8(t)},e.prototype.toHexShortString=function(t){return t===void 0&&(t=!1),this.a===1?this.toHexString(t):this.toHex8String(t)},e.prototype.toRgb=function(){return{r:Math.round(this.r),g:Math.round(this.g),b:Math.round(this.b),a:this.a}},e.prototype.toRgbString=function(){var t=Math.round(this.r),n=Math.round(this.g),o=Math.round(this.b);return this.a===1?"rgb(".concat(t,", ").concat(n,", ").concat(o,")"):"rgba(".concat(t,", ").concat(n,", ").concat(o,", ").concat(this.roundA,")")},e.prototype.toPercentageRgb=function(){var t=function(n){return"".concat(Math.round(ro(n,255)*100),"%")};return{r:t(this.r),g:t(this.g),b:t(this.b),a:this.a}},e.prototype.toPercentageRgbString=function(){var t=function(n){return Math.round(ro(n,255)*100)};return this.a===1?"rgb(".concat(t(this.r),"%, ").concat(t(this.g),"%, ").concat(t(this.b),"%)"):"rgba(".concat(t(this.r),"%, ").concat(t(this.g),"%, ").concat(t(this.b),"%, ").concat(this.roundA,")")},e.prototype.toName=function(){if(this.a===0)return"transparent";if(this.a<1)return!1;for(var t="#"+Z5(this.r,this.g,this.b,!1),n=0,o=Object.entries(ab);n<o.length;n++){var r=o[n],s=r[0],i=r[1];if(t===i)return s}return!1},e.prototype.toString=function(t){var n=!!t;t=t??this.format;var o=!1,r=this.a<1&&this.a>=0,s=!n&&r&&(t.startsWith("hex")||t==="name");return s?t==="name"&&this.a===0?this.toName():this.toRgbString():(t==="rgb"&&(o=this.toRgbString()),t==="prgb"&&(o=this.toPercentageRgbString()),(t==="hex"||t==="hex6")&&(o=this.toHexString()),t==="hex3"&&(o=this.toHexString(!0)),t==="hex4"&&(o=this.toHex8String(!0)),t==="hex8"&&(o=this.toHex8String()),t==="name"&&(o=this.toName()),t==="hsl"&&(o=this.toHslString()),t==="hsv"&&(o=this.toHsvString()),o||this.toHexString())},e.prototype.toNumber=function(){return(Math.round(this.r)<<16)+(Math.round(this.g)<<8)+Math.round(this.b)},e.prototype.clone=function(){return new e(this.toString())},e.prototype.lighten=function(t){t===void 0&&(t=10);var n=this.toHsl();return n.l+=t/100,n.l=hm(n.l),new e(n)},e.prototype.brighten=function(t){t===void 0&&(t=10);var n=this.toRgb();return n.r=Math.max(0,Math.min(255,n.r-Math.round(255*-(t/100)))),n.g=Math.max(0,Math.min(255,n.g-Math.round(255*-(t/100)))),n.b=Math.max(0,Math.min(255,n.b-Math.round(255*-(t/100)))),new e(n)},e.prototype.darken=function(t){t===void 0&&(t=10);var n=this.toHsl();return n.l-=t/100,n.l=hm(n.l),new e(n)},e.prototype.tint=function(t){return t===void 0&&(t=10),this.mix("white",t)},e.prototype.shade=function(t){return t===void 0&&(t=10),this.mix("black",t)},e.prototype.desaturate=function(t){t===void 0&&(t=10);var n=this.toHsl();return n.s-=t/100,n.s=hm(n.s),new e(n)},e.prototype.saturate=function(t){t===void 0&&(t=10);var n=this.toHsl();return n.s+=t/100,n.s=hm(n.s),new e(n)},e.prototype.greyscale=function(){return this.desaturate(100)},e.prototype.spin=function(t){var n=this.toHsl(),o=(n.h+t)%360;return n.h=o<0?360+o:o,new e(n)},e.prototype.mix=function(t,n){n===void 0&&(n=50);var o=this.toRgb(),r=new e(t).toRgb(),s=n/100,i={r:(r.r-o.r)*s+o.r,g:(r.g-o.g)*s+o.g,b:(r.b-o.b)*s+o.b,a:(r.a-o.a)*s+o.a};return new e(i)},e.prototype.analogous=function(t,n){t===void 0&&(t=6),n===void 0&&(n=30);var o=this.toHsl(),r=360/n,s=[this];for(o.h=(o.h-(r*t>>1)+720)%360;--t;)o.h=(o.h+r)%360,s.push(new e(o));return s},e.prototype.complement=function(){var t=this.toHsl();return t.h=(t.h+180)%360,new e(t)},e.prototype.monochromatic=function(t){t===void 0&&(t=6);for(var n=this.toHsv(),o=n.h,r=n.s,s=n.v,i=[],l=1/t;t--;)i.push(new e({h:o,s:r,v:s})),s=(s+l)%1;return i},e.prototype.splitcomplement=function(){var t=this.toHsl(),n=t.h;return[this,new e({h:(n+72)%360,s:t.s,l:t.l}),new e({h:(n+216)%360,s:t.s,l:t.l})]},e.prototype.onBackground=function(t){var n=this.toRgb(),o=new e(t).toRgb(),r=n.a+o.a*(1-n.a);return new e({r:(n.r*n.a+o.r*o.a*(1-n.a))/r,g:(n.g*n.a+o.g*o.a*(1-n.a))/r,b:(n.b*n.a+o.b*o.a*(1-n.a))/r,a:r})},e.prototype.triad=function(){return this.polyad(3)},e.prototype.tetrad=function(){return this.polyad(4)},e.prototype.polyad=function(t){for(var n=this.toHsl(),o=n.h,r=[this],s=360/t,i=1;i<t;i++)r.push(new e({h:(o+i*s)%360,s:n.s,l:n.l}));return r},e.prototype.equals=function(t){return this.toRgbString()===new e(t).toRgbString()},e}();function Zi(e,t=20){return e.mix("#141414",t).toString()}function Ene(e){const t=Gr(),n=Re("button");return R(()=>{let o={};const r=e.color;if(r){const s=new $ne(r),i=e.dark?s.tint(20).toString():Zi(s,20);if(e.plain)o=n.cssVarBlock({"bg-color":e.dark?Zi(s,90):s.tint(90).toString(),"text-color":r,"border-color":e.dark?Zi(s,50):s.tint(50).toString(),"hover-text-color":`var(${n.cssVarName("color-white")})`,"hover-bg-color":r,"hover-border-color":r,"active-bg-color":i,"active-text-color":`var(${n.cssVarName("color-white")})`,"active-border-color":i}),t.value&&(o[n.cssVarBlockName("disabled-bg-color")]=e.dark?Zi(s,90):s.tint(90).toString(),o[n.cssVarBlockName("disabled-text-color")]=e.dark?Zi(s,50):s.tint(50).toString(),o[n.cssVarBlockName("disabled-border-color")]=e.dark?Zi(s,80):s.tint(80).toString());else{const l=e.dark?Zi(s,30):s.tint(30).toString(),a=s.isDark()?`var(${n.cssVarName("color-white")})`:`var(${n.cssVarName("color-black")})`;if(o=n.cssVarBlock({"bg-color":r,"text-color":a,"border-color":r,"hover-bg-color":l,"hover-text-color":a,"hover-border-color":l,"active-bg-color":i,"active-border-color":i}),t.value){const u=e.dark?Zi(s,50):s.tint(50).toString();o[n.cssVarBlockName("disabled-bg-color")]=u,o[n.cssVarBlockName("disabled-text-color")]=e.dark?"rgba(255, 255, 255, 0.5)":`var(${n.cssVarName("color-white")})`,o[n.cssVarBlockName("disabled-border-color")]=u}}}return o})}const xne=Q({name:"ElButton"}),Mne=Q({...xne,props:lb,emits:fne,setup(e,{expose:t,emit:n}){const o=e,r=Ene(o),s=Re("button"),{_ref:i,_size:l,_type:a,_disabled:u,_props:c,shouldAddSpace:d,handleClick:f}=une(o,n),p=R(()=>[s.b(),s.m(a.value),s.m(l.value),s.is("disabled",u.value),s.is("loading",o.loading),s.is("plain",o.plain),s.is("round",o.round),s.is("circle",o.circle),s.is("text",o.text),s.is("link",o.link),s.is("has-bg",o.bg)]);return t({ref:i,size:l,type:a,disabled:u,shouldAddSpace:d}),(h,m)=>(C(),q(Lt(h.tag),un({ref_key:"_ref",ref:i},g(c),{class:g(p),style:g(r),onClick:g(f)}),{default:$(()=>[h.loading?(C(),M(fe,{key:0},[h.$slots.loading?he(h.$slots,"loading",{key:0}):(C(),q(g(Ne),{key:1,class:D(g(s).is("loading"))},{default:$(()=>[(C(),q(Lt(h.loadingIcon)))]),_:1},8,["class"]))],64)):h.icon||h.$slots.icon?(C(),q(g(Ne),{key:1},{default:$(()=>[h.icon?(C(),q(Lt(h.icon),{key:0})):he(h.$slots,"icon",{key:1})]),_:3})):W("v-if",!0),h.$slots.default?(C(),M("span",{key:2,class:D({[g(s).em("text","expand")]:g(d)})},[he(h.$slots,"default")],2)):W("v-if",!0)]),_:3},16,["class","style","onClick"]))}});var Tne=ze(Mne,[["__file","button.vue"]]);const One={size:lb.size,type:lb.type},Ine=Q({name:"ElButtonGroup"}),Ane=Q({...Ine,props:One,setup(e){const t=e;wt(oT,Dn({size:pn(t,"size"),type:pn(t,"type")}));const n=Re("button");return(o,r)=>(C(),M("div",{class:D(`${g(n).b("group")}`)},[he(o.$slots,"default")],2))}});var sT=ze(Ane,[["__file","button-group.vue"]]);const pt=Zt(Tne,{ButtonGroup:sT});Gn(sT);var On=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function _o(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var iT={exports:{}};(function(e,t){(function(n,o){e.exports=o()})(On,function(){var n=1e3,o=6e4,r=36e5,s="millisecond",i="second",l="minute",a="hour",u="day",c="week",d="month",f="quarter",p="year",h="date",m="Invalid Date",y=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,v=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,w={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(Z){var U=["th","st","nd","rd"],j=Z%100;return"["+Z+(U[(j-20)%10]||U[j]||U[0])+"]"}},_=function(Z,U,j){var V=String(Z);return!V||V.length>=U?Z:""+Array(U+1-V.length).join(j)+Z},S={s:_,z:function(Z){var U=-Z.utcOffset(),j=Math.abs(U),V=Math.floor(j/60),H=j%60;return(U<=0?"+":"-")+_(V,2,"0")+":"+_(H,2,"0")},m:function Z(U,j){if(U.date()<j.date())return-Z(j,U);var V=12*(j.year()-U.year())+(j.month()-U.month()),H=U.clone().add(V,d),L=j-H<0,I=U.clone().add(V+(L?-1:1),d);return+(-(V+(j-H)/(L?H-I:I-H))||0)},a:function(Z){return Z<0?Math.ceil(Z)||0:Math.floor(Z)},p:function(Z){return{M:d,y:p,w:c,d:u,D:h,h:a,m:l,s:i,ms:s,Q:f}[Z]||String(Z||"").toLowerCase().replace(/s$/,"")},u:function(Z){return Z===void 0}},x="en",E={};E[x]=w;var T="$isDayjsObject",O=function(Z){return Z instanceof B||!(!Z||!Z[T])},P=function Z(U,j,V){var H;if(!U)return x;if(typeof U=="string"){var L=U.toLowerCase();E[L]&&(H=L),j&&(E[L]=j,H=L);var I=U.split("-");if(!H&&I.length>1)return Z(I[0])}else{var X=U.name;E[X]=U,H=X}return!V&&H&&(x=H),H||!V&&x},N=function(Z,U){if(O(Z))return Z.clone();var j=typeof U=="object"?U:{};return j.date=Z,j.args=arguments,new B(j)},F=S;F.l=P,F.i=O,F.w=function(Z,U){return N(Z,{locale:U.$L,utc:U.$u,x:U.$x,$offset:U.$offset})};var B=function(){function Z(j){this.$L=P(j.locale,null,!0),this.parse(j),this.$x=this.$x||j.x||{},this[T]=!0}var U=Z.prototype;return U.parse=function(j){this.$d=function(V){var H=V.date,L=V.utc;if(H===null)return new Date(NaN);if(F.u(H))return new Date;if(H instanceof Date)return new Date(H);if(typeof H=="string"&&!/Z$/i.test(H)){var I=H.match(y);if(I){var X=I[2]-1||0,oe=(I[7]||"0").substring(0,3);return L?new Date(Date.UTC(I[1],X,I[3]||1,I[4]||0,I[5]||0,I[6]||0,oe)):new Date(I[1],X,I[3]||1,I[4]||0,I[5]||0,I[6]||0,oe)}}return new Date(H)}(j),this.init()},U.init=function(){var j=this.$d;this.$y=j.getFullYear(),this.$M=j.getMonth(),this.$D=j.getDate(),this.$W=j.getDay(),this.$H=j.getHours(),this.$m=j.getMinutes(),this.$s=j.getSeconds(),this.$ms=j.getMilliseconds()},U.$utils=function(){return F},U.isValid=function(){return this.$d.toString()!==m},U.isSame=function(j,V){var H=N(j);return this.startOf(V)<=H&&H<=this.endOf(V)},U.isAfter=function(j,V){return N(j)<this.startOf(V)},U.isBefore=function(j,V){return this.endOf(V)<N(j)},U.$g=function(j,V,H){return F.u(j)?this[V]:this.set(H,j)},U.unix=function(){return Math.floor(this.valueOf()/1e3)},U.valueOf=function(){return this.$d.getTime()},U.startOf=function(j,V){var H=this,L=!!F.u(V)||V,I=F.p(j),X=function(ve,le){var Ie=F.w(H.$u?Date.UTC(H.$y,le,ve):new Date(H.$y,le,ve),H);return L?Ie:Ie.endOf(u)},oe=function(ve,le){return F.w(H.toDate()[ve].apply(H.toDate("s"),(L?[0,0,0,0]:[23,59,59,999]).slice(le)),H)},z=this.$W,ge=this.$M,Oe=this.$D,xe="set"+(this.$u?"UTC":"");switch(I){case p:return L?X(1,0):X(31,11);case d:return L?X(1,ge):X(0,ge+1);case c:var ee=this.$locale().weekStart||0,de=(z<ee?z+7:z)-ee;return X(L?Oe-de:Oe+(6-de),ge);case u:case h:return oe(xe+"Hours",0);case a:return oe(xe+"Minutes",1);case l:return oe(xe+"Seconds",2);case i:return oe(xe+"Milliseconds",3);default:return this.clone()}},U.endOf=function(j){return this.startOf(j,!1)},U.$set=function(j,V){var H,L=F.p(j),I="set"+(this.$u?"UTC":""),X=(H={},H[u]=I+"Date",H[h]=I+"Date",H[d]=I+"Month",H[p]=I+"FullYear",H[a]=I+"Hours",H[l]=I+"Minutes",H[i]=I+"Seconds",H[s]=I+"Milliseconds",H)[L],oe=L===u?this.$D+(V-this.$W):V;if(L===d||L===p){var z=this.clone().set(h,1);z.$d[X](oe),z.init(),this.$d=z.set(h,Math.min(this.$D,z.daysInMonth())).$d}else X&&this.$d[X](oe);return this.init(),this},U.set=function(j,V){return this.clone().$set(j,V)},U.get=function(j){return this[F.p(j)]()},U.add=function(j,V){var H,L=this;j=Number(j);var I=F.p(V),X=function(ge){var Oe=N(L);return F.w(Oe.date(Oe.date()+Math.round(ge*j)),L)};if(I===d)return this.set(d,this.$M+j);if(I===p)return this.set(p,this.$y+j);if(I===u)return X(1);if(I===c)return X(7);var oe=(H={},H[l]=o,H[a]=r,H[i]=n,H)[I]||1,z=this.$d.getTime()+j*oe;return F.w(z,this)},U.subtract=function(j,V){return this.add(-1*j,V)},U.format=function(j){var V=this,H=this.$locale();if(!this.isValid())return H.invalidDate||m;var L=j||"YYYY-MM-DDTHH:mm:ssZ",I=F.z(this),X=this.$H,oe=this.$m,z=this.$M,ge=H.weekdays,Oe=H.months,xe=H.meridiem,ee=function(le,Ie,Ge,G){return le&&(le[Ie]||le(V,L))||Ge[Ie].slice(0,G)},de=function(le){return F.s(X%12||12,le,"0")},ve=xe||function(le,Ie,Ge){var G=le<12?"AM":"PM";return Ge?G.toLowerCase():G};return L.replace(v,function(le,Ie){return Ie||function(Ge){switch(Ge){case"YY":return String(V.$y).slice(-2);case"YYYY":return F.s(V.$y,4,"0");case"M":return z+1;case"MM":return F.s(z+1,2,"0");case"MMM":return ee(H.monthsShort,z,Oe,3);case"MMMM":return ee(Oe,z);case"D":return V.$D;case"DD":return F.s(V.$D,2,"0");case"d":return String(V.$W);case"dd":return ee(H.weekdaysMin,V.$W,ge,2);case"ddd":return ee(H.weekdaysShort,V.$W,ge,3);case"dddd":return ge[V.$W];case"H":return String(X);case"HH":return F.s(X,2,"0");case"h":return de(1);case"hh":return de(2);case"a":return ve(X,oe,!0);case"A":return ve(X,oe,!1);case"m":return String(oe);case"mm":return F.s(oe,2,"0");case"s":return String(V.$s);case"ss":return F.s(V.$s,2,"0");case"SSS":return F.s(V.$ms,3,"0");case"Z":return I}return null}(le)||I.replace(":","")})},U.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},U.diff=function(j,V,H){var L,I=this,X=F.p(V),oe=N(j),z=(oe.utcOffset()-this.utcOffset())*o,ge=this-oe,Oe=function(){return F.m(I,oe)};switch(X){case p:L=Oe()/12;break;case d:L=Oe();break;case f:L=Oe()/3;break;case c:L=(ge-z)/6048e5;break;case u:L=(ge-z)/864e5;break;case a:L=ge/r;break;case l:L=ge/o;break;case i:L=ge/n;break;default:L=ge}return H?L:F.a(L)},U.daysInMonth=function(){return this.endOf(d).$D},U.$locale=function(){return E[this.$L]},U.locale=function(j,V){if(!j)return this.$L;var H=this.clone(),L=P(j,V,!0);return L&&(H.$L=L),H},U.clone=function(){return F.w(this.$d,this)},U.toDate=function(){return new Date(this.valueOf())},U.toJSON=function(){return this.isValid()?this.toISOString():null},U.toISOString=function(){return this.$d.toISOString()},U.toString=function(){return this.$d.toUTCString()},Z}(),Y=B.prototype;return N.prototype=Y,[["$ms",s],["$s",i],["$m",l],["$H",a],["$W",u],["$M",d],["$y",p],["$D",h]].forEach(function(Z){Y[Z[1]]=function(U){return this.$g(U,Z[0],Z[1])}}),N.extend=function(Z,U){return Z.$i||(Z(U,B,N),Z.$i=!0),N},N.locale=P,N.isDayjs=O,N.unix=function(Z){return N(1e3*Z)},N.en=E[x],N.Ls=E,N.p={},N})})(iT);var Nne=iT.exports;const ut=_o(Nne);var lT={exports:{}};(function(e,t){(function(n,o){e.exports=o()})(On,function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},o=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,r=/\d\d/,s=/\d\d?/,i=/\d*[^-_:/,()\s\d]+/,l={},a=function(m){return(m=+m)+(m>68?1900:2e3)},u=function(m){return function(y){this[m]=+y}},c=[/[+-]\d\d:?(\d\d)?|Z/,function(m){(this.zone||(this.zone={})).offset=function(y){if(!y||y==="Z")return 0;var v=y.match(/([+-]|\d\d)/g),w=60*v[1]+(+v[2]||0);return w===0?0:v[0]==="+"?-w:w}(m)}],d=function(m){var y=l[m];return y&&(y.indexOf?y:y.s.concat(y.f))},f=function(m,y){var v,w=l.meridiem;if(w){for(var _=1;_<=24;_+=1)if(m.indexOf(w(_,0,y))>-1){v=_>12;break}}else v=m===(y?"pm":"PM");return v},p={A:[i,function(m){this.afternoon=f(m,!1)}],a:[i,function(m){this.afternoon=f(m,!0)}],S:[/\d/,function(m){this.milliseconds=100*+m}],SS:[r,function(m){this.milliseconds=10*+m}],SSS:[/\d{3}/,function(m){this.milliseconds=+m}],s:[s,u("seconds")],ss:[s,u("seconds")],m:[s,u("minutes")],mm:[s,u("minutes")],H:[s,u("hours")],h:[s,u("hours")],HH:[s,u("hours")],hh:[s,u("hours")],D:[s,u("day")],DD:[r,u("day")],Do:[i,function(m){var y=l.ordinal,v=m.match(/\d+/);if(this.day=v[0],y)for(var w=1;w<=31;w+=1)y(w).replace(/\[|\]/g,"")===m&&(this.day=w)}],M:[s,u("month")],MM:[r,u("month")],MMM:[i,function(m){var y=d("months"),v=(d("monthsShort")||y.map(function(w){return w.slice(0,3)})).indexOf(m)+1;if(v<1)throw new Error;this.month=v%12||v}],MMMM:[i,function(m){var y=d("months").indexOf(m)+1;if(y<1)throw new Error;this.month=y%12||y}],Y:[/[+-]?\d+/,u("year")],YY:[r,function(m){this.year=a(m)}],YYYY:[/\d{4}/,u("year")],Z:c,ZZ:c};function h(m){var y,v;y=m,v=l&&l.formats;for(var w=(m=y.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(P,N,F){var B=F&&F.toUpperCase();return N||v[F]||n[F]||v[B].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(Y,Z,U){return Z||U.slice(1)})})).match(o),_=w.length,S=0;S<_;S+=1){var x=w[S],E=p[x],T=E&&E[0],O=E&&E[1];w[S]=O?{regex:T,parser:O}:x.replace(/^\[|\]$/g,"")}return function(P){for(var N={},F=0,B=0;F<_;F+=1){var Y=w[F];if(typeof Y=="string")B+=Y.length;else{var Z=Y.regex,U=Y.parser,j=P.slice(B),V=Z.exec(j)[0];U.call(N,V),P=P.replace(V,"")}}return function(H){var L=H.afternoon;if(L!==void 0){var I=H.hours;L?I<12&&(H.hours+=12):I===12&&(H.hours=0),delete H.afternoon}}(N),N}}return function(m,y,v){v.p.customParseFormat=!0,m&&m.parseTwoDigitYear&&(a=m.parseTwoDigitYear);var w=y.prototype,_=w.parse;w.parse=function(S){var x=S.date,E=S.utc,T=S.args;this.$u=E;var O=T[1];if(typeof O=="string"){var P=T[2]===!0,N=T[3]===!0,F=P||N,B=T[2];N&&(B=T[2]),l=this.$locale(),!P&&B&&(l=v.Ls[B]),this.$d=function(j,V,H){try{if(["x","X"].indexOf(V)>-1)return new Date((V==="X"?1e3:1)*j);var L=h(V)(j),I=L.year,X=L.month,oe=L.day,z=L.hours,ge=L.minutes,Oe=L.seconds,xe=L.milliseconds,ee=L.zone,de=new Date,ve=oe||(I||X?1:de.getDate()),le=I||de.getFullYear(),Ie=0;I&&!X||(Ie=X>0?X-1:de.getMonth());var Ge=z||0,G=ge||0,J=Oe||0,ue=xe||0;return ee?new Date(Date.UTC(le,Ie,ve,Ge,G,J,ue+60*ee.offset*1e3)):H?new Date(Date.UTC(le,Ie,ve,Ge,G,J,ue)):new Date(le,Ie,ve,Ge,G,J,ue)}catch{return new Date("")}}(x,O,E),this.init(),B&&B!==!0&&(this.$L=this.locale(B).$L),F&&x!=this.format(O)&&(this.$d=new Date("")),l={}}else if(O instanceof Array)for(var Y=O.length,Z=1;Z<=Y;Z+=1){T[1]=O[Z-1];var U=v.apply(this,T);if(U.isValid()){this.$d=U.$d,this.$L=U.$L,this.init();break}Z===Y&&(this.$d=new Date(""))}else _.call(this,S)}}})})(lT);var Pne=lT.exports;const aT=_o(Pne),X5=["hours","minutes","seconds"],Q5="HH:mm:ss",qu="YYYY-MM-DD",Lne={date:qu,dates:qu,week:"gggg[w]ww",year:"YYYY",years:"YYYY",month:"YYYY-MM",datetime:`${qu} ${Q5}`,monthrange:"YYYY-MM",daterange:qu,datetimerange:`${qu} ${Q5}`},ry=(e,t)=>[e>0?e-1:void 0,e,e<t?e+1:void 0],uT=e=>Array.from(Array.from({length:e}).keys()),cT=e=>e.replace(/\W?m{1,2}|\W?ZZ/g,"").replace(/\W?h{1,2}|\W?s{1,3}|\W?a/gi,"").trim(),dT=e=>e.replace(/\W?D{1,2}|\W?Do|\W?d{1,4}|\W?M{1,4}|\W?Y{2,4}/g,"").trim(),e8=function(e,t){const n=og(e),o=og(t);return n&&o?e.getTime()===t.getTime():!n&&!o?e===t:!1},t8=function(e,t){const n=Me(e),o=Me(t);return n&&o?e.length!==t.length?!1:e.every((r,s)=>e8(r,t[s])):!n&&!o?e8(e,t):!1},n8=function(e,t,n){const o=qx(t)||t==="x"?ut(e).locale(n):ut(e,t).locale(n);return o.isValid()?o:void 0},o8=function(e,t,n){return qx(t)?e:t==="x"?+e:ut(e).locale(n).format(t)},sy=(e,t)=>{var n;const o=[],r=t==null?void 0:t();for(let s=0;s<e;s++)o.push((n=r==null?void 0:r.includes(s))!=null?n:!1);return o},fT=We({disabledHours:{type:Ce(Function)},disabledMinutes:{type:Ce(Function)},disabledSeconds:{type:Ce(Function)}}),Rne=We({visible:Boolean,actualVisible:{type:Boolean,default:void 0},format:{type:String,default:""}}),pT=We({id:{type:Ce([Array,String])},name:{type:Ce([Array,String]),default:""},popperClass:{type:String,default:""},format:String,valueFormat:String,dateFormat:String,timeFormat:String,type:{type:String,default:""},clearable:{type:Boolean,default:!0},clearIcon:{type:Ce([String,Object]),default:wd},editable:{type:Boolean,default:!0},prefixIcon:{type:Ce([String,Object]),default:""},size:qr,readonly:Boolean,disabled:Boolean,placeholder:{type:String,default:""},popperOptions:{type:Ce(Object),default:()=>({})},modelValue:{type:Ce([Date,Array,String,Number]),default:""},rangeSeparator:{type:String,default:"-"},startPlaceholder:String,endPlaceholder:String,defaultValue:{type:Ce([Date,Array])},defaultTime:{type:Ce([Date,Array])},isRange:Boolean,...fT,disabledDate:{type:Function},cellClassName:{type:Function},shortcuts:{type:Array,default:()=>[]},arrowControl:Boolean,label:{type:String,default:void 0},tabindex:{type:Ce([String,Number]),default:0},validateEvent:{type:Boolean,default:!0},unlinkPanels:Boolean,...M3}),Dne=["id","name","placeholder","value","disabled","readonly"],Fne=["id","name","placeholder","value","disabled","readonly"],Vne=Q({name:"Picker"}),Bne=Q({...Vne,props:pT,emits:["update:modelValue","change","focus","blur","calendar-change","panel-change","visible-change","keydown"],setup(e,{expose:t,emit:n}){const o=e,r=_d(),{lang:s}=Kt(),i=Re("date"),l=Re("input"),a=Re("range"),{form:u,formItem:c}=ni(),d=Be("ElPopperOptions",{}),{valueOnClear:f}=HM(o,null),p=K(),h=K(),m=K(!1),y=K(!1),v=K(null);let w=!1,_=!1;const S=R(()=>[i.b("editor"),i.bm("editor",o.type),l.e("wrapper"),i.is("disabled",z.value),i.is("active",m.value),a.b("editor"),Le?a.bm("editor",Le.value):"",r.class]),x=R(()=>[l.e("icon"),a.e("close-icon"),Ie.value?"":a.e("close-icon--hidden")]);Te(m,se=>{se?ot(()=>{se&&(v.value=o.modelValue)}):(me.value=null,ot(()=>{E(o.modelValue)}))});const E=(se,De)=>{(De||!t8(se,v.value))&&(n("change",se),o.validateEvent&&(c==null||c.validate("change").catch(Ot=>void 0)))},T=se=>{if(!t8(o.modelValue,se)){let De;Me(se)?De=se.map(Ot=>o8(Ot,o.valueFormat,s.value)):se&&(De=o8(se,o.valueFormat,s.value)),n("update:modelValue",se&&De,s.value)}},O=se=>{n("keydown",se)},P=R(()=>{if(h.value){const se=Ae.value?h.value:h.value.$el;return Array.from(se.querySelectorAll("input"))}return[]}),N=(se,De,Ot)=>{const mn=P.value;mn.length&&(!Ot||Ot==="min"?(mn[0].setSelectionRange(se,De),mn[0].focus()):Ot==="max"&&(mn[1].setSelectionRange(se,De),mn[1].focus()))},F=()=>{L(!0,!0),ot(()=>{_=!1})},B=(se="",De=!1)=>{De||(_=!0),m.value=De;let Ot;Me(se)?Ot=se.map(mn=>mn.toDate()):Ot=se&&se.toDate(),me.value=null,T(Ot)},Y=()=>{y.value=!0},Z=()=>{n("visible-change",!0)},U=se=>{(se==null?void 0:se.key)===rt.esc&&L(!0,!0)},j=()=>{y.value=!1,m.value=!1,_=!1,n("visible-change",!1)},V=()=>{m.value=!0},H=()=>{m.value=!1},L=(se=!0,De=!1)=>{_=De;const[Ot,mn]=g(P);let Un=Ot;!se&&Ae.value&&(Un=mn),Un&&Un.focus()},I=se=>{o.readonly||z.value||m.value||_||(m.value=!0,n("focus",se))};let X;const oe=se=>{const De=async()=>{setTimeout(()=>{var Ot;X===De&&(!((Ot=p.value)!=null&&Ot.isFocusInsideContent()&&!w)&&P.value.filter(mn=>mn.contains(document.activeElement)).length===0&&(je(),m.value=!1,n("blur",se),o.validateEvent&&(c==null||c.validate("blur").catch(mn=>void 0))),w=!1)},0)};X=De,De()},z=R(()=>o.disabled||(u==null?void 0:u.disabled)),ge=R(()=>{let se;if(G.value?ae.value.getDefaultValue&&(se=ae.value.getDefaultValue()):Me(o.modelValue)?se=o.modelValue.map(De=>n8(De,o.valueFormat,s.value)):se=n8(o.modelValue,o.valueFormat,s.value),ae.value.getRangeAvailableTime){const De=ae.value.getRangeAvailableTime(se);jl(De,se)||(se=De,T(Me(se)?se.map(Ot=>Ot.toDate()):se.toDate()))}return Me(se)&&se.some(De=>!De)&&(se=[]),se}),Oe=R(()=>{if(!ae.value.panelReady)return"";const se=ce(ge.value);return Me(me.value)?[me.value[0]||se&&se[0]||"",me.value[1]||se&&se[1]||""]:me.value!==null?me.value:!ee.value&&G.value||!m.value&&G.value?"":se?de.value||ve.value?se.join(", "):se:""}),xe=R(()=>o.type.includes("time")),ee=R(()=>o.type.startsWith("time")),de=R(()=>o.type==="dates"),ve=R(()=>o.type==="years"),le=R(()=>o.prefixIcon||(xe.value?Jx:PY)),Ie=K(!1),Ge=se=>{o.readonly||z.value||Ie.value&&(se.stopPropagation(),F(),T(f.value),E(f.value,!0),Ie.value=!1,m.value=!1,ae.value.handleClear&&ae.value.handleClear())},G=R(()=>{const{modelValue:se}=o;return!se||Me(se)&&!se.filter(Boolean).length}),J=async se=>{var De;o.readonly||z.value||(((De=se.target)==null?void 0:De.tagName)!=="INPUT"||P.value.includes(document.activeElement))&&(m.value=!0)},ue=()=>{o.readonly||z.value||!G.value&&o.clearable&&(Ie.value=!0)},_e=()=>{Ie.value=!1},ye=se=>{var De;o.readonly||z.value||(((De=se.touches[0].target)==null?void 0:De.tagName)!=="INPUT"||P.value.includes(document.activeElement))&&(m.value=!0)},Ae=R(()=>o.type.includes("range")),Le=Jo(),Ee=R(()=>{var se,De;return(De=(se=g(p))==null?void 0:se.popperRef)==null?void 0:De.contentRef}),Pe=R(()=>{var se;return g(Ae)?g(h):(se=g(h))==null?void 0:se.$el});fx(Pe,se=>{const De=g(Ee),Ot=g(Pe);De&&(se.target===De||se.composedPath().includes(De))||se.target===Ot||se.composedPath().includes(Ot)||(m.value=!1)});const me=K(null),je=()=>{if(me.value){const se=Ze(Oe.value);se&&te(se)&&(T(Me(se)?se.map(De=>De.toDate()):se.toDate()),me.value=null)}me.value===""&&(T(f.value),E(f.value),me.value=null)},Ze=se=>se?ae.value.parseUserInput(se):null,ce=se=>se?ae.value.formatToString(se):null,te=se=>ae.value.isValidValue(se),pe=async se=>{if(o.readonly||z.value)return;const{code:De}=se;if(O(se),De===rt.esc){m.value===!0&&(m.value=!1,se.preventDefault(),se.stopPropagation());return}if(De===rt.down&&(ae.value.handleFocusPicker&&(se.preventDefault(),se.stopPropagation()),m.value===!1&&(m.value=!0,await ot()),ae.value.handleFocusPicker)){ae.value.handleFocusPicker();return}if(De===rt.tab){w=!0;return}if(De===rt.enter||De===rt.numpadEnter){(me.value===null||me.value===""||te(Ze(Oe.value)))&&(je(),m.value=!1),se.stopPropagation();return}if(me.value){se.stopPropagation();return}ae.value.handleKeydownInput&&ae.value.handleKeydownInput(se)},Ve=se=>{me.value=se,m.value||(m.value=!0)},Je=se=>{const De=se.target;me.value?me.value=[De.value,me.value[1]]:me.value=[De.value,null]},$e=se=>{const De=se.target;me.value?me.value=[me.value[0],De.value]:me.value=[null,De.value]},ie=()=>{var se;const De=me.value,Ot=Ze(De&&De[0]),mn=g(ge);if(Ot&&Ot.isValid()){me.value=[ce(Ot),((se=Oe.value)==null?void 0:se[1])||null];const Un=[Ot,mn&&(mn[1]||null)];te(Un)&&(T(Un),me.value=null)}},we=()=>{var se;const De=g(me),Ot=Ze(De&&De[1]),mn=g(ge);if(Ot&&Ot.isValid()){me.value=[((se=g(Oe))==null?void 0:se[0])||null,ce(Ot)];const Un=[mn&&mn[0],Ot];te(Un)&&(T(Un),me.value=null)}},ae=K({}),Se=se=>{ae.value[se[0]]=se[1],ae.value.panelReady=!0},Fe=se=>{n("calendar-change",se)},st=(se,De,Ot)=>{n("panel-change",se,De,Ot)};return wt("EP_PICKER_BASE",{props:o}),t({focus:L,handleFocusInput:I,handleBlurInput:oe,handleOpen:V,handleClose:H,onPick:B}),(se,De)=>(C(),q(g($u),un({ref_key:"refPopper",ref:p,visible:m.value,effect:"light",pure:"",trigger:"click"},se.$attrs,{role:"dialog",teleported:"",transition:`${g(i).namespace.value}-zoom-in-top`,"popper-class":[`${g(i).namespace.value}-picker__popper`,se.popperClass],"popper-options":g(d),"fallback-placements":["bottom","top","right","left"],"gpu-acceleration":!1,"stop-popper-mouse-event":!1,"hide-after":0,persistent:"",onBeforeShow:Y,onShow:Z,onHide:j}),{default:$(()=>[g(Ae)?(C(),M("div",{key:1,ref_key:"inputRef",ref:h,class:D(g(S)),style:Qe(se.$attrs.style),onClick:I,onMouseenter:ue,onMouseleave:_e,onTouchstart:ye,onKeydown:pe},[g(le)?(C(),q(g(Ne),{key:0,class:D([g(l).e("icon"),g(a).e("icon")]),onMousedown:et(J,["prevent"]),onTouchstart:ye},{default:$(()=>[(C(),q(Lt(g(le))))]),_:1},8,["class","onMousedown"])):W("v-if",!0),b("input",{id:se.id&&se.id[0],autocomplete:"off",name:se.name&&se.name[0],placeholder:se.startPlaceholder,value:g(Oe)&&g(Oe)[0],disabled:g(z),readonly:!se.editable||se.readonly,class:D(g(a).b("input")),onMousedown:J,onInput:Je,onChange:ie,onFocus:I,onBlur:oe},null,42,Dne),he(se.$slots,"range-separator",{},()=>[b("span",{class:D(g(a).b("separator"))},A(se.rangeSeparator),3)]),b("input",{id:se.id&&se.id[1],autocomplete:"off",name:se.name&&se.name[1],placeholder:se.endPlaceholder,value:g(Oe)&&g(Oe)[1],disabled:g(z),readonly:!se.editable||se.readonly,class:D(g(a).b("input")),onMousedown:J,onFocus:I,onBlur:oe,onInput:$e,onChange:we},null,42,Fne),se.clearIcon?(C(),q(g(Ne),{key:1,class:D(g(x)),onClick:Ge},{default:$(()=>[(C(),q(Lt(se.clearIcon)))]),_:1},8,["class"])):W("v-if",!0)],38)):(C(),q(g(At),{key:0,id:se.id,ref_key:"inputRef",ref:h,"container-role":"combobox","model-value":g(Oe),name:se.name,size:g(Le),disabled:g(z),placeholder:se.placeholder,class:D([g(i).b("editor"),g(i).bm("editor",se.type),se.$attrs.class]),style:Qe(se.$attrs.style),readonly:!se.editable||se.readonly||g(de)||g(ve)||se.type==="week",label:se.label,tabindex:se.tabindex,"validate-event":!1,onInput:Ve,onFocus:I,onBlur:oe,onKeydown:pe,onChange:je,onMousedown:J,onMouseenter:ue,onMouseleave:_e,onTouchstart:ye,onClick:De[0]||(De[0]=et(()=>{},["stop"]))},{prefix:$(()=>[g(le)?(C(),q(g(Ne),{key:0,class:D(g(l).e("icon")),onMousedown:et(J,["prevent"]),onTouchstart:ye},{default:$(()=>[(C(),q(Lt(g(le))))]),_:1},8,["class","onMousedown"])):W("v-if",!0)]),suffix:$(()=>[Ie.value&&se.clearIcon?(C(),q(g(Ne),{key:0,class:D(`${g(l).e("icon")} clear-icon`),onClick:et(Ge,["stop"])},{default:$(()=>[(C(),q(Lt(se.clearIcon)))]),_:1},8,["class","onClick"])):W("v-if",!0)]),_:1},8,["id","model-value","name","size","disabled","placeholder","class","style","readonly","label","tabindex","onKeydown"]))]),content:$(()=>[he(se.$slots,"default",{visible:m.value,actualVisible:y.value,parsedValue:g(ge),format:se.format,dateFormat:se.dateFormat,timeFormat:se.timeFormat,unlinkPanels:se.unlinkPanels,type:se.type,defaultValue:se.defaultValue,onPick:B,onSelectRange:N,onSetPickerOption:Se,onCalendarChange:Fe,onPanelChange:st,onKeydown:U,onMousedown:De[1]||(De[1]=et(()=>{},["stop"]))})]),_:3},16,["visible","transition","popper-class","popper-options"]))}});var zne=ze(Bne,[["__file","picker.vue"]]);const jne=We({...Rne,datetimeRole:String,parsedValue:{type:Ce(Object)}}),Hne=({getAvailableHours:e,getAvailableMinutes:t,getAvailableSeconds:n})=>{const o=(i,l,a,u)=>{const c={hour:e,minute:t,second:n};let d=i;return["hour","minute","second"].forEach(f=>{if(c[f]){let p;const h=c[f];switch(f){case"minute":{p=h(d.hour(),l,u);break}case"second":{p=h(d.hour(),d.minute(),l,u);break}default:{p=h(l,u);break}}if(p!=null&&p.length&&!p.includes(d[f]())){const m=a?0:p.length-1;d=d[f](p[m])}}}),d},r={};return{timePickerOptions:r,getAvailableTime:o,onSetOption:([i,l])=>{r[i]=l}}},iy=e=>{const t=(o,r)=>o||r,n=o=>o!==!0;return e.map(t).filter(n)},hT=(e,t,n)=>({getHoursList:(i,l)=>sy(24,e&&(()=>e==null?void 0:e(i,l))),getMinutesList:(i,l,a)=>sy(60,t&&(()=>t==null?void 0:t(i,l,a))),getSecondsList:(i,l,a,u)=>sy(60,n&&(()=>n==null?void 0:n(i,l,a,u)))}),Une=(e,t,n)=>{const{getHoursList:o,getMinutesList:r,getSecondsList:s}=hT(e,t,n);return{getAvailableHours:(u,c)=>iy(o(u,c)),getAvailableMinutes:(u,c,d)=>iy(r(u,c,d)),getAvailableSeconds:(u,c,d,f)=>iy(s(u,c,d,f))}},Wne=e=>{const t=K(e.parsedValue);return Te(()=>e.visible,n=>{n||(t.value=e.parsedValue)}),t},tl=new Map;let r8;xt&&(document.addEventListener("mousedown",e=>r8=e),document.addEventListener("mouseup",e=>{for(const t of tl.values())for(const{documentHandler:n}of t)n(e,r8)}));function s8(e,t){let n=[];return Array.isArray(t.arg)?n=t.arg:gs(t.arg)&&n.push(t.arg),function(o,r){const s=t.instance.popperRef,i=o.target,l=r==null?void 0:r.target,a=!t||!t.instance,u=!i||!l,c=e.contains(i)||e.contains(l),d=e===i,f=n.length&&n.some(h=>h==null?void 0:h.contains(i))||n.length&&n.includes(l),p=s&&(s.contains(i)||s.contains(l));a||u||c||d||f||p||t.value(o,r)}}const id={beforeMount(e,t){tl.has(e)||tl.set(e,[]),tl.get(e).push({documentHandler:s8(e,t),bindingFn:t.value})},updated(e,t){tl.has(e)||tl.set(e,[]);const n=tl.get(e),o=n.findIndex(s=>s.bindingFn===t.oldValue),r={documentHandler:s8(e,t),bindingFn:t.value};o>=0?n.splice(o,1,r):n.push(r)},unmounted(e){tl.delete(e)}},Kne=100,qne=600,Rg={beforeMount(e,t){const n=t.value,{interval:o=Kne,delay:r=qne}=Xe(n)?{}:n;let s,i;const l=()=>Xe(n)?n():n.handler(),a=()=>{i&&(clearTimeout(i),i=void 0),s&&(clearInterval(s),s=void 0)};e.addEventListener("mousedown",u=>{u.button===0&&(a(),l(),document.addEventListener("mouseup",()=>a(),{once:!0}),i=setTimeout(()=>{s=setInterval(()=>{l()},o)},r))})}},ub="_trap-focus-children",Na=[],i8=e=>{if(Na.length===0)return;const t=Na[Na.length-1][ub];if(t.length>0&&e.code===rt.tab){if(t.length===1){e.preventDefault(),document.activeElement!==t[0]&&t[0].focus();return}const n=e.shiftKey,o=e.target===t[0],r=e.target===t[t.length-1];o&&n&&(e.preventDefault(),t[t.length-1].focus()),r&&!n&&(e.preventDefault(),t[0].focus())}},Gne={beforeMount(e){e[ub]=_6(e),Na.push(e),Na.length<=1&&document.addEventListener("keydown",i8)},updated(e){ot(()=>{e[ub]=_6(e)})},unmounted(){Na.shift(),Na.length===0&&document.removeEventListener("keydown",i8)}};var l8=!1,Ea,cb,db,Xm,Qm,mT,e1,fb,pb,hb,gT,mb,gb,vT,yT;function Ro(){if(!l8){l8=!0;var e=navigator.userAgent,t=/(?:MSIE.(\d+\.\d+))|(?:(?:Firefox|GranParadiso|Iceweasel).(\d+\.\d+))|(?:Opera(?:.+Version.|.)(\d+\.\d+))|(?:AppleWebKit.(\d+(?:\.\d+)?))|(?:Trident\/\d+\.\d+.*rv:(\d+\.\d+))/.exec(e),n=/(Mac OS X)|(Windows)|(Linux)/.exec(e);if(mb=/\b(iPhone|iP[ao]d)/.exec(e),gb=/\b(iP[ao]d)/.exec(e),hb=/Android/i.exec(e),vT=/FBAN\/\w+;/i.exec(e),yT=/Mobile/i.exec(e),gT=!!/Win64/.exec(e),t){Ea=t[1]?parseFloat(t[1]):t[5]?parseFloat(t[5]):NaN,Ea&&document&&document.documentMode&&(Ea=document.documentMode);var o=/(?:Trident\/(\d+.\d+))/.exec(e);mT=o?parseFloat(o[1])+4:Ea,cb=t[2]?parseFloat(t[2]):NaN,db=t[3]?parseFloat(t[3]):NaN,Xm=t[4]?parseFloat(t[4]):NaN,Xm?(t=/(?:Chrome\/(\d+\.\d+))/.exec(e),Qm=t&&t[1]?parseFloat(t[1]):NaN):Qm=NaN}else Ea=cb=db=Qm=Xm=NaN;if(n){if(n[1]){var r=/(?:Mac OS X (\d+(?:[._]\d+)?))/.exec(e);e1=r?parseFloat(r[1].replace("_",".")):!0}else e1=!1;fb=!!n[2],pb=!!n[3]}else e1=fb=pb=!1}}var vb={ie:function(){return Ro()||Ea},ieCompatibilityMode:function(){return Ro()||mT>Ea},ie64:function(){return vb.ie()&&gT},firefox:function(){return Ro()||cb},opera:function(){return Ro()||db},webkit:function(){return Ro()||Xm},safari:function(){return vb.webkit()},chrome:function(){return Ro()||Qm},windows:function(){return Ro()||fb},osx:function(){return Ro()||e1},linux:function(){return Ro()||pb},iphone:function(){return Ro()||mb},mobile:function(){return Ro()||mb||gb||hb||yT},nativeApp:function(){return Ro()||vT},android:function(){return Ro()||hb},ipad:function(){return Ro()||gb}},Yne=vb,gm=!!(typeof window<"u"&&window.document&&window.document.createElement),Zne={canUseDOM:gm,canUseWorkers:typeof Worker<"u",canUseEventListeners:gm&&!!(window.addEventListener||window.attachEvent),canUseViewport:gm&&!!window.screen,isInWorker:!gm},_T=Zne,bT;_T.canUseDOM&&(bT=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0);function Jne(e,t){if(!_T.canUseDOM||t&&!("addEventListener"in document))return!1;var n="on"+e,o=n in document;if(!o){var r=document.createElement("div");r.setAttribute(n,"return;"),o=typeof r[n]=="function"}return!o&&bT&&e==="wheel"&&(o=document.implementation.hasFeature("Events.wheel","3.0")),o}var Xne=Jne,a8=10,u8=40,c8=800;function wT(e){var t=0,n=0,o=0,r=0;return"detail"in e&&(n=e.detail),"wheelDelta"in e&&(n=-e.wheelDelta/120),"wheelDeltaY"in e&&(n=-e.wheelDeltaY/120),"wheelDeltaX"in e&&(t=-e.wheelDeltaX/120),"axis"in e&&e.axis===e.HORIZONTAL_AXIS&&(t=n,n=0),o=t*a8,r=n*a8,"deltaY"in e&&(r=e.deltaY),"deltaX"in e&&(o=e.deltaX),(o||r)&&e.deltaMode&&(e.deltaMode==1?(o*=u8,r*=u8):(o*=c8,r*=c8)),o&&!t&&(t=o<1?-1:1),r&&!n&&(n=r<1?-1:1),{spinX:t,spinY:n,pixelX:o,pixelY:r}}wT.getEventType=function(){return Yne.firefox()?"DOMMouseScroll":Xne("wheel")?"wheel":"mousewheel"};var Qne=wT;/**
59 * Checks if an event is supported in the current execution environment.
60 *
61 * NOTE: This will not work correctly for non-generic events such as `change`,
62 * `reset`, `load`, `error`, and `select`.
63 *
64 * Borrows from Modernizr.
65 *
66 * @param {string} eventNameSuffix Event name, e.g. "click".
67 * @param {?boolean} capture Check if the capture phase is supported.
68 * @return {boolean} True if the event is supported.
69 * @internal
70 * @license Modernizr 3.0.0pre (Custom Build) | MIT
71 */const eoe=function(e,t){if(e&&e.addEventListener){const n=function(o){const r=Qne(o);t&&Reflect.apply(t,this,[o,r])};e.addEventListener("wheel",n,{passive:!0})}},toe={beforeMount(e,t){eoe(e,t.value)}},noe=We({role:{type:String,required:!0},spinnerDate:{type:Ce(Object),required:!0},showSeconds:{type:Boolean,default:!0},arrowControl:Boolean,amPmMode:{type:Ce(String),default:""},...fT}),ooe=["onClick"],roe=["onMouseenter"],soe=Q({__name:"basic-time-spinner",props:noe,emits:["change","select-range","set-option"],setup(e,{emit:t}){const n=e,o=Re("time"),{getHoursList:r,getMinutesList:s,getSecondsList:i}=hT(n.disabledHours,n.disabledMinutes,n.disabledSeconds);let l=!1;const a=K(),u=K(),c=K(),d=K(),f={hours:u,minutes:c,seconds:d},p=R(()=>n.showSeconds?X5:X5.slice(0,2)),h=R(()=>{const{spinnerDate:L}=n,I=L.hour(),X=L.minute(),oe=L.second();return{hours:I,minutes:X,seconds:oe}}),m=R(()=>{const{hours:L,minutes:I}=g(h);return{hours:r(n.role),minutes:s(L,n.role),seconds:i(L,I,n.role)}}),y=R(()=>{const{hours:L,minutes:I,seconds:X}=g(h);return{hours:ry(L,23),minutes:ry(I,59),seconds:ry(X,59)}}),v=zl(L=>{l=!1,S(L)},200),w=L=>{if(!!!n.amPmMode)return"";const X=n.amPmMode==="A";let oe=L<12?" am":" pm";return X&&(oe=oe.toUpperCase()),oe},_=L=>{let I;switch(L){case"hours":I=[0,2];break;case"minutes":I=[3,5];break;case"seconds":I=[6,8];break}const[X,oe]=I;t("select-range",X,oe),a.value=L},S=L=>{T(L,g(h)[L])},x=()=>{S("hours"),S("minutes"),S("seconds")},E=L=>L.querySelector(`.${o.namespace.value}-scrollbar__wrap`),T=(L,I)=>{if(n.arrowControl)return;const X=g(f[L]);X&&X.$el&&(E(X.$el).scrollTop=Math.max(0,I*O(L)))},O=L=>{const I=g(f[L]),X=I==null?void 0:I.$el.querySelector("li");return X&&Number.parseFloat(kl(X,"height"))||0},P=()=>{F(1)},N=()=>{F(-1)},F=L=>{a.value||_("hours");const I=a.value,X=g(h)[I],oe=a.value==="hours"?24:60,z=B(I,X,L,oe);Y(I,z),T(I,z),ot(()=>_(I))},B=(L,I,X,oe)=>{let z=(I+X+oe)%oe;const ge=g(m)[L];for(;ge[z]&&z!==I;)z=(z+X+oe)%oe;return z},Y=(L,I)=>{if(g(m)[L][I])return;const{hours:z,minutes:ge,seconds:Oe}=g(h);let xe;switch(L){case"hours":xe=n.spinnerDate.hour(I).minute(ge).second(Oe);break;case"minutes":xe=n.spinnerDate.hour(z).minute(I).second(Oe);break;case"seconds":xe=n.spinnerDate.hour(z).minute(ge).second(I);break}t("change",xe)},Z=(L,{value:I,disabled:X})=>{X||(Y(L,I),_(L),T(L,I))},U=L=>{l=!0,v(L);const I=Math.min(Math.round((E(g(f[L]).$el).scrollTop-(j(L)*.5-10)/O(L)+3)/O(L)),L==="hours"?23:59);Y(L,I)},j=L=>g(f[L]).$el.offsetHeight,V=()=>{const L=I=>{const X=g(f[I]);X&&X.$el&&(E(X.$el).onscroll=()=>{U(I)})};L("hours"),L("minutes"),L("seconds")};Ct(()=>{ot(()=>{!n.arrowControl&&V(),x(),n.role==="start"&&_("hours")})});const H=(L,I)=>{f[I].value=L};return t("set-option",[`${n.role}_scrollDown`,F]),t("set-option",[`${n.role}_emitSelectRange`,_]),Te(()=>n.spinnerDate,()=>{l||x()}),(L,I)=>(C(),M("div",{class:D([g(o).b("spinner"),{"has-seconds":L.showSeconds}])},[L.arrowControl?W("v-if",!0):(C(!0),M(fe,{key:0},nt(g(p),X=>(C(),q(g(ks),{key:X,ref_for:!0,ref:oe=>H(oe,X),class:D(g(o).be("spinner","wrapper")),"wrap-style":"max-height: inherit;","view-class":g(o).be("spinner","list"),noresize:"",tag:"ul",onMouseenter:oe=>_(X),onMousemove:oe=>S(X)},{default:$(()=>[(C(!0),M(fe,null,nt(g(m)[X],(oe,z)=>(C(),M("li",{key:z,class:D([g(o).be("spinner","item"),g(o).is("active",z===g(h)[X]),g(o).is("disabled",oe)]),onClick:ge=>Z(X,{value:z,disabled:oe})},[X==="hours"?(C(),M(fe,{key:0},[ne(A(("0"+(L.amPmMode?z%12||12:z)).slice(-2))+A(w(z)),1)],64)):(C(),M(fe,{key:1},[ne(A(("0"+z).slice(-2)),1)],64))],10,ooe))),128))]),_:2},1032,["class","view-class","onMouseenter","onMousemove"]))),128)),L.arrowControl?(C(!0),M(fe,{key:1},nt(g(p),X=>(C(),M("div",{key:X,class:D([g(o).be("spinner","wrapper"),g(o).is("arrow")]),onMouseenter:oe=>_(X)},[He((C(),q(g(Ne),{class:D(["arrow-up",g(o).be("spinner","arrow")])},{default:$(()=>[k(g(N0))]),_:1},8,["class"])),[[g(Rg),N]]),He((C(),q(g(Ne),{class:D(["arrow-down",g(o).be("spinner","arrow")])},{default:$(()=>[k(g(Su))]),_:1},8,["class"])),[[g(Rg),P]]),b("ul",{class:D(g(o).be("spinner","list"))},[(C(!0),M(fe,null,nt(g(y)[X],(oe,z)=>(C(),M("li",{key:z,class:D([g(o).be("spinner","item"),g(o).is("active",oe===g(h)[X]),g(o).is("disabled",g(m)[X][oe])])},[typeof oe=="number"?(C(),M(fe,{key:0},[X==="hours"?(C(),M(fe,{key:0},[ne(A(("0"+(L.amPmMode?oe%12||12:oe)).slice(-2))+A(w(oe)),1)],64)):(C(),M(fe,{key:1},[ne(A(("0"+oe).slice(-2)),1)],64))],64)):W("v-if",!0)],2))),128))],2)],42,roe))),128)):W("v-if",!0)],2))}});var ioe=ze(soe,[["__file","basic-time-spinner.vue"]]);const loe=Q({__name:"panel-time-pick",props:jne,emits:["pick","select-range","set-picker-option"],setup(e,{emit:t}){const n=e,o=Be("EP_PICKER_BASE"),{arrowControl:r,disabledHours:s,disabledMinutes:i,disabledSeconds:l,defaultValue:a}=o.props,{getAvailableHours:u,getAvailableMinutes:c,getAvailableSeconds:d}=Une(s,i,l),f=Re("time"),{t:p,lang:h}=Kt(),m=K([0,2]),y=Wne(n),v=R(()=>Uo(n.actualVisible)?`${f.namespace.value}-zoom-in-top`:""),w=R(()=>n.format.includes("ss")),_=R(()=>n.format.includes("A")?"A":n.format.includes("a")?"a":""),S=H=>{const L=ut(H).locale(h.value),I=Z(L);return L.isSame(I)},x=()=>{t("pick",y.value,!1)},E=(H=!1,L=!1)=>{L||t("pick",n.parsedValue,H)},T=H=>{if(!n.visible)return;const L=Z(H).millisecond(0);t("pick",L,!0)},O=(H,L)=>{t("select-range",H,L),m.value=[H,L]},P=H=>{const L=[0,3].concat(w.value?[6]:[]),I=["hours","minutes"].concat(w.value?["seconds"]:[]),oe=(L.indexOf(m.value[0])+H+L.length)%L.length;F.start_emitSelectRange(I[oe])},N=H=>{const L=H.code,{left:I,right:X,up:oe,down:z}=rt;if([I,X].includes(L)){P(L===I?-1:1),H.preventDefault();return}if([oe,z].includes(L)){const ge=L===oe?-1:1;F.start_scrollDown(ge),H.preventDefault();return}},{timePickerOptions:F,onSetOption:B,getAvailableTime:Y}=Hne({getAvailableHours:u,getAvailableMinutes:c,getAvailableSeconds:d}),Z=H=>Y(H,n.datetimeRole||"",!0),U=H=>H?ut(H,n.format).locale(h.value):null,j=H=>H?H.format(n.format):null,V=()=>ut(a).locale(h.value);return t("set-picker-option",["isValidValue",S]),t("set-picker-option",["formatToString",j]),t("set-picker-option",["parseUserInput",U]),t("set-picker-option",["handleKeydownInput",N]),t("set-picker-option",["getRangeAvailableTime",Z]),t("set-picker-option",["getDefaultValue",V]),(H,L)=>(C(),q(_r,{name:g(v)},{default:$(()=>[H.actualVisible||H.visible?(C(),M("div",{key:0,class:D(g(f).b("panel"))},[b("div",{class:D([g(f).be("panel","content"),{"has-seconds":g(w)}])},[k(ioe,{ref:"spinner",role:H.datetimeRole||"start","arrow-control":g(r),"show-seconds":g(w),"am-pm-mode":g(_),"spinner-date":H.parsedValue,"disabled-hours":g(s),"disabled-minutes":g(i),"disabled-seconds":g(l),onChange:T,onSetOption:g(B),onSelectRange:O},null,8,["role","arrow-control","show-seconds","am-pm-mode","spinner-date","disabled-hours","disabled-minutes","disabled-seconds","onSetOption"])],2),b("div",{class:D(g(f).be("panel","footer"))},[b("button",{type:"button",class:D([g(f).be("panel","btn"),"cancel"]),onClick:x},A(g(p)("el.datepicker.cancel")),3),b("button",{type:"button",class:D([g(f).be("panel","btn"),"confirm"]),onClick:L[0]||(L[0]=I=>E())},A(g(p)("el.datepicker.confirm")),3)],2)],2)):W("v-if",!0)]),_:1},8,["name"]))}});var yb=ze(loe,[["__file","panel-time-pick.vue"]]),CT={exports:{}};(function(e,t){(function(n,o){e.exports=o()})(On,function(){return function(n,o,r){var s=o.prototype,i=function(d){return d&&(d.indexOf?d:d.s)},l=function(d,f,p,h,m){var y=d.name?d:d.$locale(),v=i(y[f]),w=i(y[p]),_=v||w.map(function(x){return x.slice(0,h)});if(!m)return _;var S=y.weekStart;return _.map(function(x,E){return _[(E+(S||0))%7]})},a=function(){return r.Ls[r.locale()]},u=function(d,f){return d.formats[f]||function(p){return p.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(h,m,y){return m||y.slice(1)})}(d.formats[f.toUpperCase()])},c=function(){var d=this;return{months:function(f){return f?f.format("MMMM"):l(d,"months")},monthsShort:function(f){return f?f.format("MMM"):l(d,"monthsShort","months",3)},firstDayOfWeek:function(){return d.$locale().weekStart||0},weekdays:function(f){return f?f.format("dddd"):l(d,"weekdays")},weekdaysMin:function(f){return f?f.format("dd"):l(d,"weekdaysMin","weekdays",2)},weekdaysShort:function(f){return f?f.format("ddd"):l(d,"weekdaysShort","weekdays",3)},longDateFormat:function(f){return u(d.$locale(),f)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};s.localeData=function(){return c.bind(this)()},r.localeData=function(){var d=a();return{firstDayOfWeek:function(){return d.weekStart||0},weekdays:function(){return r.weekdays()},weekdaysShort:function(){return r.weekdaysShort()},weekdaysMin:function(){return r.weekdaysMin()},months:function(){return r.months()},monthsShort:function(){return r.monthsShort()},longDateFormat:function(f){return u(d,f)},meridiem:d.meridiem,ordinal:d.ordinal}},r.months=function(){return l(a(),"months")},r.monthsShort=function(){return l(a(),"monthsShort","months",3)},r.weekdays=function(d){return l(a(),"weekdays",null,null,d)},r.weekdaysShort=function(d){return l(a(),"weekdaysShort","weekdays",3,d)},r.weekdaysMin=function(d){return l(a(),"weekdaysMin","weekdays",2,d)}}})})(CT);var aoe=CT.exports;const uoe=_o(aoe),kT={modelValue:{type:[Number,String,Boolean],default:void 0},label:{type:[String,Boolean,Number,Object],default:void 0},value:{type:[String,Boolean,Number,Object],default:void 0},indeterminate:Boolean,disabled:Boolean,checked:Boolean,name:{type:String,default:void 0},trueValue:{type:[String,Number],default:void 0},falseValue:{type:[String,Number],default:void 0},trueLabel:{type:[String,Number],default:void 0},falseLabel:{type:[String,Number],default:void 0},id:{type:String,default:void 0},controls:{type:String,default:void 0},border:Boolean,size:qr,tabindex:[String,Number],validateEvent:{type:Boolean,default:!0}},ST={[Jt]:e=>tt(e)||_t(e)||Br(e),change:e=>tt(e)||_t(e)||Br(e)},$d=Symbol("checkboxGroupContextKey"),coe=({model:e,isChecked:t})=>{const n=Be($d,void 0),o=R(()=>{var s,i;const l=(s=n==null?void 0:n.max)==null?void 0:s.value,a=(i=n==null?void 0:n.min)==null?void 0:i.value;return!Uo(l)&&e.value.length>=l&&!t.value||!Uo(a)&&e.value.length<=a&&t.value});return{isDisabled:Gr(R(()=>(n==null?void 0:n.disabled.value)||o.value)),isLimitDisabled:o}},doe=(e,{model:t,isLimitExceeded:n,hasOwnLabel:o,isDisabled:r,isLabeledByFormItem:s})=>{const i=Be($d,void 0),{formItem:l}=ni(),{emit:a}=at();function u(h){var m,y,v,w;return[!0,e.trueValue,e.trueLabel].includes(h)?(y=(m=e.trueValue)!=null?m:e.trueLabel)!=null?y:!0:(w=(v=e.falseValue)!=null?v:e.falseLabel)!=null?w:!1}function c(h,m){a("change",u(h),m)}function d(h){if(n.value)return;const m=h.target;a("change",u(m.checked),h)}async function f(h){n.value||!o.value&&!r.value&&s.value&&(h.composedPath().some(v=>v.tagName==="LABEL")||(t.value=u([!1,e.falseValue,e.falseLabel].includes(t.value)),await ot(),c(t.value,h)))}const p=R(()=>(i==null?void 0:i.validateEvent)||e.validateEvent);return Te(()=>e.modelValue,()=>{p.value&&(l==null||l.validate("change").catch(h=>void 0))}),{handleChange:d,onClickRoot:f}},foe=e=>{const t=K(!1),{emit:n}=at(),o=Be($d,void 0),r=R(()=>Uo(o)===!1),s=K(!1),i=R({get(){var l,a;return r.value?(l=o==null?void 0:o.modelValue)==null?void 0:l.value:(a=e.modelValue)!=null?a:t.value},set(l){var a,u;r.value&&Me(l)?(s.value=((a=o==null?void 0:o.max)==null?void 0:a.value)!==void 0&&l.length>(o==null?void 0:o.max.value)&&l.length>i.value.length,s.value===!1&&((u=o==null?void 0:o.changeEvent)==null||u.call(o,l))):(n(Jt,l),t.value=l)}});return{model:i,isGroup:r,isLimitExceeded:s}},poe=(e,t,{model:n})=>{const o=Be($d,void 0),r=K(!1),s=R(()=>Ap(e.value)?e.label:e.value),i=R(()=>{const c=n.value;return Br(c)?c:Me(c)?ft(s.value)?c.map(Mt).some(d=>jl(d,s.value)):c.map(Mt).includes(s.value):c!=null?c===e.trueValue||c===e.trueLabel:!!c}),l=Jo(R(()=>{var c;return(c=o==null?void 0:o.size)==null?void 0:c.value}),{prop:!0}),a=Jo(R(()=>{var c;return(c=o==null?void 0:o.size)==null?void 0:c.value})),u=R(()=>!!t.default||!Ap(s.value));return{checkboxButtonSize:l,isChecked:i,isFocused:r,checkboxSize:a,hasOwnLabel:u,actualValue:s}},$T=(e,t)=>{const{formItem:n}=ni(),{model:o,isGroup:r,isLimitExceeded:s}=foe(e),{isFocused:i,isChecked:l,checkboxButtonSize:a,checkboxSize:u,hasOwnLabel:c,actualValue:d}=poe(e,t,{model:o}),{isDisabled:f}=coe({model:o,isChecked:l}),{inputId:p,isLabeledByFormItem:h}=Sd(e,{formItemContext:n,disableIdGeneration:c,disableIdManagement:r}),{handleChange:m,onClickRoot:y}=doe(e,{model:o,isLimitExceeded:s,hasOwnLabel:c,isDisabled:f,isLabeledByFormItem:h});return(()=>{function w(){var _,S;Me(o.value)&&!o.value.includes(d.value)?o.value.push(d.value):o.value=(S=(_=e.trueValue)!=null?_:e.trueLabel)!=null?S:!0}e.checked&&w()})(),Ua({from:"label act as value",replacement:"value",version:"3.0.0",scope:"el-checkbox",ref:"https://element-plus.org/en-US/component/checkbox.html"},R(()=>r.value&&Ap(e.value))),Ua({from:"true-label",replacement:"true-value",version:"3.0.0",scope:"el-checkbox",ref:"https://element-plus.org/en-US/component/checkbox.html"},R(()=>!!e.trueLabel)),Ua({from:"false-label",replacement:"false-value",version:"3.0.0",scope:"el-checkbox",ref:"https://element-plus.org/en-US/component/checkbox.html"},R(()=>!!e.falseLabel)),{inputId:p,isLabeledByFormItem:h,isChecked:l,isDisabled:f,isFocused:i,checkboxButtonSize:a,checkboxSize:u,hasOwnLabel:c,model:o,actualValue:d,handleChange:m,onClickRoot:y}},hoe=["id","indeterminate","name","tabindex","disabled","true-value","false-value"],moe=["id","indeterminate","disabled","value","name","tabindex"],goe=Q({name:"ElCheckbox"}),voe=Q({...goe,props:kT,emits:ST,setup(e){const t=e,n=Kr(),{inputId:o,isLabeledByFormItem:r,isChecked:s,isDisabled:i,isFocused:l,checkboxSize:a,hasOwnLabel:u,model:c,actualValue:d,handleChange:f,onClickRoot:p}=$T(t,n),h=Re("checkbox"),m=R(()=>[h.b(),h.m(a.value),h.is("disabled",i.value),h.is("bordered",t.border),h.is("checked",s.value)]),y=R(()=>[h.e("input"),h.is("disabled",i.value),h.is("checked",s.value),h.is("indeterminate",t.indeterminate),h.is("focus",l.value)]);return(v,w)=>(C(),q(Lt(!g(u)&&g(r)?"span":"label"),{class:D(g(m)),"aria-controls":v.indeterminate?v.controls:null,onClick:g(p)},{default:$(()=>{var _,S;return[b("span",{class:D(g(y))},[v.trueValue||v.falseValue||v.trueLabel||v.falseLabel?He((C(),M("input",{key:0,id:g(o),"onUpdate:modelValue":w[0]||(w[0]=x=>on(c)?c.value=x:null),class:D(g(h).e("original")),type:"checkbox",indeterminate:v.indeterminate,name:v.name,tabindex:v.tabindex,disabled:g(i),"true-value":(_=v.trueValue)!=null?_:v.trueLabel,"false-value":(S=v.falseValue)!=null?S:v.falseLabel,onChange:w[1]||(w[1]=(...x)=>g(f)&&g(f)(...x)),onFocus:w[2]||(w[2]=x=>l.value=!0),onBlur:w[3]||(w[3]=x=>l.value=!1),onClick:w[4]||(w[4]=et(()=>{},["stop"]))},null,42,hoe)),[[ru,g(c)]]):He((C(),M("input",{key:1,id:g(o),"onUpdate:modelValue":w[5]||(w[5]=x=>on(c)?c.value=x:null),class:D(g(h).e("original")),type:"checkbox",indeterminate:v.indeterminate,disabled:g(i),value:g(d),name:v.name,tabindex:v.tabindex,onChange:w[6]||(w[6]=(...x)=>g(f)&&g(f)(...x)),onFocus:w[7]||(w[7]=x=>l.value=!0),onBlur:w[8]||(w[8]=x=>l.value=!1),onClick:w[9]||(w[9]=et(()=>{},["stop"]))},null,42,moe)),[[ru,g(c)]]),b("span",{class:D(g(h).e("inner"))},null,2)],2),g(u)?(C(),M("span",{key:0,class:D(g(h).e("label"))},[he(v.$slots,"default"),v.$slots.default?W("v-if",!0):(C(),M(fe,{key:0},[ne(A(v.label),1)],64))],2)):W("v-if",!0)]}),_:3},8,["class","aria-controls","onClick"]))}});var yoe=ze(voe,[["__file","checkbox.vue"]]);const _oe=["name","tabindex","disabled","true-value","false-value"],boe=["name","tabindex","disabled","value"],woe=Q({name:"ElCheckboxButton"}),Coe=Q({...woe,props:kT,emits:ST,setup(e){const t=e,n=Kr(),{isFocused:o,isChecked:r,isDisabled:s,checkboxButtonSize:i,model:l,actualValue:a,handleChange:u}=$T(t,n),c=Be($d,void 0),d=Re("checkbox"),f=R(()=>{var h,m,y,v;const w=(m=(h=c==null?void 0:c.fill)==null?void 0:h.value)!=null?m:"";return{backgroundColor:w,borderColor:w,color:(v=(y=c==null?void 0:c.textColor)==null?void 0:y.value)!=null?v:"",boxShadow:w?`-1px 0 0 0 ${w}`:void 0}}),p=R(()=>[d.b("button"),d.bm("button",i.value),d.is("disabled",s.value),d.is("checked",r.value),d.is("focus",o.value)]);return(h,m)=>{var y,v;return C(),M("label",{class:D(g(p))},[h.trueValue||h.falseValue||h.trueLabel||h.falseLabel?He((C(),M("input",{key:0,"onUpdate:modelValue":m[0]||(m[0]=w=>on(l)?l.value=w:null),class:D(g(d).be("button","original")),type:"checkbox",name:h.name,tabindex:h.tabindex,disabled:g(s),"true-value":(y=h.trueValue)!=null?y:h.trueLabel,"false-value":(v=h.falseValue)!=null?v:h.falseLabel,onChange:m[1]||(m[1]=(...w)=>g(u)&&g(u)(...w)),onFocus:m[2]||(m[2]=w=>o.value=!0),onBlur:m[3]||(m[3]=w=>o.value=!1),onClick:m[4]||(m[4]=et(()=>{},["stop"]))},null,42,_oe)),[[ru,g(l)]]):He((C(),M("input",{key:1,"onUpdate:modelValue":m[5]||(m[5]=w=>on(l)?l.value=w:null),class:D(g(d).be("button","original")),type:"checkbox",name:h.name,tabindex:h.tabindex,disabled:g(s),value:g(a),onChange:m[6]||(m[6]=(...w)=>g(u)&&g(u)(...w)),onFocus:m[7]||(m[7]=w=>o.value=!0),onBlur:m[8]||(m[8]=w=>o.value=!1),onClick:m[9]||(m[9]=et(()=>{},["stop"]))},null,42,boe)),[[ru,g(l)]]),h.$slots.default||h.label?(C(),M("span",{key:2,class:D(g(d).be("button","inner")),style:Qe(g(r)?g(f):void 0)},[he(h.$slots,"default",{},()=>[ne(A(h.label),1)])],6)):W("v-if",!0)],2)}}});var ET=ze(Coe,[["__file","checkbox-button.vue"]]);const koe=We({modelValue:{type:Ce(Array),default:()=>[]},disabled:Boolean,min:Number,max:Number,size:qr,label:String,fill:String,textColor:String,tag:{type:String,default:"div"},validateEvent:{type:Boolean,default:!0}}),Soe={[Jt]:e=>Me(e),change:e=>Me(e)},$oe=Q({name:"ElCheckboxGroup"}),Eoe=Q({...$oe,props:koe,emits:Soe,setup(e,{emit:t}){const n=e,o=Re("checkbox"),{formItem:r}=ni(),{inputId:s,isLabeledByFormItem:i}=Sd(n,{formItemContext:r}),l=async u=>{t(Jt,u),await ot(),t("change",u)},a=R({get(){return n.modelValue},set(u){l(u)}});return wt($d,{...uY(ei(n),["size","min","max","disabled","validateEvent","fill","textColor"]),modelValue:a,changeEvent:l}),Te(()=>n.modelValue,()=>{n.validateEvent&&(r==null||r.validate("change").catch(u=>void 0))}),(u,c)=>{var d;return C(),q(Lt(u.tag),{id:g(s),class:D(g(o).b("group")),role:"group","aria-label":g(i)?void 0:u.label||"checkbox-group","aria-labelledby":g(i)?(d=g(r))==null?void 0:d.labelId:void 0},{default:$(()=>[he(u.$slots,"default")]),_:3},8,["id","class","aria-label","aria-labelledby"])}}});var xT=ze(Eoe,[["__file","checkbox-group.vue"]]);const Hn=Zt(yoe,{CheckboxButton:ET,CheckboxGroup:xT});Gn(ET);const xoe=Gn(xT),MT=We({modelValue:{type:[String,Number,Boolean],default:void 0},size:qr,disabled:Boolean,label:{type:[String,Number,Boolean],default:void 0},value:{type:[String,Number,Boolean],default:void 0},name:{type:String,default:void 0}}),Moe=We({...MT,border:Boolean}),TT={[Jt]:e=>tt(e)||_t(e)||Br(e),[Cd]:e=>tt(e)||_t(e)||Br(e)},OT=Symbol("radioGroupKey"),IT=(e,t)=>{const n=K(),o=Be(OT,void 0),r=R(()=>!!o),s=R(()=>Ap(e.value)?e.label:e.value),i=R({get(){return r.value?o.modelValue:e.modelValue},set(d){r.value?o.changeEvent(d):t&&t(Jt,d),n.value.checked=e.modelValue===s.value}}),l=Jo(R(()=>o==null?void 0:o.size)),a=Gr(R(()=>o==null?void 0:o.disabled)),u=K(!1),c=R(()=>a.value||r.value&&i.value!==s.value?-1:0);return Ua({from:"label act as value",replacement:"value",version:"3.0.0",scope:"el-radio",ref:"https://element-plus.org/en-US/component/radio.html"},R(()=>r.value&&Ap(e.value))),{radioRef:n,isGroup:r,radioGroup:o,focus:u,size:l,disabled:a,tabIndex:c,modelValue:i,actualValue:s}},Toe=["value","name","disabled"],Ooe=Q({name:"ElRadio"}),Ioe=Q({...Ooe,props:Moe,emits:TT,setup(e,{emit:t}){const n=e,o=Re("radio"),{radioRef:r,radioGroup:s,focus:i,size:l,disabled:a,modelValue:u,actualValue:c}=IT(n,t);function d(){ot(()=>t("change",u.value))}return(f,p)=>{var h;return C(),M("label",{class:D([g(o).b(),g(o).is("disabled",g(a)),g(o).is("focus",g(i)),g(o).is("bordered",f.border),g(o).is("checked",g(u)===g(c)),g(o).m(g(l))])},[b("span",{class:D([g(o).e("input"),g(o).is("disabled",g(a)),g(o).is("checked",g(u)===g(c))])},[He(b("input",{ref_key:"radioRef",ref:r,"onUpdate:modelValue":p[0]||(p[0]=m=>on(u)?u.value=m:null),class:D(g(o).e("original")),value:g(c),name:f.name||((h=g(s))==null?void 0:h.name),disabled:g(a),type:"radio",onFocus:p[1]||(p[1]=m=>i.value=!0),onBlur:p[2]||(p[2]=m=>i.value=!1),onChange:d,onClick:p[3]||(p[3]=et(()=>{},["stop"]))},null,42,Toe),[[Xp,g(u)]]),b("span",{class:D(g(o).e("inner"))},null,2)],2),b("span",{class:D(g(o).e("label")),onKeydown:p[4]||(p[4]=et(()=>{},["stop"]))},[he(f.$slots,"default",{},()=>[ne(A(f.label),1)])],34)],2)}}});var Aoe=ze(Ioe,[["__file","radio.vue"]]);const Noe=We({...MT}),Poe=["value","name","disabled"],Loe=Q({name:"ElRadioButton"}),Roe=Q({...Loe,props:Noe,setup(e){const t=e,n=Re("radio"),{radioRef:o,focus:r,size:s,disabled:i,modelValue:l,radioGroup:a,actualValue:u}=IT(t),c=R(()=>({backgroundColor:(a==null?void 0:a.fill)||"",borderColor:(a==null?void 0:a.fill)||"",boxShadow:a!=null&&a.fill?`-1px 0 0 0 ${a.fill}`:"",color:(a==null?void 0:a.textColor)||""}));return(d,f)=>{var p;return C(),M("label",{class:D([g(n).b("button"),g(n).is("active",g(l)===g(u)),g(n).is("disabled",g(i)),g(n).is("focus",g(r)),g(n).bm("button",g(s))])},[He(b("input",{ref_key:"radioRef",ref:o,"onUpdate:modelValue":f[0]||(f[0]=h=>on(l)?l.value=h:null),class:D(g(n).be("button","original-radio")),value:g(u),type:"radio",name:d.name||((p=g(a))==null?void 0:p.name),disabled:g(i),onFocus:f[1]||(f[1]=h=>r.value=!0),onBlur:f[2]||(f[2]=h=>r.value=!1),onClick:f[3]||(f[3]=et(()=>{},["stop"]))},null,42,Poe),[[Xp,g(l)]]),b("span",{class:D(g(n).be("button","inner")),style:Qe(g(l)===g(u)?g(c):{}),onKeydown:f[4]||(f[4]=et(()=>{},["stop"]))},[he(d.$slots,"default",{},()=>[ne(A(d.label),1)])],38)],2)}}});var AT=ze(Roe,[["__file","radio-button.vue"]]);const Doe=We({id:{type:String,default:void 0},size:qr,disabled:Boolean,modelValue:{type:[String,Number,Boolean],default:void 0},fill:{type:String,default:""},label:{type:String,default:void 0},textColor:{type:String,default:""},name:{type:String,default:void 0},validateEvent:{type:Boolean,default:!0}}),Foe=TT,Voe=["id","aria-label","aria-labelledby"],Boe=Q({name:"ElRadioGroup"}),zoe=Q({...Boe,props:Doe,emits:Foe,setup(e,{emit:t}){const n=e,o=Re("radio"),r=Hr(),s=K(),{formItem:i}=ni(),{inputId:l,isLabeledByFormItem:a}=Sd(n,{formItemContext:i}),u=d=>{t(Jt,d),ot(()=>t("change",d))};Ct(()=>{const d=s.value.querySelectorAll("[type=radio]"),f=d[0];!Array.from(d).some(p=>p.checked)&&f&&(f.tabIndex=0)});const c=R(()=>n.name||r.value);return wt(OT,Dn({...ei(n),changeEvent:u,name:c})),Te(()=>n.modelValue,()=>{n.validateEvent&&(i==null||i.validate("change").catch(d=>void 0))}),(d,f)=>(C(),M("div",{id:g(l),ref_key:"radioGroupRef",ref:s,class:D(g(o).b("group")),role:"radiogroup","aria-label":g(a)?void 0:d.label||"radio-group","aria-labelledby":g(a)?g(i).labelId:void 0},[he(d.$slots,"default")],10,Voe))}});var NT=ze(zoe,[["__file","radio-group.vue"]]);const U0=Zt(Aoe,{RadioButton:AT,RadioGroup:NT}),Eu=Gn(NT),L3=Gn(AT),PT=We({type:{type:String,values:["primary","success","info","warning","danger"],default:"primary"},closable:Boolean,disableTransitions:Boolean,hit:Boolean,color:String,size:{type:String,values:Zl},effect:{type:String,values:["dark","light","plain"],default:"light"},round:Boolean}),joe={close:e=>e instanceof MouseEvent,click:e=>e instanceof MouseEvent},Hoe=Q({name:"ElTag"}),Uoe=Q({...Hoe,props:PT,emits:joe,setup(e,{emit:t}){const n=e,o=Jo(),r=Re("tag"),s=R(()=>{const{type:a,hit:u,effect:c,closable:d,round:f}=n;return[r.b(),r.is("closable",d),r.m(a||"primary"),r.m(o.value),r.m(c),r.is("hit",u),r.is("round",f)]}),i=a=>{t("close",a)},l=a=>{t("click",a)};return(a,u)=>a.disableTransitions?(C(),M("span",{key:0,class:D(g(s)),style:Qe({backgroundColor:a.color}),onClick:l},[b("span",{class:D(g(r).e("content"))},[he(a.$slots,"default")],2),a.closable?(C(),q(g(Ne),{key:0,class:D(g(r).e("close")),onClick:et(i,["stop"])},{default:$(()=>[k(g(Gs))]),_:1},8,["class","onClick"])):W("v-if",!0)],6)):(C(),q(_r,{key:1,name:`${g(r).namespace.value}-zoom-in-center`,appear:""},{default:$(()=>[b("span",{class:D(g(s)),style:Qe({backgroundColor:a.color}),onClick:l},[b("span",{class:D(g(r).e("content"))},[he(a.$slots,"default")],2),a.closable?(C(),q(g(Ne),{key:0,class:D(g(r).e("close")),onClick:et(i,["stop"])},{default:$(()=>[k(g(Gs))]),_:1},8,["class","onClick"])):W("v-if",!0)],6)]),_:3},8,["name"]))}});var Woe=ze(Uoe,[["__file","tag.vue"]]);const mh=Zt(Woe),LT=Symbol("rowContextKey"),Koe=["start","center","end","space-around","space-between","space-evenly"],qoe=["top","middle","bottom"],Goe=We({tag:{type:String,default:"div"},gutter:{type:Number,default:0},justify:{type:String,values:Koe,default:"start"},align:{type:String,values:qoe}}),Yoe=Q({name:"ElRow"}),Zoe=Q({...Yoe,props:Goe,setup(e){const t=e,n=Re("row"),o=R(()=>t.gutter);wt(LT,{gutter:o});const r=R(()=>{const i={};return t.gutter&&(i.marginRight=i.marginLeft=`-${t.gutter/2}px`),i}),s=R(()=>[n.b(),n.is(`justify-${t.justify}`,t.justify!=="start"),n.is(`align-${t.align}`,!!t.align)]);return(i,l)=>(C(),q(Lt(i.tag),{class:D(g(s)),style:Qe(g(r))},{default:$(()=>[he(i.$slots,"default")]),_:3},8,["class","style"]))}});var Joe=ze(Zoe,[["__file","row.vue"]]);const gh=Zt(Joe),Xoe=We({tag:{type:String,default:"div"},span:{type:Number,default:24},offset:{type:Number,default:0},pull:{type:Number,default:0},push:{type:Number,default:0},xs:{type:Ce([Number,Object]),default:()=>$o({})},sm:{type:Ce([Number,Object]),default:()=>$o({})},md:{type:Ce([Number,Object]),default:()=>$o({})},lg:{type:Ce([Number,Object]),default:()=>$o({})},xl:{type:Ce([Number,Object]),default:()=>$o({})}}),Qoe=Q({name:"ElCol"}),ere=Q({...Qoe,props:Xoe,setup(e){const t=e,{gutter:n}=Be(LT,{gutter:R(()=>0)}),o=Re("col"),r=R(()=>{const i={};return n.value&&(i.paddingLeft=i.paddingRight=`${n.value/2}px`),i}),s=R(()=>{const i=[];return["span","offset","pull","push"].forEach(u=>{const c=t[u];_t(c)&&(u==="span"?i.push(o.b(`${t[u]}`)):c>0&&i.push(o.b(`${u}-${t[u]}`)))}),["xs","sm","md","lg","xl"].forEach(u=>{_t(t[u])?i.push(o.b(`${u}-${t[u]}`)):ft(t[u])&&Object.entries(t[u]).forEach(([c,d])=>{i.push(c!=="span"?o.b(`${u}-${c}-${d}`):o.b(`${u}-${d}`))})}),n.value&&i.push(o.is("guttered")),[o.b(),i]});return(i,l)=>(C(),q(Lt(i.tag),{class:D(g(s)),style:Qe(g(r))},{default:$(()=>[he(i.$slots,"default")]),_:3},8,["class","style"]))}});var tre=ze(ere,[["__file","col.vue"]]);const vh=Zt(tre),nre=We({color:{type:Ce(Object),required:!0},vertical:{type:Boolean,default:!1}});let ly=!1;function Fp(e,t){if(!xt)return;const n=function(s){var i;(i=t.drag)==null||i.call(t,s)},o=function(s){var i;document.removeEventListener("mousemove",n),document.removeEventListener("mouseup",o),document.removeEventListener("touchmove",n),document.removeEventListener("touchend",o),document.onselectstart=null,document.ondragstart=null,ly=!1,(i=t.end)==null||i.call(t,s)},r=function(s){var i;ly||(s.preventDefault(),document.onselectstart=()=>!1,document.ondragstart=()=>!1,document.addEventListener("mousemove",n),document.addEventListener("mouseup",o),document.addEventListener("touchmove",n),document.addEventListener("touchend",o),ly=!0,(i=t.start)==null||i.call(t,s))};e.addEventListener("mousedown",r),e.addEventListener("touchstart",r)}const ore=e=>{const t=at(),n=Tn(),o=Tn();function r(i){i.target!==n.value&&s(i)}function s(i){if(!o.value||!n.value)return;const a=t.vnode.el.getBoundingClientRect(),{clientX:u,clientY:c}=Hw(i);if(e.vertical){let d=c-a.top;d=Math.max(n.value.offsetHeight/2,d),d=Math.min(d,a.height-n.value.offsetHeight/2),e.color.set("alpha",Math.round((d-n.value.offsetHeight/2)/(a.height-n.value.offsetHeight)*100))}else{let d=u-a.left;d=Math.max(n.value.offsetWidth/2,d),d=Math.min(d,a.width-n.value.offsetWidth/2),e.color.set("alpha",Math.round((d-n.value.offsetWidth/2)/(a.width-n.value.offsetWidth)*100))}}return{thumb:n,bar:o,handleDrag:s,handleClick:r}},rre=(e,{bar:t,thumb:n,handleDrag:o})=>{const r=at(),s=Re("color-alpha-slider"),i=K(0),l=K(0),a=K();function u(){if(!n.value||e.vertical)return 0;const w=r.vnode.el,_=e.color.get("alpha");return w?Math.round(_*(w.offsetWidth-n.value.offsetWidth/2)/100):0}function c(){if(!n.value)return 0;const w=r.vnode.el;if(!e.vertical)return 0;const _=e.color.get("alpha");return w?Math.round(_*(w.offsetHeight-n.value.offsetHeight/2)/100):0}function d(){if(e.color&&e.color.value){const{r:w,g:_,b:S}=e.color.toRgb();return`linear-gradient(to right, rgba(${w}, ${_}, ${S}, 0) 0%, rgba(${w}, ${_}, ${S}, 1) 100%)`}return""}function f(){i.value=u(),l.value=c(),a.value=d()}Ct(()=>{if(!t.value||!n.value)return;const w={drag:_=>{o(_)},end:_=>{o(_)}};Fp(t.value,w),Fp(n.value,w),f()}),Te(()=>e.color.get("alpha"),()=>f()),Te(()=>e.color.value,()=>f());const p=R(()=>[s.b(),s.is("vertical",e.vertical)]),h=R(()=>s.e("bar")),m=R(()=>s.e("thumb")),y=R(()=>({background:a.value})),v=R(()=>({left:Zo(i.value),top:Zo(l.value)}));return{rootKls:p,barKls:h,barStyle:y,thumbKls:m,thumbStyle:v,update:f}},sre="ElColorAlphaSlider",ire=Q({name:sre}),lre=Q({...ire,props:nre,setup(e,{expose:t}){const n=e,{bar:o,thumb:r,handleDrag:s,handleClick:i}=ore(n),{rootKls:l,barKls:a,barStyle:u,thumbKls:c,thumbStyle:d,update:f}=rre(n,{bar:o,thumb:r,handleDrag:s});return t({update:f,bar:o,thumb:r}),(p,h)=>(C(),M("div",{class:D(g(l))},[b("div",{ref_key:"bar",ref:o,class:D(g(a)),style:Qe(g(u)),onClick:h[0]||(h[0]=(...m)=>g(i)&&g(i)(...m))},null,6),b("div",{ref_key:"thumb",ref:r,class:D(g(c)),style:Qe(g(d))},null,6)],2))}});var are=ze(lre,[["__file","alpha-slider.vue"]]);const ure=Q({name:"ElColorHueSlider",props:{color:{type:Object,required:!0},vertical:Boolean},setup(e){const t=Re("color-hue-slider"),n=at(),o=K(),r=K(),s=K(0),i=K(0),l=R(()=>e.color.get("hue"));Te(()=>l.value,()=>{f()});function a(p){p.target!==o.value&&u(p)}function u(p){if(!r.value||!o.value)return;const m=n.vnode.el.getBoundingClientRect(),{clientX:y,clientY:v}=Hw(p);let w;if(e.vertical){let _=v-m.top;_=Math.min(_,m.height-o.value.offsetHeight/2),_=Math.max(o.value.offsetHeight/2,_),w=Math.round((_-o.value.offsetHeight/2)/(m.height-o.value.offsetHeight)*360)}else{let _=y-m.left;_=Math.min(_,m.width-o.value.offsetWidth/2),_=Math.max(o.value.offsetWidth/2,_),w=Math.round((_-o.value.offsetWidth/2)/(m.width-o.value.offsetWidth)*360)}e.color.set("hue",w)}function c(){if(!o.value)return 0;const p=n.vnode.el;if(e.vertical)return 0;const h=e.color.get("hue");return p?Math.round(h*(p.offsetWidth-o.value.offsetWidth/2)/360):0}function d(){if(!o.value)return 0;const p=n.vnode.el;if(!e.vertical)return 0;const h=e.color.get("hue");return p?Math.round(h*(p.offsetHeight-o.value.offsetHeight/2)/360):0}function f(){s.value=c(),i.value=d()}return Ct(()=>{if(!r.value||!o.value)return;const p={drag:h=>{u(h)},end:h=>{u(h)}};Fp(r.value,p),Fp(o.value,p),f()}),{bar:r,thumb:o,thumbLeft:s,thumbTop:i,hueValue:l,handleClick:a,update:f,ns:t}}});function cre(e,t,n,o,r,s){return C(),M("div",{class:D([e.ns.b(),e.ns.is("vertical",e.vertical)])},[b("div",{ref:"bar",class:D(e.ns.e("bar")),onClick:t[0]||(t[0]=(...i)=>e.handleClick&&e.handleClick(...i))},null,2),b("div",{ref:"thumb",class:D(e.ns.e("thumb")),style:Qe({left:e.thumbLeft+"px",top:e.thumbTop+"px"})},null,6)],2)}var dre=ze(ure,[["render",cre],["__file","hue-slider.vue"]]);const fre=We({modelValue:String,id:String,showAlpha:Boolean,colorFormat:String,disabled:Boolean,size:qr,popperClass:{type:String,default:""},label:{type:String,default:void 0},tabindex:{type:[String,Number],default:0},predefine:{type:Ce(Array)},validateEvent:{type:Boolean,default:!0}}),pre={[Jt]:e=>tt(e)||xo(e),[Cd]:e=>tt(e)||xo(e),activeChange:e=>tt(e)||xo(e),focus:e=>e instanceof FocusEvent,blur:e=>e instanceof FocusEvent},RT=Symbol("colorPickerContextKey"),d8=function(e,t,n){return[e,t*n/((e=(2-t)*n)<1?e:2-e)||0,e/2]},hre=function(e){return typeof e=="string"&&e.includes(".")&&Number.parseFloat(e)===1},mre=function(e){return typeof e=="string"&&e.includes("%")},$c=function(e,t){hre(e)&&(e="100%");const n=mre(e);return e=Math.min(t,Math.max(0,Number.parseFloat(`${e}`))),n&&(e=Number.parseInt(`${e*t}`,10)/100),Math.abs(e-t)<1e-6?1:e%t/Number.parseFloat(t)},f8={10:"A",11:"B",12:"C",13:"D",14:"E",15:"F"},t1=e=>{e=Math.min(Math.round(e),255);const t=Math.floor(e/16),n=e%16;return`${f8[t]||t}${f8[n]||n}`},p8=function({r:e,g:t,b:n}){return Number.isNaN(+e)||Number.isNaN(+t)||Number.isNaN(+n)?"":`#${t1(e)}${t1(t)}${t1(n)}`},ay={A:10,B:11,C:12,D:13,E:14,F:15},da=function(e){return e.length===2?(ay[e[0].toUpperCase()]||+e[0])*16+(ay[e[1].toUpperCase()]||+e[1]):ay[e[1].toUpperCase()]||+e[1]},gre=function(e,t,n){t=t/100,n=n/100;let o=t;const r=Math.max(n,.01);n*=2,t*=n<=1?n:2-n,o*=r<=1?r:2-r;const s=(n+t)/2,i=n===0?2*o/(r+o):2*t/(n+t);return{h:e,s:i*100,v:s*100}},h8=(e,t,n)=>{e=$c(e,255),t=$c(t,255),n=$c(n,255);const o=Math.max(e,t,n),r=Math.min(e,t,n);let s;const i=o,l=o-r,a=o===0?0:l/o;if(o===r)s=0;else{switch(o){case e:{s=(t-n)/l+(t<n?6:0);break}case t:{s=(n-e)/l+2;break}case n:{s=(e-t)/l+4;break}}s/=6}return{h:s*360,s:a*100,v:i*100}},Wd=function(e,t,n){e=$c(e,360)*6,t=$c(t,100),n=$c(n,100);const o=Math.floor(e),r=e-o,s=n*(1-t),i=n*(1-r*t),l=n*(1-(1-r)*t),a=o%6,u=[n,i,s,s,l,n][a],c=[l,n,n,i,s,s][a],d=[s,s,l,n,n,i][a];return{r:Math.round(u*255),g:Math.round(c*255),b:Math.round(d*255)}};class Gf{constructor(t={}){this._hue=0,this._saturation=100,this._value=100,this._alpha=100,this.enableAlpha=!1,this.format="hex",this.value="";for(const n in t)vt(t,n)&&(this[n]=t[n]);t.value?this.fromString(t.value):this.doOnChange()}set(t,n){if(arguments.length===1&&typeof t=="object"){for(const o in t)vt(t,o)&&this.set(o,t[o]);return}this[`_${t}`]=n,this.doOnChange()}get(t){return t==="alpha"?Math.floor(this[`_${t}`]):this[`_${t}`]}toRgb(){return Wd(this._hue,this._saturation,this._value)}fromString(t){if(!t){this._hue=0,this._saturation=100,this._value=100,this.doOnChange();return}const n=(o,r,s)=>{this._hue=Math.max(0,Math.min(360,o)),this._saturation=Math.max(0,Math.min(100,r)),this._value=Math.max(0,Math.min(100,s)),this.doOnChange()};if(t.includes("hsl")){const o=t.replace(/hsla|hsl|\(|\)/gm,"").split(/\s|,/g).filter(r=>r!=="").map((r,s)=>s>2?Number.parseFloat(r):Number.parseInt(r,10));if(o.length===4?this._alpha=Number.parseFloat(o[3])*100:o.length===3&&(this._alpha=100),o.length>=3){const{h:r,s,v:i}=gre(o[0],o[1],o[2]);n(r,s,i)}}else if(t.includes("hsv")){const o=t.replace(/hsva|hsv|\(|\)/gm,"").split(/\s|,/g).filter(r=>r!=="").map((r,s)=>s>2?Number.parseFloat(r):Number.parseInt(r,10));o.length===4?this._alpha=Number.parseFloat(o[3])*100:o.length===3&&(this._alpha=100),o.length>=3&&n(o[0],o[1],o[2])}else if(t.includes("rgb")){const o=t.replace(/rgba|rgb|\(|\)/gm,"").split(/\s|,/g).filter(r=>r!=="").map((r,s)=>s>2?Number.parseFloat(r):Number.parseInt(r,10));if(o.length===4?this._alpha=Number.parseFloat(o[3])*100:o.length===3&&(this._alpha=100),o.length>=3){const{h:r,s,v:i}=h8(o[0],o[1],o[2]);n(r,s,i)}}else if(t.includes("#")){const o=t.replace("#","").trim();if(!/^[0-9a-fA-F]{3}$|^[0-9a-fA-F]{6}$|^[0-9a-fA-F]{8}$/.test(o))return;let r,s,i;o.length===3?(r=da(o[0]+o[0]),s=da(o[1]+o[1]),i=da(o[2]+o[2])):(o.length===6||o.length===8)&&(r=da(o.slice(0,2)),s=da(o.slice(2,4)),i=da(o.slice(4,6))),o.length===8?this._alpha=da(o.slice(6))/255*100:(o.length===3||o.length===6)&&(this._alpha=100);const{h:l,s:a,v:u}=h8(r,s,i);n(l,a,u)}}compare(t){return Math.abs(t._hue-this._hue)<2&&Math.abs(t._saturation-this._saturation)<1&&Math.abs(t._value-this._value)<1&&Math.abs(t._alpha-this._alpha)<1}doOnChange(){const{_hue:t,_saturation:n,_value:o,_alpha:r,format:s}=this;if(this.enableAlpha)switch(s){case"hsl":{const i=d8(t,n/100,o/100);this.value=`hsla(${t}, ${Math.round(i[1]*100)}%, ${Math.round(i[2]*100)}%, ${this.get("alpha")/100})`;break}case"hsv":{this.value=`hsva(${t}, ${Math.round(n)}%, ${Math.round(o)}%, ${this.get("alpha")/100})`;break}case"hex":{this.value=`${p8(Wd(t,n,o))}${t1(r*255/100)}`;break}default:{const{r:i,g:l,b:a}=Wd(t,n,o);this.value=`rgba(${i}, ${l}, ${a}, ${this.get("alpha")/100})`}}else switch(s){case"hsl":{const i=d8(t,n/100,o/100);this.value=`hsl(${t}, ${Math.round(i[1]*100)}%, ${Math.round(i[2]*100)}%)`;break}case"hsv":{this.value=`hsv(${t}, ${Math.round(n)}%, ${Math.round(o)}%)`;break}case"rgb":{const{r:i,g:l,b:a}=Wd(t,n,o);this.value=`rgb(${i}, ${l}, ${a})`;break}default:this.value=p8(Wd(t,n,o))}}}const vre=Q({props:{colors:{type:Array,required:!0},color:{type:Object,required:!0}},setup(e){const t=Re("color-predefine"),{currentColor:n}=Be(RT),o=K(s(e.colors,e.color));Te(()=>n.value,i=>{const l=new Gf;l.fromString(i),o.value.forEach(a=>{a.selected=l.compare(a)})}),ls(()=>{o.value=s(e.colors,e.color)});function r(i){e.color.fromString(e.colors[i])}function s(i,l){return i.map(a=>{const u=new Gf;return u.enableAlpha=!0,u.format="rgba",u.fromString(a),u.selected=u.value===l.value,u})}return{rgbaColors:o,handleSelect:r,ns:t}}}),yre=["onClick"];function _re(e,t,n,o,r,s){return C(),M("div",{class:D(e.ns.b())},[b("div",{class:D(e.ns.e("colors"))},[(C(!0),M(fe,null,nt(e.rgbaColors,(i,l)=>(C(),M("div",{key:e.colors[l],class:D([e.ns.e("color-selector"),e.ns.is("alpha",i._alpha<100),{selected:i.selected}]),onClick:a=>e.handleSelect(l)},[b("div",{style:Qe({backgroundColor:i.value})},null,4)],10,yre))),128))],2)],2)}var bre=ze(vre,[["render",_re],["__file","predefine.vue"]]);const wre=Q({name:"ElSlPanel",props:{color:{type:Object,required:!0}},setup(e){const t=Re("color-svpanel"),n=at(),o=K(0),r=K(0),s=K("hsl(0, 100%, 50%)"),i=R(()=>{const u=e.color.get("hue"),c=e.color.get("value");return{hue:u,value:c}});function l(){const u=e.color.get("saturation"),c=e.color.get("value"),d=n.vnode.el,{clientWidth:f,clientHeight:p}=d;r.value=u*f/100,o.value=(100-c)*p/100,s.value=`hsl(${e.color.get("hue")}, 100%, 50%)`}function a(u){const d=n.vnode.el.getBoundingClientRect(),{clientX:f,clientY:p}=Hw(u);let h=f-d.left,m=p-d.top;h=Math.max(0,h),h=Math.min(h,d.width),m=Math.max(0,m),m=Math.min(m,d.height),r.value=h,o.value=m,e.color.set({saturation:h/d.width*100,value:100-m/d.height*100})}return Te(()=>i.value,()=>{l()}),Ct(()=>{Fp(n.vnode.el,{drag:u=>{a(u)},end:u=>{a(u)}}),l()}),{cursorTop:o,cursorLeft:r,background:s,colorValue:i,handleDrag:a,update:l,ns:t}}}),Cre=b("div",null,null,-1),kre=[Cre];function Sre(e,t,n,o,r,s){return C(),M("div",{class:D(e.ns.b()),style:Qe({backgroundColor:e.background})},[b("div",{class:D(e.ns.e("white"))},null,2),b("div",{class:D(e.ns.e("black"))},null,2),b("div",{class:D(e.ns.e("cursor")),style:Qe({top:e.cursorTop+"px",left:e.cursorLeft+"px"})},kre,6)],6)}var $re=ze(wre,[["render",Sre],["__file","sv-panel.vue"]]);const Ere=["onKeydown"],xre=["id","aria-label","aria-labelledby","aria-description","aria-disabled","tabindex"],Mre=Q({name:"ElColorPicker"}),Tre=Q({...Mre,props:fre,emits:pre,setup(e,{expose:t,emit:n}){const o=e,{t:r}=Kt(),s=Re("color"),{formItem:i}=ni(),l=Jo(),a=Gr(),{inputId:u,isLabeledByFormItem:c}=Sd(o,{formItemContext:i}),d=K(),f=K(),p=K(),h=K(),m=K(),y=K(),{isFocused:v,handleFocus:w,handleBlur:_}=x3(m,{beforeBlur(le){var Ie;return(Ie=h.value)==null?void 0:Ie.isFocusInsideContent(le)},afterBlur(){j(!1),I()}}),S=le=>{if(a.value)return ve();w(le)};let x=!0;const E=Dn(new Gf({enableAlpha:o.showAlpha,format:o.colorFormat||"",value:o.modelValue})),T=K(!1),O=K(!1),P=K(""),N=R(()=>!o.modelValue&&!O.value?"transparent":U(E,o.showAlpha)),F=R(()=>!o.modelValue&&!O.value?"":E.value),B=R(()=>c.value?void 0:o.label||r("el.colorpicker.defaultLabel")),Y=R(()=>c.value?i==null?void 0:i.labelId:void 0),Z=R(()=>[s.b("picker"),s.is("disabled",a.value),s.bm("picker",l.value),s.is("focused",v.value)]);function U(le,Ie){if(!(le instanceof Gf))throw new TypeError("color should be instance of _color Class");const{r:Ge,g:G,b:J}=le.toRgb();return Ie?`rgba(${Ge}, ${G}, ${J}, ${le.get("alpha")/100})`:`rgb(${Ge}, ${G}, ${J})`}function j(le){T.value=le}const V=zl(j,100,{leading:!0});function H(){a.value||j(!0)}function L(){V(!1),I()}function I(){ot(()=>{o.modelValue?E.fromString(o.modelValue):(E.value="",ot(()=>{O.value=!1}))})}function X(){a.value||V(!T.value)}function oe(){E.fromString(P.value)}function z(){const le=E.value;n(Jt,le),n("change",le),o.validateEvent&&(i==null||i.validate("change").catch(Ie=>void 0)),V(!1),ot(()=>{const Ie=new Gf({enableAlpha:o.showAlpha,format:o.colorFormat||"",value:o.modelValue});E.compare(Ie)||I()})}function ge(){V(!1),n(Jt,null),n("change",null),o.modelValue!==null&&o.validateEvent&&(i==null||i.validate("change").catch(le=>void 0)),I()}function Oe(le){if(T.value&&(L(),v.value)){const Ie=new FocusEvent("focus",le);_(Ie)}}function xe(le){le.preventDefault(),le.stopPropagation(),j(!1),I()}function ee(le){switch(le.code){case rt.enter:case rt.space:le.preventDefault(),le.stopPropagation(),H(),y.value.focus();break;case rt.esc:xe(le);break}}function de(){m.value.focus()}function ve(){m.value.blur()}return Ct(()=>{o.modelValue&&(P.value=F.value)}),Te(()=>o.modelValue,le=>{le?le&&le!==E.value&&(x=!1,E.fromString(le)):O.value=!1}),Te(()=>F.value,le=>{P.value=le,x&&n("activeChange",le),x=!0}),Te(()=>E.value,()=>{!o.modelValue&&!O.value&&(O.value=!0)}),Te(()=>T.value,()=>{ot(()=>{var le,Ie,Ge;(le=d.value)==null||le.update(),(Ie=f.value)==null||Ie.update(),(Ge=p.value)==null||Ge.update()})}),wt(RT,{currentColor:F}),t({color:E,show:H,hide:L,focus:de,blur:ve}),(le,Ie)=>(C(),q(g($u),{ref_key:"popper",ref:h,visible:T.value,"show-arrow":!1,"fallback-placements":["bottom","top","right","left"],offset:0,"gpu-acceleration":!1,"popper-class":[g(s).be("picker","panel"),g(s).b("dropdown"),le.popperClass],"stop-popper-mouse-event":!1,effect:"light",trigger:"click",transition:`${g(s).namespace.value}-zoom-in-top`,persistent:"",onHide:Ie[2]||(Ie[2]=Ge=>j(!1))},{content:$(()=>[He((C(),M("div",{onKeydown:Pt(xe,["esc"])},[b("div",{class:D(g(s).be("dropdown","main-wrapper"))},[k(dre,{ref_key:"hue",ref:d,class:"hue-slider",color:g(E),vertical:""},null,8,["color"]),k($re,{ref_key:"sv",ref:f,color:g(E)},null,8,["color"])],2),le.showAlpha?(C(),q(are,{key:0,ref_key:"alpha",ref:p,color:g(E)},null,8,["color"])):W("v-if",!0),le.predefine?(C(),q(bre,{key:1,ref:"predefine",color:g(E),colors:le.predefine},null,8,["color","colors"])):W("v-if",!0),b("div",{class:D(g(s).be("dropdown","btns"))},[b("span",{class:D(g(s).be("dropdown","value"))},[k(g(At),{ref_key:"inputRef",ref:y,modelValue:P.value,"onUpdate:modelValue":Ie[0]||(Ie[0]=Ge=>P.value=Ge),"validate-event":!1,size:"small",onKeyup:Pt(oe,["enter"]),onBlur:oe},null,8,["modelValue","onKeyup"])],2),k(g(pt),{class:D(g(s).be("dropdown","link-btn")),text:"",size:"small",onClick:ge},{default:$(()=>[ne(A(g(r)("el.colorpicker.clear")),1)]),_:1},8,["class"]),k(g(pt),{plain:"",size:"small",class:D(g(s).be("dropdown","btn")),onClick:z},{default:$(()=>[ne(A(g(r)("el.colorpicker.confirm")),1)]),_:1},8,["class"])],2)],40,Ere)),[[g(id),Oe]])]),default:$(()=>[b("div",{id:g(u),ref_key:"triggerRef",ref:m,class:D(g(Z)),role:"button","aria-label":g(B),"aria-labelledby":g(Y),"aria-description":g(r)("el.colorpicker.description",{color:le.modelValue||""}),"aria-disabled":g(a),tabindex:g(a)?-1:le.tabindex,onKeydown:ee,onFocus:S,onBlur:Ie[1]||(Ie[1]=(...Ge)=>g(_)&&g(_)(...Ge))},[g(a)?(C(),M("div",{key:0,class:D(g(s).be("picker","mask"))},null,2)):W("v-if",!0),b("div",{class:D(g(s).be("picker","trigger")),onClick:X},[b("span",{class:D([g(s).be("picker","color"),g(s).is("alpha",le.showAlpha)])},[b("span",{class:D(g(s).be("picker","color-inner")),style:Qe({backgroundColor:g(N)})},[He(k(g(Ne),{class:D([g(s).be("picker","icon"),g(s).is("icon-arrow-down")])},{default:$(()=>[k(g(Su))]),_:1},8,["class"]),[[en,le.modelValue||O.value]]),He(k(g(Ne),{class:D([g(s).be("picker","empty"),g(s).is("icon-close")])},{default:$(()=>[k(g(Gs))]),_:1},8,["class"]),[[en,!le.modelValue&&!O.value]])],6)],2)],2)],42,xre)]),_:1},8,["visible","popper-class","transition"]))}});var Ore=ze(Tre,[["__file","color-picker.vue"]]);const R3=Zt(Ore),Ire=Q({name:"ElContainer"}),Are=Q({...Ire,props:{direction:{type:String}},setup(e){const t=e,n=Kr(),o=Re("container"),r=R(()=>t.direction==="vertical"?!0:t.direction==="horizontal"?!1:n&&n.default?n.default().some(i=>{const l=i.type.name;return l==="ElHeader"||l==="ElFooter"}):!1);return(s,i)=>(C(),M("section",{class:D([g(o).b(),g(o).is("vertical",g(r))])},[he(s.$slots,"default")],2))}});var Nre=ze(Are,[["__file","container.vue"]]);const Pre=Q({name:"ElAside"}),Lre=Q({...Pre,props:{width:{type:String,default:null}},setup(e){const t=e,n=Re("aside"),o=R(()=>t.width?n.cssVarBlock({width:t.width}):{});return(r,s)=>(C(),M("aside",{class:D(g(n).b()),style:Qe(g(o))},[he(r.$slots,"default")],6))}});var DT=ze(Lre,[["__file","aside.vue"]]);const Rre=Q({name:"ElFooter"}),Dre=Q({...Rre,props:{height:{type:String,default:null}},setup(e){const t=e,n=Re("footer"),o=R(()=>t.height?n.cssVarBlock({height:t.height}):{});return(r,s)=>(C(),M("footer",{class:D(g(n).b()),style:Qe(g(o))},[he(r.$slots,"default")],6))}});var FT=ze(Dre,[["__file","footer.vue"]]);const Fre=Q({name:"ElHeader"}),Vre=Q({...Fre,props:{height:{type:String,default:null}},setup(e){const t=e,n=Re("header"),o=R(()=>t.height?n.cssVarBlock({height:t.height}):{});return(r,s)=>(C(),M("header",{class:D(g(n).b()),style:Qe(g(o))},[he(r.$slots,"default")],6))}});var VT=ze(Vre,[["__file","header.vue"]]);const Bre=Q({name:"ElMain"}),zre=Q({...Bre,setup(e){const t=Re("main");return(n,o)=>(C(),M("main",{class:D(g(t).b())},[he(n.$slots,"default")],2))}});var BT=ze(zre,[["__file","main.vue"]]);const zT=Zt(Nre,{Aside:DT,Footer:FT,Header:VT,Main:BT}),jT=Gn(DT);Gn(FT);const HT=Gn(VT),W0=Gn(BT);var UT={exports:{}};(function(e,t){(function(n,o){e.exports=o()})(On,function(){return function(n,o){var r=o.prototype,s=r.format;r.format=function(i){var l=this,a=this.$locale();if(!this.isValid())return s.bind(this)(i);var u=this.$utils(),c=(i||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,function(d){switch(d){case"Q":return Math.ceil((l.$M+1)/3);case"Do":return a.ordinal(l.$D);case"gggg":return l.weekYear();case"GGGG":return l.isoWeekYear();case"wo":return a.ordinal(l.week(),"W");case"w":case"ww":return u.s(l.week(),d==="w"?1:2,"0");case"W":case"WW":return u.s(l.isoWeek(),d==="W"?1:2,"0");case"k":case"kk":return u.s(String(l.$H===0?24:l.$H),d==="k"?1:2,"0");case"X":return Math.floor(l.$d.getTime()/1e3);case"x":return l.$d.getTime();case"z":return"["+l.offsetName()+"]";case"zzz":return"["+l.offsetName("long")+"]";default:return d}});return s.bind(this)(c)}}})})(UT);var jre=UT.exports;const Hre=_o(jre);var WT={exports:{}};(function(e,t){(function(n,o){e.exports=o()})(On,function(){var n="week",o="year";return function(r,s,i){var l=s.prototype;l.week=function(a){if(a===void 0&&(a=null),a!==null)return this.add(7*(a-this.week()),"day");var u=this.$locale().yearStart||1;if(this.month()===11&&this.date()>25){var c=i(this).startOf(o).add(1,o).date(u),d=i(this).endOf(n);if(c.isBefore(d))return 1}var f=i(this).startOf(o).date(u).startOf(n).subtract(1,"millisecond"),p=this.diff(f,n,!0);return p<0?i(this).startOf("week").week():Math.ceil(p)},l.weeks=function(a){return a===void 0&&(a=null),this.week(a)}}})})(WT);var Ure=WT.exports;const Wre=_o(Ure);var KT={exports:{}};(function(e,t){(function(n,o){e.exports=o()})(On,function(){return function(n,o){o.prototype.weekYear=function(){var r=this.month(),s=this.week(),i=this.year();return s===1&&r===11?i+1:r===0&&s>=52?i-1:i}}})})(KT);var Kre=KT.exports;const qre=_o(Kre);var qT={exports:{}};(function(e,t){(function(n,o){e.exports=o()})(On,function(){return function(n,o,r){o.prototype.dayOfYear=function(s){var i=Math.round((r(this).startOf("day")-r(this).startOf("year"))/864e5)+1;return s==null?i:this.add(s-i,"day")}}})})(qT);var Gre=qT.exports;const Yre=_o(Gre);var GT={exports:{}};(function(e,t){(function(n,o){e.exports=o()})(On,function(){return function(n,o){o.prototype.isSameOrAfter=function(r,s){return this.isSame(r,s)||this.isAfter(r,s)}}})})(GT);var Zre=GT.exports;const Jre=_o(Zre);var YT={exports:{}};(function(e,t){(function(n,o){e.exports=o()})(On,function(){return function(n,o){o.prototype.isSameOrBefore=function(r,s){return this.isSame(r,s)||this.isBefore(r,s)}}})})(YT);var Xre=YT.exports;const Qre=_o(Xre),D3=Symbol(),ese=We({...pT,type:{type:Ce(String),default:"date"}}),tse=["date","dates","year","years","month","week","range"],F3=We({disabledDate:{type:Ce(Function)},date:{type:Ce(Object),required:!0},minDate:{type:Ce(Object)},maxDate:{type:Ce(Object)},parsedValue:{type:Ce([Object,Array])},rangeState:{type:Ce(Object),default:()=>({endDate:null,selecting:!1})}}),ZT=We({type:{type:Ce(String),required:!0,values:vJ},dateFormat:String,timeFormat:String}),JT=We({unlinkPanels:Boolean,parsedValue:{type:Ce(Array)}}),V3=e=>({type:String,values:tse,default:e}),nse=We({...ZT,parsedValue:{type:Ce([Object,Array])},visible:{type:Boolean},format:{type:String,default:""}}),ose=We({...F3,cellClassName:{type:Ce(Function)},showWeekNumber:Boolean,selectionMode:V3("date")}),rse=["changerange","pick","select"],_b=e=>{if(!Me(e))return!1;const[t,n]=e;return ut.isDayjs(t)&&ut.isDayjs(n)&&t.isSameOrBefore(n)},XT=(e,{lang:t,unit:n,unlinkPanels:o})=>{let r;if(Me(e)){let[s,i]=e.map(l=>ut(l).locale(t));return o||(i=s.add(1,n)),[s,i]}else e?r=ut(e):r=ut();return r=r.locale(t),[r,r.add(1,n)]},sse=(e,t,{columnIndexOffset:n,startDate:o,nextEndDate:r,now:s,unit:i,relativeDateGetter:l,setCellMetadata:a,setRowMetadata:u})=>{for(let c=0;c<e.row;c++){const d=t[c];for(let f=0;f<e.column;f++){let p=d[f+n];p||(p={row:c,column:f,type:"normal",inRange:!1,start:!1,end:!1});const h=c*e.column+f,m=l(h);p.dayjs=m,p.date=m.toDate(),p.timestamp=m.valueOf(),p.type="normal",p.inRange=!!(o&&m.isSameOrAfter(o,i)&&r&&m.isSameOrBefore(r,i))||!!(o&&m.isSameOrBefore(o,i)&&r&&m.isSameOrAfter(r,i)),o!=null&&o.isSameOrAfter(r)?(p.start=!!r&&m.isSame(r,i),p.end=o&&m.isSame(o,i)):(p.start=!!o&&m.isSame(o,i),p.end=!!r&&m.isSame(r,i)),m.isSame(s,i)&&(p.type="today"),a==null||a(p,{rowIndex:c,columnIndex:f}),d[f+n]=p}u==null||u(d)}},bb=(e="")=>["normal","today"].includes(e),ise=(e,t)=>{const{lang:n}=Kt(),o=K(),r=K(),s=K(),i=K(),l=K([[],[],[],[],[],[]]);let a=!1;const u=e.date.$locale().weekStart||7,c=e.date.locale("en").localeData().weekdaysShort().map(L=>L.toLowerCase()),d=R(()=>u>3?7-u:-u),f=R(()=>{const L=e.date.startOf("month");return L.subtract(L.day()||7,"day")}),p=R(()=>c.concat(c).slice(u,u+7)),h=R(()=>Ex(g(S)).some(L=>L.isCurrent)),m=R(()=>{const L=e.date.startOf("month"),I=L.day()||7,X=L.daysInMonth(),oe=L.subtract(1,"month").daysInMonth();return{startOfMonthDay:I,dateCountOfMonth:X,dateCountOfLastMonth:oe}}),y=R(()=>e.selectionMode==="dates"?ns(e.parsedValue):[]),v=(L,{count:I,rowIndex:X,columnIndex:oe})=>{const{startOfMonthDay:z,dateCountOfMonth:ge,dateCountOfLastMonth:Oe}=g(m),xe=g(d);if(X>=0&&X<=1){const ee=z+xe<0?7+z+xe:z+xe;if(oe+X*7>=ee)return L.text=I,!0;L.text=Oe-(ee-oe%7)+1+X*7,L.type="prev-month"}else return I<=ge?L.text=I:(L.text=I-ge,L.type="next-month"),!0;return!1},w=(L,{columnIndex:I,rowIndex:X},oe)=>{const{disabledDate:z,cellClassName:ge}=e,Oe=g(y),xe=v(L,{count:oe,rowIndex:X,columnIndex:I}),ee=L.dayjs.toDate();return L.selected=Oe.find(de=>de.isSame(L.dayjs,"day")),L.isSelected=!!L.selected,L.isCurrent=E(L),L.disabled=z==null?void 0:z(ee),L.customClass=ge==null?void 0:ge(ee),xe},_=L=>{if(e.selectionMode==="week"){const[I,X]=e.showWeekNumber?[1,7]:[0,6],oe=H(L[I+1]);L[I].inRange=oe,L[I].start=oe,L[X].inRange=oe,L[X].end=oe}},S=R(()=>{const{minDate:L,maxDate:I,rangeState:X,showWeekNumber:oe}=e,z=g(d),ge=g(l),Oe="day";let xe=1;if(oe)for(let ee=0;ee<6;ee++)ge[ee][0]||(ge[ee][0]={type:"week",text:g(f).add(ee*7+1,Oe).week()});return sse({row:6,column:7},ge,{startDate:L,columnIndexOffset:oe?1:0,nextEndDate:X.endDate||I||X.selecting&&L||null,now:ut().locale(g(n)).startOf(Oe),unit:Oe,relativeDateGetter:ee=>g(f).add(ee-z,Oe),setCellMetadata:(...ee)=>{w(...ee,xe)&&(xe+=1)},setRowMetadata:_}),ge});Te(()=>e.date,async()=>{var L;(L=g(o))!=null&&L.contains(document.activeElement)&&(await ot(),await x())});const x=async()=>{var L;return(L=g(r))==null?void 0:L.focus()},E=L=>e.selectionMode==="date"&&bb(L.type)&&T(L,e.parsedValue),T=(L,I)=>I?ut(I).locale(g(n)).isSame(e.date.date(Number(L.text)),"day"):!1,O=(L,I)=>{const X=L*7+(I-(e.showWeekNumber?1:0))-g(d);return g(f).add(X,"day")},P=L=>{var I;if(!e.rangeState.selecting)return;let X=L.target;if(X.tagName==="SPAN"&&(X=(I=X.parentNode)==null?void 0:I.parentNode),X.tagName==="DIV"&&(X=X.parentNode),X.tagName!=="TD")return;const oe=X.parentNode.rowIndex-1,z=X.cellIndex;g(S)[oe][z].disabled||(oe!==g(s)||z!==g(i))&&(s.value=oe,i.value=z,t("changerange",{selecting:!0,endDate:O(oe,z)}))},N=L=>!g(h)&&(L==null?void 0:L.text)===1&&L.type==="normal"||L.isCurrent,F=L=>{a||g(h)||e.selectionMode!=="date"||V(L,!0)},B=L=>{L.target.closest("td")&&(a=!0)},Y=L=>{L.target.closest("td")&&(a=!1)},Z=L=>{!e.rangeState.selecting||!e.minDate?(t("pick",{minDate:L,maxDate:null}),t("select",!0)):(L>=e.minDate?t("pick",{minDate:e.minDate,maxDate:L}):t("pick",{minDate:L,maxDate:e.minDate}),t("select",!1))},U=L=>{const I=L.week(),X=`${L.year()}w${I}`;t("pick",{year:L.year(),week:I,value:X,date:L.startOf("week")})},j=(L,I)=>{const X=I?ns(e.parsedValue).filter(oe=>(oe==null?void 0:oe.valueOf())!==L.valueOf()):ns(e.parsedValue).concat([L]);t("pick",X)},V=(L,I=!1)=>{const X=L.target.closest("td");if(!X)return;const oe=X.parentNode.rowIndex-1,z=X.cellIndex,ge=g(S)[oe][z];if(ge.disabled||ge.type==="week")return;const Oe=O(oe,z);switch(e.selectionMode){case"range":{Z(Oe);break}case"date":{t("pick",Oe,I);break}case"week":{U(Oe);break}case"dates":{j(Oe,!!ge.selected);break}}},H=L=>{if(e.selectionMode!=="week")return!1;let I=e.date.startOf("day");if(L.type==="prev-month"&&(I=I.subtract(1,"month")),L.type==="next-month"&&(I=I.add(1,"month")),I=I.date(Number.parseInt(L.text,10)),e.parsedValue&&!Array.isArray(e.parsedValue)){const X=(e.parsedValue.day()-u+7)%7-1;return e.parsedValue.subtract(X,"day").isSame(I,"day")}return!1};return{WEEKS:p,rows:S,tbodyRef:o,currentCellRef:r,focus:x,isCurrent:E,isWeekActive:H,isSelectedCell:N,handlePickDate:V,handleMouseUp:Y,handleMouseDown:B,handleMouseMove:P,handleFocus:F}},lse=(e,{isCurrent:t,isWeekActive:n})=>{const o=Re("date-table"),{t:r}=Kt(),s=R(()=>[o.b(),{"is-week-mode":e.selectionMode==="week"}]),i=R(()=>r("el.datepicker.dateTablePrompt")),l=R(()=>r("el.datepicker.week"));return{tableKls:s,tableLabel:i,weekLabel:l,getCellClasses:c=>{const d=[];return bb(c.type)&&!c.disabled?(d.push("available"),c.type==="today"&&d.push("today")):d.push(c.type),t(c)&&d.push("current"),c.inRange&&(bb(c.type)||e.selectionMode==="week")&&(d.push("in-range"),c.start&&d.push("start-date"),c.end&&d.push("end-date")),c.disabled&&d.push("disabled"),c.selected&&d.push("selected"),c.customClass&&d.push(c.customClass),d.join(" ")},getRowKls:c=>[o.e("row"),{current:n(c)}],t:r}},ase=We({cell:{type:Ce(Object)}});var use=Q({name:"ElDatePickerCell",props:ase,setup(e){const t=Re("date-table-cell"),{slots:n}=Be(D3);return()=>{const{cell:o}=e;return he(n,"default",{...o},()=>[k("div",{class:t.b()},[k("span",{class:t.e("text")},[o==null?void 0:o.text])])])}}});const cse=["aria-label"],dse={key:0,scope:"col"},fse=["aria-label"],pse=["aria-current","aria-selected","tabindex"],hse=Q({__name:"basic-date-table",props:ose,emits:rse,setup(e,{expose:t,emit:n}){const o=e,{WEEKS:r,rows:s,tbodyRef:i,currentCellRef:l,focus:a,isCurrent:u,isWeekActive:c,isSelectedCell:d,handlePickDate:f,handleMouseUp:p,handleMouseDown:h,handleMouseMove:m,handleFocus:y}=ise(o,n),{tableLabel:v,tableKls:w,weekLabel:_,getCellClasses:S,getRowKls:x,t:E}=lse(o,{isCurrent:u,isWeekActive:c});return t({focus:a}),(T,O)=>(C(),M("table",{"aria-label":g(v),class:D(g(w)),cellspacing:"0",cellpadding:"0",role:"grid",onClick:O[1]||(O[1]=(...P)=>g(f)&&g(f)(...P)),onMousemove:O[2]||(O[2]=(...P)=>g(m)&&g(m)(...P)),onMousedown:O[3]||(O[3]=et((...P)=>g(h)&&g(h)(...P),["prevent"])),onMouseup:O[4]||(O[4]=(...P)=>g(p)&&g(p)(...P))},[b("tbody",{ref_key:"tbodyRef",ref:i},[b("tr",null,[T.showWeekNumber?(C(),M("th",dse,A(g(_)),1)):W("v-if",!0),(C(!0),M(fe,null,nt(g(r),(P,N)=>(C(),M("th",{key:N,"aria-label":g(E)("el.datepicker.weeksFull."+P),scope:"col"},A(g(E)("el.datepicker.weeks."+P)),9,fse))),128))]),(C(!0),M(fe,null,nt(g(s),(P,N)=>(C(),M("tr",{key:N,class:D(g(x)(P[1]))},[(C(!0),M(fe,null,nt(P,(F,B)=>(C(),M("td",{key:`${N}.${B}`,ref_for:!0,ref:Y=>g(d)(F)&&(l.value=Y),class:D(g(S)(F)),"aria-current":F.isCurrent?"date":void 0,"aria-selected":F.isCurrent,tabindex:g(d)(F)?0:-1,onFocus:O[0]||(O[0]=(...Y)=>g(y)&&g(y)(...Y))},[k(g(use),{cell:F},null,8,["cell"])],42,pse))),128))],2))),128))],512)],42,cse))}});var wb=ze(hse,[["__file","basic-date-table.vue"]]);const mse=We({...F3,selectionMode:V3("month")}),gse=["aria-label"],vse=["aria-selected","aria-label","tabindex","onKeydown"],yse={class:"cell"},_se=Q({__name:"basic-month-table",props:mse,emits:["changerange","pick","select"],setup(e,{expose:t,emit:n}){const o=e,r=(S,x,E)=>{const T=ut().locale(E).startOf("month").month(x).year(S),O=T.daysInMonth();return uT(O).map(P=>T.add(P,"day").toDate())},s=Re("month-table"),{t:i,lang:l}=Kt(),a=K(),u=K(),c=K(o.date.locale("en").localeData().monthsShort().map(S=>S.toLowerCase())),d=K([[],[],[]]),f=K(),p=K(),h=R(()=>{var S,x;const E=d.value,T=ut().locale(l.value).startOf("month");for(let O=0;O<3;O++){const P=E[O];for(let N=0;N<4;N++){const F=P[N]||(P[N]={row:O,column:N,type:"normal",inRange:!1,start:!1,end:!1,text:-1,disabled:!1});F.type="normal";const B=O*4+N,Y=o.date.startOf("year").month(B),Z=o.rangeState.endDate||o.maxDate||o.rangeState.selecting&&o.minDate||null;F.inRange=!!(o.minDate&&Y.isSameOrAfter(o.minDate,"month")&&Z&&Y.isSameOrBefore(Z,"month"))||!!(o.minDate&&Y.isSameOrBefore(o.minDate,"month")&&Z&&Y.isSameOrAfter(Z,"month")),(S=o.minDate)!=null&&S.isSameOrAfter(Z)?(F.start=!!(Z&&Y.isSame(Z,"month")),F.end=o.minDate&&Y.isSame(o.minDate,"month")):(F.start=!!(o.minDate&&Y.isSame(o.minDate,"month")),F.end=!!(Z&&Y.isSame(Z,"month"))),T.isSame(Y)&&(F.type="today"),F.text=B,F.disabled=((x=o.disabledDate)==null?void 0:x.call(o,Y.toDate()))||!1}}return E}),m=()=>{var S;(S=u.value)==null||S.focus()},y=S=>{const x={},E=o.date.year(),T=new Date,O=S.text;return x.disabled=o.disabledDate?r(E,O,l.value).every(o.disabledDate):!1,x.current=ns(o.parsedValue).findIndex(P=>ut.isDayjs(P)&&P.year()===E&&P.month()===O)>=0,x.today=T.getFullYear()===E&&T.getMonth()===O,S.inRange&&(x["in-range"]=!0,S.start&&(x["start-date"]=!0),S.end&&(x["end-date"]=!0)),x},v=S=>{const x=o.date.year(),E=S.text;return ns(o.date).findIndex(T=>T.year()===x&&T.month()===E)>=0},w=S=>{var x;if(!o.rangeState.selecting)return;let E=S.target;if(E.tagName==="SPAN"&&(E=(x=E.parentNode)==null?void 0:x.parentNode),E.tagName==="DIV"&&(E=E.parentNode),E.tagName!=="TD")return;const T=E.parentNode.rowIndex,O=E.cellIndex;h.value[T][O].disabled||(T!==f.value||O!==p.value)&&(f.value=T,p.value=O,n("changerange",{selecting:!0,endDate:o.date.startOf("year").month(T*4+O)}))},_=S=>{var x;const E=(x=S.target)==null?void 0:x.closest("td");if((E==null?void 0:E.tagName)!=="TD"||Ti(E,"disabled"))return;const T=E.cellIndex,P=E.parentNode.rowIndex*4+T,N=o.date.startOf("year").month(P);o.selectionMode==="range"?o.rangeState.selecting?(o.minDate&&N>=o.minDate?n("pick",{minDate:o.minDate,maxDate:N}):n("pick",{minDate:N,maxDate:o.minDate}),n("select",!1)):(n("pick",{minDate:N,maxDate:null}),n("select",!0)):n("pick",P)};return Te(()=>o.date,async()=>{var S,x;(S=a.value)!=null&&S.contains(document.activeElement)&&(await ot(),(x=u.value)==null||x.focus())}),t({focus:m}),(S,x)=>(C(),M("table",{role:"grid","aria-label":g(i)("el.datepicker.monthTablePrompt"),class:D(g(s).b()),onClick:_,onMousemove:w},[b("tbody",{ref_key:"tbodyRef",ref:a},[(C(!0),M(fe,null,nt(g(h),(E,T)=>(C(),M("tr",{key:T},[(C(!0),M(fe,null,nt(E,(O,P)=>(C(),M("td",{key:P,ref_for:!0,ref:N=>v(O)&&(u.value=N),class:D(y(O)),"aria-selected":`${v(O)}`,"aria-label":g(i)(`el.datepicker.month${+O.text+1}`),tabindex:v(O)?0:-1,onKeydown:[Pt(et(_,["prevent","stop"]),["space"]),Pt(et(_,["prevent","stop"]),["enter"])]},[b("div",null,[b("span",yse,A(g(i)("el.datepicker.months."+c.value[O.text])),1)])],42,vse))),128))]))),128))],512)],42,gse))}});var Cb=ze(_se,[["__file","basic-month-table.vue"]]);const{date:bse,disabledDate:wse,parsedValue:Cse}=F3,kse=We({date:bse,disabledDate:wse,parsedValue:Cse,selectionMode:V3("year")}),Sse=["aria-label"],$se=["aria-selected","tabindex","onKeydown"],Ese={class:"cell"},xse={key:1},Mse=Q({__name:"basic-year-table",props:kse,emits:["pick"],setup(e,{expose:t,emit:n}){const o=e,r=(m,y)=>{const v=ut(String(m)).locale(y).startOf("year"),_=v.endOf("year").dayOfYear();return uT(_).map(S=>v.add(S,"day").toDate())},s=Re("year-table"),{t:i,lang:l}=Kt(),a=K(),u=K(),c=R(()=>Math.floor(o.date.year()/10)*10),d=()=>{var m;(m=u.value)==null||m.focus()},f=m=>{const y={},v=ut().locale(l.value);return y.disabled=o.disabledDate?r(m,l.value).every(o.disabledDate):!1,y.current=ns(o.parsedValue).findIndex(w=>w.year()===m)>=0,y.today=v.year()===m,y},p=m=>m===c.value&&o.date.year()<c.value&&o.date.year()>c.value+9||ns(o.date).findIndex(y=>y.year()===m)>=0||ns(o.parsedValue).findIndex(y=>(y==null?void 0:y.year())===m)>=0,h=m=>{const v=m.target.closest("td");if(v&&v.textContent){if(Ti(v,"disabled"))return;const w=v.textContent||v.innerText;if(o.selectionMode==="years"){if(m.type==="keydown"){n("pick",ns(o.parsedValue),!1);return}const _=Ti(v,"current")?ns(o.parsedValue).filter(S=>(S==null?void 0:S.year())!==Number(w)):ns(o.parsedValue).concat([ut(w)]);n("pick",_)}else n("pick",Number(w))}};return Te(()=>o.date,async()=>{var m,y;(m=a.value)!=null&&m.contains(document.activeElement)&&(await ot(),(y=u.value)==null||y.focus())}),t({focus:d}),(m,y)=>(C(),M("table",{role:"grid","aria-label":g(i)("el.datepicker.yearTablePrompt"),class:D(g(s).b()),onClick:h},[b("tbody",{ref_key:"tbodyRef",ref:a},[(C(),M(fe,null,nt(3,(v,w)=>b("tr",{key:w},[(C(),M(fe,null,nt(4,(_,S)=>(C(),M(fe,{key:w+"_"+S},[w*4+S<10?(C(),M("td",{key:0,ref_for:!0,ref:x=>p(g(c)+w*4+S)&&(u.value=x),class:D(["available",f(g(c)+w*4+S)]),"aria-selected":`${p(g(c)+w*4+S)}`,tabindex:p(g(c)+w*4+S)?0:-1,onKeydown:[Pt(et(h,["prevent","stop"]),["space"]),Pt(et(h,["prevent","stop"]),["enter"])]},[b("div",null,[b("span",Ese,A(g(c)+w*4+S),1)])],42,$se)):(C(),M("td",xse))],64))),64))])),64))],512)],10,Sse))}});var Tse=ze(Mse,[["__file","basic-year-table.vue"]]);const Ose=["onClick"],Ise=["aria-label"],Ase=["aria-label"],Nse=["aria-label"],Pse=["aria-label"],Lse=Q({__name:"panel-date-pick",props:nse,emits:["pick","set-picker-option","panel-change"],setup(e,{emit:t}){const n=e,o=(ie,we,ae)=>!0,r=Re("picker-panel"),s=Re("date-picker"),i=_d(),l=Kr(),{t:a,lang:u}=Kt(),c=Be("EP_PICKER_BASE"),d=Be(H0),{shortcuts:f,disabledDate:p,cellClassName:h,defaultTime:m}=c.props,y=pn(c.props,"defaultValue"),v=K(),w=K(ut().locale(u.value)),_=K(!1);let S=!1;const x=R(()=>ut(m).locale(u.value)),E=R(()=>w.value.month()),T=R(()=>w.value.year()),O=K([]),P=K(null),N=K(null),F=ie=>O.value.length>0?o(ie,O.value,n.format||"HH:mm:ss"):!0,B=ie=>m&&!J.value&&!_.value&&!S?x.value.year(ie.year()).month(ie.month()).date(ie.date()):xe.value?ie.millisecond(0):ie.startOf("day"),Y=(ie,...we)=>{if(!ie)t("pick",ie,...we);else if(Me(ie)){const ae=ie.map(B);t("pick",ae,...we)}else t("pick",B(ie),...we);P.value=null,N.value=null,_.value=!1,S=!1},Z=async(ie,we)=>{if(I.value==="date"){ie=ie;let ae=n.parsedValue?n.parsedValue.year(ie.year()).month(ie.month()).date(ie.date()):ie;F(ae)||(ae=O.value[0][0].year(ie.year()).month(ie.month()).date(ie.date())),w.value=ae,Y(ae,xe.value||we),n.type==="datetime"&&(await ot(),pe())}else I.value==="week"?Y(ie.date):I.value==="dates"&&Y(ie,!0)},U=ie=>{const we=ie?"add":"subtract";w.value=w.value[we](1,"month"),$e("month")},j=ie=>{const we=w.value,ae=ie?"add":"subtract";w.value=V.value==="year"?we[ae](10,"year"):we[ae](1,"year"),$e("year")},V=K("date"),H=R(()=>{const ie=a("el.datepicker.year");if(V.value==="year"){const we=Math.floor(T.value/10)*10;return ie?`${we} ${ie} - ${we+9} ${ie}`:`${we} - ${we+9}`}return`${T.value} ${ie}`}),L=ie=>{const we=Xe(ie.value)?ie.value():ie.value;if(we){S=!0,Y(ut(we).locale(u.value));return}ie.onClick&&ie.onClick({attrs:i,slots:l,emit:t})},I=R(()=>{const{type:ie}=n;return["week","month","year","years","dates"].includes(ie)?ie:"date"}),X=R(()=>I.value==="date"?V.value:I.value),oe=R(()=>!!f.length),z=async ie=>{w.value=w.value.startOf("month").month(ie),I.value==="month"?Y(w.value,!1):(V.value="date",["month","year","date","week"].includes(I.value)&&(Y(w.value,!0),await ot(),pe())),$e("month")},ge=async(ie,we)=>{I.value==="year"?(w.value=w.value.startOf("year").year(ie),Y(w.value,!1)):I.value==="years"?Y(ie,we??!0):(w.value=w.value.year(ie),V.value="month",["month","year","date","week"].includes(I.value)&&(Y(w.value,!0),await ot(),pe())),$e("year")},Oe=async ie=>{V.value=ie,await ot(),pe()},xe=R(()=>n.type==="datetime"||n.type==="datetimerange"),ee=R(()=>{const ie=xe.value||I.value==="dates",we=I.value==="years",ae=V.value==="date",Se=V.value==="year";return ie&&ae||we&&Se}),de=R(()=>p?n.parsedValue?Me(n.parsedValue)?p(n.parsedValue[0].toDate()):p(n.parsedValue.toDate()):!0:!1),ve=()=>{if(I.value==="dates"||I.value==="years")Y(n.parsedValue);else{let ie=n.parsedValue;if(!ie){const we=ut(m).locale(u.value),ae=te();ie=we.year(ae.year()).month(ae.month()).date(ae.date())}w.value=ie,Y(ie)}},le=R(()=>p?p(ut().locale(u.value).toDate()):!1),Ie=()=>{const we=ut().locale(u.value).toDate();_.value=!0,(!p||!p(we))&&F(we)&&(w.value=ut().locale(u.value),Y(w.value))},Ge=R(()=>n.timeFormat||dT(n.format)),G=R(()=>n.dateFormat||cT(n.format)),J=R(()=>{if(N.value)return N.value;if(!(!n.parsedValue&&!y.value))return(n.parsedValue||w.value).format(Ge.value)}),ue=R(()=>{if(P.value)return P.value;if(!(!n.parsedValue&&!y.value))return(n.parsedValue||w.value).format(G.value)}),_e=K(!1),ye=()=>{_e.value=!0},Ae=()=>{_e.value=!1},Le=ie=>({hour:ie.hour(),minute:ie.minute(),second:ie.second(),year:ie.year(),month:ie.month(),date:ie.date()}),Ee=(ie,we,ae)=>{const{hour:Se,minute:Fe,second:st}=Le(ie),se=n.parsedValue?n.parsedValue.hour(Se).minute(Fe).second(st):ie;w.value=se,Y(w.value,!0),ae||(_e.value=we)},Pe=ie=>{const we=ut(ie,Ge.value).locale(u.value);if(we.isValid()&&F(we)){const{year:ae,month:Se,date:Fe}=Le(w.value);w.value=we.year(ae).month(Se).date(Fe),N.value=null,_e.value=!1,Y(w.value,!0)}},me=ie=>{const we=ut(ie,G.value).locale(u.value);if(we.isValid()){if(p&&p(we.toDate()))return;const{hour:ae,minute:Se,second:Fe}=Le(w.value);w.value=we.hour(ae).minute(Se).second(Fe),P.value=null,Y(w.value,!0)}},je=ie=>ut.isDayjs(ie)&&ie.isValid()&&(p?!p(ie.toDate()):!0),Ze=ie=>Me(ie)?ie.map(we=>we.format(n.format)):ie.format(n.format),ce=ie=>ut(ie,n.format).locale(u.value),te=()=>{const ie=ut(y.value).locale(u.value);if(!y.value){const we=x.value;return ut().hour(we.hour()).minute(we.minute()).second(we.second()).locale(u.value)}return ie},pe=async()=>{var ie;["week","month","year","date"].includes(I.value)&&((ie=v.value)==null||ie.focus(),I.value==="week"&&Je(rt.down))},Ve=ie=>{const{code:we}=ie;[rt.up,rt.down,rt.left,rt.right,rt.home,rt.end,rt.pageUp,rt.pageDown].includes(we)&&(Je(we),ie.stopPropagation(),ie.preventDefault()),[rt.enter,rt.space,rt.numpadEnter].includes(we)&&P.value===null&&N.value===null&&(ie.preventDefault(),Y(w.value,!1))},Je=ie=>{var we;const{up:ae,down:Se,left:Fe,right:st,home:se,end:De,pageUp:Ot,pageDown:mn}=rt,Un={year:{[ae]:-4,[Se]:4,[Fe]:-1,[st]:1,offset:(qt,nr)=>qt.setFullYear(qt.getFullYear()+nr)},month:{[ae]:-4,[Se]:4,[Fe]:-1,[st]:1,offset:(qt,nr)=>qt.setMonth(qt.getMonth()+nr)},week:{[ae]:-1,[Se]:1,[Fe]:-1,[st]:1,offset:(qt,nr)=>qt.setDate(qt.getDate()+nr*7)},date:{[ae]:-7,[Se]:7,[Fe]:-1,[st]:1,[se]:qt=>-qt.getDay(),[De]:qt=>-qt.getDay()+6,[Ot]:qt=>-new Date(qt.getFullYear(),qt.getMonth(),0).getDate(),[mn]:qt=>new Date(qt.getFullYear(),qt.getMonth()+1,0).getDate(),offset:(qt,nr)=>qt.setDate(qt.getDate()+nr)}},Zr=w.value.toDate();for(;Math.abs(w.value.diff(Zr,"year",!0))<1;){const qt=Un[X.value];if(!qt)return;if(qt.offset(Zr,Xe(qt[ie])?qt[ie](Zr):(we=qt[ie])!=null?we:0),p&&p(Zr))break;const nr=ut(Zr).locale(u.value);w.value=nr,t("pick",nr,!0);break}},$e=ie=>{t("panel-change",w.value.toDate(),ie,V.value)};return Te(()=>I.value,ie=>{if(["month","year"].includes(ie)){V.value=ie;return}else if(ie==="years"){V.value="year";return}V.value="date"},{immediate:!0}),Te(()=>V.value,()=>{d==null||d.updatePopper()}),Te(()=>y.value,ie=>{ie&&(w.value=te())},{immediate:!0}),Te(()=>n.parsedValue,ie=>{if(ie){if(I.value==="dates"||I.value==="years"||Array.isArray(ie))return;w.value=ie}else w.value=te()},{immediate:!0}),t("set-picker-option",["isValidValue",je]),t("set-picker-option",["formatToString",Ze]),t("set-picker-option",["parseUserInput",ce]),t("set-picker-option",["handleFocusPicker",pe]),(ie,we)=>(C(),M("div",{class:D([g(r).b(),g(s).b(),{"has-sidebar":ie.$slots.sidebar||g(oe),"has-time":g(xe)}])},[b("div",{class:D(g(r).e("body-wrapper"))},[he(ie.$slots,"sidebar",{class:D(g(r).e("sidebar"))}),g(oe)?(C(),M("div",{key:0,class:D(g(r).e("sidebar"))},[(C(!0),M(fe,null,nt(g(f),(ae,Se)=>(C(),M("button",{key:Se,type:"button",class:D(g(r).e("shortcut")),onClick:Fe=>L(ae)},A(ae.text),11,Ose))),128))],2)):W("v-if",!0),b("div",{class:D(g(r).e("body"))},[g(xe)?(C(),M("div",{key:0,class:D(g(s).e("time-header"))},[b("span",{class:D(g(s).e("editor-wrap"))},[k(g(At),{placeholder:g(a)("el.datepicker.selectDate"),"model-value":g(ue),size:"small","validate-event":!1,onInput:we[0]||(we[0]=ae=>P.value=ae),onChange:me},null,8,["placeholder","model-value"])],2),He((C(),M("span",{class:D(g(s).e("editor-wrap"))},[k(g(At),{placeholder:g(a)("el.datepicker.selectTime"),"model-value":g(J),size:"small","validate-event":!1,onFocus:ye,onInput:we[1]||(we[1]=ae=>N.value=ae),onChange:Pe},null,8,["placeholder","model-value"]),k(g(yb),{visible:_e.value,format:g(Ge),"parsed-value":w.value,onPick:Ee},null,8,["visible","format","parsed-value"])],2)),[[g(id),Ae]])],2)):W("v-if",!0),He(b("div",{class:D([g(s).e("header"),(V.value==="year"||V.value==="month")&&g(s).e("header--bordered")])},[b("span",{class:D(g(s).e("prev-btn"))},[b("button",{type:"button","aria-label":g(a)("el.datepicker.prevYear"),class:D(["d-arrow-left",g(r).e("icon-btn")]),onClick:we[2]||(we[2]=ae=>j(!1))},[k(g(Ne),null,{default:$(()=>[k(g(Jc))]),_:1})],10,Ise),He(b("button",{type:"button","aria-label":g(a)("el.datepicker.prevMonth"),class:D([g(r).e("icon-btn"),"arrow-left"]),onClick:we[3]||(we[3]=ae=>U(!1))},[k(g(Ne),null,{default:$(()=>[k(g(au))]),_:1})],10,Ase),[[en,V.value==="date"]])],2),b("span",{role:"button",class:D(g(s).e("header-label")),"aria-live":"polite",tabindex:"0",onKeydown:we[4]||(we[4]=Pt(ae=>Oe("year"),["enter"])),onClick:we[5]||(we[5]=ae=>Oe("year"))},A(g(H)),35),He(b("span",{role:"button","aria-live":"polite",tabindex:"0",class:D([g(s).e("header-label"),{active:V.value==="month"}]),onKeydown:we[6]||(we[6]=Pt(ae=>Oe("month"),["enter"])),onClick:we[7]||(we[7]=ae=>Oe("month"))},A(g(a)(`el.datepicker.month${g(E)+1}`)),35),[[en,V.value==="date"]]),b("span",{class:D(g(s).e("next-btn"))},[He(b("button",{type:"button","aria-label":g(a)("el.datepicker.nextMonth"),class:D([g(r).e("icon-btn"),"arrow-right"]),onClick:we[8]||(we[8]=ae=>U(!0))},[k(g(Ne),null,{default:$(()=>[k(g(js))]),_:1})],10,Nse),[[en,V.value==="date"]]),b("button",{type:"button","aria-label":g(a)("el.datepicker.nextYear"),class:D([g(r).e("icon-btn"),"d-arrow-right"]),onClick:we[9]||(we[9]=ae=>j(!0))},[k(g(Ne),null,{default:$(()=>[k(g(Xc))]),_:1})],10,Pse)],2)],2),[[en,V.value!=="time"]]),b("div",{class:D(g(r).e("content")),onKeydown:Ve},[V.value==="date"?(C(),q(wb,{key:0,ref_key:"currentViewRef",ref:v,"selection-mode":g(I),date:w.value,"parsed-value":ie.parsedValue,"disabled-date":g(p),"cell-class-name":g(h),onPick:Z},null,8,["selection-mode","date","parsed-value","disabled-date","cell-class-name"])):W("v-if",!0),V.value==="year"?(C(),q(Tse,{key:1,ref_key:"currentViewRef",ref:v,"selection-mode":g(I),date:w.value,"disabled-date":g(p),"parsed-value":ie.parsedValue,onPick:ge},null,8,["selection-mode","date","disabled-date","parsed-value"])):W("v-if",!0),V.value==="month"?(C(),q(Cb,{key:2,ref_key:"currentViewRef",ref:v,date:w.value,"parsed-value":ie.parsedValue,"disabled-date":g(p),onPick:z},null,8,["date","parsed-value","disabled-date"])):W("v-if",!0)],34)],2)],2),He(b("div",{class:D(g(r).e("footer"))},[He(k(g(pt),{text:"",size:"small",class:D(g(r).e("link-btn")),disabled:g(le),onClick:Ie},{default:$(()=>[ne(A(g(a)("el.datepicker.now")),1)]),_:1},8,["class","disabled"]),[[en,g(I)!=="dates"&&g(I)!=="years"]]),k(g(pt),{plain:"",size:"small",class:D(g(r).e("link-btn")),disabled:g(de),onClick:ve},{default:$(()=>[ne(A(g(a)("el.datepicker.confirm")),1)]),_:1},8,["class","disabled"])],2),[[en,g(ee)]])],2))}});var Rse=ze(Lse,[["__file","panel-date-pick.vue"]]);const Dse=We({...ZT,...JT}),Fse=e=>{const{emit:t}=at(),n=_d(),o=Kr();return s=>{const i=Xe(s.value)?s.value():s.value;if(i){t("pick",[ut(i[0]).locale(e.value),ut(i[1]).locale(e.value)]);return}s.onClick&&s.onClick({attrs:n,slots:o,emit:t})}},QT=(e,{defaultValue:t,leftDate:n,rightDate:o,unit:r,onParsedValueChanged:s})=>{const{emit:i}=at(),{pickerNs:l}=Be(D3),a=Re("date-range-picker"),{t:u,lang:c}=Kt(),d=Fse(c),f=K(),p=K(),h=K({endDate:null,selecting:!1}),m=_=>{h.value=_},y=(_=!1)=>{const S=g(f),x=g(p);_b([S,x])&&i("pick",[S,x],_)},v=_=>{h.value.selecting=_,_||(h.value.endDate=null)},w=()=>{const[_,S]=XT(g(t),{lang:g(c),unit:r,unlinkPanels:e.unlinkPanels});f.value=void 0,p.value=void 0,n.value=_,o.value=S};return Te(t,_=>{_&&w()},{immediate:!0}),Te(()=>e.parsedValue,_=>{if(Me(_)&&_.length===2){const[S,x]=_;f.value=S,n.value=S,p.value=x,s(g(f),g(p))}else w()},{immediate:!0}),{minDate:f,maxDate:p,rangeState:h,lang:c,ppNs:l,drpNs:a,handleChangeRange:m,handleRangeConfirm:y,handleShortcutClick:d,onSelect:v,t:u}},Vse=["onClick"],Bse=["aria-label"],zse=["aria-label"],jse=["disabled","aria-label"],Hse=["disabled","aria-label"],Use=["disabled","aria-label"],Wse=["disabled","aria-label"],Kse=["aria-label"],qse=["aria-label"],vm="month",Gse=Q({__name:"panel-date-range",props:Dse,emits:["pick","set-picker-option","calendar-change","panel-change"],setup(e,{emit:t}){const n=e,o=Be("EP_PICKER_BASE"),{disabledDate:r,cellClassName:s,format:i,defaultTime:l,clearable:a}=o.props,u=pn(o.props,"shortcuts"),c=pn(o.props,"defaultValue"),{lang:d}=Kt(),f=K(ut().locale(d.value)),p=K(ut().locale(d.value).add(1,vm)),{minDate:h,maxDate:m,rangeState:y,ppNs:v,drpNs:w,handleChangeRange:_,handleRangeConfirm:S,handleShortcutClick:x,onSelect:E,t:T}=QT(n,{defaultValue:c,leftDate:f,rightDate:p,unit:vm,onParsedValueChanged:we}),O=K({min:null,max:null}),P=K({min:null,max:null}),N=R(()=>`${f.value.year()} ${T("el.datepicker.year")} ${T(`el.datepicker.month${f.value.month()+1}`)}`),F=R(()=>`${p.value.year()} ${T("el.datepicker.year")} ${T(`el.datepicker.month${p.value.month()+1}`)}`),B=R(()=>f.value.year()),Y=R(()=>f.value.month()),Z=R(()=>p.value.year()),U=R(()=>p.value.month()),j=R(()=>!!u.value.length),V=R(()=>O.value.min!==null?O.value.min:h.value?h.value.format(oe.value):""),H=R(()=>O.value.max!==null?O.value.max:m.value||h.value?(m.value||h.value).format(oe.value):""),L=R(()=>P.value.min!==null?P.value.min:h.value?h.value.format(X.value):""),I=R(()=>P.value.max!==null?P.value.max:m.value||h.value?(m.value||h.value).format(X.value):""),X=R(()=>n.timeFormat||dT(i)),oe=R(()=>n.dateFormat||cT(i)),z=ae=>_b(ae)&&(r?!r(ae[0].toDate())&&!r(ae[1].toDate()):!0),ge=()=>{f.value=f.value.subtract(1,"year"),n.unlinkPanels||(p.value=f.value.add(1,"month")),Ge("year")},Oe=()=>{f.value=f.value.subtract(1,"month"),n.unlinkPanels||(p.value=f.value.add(1,"month")),Ge("month")},xe=()=>{n.unlinkPanels?p.value=p.value.add(1,"year"):(f.value=f.value.add(1,"year"),p.value=f.value.add(1,"month")),Ge("year")},ee=()=>{n.unlinkPanels?p.value=p.value.add(1,"month"):(f.value=f.value.add(1,"month"),p.value=f.value.add(1,"month")),Ge("month")},de=()=>{f.value=f.value.add(1,"year"),Ge("year")},ve=()=>{f.value=f.value.add(1,"month"),Ge("month")},le=()=>{p.value=p.value.subtract(1,"year"),Ge("year")},Ie=()=>{p.value=p.value.subtract(1,"month"),Ge("month")},Ge=ae=>{t("panel-change",[f.value.toDate(),p.value.toDate()],ae)},G=R(()=>{const ae=(Y.value+1)%12,Se=Y.value+1>=12?1:0;return n.unlinkPanels&&new Date(B.value+Se,ae)<new Date(Z.value,U.value)}),J=R(()=>n.unlinkPanels&&Z.value*12+U.value-(B.value*12+Y.value+1)>=12),ue=R(()=>!(h.value&&m.value&&!y.value.selecting&&_b([h.value,m.value]))),_e=R(()=>n.type==="datetime"||n.type==="datetimerange"),ye=(ae,Se)=>{if(ae)return l?ut(l[Se]||l).locale(d.value).year(ae.year()).month(ae.month()).date(ae.date()):ae},Ae=(ae,Se=!0)=>{const Fe=ae.minDate,st=ae.maxDate,se=ye(Fe,0),De=ye(st,1);m.value===De&&h.value===se||(t("calendar-change",[Fe.toDate(),st&&st.toDate()]),m.value=De,h.value=se,!(!Se||_e.value)&&S())},Le=K(!1),Ee=K(!1),Pe=()=>{Le.value=!1},me=()=>{Ee.value=!1},je=(ae,Se)=>{O.value[Se]=ae;const Fe=ut(ae,oe.value).locale(d.value);if(Fe.isValid()){if(r&&r(Fe.toDate()))return;Se==="min"?(f.value=Fe,h.value=(h.value||f.value).year(Fe.year()).month(Fe.month()).date(Fe.date()),!n.unlinkPanels&&(!m.value||m.value.isBefore(h.value))&&(p.value=Fe.add(1,"month"),m.value=h.value.add(1,"month"))):(p.value=Fe,m.value=(m.value||p.value).year(Fe.year()).month(Fe.month()).date(Fe.date()),!n.unlinkPanels&&(!h.value||h.value.isAfter(m.value))&&(f.value=Fe.subtract(1,"month"),h.value=m.value.subtract(1,"month")))}},Ze=(ae,Se)=>{O.value[Se]=null},ce=(ae,Se)=>{P.value[Se]=ae;const Fe=ut(ae,X.value).locale(d.value);Fe.isValid()&&(Se==="min"?(Le.value=!0,h.value=(h.value||f.value).hour(Fe.hour()).minute(Fe.minute()).second(Fe.second()),(!m.value||m.value.isBefore(h.value))&&(m.value=h.value)):(Ee.value=!0,m.value=(m.value||p.value).hour(Fe.hour()).minute(Fe.minute()).second(Fe.second()),p.value=m.value,m.value&&m.value.isBefore(h.value)&&(h.value=m.value)))},te=(ae,Se)=>{P.value[Se]=null,Se==="min"?(f.value=h.value,Le.value=!1):(p.value=m.value,Ee.value=!1)},pe=(ae,Se,Fe)=>{P.value.min||(ae&&(f.value=ae,h.value=(h.value||f.value).hour(ae.hour()).minute(ae.minute()).second(ae.second())),Fe||(Le.value=Se),(!m.value||m.value.isBefore(h.value))&&(m.value=h.value,p.value=ae))},Ve=(ae,Se,Fe)=>{P.value.max||(ae&&(p.value=ae,m.value=(m.value||p.value).hour(ae.hour()).minute(ae.minute()).second(ae.second())),Fe||(Ee.value=Se),m.value&&m.value.isBefore(h.value)&&(h.value=m.value))},Je=()=>{f.value=XT(g(c),{lang:g(d),unit:"month",unlinkPanels:n.unlinkPanels})[0],p.value=f.value.add(1,"month"),m.value=void 0,h.value=void 0,t("pick",null)},$e=ae=>Me(ae)?ae.map(Se=>Se.format(i)):ae.format(i),ie=ae=>Me(ae)?ae.map(Se=>ut(Se,i).locale(d.value)):ut(ae,i).locale(d.value);function we(ae,Se){if(n.unlinkPanels&&Se){const Fe=(ae==null?void 0:ae.year())||0,st=(ae==null?void 0:ae.month())||0,se=Se.year(),De=Se.month();p.value=Fe===se&&st===De?Se.add(1,vm):Se}else p.value=f.value.add(1,vm),Se&&(p.value=p.value.hour(Se.hour()).minute(Se.minute()).second(Se.second()))}return t("set-picker-option",["isValidValue",z]),t("set-picker-option",["parseUserInput",ie]),t("set-picker-option",["formatToString",$e]),t("set-picker-option",["handleClear",Je]),(ae,Se)=>(C(),M("div",{class:D([g(v).b(),g(w).b(),{"has-sidebar":ae.$slots.sidebar||g(j),"has-time":g(_e)}])},[b("div",{class:D(g(v).e("body-wrapper"))},[he(ae.$slots,"sidebar",{class:D(g(v).e("sidebar"))}),g(j)?(C(),M("div",{key:0,class:D(g(v).e("sidebar"))},[(C(!0),M(fe,null,nt(g(u),(Fe,st)=>(C(),M("button",{key:st,type:"button",class:D(g(v).e("shortcut")),onClick:se=>g(x)(Fe)},A(Fe.text),11,Vse))),128))],2)):W("v-if",!0),b("div",{class:D(g(v).e("body"))},[g(_e)?(C(),M("div",{key:0,class:D(g(w).e("time-header"))},[b("span",{class:D(g(w).e("editors-wrap"))},[b("span",{class:D(g(w).e("time-picker-wrap"))},[k(g(At),{size:"small",disabled:g(y).selecting,placeholder:g(T)("el.datepicker.startDate"),class:D(g(w).e("editor")),"model-value":g(V),"validate-event":!1,onInput:Se[0]||(Se[0]=Fe=>je(Fe,"min")),onChange:Se[1]||(Se[1]=Fe=>Ze(Fe,"min"))},null,8,["disabled","placeholder","class","model-value"])],2),He((C(),M("span",{class:D(g(w).e("time-picker-wrap"))},[k(g(At),{size:"small",class:D(g(w).e("editor")),disabled:g(y).selecting,placeholder:g(T)("el.datepicker.startTime"),"model-value":g(L),"validate-event":!1,onFocus:Se[2]||(Se[2]=Fe=>Le.value=!0),onInput:Se[3]||(Se[3]=Fe=>ce(Fe,"min")),onChange:Se[4]||(Se[4]=Fe=>te(Fe,"min"))},null,8,["class","disabled","placeholder","model-value"]),k(g(yb),{visible:Le.value,format:g(X),"datetime-role":"start","parsed-value":f.value,onPick:pe},null,8,["visible","format","parsed-value"])],2)),[[g(id),Pe]])],2),b("span",null,[k(g(Ne),null,{default:$(()=>[k(g(js))]),_:1})]),b("span",{class:D([g(w).e("editors-wrap"),"is-right"])},[b("span",{class:D(g(w).e("time-picker-wrap"))},[k(g(At),{size:"small",class:D(g(w).e("editor")),disabled:g(y).selecting,placeholder:g(T)("el.datepicker.endDate"),"model-value":g(H),readonly:!g(h),"validate-event":!1,onInput:Se[5]||(Se[5]=Fe=>je(Fe,"max")),onChange:Se[6]||(Se[6]=Fe=>Ze(Fe,"max"))},null,8,["class","disabled","placeholder","model-value","readonly"])],2),He((C(),M("span",{class:D(g(w).e("time-picker-wrap"))},[k(g(At),{size:"small",class:D(g(w).e("editor")),disabled:g(y).selecting,placeholder:g(T)("el.datepicker.endTime"),"model-value":g(I),readonly:!g(h),"validate-event":!1,onFocus:Se[7]||(Se[7]=Fe=>g(h)&&(Ee.value=!0)),onInput:Se[8]||(Se[8]=Fe=>ce(Fe,"max")),onChange:Se[9]||(Se[9]=Fe=>te(Fe,"max"))},null,8,["class","disabled","placeholder","model-value","readonly"]),k(g(yb),{"datetime-role":"end",visible:Ee.value,format:g(X),"parsed-value":p.value,onPick:Ve},null,8,["visible","format","parsed-value"])],2)),[[g(id),me]])],2)],2)):W("v-if",!0),b("div",{class:D([[g(v).e("content"),g(w).e("content")],"is-left"])},[b("div",{class:D(g(w).e("header"))},[b("button",{type:"button",class:D([g(v).e("icon-btn"),"d-arrow-left"]),"aria-label":g(T)("el.datepicker.prevYear"),onClick:ge},[k(g(Ne),null,{default:$(()=>[k(g(Jc))]),_:1})],10,Bse),b("button",{type:"button",class:D([g(v).e("icon-btn"),"arrow-left"]),"aria-label":g(T)("el.datepicker.prevMonth"),onClick:Oe},[k(g(Ne),null,{default:$(()=>[k(g(au))]),_:1})],10,zse),ae.unlinkPanels?(C(),M("button",{key:0,type:"button",disabled:!g(J),class:D([[g(v).e("icon-btn"),{"is-disabled":!g(J)}],"d-arrow-right"]),"aria-label":g(T)("el.datepicker.nextYear"),onClick:de},[k(g(Ne),null,{default:$(()=>[k(g(Xc))]),_:1})],10,jse)):W("v-if",!0),ae.unlinkPanels?(C(),M("button",{key:1,type:"button",disabled:!g(G),class:D([[g(v).e("icon-btn"),{"is-disabled":!g(G)}],"arrow-right"]),"aria-label":g(T)("el.datepicker.nextMonth"),onClick:ve},[k(g(Ne),null,{default:$(()=>[k(g(js))]),_:1})],10,Hse)):W("v-if",!0),b("div",null,A(g(N)),1)],2),k(wb,{"selection-mode":"range",date:f.value,"min-date":g(h),"max-date":g(m),"range-state":g(y),"disabled-date":g(r),"cell-class-name":g(s),onChangerange:g(_),onPick:Ae,onSelect:g(E)},null,8,["date","min-date","max-date","range-state","disabled-date","cell-class-name","onChangerange","onSelect"])],2),b("div",{class:D([[g(v).e("content"),g(w).e("content")],"is-right"])},[b("div",{class:D(g(w).e("header"))},[ae.unlinkPanels?(C(),M("button",{key:0,type:"button",disabled:!g(J),class:D([[g(v).e("icon-btn"),{"is-disabled":!g(J)}],"d-arrow-left"]),"aria-label":g(T)("el.datepicker.prevYear"),onClick:le},[k(g(Ne),null,{default:$(()=>[k(g(Jc))]),_:1})],10,Use)):W("v-if",!0),ae.unlinkPanels?(C(),M("button",{key:1,type:"button",disabled:!g(G),class:D([[g(v).e("icon-btn"),{"is-disabled":!g(G)}],"arrow-left"]),"aria-label":g(T)("el.datepicker.prevMonth"),onClick:Ie},[k(g(Ne),null,{default:$(()=>[k(g(au))]),_:1})],10,Wse)):W("v-if",!0),b("button",{type:"button","aria-label":g(T)("el.datepicker.nextYear"),class:D([g(v).e("icon-btn"),"d-arrow-right"]),onClick:xe},[k(g(Ne),null,{default:$(()=>[k(g(Xc))]),_:1})],10,Kse),b("button",{type:"button",class:D([g(v).e("icon-btn"),"arrow-right"]),"aria-label":g(T)("el.datepicker.nextMonth"),onClick:ee},[k(g(Ne),null,{default:$(()=>[k(g(js))]),_:1})],10,qse),b("div",null,A(g(F)),1)],2),k(wb,{"selection-mode":"range",date:p.value,"min-date":g(h),"max-date":g(m),"range-state":g(y),"disabled-date":g(r),"cell-class-name":g(s),onChangerange:g(_),onPick:Ae,onSelect:g(E)},null,8,["date","min-date","max-date","range-state","disabled-date","cell-class-name","onChangerange","onSelect"])],2)],2)],2),g(_e)?(C(),M("div",{key:0,class:D(g(v).e("footer"))},[g(a)?(C(),q(g(pt),{key:0,text:"",size:"small",class:D(g(v).e("link-btn")),onClick:Je},{default:$(()=>[ne(A(g(T)("el.datepicker.clear")),1)]),_:1},8,["class"])):W("v-if",!0),k(g(pt),{plain:"",size:"small",class:D(g(v).e("link-btn")),disabled:g(ue),onClick:Se[10]||(Se[10]=Fe=>g(S)(!1))},{default:$(()=>[ne(A(g(T)("el.datepicker.confirm")),1)]),_:1},8,["class","disabled"])],2)):W("v-if",!0)],2))}});var Yse=ze(Gse,[["__file","panel-date-range.vue"]]);const Zse=We({...JT}),Jse=["pick","set-picker-option","calendar-change"],Xse=({unlinkPanels:e,leftDate:t,rightDate:n})=>{const{t:o}=Kt(),r=()=>{t.value=t.value.subtract(1,"year"),e.value||(n.value=n.value.subtract(1,"year"))},s=()=>{e.value||(t.value=t.value.add(1,"year")),n.value=n.value.add(1,"year")},i=()=>{t.value=t.value.add(1,"year")},l=()=>{n.value=n.value.subtract(1,"year")},a=R(()=>`${t.value.year()} ${o("el.datepicker.year")}`),u=R(()=>`${n.value.year()} ${o("el.datepicker.year")}`),c=R(()=>t.value.year()),d=R(()=>n.value.year()===t.value.year()?t.value.year()+1:n.value.year());return{leftPrevYear:r,rightNextYear:s,leftNextYear:i,rightPrevYear:l,leftLabel:a,rightLabel:u,leftYear:c,rightYear:d}},Qse=["onClick"],eie=["disabled"],tie=["disabled"],ym="year",nie=Q({name:"DatePickerMonthRange"}),oie=Q({...nie,props:Zse,emits:Jse,setup(e,{emit:t}){const n=e,{lang:o}=Kt(),r=Be("EP_PICKER_BASE"),{shortcuts:s,disabledDate:i,format:l}=r.props,a=pn(r.props,"defaultValue"),u=K(ut().locale(o.value)),c=K(ut().locale(o.value).add(1,ym)),{minDate:d,maxDate:f,rangeState:p,ppNs:h,drpNs:m,handleChangeRange:y,handleRangeConfirm:v,handleShortcutClick:w,onSelect:_}=QT(n,{defaultValue:a,leftDate:u,rightDate:c,unit:ym,onParsedValueChanged:j}),S=R(()=>!!s.length),{leftPrevYear:x,rightNextYear:E,leftNextYear:T,rightPrevYear:O,leftLabel:P,rightLabel:N,leftYear:F,rightYear:B}=Xse({unlinkPanels:pn(n,"unlinkPanels"),leftDate:u,rightDate:c}),Y=R(()=>n.unlinkPanels&&B.value>F.value+1),Z=(V,H=!0)=>{const L=V.minDate,I=V.maxDate;f.value===I&&d.value===L||(t("calendar-change",[L.toDate(),I&&I.toDate()]),f.value=I,d.value=L,H&&v())},U=V=>V.map(H=>H.format(l));function j(V,H){if(n.unlinkPanels&&H){const L=(V==null?void 0:V.year())||0,I=H.year();c.value=L===I?H.add(1,ym):H}else c.value=u.value.add(1,ym)}return t("set-picker-option",["formatToString",U]),(V,H)=>(C(),M("div",{class:D([g(h).b(),g(m).b(),{"has-sidebar":!!V.$slots.sidebar||g(S)}])},[b("div",{class:D(g(h).e("body-wrapper"))},[he(V.$slots,"sidebar",{class:D(g(h).e("sidebar"))}),g(S)?(C(),M("div",{key:0,class:D(g(h).e("sidebar"))},[(C(!0),M(fe,null,nt(g(s),(L,I)=>(C(),M("button",{key:I,type:"button",class:D(g(h).e("shortcut")),onClick:X=>g(w)(L)},A(L.text),11,Qse))),128))],2)):W("v-if",!0),b("div",{class:D(g(h).e("body"))},[b("div",{class:D([[g(h).e("content"),g(m).e("content")],"is-left"])},[b("div",{class:D(g(m).e("header"))},[b("button",{type:"button",class:D([g(h).e("icon-btn"),"d-arrow-left"]),onClick:H[0]||(H[0]=(...L)=>g(x)&&g(x)(...L))},[k(g(Ne),null,{default:$(()=>[k(g(Jc))]),_:1})],2),V.unlinkPanels?(C(),M("button",{key:0,type:"button",disabled:!g(Y),class:D([[g(h).e("icon-btn"),{[g(h).is("disabled")]:!g(Y)}],"d-arrow-right"]),onClick:H[1]||(H[1]=(...L)=>g(T)&&g(T)(...L))},[k(g(Ne),null,{default:$(()=>[k(g(Xc))]),_:1})],10,eie)):W("v-if",!0),b("div",null,A(g(P)),1)],2),k(Cb,{"selection-mode":"range",date:u.value,"min-date":g(d),"max-date":g(f),"range-state":g(p),"disabled-date":g(i),onChangerange:g(y),onPick:Z,onSelect:g(_)},null,8,["date","min-date","max-date","range-state","disabled-date","onChangerange","onSelect"])],2),b("div",{class:D([[g(h).e("content"),g(m).e("content")],"is-right"])},[b("div",{class:D(g(m).e("header"))},[V.unlinkPanels?(C(),M("button",{key:0,type:"button",disabled:!g(Y),class:D([[g(h).e("icon-btn"),{"is-disabled":!g(Y)}],"d-arrow-left"]),onClick:H[2]||(H[2]=(...L)=>g(O)&&g(O)(...L))},[k(g(Ne),null,{default:$(()=>[k(g(Jc))]),_:1})],10,tie)):W("v-if",!0),b("button",{type:"button",class:D([g(h).e("icon-btn"),"d-arrow-right"]),onClick:H[3]||(H[3]=(...L)=>g(E)&&g(E)(...L))},[k(g(Ne),null,{default:$(()=>[k(g(Xc))]),_:1})],2),b("div",null,A(g(N)),1)],2),k(Cb,{"selection-mode":"range",date:c.value,"min-date":g(d),"max-date":g(f),"range-state":g(p),"disabled-date":g(i),onChangerange:g(y),onPick:Z,onSelect:g(_)},null,8,["date","min-date","max-date","range-state","disabled-date","onChangerange","onSelect"])],2)],2)],2)],2))}});var rie=ze(oie,[["__file","panel-month-range.vue"]]);const sie=function(e){switch(e){case"daterange":case"datetimerange":return Yse;case"monthrange":return rie;default:return Rse}};ut.extend(uoe);ut.extend(Hre);ut.extend(aT);ut.extend(Wre);ut.extend(qre);ut.extend(Yre);ut.extend(Jre);ut.extend(Qre);var iie=Q({name:"ElDatePicker",install:null,props:ese,emits:["update:modelValue"],setup(e,{expose:t,emit:n,slots:o}){const r=Re("picker-panel");wt("ElPopperOptions",Dn(pn(e,"popperOptions"))),wt(D3,{slots:o,pickerNs:r});const s=K();t({focus:(a=!0)=>{var u;(u=s.value)==null||u.focus(a)},handleOpen:()=>{var a;(a=s.value)==null||a.handleOpen()},handleClose:()=>{var a;(a=s.value)==null||a.handleClose()}});const l=a=>{n("update:modelValue",a)};return()=>{var a;const u=(a=e.format)!=null?a:Lne[e.type]||qu,c=sie(e.type);return k(zne,un(e,{format:u,type:e.type,ref:s,"onUpdate:modelValue":l}),{default:d=>k(c,d,null),"range-separator":o["range-separator"]})}}});const n1=iie;n1.install=e=>{e.component(n1.name,n1)};const lie=n1,aie=We({mask:{type:Boolean,default:!0},customMaskEvent:{type:Boolean,default:!1},overlayClass:{type:Ce([String,Array,Object])},zIndex:{type:Ce([String,Number])}}),uie={click:e=>e instanceof MouseEvent},cie="overlay";var die=Q({name:"ElOverlay",props:aie,emits:uie,setup(e,{slots:t,emit:n}){const o=Re(cie),r=a=>{n("click",a)},{onClick:s,onMousedown:i,onMouseup:l}=C3(e.customMaskEvent?void 0:r);return()=>e.mask?k("div",{class:[o.b(),e.overlayClass],style:{zIndex:e.zIndex},onClick:s,onMousedown:i,onMouseup:l},[he(t,"default")],Gm.STYLE|Gm.CLASS|Gm.PROPS,["onClick","onMouseup","onMousedown"]):lt("div",{class:e.overlayClass,style:{zIndex:e.zIndex,position:"fixed",top:"0px",right:"0px",bottom:"0px",left:"0px"}},[he(t,"default")])}});const B3=die,eO=Symbol("dialogInjectionKey"),tO=We({center:Boolean,alignCenter:Boolean,closeIcon:{type:Oo},draggable:Boolean,overflow:Boolean,fullscreen:Boolean,showClose:{type:Boolean,default:!0},title:{type:String,default:""},ariaLevel:{type:String,default:"2"}}),fie={close:()=>!0},pie=["aria-level"],hie=["aria-label"],mie=["id"],gie=Q({name:"ElDialogContent"}),vie=Q({...gie,props:tO,emits:fie,setup(e){const t=e,{t:n}=Kt(),{Close:o}=sM,{dialogRef:r,headerRef:s,bodyId:i,ns:l,style:a}=Be(eO),{focusTrapRef:u}=Be(A3),c=R(()=>[l.b(),l.is("fullscreen",t.fullscreen),l.is("draggable",t.draggable),l.is("align-center",t.alignCenter),{[l.m("center")]:t.center}]),d=f3(u,r),f=R(()=>t.draggable),p=R(()=>t.overflow);return uM(r,s,f,p),(h,m)=>(C(),M("div",{ref:g(d),class:D(g(c)),style:Qe(g(a)),tabindex:"-1"},[b("header",{ref_key:"headerRef",ref:s,class:D([g(l).e("header"),{"show-close":h.showClose}])},[he(h.$slots,"header",{},()=>[b("span",{role:"heading","aria-level":h.ariaLevel,class:D(g(l).e("title"))},A(h.title),11,pie)]),h.showClose?(C(),M("button",{key:0,"aria-label":g(n)("el.dialog.close"),class:D(g(l).e("headerbtn")),type:"button",onClick:m[0]||(m[0]=y=>h.$emit("close"))},[k(g(Ne),{class:D(g(l).e("close"))},{default:$(()=>[(C(),q(Lt(h.closeIcon||g(o))))]),_:1},8,["class"])],10,hie)):W("v-if",!0)],2),b("div",{id:g(i),class:D(g(l).e("body"))},[he(h.$slots,"default")],10,mie),h.$slots.footer?(C(),M("footer",{key:0,class:D(g(l).e("footer"))},[he(h.$slots,"footer")],2)):W("v-if",!0)],6))}});var yie=ze(vie,[["__file","dialog-content.vue"]]);const nO=We({...tO,appendToBody:Boolean,appendTo:{type:Ce(String),default:"body"},beforeClose:{type:Ce(Function)},destroyOnClose:Boolean,closeOnClickModal:{type:Boolean,default:!0},closeOnPressEscape:{type:Boolean,default:!0},lockScroll:{type:Boolean,default:!0},modal:{type:Boolean,default:!0},openDelay:{type:Number,default:0},closeDelay:{type:Number,default:0},top:{type:String},modelValue:Boolean,modalClass:String,width:{type:[String,Number]},zIndex:{type:Number},trapFocus:{type:Boolean,default:!1},headerAriaLevel:{type:String,default:"2"}}),oO={open:()=>!0,opened:()=>!0,close:()=>!0,closed:()=>!0,[Jt]:e=>Br(e),openAutoFocus:()=>!0,closeAutoFocus:()=>!0},rO=(e,t)=>{var n;const r=at().emit,{nextZIndex:s}=D0();let i="";const l=Hr(),a=Hr(),u=K(!1),c=K(!1),d=K(!1),f=K((n=e.zIndex)!=null?n:s());let p,h;const m=ph("namespace",Hf),y=R(()=>{const U={},j=`--${m.value}-dialog`;return e.fullscreen||(e.top&&(U[`${j}-margin-top`]=e.top),e.width&&(U[`${j}-width`]=Zo(e.width))),U}),v=R(()=>e.alignCenter?{display:"flex"}:{});function w(){r("opened")}function _(){r("closed"),r(Jt,!1),e.destroyOnClose&&(d.value=!1)}function S(){r("close")}function x(){h==null||h(),p==null||p(),e.openDelay&&e.openDelay>0?{stop:p}=V_(()=>P(),e.openDelay):P()}function E(){p==null||p(),h==null||h(),e.closeDelay&&e.closeDelay>0?{stop:h}=V_(()=>N(),e.closeDelay):N()}function T(){function U(j){j||(c.value=!0,u.value=!1)}e.beforeClose?e.beforeClose(U):E()}function O(){e.closeOnClickModal&&T()}function P(){xt&&(u.value=!0)}function N(){u.value=!1}function F(){r("openAutoFocus")}function B(){r("closeAutoFocus")}function Y(U){var j;((j=U.detail)==null?void 0:j.focusReason)==="pointer"&&U.preventDefault()}e.lockScroll&&fM(u);function Z(){e.closeOnPressEscape&&T()}return Te(()=>e.modelValue,U=>{U?(c.value=!1,x(),d.value=!0,f.value=Wx(e.zIndex)?s():f.value++,ot(()=>{r("open"),t.value&&(t.value.scrollTop=0)})):u.value&&E()}),Te(()=>e.fullscreen,U=>{t.value&&(U?(i=t.value.style.transform,t.value.style.transform=""):t.value.style.transform=i)}),Ct(()=>{e.modelValue&&(u.value=!0,d.value=!0,x())}),{afterEnter:w,afterLeave:_,beforeLeave:S,handleClose:T,onModalClick:O,close:E,doClose:N,onOpenAutoFocus:F,onCloseAutoFocus:B,onCloseRequested:Z,onFocusoutPrevented:Y,titleId:l,bodyId:a,closed:c,style:y,overlayDialogStyle:v,rendered:d,visible:u,zIndex:f}},_ie=["aria-label","aria-labelledby","aria-describedby"],bie=Q({name:"ElDialog",inheritAttrs:!1}),wie=Q({...bie,props:nO,emits:oO,setup(e,{expose:t}){const n=e,o=Kr();Ua({scope:"el-dialog",from:"the title slot",replacement:"the header slot",version:"3.0.0",ref:"https://element-plus.org/en-US/component/dialog.html#slots"},R(()=>!!o.title));const r=Re("dialog"),s=K(),i=K(),l=K(),{visible:a,titleId:u,bodyId:c,style:d,overlayDialogStyle:f,rendered:p,zIndex:h,afterEnter:m,afterLeave:y,beforeLeave:v,handleClose:w,onModalClick:_,onOpenAutoFocus:S,onCloseAutoFocus:x,onCloseRequested:E,onFocusoutPrevented:T}=rO(n,s);wt(eO,{dialogRef:s,headerRef:i,bodyId:c,ns:r,rendered:p,style:d});const O=C3(_),P=R(()=>n.draggable&&!n.fullscreen);return t({visible:a,dialogContentRef:l}),(N,F)=>(C(),q(_s,{to:N.appendTo,disabled:N.appendTo!=="body"?!1:!N.appendToBody},[k(_r,{name:"dialog-fade",onAfterEnter:g(m),onAfterLeave:g(y),onBeforeLeave:g(v),persisted:""},{default:$(()=>[He(k(g(B3),{"custom-mask-event":"",mask:N.modal,"overlay-class":N.modalClass,"z-index":g(h)},{default:$(()=>[b("div",{role:"dialog","aria-modal":"true","aria-label":N.title||void 0,"aria-labelledby":N.title?void 0:g(u),"aria-describedby":g(c),class:D(`${g(r).namespace.value}-overlay-dialog`),style:Qe(g(f)),onClick:F[0]||(F[0]=(...B)=>g(O).onClick&&g(O).onClick(...B)),onMousedown:F[1]||(F[1]=(...B)=>g(O).onMousedown&&g(O).onMousedown(...B)),onMouseup:F[2]||(F[2]=(...B)=>g(O).onMouseup&&g(O).onMouseup(...B))},[k(g(j0),{loop:"",trapped:g(a),"focus-start-el":"container",onFocusAfterTrapped:g(S),onFocusAfterReleased:g(x),onFocusoutPrevented:g(T),onReleaseRequested:g(E)},{default:$(()=>[g(p)?(C(),q(yie,un({key:0,ref_key:"dialogContentRef",ref:l},N.$attrs,{center:N.center,"align-center":N.alignCenter,"close-icon":N.closeIcon,draggable:g(P),overflow:N.overflow,fullscreen:N.fullscreen,"show-close":N.showClose,title:N.title,"aria-level":N.headerAriaLevel,onClose:g(w)}),tu({header:$(()=>[N.$slots.title?he(N.$slots,"title",{key:1}):he(N.$slots,"header",{key:0,close:g(w),titleId:g(u),titleClass:g(r).e("title")})]),default:$(()=>[he(N.$slots,"default")]),_:2},[N.$slots.footer?{name:"footer",fn:$(()=>[he(N.$slots,"footer")])}:void 0]),1040,["center","align-center","close-icon","draggable","overflow","fullscreen","show-close","title","aria-level","onClose"])):W("v-if",!0)]),_:3},8,["trapped","onFocusAfterTrapped","onFocusAfterReleased","onFocusoutPrevented","onReleaseRequested"])],46,_ie)]),_:3},8,["mask","overlay-class","z-index"]),[[en,g(a)]])]),_:3},8,["onAfterEnter","onAfterLeave","onBeforeLeave"])],8,["to","disabled"]))}});var Cie=ze(wie,[["__file","dialog.vue"]]);const yh=Zt(Cie),kie=We({direction:{type:String,values:["horizontal","vertical"],default:"horizontal"},contentPosition:{type:String,values:["left","center","right"],default:"center"},borderStyle:{type:Ce(String),default:"solid"}}),Sie=Q({name:"ElDivider"}),$ie=Q({...Sie,props:kie,setup(e){const t=e,n=Re("divider"),o=R(()=>n.cssVar({"border-style":t.borderStyle}));return(r,s)=>(C(),M("div",{class:D([g(n).b(),g(n).m(r.direction)]),style:Qe(g(o)),role:"separator"},[r.$slots.default&&r.direction!=="vertical"?(C(),M("div",{key:0,class:D([g(n).e("text"),g(n).is(r.contentPosition)])},[he(r.$slots,"default")],2)):W("v-if",!0)],6))}});var Eie=ze($ie,[["__file","divider.vue"]]);const xie=Zt(Eie),Mie=We({...nO,direction:{type:String,default:"rtl",values:["ltr","rtl","ttb","btt"]},size:{type:[String,Number],default:"30%"},withHeader:{type:Boolean,default:!0},modalFade:{type:Boolean,default:!0},headerAriaLevel:{type:String,default:"2"}}),Tie=oO,Oie=["aria-label","aria-labelledby","aria-describedby"],Iie=["id","aria-level"],Aie=["aria-label"],Nie=["id"],Pie=Q({name:"ElDrawer",inheritAttrs:!1}),Lie=Q({...Pie,props:Mie,emits:Tie,setup(e,{expose:t}){const n=e,o=Kr();Ua({scope:"el-drawer",from:"the title slot",replacement:"the header slot",version:"3.0.0",ref:"https://element-plus.org/en-US/component/drawer.html#slots"},R(()=>!!o.title));const r=K(),s=K(),i=Re("drawer"),{t:l}=Kt(),{afterEnter:a,afterLeave:u,beforeLeave:c,visible:d,rendered:f,titleId:p,bodyId:h,zIndex:m,onModalClick:y,onOpenAutoFocus:v,onCloseAutoFocus:w,onFocusoutPrevented:_,onCloseRequested:S,handleClose:x}=rO(n,r),E=R(()=>n.direction==="rtl"||n.direction==="ltr"),T=R(()=>Zo(n.size));return t({handleClose:x,afterEnter:a,afterLeave:u}),(O,P)=>(C(),q(_s,{to:"body",disabled:!O.appendToBody},[k(_r,{name:g(i).b("fade"),onAfterEnter:g(a),onAfterLeave:g(u),onBeforeLeave:g(c),persisted:""},{default:$(()=>[He(k(g(B3),{mask:O.modal,"overlay-class":O.modalClass,"z-index":g(m),onClick:g(y)},{default:$(()=>[k(g(j0),{loop:"",trapped:g(d),"focus-trap-el":r.value,"focus-start-el":s.value,onFocusAfterTrapped:g(v),onFocusAfterReleased:g(w),onFocusoutPrevented:g(_),onReleaseRequested:g(S)},{default:$(()=>[b("div",un({ref_key:"drawerRef",ref:r,"aria-modal":"true","aria-label":O.title||void 0,"aria-labelledby":O.title?void 0:g(p),"aria-describedby":g(h)},O.$attrs,{class:[g(i).b(),O.direction,g(d)&&"open"],style:g(E)?"width: "+g(T):"height: "+g(T),role:"dialog",onClick:P[1]||(P[1]=et(()=>{},["stop"]))}),[b("span",{ref_key:"focusStartRef",ref:s,class:D(g(i).e("sr-focus")),tabindex:"-1"},null,2),O.withHeader?(C(),M("header",{key:0,class:D(g(i).e("header"))},[O.$slots.title?he(O.$slots,"title",{key:1},()=>[W(" DEPRECATED SLOT ")]):he(O.$slots,"header",{key:0,close:g(x),titleId:g(p),titleClass:g(i).e("title")},()=>[O.$slots.title?W("v-if",!0):(C(),M("span",{key:0,id:g(p),role:"heading","aria-level":O.headerAriaLevel,class:D(g(i).e("title"))},A(O.title),11,Iie))]),O.showClose?(C(),M("button",{key:2,"aria-label":g(l)("el.drawer.close"),class:D(g(i).e("close-btn")),type:"button",onClick:P[0]||(P[0]=(...N)=>g(x)&&g(x)(...N))},[k(g(Ne),{class:D(g(i).e("close"))},{default:$(()=>[k(g(Gs))]),_:1},8,["class"])],10,Aie)):W("v-if",!0)],2)):W("v-if",!0),g(f)?(C(),M("div",{key:1,id:g(h),class:D(g(i).e("body"))},[he(O.$slots,"default")],10,Nie)):W("v-if",!0),O.$slots.footer?(C(),M("div",{key:2,class:D(g(i).e("footer"))},[he(O.$slots,"footer")],2)):W("v-if",!0)],16,Oie)]),_:3},8,["trapped","focus-trap-el","focus-start-el","onFocusAfterTrapped","onFocusAfterReleased","onFocusoutPrevented","onReleaseRequested"])]),_:3},8,["mask","overlay-class","z-index","onClick"]),[[en,g(d)]])]),_:3},8,["name","onAfterEnter","onAfterLeave","onBeforeLeave"])],8,["disabled"]))}});var Rie=ze(Lie,[["__file","drawer.vue"]]);const Ql=Zt(Rie),Die=Q({inheritAttrs:!1});function Fie(e,t,n,o,r,s){return he(e.$slots,"default")}var Vie=ze(Die,[["render",Fie],["__file","collection.vue"]]);const Bie=Q({name:"ElCollectionItem",inheritAttrs:!1});function zie(e,t,n,o,r,s){return he(e.$slots,"default")}var jie=ze(Bie,[["render",zie],["__file","collection-item.vue"]]);const sO="data-el-collection-item",iO=e=>{const t=`El${e}Collection`,n=`${t}Item`,o=Symbol(t),r=Symbol(n),s={...Vie,name:t,setup(){const l=K(null),a=new Map;wt(o,{itemMap:a,getItems:()=>{const c=g(l);if(!c)return[];const d=Array.from(c.querySelectorAll(`[${sO}]`));return[...a.values()].sort((p,h)=>d.indexOf(p.ref)-d.indexOf(h.ref))},collectionRef:l})}},i={...jie,name:n,setup(l,{attrs:a}){const u=K(null),c=Be(o,void 0);wt(r,{collectionItemRef:u}),Ct(()=>{const d=g(u);d&&c.itemMap.set(d,{ref:d,...a})}),En(()=>{const d=g(u);c.itemMap.delete(d)})}};return{COLLECTION_INJECTION_KEY:o,COLLECTION_ITEM_INJECTION_KEY:r,ElCollection:s,ElCollectionItem:i}},Hie=We({style:{type:Ce([String,Array,Object])},currentTabId:{type:Ce(String)},defaultCurrentTabId:String,loop:Boolean,dir:{type:String,values:["ltr","rtl"],default:"ltr"},orientation:{type:Ce(String)},onBlur:Function,onFocus:Function,onMousedown:Function}),{ElCollection:Uie,ElCollectionItem:Wie,COLLECTION_INJECTION_KEY:z3,COLLECTION_ITEM_INJECTION_KEY:Kie}=iO("RovingFocusGroup"),j3=Symbol("elRovingFocusGroup"),lO=Symbol("elRovingFocusGroupItem"),qie={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"},Gie=(e,t)=>{if(t!=="rtl")return e;switch(e){case rt.right:return rt.left;case rt.left:return rt.right;default:return e}},Yie=(e,t,n)=>{const o=Gie(e.key,n);if(!(t==="vertical"&&[rt.left,rt.right].includes(o))&&!(t==="horizontal"&&[rt.up,rt.down].includes(o)))return qie[o]},Zie=(e,t)=>e.map((n,o)=>e[(o+t)%e.length]),H3=e=>{const{activeElement:t}=document;for(const n of e)if(n===t||(n.focus(),t!==document.activeElement))return},m8="currentTabIdChange",g8="rovingFocusGroup.entryFocus",Jie={bubbles:!1,cancelable:!0},Xie=Q({name:"ElRovingFocusGroupImpl",inheritAttrs:!1,props:Hie,emits:[m8,"entryFocus"],setup(e,{emit:t}){var n;const o=K((n=e.currentTabId||e.defaultCurrentTabId)!=null?n:null),r=K(!1),s=K(!1),i=K(null),{getItems:l}=Be(z3,void 0),a=R(()=>[{outline:"none"},e.style]),u=m=>{t(m8,m)},c=()=>{r.value=!0},d=Nn(m=>{var y;(y=e.onMousedown)==null||y.call(e,m)},()=>{s.value=!0}),f=Nn(m=>{var y;(y=e.onFocus)==null||y.call(e,m)},m=>{const y=!g(s),{target:v,currentTarget:w}=m;if(v===w&&y&&!g(r)){const _=new Event(g8,Jie);if(w==null||w.dispatchEvent(_),!_.defaultPrevented){const S=l().filter(P=>P.focusable),x=S.find(P=>P.active),E=S.find(P=>P.id===g(o)),O=[x,E,...S].filter(Boolean).map(P=>P.ref);H3(O)}}s.value=!1}),p=Nn(m=>{var y;(y=e.onBlur)==null||y.call(e,m)},()=>{r.value=!1}),h=(...m)=>{t("entryFocus",...m)};wt(j3,{currentTabbedId:_u(o),loop:pn(e,"loop"),tabIndex:R(()=>g(r)?-1:0),rovingFocusGroupRef:i,rovingFocusGroupRootStyle:a,orientation:pn(e,"orientation"),dir:pn(e,"dir"),onItemFocus:u,onItemShiftTab:c,onBlur:p,onFocus:f,onMousedown:d}),Te(()=>e.currentTabId,m=>{o.value=m??null}),Ln(i,g8,h)}});function Qie(e,t,n,o,r,s){return he(e.$slots,"default")}var ele=ze(Xie,[["render",Qie],["__file","roving-focus-group-impl.vue"]]);const tle=Q({name:"ElRovingFocusGroup",components:{ElFocusGroupCollection:Uie,ElRovingFocusGroupImpl:ele}});function nle(e,t,n,o,r,s){const i=re("el-roving-focus-group-impl"),l=re("el-focus-group-collection");return C(),q(l,null,{default:$(()=>[k(i,Z2(_w(e.$attrs)),{default:$(()=>[he(e.$slots,"default")]),_:3},16)]),_:3})}var ole=ze(tle,[["render",nle],["__file","roving-focus-group.vue"]]);const rle=Q({components:{ElRovingFocusCollectionItem:Wie},props:{focusable:{type:Boolean,default:!0},active:{type:Boolean,default:!1}},emits:["mousedown","focus","keydown"],setup(e,{emit:t}){const{currentTabbedId:n,loop:o,onItemFocus:r,onItemShiftTab:s}=Be(j3,void 0),{getItems:i}=Be(z3,void 0),l=Hr(),a=K(null),u=Nn(p=>{t("mousedown",p)},p=>{e.focusable?r(g(l)):p.preventDefault()}),c=Nn(p=>{t("focus",p)},()=>{r(g(l))}),d=Nn(p=>{t("keydown",p)},p=>{const{key:h,shiftKey:m,target:y,currentTarget:v}=p;if(h===rt.tab&&m){s();return}if(y!==v)return;const w=Yie(p);if(w){p.preventDefault();let S=i().filter(x=>x.focusable).map(x=>x.ref);switch(w){case"last":{S.reverse();break}case"prev":case"next":{w==="prev"&&S.reverse();const x=S.indexOf(v);S=o.value?Zie(S,x+1):S.slice(x+1);break}}ot(()=>{H3(S)})}}),f=R(()=>n.value===g(l));return wt(lO,{rovingFocusGroupItemRef:a,tabIndex:R(()=>g(f)?0:-1),handleMousedown:u,handleFocus:c,handleKeydown:d}),{id:l,handleKeydown:d,handleFocus:c,handleMousedown:u}}});function sle(e,t,n,o,r,s){const i=re("el-roving-focus-collection-item");return C(),q(i,{id:e.id,focusable:e.focusable,active:e.active},{default:$(()=>[he(e.$slots,"default")]),_:3},8,["id","focusable","active"])}var ile=ze(rle,[["render",sle],["__file","roving-focus-item.vue"]]);const o1=We({trigger:Dp.trigger,effect:{...ar.effect,default:"light"},type:{type:Ce(String)},placement:{type:Ce(String),default:"bottom"},popperOptions:{type:Ce(Object),default:()=>({})},id:String,size:{type:String,default:""},splitButton:Boolean,hideOnClick:{type:Boolean,default:!0},loop:{type:Boolean,default:!0},showTimeout:{type:Number,default:150},hideTimeout:{type:Number,default:150},tabindex:{type:Ce([Number,String]),default:0},maxHeight:{type:Ce([Number,String]),default:""},popperClass:{type:String,default:""},disabled:{type:Boolean,default:!1},role:{type:String,default:"menu"},buttonProps:{type:Ce(Object)},teleported:ar.teleported}),aO=We({command:{type:[Object,String,Number],default:()=>({})},disabled:Boolean,divided:Boolean,textValue:String,icon:{type:Oo}}),lle=We({onKeydown:{type:Ce(Function)}}),ale=[rt.down,rt.pageDown,rt.home],uO=[rt.up,rt.pageUp,rt.end],ule=[...ale,...uO],{ElCollection:cle,ElCollectionItem:dle,COLLECTION_INJECTION_KEY:fle,COLLECTION_ITEM_INJECTION_KEY:ple}=iO("Dropdown"),K0=Symbol("elDropdown"),{ButtonGroup:hle}=pt,mle=Q({name:"ElDropdown",components:{ElButton:pt,ElButtonGroup:hle,ElScrollbar:ks,ElDropdownCollection:cle,ElTooltip:$u,ElRovingFocusGroup:ole,ElOnlyChild:ZM,ElIcon:Ne,ArrowDown:Su},props:o1,emits:["visible-change","click","command"],setup(e,{emit:t}){const n=at(),o=Re("dropdown"),{t:r}=Kt(),s=K(),i=K(),l=K(null),a=K(null),u=K(null),c=K(null),d=K(!1),f=[rt.enter,rt.space,rt.down],p=R(()=>({maxHeight:Zo(e.maxHeight)})),h=R(()=>[o.m(x.value)]),m=R(()=>Eg(e.trigger)),y=Hr().value,v=R(()=>e.id||y);Te([s,m],([V,H],[L])=>{var I,X,oe;(I=L==null?void 0:L.$el)!=null&&I.removeEventListener&&L.$el.removeEventListener("pointerenter",T),(X=V==null?void 0:V.$el)!=null&&X.removeEventListener&&V.$el.removeEventListener("pointerenter",T),(oe=V==null?void 0:V.$el)!=null&&oe.addEventListener&&H.includes("hover")&&V.$el.addEventListener("pointerenter",T)},{immediate:!0}),En(()=>{var V,H;(H=(V=s.value)==null?void 0:V.$el)!=null&&H.removeEventListener&&s.value.$el.removeEventListener("pointerenter",T)});function w(){_()}function _(){var V;(V=l.value)==null||V.onClose()}function S(){var V;(V=l.value)==null||V.onOpen()}const x=Jo();function E(...V){t("command",...V)}function T(){var V,H;(H=(V=s.value)==null?void 0:V.$el)==null||H.focus()}function O(){}function P(){const V=g(a);m.value.includes("hover")&&(V==null||V.focus()),c.value=null}function N(V){c.value=V}function F(V){d.value||(V.preventDefault(),V.stopImmediatePropagation())}function B(){t("visible-change",!0)}function Y(V){(V==null?void 0:V.type)==="keydown"&&a.value.focus()}function Z(){t("visible-change",!1)}return wt(K0,{contentRef:a,role:R(()=>e.role),triggerId:v,isUsingKeyboard:d,onItemEnter:O,onItemLeave:P}),wt("elDropdown",{instance:n,dropdownSize:x,handleClick:w,commandHandler:E,trigger:pn(e,"trigger"),hideOnClick:pn(e,"hideOnClick")}),{t:r,ns:o,scrollbar:u,wrapStyle:p,dropdownTriggerKls:h,dropdownSize:x,triggerId:v,triggerKeys:f,currentTabId:c,handleCurrentTabIdChange:N,handlerMainButtonClick:V=>{t("click",V)},handleEntryFocus:F,handleClose:_,handleOpen:S,handleBeforeShowTooltip:B,handleShowTooltip:Y,handleBeforeHideTooltip:Z,onFocusAfterTrapped:V=>{var H,L;V.preventDefault(),(L=(H=a.value)==null?void 0:H.focus)==null||L.call(H,{preventScroll:!0})},popperRef:l,contentRef:a,triggeringElementRef:s,referenceElementRef:i}}});function gle(e,t,n,o,r,s){var i;const l=re("el-dropdown-collection"),a=re("el-roving-focus-group"),u=re("el-scrollbar"),c=re("el-only-child"),d=re("el-tooltip"),f=re("el-button"),p=re("arrow-down"),h=re("el-icon"),m=re("el-button-group");return C(),M("div",{class:D([e.ns.b(),e.ns.is("disabled",e.disabled)])},[k(d,{ref:"popperRef",role:e.role,effect:e.effect,"fallback-placements":["bottom","top"],"popper-options":e.popperOptions,"gpu-acceleration":!1,"hide-after":e.trigger==="hover"?e.hideTimeout:0,"manual-mode":!0,placement:e.placement,"popper-class":[e.ns.e("popper"),e.popperClass],"reference-element":(i=e.referenceElementRef)==null?void 0:i.$el,trigger:e.trigger,"trigger-keys":e.triggerKeys,"trigger-target-el":e.contentRef,"show-after":e.trigger==="hover"?e.showTimeout:0,"stop-popper-mouse-event":!1,"virtual-ref":e.triggeringElementRef,"virtual-triggering":e.splitButton,disabled:e.disabled,transition:`${e.ns.namespace.value}-zoom-in-top`,teleported:e.teleported,pure:"",persistent:"",onBeforeShow:e.handleBeforeShowTooltip,onShow:e.handleShowTooltip,onBeforeHide:e.handleBeforeHideTooltip},tu({content:$(()=>[k(u,{ref:"scrollbar","wrap-style":e.wrapStyle,tag:"div","view-class":e.ns.e("list")},{default:$(()=>[k(a,{loop:e.loop,"current-tab-id":e.currentTabId,orientation:"horizontal",onCurrentTabIdChange:e.handleCurrentTabIdChange,onEntryFocus:e.handleEntryFocus},{default:$(()=>[k(l,null,{default:$(()=>[he(e.$slots,"dropdown")]),_:3})]),_:3},8,["loop","current-tab-id","onCurrentTabIdChange","onEntryFocus"])]),_:3},8,["wrap-style","view-class"])]),_:2},[e.splitButton?void 0:{name:"default",fn:$(()=>[k(c,{id:e.triggerId,ref:"triggeringElementRef",role:"button",tabindex:e.tabindex},{default:$(()=>[he(e.$slots,"default")]),_:3},8,["id","tabindex"])])}]),1032,["role","effect","popper-options","hide-after","placement","popper-class","reference-element","trigger","trigger-keys","trigger-target-el","show-after","virtual-ref","virtual-triggering","disabled","transition","teleported","onBeforeShow","onShow","onBeforeHide"]),e.splitButton?(C(),q(m,{key:0},{default:$(()=>[k(f,un({ref:"referenceElementRef"},e.buttonProps,{size:e.dropdownSize,type:e.type,disabled:e.disabled,tabindex:e.tabindex,onClick:e.handlerMainButtonClick}),{default:$(()=>[he(e.$slots,"default")]),_:3},16,["size","type","disabled","tabindex","onClick"]),k(f,un({id:e.triggerId,ref:"triggeringElementRef"},e.buttonProps,{role:"button",size:e.dropdownSize,type:e.type,class:e.ns.e("caret-button"),disabled:e.disabled,tabindex:e.tabindex,"aria-label":e.t("el.dropdown.toggleDropdown")}),{default:$(()=>[k(h,{class:D(e.ns.e("icon"))},{default:$(()=>[k(p)]),_:1},8,["class"])]),_:1},16,["id","size","type","class","disabled","tabindex","aria-label"])]),_:3})):W("v-if",!0)],2)}var vle=ze(mle,[["render",gle],["__file","dropdown.vue"]]);const yle=Q({name:"DropdownItemImpl",components:{ElIcon:Ne},props:aO,emits:["pointermove","pointerleave","click","clickimpl"],setup(e,{emit:t}){const n=Re("dropdown"),{role:o}=Be(K0,void 0),{collectionItemRef:r}=Be(ple,void 0),{collectionItemRef:s}=Be(Kie,void 0),{rovingFocusGroupItemRef:i,tabIndex:l,handleFocus:a,handleKeydown:u,handleMousedown:c}=Be(lO,void 0),d=f3(r,s,i),f=R(()=>o.value==="menu"?"menuitem":o.value==="navigation"?"link":"button"),p=Nn(h=>{const{code:m}=h;if(m===rt.enter||m===rt.space)return h.preventDefault(),h.stopImmediatePropagation(),t("clickimpl",h),!0},u);return{ns:n,itemRef:d,dataset:{[sO]:""},role:f,tabIndex:l,handleFocus:a,handleKeydown:p,handleMousedown:c}}}),_le=["aria-disabled","tabindex","role"];function ble(e,t,n,o,r,s){const i=re("el-icon");return C(),M(fe,null,[e.divided?(C(),M("li",un({key:0,role:"separator",class:e.ns.bem("menu","item","divided")},e.$attrs),null,16)):W("v-if",!0),b("li",un({ref:e.itemRef},{...e.dataset,...e.$attrs},{"aria-disabled":e.disabled,class:[e.ns.be("menu","item"),e.ns.is("disabled",e.disabled)],tabindex:e.tabIndex,role:e.role,onClick:t[0]||(t[0]=l=>e.$emit("clickimpl",l)),onFocus:t[1]||(t[1]=(...l)=>e.handleFocus&&e.handleFocus(...l)),onKeydown:t[2]||(t[2]=et((...l)=>e.handleKeydown&&e.handleKeydown(...l),["self"])),onMousedown:t[3]||(t[3]=(...l)=>e.handleMousedown&&e.handleMousedown(...l)),onPointermove:t[4]||(t[4]=l=>e.$emit("pointermove",l)),onPointerleave:t[5]||(t[5]=l=>e.$emit("pointerleave",l))}),[e.icon?(C(),q(i,{key:0},{default:$(()=>[(C(),q(Lt(e.icon)))]),_:1})):W("v-if",!0),he(e.$slots,"default")],16,_le)],64)}var wle=ze(yle,[["render",ble],["__file","dropdown-item-impl.vue"]]);const cO=()=>{const e=Be("elDropdown",{}),t=R(()=>e==null?void 0:e.dropdownSize);return{elDropdown:e,_elDropdownSize:t}},Cle=Q({name:"ElDropdownItem",components:{ElDropdownCollectionItem:dle,ElRovingFocusItem:ile,ElDropdownItemImpl:wle},inheritAttrs:!1,props:aO,emits:["pointermove","pointerleave","click"],setup(e,{emit:t,attrs:n}){const{elDropdown:o}=cO(),r=at(),s=K(null),i=R(()=>{var p,h;return(h=(p=g(s))==null?void 0:p.textContent)!=null?h:""}),{onItemEnter:l,onItemLeave:a}=Be(K0,void 0),u=Nn(p=>(t("pointermove",p),p.defaultPrevented),b6(p=>{if(e.disabled){a(p);return}const h=p.currentTarget;h===document.activeElement||h.contains(document.activeElement)||(l(p),p.defaultPrevented||h==null||h.focus())})),c=Nn(p=>(t("pointerleave",p),p.defaultPrevented),b6(p=>{a(p)})),d=Nn(p=>{if(!e.disabled)return t("click",p),p.type!=="keydown"&&p.defaultPrevented},p=>{var h,m,y;if(e.disabled){p.stopImmediatePropagation();return}(h=o==null?void 0:o.hideOnClick)!=null&&h.value&&((m=o.handleClick)==null||m.call(o)),(y=o.commandHandler)==null||y.call(o,e.command,r,p)}),f=R(()=>({...e,...n}));return{handleClick:d,handlePointerMove:u,handlePointerLeave:c,textContent:i,propsAndAttrs:f}}});function kle(e,t,n,o,r,s){var i;const l=re("el-dropdown-item-impl"),a=re("el-roving-focus-item"),u=re("el-dropdown-collection-item");return C(),q(u,{disabled:e.disabled,"text-value":(i=e.textValue)!=null?i:e.textContent},{default:$(()=>[k(a,{focusable:!e.disabled},{default:$(()=>[k(l,un(e.propsAndAttrs,{onPointerleave:e.handlePointerLeave,onPointermove:e.handlePointerMove,onClickimpl:e.handleClick}),{default:$(()=>[he(e.$slots,"default")]),_:3},16,["onPointerleave","onPointermove","onClickimpl"])]),_:3},8,["focusable"])]),_:3},8,["disabled","text-value"])}var dO=ze(Cle,[["render",kle],["__file","dropdown-item.vue"]]);const Sle=Q({name:"ElDropdownMenu",props:lle,setup(e){const t=Re("dropdown"),{_elDropdownSize:n}=cO(),o=n.value,{focusTrapRef:r,onKeydown:s}=Be(A3,void 0),{contentRef:i,role:l,triggerId:a}=Be(K0,void 0),{collectionRef:u,getItems:c}=Be(fle,void 0),{rovingFocusGroupRef:d,rovingFocusGroupRootStyle:f,tabIndex:p,onBlur:h,onFocus:m,onMousedown:y}=Be(j3,void 0),{collectionRef:v}=Be(z3,void 0),w=R(()=>[t.b("menu"),t.bm("menu",o==null?void 0:o.value)]),_=f3(i,u,r,d,v),S=Nn(E=>{var T;(T=e.onKeydown)==null||T.call(e,E)},E=>{const{currentTarget:T,code:O,target:P}=E;if(T.contains(P),rt.tab===O&&E.stopImmediatePropagation(),E.preventDefault(),P!==g(i)||!ule.includes(O))return;const F=c().filter(B=>!B.disabled).map(B=>B.ref);uO.includes(O)&&F.reverse(),H3(F)});return{size:o,rovingFocusGroupRootStyle:f,tabIndex:p,dropdownKls:w,role:l,triggerId:a,dropdownListWrapperRef:_,handleKeydown:E=>{S(E),s(E)},onBlur:h,onFocus:m,onMousedown:y}}}),$le=["role","aria-labelledby"];function Ele(e,t,n,o,r,s){return C(),M("ul",{ref:e.dropdownListWrapperRef,class:D(e.dropdownKls),style:Qe(e.rovingFocusGroupRootStyle),tabindex:-1,role:e.role,"aria-labelledby":e.triggerId,onBlur:t[0]||(t[0]=(...i)=>e.onBlur&&e.onBlur(...i)),onFocus:t[1]||(t[1]=(...i)=>e.onFocus&&e.onFocus(...i)),onKeydown:t[2]||(t[2]=et((...i)=>e.handleKeydown&&e.handleKeydown(...i),["self"])),onMousedown:t[3]||(t[3]=et((...i)=>e.onMousedown&&e.onMousedown(...i),["self"]))},[he(e.$slots,"default")],46,$le)}var fO=ze(Sle,[["render",Ele],["__file","dropdown-menu.vue"]]);const _h=Zt(vle,{DropdownItem:dO,DropdownMenu:fO}),bh=Gn(dO),wh=Gn(fO),xle=We({urlList:{type:Ce(Array),default:()=>$o([])},zIndex:{type:Number},initialIndex:{type:Number,default:0},infinite:{type:Boolean,default:!0},hideOnClickModal:Boolean,teleported:Boolean,closeOnPressEscape:{type:Boolean,default:!0},zoomRate:{type:Number,default:1.2},minScale:{type:Number,default:.2},maxScale:{type:Number,default:7},crossorigin:{type:Ce(String)}}),Mle={close:()=>!0,switch:e=>_t(e),rotate:e=>_t(e)},Tle=["src","crossorigin"],Ole=Q({name:"ElImageViewer"}),Ile=Q({...Ole,props:xle,emits:Mle,setup(e,{expose:t,emit:n}){var o;const r=e,s={CONTAIN:{name:"contain",icon:Ii(Qx)},ORIGINAL:{name:"original",icon:Ii(ZZ)}},{t:i}=Kt(),l=Re("image-viewer"),{nextZIndex:a}=D0(),u=K(),c=K([]),d=E$(),f=K(!0),p=K(r.initialIndex),h=Tn(s.CONTAIN),m=K({scale:1,deg:0,offsetX:0,offsetY:0,enableTransition:!1}),y=K((o=r.zIndex)!=null?o:a()),v=R(()=>{const{urlList:I}=r;return I.length<=1}),w=R(()=>p.value===0),_=R(()=>p.value===r.urlList.length-1),S=R(()=>r.urlList[p.value]),x=R(()=>[l.e("btn"),l.e("prev"),l.is("disabled",!r.infinite&&w.value)]),E=R(()=>[l.e("btn"),l.e("next"),l.is("disabled",!r.infinite&&_.value)]),T=R(()=>{const{scale:I,deg:X,offsetX:oe,offsetY:z,enableTransition:ge}=m.value;let Oe=oe/I,xe=z/I;switch(X%360){case 90:case-270:[Oe,xe]=[xe,-Oe];break;case 180:case-180:[Oe,xe]=[-Oe,-xe];break;case 270:case-90:[Oe,xe]=[-xe,Oe];break}const ee={transform:`scale(${I}) rotate(${X}deg) translate(${Oe}px, ${xe}px)`,transition:ge?"transform .3s":""};return h.value.name===s.CONTAIN.name&&(ee.maxWidth=ee.maxHeight="100%"),ee});function O(){N(),n("close")}function P(){const I=Jv(oe=>{switch(oe.code){case rt.esc:r.closeOnPressEscape&&O();break;case rt.space:U();break;case rt.left:V();break;case rt.up:L("zoomIn");break;case rt.right:H();break;case rt.down:L("zoomOut");break}}),X=Jv(oe=>{const z=oe.deltaY||oe.deltaX;L(z<0?"zoomIn":"zoomOut",{zoomRate:r.zoomRate,enableTransition:!1})});d.run(()=>{Ln(document,"keydown",I),Ln(document,"wheel",X)})}function N(){d.stop()}function F(){f.value=!1}function B(I){f.value=!1,I.target.alt=i("el.image.error")}function Y(I){if(f.value||I.button!==0||!u.value)return;m.value.enableTransition=!1;const{offsetX:X,offsetY:oe}=m.value,z=I.pageX,ge=I.pageY,Oe=Jv(ee=>{m.value={...m.value,offsetX:X+ee.pageX-z,offsetY:oe+ee.pageY-ge}}),xe=Ln(document,"mousemove",Oe);Ln(document,"mouseup",()=>{xe()}),I.preventDefault()}function Z(){m.value={scale:1,deg:0,offsetX:0,offsetY:0,enableTransition:!1}}function U(){if(f.value)return;const I=G_(s),X=Object.values(s),oe=h.value.name,ge=(X.findIndex(Oe=>Oe.name===oe)+1)%I.length;h.value=s[I[ge]],Z()}function j(I){const X=r.urlList.length;p.value=(I+X)%X}function V(){w.value&&!r.infinite||j(p.value-1)}function H(){_.value&&!r.infinite||j(p.value+1)}function L(I,X={}){if(f.value)return;const{minScale:oe,maxScale:z}=r,{zoomRate:ge,rotateDeg:Oe,enableTransition:xe}={zoomRate:r.zoomRate,rotateDeg:90,enableTransition:!0,...X};switch(I){case"zoomOut":m.value.scale>oe&&(m.value.scale=Number.parseFloat((m.value.scale/ge).toFixed(3)));break;case"zoomIn":m.value.scale<z&&(m.value.scale=Number.parseFloat((m.value.scale*ge).toFixed(3)));break;case"clockwise":m.value.deg+=Oe,n("rotate",m.value.deg);break;case"anticlockwise":m.value.deg-=Oe,n("rotate",m.value.deg);break}m.value.enableTransition=xe}return Te(S,()=>{ot(()=>{const I=c.value[0];I!=null&&I.complete||(f.value=!0)})}),Te(p,I=>{Z(),n("switch",I)}),Ct(()=>{var I,X;P(),(X=(I=u.value)==null?void 0:I.focus)==null||X.call(I)}),t({setActiveItem:j}),(I,X)=>(C(),q(_s,{to:"body",disabled:!I.teleported},[k(_r,{name:"viewer-fade",appear:""},{default:$(()=>[b("div",{ref_key:"wrapper",ref:u,tabindex:-1,class:D(g(l).e("wrapper")),style:Qe({zIndex:y.value})},[b("div",{class:D(g(l).e("mask")),onClick:X[0]||(X[0]=et(oe=>I.hideOnClickModal&&O(),["self"]))},null,2),W(" CLOSE "),b("span",{class:D([g(l).e("btn"),g(l).e("close")]),onClick:O},[k(g(Ne),null,{default:$(()=>[k(g(Gs))]),_:1})],2),W(" ARROW "),g(v)?W("v-if",!0):(C(),M(fe,{key:0},[b("span",{class:D(g(x)),onClick:V},[k(g(Ne),null,{default:$(()=>[k(g(au))]),_:1})],2),b("span",{class:D(g(E)),onClick:H},[k(g(Ne),null,{default:$(()=>[k(g(js))]),_:1})],2)],64)),W(" ACTIONS "),b("div",{class:D([g(l).e("btn"),g(l).e("actions")])},[b("div",{class:D(g(l).e("actions__inner"))},[k(g(Ne),{onClick:X[1]||(X[1]=oe=>L("zoomOut"))},{default:$(()=>[k(g(fJ))]),_:1}),k(g(Ne),{onClick:X[2]||(X[2]=oe=>L("zoomIn"))},{default:$(()=>[k(g(oM))]),_:1}),b("i",{class:D(g(l).e("actions__divider"))},null,2),k(g(Ne),{onClick:U},{default:$(()=>[(C(),q(Lt(g(h).icon)))]),_:1}),b("i",{class:D(g(l).e("actions__divider"))},null,2),k(g(Ne),{onClick:X[3]||(X[3]=oe=>L("anticlockwise"))},{default:$(()=>[k(g(tM))]),_:1}),k(g(Ne),{onClick:X[4]||(X[4]=oe=>L("clockwise"))},{default:$(()=>[k(g(GZ))]),_:1})],2)],2),W(" CANVAS "),b("div",{class:D(g(l).e("canvas"))},[(C(!0),M(fe,null,nt(I.urlList,(oe,z)=>He((C(),M("img",{ref_for:!0,ref:ge=>c.value[z]=ge,key:oe,src:oe,style:Qe(g(T)),class:D(g(l).e("img")),crossorigin:I.crossorigin,onLoad:F,onError:B,onMousedown:Y},null,46,Tle)),[[en,z===p.value]])),128))],2),he(I.$slots,"default")],6)]),_:3})],8,["disabled"]))}});var Ale=ze(Ile,[["__file","image-viewer.vue"]]);const Nle=Zt(Ale),Ple=We({hideOnClickModal:Boolean,src:{type:String,default:""},fit:{type:String,values:["","contain","cover","fill","none","scale-down"],default:""},loading:{type:String,values:["eager","lazy"]},lazy:Boolean,scrollContainer:{type:Ce([String,Object])},previewSrcList:{type:Ce(Array),default:()=>$o([])},previewTeleported:Boolean,zIndex:{type:Number},initialIndex:{type:Number,default:0},infinite:{type:Boolean,default:!0},closeOnPressEscape:{type:Boolean,default:!0},zoomRate:{type:Number,default:1.2},minScale:{type:Number,default:.2},maxScale:{type:Number,default:7},crossorigin:{type:Ce(String)}}),Lle={load:e=>e instanceof Event,error:e=>e instanceof Event,switch:e=>_t(e),close:()=>!0,show:()=>!0},Rle=["src","loading","crossorigin"],Dle={key:0},Fle=Q({name:"ElImage",inheritAttrs:!1}),Vle=Q({...Fle,props:Ple,emits:Lle,setup(e,{emit:t}){const n=e;let o="";const{t:r}=Kt(),s=Re("image"),i=_d(),l=aM(),a=K(),u=K(!1),c=K(!0),d=K(!1),f=K(),p=K(),h=xt&&"loading"in HTMLImageElement.prototype;let m,y;const v=R(()=>[s.e("inner"),S.value&&s.e("preview"),c.value&&s.is("loading")]),w=R(()=>i.style),_=R(()=>{const{fit:H}=n;return xt&&H?{objectFit:H}:{}}),S=R(()=>{const{previewSrcList:H}=n;return Array.isArray(H)&&H.length>0}),x=R(()=>{const{previewSrcList:H,initialIndex:L}=n;let I=L;return L>H.length-1&&(I=0),I}),E=R(()=>n.loading==="eager"?!1:!h&&n.loading==="lazy"||n.lazy),T=()=>{xt&&(c.value=!0,u.value=!1,a.value=n.src)};function O(H){c.value=!1,u.value=!1,t("load",H)}function P(H){c.value=!1,u.value=!0,t("error",H)}function N(){fH(f.value,p.value)&&(T(),Y())}const F=Kj(N,200,!0);async function B(){var H;if(!xt)return;await ot();const{scrollContainer:L}=n;gs(L)?p.value=L:tt(L)&&L!==""?p.value=(H=document.querySelector(L))!=null?H:void 0:f.value&&(p.value=yY(f.value)),p.value&&(m=Ln(p,"scroll",F),setTimeout(()=>N(),100))}function Y(){!xt||!p.value||!F||(m==null||m(),p.value=void 0)}function Z(H){if(H.ctrlKey){if(H.deltaY<0)return H.preventDefault(),!1;if(H.deltaY>0)return H.preventDefault(),!1}}function U(){S.value&&(y=Ln("wheel",Z,{passive:!1}),o=document.body.style.overflow,document.body.style.overflow="hidden",d.value=!0,t("show"))}function j(){y==null||y(),document.body.style.overflow=o,d.value=!1,t("close")}function V(H){t("switch",H)}return Te(()=>n.src,()=>{E.value?(c.value=!0,u.value=!1,Y(),B()):T()}),Ct(()=>{E.value?B():T()}),(H,L)=>(C(),M("div",{ref_key:"container",ref:f,class:D([g(s).b(),H.$attrs.class]),style:Qe(g(w))},[u.value?he(H.$slots,"error",{key:0},()=>[b("div",{class:D(g(s).e("error"))},A(g(r)("el.image.error")),3)]):(C(),M(fe,{key:1},[a.value!==void 0?(C(),M("img",un({key:0},g(l),{src:a.value,loading:H.loading,style:g(_),class:g(v),crossorigin:H.crossorigin,onClick:U,onLoad:O,onError:P}),null,16,Rle)):W("v-if",!0),c.value?(C(),M("div",{key:1,class:D(g(s).e("wrapper"))},[he(H.$slots,"placeholder",{},()=>[b("div",{class:D(g(s).e("placeholder"))},null,2)])],2)):W("v-if",!0)],64)),g(S)?(C(),M(fe,{key:2},[d.value?(C(),q(g(Nle),{key:0,"z-index":H.zIndex,"initial-index":g(x),infinite:H.infinite,"zoom-rate":H.zoomRate,"min-scale":H.minScale,"max-scale":H.maxScale,"url-list":H.previewSrcList,"hide-on-click-modal":H.hideOnClickModal,teleported:H.previewTeleported,"close-on-press-escape":H.closeOnPressEscape,onClose:j,onSwitch:V},{default:$(()=>[H.$slots.viewer?(C(),M("div",Dle,[he(H.$slots,"viewer")])):W("v-if",!0)]),_:3},8,["z-index","initial-index","infinite","zoom-rate","min-scale","max-scale","url-list","hide-on-click-modal","teleported","close-on-press-escape"])):W("v-if",!0)],64)):W("v-if",!0)],6))}});var Ble=ze(Vle,[["__file","image.vue"]]);const Ed=Zt(Ble),zle=We({id:{type:String,default:void 0},step:{type:Number,default:1},stepStrictly:Boolean,max:{type:Number,default:Number.POSITIVE_INFINITY},min:{type:Number,default:Number.NEGATIVE_INFINITY},modelValue:Number,readonly:Boolean,disabled:Boolean,size:qr,controls:{type:Boolean,default:!0},controlsPosition:{type:String,default:"",values:["","right"]},valueOnClear:{type:[String,Number,null],validator:e=>e===null||_t(e)||["min","max"].includes(e),default:null},name:String,label:String,placeholder:String,precision:{type:Number,validator:e=>e>=0&&e===Number.parseInt(`${e}`,10)},validateEvent:{type:Boolean,default:!0}}),jle={[Cd]:(e,t)=>t!==e,blur:e=>e instanceof FocusEvent,focus:e=>e instanceof FocusEvent,[qm]:e=>_t(e)||xo(e),[Jt]:e=>_t(e)||xo(e)},Hle=["aria-label","onKeydown"],Ule=["aria-label","onKeydown"],Wle=Q({name:"ElInputNumber"}),Kle=Q({...Wle,props:zle,emits:jle,setup(e,{expose:t,emit:n}){const o=e,{t:r}=Kt(),s=Re("input-number"),i=K(),l=Dn({currentValue:o.modelValue,userInput:null}),{formItem:a}=ni(),u=R(()=>_t(o.modelValue)&&o.modelValue<=o.min),c=R(()=>_t(o.modelValue)&&o.modelValue>=o.max),d=R(()=>{const U=v(o.step);return Uo(o.precision)?Math.max(v(o.modelValue),U):(U>o.precision,o.precision)}),f=R(()=>o.controls&&o.controlsPosition==="right"),p=Jo(),h=Gr(),m=R(()=>{if(l.userInput!==null)return l.userInput;let U=l.currentValue;if(xo(U))return"";if(_t(U)){if(Number.isNaN(U))return"";Uo(o.precision)||(U=U.toFixed(o.precision))}return U}),y=(U,j)=>{if(Uo(j)&&(j=d.value),j===0)return Math.round(U);let V=String(U);const H=V.indexOf(".");if(H===-1||!V.replace(".","").split("")[H+j])return U;const X=V.length;return V.charAt(X-1)==="5"&&(V=`${V.slice(0,Math.max(0,X-1))}6`),Number.parseFloat(Number(V).toFixed(j))},v=U=>{if(xo(U))return 0;const j=U.toString(),V=j.indexOf(".");let H=0;return V!==-1&&(H=j.length-V-1),H},w=(U,j=1)=>_t(U)?y(U+o.step*j):l.currentValue,_=()=>{if(o.readonly||h.value||c.value)return;const U=Number(m.value)||0,j=w(U);E(j),n(qm,l.currentValue),Y()},S=()=>{if(o.readonly||h.value||u.value)return;const U=Number(m.value)||0,j=w(U,-1);E(j),n(qm,l.currentValue),Y()},x=(U,j)=>{const{max:V,min:H,step:L,precision:I,stepStrictly:X,valueOnClear:oe}=o;V<H&&ws("InputNumber","min should not be greater than max.");let z=Number(U);if(xo(U)||Number.isNaN(z))return null;if(U===""){if(oe===null)return null;z=tt(oe)?{min:H,max:V}[oe]:oe}return X&&(z=y(Math.round(z/L)*L,I)),Uo(I)||(z=y(z,I)),(z>V||z<H)&&(z=z>V?V:H,j&&n(Jt,z)),z},E=(U,j=!0)=>{var V;const H=l.currentValue,L=x(U);if(!j){n(Jt,L);return}H===L&&U||(l.userInput=null,n(Jt,L),H!==L&&n(Cd,L,H),o.validateEvent&&((V=a==null?void 0:a.validate)==null||V.call(a,"change").catch(I=>void 0)),l.currentValue=L)},T=U=>{l.userInput=U;const j=U===""?null:Number(U);n(qm,j),E(j,!1)},O=U=>{const j=U!==""?Number(U):"";(_t(j)&&!Number.isNaN(j)||U==="")&&E(j),Y(),l.userInput=null},P=()=>{var U,j;(j=(U=i.value)==null?void 0:U.focus)==null||j.call(U)},N=()=>{var U,j;(j=(U=i.value)==null?void 0:U.blur)==null||j.call(U)},F=U=>{n("focus",U)},B=U=>{var j;l.userInput=null,n("blur",U),o.validateEvent&&((j=a==null?void 0:a.validate)==null||j.call(a,"blur").catch(V=>void 0))},Y=()=>{l.currentValue!==o.modelValue&&(l.currentValue=o.modelValue)},Z=U=>{document.activeElement===U.target&&U.preventDefault()};return Te(()=>o.modelValue,(U,j)=>{const V=x(U,!0);l.userInput===null&&V!==j&&(l.currentValue=V)},{immediate:!0}),Ct(()=>{var U;const{min:j,max:V,modelValue:H}=o,L=(U=i.value)==null?void 0:U.input;if(L.setAttribute("role","spinbutton"),Number.isFinite(V)?L.setAttribute("aria-valuemax",String(V)):L.removeAttribute("aria-valuemax"),Number.isFinite(j)?L.setAttribute("aria-valuemin",String(j)):L.removeAttribute("aria-valuemin"),L.setAttribute("aria-valuenow",l.currentValue||l.currentValue===0?String(l.currentValue):""),L.setAttribute("aria-disabled",String(h.value)),!_t(H)&&H!=null){let I=Number(H);Number.isNaN(I)&&(I=null),n(Jt,I)}}),Fi(()=>{var U,j;const V=(U=i.value)==null?void 0:U.input;V==null||V.setAttribute("aria-valuenow",`${(j=l.currentValue)!=null?j:""}`)}),t({focus:P,blur:N}),(U,j)=>(C(),M("div",{class:D([g(s).b(),g(s).m(g(p)),g(s).is("disabled",g(h)),g(s).is("without-controls",!U.controls),g(s).is("controls-right",g(f))]),onDragstart:j[0]||(j[0]=et(()=>{},["prevent"]))},[U.controls?He((C(),M("span",{key:0,role:"button","aria-label":g(r)("el.inputNumber.decrease"),class:D([g(s).e("decrease"),g(s).is("disabled",g(u))]),onKeydown:Pt(S,["enter"])},[he(U.$slots,"decrease-icon",{},()=>[k(g(Ne),null,{default:$(()=>[g(f)?(C(),q(g(Su),{key:0})):(C(),q(g(TZ),{key:1}))]),_:1})])],42,Hle)),[[g(Rg),S]]):W("v-if",!0),U.controls?He((C(),M("span",{key:1,role:"button","aria-label":g(r)("el.inputNumber.increase"),class:D([g(s).e("increase"),g(s).is("disabled",g(c))]),onKeydown:Pt(_,["enter"])},[he(U.$slots,"increase-icon",{},()=>[k(g(Ne),null,{default:$(()=>[g(f)?(C(),q(g(N0),{key:0})):(C(),q(g(u3),{key:1}))]),_:1})])],42,Ule)),[[g(Rg),_]]):W("v-if",!0),k(g(At),{id:U.id,ref_key:"input",ref:i,type:"number",step:U.step,"model-value":g(m),placeholder:U.placeholder,readonly:U.readonly,disabled:g(h),size:g(p),max:U.max,min:U.min,name:U.name,label:U.label,"validate-event":!1,onWheel:Z,onKeydown:[Pt(et(_,["prevent"]),["up"]),Pt(et(S,["prevent"]),["down"])],onBlur:B,onFocus:F,onInput:T,onChange:O},null,8,["id","step","model-value","placeholder","readonly","disabled","size","max","min","name","label","onKeydown"])],34))}});var qle=ze(Kle,[["__file","input-number.vue"]]);const Gle=Zt(qle),pO=Symbol("elPaginationKey"),Yle=We({disabled:Boolean,currentPage:{type:Number,default:1},prevText:{type:String},prevIcon:{type:Oo}}),Zle={click:e=>e instanceof MouseEvent},Jle=["disabled","aria-label","aria-disabled"],Xle={key:0},Qle=Q({name:"ElPaginationPrev"}),eae=Q({...Qle,props:Yle,emits:Zle,setup(e){const t=e,{t:n}=Kt(),o=R(()=>t.disabled||t.currentPage<=1);return(r,s)=>(C(),M("button",{type:"button",class:"btn-prev",disabled:g(o),"aria-label":r.prevText||g(n)("el.pagination.prev"),"aria-disabled":g(o),onClick:s[0]||(s[0]=i=>r.$emit("click",i))},[r.prevText?(C(),M("span",Xle,A(r.prevText),1)):(C(),q(g(Ne),{key:1},{default:$(()=>[(C(),q(Lt(r.prevIcon)))]),_:1}))],8,Jle))}});var tae=ze(eae,[["__file","prev.vue"]]);const nae=We({disabled:Boolean,currentPage:{type:Number,default:1},pageCount:{type:Number,default:50},nextText:{type:String},nextIcon:{type:Oo}}),oae=["disabled","aria-label","aria-disabled"],rae={key:0},sae=Q({name:"ElPaginationNext"}),iae=Q({...sae,props:nae,emits:["click"],setup(e){const t=e,{t:n}=Kt(),o=R(()=>t.disabled||t.currentPage===t.pageCount||t.pageCount===0);return(r,s)=>(C(),M("button",{type:"button",class:"btn-next",disabled:g(o),"aria-label":r.nextText||g(n)("el.pagination.next"),"aria-disabled":g(o),onClick:s[0]||(s[0]=i=>r.$emit("click",i))},[r.nextText?(C(),M("span",rae,A(r.nextText),1)):(C(),q(g(Ne),{key:1},{default:$(()=>[(C(),q(Lt(r.nextIcon)))]),_:1}))],8,oae))}});var lae=ze(iae,[["__file","next.vue"]]);const hO=Symbol("ElSelectGroup"),q0=Symbol("ElSelect");function aae(e,t){const n=Be(q0),o=Be(hO,{disabled:!1}),r=R(()=>n.props.multiple?c(n.props.modelValue,e.value):c([n.props.modelValue],e.value)),s=R(()=>{if(n.props.multiple){const p=n.props.modelValue||[];return!r.value&&p.length>=n.props.multipleLimit&&n.props.multipleLimit>0}else return!1}),i=R(()=>e.label||(ft(e.value)?"":e.value)),l=R(()=>e.value||e.label||""),a=R(()=>e.disabled||t.groupDisabled||s.value),u=at(),c=(p=[],h)=>{if(ft(e.value)){const m=n.props.valueKey;return p&&p.some(y=>Mt(Tr(y,m))===Tr(h,m))}else return p&&p.includes(h)},d=()=>{!e.disabled&&!o.disabled&&(n.states.hoveringIndex=n.optionsArray.indexOf(u.proxy))},f=p=>{const h=new RegExp(hY(p),"i");t.visible=h.test(i.value)||e.created};return Te(()=>i.value,()=>{!e.created&&!n.props.remote&&n.setSelected()}),Te(()=>e.value,(p,h)=>{const{remote:m,valueKey:y}=n.props;if(jl(p,h)||(n.onOptionDestroy(h,u.proxy),n.onOptionCreate(u.proxy)),!e.created&&!m){if(y&&ft(p)&&ft(h)&&p[y]===h[y])return;n.setSelected()}}),Te(()=>o.disabled,()=>{t.groupDisabled=o.disabled},{immediate:!0}),{select:n,currentLabel:i,currentValue:l,itemSelected:r,isDisabled:a,hoverItem:d,updateOption:f}}const uae=Q({name:"ElOption",componentName:"ElOption",props:{value:{required:!0,type:[String,Number,Boolean,Object]},label:[String,Number],created:Boolean,disabled:Boolean},setup(e){const t=Re("select"),n=Hr(),o=R(()=>[t.be("dropdown","item"),t.is("disabled",g(l)),t.is("selected",g(i)),t.is("hovering",g(f))]),r=Dn({index:-1,groupDisabled:!1,visible:!0,hover:!1}),{currentLabel:s,itemSelected:i,isDisabled:l,select:a,hoverItem:u,updateOption:c}=aae(e,r),{visible:d,hover:f}=ei(r),p=at().proxy;a.onOptionCreate(p),En(()=>{const m=p.value,{selected:y}=a.states,w=(a.props.multiple?y:[y]).some(_=>_.value===p.value);ot(()=>{a.states.cachedOptions.get(m)===p&&!w&&a.states.cachedOptions.delete(m)}),a.onOptionDestroy(m,p)});function h(){e.disabled!==!0&&r.groupDisabled!==!0&&a.handleOptionSelect(p)}return{ns:t,id:n,containerKls:o,currentLabel:s,itemSelected:i,isDisabled:l,select:a,hoverItem:u,updateOption:c,visible:d,hover:f,selectOptionClick:h,states:r}}}),cae=["id","aria-disabled","aria-selected"];function dae(e,t,n,o,r,s){return He((C(),M("li",{id:e.id,class:D(e.containerKls),role:"option","aria-disabled":e.isDisabled||void 0,"aria-selected":e.itemSelected,onMouseenter:t[0]||(t[0]=(...i)=>e.hoverItem&&e.hoverItem(...i)),onClick:t[1]||(t[1]=et((...i)=>e.selectOptionClick&&e.selectOptionClick(...i),["stop"]))},[he(e.$slots,"default",{},()=>[b("span",null,A(e.currentLabel),1)])],42,cae)),[[en,e.visible]])}var U3=ze(uae,[["render",dae],["__file","option.vue"]]);const fae=Q({name:"ElSelectDropdown",componentName:"ElSelectDropdown",setup(){const e=Be(q0),t=Re("select"),n=R(()=>e.props.popperClass),o=R(()=>e.props.multiple),r=R(()=>e.props.fitInputWidth),s=K("");function i(){var l;s.value=`${(l=e.selectRef)==null?void 0:l.offsetWidth}px`}return Ct(()=>{i(),Bo(e.selectRef,i)}),{ns:t,minWidth:s,popperClass:n,isMultiple:o,isFitInputWidth:r}}});function pae(e,t,n,o,r,s){return C(),M("div",{class:D([e.ns.b("dropdown"),e.ns.is("multiple",e.isMultiple),e.popperClass]),style:Qe({[e.isFitInputWidth?"width":"minWidth"]:e.minWidth})},[e.$slots.header?(C(),M("div",{key:0,class:D(e.ns.be("dropdown","header"))},[he(e.$slots,"header")],2)):W("v-if",!0),he(e.$slots,"default"),e.$slots.footer?(C(),M("div",{key:1,class:D(e.ns.be("dropdown","footer"))},[he(e.$slots,"footer")],2)):W("v-if",!0)],6)}var hae=ze(fae,[["render",pae],["__file","select-dropdown.vue"]]);function mae(e){const t=K(!1);return{handleCompositionStart:()=>{t.value=!0},handleCompositionUpdate:s=>{const i=s.target.value,l=i[i.length-1]||"";t.value=!lM(l)},handleCompositionEnd:s=>{t.value&&(t.value=!1,Xe(e)&&e(s))}}}const gae=11,vae=(e,t)=>{const{t:n}=Kt(),o=Hr(),r=Re("select"),s=Re("input"),i=Dn({inputValue:"",options:new Map,cachedOptions:new Map,disabledOptions:new Map,optionValues:[],selected:e.multiple?[]:{},selectionWidth:0,calculatorWidth:0,collapseItemWidth:0,selectedLabel:"",hoveringIndex:-1,previousQuery:null,inputHovering:!1,menuVisibleOnFocus:!1,isBeforeHide:!1}),l=K(null),a=K(null),u=K(null),c=K(null),d=K(null),f=K(null),p=K(null),h=K(null),m=K(null),y=K(null),v=K(null),w=K(null),{wrapperRef:_,isFocused:S,handleFocus:x,handleBlur:E}=x3(d,{afterFocus(){e.automaticDropdown&&!T.value&&(T.value=!0,i.menuVisibleOnFocus=!0)},beforeBlur(be){var Ke,tn;return((Ke=u.value)==null?void 0:Ke.isFocusInsideContent(be))||((tn=c.value)==null?void 0:tn.isFocusInsideContent(be))},afterBlur(){T.value=!1,i.menuVisibleOnFocus=!1}}),T=K(!1),O=K(),{form:P,formItem:N}=ni(),{inputId:F}=Sd(e,{formItemContext:N}),{valueOnClear:B,isEmptyValue:Y}=HM(e),Z=R(()=>e.disabled||(P==null?void 0:P.disabled)),U=R(()=>e.multiple?Me(e.modelValue)&&e.modelValue.length>0:!Y(e.modelValue)),j=R(()=>e.clearable&&!Z.value&&i.inputHovering&&U.value),V=R(()=>e.remote&&e.filterable&&!e.remoteShowSuffix?"":e.suffixIcon),H=R(()=>r.is("reverse",V.value&&T.value)),L=R(()=>(N==null?void 0:N.validateState)||""),I=R(()=>iM[L.value]),X=R(()=>e.remote?300:0),oe=R(()=>e.loading?e.loadingText||n("el.select.loading"):e.remote&&!i.inputValue&&i.options.size===0?!1:e.filterable&&i.inputValue&&i.options.size>0&&z.value===0?e.noMatchText||n("el.select.noMatch"):i.options.size===0?e.noDataText||n("el.select.noData"):null),z=R(()=>ge.value.filter(be=>be.visible).length),ge=R(()=>{const be=Array.from(i.options.values()),Ke=[];return i.optionValues.forEach(tn=>{const Mn=be.findIndex(Ui=>Ui.value===tn);Mn>-1&&Ke.push(be[Mn])}),Ke.length>=be.length?Ke:be}),Oe=R(()=>Array.from(i.cachedOptions.values())),xe=R(()=>{const be=ge.value.filter(Ke=>!Ke.created).some(Ke=>Ke.currentLabel===i.inputValue);return e.filterable&&e.allowCreate&&i.inputValue!==""&&!be}),ee=()=>{e.filterable&&Xe(e.filterMethod)||e.filterable&&e.remote&&Xe(e.remoteMethod)||ge.value.forEach(be=>{var Ke;(Ke=be.updateOption)==null||Ke.call(be,i.inputValue)})},de=Jo(),ve=R(()=>["small"].includes(de.value)?"small":"default"),le=R({get(){return T.value&&oe.value!==!1},set(be){T.value=be}}),Ie=R(()=>Me(e.modelValue)?e.modelValue.length===0&&!i.inputValue:e.filterable?!i.inputValue:!0),Ge=R(()=>{var be;const Ke=(be=e.placeholder)!=null?be:n("el.select.placeholder");return e.multiple||!U.value?Ke:i.selectedLabel});Te(()=>e.modelValue,(be,Ke)=>{e.multiple&&e.filterable&&!e.reserveKeyword&&(i.inputValue="",G("")),ue(),!jl(be,Ke)&&e.validateEvent&&(N==null||N.validate("change").catch(tn=>void 0))},{flush:"post",deep:!0}),Te(()=>T.value,be=>{be?G(i.inputValue):(i.inputValue="",i.previousQuery=null,i.isBeforeHide=!0),t("visible-change",be)}),Te(()=>i.options.entries(),()=>{var be;if(!xt)return;const Ke=((be=l.value)==null?void 0:be.querySelectorAll("input"))||[];(!e.filterable&&!e.defaultFirstOption&&!Uo(e.modelValue)||!Array.from(Ke).includes(document.activeElement))&&ue(),e.defaultFirstOption&&(e.filterable||e.remote)&&z.value&&J()},{flush:"post"}),Te(()=>i.hoveringIndex,be=>{_t(be)&&be>-1?O.value=ge.value[be]||{}:O.value={},ge.value.forEach(Ke=>{Ke.hover=O.value===Ke})}),ls(()=>{i.isBeforeHide||ee()});const G=be=>{i.previousQuery!==be&&(i.previousQuery=be,e.filterable&&Xe(e.filterMethod)?e.filterMethod(be):e.filterable&&e.remote&&Xe(e.remoteMethod)&&e.remoteMethod(be),e.defaultFirstOption&&(e.filterable||e.remote)&&z.value?ot(J):ot(ye))},J=()=>{const be=ge.value.filter(Mn=>Mn.visible&&!Mn.disabled&&!Mn.states.groupDisabled),Ke=be.find(Mn=>Mn.created),tn=be[0];i.hoveringIndex=we(ge.value,Ke||tn)},ue=()=>{if(e.multiple)i.selectedLabel="";else{const Ke=_e(e.modelValue);i.selectedLabel=Ke.currentLabel,i.selected=Ke;return}const be=[];Me(e.modelValue)&&e.modelValue.forEach(Ke=>{be.push(_e(Ke))}),i.selected=be},_e=be=>{let Ke;const tn=Fm(be).toLowerCase()==="object",Mn=Fm(be).toLowerCase()==="null",Ui=Fm(be).toLowerCase()==="undefined";for(let la=i.cachedOptions.size-1;la>=0;la--){const Es=Oe.value[la];if(tn?Tr(Es.value,e.valueKey)===Tr(be,e.valueKey):Es.value===be){Ke={value:be,currentLabel:Es.currentLabel,isDisabled:Es.isDisabled};break}}if(Ke)return Ke;const Iu=tn?be.label:!Mn&&!Ui?be:"";return{value:be,currentLabel:Iu}},ye=()=>{e.multiple?i.hoveringIndex=ge.value.findIndex(be=>i.selected.some(Ke=>Vd(Ke)===Vd(be))):i.hoveringIndex=ge.value.findIndex(be=>Vd(be)===Vd(i.selected))},Ae=()=>{i.selectionWidth=a.value.getBoundingClientRect().width},Le=()=>{i.calculatorWidth=f.value.getBoundingClientRect().width},Ee=()=>{i.collapseItemWidth=v.value.getBoundingClientRect().width},Pe=()=>{var be,Ke;(Ke=(be=u.value)==null?void 0:be.updatePopper)==null||Ke.call(be)},me=()=>{var be,Ke;(Ke=(be=c.value)==null?void 0:be.updatePopper)==null||Ke.call(be)},je=()=>{i.inputValue.length>0&&!T.value&&(T.value=!0),G(i.inputValue)},Ze=be=>{if(i.inputValue=be.target.value,e.remote)ce();else return je()},ce=zl(()=>{je()},X.value),te=be=>{jl(e.modelValue,be)||t(Cd,be)},pe=be=>eY(be,Ke=>!i.disabledOptions.has(Ke)),Ve=be=>{if(e.multiple&&be.code!==rt.delete&&be.target.value.length<=0){const Ke=e.modelValue.slice(),tn=pe(Ke);if(tn<0)return;Ke.splice(tn,1),t(Jt,Ke),te(Ke)}},Je=(be,Ke)=>{const tn=i.selected.indexOf(Ke);if(tn>-1&&!Z.value){const Mn=e.modelValue.slice();Mn.splice(tn,1),t(Jt,Mn),te(Mn),t("remove-tag",Ke.value)}be.stopPropagation(),Un()},$e=be=>{be.stopPropagation();const Ke=e.multiple?[]:B.value;if(e.multiple)for(const tn of i.selected)tn.isDisabled&&Ke.push(tn.value);t(Jt,Ke),te(Ke),i.hoveringIndex=-1,T.value=!1,t("clear"),Un()},ie=be=>{if(e.multiple){const Ke=(e.modelValue||[]).slice(),tn=we(Ke,be.value);tn>-1?Ke.splice(tn,1):(e.multipleLimit<=0||Ke.length<e.multipleLimit)&&Ke.push(be.value),t(Jt,Ke),te(Ke),be.created&&G(""),e.filterable&&!e.reserveKeyword&&(i.inputValue="")}else t(Jt,be.value),te(be.value),T.value=!1;Un(),!T.value&&ot(()=>{ae(be)})},we=(be=[],Ke)=>{if(!ft(Ke))return be.indexOf(Ke);const tn=e.valueKey;let Mn=-1;return be.some((Ui,Iu)=>Mt(Tr(Ui,tn))===Tr(Ke,tn)?(Mn=Iu,!0):!1),Mn},ae=be=>{var Ke,tn,Mn,Ui,Iu;const Uh=Me(be)?be[0]:be;let la=null;if(Uh!=null&&Uh.value){const Es=ge.value.filter(Gk=>Gk.value===Uh.value);Es.length>0&&(la=Es[0].$el)}if(u.value&&la){const Es=(Ui=(Mn=(tn=(Ke=u.value)==null?void 0:Ke.popperRef)==null?void 0:tn.contentRef)==null?void 0:Mn.querySelector)==null?void 0:Ui.call(Mn,`.${r.be("dropdown","wrap")}`);Es&&bY(Es,la)}(Iu=w.value)==null||Iu.handleScroll()},Se=be=>{i.options.set(be.value,be),i.cachedOptions.set(be.value,be),be.disabled&&i.disabledOptions.set(be.value,be)},Fe=(be,Ke)=>{i.options.get(be)===Ke&&i.options.delete(be)},{handleCompositionStart:st,handleCompositionUpdate:se,handleCompositionEnd:De}=mae(be=>Ze(be)),Ot=R(()=>{var be,Ke;return(Ke=(be=u.value)==null?void 0:be.popperRef)==null?void 0:Ke.contentRef}),mn=()=>{i.isBeforeHide=!1,ot(()=>ae(i.selected))},Un=()=>{var be;(be=d.value)==null||be.focus()},Zr=()=>{nr()},qt=be=>{$e(be)},nr=be=>{if(T.value=!1,S.value){const Ke=new FocusEvent("focus",be);ot(()=>E(Ke))}},pR=()=>{i.inputValue.length>0?i.inputValue="":T.value=!1},Kk=()=>{Z.value||(i.menuVisibleOnFocus?i.menuVisibleOnFocus=!1:T.value=!T.value)},hR=()=>{T.value?ge.value[i.hoveringIndex]&&ie(ge.value[i.hoveringIndex]):Kk()},Vd=be=>ft(be.value)?Tr(be.value,e.valueKey):be.value,mR=R(()=>ge.value.filter(be=>be.visible).every(be=>be.disabled)),gR=R(()=>e.multiple?e.collapseTags?i.selected.slice(0,e.maxCollapseTags):i.selected:[]),vR=R(()=>e.multiple?e.collapseTags?i.selected.slice(e.maxCollapseTags):[]:[]),qk=be=>{if(!T.value){T.value=!0;return}if(!(i.options.size===0||z.value===0)&&!mR.value){be==="next"?(i.hoveringIndex++,i.hoveringIndex===i.options.size&&(i.hoveringIndex=0)):be==="prev"&&(i.hoveringIndex--,i.hoveringIndex<0&&(i.hoveringIndex=i.options.size-1));const Ke=ge.value[i.hoveringIndex];(Ke.disabled===!0||Ke.states.groupDisabled===!0||!Ke.visible)&&qk(be),ot(()=>ae(O.value))}},yR=()=>{if(!a.value)return 0;const be=window.getComputedStyle(a.value);return Number.parseFloat(be.gap||"6px")},_R=R(()=>{const be=yR();return{maxWidth:`${v.value&&e.maxCollapseTags===1?i.selectionWidth-i.collapseItemWidth-be:i.selectionWidth}px`}}),bR=R(()=>({maxWidth:`${i.selectionWidth}px`})),wR=R(()=>({width:`${Math.max(i.calculatorWidth,gae)}px`}));return e.multiple&&!Me(e.modelValue)&&t(Jt,[]),!e.multiple&&Me(e.modelValue)&&t(Jt,""),Bo(a,Ae),Bo(f,Le),Bo(m,Pe),Bo(_,Pe),Bo(y,me),Bo(v,Ee),Ct(()=>{ue()}),{inputId:F,contentId:o,nsSelect:r,nsInput:s,states:i,isFocused:S,expanded:T,optionsArray:ge,hoverOption:O,selectSize:de,filteredOptionsCount:z,resetCalculatorWidth:Le,updateTooltip:Pe,updateTagTooltip:me,debouncedOnInputChange:ce,onInput:Ze,deletePrevTag:Ve,deleteTag:Je,deleteSelected:$e,handleOptionSelect:ie,scrollToOption:ae,hasModelValue:U,shouldShowPlaceholder:Ie,currentPlaceholder:Ge,showClose:j,iconComponent:V,iconReverse:H,validateState:L,validateIcon:I,showNewOption:xe,updateOptions:ee,collapseTagSize:ve,setSelected:ue,selectDisabled:Z,emptyText:oe,handleCompositionStart:st,handleCompositionUpdate:se,handleCompositionEnd:De,onOptionCreate:Se,onOptionDestroy:Fe,handleMenuEnter:mn,handleFocus:x,focus:Un,blur:Zr,handleBlur:E,handleClearClick:qt,handleClickOutside:nr,handleEsc:pR,toggleMenu:Kk,selectOption:hR,getValueKey:Vd,navigateOptions:qk,dropdownMenuVisible:le,showTagList:gR,collapseTagList:vR,tagStyle:_R,collapseTagStyle:bR,inputStyle:wR,popperRef:Ot,inputRef:d,tooltipRef:u,tagTooltipRef:c,calculatorRef:f,prefixRef:p,suffixRef:h,selectRef:l,wrapperRef:_,selectionRef:a,scrollbarRef:w,menuRef:m,tagMenuRef:y,collapseItemRef:v}};var yae=Q({name:"ElOptions",setup(e,{slots:t}){const n=Be(q0);let o=[];return()=>{var r,s;const i=(r=t.default)==null?void 0:r.call(t),l=[];function a(u){Me(u)&&u.forEach(c=>{var d,f,p,h;const m=(d=(c==null?void 0:c.type)||{})==null?void 0:d.name;m==="ElOptionGroup"?a(!tt(c.children)&&!Me(c.children)&&Xe((f=c.children)==null?void 0:f.default)?(p=c.children)==null?void 0:p.default():c.children):m==="ElOption"?l.push((h=c.props)==null?void 0:h.value):Me(c.children)&&a(c.children)})}return i.length&&a((s=i[0])==null?void 0:s.children),jl(l,o)||(o=l,n&&(n.states.optionValues=l)),i}}});const _ae=We({name:String,id:String,modelValue:{type:[Array,String,Number,Boolean,Object],default:void 0},autocomplete:{type:String,default:"off"},automaticDropdown:Boolean,size:qr,effect:{type:Ce(String),default:"light"},disabled:Boolean,clearable:Boolean,filterable:Boolean,allowCreate:Boolean,loading:Boolean,popperClass:{type:String,default:""},popperOptions:{type:Ce(Object),default:()=>({})},remote:Boolean,loadingText:String,noMatchText:String,noDataText:String,remoteMethod:Function,filterMethod:Function,multiple:Boolean,multipleLimit:{type:Number,default:0},placeholder:{type:String},defaultFirstOption:Boolean,reserveKeyword:{type:Boolean,default:!0},valueKey:{type:String,default:"value"},collapseTags:Boolean,collapseTagsTooltip:Boolean,maxCollapseTags:{type:Number,default:1},teleported:ar.teleported,persistent:{type:Boolean,default:!0},clearIcon:{type:Oo,default:wd},fitInputWidth:Boolean,suffixIcon:{type:Oo,default:Su},tagType:{...PT.type,default:"info"},validateEvent:{type:Boolean,default:!0},remoteShowSuffix:Boolean,placement:{type:Ce(String),values:L0,default:"bottom-start"},fallbackPlacements:{type:Ce(Array),default:["bottom-start","top-start","right","left"]},ariaLabel:{type:String,default:void 0},...M3}),v8="ElSelect",bae=Q({name:v8,componentName:v8,components:{ElInput:At,ElSelectMenu:hae,ElOption:U3,ElOptions:yae,ElTag:mh,ElScrollbar:ks,ElTooltip:$u,ElIcon:Ne},directives:{ClickOutside:id},props:_ae,emits:[Jt,Cd,"remove-tag","clear","visible-change","focus","blur"],setup(e,{emit:t}){const n=vae(e,t);return wt(q0,Dn({props:e,states:n.states,optionsArray:n.optionsArray,handleOptionSelect:n.handleOptionSelect,onOptionCreate:n.onOptionCreate,onOptionDestroy:n.onOptionDestroy,selectRef:n.selectRef,setSelected:n.setSelected})),{...n}}}),wae=["id","disabled","autocomplete","readonly","aria-activedescendant","aria-controls","aria-expanded","aria-label"],Cae=["textContent"];function kae(e,t,n,o,r,s){const i=re("el-tag"),l=re("el-tooltip"),a=re("el-icon"),u=re("el-option"),c=re("el-options"),d=re("el-scrollbar"),f=re("el-select-menu"),p=zt("click-outside");return He((C(),M("div",{ref:"selectRef",class:D([e.nsSelect.b(),e.nsSelect.m(e.selectSize)]),onMouseenter:t[16]||(t[16]=h=>e.states.inputHovering=!0),onMouseleave:t[17]||(t[17]=h=>e.states.inputHovering=!1),onClick:t[18]||(t[18]=et((...h)=>e.toggleMenu&&e.toggleMenu(...h),["prevent","stop"]))},[k(l,{ref:"tooltipRef",visible:e.dropdownMenuVisible,placement:e.placement,teleported:e.teleported,"popper-class":[e.nsSelect.e("popper"),e.popperClass],"popper-options":e.popperOptions,"fallback-placements":e.fallbackPlacements,effect:e.effect,pure:"",trigger:"click",transition:`${e.nsSelect.namespace.value}-zoom-in-top`,"stop-popper-mouse-event":!1,"gpu-acceleration":!1,persistent:e.persistent,onBeforeShow:e.handleMenuEnter,onHide:t[15]||(t[15]=h=>e.states.isBeforeHide=!1)},{default:$(()=>{var h;return[b("div",{ref:"wrapperRef",class:D([e.nsSelect.e("wrapper"),e.nsSelect.is("focused",e.isFocused),e.nsSelect.is("hovering",e.states.inputHovering),e.nsSelect.is("filterable",e.filterable),e.nsSelect.is("disabled",e.selectDisabled)])},[e.$slots.prefix?(C(),M("div",{key:0,ref:"prefixRef",class:D(e.nsSelect.e("prefix"))},[he(e.$slots,"prefix")],2)):W("v-if",!0),b("div",{ref:"selectionRef",class:D([e.nsSelect.e("selection"),e.nsSelect.is("near",e.multiple&&!e.$slots.prefix&&!!e.states.selected.length)])},[e.multiple?he(e.$slots,"tag",{key:0},()=>[(C(!0),M(fe,null,nt(e.showTagList,m=>(C(),M("div",{key:e.getValueKey(m),class:D(e.nsSelect.e("selected-item"))},[k(i,{closable:!e.selectDisabled&&!m.isDisabled,size:e.collapseTagSize,type:e.tagType,"disable-transitions":"",style:Qe(e.tagStyle),onClose:y=>e.deleteTag(y,m)},{default:$(()=>[b("span",{class:D(e.nsSelect.e("tags-text"))},A(m.currentLabel),3)]),_:2},1032,["closable","size","type","style","onClose"])],2))),128)),e.collapseTags&&e.states.selected.length>e.maxCollapseTags?(C(),q(l,{key:0,ref:"tagTooltipRef",disabled:e.dropdownMenuVisible||!e.collapseTagsTooltip,"fallback-placements":["bottom","top","right","left"],effect:e.effect,placement:"bottom",teleported:e.teleported},{default:$(()=>[b("div",{ref:"collapseItemRef",class:D(e.nsSelect.e("selected-item"))},[k(i,{closable:!1,size:e.collapseTagSize,type:e.tagType,"disable-transitions":"",style:Qe(e.collapseTagStyle)},{default:$(()=>[b("span",{class:D(e.nsSelect.e("tags-text"))}," + "+A(e.states.selected.length-e.maxCollapseTags),3)]),_:1},8,["size","type","style"])],2)]),content:$(()=>[b("div",{ref:"tagMenuRef",class:D(e.nsSelect.e("selection"))},[(C(!0),M(fe,null,nt(e.collapseTagList,m=>(C(),M("div",{key:e.getValueKey(m),class:D(e.nsSelect.e("selected-item"))},[k(i,{class:"in-tooltip",closable:!e.selectDisabled&&!m.isDisabled,size:e.collapseTagSize,type:e.tagType,"disable-transitions":"",onClose:y=>e.deleteTag(y,m)},{default:$(()=>[b("span",{class:D(e.nsSelect.e("tags-text"))},A(m.currentLabel),3)]),_:2},1032,["closable","size","type","onClose"])],2))),128))],2)]),_:1},8,["disabled","effect","teleported"])):W("v-if",!0)]):W("v-if",!0),e.selectDisabled?W("v-if",!0):(C(),M("div",{key:1,class:D([e.nsSelect.e("selected-item"),e.nsSelect.e("input-wrapper"),e.nsSelect.is("hidden",!e.filterable)])},[He(b("input",{id:e.inputId,ref:"inputRef","onUpdate:modelValue":t[0]||(t[0]=m=>e.states.inputValue=m),type:"text",class:D([e.nsSelect.e("input"),e.nsSelect.is(e.selectSize)]),disabled:e.selectDisabled,autocomplete:e.autocomplete,style:Qe(e.inputStyle),role:"combobox",readonly:!e.filterable,spellcheck:"false","aria-activedescendant":((h=e.hoverOption)==null?void 0:h.id)||"","aria-controls":e.contentId,"aria-expanded":e.dropdownMenuVisible,"aria-label":e.ariaLabel,"aria-autocomplete":"none","aria-haspopup":"listbox",onFocus:t[1]||(t[1]=(...m)=>e.handleFocus&&e.handleFocus(...m)),onBlur:t[2]||(t[2]=(...m)=>e.handleBlur&&e.handleBlur(...m)),onKeydown:[t[3]||(t[3]=Pt(et(m=>e.navigateOptions("next"),["stop","prevent"]),["down"])),t[4]||(t[4]=Pt(et(m=>e.navigateOptions("prev"),["stop","prevent"]),["up"])),t[5]||(t[5]=Pt(et((...m)=>e.handleEsc&&e.handleEsc(...m),["stop","prevent"]),["esc"])),t[6]||(t[6]=Pt(et((...m)=>e.selectOption&&e.selectOption(...m),["stop","prevent"]),["enter"])),t[7]||(t[7]=Pt(et((...m)=>e.deletePrevTag&&e.deletePrevTag(...m),["stop"]),["delete"]))],onCompositionstart:t[8]||(t[8]=(...m)=>e.handleCompositionStart&&e.handleCompositionStart(...m)),onCompositionupdate:t[9]||(t[9]=(...m)=>e.handleCompositionUpdate&&e.handleCompositionUpdate(...m)),onCompositionend:t[10]||(t[10]=(...m)=>e.handleCompositionEnd&&e.handleCompositionEnd(...m)),onInput:t[11]||(t[11]=(...m)=>e.onInput&&e.onInput(...m)),onClick:t[12]||(t[12]=et((...m)=>e.toggleMenu&&e.toggleMenu(...m),["stop"]))},null,46,wae),[[Bc,e.states.inputValue]]),e.filterable?(C(),M("span",{key:0,ref:"calculatorRef","aria-hidden":"true",class:D(e.nsSelect.e("input-calculator")),textContent:A(e.states.inputValue)},null,10,Cae)):W("v-if",!0)],2)),e.shouldShowPlaceholder?(C(),M("div",{key:2,class:D([e.nsSelect.e("selected-item"),e.nsSelect.e("placeholder"),e.nsSelect.is("transparent",!e.hasModelValue||e.expanded&&!e.states.inputValue)])},[b("span",null,A(e.currentPlaceholder),1)],2)):W("v-if",!0)],2),b("div",{ref:"suffixRef",class:D(e.nsSelect.e("suffix"))},[e.iconComponent&&!e.showClose?(C(),q(a,{key:0,class:D([e.nsSelect.e("caret"),e.nsSelect.e("icon"),e.iconReverse])},{default:$(()=>[(C(),q(Lt(e.iconComponent)))]),_:1},8,["class"])):W("v-if",!0),e.showClose&&e.clearIcon?(C(),q(a,{key:1,class:D([e.nsSelect.e("caret"),e.nsSelect.e("icon")]),onClick:e.handleClearClick},{default:$(()=>[(C(),q(Lt(e.clearIcon)))]),_:1},8,["class","onClick"])):W("v-if",!0),e.validateState&&e.validateIcon?(C(),q(a,{key:2,class:D([e.nsInput.e("icon"),e.nsInput.e("validateIcon")])},{default:$(()=>[(C(),q(Lt(e.validateIcon)))]),_:1},8,["class"])):W("v-if",!0)],2)],2)]}),content:$(()=>[k(f,{ref:"menuRef"},{default:$(()=>[e.$slots.header?(C(),M("div",{key:0,class:D(e.nsSelect.be("dropdown","header")),onClick:t[13]||(t[13]=et(()=>{},["stop"]))},[he(e.$slots,"header")],2)):W("v-if",!0),He(k(d,{id:e.contentId,ref:"scrollbarRef",tag:"ul","wrap-class":e.nsSelect.be("dropdown","wrap"),"view-class":e.nsSelect.be("dropdown","list"),class:D([e.nsSelect.is("empty",e.filteredOptionsCount===0)]),role:"listbox","aria-label":e.ariaLabel,"aria-orientation":"vertical"},{default:$(()=>[e.showNewOption?(C(),q(u,{key:0,value:e.states.inputValue,created:!0},null,8,["value"])):W("v-if",!0),k(c,null,{default:$(()=>[he(e.$slots,"default")]),_:3})]),_:3},8,["id","wrap-class","view-class","class","aria-label"]),[[en,e.states.options.size>0&&!e.loading]]),e.$slots.loading&&e.loading?(C(),M("div",{key:1,class:D(e.nsSelect.be("dropdown","loading"))},[he(e.$slots,"loading")],2)):e.loading||e.filteredOptionsCount===0?(C(),M("div",{key:2,class:D(e.nsSelect.be("dropdown","empty"))},[he(e.$slots,"empty",{},()=>[b("span",null,A(e.emptyText),1)])],2)):W("v-if",!0),e.$slots.footer?(C(),M("div",{key:3,class:D(e.nsSelect.be("dropdown","footer")),onClick:t[14]||(t[14]=et(()=>{},["stop"]))},[he(e.$slots,"footer")],2)):W("v-if",!0)]),_:3},512)]),_:3},8,["visible","placement","teleported","popper-class","popper-options","fallback-placements","effect","transition","persistent","onBeforeShow"])],34)),[[p,e.handleClickOutside,e.popperRef]])}var Sae=ze(bae,[["render",kae],["__file","select.vue"]]);const $ae=Q({name:"ElOptionGroup",componentName:"ElOptionGroup",props:{label:String,disabled:Boolean},setup(e){const t=Re("select"),n=K(null),o=at(),r=K([]);wt(hO,Dn({...ei(e)}));const s=R(()=>r.value.some(a=>a.visible===!0)),i=a=>{const u=[];return Me(a.children)&&a.children.forEach(c=>{var d,f;c.type&&c.type.name==="ElOption"&&c.component&&c.component.proxy?u.push(c.component.proxy):(d=c.children)!=null&&d.length?u.push(...i(c)):(f=c.component)!=null&&f.subTree&&u.push(...i(c.component.subTree))}),u},l=()=>{r.value=i(o.subTree)};return Ct(()=>{l()}),oH(n,l,{attributes:!0,subtree:!0,childList:!0}),{groupRef:n,visible:s,ns:t}}});function Eae(e,t,n,o,r,s){return He((C(),M("ul",{ref:"groupRef",class:D(e.ns.be("group","wrap"))},[b("li",{class:D(e.ns.be("group","title"))},A(e.label),3),b("li",null,[b("ul",{class:D(e.ns.b("group"))},[he(e.$slots,"default")],2)])],2)),[[en,e.visible]])}var mO=ze($ae,[["render",Eae],["__file","option-group.vue"]]);const vr=Zt(Sae,{Option:U3,OptionGroup:mO}),Ss=Gn(U3),xae=Gn(mO),W3=()=>Be(pO,{}),Mae=We({pageSize:{type:Number,required:!0},pageSizes:{type:Ce(Array),default:()=>$o([10,20,30,40,50,100])},popperClass:{type:String},disabled:Boolean,teleported:Boolean,size:{type:String,values:Zl}}),Tae=Q({name:"ElPaginationSizes"}),Oae=Q({...Tae,props:Mae,emits:["page-size-change"],setup(e,{emit:t}){const n=e,{t:o}=Kt(),r=Re("pagination"),s=W3(),i=K(n.pageSize);Te(()=>n.pageSizes,(u,c)=>{if(!jl(u,c)&&Array.isArray(u)){const d=u.includes(n.pageSize)?n.pageSize:n.pageSizes[0];t("page-size-change",d)}}),Te(()=>n.pageSize,u=>{i.value=u});const l=R(()=>n.pageSizes);function a(u){var c;u!==i.value&&(i.value=u,(c=s.handleSizeChange)==null||c.call(s,Number(u)))}return(u,c)=>(C(),M("span",{class:D(g(r).e("sizes"))},[k(g(vr),{"model-value":i.value,disabled:u.disabled,"popper-class":u.popperClass,size:u.size,teleported:u.teleported,"validate-event":!1,onChange:a},{default:$(()=>[(C(!0),M(fe,null,nt(g(l),d=>(C(),q(g(Ss),{key:d,value:d,label:d+g(o)("el.pagination.pagesize")},null,8,["value","label"]))),128))]),_:1},8,["model-value","disabled","popper-class","size","teleported"])],2))}});var Iae=ze(Oae,[["__file","sizes.vue"]]);const Aae=We({size:{type:String,values:Zl}}),Nae=["disabled"],Pae=Q({name:"ElPaginationJumper"}),Lae=Q({...Pae,props:Aae,setup(e){const{t}=Kt(),n=Re("pagination"),{pageCount:o,disabled:r,currentPage:s,changeEvent:i}=W3(),l=K(),a=R(()=>{var d;return(d=l.value)!=null?d:s==null?void 0:s.value});function u(d){l.value=d?+d:""}function c(d){d=Math.trunc(+d),i==null||i(d),l.value=void 0}return(d,f)=>(C(),M("span",{class:D(g(n).e("jump")),disabled:g(r)},[b("span",{class:D([g(n).e("goto")])},A(g(t)("el.pagination.goto")),3),k(g(At),{size:d.size,class:D([g(n).e("editor"),g(n).is("in-pagination")]),min:1,max:g(o),disabled:g(r),"model-value":g(a),"validate-event":!1,label:g(t)("el.pagination.page"),type:"number","onUpdate:modelValue":u,onChange:c},null,8,["size","class","max","disabled","model-value","label"]),b("span",{class:D([g(n).e("classifier")])},A(g(t)("el.pagination.pageClassifier")),3)],10,Nae))}});var Rae=ze(Lae,[["__file","jumper.vue"]]);const Dae=We({total:{type:Number,default:1e3}}),Fae=["disabled"],Vae=Q({name:"ElPaginationTotal"}),Bae=Q({...Vae,props:Dae,setup(e){const{t}=Kt(),n=Re("pagination"),{disabled:o}=W3();return(r,s)=>(C(),M("span",{class:D(g(n).e("total")),disabled:g(o)},A(g(t)("el.pagination.total",{total:r.total})),11,Fae))}});var zae=ze(Bae,[["__file","total.vue"]]);const jae=We({currentPage:{type:Number,default:1},pageCount:{type:Number,required:!0},pagerCount:{type:Number,default:7},disabled:Boolean}),Hae=["onKeyup"],Uae=["aria-current","aria-label","tabindex"],Wae=["tabindex","aria-label"],Kae=["aria-current","aria-label","tabindex"],qae=["tabindex","aria-label"],Gae=["aria-current","aria-label","tabindex"],Yae=Q({name:"ElPaginationPager"}),Zae=Q({...Yae,props:jae,emits:["change"],setup(e,{emit:t}){const n=e,o=Re("pager"),r=Re("icon"),{t:s}=Kt(),i=K(!1),l=K(!1),a=K(!1),u=K(!1),c=K(!1),d=K(!1),f=R(()=>{const S=n.pagerCount,x=(S-1)/2,E=Number(n.currentPage),T=Number(n.pageCount);let O=!1,P=!1;T>S&&(E>S-x&&(O=!0),E<T-x&&(P=!0));const N=[];if(O&&!P){const F=T-(S-2);for(let B=F;B<T;B++)N.push(B)}else if(!O&&P)for(let F=2;F<S;F++)N.push(F);else if(O&&P){const F=Math.floor(S/2)-1;for(let B=E-F;B<=E+F;B++)N.push(B)}else for(let F=2;F<T;F++)N.push(F);return N}),p=R(()=>["more","btn-quickprev",r.b(),o.is("disabled",n.disabled)]),h=R(()=>["more","btn-quicknext",r.b(),o.is("disabled",n.disabled)]),m=R(()=>n.disabled?-1:0);ls(()=>{const S=(n.pagerCount-1)/2;i.value=!1,l.value=!1,n.pageCount>n.pagerCount&&(n.currentPage>n.pagerCount-S&&(i.value=!0),n.currentPage<n.pageCount-S&&(l.value=!0))});function y(S=!1){n.disabled||(S?a.value=!0:u.value=!0)}function v(S=!1){S?c.value=!0:d.value=!0}function w(S){const x=S.target;if(x.tagName.toLowerCase()==="li"&&Array.from(x.classList).includes("number")){const E=Number(x.textContent);E!==n.currentPage&&t("change",E)}else x.tagName.toLowerCase()==="li"&&Array.from(x.classList).includes("more")&&_(S)}function _(S){const x=S.target;if(x.tagName.toLowerCase()==="ul"||n.disabled)return;let E=Number(x.textContent);const T=n.pageCount,O=n.currentPage,P=n.pagerCount-2;x.className.includes("more")&&(x.className.includes("quickprev")?E=O-P:x.className.includes("quicknext")&&(E=O+P)),Number.isNaN(+E)||(E<1&&(E=1),E>T&&(E=T)),E!==O&&t("change",E)}return(S,x)=>(C(),M("ul",{class:D(g(o).b()),onClick:_,onKeyup:Pt(w,["enter"])},[S.pageCount>0?(C(),M("li",{key:0,class:D([[g(o).is("active",S.currentPage===1),g(o).is("disabled",S.disabled)],"number"]),"aria-current":S.currentPage===1,"aria-label":g(s)("el.pagination.currentPage",{pager:1}),tabindex:g(m)}," 1 ",10,Uae)):W("v-if",!0),i.value?(C(),M("li",{key:1,class:D(g(p)),tabindex:g(m),"aria-label":g(s)("el.pagination.prevPages",{pager:S.pagerCount-2}),onMouseenter:x[0]||(x[0]=E=>y(!0)),onMouseleave:x[1]||(x[1]=E=>a.value=!1),onFocus:x[2]||(x[2]=E=>v(!0)),onBlur:x[3]||(x[3]=E=>c.value=!1)},[(a.value||c.value)&&!S.disabled?(C(),q(g(Jc),{key:0})):(C(),q(g(Y_),{key:1}))],42,Wae)):W("v-if",!0),(C(!0),M(fe,null,nt(g(f),E=>(C(),M("li",{key:E,class:D([[g(o).is("active",S.currentPage===E),g(o).is("disabled",S.disabled)],"number"]),"aria-current":S.currentPage===E,"aria-label":g(s)("el.pagination.currentPage",{pager:E}),tabindex:g(m)},A(E),11,Kae))),128)),l.value?(C(),M("li",{key:2,class:D(g(h)),tabindex:g(m),"aria-label":g(s)("el.pagination.nextPages",{pager:S.pagerCount-2}),onMouseenter:x[4]||(x[4]=E=>y()),onMouseleave:x[5]||(x[5]=E=>u.value=!1),onFocus:x[6]||(x[6]=E=>v()),onBlur:x[7]||(x[7]=E=>d.value=!1)},[(u.value||d.value)&&!S.disabled?(C(),q(g(Xc),{key:0})):(C(),q(g(Y_),{key:1}))],42,qae)):W("v-if",!0),S.pageCount>1?(C(),M("li",{key:3,class:D([[g(o).is("active",S.currentPage===S.pageCount),g(o).is("disabled",S.disabled)],"number"]),"aria-current":S.currentPage===S.pageCount,"aria-label":g(s)("el.pagination.currentPage",{pager:S.pageCount}),tabindex:g(m)},A(S.pageCount),11,Gae)):W("v-if",!0)],42,Hae))}});var Jae=ze(Zae,[["__file","pager.vue"]]);const wo=e=>typeof e!="number",Xae=We({pageSize:Number,defaultPageSize:Number,total:Number,pageCount:Number,pagerCount:{type:Number,validator:e=>_t(e)&&Math.trunc(e)===e&&e>4&&e<22&&e%2===1,default:7},currentPage:Number,defaultCurrentPage:Number,layout:{type:String,default:["prev","pager","next","jumper","->","total"].join(", ")},pageSizes:{type:Ce(Array),default:()=>$o([10,20,30,40,50,100])},popperClass:{type:String,default:""},prevText:{type:String,default:""},prevIcon:{type:Oo,default:()=>au},nextText:{type:String,default:""},nextIcon:{type:Oo,default:()=>js},teleported:{type:Boolean,default:!0},small:Boolean,background:Boolean,disabled:Boolean,hideOnSinglePage:Boolean}),Qae={"update:current-page":e=>_t(e),"update:page-size":e=>_t(e),"size-change":e=>_t(e),change:(e,t)=>_t(e)&&_t(t),"current-change":e=>_t(e),"prev-click":e=>_t(e),"next-click":e=>_t(e)},y8="ElPagination";var eue=Q({name:y8,props:Xae,emits:Qae,setup(e,{emit:t,slots:n}){const{t:o}=Kt(),r=Re("pagination"),s=at().vnode.props||{},i="onUpdate:currentPage"in s||"onUpdate:current-page"in s||"onCurrentChange"in s,l="onUpdate:pageSize"in s||"onUpdate:page-size"in s||"onSizeChange"in s,a=R(()=>{if(wo(e.total)&&wo(e.pageCount)||!wo(e.currentPage)&&!i)return!1;if(e.layout.includes("sizes")){if(wo(e.pageCount)){if(!wo(e.total)&&!wo(e.pageSize)&&!l)return!1}else if(!l)return!1}return!0}),u=K(wo(e.defaultPageSize)?10:e.defaultPageSize),c=K(wo(e.defaultCurrentPage)?1:e.defaultCurrentPage),d=R({get(){return wo(e.pageSize)?u.value:e.pageSize},set(_){wo(e.pageSize)&&(u.value=_),l&&(t("update:page-size",_),t("size-change",_))}}),f=R(()=>{let _=0;return wo(e.pageCount)?wo(e.total)||(_=Math.max(1,Math.ceil(e.total/d.value))):_=e.pageCount,_}),p=R({get(){return wo(e.currentPage)?c.value:e.currentPage},set(_){let S=_;_<1?S=1:_>f.value&&(S=f.value),wo(e.currentPage)&&(c.value=S),i&&(t("update:current-page",S),t("current-change",S))}});Te(f,_=>{p.value>_&&(p.value=_)}),Te([p,d],_=>{t("change",..._)},{flush:"post"});function h(_){p.value=_}function m(_){d.value=_;const S=f.value;p.value>S&&(p.value=S)}function y(){e.disabled||(p.value-=1,t("prev-click",p.value))}function v(){e.disabled||(p.value+=1,t("next-click",p.value))}function w(_,S){_&&(_.props||(_.props={}),_.props.class=[_.props.class,S].join(" "))}return wt(pO,{pageCount:f,disabled:R(()=>e.disabled),currentPage:p,changeEvent:h,handleSizeChange:m}),()=>{var _,S;if(!a.value)return o("el.pagination.deprecationWarning"),null;if(!e.layout||e.hideOnSinglePage&&f.value<=1)return null;const x=[],E=[],T=lt("div",{class:r.e("rightwrapper")},E),O={prev:lt(tae,{disabled:e.disabled,currentPage:p.value,prevText:e.prevText,prevIcon:e.prevIcon,onClick:y}),jumper:lt(Rae,{size:e.small?"small":"default"}),pager:lt(Jae,{currentPage:p.value,pageCount:f.value,pagerCount:e.pagerCount,onChange:h,disabled:e.disabled}),next:lt(lae,{disabled:e.disabled,currentPage:p.value,pageCount:f.value,nextText:e.nextText,nextIcon:e.nextIcon,onClick:v}),sizes:lt(Iae,{pageSize:d.value,pageSizes:e.pageSizes,popperClass:e.popperClass,disabled:e.disabled,teleported:e.teleported,size:e.small?"small":"default"}),slot:(S=(_=n==null?void 0:n.default)==null?void 0:_.call(n))!=null?S:null,total:lt(zae,{total:wo(e.total)?0:e.total})},P=e.layout.split(",").map(F=>F.trim());let N=!1;return P.forEach(F=>{if(F==="->"){N=!0;return}N?E.push(O[F]):x.push(O[F])}),w(x[0],r.is("first")),w(x[x.length-1],r.is("last")),N&&E.length>0&&(w(E[0],r.is("first")),w(E[E.length-1],r.is("last")),x.push(T)),lt("div",{class:[r.b(),r.is("background",e.background),{[r.m("small")]:e.small}]},x)}}});const tue=Zt(eue),nue=We({trigger:Dp.trigger,placement:o1.placement,disabled:Dp.disabled,visible:ar.visible,transition:ar.transition,popperOptions:o1.popperOptions,tabindex:o1.tabindex,content:ar.content,popperStyle:ar.popperStyle,popperClass:ar.popperClass,enterable:{...ar.enterable,default:!0},effect:{...ar.effect,default:"light"},teleported:ar.teleported,title:String,width:{type:[String,Number],default:150},offset:{type:Number,default:void 0},showAfter:{type:Number,default:0},hideAfter:{type:Number,default:200},autoClose:{type:Number,default:0},showArrow:{type:Boolean,default:!0},persistent:{type:Boolean,default:!0},"onUpdate:visible":{type:Function}}),oue={"update:visible":e=>Br(e),"before-enter":()=>!0,"before-leave":()=>!0,"after-enter":()=>!0,"after-leave":()=>!0},rue="onUpdate:visible",sue=Q({name:"ElPopover"}),iue=Q({...sue,props:nue,emits:oue,setup(e,{expose:t,emit:n}){const o=e,r=R(()=>o[rue]),s=Re("popover"),i=K(),l=R(()=>{var y;return(y=g(i))==null?void 0:y.popperRef}),a=R(()=>[{width:Zo(o.width)},o.popperStyle]),u=R(()=>[s.b(),o.popperClass,{[s.m("plain")]:!!o.content}]),c=R(()=>o.transition===`${s.namespace.value}-fade-in-linear`),d=()=>{var y;(y=i.value)==null||y.hide()},f=()=>{n("before-enter")},p=()=>{n("before-leave")},h=()=>{n("after-enter")},m=()=>{n("update:visible",!1),n("after-leave")};return t({popperRef:l,hide:d}),(y,v)=>(C(),q(g($u),un({ref_key:"tooltipRef",ref:i},y.$attrs,{trigger:y.trigger,placement:y.placement,disabled:y.disabled,visible:y.visible,transition:y.transition,"popper-options":y.popperOptions,tabindex:y.tabindex,content:y.content,offset:y.offset,"show-after":y.showAfter,"hide-after":y.hideAfter,"auto-close":y.autoClose,"show-arrow":y.showArrow,"aria-label":y.title,effect:y.effect,enterable:y.enterable,"popper-class":g(u),"popper-style":g(a),teleported:y.teleported,persistent:y.persistent,"gpu-acceleration":g(c),"onUpdate:visible":g(r),onBeforeShow:f,onBeforeHide:p,onShow:h,onHide:m}),{content:$(()=>[y.title?(C(),M("div",{key:0,class:D(g(s).e("title")),role:"title"},A(y.title),3)):W("v-if",!0),he(y.$slots,"default",{},()=>[ne(A(y.content),1)])]),default:$(()=>[y.$slots.reference?he(y.$slots,"reference",{key:0}):W("v-if",!0)]),_:3},16,["trigger","placement","disabled","visible","transition","popper-options","tabindex","content","offset","show-after","hide-after","auto-close","show-arrow","aria-label","effect","enterable","popper-class","popper-style","teleported","persistent","gpu-acceleration","onUpdate:visible"]))}});var lue=ze(iue,[["__file","popover.vue"]]);const _8=(e,t)=>{const n=t.arg||t.value,o=n==null?void 0:n.popperRef;o&&(o.triggerRef=e)};var aue={mounted(e,t){_8(e,t)},updated(e,t){_8(e,t)}};const uue="popover",cue=gJ(aue,uue),Po=Zt(lue,{directive:cue}),due=We({type:{type:String,default:"line",values:["line","circle","dashboard"]},percentage:{type:Number,default:0,validator:e=>e>=0&&e<=100},status:{type:String,default:"",values:["","success","exception","warning"]},indeterminate:{type:Boolean,default:!1},duration:{type:Number,default:3},strokeWidth:{type:Number,default:6},strokeLinecap:{type:Ce(String),default:"round"},textInside:{type:Boolean,default:!1},width:{type:Number,default:126},showText:{type:Boolean,default:!0},color:{type:Ce([String,Array,Function]),default:""},striped:Boolean,stripedFlow:Boolean,format:{type:Ce(Function),default:e=>`${e}%`}}),fue=["aria-valuenow"],pue={viewBox:"0 0 100 100"},hue=["d","stroke","stroke-linecap","stroke-width"],mue=["d","stroke","opacity","stroke-linecap","stroke-width"],gue={key:0},vue=Q({name:"ElProgress"}),yue=Q({...vue,props:due,setup(e){const t=e,n={success:"#13ce66",exception:"#ff4949",warning:"#e6a23c",default:"#20a0ff"},o=Re("progress"),r=R(()=>({width:`${t.percentage}%`,animationDuration:`${t.duration}s`,backgroundColor:w(t.percentage)})),s=R(()=>(t.strokeWidth/t.width*100).toFixed(1)),i=R(()=>["circle","dashboard"].includes(t.type)?Number.parseInt(`${50-Number.parseFloat(s.value)/2}`,10):0),l=R(()=>{const _=i.value,S=t.type==="dashboard";return`
72 M 50 50
73 m 0 ${S?"":"-"}${_}
74 a ${_} ${_} 0 1 1 0 ${S?"-":""}${_*2}
75 a ${_} ${_} 0 1 1 0 ${S?"":"-"}${_*2}
76 `}),a=R(()=>2*Math.PI*i.value),u=R(()=>t.type==="dashboard"?.75:1),c=R(()=>`${-1*a.value*(1-u.value)/2}px`),d=R(()=>({strokeDasharray:`${a.value*u.value}px, ${a.value}px`,strokeDashoffset:c.value})),f=R(()=>({strokeDasharray:`${a.value*u.value*(t.percentage/100)}px, ${a.value}px`,strokeDashoffset:c.value,transition:"stroke-dasharray 0.6s ease 0s, stroke 0.6s ease, opacity ease 0.6s"})),p=R(()=>{let _;return t.color?_=w(t.percentage):_=n[t.status]||n.default,_}),h=R(()=>t.status==="warning"?d3:t.type==="line"?t.status==="success"?i3:wd:t.status==="success"?Yx:Gs),m=R(()=>t.type==="line"?12+t.strokeWidth*.4:t.width*.111111+2),y=R(()=>t.format(t.percentage));function v(_){const S=100/_.length;return _.map((E,T)=>tt(E)?{color:E,percentage:(T+1)*S}:E).sort((E,T)=>E.percentage-T.percentage)}const w=_=>{var S;const{color:x}=t;if(Xe(x))return x(_);if(tt(x))return x;{const E=v(x);for(const T of E)if(T.percentage>_)return T.color;return(S=E[E.length-1])==null?void 0:S.color}};return(_,S)=>(C(),M("div",{class:D([g(o).b(),g(o).m(_.type),g(o).is(_.status),{[g(o).m("without-text")]:!_.showText,[g(o).m("text-inside")]:_.textInside}]),role:"progressbar","aria-valuenow":_.percentage,"aria-valuemin":"0","aria-valuemax":"100"},[_.type==="line"?(C(),M("div",{key:0,class:D(g(o).b("bar"))},[b("div",{class:D(g(o).be("bar","outer")),style:Qe({height:`${_.strokeWidth}px`})},[b("div",{class:D([g(o).be("bar","inner"),{[g(o).bem("bar","inner","indeterminate")]:_.indeterminate},{[g(o).bem("bar","inner","striped")]:_.striped},{[g(o).bem("bar","inner","striped-flow")]:_.stripedFlow}]),style:Qe(g(r))},[(_.showText||_.$slots.default)&&_.textInside?(C(),M("div",{key:0,class:D(g(o).be("bar","innerText"))},[he(_.$slots,"default",{percentage:_.percentage},()=>[b("span",null,A(g(y)),1)])],2)):W("v-if",!0)],6)],6)],2)):(C(),M("div",{key:1,class:D(g(o).b("circle")),style:Qe({height:`${_.width}px`,width:`${_.width}px`})},[(C(),M("svg",pue,[b("path",{class:D(g(o).be("circle","track")),d:g(l),stroke:`var(${g(o).cssVarName("fill-color-light")}, #e5e9f2)`,"stroke-linecap":_.strokeLinecap,"stroke-width":g(s),fill:"none",style:Qe(g(d))},null,14,hue),b("path",{class:D(g(o).be("circle","path")),d:g(l),stroke:g(p),fill:"none",opacity:_.percentage?1:0,"stroke-linecap":_.strokeLinecap,"stroke-width":g(s),style:Qe(g(f))},null,14,mue)]))],6)),(_.showText||_.$slots.default)&&!_.textInside?(C(),M("div",{key:2,class:D(g(o).e("text")),style:Qe({fontSize:`${g(m)}px`})},[he(_.$slots,"default",{percentage:_.percentage},()=>[_.status?(C(),q(g(Ne),{key:1},{default:$(()=>[(C(),q(Lt(g(h))))]),_:1})):(C(),M("span",gue,A(g(y)),1))])],6)):W("v-if",!0)],10,fue))}});var _ue=ze(yue,[["__file","progress.vue"]]);const gO=Zt(_ue),bue=We({animated:{type:Boolean,default:!1},count:{type:Number,default:1},rows:{type:Number,default:3},loading:{type:Boolean,default:!0},throttle:{type:Number}}),wue=We({variant:{type:String,values:["circle","rect","h1","h3","text","caption","p","image","button"],default:"text"}}),Cue=Q({name:"ElSkeletonItem"}),kue=Q({...Cue,props:wue,setup(e){const t=Re("skeleton");return(n,o)=>(C(),M("div",{class:D([g(t).e("item"),g(t).e(n.variant)])},[n.variant==="image"?(C(),q(g(FZ),{key:0})):W("v-if",!0)],2))}});var Dg=ze(kue,[["__file","skeleton-item.vue"]]);const Sue=Q({name:"ElSkeleton"}),$ue=Q({...Sue,props:bue,setup(e,{expose:t}){const n=e,o=Re("skeleton"),r=AX(pn(n,"loading"),n.throttle);return t({uiLoading:r}),(s,i)=>g(r)?(C(),M("div",un({key:0,class:[g(o).b(),g(o).is("animated",s.animated)]},s.$attrs),[(C(!0),M(fe,null,nt(s.count,l=>(C(),M(fe,{key:l},[s.loading?he(s.$slots,"template",{key:l},()=>[k(Dg,{class:D(g(o).is("first")),variant:"p"},null,8,["class"]),(C(!0),M(fe,null,nt(s.rows,a=>(C(),q(Dg,{key:a,class:D([g(o).e("paragraph"),g(o).is("last",a===s.rows&&s.rows>1)]),variant:"p"},null,8,["class"]))),128))]):W("v-if",!0)],64))),128))],16)):he(s.$slots,"default",Z2(un({key:1},s.$attrs)))}});var Eue=ze($ue,[["__file","skeleton.vue"]]);const lo=Zt(Eue,{SkeletonItem:Dg});Gn(Dg);const uy=function(e){var t;return(t=e.target)==null?void 0:t.closest("td")},xue=function(e,t,n,o,r){if(!t&&!o&&(!r||Array.isArray(r)&&!r.length))return e;typeof n=="string"?n=n==="descending"?-1:1:n=n&&n<0?-1:1;const s=o?null:function(l,a){return r?(Array.isArray(r)||(r=[r]),r.map(u=>typeof u=="string"?Tr(l,u):u(l,a,e))):(t!=="$key"&&ft(l)&&"$value"in l&&(l=l.$value),[ft(l)?Tr(l,t):l])},i=function(l,a){if(o)return o(l.value,a.value);for(let u=0,c=l.key.length;u<c;u++){if(l.key[u]<a.key[u])return-1;if(l.key[u]>a.key[u])return 1}return 0};return e.map((l,a)=>({value:l,index:a,key:s?s(l,a):null})).sort((l,a)=>{let u=i(l,a);return u||(u=l.index-a.index),u*+n}).map(l=>l.value)},vO=function(e,t){let n=null;return e.columns.forEach(o=>{o.id===t&&(n=o)}),n},Mue=function(e,t){let n=null;for(let o=0;o<e.columns.length;o++){const r=e.columns[o];if(r.columnKey===t){n=r;break}}return n||ws("ElTable",`No column matching with column-key: ${t}`),n},b8=function(e,t,n){const o=(t.className||"").match(new RegExp(`${n}-table_[^\\s]+`,"gm"));return o?vO(e,o[0]):null},oo=(e,t)=>{if(!e)throw new Error("Row is required when get row identity");if(typeof t=="string"){if(!t.includes("."))return`${e[t]}`;const n=t.split(".");let o=e;for(const r of n)o=o[r];return`${o}`}else if(typeof t=="function")return t.call(null,e)},Pa=function(e,t){const n={};return(e||[]).forEach((o,r)=>{n[oo(o,t)]={row:o,index:r}}),n};function Tue(e,t){const n={};let o;for(o in e)n[o]=e[o];for(o in t)if(vt(t,o)){const r=t[o];typeof r<"u"&&(n[o]=r)}return n}function K3(e){return e===""||e!==void 0&&(e=Number.parseInt(e,10),Number.isNaN(e)&&(e="")),e}function yO(e){return e===""||e!==void 0&&(e=K3(e),Number.isNaN(e)&&(e=80)),e}function Oue(e){return typeof e=="number"?e:typeof e=="string"?/^\d+(?:px)?$/.test(e)?Number.parseInt(e,10):e:null}function Iue(...e){return e.length===0?t=>t:e.length===1?e[0]:e.reduce((t,n)=>(...o)=>t(n(...o)))}function Yf(e,t,n){let o=!1;const r=e.indexOf(t),s=r!==-1,i=l=>{l==="add"?e.push(t):e.splice(r,1),o=!0,Me(t.children)&&t.children.forEach(a=>{Yf(e,a,n??!s)})};return Br(n)?n&&!s?i("add"):!n&&s&&i("remove"):i(s?"remove":"add"),o}function Aue(e,t,n="children",o="hasChildren"){const r=i=>!(Array.isArray(i)&&i.length);function s(i,l,a){t(i,l,a),l.forEach(u=>{if(u[o]){t(u,null,a+1);return}const c=u[n];r(c)||s(u,c,a+1)})}e.forEach(i=>{if(i[o]){t(i,null,0);return}const l=i[n];r(l)||s(i,l,0)})}let Sr=null;function Nue(e,t,n,o){if((Sr==null?void 0:Sr.trigger)===n)return;Sr==null||Sr();const r=o==null?void 0:o.refs.tableWrapper,s=r==null?void 0:r.dataset.prefix,i={strategy:"fixed",...e.popperOptions},l=k($u,{content:t,virtualTriggering:!0,virtualRef:n,appendTo:r,placement:"top",transition:"none",offset:0,hideAfter:0,...e,popperOptions:i,onHide:()=>{Sr==null||Sr()}});l.appContext={...o.appContext,...o};const a=document.createElement("div");Ni(l,a),l.component.exposed.onOpen();const u=r==null?void 0:r.querySelector(`.${s}-scrollbar__wrap`);Sr=()=>{Ni(null,a),u==null||u.removeEventListener("scroll",Sr),Sr=null},Sr.trigger=n,u==null||u.addEventListener("scroll",Sr)}function _O(e){return e.children?oY(e.children,_O):[e]}function w8(e,t){return e+t.colSpan}const bO=(e,t,n,o)=>{let r=0,s=e;const i=n.states.columns.value;if(o){const a=_O(o[e]);r=i.slice(0,i.indexOf(a[0])).reduce(w8,0),s=r+a.reduce(w8,0)-1}else r=e;let l;switch(t){case"left":s<n.states.fixedLeafColumnsLength.value&&(l="left");break;case"right":r>=i.length-n.states.rightFixedLeafColumnsLength.value&&(l="right");break;default:s<n.states.fixedLeafColumnsLength.value?l="left":r>=i.length-n.states.rightFixedLeafColumnsLength.value&&(l="right")}return l?{direction:l,start:r,after:s}:{}},q3=(e,t,n,o,r,s=0)=>{const i=[],{direction:l,start:a,after:u}=bO(t,n,o,r);if(l){const c=l==="left";i.push(`${e}-fixed-column--${l}`),c&&u+s===o.states.fixedLeafColumnsLength.value-1?i.push("is-last-column"):!c&&a-s===o.states.columns.value.length-o.states.rightFixedLeafColumnsLength.value&&i.push("is-first-column")}return i};function C8(e,t){return e+(t.realWidth===null||Number.isNaN(t.realWidth)?Number(t.width):t.realWidth)}const G3=(e,t,n,o)=>{const{direction:r,start:s=0,after:i=0}=bO(e,t,n,o);if(!r)return;const l={},a=r==="left",u=n.states.columns.value;return a?l.left=u.slice(0,s).reduce(C8,0):l.right=u.slice(i+1).reverse().reduce(C8,0),l},ld=(e,t)=>{e&&(Number.isNaN(e[t])||(e[t]=`${e[t]}px`))};function Pue(e){const t=at(),n=K(!1),o=K([]);return{updateExpandRows:()=>{const a=e.data.value||[],u=e.rowKey.value;if(n.value)o.value=a.slice();else if(u){const c=Pa(o.value,u);o.value=a.reduce((d,f)=>{const p=oo(f,u);return c[p]&&d.push(f),d},[])}else o.value=[]},toggleRowExpansion:(a,u)=>{Yf(o.value,a,u)&&t.emit("expand-change",a,o.value.slice())},setExpandRowKeys:a=>{t.store.assertRowKey();const u=e.data.value||[],c=e.rowKey.value,d=Pa(u,c);o.value=a.reduce((f,p)=>{const h=d[p];return h&&f.push(h.row),f},[])},isRowExpanded:a=>{const u=e.rowKey.value;return u?!!Pa(o.value,u)[oo(a,u)]:o.value.includes(a)},states:{expandRows:o,defaultExpandAll:n}}}function Lue(e){const t=at(),n=K(null),o=K(null),r=u=>{t.store.assertRowKey(),n.value=u,i(u)},s=()=>{n.value=null},i=u=>{const{data:c,rowKey:d}=e;let f=null;d.value&&(f=(g(c)||[]).find(p=>oo(p,d.value)===u)),o.value=f,t.emit("current-change",o.value,null)};return{setCurrentRowKey:r,restoreCurrentRowKey:s,setCurrentRowByKey:i,updateCurrentRow:u=>{const c=o.value;if(u&&u!==c){o.value=u,t.emit("current-change",o.value,c);return}!u&&c&&(o.value=null,t.emit("current-change",null,c))},updateCurrentRowData:()=>{const u=e.rowKey.value,c=e.data.value||[],d=o.value;if(!c.includes(d)&&d){if(u){const f=oo(d,u);i(f)}else o.value=null;o.value===null&&t.emit("current-change",null,d)}else n.value&&(i(n.value),s())},states:{_currentRowKey:n,currentRow:o}}}function Rue(e){const t=K([]),n=K({}),o=K(16),r=K(!1),s=K({}),i=K("hasChildren"),l=K("children"),a=at(),u=R(()=>{if(!e.rowKey.value)return{};const v=e.data.value||[];return d(v)}),c=R(()=>{const v=e.rowKey.value,w=Object.keys(s.value),_={};return w.length&&w.forEach(S=>{if(s.value[S].length){const x={children:[]};s.value[S].forEach(E=>{const T=oo(E,v);x.children.push(T),E[i.value]&&!_[T]&&(_[T]={children:[]})}),_[S]=x}}),_}),d=v=>{const w=e.rowKey.value,_={};return Aue(v,(S,x,E)=>{const T=oo(S,w);Array.isArray(x)?_[T]={children:x.map(O=>oo(O,w)),level:E}:r.value&&(_[T]={children:[],lazy:!0,level:E})},l.value,i.value),_},f=(v=!1,w=(_=>(_=a.store)==null?void 0:_.states.defaultExpandAll.value)())=>{var _;const S=u.value,x=c.value,E=Object.keys(S),T={};if(E.length){const O=g(n),P=[],N=(B,Y)=>{if(v)return t.value?w||t.value.includes(Y):!!(w||B!=null&&B.expanded);{const Z=w||t.value&&t.value.includes(Y);return!!(B!=null&&B.expanded||Z)}};E.forEach(B=>{const Y=O[B],Z={...S[B]};if(Z.expanded=N(Y,B),Z.lazy){const{loaded:U=!1,loading:j=!1}=Y||{};Z.loaded=!!U,Z.loading=!!j,P.push(B)}T[B]=Z});const F=Object.keys(x);r.value&&F.length&&P.length&&F.forEach(B=>{const Y=O[B],Z=x[B].children;if(P.includes(B)){if(T[B].children.length!==0)throw new Error("[ElTable]children must be an empty array.");T[B].children=Z}else{const{loaded:U=!1,loading:j=!1}=Y||{};T[B]={lazy:!0,loaded:!!U,loading:!!j,expanded:N(Y,B),children:Z,level:""}}})}n.value=T,(_=a.store)==null||_.updateTableScrollY()};Te(()=>t.value,()=>{f(!0)}),Te(()=>u.value,()=>{f()}),Te(()=>c.value,()=>{f()});const p=v=>{t.value=v,f()},h=(v,w)=>{a.store.assertRowKey();const _=e.rowKey.value,S=oo(v,_),x=S&&n.value[S];if(S&&x&&"expanded"in x){const E=x.expanded;w=typeof w>"u"?!x.expanded:w,n.value[S].expanded=w,E!==w&&a.emit("expand-change",v,w),a.store.updateTableScrollY()}},m=v=>{a.store.assertRowKey();const w=e.rowKey.value,_=oo(v,w),S=n.value[_];r.value&&S&&"loaded"in S&&!S.loaded?y(v,_,S):h(v,void 0)},y=(v,w,_)=>{const{load:S}=a.props;S&&!n.value[w].loaded&&(n.value[w].loading=!0,S(v,_,x=>{if(!Array.isArray(x))throw new TypeError("[ElTable] data must be an array");n.value[w].loading=!1,n.value[w].loaded=!0,n.value[w].expanded=!0,x.length&&(s.value[w]=x),a.emit("expand-change",v,!0)}))};return{loadData:y,loadOrToggle:m,toggleTreeExpansion:h,updateTreeExpandKeys:p,updateTreeData:f,normalize:d,states:{expandRowKeys:t,treeData:n,indent:o,lazy:r,lazyTreeNodeMap:s,lazyColumnIdentifier:i,childrenColumnName:l}}}const Due=(e,t)=>{const n=t.sortingColumn;return!n||typeof n.sortable=="string"?e:xue(e,t.sortProp,t.sortOrder,n.sortMethod,n.sortBy)},r1=e=>{const t=[];return e.forEach(n=>{n.children&&n.children.length>0?t.push.apply(t,r1(n.children)):t.push(n)}),t};function Fue(){var e;const t=at(),{size:n}=ei((e=t.proxy)==null?void 0:e.$props),o=K(null),r=K([]),s=K([]),i=K(!1),l=K([]),a=K([]),u=K([]),c=K([]),d=K([]),f=K([]),p=K([]),h=K([]),m=[],y=K(0),v=K(0),w=K(0),_=K(!1),S=K([]),x=K(!1),E=K(!1),T=K(null),O=K({}),P=K(null),N=K(null),F=K(null),B=K(null),Y=K(null);Te(r,()=>t.state&&V(!1),{deep:!0});const Z=()=>{if(!o.value)throw new Error("[ElTable] prop row-key is required")},U=$e=>{var ie;(ie=$e.children)==null||ie.forEach(we=>{we.fixed=$e.fixed,U(we)})},j=()=>{l.value.forEach(Se=>{U(Se)}),c.value=l.value.filter(Se=>Se.fixed===!0||Se.fixed==="left"),d.value=l.value.filter(Se=>Se.fixed==="right"),c.value.length>0&&l.value[0]&&l.value[0].type==="selection"&&!l.value[0].fixed&&(l.value[0].fixed=!0,c.value.unshift(l.value[0]));const $e=l.value.filter(Se=>!Se.fixed);a.value=[].concat(c.value).concat($e).concat(d.value);const ie=r1($e),we=r1(c.value),ae=r1(d.value);y.value=ie.length,v.value=we.length,w.value=ae.length,u.value=[].concat(we).concat(ie).concat(ae),i.value=c.value.length>0||d.value.length>0},V=($e,ie=!1)=>{$e&&j(),ie?t.state.doLayout():t.state.debouncedUpdateLayout()},H=$e=>S.value.includes($e),L=()=>{_.value=!1,S.value.length&&(S.value=[],t.emit("selection-change",[]))},I=()=>{let $e;if(o.value){$e=[];const ie=Pa(S.value,o.value),we=Pa(r.value,o.value);for(const ae in ie)vt(ie,ae)&&!we[ae]&&$e.push(ie[ae].row)}else $e=S.value.filter(ie=>!r.value.includes(ie));if($e.length){const ie=S.value.filter(we=>!$e.includes(we));S.value=ie,t.emit("selection-change",ie.slice())}},X=()=>(S.value||[]).slice(),oe=($e,ie=void 0,we=!0)=>{if(Yf(S.value,$e,ie)){const Se=(S.value||[]).slice();we&&t.emit("select",Se,$e),t.emit("selection-change",Se)}},z=()=>{var $e,ie;const we=E.value?!_.value:!(_.value||S.value.length);_.value=we;let ae=!1,Se=0;const Fe=(ie=($e=t==null?void 0:t.store)==null?void 0:$e.states)==null?void 0:ie.rowKey.value;r.value.forEach((st,se)=>{const De=se+Se;T.value?T.value.call(null,st,De)&&Yf(S.value,st,we)&&(ae=!0):Yf(S.value,st,we)&&(ae=!0),Se+=xe(oo(st,Fe))}),ae&&t.emit("selection-change",S.value?S.value.slice():[]),t.emit("select-all",S.value)},ge=()=>{const $e=Pa(S.value,o.value);r.value.forEach(ie=>{const we=oo(ie,o.value),ae=$e[we];ae&&(S.value[ae.index]=ie)})},Oe=()=>{var $e,ie,we;if((($e=r.value)==null?void 0:$e.length)===0){_.value=!1;return}let ae;o.value&&(ae=Pa(S.value,o.value));const Se=function(De){return ae?!!ae[oo(De,o.value)]:S.value.includes(De)};let Fe=!0,st=0,se=0;for(let De=0,Ot=(r.value||[]).length;De<Ot;De++){const mn=(we=(ie=t==null?void 0:t.store)==null?void 0:ie.states)==null?void 0:we.rowKey.value,Un=De+se,Zr=r.value[De],qt=T.value&&T.value.call(null,Zr,Un);if(Se(Zr))st++;else if(!T.value||qt){Fe=!1;break}se+=xe(oo(Zr,mn))}st===0&&(Fe=!1),_.value=Fe},xe=$e=>{var ie;if(!t||!t.store)return 0;const{treeData:we}=t.store.states;let ae=0;const Se=(ie=we.value[$e])==null?void 0:ie.children;return Se&&(ae+=Se.length,Se.forEach(Fe=>{ae+=xe(Fe)})),ae},ee=($e,ie)=>{Array.isArray($e)||($e=[$e]);const we={};return $e.forEach(ae=>{O.value[ae.id]=ie,we[ae.columnKey||ae.id]=ie}),we},de=($e,ie,we)=>{N.value&&N.value!==$e&&(N.value.order=null),N.value=$e,F.value=ie,B.value=we},ve=()=>{let $e=g(s);Object.keys(O.value).forEach(ie=>{const we=O.value[ie];if(!we||we.length===0)return;const ae=vO({columns:u.value},ie);ae&&ae.filterMethod&&($e=$e.filter(Se=>we.some(Fe=>ae.filterMethod.call(null,Fe,Se,ae))))}),P.value=$e},le=()=>{r.value=Due(P.value,{sortingColumn:N.value,sortProp:F.value,sortOrder:B.value})},Ie=($e=void 0)=>{$e&&$e.filter||ve(),le()},Ge=$e=>{const{tableHeaderRef:ie}=t.refs;if(!ie)return;const we=Object.assign({},ie.filterPanels),ae=Object.keys(we);if(ae.length)if(typeof $e=="string"&&($e=[$e]),Array.isArray($e)){const Se=$e.map(Fe=>Mue({columns:u.value},Fe));ae.forEach(Fe=>{const st=Se.find(se=>se.id===Fe);st&&(st.filteredValue=[])}),t.store.commit("filterChange",{column:Se,values:[],silent:!0,multi:!0})}else ae.forEach(Se=>{const Fe=u.value.find(st=>st.id===Se);Fe&&(Fe.filteredValue=[])}),O.value={},t.store.commit("filterChange",{column:{},values:[],silent:!0})},G=()=>{N.value&&(de(null,null,null),t.store.commit("changeSortCondition",{silent:!0}))},{setExpandRowKeys:J,toggleRowExpansion:ue,updateExpandRows:_e,states:ye,isRowExpanded:Ae}=Pue({data:r,rowKey:o}),{updateTreeExpandKeys:Le,toggleTreeExpansion:Ee,updateTreeData:Pe,loadOrToggle:me,states:je}=Rue({data:r,rowKey:o}),{updateCurrentRowData:Ze,updateCurrentRow:ce,setCurrentRowKey:te,states:pe}=Lue({data:r,rowKey:o});return{assertRowKey:Z,updateColumns:j,scheduleLayout:V,isSelected:H,clearSelection:L,cleanSelection:I,getSelectionRows:X,toggleRowSelection:oe,_toggleAllSelection:z,toggleAllSelection:null,updateSelectionByRowKey:ge,updateAllSelected:Oe,updateFilters:ee,updateCurrentRow:ce,updateSort:de,execFilter:ve,execSort:le,execQuery:Ie,clearFilter:Ge,clearSort:G,toggleRowExpansion:ue,setExpandRowKeysAdapter:$e=>{J($e),Le($e)},setCurrentRowKey:te,toggleRowExpansionAdapter:($e,ie)=>{u.value.some(({type:ae})=>ae==="expand")?ue($e,ie):Ee($e,ie)},isRowExpanded:Ae,updateExpandRows:_e,updateCurrentRowData:Ze,loadOrToggle:me,updateTreeData:Pe,states:{tableSize:n,rowKey:o,data:r,_data:s,isComplex:i,_columns:l,originColumns:a,columns:u,fixedColumns:c,rightFixedColumns:d,leafColumns:f,fixedLeafColumns:p,rightFixedLeafColumns:h,updateOrderFns:m,leafColumnsLength:y,fixedLeafColumnsLength:v,rightFixedLeafColumnsLength:w,isAllSelected:_,selection:S,reserveSelection:x,selectOnIndeterminate:E,selectable:T,filters:O,filteredData:P,sortingColumn:N,sortProp:F,sortOrder:B,hoverRow:Y,...ye,...je,...pe}}}function kb(e,t){return e.map(n=>{var o;return n.id===t.id?t:((o=n.children)!=null&&o.length&&(n.children=kb(n.children,t)),n)})}function Sb(e){e.forEach(t=>{var n,o;t.no=(n=t.getColumnIndex)==null?void 0:n.call(t),(o=t.children)!=null&&o.length&&Sb(t.children)}),e.sort((t,n)=>t.no-n.no)}function Vue(){const e=at(),t=Fue();return{ns:Re("table"),...t,mutations:{setData(i,l){const a=g(i._data)!==l;i.data.value=l,i._data.value=l,e.store.execQuery(),e.store.updateCurrentRowData(),e.store.updateExpandRows(),e.store.updateTreeData(e.store.states.defaultExpandAll.value),g(i.reserveSelection)?(e.store.assertRowKey(),e.store.updateSelectionByRowKey()):a?e.store.clearSelection():e.store.cleanSelection(),e.store.updateAllSelected(),e.$ready&&e.store.scheduleLayout()},insertColumn(i,l,a,u){const c=g(i._columns);let d=[];a?(a&&!a.children&&(a.children=[]),a.children.push(l),d=kb(c,a)):(c.push(l),d=c),Sb(d),i._columns.value=d,i.updateOrderFns.push(u),l.type==="selection"&&(i.selectable.value=l.selectable,i.reserveSelection.value=l.reserveSelection),e.$ready&&(e.store.updateColumns(),e.store.scheduleLayout())},updateColumnOrder(i,l){var a;((a=l.getColumnIndex)==null?void 0:a.call(l))!==l.no&&(Sb(i._columns.value),e.$ready&&e.store.updateColumns())},removeColumn(i,l,a,u){const c=g(i._columns)||[];if(a)a.children.splice(a.children.findIndex(f=>f.id===l.id),1),ot(()=>{var f;((f=a.children)==null?void 0:f.length)===0&&delete a.children}),i._columns.value=kb(c,a);else{const f=c.indexOf(l);f>-1&&(c.splice(f,1),i._columns.value=c)}const d=i.updateOrderFns.indexOf(u);d>-1&&i.updateOrderFns.splice(d,1),e.$ready&&(e.store.updateColumns(),e.store.scheduleLayout())},sort(i,l){const{prop:a,order:u,init:c}=l;if(a){const d=g(i.columns).find(f=>f.property===a);d&&(d.order=u,e.store.updateSort(d,a,u),e.store.commit("changeSortCondition",{init:c}))}},changeSortCondition(i,l){const{sortingColumn:a,sortProp:u,sortOrder:c}=i,d=g(a),f=g(u),p=g(c);p===null&&(i.sortingColumn.value=null,i.sortProp.value=null);const h={filter:!0};e.store.execQuery(h),(!l||!(l.silent||l.init))&&e.emit("sort-change",{column:d,prop:f,order:p}),e.store.updateTableScrollY()},filterChange(i,l){const{column:a,values:u,silent:c}=l,d=e.store.updateFilters(a,u);e.store.execQuery(),c||e.emit("filter-change",d),e.store.updateTableScrollY()},toggleAllSelection(){e.store.toggleAllSelection()},rowSelectedChanged(i,l){e.store.toggleRowSelection(l),e.store.updateAllSelected()},setHoverRow(i,l){i.hoverRow.value=l},setCurrentRow(i,l){e.store.updateCurrentRow(l)}},commit:function(i,...l){const a=e.store.mutations;if(a[i])a[i].apply(e,[e.store.states].concat(l));else throw new Error(`Action not found: ${i}`)},updateTableScrollY:function(){ot(()=>e.layout.updateScrollY.apply(e.layout))}}}const Zf={rowKey:"rowKey",defaultExpandAll:"defaultExpandAll",selectOnIndeterminate:"selectOnIndeterminate",indent:"indent",lazy:"lazy",data:"data","treeProps.hasChildren":{key:"lazyColumnIdentifier",default:"hasChildren"},"treeProps.children":{key:"childrenColumnName",default:"children"}};function Bue(e,t){if(!e)throw new Error("Table is required.");const n=Vue();return n.toggleAllSelection=zl(n._toggleAllSelection,10),Object.keys(Zf).forEach(o=>{wO(CO(t,o),o,n)}),zue(n,t),n}function zue(e,t){Object.keys(Zf).forEach(n=>{Te(()=>CO(t,n),o=>{wO(o,n,e)})})}function wO(e,t,n){let o=e,r=Zf[t];typeof Zf[t]=="object"&&(r=r.key,o=o||Zf[t].default),n.states[r].value=o}function CO(e,t){if(t.includes(".")){const n=t.split(".");let o=e;return n.forEach(r=>{o=o[r]}),o}else return e[t]}class jue{constructor(t){this.observers=[],this.table=null,this.store=null,this.columns=[],this.fit=!0,this.showHeader=!0,this.height=K(null),this.scrollX=K(!1),this.scrollY=K(!1),this.bodyWidth=K(null),this.fixedWidth=K(null),this.rightFixedWidth=K(null),this.gutterWidth=0;for(const n in t)vt(t,n)&&(on(this[n])?this[n].value=t[n]:this[n]=t[n]);if(!this.table)throw new Error("Table is required for Table Layout");if(!this.store)throw new Error("Store is required for Table Layout")}updateScrollY(){if(this.height.value===null)return!1;const n=this.table.refs.scrollBarRef;if(this.table.vnode.el&&(n!=null&&n.wrapRef)){let o=!0;const r=this.scrollY.value;return o=n.wrapRef.scrollHeight>n.wrapRef.clientHeight,this.scrollY.value=o,r!==o}return!1}setHeight(t,n="height"){if(!xt)return;const o=this.table.vnode.el;if(t=Oue(t),this.height.value=Number(t),!o&&(t||t===0))return ot(()=>this.setHeight(t,n));typeof t=="number"?(o.style[n]=`${t}px`,this.updateElsHeight()):typeof t=="string"&&(o.style[n]=t,this.updateElsHeight())}setMaxHeight(t){this.setHeight(t,"max-height")}getFlattenColumns(){const t=[];return this.table.store.states.columns.value.forEach(o=>{o.isColumnGroup?t.push.apply(t,o.columns):t.push(o)}),t}updateElsHeight(){this.updateScrollY(),this.notifyObservers("scrollable")}headerDisplayNone(t){if(!t)return!0;let n=t;for(;n.tagName!=="DIV";){if(getComputedStyle(n).display==="none")return!0;n=n.parentElement}return!1}updateColumnsWidth(){if(!xt)return;const t=this.fit,n=this.table.vnode.el.clientWidth;let o=0;const r=this.getFlattenColumns(),s=r.filter(a=>typeof a.width!="number");if(r.forEach(a=>{typeof a.width=="number"&&a.realWidth&&(a.realWidth=null)}),s.length>0&&t){if(r.forEach(a=>{o+=Number(a.width||a.minWidth||80)}),o<=n){this.scrollX.value=!1;const a=n-o;if(s.length===1)s[0].realWidth=Number(s[0].minWidth||80)+a;else{const u=s.reduce((f,p)=>f+Number(p.minWidth||80),0),c=a/u;let d=0;s.forEach((f,p)=>{if(p===0)return;const h=Math.floor(Number(f.minWidth||80)*c);d+=h,f.realWidth=Number(f.minWidth||80)+h}),s[0].realWidth=Number(s[0].minWidth||80)+a-d}}else this.scrollX.value=!0,s.forEach(a=>{a.realWidth=Number(a.minWidth)});this.bodyWidth.value=Math.max(o,n),this.table.state.resizeState.value.width=this.bodyWidth.value}else r.forEach(a=>{!a.width&&!a.minWidth?a.realWidth=80:a.realWidth=Number(a.width||a.minWidth),o+=a.realWidth}),this.scrollX.value=o>n,this.bodyWidth.value=o;const i=this.store.states.fixedColumns.value;if(i.length>0){let a=0;i.forEach(u=>{a+=Number(u.realWidth||u.width)}),this.fixedWidth.value=a}const l=this.store.states.rightFixedColumns.value;if(l.length>0){let a=0;l.forEach(u=>{a+=Number(u.realWidth||u.width)}),this.rightFixedWidth.value=a}this.notifyObservers("columns")}addObserver(t){this.observers.push(t)}removeObserver(t){const n=this.observers.indexOf(t);n!==-1&&this.observers.splice(n,1)}notifyObservers(t){this.observers.forEach(o=>{var r,s;switch(t){case"columns":(r=o.state)==null||r.onColumnsChange(this);break;case"scrollable":(s=o.state)==null||s.onScrollableChange(this);break;default:throw new Error(`Table Layout don't have event ${t}.`)}})}}const{CheckboxGroup:Hue}=Hn,Uue=Q({name:"ElTableFilterPanel",components:{ElCheckbox:Hn,ElCheckboxGroup:Hue,ElScrollbar:ks,ElTooltip:$u,ElIcon:Ne,ArrowDown:Su,ArrowUp:N0},directives:{ClickOutside:id},props:{placement:{type:String,default:"bottom-start"},store:{type:Object},column:{type:Object},upDataColumn:{type:Function}},setup(e){const t=at(),{t:n}=Kt(),o=Re("table-filter"),r=t==null?void 0:t.parent;r.filterPanels.value[e.column.id]||(r.filterPanels.value[e.column.id]=t);const s=K(!1),i=K(null),l=R(()=>e.column&&e.column.filters),a=R(()=>e.column.filterClassName?`${o.b()} ${e.column.filterClassName}`:o.b()),u=R({get:()=>{var x;return(((x=e.column)==null?void 0:x.filteredValue)||[])[0]},set:x=>{c.value&&(typeof x<"u"&&x!==null?c.value.splice(0,1,x):c.value.splice(0,1))}}),c=R({get(){return e.column?e.column.filteredValue||[]:[]},set(x){e.column&&e.upDataColumn("filteredValue",x)}}),d=R(()=>e.column?e.column.filterMultiple:!0),f=x=>x.value===u.value,p=()=>{s.value=!1},h=x=>{x.stopPropagation(),s.value=!s.value},m=()=>{s.value=!1},y=()=>{_(c.value),p()},v=()=>{c.value=[],_(c.value),p()},w=x=>{u.value=x,_(typeof x<"u"&&x!==null?c.value:[]),p()},_=x=>{e.store.commit("filterChange",{column:e.column,values:x}),e.store.updateAllSelected()};Te(s,x=>{e.column&&e.upDataColumn("filterOpened",x)},{immediate:!0});const S=R(()=>{var x,E;return(E=(x=i.value)==null?void 0:x.popperRef)==null?void 0:E.contentRef});return{tooltipVisible:s,multiple:d,filterClassName:a,filteredValue:c,filterValue:u,filters:l,handleConfirm:y,handleReset:v,handleSelect:w,isActive:f,t:n,ns:o,showFilterPanel:h,hideFilterPanel:m,popperPaneRef:S,tooltip:i}}}),Wue={key:0},Kue=["disabled"],que=["label","onClick"];function Gue(e,t,n,o,r,s){const i=re("el-checkbox"),l=re("el-checkbox-group"),a=re("el-scrollbar"),u=re("arrow-up"),c=re("arrow-down"),d=re("el-icon"),f=re("el-tooltip"),p=zt("click-outside");return C(),q(f,{ref:"tooltip",visible:e.tooltipVisible,offset:0,placement:e.placement,"show-arrow":!1,"stop-popper-mouse-event":!1,teleported:"",effect:"light",pure:"","popper-class":e.filterClassName,persistent:""},{content:$(()=>[e.multiple?(C(),M("div",Wue,[b("div",{class:D(e.ns.e("content"))},[k(a,{"wrap-class":e.ns.e("wrap")},{default:$(()=>[k(l,{modelValue:e.filteredValue,"onUpdate:modelValue":t[0]||(t[0]=h=>e.filteredValue=h),class:D(e.ns.e("checkbox-group"))},{default:$(()=>[(C(!0),M(fe,null,nt(e.filters,h=>(C(),q(i,{key:h.value,value:h.value},{default:$(()=>[ne(A(h.text),1)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue","class"])]),_:1},8,["wrap-class"])],2),b("div",{class:D(e.ns.e("bottom"))},[b("button",{class:D({[e.ns.is("disabled")]:e.filteredValue.length===0}),disabled:e.filteredValue.length===0,type:"button",onClick:t[1]||(t[1]=(...h)=>e.handleConfirm&&e.handleConfirm(...h))},A(e.t("el.table.confirmFilter")),11,Kue),b("button",{type:"button",onClick:t[2]||(t[2]=(...h)=>e.handleReset&&e.handleReset(...h))},A(e.t("el.table.resetFilter")),1)],2)])):(C(),M("ul",{key:1,class:D(e.ns.e("list"))},[b("li",{class:D([e.ns.e("list-item"),{[e.ns.is("active")]:e.filterValue===void 0||e.filterValue===null}]),onClick:t[3]||(t[3]=h=>e.handleSelect(null))},A(e.t("el.table.clearFilter")),3),(C(!0),M(fe,null,nt(e.filters,h=>(C(),M("li",{key:h.value,class:D([e.ns.e("list-item"),e.ns.is("active",e.isActive(h))]),label:h.value,onClick:m=>e.handleSelect(h.value)},A(h.text),11,que))),128))],2))]),default:$(()=>[He((C(),M("span",{class:D([`${e.ns.namespace.value}-table__column-filter-trigger`,`${e.ns.namespace.value}-none-outline`]),onClick:t[4]||(t[4]=(...h)=>e.showFilterPanel&&e.showFilterPanel(...h))},[k(d,null,{default:$(()=>[e.column.filterOpened?(C(),q(u,{key:0})):(C(),q(c,{key:1}))]),_:1})],2)),[[p,e.hideFilterPanel,e.popperPaneRef]])]),_:1},8,["visible","placement","popper-class"])}var Yue=ze(Uue,[["render",Gue],["__file","filter-panel.vue"]]);function kO(e){const t=at();yd(()=>{n.value.addObserver(t)}),Ct(()=>{o(n.value),r(n.value)}),Fi(()=>{o(n.value),r(n.value)}),ti(()=>{n.value.removeObserver(t)});const n=R(()=>{const s=e.layout;if(!s)throw new Error("Can not find table layout.");return s}),o=s=>{var i;const l=((i=e.vnode.el)==null?void 0:i.querySelectorAll("colgroup > col"))||[];if(!l.length)return;const a=s.getFlattenColumns(),u={};a.forEach(c=>{u[c.id]=c});for(let c=0,d=l.length;c<d;c++){const f=l[c],p=f.getAttribute("name"),h=u[p];h&&f.setAttribute("width",h.realWidth||h.width)}},r=s=>{var i,l;const a=((i=e.vnode.el)==null?void 0:i.querySelectorAll("colgroup > col[name=gutter]"))||[];for(let c=0,d=a.length;c<d;c++)a[c].setAttribute("width",s.scrollY.value?s.gutterWidth:"0");const u=((l=e.vnode.el)==null?void 0:l.querySelectorAll("th.gutter"))||[];for(let c=0,d=u.length;c<d;c++){const f=u[c];f.style.width=s.scrollY.value?`${s.gutterWidth}px`:"0",f.style.display=s.scrollY.value?"":"none"}};return{tableLayout:n.value,onColumnsChange:o,onScrollableChange:r}}const oi=Symbol("ElTable");function Zue(e,t){const n=at(),o=Be(oi),r=m=>{m.stopPropagation()},s=(m,y)=>{!y.filters&&y.sortable?h(m,y,!1):y.filterable&&!y.sortable&&r(m),o==null||o.emit("header-click",y,m)},i=(m,y)=>{o==null||o.emit("header-contextmenu",y,m)},l=K(null),a=K(!1),u=K({}),c=(m,y)=>{if(xt&&!(y.children&&y.children.length>0)&&l.value&&e.border){a.value=!0;const v=o;t("set-drag-visible",!0);const _=(v==null?void 0:v.vnode.el).getBoundingClientRect().left,S=n.vnode.el.querySelector(`th.${y.id}`),x=S.getBoundingClientRect(),E=x.left-_+30;lu(S,"noclick"),u.value={startMouseLeft:m.clientX,startLeft:x.right-_,startColumnLeft:x.left-_,tableLeft:_};const T=v==null?void 0:v.refs.resizeProxy;T.style.left=`${u.value.startLeft}px`,document.onselectstart=function(){return!1},document.ondragstart=function(){return!1};const O=N=>{const F=N.clientX-u.value.startMouseLeft,B=u.value.startLeft+F;T.style.left=`${Math.max(E,B)}px`},P=()=>{if(a.value){const{startColumnLeft:N,startLeft:F}=u.value,Y=Number.parseInt(T.style.left,10)-N;y.width=y.realWidth=Y,v==null||v.emit("header-dragend",y.width,F-N,y,m),requestAnimationFrame(()=>{e.store.scheduleLayout(!1,!0)}),document.body.style.cursor="",a.value=!1,l.value=null,u.value={},t("set-drag-visible",!1)}document.removeEventListener("mousemove",O),document.removeEventListener("mouseup",P),document.onselectstart=null,document.ondragstart=null,setTimeout(()=>{qs(S,"noclick")},0)};document.addEventListener("mousemove",O),document.addEventListener("mouseup",P)}},d=(m,y)=>{if(y.children&&y.children.length>0)return;const v=m.target;if(!gs(v))return;const w=v==null?void 0:v.closest("th");if(!(!y||!y.resizable)&&!a.value&&e.border){const _=w.getBoundingClientRect(),S=document.body.style;_.width>12&&_.right-m.pageX<8?(S.cursor="col-resize",Ti(w,"is-sortable")&&(w.style.cursor="col-resize"),l.value=y):a.value||(S.cursor="",Ti(w,"is-sortable")&&(w.style.cursor="pointer"),l.value=null)}},f=()=>{xt&&(document.body.style.cursor="")},p=({order:m,sortOrders:y})=>{if(m==="")return y[0];const v=y.indexOf(m||null);return y[v>y.length-2?0:v+1]},h=(m,y,v)=>{var w;m.stopPropagation();const _=y.order===v?null:v||p(y),S=(w=m.target)==null?void 0:w.closest("th");if(S&&Ti(S,"noclick")){qs(S,"noclick");return}if(!y.sortable)return;const x=e.store.states;let E=x.sortProp.value,T;const O=x.sortingColumn.value;(O!==y||O===y&&O.order===null)&&(O&&(O.order=null),x.sortingColumn.value=y,E=y.property),_?T=y.order=_:T=y.order=null,x.sortProp.value=E,x.sortOrder.value=T,o==null||o.store.commit("changeSortCondition")};return{handleHeaderClick:s,handleHeaderContextMenu:i,handleMouseDown:c,handleMouseMove:d,handleMouseOut:f,handleSortClick:h,handleFilterClick:r}}function Jue(e){const t=Be(oi),n=Re("table");return{getHeaderRowStyle:l=>{const a=t==null?void 0:t.props.headerRowStyle;return typeof a=="function"?a.call(null,{rowIndex:l}):a},getHeaderRowClass:l=>{const a=[],u=t==null?void 0:t.props.headerRowClassName;return typeof u=="string"?a.push(u):typeof u=="function"&&a.push(u.call(null,{rowIndex:l})),a.join(" ")},getHeaderCellStyle:(l,a,u,c)=>{var d;let f=(d=t==null?void 0:t.props.headerCellStyle)!=null?d:{};typeof f=="function"&&(f=f.call(null,{rowIndex:l,columnIndex:a,row:u,column:c}));const p=G3(a,c.fixed,e.store,u);return ld(p,"left"),ld(p,"right"),Object.assign({},f,p)},getHeaderCellClass:(l,a,u,c)=>{const d=q3(n.b(),a,c.fixed,e.store,u),f=[c.id,c.order,c.headerAlign,c.className,c.labelClassName,...d];c.children||f.push("is-leaf"),c.sortable&&f.push("is-sortable");const p=t==null?void 0:t.props.headerCellClassName;return typeof p=="string"?f.push(p):typeof p=="function"&&f.push(p.call(null,{rowIndex:l,columnIndex:a,row:u,column:c})),f.push(n.e("cell")),f.filter(h=>!!h).join(" ")}}}const SO=e=>{const t=[];return e.forEach(n=>{n.children?(t.push(n),t.push.apply(t,SO(n.children))):t.push(n)}),t},Xue=e=>{let t=1;const n=(s,i)=>{if(i&&(s.level=i.level+1,t<s.level&&(t=s.level)),s.children){let l=0;s.children.forEach(a=>{n(a,s),l+=a.colSpan}),s.colSpan=l}else s.colSpan=1};e.forEach(s=>{s.level=1,n(s,void 0)});const o=[];for(let s=0;s<t;s++)o.push([]);return SO(e).forEach(s=>{s.children?(s.rowSpan=1,s.children.forEach(i=>i.isSubColumn=!0)):s.rowSpan=t-s.level+1,o[s.level-1].push(s)}),o};function Que(e){const t=Be(oi),n=R(()=>Xue(e.store.states.originColumns.value));return{isGroup:R(()=>{const s=n.value.length>1;return s&&t&&(t.state.isGroup.value=!0),s}),toggleAllSelection:s=>{s.stopPropagation(),t==null||t.store.commit("toggleAllSelection")},columnRows:n}}var ece=Q({name:"ElTableHeader",components:{ElCheckbox:Hn},props:{fixed:{type:String,default:""},store:{required:!0,type:Object},border:Boolean,defaultSort:{type:Object,default:()=>({prop:"",order:""})}},setup(e,{emit:t}){const n=at(),o=Be(oi),r=Re("table"),s=K({}),{onColumnsChange:i,onScrollableChange:l}=kO(o);Ct(async()=>{await ot(),await ot();const{prop:E,order:T}=e.defaultSort;o==null||o.store.commit("sort",{prop:E,order:T,init:!0})});const{handleHeaderClick:a,handleHeaderContextMenu:u,handleMouseDown:c,handleMouseMove:d,handleMouseOut:f,handleSortClick:p,handleFilterClick:h}=Zue(e,t),{getHeaderRowStyle:m,getHeaderRowClass:y,getHeaderCellStyle:v,getHeaderCellClass:w}=Jue(e),{isGroup:_,toggleAllSelection:S,columnRows:x}=Que(e);return n.state={onColumnsChange:i,onScrollableChange:l},n.filterPanels=s,{ns:r,filterPanels:s,onColumnsChange:i,onScrollableChange:l,columnRows:x,getHeaderRowClass:y,getHeaderRowStyle:m,getHeaderCellClass:w,getHeaderCellStyle:v,handleHeaderClick:a,handleHeaderContextMenu:u,handleMouseDown:c,handleMouseMove:d,handleMouseOut:f,handleSortClick:p,handleFilterClick:h,isGroup:_,toggleAllSelection:S}},render(){const{ns:e,isGroup:t,columnRows:n,getHeaderCellStyle:o,getHeaderCellClass:r,getHeaderRowClass:s,getHeaderRowStyle:i,handleHeaderClick:l,handleHeaderContextMenu:a,handleMouseDown:u,handleMouseMove:c,handleSortClick:d,handleMouseOut:f,store:p,$parent:h}=this;let m=1;return lt("thead",{class:{[e.is("group")]:t}},n.map((y,v)=>lt("tr",{class:s(v),key:v,style:i(v)},y.map((w,_)=>(w.rowSpan>m&&(m=w.rowSpan),lt("th",{class:r(v,_,y,w),colspan:w.colSpan,key:`${w.id}-thead`,rowspan:w.rowSpan,style:o(v,_,y,w),onClick:S=>l(S,w),onContextmenu:S=>a(S,w),onMousedown:S=>u(S,w),onMousemove:S=>c(S,w),onMouseout:f},[lt("div",{class:["cell",w.filteredValue&&w.filteredValue.length>0?"highlight":""]},[w.renderHeader?w.renderHeader({column:w,$index:_,store:p,_self:h}):w.label,w.sortable&&lt("span",{onClick:S=>d(S,w),class:"caret-wrapper"},[lt("i",{onClick:S=>d(S,w,"ascending"),class:"sort-caret ascending"}),lt("i",{onClick:S=>d(S,w,"descending"),class:"sort-caret descending"})]),w.filterable&&lt(Yue,{store:p,placement:w.filterPlacement||"bottom-start",column:w,upDataColumn:(S,x)=>{w[S]=x}})])]))))))}});function tce(e){const t=Be(oi),n=K(""),o=K(lt("div")),r=(h,m,y)=>{var v;const w=t,_=uy(h);let S;const x=(v=w==null?void 0:w.vnode.el)==null?void 0:v.dataset.prefix;_&&(S=b8({columns:e.store.states.columns.value},_,x),S&&(w==null||w.emit(`cell-${y}`,m,S,_,h))),w==null||w.emit(`row-${y}`,m,S,h)},s=(h,m)=>{r(h,m,"dblclick")},i=(h,m)=>{e.store.commit("setCurrentRow",m),r(h,m,"click")},l=(h,m)=>{r(h,m,"contextmenu")},a=zl(h=>{e.store.commit("setHoverRow",h)},30),u=zl(()=>{e.store.commit("setHoverRow",null)},30),c=h=>{const m=window.getComputedStyle(h,null),y=Number.parseInt(m.paddingLeft,10)||0,v=Number.parseInt(m.paddingRight,10)||0,w=Number.parseInt(m.paddingTop,10)||0,_=Number.parseInt(m.paddingBottom,10)||0;return{left:y,right:v,top:w,bottom:_}},d=(h,m,y)=>{let v=m.target.parentNode;for(;h>1&&(v=v==null?void 0:v.nextSibling,!(!v||v.nodeName!=="TR"));)y(v,"hover-row hover-fixed-row"),h--};return{handleDoubleClick:s,handleClick:i,handleContextMenu:l,handleMouseEnter:a,handleMouseLeave:u,handleCellMouseEnter:(h,m,y)=>{var v;const w=t,_=uy(h),S=(v=w==null?void 0:w.vnode.el)==null?void 0:v.dataset.prefix;if(_){const V=b8({columns:e.store.states.columns.value},_,S);_.rowSpan>1&&d(_.rowSpan,h,lu);const H=w.hoverState={cell:_,column:V,row:m};w==null||w.emit("cell-mouse-enter",H.row,H.column,H.cell,h)}if(!y)return;const x=h.target.querySelector(".cell");if(!(Ti(x,`${S}-tooltip`)&&x.childNodes.length))return;const E=document.createRange();E.setStart(x,0),E.setEnd(x,x.childNodes.length);let T=E.getBoundingClientRect().width,O=E.getBoundingClientRect().height;T-Math.floor(T)<.001&&(T=Math.floor(T)),O-Math.floor(O)<.001&&(O=Math.floor(O));const{top:F,left:B,right:Y,bottom:Z}=c(x),U=B+Y,j=F+Z;(T+U>x.offsetWidth||O+j>x.offsetHeight||x.scrollWidth>x.offsetWidth)&&Nue(y,_.innerText||_.textContent,_,w)},handleCellMouseLeave:h=>{const m=uy(h);if(!m)return;m.rowSpan>1&&d(m.rowSpan,h,qs);const y=t==null?void 0:t.hoverState;t==null||t.emit("cell-mouse-leave",y==null?void 0:y.row,y==null?void 0:y.column,y==null?void 0:y.cell,h)},tooltipContent:n,tooltipTrigger:o}}function nce(e){const t=Be(oi),n=Re("table");return{getRowStyle:(u,c)=>{const d=t==null?void 0:t.props.rowStyle;return typeof d=="function"?d.call(null,{row:u,rowIndex:c}):d||null},getRowClass:(u,c)=>{const d=[n.e("row")];t!=null&&t.props.highlightCurrentRow&&u===e.store.states.currentRow.value&&d.push("current-row"),e.stripe&&c%2===1&&d.push(n.em("row","striped"));const f=t==null?void 0:t.props.rowClassName;return typeof f=="string"?d.push(f):typeof f=="function"&&d.push(f.call(null,{row:u,rowIndex:c})),d},getCellStyle:(u,c,d,f)=>{const p=t==null?void 0:t.props.cellStyle;let h=p??{};typeof p=="function"&&(h=p.call(null,{rowIndex:u,columnIndex:c,row:d,column:f}));const m=G3(c,e==null?void 0:e.fixed,e.store);return ld(m,"left"),ld(m,"right"),Object.assign({},h,m)},getCellClass:(u,c,d,f,p)=>{const h=q3(n.b(),c,e==null?void 0:e.fixed,e.store,void 0,p),m=[f.id,f.align,f.className,...h],y=t==null?void 0:t.props.cellClassName;return typeof y=="string"?m.push(y):typeof y=="function"&&m.push(y.call(null,{rowIndex:u,columnIndex:c,row:d,column:f})),m.push(n.e("cell")),m.filter(v=>!!v).join(" ")},getSpan:(u,c,d,f)=>{let p=1,h=1;const m=t==null?void 0:t.props.spanMethod;if(typeof m=="function"){const y=m({row:u,column:c,rowIndex:d,columnIndex:f});Array.isArray(y)?(p=y[0],h=y[1]):typeof y=="object"&&(p=y.rowspan,h=y.colspan)}return{rowspan:p,colspan:h}},getColspanRealWidth:(u,c,d)=>{if(c<1)return u[d].realWidth;const f=u.map(({realWidth:p,width:h})=>p||h).slice(d,d+c);return Number(f.reduce((p,h)=>Number(p)+Number(h),-1))}}}function oce(e){const t=Be(oi),n=Re("table"),{handleDoubleClick:o,handleClick:r,handleContextMenu:s,handleMouseEnter:i,handleMouseLeave:l,handleCellMouseEnter:a,handleCellMouseLeave:u,tooltipContent:c,tooltipTrigger:d}=tce(e),{getRowStyle:f,getRowClass:p,getCellStyle:h,getCellClass:m,getSpan:y,getColspanRealWidth:v}=nce(e),w=R(()=>e.store.states.columns.value.findIndex(({type:T})=>T==="default")),_=(T,O)=>{const P=t.props.rowKey;return P?oo(T,P):O},S=(T,O,P,N=!1)=>{const{tooltipEffect:F,tooltipOptions:B,store:Y}=e,{indent:Z,columns:U}=Y.states,j=p(T,O);let V=!0;return P&&(j.push(n.em("row",`level-${P.level}`)),V=P.display),lt("tr",{style:[V?null:{display:"none"},f(T,O)],class:j,key:_(T,O),onDblclick:L=>o(L,T),onClick:L=>r(L,T),onContextmenu:L=>s(L,T),onMouseenter:()=>i(O),onMouseleave:l},U.value.map((L,I)=>{const{rowspan:X,colspan:oe}=y(T,L,O,I);if(!X||!oe)return null;const z=Object.assign({},L);z.realWidth=v(U.value,oe,I);const ge={store:e.store,_self:e.context||t,column:z,row:T,$index:O,cellIndex:I,expanded:N};I===w.value&&P&&(ge.treeNode={indent:P.level*Z.value,level:P.level},typeof P.expanded=="boolean"&&(ge.treeNode.expanded=P.expanded,"loading"in P&&(ge.treeNode.loading=P.loading),"noLazyChildren"in P&&(ge.treeNode.noLazyChildren=P.noLazyChildren)));const Oe=`${O},${I}`,xe=z.columnKey||z.rawColumnKey||"",ee=x(I,L,ge),de=L.showOverflowTooltip&&sY({effect:F},B,L.showOverflowTooltip);return lt("td",{style:h(O,I,T,L),class:m(O,I,T,L,oe-1),key:`${xe}${Oe}`,rowspan:X,colspan:oe,onMouseenter:ve=>a(ve,T,de),onMouseleave:u},[ee])}))},x=(T,O,P)=>O.renderCell(P);return{wrappedRowRender:(T,O)=>{const P=e.store,{isRowExpanded:N,assertRowKey:F}=P,{treeData:B,lazyTreeNodeMap:Y,childrenColumnName:Z,rowKey:U}=P.states,j=P.states.columns.value;if(j.some(({type:H})=>H==="expand")){const H=N(T),L=S(T,O,void 0,H),I=t.renderExpanded;return H?I?[[L,lt("tr",{key:`expanded-row__${L.key}`},[lt("td",{colspan:j.length,class:`${n.e("cell")} ${n.e("expanded-cell")}`},[I({row:T,$index:O,store:P,expanded:H})])])]]:(console.error("[Element Error]renderExpanded is required."),L):[[L]]}else if(Object.keys(B.value).length){F();const H=oo(T,U.value);let L=B.value[H],I=null;L&&(I={expanded:L.expanded,level:L.level,display:!0},typeof L.lazy=="boolean"&&(typeof L.loaded=="boolean"&&L.loaded&&(I.noLazyChildren=!(L.children&&L.children.length)),I.loading=L.loading));const X=[S(T,O,I)];if(L){let oe=0;const z=(Oe,xe)=>{Oe&&Oe.length&&xe&&Oe.forEach(ee=>{const de={display:xe.display&&xe.expanded,level:xe.level+1,expanded:!1,noLazyChildren:!1,loading:!1},ve=oo(ee,U.value);if(ve==null)throw new Error("For nested data item, row-key is required.");if(L={...B.value[ve]},L&&(de.expanded=L.expanded,L.level=L.level||de.level,L.display=!!(L.expanded&&de.display),typeof L.lazy=="boolean"&&(typeof L.loaded=="boolean"&&L.loaded&&(de.noLazyChildren=!(L.children&&L.children.length)),de.loading=L.loading)),oe++,X.push(S(ee,O+oe,de)),L){const le=Y.value[ve]||ee[Z.value];z(le,L)}})};L.display=!0;const ge=Y.value[H]||T[Z.value];z(ge,L)}return X}else return S(T,O,void 0)},tooltipContent:c,tooltipTrigger:d}}const rce={store:{required:!0,type:Object},stripe:Boolean,tooltipEffect:String,tooltipOptions:{type:Object},context:{default:()=>({}),type:Object},rowClassName:[String,Function],rowStyle:[Object,Function],fixed:{type:String,default:""},highlight:Boolean};var sce=Q({name:"ElTableBody",props:rce,setup(e){const t=at(),n=Be(oi),o=Re("table"),{wrappedRowRender:r,tooltipContent:s,tooltipTrigger:i}=oce(e),{onColumnsChange:l,onScrollableChange:a}=kO(n),u=[];return Te(e.store.states.hoverRow,(c,d)=>{var f;const p=t==null?void 0:t.vnode.el,h=Array.from((p==null?void 0:p.children)||[]).filter(v=>v==null?void 0:v.classList.contains(`${o.e("row")}`));let m=c;const y=(f=h[m])==null?void 0:f.childNodes;if(y!=null&&y.length){let v=0;Array.from(y).reduce((_,S,x)=>{var E,T;return((E=y[x])==null?void 0:E.colSpan)>1&&(v=(T=y[x])==null?void 0:T.colSpan),S.nodeName!=="TD"&&v===0&&_.push(x),v>0&&v--,_},[]).forEach(_=>{for(var S;m>0;){const x=(S=h[m-1])==null?void 0:S.childNodes;if(x[_]&&x[_].nodeName==="TD"&&x[_].rowSpan>1){lu(x[_],"hover-cell"),u.push(x[_]);break}m--}})}else u.forEach(v=>qs(v,"hover-cell")),u.length=0;!e.store.states.isComplex.value||!xt||pY(()=>{const v=h[d],w=h[c];v&&!v.classList.contains("hover-fixed-row")&&qs(v,"hover-row"),w&&lu(w,"hover-row")})}),ti(()=>{var c;(c=Sr)==null||c()}),{ns:o,onColumnsChange:l,onScrollableChange:a,wrappedRowRender:r,tooltipContent:s,tooltipTrigger:i}},render(){const{wrappedRowRender:e,store:t}=this,n=t.states.data.value||[];return lt("tbody",{tabIndex:-1},[n.reduce((o,r)=>o.concat(e(r,o.length)),[])])}});function ice(){const e=Be(oi),t=e==null?void 0:e.store,n=R(()=>t.states.fixedLeafColumnsLength.value),o=R(()=>t.states.rightFixedColumns.value.length),r=R(()=>t.states.columns.value.length),s=R(()=>t.states.fixedColumns.value.length),i=R(()=>t.states.rightFixedColumns.value.length);return{leftFixedLeafCount:n,rightFixedLeafCount:o,columnsCount:r,leftFixedCount:s,rightFixedCount:i,columns:t.states.columns}}function lce(e){const{columns:t}=ice(),n=Re("table");return{getCellClasses:(s,i)=>{const l=s[i],a=[n.e("cell"),l.id,l.align,l.labelClassName,...q3(n.b(),i,l.fixed,e.store)];return l.className&&a.push(l.className),l.children||a.push(n.is("leaf")),a},getCellStyles:(s,i)=>{const l=G3(i,s.fixed,e.store);return ld(l,"left"),ld(l,"right"),l},columns:t}}var ace=Q({name:"ElTableFooter",props:{fixed:{type:String,default:""},store:{required:!0,type:Object},summaryMethod:Function,sumText:String,border:Boolean,defaultSort:{type:Object,default:()=>({prop:"",order:""})}},setup(e){const{getCellClasses:t,getCellStyles:n,columns:o}=lce(e);return{ns:Re("table"),getCellClasses:t,getCellStyles:n,columns:o}},render(){const{columns:e,getCellStyles:t,getCellClasses:n,summaryMethod:o,sumText:r}=this,s=this.store.states.data.value;let i=[];return o?i=o({columns:e,data:s}):e.forEach((l,a)=>{if(a===0){i[a]=r;return}const u=s.map(p=>Number(p[l.property])),c=[];let d=!0;u.forEach(p=>{if(!Number.isNaN(+p)){d=!1;const h=`${p}`.split(".")[1];c.push(h?h.length:0)}});const f=Math.max.apply(null,c);d?i[a]="":i[a]=u.reduce((p,h)=>{const m=Number(h);return Number.isNaN(+m)?p:Number.parseFloat((p+h).toFixed(Math.min(f,20)))},0)}),lt(lt("tfoot",[lt("tr",{},[...e.map((l,a)=>lt("td",{key:a,colspan:l.colSpan,rowspan:l.rowSpan,class:n(e,a),style:t(l,a)},[lt("div",{class:["cell",l.labelClassName]},[i[a]])]))])]))}});function uce(e){return{setCurrentRow:c=>{e.commit("setCurrentRow",c)},getSelectionRows:()=>e.getSelectionRows(),toggleRowSelection:(c,d)=>{e.toggleRowSelection(c,d,!1),e.updateAllSelected()},clearSelection:()=>{e.clearSelection()},clearFilter:c=>{e.clearFilter(c)},toggleAllSelection:()=>{e.commit("toggleAllSelection")},toggleRowExpansion:(c,d)=>{e.toggleRowExpansionAdapter(c,d)},clearSort:()=>{e.clearSort()},sort:(c,d)=>{e.commit("sort",{prop:c,order:d})}}}function cce(e,t,n,o){const r=K(!1),s=K(null),i=K(!1),l=L=>{i.value=L},a=K({width:null,height:null,headerHeight:null}),u=K(!1),c={display:"inline-block",verticalAlign:"middle"},d=K(),f=K(0),p=K(0),h=K(0),m=K(0),y=K(0);ls(()=>{t.setHeight(e.height)}),ls(()=>{t.setMaxHeight(e.maxHeight)}),Te(()=>[e.currentRowKey,n.states.rowKey],([L,I])=>{!g(I)||!g(L)||n.setCurrentRowKey(`${L}`)},{immediate:!0}),Te(()=>e.data,L=>{o.store.commit("setData",L)},{immediate:!0,deep:!0}),ls(()=>{e.expandRowKeys&&n.setExpandRowKeysAdapter(e.expandRowKeys)});const v=()=>{o.store.commit("setHoverRow",null),o.hoverState&&(o.hoverState=null)},w=(L,I)=>{const{pixelX:X,pixelY:oe}=I;Math.abs(X)>=Math.abs(oe)&&(o.refs.bodyWrapper.scrollLeft+=I.pixelX/5)},_=R(()=>e.height||e.maxHeight||n.states.fixedColumns.value.length>0||n.states.rightFixedColumns.value.length>0),S=R(()=>({width:t.bodyWidth.value?`${t.bodyWidth.value}px`:""})),x=()=>{_.value&&t.updateElsHeight(),t.updateColumnsWidth(),requestAnimationFrame(P)};Ct(async()=>{await ot(),n.updateColumns(),N(),requestAnimationFrame(x);const L=o.vnode.el,I=o.refs.headerWrapper;e.flexible&&L&&L.parentElement&&(L.parentElement.style.minWidth="0"),a.value={width:d.value=L.offsetWidth,height:L.offsetHeight,headerHeight:e.showHeader&&I?I.offsetHeight:null},n.states.columns.value.forEach(X=>{X.filteredValue&&X.filteredValue.length&&o.store.commit("filterChange",{column:X,values:X.filteredValue,silent:!0})}),o.$ready=!0});const E=(L,I)=>{if(!L)return;const X=Array.from(L.classList).filter(oe=>!oe.startsWith("is-scrolling-"));X.push(t.scrollX.value?I:"is-scrolling-none"),L.className=X.join(" ")},T=L=>{const{tableWrapper:I}=o.refs;E(I,L)},O=L=>{const{tableWrapper:I}=o.refs;return!!(I&&I.classList.contains(L))},P=function(){if(!o.refs.scrollBarRef)return;if(!t.scrollX.value){const xe="is-scrolling-none";O(xe)||T(xe);return}const L=o.refs.scrollBarRef.wrapRef;if(!L)return;const{scrollLeft:I,offsetWidth:X,scrollWidth:oe}=L,{headerWrapper:z,footerWrapper:ge}=o.refs;z&&(z.scrollLeft=I),ge&&(ge.scrollLeft=I);const Oe=oe-X-1;I>=Oe?T("is-scrolling-right"):T(I===0?"is-scrolling-left":"is-scrolling-middle")},N=()=>{o.refs.scrollBarRef&&(o.refs.scrollBarRef.wrapRef&&Ln(o.refs.scrollBarRef.wrapRef,"scroll",P,{passive:!0}),e.fit?Bo(o.vnode.el,F):Ln(window,"resize",F),Bo(o.refs.bodyWrapper,()=>{var L,I;F(),(I=(L=o.refs)==null?void 0:L.scrollBarRef)==null||I.update()}))},F=()=>{var L,I,X,oe;const z=o.vnode.el;if(!o.$ready||!z)return;let ge=!1;const{width:Oe,height:xe,headerHeight:ee}=a.value,de=d.value=z.offsetWidth;Oe!==de&&(ge=!0);const ve=z.offsetHeight;(e.height||_.value)&&xe!==ve&&(ge=!0);const le=e.tableLayout==="fixed"?o.refs.headerWrapper:(L=o.refs.tableHeaderRef)==null?void 0:L.$el;e.showHeader&&(le==null?void 0:le.offsetHeight)!==ee&&(ge=!0),f.value=((I=o.refs.tableWrapper)==null?void 0:I.scrollHeight)||0,h.value=(le==null?void 0:le.scrollHeight)||0,m.value=((X=o.refs.footerWrapper)==null?void 0:X.offsetHeight)||0,y.value=((oe=o.refs.appendWrapper)==null?void 0:oe.offsetHeight)||0,p.value=f.value-h.value-m.value-y.value,ge&&(a.value={width:de,height:ve,headerHeight:e.showHeader&&(le==null?void 0:le.offsetHeight)||0},x())},B=Jo(),Y=R(()=>{const{bodyWidth:L,scrollY:I,gutterWidth:X}=t;return L.value?`${L.value-(I.value?X:0)}px`:""}),Z=R(()=>e.maxHeight?"fixed":e.tableLayout),U=R(()=>{if(e.data&&e.data.length)return null;let L="100%";e.height&&p.value&&(L=`${p.value}px`);const I=d.value;return{width:I?`${I}px`:"",height:L}}),j=R(()=>e.height?{height:Number.isNaN(Number(e.height))?e.height:`${e.height}px`}:e.maxHeight?{maxHeight:Number.isNaN(Number(e.maxHeight))?e.maxHeight:`${e.maxHeight}px`}:{}),V=R(()=>e.height?{height:"100%"}:e.maxHeight?Number.isNaN(Number(e.maxHeight))?{maxHeight:`calc(${e.maxHeight} - ${h.value+m.value}px)`}:{maxHeight:`${e.maxHeight-h.value-m.value}px`}:{});return{isHidden:r,renderExpanded:s,setDragVisible:l,isGroup:u,handleMouseLeave:v,handleHeaderFooterMousewheel:w,tableSize:B,emptyBlockStyle:U,handleFixedMousewheel:(L,I)=>{const X=o.refs.bodyWrapper;if(Math.abs(I.spinY)>0){const oe=X.scrollTop;I.pixelY<0&&oe!==0&&L.preventDefault(),I.pixelY>0&&X.scrollHeight-X.clientHeight>oe&&L.preventDefault(),X.scrollTop+=Math.ceil(I.pixelY/5)}else X.scrollLeft+=Math.ceil(I.pixelX/5)},resizeProxyVisible:i,bodyWidth:Y,resizeState:a,doLayout:x,tableBodyStyles:S,tableLayout:Z,scrollbarViewStyle:c,tableInnerStyle:j,scrollbarStyle:V}}function dce(e){const t=K(),n=()=>{const r=e.vnode.el.querySelector(".hidden-columns"),s={childList:!0,subtree:!0},i=e.store.states.updateOrderFns;t.value=new MutationObserver(()=>{i.forEach(l=>l())}),t.value.observe(r,s)};Ct(()=>{n()}),ti(()=>{var o;(o=t.value)==null||o.disconnect()})}var fce={data:{type:Array,default:()=>[]},size:qr,width:[String,Number],height:[String,Number],maxHeight:[String,Number],fit:{type:Boolean,default:!0},stripe:Boolean,border:Boolean,rowKey:[String,Function],showHeader:{type:Boolean,default:!0},showSummary:Boolean,sumText:String,summaryMethod:Function,rowClassName:[String,Function],rowStyle:[Object,Function],cellClassName:[String,Function],cellStyle:[Object,Function],headerRowClassName:[String,Function],headerRowStyle:[Object,Function],headerCellClassName:[String,Function],headerCellStyle:[Object,Function],highlightCurrentRow:Boolean,currentRowKey:[String,Number],emptyText:String,expandRowKeys:Array,defaultExpandAll:Boolean,defaultSort:Object,tooltipEffect:String,tooltipOptions:Object,spanMethod:Function,selectOnIndeterminate:{type:Boolean,default:!0},indent:{type:Number,default:16},treeProps:{type:Object,default:()=>({hasChildren:"hasChildren",children:"children"})},lazy:Boolean,load:Function,style:{type:Object,default:()=>({})},className:{type:String,default:""},tableLayout:{type:String,default:"fixed"},scrollbarAlwaysOn:Boolean,flexible:Boolean,showOverflowTooltip:[Boolean,Object]};function $O(e){const t=e.tableLayout==="auto";let n=e.columns||[];t&&n.every(r=>r.width===void 0)&&(n=[]);const o=r=>{const s={key:`${e.tableLayout}_${r.id}`,style:{},name:void 0};return t?s.style={width:`${r.width}px`}:s.name=r.id,s};return lt("colgroup",{},n.map(r=>lt("col",o(r))))}$O.props=["columns","tableLayout"];const pce=()=>{const e=K(),t=(s,i)=>{const l=e.value;l&&l.scrollTo(s,i)},n=(s,i)=>{const l=e.value;l&&_t(i)&&["Top","Left"].includes(s)&&l[`setScroll${s}`](i)};return{scrollBarRef:e,scrollTo:t,setScrollTop:s=>n("Top",s),setScrollLeft:s=>n("Left",s)}};let hce=1;const mce=Q({name:"ElTable",directives:{Mousewheel:toe},components:{TableHeader:ece,TableBody:sce,TableFooter:ace,ElScrollbar:ks,hColgroup:$O},props:fce,emits:["select","select-all","selection-change","cell-mouse-enter","cell-mouse-leave","cell-contextmenu","cell-click","cell-dblclick","row-click","row-contextmenu","row-dblclick","header-click","header-contextmenu","sort-change","filter-change","current-change","header-dragend","expand-change"],setup(e){const{t}=Kt(),n=Re("table"),o=at();wt(oi,o);const r=Bue(o,e);o.store=r;const s=new jue({store:o.store,table:o,fit:e.fit,showHeader:e.showHeader});o.layout=s;const i=R(()=>(r.states.data.value||[]).length===0),{setCurrentRow:l,getSelectionRows:a,toggleRowSelection:u,clearSelection:c,clearFilter:d,toggleAllSelection:f,toggleRowExpansion:p,clearSort:h,sort:m}=uce(r),{isHidden:y,renderExpanded:v,setDragVisible:w,isGroup:_,handleMouseLeave:S,handleHeaderFooterMousewheel:x,tableSize:E,emptyBlockStyle:T,handleFixedMousewheel:O,resizeProxyVisible:P,bodyWidth:N,resizeState:F,doLayout:B,tableBodyStyles:Y,tableLayout:Z,scrollbarViewStyle:U,tableInnerStyle:j,scrollbarStyle:V}=cce(e,s,r,o),{scrollBarRef:H,scrollTo:L,setScrollLeft:I,setScrollTop:X}=pce(),oe=zl(B,50),z=`${n.namespace.value}-table_${hce++}`;o.tableId=z,o.state={isGroup:_,resizeState:F,doLayout:B,debouncedUpdateLayout:oe};const ge=R(()=>e.sumText||t("el.table.sumText")),Oe=R(()=>e.emptyText||t("el.table.emptyText"));return dce(o),{ns:n,layout:s,store:r,handleHeaderFooterMousewheel:x,handleMouseLeave:S,tableId:z,tableSize:E,isHidden:y,isEmpty:i,renderExpanded:v,resizeProxyVisible:P,resizeState:F,isGroup:_,bodyWidth:N,tableBodyStyles:Y,emptyBlockStyle:T,debouncedUpdateLayout:oe,handleFixedMousewheel:O,setCurrentRow:l,getSelectionRows:a,toggleRowSelection:u,clearSelection:c,clearFilter:d,toggleAllSelection:f,toggleRowExpansion:p,clearSort:h,doLayout:B,sort:m,t,setDragVisible:w,context:o,computedSumText:ge,computedEmptyText:Oe,tableLayout:Z,scrollbarViewStyle:U,tableInnerStyle:j,scrollbarStyle:V,scrollBarRef:H,scrollTo:L,setScrollLeft:I,setScrollTop:X}}}),gce=["data-prefix"],vce={ref:"hiddenColumns",class:"hidden-columns"};function yce(e,t,n,o,r,s){const i=re("hColgroup"),l=re("table-header"),a=re("table-body"),u=re("table-footer"),c=re("el-scrollbar"),d=zt("mousewheel");return C(),M("div",{ref:"tableWrapper",class:D([{[e.ns.m("fit")]:e.fit,[e.ns.m("striped")]:e.stripe,[e.ns.m("border")]:e.border||e.isGroup,[e.ns.m("hidden")]:e.isHidden,[e.ns.m("group")]:e.isGroup,[e.ns.m("fluid-height")]:e.maxHeight,[e.ns.m("scrollable-x")]:e.layout.scrollX.value,[e.ns.m("scrollable-y")]:e.layout.scrollY.value,[e.ns.m("enable-row-hover")]:!e.store.states.isComplex.value,[e.ns.m("enable-row-transition")]:(e.store.states.data.value||[]).length!==0&&(e.store.states.data.value||[]).length<100,"has-footer":e.showSummary},e.ns.m(e.tableSize),e.className,e.ns.b(),e.ns.m(`layout-${e.tableLayout}`)]),style:Qe(e.style),"data-prefix":e.ns.namespace.value,onMouseleave:t[0]||(t[0]=(...f)=>e.handleMouseLeave&&e.handleMouseLeave(...f))},[b("div",{class:D(e.ns.e("inner-wrapper")),style:Qe(e.tableInnerStyle)},[b("div",vce,[he(e.$slots,"default")],512),e.showHeader&&e.tableLayout==="fixed"?He((C(),M("div",{key:0,ref:"headerWrapper",class:D(e.ns.e("header-wrapper"))},[b("table",{ref:"tableHeader",class:D(e.ns.e("header")),style:Qe(e.tableBodyStyles),border:"0",cellpadding:"0",cellspacing:"0"},[k(i,{columns:e.store.states.columns.value,"table-layout":e.tableLayout},null,8,["columns","table-layout"]),k(l,{ref:"tableHeaderRef",border:e.border,"default-sort":e.defaultSort,store:e.store,onSetDragVisible:e.setDragVisible},null,8,["border","default-sort","store","onSetDragVisible"])],6)],2)),[[d,e.handleHeaderFooterMousewheel]]):W("v-if",!0),b("div",{ref:"bodyWrapper",class:D(e.ns.e("body-wrapper"))},[k(c,{ref:"scrollBarRef","view-style":e.scrollbarViewStyle,"wrap-style":e.scrollbarStyle,always:e.scrollbarAlwaysOn},{default:$(()=>[b("table",{ref:"tableBody",class:D(e.ns.e("body")),cellspacing:"0",cellpadding:"0",border:"0",style:Qe({width:e.bodyWidth,tableLayout:e.tableLayout})},[k(i,{columns:e.store.states.columns.value,"table-layout":e.tableLayout},null,8,["columns","table-layout"]),e.showHeader&&e.tableLayout==="auto"?(C(),q(l,{key:0,ref:"tableHeaderRef",class:D(e.ns.e("body-header")),border:e.border,"default-sort":e.defaultSort,store:e.store,onSetDragVisible:e.setDragVisible},null,8,["class","border","default-sort","store","onSetDragVisible"])):W("v-if",!0),k(a,{context:e.context,highlight:e.highlightCurrentRow,"row-class-name":e.rowClassName,"tooltip-effect":e.tooltipEffect,"tooltip-options":e.tooltipOptions,"row-style":e.rowStyle,store:e.store,stripe:e.stripe},null,8,["context","highlight","row-class-name","tooltip-effect","tooltip-options","row-style","store","stripe"]),e.showSummary&&e.tableLayout==="auto"?(C(),q(u,{key:1,class:D(e.ns.e("body-footer")),border:e.border,"default-sort":e.defaultSort,store:e.store,"sum-text":e.computedSumText,"summary-method":e.summaryMethod},null,8,["class","border","default-sort","store","sum-text","summary-method"])):W("v-if",!0)],6),e.isEmpty?(C(),M("div",{key:0,ref:"emptyBlock",style:Qe(e.emptyBlockStyle),class:D(e.ns.e("empty-block"))},[b("span",{class:D(e.ns.e("empty-text"))},[he(e.$slots,"empty",{},()=>[ne(A(e.computedEmptyText),1)])],2)],6)):W("v-if",!0),e.$slots.append?(C(),M("div",{key:1,ref:"appendWrapper",class:D(e.ns.e("append-wrapper"))},[he(e.$slots,"append")],2)):W("v-if",!0)]),_:3},8,["view-style","wrap-style","always"])],2),e.showSummary&&e.tableLayout==="fixed"?He((C(),M("div",{key:1,ref:"footerWrapper",class:D(e.ns.e("footer-wrapper"))},[b("table",{class:D(e.ns.e("footer")),cellspacing:"0",cellpadding:"0",border:"0",style:Qe(e.tableBodyStyles)},[k(i,{columns:e.store.states.columns.value,"table-layout":e.tableLayout},null,8,["columns","table-layout"]),k(u,{border:e.border,"default-sort":e.defaultSort,store:e.store,"sum-text":e.computedSumText,"summary-method":e.summaryMethod},null,8,["border","default-sort","store","sum-text","summary-method"])],6)],2)),[[en,!e.isEmpty],[d,e.handleHeaderFooterMousewheel]]):W("v-if",!0),e.border||e.isGroup?(C(),M("div",{key:2,class:D(e.ns.e("border-left-patch"))},null,2)):W("v-if",!0)],6),He(b("div",{ref:"resizeProxy",class:D(e.ns.e("column-resize-proxy"))},null,2),[[en,e.resizeProxyVisible]])],46,gce)}var _ce=ze(mce,[["render",yce],["__file","table.vue"]]);const bce={selection:"table-column--selection",expand:"table__expand-column"},wce={default:{order:""},selection:{width:48,minWidth:48,realWidth:48,order:""},expand:{width:48,minWidth:48,realWidth:48,order:""},index:{width:48,minWidth:48,realWidth:48,order:""}},Cce=e=>bce[e]||"",kce={selection:{renderHeader({store:e,column:t}){function n(){return e.states.data.value&&e.states.data.value.length===0}return lt(Hn,{disabled:n(),size:e.states.tableSize.value,indeterminate:e.states.selection.value.length>0&&!e.states.isAllSelected.value,"onUpdate:modelValue":e.toggleAllSelection,modelValue:e.states.isAllSelected.value,ariaLabel:t.label})},renderCell({row:e,column:t,store:n,$index:o}){return lt(Hn,{disabled:t.selectable?!t.selectable.call(null,e,o):!1,size:n.states.tableSize.value,onChange:()=>{n.commit("rowSelectedChanged",e)},onClick:r=>r.stopPropagation(),modelValue:n.isSelected(e),ariaLabel:t.label})},sortable:!1,resizable:!1},index:{renderHeader({column:e}){return e.label||"#"},renderCell({column:e,$index:t}){let n=t+1;const o=e.index;return typeof o=="number"?n=t+o:typeof o=="function"&&(n=o(t)),lt("div",{},[n])},sortable:!1},expand:{renderHeader({column:e}){return e.label||""},renderCell({row:e,store:t,expanded:n}){const{ns:o}=t,r=[o.e("expand-icon")];return n&&r.push(o.em("expand-icon","expanded")),lt("div",{class:r,onClick:function(i){i.stopPropagation(),t.toggleRowExpansion(e)}},{default:()=>[lt(Ne,null,{default:()=>[lt(js)]})]})},sortable:!1,resizable:!1}};function Sce({row:e,column:t,$index:n}){var o;const r=t.property,s=r&&Km(e,r).value;return t&&t.formatter?t.formatter(e,t,s,n):((o=s==null?void 0:s.toString)==null?void 0:o.call(s))||""}function $ce({row:e,treeNode:t,store:n},o=!1){const{ns:r}=n;if(!t)return o?[lt("span",{class:r.e("placeholder")})]:null;const s=[],i=function(l){l.stopPropagation(),!t.loading&&n.loadOrToggle(e)};if(t.indent&&s.push(lt("span",{class:r.e("indent"),style:{"padding-left":`${t.indent}px`}})),typeof t.expanded=="boolean"&&!t.noLazyChildren){const l=[r.e("expand-icon"),t.expanded?r.em("expand-icon","expanded"):""];let a=js;t.loading&&(a=a3),s.push(lt("div",{class:l,onClick:i},{default:()=>[lt(Ne,{class:{[r.is("loading")]:t.loading}},{default:()=>[lt(a)]})]}))}else s.push(lt("span",{class:r.e("placeholder")}));return s}function k8(e,t){return e.reduce((n,o)=>(n[o]=o,n),t)}function Ece(e,t){const n=at();return{registerComplexWatchers:()=>{const s=["fixed"],i={realWidth:"width",realMinWidth:"minWidth"},l=k8(s,i);Object.keys(l).forEach(a=>{const u=i[a];vt(t,u)&&Te(()=>t[u],c=>{let d=c;u==="width"&&a==="realWidth"&&(d=K3(c)),u==="minWidth"&&a==="realMinWidth"&&(d=yO(c)),n.columnConfig.value[u]=d,n.columnConfig.value[a]=d;const f=u==="fixed";e.value.store.scheduleLayout(f)})})},registerNormalWatchers:()=>{const s=["label","filters","filterMultiple","filteredValue","sortable","index","formatter","className","labelClassName","filterClassName","showOverflowTooltip"],i={property:"prop",align:"realAlign",headerAlign:"realHeaderAlign"},l=k8(s,i);Object.keys(l).forEach(a=>{const u=i[a];vt(t,u)&&Te(()=>t[u],c=>{n.columnConfig.value[a]=c})})}}}function xce(e,t,n){const o=at(),r=K(""),s=K(!1),i=K(),l=K(),a=Re("table");ls(()=>{i.value=e.align?`is-${e.align}`:null,i.value}),ls(()=>{l.value=e.headerAlign?`is-${e.headerAlign}`:i.value,l.value});const u=R(()=>{let S=o.vnode.vParent||o.parent;for(;S&&!S.tableId&&!S.columnId;)S=S.vnode.vParent||S.parent;return S}),c=R(()=>{const{store:S}=o.parent;if(!S)return!1;const{treeData:x}=S.states,E=x.value;return E&&Object.keys(E).length>0}),d=K(K3(e.width)),f=K(yO(e.minWidth)),p=S=>(d.value&&(S.width=d.value),f.value&&(S.minWidth=f.value),!d.value&&f.value&&(S.width=void 0),S.minWidth||(S.minWidth=80),S.realWidth=Number(S.width===void 0?S.minWidth:S.width),S),h=S=>{const x=S.type,E=kce[x]||{};Object.keys(E).forEach(O=>{const P=E[O];O!=="className"&&P!==void 0&&(S[O]=P)});const T=Cce(x);if(T){const O=`${g(a.namespace)}-${T}`;S.className=S.className?`${S.className} ${O}`:O}return S},m=S=>{Array.isArray(S)?S.forEach(E=>x(E)):x(S);function x(E){var T;((T=E==null?void 0:E.type)==null?void 0:T.name)==="ElTableColumn"&&(E.vParent=o)}};return{columnId:r,realAlign:i,isSubColumn:s,realHeaderAlign:l,columnOrTableParent:u,setColumnWidth:p,setColumnForcedProps:h,setColumnRenders:S=>{e.renderHeader||S.type!=="selection"&&(S.renderHeader=E=>(o.columnConfig.value.label,he(t,"header",E,()=>[S.label])));let x=S.renderCell;return S.type==="expand"?(S.renderCell=E=>lt("div",{class:"cell"},[x(E)]),n.value.renderExpanded=E=>t.default?t.default(E):t.default):(x=x||Sce,S.renderCell=E=>{let T=null;if(t.default){const Y=t.default(E);T=Y.some(Z=>Z.type!==Kn)?Y:x(E)}else T=x(E);const{columns:O}=n.value.store.states,P=O.value.findIndex(Y=>Y.type==="default"),N=c.value&&E.cellIndex===P,F=$ce(E,N),B={class:"cell",style:{}};return S.showOverflowTooltip&&(B.class=`${B.class} ${g(a.namespace)}-tooltip`,B.style={width:`${(E.column.realWidth||Number(E.column.width))-1}px`}),m(T),lt("div",B,[F,T])}),S},getPropsData:(...S)=>S.reduce((x,E)=>(Array.isArray(E)&&E.forEach(T=>{x[T]=e[T]}),x),{}),getColumnElIndex:(S,x)=>Array.prototype.indexOf.call(S,x),updateColumnOrder:()=>{n.value.store.commit("updateColumnOrder",o.columnConfig.value)}}}var Mce={type:{type:String,default:"default"},label:String,className:String,labelClassName:String,property:String,prop:String,width:{type:[String,Number],default:""},minWidth:{type:[String,Number],default:""},renderHeader:Function,sortable:{type:[Boolean,String],default:!1},sortMethod:Function,sortBy:[String,Function,Array],resizable:{type:Boolean,default:!0},columnKey:String,align:String,headerAlign:String,showOverflowTooltip:{type:[Boolean,Object],default:void 0},fixed:[Boolean,String],formatter:Function,selectable:Function,reserveSelection:Boolean,filterMethod:Function,filteredValue:Array,filters:Array,filterPlacement:String,filterMultiple:{type:Boolean,default:!0},filterClassName:String,index:[Number,Function],sortOrders:{type:Array,default:()=>["ascending","descending",null],validator:e=>e.every(t=>["ascending","descending",null].includes(t))}};let Tce=1;var EO=Q({name:"ElTableColumn",components:{ElCheckbox:Hn},props:Mce,setup(e,{slots:t}){const n=at(),o=K({}),r=R(()=>{let _=n.parent;for(;_&&!_.tableId;)_=_.parent;return _}),{registerNormalWatchers:s,registerComplexWatchers:i}=Ece(r,e),{columnId:l,isSubColumn:a,realHeaderAlign:u,columnOrTableParent:c,setColumnWidth:d,setColumnForcedProps:f,setColumnRenders:p,getPropsData:h,getColumnElIndex:m,realAlign:y,updateColumnOrder:v}=xce(e,t,r),w=c.value;l.value=`${w.tableId||w.columnId}_column_${Tce++}`,yd(()=>{a.value=r.value!==w;const _=e.type||"default",S=e.sortable===""?!0:e.sortable,x=Uo(e.showOverflowTooltip)?w.props.showOverflowTooltip:e.showOverflowTooltip,E={...wce[_],id:l.value,type:_,property:e.prop||e.property,align:y,headerAlign:u,showOverflowTooltip:x,filterable:e.filters||e.filterMethod,filteredValue:[],filterPlacement:"",filterClassName:"",isColumnGroup:!1,isSubColumn:!1,filterOpened:!1,sortable:S,index:e.index,rawColumnKey:n.vnode.key};let F=h(["columnKey","label","className","labelClassName","type","renderHeader","formatter","fixed","resizable"],["sortMethod","sortBy","sortOrders"],["selectable","reserveSelection"],["filterMethod","filters","filterMultiple","filterOpened","filteredValue","filterPlacement","filterClassName"]);F=Tue(E,F),F=Iue(p,d,f)(F),o.value=F,s(),i()}),Ct(()=>{var _;const S=c.value,x=a.value?S.vnode.el.children:(_=S.refs.hiddenColumns)==null?void 0:_.children,E=()=>m(x||[],n.vnode.el);o.value.getColumnIndex=E,E()>-1&&r.value.store.commit("insertColumn",o.value,a.value?S.columnConfig.value:null,v)}),En(()=>{r.value.store.commit("removeColumn",o.value,a.value?w.columnConfig.value:null,v)}),n.columnId=l.value,n.columnConfig=o},render(){var e,t,n;try{const o=(t=(e=this.$slots).default)==null?void 0:t.call(e,{row:{},column:{},$index:-1}),r=[];if(Array.isArray(o))for(const i of o)((n=i.type)==null?void 0:n.name)==="ElTableColumn"||i.shapeFlag&2?r.push(i):i.type===fe&&Array.isArray(i.children)&&i.children.forEach(l=>{(l==null?void 0:l.patchFlag)!==1024&&!tt(l==null?void 0:l.children)&&r.push(l)});return lt("div",r)}catch{return lt("div",[])}}});const G0=Zt(_ce,{TableColumn:EO}),Y0=Gn(EO),Z0=Symbol("tabsRootContextKey"),Oce=We({tabs:{type:Ce(Array),default:()=>$o([])}}),xO="ElTabBar",Ice=Q({name:xO}),Ace=Q({...Ice,props:Oce,setup(e,{expose:t}){const n=e,o=at(),r=Be(Z0);r||ws(xO,"<el-tabs><el-tab-bar /></el-tabs>");const s=Re("tabs"),i=K(),l=K(),a=()=>{let c=0,d=0;const f=["top","bottom"].includes(r.props.tabPosition)?"width":"height",p=f==="width"?"x":"y",h=p==="x"?"left":"top";return n.tabs.every(m=>{var y,v;const w=(v=(y=o.parent)==null?void 0:y.refs)==null?void 0:v[`tab-${m.uid}`];if(!w)return!1;if(!m.active)return!0;c=w[`offset${Cl(h)}`],d=w[`client${Cl(f)}`];const _=window.getComputedStyle(w);return f==="width"&&(n.tabs.length>1&&(d-=Number.parseFloat(_.paddingLeft)+Number.parseFloat(_.paddingRight)),c+=Number.parseFloat(_.paddingLeft)),!1}),{[f]:`${d}px`,transform:`translate${Cl(p)}(${c}px)`}},u=()=>l.value=a();return Te(()=>n.tabs,async()=>{await ot(),u()},{immediate:!0}),Bo(i,()=>u()),t({ref:i,update:u}),(c,d)=>(C(),M("div",{ref_key:"barRef",ref:i,class:D([g(s).e("active-bar"),g(s).is(g(r).props.tabPosition)]),style:Qe(l.value)},null,6))}});var Nce=ze(Ace,[["__file","tab-bar.vue"]]);const Pce=We({panes:{type:Ce(Array),default:()=>$o([])},currentName:{type:[String,Number],default:""},editable:Boolean,type:{type:String,values:["card","border-card",""],default:""},stretch:Boolean}),Lce={tabClick:(e,t,n)=>n instanceof Event,tabRemove:(e,t)=>t instanceof Event},S8="ElTabNav",Rce=Q({name:S8,props:Pce,emits:Lce,setup(e,{expose:t,emit:n}){const o=at(),r=Be(Z0);r||ws(S8,"<el-tabs><tab-nav /></el-tabs>");const s=Re("tabs"),i=Zj(),l=cH(),a=K(),u=K(),c=K(),d=K(),f=K(!1),p=K(0),h=K(!1),m=K(!0),y=R(()=>["top","bottom"].includes(r.props.tabPosition)?"width":"height"),v=R(()=>({transform:`translate${y.value==="width"?"X":"Y"}(-${p.value}px)`})),w=()=>{if(!a.value)return;const P=a.value[`offset${Cl(y.value)}`],N=p.value;if(!N)return;const F=N>P?N-P:0;p.value=F},_=()=>{if(!a.value||!u.value)return;const P=u.value[`offset${Cl(y.value)}`],N=a.value[`offset${Cl(y.value)}`],F=p.value;if(P-F<=N)return;const B=P-F>N*2?F+N:P-N;p.value=B},S=async()=>{const P=u.value;if(!f.value||!c.value||!a.value||!P)return;await ot();const N=c.value.querySelector(".is-active");if(!N)return;const F=a.value,B=["top","bottom"].includes(r.props.tabPosition),Y=N.getBoundingClientRect(),Z=F.getBoundingClientRect(),U=B?P.offsetWidth-Z.width:P.offsetHeight-Z.height,j=p.value;let V=j;B?(Y.left<Z.left&&(V=j-(Z.left-Y.left)),Y.right>Z.right&&(V=j+Y.right-Z.right)):(Y.top<Z.top&&(V=j-(Z.top-Y.top)),Y.bottom>Z.bottom&&(V=j+(Y.bottom-Z.bottom))),V=Math.max(V,0),p.value=Math.min(V,U)},x=()=>{var P;if(!u.value||!a.value)return;e.stretch&&((P=d.value)==null||P.update());const N=u.value[`offset${Cl(y.value)}`],F=a.value[`offset${Cl(y.value)}`],B=p.value;F<N?(f.value=f.value||{},f.value.prev=B,f.value.next=B+F<N,N-B<F&&(p.value=N-F)):(f.value=!1,B>0&&(p.value=0))},E=P=>{const N=P.code,{up:F,down:B,left:Y,right:Z}=rt;if(![F,B,Y,Z].includes(N))return;const U=Array.from(P.currentTarget.querySelectorAll("[role=tab]:not(.is-disabled)")),j=U.indexOf(P.target);let V;N===Y||N===F?j===0?V=U.length-1:V=j-1:j<U.length-1?V=j+1:V=0,U[V].focus({preventScroll:!0}),U[V].click(),T()},T=()=>{m.value&&(h.value=!0)},O=()=>h.value=!1;return Te(i,P=>{P==="hidden"?m.value=!1:P==="visible"&&setTimeout(()=>m.value=!0,50)}),Te(l,P=>{P?setTimeout(()=>m.value=!0,50):m.value=!1}),Bo(c,x),Ct(()=>setTimeout(()=>S(),0)),Fi(()=>x()),t({scrollToActiveTab:S,removeFocus:O}),Te(()=>e.panes,()=>o.update(),{flush:"post",deep:!0}),()=>{const P=f.value?[k("span",{class:[s.e("nav-prev"),s.is("disabled",!f.value.prev)],onClick:w},[k(Ne,null,{default:()=>[k(au,null,null)]})]),k("span",{class:[s.e("nav-next"),s.is("disabled",!f.value.next)],onClick:_},[k(Ne,null,{default:()=>[k(js,null,null)]})])]:null,N=e.panes.map((F,B)=>{var Y,Z,U,j;const V=F.uid,H=F.props.disabled,L=(Z=(Y=F.props.name)!=null?Y:F.index)!=null?Z:`${B}`,I=!H&&(F.isClosable||e.editable);F.index=`${B}`;const X=I?k(Ne,{class:"is-icon-close",onClick:ge=>n("tabRemove",F,ge)},{default:()=>[k(Gs,null,null)]}):null,oe=((j=(U=F.slots).label)==null?void 0:j.call(U))||F.props.label,z=!H&&F.active?0:-1;return k("div",{ref:`tab-${V}`,class:[s.e("item"),s.is(r.props.tabPosition),s.is("active",F.active),s.is("disabled",H),s.is("closable",I),s.is("focus",h.value)],id:`tab-${L}`,key:`tab-${V}`,"aria-controls":`pane-${L}`,role:"tab","aria-selected":F.active,tabindex:z,onFocus:()=>T(),onBlur:()=>O(),onClick:ge=>{O(),n("tabClick",F,L,ge)},onKeydown:ge=>{I&&(ge.code===rt.delete||ge.code===rt.backspace)&&n("tabRemove",F,ge)}},[oe,X])});return k("div",{ref:c,class:[s.e("nav-wrap"),s.is("scrollable",!!f.value),s.is(r.props.tabPosition)]},[P,k("div",{class:s.e("nav-scroll"),ref:a},[k("div",{class:[s.e("nav"),s.is(r.props.tabPosition),s.is("stretch",e.stretch&&["top","bottom"].includes(r.props.tabPosition))],ref:u,style:v.value,role:"tablist",onKeydown:E},[e.type?null:k(Nce,{ref:d,tabs:[...e.panes]},null),N])])])}}}),Dce=We({type:{type:String,values:["card","border-card",""],default:""},closable:Boolean,addable:Boolean,modelValue:{type:[String,Number]},editable:Boolean,tabPosition:{type:String,values:["top","right","bottom","left"],default:"top"},beforeLeave:{type:Ce(Function),default:()=>!0},stretch:Boolean}),cy=e=>tt(e)||_t(e),Fce={[Jt]:e=>cy(e),tabClick:(e,t)=>t instanceof Event,tabChange:e=>cy(e),edit:(e,t)=>["remove","add"].includes(t),tabRemove:e=>cy(e),tabAdd:()=>!0},Vce=Q({name:"ElTabs",props:Dce,emits:Fce,setup(e,{emit:t,slots:n,expose:o}){var r;const s=Re("tabs"),{children:i,addChild:l,removeChild:a}=_Q(at(),"ElTabPane"),u=K(),c=K((r=e.modelValue)!=null?r:"0"),d=async(m,y=!1)=>{var v,w,_;if(!(c.value===m||Uo(m)))try{await((v=e.beforeLeave)==null?void 0:v.call(e,m,c.value))!==!1&&(c.value=m,y&&(t(Jt,m),t("tabChange",m)),(_=(w=u.value)==null?void 0:w.removeFocus)==null||_.call(w))}catch{}},f=(m,y,v)=>{m.props.disabled||(d(y,!0),t("tabClick",m,v))},p=(m,y)=>{m.props.disabled||Uo(m.props.name)||(y.stopPropagation(),t("edit",m.props.name,"remove"),t("tabRemove",m.props.name))},h=()=>{t("edit",void 0,"add"),t("tabAdd")};return Te(()=>e.modelValue,m=>d(m)),Te(c,async()=>{var m;await ot(),(m=u.value)==null||m.scrollToActiveTab()}),wt(Z0,{props:e,currentName:c,registerPane:l,unregisterPane:a}),o({currentName:c}),()=>{const m=n["add-icon"],y=e.editable||e.addable?k("span",{class:s.e("new-tab"),tabindex:"0",onClick:h,onKeydown:_=>{_.code===rt.enter&&h()}},[m?he(n,"add-icon"):k(Ne,{class:s.is("icon-plus")},{default:()=>[k(u3,null,null)]})]):null,v=k("div",{class:[s.e("header"),s.is(e.tabPosition)]},[y,k(Rce,{ref:u,currentName:c.value,editable:e.editable,type:e.type,panes:i.value,stretch:e.stretch,onTabClick:f,onTabRemove:p},null)]),w=k("div",{class:s.e("content")},[he(n,"default")]);return k("div",{class:[s.b(),s.m(e.tabPosition),{[s.m("card")]:e.type==="card",[s.m("border-card")]:e.type==="border-card"}]},[...e.tabPosition!=="bottom"?[v,w]:[w,v]])}}}),Bce=We({label:{type:String,default:""},name:{type:[String,Number]},closable:Boolean,disabled:Boolean,lazy:Boolean}),zce=["id","aria-hidden","aria-labelledby"],MO="ElTabPane",jce=Q({name:MO}),Hce=Q({...jce,props:Bce,setup(e){const t=e,n=at(),o=Kr(),r=Be(Z0);r||ws(MO,"usage: <el-tabs><el-tab-pane /></el-tabs/>");const s=Re("tab-pane"),i=K(),l=R(()=>t.closable||r.props.closable),a=k6(()=>{var p;return r.currentName.value===((p=t.name)!=null?p:i.value)}),u=K(a.value),c=R(()=>{var p;return(p=t.name)!=null?p:i.value}),d=k6(()=>!t.lazy||u.value||a.value);Te(a,p=>{p&&(u.value=!0)});const f=Dn({uid:n.uid,slots:o,props:t,paneName:c,active:a,index:i,isClosable:l});return Ct(()=>{r.registerPane(f)}),ti(()=>{r.unregisterPane(f.uid)}),(p,h)=>g(d)?He((C(),M("div",{key:0,id:`pane-${g(c)}`,class:D(g(s).b()),role:"tabpanel","aria-hidden":!g(a),"aria-labelledby":`tab-${g(c)}`},[he(p.$slots,"default")],10,zce)),[[en,g(a)]]):W("v-if",!0)}});var TO=ze(Hce,[["__file","tab-pane.vue"]]);const OO=Zt(Vce,{TabPane:TO}),IO=Gn(TO),Uce=We({format:{type:String,default:"HH:mm"},modelValue:String,disabled:Boolean,editable:{type:Boolean,default:!0},effect:{type:String,default:"light"},clearable:{type:Boolean,default:!0},size:qr,placeholder:String,start:{type:String,default:"09:00"},end:{type:String,default:"18:00"},step:{type:String,default:"00:30"},minTime:String,maxTime:String,name:String,prefixIcon:{type:Ce([String,Object]),default:()=>Jx},clearIcon:{type:Ce([String,Object]),default:()=>wd},...M3}),wi=e=>{const t=(e||"").split(":");if(t.length>=2){let n=Number.parseInt(t[0],10);const o=Number.parseInt(t[1],10),r=e.toUpperCase();return r.includes("AM")&&n===12?n=0:r.includes("PM")&&n!==12&&(n+=12),{hours:n,minutes:o}}return null},dy=(e,t)=>{const n=wi(e);if(!n)return-1;const o=wi(t);if(!o)return-1;const r=n.minutes+n.hours*60,s=o.minutes+o.hours*60;return r===s?0:r>s?1:-1},$8=e=>`${e}`.padStart(2,"0"),Gu=e=>`${$8(e.hours)}:${$8(e.minutes)}`,Wce=(e,t)=>{const n=wi(e);if(!n)return"";const o=wi(t);if(!o)return"";const r={hours:n.hours,minutes:n.minutes};return r.minutes+=o.minutes,r.hours+=o.hours,r.hours+=Math.floor(r.minutes/60),r.minutes=r.minutes%60,Gu(r)},Kce=Q({name:"ElTimeSelect"}),qce=Q({...Kce,props:Uce,emits:["change","blur","focus","update:modelValue"],setup(e,{expose:t}){const n=e;ut.extend(aT);const{Option:o}=vr,r=Re("input"),s=K(),i=Gr(),{lang:l}=Kt(),a=R(()=>n.modelValue),u=R(()=>{const v=wi(n.start);return v?Gu(v):null}),c=R(()=>{const v=wi(n.end);return v?Gu(v):null}),d=R(()=>{const v=wi(n.step);return v?Gu(v):null}),f=R(()=>{const v=wi(n.minTime||"");return v?Gu(v):null}),p=R(()=>{const v=wi(n.maxTime||"");return v?Gu(v):null}),h=R(()=>{const v=[];if(n.start&&n.end&&n.step){let w=u.value,_;for(;w&&c.value&&dy(w,c.value)<=0;)_=ut(w,"HH:mm").locale(l.value).format(n.format),v.push({value:_,disabled:dy(w,f.value||"-1:-1")<=0||dy(w,p.value||"100:100")>=0}),w=Wce(w,d.value)}return v});return t({blur:()=>{var v,w;(w=(v=s.value)==null?void 0:v.blur)==null||w.call(v)},focus:()=>{var v,w;(w=(v=s.value)==null?void 0:v.focus)==null||w.call(v)}}),(v,w)=>(C(),q(g(vr),{ref_key:"select",ref:s,"model-value":g(a),disabled:g(i),clearable:v.clearable,"clear-icon":v.clearIcon,size:v.size,effect:v.effect,placeholder:v.placeholder,"default-first-option":"",filterable:v.editable,"empty-values":v.emptyValues,"value-on-clear":v.valueOnClear,"onUpdate:modelValue":w[0]||(w[0]=_=>v.$emit("update:modelValue",_)),onChange:w[1]||(w[1]=_=>v.$emit("change",_)),onBlur:w[2]||(w[2]=_=>v.$emit("blur",_)),onFocus:w[3]||(w[3]=_=>v.$emit("focus",_))},{prefix:$(()=>[v.prefixIcon?(C(),q(g(Ne),{key:0,class:D(g(r).e("prefix-icon"))},{default:$(()=>[(C(),q(Lt(v.prefixIcon)))]),_:1},8,["class"])):W("v-if",!0)]),default:$(()=>[(C(!0),M(fe,null,nt(g(h),_=>(C(),q(g(o),{key:_.value,label:_.value,value:_.value,disabled:_.disabled},null,8,["label","value","disabled"]))),128))]),_:1},8,["model-value","disabled","clearable","clear-icon","size","effect","placeholder","filterable","empty-values","value-on-clear"]))}});var s1=ze(qce,[["__file","time-select.vue"]]);s1.install=e=>{e.component(s1.name,s1)};const Gce=s1,AO=Gce,NO=Symbol("uploadContextKey"),Yce="ElUpload";class Zce extends Error{constructor(t,n,o,r){super(t),this.name="UploadAjaxError",this.status=n,this.method=o,this.url=r}}function E8(e,t,n){let o;return n.response?o=`${n.response.error||n.response}`:n.responseText?o=`${n.responseText}`:o=`fail to ${t.method} ${e} ${n.status}`,new Zce(o,n.status,t.method,e)}function Jce(e){const t=e.responseText||e.response;if(!t)return t;try{return JSON.parse(t)}catch{return t}}const Xce=e=>{typeof XMLHttpRequest>"u"&&ws(Yce,"XMLHttpRequest is undefined");const t=new XMLHttpRequest,n=e.action;t.upload&&t.upload.addEventListener("progress",s=>{const i=s;i.percent=s.total>0?s.loaded/s.total*100:0,e.onProgress(i)});const o=new FormData;if(e.data)for(const[s,i]of Object.entries(e.data))Me(i)&&i.length?o.append(s,...i):o.append(s,i);o.append(e.filename,e.file,e.file.name),t.addEventListener("error",()=>{e.onError(E8(n,e,t))}),t.addEventListener("load",()=>{if(t.status<200||t.status>=300)return e.onError(E8(n,e,t));e.onSuccess(Jce(t))}),t.open(e.method,n,!0),e.withCredentials&&"withCredentials"in t&&(t.withCredentials=!0);const r=e.headers||{};if(r instanceof Headers)r.forEach((s,i)=>t.setRequestHeader(i,s));else for(const[s,i]of Object.entries(r))xo(i)||t.setRequestHeader(s,String(i));return t.send(o),t},PO=["text","picture","picture-card"];let Qce=1;const $b=()=>Date.now()+Qce++,LO=We({action:{type:String,default:"#"},headers:{type:Ce(Object)},method:{type:String,default:"post"},data:{type:Ce([Object,Function,Promise]),default:()=>$o({})},multiple:{type:Boolean,default:!1},name:{type:String,default:"file"},drag:{type:Boolean,default:!1},withCredentials:Boolean,showFileList:{type:Boolean,default:!0},accept:{type:String,default:""},fileList:{type:Ce(Array),default:()=>$o([])},autoUpload:{type:Boolean,default:!0},listType:{type:String,values:PO,default:"text"},httpRequest:{type:Ce(Function),default:Xce},disabled:Boolean,limit:Number}),ede=We({...LO,beforeUpload:{type:Ce(Function),default:yt},beforeRemove:{type:Ce(Function)},onRemove:{type:Ce(Function),default:yt},onChange:{type:Ce(Function),default:yt},onPreview:{type:Ce(Function),default:yt},onSuccess:{type:Ce(Function),default:yt},onProgress:{type:Ce(Function),default:yt},onError:{type:Ce(Function),default:yt},onExceed:{type:Ce(Function),default:yt},crossorigin:{type:Ce(String)}}),tde=We({files:{type:Ce(Array),default:()=>$o([])},disabled:{type:Boolean,default:!1},handlePreview:{type:Ce(Function),default:yt},listType:{type:String,values:PO,default:"text"},crossorigin:{type:Ce(String)}}),nde={remove:e=>!!e},ode=["onKeydown"],rde=["src","crossorigin"],sde=["onClick"],ide=["title"],lde=["onClick"],ade=["onClick"],ude=Q({name:"ElUploadList"}),cde=Q({...ude,props:tde,emits:nde,setup(e,{emit:t}){const n=e,{t:o}=Kt(),r=Re("upload"),s=Re("icon"),i=Re("list"),l=Gr(),a=K(!1),u=R(()=>[r.b("list"),r.bm("list",n.listType),r.is("disabled",n.disabled)]),c=d=>{t("remove",d)};return(d,f)=>(C(),q(w0,{tag:"ul",class:D(g(u)),name:g(i).b()},{default:$(()=>[(C(!0),M(fe,null,nt(d.files,p=>(C(),M("li",{key:p.uid||p.name,class:D([g(r).be("list","item"),g(r).is(p.status),{focusing:a.value}]),tabindex:"0",onKeydown:Pt(h=>!g(l)&&c(p),["delete"]),onFocus:f[0]||(f[0]=h=>a.value=!0),onBlur:f[1]||(f[1]=h=>a.value=!1),onClick:f[2]||(f[2]=h=>a.value=!1)},[he(d.$slots,"default",{file:p},()=>[d.listType==="picture"||p.status!=="uploading"&&d.listType==="picture-card"?(C(),M("img",{key:0,class:D(g(r).be("list","item-thumbnail")),src:p.url,crossorigin:d.crossorigin,alt:""},null,10,rde)):W("v-if",!0),p.status==="uploading"||d.listType!=="picture-card"?(C(),M("div",{key:1,class:D(g(r).be("list","item-info"))},[b("a",{class:D(g(r).be("list","item-name")),onClick:et(h=>d.handlePreview(p),["prevent"])},[k(g(Ne),{class:D(g(s).m("document"))},{default:$(()=>[k(g(lZ))]),_:1},8,["class"]),b("span",{class:D(g(r).be("list","item-file-name")),title:p.name},A(p.name),11,ide)],10,sde),p.status==="uploading"?(C(),q(g(gO),{key:0,type:d.listType==="picture-card"?"circle":"line","stroke-width":d.listType==="picture-card"?6:2,percentage:Number(p.percentage),style:Qe(d.listType==="picture-card"?"":"margin-top: 0.5rem")},null,8,["type","stroke-width","percentage","style"])):W("v-if",!0)],2)):W("v-if",!0),b("label",{class:D(g(r).be("list","item-status-label"))},[d.listType==="text"?(C(),q(g(Ne),{key:0,class:D([g(s).m("upload-success"),g(s).m("circle-check")])},{default:$(()=>[k(g(i3))]),_:1},8,["class"])):["picture-card","picture"].includes(d.listType)?(C(),q(g(Ne),{key:1,class:D([g(s).m("upload-success"),g(s).m("check")])},{default:$(()=>[k(g(Yx))]),_:1},8,["class"])):W("v-if",!0)],2),g(l)?W("v-if",!0):(C(),q(g(Ne),{key:2,class:D(g(s).m("close")),onClick:h=>c(p)},{default:$(()=>[k(g(Gs))]),_:2},1032,["class","onClick"])),W(" Due to close btn only appears when li gets focused disappears after li gets blurred, thus keyboard navigation can never reach close btn"),W(" This is a bug which needs to be fixed "),W(" TODO: Fix the incorrect navigation interaction "),g(l)?W("v-if",!0):(C(),M("i",{key:3,class:D(g(s).m("close-tip"))},A(g(o)("el.upload.deleteTip")),3)),d.listType==="picture-card"?(C(),M("span",{key:4,class:D(g(r).be("list","item-actions"))},[b("span",{class:D(g(r).be("list","item-preview")),onClick:h=>d.handlePreview(p)},[k(g(Ne),{class:D(g(s).m("zoom-in"))},{default:$(()=>[k(g(oM))]),_:1},8,["class"])],10,lde),g(l)?W("v-if",!0):(C(),M("span",{key:0,class:D(g(r).be("list","item-delete")),onClick:h=>c(p)},[k(g(Ne),{class:D(g(s).m("delete"))},{default:$(()=>[k(g(Xx))]),_:1},8,["class"])],10,ade))],2)):W("v-if",!0)])],42,ode))),128)),he(d.$slots,"append")]),_:3},8,["class","name"]))}});var x8=ze(cde,[["__file","upload-list.vue"]]);const dde=We({disabled:{type:Boolean,default:!1}}),fde={file:e=>Me(e)},pde=["onDrop","onDragover"],RO="ElUploadDrag",hde=Q({name:RO}),mde=Q({...hde,props:dde,emits:fde,setup(e,{emit:t}){Be(NO)||ws(RO,"usage: <el-upload><el-upload-dragger /></el-upload>");const o=Re("upload"),r=K(!1),s=Gr(),i=a=>{if(s.value)return;r.value=!1,a.stopPropagation();const u=Array.from(a.dataTransfer.files);t("file",u)},l=()=>{s.value||(r.value=!0)};return(a,u)=>(C(),M("div",{class:D([g(o).b("dragger"),g(o).is("dragover",r.value)]),onDrop:et(i,["prevent"]),onDragover:et(l,["prevent"]),onDragleave:u[0]||(u[0]=et(c=>r.value=!1,["prevent"]))},[he(a.$slots,"default")],42,pde))}});var gde=ze(mde,[["__file","upload-dragger.vue"]]);const vde=We({...LO,beforeUpload:{type:Ce(Function),default:yt},onRemove:{type:Ce(Function),default:yt},onStart:{type:Ce(Function),default:yt},onSuccess:{type:Ce(Function),default:yt},onProgress:{type:Ce(Function),default:yt},onError:{type:Ce(Function),default:yt},onExceed:{type:Ce(Function),default:yt}}),yde=["onKeydown"],_de=["name","multiple","accept"],bde=Q({name:"ElUploadContent",inheritAttrs:!1}),wde=Q({...bde,props:vde,setup(e,{expose:t}){const n=e,o=Re("upload"),r=Gr(),s=Tn({}),i=Tn(),l=m=>{if(m.length===0)return;const{autoUpload:y,limit:v,fileList:w,multiple:_,onStart:S,onExceed:x}=n;if(v&&w.length+m.length>v){x(m,w);return}_||(m=m.slice(0,1));for(const E of m){const T=E;T.uid=$b(),S(T),y&&a(T)}},a=async m=>{if(i.value.value="",!n.beforeUpload)return c(m);let y,v={};try{const _=n.data,S=n.beforeUpload(m);v=rg(n.data)?i5(n.data):n.data,y=await S,rg(n.data)&&jl(_,v)&&(v=i5(n.data))}catch{y=!1}if(y===!1){n.onRemove(m);return}let w=m;y instanceof Blob&&(y instanceof File?w=y:w=new File([y],m.name,{type:m.type})),c(Object.assign(w,{uid:m.uid}),v)},u=async(m,y)=>Xe(m)?m(y):m,c=async(m,y)=>{const{headers:v,data:w,method:_,withCredentials:S,name:x,action:E,onProgress:T,onSuccess:O,onError:P,httpRequest:N}=n;try{y=await u(y??w,m)}catch{n.onRemove(m);return}const{uid:F}=m,B={headers:v||{},withCredentials:S,file:m,data:y,method:_,filename:x,action:E,onProgress:Z=>{T(Z,m)},onSuccess:Z=>{O(Z,m),delete s.value[F]},onError:Z=>{P(Z,m),delete s.value[F]}},Y=N(B);s.value[F]=Y,Y instanceof Promise&&Y.then(B.onSuccess,B.onError)},d=m=>{const y=m.target.files;y&&l(Array.from(y))},f=()=>{r.value||(i.value.value="",i.value.click())},p=()=>{f()};return t({abort:m=>{mY(s.value).filter(m?([v])=>String(m.uid)===v:()=>!0).forEach(([v,w])=>{w instanceof XMLHttpRequest&&w.abort(),delete s.value[v]})},upload:a}),(m,y)=>(C(),M("div",{class:D([g(o).b(),g(o).m(m.listType),g(o).is("drag",m.drag)]),tabindex:"0",onClick:f,onKeydown:Pt(et(p,["self"]),["enter","space"])},[m.drag?(C(),q(gde,{key:0,disabled:g(r),onFile:l},{default:$(()=>[he(m.$slots,"default")]),_:3},8,["disabled"])):he(m.$slots,"default",{key:1}),b("input",{ref_key:"inputRef",ref:i,class:D(g(o).e("input")),name:m.name,multiple:m.multiple,accept:m.accept,type:"file",onChange:d,onClick:y[0]||(y[0]=et(()=>{},["stop"]))},null,42,_de)],42,yde))}});var M8=ze(wde,[["__file","upload-content.vue"]]);const T8="ElUpload",O8=e=>{var t;(t=e.url)!=null&&t.startsWith("blob:")&&URL.revokeObjectURL(e.url)},Cde=(e,t)=>{const n=uH(e,"fileList",void 0,{passive:!0}),o=f=>n.value.find(p=>p.uid===f.uid);function r(f){var p;(p=t.value)==null||p.abort(f)}function s(f=["ready","uploading","success","fail"]){n.value=n.value.filter(p=>!f.includes(p.status))}const i=(f,p)=>{const h=o(p);h&&(console.error(f),h.status="fail",n.value.splice(n.value.indexOf(h),1),e.onError(f,h,n.value),e.onChange(h,n.value))},l=(f,p)=>{const h=o(p);h&&(e.onProgress(f,h,n.value),h.status="uploading",h.percentage=Math.round(f.percent))},a=(f,p)=>{const h=o(p);h&&(h.status="success",h.response=f,e.onSuccess(f,h,n.value),e.onChange(h,n.value))},u=f=>{xo(f.uid)&&(f.uid=$b());const p={name:f.name,percentage:0,status:"ready",size:f.size,raw:f,uid:f.uid};if(e.listType==="picture-card"||e.listType==="picture")try{p.url=URL.createObjectURL(f)}catch(h){h.message,e.onError(h,p,n.value)}n.value=[...n.value,p],e.onChange(p,n.value)},c=async f=>{const p=f instanceof File?o(f):f;p||ws(T8,"file to be removed not found");const h=m=>{r(m);const y=n.value;y.splice(y.indexOf(m),1),e.onRemove(m,y),O8(m)};e.beforeRemove?await e.beforeRemove(p,n.value)!==!1&&h(p):h(p)};function d(){n.value.filter(({status:f})=>f==="ready").forEach(({raw:f})=>{var p;return f&&((p=t.value)==null?void 0:p.upload(f))})}return Te(()=>e.listType,f=>{f!=="picture-card"&&f!=="picture"||(n.value=n.value.map(p=>{const{raw:h,url:m}=p;if(!m&&h)try{p.url=URL.createObjectURL(h)}catch(y){e.onError(y,p,n.value)}return p}))}),Te(n,f=>{for(const p of f)p.uid||(p.uid=$b()),p.status||(p.status="success")},{immediate:!0,deep:!0}),{uploadFiles:n,abort:r,clearFiles:s,handleError:i,handleProgress:l,handleStart:u,handleSuccess:a,handleRemove:c,submit:d,revokeFileObjectURL:O8}},kde=Q({name:"ElUpload"}),Sde=Q({...kde,props:ede,setup(e,{expose:t}){const n=e,o=Gr(),r=Tn(),{abort:s,submit:i,clearFiles:l,uploadFiles:a,handleStart:u,handleError:c,handleRemove:d,handleSuccess:f,handleProgress:p,revokeFileObjectURL:h}=Cde(n,r),m=R(()=>n.listType==="picture-card"),y=R(()=>({...n,fileList:a.value,onStart:u,onProgress:p,onSuccess:f,onError:c,onRemove:d}));return En(()=>{a.value.forEach(h)}),wt(NO,{accept:pn(n,"accept")}),t({abort:s,submit:i,clearFiles:l,handleStart:u,handleRemove:d}),(v,w)=>(C(),M("div",null,[g(m)&&v.showFileList?(C(),q(x8,{key:0,disabled:g(o),"list-type":v.listType,files:g(a),crossorigin:v.crossorigin,"handle-preview":v.onPreview,onRemove:g(d)},tu({append:$(()=>[k(M8,un({ref_key:"uploadRef",ref:r},g(y)),{default:$(()=>[v.$slots.trigger?he(v.$slots,"trigger",{key:0}):W("v-if",!0),!v.$slots.trigger&&v.$slots.default?he(v.$slots,"default",{key:1}):W("v-if",!0)]),_:3},16)]),_:2},[v.$slots.file?{name:"default",fn:$(({file:_})=>[he(v.$slots,"file",{file:_})])}:void 0]),1032,["disabled","list-type","files","crossorigin","handle-preview","onRemove"])):W("v-if",!0),!g(m)||g(m)&&!v.showFileList?(C(),q(M8,un({key:1,ref_key:"uploadRef",ref:r},g(y)),{default:$(()=>[v.$slots.trigger?he(v.$slots,"trigger",{key:0}):W("v-if",!0),!v.$slots.trigger&&v.$slots.default?he(v.$slots,"default",{key:1}):W("v-if",!0)]),_:3},16)):W("v-if",!0),v.$slots.trigger?he(v.$slots,"default",{key:2}):W("v-if",!0),he(v.$slots,"tip"),!g(m)&&v.showFileList?(C(),q(x8,{key:3,disabled:g(o),"list-type":v.listType,files:g(a),crossorigin:v.crossorigin,"handle-preview":v.onPreview,onRemove:g(d)},tu({_:2},[v.$slots.file?{name:"default",fn:$(({file:_})=>[he(v.$slots,"file",{file:_})])}:void 0]),1032,["disabled","list-type","files","crossorigin","handle-preview","onRemove"])):W("v-if",!0)]))}});var $de=ze(Sde,[["__file","upload.vue"]]);const DO=Zt($de);function Ede(e){let t;const n=K(!1),o=Dn({...e,originalPosition:"",originalOverflow:"",visible:!1});function r(f){o.text=f}function s(){const f=o.parent,p=d.ns;if(!f.vLoadingAddClassList){let h=f.getAttribute("loading-number");h=Number.parseInt(h)-1,h?f.setAttribute("loading-number",h.toString()):(qs(f,p.bm("parent","relative")),f.removeAttribute("loading-number")),qs(f,p.bm("parent","hidden"))}i(),c.unmount()}function i(){var f,p;(p=(f=d.$el)==null?void 0:f.parentNode)==null||p.removeChild(d.$el)}function l(){var f;e.beforeClose&&!e.beforeClose()||(n.value=!0,clearTimeout(t),t=window.setTimeout(a,400),o.visible=!1,(f=e.closed)==null||f.call(e))}function a(){if(!n.value)return;const f=o.parent;n.value=!1,f.vLoadingAddClassList=void 0,s()}const c=ww(Q({name:"ElLoading",setup(f,{expose:p}){const{ns:h,zIndex:m}=T3("loading");return p({ns:h,zIndex:m}),()=>{const y=o.spinner||o.svg,v=lt("svg",{class:"circular",viewBox:o.svgViewBox?o.svgViewBox:"0 0 50 50",...y?{innerHTML:y}:{}},[lt("circle",{class:"path",cx:"25",cy:"25",r:"20",fill:"none"})]),w=o.text?lt("p",{class:h.b("text")},[o.text]):void 0;return lt(_r,{name:h.b("fade"),onAfterLeave:a},{default:$(()=>[He(k("div",{style:{backgroundColor:o.background||""},class:[h.b("mask"),o.customClass,o.fullscreen?"is-fullscreen":""]},[lt("div",{class:h.b("spinner")},[v,w])]),[[en,o.visible]])])})}}})),d=c.mount(document.createElement("div"));return{...ei(o),setText:r,removeElLoadingChild:i,close:l,handleAfterLeave:a,vm:d,get $el(){return d.$el}}}let _m;const Eb=function(e={}){if(!xt)return;const t=xde(e);if(t.fullscreen&&_m)return _m;const n=Ede({...t,closed:()=>{var r;(r=t.closed)==null||r.call(t),t.fullscreen&&(_m=void 0)}});Mde(t,t.parent,n),I8(t,t.parent,n),t.parent.vLoadingAddClassList=()=>I8(t,t.parent,n);let o=t.parent.getAttribute("loading-number");return o?o=`${Number.parseInt(o)+1}`:o="1",t.parent.setAttribute("loading-number",o),t.parent.appendChild(n.$el),ot(()=>n.visible.value=t.visible),t.fullscreen&&(_m=n),n},xde=e=>{var t,n,o,r;let s;return tt(e.target)?s=(t=document.querySelector(e.target))!=null?t:document.body:s=e.target||document.body,{parent:s===document.body||e.body?document.body:s,background:e.background||"",svg:e.svg||"",svgViewBox:e.svgViewBox||"",spinner:e.spinner||!1,text:e.text||"",fullscreen:s===document.body&&((n=e.fullscreen)!=null?n:!0),lock:(o=e.lock)!=null?o:!1,customClass:e.customClass||"",visible:(r=e.visible)!=null?r:!0,target:s}},Mde=async(e,t,n)=>{const{nextZIndex:o}=n.vm.zIndex||n.vm._.exposed.zIndex,r={};if(e.fullscreen)n.originalPosition.value=kl(document.body,"position"),n.originalOverflow.value=kl(document.body,"overflow"),r.zIndex=o();else if(e.parent===document.body){n.originalPosition.value=kl(document.body,"position"),await ot();for(const s of["top","left"]){const i=s==="top"?"scrollTop":"scrollLeft";r[s]=`${e.target.getBoundingClientRect()[s]+document.body[i]+document.documentElement[i]-Number.parseInt(kl(document.body,`margin-${s}`),10)}px`}for(const s of["height","width"])r[s]=`${e.target.getBoundingClientRect()[s]}px`}else n.originalPosition.value=kl(t,"position");for(const[s,i]of Object.entries(r))n.$el.style[s]=i},I8=(e,t,n)=>{const o=n.vm.ns||n.vm._.exposed.ns;["absolute","fixed","sticky"].includes(n.originalPosition.value)?qs(t,o.bm("parent","relative")):lu(t,o.bm("parent","relative")),e.fullscreen&&e.lock?lu(t,o.bm("parent","hidden")):qs(t,o.bm("parent","hidden"))},i1=Symbol("ElLoading"),A8=(e,t)=>{var n,o,r,s;const i=t.instance,l=f=>ft(t.value)?t.value[f]:void 0,a=f=>{const p=tt(f)&&(i==null?void 0:i[f])||f;return p&&K(p)},u=f=>a(l(f)||e.getAttribute(`element-loading-${zo(f)}`)),c=(n=l("fullscreen"))!=null?n:t.modifiers.fullscreen,d={text:u("text"),svg:u("svg"),svgViewBox:u("svgViewBox"),spinner:u("spinner"),background:u("background"),customClass:u("customClass"),fullscreen:c,target:(o=l("target"))!=null?o:c?void 0:e,body:(r=l("body"))!=null?r:t.modifiers.body,lock:(s=l("lock"))!=null?s:t.modifiers.lock};e[i1]={options:d,instance:Eb(d)}},Tde=(e,t)=>{for(const n of Object.keys(t))on(t[n])&&(t[n].value=e[n])},N8={mounted(e,t){t.value&&A8(e,t)},updated(e,t){const n=e[i1];t.oldValue!==t.value&&(t.value&&!t.oldValue?A8(e,t):t.value&&t.oldValue?ft(t.value)&&Tde(t.value,n.options):n==null||n.instance.close())},unmounted(e){var t;(t=e[i1])==null||t.instance.close(),e[i1]=null}},Ode={install(e){e.directive("loading",N8),e.config.globalProperties.$loading=Eb},directive:N8,service:Eb},Ide=Q({name:"ElMessageBox",directives:{TrapFocus:Gne},components:{ElButton:pt,ElFocusTrap:j0,ElInput:At,ElOverlay:B3,ElIcon:Ne,...hJ},inheritAttrs:!1,props:{buttonSize:{type:String,validator:yJ},modal:{type:Boolean,default:!0},lockScroll:{type:Boolean,default:!0},showClose:{type:Boolean,default:!0},closeOnClickModal:{type:Boolean,default:!0},closeOnPressEscape:{type:Boolean,default:!0},closeOnHashChange:{type:Boolean,default:!0},center:Boolean,draggable:Boolean,overflow:Boolean,roundButton:{default:!1,type:Boolean},container:{type:String,default:"body"},boxType:{type:String,default:""}},emits:["vanish","action"],setup(e,{emit:t}){const{locale:n,zIndex:o,ns:r,size:s}=T3("message-box",R(()=>e.buttonSize)),{t:i}=n,{nextZIndex:l}=o,a=K(!1),u=Dn({autofocus:!0,beforeClose:null,callback:null,cancelButtonText:"",cancelButtonClass:"",confirmButtonText:"",confirmButtonClass:"",customClass:"",customStyle:{},dangerouslyUseHTMLString:!1,distinguishCancelAndClose:!1,icon:"",inputPattern:null,inputPlaceholder:"",inputType:"text",inputValue:null,inputValidator:null,inputErrorMessage:"",message:null,modalFade:!0,modalClass:"",showCancelButton:!1,showConfirmButton:!0,type:"",title:void 0,showInput:!1,action:"",confirmButtonLoading:!1,cancelButtonLoading:!1,confirmButtonDisabled:!1,editorErrorMessage:"",validateError:!1,zIndex:l()}),c=R(()=>{const j=u.type;return{[r.bm("icon",j)]:j&&Og[j]}}),d=Hr(),f=Hr(),p=R(()=>u.icon||Og[u.type]||""),h=R(()=>!!u.message),m=K(),y=K(),v=K(),w=K(),_=K(),S=R(()=>u.confirmButtonClass);Te(()=>u.inputValue,async j=>{await ot(),e.boxType==="prompt"&&j!==null&&B()},{immediate:!0}),Te(()=>a.value,j=>{var V,H;j&&(e.boxType!=="prompt"&&(u.autofocus?v.value=(H=(V=_.value)==null?void 0:V.$el)!=null?H:m.value:v.value=m.value),u.zIndex=l()),e.boxType==="prompt"&&(j?ot().then(()=>{var L;w.value&&w.value.$el&&(u.autofocus?v.value=(L=Y())!=null?L:m.value:v.value=m.value)}):(u.editorErrorMessage="",u.validateError=!1))});const x=R(()=>e.draggable),E=R(()=>e.overflow);uM(m,y,x,E),Ct(async()=>{await ot(),e.closeOnHashChange&&window.addEventListener("hashchange",T)}),En(()=>{e.closeOnHashChange&&window.removeEventListener("hashchange",T)});function T(){a.value&&(a.value=!1,ot(()=>{u.action&&t("action",u.action)}))}const O=()=>{e.closeOnClickModal&&F(u.distinguishCancelAndClose?"close":"cancel")},P=C3(O),N=j=>{if(u.inputType!=="textarea")return j.preventDefault(),F("confirm")},F=j=>{var V;e.boxType==="prompt"&&j==="confirm"&&!B()||(u.action=j,u.beforeClose?(V=u.beforeClose)==null||V.call(u,j,u,T):T())},B=()=>{if(e.boxType==="prompt"){const j=u.inputPattern;if(j&&!j.test(u.inputValue||""))return u.editorErrorMessage=u.inputErrorMessage||i("el.messagebox.error"),u.validateError=!0,!1;const V=u.inputValidator;if(typeof V=="function"){const H=V(u.inputValue);if(H===!1)return u.editorErrorMessage=u.inputErrorMessage||i("el.messagebox.error"),u.validateError=!0,!1;if(typeof H=="string")return u.editorErrorMessage=H,u.validateError=!0,!1}}return u.editorErrorMessage="",u.validateError=!1,!0},Y=()=>{const j=w.value.$refs;return j.input||j.textarea},Z=()=>{F("close")},U=()=>{e.closeOnPressEscape&&Z()};return e.lockScroll&&fM(a),{...ei(u),ns:r,overlayEvent:P,visible:a,hasMessage:h,typeClass:c,contentId:d,inputId:f,btnSize:s,iconComponent:p,confirmButtonClasses:S,rootRef:m,focusStartRef:v,headerRef:y,inputRef:w,confirmRef:_,doClose:T,handleClose:Z,onCloseRequested:U,handleWrapperClick:O,handleInputEnter:N,handleAction:F,t:i}}}),Ade=["aria-label","aria-describedby"],Nde=["aria-label"],Pde=["id"];function Lde(e,t,n,o,r,s){const i=re("el-icon"),l=re("close"),a=re("el-input"),u=re("el-button"),c=re("el-focus-trap"),d=re("el-overlay");return C(),q(_r,{name:"fade-in-linear",onAfterLeave:t[11]||(t[11]=f=>e.$emit("vanish")),persisted:""},{default:$(()=>[He(k(d,{"z-index":e.zIndex,"overlay-class":[e.ns.is("message-box"),e.modalClass],mask:e.modal},{default:$(()=>[b("div",{role:"dialog","aria-label":e.title,"aria-modal":"true","aria-describedby":e.showInput?void 0:e.contentId,class:D(`${e.ns.namespace.value}-overlay-message-box`),onClick:t[8]||(t[8]=(...f)=>e.overlayEvent.onClick&&e.overlayEvent.onClick(...f)),onMousedown:t[9]||(t[9]=(...f)=>e.overlayEvent.onMousedown&&e.overlayEvent.onMousedown(...f)),onMouseup:t[10]||(t[10]=(...f)=>e.overlayEvent.onMouseup&&e.overlayEvent.onMouseup(...f))},[k(c,{loop:"",trapped:e.visible,"focus-trap-el":e.rootRef,"focus-start-el":e.focusStartRef,onReleaseRequested:e.onCloseRequested},{default:$(()=>[b("div",{ref:"rootRef",class:D([e.ns.b(),e.customClass,e.ns.is("draggable",e.draggable),{[e.ns.m("center")]:e.center}]),style:Qe(e.customStyle),tabindex:"-1",onClick:t[7]||(t[7]=et(()=>{},["stop"]))},[e.title!==null&&e.title!==void 0?(C(),M("div",{key:0,ref:"headerRef",class:D([e.ns.e("header"),{"show-close":e.showClose}])},[b("div",{class:D(e.ns.e("title"))},[e.iconComponent&&e.center?(C(),q(i,{key:0,class:D([e.ns.e("status"),e.typeClass])},{default:$(()=>[(C(),q(Lt(e.iconComponent)))]),_:1},8,["class"])):W("v-if",!0),b("span",null,A(e.title),1)],2),e.showClose?(C(),M("button",{key:0,type:"button",class:D(e.ns.e("headerbtn")),"aria-label":e.t("el.messagebox.close"),onClick:t[0]||(t[0]=f=>e.handleAction(e.distinguishCancelAndClose?"close":"cancel")),onKeydown:t[1]||(t[1]=Pt(et(f=>e.handleAction(e.distinguishCancelAndClose?"close":"cancel"),["prevent"]),["enter"]))},[k(i,{class:D(e.ns.e("close"))},{default:$(()=>[k(l)]),_:1},8,["class"])],42,Nde)):W("v-if",!0)],2)):W("v-if",!0),b("div",{id:e.contentId,class:D(e.ns.e("content"))},[b("div",{class:D(e.ns.e("container"))},[e.iconComponent&&!e.center&&e.hasMessage?(C(),q(i,{key:0,class:D([e.ns.e("status"),e.typeClass])},{default:$(()=>[(C(),q(Lt(e.iconComponent)))]),_:1},8,["class"])):W("v-if",!0),e.hasMessage?(C(),M("div",{key:1,class:D(e.ns.e("message"))},[he(e.$slots,"default",{},()=>[e.dangerouslyUseHTMLString?(C(),q(Lt(e.showInput?"label":"p"),{key:1,for:e.showInput?e.inputId:void 0,innerHTML:e.message},null,8,["for","innerHTML"])):(C(),q(Lt(e.showInput?"label":"p"),{key:0,for:e.showInput?e.inputId:void 0},{default:$(()=>[ne(A(e.dangerouslyUseHTMLString?"":e.message),1)]),_:1},8,["for"]))])],2)):W("v-if",!0)],2),He(b("div",{class:D(e.ns.e("input"))},[k(a,{id:e.inputId,ref:"inputRef",modelValue:e.inputValue,"onUpdate:modelValue":t[2]||(t[2]=f=>e.inputValue=f),type:e.inputType,placeholder:e.inputPlaceholder,"aria-invalid":e.validateError,class:D({invalid:e.validateError}),onKeydown:Pt(e.handleInputEnter,["enter"])},null,8,["id","modelValue","type","placeholder","aria-invalid","class","onKeydown"]),b("div",{class:D(e.ns.e("errormsg")),style:Qe({visibility:e.editorErrorMessage?"visible":"hidden"})},A(e.editorErrorMessage),7)],2),[[en,e.showInput]])],10,Pde),b("div",{class:D(e.ns.e("btns"))},[e.showCancelButton?(C(),q(u,{key:0,loading:e.cancelButtonLoading,class:D([e.cancelButtonClass]),round:e.roundButton,size:e.btnSize,onClick:t[3]||(t[3]=f=>e.handleAction("cancel")),onKeydown:t[4]||(t[4]=Pt(et(f=>e.handleAction("cancel"),["prevent"]),["enter"]))},{default:$(()=>[ne(A(e.cancelButtonText||e.t("el.messagebox.cancel")),1)]),_:1},8,["loading","class","round","size"])):W("v-if",!0),He(k(u,{ref:"confirmRef",type:"primary",loading:e.confirmButtonLoading,class:D([e.confirmButtonClasses]),round:e.roundButton,disabled:e.confirmButtonDisabled,size:e.btnSize,onClick:t[5]||(t[5]=f=>e.handleAction("confirm")),onKeydown:t[6]||(t[6]=Pt(et(f=>e.handleAction("confirm"),["prevent"]),["enter"]))},{default:$(()=>[ne(A(e.confirmButtonText||e.t("el.messagebox.confirm")),1)]),_:1},8,["loading","class","round","disabled","size"]),[[en,e.showConfirmButton]])],2)],6)]),_:3},8,["trapped","focus-trap-el","focus-start-el","onReleaseRequested"])],42,Ade)]),_:3},8,["z-index","overlay-class","mask"]),[[en,e.visible]])]),_:3})}var Rde=ze(Ide,[["render",Lde],["__file","index.vue"]]);const Vp=new Map,Dde=e=>{let t=document.body;return e.appendTo&&(tt(e.appendTo)&&(t=document.querySelector(e.appendTo)),gs(e.appendTo)&&(t=e.appendTo),gs(t)||(t=document.body)),t},Fde=(e,t,n=null)=>{const o=k(Rde,e,Xe(e.message)||yo(e.message)?{default:Xe(e.message)?e.message:()=>e.message}:null);return o.appContext=n,Ni(o,t),Dde(e).appendChild(t.firstElementChild),o.component},Vde=()=>document.createElement("div"),Bde=(e,t)=>{const n=Vde();e.onVanish=()=>{Ni(null,n),Vp.delete(r)},e.onAction=s=>{const i=Vp.get(r);let l;e.showInput?l={value:r.inputValue,action:s}:l=s,e.callback?e.callback(l,o.proxy):s==="cancel"||s==="close"?e.distinguishCancelAndClose&&s!=="cancel"?i.reject("close"):i.reject("cancel"):i.resolve(l)};const o=Fde(e,n,t),r=o.proxy;for(const s in e)vt(e,s)&&!vt(r.$props,s)&&(r[s]=e[s]);return r.visible=!0,r};function xd(e,t=null){if(!xt)return Promise.reject();let n;return tt(e)||yo(e)?e={message:e}:n=e.callback,new Promise((o,r)=>{const s=Bde(e,t??xd._context);Vp.set(s,{options:e,callback:n,resolve:o,reject:r})})}const zde=["alert","confirm","prompt"],jde={alert:{closeOnPressEscape:!1,closeOnClickModal:!1},confirm:{showCancelButton:!0},prompt:{showCancelButton:!0,showInput:!0}};zde.forEach(e=>{xd[e]=Hde(e)});function Hde(e){return(t,n,o,r)=>{let s="";return ft(n)?(o=n,s=""):Uo(n)?s="":s=n,xd(Object.assign({title:s,message:t,type:"",...jde[e]},o,{boxType:e}),r)}}xd.close=()=>{Vp.forEach((e,t)=>{t.doClose()}),Vp.clear()};xd._context=null;const nl=xd;nl.install=e=>{nl._context=e._context,e.config.globalProperties.$msgbox=nl,e.config.globalProperties.$messageBox=nl,e.config.globalProperties.$alert=nl.alert,e.config.globalProperties.$confirm=nl.confirm,e.config.globalProperties.$prompt=nl.prompt};const fy=nl,FO=["success","info","warning","error"],Ude=We({customClass:{type:String,default:""},dangerouslyUseHTMLString:{type:Boolean,default:!1},duration:{type:Number,default:4500},icon:{type:Oo},id:{type:String,default:""},message:{type:Ce([String,Object]),default:""},offset:{type:Number,default:0},onClick:{type:Ce(Function),default:()=>{}},onClose:{type:Ce(Function),required:!0},position:{type:String,values:["top-right","top-left","bottom-right","bottom-left"],default:"top-right"},showClose:{type:Boolean,default:!0},title:{type:String,default:""},type:{type:String,values:[...FO,""],default:""},zIndex:Number}),Wde={destroy:()=>!0},Kde=["id"],qde=["textContent"],Gde={key:0},Yde=["innerHTML"],Zde=Q({name:"ElNotification"}),Jde=Q({...Zde,props:Ude,emits:Wde,setup(e,{expose:t}){const n=e,{ns:o,zIndex:r}=T3("notification"),{nextZIndex:s,currentZIndex:i}=r,{Close:l}=sM,a=K(!1);let u;const c=R(()=>{const _=n.type;return _&&Og[n.type]?o.m(_):""}),d=R(()=>n.type&&Og[n.type]||n.icon),f=R(()=>n.position.endsWith("right")?"right":"left"),p=R(()=>n.position.startsWith("top")?"top":"bottom"),h=R(()=>{var _;return{[p.value]:`${n.offset}px`,zIndex:(_=n.zIndex)!=null?_:i.value}});function m(){n.duration>0&&({stop:u}=V_(()=>{a.value&&v()},n.duration))}function y(){u==null||u()}function v(){a.value=!1}function w({code:_}){_===rt.delete||_===rt.backspace?y():_===rt.esc?a.value&&v():m()}return Ct(()=>{m(),s(),a.value=!0}),Ln(document,"keydown",w),t({visible:a,close:v}),(_,S)=>(C(),q(_r,{name:g(o).b("fade"),onBeforeLeave:_.onClose,onAfterLeave:S[1]||(S[1]=x=>_.$emit("destroy")),persisted:""},{default:$(()=>[He(b("div",{id:_.id,class:D([g(o).b(),_.customClass,g(f)]),style:Qe(g(h)),role:"alert",onMouseenter:y,onMouseleave:m,onClick:S[0]||(S[0]=(...x)=>_.onClick&&_.onClick(...x))},[g(d)?(C(),q(g(Ne),{key:0,class:D([g(o).e("icon"),g(c)])},{default:$(()=>[(C(),q(Lt(g(d))))]),_:1},8,["class"])):W("v-if",!0),b("div",{class:D(g(o).e("group"))},[b("h2",{class:D(g(o).e("title")),textContent:A(_.title)},null,10,qde),He(b("div",{class:D(g(o).e("content")),style:Qe(_.title?void 0:{margin:0})},[he(_.$slots,"default",{},()=>[_.dangerouslyUseHTMLString?(C(),M(fe,{key:1},[W(" Caution here, message could've been compromised, never use user's input as message "),b("p",{innerHTML:_.message},null,8,Yde)],2112)):(C(),M("p",Gde,A(_.message),1))])],6),[[en,_.message]]),_.showClose?(C(),q(g(Ne),{key:0,class:D(g(o).e("closeBtn")),onClick:et(v,["stop"])},{default:$(()=>[k(g(l))]),_:1},8,["class","onClick"])):W("v-if",!0)],2)],46,Kde),[[en,a.value]])]),_:3},8,["name","onBeforeLeave"]))}});var Xde=ze(Jde,[["__file","notification.vue"]]);const Fg={"top-left":[],"top-right":[],"bottom-left":[],"bottom-right":[]},xb=16;let Qde=1;const ad=function(e={},t=null){if(!xt)return{close:()=>{}};(typeof e=="string"||yo(e))&&(e={message:e});const n=e.position||"top-right";let o=e.offset||0;Fg[n].forEach(({vm:c})=>{var d;o+=(((d=c.el)==null?void 0:d.offsetHeight)||0)+xb}),o+=xb;const r=`notification_${Qde++}`,s=e.onClose,i={...e,offset:o,id:r,onClose:()=>{efe(r,n,s)}};let l=document.body;gs(e.appendTo)?l=e.appendTo:tt(e.appendTo)&&(l=document.querySelector(e.appendTo)),gs(l)||(l=document.body);const a=document.createElement("div"),u=k(Xde,i,yo(i.message)?{default:()=>i.message}:null);return u.appContext=t??ad._context,u.props.onDestroy=()=>{Ni(null,a)},Ni(u,a),Fg[n].push({vm:u}),l.appendChild(a.firstElementChild),{close:()=>{u.component.exposed.visible.value=!1}}};FO.forEach(e=>{ad[e]=(t={})=>((typeof t=="string"||yo(t))&&(t={message:t}),ad({...t,type:e}))});function efe(e,t,n){const o=Fg[t],r=o.findIndex(({vm:u})=>{var c;return((c=u.component)==null?void 0:c.props.id)===e});if(r===-1)return;const{vm:s}=o[r];if(!s)return;n==null||n(s);const i=s.el.offsetHeight,l=t.split("-")[0];o.splice(r,1);const a=o.length;if(!(a<1))for(let u=r;u<a;u++){const{el:c,component:d}=o[u].vm,f=Number.parseInt(c.style[l],10)-i-xb;d.props.offset=f}}function tfe(){for(const e of Object.values(Fg))e.forEach(({vm:t})=>{t.component.exposed.visible.value=!1})}ad.closeAll=tfe;ad._context=null;const nfe=mJ(ad,"$notify"),qe=(e,t)=>{const n=e.__vccOpts||e;for(const[o,r]of t)n[o]=r;return n},ofe={name:"PortalApplication",components:{},data(){return{loading:!1,hasSearchHolder:!1,hasNotificationHolder:!1,isSmallScreen:!1,menuItems:[{label:this.$t("General"),route:"settings",icon_svg:'<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M2.08301 10.0002C2.08301 6.26821 2.08301 4.40223 3.24238 3.24287C4.40175 2.0835 6.26772 2.0835 9.99967 2.0835C13.7316 2.0835 15.5976 2.0835 16.757 3.24287C17.9163 4.40223 17.9163 6.26821 17.9163 10.0002C17.9163 13.7321 17.9163 15.5981 16.757 16.7575C15.5976 17.9168 13.7316 17.9168 9.99967 17.9168C6.26772 17.9168 4.40175 17.9168 3.24238 16.7575C2.08301 15.5981 2.08301 13.7321 2.08301 10.0002Z" stroke="currentColor" stroke-width="1.5" stroke-linejoin="round"/><path d="M8.33301 12.917C8.33301 13.6073 7.77336 14.167 7.08301 14.167C6.39265 14.167 5.83301 13.6073 5.83301 12.917C5.83301 12.2266 6.39265 11.667 7.08301 11.667C7.77336 11.667 8.33301 12.2266 8.33301 12.917Z" stroke="currentColor" stroke-width="1.5"/><path d="M14.166 7.0835C14.166 6.39314 13.6064 5.8335 12.916 5.8335C12.2257 5.8335 11.666 6.39314 11.666 7.0835C11.666 7.77385 12.2257 8.3335 12.916 8.3335C13.6064 8.3335 14.166 7.77385 14.166 7.0835Z" stroke="currentColor" stroke-width="1.5"/><path d="M7.08301 11.6668L7.08301 5.8335" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"/><path d="M12.916 8.33366L12.916 14.167" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"/></svg>'},{label:this.$t("Customizations"),route:"customization",icon_svg:'<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_3687_33463)"><path d="M18.3337 9.99984C18.3337 5.39746 14.6027 1.6665 10.0003 1.6665C5.39795 1.6665 1.66699 5.39746 1.66699 9.99984C1.66699 14.6022 5.39795 18.3332 10.0003 18.3332C10.7018 18.3332 11.667 18.4301 11.667 17.4998C11.667 16.9924 11.403 16.6008 11.1408 16.2119C10.7572 15.6428 10.3773 15.0793 10.8337 14.1665C11.3892 13.0554 12.3152 13.0554 13.7349 13.0554C14.4448 13.0554 15.2781 13.0554 16.2504 12.9165C18.0012 12.6664 18.3337 11.5902 18.3337 9.99984Z" stroke="currentColor" stroke-width="1.5"/><path d="M5.83398 12.502L5.84121 12.5" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"/><ellipse cx="7.91699" cy="7.08301" rx="1.25" ry="1.25" stroke="currentColor" stroke-width="1.5"/><ellipse cx="13.75" cy="7.9165" rx="1.25" ry="1.25" stroke="currentColor" stroke-width="1.5"/></g><defs><clipPath id="clip0_3687_33463"><rect width="20" height="20" fill="white"/></clipPath></defs></svg>'},{label:this.$t("Managers"),route:"admin_moderators",icon_svg:'<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M17.3117 15C17.9361 15 18.4328 14.6071 18.8787 14.0576C19.7916 12.9329 18.2928 12.034 17.7211 11.5938C17.14 11.1463 16.4912 10.8928 15.8333 10.8333M15 9.16667C16.1506 9.16667 17.0833 8.23393 17.0833 7.08333C17.0833 5.93274 16.1506 5 15 5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"/><path d="M2.68797 15C2.06355 15 1.5669 14.6071 1.12096 14.0576C0.208082 12.9329 1.7069 12.034 2.27855 11.5938C2.85965 11.1463 3.50849 10.8928 4.16634 10.8333M4.58301 9.16667C3.43241 9.16667 2.49967 8.23393 2.49967 7.08333C2.49967 5.93274 3.43241 5 4.58301 5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"/><path d="M6.73618 12.593C5.8847 13.1195 3.65216 14.1946 5.01192 15.5398C5.67616 16.197 6.41594 16.667 7.34603 16.667H12.6533C13.5834 16.667 14.3232 16.197 14.9874 15.5398C16.3472 14.1946 14.1147 13.1195 13.2632 12.593C11.2665 11.3583 8.73289 11.3583 6.73618 12.593Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/><path d="M12.9163 6.25016C12.9163 7.86099 11.6105 9.16683 9.99967 9.16683C8.38884 9.16683 7.08301 7.86099 7.08301 6.25016C7.08301 4.63933 8.38884 3.3335 9.99967 3.3335C11.6105 3.3335 12.9163 4.63933 12.9163 6.25016Z" stroke="currentColor" stroke-width="1.5"/></svg>'},{label:this.$t("Email Settings"),route:"email_notifications",icon_svg:'<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M5.83398 7.08301L8.28566 8.53253C9.715 9.37761 10.2863 9.37761 11.7156 8.53253L14.1673 7.08301" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/><path d="M1.68013 11.2295C1.73461 13.7841 1.76185 15.0614 2.70446 16.0076C3.64706 16.9538 4.95894 16.9868 7.58268 17.0527C9.19975 17.0933 10.8009 17.0933 12.418 17.0527C15.0417 16.9868 16.3536 16.9538 17.2962 16.0076C18.2388 15.0614 18.266 13.7841 18.3205 11.2295C18.338 10.4081 18.338 9.59157 18.3205 8.77017C18.266 6.21555 18.2388 4.93825 17.2962 3.99206C16.3536 3.04586 15.0417 3.0129 12.418 2.94698C10.8009 2.90635 9.19975 2.90635 7.58268 2.94697C4.95893 3.01289 3.64706 3.04585 2.70445 3.99204C1.76184 4.93824 1.73461 6.21554 1.68013 8.77015C1.66261 9.59156 1.66261 10.4081 1.68013 11.2295Z" stroke="currentColor" stroke-width="1.5" stroke-linejoin="round"/></svg>'},{label:this.$t("Features & Addons"),route:"features",icon_svg:'<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_3687_33503)"><path d="M3.33301 10.0002C3.33301 6.85746 3.33301 5.28612 4.30932 4.3098C5.28563 3.3335 6.85697 3.3335 9.99967 3.3335C13.1423 3.3335 14.7138 3.3335 15.69 4.3098C16.6663 5.28612 16.6663 6.85746 16.6663 10.0002C16.6663 13.1428 16.6663 14.7142 15.69 15.6905C14.7138 16.6668 13.1423 16.6668 9.99967 16.6668C6.85697 16.6668 5.28563 16.6668 4.30932 15.6905C3.33301 14.7142 3.33301 13.1428 3.33301 10.0002Z" stroke="currentColor" stroke-width="1.5" stroke-linejoin="round"/><path d="M6.4432 13.5567C7.0534 14.1668 8.03549 14.1668 9.99967 14.1668C10.6578 14.1668 11.2058 14.1668 11.6663 14.1438L14.1433 11.6668C14.1663 11.2062 14.1663 10.6583 14.1663 10.0002C14.1663 8.03598 14.1663 7.05389 13.5562 6.44369C12.9459 5.8335 11.9638 5.8335 9.99967 5.8335C8.03549 5.8335 7.0534 5.8335 6.4432 6.44369C5.83301 7.05389 5.83301 8.03598 5.83301 10.0002C5.83301 11.9643 5.83301 12.9464 6.4432 13.5567Z" stroke="currentColor" stroke-width="1.5" stroke-linejoin="round"/><path d="M6.66699 1.6665V3.33317M13.3337 1.6665V3.33317M10.0003 1.6665V3.33317M6.66699 16.6665V18.3332M10.0003 16.6665V18.3332M13.3337 16.6665V18.3332M18.3337 13.3332H16.667M3.33366 6.6665H1.66699M3.33366 13.3332H1.66699M3.33366 9.99984H1.66699M18.3337 6.6665H16.667M18.3337 9.99984H16.667" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></g><defs><clipPath id="clip0_3687_33503"><rect width="20" height="20" fill="white"/></clipPath></defs></svg>'},{label:this.$t("Manage Topics"),route:"all_topics",icon_svg:'<svg viewBox="0 0 24 24" width="20" height="20" color="currentColor" fill="none"><path d="M2.73552 11.6867C1.78253 12.7511 1.76203 14.3569 2.63665 15.4865C4.37226 17.7281 6.2719 19.6277 8.51351 21.3633C9.64313 22.238 11.2489 22.2175 12.3133 21.2645C15.203 18.6771 17.8494 15.9731 20.4033 13.0016C20.6558 12.7078 20.8137 12.3477 20.8492 11.9619C21.0059 10.2561 21.3279 5.34144 19.9932 4.00675C18.6586 2.67207 13.7439 2.99408 12.0381 3.15083C11.6523 3.18627 11.2922 3.34421 10.9984 3.59671C8.02692 6.15064 5.32291 8.797 2.73552 11.6867Z" stroke="currentColor" stroke-width="1.5" /><path opacity="0.4" d="M7.5 14.5L9.5 16.5" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" /><path d="M18 6L22 2" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" /></svg>'},{label:this.$t("Space Groups"),route:"space_groups",icon_svg:'<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_3687_33515)"><path d="M5.00033 3.33317C5.00033 4.25365 4.25413 4.99984 3.33366 4.99984C2.41318 4.99984 1.66699 4.25365 1.66699 3.33317C1.66699 2.4127 2.41318 1.6665 3.33366 1.6665C4.25413 1.6665 5.00033 2.4127 5.00033 3.33317Z" stroke="currentColor" stroke-width="1.5"/><path d="M18.3333 3.33317C18.3333 4.25365 17.5872 4.99984 16.6667 4.99984C15.7462 4.99984 15 4.25365 15 3.33317C15 2.4127 15.7462 1.6665 16.6667 1.6665C17.5872 1.6665 18.3333 2.4127 18.3333 3.33317Z" stroke="currentColor" stroke-width="1.5"/><path d="M18.3333 16.6667C18.3333 17.5872 17.5872 18.3333 16.6667 18.3333C15.7462 18.3333 15 17.5872 15 16.6667C15 15.7462 15.7462 15 16.6667 15C17.5872 15 18.3333 15.7462 18.3333 16.6667Z" stroke="currentColor" stroke-width="1.5"/><path d="M5.00033 16.6667C5.00033 17.5872 4.25413 18.3333 3.33366 18.3333C2.41318 18.3333 1.66699 17.5872 1.66699 16.6667C1.66699 15.7462 2.41318 15 3.33366 15C4.25413 15 5.00033 15.7462 5.00033 16.6667Z" stroke="currentColor" stroke-width="1.5"/><path d="M16.6663 5.00016V15.0002M14.9997 16.6668H4.99967M14.9997 3.3335H4.99967M3.33301 5.00016V15.0002" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/><path d="M13.75 7.5C13.75 7.11172 13.75 6.91758 13.6866 6.76443C13.602 6.56024 13.4397 6.39801 13.2356 6.31343C13.0824 6.25 12.8882 6.25 12.5 6.25H7.5C7.11172 6.25 6.91758 6.25 6.76443 6.31343C6.56024 6.39801 6.39801 6.56024 6.31343 6.76443C6.25 6.91758 6.25 7.11172 6.25 7.5C6.25 7.88828 6.25 8.08242 6.31343 8.23557C6.39801 8.43975 6.56024 8.602 6.76443 8.68658C6.91758 8.75 7.11172 8.75 7.5 8.75H12.5C12.8882 8.75 13.0824 8.75 13.2356 8.68658C13.4397 8.602 13.602 8.43975 13.6866 8.23557C13.75 8.08242 13.75 7.88828 13.75 7.5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/><path d="M13.75 12.5C13.75 12.1117 13.75 11.9176 13.6866 11.7644C13.602 11.5603 13.4397 11.398 13.2356 11.3134C13.0824 11.25 12.8882 11.25 12.5 11.25H7.5C7.11172 11.25 6.91758 11.25 6.76443 11.3134C6.56024 11.398 6.39801 11.5603 6.31343 11.7644C6.25 11.9176 6.25 12.1117 6.25 12.5C6.25 12.8882 6.25 13.0824 6.31343 13.2356C6.39801 13.4397 6.56024 13.602 6.76443 13.6866C6.91758 13.75 7.11172 13.75 7.5 13.75H12.5C12.8882 13.75 13.0824 13.75 13.2356 13.6866C13.4397 13.602 13.602 13.4397 13.6866 13.2356C13.75 13.0824 13.75 12.8882 13.75 12.5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></g><defs><clipPath id="clip0_3687_33515"><rect width="20" height="20" fill="white"/></clipPath></defs></svg>'},{label:this.$t("Menu Settings"),route:"menu_settings",icon_svg:'<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M8.33301 4.1665L16.6663 4.1665" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/><path d="M3.33301 10L16.6663 10" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/><path d="M3.33301 15.833L11.6663 15.833" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg>'}]}},watch:{},methods:{},created(){this.isSmallScreen=window.innerWidth<=1024},mounted(){}},rfe={class:"fcom_general_menu"},sfe=["href"],ife={class:"el-icon"},lfe={class:"fcom_communities_menu"},afe={style:{"margin-left":"18px","font-size":"0.875rem","font-weight":"bold","margin-bottom":"10px",color:"currentColor"}},ufe={style:{"margin-bottom":"30px"},class:"fcom_general_menu"},cfe={class:"community_avatar"},dfe={class:"fcom_shape"},ffe={class:"community_name"},pfe={style:{"margin-left":"18px","font-size":"0.875rem","font-weight":"bold","margin-bottom":"10px",color:"currentColor"}},hfe={class:"fcom_general_menu"},mfe={class:"community_avatar"},gfe={class:"fcom_shape"},vfe=b("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},[b("path",{d:"M10.734 5.84746L14.7114 6.9072M9.88139 9.01146L11.8701 9.54132M9.98031 14.9723L10.7758 15.1843C13.0258 15.7838 14.1508 16.0835 15.037 15.5747C15.9233 15.0659 16.2247 13.9473 16.8276 11.71L17.6802 8.54599C18.2831 6.3087 18.5845 5.19006 18.0728 4.30879C17.5611 3.42752 16.4362 3.12778 14.1862 2.52831L13.3907 2.31636C11.1407 1.71688 10.0157 1.41714 9.12948 1.92594C8.24322 2.43474 7.94178 3.55338 7.3389 5.79067L6.4863 8.95466C5.88342 11.1919 5.58198 12.3106 6.09367 13.1919C6.60536 14.0731 7.73034 14.3729 9.98031 14.9723Z",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round"}),b("path",{d:"M9.99996 17.4559L9.20634 17.672C6.96165 18.2832 5.83931 18.5889 4.95512 18.0701C4.07093 17.5513 3.7702 16.4107 3.16874 14.1295L2.31814 10.9035C1.71668 8.62232 1.41595 7.48174 1.92643 6.58318C2.36802 5.80591 3.33329 5.83421 4.58329 5.83411",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round"})],-1),yfe={class:"community_name"};function _fe(e,t,n,o,r,s){const i=re("router-view"),l=re("Back"),a=Ne,u=re("router-link");return C(),M(fe,null,[k(i,{class:D(e.appVars.route_classes)},null,8,["class"]),(C(),q(_s,{to:"#fcom_menu_sidebar"},[b("ul",rfe,[b("li",null,[b("a",{href:e.appVars.portal_url},[b("i",ife,[k(l)]),b("span",null,A(e.$t("Back to home")),1)],8,sfe)])]),b("div",lfe,[b("h4",afe,A(e.$t("Portal Settings")),1),b("ul",ufe,[(C(!0),M(fe,null,nt(r.menuItems,c=>(C(),M("li",{key:c.name,class:D("course_inner_menu_"+c.name)},[k(u,{to:{name:c.route}},{default:$(()=>[b("div",cfe,[b("span",dfe,[k(a,{innerHTML:c.icon_svg},null,8,["innerHTML"])])]),b("span",ffe,A(c.label),1)]),_:2},1032,["to"])],2))),128))]),e.hasFeature("has_course")?(C(),M(fe,{key:0},[b("h4",pfe,A(e.$t("Course Management")),1),b("ul",hfe,[b("li",null,[k(u,{to:{name:"manage_courses"}},{default:$(()=>[b("div",mfe,[b("span",gfe,[k(a,null,{default:$(()=>[vfe]),_:1})])]),b("span",yfe,A(e.$t("Manage Courses")),1)]),_:1})])])],64)):W("",!0)])]))],64)}const bfe=qe(ofe,[["render",_fe]]),wfe={name:"SettingsRoute",components:{},data(){return{loading:!1}}};function Cfe(e,t,n,o,r,s){const i=re("router-view");return C(),q(i)}const kfe=qe(wfe,[["render",Cfe]]),Sfe={name:"ImageUploader",emits:["uploaded","completed","uploading"],data(){return{loading:!1}},props:{button_text:{type:String,default:"Upload Photo"},additionalData:{type:Object,default:()=>({})},isMultiple:{type:Boolean,default:!1},can_remove:{type:Boolean,default:!1},isTextBtn:{type:Boolean,default:!0},removeIcon:{type:Boolean,default:!0},className:{type:String,default:"image-uploader"}},methods:{handleSuccess(e){this.$emit("uploaded",e.media.url),this.$emit("completed",e),this.loading=!1},handleError(e){this.$handleError(JSON.parse(e.message)),this.$emit("completed",e),this.loading=!1},inProgress(e){this.$emit("uploading"),this.loading=!0}},computed:{action_url(){return this.appVars.rest.url+"/feeds/media-upload"},headers(){return{"X-WP-Nonce":this.appVars.rest.nonce}}}};function $fe(e,t,n,o,r,s){const i=pt,l=DO,a=re("CloseBold"),u=Ne,c=zt("loading");return C(),M(fe,null,[k(l,{class:D(n.className),multiple:n.isMultiple,action:s.action_url,headers:s.headers,accept:"image/*",data:n.additionalData,"on-success":s.handleSuccess,"on-progress":s.inProgress,"on-error":s.handleError,"show-file-list":!1},{default:$(()=>[he(e.$slots,"trigger",{},()=>[he(e.$slots,"default",{},()=>[He((C(),q(i,{disabled:r.loading,text:n.isTextBtn,class:"fcom_plain_button"},{default:$(()=>[ne(A(n.button_text),1)]),_:1},8,["disabled","text"])),[[c,r.loading]])])])]),_:3},8,["class","multiple","action","headers","data","on-success","on-progress","on-error"]),n.can_remove?(C(),q(i,{key:0,class:"remove_img",size:"small",type:"danger",plain:"",onClick:t[0]||(t[0]=d=>e.$emit("uploaded","")),text:n.isTextBtn},{default:$(()=>[n.removeIcon?(C(),q(u,{key:0},{default:$(()=>[k(a)]),_:1})):W("",!0),b("span",null,A(e.$t("Remove")),1)]),_:1},8,["text"])):W("",!0)],64)}const Md=qe(Sfe,[["render",$fe]]);function Efe(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Ch=Efe,xfe=typeof On=="object"&&On&&On.Object===Object&&On,VO=xfe,Mfe=VO,Tfe=typeof self=="object"&&self&&self.Object===Object&&self,Ofe=Mfe||Tfe||Function("return this")(),zi=Ofe,Ife=zi,Afe=function(){return Ife.Date.now()},Nfe=Afe,Pfe=/\s/;function Lfe(e){for(var t=e.length;t--&&Pfe.test(e.charAt(t)););return t}var Rfe=Lfe,Dfe=Rfe,Ffe=/^\s+/;function Vfe(e){return e&&e.slice(0,Dfe(e)+1).replace(Ffe,"")}var Bfe=Vfe,zfe=zi,jfe=zfe.Symbol,BO=jfe,P8=BO,zO=Object.prototype,Hfe=zO.hasOwnProperty,Ufe=zO.toString,Kd=P8?P8.toStringTag:void 0;function Wfe(e){var t=Hfe.call(e,Kd),n=e[Kd];try{e[Kd]=void 0;var o=!0}catch{}var r=Ufe.call(e);return o&&(t?e[Kd]=n:delete e[Kd]),r}var Kfe=Wfe,qfe=Object.prototype,Gfe=qfe.toString;function Yfe(e){return Gfe.call(e)}var Zfe=Yfe,L8=BO,Jfe=Kfe,Xfe=Zfe,Qfe="[object Null]",epe="[object Undefined]",R8=L8?L8.toStringTag:void 0;function tpe(e){return e==null?e===void 0?epe:Qfe:R8&&R8 in Object(e)?Jfe(e):Xfe(e)}var kh=tpe;function npe(e){return e!=null&&typeof e=="object"}var J0=npe,ope=kh,rpe=J0,spe="[object Symbol]";function ipe(e){return typeof e=="symbol"||rpe(e)&&ope(e)==spe}var lpe=ipe,ape=Bfe,D8=Ch,upe=lpe,F8=0/0,cpe=/^[-+]0x[0-9a-f]+$/i,dpe=/^0b[01]+$/i,fpe=/^0o[0-7]+$/i,ppe=parseInt;function hpe(e){if(typeof e=="number")return e;if(upe(e))return F8;if(D8(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=D8(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=ape(e);var n=dpe.test(e);return n||fpe.test(e)?ppe(e.slice(2),n?2:8):cpe.test(e)?F8:+e}var mpe=hpe,gpe=Ch,py=Nfe,V8=mpe,vpe="Expected a function",ype=Math.max,_pe=Math.min;function bpe(e,t,n){var o,r,s,i,l,a,u=0,c=!1,d=!1,f=!0;if(typeof e!="function")throw new TypeError(vpe);t=V8(t)||0,gpe(n)&&(c=!!n.leading,d="maxWait"in n,s=d?ype(V8(n.maxWait)||0,t):s,f="trailing"in n?!!n.trailing:f);function p(E){var T=o,O=r;return o=r=void 0,u=E,i=e.apply(O,T),i}function h(E){return u=E,l=setTimeout(v,t),c?p(E):i}function m(E){var T=E-a,O=E-u,P=t-T;return d?_pe(P,s-O):P}function y(E){var T=E-a,O=E-u;return a===void 0||T>=t||T<0||d&&O>=s}function v(){var E=py();if(y(E))return w(E);l=setTimeout(v,m(E))}function w(E){return l=void 0,f&&o?p(E):(o=r=void 0,i)}function _(){l!==void 0&&clearTimeout(l),u=0,o=a=r=l=void 0}function S(){return l===void 0?i:w(py())}function x(){var E=py(),T=y(E);if(o=arguments,r=this,a=E,T){if(l===void 0)return h(a);if(d)return clearTimeout(l),l=setTimeout(v,t),p(a)}return l===void 0&&(l=setTimeout(v,t)),i}return x.cancel=_,x.flush=S,x}var jO=bpe;const wpe=_o(jO);var Cpe=jO,kpe=Ch,Spe="Expected a function";function $pe(e,t,n){var o=!0,r=!0;if(typeof e!="function")throw new TypeError(Spe);return kpe(n)&&(o="leading"in n?!!n.leading:o,r="trailing"in n?!!n.trailing:r),Cpe(e,t,{leading:o,maxWait:t,trailing:r})}var Epe=$pe;const xpe=_o(Epe),Mpe={name:"ContentLayout",props:["title","content_class","wrapper_class"],data(){return{throttledScrollHandler:null}},created(){this.throttledScrollHandler=xpe(e=>{document.dispatchEvent(new CustomEvent("fcom_layout_scroll",{detail:{scrollTop:e}}))},1e3)},methods:{handleLayoutScroll(e){this.throttledScrollHandler(e.scrollTop)}},mounted(){window.fcomLayoutRef=this.$refs.layoutScrollbarRef}},Tpe={key:0,class:"fhr_content_layout_header"},Ope={role:"region","aria-label":"Actions",class:"fhr_page_actions"};function Ipe(e,t,n,o,r,s){const i=ks;return C(),M("div",{class:D([n.wrapper_class,"fhr_content_layout"])},[k(i,{"min-size":100,always:!0,noresize:!0,native:!0,onScroll:s.handleLayoutScroll,ref:"layoutScrollbarRef",height:"calc(100vh - var(--fcom-header-height, 0px)"},{default:$(()=>[he(e.$slots,"header",{},()=>[n.title?(C(),M("div",Tpe,[he(e.$slots,"title",{},()=>[b("h1",{role:"region","aria-label":"Page Title",style:{cursor:"pointer"},onClick:t[0]||(t[0]=l=>e.$eventBus.emit("toTop")),class:"fhr_page_title"},A(n.title),1)]),b("div",Ope,[he(e.$slots,"actions")])])):W("",!0)]),he(e.$slots,"sub_header"),b("div",{class:D([n.content_class,"fhr_content_layout_body"])},[he(e.$slots,"default")],2)]),_:3},8,["onScroll"])],2)}const ri=qe(Mpe,[["render",Ipe]]),Ape={name:"AppLayout",props:["wrapper_class"]},Npe={class:"feeds_main"};function Ppe(e,t,n,o,r,s){const i=re("router-view");return C(),M("div",{class:D([n.wrapper_class,"feeds"])},[b("div",Npe,[he(e.$slots,"before_route_view"),he(e.$slots,"default",{},()=>[k(i)]),he(e.$slots,"after_route_view")])],2)}const si=qe(Ape,[["render",Ppe]]),Lpe={name:"GeneralSettings",components:{ImageUploader:Md,Layout:ri,AppLayout:si,CopyDocument:eZ},data(){return{settings:null,user_roles:{},loading:!1,saving:!1}},computed:{loginUrl(){return this.appVars.urls.portal_base+"?fcom_action=auth"},isRoleBase(){return this.settings&&this.settings.access.acess_level==="role_based"}},methods:{copyToClipboard(e){navigator.clipboard.writeText(e).then(()=>{this.$notify.success(this.$t("Link copied to clipboard"))}).catch(t=>{this.$notify.error("Failed to copy")})},getSettings(){this.loading=!0,this.$get("admin/general").then(e=>{this.settings=e.settings,this.user_roles=e.user_roles}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},saveSettings(){this.saving=!0,this.$post("admin/general",{settings:this.settings}).then(e=>{this.$notify.success(e.message)}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})}},mounted(){this.getSettings(),this.changeTitle(this.$t("General Settings"))}},Rpe={class:"settings_router"},Dpe={class:"fhr_content_layout_body"},Fpe={class:"setting_body"},Vpe={class:"settings_title"},Bpe={class:"settings_subtitle"},zpe={class:"settings_title"},jpe={class:"settings_subtitle"},Hpe=["src"],Upe={class:"settings_title"},Wpe={class:"settings_subtitle"},Kpe=["src"],qpe={class:"settings_title"},Gpe={class:"settings_subtitle"},Ype=["src"],Zpe={class:"settings_title"},Jpe={class:"settings_subtitle"},Xpe={class:"fcom_help_text"},Qpe={class:"settings_title"},ehe={class:"settings_subtitle"},the={class:"settings_title"},nhe={class:"settings_subtitle"},ohe={class:"help_text"},rhe={class:"settings_title"},she={class:"settings_subtitle"},ihe={class:"settings_title"},lhe={class:"settings_subtitle"},ahe={class:"settings_title"},uhe={class:"settings_subtitle"};function che(e,t,n,o,r,s){const i=pt,l=vh,a=At,u=io,c=gh,d=re("image-uploader"),f=Hn,p=U0,h=Eu,m=Ss,y=vr,v=re("CopyDocument"),w=Ne,_=so,S=lo,x=re("layout"),E=re("app-layout");return C(),q(E,{wrapper_class:"fcom_single_layout fcom_member_profile fcom_max_layout"},{default:$(()=>[k(x,{wrapper_class:"no_bg_layout",title:e.$t("General Settings")},{actions:$(()=>[k(i,{class:"fcom_primary_button",disabled:r.saving||r.loading,onClick:s.saveSettings},{default:$(()=>[b("span",null,A(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])]),default:$(()=>[b("div",Rpe,[b("div",Dpe,[b("div",Fpe,[r.settings?(C(),q(_,{key:0,onSubmit:t[10]||(t[10]=et(T=>e.doNothing(),["prevent"])),"label-position":"top","label-width":"120px"},{default:$(()=>[k(c,{gutter:20,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",Vpe,A(e.$t("Community Title")),1),b("span",Bpe,A(e.$t("This title will be used for meta title and email notification referneces. Should be same as your site title")),1)]),_:1}),k(l,{sm:12},{default:$(()=>[k(u,null,{default:$(()=>[k(a,{placeholder:e.$t("Community title"),type:"text",modelValue:r.settings.site_title,"onUpdate:modelValue":t[0]||(t[0]=T=>r.settings.site_title=T)},null,8,["placeholder","modelValue"])]),_:1})]),_:1})]),_:1}),k(c,{gutter:20,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",zpe,A(e.$t("Site Logo (For Light Background)")),1),b("span",jpe,A(e.$t("Recommended dimensions: 480 x 120, 4:1 aspect ratio.")),1)]),_:1}),k(l,{sm:12},{default:$(()=>[k(u,null,{default:$(()=>[r.settings.logo?(C(),M("img",{key:0,alt:"",class:"settings_img",src:r.settings.logo},null,8,Hpe)):W("",!0),k(d,{additionalData:{resize:!1,max_width:500,skip_convert:"yes"},button_text:r.settings.logo?e.$t("Change"):e.$t("Upload Logo"),can_remove:!!r.settings.logo,className:"setting_img_upload",isTextBtn:!1,removeIcon:!1,onUploaded:t[1]||(t[1]=T=>{r.settings.logo=T})},null,8,["button_text","can_remove"])]),_:1})]),_:1})]),_:1}),k(c,{gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",Upe,A(e.$t("Site Logo (For Dark Mode)")),1),b("span",Wpe,A(e.$t("Recommended dimensions: 480 x 120, 4:1 aspect ratio.")),1)]),_:1}),k(l,{sm:12},{default:$(()=>[k(u,null,{default:$(()=>[r.settings.white_logo?(C(),M("img",{key:0,alt:"",class:"settings_img",src:r.settings.white_logo},null,8,Kpe)):W("",!0),k(d,{additionalData:{resize:!1,max_width:500,skip_convert:"yes"},button_text:r.settings.white_logo?e.$t("Change"):e.$t("Set Logo"),can_remove:!!r.settings.white_logo,className:"setting_img_upload",isTextBtn:!1,removeIcon:!1,onUploaded:t[2]||(t[2]=T=>{r.settings.white_logo=T})},null,8,["button_text","can_remove"])]),_:1})]),_:1})]),_:1}),k(c,{gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",qpe,A(e.$t("Default Open Graph Image")),1),b("span",Gpe,A(e.$t("This image will be used on social sharing preview. Recommended size: 1200 x 630 px")),1)]),_:1}),k(l,{sm:12},{default:$(()=>[k(u,null,{default:$(()=>[r.settings.featured_image?(C(),M("img",{key:0,alt:"",style:{"max-height":"100px"},class:"settings_img",src:r.settings.featured_image},null,8,Ype)):W("",!0),k(d,{additionalData:{resize:!1,max_width:1600,skip_convert:"yes"},button_text:r.settings.featured_image?e.$t("Change"):e.$t("Set Featured Image"),can_remove:!!r.settings.featured_image,className:"setting_img_upload",isTextBtn:!1,removeIcon:!1,onUploaded:t[3]||(t[3]=T=>{r.settings.featured_image=T})},null,8,["button_text","can_remove"])]),_:1})]),_:1})]),_:1}),k(c,{gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",Zpe,A(e.$t("Global Post Status")),1),b("span",Jpe,A(e.$t("Enable/disable Post Status")),1)]),_:1}),k(l,{sm:12},{default:$(()=>[k(u,null,{default:$(()=>[k(f,{"true-value":"no","false-value":"yes",modelValue:r.settings.disable_global_posts,"onUpdate:modelValue":t[4]||(t[4]=T=>r.settings.disable_global_posts=T)},{default:$(()=>[ne(A(e.$t("Enable Global Posts Status Form")),1)]),_:1},8,["modelValue"]),b("div",Xpe,[b("p",null,A(e.$t("if you enable this, then user can post globally without selecting a space which will be available for everyone.")),1)])]),_:1})]),_:1})]),_:1}),k(c,{gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",Qpe,A(e.$t("Portal Access Settings")),1),b("span",ehe,A(e.$t("Who can access to the portal")),1)]),_:1}),k(l,{sm:12},{default:$(()=>[k(u,null,{default:$(()=>[k(h,{modelValue:r.settings.access.acess_level,"onUpdate:modelValue":t[5]||(t[5]=T=>r.settings.access.acess_level=T)},{default:$(()=>[k(p,{value:"public"},{default:$(()=>[ne(A(e.$t("Everyone")),1)]),_:1}),k(p,{value:"logged_in"},{default:$(()=>[ne(A(e.$t("Only Logged In Users")),1)]),_:1}),k(p,{value:"role_based"},{default:$(()=>[ne(A(e.$t("Only Selected User Roles")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),s.isRoleBase?(C(),q(c,{key:0,gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",the,A(e.$t("User Roles")),1),b("span",nhe,A(e.$t("Select User Roles who can access to the portal")),1)]),_:1}),k(l,{sm:12},{default:$(()=>[k(u,null,{default:$(()=>[k(y,{placeholder:e.$t("Select Access Roles"),modelValue:r.settings.access.access_roles,"onUpdate:modelValue":t[6]||(t[6]=T=>r.settings.access.access_roles=T),multiple:""},{default:$(()=>[(C(!0),M(fe,null,nt(r.user_roles,(T,O)=>(C(),q(m,{key:O,label:T,value:O},null,8,["label","value"]))),128))]),_:1},8,["placeholder","modelValue"]),b("span",ohe,A(e.$t("__ALL_ADMIN_ACCESS_DESC")),1)]),_:1})]),_:1})]),_:1})):W("",!0),s.isRoleBase?(C(),q(c,{key:1,gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",rhe,A(e.$t("Not Matched User Roles")),1),b("span",she,A(e.$t("Message to show for not matched user roles")),1)]),_:1}),k(l,{sm:12},{default:$(()=>[k(u,null,{default:$(()=>[k(a,{type:"textarea",rows:3,modelValue:r.settings.restricted_role_content,"onUpdate:modelValue":t[7]||(t[7]=T=>r.settings.restricted_role_content=T)},null,8,["modelValue"])]),_:1})]),_:1})]),_:1})):W("",!0),r.settings.access.acess_level!="public"?(C(),q(c,{key:2,gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",ihe,A(e.$t("Redirect URL")),1),b("span",lhe,A(e.$t("Redirect URL for Public Users")),1)]),_:1}),k(l,{sm:12},{default:$(()=>[k(u,null,{default:$(()=>[k(a,{type:"url",modelValue:r.settings.auth_url,"onUpdate:modelValue":t[8]||(t[8]=T=>r.settings.auth_url=T)},null,8,["modelValue"])]),_:1})]),_:1})]),_:1})):W("",!0),r.settings.access.acess_level!="public"?(C(),q(c,{key:3,gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",ahe,A(e.$t("Login URL")),1),b("span",uhe,A(e.$t("For default authentication, please use this URL")),1)]),_:1}),k(l,{sm:12},{default:$(()=>[k(u,null,{default:$(()=>[k(a,{type:"url",disabled:"",value:s.loginUrl,placeholder:e.$t("Login URL for public Users")},{append:$(()=>[k(w,{onClick:t[9]||(t[9]=T=>s.copyToClipboard(s.loginUrl))},{default:$(()=>[k(v)]),_:1}),b("span",null,A(e.$t("Copy")),1)]),_:1},8,["value","placeholder"])]),_:1})]),_:1})]),_:1})):W("",!0),k(c,{gutter:30},{default:$(()=>[k(i,{class:"fcom_primary_button",disabled:r.saving||r.loading,onClick:s.saveSettings},{default:$(()=>[b("span",null,A(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])]),_:1})]),_:1})):r.loading?(C(),q(S,{key:1,animated:!0,rows:10})):W("",!0)])])])]),_:1},8,["title"])]),_:1})}const dhe=qe(Lpe,[["render",che]]),fhe={name:"ManagerForm",props:["modelValue"],emits:["completed"],data(){return{users:[],loading:!1,form:this.modelValue||{user_id:"",roles:[]},adding:!1}},methods:{fetchUsers(e=""){this.loading=!0,this.$get("admin/users",{context:"add_manager",search:e}).then(t=>{this.users=t.users.data}).catch(t=>{this.$handleError(t)}).finally(()=>{this.loading=!1})},addManager(){if(!this.form.user_id||!this.form.roles.length){this.$notify.error(this.$t("Please select a user and role"));return}this.adding=!0,this.$post("admin/managers",{user_id:this.form.user_id,roles:this.form.roles}).then(e=>{this.$notify.success(e.message),this.$emit("completed")}).catch(e=>{this.$handleError(e)}).finally(()=>{this.adding=!1})}},mounted(){this.form.roles||(this.form.roles=[]),this.modelValue.editing_user||this.fetchUsers()}},phe={style:{float:"left"}},hhe={style:{float:"right",color:"#8492a6","font-size":"13px"}},mhe={key:1},ghe={class:"dialog_footer"},vhe={key:0},yhe={key:1};function _he(e,t,n,o,r,s){const i=Ss,l=vr,a=io,u=Hn,c=xoe,d=pt,f=so,p=zt("loading");return C(),q(f,{onSubmit:t[3]||(t[3]=et(h=>e.doNothing(),["prevent"])),"label-position":"top",modelValue:r.form,"onUpdate:modelValue":t[4]||(t[4]=h=>r.form=h),size:"large"},{default:$(()=>[r.form.editing_user?(C(),M("p",mhe,A(e.$t("Editing manager role for %s",r.form.editing_user.display_name)),1)):(C(),q(a,{key:0,label:e.$t("User")},{default:$(()=>[k(l,{class:"rich_select",filterable:"",remote:"",loading:r.loading,"remote-method":s.fetchUsers,placeholder:e.$t("Select User"),modelValue:r.form.user_id,"onUpdate:modelValue":t[0]||(t[0]=h=>r.form.user_id=h)},{default:$(()=>[(C(!0),M(fe,null,nt(r.users,h=>(C(),q(i,{key:h.ID,label:h.display_name+" ("+h.user_email+")",value:h.ID},{default:$(()=>[b("span",phe,A(h.display_name),1),b("span",hhe,A(h.user_email),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["loading","remote-method","placeholder","modelValue"])]),_:1},8,["label"])),k(a,{label:e.$t("Space Management Roles")},{default:$(()=>[k(c,{modelValue:r.form.roles,"onUpdate:modelValue":t[1]||(t[1]=h=>r.form.roles=h)},{default:$(()=>[k(u,{value:"admin"},{default:$(()=>[ne(A(e.$t("Space Admin (All Access)")),1)]),_:1}),k(u,{disabled:r.form.roles.includes("admin"),value:"moderator"},{default:$(()=>[ne(A(e.$t("Space Moderator")),1)]),_:1},8,["disabled"]),k(u,{disabled:r.form.roles.includes("admin"),value:"course_admin"},{default:$(()=>[ne(A(e.$t("Course Admin")),1)]),_:1},8,["disabled"]),k(u,{disabled:r.form.roles.includes("admin")||r.form.roles.includes("course_admin"),value:"course_creatror"},{default:$(()=>[ne(A(e.$t("Course Creator")),1)]),_:1},8,["disabled"])]),_:1},8,["modelValue"])]),_:1},8,["label"]),b("div",ghe,[he(e.$slots,"after_form",{},()=>[He((C(),q(d,{class:"fcom_primary_button",disabled:r.adding,onClick:t[2]||(t[2]=h=>s.addManager())},{default:$(()=>[r.form.editing_user?(C(),M("span",vhe,A(e.$t("Update Role")),1)):(C(),M("span",yhe,A(e.$t("Add Manager")),1))]),_:1},8,["disabled"])),[[p,r.adding]])])])]),_:3},8,["modelValue"])}const bhe=qe(fhe,[["render",_he]]);function whe(e,t){for(var n=-1,o=e==null?0:e.length;++n<o&&t(e[n],n,e)!==!1;);return e}var Che=whe;function khe(e){return function(t,n,o){for(var r=-1,s=Object(t),i=o(t),l=i.length;l--;){var a=i[e?l:++r];if(n(s[a],a,s)===!1)break}return t}}var She=khe,$he=She,Ehe=$he(),xhe=Ehe;function Mhe(e,t){for(var n=-1,o=Array(e);++n<e;)o[n]=t(n);return o}var The=Mhe,Ohe=kh,Ihe=J0,Ahe="[object Arguments]";function Nhe(e){return Ihe(e)&&Ohe(e)==Ahe}var Phe=Nhe,B8=Phe,Lhe=J0,HO=Object.prototype,Rhe=HO.hasOwnProperty,Dhe=HO.propertyIsEnumerable,Fhe=B8(function(){return arguments}())?B8:function(e){return Lhe(e)&&Rhe.call(e,"callee")&&!Dhe.call(e,"callee")},UO=Fhe,Vhe=Array.isArray,Y3=Vhe,Vg={exports:{}};function Bhe(){return!1}var zhe=Bhe;Vg.exports;(function(e,t){var n=zi,o=zhe,r=t&&!t.nodeType&&t,s=r&&!0&&e&&!e.nodeType&&e,i=s&&s.exports===r,l=i?n.Buffer:void 0,a=l?l.isBuffer:void 0,u=a||o;e.exports=u})(Vg,Vg.exports);var WO=Vg.exports,jhe=9007199254740991,Hhe=/^(?:0|[1-9]\d*)$/;function Uhe(e,t){var n=typeof e;return t=t??jhe,!!t&&(n=="number"||n!="symbol"&&Hhe.test(e))&&e>-1&&e%1==0&&e<t}var Whe=Uhe,Khe=9007199254740991;function qhe(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Khe}var KO=qhe,Ghe=kh,Yhe=KO,Zhe=J0,Jhe="[object Arguments]",Xhe="[object Array]",Qhe="[object Boolean]",eme="[object Date]",tme="[object Error]",nme="[object Function]",ome="[object Map]",rme="[object Number]",sme="[object Object]",ime="[object RegExp]",lme="[object Set]",ame="[object String]",ume="[object WeakMap]",cme="[object ArrayBuffer]",dme="[object DataView]",fme="[object Float32Array]",pme="[object Float64Array]",hme="[object Int8Array]",mme="[object Int16Array]",gme="[object Int32Array]",vme="[object Uint8Array]",yme="[object Uint8ClampedArray]",_me="[object Uint16Array]",bme="[object Uint32Array]",dn={};dn[fme]=dn[pme]=dn[hme]=dn[mme]=dn[gme]=dn[vme]=dn[yme]=dn[_me]=dn[bme]=!0;dn[Jhe]=dn[Xhe]=dn[cme]=dn[Qhe]=dn[dme]=dn[eme]=dn[tme]=dn[nme]=dn[ome]=dn[rme]=dn[sme]=dn[ime]=dn[lme]=dn[ame]=dn[ume]=!1;function wme(e){return Zhe(e)&&Yhe(e.length)&&!!dn[Ghe(e)]}var Cme=wme;function kme(e){return function(t){return e(t)}}var Sme=kme,Bg={exports:{}};Bg.exports;(function(e,t){var n=VO,o=t&&!t.nodeType&&t,r=o&&!0&&e&&!e.nodeType&&e,s=r&&r.exports===o,i=s&&n.process,l=function(){try{var a=r&&r.require&&r.require("util").types;return a||i&&i.binding&&i.binding("util")}catch{}}();e.exports=l})(Bg,Bg.exports);var $me=Bg.exports,Eme=Cme,xme=Sme,z8=$me,j8=z8&&z8.isTypedArray,Mme=j8?xme(j8):Eme,qO=Mme,Tme=The,Ome=UO,Ime=Y3,Ame=WO,Nme=Whe,Pme=qO,Lme=Object.prototype,Rme=Lme.hasOwnProperty;function Dme(e,t){var n=Ime(e),o=!n&&Ome(e),r=!n&&!o&&Ame(e),s=!n&&!o&&!r&&Pme(e),i=n||o||r||s,l=i?Tme(e.length,String):[],a=l.length;for(var u in e)(t||Rme.call(e,u))&&!(i&&(u=="length"||r&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||Nme(u,a)))&&l.push(u);return l}var Fme=Dme,Vme=Object.prototype;function Bme(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||Vme;return e===n}var GO=Bme;function zme(e,t){return function(n){return e(t(n))}}var jme=zme,Hme=jme,Ume=Hme(Object.keys,Object),Wme=Ume,Kme=GO,qme=Wme,Gme=Object.prototype,Yme=Gme.hasOwnProperty;function Zme(e){if(!Kme(e))return qme(e);var t=[];for(var n in Object(e))Yme.call(e,n)&&n!="constructor"&&t.push(n);return t}var YO=Zme,Jme=kh,Xme=Ch,Qme="[object AsyncFunction]",e1e="[object Function]",t1e="[object GeneratorFunction]",n1e="[object Proxy]";function o1e(e){if(!Xme(e))return!1;var t=Jme(e);return t==e1e||t==t1e||t==Qme||t==n1e}var ZO=o1e,r1e=ZO,s1e=KO;function i1e(e){return e!=null&&s1e(e.length)&&!r1e(e)}var Z3=i1e,l1e=Fme,a1e=YO,u1e=Z3;function c1e(e){return u1e(e)?l1e(e):a1e(e)}var d1e=c1e,f1e=xhe,p1e=d1e;function h1e(e,t){return e&&f1e(e,t,p1e)}var m1e=h1e,g1e=Z3;function v1e(e,t){return function(n,o){if(n==null)return n;if(!g1e(n))return e(n,o);for(var r=n.length,s=t?r:-1,i=Object(n);(t?s--:++s<r)&&o(i[s],s,i)!==!1;);return n}}var y1e=v1e,_1e=m1e,b1e=y1e,w1e=b1e(_1e),C1e=w1e;function k1e(e){return e}var S1e=k1e,$1e=S1e;function E1e(e){return typeof e=="function"?e:$1e}var x1e=E1e,M1e=Che,T1e=C1e,O1e=x1e,I1e=Y3;function A1e(e,t){var n=I1e(e)?M1e:T1e;return n(e,O1e(t))}var N1e=A1e,P1e=N1e;const cu=_o(P1e);function Et(e){return window.fluentComAdmin.i18n[e]||e}const L1e={public:{label:Et("Public"),description:Et("__PUBLIC_SPACE_DESC"),space_description:Et("__PIBLIC_SPACE_DESC_2")},private:{label:Et("Private"),description:Et("__PRIVATE_SPACE_DESC"),space_description:Et("__PRIVATE_SPACE_DESC_2")},secret:{label:Et("Secret"),description:Et("Only invited members can view and post."),space_description:Et("__SECRET_SPACE_DESC_2")}},R1e={public:{label:Et("Public"),description:Et("Anyone can view and enroll the course for free")},private:{label:Et("Private"),description:Et("__PRIVATE_COURSE_DESC")},secret:{label:Et("Secret"),description:Et("Only invited students can view and enroll the course content.")}},D1e={self_paced:{label:Et("Self Paced"),description:Et("__SELF_PAED_COURSE_DESC")},structured:{label:"Structured",description:Et("__STRUCTURED_COURSE_DESC")},scheduled:{label:Et("Scheduled"),description:Et("Course starts on a specific date. Sections are dripped relative to that date.")}},F1e={leader_board_module:{headerTitle:Et("Leaderboard Settings"),headerDescription:Et("Settings for Leaderboard & Gamification features"),featureImage:"leaderboard_module.png",bodyTitle:Et("Get Leaderboard & Gamification Module"),bodyDescription:Et("Unlock potential by creating new feeds and earning points for likes. Advance in rank based on your total points using this module")},emoji_module:{headerTitle:Et("Emoji Module"),headerDescription:Et("Settings for Emoji & Reaction features"),featureImage:"emoji_module.png",bodyTitle:Et("Get Emoji & Reaction Module"),bodyDescription:Et("Use emojis to add a personal touch and make your new article, post, or comment more expressive")},giphy_module:{headerTitle:Et("Giphy Module"),headerDescription:Et("Customize Your Giphy Module Settings"),featureImage:"giphy_module.png",bodyTitle:Et("Get Giphy Module"),bodyDescription:Et("Want to use awesome GIF, upgrade to pro plan now and enjoy your surfing on Fluent community")},user_badge_module:{headerTitle:Et("User Badge Module"),headerDescription:Et("Add a badge next to user profile name to highlight valued users"),featureImage:"badge_module.png",bodyTitle:Et("Get User Badge Module"),bodyDescription:Et("Show customized Badge to user profile beside name to easily recognize your admins / moderators or give appriciations to your power users")},media_module:{headerTitle:Et("Media Module"),headerDescription:Et("Add a badge next to user profile name to highlight valued users"),featureImage:"media_module.png",bodyTitle:Et("Get Media Module"),bodyDescription:Et("Choose where to store your media files. Options include Local File System, Amazon S3, or Cloudflare R2 for storing and serving your media assets")}},Yu=e=>{e=parseInt(e);const t=Object.values(window.fluentComAdmin.leaderboard_levels);if(!e)return t[0];for(let n=0;n<t.length;n++)if(e>=t[n].min_points&&e<=t[n].max_points)return t[n];return t[t-1]};var V1e=zi,B1e=V1e["__core-js_shared__"],z1e=B1e,hy=z1e,H8=function(){var e=/[^.]+$/.exec(hy&&hy.keys&&hy.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function j1e(e){return!!H8&&H8 in e}var H1e=j1e,U1e=Function.prototype,W1e=U1e.toString;function K1e(e){if(e!=null){try{return W1e.call(e)}catch{}try{return e+""}catch{}}return""}var JO=K1e,q1e=ZO,G1e=H1e,Y1e=Ch,Z1e=JO,J1e=/[\\^$.*+?()[\]{}|]/g,X1e=/^\[object .+?Constructor\]$/,Q1e=Function.prototype,ege=Object.prototype,tge=Q1e.toString,nge=ege.hasOwnProperty,oge=RegExp("^"+tge.call(nge).replace(J1e,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function rge(e){if(!Y1e(e)||G1e(e))return!1;var t=q1e(e)?oge:X1e;return t.test(Z1e(e))}var sge=rge;function ige(e,t){return e==null?void 0:e[t]}var lge=ige,age=sge,uge=lge;function cge(e,t){var n=uge(e,t);return age(n)?n:void 0}var Sh=cge,dge=Sh,fge=zi,pge=dge(fge,"DataView"),hge=pge,mge=Sh,gge=zi,vge=mge(gge,"Map"),yge=vge,_ge=Sh,bge=zi,wge=_ge(bge,"Promise"),Cge=wge,kge=Sh,Sge=zi,$ge=kge(Sge,"Set"),Ege=$ge,xge=Sh,Mge=zi,Tge=xge(Mge,"WeakMap"),Oge=Tge,Mb=hge,Tb=yge,Ob=Cge,Ib=Ege,Ab=Oge,XO=kh,Td=JO,U8="[object Map]",Ige="[object Object]",W8="[object Promise]",K8="[object Set]",q8="[object WeakMap]",G8="[object DataView]",Age=Td(Mb),Nge=Td(Tb),Pge=Td(Ob),Lge=Td(Ib),Rge=Td(Ab),ya=XO;(Mb&&ya(new Mb(new ArrayBuffer(1)))!=G8||Tb&&ya(new Tb)!=U8||Ob&&ya(Ob.resolve())!=W8||Ib&&ya(new Ib)!=K8||Ab&&ya(new Ab)!=q8)&&(ya=function(e){var t=XO(e),n=t==Ige?e.constructor:void 0,o=n?Td(n):"";if(o)switch(o){case Age:return G8;case Nge:return U8;case Pge:return W8;case Lge:return K8;case Rge:return q8}return t});var Dge=ya,Fge=YO,Vge=Dge,Bge=UO,zge=Y3,jge=Z3,Hge=WO,Uge=GO,Wge=qO,Kge="[object Map]",qge="[object Set]",Gge=Object.prototype,Yge=Gge.hasOwnProperty;function Zge(e){if(e==null)return!0;if(jge(e)&&(zge(e)||typeof e=="string"||typeof e.splice=="function"||Hge(e)||Wge(e)||Bge(e)))return!e.length;var t=Vge(e);if(t==Kge||t==qge)return!e.size;if(Uge(e))return!Fge(e).length;for(var n in e)if(Yge.call(e,n))return!1;return!0}var Jge=Zge;const QO=_o(Jge),Xge={name:"SocialLinks",props:["xprofile","isOwn"],computed:{socialLinks(){var o,r;if(!this.xprofile)return[];const e=[];this.xprofile.website?e.push({title:this.$t("Website"),icon:'<svg viewBox="0 0 40 20" fill="currentColor"><path d="M3.8 10C3.8 6.58 6.58 3.8 10 3.8H18V0H10C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20H18V16.2H10C6.58 16.2 3.8 13.42 3.8 10ZM12 12H28V8H12V12ZM30 0H22V3.8H30C33.42 3.8 36.2 6.58 36.2 10C36.2 13.42 33.42 16.2 30 16.2H22V20H30C35.52 20 40 15.52 40 10C40 4.48 35.52 0 30 0Z"></path></svg>',url:this.xprofile.website}):(o=this.xprofile.meta)!=null&&o.website&&e.push({title:this.$t("Website"),icon:'<svg viewBox="0 0 40 20" fill="currentColor"><path d="M3.8 10C3.8 6.58 6.58 3.8 10 3.8H18V0H10C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20H18V16.2H10C6.58 16.2 3.8 13.42 3.8 10ZM12 12H28V8H12V12ZM30 0H22V3.8H30C33.42 3.8 36.2 6.58 36.2 10C36.2 13.42 33.42 16.2 30 16.2H22V20H30C35.52 20 40 15.52 40 10C40 4.48 35.52 0 30 0Z"></path></svg>',url:this.xprofile.meta.website});let t=this.xprofile.social_links;if(t||(t=(r=this.xprofile.meta)==null?void 0:r.social_links),QO(t))return e;const n=this.appVars.socialLinkProviders;return n&&this.each(n,(s,i)=>{t[i]&&e.push({title:s.title,icon:s.icon_svg,url:s.domain+t[i]})}),e}}},Qge={class:"fcom_social_links"},e0e=["href","title"];function t0e(e,t,n,o,r,s){const i=Ne,l=re("router-link");return C(),M("div",Qge,[(C(!0),M(fe,null,nt(s.socialLinks,a=>(C(),M("a",{rel:"noopener nofollow",target:"_blank",href:a.url,key:a.title,title:a.title},[k(i,{innerHTML:a.icon},null,8,["innerHTML"])],8,e0e))),128)),n.isOwn&&!s.socialLinks.length?(C(),q(l,{key:0,to:{name:"update_profile",params:{username:n.xprofile.username}}},{default:$(()=>[ne(A("+ "+e.$t("Add social links")),1)]),_:1},8,["to"])):W("",!0)])}const n0e=qe(Xge,[["render",t0e]]),o0e={name:"UserRouteLink",props:{xprofile:{default:()=>({})},show_pop:{type:Boolean,default(){return!0}},show_badge:{type:Boolean,default(){return!1}}},components:{SocialLinks:n0e},data(){return{showingPop:!1,userLevel:null}},methods:{initShow(){this.showingPop=!0,this.has_leaderboard&&!this.userLevel&&(this.userLevel=Yu(this.xprofile.total_points))}}},r0e=["href"],s0e=["href"],i0e={key:0,class:"fcom_profile_pop"},l0e={class:"fcom_profile_pop_avatar"},a0e={key:0,class:"fcom_prfile_tagline"},u0e={class:"fcom_level_name"},c0e={style:{display:"block"},class:"fcoml_level_sub meta_line"},d0e={class:"fcom_profile_pop_info"},f0e=["href"],p0e={class:"fcom_user_name"},h0e={key:0,class:"fcom_profile_pop_bio"},m0e={class:"meta_line"},g0e={key:1,class:"meta_line"},v0e={class:"fcom_profile_btns"},y0e=["href"],_0e=["href"];function b0e(e,t,n,o,r,s){const i=re("verified-sign"),l=re("UserBadge"),a=re("UserAvatar"),u=vh,c=re("SocialLinks"),d=gh,f=Po;return n.show_pop?(C(),q(f,{key:1,width:500,"show-after":500,trigger:"hover",onShow:s.initShow,persistent:!1,"popper-class":"fcom_profile_popper","popper-style":"padding: 20px;"},{reference:$(()=>[he(e.$slots,"default",{},()=>[b("a",{href:e.$getRouteLink("u/:username",{username:n.xprofile.username}),class:"user_route"},[ne(A(n.xprofile.display_name||e.$t("No name"))+" ",1),n.xprofile.is_verified?(C(),q(i,{key:0})):W("",!0),n.show_badge?(C(),q(l,{key:1,profile:n.xprofile},null,8,["profile"])):W("",!0)],8,s0e)])]),default:$(()=>[r.showingPop?(C(),M("div",i0e,[k(d,{gutter:20},{default:$(()=>[k(u,{sm:24,md:8},{default:$(()=>[b("div",l0e,[k(a,{xprofile:n.xprofile},null,8,["xprofile"]),r.userLevel?(C(),M("div",a0e,[b("div",u0e,A(r.userLevel.title),1),b("div",c0e,A(r.userLevel.tagline),1)])):W("",!0)])]),_:1}),k(u,{sm:24,md:16},{default:$(()=>[b("div",d0e,[b("a",{href:e.$getRouteLink("u/:username",{username:n.xprofile.username}),class:"user_route"},[ne(A(n.xprofile.display_name)+" ",1),n.xprofile.is_verified?(C(),q(i,{key:0})):W("",!0),n.show_badge?(C(),q(l,{key:1,profile:n.xprofile},null,8,["profile"])):W("",!0)],8,f0e),b("span",p0e," @"+A(n.xprofile.username),1),n.xprofile.short_description?(C(),M("div",h0e,A(e.getExcerpt(n.xprofile.short_description,160)),1)):W("",!0),b("div",m0e," Joined: "+A(e.humanDateDiff(n.xprofile.created_at)),1),n.xprofile.last_activity?(C(),M("div",g0e," Last seen: "+A(e.humanDateDiff(n.xprofile.last_activity)),1)):W("",!0),b("div",v0e,[b("a",{class:"el-button el-button--primary is-text is-has-bg",href:e.$getRouteLink("u/:username",{username:n.xprofile.username})},A(e.$t("View Profile")),9,y0e),e.appVars.has_chat?(C(),M("a",{key:0,class:"el-button el-button--primary is-text is-has-bg",href:e.$getRouteLink("chat/?user_id=:user_id",{user_id:n.xprofile.user_id})},A(e.$t("Message")),9,_0e)):W("",!0)]),k(c,{style:{"justify-content":"left"},xprofile:n.xprofile,isOwn:!1},null,8,["xprofile"])])]),_:1})]),_:1})])):W("",!0)]),_:3},8,["onShow"])):(C(),M("a",{key:0,href:e.$getRouteLink("u/:username",{username:n.xprofile.username}),class:"user_route"},[he(e.$slots,"default",{},()=>[ne(A(n.xprofile.display_name)+" ",1),n.xprofile.is_verified?(C(),q(i,{key:0})):W("",!0),n.show_badge?(C(),q(l,{key:1,profile:n.xprofile},null,8,["profile"])):W("",!0)])],8,r0e))}const X0=qe(o0e,[["render",b0e]]),w0e={name:"Avatar",props:{xprofile:{default:()=>({})},with_level:{type:Boolean,default(){return!0}},is_rounded:{type:Boolean,default(){return!0}},with_completion:{type:Boolean,default(){return!1}},is_online:{type:Boolean,default(){return!1}}},computed:{level(){if(!this.with_level||!this.has_leaderboard)return"";const e=Yu(this.xprofile.total_points);return e?e.level:0},withCompletion(){var n;if(!this.with_completion||!((n=this.xprofile)!=null&&n.total_points))return!1;const e=Yu(this.xprofile.total_points),t=Yu(e.max_points+1);return e.level!==t.level},getOutlineStyle(){if(!this.withCompletion)return{};const e=Yu(this.xprofile.total_points),t=Yu(e.max_points+1),n=this.xprofile.total_points-e.min_points,o=t.min_points-e.min_points,s=n/o*100/100*360;return{backgroundImage:`conic-gradient(rgb(56, 117, 223) ${s}deg, #D9D9D9 ${s}deg)`}}},methods:{setAltImg(e){e.target.src=this.appVars.assets_url+"images/placeholder.png"}}},C0e=["src"],k0e={key:1,class:"fcom_no_image"},S0e={key:0,role:"region","aria-label":"User Level",class:"fcom_user_level_mark"};function $0e(e,t,n,o,r,s){return C(),M("div",{class:D([{fcom_avatar_is_rounded:n.is_rounded,is_member_online:n.is_online},"fcom_user_avatar"])},[b("span",{style:Qe(s.getOutlineStyle),class:D({fcom_compilation_avatar:s.withCompletion})},[n.xprofile?(C(),M("img",{key:0,onError:t[0]||(t[0]=(...i)=>s.setAltImg&&s.setAltImg(...i)),src:n.xprofile.avatar,alt:""},null,40,C0e)):(C(),M("span",k0e))],6),s.level||n.is_online?(C(),M("div",S0e,[b("span",null,A(s.level),1)])):W("",!0)],2)}const eI=qe(w0e,[["render",$0e]]),E0e={name:"ModeratorSettings",components:{UserAvatar:eI,UserRouteLink:X0,ManagerForm:bhe,Layout:ri,AppLayout:si},data(){return{managers:[],loading:!1,paginate:{page:1,per_page:20,total:0},search:"",bulkAction:"",showModal:!1,editing_manager:{user_id:"",roles:[]}}},methods:{applyBulkAction(){this.bulkAction=""},showForm(e){this.editing_manager=e?{user_id:e.ID,roles:e.community_role.value,editing_user:e}:{user_id:"",roles:[]},this.showModal=!0},fetch(){this.loading=!0,this.$get("admin/managers",{page:this.paginate.page,per_page:this.paginate.per_page,search:this.search}).then(e=>{this.managers=e.managers.data,this.paginate.total=e.total}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},removeManager(e){this.$confirm(this.$t("Are you sure you want to remove this manager?"),this.$t("Warning"),{confirmButtonText:this.$t("Yes, Remove"),cancelButtonText:this.$t("Cancel"),type:"warning"}).then(()=>{this.working=!0,this.$del("admin/managers/"+e.ID).then(t=>{this.$notify.success(t.message),this.fetch()}).catch(t=>{this.$handleError(t)}).finally(()=>{this.working=!1})})},formatRoles(e){let t=[];return this.each(e,n=>{t.push(this.ucWords(n.replace("_"," ")))}),t.join(", ")}},mounted(){this.has_pro&&this.fetch(),this.changeTitle(this.$t("Moderator Settings"))}},x0e=["href"],M0e={class:"settings_router manager_section"},T0e={class:"fhr_content_layout_body"},O0e={key:0,class:"setting_body"},I0e={class:"fcom_manager_actions"},A0e={class:"bulk_search"},N0e=b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},[b("path",{d:"M14.5833 14.584L18.3333 18.334",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{d:"M16.6667 9.16699C16.6667 5.02486 13.3088 1.66699 9.16666 1.66699C5.02453 1.66699 1.66666 5.02486 1.66666 9.16699C1.66666 13.3091 5.02453 16.667 9.16666 16.667C13.3088 16.667 16.6667 13.3091 16.6667 9.16699Z",stroke:"currentColor","stroke-width":"1.5","stroke-linejoin":"round"})],-1),P0e={class:"fcom_manager_table"},L0e={class:"user_col"},R0e={class:"user_info"},D0e={class:"user_id"},F0e={class:"user_email"},V0e={class:"fcom_table_action_col"},B0e={key:1,class:"setting_body",style:{"text-align":"center"}},z0e=b("p",null,"Add your team members as an Admin/Moderator of this community. This feature is available on the premium version of FluentCommunity. Please upgrade to pro",-1),j0e=["href"],H0e={class:"dialog_header"},U0e={class:"dialog_left"},W0e=b("div",{class:"header_icon"},[b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},[b("path",{d:"M11.5 11.689V13.2565C10.8212 13.0165 10.0947 12.9429 9.38155 13.0418C8.6684 13.1408 7.9894 13.4094 7.40157 13.8252C6.81375 14.2409 6.33426 14.7916 6.00337 15.4311C5.67249 16.0705 5.49986 16.78 5.5 17.5L4 17.4993C3.99977 16.5834 4.20919 15.6797 4.61222 14.8573C5.01526 14.0349 5.6012 13.3157 6.32516 12.7548C7.04912 12.1939 7.89188 11.8061 8.78887 11.6212C9.68585 11.4364 10.6132 11.4593 11.5 11.6883V11.689ZM10 10.75C7.51375 10.75 5.5 8.73625 5.5 6.25C5.5 3.76375 7.51375 1.75 10 1.75C12.4862 1.75 14.5 3.76375 14.5 6.25C14.5 8.73625 12.4862 10.75 10 10.75ZM10 9.25C11.6575 9.25 13 7.9075 13 6.25C13 4.5925 11.6575 3.25 10 3.25C8.3425 3.25 7 4.5925 7 6.25C7 7.9075 8.3425 9.25 10 9.25ZM14.5 13.75V11.5H16V13.75H18.25V15.25H16V17.5H14.5V15.25H12.25V13.75H14.5Z",fill:"currentColor"})])],-1),K0e={class:"dialog_body"};function q0e(e,t,n,o,r,s){const i=re("Plus"),l=Ne,a=pt,u=At,c=Xte,d=re("user-route-link"),f=Y0,p=G0,h=re("layout"),m=re("app-layout"),y=re("manager-form"),v=yh,w=zt("loading");return C(),M(fe,null,[k(m,{wrapper_class:"fcom_single_layout fcom_member_profile fcom_max_layout"},{default:$(()=>[k(h,{wrapper_class:"no_bg_layout fcom_setting_route",title:e.$t("Community Managers")},{actions:$(()=>[e.has_pro?(C(),q(a,{key:0,class:"fcom_primary_button",onClick:t[0]||(t[0]=_=>s.showForm(null))},{default:$(()=>[k(l,null,{default:$(()=>[k(i)]),_:1}),b("span",null,A(e.$t("Add Manager")),1)]),_:1})):(C(),M("a",{key:1,target:"_blank",rel:"noopener",href:e.appVars.upgrade_url,class:"el-button el-button--danger"},A(e.$t("Upgrade to Pro")),9,x0e))]),default:$(()=>[b("div",M0e,[b("div",T0e,[e.has_pro?(C(),M("div",O0e,[b("div",I0e,[b("div",A0e,[k(u,{modelValue:r.search,"onUpdate:modelValue":t[1]||(t[1]=_=>r.search=_),onKeydown:Pt(s.fetch,["enter"]),placeholder:e.$t("Search"),class:"el-input-round"},{prefix:$(()=>[N0e]),_:1},8,["modelValue","onKeydown","placeholder"])])]),b("div",P0e,[He((C(),q(p,{data:r.managers},{default:$(()=>[k(f,{label:e.$t("Members"),sortable:"","min-width":"160"},{default:$(_=>[b("div",L0e,[k(c,{src:_.row.xprofile.avatar},null,8,["src"]),b("div",R0e,[b("div",null,[k(d,{xprofile:_.row.xprofile},null,8,["xprofile"]),b("span",D0e,"#"+A(_.row.ID),1)]),b("span",F0e,A(_.row.user_email),1)])])]),_:1},8,["label"]),k(f,{label:e.$t("Role"),sortable:""},{default:$(_=>[b("span",null,A(s.formatRoles(_.row.community_role.value)),1)]),_:1},8,["label"]),k(f,null,{default:$(_=>[b("div",V0e,[k(a,{onClick:S=>s.showForm(_.row),size:"small"},{default:$(()=>[ne(A(e.$t("Edit")),1)]),_:2},1032,["onClick"]),k(a,{onClick:S=>s.removeManager(_.row),type:"danger",plain:"",size:"small"},{default:$(()=>[ne(A(e.$t("Remove")),1)]),_:2},1032,["onClick"])])]),_:1})]),_:1},8,["data"])),[[w,r.loading]])])])):(C(),M("div",B0e,[z0e,b("a",{target:"_blank",rel:"noopener",href:e.appVars.upgrade_url,class:"el-button el-button--danger"},A(e.$t("Upgrade to Pro")),9,j0e)]))])])]),_:1},8,["title"])]),_:1}),k(v,{"modal-class":"fcom_common_dialog",id:"fluent_comminity_body","close-on-click-modal":!1,"append-to-body":!0,width:e.dialogWidth,modelValue:r.showModal,"onUpdate:modelValue":t[4]||(t[4]=_=>r.showModal=_),direction:"rtl"},{header:$(({close:_})=>[b("div",H0e,[b("div",U0e,[W0e,b("div",null,[b("h4",null,A(e.$t(r.editing_manager.editing_user?"Update Role":"Add Manager")),1),b("p",null,A(e.$t("you can edit your role here")),1)])])])]),default:$(()=>[b("div",K0e,[r.showModal?(C(),q(y,{key:0,onCompleted:t[2]||(t[2]=()=>{s.fetch(),r.showModal=!1}),modelValue:r.editing_manager,"onUpdate:modelValue":t[3]||(t[3]=_=>r.editing_manager=_)},null,8,["modelValue"])):W("",!0)])]),_:1},8,["width","modelValue"])],64)}const G0e=qe(E0e,[["render",q0e]]);var Xo=(e=>(e.docTypeError="docTypeError",e.contextNotFound="contextNotFound",e.timerNotFound="timerNotFound",e.ctxCallOutOfScope="ctxCallOutOfScope",e.createNodeInParserFail="createNodeInParserFail",e.stackOverFlow="stackOverFlow",e.parserMatchError="parserMatchError",e.serializerMatchError="serializerMatchError",e.getAtomFromSchemaFail="getAtomFromSchemaFail",e.expectDomTypeError="expectDomTypeError",e.callCommandBeforeEditorView="callCommandBeforeEditorView",e.missingRootElement="missingRootElement",e.missingNodeInSchema="missingNodeInSchema",e.missingMarkInSchema="missingMarkInSchema",e.ctxNotBind="ctxNotBind",e.missingYjsDoc="missingYjsDoc",e))(Xo||{});let wr=class extends Error{constructor(t,n){super(n),this.name="MilkdownError",this.code=t}};const Y0e=(e,t)=>typeof t=="function"?"[Function]":t,ud=e=>JSON.stringify(e,Y0e);function Z0e(e){return new wr(Xo.docTypeError,`Doc type error, unsupported type: ${ud(e)}`)}function J0e(e){return new wr(Xo.contextNotFound,`Context "${e}" not found, do you forget to inject it?`)}function X0e(e){return new wr(Xo.timerNotFound,`Timer "${e}" not found, do you forget to record it?`)}function J3(){return new wr(Xo.ctxCallOutOfScope,"Should not call a context out of the plugin.")}function Q0e(...e){const t=e.reduce((n,o)=>{if(!o)return n;const r=s=>Array.isArray(s)?s.map(i=>r(i)).join(", "):s.toJSON?ud(s.toJSON()):s.spec?ud(s.spec):s.toString();return`${n}, ${r(o)}`},"Create prosemirror node from remark failed in parser");return new wr(Xo.createNodeInParserFail,t)}function tI(){return new wr(Xo.stackOverFlow,"Stack over flow, cannot pop on an empty stack.")}function eve(e){return new wr(Xo.parserMatchError,`Cannot match target parser for node: ${ud(e)}.`)}function tve(e){return new wr(Xo.serializerMatchError,`Cannot match target serializer for node: ${ud(e)}.`)}function nve(e,t){return new wr(Xo.getAtomFromSchemaFail,`Cannot get ${e}: ${t} from schema.`)}function ii(e){return new wr(Xo.expectDomTypeError,`Expect to be a dom, but get: ${ud(e)}.`)}function ove(){return new wr(Xo.callCommandBeforeEditorView,"You're trying to call a command before editor view initialized, make sure to get commandManager from ctx after editor view has been initialized")}function nI(e){return new wr(Xo.missingNodeInSchema,`Missing node in schema, milkdown cannot find "${e}" in schema.`)}function rve(e){return new wr(Xo.missingMarkInSchema,`Missing mark in schema, milkdown cannot find "${e}" in schema.`)}var oI=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},it=(e,t,n)=>(oI(e,t,"read from private field"),n?n.call(e):t.get(e)),kn=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},Ut=(e,t,n,o)=>(oI(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n);let rI=class{constructor(){this.sliceMap=new Map,this.get=t=>{const n=typeof t=="string"?[...this.sliceMap.values()].find(o=>o.type.name===t):this.sliceMap.get(t.id);if(!n){const o=typeof t=="string"?t:t.name;throw J0e(o)}return n},this.remove=t=>{const n=typeof t=="string"?[...this.sliceMap.values()].find(o=>o.type.name===t):this.sliceMap.get(t.id);n&&this.sliceMap.delete(n.type.id)},this.has=t=>typeof t=="string"?[...this.sliceMap.values()].some(n=>n.type.name===t):this.sliceMap.has(t.id)}};var Os,ol,Qd;let sve=class{constructor(t,n,o){kn(this,Os,void 0),kn(this,ol,void 0),kn(this,Qd,void 0),Ut(this,Os,[]),Ut(this,Qd,()=>{it(this,Os).forEach(r=>r(it(this,ol)))}),this.set=r=>{Ut(this,ol,r),it(this,Qd).call(this)},this.get=()=>it(this,ol),this.update=r=>{Ut(this,ol,r(it(this,ol))),it(this,Qd).call(this)},this.type=o,Ut(this,ol,n),t.set(o.id,this)}on(t){return it(this,Os).push(t),()=>{Ut(this,Os,it(this,Os).filter(n=>n!==t))}}once(t){const n=this.on(o=>{t(o),n()});return n}off(t){Ut(this,Os,it(this,Os).filter(n=>n!==t))}offAll(){Ut(this,Os,[])}};Os=new WeakMap,ol=new WeakMap,Qd=new WeakMap;let ive=class{constructor(t,n){this.id=Symbol(`Context-${n}`),this.name=n,this._defaultValue=t,this._typeInfo=()=>{throw J3()}}create(t,n=this._defaultValue){return new sve(t,n,this)}};const jt=(e,t)=>new ive(e,t);var l1,a1,u1,Zu,ef,_a,tf,nf,of;let lve=class{constructor(t,n,o){kn(this,l1,void 0),kn(this,a1,void 0),kn(this,u1,void 0),kn(this,Zu,void 0),kn(this,ef,void 0),kn(this,_a,void 0),kn(this,tf,void 0),kn(this,nf,void 0),kn(this,of,void 0),Ut(this,Zu,new Set),Ut(this,ef,new Set),Ut(this,_a,new Map),Ut(this,tf,new Map),this.read=()=>({metadata:it(this,l1),injectedSlices:[...it(this,Zu)].map(r=>({name:typeof r=="string"?r:r.name,value:it(this,nf).call(this,r)})),consumedSlices:[...it(this,ef)].map(r=>({name:typeof r=="string"?r:r.name,value:it(this,nf).call(this,r)})),recordedTimers:[...it(this,_a)].map(([r,{duration:s}])=>({name:r.name,duration:s,status:it(this,of).call(this,r)})),waitTimers:[...it(this,tf)].map(([r,{duration:s}])=>({name:r.name,duration:s,status:it(this,of).call(this,r)}))}),this.onRecord=r=>{it(this,_a).set(r,{start:Date.now(),duration:0})},this.onClear=r=>{it(this,_a).delete(r)},this.onDone=r=>{const s=it(this,_a).get(r);s&&(s.duration=Date.now()-s.start)},this.onWait=(r,s)=>{const i=Date.now();s.finally(()=>{it(this,tf).set(r,{duration:Date.now()-i})})},this.onInject=r=>{it(this,Zu).add(r)},this.onRemove=r=>{it(this,Zu).delete(r)},this.onUse=r=>{it(this,ef).add(r)},Ut(this,nf,r=>it(this,a1).get(r).get()),Ut(this,of,r=>it(this,u1).get(r).status),Ut(this,a1,t),Ut(this,u1,n),Ut(this,l1,o)}};l1=new WeakMap,a1=new WeakMap,u1=new WeakMap,Zu=new WeakMap,ef=new WeakMap,_a=new WeakMap,tf=new WeakMap,nf=new WeakMap,of=new WeakMap;var rl,sl,c1,Qr;const ave=class sI{constructor(t,n,o){kn(this,rl,void 0),kn(this,sl,void 0),kn(this,c1,void 0),kn(this,Qr,void 0),this.produce=r=>r&&Object.keys(r).length?new sI(it(this,rl),it(this,sl),{...r}):this,this.inject=(r,s)=>{var i;const l=r.create(it(this,rl).sliceMap);return s!=null&&l.set(s),(i=it(this,Qr))==null||i.onInject(r),this},this.remove=r=>{var s;return it(this,rl).remove(r),(s=it(this,Qr))==null||s.onRemove(r),this},this.record=r=>{var s;return r.create(it(this,sl).store),(s=it(this,Qr))==null||s.onRecord(r),this},this.clearTimer=r=>{var s;return it(this,sl).remove(r),(s=it(this,Qr))==null||s.onClear(r),this},this.isInjected=r=>it(this,rl).has(r),this.isRecorded=r=>it(this,sl).has(r),this.use=r=>{var s;return(s=it(this,Qr))==null||s.onUse(r),it(this,rl).get(r)},this.get=r=>this.use(r).get(),this.set=(r,s)=>this.use(r).set(s),this.update=(r,s)=>this.use(r).update(s),this.timer=r=>it(this,sl).get(r),this.done=r=>{var s;this.timer(r).done(),(s=it(this,Qr))==null||s.onDone(r)},this.wait=r=>{var s;const i=this.timer(r).start();return(s=it(this,Qr))==null||s.onWait(r,i),i},this.waitTimers=async r=>{await Promise.all(this.get(r).map(s=>this.wait(s)))},Ut(this,rl,t),Ut(this,sl,n),Ut(this,c1,o),o&&Ut(this,Qr,new lve(t,n,o))}get meta(){return it(this,c1)}get inspector(){return it(this,Qr)}};rl=new WeakMap,sl=new WeakMap,c1=new WeakMap,Qr=new WeakMap;let uve=ave,cve=class{constructor(){this.store=new Map,this.get=t=>{const n=this.store.get(t.id);if(!n)throw X0e(t.name);return n},this.remove=t=>{this.store.delete(t.id)},this.has=t=>this.store.has(t.id)}};var Ju,ba,rf,il,sf,d1;let dve=class{constructor(t,n){kn(this,Ju,void 0),kn(this,ba,void 0),kn(this,rf,void 0),kn(this,il,void 0),kn(this,sf,void 0),kn(this,d1,void 0),Ut(this,Ju,null),Ut(this,ba,null),Ut(this,il,"pending"),this.start=()=>(it(this,Ju)??Ut(this,Ju,new Promise((o,r)=>{Ut(this,ba,s=>{s instanceof CustomEvent&&s.detail.id===it(this,rf)&&(Ut(this,il,"resolved"),it(this,sf).call(this),s.stopImmediatePropagation(),o())}),it(this,d1).call(this,()=>{it(this,il)==="pending"&&Ut(this,il,"rejected"),it(this,sf).call(this),r(new Error(`Timing ${this.type.name} timeout.`))}),Ut(this,il,"pending"),addEventListener(this.type.name,it(this,ba))})),it(this,Ju)),this.done=()=>{const o=new CustomEvent(this.type.name,{detail:{id:it(this,rf)}});dispatchEvent(o)},Ut(this,sf,()=>{it(this,ba)&&removeEventListener(this.type.name,it(this,ba))}),Ut(this,d1,o=>{setTimeout(()=>{o()},this.type.timeout)}),Ut(this,rf,Symbol(n.name)),this.type=n,t.set(n.id,this)}get status(){return it(this,il)}};Ju=new WeakMap,ba=new WeakMap,rf=new WeakMap,il=new WeakMap,sf=new WeakMap,d1=new WeakMap;let fve=class{constructor(t,n=3e3){this.create=o=>new dve(o,this),this.id=Symbol(`Timer-${t}`),this.name=t,this.timeout=n}};const ea=(e,t=3e3)=>new fve(e,t);function Xn(e){this.content=e}Xn.prototype={constructor:Xn,find:function(e){for(var t=0;t<this.content.length;t+=2)if(this.content[t]===e)return t;return-1},get:function(e){var t=this.find(e);return t==-1?void 0:this.content[t+1]},update:function(e,t,n){var o=n&&n!=e?this.remove(n):this,r=o.find(e),s=o.content.slice();return r==-1?s.push(n||e,t):(s[r+1]=t,n&&(s[r]=n)),new Xn(s)},remove:function(e){var t=this.find(e);if(t==-1)return this;var n=this.content.slice();return n.splice(t,2),new Xn(n)},addToStart:function(e,t){return new Xn([e,t].concat(this.remove(e).content))},addToEnd:function(e,t){var n=this.remove(e).content.slice();return n.push(e,t),new Xn(n)},addBefore:function(e,t,n){var o=this.remove(t),r=o.content.slice(),s=o.find(e);return r.splice(s==-1?r.length:s,0,t,n),new Xn(r)},forEach:function(e){for(var t=0;t<this.content.length;t+=2)e(this.content[t],this.content[t+1])},prepend:function(e){return e=Xn.from(e),e.size?new Xn(e.content.concat(this.subtract(e).content)):this},append:function(e){return e=Xn.from(e),e.size?new Xn(this.subtract(e).content.concat(e.content)):this},subtract:function(e){var t=this;e=Xn.from(e);for(var n=0;n<e.content.length;n+=2)t=t.remove(e.content[n]);return t},toObject:function(){var e={};return this.forEach(function(t,n){e[t]=n}),e},get size(){return this.content.length>>1}};Xn.from=function(e){if(e instanceof Xn)return e;var t=[];if(e)for(var n in e)t.push(n,e[n]);return new Xn(t)};function iI(e,t,n){for(let o=0;;o++){if(o==e.childCount||o==t.childCount)return e.childCount==t.childCount?null:n;let r=e.child(o),s=t.child(o);if(r==s){n+=r.nodeSize;continue}if(!r.sameMarkup(s))return n;if(r.isText&&r.text!=s.text){for(let i=0;r.text[i]==s.text[i];i++)n++;return n}if(r.content.size||s.content.size){let i=iI(r.content,s.content,n+1);if(i!=null)return i}n+=r.nodeSize}}function lI(e,t,n,o){for(let r=e.childCount,s=t.childCount;;){if(r==0||s==0)return r==s?null:{a:n,b:o};let i=e.child(--r),l=t.child(--s),a=i.nodeSize;if(i==l){n-=a,o-=a;continue}if(!i.sameMarkup(l))return{a:n,b:o};if(i.isText&&i.text!=l.text){let u=0,c=Math.min(i.text.length,l.text.length);for(;u<c&&i.text[i.text.length-u-1]==l.text[l.text.length-u-1];)u++,n--,o--;return{a:n,b:o}}if(i.content.size||l.content.size){let u=lI(i.content,l.content,n-1,o-1);if(u)return u}n-=a,o-=a}}let Ue=class ko{constructor(t,n){if(this.content=t,this.size=n||0,n==null)for(let o=0;o<t.length;o++)this.size+=t[o].nodeSize}nodesBetween(t,n,o,r=0,s){for(let i=0,l=0;l<n;i++){let a=this.content[i],u=l+a.nodeSize;if(u>t&&o(a,r+l,s||null,i)!==!1&&a.content.size){let c=l+1;a.nodesBetween(Math.max(0,t-c),Math.min(a.content.size,n-c),o,r+c)}l=u}}descendants(t){this.nodesBetween(0,this.size,t)}textBetween(t,n,o,r){let s="",i=!0;return this.nodesBetween(t,n,(l,a)=>{let u=l.isText?l.text.slice(Math.max(t,a)-a,n-a):l.isLeaf?r?typeof r=="function"?r(l):r:l.type.spec.leafText?l.type.spec.leafText(l):"":"";l.isBlock&&(l.isLeaf&&u||l.isTextblock)&&o&&(i?i=!1:s+=o),s+=u},0),s}append(t){if(!t.size)return this;if(!this.size)return t;let n=this.lastChild,o=t.firstChild,r=this.content.slice(),s=0;for(n.isText&&n.sameMarkup(o)&&(r[r.length-1]=n.withText(n.text+o.text),s=1);s<t.content.length;s++)r.push(t.content[s]);return new ko(r,this.size+t.size)}cut(t,n=this.size){if(t==0&&n==this.size)return this;let o=[],r=0;if(n>t)for(let s=0,i=0;i<n;s++){let l=this.content[s],a=i+l.nodeSize;a>t&&((i<t||a>n)&&(l.isText?l=l.cut(Math.max(0,t-i),Math.min(l.text.length,n-i)):l=l.cut(Math.max(0,t-i-1),Math.min(l.content.size,n-i-1))),o.push(l),r+=l.nodeSize),i=a}return new ko(o,r)}cutByIndex(t,n){return t==n?ko.empty:t==0&&n==this.content.length?this:new ko(this.content.slice(t,n))}replaceChild(t,n){let o=this.content[t];if(o==n)return this;let r=this.content.slice(),s=this.size+n.nodeSize-o.nodeSize;return r[t]=n,new ko(r,s)}addToStart(t){return new ko([t].concat(this.content),this.size+t.nodeSize)}addToEnd(t){return new ko(this.content.concat(t),this.size+t.nodeSize)}eq(t){if(this.content.length!=t.content.length)return!1;for(let n=0;n<this.content.length;n++)if(!this.content[n].eq(t.content[n]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(t){let n=this.content[t];if(!n)throw new RangeError("Index "+t+" out of range for "+this);return n}maybeChild(t){return this.content[t]||null}forEach(t){for(let n=0,o=0;n<this.content.length;n++){let r=this.content[n];t(r,o,n),o+=r.nodeSize}}findDiffStart(t,n=0){return iI(this,t,n)}findDiffEnd(t,n=this.size,o=t.size){return lI(this,t,n,o)}findIndex(t,n=-1){if(t==0)return bm(0,t);if(t==this.size)return bm(this.content.length,t);if(t>this.size||t<0)throw new RangeError(`Position ${t} outside of fragment (${this})`);for(let o=0,r=0;;o++){let s=this.child(o),i=r+s.nodeSize;if(i>=t)return i==t||n>0?bm(o+1,i):bm(o,r);r=i}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(t=>t.toJSON()):null}static fromJSON(t,n){if(!n)return ko.empty;if(!Array.isArray(n))throw new RangeError("Invalid input for Fragment.fromJSON");return new ko(n.map(t.nodeFromJSON))}static fromArray(t){if(!t.length)return ko.empty;let n,o=0;for(let r=0;r<t.length;r++){let s=t[r];o+=s.nodeSize,r&&s.isText&&t[r-1].sameMarkup(s)?(n||(n=t.slice(0,r)),n[n.length-1]=s.withText(n[n.length-1].text+s.text)):n&&n.push(s)}return new ko(n||t,o)}static from(t){if(!t)return ko.empty;if(t instanceof ko)return t;if(Array.isArray(t))return this.fromArray(t);if(t.attrs)return new ko([t],t.nodeSize);throw new RangeError("Can not convert "+t+" to a Fragment"+(t.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}};Ue.empty=new Ue([],0);const my={index:0,offset:0};function bm(e,t){return my.index=e,my.offset=t,my}function zg(e,t){if(e===t)return!0;if(!(e&&typeof e=="object")||!(t&&typeof t=="object"))return!1;let n=Array.isArray(e);if(Array.isArray(t)!=n)return!1;if(n){if(e.length!=t.length)return!1;for(let o=0;o<e.length;o++)if(!zg(e[o],t[o]))return!1}else{for(let o in e)if(!(o in t)||!zg(e[o],t[o]))return!1;for(let o in t)if(!(o in e))return!1}return!0}let Yt=class Nb{constructor(t,n){this.type=t,this.attrs=n}addToSet(t){let n,o=!1;for(let r=0;r<t.length;r++){let s=t[r];if(this.eq(s))return t;if(this.type.excludes(s.type))n||(n=t.slice(0,r));else{if(s.type.excludes(this.type))return t;!o&&s.type.rank>this.type.rank&&(n||(n=t.slice(0,r)),n.push(this),o=!0),n&&n.push(s)}}return n||(n=t.slice()),o||n.push(this),n}removeFromSet(t){for(let n=0;n<t.length;n++)if(this.eq(t[n]))return t.slice(0,n).concat(t.slice(n+1));return t}isInSet(t){for(let n=0;n<t.length;n++)if(this.eq(t[n]))return!0;return!1}eq(t){return this==t||this.type==t.type&&zg(this.attrs,t.attrs)}toJSON(){let t={type:this.type.name};for(let n in this.attrs){t.attrs=this.attrs;break}return t}static fromJSON(t,n){if(!n)throw new RangeError("Invalid input for Mark.fromJSON");let o=t.marks[n.type];if(!o)throw new RangeError(`There is no mark type ${n.type} in this schema`);let r=o.create(n.attrs);return o.checkAttrs(r.attrs),r}static sameSet(t,n){if(t==n)return!0;if(t.length!=n.length)return!1;for(let o=0;o<t.length;o++)if(!t[o].eq(n[o]))return!1;return!0}static setFrom(t){if(!t||Array.isArray(t)&&t.length==0)return Nb.none;if(t instanceof Nb)return[t];let n=t.slice();return n.sort((o,r)=>o.type.rank-r.type.rank),n}};Yt.none=[];class jg extends Error{}class Ye{constructor(t,n,o){this.content=t,this.openStart=n,this.openEnd=o}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(t,n){let o=uI(this.content,t+this.openStart,n);return o&&new Ye(o,this.openStart,this.openEnd)}removeBetween(t,n){return new Ye(aI(this.content,t+this.openStart,n+this.openStart),this.openStart,this.openEnd)}eq(t){return this.content.eq(t.content)&&this.openStart==t.openStart&&this.openEnd==t.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let t={content:this.content.toJSON()};return this.openStart>0&&(t.openStart=this.openStart),this.openEnd>0&&(t.openEnd=this.openEnd),t}static fromJSON(t,n){if(!n)return Ye.empty;let o=n.openStart||0,r=n.openEnd||0;if(typeof o!="number"||typeof r!="number")throw new RangeError("Invalid input for Slice.fromJSON");return new Ye(Ue.fromJSON(t,n.content),o,r)}static maxOpen(t,n=!0){let o=0,r=0;for(let s=t.firstChild;s&&!s.isLeaf&&(n||!s.type.spec.isolating);s=s.firstChild)o++;for(let s=t.lastChild;s&&!s.isLeaf&&(n||!s.type.spec.isolating);s=s.lastChild)r++;return new Ye(t,o,r)}}Ye.empty=new Ye(Ue.empty,0,0);function aI(e,t,n){let{index:o,offset:r}=e.findIndex(t),s=e.maybeChild(o),{index:i,offset:l}=e.findIndex(n);if(r==t||s.isText){if(l!=n&&!e.child(i).isText)throw new RangeError("Removing non-flat range");return e.cut(0,t).append(e.cut(n))}if(o!=i)throw new RangeError("Removing non-flat range");return e.replaceChild(o,s.copy(aI(s.content,t-r-1,n-r-1)))}function uI(e,t,n,o){let{index:r,offset:s}=e.findIndex(t),i=e.maybeChild(r);if(s==t||i.isText)return o&&!o.canReplace(r,r,n)?null:e.cut(0,t).append(n).append(e.cut(t));let l=uI(i.content,t-s-1,n);return l&&e.replaceChild(r,i.copy(l))}function pve(e,t,n){if(n.openStart>e.depth)throw new jg("Inserted content deeper than insertion position");if(e.depth-n.openStart!=t.depth-n.openEnd)throw new jg("Inconsistent open depths");return cI(e,t,n,0)}function cI(e,t,n,o){let r=e.index(o),s=e.node(o);if(r==t.index(o)&&o<e.depth-n.openStart){let i=cI(e,t,n,o+1);return s.copy(s.content.replaceChild(r,i))}else if(n.content.size)if(!n.openStart&&!n.openEnd&&e.depth==o&&t.depth==o){let i=e.parent,l=i.content;return qa(i,l.cut(0,e.parentOffset).append(n.content).append(l.cut(t.parentOffset)))}else{let{start:i,end:l}=hve(n,e);return qa(s,fI(e,i,l,t,o))}else return qa(s,Hg(e,t,o))}function dI(e,t){if(!t.type.compatibleContent(e.type))throw new jg("Cannot join "+t.type.name+" onto "+e.type.name)}function Pb(e,t,n){let o=e.node(n);return dI(o,t.node(n)),o}function Ka(e,t){let n=t.length-1;n>=0&&e.isText&&e.sameMarkup(t[n])?t[n]=e.withText(t[n].text+e.text):t.push(e)}function Jf(e,t,n,o){let r=(t||e).node(n),s=0,i=t?t.index(n):r.childCount;e&&(s=e.index(n),e.depth>n?s++:e.textOffset&&(Ka(e.nodeAfter,o),s++));for(let l=s;l<i;l++)Ka(r.child(l),o);t&&t.depth==n&&t.textOffset&&Ka(t.nodeBefore,o)}function qa(e,t){return e.type.checkContent(t),e.copy(t)}function fI(e,t,n,o,r){let s=e.depth>r&&Pb(e,t,r+1),i=o.depth>r&&Pb(n,o,r+1),l=[];return Jf(null,e,r,l),s&&i&&t.index(r)==n.index(r)?(dI(s,i),Ka(qa(s,fI(e,t,n,o,r+1)),l)):(s&&Ka(qa(s,Hg(e,t,r+1)),l),Jf(t,n,r,l),i&&Ka(qa(i,Hg(n,o,r+1)),l)),Jf(o,null,r,l),new Ue(l)}function Hg(e,t,n){let o=[];if(Jf(null,e,n,o),e.depth>n){let r=Pb(e,t,n+1);Ka(qa(r,Hg(e,t,n+1)),o)}return Jf(t,null,n,o),new Ue(o)}function hve(e,t){let n=t.depth-e.openStart,r=t.node(n).copy(e.content);for(let s=n-1;s>=0;s--)r=t.node(s).copy(Ue.from(r));return{start:r.resolveNoCache(e.openStart+n),end:r.resolveNoCache(r.content.size-e.openEnd-n)}}class Bp{constructor(t,n,o){this.pos=t,this.path=n,this.parentOffset=o,this.depth=n.length/3-1}resolveDepth(t){return t==null?this.depth:t<0?this.depth+t:t}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(t){return this.path[this.resolveDepth(t)*3]}index(t){return this.path[this.resolveDepth(t)*3+1]}indexAfter(t){return t=this.resolveDepth(t),this.index(t)+(t==this.depth&&!this.textOffset?0:1)}start(t){return t=this.resolveDepth(t),t==0?0:this.path[t*3-1]+1}end(t){return t=this.resolveDepth(t),this.start(t)+this.node(t).content.size}before(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position before the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]}after(t){if(t=this.resolveDepth(t),!t)throw new RangeError("There is no position after the top-level node");return t==this.depth+1?this.pos:this.path[t*3-1]+this.path[t*3].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let t=this.parent,n=this.index(this.depth);if(n==t.childCount)return null;let o=this.pos-this.path[this.path.length-1],r=t.child(n);return o?t.child(n).cut(o):r}get nodeBefore(){let t=this.index(this.depth),n=this.pos-this.path[this.path.length-1];return n?this.parent.child(t).cut(0,n):t==0?null:this.parent.child(t-1)}posAtIndex(t,n){n=this.resolveDepth(n);let o=this.path[n*3],r=n==0?0:this.path[n*3-1]+1;for(let s=0;s<t;s++)r+=o.child(s).nodeSize;return r}marks(){let t=this.parent,n=this.index();if(t.content.size==0)return Yt.none;if(this.textOffset)return t.child(n).marks;let o=t.maybeChild(n-1),r=t.maybeChild(n);if(!o){let l=o;o=r,r=l}let s=o.marks;for(var i=0;i<s.length;i++)s[i].type.spec.inclusive===!1&&(!r||!s[i].isInSet(r.marks))&&(s=s[i--].removeFromSet(s));return s}marksAcross(t){let n=this.parent.maybeChild(this.index());if(!n||!n.isInline)return null;let o=n.marks,r=t.parent.maybeChild(t.index());for(var s=0;s<o.length;s++)o[s].type.spec.inclusive===!1&&(!r||!o[s].isInSet(r.marks))&&(o=o[s--].removeFromSet(o));return o}sharedDepth(t){for(let n=this.depth;n>0;n--)if(this.start(n)<=t&&this.end(n)>=t)return n;return 0}blockRange(t=this,n){if(t.pos<this.pos)return t.blockRange(this);for(let o=this.depth-(this.parent.inlineContent||this.pos==t.pos?1:0);o>=0;o--)if(t.pos<=this.end(o)&&(!n||n(this.node(o))))return new pI(this,t,o);return null}sameParent(t){return this.pos-this.parentOffset==t.pos-t.parentOffset}max(t){return t.pos>this.pos?t:this}min(t){return t.pos<this.pos?t:this}toString(){let t="";for(let n=1;n<=this.depth;n++)t+=(t?"/":"")+this.node(n).type.name+"_"+this.index(n-1);return t+":"+this.parentOffset}static resolve(t,n){if(!(n>=0&&n<=t.content.size))throw new RangeError("Position "+n+" out of range");let o=[],r=0,s=n;for(let i=t;;){let{index:l,offset:a}=i.content.findIndex(s),u=s-a;if(o.push(i,l,r+a),!u||(i=i.child(l),i.isText))break;s=u-1,r+=a+1}return new Bp(n,o,s)}static resolveCached(t,n){let o=Y8.get(t);if(o)for(let s=0;s<o.elts.length;s++){let i=o.elts[s];if(i.pos==n)return i}else Y8.set(t,o=new mve);let r=o.elts[o.i]=Bp.resolve(t,n);return o.i=(o.i+1)%gve,r}}class mve{constructor(){this.elts=[],this.i=0}}const gve=12,Y8=new WeakMap;class pI{constructor(t,n,o){this.$from=t,this.$to=n,this.depth=o}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}}const vve=Object.create(null);let Ll=class Lb{constructor(t,n,o,r=Yt.none){this.type=t,this.attrs=n,this.marks=r,this.content=o||Ue.empty}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(t){return this.content.child(t)}maybeChild(t){return this.content.maybeChild(t)}forEach(t){this.content.forEach(t)}nodesBetween(t,n,o,r=0){this.content.nodesBetween(t,n,o,r,this)}descendants(t){this.nodesBetween(0,this.content.size,t)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(t,n,o,r){return this.content.textBetween(t,n,o,r)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(t){return this==t||this.sameMarkup(t)&&this.content.eq(t.content)}sameMarkup(t){return this.hasMarkup(t.type,t.attrs,t.marks)}hasMarkup(t,n,o){return this.type==t&&zg(this.attrs,n||t.defaultAttrs||vve)&&Yt.sameSet(this.marks,o||Yt.none)}copy(t=null){return t==this.content?this:new Lb(this.type,this.attrs,t,this.marks)}mark(t){return t==this.marks?this:new Lb(this.type,this.attrs,this.content,t)}cut(t,n=this.content.size){return t==0&&n==this.content.size?this:this.copy(this.content.cut(t,n))}slice(t,n=this.content.size,o=!1){if(t==n)return Ye.empty;let r=this.resolve(t),s=this.resolve(n),i=o?0:r.sharedDepth(n),l=r.start(i),u=r.node(i).content.cut(r.pos-l,s.pos-l);return new Ye(u,r.depth-i,s.depth-i)}replace(t,n,o){return pve(this.resolve(t),this.resolve(n),o)}nodeAt(t){for(let n=this;;){let{index:o,offset:r}=n.content.findIndex(t);if(n=n.maybeChild(o),!n)return null;if(r==t||n.isText)return n;t-=r+1}}childAfter(t){let{index:n,offset:o}=this.content.findIndex(t);return{node:this.content.maybeChild(n),index:n,offset:o}}childBefore(t){if(t==0)return{node:null,index:0,offset:0};let{index:n,offset:o}=this.content.findIndex(t);if(o<t)return{node:this.content.child(n),index:n,offset:o};let r=this.content.child(n-1);return{node:r,index:n-1,offset:o-r.nodeSize}}resolve(t){return Bp.resolveCached(this,t)}resolveNoCache(t){return Bp.resolve(this,t)}rangeHasMark(t,n,o){let r=!1;return n>t&&this.nodesBetween(t,n,s=>(o.isInSet(s.marks)&&(r=!0),!r)),r}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let t=this.type.name;return this.content.size&&(t+="("+this.content.toStringInner()+")"),hI(this.marks,t)}contentMatchAt(t){let n=this.type.contentMatch.matchFragment(this.content,0,t);if(!n)throw new Error("Called contentMatchAt on a node with invalid content");return n}canReplace(t,n,o=Ue.empty,r=0,s=o.childCount){let i=this.contentMatchAt(t).matchFragment(o,r,s),l=i&&i.matchFragment(this.content,n);if(!l||!l.validEnd)return!1;for(let a=r;a<s;a++)if(!this.type.allowsMarks(o.child(a).marks))return!1;return!0}canReplaceWith(t,n,o,r){if(r&&!this.type.allowsMarks(r))return!1;let s=this.contentMatchAt(t).matchType(o),i=s&&s.matchFragment(this.content,n);return i?i.validEnd:!1}canAppend(t){return t.content.size?this.canReplace(this.childCount,this.childCount,t.content):this.type.compatibleContent(t.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let t=Yt.none;for(let n=0;n<this.marks.length;n++){let o=this.marks[n];o.type.checkAttrs(o.attrs),t=o.addToSet(t)}if(!Yt.sameSet(t,this.marks))throw new RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(n=>n.type.name)}`);this.content.forEach(n=>n.check())}toJSON(){let t={type:this.type.name};for(let n in this.attrs){t.attrs=this.attrs;break}return this.content.size&&(t.content=this.content.toJSON()),this.marks.length&&(t.marks=this.marks.map(n=>n.toJSON())),t}static fromJSON(t,n){if(!n)throw new RangeError("Invalid input for Node.fromJSON");let o;if(n.marks){if(!Array.isArray(n.marks))throw new RangeError("Invalid mark data for Node.fromJSON");o=n.marks.map(t.markFromJSON)}if(n.type=="text"){if(typeof n.text!="string")throw new RangeError("Invalid text node in JSON");return t.text(n.text,o)}let r=Ue.fromJSON(t,n.content),s=t.nodeType(n.type).create(n.attrs,r,o);return s.type.checkAttrs(s.attrs),s}};Ll.prototype.text=void 0;class Ug extends Ll{constructor(t,n,o,r){if(super(t,n,null,r),!o)throw new RangeError("Empty text nodes are not allowed");this.text=o}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):hI(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(t,n){return this.text.slice(t,n)}get nodeSize(){return this.text.length}mark(t){return t==this.marks?this:new Ug(this.type,this.attrs,this.text,t)}withText(t){return t==this.text?this:new Ug(this.type,this.attrs,t,this.marks)}cut(t=0,n=this.text.length){return t==0&&n==this.text.length?this:this.withText(this.text.slice(t,n))}eq(t){return this.sameMarkup(t)&&this.text==t.text}toJSON(){let t=super.toJSON();return t.text=this.text,t}}function hI(e,t){for(let n=e.length-1;n>=0;n--)t=e[n].type.name+"("+t+")";return t}class du{constructor(t){this.validEnd=t,this.next=[],this.wrapCache=[]}static parse(t,n){let o=new yve(t,n);if(o.next==null)return du.empty;let r=mI(o);o.next&&o.err("Unexpected trailing text");let s=$ve(Sve(r));return Eve(s,o),s}matchType(t){for(let n=0;n<this.next.length;n++)if(this.next[n].type==t)return this.next[n].next;return null}matchFragment(t,n=0,o=t.childCount){let r=this;for(let s=n;r&&s<o;s++)r=r.matchType(t.child(s).type);return r}get inlineContent(){return this.next.length!=0&&this.next[0].type.isInline}get defaultType(){for(let t=0;t<this.next.length;t++){let{type:n}=this.next[t];if(!(n.isText||n.hasRequiredAttrs()))return n}return null}compatible(t){for(let n=0;n<this.next.length;n++)for(let o=0;o<t.next.length;o++)if(this.next[n].type==t.next[o].type)return!0;return!1}fillBefore(t,n=!1,o=0){let r=[this];function s(i,l){let a=i.matchFragment(t,o);if(a&&(!n||a.validEnd))return Ue.from(l.map(u=>u.createAndFill()));for(let u=0;u<i.next.length;u++){let{type:c,next:d}=i.next[u];if(!(c.isText||c.hasRequiredAttrs())&&r.indexOf(d)==-1){r.push(d);let f=s(d,l.concat(c));if(f)return f}}return null}return s(this,[])}findWrapping(t){for(let o=0;o<this.wrapCache.length;o+=2)if(this.wrapCache[o]==t)return this.wrapCache[o+1];let n=this.computeWrapping(t);return this.wrapCache.push(t,n),n}computeWrapping(t){let n=Object.create(null),o=[{match:this,type:null,via:null}];for(;o.length;){let r=o.shift(),s=r.match;if(s.matchType(t)){let i=[];for(let l=r;l.type;l=l.via)i.push(l.type);return i.reverse()}for(let i=0;i<s.next.length;i++){let{type:l,next:a}=s.next[i];!l.isLeaf&&!l.hasRequiredAttrs()&&!(l.name in n)&&(!r.type||a.validEnd)&&(o.push({match:l.contentMatch,type:l,via:r}),n[l.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(t){if(t>=this.next.length)throw new RangeError(`There's no ${t}th edge in this content match`);return this.next[t]}toString(){let t=[];function n(o){t.push(o);for(let r=0;r<o.next.length;r++)t.indexOf(o.next[r].next)==-1&&n(o.next[r].next)}return n(this),t.map((o,r)=>{let s=r+(o.validEnd?"*":" ")+" ";for(let i=0;i<o.next.length;i++)s+=(i?", ":"")+o.next[i].type.name+"->"+t.indexOf(o.next[i].next);return s}).join(`
77 `)}}du.empty=new du(!0);class yve{constructor(t,n){this.string=t,this.nodeTypes=n,this.inline=null,this.pos=0,this.tokens=t.split(/\s*(?=\b|\W|$)/),this.tokens[this.tokens.length-1]==""&&this.tokens.pop(),this.tokens[0]==""&&this.tokens.shift()}get next(){return this.tokens[this.pos]}eat(t){return this.next==t&&(this.pos++||!0)}err(t){throw new SyntaxError(t+" (in content expression '"+this.string+"')")}}function mI(e){let t=[];do t.push(_ve(e));while(e.eat("|"));return t.length==1?t[0]:{type:"choice",exprs:t}}function _ve(e){let t=[];do t.push(bve(e));while(e.next&&e.next!=")"&&e.next!="|");return t.length==1?t[0]:{type:"seq",exprs:t}}function bve(e){let t=kve(e);for(;;)if(e.eat("+"))t={type:"plus",expr:t};else if(e.eat("*"))t={type:"star",expr:t};else if(e.eat("?"))t={type:"opt",expr:t};else if(e.eat("{"))t=wve(e,t);else break;return t}function Z8(e){/\D/.test(e.next)&&e.err("Expected number, got '"+e.next+"'");let t=Number(e.next);return e.pos++,t}function wve(e,t){let n=Z8(e),o=n;return e.eat(",")&&(e.next!="}"?o=Z8(e):o=-1),e.eat("}")||e.err("Unclosed braced range"),{type:"range",min:n,max:o,expr:t}}function Cve(e,t){let n=e.nodeTypes,o=n[t];if(o)return[o];let r=[];for(let s in n){let i=n[s];i.groups.indexOf(t)>-1&&r.push(i)}return r.length==0&&e.err("No node type or group '"+t+"' found"),r}function kve(e){if(e.eat("(")){let t=mI(e);return e.eat(")")||e.err("Missing closing paren"),t}else if(/\W/.test(e.next))e.err("Unexpected token '"+e.next+"'");else{let t=Cve(e,e.next).map(n=>(e.inline==null?e.inline=n.isInline:e.inline!=n.isInline&&e.err("Mixing inline and block content"),{type:"name",value:n}));return e.pos++,t.length==1?t[0]:{type:"choice",exprs:t}}}function Sve(e){let t=[[]];return r(s(e,0),n()),t;function n(){return t.push([])-1}function o(i,l,a){let u={term:a,to:l};return t[i].push(u),u}function r(i,l){i.forEach(a=>a.to=l)}function s(i,l){if(i.type=="choice")return i.exprs.reduce((a,u)=>a.concat(s(u,l)),[]);if(i.type=="seq")for(let a=0;;a++){let u=s(i.exprs[a],l);if(a==i.exprs.length-1)return u;r(u,l=n())}else if(i.type=="star"){let a=n();return o(l,a),r(s(i.expr,a),a),[o(a)]}else if(i.type=="plus"){let a=n();return r(s(i.expr,l),a),r(s(i.expr,a),a),[o(a)]}else{if(i.type=="opt")return[o(l)].concat(s(i.expr,l));if(i.type=="range"){let a=l;for(let u=0;u<i.min;u++){let c=n();r(s(i.expr,a),c),a=c}if(i.max==-1)r(s(i.expr,a),a);else for(let u=i.min;u<i.max;u++){let c=n();o(a,c),r(s(i.expr,a),c),a=c}return[o(a)]}else{if(i.type=="name")return[o(l,void 0,i.value)];throw new Error("Unknown expr type")}}}}function gI(e,t){return t-e}function J8(e,t){let n=[];return o(t),n.sort(gI);function o(r){let s=e[r];if(s.length==1&&!s[0].term)return o(s[0].to);n.push(r);for(let i=0;i<s.length;i++){let{term:l,to:a}=s[i];!l&&n.indexOf(a)==-1&&o(a)}}}function $ve(e){let t=Object.create(null);return n(J8(e,0));function n(o){let r=[];o.forEach(i=>{e[i].forEach(({term:l,to:a})=>{if(!l)return;let u;for(let c=0;c<r.length;c++)r[c][0]==l&&(u=r[c][1]);J8(e,a).forEach(c=>{u||r.push([l,u=[]]),u.indexOf(c)==-1&&u.push(c)})})});let s=t[o.join(",")]=new du(o.indexOf(e.length-1)>-1);for(let i=0;i<r.length;i++){let l=r[i][1].sort(gI);s.next.push({type:r[i][0],next:t[l.join(",")]||n(l)})}return s}}function Eve(e,t){for(let n=0,o=[e];n<o.length;n++){let r=o[n],s=!r.validEnd,i=[];for(let l=0;l<r.next.length;l++){let{type:a,next:u}=r.next[l];i.push(a.name),s&&!(a.isText||a.hasRequiredAttrs())&&(s=!1),o.indexOf(u)==-1&&o.push(u)}s&&t.err("Only non-generatable nodes ("+i.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}function vI(e){let t=Object.create(null);for(let n in e){let o=e[n];if(!o.hasDefault)return null;t[n]=o.default}return t}function yI(e,t){let n=Object.create(null);for(let o in e){let r=t&&t[o];if(r===void 0){let s=e[o];if(s.hasDefault)r=s.default;else throw new RangeError("No value supplied for attribute "+o)}n[o]=r}return n}function _I(e,t,n,o){for(let r in t)if(!(r in e))throw new RangeError(`Unsupported attribute ${r} for ${n} of type ${r}`);for(let r in e){let s=e[r];s.validate&&s.validate(t[r])}}function bI(e,t){let n=Object.create(null);if(t)for(let o in t)n[o]=new Mve(e,o,t[o]);return n}let X8=class wI{constructor(t,n,o){this.name=t,this.schema=n,this.spec=o,this.markSet=null,this.groups=o.group?o.group.split(" "):[],this.attrs=bI(t,o.attrs),this.defaultAttrs=vI(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(o.inline||t=="text"),this.isText=t=="text"}get isInline(){return!this.isBlock}get isTextblock(){return this.isBlock&&this.inlineContent}get isLeaf(){return this.contentMatch==du.empty}get isAtom(){return this.isLeaf||!!this.spec.atom}get whitespace(){return this.spec.whitespace||(this.spec.code?"pre":"normal")}hasRequiredAttrs(){for(let t in this.attrs)if(this.attrs[t].isRequired)return!0;return!1}compatibleContent(t){return this==t||this.contentMatch.compatible(t.contentMatch)}computeAttrs(t){return!t&&this.defaultAttrs?this.defaultAttrs:yI(this.attrs,t)}create(t=null,n,o){if(this.isText)throw new Error("NodeType.create can't construct text nodes");return new Ll(this,this.computeAttrs(t),Ue.from(n),Yt.setFrom(o))}createChecked(t=null,n,o){return n=Ue.from(n),this.checkContent(n),new Ll(this,this.computeAttrs(t),n,Yt.setFrom(o))}createAndFill(t=null,n,o){if(t=this.computeAttrs(t),n=Ue.from(n),n.size){let i=this.contentMatch.fillBefore(n);if(!i)return null;n=i.append(n)}let r=this.contentMatch.matchFragment(n),s=r&&r.fillBefore(Ue.empty,!0);return s?new Ll(this,t,n.append(s),Yt.setFrom(o)):null}validContent(t){let n=this.contentMatch.matchFragment(t);if(!n||!n.validEnd)return!1;for(let o=0;o<t.childCount;o++)if(!this.allowsMarks(t.child(o).marks))return!1;return!0}checkContent(t){if(!this.validContent(t))throw new RangeError(`Invalid content for node ${this.name}: ${t.toString().slice(0,50)}`)}checkAttrs(t){_I(this.attrs,t,"node",this.name)}allowsMarkType(t){return this.markSet==null||this.markSet.indexOf(t)>-1}allowsMarks(t){if(this.markSet==null)return!0;for(let n=0;n<t.length;n++)if(!this.allowsMarkType(t[n].type))return!1;return!0}allowedMarks(t){if(this.markSet==null)return t;let n;for(let o=0;o<t.length;o++)this.allowsMarkType(t[o].type)?n&&n.push(t[o]):n||(n=t.slice(0,o));return n?n.length?n:Yt.none:t}static compile(t,n){let o=Object.create(null);t.forEach((s,i)=>o[s]=new wI(s,n,i));let r=n.spec.topNode||"doc";if(!o[r])throw new RangeError("Schema is missing its top node type ('"+r+"')");if(!o.text)throw new RangeError("Every schema needs a 'text' type");for(let s in o.text.attrs)throw new RangeError("The text node type should not have attributes");return o}};function xve(e,t,n){let o=n.split("|");return r=>{let s=r===null?"null":typeof r;if(o.indexOf(s)<0)throw new RangeError(`Expected value of type ${o} for attribute ${t} on type ${e}, got ${s}`)}}class Mve{constructor(t,n,o){this.hasDefault=Object.prototype.hasOwnProperty.call(o,"default"),this.default=o.default,this.validate=typeof o.validate=="string"?xve(t,n,o.validate):o.validate}get isRequired(){return!this.hasDefault}}class Q0{constructor(t,n,o,r){this.name=t,this.rank=n,this.schema=o,this.spec=r,this.attrs=bI(t,r.attrs),this.excluded=null;let s=vI(this.attrs);this.instance=s?new Yt(this,s):null}create(t=null){return!t&&this.instance?this.instance:new Yt(this,yI(this.attrs,t))}static compile(t,n){let o=Object.create(null),r=0;return t.forEach((s,i)=>o[s]=new Q0(s,r++,n,i)),o}removeFromSet(t){for(var n=0;n<t.length;n++)t[n].type==this&&(t=t.slice(0,n).concat(t.slice(n+1)),n--);return t}isInSet(t){for(let n=0;n<t.length;n++)if(t[n].type==this)return t[n]}checkAttrs(t){_I(this.attrs,t,"mark",this.name)}excludes(t){return this.excluded.indexOf(t)>-1}}class Tve{constructor(t){this.linebreakReplacement=null,this.cached=Object.create(null);let n=this.spec={};for(let r in t)n[r]=t[r];n.nodes=Xn.from(t.nodes),n.marks=Xn.from(t.marks||{}),this.nodes=X8.compile(this.spec.nodes,this),this.marks=Q0.compile(this.spec.marks,this);let o=Object.create(null);for(let r in this.nodes){if(r in this.marks)throw new RangeError(r+" can not be both a node and a mark");let s=this.nodes[r],i=s.spec.content||"",l=s.spec.marks;if(s.contentMatch=o[i]||(o[i]=du.parse(i,this.nodes)),s.inlineContent=s.contentMatch.inlineContent,s.spec.linebreakReplacement){if(this.linebreakReplacement)throw new RangeError("Multiple linebreak nodes defined");if(!s.isInline||!s.isLeaf)throw new RangeError("Linebreak replacement nodes must be inline leaf nodes");this.linebreakReplacement=s}s.markSet=l=="_"?null:l?Q8(this,l.split(" ")):l==""||!s.inlineContent?[]:null}for(let r in this.marks){let s=this.marks[r],i=s.spec.excludes;s.excluded=i==null?[s]:i==""?[]:Q8(this,i.split(" "))}this.nodeFromJSON=this.nodeFromJSON.bind(this),this.markFromJSON=this.markFromJSON.bind(this),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached.wrappings=Object.create(null)}node(t,n=null,o,r){if(typeof t=="string")t=this.nodeType(t);else if(t instanceof X8){if(t.schema!=this)throw new RangeError("Node type from different schema used ("+t.name+")")}else throw new RangeError("Invalid node type: "+t);return t.createChecked(n,o,r)}text(t,n){let o=this.nodes.text;return new Ug(o,o.defaultAttrs,t,Yt.setFrom(n))}mark(t,n){return typeof t=="string"&&(t=this.marks[t]),t.create(n)}nodeFromJSON(t){return Ll.fromJSON(this,t)}markFromJSON(t){return Yt.fromJSON(this,t)}nodeType(t){let n=this.nodes[t];if(!n)throw new RangeError("Unknown node type: "+t);return n}}function Q8(e,t){let n=[];for(let o=0;o<t.length;o++){let r=t[o],s=e.marks[r],i=s;if(s)n.push(s);else for(let l in e.marks){let a=e.marks[l];(r=="_"||a.spec.group&&a.spec.group.split(" ").indexOf(r)>-1)&&n.push(i=a)}if(!i)throw new SyntaxError("Unknown mark type: '"+t[o]+"'")}return n}function Ove(e){return e.tag!=null}function Ive(e){return e.style!=null}class fu{constructor(t,n){this.schema=t,this.rules=n,this.tags=[],this.styles=[];let o=this.matchedStyles=[];n.forEach(r=>{if(Ove(r))this.tags.push(r);else if(Ive(r)){let s=/[^=]*/.exec(r.style)[0];o.indexOf(s)<0&&o.push(s),this.styles.push(r)}}),this.normalizeLists=!this.tags.some(r=>{if(!/^(ul|ol)\b/.test(r.tag)||!r.node)return!1;let s=t.nodes[r.node];return s.contentMatch.matchType(s)})}parse(t,n={}){let o=new tS(this,n,!1);return o.addAll(t,Yt.none,n.from,n.to),o.finish()}parseSlice(t,n={}){let o=new tS(this,n,!0);return o.addAll(t,Yt.none,n.from,n.to),Ye.maxOpen(o.finish())}matchTag(t,n,o){for(let r=o?this.tags.indexOf(o)+1:0;r<this.tags.length;r++){let s=this.tags[r];if(Pve(t,s.tag)&&(s.namespace===void 0||t.namespaceURI==s.namespace)&&(!s.context||n.matchesContext(s.context))){if(s.getAttrs){let i=s.getAttrs(t);if(i===!1)continue;s.attrs=i||void 0}return s}}}matchStyle(t,n,o,r){for(let s=r?this.styles.indexOf(r)+1:0;s<this.styles.length;s++){let i=this.styles[s],l=i.style;if(!(l.indexOf(t)!=0||i.context&&!o.matchesContext(i.context)||l.length>t.length&&(l.charCodeAt(t.length)!=61||l.slice(t.length+1)!=n))){if(i.getAttrs){let a=i.getAttrs(n);if(a===!1)continue;i.attrs=a||void 0}return i}}}static schemaRules(t){let n=[];function o(r){let s=r.priority==null?50:r.priority,i=0;for(;i<n.length;i++){let l=n[i];if((l.priority==null?50:l.priority)<s)break}n.splice(i,0,r)}for(let r in t.marks){let s=t.marks[r].spec.parseDOM;s&&s.forEach(i=>{o(i=nS(i)),i.mark||i.ignore||i.clearMark||(i.mark=r)})}for(let r in t.nodes){let s=t.nodes[r].spec.parseDOM;s&&s.forEach(i=>{o(i=nS(i)),i.node||i.ignore||i.mark||(i.node=r)})}return n}static fromSchema(t){return t.cached.domParser||(t.cached.domParser=new fu(t,fu.schemaRules(t)))}}const CI={address:!0,article:!0,aside:!0,blockquote:!0,canvas:!0,dd:!0,div:!0,dl:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,li:!0,noscript:!0,ol:!0,output:!0,p:!0,pre:!0,section:!0,table:!0,tfoot:!0,ul:!0},Ave={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},kI={ol:!0,ul:!0},Wg=1,Kg=2,Xf=4;function eS(e,t,n){return t!=null?(t?Wg:0)|(t==="full"?Kg:0):e&&e.whitespace=="pre"?Wg|Kg:n&~Xf}class wm{constructor(t,n,o,r,s,i){this.type=t,this.attrs=n,this.marks=o,this.solid=r,this.options=i,this.content=[],this.activeMarks=Yt.none,this.match=s||(i&Xf?null:t.contentMatch)}findWrapping(t){if(!this.match){if(!this.type)return[];let n=this.type.contentMatch.fillBefore(Ue.from(t));if(n)this.match=this.type.contentMatch.matchFragment(n);else{let o=this.type.contentMatch,r;return(r=o.findWrapping(t.type))?(this.match=o,r):null}}return this.match.findWrapping(t.type)}finish(t){if(!(this.options&Wg)){let o=this.content[this.content.length-1],r;if(o&&o.isText&&(r=/[ \t\r\n\u000c]+$/.exec(o.text))){let s=o;o.text.length==r[0].length?this.content.pop():this.content[this.content.length-1]=s.withText(s.text.slice(0,s.text.length-r[0].length))}}let n=Ue.from(this.content);return!t&&this.match&&(n=n.append(this.match.fillBefore(Ue.empty,!0))),this.type?this.type.create(this.attrs,n,this.marks):n}inlineContext(t){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:t.parentNode&&!CI.hasOwnProperty(t.parentNode.nodeName.toLowerCase())}}class tS{constructor(t,n,o){this.parser=t,this.options=n,this.isOpen=o,this.open=0;let r=n.topNode,s,i=eS(null,n.preserveWhitespace,0)|(o?Xf:0);r?s=new wm(r.type,r.attrs,Yt.none,!0,n.topMatch||r.type.contentMatch,i):o?s=new wm(null,null,Yt.none,!0,null,i):s=new wm(t.schema.topNodeType,null,Yt.none,!0,null,i),this.nodes=[s],this.find=n.findPositions,this.needsBlock=!1}get top(){return this.nodes[this.open]}addDOM(t,n){t.nodeType==3?this.addTextNode(t,n):t.nodeType==1&&this.addElement(t,n)}addTextNode(t,n){let o=t.nodeValue,r=this.top;if(r.options&Kg||r.inlineContext(t)||/[^ \t\r\n\u000c]/.test(o)){if(r.options&Wg)r.options&Kg?o=o.replace(/\r\n?/g,`
78 `):o=o.replace(/\r?\n|\r/g," ");else if(o=o.replace(/[ \t\r\n\u000c]+/g," "),/^[ \t\r\n\u000c]/.test(o)&&this.open==this.nodes.length-1){let s=r.content[r.content.length-1],i=t.previousSibling;(!s||i&&i.nodeName=="BR"||s.isText&&/[ \t\r\n\u000c]$/.test(s.text))&&(o=o.slice(1))}o&&this.insertNode(this.parser.schema.text(o),n),this.findInText(t)}else this.findInside(t)}addElement(t,n,o){let r=t.nodeName.toLowerCase(),s;kI.hasOwnProperty(r)&&this.parser.normalizeLists&&Nve(t);let i=this.options.ruleFromNode&&this.options.ruleFromNode(t)||(s=this.parser.matchTag(t,this,o));if(i?i.ignore:Ave.hasOwnProperty(r))this.findInside(t),this.ignoreFallback(t,n);else if(!i||i.skip||i.closeParent){i&&i.closeParent?this.open=Math.max(0,this.open-1):i&&i.skip.nodeType&&(t=i.skip);let l,a=this.top,u=this.needsBlock;if(CI.hasOwnProperty(r))a.content.length&&a.content[0].isInline&&this.open&&(this.open--,a=this.top),l=!0,a.type||(this.needsBlock=!0);else if(!t.firstChild){this.leafFallback(t,n);return}let c=i&&i.skip?n:this.readStyles(t,n);c&&this.addAll(t,c),l&&this.sync(a),this.needsBlock=u}else{let l=this.readStyles(t,n);l&&this.addElementByRule(t,i,l,i.consuming===!1?s:void 0)}}leafFallback(t,n){t.nodeName=="BR"&&this.top.type&&this.top.type.inlineContent&&this.addTextNode(t.ownerDocument.createTextNode(`
79 `),n)}ignoreFallback(t,n){t.nodeName=="BR"&&(!this.top.type||!this.top.type.inlineContent)&&this.findPlace(this.parser.schema.text("-"),n)}readStyles(t,n){let o=t.style;if(o&&o.length)for(let r=0;r<this.parser.matchedStyles.length;r++){let s=this.parser.matchedStyles[r],i=o.getPropertyValue(s);if(i)for(let l=void 0;;){let a=this.parser.matchStyle(s,i,this,l);if(!a)break;if(a.ignore)return null;if(a.clearMark?n=n.filter(u=>!a.clearMark(u)):n=n.concat(this.parser.schema.marks[a.mark].create(a.attrs)),a.consuming===!1)l=a;else break}}return n}addElementByRule(t,n,o,r){let s,i;if(n.node)if(i=this.parser.schema.nodes[n.node],i.isLeaf)this.insertNode(i.create(n.attrs),o)||this.leafFallback(t,o);else{let a=this.enter(i,n.attrs||null,o,n.preserveWhitespace);a&&(s=!0,o=a)}else{let a=this.parser.schema.marks[n.mark];o=o.concat(a.create(n.attrs))}let l=this.top;if(i&&i.isLeaf)this.findInside(t);else if(r)this.addElement(t,o,r);else if(n.getContent)this.findInside(t),n.getContent(t,this.parser.schema).forEach(a=>this.insertNode(a,o));else{let a=t;typeof n.contentElement=="string"?a=t.querySelector(n.contentElement):typeof n.contentElement=="function"?a=n.contentElement(t):n.contentElement&&(a=n.contentElement),this.findAround(t,a,!0),this.addAll(a,o)}s&&this.sync(l)&&this.open--}addAll(t,n,o,r){let s=o||0;for(let i=o?t.childNodes[o]:t.firstChild,l=r==null?null:t.childNodes[r];i!=l;i=i.nextSibling,++s)this.findAtPoint(t,s),this.addDOM(i,n);this.findAtPoint(t,s)}findPlace(t,n){let o,r;for(let s=this.open;s>=0;s--){let i=this.nodes[s],l=i.findWrapping(t);if(l&&(!o||o.length>l.length)&&(o=l,r=i,!l.length)||i.solid)break}if(!o)return null;this.sync(r);for(let s=0;s<o.length;s++)n=this.enterInner(o[s],null,n,!1);return n}insertNode(t,n){if(t.isInline&&this.needsBlock&&!this.top.type){let r=this.textblockFromContext();r&&(n=this.enterInner(r,null,n))}let o=this.findPlace(t,n);if(o){this.closeExtra();let r=this.top;r.match&&(r.match=r.match.matchType(t.type));let s=Yt.none;for(let i of o.concat(t.marks))(r.type?r.type.allowsMarkType(i.type):oS(i.type,t.type))&&(s=i.addToSet(s));return r.content.push(t.mark(s)),!0}return!1}enter(t,n,o,r){let s=this.findPlace(t.create(n),o);return s&&(s=this.enterInner(t,n,o,!0,r)),s}enterInner(t,n,o,r=!1,s){this.closeExtra();let i=this.top;i.match=i.match&&i.match.matchType(t);let l=eS(t,s,i.options);i.options&Xf&&i.content.length==0&&(l|=Xf);let a=Yt.none;return o=o.filter(u=>(i.type?i.type.allowsMarkType(u.type):oS(u.type,t))?(a=u.addToSet(a),!1):!0),this.nodes.push(new wm(t,n,a,r,null,l)),this.open++,o}closeExtra(t=!1){let n=this.nodes.length-1;if(n>this.open){for(;n>this.open;n--)this.nodes[n-1].content.push(this.nodes[n].finish(t));this.nodes.length=this.open+1}}finish(){return this.open=0,this.closeExtra(this.isOpen),this.nodes[0].finish(this.isOpen||this.options.topOpen)}sync(t){for(let n=this.open;n>=0;n--)if(this.nodes[n]==t)return this.open=n,!0;return!1}get currentPos(){this.closeExtra();let t=0;for(let n=this.open;n>=0;n--){let o=this.nodes[n].content;for(let r=o.length-1;r>=0;r--)t+=o[r].nodeSize;n&&t++}return t}findAtPoint(t,n){if(this.find)for(let o=0;o<this.find.length;o++)this.find[o].node==t&&this.find[o].offset==n&&(this.find[o].pos=this.currentPos)}findInside(t){if(this.find)for(let n=0;n<this.find.length;n++)this.find[n].pos==null&&t.nodeType==1&&t.contains(this.find[n].node)&&(this.find[n].pos=this.currentPos)}findAround(t,n,o){if(t!=n&&this.find)for(let r=0;r<this.find.length;r++)this.find[r].pos==null&&t.nodeType==1&&t.contains(this.find[r].node)&&n.compareDocumentPosition(this.find[r].node)&(o?2:4)&&(this.find[r].pos=this.currentPos)}findInText(t){if(this.find)for(let n=0;n<this.find.length;n++)this.find[n].node==t&&(this.find[n].pos=this.currentPos-(t.nodeValue.length-this.find[n].offset))}matchesContext(t){if(t.indexOf("|")>-1)return t.split(/\s*\|\s*/).some(this.matchesContext,this);let n=t.split("/"),o=this.options.context,r=!this.isOpen&&(!o||o.parent.type==this.nodes[0].type),s=-(o?o.depth+1:0)+(r?0:1),i=(l,a)=>{for(;l>=0;l--){let u=n[l];if(u==""){if(l==n.length-1||l==0)continue;for(;a>=s;a--)if(i(l-1,a))return!0;return!1}else{let c=a>0||a==0&&r?this.nodes[a].type:o&&a>=s?o.node(a-s).type:null;if(!c||c.name!=u&&c.groups.indexOf(u)==-1)return!1;a--}}return!0};return i(n.length-1,this.open)}textblockFromContext(){let t=this.options.context;if(t)for(let n=t.depth;n>=0;n--){let o=t.node(n).contentMatchAt(t.indexAfter(n)).defaultType;if(o&&o.isTextblock&&o.defaultAttrs)return o}for(let n in this.parser.schema.nodes){let o=this.parser.schema.nodes[n];if(o.isTextblock&&o.defaultAttrs)return o}}}function Nve(e){for(let t=e.firstChild,n=null;t;t=t.nextSibling){let o=t.nodeType==1?t.nodeName.toLowerCase():null;o&&kI.hasOwnProperty(o)&&n?(n.appendChild(t),t=n):o=="li"?n=t:o&&(n=null)}}function Pve(e,t){return(e.matches||e.msMatchesSelector||e.webkitMatchesSelector||e.mozMatchesSelector).call(e,t)}function nS(e){let t={};for(let n in e)t[n]=e[n];return t}function oS(e,t){let n=t.schema.nodes;for(let o in n){let r=n[o];if(!r.allowsMarkType(e))continue;let s=[],i=l=>{s.push(l);for(let a=0;a<l.edgeCount;a++){let{type:u,next:c}=l.edge(a);if(u==t||s.indexOf(c)<0&&i(c))return!0}};if(i(r.contentMatch))return!0}}class ta{constructor(t,n){this.nodes=t,this.marks=n}serializeFragment(t,n={},o){o||(o=gy(n).createDocumentFragment());let r=o,s=[];return t.forEach(i=>{if(s.length||i.marks.length){let l=0,a=0;for(;l<s.length&&a<i.marks.length;){let u=i.marks[a];if(!this.marks[u.type.name]){a++;continue}if(!u.eq(s[l][0])||u.type.spec.spanning===!1)break;l++,a++}for(;l<s.length;)r=s.pop()[1];for(;a<i.marks.length;){let u=i.marks[a++],c=this.serializeMark(u,i.isInline,n);c&&(s.push([u,r]),r.appendChild(c.dom),r=c.contentDOM||c.dom)}}r.appendChild(this.serializeNodeInner(i,n))}),o}serializeNodeInner(t,n){let{dom:o,contentDOM:r}=f1(gy(n),this.nodes[t.type.name](t),null,t.attrs);if(r){if(t.isLeaf)throw new RangeError("Content hole not allowed in a leaf node spec");this.serializeFragment(t.content,n,r)}return o}serializeNode(t,n={}){let o=this.serializeNodeInner(t,n);for(let r=t.marks.length-1;r>=0;r--){let s=this.serializeMark(t.marks[r],t.isInline,n);s&&((s.contentDOM||s.dom).appendChild(o),o=s.dom)}return o}serializeMark(t,n,o={}){let r=this.marks[t.type.name];return r&&f1(gy(o),r(t,n),null,t.attrs)}static renderSpec(t,n,o=null,r){return f1(t,n,o,r)}static fromSchema(t){return t.cached.domSerializer||(t.cached.domSerializer=new ta(this.nodesFromSchema(t),this.marksFromSchema(t)))}static nodesFromSchema(t){let n=rS(t.nodes);return n.text||(n.text=o=>o.text),n}static marksFromSchema(t){return rS(t.marks)}}function rS(e){let t={};for(let n in e){let o=e[n].spec.toDOM;o&&(t[n]=o)}return t}function gy(e){return e.document||window.document}const sS=new WeakMap;function Lve(e){let t=sS.get(e);return t===void 0&&sS.set(e,t=Rve(e)),t}function Rve(e){let t=null;function n(o){if(o&&typeof o=="object")if(Array.isArray(o))if(typeof o[0]=="string")t||(t=[]),t.push(o);else for(let r=0;r<o.length;r++)n(o[r]);else for(let r in o)n(o[r])}return n(e),t}function f1(e,t,n,o){if(typeof t=="string")return{dom:e.createTextNode(t)};if(t.nodeType!=null)return{dom:t};if(t.dom&&t.dom.nodeType!=null)return t;let r=t[0],s;if(typeof r!="string")throw new RangeError("Invalid array passed to renderSpec");if(o&&(s=Lve(o))&&s.indexOf(t)>-1)throw new RangeError("Using an array from an attribute object as a DOM spec. This may be an attempted cross site scripting attack.");let i=r.indexOf(" ");i>0&&(n=r.slice(0,i),r=r.slice(i+1));let l,a=n?e.createElementNS(n,r):e.createElement(r),u=t[1],c=1;if(u&&typeof u=="object"&&u.nodeType==null&&!Array.isArray(u)){c=2;for(let d in u)if(u[d]!=null){let f=d.indexOf(" ");f>0?a.setAttributeNS(d.slice(0,f),d.slice(f+1),u[d]):a.setAttribute(d,u[d])}}for(let d=c;d<t.length;d++){let f=t[d];if(f===0){if(d<t.length-1||d>c)throw new RangeError("Content hole must be the only child of its parent node");return{dom:a,contentDOM:a}}else{let{dom:p,contentDOM:h}=f1(e,f,n,o);if(a.appendChild(p),h){if(l)throw new RangeError("Multiple content holes");l=h}}}return{dom:a,contentDOM:l}}const Dve={};function X3(e,t){const n=t||Dve,o=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,r=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return SI(e,o,r)}function SI(e,t,n){if(Fve(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return iS(e.children,t,n)}return Array.isArray(e)?iS(e,t,n):""}function iS(e,t,n){const o=[];let r=-1;for(;++r<e.length;)o[r]=SI(e[r],t,n);return o.join("")}function Fve(e){return!!(e&&typeof e=="object")}const lS=document.createElement("i");function Q3(e){const t="&"+e+";";lS.innerHTML=t;const n=lS.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function Rr(e,t,n,o){const r=e.length;let s=0,i;if(t<0?t=-t>r?0:r+t:t=t>r?r:t,n=n>0?n:0,o.length<1e4)i=Array.from(o),i.unshift(t,n),e.splice(...i);else for(n&&e.splice(t,n);s<o.length;)i=o.slice(s,s+1e4),i.unshift(t,0),e.splice(...i),s+=1e4,t+=1e4}function xr(e,t){return e.length>0?(Rr(e,e.length,0,t),e):t}const aS={}.hasOwnProperty;function $I(e){const t={};let n=-1;for(;++n<e.length;)Vve(t,e[n]);return t}function Vve(e,t){let n;for(n in t){const r=(aS.call(e,n)?e[n]:void 0)||(e[n]={}),s=t[n];let i;if(s)for(i in s){aS.call(r,i)||(r[i]=[]);const l=s[i];Bve(r[i],Array.isArray(l)?l:l?[l]:[])}}}function Bve(e,t){let n=-1;const o=[];for(;++n<t.length;)(t[n].add==="after"?e:o).push(t[n]);Rr(e,0,0,o)}function EI(e,t){const n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCodePoint(n)}function cs(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Eo=na(/[A-Za-z]/),Wo=na(/[\dA-Za-z]/),zve=na(/[#-'*+\--9=?A-Z^-~]/);function qg(e){return e!==null&&(e<32||e===127)}const Rb=na(/\d/),jve=na(/[\dA-Fa-f]/),Hve=na(/[!-/:-@[-`{-~]/);function dt(e){return e!==null&&e<-2}function nn(e){return e!==null&&(e<0||e===32)}function Nt(e){return e===-2||e===-1||e===32}const ev=na(/\p{P}|\p{S}/u),pu=na(/\s/);function na(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Vt(e,t,n,o){const r=o?o-1:Number.POSITIVE_INFINITY;let s=0;return i;function i(a){return Nt(a)?(e.enter(n),l(a)):t(a)}function l(a){return Nt(a)&&s++<r?(e.consume(a),l):(e.exit(n),t(a))}}const Uve={tokenize:Wve};function Wve(e){const t=e.attempt(this.parser.constructs.contentInitial,o,r);let n;return t;function o(l){if(l===null){e.consume(l);return}return e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),Vt(e,t,"linePrefix")}function r(l){return e.enter("paragraph"),s(l)}function s(l){const a=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=a),n=a,i(l)}function i(l){if(l===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(l);return}return dt(l)?(e.consume(l),e.exit("chunkText"),s):(e.consume(l),i)}}const Kve={tokenize:qve},uS={tokenize:Gve};function qve(e){const t=this,n=[];let o=0,r,s,i;return l;function l(_){if(o<n.length){const S=n[o];return t.containerState=S[1],e.attempt(S[0].continuation,a,u)(_)}return u(_)}function a(_){if(o++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,r&&w();const S=t.events.length;let x=S,E;for(;x--;)if(t.events[x][0]==="exit"&&t.events[x][1].type==="chunkFlow"){E=t.events[x][1].end;break}v(o);let T=S;for(;T<t.events.length;)t.events[T][1].end=Object.assign({},E),T++;return Rr(t.events,x+1,0,t.events.slice(S)),t.events.length=T,u(_)}return l(_)}function u(_){if(o===n.length){if(!r)return f(_);if(r.currentConstruct&&r.currentConstruct.concrete)return h(_);t.interrupt=!!(r.currentConstruct&&!r._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(uS,c,d)(_)}function c(_){return r&&w(),v(o),f(_)}function d(_){return t.parser.lazy[t.now().line]=o!==n.length,i=t.now().offset,h(_)}function f(_){return t.containerState={},e.attempt(uS,p,h)(_)}function p(_){return o++,n.push([t.currentConstruct,t.containerState]),f(_)}function h(_){if(_===null){r&&w(),v(0),e.consume(_);return}return r=r||t.parser.flow(t.now()),e.enter("chunkFlow",{contentType:"flow",previous:s,_tokenizer:r}),m(_)}function m(_){if(_===null){y(e.exit("chunkFlow"),!0),v(0),e.consume(_);return}return dt(_)?(e.consume(_),y(e.exit("chunkFlow")),o=0,t.interrupt=void 0,l):(e.consume(_),m)}function y(_,S){const x=t.sliceStream(_);if(S&&x.push(null),_.previous=s,s&&(s.next=_),s=_,r.defineSkip(_.start),r.write(x),t.parser.lazy[_.start.line]){let E=r.events.length;for(;E--;)if(r.events[E][1].start.offset<i&&(!r.events[E][1].end||r.events[E][1].end.offset>i))return;const T=t.events.length;let O=T,P,N;for(;O--;)if(t.events[O][0]==="exit"&&t.events[O][1].type==="chunkFlow"){if(P){N=t.events[O][1].end;break}P=!0}for(v(o),E=T;E<t.events.length;)t.events[E][1].end=Object.assign({},N),E++;Rr(t.events,O+1,0,t.events.slice(T)),t.events.length=E}}function v(_){let S=n.length;for(;S-- >_;){const x=n[S];t.containerState=x[1],x[0].exit.call(t,e)}n.length=_}function w(){r.write([null]),s=void 0,r=void 0,t.containerState._closeFlow=void 0}}function Gve(e,t,n){return Vt(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Gg(e){if(e===null||nn(e)||pu(e))return 1;if(ev(e))return 2}function tv(e,t,n){const o=[];let r=-1;for(;++r<e.length;){const s=e[r].resolveAll;s&&!o.includes(s)&&(t=s(t,n),o.push(s))}return t}const Db={name:"attention",tokenize:Zve,resolveAll:Yve};function Yve(e,t){let n=-1,o,r,s,i,l,a,u,c;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(o=n;o--;)if(e[o][0]==="exit"&&e[o][1].type==="attentionSequence"&&e[o][1]._open&&t.sliceSerialize(e[o][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[o][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[o][1].end.offset-e[o][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;a=e[o][1].end.offset-e[o][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const d=Object.assign({},e[o][1].end),f=Object.assign({},e[n][1].start);cS(d,-a),cS(f,a),i={type:a>1?"strongSequence":"emphasisSequence",start:d,end:Object.assign({},e[o][1].end)},l={type:a>1?"strongSequence":"emphasisSequence",start:Object.assign({},e[n][1].start),end:f},s={type:a>1?"strongText":"emphasisText",start:Object.assign({},e[o][1].end),end:Object.assign({},e[n][1].start)},r={type:a>1?"strong":"emphasis",start:Object.assign({},i.start),end:Object.assign({},l.end)},e[o][1].end=Object.assign({},i.start),e[n][1].start=Object.assign({},l.end),u=[],e[o][1].end.offset-e[o][1].start.offset&&(u=xr(u,[["enter",e[o][1],t],["exit",e[o][1],t]])),u=xr(u,[["enter",r,t],["enter",i,t],["exit",i,t],["enter",s,t]]),u=xr(u,tv(t.parser.constructs.insideSpan.null,e.slice(o+1,n),t)),u=xr(u,[["exit",s,t],["enter",l,t],["exit",l,t],["exit",r,t]]),e[n][1].end.offset-e[n][1].start.offset?(c=2,u=xr(u,[["enter",e[n][1],t],["exit",e[n][1],t]])):c=0,Rr(e,o-1,n-o+3,u),n=o+u.length-c-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function Zve(e,t){const n=this.parser.constructs.attentionMarkers.null,o=this.previous,r=Gg(o);let s;return i;function i(a){return s=a,e.enter("attentionSequence"),l(a)}function l(a){if(a===s)return e.consume(a),l;const u=e.exit("attentionSequence"),c=Gg(a),d=!c||c===2&&r||n.includes(a),f=!r||r===2&&c||n.includes(o);return u._open=!!(s===42?d:d&&(r||!f)),u._close=!!(s===42?f:f&&(c||!d)),t(a)}}function cS(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const Jve={name:"autolink",tokenize:Xve};function Xve(e,t,n){let o=0;return r;function r(p){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),s}function s(p){return Eo(p)?(e.consume(p),i):p===64?n(p):u(p)}function i(p){return p===43||p===45||p===46||Wo(p)?(o=1,l(p)):u(p)}function l(p){return p===58?(e.consume(p),o=0,a):(p===43||p===45||p===46||Wo(p))&&o++<32?(e.consume(p),l):(o=0,u(p))}function a(p){return p===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.exit("autolink"),t):p===null||p===32||p===60||qg(p)?n(p):(e.consume(p),a)}function u(p){return p===64?(e.consume(p),c):zve(p)?(e.consume(p),u):n(p)}function c(p){return Wo(p)?d(p):n(p)}function d(p){return p===46?(e.consume(p),o=0,c):p===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.exit("autolink"),t):f(p)}function f(p){if((p===45||Wo(p))&&o++<63){const h=p===45?f:d;return e.consume(p),h}return n(p)}}const $h={tokenize:Qve,partial:!0};function Qve(e,t,n){return o;function o(s){return Nt(s)?Vt(e,r,"linePrefix")(s):r(s)}function r(s){return s===null||dt(s)?t(s):n(s)}}const xI={name:"blockQuote",tokenize:eye,continuation:{tokenize:tye},exit:nye};function eye(e,t,n){const o=this;return r;function r(i){if(i===62){const l=o.containerState;return l.open||(e.enter("blockQuote",{_container:!0}),l.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(i),e.exit("blockQuoteMarker"),s}return n(i)}function s(i){return Nt(i)?(e.enter("blockQuotePrefixWhitespace"),e.consume(i),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(i))}}function tye(e,t,n){const o=this;return r;function r(i){return Nt(i)?Vt(e,s,"linePrefix",o.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(i):s(i)}function s(i){return e.attempt(xI,t,n)(i)}}function nye(e){e.exit("blockQuote")}const MI={name:"characterEscape",tokenize:oye};function oye(e,t,n){return o;function o(s){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(s),e.exit("escapeMarker"),r}function r(s){return Hve(s)?(e.enter("characterEscapeValue"),e.consume(s),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(s)}}const TI={name:"characterReference",tokenize:rye};function rye(e,t,n){const o=this;let r=0,s,i;return l;function l(d){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),a}function a(d){return d===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(d),e.exit("characterReferenceMarkerNumeric"),u):(e.enter("characterReferenceValue"),s=31,i=Wo,c(d))}function u(d){return d===88||d===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(d),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),s=6,i=jve,c):(e.enter("characterReferenceValue"),s=7,i=Rb,c(d))}function c(d){if(d===59&&r){const f=e.exit("characterReferenceValue");return i===Wo&&!Q3(o.sliceSerialize(f))?n(d):(e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return i(d)&&r++<s?(e.consume(d),c):n(d)}}const dS={tokenize:iye,partial:!0},fS={name:"codeFenced",tokenize:sye,concrete:!0};function sye(e,t,n){const o=this,r={tokenize:x,partial:!0};let s=0,i=0,l;return a;function a(E){return u(E)}function u(E){const T=o.events[o.events.length-1];return s=T&&T[1].type==="linePrefix"?T[2].sliceSerialize(T[1],!0).length:0,l=E,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),c(E)}function c(E){return E===l?(i++,e.consume(E),c):i<3?n(E):(e.exit("codeFencedFenceSequence"),Nt(E)?Vt(e,d,"whitespace")(E):d(E))}function d(E){return E===null||dt(E)?(e.exit("codeFencedFence"),o.interrupt?t(E):e.check(dS,m,S)(E)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),f(E))}function f(E){return E===null||dt(E)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),d(E)):Nt(E)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Vt(e,p,"whitespace")(E)):E===96&&E===l?n(E):(e.consume(E),f)}function p(E){return E===null||dt(E)?d(E):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),h(E))}function h(E){return E===null||dt(E)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),d(E)):E===96&&E===l?n(E):(e.consume(E),h)}function m(E){return e.attempt(r,S,y)(E)}function y(E){return e.enter("lineEnding"),e.consume(E),e.exit("lineEnding"),v}function v(E){return s>0&&Nt(E)?Vt(e,w,"linePrefix",s+1)(E):w(E)}function w(E){return E===null||dt(E)?e.check(dS,m,S)(E):(e.enter("codeFlowValue"),_(E))}function _(E){return E===null||dt(E)?(e.exit("codeFlowValue"),w(E)):(e.consume(E),_)}function S(E){return e.exit("codeFenced"),t(E)}function x(E,T,O){let P=0;return N;function N(U){return E.enter("lineEnding"),E.consume(U),E.exit("lineEnding"),F}function F(U){return E.enter("codeFencedFence"),Nt(U)?Vt(E,B,"linePrefix",o.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(U):B(U)}function B(U){return U===l?(E.enter("codeFencedFenceSequence"),Y(U)):O(U)}function Y(U){return U===l?(P++,E.consume(U),Y):P>=i?(E.exit("codeFencedFenceSequence"),Nt(U)?Vt(E,Z,"whitespace")(U):Z(U)):O(U)}function Z(U){return U===null||dt(U)?(E.exit("codeFencedFence"),T(U)):O(U)}}}function iye(e,t,n){const o=this;return r;function r(i){return i===null?n(i):(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),s)}function s(i){return o.parser.lazy[o.now().line]?n(i):t(i)}}const vy={name:"codeIndented",tokenize:aye},lye={tokenize:uye,partial:!0};function aye(e,t,n){const o=this;return r;function r(u){return e.enter("codeIndented"),Vt(e,s,"linePrefix",4+1)(u)}function s(u){const c=o.events[o.events.length-1];return c&&c[1].type==="linePrefix"&&c[2].sliceSerialize(c[1],!0).length>=4?i(u):n(u)}function i(u){return u===null?a(u):dt(u)?e.attempt(lye,i,a)(u):(e.enter("codeFlowValue"),l(u))}function l(u){return u===null||dt(u)?(e.exit("codeFlowValue"),i(u)):(e.consume(u),l)}function a(u){return e.exit("codeIndented"),t(u)}}function uye(e,t,n){const o=this;return r;function r(i){return o.parser.lazy[o.now().line]?n(i):dt(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),r):Vt(e,s,"linePrefix",4+1)(i)}function s(i){const l=o.events[o.events.length-1];return l&&l[1].type==="linePrefix"&&l[2].sliceSerialize(l[1],!0).length>=4?t(i):dt(i)?r(i):n(i)}}const cye={name:"codeText",tokenize:pye,resolve:dye,previous:fye};function dye(e){let t=e.length-4,n=3,o,r;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(o=n;++o<t;)if(e[o][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(o=n-1,t++;++o<=t;)r===void 0?o!==t&&e[o][1].type!=="lineEnding"&&(r=o):(o===t||e[o][1].type==="lineEnding")&&(e[r][1].type="codeTextData",o!==r+2&&(e[r][1].end=e[o-1][1].end,e.splice(r+2,o-r-2),t-=o-r-2,o=r+2),r=void 0);return e}function fye(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function pye(e,t,n){let o=0,r,s;return i;function i(d){return e.enter("codeText"),e.enter("codeTextSequence"),l(d)}function l(d){return d===96?(e.consume(d),o++,l):(e.exit("codeTextSequence"),a(d))}function a(d){return d===null?n(d):d===32?(e.enter("space"),e.consume(d),e.exit("space"),a):d===96?(s=e.enter("codeTextSequence"),r=0,c(d)):dt(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),a):(e.enter("codeTextData"),u(d))}function u(d){return d===null||d===32||d===96||dt(d)?(e.exit("codeTextData"),a(d)):(e.consume(d),u)}function c(d){return d===96?(e.consume(d),r++,c):r===o?(e.exit("codeTextSequence"),e.exit("codeText"),t(d)):(s.type="codeTextData",u(d))}}class hye{constructor(t){this.left=t?[...t]:[],this.right=[]}get(t){if(t<0||t>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return t<this.left.length?this.left[t]:this.right[this.right.length-t+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(t,n){const o=n??Number.POSITIVE_INFINITY;return o<this.left.length?this.left.slice(t,o):t>this.left.length?this.right.slice(this.right.length-o+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-o+this.left.length).reverse())}splice(t,n,o){const r=n||0;this.setCursor(Math.trunc(t));const s=this.right.splice(this.right.length-r,Number.POSITIVE_INFINITY);return o&&qd(this.left,o),s.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),qd(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),qd(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t<this.left.length){const n=this.left.splice(t,Number.POSITIVE_INFINITY);qd(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);qd(this.left,n.reverse())}}}function qd(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function OI(e){const t={};let n=-1,o,r,s,i,l,a,u;const c=new hye(e);for(;++n<c.length;){for(;n in t;)n=t[n];if(o=c.get(n),n&&o[1].type==="chunkFlow"&&c.get(n-1)[1].type==="listItemPrefix"&&(a=o[1]._tokenizer.events,s=0,s<a.length&&a[s][1].type==="lineEndingBlank"&&(s+=2),s<a.length&&a[s][1].type==="content"))for(;++s<a.length&&a[s][1].type!=="content";)a[s][1].type==="chunkText"&&(a[s][1]._isInFirstContentOfListItem=!0,s++);if(o[0]==="enter")o[1].contentType&&(Object.assign(t,mye(c,n)),n=t[n],u=!0);else if(o[1]._container){for(s=n,r=void 0;s--&&(i=c.get(s),i[1].type==="lineEnding"||i[1].type==="lineEndingBlank");)i[0]==="enter"&&(r&&(c.get(r)[1].type="lineEndingBlank"),i[1].type="lineEnding",r=s);r&&(o[1].end=Object.assign({},c.get(r)[1].start),l=c.slice(r,n),l.unshift(o),c.splice(r,n-r+1,l))}}return Rr(e,0,Number.POSITIVE_INFINITY,c.slice(0)),!u}function mye(e,t){const n=e.get(t)[1],o=e.get(t)[2];let r=t-1;const s=[],i=n._tokenizer||o.parser[n.contentType](n.start),l=i.events,a=[],u={};let c,d,f=-1,p=n,h=0,m=0;const y=[m];for(;p;){for(;e.get(++r)[1]!==p;);s.push(r),p._tokenizer||(c=o.sliceStream(p),p.next||c.push(null),d&&i.defineSkip(p.start),p._isInFirstContentOfListItem&&(i._gfmTasklistFirstContentOfListItem=!0),i.write(c),p._isInFirstContentOfListItem&&(i._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++f<l.length;)l[f][0]==="exit"&&l[f-1][0]==="enter"&&l[f][1].type===l[f-1][1].type&&l[f][1].start.line!==l[f][1].end.line&&(m=f+1,y.push(m),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(i.events=[],p?(p._tokenizer=void 0,p.previous=void 0):y.pop(),f=y.length;f--;){const v=l.slice(y[f],y[f+1]),w=s.pop();a.push([w,w+v.length-1]),e.splice(w,2,v)}for(a.reverse(),f=-1;++f<a.length;)u[h+a[f][0]]=h+a[f][1],h+=a[f][1]-a[f][0]-1;return u}const gye={tokenize:_ye,resolve:yye},vye={tokenize:bye,partial:!0};function yye(e){return OI(e),e}function _ye(e,t){let n;return o;function o(l){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),r(l)}function r(l){return l===null?s(l):dt(l)?e.check(vye,i,s)(l):(e.consume(l),r)}function s(l){return e.exit("chunkContent"),e.exit("content"),t(l)}function i(l){return e.consume(l),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,r}}function bye(e,t,n){const o=this;return r;function r(i){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),Vt(e,s,"linePrefix")}function s(i){if(i===null||dt(i))return n(i);const l=o.events[o.events.length-1];return!o.parser.constructs.disable.null.includes("codeIndented")&&l&&l[1].type==="linePrefix"&&l[2].sliceSerialize(l[1],!0).length>=4?t(i):e.interrupt(o.parser.constructs.flow,n,t)(i)}}function II(e,t,n,o,r,s,i,l,a){const u=a||Number.POSITIVE_INFINITY;let c=0;return d;function d(v){return v===60?(e.enter(o),e.enter(r),e.enter(s),e.consume(v),e.exit(s),f):v===null||v===32||v===41||qg(v)?n(v):(e.enter(o),e.enter(i),e.enter(l),e.enter("chunkString",{contentType:"string"}),m(v))}function f(v){return v===62?(e.enter(s),e.consume(v),e.exit(s),e.exit(r),e.exit(o),t):(e.enter(l),e.enter("chunkString",{contentType:"string"}),p(v))}function p(v){return v===62?(e.exit("chunkString"),e.exit(l),f(v)):v===null||v===60||dt(v)?n(v):(e.consume(v),v===92?h:p)}function h(v){return v===60||v===62||v===92?(e.consume(v),p):p(v)}function m(v){return!c&&(v===null||v===41||nn(v))?(e.exit("chunkString"),e.exit(l),e.exit(i),e.exit(o),t(v)):c<u&&v===40?(e.consume(v),c++,m):v===41?(e.consume(v),c--,m):v===null||v===32||v===40||qg(v)?n(v):(e.consume(v),v===92?y:m)}function y(v){return v===40||v===41||v===92?(e.consume(v),m):m(v)}}function AI(e,t,n,o,r,s){const i=this;let l=0,a;return u;function u(p){return e.enter(o),e.enter(r),e.consume(p),e.exit(r),e.enter(s),c}function c(p){return l>999||p===null||p===91||p===93&&!a||p===94&&!l&&"_hiddenFootnoteSupport"in i.parser.constructs?n(p):p===93?(e.exit(s),e.enter(r),e.consume(p),e.exit(r),e.exit(o),t):dt(p)?(e.enter("lineEnding"),e.consume(p),e.exit("lineEnding"),c):(e.enter("chunkString",{contentType:"string"}),d(p))}function d(p){return p===null||p===91||p===93||dt(p)||l++>999?(e.exit("chunkString"),c(p)):(e.consume(p),a||(a=!Nt(p)),p===92?f:d)}function f(p){return p===91||p===92||p===93?(e.consume(p),l++,d):d(p)}}function NI(e,t,n,o,r,s){let i;return l;function l(f){return f===34||f===39||f===40?(e.enter(o),e.enter(r),e.consume(f),e.exit(r),i=f===40?41:f,a):n(f)}function a(f){return f===i?(e.enter(r),e.consume(f),e.exit(r),e.exit(o),t):(e.enter(s),u(f))}function u(f){return f===i?(e.exit(s),a(i)):f===null?n(f):dt(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),Vt(e,u,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),c(f))}function c(f){return f===i||f===null||dt(f)?(e.exit("chunkString"),u(f)):(e.consume(f),f===92?d:c)}function d(f){return f===i||f===92?(e.consume(f),c):c(f)}}function Qf(e,t){let n;return o;function o(r){return dt(r)?(e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),n=!0,o):Nt(r)?Vt(e,o,n?"linePrefix":"lineSuffix")(r):t(r)}}const wye={name:"definition",tokenize:kye},Cye={tokenize:Sye,partial:!0};function kye(e,t,n){const o=this;let r;return s;function s(p){return e.enter("definition"),i(p)}function i(p){return AI.call(o,e,l,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(p)}function l(p){return r=cs(o.sliceSerialize(o.events[o.events.length-1][1]).slice(1,-1)),p===58?(e.enter("definitionMarker"),e.consume(p),e.exit("definitionMarker"),a):n(p)}function a(p){return nn(p)?Qf(e,u)(p):u(p)}function u(p){return II(e,c,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(p)}function c(p){return e.attempt(Cye,d,d)(p)}function d(p){return Nt(p)?Vt(e,f,"whitespace")(p):f(p)}function f(p){return p===null||dt(p)?(e.exit("definition"),o.parser.defined.push(r),t(p)):n(p)}}function Sye(e,t,n){return o;function o(l){return nn(l)?Qf(e,r)(l):n(l)}function r(l){return NI(e,s,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(l)}function s(l){return Nt(l)?Vt(e,i,"whitespace")(l):i(l)}function i(l){return l===null||dt(l)?t(l):n(l)}}const $ye={name:"hardBreakEscape",tokenize:Eye};function Eye(e,t,n){return o;function o(s){return e.enter("hardBreakEscape"),e.consume(s),r}function r(s){return dt(s)?(e.exit("hardBreakEscape"),t(s)):n(s)}}const xye={name:"headingAtx",tokenize:Tye,resolve:Mye};function Mye(e,t){let n=e.length-2,o=3,r,s;return e[o][1].type==="whitespace"&&(o+=2),n-2>o&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(o===n-1||n-4>o&&e[n-2][1].type==="whitespace")&&(n-=o+1===n?2:4),n>o&&(r={type:"atxHeadingText",start:e[o][1].start,end:e[n][1].end},s={type:"chunkText",start:e[o][1].start,end:e[n][1].end,contentType:"text"},Rr(e,o,n-o+1,[["enter",r,t],["enter",s,t],["exit",s,t],["exit",r,t]])),e}function Tye(e,t,n){let o=0;return r;function r(c){return e.enter("atxHeading"),s(c)}function s(c){return e.enter("atxHeadingSequence"),i(c)}function i(c){return c===35&&o++<6?(e.consume(c),i):c===null||nn(c)?(e.exit("atxHeadingSequence"),l(c)):n(c)}function l(c){return c===35?(e.enter("atxHeadingSequence"),a(c)):c===null||dt(c)?(e.exit("atxHeading"),t(c)):Nt(c)?Vt(e,l,"whitespace")(c):(e.enter("atxHeadingText"),u(c))}function a(c){return c===35?(e.consume(c),a):(e.exit("atxHeadingSequence"),l(c))}function u(c){return c===null||c===35||nn(c)?(e.exit("atxHeadingText"),l(c)):(e.consume(c),u)}}const Oye=["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"],pS=["pre","script","style","textarea"],Iye={name:"htmlFlow",tokenize:Lye,resolveTo:Pye,concrete:!0},Aye={tokenize:Dye,partial:!0},Nye={tokenize:Rye,partial:!0};function Pye(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function Lye(e,t,n){const o=this;let r,s,i,l,a;return u;function u(z){return c(z)}function c(z){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(z),d}function d(z){return z===33?(e.consume(z),f):z===47?(e.consume(z),s=!0,m):z===63?(e.consume(z),r=3,o.interrupt?t:I):Eo(z)?(e.consume(z),i=String.fromCharCode(z),y):n(z)}function f(z){return z===45?(e.consume(z),r=2,p):z===91?(e.consume(z),r=5,l=0,h):Eo(z)?(e.consume(z),r=4,o.interrupt?t:I):n(z)}function p(z){return z===45?(e.consume(z),o.interrupt?t:I):n(z)}function h(z){const ge="CDATA[";return z===ge.charCodeAt(l++)?(e.consume(z),l===ge.length?o.interrupt?t:B:h):n(z)}function m(z){return Eo(z)?(e.consume(z),i=String.fromCharCode(z),y):n(z)}function y(z){if(z===null||z===47||z===62||nn(z)){const ge=z===47,Oe=i.toLowerCase();return!ge&&!s&&pS.includes(Oe)?(r=1,o.interrupt?t(z):B(z)):Oye.includes(i.toLowerCase())?(r=6,ge?(e.consume(z),v):o.interrupt?t(z):B(z)):(r=7,o.interrupt&&!o.parser.lazy[o.now().line]?n(z):s?w(z):_(z))}return z===45||Wo(z)?(e.consume(z),i+=String.fromCharCode(z),y):n(z)}function v(z){return z===62?(e.consume(z),o.interrupt?t:B):n(z)}function w(z){return Nt(z)?(e.consume(z),w):N(z)}function _(z){return z===47?(e.consume(z),N):z===58||z===95||Eo(z)?(e.consume(z),S):Nt(z)?(e.consume(z),_):N(z)}function S(z){return z===45||z===46||z===58||z===95||Wo(z)?(e.consume(z),S):x(z)}function x(z){return z===61?(e.consume(z),E):Nt(z)?(e.consume(z),x):_(z)}function E(z){return z===null||z===60||z===61||z===62||z===96?n(z):z===34||z===39?(e.consume(z),a=z,T):Nt(z)?(e.consume(z),E):O(z)}function T(z){return z===a?(e.consume(z),a=null,P):z===null||dt(z)?n(z):(e.consume(z),T)}function O(z){return z===null||z===34||z===39||z===47||z===60||z===61||z===62||z===96||nn(z)?x(z):(e.consume(z),O)}function P(z){return z===47||z===62||Nt(z)?_(z):n(z)}function N(z){return z===62?(e.consume(z),F):n(z)}function F(z){return z===null||dt(z)?B(z):Nt(z)?(e.consume(z),F):n(z)}function B(z){return z===45&&r===2?(e.consume(z),j):z===60&&r===1?(e.consume(z),V):z===62&&r===4?(e.consume(z),X):z===63&&r===3?(e.consume(z),I):z===93&&r===5?(e.consume(z),L):dt(z)&&(r===6||r===7)?(e.exit("htmlFlowData"),e.check(Aye,oe,Y)(z)):z===null||dt(z)?(e.exit("htmlFlowData"),Y(z)):(e.consume(z),B)}function Y(z){return e.check(Nye,Z,oe)(z)}function Z(z){return e.enter("lineEnding"),e.consume(z),e.exit("lineEnding"),U}function U(z){return z===null||dt(z)?Y(z):(e.enter("htmlFlowData"),B(z))}function j(z){return z===45?(e.consume(z),I):B(z)}function V(z){return z===47?(e.consume(z),i="",H):B(z)}function H(z){if(z===62){const ge=i.toLowerCase();return pS.includes(ge)?(e.consume(z),X):B(z)}return Eo(z)&&i.length<8?(e.consume(z),i+=String.fromCharCode(z),H):B(z)}function L(z){return z===93?(e.consume(z),I):B(z)}function I(z){return z===62?(e.consume(z),X):z===45&&r===2?(e.consume(z),I):B(z)}function X(z){return z===null||dt(z)?(e.exit("htmlFlowData"),oe(z)):(e.consume(z),X)}function oe(z){return e.exit("htmlFlow"),t(z)}}function Rye(e,t,n){const o=this;return r;function r(i){return dt(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),s):n(i)}function s(i){return o.parser.lazy[o.now().line]?n(i):t(i)}}function Dye(e,t,n){return o;function o(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),e.attempt($h,t,n)}}const Fye={name:"htmlText",tokenize:Vye};function Vye(e,t,n){const o=this;let r,s,i;return l;function l(I){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(I),a}function a(I){return I===33?(e.consume(I),u):I===47?(e.consume(I),x):I===63?(e.consume(I),_):Eo(I)?(e.consume(I),O):n(I)}function u(I){return I===45?(e.consume(I),c):I===91?(e.consume(I),s=0,h):Eo(I)?(e.consume(I),w):n(I)}function c(I){return I===45?(e.consume(I),p):n(I)}function d(I){return I===null?n(I):I===45?(e.consume(I),f):dt(I)?(i=d,V(I)):(e.consume(I),d)}function f(I){return I===45?(e.consume(I),p):d(I)}function p(I){return I===62?j(I):I===45?f(I):d(I)}function h(I){const X="CDATA[";return I===X.charCodeAt(s++)?(e.consume(I),s===X.length?m:h):n(I)}function m(I){return I===null?n(I):I===93?(e.consume(I),y):dt(I)?(i=m,V(I)):(e.consume(I),m)}function y(I){return I===93?(e.consume(I),v):m(I)}function v(I){return I===62?j(I):I===93?(e.consume(I),v):m(I)}function w(I){return I===null||I===62?j(I):dt(I)?(i=w,V(I)):(e.consume(I),w)}function _(I){return I===null?n(I):I===63?(e.consume(I),S):dt(I)?(i=_,V(I)):(e.consume(I),_)}function S(I){return I===62?j(I):_(I)}function x(I){return Eo(I)?(e.consume(I),E):n(I)}function E(I){return I===45||Wo(I)?(e.consume(I),E):T(I)}function T(I){return dt(I)?(i=T,V(I)):Nt(I)?(e.consume(I),T):j(I)}function O(I){return I===45||Wo(I)?(e.consume(I),O):I===47||I===62||nn(I)?P(I):n(I)}function P(I){return I===47?(e.consume(I),j):I===58||I===95||Eo(I)?(e.consume(I),N):dt(I)?(i=P,V(I)):Nt(I)?(e.consume(I),P):j(I)}function N(I){return I===45||I===46||I===58||I===95||Wo(I)?(e.consume(I),N):F(I)}function F(I){return I===61?(e.consume(I),B):dt(I)?(i=F,V(I)):Nt(I)?(e.consume(I),F):P(I)}function B(I){return I===null||I===60||I===61||I===62||I===96?n(I):I===34||I===39?(e.consume(I),r=I,Y):dt(I)?(i=B,V(I)):Nt(I)?(e.consume(I),B):(e.consume(I),Z)}function Y(I){return I===r?(e.consume(I),r=void 0,U):I===null?n(I):dt(I)?(i=Y,V(I)):(e.consume(I),Y)}function Z(I){return I===null||I===34||I===39||I===60||I===61||I===96?n(I):I===47||I===62||nn(I)?P(I):(e.consume(I),Z)}function U(I){return I===47||I===62||nn(I)?P(I):n(I)}function j(I){return I===62?(e.consume(I),e.exit("htmlTextData"),e.exit("htmlText"),t):n(I)}function V(I){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(I),e.exit("lineEnding"),H}function H(I){return Nt(I)?Vt(e,L,"linePrefix",o.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(I):L(I)}function L(I){return e.enter("htmlTextData"),i(I)}}const eC={name:"labelEnd",tokenize:Wye,resolveTo:Uye,resolveAll:Hye},Bye={tokenize:Kye},zye={tokenize:qye},jye={tokenize:Gye};function Hye(e){let t=-1;for(;++t<e.length;){const n=e[t][1];(n.type==="labelImage"||n.type==="labelLink"||n.type==="labelEnd")&&(e.splice(t+1,n.type==="labelImage"?4:2),n.type="data",t++)}return e}function Uye(e,t){let n=e.length,o=0,r,s,i,l;for(;n--;)if(r=e[n][1],s){if(r.type==="link"||r.type==="labelLink"&&r._inactive)break;e[n][0]==="enter"&&r.type==="labelLink"&&(r._inactive=!0)}else if(i){if(e[n][0]==="enter"&&(r.type==="labelImage"||r.type==="labelLink")&&!r._balanced&&(s=n,r.type!=="labelLink")){o=2;break}}else r.type==="labelEnd"&&(i=n);const a={type:e[s][1].type==="labelLink"?"link":"image",start:Object.assign({},e[s][1].start),end:Object.assign({},e[e.length-1][1].end)},u={type:"label",start:Object.assign({},e[s][1].start),end:Object.assign({},e[i][1].end)},c={type:"labelText",start:Object.assign({},e[s+o+2][1].end),end:Object.assign({},e[i-2][1].start)};return l=[["enter",a,t],["enter",u,t]],l=xr(l,e.slice(s+1,s+o+3)),l=xr(l,[["enter",c,t]]),l=xr(l,tv(t.parser.constructs.insideSpan.null,e.slice(s+o+4,i-3),t)),l=xr(l,[["exit",c,t],e[i-2],e[i-1],["exit",u,t]]),l=xr(l,e.slice(i+1)),l=xr(l,[["exit",a,t]]),Rr(e,s,e.length,l),e}function Wye(e,t,n){const o=this;let r=o.events.length,s,i;for(;r--;)if((o.events[r][1].type==="labelImage"||o.events[r][1].type==="labelLink")&&!o.events[r][1]._balanced){s=o.events[r][1];break}return l;function l(f){return s?s._inactive?d(f):(i=o.parser.defined.includes(cs(o.sliceSerialize({start:s.end,end:o.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(f),e.exit("labelMarker"),e.exit("labelEnd"),a):n(f)}function a(f){return f===40?e.attempt(Bye,c,i?c:d)(f):f===91?e.attempt(zye,c,i?u:d)(f):i?c(f):d(f)}function u(f){return e.attempt(jye,c,d)(f)}function c(f){return t(f)}function d(f){return s._balanced=!0,n(f)}}function Kye(e,t,n){return o;function o(d){return e.enter("resource"),e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),r}function r(d){return nn(d)?Qf(e,s)(d):s(d)}function s(d){return d===41?c(d):II(e,i,l,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(d)}function i(d){return nn(d)?Qf(e,a)(d):c(d)}function l(d){return n(d)}function a(d){return d===34||d===39||d===40?NI(e,u,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(d):c(d)}function u(d){return nn(d)?Qf(e,c)(d):c(d)}function c(d){return d===41?(e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),e.exit("resource"),t):n(d)}}function qye(e,t,n){const o=this;return r;function r(l){return AI.call(o,e,s,i,"reference","referenceMarker","referenceString")(l)}function s(l){return o.parser.defined.includes(cs(o.sliceSerialize(o.events[o.events.length-1][1]).slice(1,-1)))?t(l):n(l)}function i(l){return n(l)}}function Gye(e,t,n){return o;function o(s){return e.enter("reference"),e.enter("referenceMarker"),e.consume(s),e.exit("referenceMarker"),r}function r(s){return s===93?(e.enter("referenceMarker"),e.consume(s),e.exit("referenceMarker"),e.exit("reference"),t):n(s)}}const Yye={name:"labelStartImage",tokenize:Zye,resolveAll:eC.resolveAll};function Zye(e,t,n){const o=this;return r;function r(l){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(l),e.exit("labelImageMarker"),s}function s(l){return l===91?(e.enter("labelMarker"),e.consume(l),e.exit("labelMarker"),e.exit("labelImage"),i):n(l)}function i(l){return l===94&&"_hiddenFootnoteSupport"in o.parser.constructs?n(l):t(l)}}const Jye={name:"labelStartLink",tokenize:Xye,resolveAll:eC.resolveAll};function Xye(e,t,n){const o=this;return r;function r(i){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(i),e.exit("labelMarker"),e.exit("labelLink"),s}function s(i){return i===94&&"_hiddenFootnoteSupport"in o.parser.constructs?n(i):t(i)}}const yy={name:"lineEnding",tokenize:Qye};function Qye(e,t){return n;function n(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),Vt(e,t,"linePrefix")}}const p1={name:"thematicBreak",tokenize:e_e};function e_e(e,t,n){let o=0,r;return s;function s(u){return e.enter("thematicBreak"),i(u)}function i(u){return r=u,l(u)}function l(u){return u===r?(e.enter("thematicBreakSequence"),a(u)):o>=3&&(u===null||dt(u))?(e.exit("thematicBreak"),t(u)):n(u)}function a(u){return u===r?(e.consume(u),o++,a):(e.exit("thematicBreakSequence"),Nt(u)?Vt(e,l,"whitespace")(u):l(u))}}const Fo={name:"list",tokenize:o_e,continuation:{tokenize:r_e},exit:i_e},t_e={tokenize:l_e,partial:!0},n_e={tokenize:s_e,partial:!0};function o_e(e,t,n){const o=this,r=o.events[o.events.length-1];let s=r&&r[1].type==="linePrefix"?r[2].sliceSerialize(r[1],!0).length:0,i=0;return l;function l(p){const h=o.containerState.type||(p===42||p===43||p===45?"listUnordered":"listOrdered");if(h==="listUnordered"?!o.containerState.marker||p===o.containerState.marker:Rb(p)){if(o.containerState.type||(o.containerState.type=h,e.enter(h,{_container:!0})),h==="listUnordered")return e.enter("listItemPrefix"),p===42||p===45?e.check(p1,n,u)(p):u(p);if(!o.interrupt||p===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),a(p)}return n(p)}function a(p){return Rb(p)&&++i<10?(e.consume(p),a):(!o.interrupt||i<2)&&(o.containerState.marker?p===o.containerState.marker:p===41||p===46)?(e.exit("listItemValue"),u(p)):n(p)}function u(p){return e.enter("listItemMarker"),e.consume(p),e.exit("listItemMarker"),o.containerState.marker=o.containerState.marker||p,e.check($h,o.interrupt?n:c,e.attempt(t_e,f,d))}function c(p){return o.containerState.initialBlankLine=!0,s++,f(p)}function d(p){return Nt(p)?(e.enter("listItemPrefixWhitespace"),e.consume(p),e.exit("listItemPrefixWhitespace"),f):n(p)}function f(p){return o.containerState.size=s+o.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(p)}}function r_e(e,t,n){const o=this;return o.containerState._closeFlow=void 0,e.check($h,r,s);function r(l){return o.containerState.furtherBlankLines=o.containerState.furtherBlankLines||o.containerState.initialBlankLine,Vt(e,t,"listItemIndent",o.containerState.size+1)(l)}function s(l){return o.containerState.furtherBlankLines||!Nt(l)?(o.containerState.furtherBlankLines=void 0,o.containerState.initialBlankLine=void 0,i(l)):(o.containerState.furtherBlankLines=void 0,o.containerState.initialBlankLine=void 0,e.attempt(n_e,t,i)(l))}function i(l){return o.containerState._closeFlow=!0,o.interrupt=void 0,Vt(e,e.attempt(Fo,t,n),"linePrefix",o.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(l)}}function s_e(e,t,n){const o=this;return Vt(e,r,"listItemIndent",o.containerState.size+1);function r(s){const i=o.events[o.events.length-1];return i&&i[1].type==="listItemIndent"&&i[2].sliceSerialize(i[1],!0).length===o.containerState.size?t(s):n(s)}}function i_e(e){e.exit(this.containerState.type)}function l_e(e,t,n){const o=this;return Vt(e,r,"listItemPrefixWhitespace",o.parser.constructs.disable.null.includes("codeIndented")?void 0:4+1);function r(s){const i=o.events[o.events.length-1];return!Nt(s)&&i&&i[1].type==="listItemPrefixWhitespace"?t(s):n(s)}}const hS={name:"setextUnderline",tokenize:u_e,resolveTo:a_e};function a_e(e,t){let n=e.length,o,r,s;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){o=n;break}e[n][1].type==="paragraph"&&(r=n)}else e[n][1].type==="content"&&e.splice(n,1),!s&&e[n][1].type==="definition"&&(s=n);const i={type:"setextHeading",start:Object.assign({},e[r][1].start),end:Object.assign({},e[e.length-1][1].end)};return e[r][1].type="setextHeadingText",s?(e.splice(r,0,["enter",i,t]),e.splice(s+1,0,["exit",e[o][1],t]),e[o][1].end=Object.assign({},e[s][1].end)):e[o][1]=i,e.push(["exit",i,t]),e}function u_e(e,t,n){const o=this;let r;return s;function s(u){let c=o.events.length,d;for(;c--;)if(o.events[c][1].type!=="lineEnding"&&o.events[c][1].type!=="linePrefix"&&o.events[c][1].type!=="content"){d=o.events[c][1].type==="paragraph";break}return!o.parser.lazy[o.now().line]&&(o.interrupt||d)?(e.enter("setextHeadingLine"),r=u,i(u)):n(u)}function i(u){return e.enter("setextHeadingLineSequence"),l(u)}function l(u){return u===r?(e.consume(u),l):(e.exit("setextHeadingLineSequence"),Nt(u)?Vt(e,a,"lineSuffix")(u):a(u))}function a(u){return u===null||dt(u)?(e.exit("setextHeadingLine"),t(u)):n(u)}}const c_e={tokenize:d_e};function d_e(e){const t=this,n=e.attempt($h,o,e.attempt(this.parser.constructs.flowInitial,r,Vt(e,e.attempt(this.parser.constructs.flow,r,e.attempt(gye,r)),"linePrefix")));return n;function o(s){if(s===null){e.consume(s);return}return e.enter("lineEndingBlank"),e.consume(s),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function r(s){if(s===null){e.consume(s);return}return e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const f_e={resolveAll:LI()},p_e=PI("string"),h_e=PI("text");function PI(e){return{tokenize:t,resolveAll:LI(e==="text"?m_e:void 0)};function t(n){const o=this,r=this.parser.constructs[e],s=n.attempt(r,i,l);return i;function i(c){return u(c)?s(c):l(c)}function l(c){if(c===null){n.consume(c);return}return n.enter("data"),n.consume(c),a}function a(c){return u(c)?(n.exit("data"),s(c)):(n.consume(c),a)}function u(c){if(c===null)return!0;const d=r[c];let f=-1;if(d)for(;++f<d.length;){const p=d[f];if(!p.previous||p.previous.call(o,o.previous))return!0}return!1}}}function LI(e){return t;function t(n,o){let r=-1,s;for(;++r<=n.length;)s===void 0?n[r]&&n[r][1].type==="data"&&(s=r,r++):(!n[r]||n[r][1].type!=="data")&&(r!==s+2&&(n[s][1].end=n[r-1][1].end,n.splice(s+2,r-s-2),r=s+2),s=void 0);return e?e(n,o):n}}function m_e(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const o=e[n-1][1],r=t.sliceStream(o);let s=r.length,i=-1,l=0,a;for(;s--;){const u=r[s];if(typeof u=="string"){for(i=u.length;u.charCodeAt(i-1)===32;)l++,i--;if(i)break;i=-1}else if(u===-2)a=!0,l++;else if(u!==-1){s++;break}}if(l){const u={type:n===e.length||a||l<2?"lineSuffix":"hardBreakTrailing",start:{line:o.end.line,column:o.end.column-l,offset:o.end.offset-l,_index:o.start._index+s,_bufferIndex:s?i:o.start._bufferIndex+i},end:Object.assign({},o.end)};o.end=Object.assign({},u.start),o.start.offset===o.end.offset?Object.assign(o,u):(e.splice(n,0,["enter",u,t],["exit",u,t]),n+=2)}n++}return e}function g_e(e,t,n){let o=Object.assign(n?Object.assign({},n):{line:1,column:1,offset:0},{_index:0,_bufferIndex:-1});const r={},s=[];let i=[],l=[];const a={consume:w,enter:_,exit:S,attempt:T(x),check:T(E),interrupt:T(E,{interrupt:!0})},u={previous:null,code:null,containerState:{},events:[],parser:e,sliceStream:p,sliceSerialize:f,now:h,defineSkip:m,write:d};let c=t.tokenize.call(u,a);return t.resolveAll&&s.push(t),u;function d(F){return i=xr(i,F),y(),i[i.length-1]!==null?[]:(O(t,0),u.events=tv(s,u.events,u),u.events)}function f(F,B){return y_e(p(F),B)}function p(F){return v_e(i,F)}function h(){const{line:F,column:B,offset:Y,_index:Z,_bufferIndex:U}=o;return{line:F,column:B,offset:Y,_index:Z,_bufferIndex:U}}function m(F){r[F.line]=F.column,N()}function y(){let F;for(;o._index<i.length;){const B=i[o._index];if(typeof B=="string")for(F=o._index,o._bufferIndex<0&&(o._bufferIndex=0);o._index===F&&o._bufferIndex<B.length;)v(B.charCodeAt(o._bufferIndex));else v(B)}}function v(F){c=c(F)}function w(F){dt(F)?(o.line++,o.column=1,o.offset+=F===-3?2:1,N()):F!==-1&&(o.column++,o.offset++),o._bufferIndex<0?o._index++:(o._bufferIndex++,o._bufferIndex===i[o._index].length&&(o._bufferIndex=-1,o._index++)),u.previous=F}function _(F,B){const Y=B||{};return Y.type=F,Y.start=h(),u.events.push(["enter",Y,u]),l.push(Y),Y}function S(F){const B=l.pop();return B.end=h(),u.events.push(["exit",B,u]),B}function x(F,B){O(F,B.from)}function E(F,B){B.restore()}function T(F,B){return Y;function Y(Z,U,j){let V,H,L,I;return Array.isArray(Z)?oe(Z):"tokenize"in Z?oe([Z]):X(Z);function X(xe){return ee;function ee(de){const ve=de!==null&&xe[de],le=de!==null&&xe.null,Ie=[...Array.isArray(ve)?ve:ve?[ve]:[],...Array.isArray(le)?le:le?[le]:[]];return oe(Ie)(de)}}function oe(xe){return V=xe,H=0,xe.length===0?j:z(xe[H])}function z(xe){return ee;function ee(de){return I=P(),L=xe,xe.partial||(u.currentConstruct=xe),xe.name&&u.parser.constructs.disable.null.includes(xe.name)?Oe():xe.tokenize.call(B?Object.assign(Object.create(u),B):u,a,ge,Oe)(de)}}function ge(xe){return F(L,I),U}function Oe(xe){return I.restore(),++H<V.length?z(V[H]):j}}}function O(F,B){F.resolveAll&&!s.includes(F)&&s.push(F),F.resolve&&Rr(u.events,B,u.events.length-B,F.resolve(u.events.slice(B),u)),F.resolveTo&&(u.events=F.resolveTo(u.events,u))}function P(){const F=h(),B=u.previous,Y=u.currentConstruct,Z=u.events.length,U=Array.from(l);return{restore:j,from:Z};function j(){o=F,u.previous=B,u.currentConstruct=Y,u.events.length=Z,l=U,N()}}function N(){o.line in r&&o.column<2&&(o.column=r[o.line],o.offset+=r[o.line]-1)}}function v_e(e,t){const n=t.start._index,o=t.start._bufferIndex,r=t.end._index,s=t.end._bufferIndex;let i;if(n===r)i=[e[n].slice(o,s)];else{if(i=e.slice(n,r),o>-1){const l=i[0];typeof l=="string"?i[0]=l.slice(o):i.shift()}s>0&&i.push(e[r].slice(0,s))}return i}function y_e(e,t){let n=-1;const o=[];let r;for(;++n<e.length;){const s=e[n];let i;if(typeof s=="string")i=s;else switch(s){case-5:{i="\r";break}case-4:{i=`
80 `;break}case-3:{i=`\r
81 `;break}case-2:{i=t?" ":" ";break}case-1:{if(!t&&r)continue;i=" ";break}default:i=String.fromCharCode(s)}r=s===-2,o.push(i)}return o.join("")}const __e={42:Fo,43:Fo,45:Fo,48:Fo,49:Fo,50:Fo,51:Fo,52:Fo,53:Fo,54:Fo,55:Fo,56:Fo,57:Fo,62:xI},b_e={91:wye},w_e={[-2]:vy,[-1]:vy,32:vy},C_e={35:xye,42:p1,45:[hS,p1],60:Iye,61:hS,95:p1,96:fS,126:fS},k_e={38:TI,92:MI},S_e={[-5]:yy,[-4]:yy,[-3]:yy,33:Yye,38:TI,42:Db,60:[Jve,Fye],91:Jye,92:[$ye,MI],93:eC,95:Db,96:cye},$_e={null:[Db,f_e]},E_e={null:[42,95]},x_e={null:[]},M_e=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:E_e,contentInitial:b_e,disable:x_e,document:__e,flow:C_e,flowInitial:w_e,insideSpan:$_e,string:k_e,text:S_e},Symbol.toStringTag,{value:"Module"}));function T_e(e){const n=$I([M_e,...(e||{}).extensions||[]]),o={defined:[],lazy:{},constructs:n,content:r(Uve),document:r(Kve),flow:r(c_e),string:r(p_e),text:r(h_e)};return o;function r(s){return i;function i(l){return g_e(o,s,l)}}}function O_e(e){for(;!OI(e););return e}const mS=/[\0\t\n\r]/g;function I_e(){let e=1,t="",n=!0,o;return r;function r(s,i,l){const a=[];let u,c,d,f,p;for(s=t+(typeof s=="string"?s.toString():new TextDecoder(i||void 0).decode(s)),d=0,t="",n&&(s.charCodeAt(0)===65279&&d++,n=void 0);d<s.length;){if(mS.lastIndex=d,u=mS.exec(s),f=u&&u.index!==void 0?u.index:s.length,p=s.charCodeAt(f),!u){t=s.slice(d);break}if(p===10&&d===f&&o)a.push(-3),o=void 0;else switch(o&&(a.push(-5),o=void 0),d<f&&(a.push(s.slice(d,f)),e+=f-d),p){case 0:{a.push(65533),e++;break}case 9:{for(c=Math.ceil(e/4)*4,a.push(-2);e++<c;)a.push(-1);break}case 10:{a.push(-4),e=1;break}default:o=!0,e=1}d=f+1}return l&&(o&&a.push(-5),t&&a.push(t),a.push(null)),a}}const A_e=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function RI(e){return e.replace(A_e,N_e)}function N_e(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const r=n.charCodeAt(1),s=r===120||r===88;return EI(n.slice(s?2:1),s?16:10)}return Q3(n)||e}function ep(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?gS(e.position):"start"in e||"end"in e?gS(e):"line"in e||"column"in e?Fb(e):""}function Fb(e){return vS(e&&e.line)+":"+vS(e&&e.column)}function gS(e){return Fb(e&&e.start)+"-"+Fb(e&&e.end)}function vS(e){return e&&typeof e=="number"?e:1}const DI={}.hasOwnProperty;function P_e(e,t,n){return typeof t!="string"&&(n=t,t=void 0),L_e(n)(O_e(T_e(n).document().write(I_e()(e,t,!0))))}function L_e(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:s(Le),autolinkProtocol:P,autolinkEmail:P,atxHeading:s(ue),blockQuote:s(le),characterEscape:P,characterReference:P,codeFenced:s(Ie),codeFencedFenceInfo:i,codeFencedFenceMeta:i,codeIndented:s(Ie,i),codeText:s(Ge,i),codeTextData:P,data:P,codeFlowValue:P,definition:s(G),definitionDestinationString:i,definitionLabelString:i,definitionTitleString:i,emphasis:s(J),hardBreakEscape:s(_e),hardBreakTrailing:s(_e),htmlFlow:s(ye,i),htmlFlowData:P,htmlText:s(ye,i),htmlTextData:P,image:s(Ae),label:i,link:s(Le),listItem:s(Pe),listItemValue:f,listOrdered:s(Ee,d),listUnordered:s(Ee),paragraph:s(me),reference:z,referenceString:i,resourceDestinationString:i,resourceTitleString:i,setextHeading:s(ue),strong:s(je),thematicBreak:s(ce)},exit:{atxHeading:a(),atxHeadingSequence:x,autolink:a(),autolinkEmail:ve,autolinkProtocol:de,blockQuote:a(),characterEscapeValue:N,characterReferenceMarkerHexadecimal:Oe,characterReferenceMarkerNumeric:Oe,characterReferenceValue:xe,characterReference:ee,codeFenced:a(y),codeFencedFence:m,codeFencedFenceInfo:p,codeFencedFenceMeta:h,codeFlowValue:N,codeIndented:a(v),codeText:a(U),codeTextData:N,data:N,definition:a(),definitionDestinationString:S,definitionLabelString:w,definitionTitleString:_,emphasis:a(),hardBreakEscape:a(B),hardBreakTrailing:a(B),htmlFlow:a(Y),htmlFlowData:N,htmlText:a(Z),htmlTextData:N,image:a(V),label:L,labelText:H,lineEnding:F,link:a(j),listItem:a(),listOrdered:a(),listUnordered:a(),paragraph:a(),referenceString:ge,resourceDestinationString:I,resourceTitleString:X,resource:oe,setextHeading:a(O),setextHeadingLineSequence:T,setextHeadingText:E,strong:a(),thematicBreak:a()}};FI(t,(e||{}).mdastExtensions||[]);const n={};return o;function o(te){let pe={type:"root",children:[]};const Ve={stack:[pe],tokenStack:[],config:t,enter:l,exit:u,buffer:i,resume:c,data:n},Je=[];let $e=-1;for(;++$e<te.length;)if(te[$e][1].type==="listOrdered"||te[$e][1].type==="listUnordered")if(te[$e][0]==="enter")Je.push($e);else{const ie=Je.pop();$e=r(te,ie,$e)}for($e=-1;++$e<te.length;){const ie=t[te[$e][0]];DI.call(ie,te[$e][1].type)&&ie[te[$e][1].type].call(Object.assign({sliceSerialize:te[$e][2].sliceSerialize},Ve),te[$e][1])}if(Ve.tokenStack.length>0){const ie=Ve.tokenStack[Ve.tokenStack.length-1];(ie[1]||yS).call(Ve,void 0,ie[0])}for(pe.position={start:Ji(te.length>0?te[0][1].start:{line:1,column:1,offset:0}),end:Ji(te.length>0?te[te.length-2][1].end:{line:1,column:1,offset:0})},$e=-1;++$e<t.transforms.length;)pe=t.transforms[$e](pe)||pe;return pe}function r(te,pe,Ve){let Je=pe-1,$e=-1,ie=!1,we,ae,Se,Fe;for(;++Je<=Ve;){const st=te[Je];switch(st[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{st[0]==="enter"?$e++:$e--,Fe=void 0;break}case"lineEndingBlank":{st[0]==="enter"&&(we&&!Fe&&!$e&&!Se&&(Se=Je),Fe=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Fe=void 0}if(!$e&&st[0]==="enter"&&st[1].type==="listItemPrefix"||$e===-1&&st[0]==="exit"&&(st[1].type==="listUnordered"||st[1].type==="listOrdered")){if(we){let se=Je;for(ae=void 0;se--;){const De=te[se];if(De[1].type==="lineEnding"||De[1].type==="lineEndingBlank"){if(De[0]==="exit")continue;ae&&(te[ae][1].type="lineEndingBlank",ie=!0),De[1].type="lineEnding",ae=se}else if(!(De[1].type==="linePrefix"||De[1].type==="blockQuotePrefix"||De[1].type==="blockQuotePrefixWhitespace"||De[1].type==="blockQuoteMarker"||De[1].type==="listItemIndent"))break}Se&&(!ae||Se<ae)&&(we._spread=!0),we.end=Object.assign({},ae?te[ae][1].start:st[1].end),te.splice(ae||Je,0,["exit",we,st[2]]),Je++,Ve++}if(st[1].type==="listItemPrefix"){const se={type:"listItem",_spread:!1,start:Object.assign({},st[1].start),end:void 0};we=se,te.splice(Je,0,["enter",se,st[2]]),Je++,Ve++,Se=void 0,Fe=!0}}}return te[pe][1]._spread=ie,Ve}function s(te,pe){return Ve;function Ve(Je){l.call(this,te(Je),Je),pe&&pe.call(this,Je)}}function i(){this.stack.push({type:"fragment",children:[]})}function l(te,pe,Ve){this.stack[this.stack.length-1].children.push(te),this.stack.push(te),this.tokenStack.push([pe,Ve]),te.position={start:Ji(pe.start),end:void 0}}function a(te){return pe;function pe(Ve){te&&te.call(this,Ve),u.call(this,Ve)}}function u(te,pe){const Ve=this.stack.pop(),Je=this.tokenStack.pop();if(Je)Je[0].type!==te.type&&(pe?pe.call(this,te,Je[0]):(Je[1]||yS).call(this,te,Je[0]));else throw new Error("Cannot close `"+te.type+"` ("+ep({start:te.start,end:te.end})+"): it’s not open");Ve.position.end=Ji(te.end)}function c(){return X3(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function f(te){if(this.data.expectingFirstListItemValue){const pe=this.stack[this.stack.length-2];pe.start=Number.parseInt(this.sliceSerialize(te),10),this.data.expectingFirstListItemValue=void 0}}function p(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.lang=te}function h(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.meta=te}function m(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function y(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.value=te.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function v(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.value=te.replace(/(\r?\n|\r)$/g,"")}function w(te){const pe=this.resume(),Ve=this.stack[this.stack.length-1];Ve.label=pe,Ve.identifier=cs(this.sliceSerialize(te)).toLowerCase()}function _(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.title=te}function S(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.url=te}function x(te){const pe=this.stack[this.stack.length-1];if(!pe.depth){const Ve=this.sliceSerialize(te).length;pe.depth=Ve}}function E(){this.data.setextHeadingSlurpLineEnding=!0}function T(te){const pe=this.stack[this.stack.length-1];pe.depth=this.sliceSerialize(te).codePointAt(0)===61?1:2}function O(){this.data.setextHeadingSlurpLineEnding=void 0}function P(te){const Ve=this.stack[this.stack.length-1].children;let Je=Ve[Ve.length-1];(!Je||Je.type!=="text")&&(Je=Ze(),Je.position={start:Ji(te.start),end:void 0},Ve.push(Je)),this.stack.push(Je)}function N(te){const pe=this.stack.pop();pe.value+=this.sliceSerialize(te),pe.position.end=Ji(te.end)}function F(te){const pe=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Ve=pe.children[pe.children.length-1];Ve.position.end=Ji(te.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(pe.type)&&(P.call(this,te),N.call(this,te))}function B(){this.data.atHardBreak=!0}function Y(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.value=te}function Z(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.value=te}function U(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.value=te}function j(){const te=this.stack[this.stack.length-1];if(this.data.inReference){const pe=this.data.referenceType||"shortcut";te.type+="Reference",te.referenceType=pe,delete te.url,delete te.title}else delete te.identifier,delete te.label;this.data.referenceType=void 0}function V(){const te=this.stack[this.stack.length-1];if(this.data.inReference){const pe=this.data.referenceType||"shortcut";te.type+="Reference",te.referenceType=pe,delete te.url,delete te.title}else delete te.identifier,delete te.label;this.data.referenceType=void 0}function H(te){const pe=this.sliceSerialize(te),Ve=this.stack[this.stack.length-2];Ve.label=RI(pe),Ve.identifier=cs(pe).toLowerCase()}function L(){const te=this.stack[this.stack.length-1],pe=this.resume(),Ve=this.stack[this.stack.length-1];if(this.data.inReference=!0,Ve.type==="link"){const Je=te.children;Ve.children=Je}else Ve.alt=pe}function I(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.url=te}function X(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.title=te}function oe(){this.data.inReference=void 0}function z(){this.data.referenceType="collapsed"}function ge(te){const pe=this.resume(),Ve=this.stack[this.stack.length-1];Ve.label=pe,Ve.identifier=cs(this.sliceSerialize(te)).toLowerCase(),this.data.referenceType="full"}function Oe(te){this.data.characterReferenceType=te.type}function xe(te){const pe=this.sliceSerialize(te),Ve=this.data.characterReferenceType;let Je;Ve?(Je=EI(pe,Ve==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Je=Q3(pe);const $e=this.stack[this.stack.length-1];$e.value+=Je}function ee(te){const pe=this.stack.pop();pe.position.end=Ji(te.end)}function de(te){N.call(this,te);const pe=this.stack[this.stack.length-1];pe.url=this.sliceSerialize(te)}function ve(te){N.call(this,te);const pe=this.stack[this.stack.length-1];pe.url="mailto:"+this.sliceSerialize(te)}function le(){return{type:"blockquote",children:[]}}function Ie(){return{type:"code",lang:null,meta:null,value:""}}function Ge(){return{type:"inlineCode",value:""}}function G(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function J(){return{type:"emphasis",children:[]}}function ue(){return{type:"heading",depth:0,children:[]}}function _e(){return{type:"break"}}function ye(){return{type:"html",value:""}}function Ae(){return{type:"image",title:null,url:"",alt:null}}function Le(){return{type:"link",title:null,url:"",children:[]}}function Ee(te){return{type:"list",ordered:te.type==="listOrdered",start:null,spread:te._spread,children:[]}}function Pe(te){return{type:"listItem",spread:te._spread,checked:null,children:[]}}function me(){return{type:"paragraph",children:[]}}function je(){return{type:"strong",children:[]}}function Ze(){return{type:"text",value:""}}function ce(){return{type:"thematicBreak"}}}function Ji(e){return{line:e.line,column:e.column,offset:e.offset}}function FI(e,t){let n=-1;for(;++n<t.length;){const o=t[n];Array.isArray(o)?FI(e,o):R_e(e,o)}}function R_e(e,t){let n;for(n in t)if(DI.call(t,n))switch(n){case"canContainEols":{const o=t[n];o&&e[n].push(...o);break}case"transforms":{const o=t[n];o&&e[n].push(...o);break}case"enter":case"exit":{const o=t[n];o&&Object.assign(e[n],o);break}}}function yS(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+ep({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+ep({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+ep({start:t.start,end:t.end})+") is still open")}function Vb(e){const t=this;t.parser=n;function n(o){return P_e(o,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}const _S={}.hasOwnProperty;function D_e(e,t){const n=t||{};function o(r,...s){let i=o.invalid;const l=o.handlers;if(r&&_S.call(r,e)){const a=String(r[e]);i=_S.call(l,a)?l[a]:o.unknown}if(i)return i.call(this,r,...s)}return o.handlers=n.handlers||{},o.invalid=n.invalid,o.unknown=n.unknown,o}const F_e={}.hasOwnProperty;function VI(e,t){let n=-1,o;if(t.extensions)for(;++n<t.extensions.length;)VI(e,t.extensions[n]);for(o in t)if(F_e.call(t,o))switch(o){case"extensions":break;case"unsafe":{bS(e[o],t[o]);break}case"join":{bS(e[o],t[o]);break}case"handlers":{V_e(e[o],t[o]);break}default:e.options[o]=t[o]}return e}function bS(e,t){t&&e.push(...t)}function V_e(e,t){t&&Object.assign(e,t)}function B_e(e,t,n,o){const r=n.enter("blockquote"),s=n.createTracker(o);s.move("> "),s.shift(2);const i=n.indentLines(n.containerFlow(e,s.current()),z_e);return r(),i}function z_e(e,t,n){return">"+(n?"":" ")+e}function BI(e,t){return wS(e,t.inConstruct,!0)&&!wS(e,t.notInConstruct,!1)}function wS(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let o=-1;for(;++o<t.length;)if(e.includes(t[o]))return!0;return!1}function CS(e,t,n,o){let r=-1;for(;++r<n.unsafe.length;)if(n.unsafe[r].character===`
82 `&&BI(n.stack,n.unsafe[r]))return/[ \t]/.test(o.before)?"":" ";return`\\
83 `}function j_e(e,t){const n=String(e);let o=n.indexOf(t),r=o,s=0,i=0;if(typeof t!="string")throw new TypeError("Expected substring");for(;o!==-1;)o===r?++s>i&&(i=s):s=1,r=o+t.length,o=n.indexOf(t,r);return i}function Bb(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function H_e(e){const t=e.options.fence||"`";if(t!=="`"&&t!=="~")throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function U_e(e,t,n,o){const r=H_e(n),s=e.value||"",i=r==="`"?"GraveAccent":"Tilde";if(Bb(e,n)){const d=n.enter("codeIndented"),f=n.indentLines(s,W_e);return d(),f}const l=n.createTracker(o),a=r.repeat(Math.max(j_e(s,r)+1,3)),u=n.enter("codeFenced");let c=l.move(a);if(e.lang){const d=n.enter(`codeFencedLang${i}`);c+=l.move(n.safe(e.lang,{before:c,after:" ",encode:["`"],...l.current()})),d()}if(e.lang&&e.meta){const d=n.enter(`codeFencedMeta${i}`);c+=l.move(" "),c+=l.move(n.safe(e.meta,{before:c,after:`
84 `,encode:["`"],...l.current()})),d()}return c+=l.move(`
85 `),s&&(c+=l.move(s+`
86 `)),c+=l.move(a),u(),c}function W_e(e,t,n){return(n?"":" ")+e}function tC(e){const t=e.options.quote||'"';if(t!=='"'&&t!=="'")throw new Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function K_e(e,t,n,o){const r=tC(n),s=r==='"'?"Quote":"Apostrophe",i=n.enter("definition");let l=n.enter("label");const a=n.createTracker(o);let u=a.move("[");return u+=a.move(n.safe(n.associationId(e),{before:u,after:"]",...a.current()})),u+=a.move("]: "),l(),!e.url||/[\0- \u007F]/.test(e.url)?(l=n.enter("destinationLiteral"),u+=a.move("<"),u+=a.move(n.safe(e.url,{before:u,after:">",...a.current()})),u+=a.move(">")):(l=n.enter("destinationRaw"),u+=a.move(n.safe(e.url,{before:u,after:e.title?" ":`
87 `,...a.current()}))),l(),e.title&&(l=n.enter(`title${s}`),u+=a.move(" "+r),u+=a.move(n.safe(e.title,{before:u,after:r,...a.current()})),u+=a.move(r),l()),i(),u}function q_e(e){const t=e.options.emphasis||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}zI.peek=G_e;function zI(e,t,n,o){const r=q_e(n),s=n.enter("emphasis"),i=n.createTracker(o);let l=i.move(r);return l+=i.move(n.containerPhrasing(e,{before:l,after:r,...i.current()})),l+=i.move(r),s(),l}function G_e(e,t,n){return n.options.emphasis||"*"}const nv=function(e){if(e==null)return X_e;if(typeof e=="function")return ov(e);if(typeof e=="object")return Array.isArray(e)?Y_e(e):Z_e(e);if(typeof e=="string")return J_e(e);throw new Error("Expected function, string, or object as test")};function Y_e(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=nv(e[n]);return ov(o);function o(...r){let s=-1;for(;++s<t.length;)if(t[s].apply(this,r))return!0;return!1}}function Z_e(e){const t=e;return ov(n);function n(o){const r=o;let s;for(s in e)if(r[s]!==t[s])return!1;return!0}}function J_e(e){return ov(t);function t(n){return n&&n.type===e}}function ov(e){return t;function t(n,o,r){return!!(Q_e(n)&&e.call(this,n,typeof o=="number"?o:void 0,r||void 0))}}function X_e(){return!0}function Q_e(e){return e!==null&&typeof e=="object"&&"type"in e}const jI=[],ebe=!0,zb=!1,jb="skip";function HI(e,t,n,o){let r;typeof t=="function"&&typeof n!="function"?(o=n,n=t):r=t;const s=nv(r),i=o?-1:1;l(e,void 0,[])();function l(a,u,c){const d=a&&typeof a=="object"?a:{};if(typeof d.type=="string"){const p=typeof d.tagName=="string"?d.tagName:typeof d.name=="string"?d.name:void 0;Object.defineProperty(f,"name",{value:"node ("+(a.type+(p?"<"+p+">":""))+")"})}return f;function f(){let p=jI,h,m,y;if((!t||s(a,u,c[c.length-1]||void 0))&&(p=tbe(n(a,c)),p[0]===zb))return p;if("children"in a&&a.children){const v=a;if(v.children&&p[0]!==jb)for(m=(o?v.children.length:-1)+i,y=c.concat(v);m>-1&&m<v.children.length;){const w=v.children[m];if(h=l(w,m,y)(),h[0]===zb)return h;m=typeof h[1]=="number"?h[1]:m+i}}return p}}}function tbe(e){return Array.isArray(e)?e:typeof e=="number"?[ebe,e]:e==null?jI:[e]}function Od(e,t,n,o){let r,s,i;typeof t=="function"&&typeof n!="function"?(s=void 0,i=t,r=n):(s=t,i=n,r=o),HI(e,s,l,r);function l(a,u){const c=u[u.length-1],d=c?c.children.indexOf(a):void 0;return i(a,d,c)}}function UI(e,t){let n=!1;return Od(e,function(o){if("value"in o&&/\r?\n|\r/.test(o.value)||o.type==="break")return n=!0,zb}),!!((!e.depth||e.depth<3)&&X3(e)&&(t.options.setext||n))}function nbe(e,t,n,o){const r=Math.max(Math.min(6,e.depth||1),1),s=n.createTracker(o);if(UI(e,n)){const c=n.enter("headingSetext"),d=n.enter("phrasing"),f=n.containerPhrasing(e,{...s.current(),before:`
88 `,after:`
89 `});return d(),c(),f+`
90 `+(r===1?"=":"-").repeat(f.length-(Math.max(f.lastIndexOf("\r"),f.lastIndexOf(`
91 `))+1))}const i="#".repeat(r),l=n.enter("headingAtx"),a=n.enter("phrasing");s.move(i+" ");let u=n.containerPhrasing(e,{before:"# ",after:`
92 `,...s.current()});return/^[\t ]/.test(u)&&(u="&#x"+u.charCodeAt(0).toString(16).toUpperCase()+";"+u.slice(1)),u=u?i+" "+u:i,n.options.closeAtx&&(u+=" "+i),a(),l(),u}WI.peek=obe;function WI(e){return e.value||""}function obe(){return"<"}KI.peek=rbe;function KI(e,t,n,o){const r=tC(n),s=r==='"'?"Quote":"Apostrophe",i=n.enter("image");let l=n.enter("label");const a=n.createTracker(o);let u=a.move("![");return u+=a.move(n.safe(e.alt,{before:u,after:"]",...a.current()})),u+=a.move("]("),l(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(l=n.enter("destinationLiteral"),u+=a.move("<"),u+=a.move(n.safe(e.url,{before:u,after:">",...a.current()})),u+=a.move(">")):(l=n.enter("destinationRaw"),u+=a.move(n.safe(e.url,{before:u,after:e.title?" ":")",...a.current()}))),l(),e.title&&(l=n.enter(`title${s}`),u+=a.move(" "+r),u+=a.move(n.safe(e.title,{before:u,after:r,...a.current()})),u+=a.move(r),l()),u+=a.move(")"),i(),u}function rbe(){return"!"}qI.peek=sbe;function qI(e,t,n,o){const r=e.referenceType,s=n.enter("imageReference");let i=n.enter("label");const l=n.createTracker(o);let a=l.move("![");const u=n.safe(e.alt,{before:a,after:"]",...l.current()});a+=l.move(u+"]["),i();const c=n.stack;n.stack=[],i=n.enter("reference");const d=n.safe(n.associationId(e),{before:a,after:"]",...l.current()});return i(),n.stack=c,s(),r==="full"||!u||u!==d?a+=l.move(d+"]"):r==="shortcut"?a=a.slice(0,-1):a+=l.move("]"),a}function sbe(){return"!"}GI.peek=ibe;function GI(e,t,n){let o=e.value||"",r="`",s=-1;for(;new RegExp("(^|[^`])"+r+"([^`]|$)").test(o);)r+="`";for(/[^ \r\n]/.test(o)&&(/^[ \r\n]/.test(o)&&/[ \r\n]$/.test(o)||/^`|`$/.test(o))&&(o=" "+o+" ");++s<n.unsafe.length;){const i=n.unsafe[s],l=n.compilePattern(i);let a;if(i.atBreak)for(;a=l.exec(o);){let u=a.index;o.charCodeAt(u)===10&&o.charCodeAt(u-1)===13&&u--,o=o.slice(0,u)+" "+o.slice(a.index+1)}}return r+o+r}function ibe(){return"`"}function YI(e,t){const n=X3(e);return!!(!t.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type==="text"&&(n===e.url||"mailto:"+n===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}ZI.peek=lbe;function ZI(e,t,n,o){const r=tC(n),s=r==='"'?"Quote":"Apostrophe",i=n.createTracker(o);let l,a;if(YI(e,n)){const c=n.stack;n.stack=[],l=n.enter("autolink");let d=i.move("<");return d+=i.move(n.containerPhrasing(e,{before:d,after:">",...i.current()})),d+=i.move(">"),l(),n.stack=c,d}l=n.enter("link"),a=n.enter("label");let u=i.move("[");return u+=i.move(n.containerPhrasing(e,{before:u,after:"](",...i.current()})),u+=i.move("]("),a(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(a=n.enter("destinationLiteral"),u+=i.move("<"),u+=i.move(n.safe(e.url,{before:u,after:">",...i.current()})),u+=i.move(">")):(a=n.enter("destinationRaw"),u+=i.move(n.safe(e.url,{before:u,after:e.title?" ":")",...i.current()}))),a(),e.title&&(a=n.enter(`title${s}`),u+=i.move(" "+r),u+=i.move(n.safe(e.title,{before:u,after:r,...i.current()})),u+=i.move(r),a()),u+=i.move(")"),l(),u}function lbe(e,t,n){return YI(e,n)?"<":"["}JI.peek=abe;function JI(e,t,n,o){const r=e.referenceType,s=n.enter("linkReference");let i=n.enter("label");const l=n.createTracker(o);let a=l.move("[");const u=n.containerPhrasing(e,{before:a,after:"]",...l.current()});a+=l.move(u+"]["),i();const c=n.stack;n.stack=[],i=n.enter("reference");const d=n.safe(n.associationId(e),{before:a,after:"]",...l.current()});return i(),n.stack=c,s(),r==="full"||!u||u!==d?a+=l.move(d+"]"):r==="shortcut"?a=a.slice(0,-1):a+=l.move("]"),a}function abe(){return"["}function nC(e){const t=e.options.bullet||"*";if(t!=="*"&&t!=="+"&&t!=="-")throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function ube(e){const t=nC(e),n=e.options.bulletOther;if(!n)return t==="*"?"-":"*";if(n!=="*"&&n!=="+"&&n!=="-")throw new Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw new Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function cbe(e){const t=e.options.bulletOrdered||".";if(t!=="."&&t!==")")throw new Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function XI(e){const t=e.options.rule||"*";if(t!=="*"&&t!=="-"&&t!=="_")throw new Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function dbe(e,t,n,o){const r=n.enter("list"),s=n.bulletCurrent;let i=e.ordered?cbe(n):nC(n);const l=e.ordered?i==="."?")":".":ube(n);let a=t&&n.bulletLastUsed?i===n.bulletLastUsed:!1;if(!e.ordered){const c=e.children?e.children[0]:void 0;if((i==="*"||i==="-")&&c&&(!c.children||!c.children[0])&&n.stack[n.stack.length-1]==="list"&&n.stack[n.stack.length-2]==="listItem"&&n.stack[n.stack.length-3]==="list"&&n.stack[n.stack.length-4]==="listItem"&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(a=!0),XI(n)===i&&c){let d=-1;for(;++d<e.children.length;){const f=e.children[d];if(f&&f.type==="listItem"&&f.children&&f.children[0]&&f.children[0].type==="thematicBreak"){a=!0;break}}}}a&&(i=l),n.bulletCurrent=i;const u=n.containerFlow(e,o);return n.bulletLastUsed=i,n.bulletCurrent=s,r(),u}function fbe(e){const t=e.options.listItemIndent||"one";if(t!=="tab"&&t!=="one"&&t!=="mixed")throw new Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}function pbe(e,t,n,o){const r=fbe(n);let s=n.bulletCurrent||nC(n);t&&t.type==="list"&&t.ordered&&(s=(typeof t.start=="number"&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+s);let i=s.length+1;(r==="tab"||r==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(i=Math.ceil(i/4)*4);const l=n.createTracker(o);l.move(s+" ".repeat(i-s.length)),l.shift(i);const a=n.enter("listItem"),u=n.indentLines(n.containerFlow(e,l.current()),c);return a(),u;function c(d,f,p){return f?(p?"":" ".repeat(i))+d:(p?s:s+" ".repeat(i-s.length))+d}}function hbe(e,t,n,o){const r=n.enter("paragraph"),s=n.enter("phrasing"),i=n.containerPhrasing(e,o);return s(),r(),i}const mbe=nv(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function gbe(e,t,n,o){return(e.children.some(function(i){return mbe(i)})?n.containerPhrasing:n.containerFlow).call(n,e,o)}function vbe(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}QI.peek=ybe;function QI(e,t,n,o){const r=vbe(n),s=n.enter("strong"),i=n.createTracker(o);let l=i.move(r+r);return l+=i.move(n.containerPhrasing(e,{before:l,after:r,...i.current()})),l+=i.move(r+r),s(),l}function ybe(e,t,n){return n.options.strong||"*"}function _be(e,t,n,o){return n.safe(e.value,o)}function bbe(e){const t=e.options.ruleRepetition||3;if(t<3)throw new Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function wbe(e,t,n){const o=(XI(n)+(n.options.ruleSpaces?" ":"")).repeat(bbe(n));return n.options.ruleSpaces?o.slice(0,-1):o}const oC={blockquote:B_e,break:CS,code:U_e,definition:K_e,emphasis:zI,hardBreak:CS,heading:nbe,html:WI,image:KI,imageReference:qI,inlineCode:GI,link:ZI,linkReference:JI,list:dbe,listItem:pbe,paragraph:hbe,root:gbe,strong:QI,text:_be,thematicBreak:wbe},Cbe=[kbe];function kbe(e,t,n,o){if(t.type==="code"&&Bb(t,o)&&(e.type==="list"||e.type===t.type&&Bb(e,o)))return!1;if("spread"in n&&typeof n.spread=="boolean")return e.type==="paragraph"&&(e.type===t.type||t.type==="definition"||t.type==="heading"&&UI(t,o))?void 0:n.spread?1:0}const fa=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"],Sbe=[{character:" ",after:"[\\r\\n]",inConstruct:"phrasing"},{character:" ",before:"[\\r\\n]",inConstruct:"phrasing"},{character:" ",inConstruct:["codeFencedLangGraveAccent","codeFencedLangTilde"]},{character:"\r",inConstruct:["codeFencedLangGraveAccent","codeFencedLangTilde","codeFencedMetaGraveAccent","codeFencedMetaTilde","destinationLiteral","headingAtx"]},{character:`
93 `,inConstruct:["codeFencedLangGraveAccent","codeFencedLangTilde","codeFencedMetaGraveAccent","codeFencedMetaTilde","destinationLiteral","headingAtx"]},{character:" ",after:"[\\r\\n]",inConstruct:"phrasing"},{character:" ",before:"[\\r\\n]",inConstruct:"phrasing"},{character:" ",inConstruct:["codeFencedLangGraveAccent","codeFencedLangTilde"]},{character:"!",after:"\\[",inConstruct:"phrasing",notInConstruct:fa},{character:'"',inConstruct:"titleQuote"},{atBreak:!0,character:"#"},{character:"#",inConstruct:"headingAtx",after:`(?:[\r
94 ]|$)`},{character:"&",after:"[#A-Za-z]",inConstruct:"phrasing"},{character:"'",inConstruct:"titleApostrophe"},{character:"(",inConstruct:"destinationRaw"},{before:"\\]",character:"(",inConstruct:"phrasing",notInConstruct:fa},{atBreak:!0,before:"\\d+",character:")"},{character:")",inConstruct:"destinationRaw"},{atBreak:!0,character:"*",after:`(?:[ \r
95 *])`},{character:"*",inConstruct:"phrasing",notInConstruct:fa},{atBreak:!0,character:"+",after:`(?:[ \r
96 ])`},{atBreak:!0,character:"-",after:`(?:[ \r
97 -])`},{atBreak:!0,before:"\\d+",character:".",after:`(?:[ \r
98 ]|$)`},{atBreak:!0,character:"<",after:"[!/?A-Za-z]"},{character:"<",after:"[!/?A-Za-z]",inConstruct:"phrasing",notInConstruct:fa},{character:"<",inConstruct:"destinationLiteral"},{atBreak:!0,character:"="},{atBreak:!0,character:">"},{character:">",inConstruct:"destinationLiteral"},{atBreak:!0,character:"["},{character:"[",inConstruct:"phrasing",notInConstruct:fa},{character:"[",inConstruct:["label","reference"]},{character:"\\",after:"[\\r\\n]",inConstruct:"phrasing"},{character:"]",inConstruct:["label","reference"]},{atBreak:!0,character:"_"},{character:"_",inConstruct:"phrasing",notInConstruct:fa},{atBreak:!0,character:"`"},{character:"`",inConstruct:["codeFencedLangGraveAccent","codeFencedMetaGraveAccent"]},{character:"`",inConstruct:"phrasing",notInConstruct:fa},{atBreak:!0,character:"~"}];function $be(e){return e.label||!e.identifier?e.label||"":RI(e.identifier)}function Ebe(e){if(!e._compiled){const t=(e.atBreak?"[\\r\\n][\\t ]*":"")+(e.before?"(?:"+e.before+")":"");e._compiled=new RegExp((t?"("+t+")":"")+(/[|\\{}()[\]^$+*?.-]/.test(e.character)?"\\":"")+e.character+(e.after?"(?:"+e.after+")":""),"g")}return e._compiled}function xbe(e,t,n){const o=t.indexStack,r=e.children||[],s=[];let i=-1,l=n.before;o.push(-1);let a=t.createTracker(n);for(;++i<r.length;){const u=r[i];let c;if(o[o.length-1]=i,i+1<r.length){let d=t.handle.handlers[r[i+1].type];d&&d.peek&&(d=d.peek),c=d?d(r[i+1],e,t,{before:"",after:"",...a.current()}).charAt(0):""}else c=n.after;s.length>0&&(l==="\r"||l===`
99 `)&&u.type==="html"&&(s[s.length-1]=s[s.length-1].replace(/(\r?\n|\r)$/," "),l=" ",a=t.createTracker(n),a.move(s.join(""))),s.push(a.move(t.handle(u,e,t,{...a.current(),before:l,after:c}))),l=s[s.length-1].slice(-1)}return o.pop(),s.join("")}function Mbe(e,t,n){const o=t.indexStack,r=e.children||[],s=t.createTracker(n),i=[];let l=-1;for(o.push(-1);++l<r.length;){const a=r[l];o[o.length-1]=l,i.push(s.move(t.handle(a,e,t,{before:`
100 `,after:`
101 `,...s.current()}))),a.type!=="list"&&(t.bulletLastUsed=void 0),l<r.length-1&&i.push(s.move(Tbe(a,r[l+1],e,t)))}return o.pop(),i.join("")}function Tbe(e,t,n,o){let r=o.join.length;for(;r--;){const s=o.join[r](e,t,n,o);if(s===!0||s===1)break;if(typeof s=="number")return`
102 `.repeat(1+s);if(s===!1)return`
103
104 <!---->
105
106 `}return`
107
108 `}const Obe=/\r?\n|\r/g;function Ibe(e,t){const n=[];let o=0,r=0,s;for(;s=Obe.exec(e);)i(e.slice(o,s.index)),n.push(s[0]),o=s.index+s[0].length,r++;return i(e.slice(o)),n.join("");function i(l){n.push(t(l,r,!l))}}function Abe(e,t,n){const o=(n.before||"")+(t||"")+(n.after||""),r=[],s=[],i={};let l=-1;for(;++l<e.unsafe.length;){const c=e.unsafe[l];if(!BI(e.stack,c))continue;const d=e.compilePattern(c);let f;for(;f=d.exec(o);){const p="before"in c||!!c.atBreak,h="after"in c,m=f.index+(p?f[1].length:0);r.includes(m)?(i[m].before&&!p&&(i[m].before=!1),i[m].after&&!h&&(i[m].after=!1)):(r.push(m),i[m]={before:p,after:h})}}r.sort(Nbe);let a=n.before?n.before.length:0;const u=o.length-(n.after?n.after.length:0);for(l=-1;++l<r.length;){const c=r[l];c<a||c>=u||c+1<u&&r[l+1]===c+1&&i[c].after&&!i[c+1].before&&!i[c+1].after||r[l-1]===c-1&&i[c].before&&!i[c-1].before&&!i[c-1].after||(a!==c&&s.push(kS(o.slice(a,c),"\\")),a=c,/[!-/:-@[-`{-~]/.test(o.charAt(c))&&(!n.encode||!n.encode.includes(o.charAt(c)))?s.push("\\"):(s.push("&#x"+o.charCodeAt(c).toString(16).toUpperCase()+";"),a++))}return s.push(kS(o.slice(a,u),n.after)),s.join("")}function Nbe(e,t){return e-t}function kS(e,t){const n=/\\(?=[!-/:-@[-`{-~])/g,o=[],r=[],s=e+t;let i=-1,l=0,a;for(;a=n.exec(s);)o.push(a.index);for(;++i<o.length;)l!==o[i]&&r.push(e.slice(l,o[i])),r.push("\\"),l=o[i];return r.push(e.slice(l)),r.join("")}function Pbe(e){const t=e||{},n=t.now||{};let o=t.lineShift||0,r=n.line||1,s=n.column||1;return{move:a,current:i,shift:l};function i(){return{now:{line:r,column:s},lineShift:o}}function l(u){o+=u}function a(u){const c=u||"",d=c.split(/\r?\n|\r/g),f=d[d.length-1];return r+=d.length-1,s=d.length===1?s+f.length:1+f.length+o,c}}function Lbe(e,t={}){const n={enter:r,indentLines:Ibe,associationId:$be,containerPhrasing:Vbe,containerFlow:Bbe,createTracker:Pbe,compilePattern:Ebe,safe:zbe,stack:[],unsafe:[...Sbe],join:[...Cbe],handlers:{...oC},options:{},indexStack:[],handle:void 0};VI(n,t),n.options.tightDefinitions&&n.join.push(Fbe),n.handle=D_e("type",{invalid:Rbe,unknown:Dbe,handlers:n.handlers});let o=n.handle(e,void 0,n,{before:`
109 `,after:`
110 `,now:{line:1,column:1},lineShift:0});return o&&o.charCodeAt(o.length-1)!==10&&o.charCodeAt(o.length-1)!==13&&(o+=`
111 `),o;function r(s){return n.stack.push(s),i;function i(){n.stack.pop()}}}function Rbe(e){throw new Error("Cannot handle value `"+e+"`, expected node")}function Dbe(e){const t=e;throw new Error("Cannot handle unknown node `"+t.type+"`")}function Fbe(e,t){if(e.type==="definition"&&e.type===t.type)return 0}function Vbe(e,t){return xbe(e,this,t)}function Bbe(e,t){return Mbe(e,this,t)}function zbe(e,t){return Abe(this,e,t)}function Hb(e){const t=this;t.compiler=n;function n(o){return Lbe(o,{...t.data("settings"),...e,extensions:t.data("toMarkdownExtensions")||[]})}}function SS(e){if(e)throw e}var h1=Object.prototype.hasOwnProperty,eA=Object.prototype.toString,$S=Object.defineProperty,ES=Object.getOwnPropertyDescriptor,xS=function(t){return typeof Array.isArray=="function"?Array.isArray(t):eA.call(t)==="[object Array]"},MS=function(t){if(!t||eA.call(t)!=="[object Object]")return!1;var n=h1.call(t,"constructor"),o=t.constructor&&t.constructor.prototype&&h1.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!o)return!1;var r;for(r in t);return typeof r>"u"||h1.call(t,r)},TS=function(t,n){$S&&n.name==="__proto__"?$S(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},OS=function(t,n){if(n==="__proto__")if(h1.call(t,n)){if(ES)return ES(t,n).value}else return;return t[n]},jbe=function e(){var t,n,o,r,s,i,l=arguments[0],a=1,u=arguments.length,c=!1;for(typeof l=="boolean"&&(c=l,l=arguments[1]||{},a=2),(l==null||typeof l!="object"&&typeof l!="function")&&(l={});a<u;++a)if(t=arguments[a],t!=null)for(n in t)o=OS(l,n),r=OS(t,n),l!==r&&(c&&r&&(MS(r)||(s=xS(r)))?(s?(s=!1,i=o&&xS(o)?o:[]):i=o&&MS(o)?o:{},TS(l,{name:n,newValue:e(c,i,r)})):typeof r<"u"&&TS(l,{name:n,newValue:r}));return l};const _y=_o(jbe);function Ub(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function Hbe(){const e=[],t={run:n,use:o};return t;function n(...r){let s=-1;const i=r.pop();if(typeof i!="function")throw new TypeError("Expected function as last argument, not "+i);l(null,...r);function l(a,...u){const c=e[++s];let d=-1;if(a){i(a);return}for(;++d<r.length;)(u[d]===null||u[d]===void 0)&&(u[d]=r[d]);r=u,c?Ube(c,l)(...u):i(null,...u)}}function o(r){if(typeof r!="function")throw new TypeError("Expected `middelware` to be a function, not "+r);return e.push(r),t}}function Ube(e,t){let n;return o;function o(...i){const l=e.length>i.length;let a;l&&i.push(r);try{a=e.apply(this,i)}catch(u){const c=u;if(l&&n)throw c;return r(c)}l||(a&&a.then&&typeof a.then=="function"?a.then(s,r):a instanceof Error?r(a):s(a))}function r(i,...l){n||(n=!0,t(i,...l))}function s(i){r(null,i)}}class Qo extends Error{constructor(t,n,o){super(),typeof n=="string"&&(o=n,n=void 0);let r="",s={},i=!1;if(n&&("line"in n&&"column"in n?s={place:n}:"start"in n&&"end"in n?s={place:n}:"type"in n?s={ancestors:[n],place:n.position}:s={...n}),typeof t=="string"?r=t:!s.cause&&t&&(i=!0,r=t.message,s.cause=t),!s.ruleId&&!s.source&&typeof o=="string"){const a=o.indexOf(":");a===-1?s.ruleId=o:(s.source=o.slice(0,a),s.ruleId=o.slice(a+1))}if(!s.place&&s.ancestors&&s.ancestors){const a=s.ancestors[s.ancestors.length-1];a&&(s.place=a.position)}const l=s.place&&"start"in s.place?s.place.start:s.place;this.ancestors=s.ancestors||void 0,this.cause=s.cause||void 0,this.column=l?l.column:void 0,this.fatal=void 0,this.file,this.message=r,this.line=l?l.line:void 0,this.name=ep(s.place)||"1:1",this.place=s.place||void 0,this.reason=this.message,this.ruleId=s.ruleId||void 0,this.source=s.source||void 0,this.stack=i&&s.cause&&typeof s.cause.stack=="string"?s.cause.stack:"",this.actual,this.expected,this.note,this.url}}Qo.prototype.file="";Qo.prototype.name="";Qo.prototype.reason="";Qo.prototype.message="";Qo.prototype.stack="";Qo.prototype.column=void 0;Qo.prototype.line=void 0;Qo.prototype.ancestors=void 0;Qo.prototype.cause=void 0;Qo.prototype.fatal=void 0;Qo.prototype.place=void 0;Qo.prototype.ruleId=void 0;Qo.prototype.source=void 0;const Ls={basename:Wbe,dirname:Kbe,extname:qbe,join:Gbe,sep:"/"};function Wbe(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');Eh(e);let n=0,o=-1,r=e.length,s;if(t===void 0||t.length===0||t.length>e.length){for(;r--;)if(e.codePointAt(r)===47){if(s){n=r+1;break}}else o<0&&(s=!0,o=r+1);return o<0?"":e.slice(n,o)}if(t===e)return"";let i=-1,l=t.length-1;for(;r--;)if(e.codePointAt(r)===47){if(s){n=r+1;break}}else i<0&&(s=!0,i=r+1),l>-1&&(e.codePointAt(r)===t.codePointAt(l--)?l<0&&(o=r):(l=-1,o=i));return n===o?o=i:o<0&&(o=e.length),e.slice(n,o)}function Kbe(e){if(Eh(e),e.length===0)return".";let t=-1,n=e.length,o;for(;--n;)if(e.codePointAt(n)===47){if(o){t=n;break}}else o||(o=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function qbe(e){Eh(e);let t=e.length,n=-1,o=0,r=-1,s=0,i;for(;t--;){const l=e.codePointAt(t);if(l===47){if(i){o=t+1;break}continue}n<0&&(i=!0,n=t+1),l===46?r<0?r=t:s!==1&&(s=1):r>-1&&(s=-1)}return r<0||n<0||s===0||s===1&&r===n-1&&r===o+1?"":e.slice(r,n)}function Gbe(...e){let t=-1,n;for(;++t<e.length;)Eh(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":Ybe(n)}function Ybe(e){Eh(e);const t=e.codePointAt(0)===47;let n=Zbe(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function Zbe(e,t){let n="",o=0,r=-1,s=0,i=-1,l,a;for(;++i<=e.length;){if(i<e.length)l=e.codePointAt(i);else{if(l===47)break;l=47}if(l===47){if(!(r===i-1||s===1))if(r!==i-1&&s===2){if(n.length<2||o!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(a=n.lastIndexOf("/"),a!==n.length-1){a<0?(n="",o=0):(n=n.slice(0,a),o=n.length-1-n.lastIndexOf("/")),r=i,s=0;continue}}else if(n.length>0){n="",o=0,r=i,s=0;continue}}t&&(n=n.length>0?n+"/..":"..",o=2)}else n.length>0?n+="/"+e.slice(r+1,i):n=e.slice(r+1,i),o=i-r-1;r=i,s=0}else l===46&&s>-1?s++:s=-1}return n}function Eh(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const Jbe={cwd:Xbe};function Xbe(){return"/"}function Wb(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function Qbe(e){if(typeof e=="string")e=new URL(e);else if(!Wb(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return e2e(e)}function e2e(e){if(e.hostname!==""){const o=new TypeError('File URL host must be "localhost" or empty on darwin');throw o.code="ERR_INVALID_FILE_URL_HOST",o}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){const o=t.codePointAt(n+2);if(o===70||o===102){const r=new TypeError("File URL path must not include encoded / characters");throw r.code="ERR_INVALID_FILE_URL_PATH",r}}return decodeURIComponent(t)}const by=["history","path","basename","stem","extname","dirname"];class t2e{constructor(t){let n;t?Wb(t)?n={path:t}:typeof t=="string"||n2e(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":Jbe.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let o=-1;for(;++o<by.length;){const s=by[o];s in n&&n[s]!==void 0&&n[s]!==null&&(this[s]=s==="history"?[...n[s]]:n[s])}let r;for(r in n)by.includes(r)||(this[r]=n[r])}get basename(){return typeof this.path=="string"?Ls.basename(this.path):void 0}set basename(t){Cy(t,"basename"),wy(t,"basename"),this.path=Ls.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?Ls.dirname(this.path):void 0}set dirname(t){IS(this.basename,"dirname"),this.path=Ls.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?Ls.extname(this.path):void 0}set extname(t){if(wy(t,"extname"),IS(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Ls.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){Wb(t)&&(t=Qbe(t)),Cy(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?Ls.basename(this.path,this.extname):void 0}set stem(t){Cy(t,"stem"),wy(t,"stem"),this.path=Ls.join(this.dirname||"",t+(this.extname||""))}fail(t,n,o){const r=this.message(t,n,o);throw r.fatal=!0,r}info(t,n,o){const r=this.message(t,n,o);return r.fatal=void 0,r}message(t,n,o){const r=new Qo(t,n,o);return this.path&&(r.name=this.path+":"+r.name,r.file=this.path),r.fatal=!1,this.messages.push(r),r}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function wy(e,t){if(e&&e.includes(Ls.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+Ls.sep+"`")}function Cy(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function IS(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function n2e(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const o2e=function(e){const o=this.constructor.prototype,r=o[e],s=function(){return r.apply(s,arguments)};return Object.setPrototypeOf(s,o),s},r2e={}.hasOwnProperty;class rC extends o2e{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=Hbe()}copy(){const t=new rC;let n=-1;for(;++n<this.attachers.length;){const o=this.attachers[n];t.use(...o)}return t.data(_y(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?($y("data",this.frozen),this.namespace[t]=n,this):r2e.call(this.namespace,t)&&this.namespace[t]||void 0:t?($y("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[n,...o]=this.attachers[this.freezeIndex];if(o[0]===!1)continue;o[0]===!0&&(o[0]=void 0);const r=n.call(t,...o);typeof r=="function"&&this.transformers.use(r)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const n=Cm(t),o=this.parser||this.Parser;return ky("parse",o),o(String(n),n)}process(t,n){const o=this;return this.freeze(),ky("process",this.parser||this.Parser),Sy("process",this.compiler||this.Compiler),n?r(void 0,n):new Promise(r);function r(s,i){const l=Cm(t),a=o.parse(l);o.run(a,l,function(c,d,f){if(c||!d||!f)return u(c);const p=d,h=o.stringify(p,f);i2e(h)?f.value=h:f.result=h,u(c,f)});function u(c,d){c||!d?i(c):s?s(d):n(void 0,d)}}}processSync(t){let n=!1,o;return this.freeze(),ky("processSync",this.parser||this.Parser),Sy("processSync",this.compiler||this.Compiler),this.process(t,r),NS("processSync","process",n),o;function r(s,i){n=!0,SS(s),o=i}}run(t,n,o){AS(t),this.freeze();const r=this.transformers;return!o&&typeof n=="function"&&(o=n,n=void 0),o?s(void 0,o):new Promise(s);function s(i,l){const a=Cm(n);r.run(t,a,u);function u(c,d,f){const p=d||t;c?l(c):i?i(p):o(void 0,p,f)}}}runSync(t,n){let o=!1,r;return this.run(t,n,s),NS("runSync","run",o),r;function s(i,l){SS(i),r=l,o=!0}}stringify(t,n){this.freeze();const o=Cm(n),r=this.compiler||this.Compiler;return Sy("stringify",r),AS(t),r(t,o)}use(t,...n){const o=this.attachers,r=this.namespace;if($y("use",this.frozen),t!=null)if(typeof t=="function")a(t,n);else if(typeof t=="object")Array.isArray(t)?l(t):i(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function s(u){if(typeof u=="function")a(u,[]);else if(typeof u=="object")if(Array.isArray(u)){const[c,...d]=u;a(c,d)}else i(u);else throw new TypeError("Expected usable value, not `"+u+"`")}function i(u){if(!("plugins"in u)&&!("settings"in u))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");l(u.plugins),u.settings&&(r.settings=_y(!0,r.settings,u.settings))}function l(u){let c=-1;if(u!=null)if(Array.isArray(u))for(;++c<u.length;){const d=u[c];s(d)}else throw new TypeError("Expected a list of plugins, not `"+u+"`")}function a(u,c){let d=-1,f=-1;for(;++d<o.length;)if(o[d][0]===u){f=d;break}if(f===-1)o.push([u,...c]);else if(c.length>0){let[p,...h]=c;const m=o[f][1];Ub(m)&&Ub(p)&&(p=_y(!0,m,p)),o[f]=[u,p,...h]}}}}const Kb=new rC().freeze();function ky(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Sy(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function $y(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function AS(e){if(!Ub(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function NS(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function Cm(e){return s2e(e)?e:new t2e(e)}function s2e(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function i2e(e){return typeof e=="string"||l2e(e)}function l2e(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}var tA=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},It=(e,t,n)=>(tA(e,t,"read from private field"),n?n.call(e):t.get(e)),An=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},fn=(e,t,n,o)=>(tA(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n);let nA=class{},oA=class{constructor(){this.elements=[],this.size=()=>this.elements.length,this.top=()=>this.elements.at(-1),this.push=t=>{var n;(n=this.top())==null||n.push(t)},this.open=t=>{this.elements.push(t)},this.close=()=>{const t=this.elements.pop();if(!t)throw tI();return t}}},a2e=class rA extends nA{constructor(t,n,o){super(),this.type=t,this.content=n,this.attrs=o}push(t,...n){this.content.push(t,...n)}pop(){return this.content.pop()}static create(t,n,o){return new rA(t,n,o)}};var Is,lf,m1,g1,v1,af,uf;const qb=class extends oA{constructor(t){super(),An(this,Is,void 0),An(this,lf,void 0),An(this,m1,void 0),An(this,g1,void 0),An(this,v1,void 0),An(this,af,void 0),An(this,uf,void 0),fn(this,Is,Yt.none),fn(this,lf,n=>n.isText),fn(this,m1,(n,o)=>{if(It(this,lf).call(this,n)&&It(this,lf).call(this,o)&&Yt.sameSet(n.marks,o.marks))return this.schema.text(n.text+o.text,n.marks)}),fn(this,g1,n=>{const o=Object.values({...this.schema.nodes,...this.schema.marks}).find(r=>r.spec.parseMarkdown.match(n));if(!o)throw eve(n);return o}),fn(this,v1,n=>{const o=It(this,g1).call(this,n);o.spec.parseMarkdown.runner(this,n,o)}),this.injectRoot=(n,o,r)=>(this.openNode(o,r),this.next(n.children),this),this.openNode=(n,o)=>(this.open(a2e.create(n,[],o)),this),fn(this,af,()=>{fn(this,Is,Yt.none);const n=this.close();return It(this,uf).call(this,n.type,n.attrs,n.content)}),this.closeNode=()=>(It(this,af).call(this),this),fn(this,uf,(n,o,r)=>{const s=n.createAndFill(o,r,It(this,Is));if(!s)throw Q0e(n,o,r);return this.push(s),s}),this.addNode=(n,o,r)=>(It(this,uf).call(this,n,o,r),this),this.openMark=(n,o)=>{const r=n.create(o);return fn(this,Is,r.addToSet(It(this,Is))),this},this.closeMark=n=>(fn(this,Is,n.removeFromSet(It(this,Is))),this),this.addText=n=>{const o=this.top();if(!o)throw tI();const r=o.pop(),s=this.schema.text(n,It(this,Is));if(!r)return o.push(s),this;const i=It(this,m1).call(this,r,s);return i?(o.push(i),this):(o.push(r,s),this)},this.build=()=>{let n;do n=It(this,af).call(this);while(this.size());return n},this.next=(n=[])=>([n].flat().forEach(o=>It(this,v1).call(this,o)),this),this.toDoc=()=>this.build(),this.run=(n,o)=>{const r=n.runSync(n.parse(o),o);return this.next(r),this},this.schema=t}};Is=new WeakMap,lf=new WeakMap,m1=new WeakMap,g1=new WeakMap,v1=new WeakMap,af=new WeakMap,uf=new WeakMap,qb.create=(e,t)=>{const n=new qb(e);return o=>(n.run(t,o),n.toDoc())};let u2e=qb;const Gb=class extends nA{constructor(t,n,o,r={}){super(),this.type=t,this.children=n,this.value=o,this.props=r,this.push=(s,...i)=>{this.children||(this.children=[]),this.children.push(s,...i)},this.pop=()=>{var s;return(s=this.children)==null?void 0:s.pop()}}};Gb.create=(e,t,n,o={})=>new Gb(e,t,n,o);let PS=Gb;const c2e=e=>Object.prototype.hasOwnProperty.call(e,"size");var hi,cf,y1,_1,df,b1,ff,w1,C1,Xu,wa,k1,pf;const Yb=class extends oA{constructor(t){super(),An(this,hi,void 0),An(this,cf,void 0),An(this,y1,void 0),An(this,_1,void 0),An(this,df,void 0),An(this,b1,void 0),An(this,ff,void 0),An(this,w1,void 0),An(this,C1,void 0),An(this,Xu,void 0),An(this,wa,void 0),An(this,k1,void 0),An(this,pf,void 0),fn(this,hi,Yt.none),fn(this,cf,n=>{const o=Object.values({...this.schema.nodes,...this.schema.marks}).find(r=>r.spec.toMarkdown.match(n));if(!o)throw tve(n.type);return o}),fn(this,y1,n=>It(this,cf).call(this,n).spec.toMarkdown.runner(this,n)),fn(this,_1,(n,o)=>It(this,cf).call(this,n).spec.toMarkdown.runner(this,n,o)),fn(this,df,n=>{const{marks:o}=n,r=s=>s.type.spec.priority??50;[...o].sort((s,i)=>r(s)-r(i)).every(s=>!It(this,_1).call(this,s,n))&&It(this,y1).call(this,n),o.forEach(s=>It(this,pf).call(this,s))}),fn(this,b1,(n,o)=>{var r;if(n.type===o||((r=n.children)==null?void 0:r.length)!==1)return n;const s=u=>{var c;if(u.type===o)return u;if(((c=u.children)==null?void 0:c.length)!==1)return null;const[d]=u.children;return d?s(d):null},i=s(n);if(!i)return n;const l=i.children?[...i.children]:void 0,a={...n,children:l};return a.children=l,i.children=[a],i}),fn(this,ff,n=>{const{children:o}=n;return o&&(n.children=o.reduce((r,s,i)=>{if(i===0)return[s];const l=r.at(-1);if(l&&l.isMark&&s.isMark){s=It(this,b1).call(this,s,l.type);const{children:a,...u}=s,{children:c,...d}=l;if(s.type===l.type&&a&&c&&JSON.stringify(u)===JSON.stringify(d)){const f={...d,children:[...c,...a]};return r.slice(0,-1).concat(It(this,ff).call(this,f))}}return r.concat(s)},[])),n}),fn(this,w1,n=>{const o={...n.props,type:n.type};return n.children&&(o.children=n.children),n.value&&(o.value=n.value),o}),this.openNode=(n,o,r)=>(this.open(PS.create(n,void 0,o,r)),this),fn(this,C1,(n,o)=>{let r="",s="";const i=n.children;let l=-1,a=-1;const u=d=>{d&&d.forEach((f,p)=>{f.type==="text"&&f.value&&(l<0&&(l=p),a=p)})};if(i){u(i);const d=i==null?void 0:i[a],f=i==null?void 0:i[l];d&&d.value.endsWith(" ")&&(s=d.value.match(/ +$/)[0],d.value=d.value.trimEnd()),f&&f.value.startsWith(" ")&&(r=f.value.match(/^ +/)[0],f.value=f.value.trimStart())}r.length&&It(this,wa).call(this,"text",void 0,r);const c=o();return s.length&&It(this,wa).call(this,"text",void 0,s),c}),fn(this,Xu,(n=!1)=>{const o=this.close(),r=()=>It(this,wa).call(this,o.type,o.children,o.value,o.props);return n?It(this,C1).call(this,o,r):r()}),this.closeNode=()=>(It(this,Xu).call(this),this),fn(this,wa,(n,o,r,s)=>{const i=PS.create(n,o,r,s),l=It(this,ff).call(this,It(this,w1).call(this,i));return this.push(l),l}),this.addNode=(n,o,r,s)=>(It(this,wa).call(this,n,o,r,s),this),fn(this,k1,(n,o,r,s)=>n.isInSet(It(this,hi))?this:(fn(this,hi,n.addToSet(It(this,hi))),this.openNode(o,r,{...s,isMark:!0}))),fn(this,pf,n=>{n.isInSet(It(this,hi))&&(fn(this,hi,n.type.removeFromSet(It(this,hi))),It(this,Xu).call(this,!0))}),this.withMark=(n,o,r,s)=>(It(this,k1).call(this,n,o,r,s),this),this.closeMark=n=>(It(this,pf).call(this,n),this),this.build=()=>{let n=null;do n=It(this,Xu).call(this);while(this.size());return n},this.next=n=>c2e(n)?(n.forEach(o=>{It(this,df).call(this,o)}),this):(It(this,df).call(this,n),this),this.toString=n=>n.stringify(this.build()),this.run=n=>(this.next(n),this),this.schema=t}};hi=new WeakMap,cf=new WeakMap,y1=new WeakMap,_1=new WeakMap,df=new WeakMap,b1=new WeakMap,ff=new WeakMap,w1=new WeakMap,C1=new WeakMap,Xu=new WeakMap,wa=new WeakMap,k1=new WeakMap,pf=new WeakMap,Yb.create=(e,t)=>{const n=new Yb(e);return o=>(n.run(o),n.toString(t))};let d2e=Yb;const sA=65535,iA=Math.pow(2,16);function f2e(e,t){return e+t*iA}function LS(e){return e&sA}function p2e(e){return(e-(e&sA))/iA}const lA=1,aA=2,S1=4,uA=8;class Zb{constructor(t,n,o){this.pos=t,this.delInfo=n,this.recover=o}get deleted(){return(this.delInfo&uA)>0}get deletedBefore(){return(this.delInfo&(lA|S1))>0}get deletedAfter(){return(this.delInfo&(aA|S1))>0}get deletedAcross(){return(this.delInfo&S1)>0}}class cr{constructor(t,n=!1){if(this.ranges=t,this.inverted=n,!t.length&&cr.empty)return cr.empty}recover(t){let n=0,o=LS(t);if(!this.inverted)for(let r=0;r<o;r++)n+=this.ranges[r*3+2]-this.ranges[r*3+1];return this.ranges[o*3]+n+p2e(t)}mapResult(t,n=1){return this._map(t,n,!1)}map(t,n=1){return this._map(t,n,!0)}_map(t,n,o){let r=0,s=this.inverted?2:1,i=this.inverted?1:2;for(let l=0;l<this.ranges.length;l+=3){let a=this.ranges[l]-(this.inverted?r:0);if(a>t)break;let u=this.ranges[l+s],c=this.ranges[l+i],d=a+u;if(t<=d){let f=u?t==a?-1:t==d?1:n:n,p=a+r+(f<0?0:c);if(o)return p;let h=t==(n<0?a:d)?null:f2e(l/3,t-a),m=t==a?aA:t==d?lA:S1;return(n<0?t!=a:t!=d)&&(m|=uA),new Zb(p,m,h)}r+=c-u}return o?t+r:new Zb(t+r,0,null)}touches(t,n){let o=0,r=LS(n),s=this.inverted?2:1,i=this.inverted?1:2;for(let l=0;l<this.ranges.length;l+=3){let a=this.ranges[l]-(this.inverted?o:0);if(a>t)break;let u=this.ranges[l+s],c=a+u;if(t<=c&&l==r*3)return!0;o+=this.ranges[l+i]-u}return!1}forEach(t){let n=this.inverted?2:1,o=this.inverted?1:2;for(let r=0,s=0;r<this.ranges.length;r+=3){let i=this.ranges[r],l=i-(this.inverted?s:0),a=i+(this.inverted?0:s),u=this.ranges[r+n],c=this.ranges[r+o];t(l,l+u,a,a+c),s+=c-u}}invert(){return new cr(this.ranges,!this.inverted)}toString(){return(this.inverted?"-":"")+JSON.stringify(this.ranges)}static offset(t){return t==0?cr.empty:new cr(t<0?[0,-t,0]:[0,0,t])}}cr.empty=new cr([]);class Ec{constructor(t=[],n,o=0,r=t.length){this.maps=t,this.mirror=n,this.from=o,this.to=r}slice(t=0,n=this.maps.length){return new Ec(this.maps,this.mirror,t,n)}copy(){return new Ec(this.maps.slice(),this.mirror&&this.mirror.slice(),this.from,this.to)}appendMap(t,n){this.to=this.maps.push(t),n!=null&&this.setMirror(this.maps.length-1,n)}appendMapping(t){for(let n=0,o=this.maps.length;n<t.maps.length;n++){let r=t.getMirror(n);this.appendMap(t.maps[n],r!=null&&r<n?o+r:void 0)}}getMirror(t){if(this.mirror){for(let n=0;n<this.mirror.length;n++)if(this.mirror[n]==t)return this.mirror[n+(n%2?-1:1)]}}setMirror(t,n){this.mirror||(this.mirror=[]),this.mirror.push(t,n)}appendMappingInverted(t){for(let n=t.maps.length-1,o=this.maps.length+t.maps.length;n>=0;n--){let r=t.getMirror(n);this.appendMap(t.maps[n].invert(),r!=null&&r>n?o-r-1:void 0)}}invert(){let t=new Ec;return t.appendMappingInverted(this),t}map(t,n=1){if(this.mirror)return this._map(t,n,!0);for(let o=this.from;o<this.to;o++)t=this.maps[o].map(t,n);return t}mapResult(t,n=1){return this._map(t,n,!1)}_map(t,n,o){let r=0;for(let s=this.from;s<this.to;s++){let i=this.maps[s],l=i.mapResult(t,n);if(l.recover!=null){let a=this.getMirror(s);if(a!=null&&a>s&&a<this.to){s=a,t=this.maps[a].recover(l.recover);continue}}r|=l.delInfo,t=l.pos}return o?t:new Zb(t,r,null)}}const Ey=Object.create(null);class bo{getMap(){return cr.empty}merge(t){return null}static fromJSON(t,n){if(!n||!n.stepType)throw new RangeError("Invalid input for Step.fromJSON");let o=Ey[n.stepType];if(!o)throw new RangeError(`No step type ${n.stepType} defined`);return o.fromJSON(t,n)}static jsonID(t,n){if(t in Ey)throw new RangeError("Duplicate use of step JSON ID "+t);return Ey[t]=n,n.prototype.jsonID=t,n}}class Rn{constructor(t,n){this.doc=t,this.failed=n}static ok(t){return new Rn(t,null)}static fail(t){return new Rn(null,t)}static fromReplace(t,n,o,r){try{return Rn.ok(t.replace(n,o,r))}catch(s){if(s instanceof jg)return Rn.fail(s.message);throw s}}}function sC(e,t,n){let o=[];for(let r=0;r<e.childCount;r++){let s=e.child(r);s.content.size&&(s=s.copy(sC(s.content,t,s))),s.isInline&&(s=t(s,n,r)),o.push(s)}return Ue.fromArray(o)}class Si extends bo{constructor(t,n,o){super(),this.from=t,this.to=n,this.mark=o}apply(t){let n=t.slice(this.from,this.to),o=t.resolve(this.from),r=o.node(o.sharedDepth(this.to)),s=new Ye(sC(n.content,(i,l)=>!i.isAtom||!l.type.allowsMarkType(this.mark.type)?i:i.mark(this.mark.addToSet(i.marks)),r),n.openStart,n.openEnd);return Rn.fromReplace(t,this.from,this.to,s)}invert(){return new zs(this.from,this.to,this.mark)}map(t){let n=t.mapResult(this.from,1),o=t.mapResult(this.to,-1);return n.deleted&&o.deleted||n.pos>=o.pos?null:new Si(n.pos,o.pos,this.mark)}merge(t){return t instanceof Si&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new Si(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark):null}toJSON(){return{stepType:"addMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(t,n){if(typeof n.from!="number"||typeof n.to!="number")throw new RangeError("Invalid input for AddMarkStep.fromJSON");return new Si(n.from,n.to,t.markFromJSON(n.mark))}}bo.jsonID("addMark",Si);class zs extends bo{constructor(t,n,o){super(),this.from=t,this.to=n,this.mark=o}apply(t){let n=t.slice(this.from,this.to),o=new Ye(sC(n.content,r=>r.mark(this.mark.removeFromSet(r.marks)),t),n.openStart,n.openEnd);return Rn.fromReplace(t,this.from,this.to,o)}invert(){return new Si(this.from,this.to,this.mark)}map(t){let n=t.mapResult(this.from,1),o=t.mapResult(this.to,-1);return n.deleted&&o.deleted||n.pos>=o.pos?null:new zs(n.pos,o.pos,this.mark)}merge(t){return t instanceof zs&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new zs(Math.min(this.from,t.from),Math.max(this.to,t.to),this.mark):null}toJSON(){return{stepType:"removeMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(t,n){if(typeof n.from!="number"||typeof n.to!="number")throw new RangeError("Invalid input for RemoveMarkStep.fromJSON");return new zs(n.from,n.to,t.markFromJSON(n.mark))}}bo.jsonID("removeMark",zs);class Ol extends bo{constructor(t,n){super(),this.pos=t,this.mark=n}apply(t){let n=t.nodeAt(this.pos);if(!n)return Rn.fail("No node at mark step's position");let o=n.type.create(n.attrs,null,this.mark.addToSet(n.marks));return Rn.fromReplace(t,this.pos,this.pos+1,new Ye(Ue.from(o),0,n.isLeaf?0:1))}invert(t){let n=t.nodeAt(this.pos);if(n){let o=this.mark.addToSet(n.marks);if(o.length==n.marks.length){for(let r=0;r<n.marks.length;r++)if(!n.marks[r].isInSet(o))return new Ol(this.pos,n.marks[r]);return new Ol(this.pos,this.mark)}}return new cd(this.pos,this.mark)}map(t){let n=t.mapResult(this.pos,1);return n.deletedAfter?null:new Ol(n.pos,this.mark)}toJSON(){return{stepType:"addNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(t,n){if(typeof n.pos!="number")throw new RangeError("Invalid input for AddNodeMarkStep.fromJSON");return new Ol(n.pos,t.markFromJSON(n.mark))}}bo.jsonID("addNodeMark",Ol);class cd extends bo{constructor(t,n){super(),this.pos=t,this.mark=n}apply(t){let n=t.nodeAt(this.pos);if(!n)return Rn.fail("No node at mark step's position");let o=n.type.create(n.attrs,null,this.mark.removeFromSet(n.marks));return Rn.fromReplace(t,this.pos,this.pos+1,new Ye(Ue.from(o),0,n.isLeaf?0:1))}invert(t){let n=t.nodeAt(this.pos);return!n||!this.mark.isInSet(n.marks)?this:new Ol(this.pos,this.mark)}map(t){let n=t.mapResult(this.pos,1);return n.deletedAfter?null:new cd(n.pos,this.mark)}toJSON(){return{stepType:"removeNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(t,n){if(typeof n.pos!="number")throw new RangeError("Invalid input for RemoveNodeMarkStep.fromJSON");return new cd(n.pos,t.markFromJSON(n.mark))}}bo.jsonID("removeNodeMark",cd);class eo extends bo{constructor(t,n,o,r=!1){super(),this.from=t,this.to=n,this.slice=o,this.structure=r}apply(t){return this.structure&&Jb(t,this.from,this.to)?Rn.fail("Structure replace would overwrite content"):Rn.fromReplace(t,this.from,this.to,this.slice)}getMap(){return new cr([this.from,this.to-this.from,this.slice.size])}invert(t){return new eo(this.from,this.from+this.slice.size,t.slice(this.from,this.to))}map(t){let n=t.mapResult(this.from,1),o=t.mapResult(this.to,-1);return n.deletedAcross&&o.deletedAcross?null:new eo(n.pos,Math.max(n.pos,o.pos),this.slice)}merge(t){if(!(t instanceof eo)||t.structure||this.structure)return null;if(this.from+this.slice.size==t.from&&!this.slice.openEnd&&!t.slice.openStart){let n=this.slice.size+t.slice.size==0?Ye.empty:new Ye(this.slice.content.append(t.slice.content),this.slice.openStart,t.slice.openEnd);return new eo(this.from,this.to+(t.to-t.from),n,this.structure)}else if(t.to==this.from&&!this.slice.openStart&&!t.slice.openEnd){let n=this.slice.size+t.slice.size==0?Ye.empty:new Ye(t.slice.content.append(this.slice.content),t.slice.openStart,this.slice.openEnd);return new eo(t.from,this.to,n,this.structure)}else return null}toJSON(){let t={stepType:"replace",from:this.from,to:this.to};return this.slice.size&&(t.slice=this.slice.toJSON()),this.structure&&(t.structure=!0),t}static fromJSON(t,n){if(typeof n.from!="number"||typeof n.to!="number")throw new RangeError("Invalid input for ReplaceStep.fromJSON");return new eo(n.from,n.to,Ye.fromJSON(t,n.slice),!!n.structure)}}bo.jsonID("replace",eo);class vo extends bo{constructor(t,n,o,r,s,i,l=!1){super(),this.from=t,this.to=n,this.gapFrom=o,this.gapTo=r,this.slice=s,this.insert=i,this.structure=l}apply(t){if(this.structure&&(Jb(t,this.from,this.gapFrom)||Jb(t,this.gapTo,this.to)))return Rn.fail("Structure gap-replace would overwrite content");let n=t.slice(this.gapFrom,this.gapTo);if(n.openStart||n.openEnd)return Rn.fail("Gap is not a flat range");let o=this.slice.insertAt(this.insert,n.content);return o?Rn.fromReplace(t,this.from,this.to,o):Rn.fail("Content does not fit in gap")}getMap(){return new cr([this.from,this.gapFrom-this.from,this.insert,this.gapTo,this.to-this.gapTo,this.slice.size-this.insert])}invert(t){let n=this.gapTo-this.gapFrom;return new vo(this.from,this.from+this.slice.size+n,this.from+this.insert,this.from+this.insert+n,t.slice(this.from,this.to).removeBetween(this.gapFrom-this.from,this.gapTo-this.from),this.gapFrom-this.from,this.structure)}map(t){let n=t.mapResult(this.from,1),o=t.mapResult(this.to,-1),r=this.from==this.gapFrom?n.pos:t.map(this.gapFrom,-1),s=this.to==this.gapTo?o.pos:t.map(this.gapTo,1);return n.deletedAcross&&o.deletedAcross||r<n.pos||s>o.pos?null:new vo(n.pos,o.pos,r,s,this.slice,this.insert,this.structure)}toJSON(){let t={stepType:"replaceAround",from:this.from,to:this.to,gapFrom:this.gapFrom,gapTo:this.gapTo,insert:this.insert};return this.slice.size&&(t.slice=this.slice.toJSON()),this.structure&&(t.structure=!0),t}static fromJSON(t,n){if(typeof n.from!="number"||typeof n.to!="number"||typeof n.gapFrom!="number"||typeof n.gapTo!="number"||typeof n.insert!="number")throw new RangeError("Invalid input for ReplaceAroundStep.fromJSON");return new vo(n.from,n.to,n.gapFrom,n.gapTo,Ye.fromJSON(t,n.slice),n.insert,!!n.structure)}}bo.jsonID("replaceAround",vo);function Jb(e,t,n){let o=e.resolve(t),r=n-t,s=o.depth;for(;r>0&&s>0&&o.indexAfter(s)==o.node(s).childCount;)s--,r--;if(r>0){let i=o.node(s).maybeChild(o.indexAfter(s));for(;r>0;){if(!i||i.isLeaf)return!0;i=i.firstChild,r--}}return!1}function h2e(e,t,n,o){let r=[],s=[],i,l;e.doc.nodesBetween(t,n,(a,u,c)=>{if(!a.isInline)return;let d=a.marks;if(!o.isInSet(d)&&c.type.allowsMarkType(o.type)){let f=Math.max(u,t),p=Math.min(u+a.nodeSize,n),h=o.addToSet(d);for(let m=0;m<d.length;m++)d[m].isInSet(h)||(i&&i.to==f&&i.mark.eq(d[m])?i.to=p:r.push(i=new zs(f,p,d[m])));l&&l.to==f?l.to=p:s.push(l=new Si(f,p,o))}}),r.forEach(a=>e.step(a)),s.forEach(a=>e.step(a))}function m2e(e,t,n,o){let r=[],s=0;e.doc.nodesBetween(t,n,(i,l)=>{if(!i.isInline)return;s++;let a=null;if(o instanceof Q0){let u=i.marks,c;for(;c=o.isInSet(u);)(a||(a=[])).push(c),u=c.removeFromSet(u)}else o?o.isInSet(i.marks)&&(a=[o]):a=i.marks;if(a&&a.length){let u=Math.min(l+i.nodeSize,n);for(let c=0;c<a.length;c++){let d=a[c],f;for(let p=0;p<r.length;p++){let h=r[p];h.step==s-1&&d.eq(r[p].style)&&(f=h)}f?(f.to=u,f.step=s):r.push({style:d,from:Math.max(l,t),to:u,step:s})}}}),r.forEach(i=>e.step(new zs(i.from,i.to,i.style)))}function cA(e,t,n,o=n.contentMatch,r=!0){let s=e.doc.nodeAt(t),i=[],l=t+1;for(let a=0;a<s.childCount;a++){let u=s.child(a),c=l+u.nodeSize,d=o.matchType(u.type);if(!d)i.push(new eo(l,c,Ye.empty));else{o=d;for(let f=0;f<u.marks.length;f++)n.allowsMarkType(u.marks[f].type)||e.step(new zs(l,c,u.marks[f]));if(r&&u.isText&&n.whitespace!="pre"){let f,p=/\r?\n|\r/g,h;for(;f=p.exec(u.text);)h||(h=new Ye(Ue.from(n.schema.text(" ",n.allowedMarks(u.marks))),0,0)),i.push(new eo(l+f.index,l+f.index+f[0].length,h))}}l=c}if(!o.validEnd){let a=o.fillBefore(Ue.empty,!0);e.replace(l,l,new Ye(a,0,0))}for(let a=i.length-1;a>=0;a--)e.step(i[a])}function g2e(e,t,n){return(t==0||e.canReplace(t,e.childCount))&&(n==e.childCount||e.canReplace(0,n))}function rv(e){let n=e.parent.content.cutByIndex(e.startIndex,e.endIndex);for(let o=e.depth;;--o){let r=e.$from.node(o),s=e.$from.index(o),i=e.$to.indexAfter(o);if(o<e.depth&&r.canReplace(s,i,n))return o;if(o==0||r.type.spec.isolating||!g2e(r,s,i))break}return null}function v2e(e,t,n){let{$from:o,$to:r,depth:s}=t,i=o.before(s+1),l=r.after(s+1),a=i,u=l,c=Ue.empty,d=0;for(let h=s,m=!1;h>n;h--)m||o.index(h)>0?(m=!0,c=Ue.from(o.node(h).copy(c)),d++):a--;let f=Ue.empty,p=0;for(let h=s,m=!1;h>n;h--)m||r.after(h+1)<r.end(h)?(m=!0,f=Ue.from(r.node(h).copy(f)),p++):u++;e.step(new vo(a,u,i,l,new Ye(c.append(f),d,p),c.size-d,!0))}function iC(e,t,n=null,o=e){let r=y2e(e,t),s=r&&_2e(o,t);return s?r.map(RS).concat({type:t,attrs:n}).concat(s.map(RS)):null}function RS(e){return{type:e,attrs:null}}function y2e(e,t){let{parent:n,startIndex:o,endIndex:r}=e,s=n.contentMatchAt(o).findWrapping(t);if(!s)return null;let i=s.length?s[0]:t;return n.canReplaceWith(o,r,i)?s:null}function _2e(e,t){let{parent:n,startIndex:o,endIndex:r}=e,s=n.child(o),i=t.contentMatch.findWrapping(s.type);if(!i)return null;let a=(i.length?i[i.length-1]:t).contentMatch;for(let u=o;a&&u<r;u++)a=a.matchType(n.child(u).type);return!a||!a.validEnd?null:i}function b2e(e,t,n){let o=Ue.empty;for(let i=n.length-1;i>=0;i--){if(o.size){let l=n[i].type.contentMatch.matchFragment(o);if(!l||!l.validEnd)throw new RangeError("Wrapper type given to Transform.wrap does not form valid content of its parent wrapper")}o=Ue.from(n[i].type.create(n[i].attrs,o))}let r=t.start,s=t.end;e.step(new vo(r,s,r,s,new Ye(o,0,0),n.length,!0))}function w2e(e,t,n,o,r){if(!o.isTextblock)throw new RangeError("Type given to setBlockType should be a textblock");let s=e.steps.length;e.doc.nodesBetween(t,n,(i,l)=>{let a=typeof r=="function"?r(i):r;if(i.isTextblock&&!i.hasMarkup(o,a)&&S2e(e.doc,e.mapping.slice(s).map(l),o)){let u=null;if(o.schema.linebreakReplacement){let p=o.whitespace=="pre",h=!!o.contentMatch.matchType(o.schema.linebreakReplacement);p&&!h?u=!1:!p&&h&&(u=!0)}u===!1&&k2e(e,i,l,s),cA(e,e.mapping.slice(s).map(l,1),o,void 0,u===null);let c=e.mapping.slice(s),d=c.map(l,1),f=c.map(l+i.nodeSize,1);return e.step(new vo(d,f,d+1,f-1,new Ye(Ue.from(o.create(a,null,i.marks)),0,0),1,!0)),u===!0&&C2e(e,i,l,s),!1}})}function C2e(e,t,n,o){t.forEach((r,s)=>{if(r.isText){let i,l=/\r?\n|\r/g;for(;i=l.exec(r.text);){let a=e.mapping.slice(o).map(n+1+s+i.index);e.replaceWith(a,a+1,t.type.schema.linebreakReplacement.create())}}})}function k2e(e,t,n,o){t.forEach((r,s)=>{if(r.type==r.type.schema.linebreakReplacement){let i=e.mapping.slice(o).map(n+1+s);e.replaceWith(i,i+1,t.type.schema.text(`
112 `))}})}function S2e(e,t,n){let o=e.resolve(t),r=o.index();return o.parent.canReplaceWith(r,r+1,n)}function $2e(e,t,n,o,r){let s=e.doc.nodeAt(t);if(!s)throw new RangeError("No node at given position");n||(n=s.type);let i=n.create(o,null,r||s.marks);if(s.isLeaf)return e.replaceWith(t,t+s.nodeSize,i);if(!n.validContent(s.content))throw new RangeError("Invalid content for node type "+n.name);e.step(new vo(t,t+s.nodeSize,t+1,t+s.nodeSize-1,new Ye(Ue.from(i),0,0),1,!0))}function tp(e,t,n=1,o){let r=e.resolve(t),s=r.depth-n,i=o&&o[o.length-1]||r.parent;if(s<0||r.parent.type.spec.isolating||!r.parent.canReplace(r.index(),r.parent.childCount)||!i.type.validContent(r.parent.content.cutByIndex(r.index(),r.parent.childCount)))return!1;for(let u=r.depth-1,c=n-2;u>s;u--,c--){let d=r.node(u),f=r.index(u);if(d.type.spec.isolating)return!1;let p=d.content.cutByIndex(f,d.childCount),h=o&&o[c+1];h&&(p=p.replaceChild(0,h.type.create(h.attrs)));let m=o&&o[c]||d;if(!d.canReplace(f+1,d.childCount)||!m.type.validContent(p))return!1}let l=r.indexAfter(s),a=o&&o[0];return r.node(s).canReplaceWith(l,l,a?a.type:r.node(s+1).type)}function E2e(e,t,n=1,o){let r=e.doc.resolve(t),s=Ue.empty,i=Ue.empty;for(let l=r.depth,a=r.depth-n,u=n-1;l>a;l--,u--){s=Ue.from(r.node(l).copy(s));let c=o&&o[u];i=Ue.from(c?c.type.create(c.attrs,i):r.node(l).copy(i))}e.step(new eo(t,t,new Ye(s.append(i),n,n),!0))}function sv(e,t){let n=e.resolve(t),o=n.index();return x2e(n.nodeBefore,n.nodeAfter)&&n.parent.canReplace(o,o+1)}function x2e(e,t){return!!(e&&t&&!e.isLeaf&&e.canAppend(t))}function M2e(e,t,n){let o=new eo(t-n,t+n,Ye.empty,!0);e.step(o)}function T2e(e,t,n){let o=e.resolve(t);if(o.parent.canReplaceWith(o.index(),o.index(),n))return t;if(o.parentOffset==0)for(let r=o.depth-1;r>=0;r--){let s=o.index(r);if(o.node(r).canReplaceWith(s,s,n))return o.before(r+1);if(s>0)return null}if(o.parentOffset==o.parent.content.size)for(let r=o.depth-1;r>=0;r--){let s=o.indexAfter(r);if(o.node(r).canReplaceWith(s,s,n))return o.after(r+1);if(s<o.node(r).childCount)return null}return null}function O2e(e,t,n){let o=e.resolve(t);if(!n.content.size)return t;let r=n.content;for(let s=0;s<n.openStart;s++)r=r.firstChild.content;for(let s=1;s<=(n.openStart==0&&n.size?2:1);s++)for(let i=o.depth;i>=0;i--){let l=i==o.depth?0:o.pos<=(o.start(i+1)+o.end(i+1))/2?-1:1,a=o.index(i)+(l>0?1:0),u=o.node(i),c=!1;if(s==1)c=u.canReplace(a,a,r);else{let d=u.contentMatchAt(a).findWrapping(r.firstChild.type);c=d&&u.canReplaceWith(a,a,d[0])}if(c)return l==0?o.pos:l<0?o.before(i+1):o.after(i+1)}return null}function lC(e,t,n=t,o=Ye.empty){if(t==n&&!o.size)return null;let r=e.resolve(t),s=e.resolve(n);return dA(r,s,o)?new eo(t,n,o):new I2e(r,s,o).fit()}function dA(e,t,n){return!n.openStart&&!n.openEnd&&e.start()==t.start()&&e.parent.canReplace(e.index(),t.index(),n.content)}class I2e{constructor(t,n,o){this.$from=t,this.$to=n,this.unplaced=o,this.frontier=[],this.placed=Ue.empty;for(let r=0;r<=t.depth;r++){let s=t.node(r);this.frontier.push({type:s.type,match:s.contentMatchAt(t.indexAfter(r))})}for(let r=t.depth;r>0;r--)this.placed=Ue.from(t.node(r).copy(this.placed))}get depth(){return this.frontier.length-1}fit(){for(;this.unplaced.size;){let u=this.findFittable();u?this.placeNodes(u):this.openMore()||this.dropNode()}let t=this.mustMoveInline(),n=this.placed.size-this.depth-this.$from.depth,o=this.$from,r=this.close(t<0?this.$to:o.doc.resolve(t));if(!r)return null;let s=this.placed,i=o.depth,l=r.depth;for(;i&&l&&s.childCount==1;)s=s.firstChild.content,i--,l--;let a=new Ye(s,i,l);return t>-1?new vo(o.pos,t,this.$to.pos,this.$to.end(),a,n):a.size||o.pos!=this.$to.pos?new eo(o.pos,r.pos,a):null}findFittable(){let t=this.unplaced.openStart;for(let n=this.unplaced.content,o=0,r=this.unplaced.openEnd;o<t;o++){let s=n.firstChild;if(n.childCount>1&&(r=0),s.type.spec.isolating&&r<=o){t=o;break}n=s.content}for(let n=1;n<=2;n++)for(let o=n==1?t:this.unplaced.openStart;o>=0;o--){let r,s=null;o?(s=xy(this.unplaced.content,o-1).firstChild,r=s.content):r=this.unplaced.content;let i=r.firstChild;for(let l=this.depth;l>=0;l--){let{type:a,match:u}=this.frontier[l],c,d=null;if(n==1&&(i?u.matchType(i.type)||(d=u.fillBefore(Ue.from(i),!1)):s&&a.compatibleContent(s.type)))return{sliceDepth:o,frontierDepth:l,parent:s,inject:d};if(n==2&&i&&(c=u.findWrapping(i.type)))return{sliceDepth:o,frontierDepth:l,parent:s,wrap:c};if(s&&u.matchType(s.type))break}}}openMore(){let{content:t,openStart:n,openEnd:o}=this.unplaced,r=xy(t,n);return!r.childCount||r.firstChild.isLeaf?!1:(this.unplaced=new Ye(t,n+1,Math.max(o,r.size+n>=t.size-o?n+1:0)),!0)}dropNode(){let{content:t,openStart:n,openEnd:o}=this.unplaced,r=xy(t,n);if(r.childCount<=1&&n>0){let s=t.size-n<=n+r.size;this.unplaced=new Ye(hf(t,n-1,1),n-1,s?n-1:o)}else this.unplaced=new Ye(hf(t,n,1),n,o)}placeNodes({sliceDepth:t,frontierDepth:n,parent:o,inject:r,wrap:s}){for(;this.depth>n;)this.closeFrontierNode();if(s)for(let m=0;m<s.length;m++)this.openFrontierNode(s[m]);let i=this.unplaced,l=o?o.content:i.content,a=i.openStart-t,u=0,c=[],{match:d,type:f}=this.frontier[n];if(r){for(let m=0;m<r.childCount;m++)c.push(r.child(m));d=d.matchFragment(r)}let p=l.size+t-(i.content.size-i.openEnd);for(;u<l.childCount;){let m=l.child(u),y=d.matchType(m.type);if(!y)break;u++,(u>1||a==0||m.content.size)&&(d=y,c.push(fA(m.mark(f.allowedMarks(m.marks)),u==1?a:0,u==l.childCount?p:-1)))}let h=u==l.childCount;h||(p=-1),this.placed=mf(this.placed,n,Ue.from(c)),this.frontier[n].match=d,h&&p<0&&o&&o.type==this.frontier[this.depth].type&&this.frontier.length>1&&this.closeFrontierNode();for(let m=0,y=l;m<p;m++){let v=y.lastChild;this.frontier.push({type:v.type,match:v.contentMatchAt(v.childCount)}),y=v.content}this.unplaced=h?t==0?Ye.empty:new Ye(hf(i.content,t-1,1),t-1,p<0?i.openEnd:t-1):new Ye(hf(i.content,t,u),i.openStart,i.openEnd)}mustMoveInline(){if(!this.$to.parent.isTextblock)return-1;let t=this.frontier[this.depth],n;if(!t.type.isTextblock||!My(this.$to,this.$to.depth,t.type,t.match,!1)||this.$to.depth==this.depth&&(n=this.findCloseLevel(this.$to))&&n.depth==this.depth)return-1;let{depth:o}=this.$to,r=this.$to.after(o);for(;o>1&&r==this.$to.end(--o);)++r;return r}findCloseLevel(t){e:for(let n=Math.min(this.depth,t.depth);n>=0;n--){let{match:o,type:r}=this.frontier[n],s=n<t.depth&&t.end(n+1)==t.pos+(t.depth-(n+1)),i=My(t,n,r,o,s);if(i){for(let l=n-1;l>=0;l--){let{match:a,type:u}=this.frontier[l],c=My(t,l,u,a,!0);if(!c||c.childCount)continue e}return{depth:n,fit:i,move:s?t.doc.resolve(t.after(n+1)):t}}}}close(t){let n=this.findCloseLevel(t);if(!n)return null;for(;this.depth>n.depth;)this.closeFrontierNode();n.fit.childCount&&(this.placed=mf(this.placed,n.depth,n.fit)),t=n.move;for(let o=n.depth+1;o<=t.depth;o++){let r=t.node(o),s=r.type.contentMatch.fillBefore(r.content,!0,t.index(o));this.openFrontierNode(r.type,r.attrs,s)}return t}openFrontierNode(t,n=null,o){let r=this.frontier[this.depth];r.match=r.match.matchType(t),this.placed=mf(this.placed,this.depth,Ue.from(t.create(n,o))),this.frontier.push({type:t,match:t.contentMatch})}closeFrontierNode(){let n=this.frontier.pop().match.fillBefore(Ue.empty,!0);n.childCount&&(this.placed=mf(this.placed,this.frontier.length,n))}}function hf(e,t,n){return t==0?e.cutByIndex(n,e.childCount):e.replaceChild(0,e.firstChild.copy(hf(e.firstChild.content,t-1,n)))}function mf(e,t,n){return t==0?e.append(n):e.replaceChild(e.childCount-1,e.lastChild.copy(mf(e.lastChild.content,t-1,n)))}function xy(e,t){for(let n=0;n<t;n++)e=e.firstChild.content;return e}function fA(e,t,n){if(t<=0)return e;let o=e.content;return t>1&&(o=o.replaceChild(0,fA(o.firstChild,t-1,o.childCount==1?n-1:0))),t>0&&(o=e.type.contentMatch.fillBefore(o).append(o),n<=0&&(o=o.append(e.type.contentMatch.matchFragment(o).fillBefore(Ue.empty,!0)))),e.copy(o)}function My(e,t,n,o,r){let s=e.node(t),i=r?e.indexAfter(t):e.index(t);if(i==s.childCount&&!n.compatibleContent(s.type))return null;let l=o.fillBefore(s.content,!0,i);return l&&!A2e(n,s.content,i)?l:null}function A2e(e,t,n){for(let o=n;o<t.childCount;o++)if(!e.allowsMarks(t.child(o).marks))return!0;return!1}function N2e(e){return e.spec.defining||e.spec.definingForContent}function P2e(e,t,n,o){if(!o.size)return e.deleteRange(t,n);let r=e.doc.resolve(t),s=e.doc.resolve(n);if(dA(r,s,o))return e.step(new eo(t,n,o));let i=hA(r,e.doc.resolve(n));i[i.length-1]==0&&i.pop();let l=-(r.depth+1);i.unshift(l);for(let f=r.depth,p=r.pos-1;f>0;f--,p--){let h=r.node(f).type.spec;if(h.defining||h.definingAsContext||h.isolating)break;i.indexOf(f)>-1?l=f:r.before(f)==p&&i.splice(1,0,-f)}let a=i.indexOf(l),u=[],c=o.openStart;for(let f=o.content,p=0;;p++){let h=f.firstChild;if(u.push(h),p==o.openStart)break;f=h.content}for(let f=c-1;f>=0;f--){let p=u[f],h=N2e(p.type);if(h&&!p.sameMarkup(r.node(Math.abs(l)-1)))c=f;else if(h||!p.type.isTextblock)break}for(let f=o.openStart;f>=0;f--){let p=(f+c+1)%(o.openStart+1),h=u[p];if(h)for(let m=0;m<i.length;m++){let y=i[(m+a)%i.length],v=!0;y<0&&(v=!1,y=-y);let w=r.node(y-1),_=r.index(y-1);if(w.canReplaceWith(_,_,h.type,h.marks))return e.replace(r.before(y),v?s.after(y):n,new Ye(pA(o.content,0,o.openStart,p),p,o.openEnd))}}let d=e.steps.length;for(let f=i.length-1;f>=0&&(e.replace(t,n,o),!(e.steps.length>d));f--){let p=i[f];p<0||(t=r.before(p),n=s.after(p))}}function pA(e,t,n,o,r){if(t<n){let s=e.firstChild;e=e.replaceChild(0,s.copy(pA(s.content,t+1,n,o,s)))}if(t>o){let s=r.contentMatchAt(0),i=s.fillBefore(e).append(e);e=i.append(s.matchFragment(i).fillBefore(Ue.empty,!0))}return e}function L2e(e,t,n,o){if(!o.isInline&&t==n&&e.doc.resolve(t).parent.content.size){let r=T2e(e.doc,t,o.type);r!=null&&(t=n=r)}e.replaceRange(t,n,new Ye(Ue.from(o),0,0))}function R2e(e,t,n){let o=e.doc.resolve(t),r=e.doc.resolve(n),s=hA(o,r);for(let i=0;i<s.length;i++){let l=s[i],a=i==s.length-1;if(a&&l==0||o.node(l).type.contentMatch.validEnd)return e.delete(o.start(l),r.end(l));if(l>0&&(a||o.node(l-1).canReplace(o.index(l-1),r.indexAfter(l-1))))return e.delete(o.before(l),r.after(l))}for(let i=1;i<=o.depth&&i<=r.depth;i++)if(t-o.start(i)==o.depth-i&&n>o.end(i)&&r.end(i)-n!=r.depth-i)return e.delete(o.before(i),n);e.delete(t,n)}function hA(e,t){let n=[],o=Math.min(e.depth,t.depth);for(let r=o;r>=0;r--){let s=e.start(r);if(s<e.pos-(e.depth-r)||t.end(r)>t.pos+(t.depth-r)||e.node(r).type.spec.isolating||t.node(r).type.spec.isolating)break;(s==t.start(r)||r==e.depth&&r==t.depth&&e.parent.inlineContent&&t.parent.inlineContent&&r&&t.start(r-1)==s-1)&&n.push(r)}return n}class xc extends bo{constructor(t,n,o){super(),this.pos=t,this.attr=n,this.value=o}apply(t){let n=t.nodeAt(this.pos);if(!n)return Rn.fail("No node at attribute step's position");let o=Object.create(null);for(let s in n.attrs)o[s]=n.attrs[s];o[this.attr]=this.value;let r=n.type.create(o,null,n.marks);return Rn.fromReplace(t,this.pos,this.pos+1,new Ye(Ue.from(r),0,n.isLeaf?0:1))}getMap(){return cr.empty}invert(t){return new xc(this.pos,this.attr,t.nodeAt(this.pos).attrs[this.attr])}map(t){let n=t.mapResult(this.pos,1);return n.deletedAfter?null:new xc(n.pos,this.attr,this.value)}toJSON(){return{stepType:"attr",pos:this.pos,attr:this.attr,value:this.value}}static fromJSON(t,n){if(typeof n.pos!="number"||typeof n.attr!="string")throw new RangeError("Invalid input for AttrStep.fromJSON");return new xc(n.pos,n.attr,n.value)}}bo.jsonID("attr",xc);class zp extends bo{constructor(t,n){super(),this.attr=t,this.value=n}apply(t){let n=Object.create(null);for(let r in t.attrs)n[r]=t.attrs[r];n[this.attr]=this.value;let o=t.type.create(n,t.content,t.marks);return Rn.ok(o)}getMap(){return cr.empty}invert(t){return new zp(this.attr,t.attrs[this.attr])}map(t){return this}toJSON(){return{stepType:"docAttr",attr:this.attr,value:this.value}}static fromJSON(t,n){if(typeof n.attr!="string")throw new RangeError("Invalid input for DocAttrStep.fromJSON");return new zp(n.attr,n.value)}}bo.jsonID("docAttr",zp);let dd=class extends Error{};dd=function e(t){let n=Error.call(this,t);return n.__proto__=e.prototype,n};dd.prototype=Object.create(Error.prototype);dd.prototype.constructor=dd;dd.prototype.name="TransformError";class mA{constructor(t){this.doc=t,this.steps=[],this.docs=[],this.mapping=new Ec}get before(){return this.docs.length?this.docs[0]:this.doc}step(t){let n=this.maybeStep(t);if(n.failed)throw new dd(n.failed);return this}maybeStep(t){let n=t.apply(this.doc);return n.failed||this.addStep(t,n.doc),n}get docChanged(){return this.steps.length>0}addStep(t,n){this.docs.push(this.doc),this.steps.push(t),this.mapping.appendMap(t.getMap()),this.doc=n}replace(t,n=t,o=Ye.empty){let r=lC(this.doc,t,n,o);return r&&this.step(r),this}replaceWith(t,n,o){return this.replace(t,n,new Ye(Ue.from(o),0,0))}delete(t,n){return this.replace(t,n,Ye.empty)}insert(t,n){return this.replaceWith(t,t,n)}replaceRange(t,n,o){return P2e(this,t,n,o),this}replaceRangeWith(t,n,o){return L2e(this,t,n,o),this}deleteRange(t,n){return R2e(this,t,n),this}lift(t,n){return v2e(this,t,n),this}join(t,n=1){return M2e(this,t,n),this}wrap(t,n){return b2e(this,t,n),this}setBlockType(t,n=t,o,r=null){return w2e(this,t,n,o,r),this}setNodeMarkup(t,n,o=null,r){return $2e(this,t,n,o,r),this}setNodeAttribute(t,n,o){return this.step(new xc(t,n,o)),this}setDocAttribute(t,n){return this.step(new zp(t,n)),this}addNodeMark(t,n){return this.step(new Ol(t,n)),this}removeNodeMark(t,n){if(!(n instanceof Yt)){let o=this.doc.nodeAt(t);if(!o)throw new RangeError("No node at position "+t);if(n=n.isInSet(o.marks),!n)return this}return this.step(new cd(t,n)),this}split(t,n=1,o){return E2e(this,t,n,o),this}addMark(t,n,o){return h2e(this,t,n,o),this}removeMark(t,n,o){return m2e(this,t,n,o),this}clearIncompatible(t,n,o){return cA(this,t,n,o),this}}const Ty=Object.create(null);class bt{constructor(t,n,o){this.$anchor=t,this.$head=n,this.ranges=o||[new Yg(t.min(n),t.max(n))]}get anchor(){return this.$anchor.pos}get head(){return this.$head.pos}get from(){return this.$from.pos}get to(){return this.$to.pos}get $from(){return this.ranges[0].$from}get $to(){return this.ranges[0].$to}get empty(){let t=this.ranges;for(let n=0;n<t.length;n++)if(t[n].$from.pos!=t[n].$to.pos)return!1;return!0}content(){return this.$from.doc.slice(this.from,this.to,!0)}replace(t,n=Ye.empty){let o=n.content.lastChild,r=null;for(let l=0;l<n.openEnd;l++)r=o,o=o.lastChild;let s=t.steps.length,i=this.ranges;for(let l=0;l<i.length;l++){let{$from:a,$to:u}=i[l],c=t.mapping.slice(s);t.replaceRange(c.map(a.pos),c.map(u.pos),l?Ye.empty:n),l==0&&VS(t,s,(o?o.isInline:r&&r.isTextblock)?-1:1)}}replaceWith(t,n){let o=t.steps.length,r=this.ranges;for(let s=0;s<r.length;s++){let{$from:i,$to:l}=r[s],a=t.mapping.slice(o),u=a.map(i.pos),c=a.map(l.pos);s?t.deleteRange(u,c):(t.replaceRangeWith(u,c,n),VS(t,o,n.isInline?-1:1))}}static findFrom(t,n,o=!1){let r=t.parent.inlineContent?new ht(t):Qu(t.node(0),t.parent,t.pos,t.index(),n,o);if(r)return r;for(let s=t.depth-1;s>=0;s--){let i=n<0?Qu(t.node(0),t.node(s),t.before(s+1),t.index(s),n,o):Qu(t.node(0),t.node(s),t.after(s+1),t.index(s)+1,n,o);if(i)return i}return null}static near(t,n=1){return this.findFrom(t,n)||this.findFrom(t,-n)||new gr(t.node(0))}static atStart(t){return Qu(t,t,0,0,1)||new gr(t)}static atEnd(t){return Qu(t,t,t.content.size,t.childCount,-1)||new gr(t)}static fromJSON(t,n){if(!n||!n.type)throw new RangeError("Invalid input for Selection.fromJSON");let o=Ty[n.type];if(!o)throw new RangeError(`No selection type ${n.type} defined`);return o.fromJSON(t,n)}static jsonID(t,n){if(t in Ty)throw new RangeError("Duplicate use of selection JSON ID "+t);return Ty[t]=n,n.prototype.jsonID=t,n}getBookmark(){return ht.between(this.$anchor,this.$head).getBookmark()}}bt.prototype.visible=!0;class Yg{constructor(t,n){this.$from=t,this.$to=n}}let DS=!1;function FS(e){!DS&&!e.parent.inlineContent&&(DS=!0,console.warn("TextSelection endpoint not pointing into a node with inline content ("+e.parent.type.name+")"))}class ht extends bt{constructor(t,n=t){FS(t),FS(n),super(t,n)}get $cursor(){return this.$anchor.pos==this.$head.pos?this.$head:null}map(t,n){let o=t.resolve(n.map(this.head));if(!o.parent.inlineContent)return bt.near(o);let r=t.resolve(n.map(this.anchor));return new ht(r.parent.inlineContent?r:o,o)}replace(t,n=Ye.empty){if(super.replace(t,n),n==Ye.empty){let o=this.$from.marksAcross(this.$to);o&&t.ensureMarks(o)}}eq(t){return t instanceof ht&&t.anchor==this.anchor&&t.head==this.head}getBookmark(){return new iv(this.anchor,this.head)}toJSON(){return{type:"text",anchor:this.anchor,head:this.head}}static fromJSON(t,n){if(typeof n.anchor!="number"||typeof n.head!="number")throw new RangeError("Invalid input for TextSelection.fromJSON");return new ht(t.resolve(n.anchor),t.resolve(n.head))}static create(t,n,o=n){let r=t.resolve(n);return new this(r,o==n?r:t.resolve(o))}static between(t,n,o){let r=t.pos-n.pos;if((!o||r)&&(o=r>=0?1:-1),!n.parent.inlineContent){let s=bt.findFrom(n,o,!0)||bt.findFrom(n,-o,!0);if(s)n=s.$head;else return bt.near(n,o)}return t.parent.inlineContent||(r==0?t=n:(t=(bt.findFrom(t,-o,!0)||bt.findFrom(t,o,!0)).$anchor,t.pos<n.pos!=r<0&&(t=n))),new ht(t,n)}}bt.jsonID("text",ht);class iv{constructor(t,n){this.anchor=t,this.head=n}map(t){return new iv(t.map(this.anchor),t.map(this.head))}resolve(t){return ht.between(t.resolve(this.anchor),t.resolve(this.head))}}class mt extends bt{constructor(t){let n=t.nodeAfter,o=t.node(0).resolve(t.pos+n.nodeSize);super(t,o),this.node=n}map(t,n){let{deleted:o,pos:r}=n.mapResult(this.anchor),s=t.resolve(r);return o?bt.near(s):new mt(s)}content(){return new Ye(Ue.from(this.node),0,0)}eq(t){return t instanceof mt&&t.anchor==this.anchor}toJSON(){return{type:"node",anchor:this.anchor}}getBookmark(){return new aC(this.anchor)}static fromJSON(t,n){if(typeof n.anchor!="number")throw new RangeError("Invalid input for NodeSelection.fromJSON");return new mt(t.resolve(n.anchor))}static create(t,n){return new mt(t.resolve(n))}static isSelectable(t){return!t.isText&&t.type.spec.selectable!==!1}}mt.prototype.visible=!1;bt.jsonID("node",mt);class aC{constructor(t){this.anchor=t}map(t){let{deleted:n,pos:o}=t.mapResult(this.anchor);return n?new iv(o,o):new aC(o)}resolve(t){let n=t.resolve(this.anchor),o=n.nodeAfter;return o&&mt.isSelectable(o)?new mt(n):bt.near(n)}}class gr extends bt{constructor(t){super(t.resolve(0),t.resolve(t.content.size))}replace(t,n=Ye.empty){if(n==Ye.empty){t.delete(0,t.doc.content.size);let o=bt.atStart(t.doc);o.eq(t.selection)||t.setSelection(o)}else super.replace(t,n)}toJSON(){return{type:"all"}}static fromJSON(t){return new gr(t)}map(t){return new gr(t)}eq(t){return t instanceof gr}getBookmark(){return D2e}}bt.jsonID("all",gr);const D2e={map(){return this},resolve(e){return new gr(e)}};function Qu(e,t,n,o,r,s=!1){if(t.inlineContent)return ht.create(e,n);for(let i=o-(r>0?0:1);r>0?i<t.childCount:i>=0;i+=r){let l=t.child(i);if(l.isAtom){if(!s&&mt.isSelectable(l))return mt.create(e,n-(r<0?l.nodeSize:0))}else{let a=Qu(e,l,n+r,r<0?l.childCount:0,r,s);if(a)return a}n+=l.nodeSize*r}return null}function VS(e,t,n){let o=e.steps.length-1;if(o<t)return;let r=e.steps[o];if(!(r instanceof eo||r instanceof vo))return;let s=e.mapping.maps[o],i;s.forEach((l,a,u,c)=>{i==null&&(i=c)}),e.setSelection(bt.near(e.doc.resolve(i),n))}const BS=1,km=2,zS=4;class F2e extends mA{constructor(t){super(t.doc),this.curSelectionFor=0,this.updated=0,this.meta=Object.create(null),this.time=Date.now(),this.curSelection=t.selection,this.storedMarks=t.storedMarks}get selection(){return this.curSelectionFor<this.steps.length&&(this.curSelection=this.curSelection.map(this.doc,this.mapping.slice(this.curSelectionFor)),this.curSelectionFor=this.steps.length),this.curSelection}setSelection(t){if(t.$from.doc!=this.doc)throw new RangeError("Selection passed to setSelection must point at the current document");return this.curSelection=t,this.curSelectionFor=this.steps.length,this.updated=(this.updated|BS)&~km,this.storedMarks=null,this}get selectionSet(){return(this.updated&BS)>0}setStoredMarks(t){return this.storedMarks=t,this.updated|=km,this}ensureMarks(t){return Yt.sameSet(this.storedMarks||this.selection.$from.marks(),t)||this.setStoredMarks(t),this}addStoredMark(t){return this.ensureMarks(t.addToSet(this.storedMarks||this.selection.$head.marks()))}removeStoredMark(t){return this.ensureMarks(t.removeFromSet(this.storedMarks||this.selection.$head.marks()))}get storedMarksSet(){return(this.updated&km)>0}addStep(t,n){super.addStep(t,n),this.updated=this.updated&~km,this.storedMarks=null}setTime(t){return this.time=t,this}replaceSelection(t){return this.selection.replace(this,t),this}replaceSelectionWith(t,n=!0){let o=this.selection;return n&&(t=t.mark(this.storedMarks||(o.empty?o.$from.marks():o.$from.marksAcross(o.$to)||Yt.none))),o.replaceWith(this,t),this}deleteSelection(){return this.selection.replace(this),this}insertText(t,n,o){let r=this.doc.type.schema;if(n==null)return t?this.replaceSelectionWith(r.text(t),!0):this.deleteSelection();{if(o==null&&(o=n),o=o??n,!t)return this.deleteRange(n,o);let s=this.storedMarks;if(!s){let i=this.doc.resolve(n);s=o==n?i.marks():i.marksAcross(this.doc.resolve(o))}return this.replaceRangeWith(n,o,r.text(t,s)),this.selection.empty||this.setSelection(bt.near(this.selection.$to)),this}}setMeta(t,n){return this.meta[typeof t=="string"?t:t.key]=n,this}getMeta(t){return this.meta[typeof t=="string"?t:t.key]}get isGeneric(){for(let t in this.meta)return!1;return!0}scrollIntoView(){return this.updated|=zS,this}get scrolledIntoView(){return(this.updated&zS)>0}}function jS(e,t){return!t||!e?e:e.bind(t)}class gf{constructor(t,n,o){this.name=t,this.init=jS(n.init,o),this.apply=jS(n.apply,o)}}const V2e=[new gf("doc",{init(e){return e.doc||e.schema.topNodeType.createAndFill()},apply(e){return e.doc}}),new gf("selection",{init(e,t){return e.selection||bt.atStart(t.doc)},apply(e){return e.selection}}),new gf("storedMarks",{init(e){return e.storedMarks||null},apply(e,t,n,o){return o.selection.$cursor?e.storedMarks:null}}),new gf("scrollToSelection",{init(){return 0},apply(e,t){return e.scrolledIntoView?t+1:t}})];class Oy{constructor(t,n){this.schema=t,this.plugins=[],this.pluginsByKey=Object.create(null),this.fields=V2e.slice(),n&&n.forEach(o=>{if(this.pluginsByKey[o.key])throw new RangeError("Adding different instances of a keyed plugin ("+o.key+")");this.plugins.push(o),this.pluginsByKey[o.key]=o,o.spec.state&&this.fields.push(new gf(o.key,o.spec.state,o))})}}class La{constructor(t){this.config=t}get schema(){return this.config.schema}get plugins(){return this.config.plugins}apply(t){return this.applyTransaction(t).state}filterTransaction(t,n=-1){for(let o=0;o<this.config.plugins.length;o++)if(o!=n){let r=this.config.plugins[o];if(r.spec.filterTransaction&&!r.spec.filterTransaction.call(r,t,this))return!1}return!0}applyTransaction(t){if(!this.filterTransaction(t))return{state:this,transactions:[]};let n=[t],o=this.applyInner(t),r=null;for(;;){let s=!1;for(let i=0;i<this.config.plugins.length;i++){let l=this.config.plugins[i];if(l.spec.appendTransaction){let a=r?r[i].n:0,u=r?r[i].state:this,c=a<n.length&&l.spec.appendTransaction.call(l,a?n.slice(a):n,u,o);if(c&&o.filterTransaction(c,i)){if(c.setMeta("appendedTransaction",t),!r){r=[];for(let d=0;d<this.config.plugins.length;d++)r.push(d<i?{state:o,n:n.length}:{state:this,n:0})}n.push(c),o=o.applyInner(c),s=!0}r&&(r[i]={state:o,n:n.length})}}if(!s)return{state:o,transactions:n}}}applyInner(t){if(!t.before.eq(this.doc))throw new RangeError("Applying a mismatched transaction");let n=new La(this.config),o=this.config.fields;for(let r=0;r<o.length;r++){let s=o[r];n[s.name]=s.apply(t,this[s.name],this,n)}return n}get tr(){return new F2e(this)}static create(t){let n=new Oy(t.doc?t.doc.type.schema:t.schema,t.plugins),o=new La(n);for(let r=0;r<n.fields.length;r++)o[n.fields[r].name]=n.fields[r].init(t,o);return o}reconfigure(t){let n=new Oy(this.schema,t.plugins),o=n.fields,r=new La(n);for(let s=0;s<o.length;s++){let i=o[s].name;r[i]=this.hasOwnProperty(i)?this[i]:o[s].init(t,r)}return r}toJSON(t){let n={doc:this.doc.toJSON(),selection:this.selection.toJSON()};if(this.storedMarks&&(n.storedMarks=this.storedMarks.map(o=>o.toJSON())),t&&typeof t=="object")for(let o in t){if(o=="doc"||o=="selection")throw new RangeError("The JSON fields `doc` and `selection` are reserved");let r=t[o],s=r.spec.state;s&&s.toJSON&&(n[o]=s.toJSON.call(r,this[r.key]))}return n}static fromJSON(t,n,o){if(!n)throw new RangeError("Invalid input for EditorState.fromJSON");if(!t.schema)throw new RangeError("Required config field 'schema' missing");let r=new Oy(t.schema,t.plugins),s=new La(r);return r.fields.forEach(i=>{if(i.name=="doc")s.doc=Ll.fromJSON(t.schema,n.doc);else if(i.name=="selection")s.selection=bt.fromJSON(s.doc,n.selection);else if(i.name=="storedMarks")n.storedMarks&&(s.storedMarks=n.storedMarks.map(t.schema.markFromJSON));else{if(o)for(let l in o){let a=o[l],u=a.spec.state;if(a.key==i.name&&u&&u.fromJSON&&Object.prototype.hasOwnProperty.call(n,l)){s[i.name]=u.fromJSON.call(a,t,n[l],s);return}}s[i.name]=i.init(t,s)}}),s}}function gA(e,t,n){for(let o in e){let r=e[o];r instanceof Function?r=r.bind(t):o=="handleDOMEvents"&&(r=gA(r,t,{})),n[o]=r}return n}class xn{constructor(t){this.spec=t,this.props={},t.props&&gA(t.props,this,this.props),this.key=t.key?t.key.key:vA("plugin")}getState(t){return t[this.key]}}const Iy=Object.create(null);function vA(e){return e in Iy?e+"$"+ ++Iy[e]:(Iy[e]=0,e+"$")}class wn{constructor(t="key"){this.key=vA(t)}get(t){return t.config.pluginsByKey[this.key]}getState(t){return t[this.key]}}class Cr{constructor(t,n,o={}){this.match=t,this.match=t,this.handler=typeof n=="string"?B2e(n):n,this.undoable=o.undoable!==!1,this.inCode=o.inCode||!1}}function B2e(e){return function(t,n,o,r){let s=e;if(n[1]){let i=n[0].lastIndexOf(n[1]);s+=n[0].slice(i+n[1].length),o+=i;let l=o-r;l>0&&(s=n[0].slice(i-l,i)+s,o=r)}return t.tr.insertText(s,o,r)}}const z2e=(e,t)=>{let n=e.plugins;for(let o=0;o<n.length;o++){let r=n[o],s;if(r.spec.isInputRules&&(s=r.getState(e))){if(t){let i=e.tr,l=s.transform;for(let a=l.steps.length-1;a>=0;a--)i.step(l.steps[a].invert(l.docs[a]));if(s.text){let a=i.doc.resolve(s.from).marks();i.replaceWith(s.from,s.to,e.schema.text(s.text,a))}else i.delete(s.from,s.to);t(i)}return!0}}return!1};new Cr(/--$/,"—");new Cr(/\.\.\.$/,"…");new Cr(/(?:^|[\s\{\[\(\<'"\u2018\u201C])(")$/,"“");new Cr(/"$/,"”");new Cr(/(?:^|[\s\{\[\(\<'"\u2018\u201C])(')$/,"‘");new Cr(/'$/,"’");function uC(e,t,n=null,o){return new Cr(e,(r,s,i,l)=>{let a=n instanceof Function?n(s):n,u=r.tr.delete(i,l),c=u.doc.resolve(i),d=c.blockRange(),f=d&&iC(d,t,a);if(!f)return null;u.wrap(d,f);let p=u.doc.resolve(i-1).nodeBefore;return p&&p.type==t&&sv(u.doc,i-1)&&(!o||o(s,p))&&u.join(i-1),u})}function yA(e,t,n=null){return new Cr(e,(o,r,s,i)=>{let l=o.doc.resolve(s),a=n instanceof Function?n(r):n;return l.node(-1).canReplaceWith(l.index(-1),l.indexAfter(-1),t)?o.tr.delete(s,i).setBlockType(s,s,t,a):null})}const Wl=typeof navigator<"u"?navigator:null,HS=typeof document<"u"?document:null,oa=Wl&&Wl.userAgent||"",Xb=/Edge\/(\d+)/.exec(oa),_A=/MSIE \d/.exec(oa),Qb=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(oa),lv=!!(_A||Qb||Xb),j2e=_A?document.documentMode:Qb?+Qb[1]:Xb?+Xb[1]:0,bA=!lv&&/gecko\/(\d+)/i.test(oa),H2e=bA&&+(/Firefox\/(\d+)/.exec(oa)||[0,0])[1],e2=!lv&&/Chrome\/(\d+)/.exec(oa),U2e=!!e2,W2e=e2?+e2[1]:0,wA=!lv&&!!Wl&&/Apple Computer/.test(Wl.vendor),CA=wA&&(/Mobile\/\w+/.test(oa)||!!Wl&&Wl.maxTouchPoints>2),K2e=CA||(Wl?/Mac/.test(Wl.platform):!1),q2e=/Android \d/.test(oa),kA=!!HS&&"webkitFontSmoothing"in HS.documentElement.style,G2e=kA?+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]:0;var Sm=Object.freeze({__proto__:null,android:q2e,chrome:U2e,chrome_version:W2e,gecko:bA,gecko_version:H2e,ie:lv,ie_version:j2e,ios:CA,mac:K2e,safari:wA,webkit:kA,webkit_version:G2e});function Ay(e,t,n,o,r,s){if(e.composing)return!1;const i=e.state,l=i.doc.resolve(t);if(l.parent.type.spec.code)return!1;const a=l.parent.textBetween(Math.max(0,l.parentOffset-500),l.parentOffset,void 0,"")+o;for(let u=0;u<r.length;u++){const c=r[u].match.exec(a),d=c&&c[0]&&r[u].handler(i,c,t-(c[0].length-o.length),n);if(d)return e.dispatch(d.setMeta(s,{transform:d,from:t,to:n,text:o})),!0}return!1}const Y2e=new wn("MILKDOWN_CUSTOM_INPUTRULES");function Z2e({rules:e}){const t=new xn({key:Y2e,isInputRules:!0,state:{init(){return null},apply(n,o){const r=n.getMeta(this);return r||(n.selectionSet||n.docChanged?null:o)}},props:{handleTextInput(n,o,r,s){return Ay(n,o,r,s,e,t)},handleDOMEvents:{compositionend:n=>(setTimeout(()=>{const{$cursor:o}=n.state.selection;o&&Ay(n,o.pos,o.pos,"",e,t)}),!1)},handleKeyDown(n,o){if(o.key!=="Enter")return!1;const{$cursor:r}=n.state.selection;return r?Ay(n,r.pos,r.pos,`
113 `,e,t):!1}}});return t}function xh(e,t,n={}){return new Cr(e,(o,r,s,i)=>{var l,a,u,c;const{tr:d}=o,f=r.length;let p=r[f-1],h=r[0],m=[],y=i;const v={group:p,fullMatch:h,start:s,end:i},w=(l=n.updateCaptured)==null?void 0:l.call(n,v);if(Object.assign(v,w),{group:p,fullMatch:h,start:s,end:i}=v,h===null||(p==null?void 0:p.trim())==="")return null;if(p){const _=h.search(/\S/),S=s+h.indexOf(p),x=S+p.length;m=(a=d.storedMarks)!=null?a:[],x<i&&d.delete(x,i),S>s&&d.delete(s+_,S),y=s+_+p.length;const E=(u=n.getAttr)==null?void 0:u.call(n,r);d.addMark(s,y,t.create(E)),d.setStoredMarks(m),(c=n.beforeDispatch)==null||c.call(n,{match:r,start:s,end:i,tr:d})}return d})}var J2e=Object.defineProperty,X2e=Object.defineProperties,Q2e=Object.getOwnPropertyDescriptors,US=Object.getOwnPropertySymbols,ewe=Object.prototype.hasOwnProperty,twe=Object.prototype.propertyIsEnumerable,WS=(e,t,n)=>t in e?J2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nwe=(e,t)=>{for(var n in t||(t={}))ewe.call(t,n)&&WS(e,n,t[n]);if(US)for(var n of US(t))twe.call(t,n)&&WS(e,n,t[n]);return e},owe=(e,t)=>X2e(e,Q2e(t));function KS(e=0,t=0,n=0){return Math.min(Math.max(e,t),n)}function av(e,t,n){const r=e.state.doc.content.size,s=KS(t,0,r),i=KS(n,0,r),l=e.coordsAtPos(s),a=e.coordsAtPos(i,-1),u=Math.min(l.top,a.top),c=Math.max(l.bottom,a.bottom),d=Math.min(l.left,a.left),f=Math.max(l.right,a.right),p=f-d,h=c-u,v={top:u,bottom:c,left:d,right:f,width:p,height:h,x:d,y:u};return owe(nwe({},v),{toJSON:()=>v})}function uv(e){return Object.assign(Object.create(e),e).setTime(Date.now())}function rwe(e,t){return Array.isArray(e)&&e.includes(t.type)||t.type===e}function cC(e){return t=>{for(let n=t.depth;n>0;n-=1){const o=t.node(n);if(e(o)){const r=t.before(n),s=t.after(n);return{from:r,to:s,node:o}}}}}function swe(e,t){return cC(n=>n.type===t)(e)}function iwe(e,t){const n=t.nodes[e];if(!n)throw nve("node",e);return n}function dC(e){return t=>{for(let n=t.depth;n>0;n--){const o=t.node(n);if(e(o))return{pos:n>0?t.before(n):0,start:t.start(n),depth:n,node:o}}}}function lwe(e){return t=>dC(e)(t.$from)}function awe(e,t){if(!(e instanceof mt))return;const{node:n,$from:o}=e;if(rwe(t,n))return{node:n,pos:o.pos,start:o.start(o.depth),depth:o.depth}}const fC=(e,t)=>e.selection.empty?!1:(t&&t(e.tr.deleteSelection().scrollIntoView()),!0);function uwe(e,t){let{$cursor:n}=e.selection;return!n||(t?!t.endOfTextblock("backward",e):n.parentOffset>0)?null:n}const SA=(e,t,n)=>{let o=uwe(e,n);if(!o)return!1;let r=EA(o);if(!r){let i=o.blockRange(),l=i&&rv(i);return l==null?!1:(t&&t(e.tr.lift(i,l).scrollIntoView()),!0)}let s=r.nodeBefore;if(MA(e,r,t,-1))return!0;if(o.parent.content.size==0&&(fd(s,"end")||mt.isSelectable(s)))for(let i=o.depth;;i--){let l=lC(e.doc,o.before(i),o.after(i),Ye.empty);if(l&&l.slice.size<l.to-l.from){if(t){let a=e.tr.step(l);a.setSelection(fd(s,"end")?bt.findFrom(a.doc.resolve(a.mapping.map(r.pos,-1)),-1):mt.create(a.doc,r.pos-s.nodeSize)),t(a.scrollIntoView())}return!0}if(i==1||o.node(i-1).childCount>1)break}return s.isAtom&&r.depth==o.depth-1?(t&&t(e.tr.delete(r.pos-s.nodeSize,r.pos).scrollIntoView()),!0):!1};function fd(e,t,n=!1){for(let o=e;o;o=t=="start"?o.firstChild:o.lastChild){if(o.isTextblock)return!0;if(n&&o.childCount!=1)return!1}return!1}const $A=(e,t,n)=>{let{$head:o,empty:r}=e.selection,s=o;if(!r)return!1;if(o.parent.isTextblock){if(n?!n.endOfTextblock("backward",e):o.parentOffset>0)return!1;s=EA(o)}let i=s&&s.nodeBefore;return!i||!mt.isSelectable(i)?!1:(t&&t(e.tr.setSelection(mt.create(e.doc,s.pos-i.nodeSize)).scrollIntoView()),!0)};function EA(e){if(!e.parent.type.spec.isolating)for(let t=e.depth-1;t>=0;t--){if(e.index(t)>0)return e.doc.resolve(e.before(t+1));if(e.node(t).type.spec.isolating)break}return null}function cwe(e,t){let{$cursor:n}=e.selection;return!n||(t?!t.endOfTextblock("forward",e):n.parentOffset<n.parent.content.size)?null:n}const dwe=(e,t,n)=>{let o=cwe(e,n);if(!o)return!1;let r=xA(o);if(!r)return!1;let s=r.nodeAfter;if(MA(e,r,t,1))return!0;if(o.parent.content.size==0&&(fd(s,"start")||mt.isSelectable(s))){let i=lC(e.doc,o.before(),o.after(),Ye.empty);if(i&&i.slice.size<i.to-i.from){if(t){let l=e.tr.step(i);l.setSelection(fd(s,"start")?bt.findFrom(l.doc.resolve(l.mapping.map(r.pos)),1):mt.create(l.doc,l.mapping.map(r.pos))),t(l.scrollIntoView())}return!0}}return s.isAtom&&r.depth==o.depth-1?(t&&t(e.tr.delete(r.pos,r.pos+s.nodeSize).scrollIntoView()),!0):!1},fwe=(e,t,n)=>{let{$head:o,empty:r}=e.selection,s=o;if(!r)return!1;if(o.parent.isTextblock){if(n?!n.endOfTextblock("forward",e):o.parentOffset<o.parent.content.size)return!1;s=xA(o)}let i=s&&s.nodeAfter;return!i||!mt.isSelectable(i)?!1:(t&&t(e.tr.setSelection(mt.create(e.doc,s.pos)).scrollIntoView()),!0)};function xA(e){if(!e.parent.type.spec.isolating)for(let t=e.depth-1;t>=0;t--){let n=e.node(t);if(e.index(t)+1<n.childCount)return e.doc.resolve(e.after(t+1));if(n.type.spec.isolating)break}return null}const pwe=(e,t)=>{let{$head:n,$anchor:o}=e.selection;return!n.parent.type.spec.code||!n.sameParent(o)?!1:(t&&t(e.tr.insertText(`
114 `).scrollIntoView()),!0)};function pC(e){for(let t=0;t<e.edgeCount;t++){let{type:n}=e.edge(t);if(n.isTextblock&&!n.hasRequiredAttrs())return n}return null}const hwe=(e,t)=>{let{$head:n,$anchor:o}=e.selection;if(!n.parent.type.spec.code||!n.sameParent(o))return!1;let r=n.node(-1),s=n.indexAfter(-1),i=pC(r.contentMatchAt(s));if(!i||!r.canReplaceWith(s,s,i))return!1;if(t){let l=n.after(),a=e.tr.replaceWith(l,l,i.createAndFill());a.setSelection(bt.near(a.doc.resolve(l),1)),t(a.scrollIntoView())}return!0},mwe=(e,t)=>{let n=e.selection,{$from:o,$to:r}=n;if(n instanceof gr||o.parent.inlineContent||r.parent.inlineContent)return!1;let s=pC(r.parent.contentMatchAt(r.indexAfter()));if(!s||!s.isTextblock)return!1;if(t){let i=(!o.parentOffset&&r.index()<r.parent.childCount?o:r).pos,l=e.tr.insert(i,s.createAndFill());l.setSelection(ht.create(l.doc,i+1)),t(l.scrollIntoView())}return!0},gwe=(e,t)=>{let{$cursor:n}=e.selection;if(!n||n.parent.content.size)return!1;if(n.depth>1&&n.after()!=n.end(-1)){let s=n.before();if(tp(e.doc,s))return t&&t(e.tr.split(s).scrollIntoView()),!0}let o=n.blockRange(),r=o&&rv(o);return r==null?!1:(t&&t(e.tr.lift(o,r).scrollIntoView()),!0)};function vwe(e){return(t,n)=>{let{$from:o,$to:r}=t.selection;if(t.selection instanceof mt&&t.selection.node.isBlock)return!o.parentOffset||!tp(t.doc,o.pos)?!1:(n&&n(t.tr.split(o.pos).scrollIntoView()),!0);if(!o.parent.isBlock)return!1;if(n){let s=r.parentOffset==r.parent.content.size,i=t.tr;(t.selection instanceof ht||t.selection instanceof gr)&&i.deleteSelection();let l=o.depth==0?null:pC(o.node(-1).contentMatchAt(o.indexAfter(-1))),a=e&&e(r.parent,s,o),u=a?[a]:s&&l?[{type:l}]:void 0,c=tp(i.doc,i.mapping.map(o.pos),1,u);if(!u&&!c&&tp(i.doc,i.mapping.map(o.pos),1,l?[{type:l}]:void 0)&&(l&&(u=[{type:l}]),c=!0),c&&(i.split(i.mapping.map(o.pos),1,u),!s&&!o.parentOffset&&o.parent.type!=l)){let d=i.mapping.map(o.before()),f=i.doc.resolve(d);l&&o.node(-1).canReplaceWith(f.index(),f.index()+1,l)&&i.setNodeMarkup(i.mapping.map(o.before()),l)}n(i.scrollIntoView())}return!0}}const ywe=vwe(),_we=(e,t)=>(t&&t(e.tr.setSelection(new gr(e.doc))),!0);function bwe(e,t,n){let o=t.nodeBefore,r=t.nodeAfter,s=t.index();return!o||!r||!o.type.compatibleContent(r.type)?!1:!o.content.size&&t.parent.canReplace(s-1,s)?(n&&n(e.tr.delete(t.pos-o.nodeSize,t.pos).scrollIntoView()),!0):!t.parent.canReplace(s,s+1)||!(r.isTextblock||sv(e.doc,t.pos))?!1:(n&&n(e.tr.clearIncompatible(t.pos,o.type,o.contentMatchAt(o.childCount)).join(t.pos).scrollIntoView()),!0)}function MA(e,t,n,o){let r=t.nodeBefore,s=t.nodeAfter,i,l,a=r.type.spec.isolating||s.type.spec.isolating;if(!a&&bwe(e,t,n))return!0;let u=!a&&t.parent.canReplace(t.index(),t.index()+1);if(u&&(i=(l=r.contentMatchAt(r.childCount)).findWrapping(s.type))&&l.matchType(i[0]||s.type).validEnd){if(n){let p=t.pos+s.nodeSize,h=Ue.empty;for(let v=i.length-1;v>=0;v--)h=Ue.from(i[v].create(null,h));h=Ue.from(r.copy(h));let m=e.tr.step(new vo(t.pos-1,p,t.pos,p,new Ye(h,1,0),i.length,!0)),y=p+2*i.length;sv(m.doc,y)&&m.join(y),n(m.scrollIntoView())}return!0}let c=s.type.spec.isolating||o>0&&a?null:bt.findFrom(t,1),d=c&&c.$from.blockRange(c.$to),f=d&&rv(d);if(f!=null&&f>=t.depth)return n&&n(e.tr.lift(d,f).scrollIntoView()),!0;if(u&&fd(s,"start",!0)&&fd(r,"end")){let p=r,h=[];for(;h.push(p),!p.isTextblock;)p=p.lastChild;let m=s,y=1;for(;!m.isTextblock;m=m.firstChild)y++;if(p.canReplace(p.childCount,p.childCount,m.content)){if(n){let v=Ue.empty;for(let _=h.length-1;_>=0;_--)v=Ue.from(h[_].copy(v));let w=e.tr.step(new vo(t.pos-h.length,t.pos+s.nodeSize,t.pos+y,t.pos+s.nodeSize-y,new Ye(v,h.length,0),0,!0));n(w.scrollIntoView())}return!0}}return!1}function TA(e){return function(t,n){let o=t.selection,r=e<0?o.$from:o.$to,s=r.depth;for(;r.node(s).isInline;){if(!s)return!1;s--}return r.node(s).isTextblock?(n&&n(t.tr.setSelection(ht.create(t.doc,e<0?r.start(s):r.end(s)))),!0):!1}}const wwe=TA(-1),Cwe=TA(1);function hC(e,t=null){return function(n,o){let{$from:r,$to:s}=n.selection,i=r.blockRange(s),l=i&&iC(i,e,t);return l?(o&&o(n.tr.wrap(i,l).scrollIntoView()),!0):!1}}function jp(e,t=null){return function(n,o){let r=!1;for(let s=0;s<n.selection.ranges.length&&!r;s++){let{$from:{pos:i},$to:{pos:l}}=n.selection.ranges[s];n.doc.nodesBetween(i,l,(a,u)=>{if(r)return!1;if(!(!a.isTextblock||a.hasMarkup(e,t)))if(a.type==e)r=!0;else{let c=n.doc.resolve(u),d=c.index();r=c.parent.canReplaceWith(d,d+1,e)}})}if(!r)return!1;if(o){let s=n.tr;for(let i=0;i<n.selection.ranges.length;i++){let{$from:{pos:l},$to:{pos:a}}=n.selection.ranges[i];s.setBlockType(l,a,e,t)}o(s.scrollIntoView())}return!0}}function kwe(e,t,n,o){for(let r=0;r<t.length;r++){let{$from:s,$to:i}=t[r],l=s.depth==0?e.inlineContent&&e.type.allowsMarkType(n):!1;if(e.nodesBetween(s.pos,i.pos,(a,u)=>{if(l||!o&&a.isAtom&&a.isInline&&u>=s.pos&&u+a.nodeSize<=i.pos)return!1;l=a.inlineContent&&a.type.allowsMarkType(n)}),l)return!0}return!1}function Swe(e){let t=[];for(let n=0;n<e.length;n++){let{$from:o,$to:r}=e[n];o.doc.nodesBetween(o.pos,r.pos,(s,i)=>{if(s.isAtom&&s.content.size&&s.isInline&&i>=o.pos&&i+s.nodeSize<=r.pos)return i+1>o.pos&&t.push(new Yg(o,o.doc.resolve(i+1))),o=o.doc.resolve(i+1+s.content.size),!1}),o.pos<r.pos&&t.push(new Yg(o,r))}return t}function cv(e,t=null,n){let o=(n&&n.removeWhenPresent)!==!1,r=(n&&n.enterInlineAtoms)!==!1;return function(s,i){let{empty:l,$cursor:a,ranges:u}=s.selection;if(l&&!a||!kwe(s.doc,u,e,r))return!1;if(i)if(a)e.isInSet(s.storedMarks||a.marks())?i(s.tr.removeStoredMark(e)):i(s.tr.addStoredMark(e.create(t)));else{let c,d=s.tr;r||(u=Swe(u)),o?c=!u.some(f=>s.doc.rangeHasMark(f.$from.pos,f.$to.pos,e)):c=!u.every(f=>{let p=!1;return d.doc.nodesBetween(f.$from.pos,f.$to.pos,(h,m,y)=>{if(p)return!1;p=!e.isInSet(h.marks)&&!!y&&y.type.allowsMarkType(e)&&!(h.isText&&/^\s*$/.test(h.textBetween(Math.max(0,f.$from.pos-m),Math.min(h.nodeSize,f.$to.pos-m))))}),!p});for(let f=0;f<u.length;f++){let{$from:p,$to:h}=u[f];if(!c)d.removeMark(p.pos,h.pos,e);else{let m=p.pos,y=h.pos,v=p.nodeAfter,w=h.nodeBefore,_=v&&v.isText?/^\s*/.exec(v.text)[0].length:0,S=w&&w.isText?/\s*$/.exec(w.text)[0].length:0;m+_<y&&(m+=_,y-=S),d.addMark(m,y,e.create(t))}}i(d.scrollIntoView())}return!0}}function dv(...e){return function(t,n,o){for(let r=0;r<e.length;r++)if(e[r](t,n,o))return!0;return!1}}let Ny=dv(fC,SA,$A),qS=dv(fC,dwe,fwe);const yi={Enter:dv(pwe,mwe,gwe,ywe),"Mod-Enter":hwe,Backspace:Ny,"Mod-Backspace":Ny,"Shift-Backspace":Ny,Delete:qS,"Mod-Delete":qS,"Mod-a":_we},OA={"Ctrl-h":yi.Backspace,"Alt-Backspace":yi["Mod-Backspace"],"Ctrl-d":yi.Delete,"Ctrl-Alt-Backspace":yi["Mod-Delete"],"Alt-Delete":yi["Mod-Delete"],"Alt-d":yi["Mod-Delete"],"Ctrl-a":wwe,"Ctrl-e":Cwe};for(let e in yi)OA[e]=yi[e];const $we=typeof navigator<"u"?/Mac|iP(hone|[oa]d)/.test(navigator.platform):typeof os<"u"&&os.platform?os.platform()=="darwin":!1,Ewe=$we?OA:yi;var Kl={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},Zg={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},xwe=typeof navigator<"u"&&/Mac/.test(navigator.platform),Mwe=typeof navigator<"u"&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);for(var to=0;to<10;to++)Kl[48+to]=Kl[96+to]=String(to);for(var to=1;to<=24;to++)Kl[to+111]="F"+to;for(var to=65;to<=90;to++)Kl[to]=String.fromCharCode(to+32),Zg[to]=String.fromCharCode(to);for(var Py in Kl)Zg.hasOwnProperty(Py)||(Zg[Py]=Kl[Py]);function Twe(e){var t=xwe&&e.metaKey&&e.shiftKey&&!e.ctrlKey&&!e.altKey||Mwe&&e.shiftKey&&e.key&&e.key.length==1||e.key=="Unidentified",n=!t&&e.key||(e.shiftKey?Zg:Kl)[e.keyCode]||e.key||"Unidentified";return n=="Esc"&&(n="Escape"),n=="Del"&&(n="Delete"),n=="Left"&&(n="ArrowLeft"),n=="Up"&&(n="ArrowUp"),n=="Right"&&(n="ArrowRight"),n=="Down"&&(n="ArrowDown"),n}const Owe=typeof navigator<"u"?/Mac|iP(hone|[oa]d)/.test(navigator.platform):!1;function Iwe(e){let t=e.split(/-(?!$)/),n=t[t.length-1];n=="Space"&&(n=" ");let o,r,s,i;for(let l=0;l<t.length-1;l++){let a=t[l];if(/^(cmd|meta|m)$/i.test(a))i=!0;else if(/^a(lt)?$/i.test(a))o=!0;else if(/^(c|ctrl|control)$/i.test(a))r=!0;else if(/^s(hift)?$/i.test(a))s=!0;else if(/^mod$/i.test(a))Owe?i=!0:r=!0;else throw new Error("Unrecognized modifier name: "+a)}return o&&(n="Alt-"+n),r&&(n="Ctrl-"+n),i&&(n="Meta-"+n),s&&(n="Shift-"+n),n}function Awe(e){let t=Object.create(null);for(let n in e)t[Iwe(n)]=e[n];return t}function Ly(e,t,n=!0){return t.altKey&&(e="Alt-"+e),t.ctrlKey&&(e="Ctrl-"+e),t.metaKey&&(e="Meta-"+e),n&&t.shiftKey&&(e="Shift-"+e),e}function IA(e){return new xn({props:{handleKeyDown:AA(e)}})}function AA(e){let t=Awe(e);return function(n,o){let r=Twe(o),s,i=t[Ly(r,o)];if(i&&i(n.state,n.dispatch,n))return!0;if(r.length==1&&r!=" "){if(o.shiftKey){let l=t[Ly(r,o,!1)];if(l&&l(n.state,n.dispatch,n))return!0}if((o.shiftKey||o.altKey||o.metaKey||r.charCodeAt(0)>127)&&(s=Kl[o.keyCode])&&s!=r){let l=t[Ly(s,o)];if(l&&l(n.state,n.dispatch,n))return!0}}return!1}}const no=function(e){for(var t=0;;t++)if(e=e.previousSibling,!e)return t},Hp=function(e){let t=e.assignedSlot||e.parentNode;return t&&t.nodeType==11?t.host:t};let t2=null;const vi=function(e,t,n){let o=t2||(t2=document.createRange());return o.setEnd(e,n??e.nodeValue.length),o.setStart(e,t||0),o},Nwe=function(){t2=null},hu=function(e,t,n,o){return n&&(GS(e,t,n,o,-1)||GS(e,t,n,o,1))},Pwe=/^(img|br|input|textarea|hr)$/i;function GS(e,t,n,o,r){for(;;){if(e==n&&t==o)return!0;if(t==(r<0?0:Bs(e))){let s=e.parentNode;if(!s||s.nodeType!=1||Mh(e)||Pwe.test(e.nodeName)||e.contentEditable=="false")return!1;t=no(e)+(r<0?0:1),e=s}else if(e.nodeType==1){if(e=e.childNodes[t+(r<0?-1:0)],e.contentEditable=="false")return!1;t=r<0?Bs(e):0}else return!1}}function Bs(e){return e.nodeType==3?e.nodeValue.length:e.childNodes.length}function Lwe(e,t){for(;;){if(e.nodeType==3&&t)return e;if(e.nodeType==1&&t>0){if(e.contentEditable=="false")return null;e=e.childNodes[t-1],t=Bs(e)}else if(e.parentNode&&!Mh(e))t=no(e),e=e.parentNode;else return null}}function Rwe(e,t){for(;;){if(e.nodeType==3&&t<e.nodeValue.length)return e;if(e.nodeType==1&&t<e.childNodes.length){if(e.contentEditable=="false")return null;e=e.childNodes[t],t=0}else if(e.parentNode&&!Mh(e))t=no(e)+1,e=e.parentNode;else return null}}function Dwe(e,t,n){for(let o=t==0,r=t==Bs(e);o||r;){if(e==n)return!0;let s=no(e);if(e=e.parentNode,!e)return!1;o=o&&s==0,r=r&&s==Bs(e)}}function Mh(e){let t;for(let n=e;n&&!(t=n.pmViewDesc);n=n.parentNode);return t&&t.node&&t.node.isBlock&&(t.dom==e||t.contentDOM==e)}const fv=function(e){return e.focusNode&&hu(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)};function xa(e,t){let n=document.createEvent("Event");return n.initEvent("keydown",!0,!0),n.keyCode=e,n.key=n.code=t,n}function Fwe(e){let t=e.activeElement;for(;t&&t.shadowRoot;)t=t.shadowRoot.activeElement;return t}function Vwe(e,t,n){if(e.caretPositionFromPoint)try{let o=e.caretPositionFromPoint(t,n);if(o)return{node:o.offsetNode,offset:o.offset}}catch{}if(e.caretRangeFromPoint){let o=e.caretRangeFromPoint(t,n);if(o)return{node:o.startContainer,offset:o.startOffset}}}const Js=typeof navigator<"u"?navigator:null,YS=typeof document<"u"?document:null,ra=Js&&Js.userAgent||"",n2=/Edge\/(\d+)/.exec(ra),NA=/MSIE \d/.exec(ra),o2=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(ra),Go=!!(NA||o2||n2),Rl=NA?document.documentMode:o2?+o2[1]:n2?+n2[1]:0,vs=!Go&&/gecko\/(\d+)/i.test(ra);vs&&+(/Firefox\/(\d+)/.exec(ra)||[0,0])[1];const r2=!Go&&/Chrome\/(\d+)/.exec(ra),mo=!!r2,PA=r2?+r2[1]:0,Io=!Go&&!!Js&&/Apple Computer/.test(Js.vendor),pd=Io&&(/Mobile\/\w+/.test(ra)||!!Js&&Js.maxTouchPoints>2),Er=pd||(Js?/Mac/.test(Js.platform):!1),Bwe=Js?/Win/.test(Js.platform):!1,rs=/Android \d/.test(ra),Th=!!YS&&"webkitFontSmoothing"in YS.documentElement.style,zwe=Th?+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]:0;function jwe(e){let t=e.defaultView&&e.defaultView.visualViewport;return t?{left:0,right:t.width,top:0,bottom:t.height}:{left:0,right:e.documentElement.clientWidth,top:0,bottom:e.documentElement.clientHeight}}function di(e,t){return typeof e=="number"?e:e[t]}function Hwe(e){let t=e.getBoundingClientRect(),n=t.width/e.offsetWidth||1,o=t.height/e.offsetHeight||1;return{left:t.left,right:t.left+e.clientWidth*n,top:t.top,bottom:t.top+e.clientHeight*o}}function ZS(e,t,n){let o=e.someProp("scrollThreshold")||0,r=e.someProp("scrollMargin")||5,s=e.dom.ownerDocument;for(let i=n||e.dom;i;i=Hp(i)){if(i.nodeType!=1)continue;let l=i,a=l==s.body,u=a?jwe(s):Hwe(l),c=0,d=0;if(t.top<u.top+di(o,"top")?d=-(u.top-t.top+di(r,"top")):t.bottom>u.bottom-di(o,"bottom")&&(d=t.bottom-t.top>u.bottom-u.top?t.top+di(r,"top")-u.top:t.bottom-u.bottom+di(r,"bottom")),t.left<u.left+di(o,"left")?c=-(u.left-t.left+di(r,"left")):t.right>u.right-di(o,"right")&&(c=t.right-u.right+di(r,"right")),c||d)if(a)s.defaultView.scrollBy(c,d);else{let f=l.scrollLeft,p=l.scrollTop;d&&(l.scrollTop+=d),c&&(l.scrollLeft+=c);let h=l.scrollLeft-f,m=l.scrollTop-p;t={left:t.left-h,top:t.top-m,right:t.right-h,bottom:t.bottom-m}}if(a||/^(fixed|sticky)$/.test(getComputedStyle(i).position))break}}function Uwe(e){let t=e.dom.getBoundingClientRect(),n=Math.max(0,t.top),o,r;for(let s=(t.left+t.right)/2,i=n+1;i<Math.min(innerHeight,t.bottom);i+=5){let l=e.root.elementFromPoint(s,i);if(!l||l==e.dom||!e.dom.contains(l))continue;let a=l.getBoundingClientRect();if(a.top>=n-20){o=l,r=a.top;break}}return{refDOM:o,refTop:r,stack:LA(e.dom)}}function LA(e){let t=[],n=e.ownerDocument;for(let o=e;o&&(t.push({dom:o,top:o.scrollTop,left:o.scrollLeft}),e!=n);o=Hp(o));return t}function Wwe({refDOM:e,refTop:t,stack:n}){let o=e?e.getBoundingClientRect().top:0;RA(n,o==0?0:o-t)}function RA(e,t){for(let n=0;n<e.length;n++){let{dom:o,top:r,left:s}=e[n];o.scrollTop!=r+t&&(o.scrollTop=r+t),o.scrollLeft!=s&&(o.scrollLeft=s)}}let Ru=null;function Kwe(e){if(e.setActive)return e.setActive();if(Ru)return e.focus(Ru);let t=LA(e);e.focus(Ru==null?{get preventScroll(){return Ru={preventScroll:!0},!0}}:void 0),Ru||(Ru=!1,RA(t,0))}function DA(e,t){let n,o=2e8,r,s=0,i=t.top,l=t.top,a,u;for(let c=e.firstChild,d=0;c;c=c.nextSibling,d++){let f;if(c.nodeType==1)f=c.getClientRects();else if(c.nodeType==3)f=vi(c).getClientRects();else continue;for(let p=0;p<f.length;p++){let h=f[p];if(h.top<=i&&h.bottom>=l){i=Math.max(h.bottom,i),l=Math.min(h.top,l);let m=h.left>t.left?h.left-t.left:h.right<t.left?t.left-h.right:0;if(m<o){n=c,o=m,r=m&&n.nodeType==3?{left:h.right<t.left?h.right:h.left,top:t.top}:t,c.nodeType==1&&m&&(s=d+(t.left>=(h.left+h.right)/2?1:0));continue}}else h.top>t.top&&!a&&h.left<=t.left&&h.right>=t.left&&(a=c,u={left:Math.max(h.left,Math.min(h.right,t.left)),top:h.top});!n&&(t.left>=h.right&&t.top>=h.top||t.left>=h.left&&t.top>=h.bottom)&&(s=d+1)}}return!n&&a&&(n=a,r=u,o=0),n&&n.nodeType==3?qwe(n,r):!n||o&&n.nodeType==1?{node:e,offset:s}:DA(n,r)}function qwe(e,t){let n=e.nodeValue.length,o=document.createRange();for(let r=0;r<n;r++){o.setEnd(e,r+1),o.setStart(e,r);let s=ll(o,1);if(s.top!=s.bottom&&mC(t,s))return{node:e,offset:r+(t.left>=(s.left+s.right)/2?1:0)}}return{node:e,offset:0}}function mC(e,t){return e.left>=t.left-1&&e.left<=t.right+1&&e.top>=t.top-1&&e.top<=t.bottom+1}function Gwe(e,t){let n=e.parentNode;return n&&/^li$/i.test(n.nodeName)&&t.left<e.getBoundingClientRect().left?n:e}function Ywe(e,t,n){let{node:o,offset:r}=DA(t,n),s=-1;if(o.nodeType==1&&!o.firstChild){let i=o.getBoundingClientRect();s=i.left!=i.right&&n.left>(i.left+i.right)/2?1:-1}return e.docView.posFromDOM(o,r,s)}function Zwe(e,t,n,o){let r=-1;for(let s=t,i=!1;s!=e.dom;){let l=e.docView.nearestDesc(s,!0);if(!l)return null;if(l.dom.nodeType==1&&(l.node.isBlock&&l.parent||!l.contentDOM)){let a=l.dom.getBoundingClientRect();if(l.node.isBlock&&l.parent&&(!i&&a.left>o.left||a.top>o.top?r=l.posBefore:(!i&&a.right<o.left||a.bottom<o.top)&&(r=l.posAfter),i=!0),!l.contentDOM&&r<0&&!l.node.isText)return(l.node.isBlock?o.top<(a.top+a.bottom)/2:o.left<(a.left+a.right)/2)?l.posBefore:l.posAfter}s=l.dom.parentNode}return r>-1?r:e.docView.posFromDOM(t,n,-1)}function FA(e,t,n){let o=e.childNodes.length;if(o&&n.top<n.bottom)for(let r=Math.max(0,Math.min(o-1,Math.floor(o*(t.top-n.top)/(n.bottom-n.top))-2)),s=r;;){let i=e.childNodes[s];if(i.nodeType==1){let l=i.getClientRects();for(let a=0;a<l.length;a++){let u=l[a];if(mC(t,u))return FA(i,t,u)}}if((s=(s+1)%o)==r)break}return e}function Jwe(e,t){let n=e.dom.ownerDocument,o,r=0,s=Vwe(n,t.left,t.top);s&&({node:o,offset:r}=s);let i=(e.root.elementFromPoint?e.root:n).elementFromPoint(t.left,t.top),l;if(!i||!e.dom.contains(i.nodeType!=1?i.parentNode:i)){let u=e.dom.getBoundingClientRect();if(!mC(t,u)||(i=FA(e.dom,t,u),!i))return null}if(Io)for(let u=i;o&&u;u=Hp(u))u.draggable&&(o=void 0);if(i=Gwe(i,t),o){if(vs&&o.nodeType==1&&(r=Math.min(r,o.childNodes.length),r<o.childNodes.length)){let c=o.childNodes[r],d;c.nodeName=="IMG"&&(d=c.getBoundingClientRect()).right<=t.left&&d.bottom>t.top&&r++}let u;Th&&r&&o.nodeType==1&&(u=o.childNodes[r-1]).nodeType==1&&u.contentEditable=="false"&&u.getBoundingClientRect().top>=t.top&&r--,o==e.dom&&r==o.childNodes.length-1&&o.lastChild.nodeType==1&&t.top>o.lastChild.getBoundingClientRect().bottom?l=e.state.doc.content.size:(r==0||o.nodeType!=1||o.childNodes[r-1].nodeName!="BR")&&(l=Zwe(e,o,r,t))}l==null&&(l=Ywe(e,i,t));let a=e.docView.nearestDesc(i,!0);return{pos:l,inside:a?a.posAtStart-a.border:-1}}function JS(e){return e.top<e.bottom||e.left<e.right}function ll(e,t){let n=e.getClientRects();if(n.length){let o=n[t<0?0:n.length-1];if(JS(o))return o}return Array.prototype.find.call(n,JS)||e.getBoundingClientRect()}const Xwe=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/;function VA(e,t,n){let{node:o,offset:r,atom:s}=e.docView.domFromPos(t,n<0?-1:1),i=Th||vs;if(o.nodeType==3)if(i&&(Xwe.test(o.nodeValue)||(n<0?!r:r==o.nodeValue.length))){let a=ll(vi(o,r,r),n);if(vs&&r&&/\s/.test(o.nodeValue[r-1])&&r<o.nodeValue.length){let u=ll(vi(o,r-1,r-1),-1);if(u.top==a.top){let c=ll(vi(o,r,r+1),-1);if(c.top!=a.top)return Gd(c,c.left<u.left)}}return a}else{let a=r,u=r,c=n<0?1:-1;return n<0&&!r?(u++,c=-1):n>=0&&r==o.nodeValue.length?(a--,c=1):n<0?a--:u++,Gd(ll(vi(o,a,u),c),c<0)}if(!e.state.doc.resolve(t-(s||0)).parent.inlineContent){if(s==null&&r&&(n<0||r==Bs(o))){let a=o.childNodes[r-1];if(a.nodeType==1)return Ry(a.getBoundingClientRect(),!1)}if(s==null&&r<Bs(o)){let a=o.childNodes[r];if(a.nodeType==1)return Ry(a.getBoundingClientRect(),!0)}return Ry(o.getBoundingClientRect(),n>=0)}if(s==null&&r&&(n<0||r==Bs(o))){let a=o.childNodes[r-1],u=a.nodeType==3?vi(a,Bs(a)-(i?0:1)):a.nodeType==1&&(a.nodeName!="BR"||!a.nextSibling)?a:null;if(u)return Gd(ll(u,1),!1)}if(s==null&&r<Bs(o)){let a=o.childNodes[r];for(;a.pmViewDesc&&a.pmViewDesc.ignoreForCoords;)a=a.nextSibling;let u=a?a.nodeType==3?vi(a,0,i?0:1):a.nodeType==1?a:null:null;if(u)return Gd(ll(u,-1),!0)}return Gd(ll(o.nodeType==3?vi(o):o,-n),n>=0)}function Gd(e,t){if(e.width==0)return e;let n=t?e.left:e.right;return{top:e.top,bottom:e.bottom,left:n,right:n}}function Ry(e,t){if(e.height==0)return e;let n=t?e.top:e.bottom;return{top:n,bottom:n,left:e.left,right:e.right}}function BA(e,t,n){let o=e.state,r=e.root.activeElement;o!=t&&e.updateState(t),r!=e.dom&&e.focus();try{return n()}finally{o!=t&&e.updateState(o),r!=e.dom&&r&&r.focus()}}function Qwe(e,t,n){let o=t.selection,r=n=="up"?o.$from:o.$to;return BA(e,t,()=>{let{node:s}=e.docView.domFromPos(r.pos,n=="up"?-1:1);for(;;){let l=e.docView.nearestDesc(s,!0);if(!l)break;if(l.node.isBlock){s=l.contentDOM||l.dom;break}s=l.dom.parentNode}let i=VA(e,r.pos,1);for(let l=s.firstChild;l;l=l.nextSibling){let a;if(l.nodeType==1)a=l.getClientRects();else if(l.nodeType==3)a=vi(l,0,l.nodeValue.length).getClientRects();else continue;for(let u=0;u<a.length;u++){let c=a[u];if(c.bottom>c.top+1&&(n=="up"?i.top-c.top>(c.bottom-i.top)*2:c.bottom-i.bottom>(i.bottom-c.top)*2))return!1}}return!0})}const e3e=/[\u0590-\u08ac]/;function t3e(e,t,n){let{$head:o}=t.selection;if(!o.parent.isTextblock)return!1;let r=o.parentOffset,s=!r,i=r==o.parent.content.size,l=e.domSelection();return l?!e3e.test(o.parent.textContent)||!l.modify?n=="left"||n=="backward"?s:i:BA(e,t,()=>{let{focusNode:a,focusOffset:u,anchorNode:c,anchorOffset:d}=e.domSelectionRange(),f=l.caretBidiLevel;l.modify("move",n,"character");let p=o.depth?e.docView.domAfterPos(o.before()):e.dom,{focusNode:h,focusOffset:m}=e.domSelectionRange(),y=h&&!p.contains(h.nodeType==1?h:h.parentNode)||a==h&&u==m;try{l.collapse(c,d),a&&(a!=c||u!=d)&&l.extend&&l.extend(a,u)}catch{}return f!=null&&(l.caretBidiLevel=f),y}):o.pos==o.start()||o.pos==o.end()}let XS=null,QS=null,e9=!1;function n3e(e,t,n){return XS==t&&QS==n?e9:(XS=t,QS=n,e9=n=="up"||n=="down"?Qwe(e,t,n):t3e(e,t,n))}const Dr=0,t9=1,Ra=2,Xs=3;class Oh{constructor(t,n,o,r){this.parent=t,this.children=n,this.dom=o,this.contentDOM=r,this.dirty=Dr,o.pmViewDesc=this}matchesWidget(t){return!1}matchesMark(t){return!1}matchesNode(t,n,o){return!1}matchesHack(t){return!1}parseRule(){return null}stopEvent(t){return!1}get size(){let t=0;for(let n=0;n<this.children.length;n++)t+=this.children[n].size;return t}get border(){return 0}destroy(){this.parent=void 0,this.dom.pmViewDesc==this&&(this.dom.pmViewDesc=void 0);for(let t=0;t<this.children.length;t++)this.children[t].destroy()}posBeforeChild(t){for(let n=0,o=this.posAtStart;;n++){let r=this.children[n];if(r==t)return o;o+=r.size}}get posBefore(){return this.parent.posBeforeChild(this)}get posAtStart(){return this.parent?this.parent.posBeforeChild(this)+this.border:0}get posAfter(){return this.posBefore+this.size}get posAtEnd(){return this.posAtStart+this.size-2*this.border}localPosFromDOM(t,n,o){if(this.contentDOM&&this.contentDOM.contains(t.nodeType==1?t:t.parentNode))if(o<0){let s,i;if(t==this.contentDOM)s=t.childNodes[n-1];else{for(;t.parentNode!=this.contentDOM;)t=t.parentNode;s=t.previousSibling}for(;s&&!((i=s.pmViewDesc)&&i.parent==this);)s=s.previousSibling;return s?this.posBeforeChild(i)+i.size:this.posAtStart}else{let s,i;if(t==this.contentDOM)s=t.childNodes[n];else{for(;t.parentNode!=this.contentDOM;)t=t.parentNode;s=t.nextSibling}for(;s&&!((i=s.pmViewDesc)&&i.parent==this);)s=s.nextSibling;return s?this.posBeforeChild(i):this.posAtEnd}let r;if(t==this.dom&&this.contentDOM)r=n>no(this.contentDOM);else if(this.contentDOM&&this.contentDOM!=this.dom&&this.dom.contains(this.contentDOM))r=t.compareDocumentPosition(this.contentDOM)&2;else if(this.dom.firstChild){if(n==0)for(let s=t;;s=s.parentNode){if(s==this.dom){r=!1;break}if(s.previousSibling)break}if(r==null&&n==t.childNodes.length)for(let s=t;;s=s.parentNode){if(s==this.dom){r=!0;break}if(s.nextSibling)break}}return r??o>0?this.posAtEnd:this.posAtStart}nearestDesc(t,n=!1){for(let o=!0,r=t;r;r=r.parentNode){let s=this.getDesc(r),i;if(s&&(!n||s.node))if(o&&(i=s.nodeDOM)&&!(i.nodeType==1?i.contains(t.nodeType==1?t:t.parentNode):i==t))o=!1;else return s}}getDesc(t){let n=t.pmViewDesc;for(let o=n;o;o=o.parent)if(o==this)return n}posFromDOM(t,n,o){for(let r=t;r;r=r.parentNode){let s=this.getDesc(r);if(s)return s.localPosFromDOM(t,n,o)}return-1}descAt(t){for(let n=0,o=0;n<this.children.length;n++){let r=this.children[n],s=o+r.size;if(o==t&&s!=o){for(;!r.border&&r.children.length;)r=r.children[0];return r}if(t<s)return r.descAt(t-o-r.border);o=s}}domFromPos(t,n){if(!this.contentDOM)return{node:this.dom,offset:0,atom:t+1};let o=0,r=0;for(let s=0;o<this.children.length;o++){let i=this.children[o],l=s+i.size;if(l>t||i instanceof jA){r=t-s;break}s=l}if(r)return this.children[o].domFromPos(r-this.children[o].border,n);for(let s;o&&!(s=this.children[o-1]).size&&s instanceof zA&&s.side>=0;o--);if(n<=0){let s,i=!0;for(;s=o?this.children[o-1]:null,!(!s||s.dom.parentNode==this.contentDOM);o--,i=!1);return s&&n&&i&&!s.border&&!s.domAtom?s.domFromPos(s.size,n):{node:this.contentDOM,offset:s?no(s.dom)+1:0}}else{let s,i=!0;for(;s=o<this.children.length?this.children[o]:null,!(!s||s.dom.parentNode==this.contentDOM);o++,i=!1);return s&&i&&!s.border&&!s.domAtom?s.domFromPos(0,n):{node:this.contentDOM,offset:s?no(s.dom):this.contentDOM.childNodes.length}}}parseRange(t,n,o=0){if(this.children.length==0)return{node:this.contentDOM,from:t,to:n,fromOffset:0,toOffset:this.contentDOM.childNodes.length};let r=-1,s=-1;for(let i=o,l=0;;l++){let a=this.children[l],u=i+a.size;if(r==-1&&t<=u){let c=i+a.border;if(t>=c&&n<=u-a.border&&a.node&&a.contentDOM&&this.contentDOM.contains(a.contentDOM))return a.parseRange(t,n,c);t=i;for(let d=l;d>0;d--){let f=this.children[d-1];if(f.size&&f.dom.parentNode==this.contentDOM&&!f.emptyChildAt(1)){r=no(f.dom)+1;break}t-=f.size}r==-1&&(r=0)}if(r>-1&&(u>n||l==this.children.length-1)){n=u;for(let c=l+1;c<this.children.length;c++){let d=this.children[c];if(d.size&&d.dom.parentNode==this.contentDOM&&!d.emptyChildAt(-1)){s=no(d.dom);break}n+=d.size}s==-1&&(s=this.contentDOM.childNodes.length);break}i=u}return{node:this.contentDOM,from:t,to:n,fromOffset:r,toOffset:s}}emptyChildAt(t){if(this.border||!this.contentDOM||!this.children.length)return!1;let n=this.children[t<0?0:this.children.length-1];return n.size==0||n.emptyChildAt(t)}domAfterPos(t){let{node:n,offset:o}=this.domFromPos(t,0);if(n.nodeType!=1||o==n.childNodes.length)throw new RangeError("No node after pos "+t);return n.childNodes[o]}setSelection(t,n,o,r=!1){let s=Math.min(t,n),i=Math.max(t,n);for(let f=0,p=0;f<this.children.length;f++){let h=this.children[f],m=p+h.size;if(s>p&&i<m)return h.setSelection(t-p-h.border,n-p-h.border,o,r);p=m}let l=this.domFromPos(t,t?-1:1),a=n==t?l:this.domFromPos(n,n?-1:1),u=o.getSelection(),c=!1;if((vs||Io)&&t==n){let{node:f,offset:p}=l;if(f.nodeType==3){if(c=!!(p&&f.nodeValue[p-1]==`
115 `),c&&p==f.nodeValue.length)for(let h=f,m;h;h=h.parentNode){if(m=h.nextSibling){m.nodeName=="BR"&&(l=a={node:m.parentNode,offset:no(m)+1});break}let y=h.pmViewDesc;if(y&&y.node&&y.node.isBlock)break}}else{let h=f.childNodes[p-1];c=h&&(h.nodeName=="BR"||h.contentEditable=="false")}}if(vs&&u.focusNode&&u.focusNode!=a.node&&u.focusNode.nodeType==1){let f=u.focusNode.childNodes[u.focusOffset];f&&f.contentEditable=="false"&&(r=!0)}if(!(r||c&&Io)&&hu(l.node,l.offset,u.anchorNode,u.anchorOffset)&&hu(a.node,a.offset,u.focusNode,u.focusOffset))return;let d=!1;if((u.extend||t==n)&&!c){u.collapse(l.node,l.offset);try{t!=n&&u.extend(a.node,a.offset),d=!0}catch{}}if(!d){if(t>n){let p=l;l=a,a=p}let f=document.createRange();f.setEnd(a.node,a.offset),f.setStart(l.node,l.offset),u.removeAllRanges(),u.addRange(f)}}ignoreMutation(t){return!this.contentDOM&&t.type!="selection"}get contentLost(){return this.contentDOM&&this.contentDOM!=this.dom&&!this.dom.contains(this.contentDOM)}markDirty(t,n){for(let o=0,r=0;r<this.children.length;r++){let s=this.children[r],i=o+s.size;if(o==i?t<=i&&n>=o:t<i&&n>o){let l=o+s.border,a=i-s.border;if(t>=l&&n<=a){this.dirty=t==o||n==i?Ra:t9,t==l&&n==a&&(s.contentLost||s.dom.parentNode!=this.contentDOM)?s.dirty=Xs:s.markDirty(t-l,n-l);return}else s.dirty=s.dom==s.contentDOM&&s.dom.parentNode==this.contentDOM&&!s.children.length?Ra:Xs}o=i}this.dirty=Ra}markParentsDirty(){let t=1;for(let n=this.parent;n;n=n.parent,t++){let o=t==1?Ra:t9;n.dirty<o&&(n.dirty=o)}}get domAtom(){return!1}get ignoreForCoords(){return!1}isText(t){return!1}}class zA extends Oh{constructor(t,n,o,r){let s,i=n.type.toDOM;if(typeof i=="function"&&(i=i(o,()=>{if(!s)return r;if(s.parent)return s.parent.posBeforeChild(s)})),!n.type.spec.raw){if(i.nodeType!=1){let l=document.createElement("span");l.appendChild(i),i=l}i.contentEditable="false",i.classList.add("ProseMirror-widget")}super(t,[],i,null),this.widget=n,this.widget=n,s=this}matchesWidget(t){return this.dirty==Dr&&t.type.eq(this.widget.type)}parseRule(){return{ignore:!0}}stopEvent(t){let n=this.widget.spec.stopEvent;return n?n(t):!1}ignoreMutation(t){return t.type!="selection"||this.widget.spec.ignoreSelection}destroy(){this.widget.type.destroy(this.dom),super.destroy()}get domAtom(){return!0}get side(){return this.widget.type.side}}class o3e extends Oh{constructor(t,n,o,r){super(t,[],n,null),this.textDOM=o,this.text=r}get size(){return this.text.length}localPosFromDOM(t,n){return t!=this.textDOM?this.posAtStart+(n?this.size:0):this.posAtStart+n}domFromPos(t){return{node:this.textDOM,offset:t}}ignoreMutation(t){return t.type==="characterData"&&t.target.nodeValue==t.oldValue}}class mu extends Oh{constructor(t,n,o,r){super(t,[],o,r),this.mark=n}static create(t,n,o,r){let s=r.nodeViews[n.type.name],i=s&&s(n,r,o);return(!i||!i.dom)&&(i=ta.renderSpec(document,n.type.spec.toDOM(n,o),null,n.attrs)),new mu(t,n,i.dom,i.contentDOM||i.dom)}parseRule(){return this.dirty&Xs||this.mark.type.spec.reparseInView?null:{mark:this.mark.type.name,attrs:this.mark.attrs,contentElement:this.contentDOM}}matchesMark(t){return this.dirty!=Xs&&this.mark.eq(t)}markDirty(t,n){if(super.markDirty(t,n),this.dirty!=Dr){let o=this.parent;for(;!o.node;)o=o.parent;o.dirty<this.dirty&&(o.dirty=this.dirty),this.dirty=Dr}}slice(t,n,o){let r=mu.create(this.parent,this.mark,!0,o),s=this.children,i=this.size;n<i&&(s=l2(s,n,i,o)),t>0&&(s=l2(s,0,t,o));for(let l=0;l<s.length;l++)s[l].parent=r;return r.children=s,r}}class Dl extends Oh{constructor(t,n,o,r,s,i,l,a,u){super(t,[],s,i),this.node=n,this.outerDeco=o,this.innerDeco=r,this.nodeDOM=l}static create(t,n,o,r,s,i){let l=s.nodeViews[n.type.name],a,u=l&&l(n,s,()=>{if(!a)return i;if(a.parent)return a.parent.posBeforeChild(a)},o,r),c=u&&u.dom,d=u&&u.contentDOM;if(n.isText){if(!c)c=document.createTextNode(n.text);else if(c.nodeType!=3)throw new RangeError("Text must be rendered as a DOM text node")}else c||({dom:c,contentDOM:d}=ta.renderSpec(document,n.type.spec.toDOM(n),null,n.attrs));!d&&!n.isText&&c.nodeName!="BR"&&(c.hasAttribute("contenteditable")||(c.contentEditable="false"),n.type.spec.draggable&&(c.draggable=!0));let f=c;return c=WA(c,o,n),u?a=new r3e(t,n,o,r,c,d||null,f,u,s,i+1):n.isText?new pv(t,n,o,r,c,f,s):new Dl(t,n,o,r,c,d||null,f,s,i+1)}parseRule(){if(this.node.type.spec.reparseInView)return null;let t={node:this.node.type.name,attrs:this.node.attrs};if(this.node.type.whitespace=="pre"&&(t.preserveWhitespace="full"),!this.contentDOM)t.getContent=()=>this.node.content;else if(!this.contentLost)t.contentElement=this.contentDOM;else{for(let n=this.children.length-1;n>=0;n--){let o=this.children[n];if(this.dom.contains(o.dom.parentNode)){t.contentElement=o.dom.parentNode;break}}t.contentElement||(t.getContent=()=>Ue.empty)}return t}matchesNode(t,n,o){return this.dirty==Dr&&t.eq(this.node)&&i2(n,this.outerDeco)&&o.eq(this.innerDeco)}get size(){return this.node.nodeSize}get border(){return this.node.isLeaf?0:1}updateChildren(t,n){let o=this.node.inlineContent,r=n,s=t.composing?this.localCompositionInfo(t,n):null,i=s&&s.pos>-1?s:null,l=s&&s.pos<0,a=new i3e(this,i&&i.node,t);u3e(this.node,this.innerDeco,(u,c,d)=>{u.spec.marks?a.syncToMarks(u.spec.marks,o,t):u.type.side>=0&&!d&&a.syncToMarks(c==this.node.childCount?Yt.none:this.node.child(c).marks,o,t),a.placeWidget(u,t,r)},(u,c,d,f)=>{a.syncToMarks(u.marks,o,t);let p;a.findNodeMatch(u,c,d,f)||l&&t.state.selection.from>r&&t.state.selection.to<r+u.nodeSize&&(p=a.findIndexWithChild(s.node))>-1&&a.updateNodeAt(u,c,d,p,t)||a.updateNextNode(u,c,d,t,f,r)||a.addNode(u,c,d,t,r),r+=u.nodeSize}),a.syncToMarks([],o,t),this.node.isTextblock&&a.addTextblockHacks(),a.destroyRest(),(a.changed||this.dirty==Ra)&&(i&&this.protectLocalComposition(t,i),HA(this.contentDOM,this.children,t),pd&&c3e(this.dom))}localCompositionInfo(t,n){let{from:o,to:r}=t.state.selection;if(!(t.state.selection instanceof ht)||o<n||r>n+this.node.content.size)return null;let s=t.input.compositionNode;if(!s||!this.dom.contains(s.parentNode))return null;if(this.node.inlineContent){let i=s.nodeValue,l=d3e(this.node.content,i,o-n,r-n);return l<0?null:{node:s,pos:l,text:i}}else return{node:s,pos:-1,text:""}}protectLocalComposition(t,{node:n,pos:o,text:r}){if(this.getDesc(n))return;let s=n;for(;s.parentNode!=this.contentDOM;s=s.parentNode){for(;s.previousSibling;)s.parentNode.removeChild(s.previousSibling);for(;s.nextSibling;)s.parentNode.removeChild(s.nextSibling);s.pmViewDesc&&(s.pmViewDesc=void 0)}let i=new o3e(this,s,n,r);t.input.compositionNodes.push(i),this.children=l2(this.children,o,o+r.length,t,i)}update(t,n,o,r){return this.dirty==Xs||!t.sameMarkup(this.node)?!1:(this.updateInner(t,n,o,r),!0)}updateInner(t,n,o,r){this.updateOuterDeco(n),this.node=t,this.innerDeco=o,this.contentDOM&&this.updateChildren(r,this.posAtStart),this.dirty=Dr}updateOuterDeco(t){if(i2(t,this.outerDeco))return;let n=this.nodeDOM.nodeType!=1,o=this.dom;this.dom=UA(this.dom,this.nodeDOM,s2(this.outerDeco,this.node,n),s2(t,this.node,n)),this.dom!=o&&(o.pmViewDesc=void 0,this.dom.pmViewDesc=this),this.outerDeco=t}selectNode(){this.nodeDOM.nodeType==1&&this.nodeDOM.classList.add("ProseMirror-selectednode"),(this.contentDOM||!this.node.type.spec.draggable)&&(this.dom.draggable=!0)}deselectNode(){this.nodeDOM.nodeType==1&&(this.nodeDOM.classList.remove("ProseMirror-selectednode"),(this.contentDOM||!this.node.type.spec.draggable)&&this.dom.removeAttribute("draggable"))}get domAtom(){return this.node.isAtom}}function n9(e,t,n,o,r){WA(o,t,e);let s=new Dl(void 0,e,t,n,o,o,o,r,0);return s.contentDOM&&s.updateChildren(r,0),s}class pv extends Dl{constructor(t,n,o,r,s,i,l){super(t,n,o,r,s,null,i,l,0)}parseRule(){let t=this.nodeDOM.parentNode;for(;t&&t!=this.dom&&!t.pmIsDeco;)t=t.parentNode;return{skip:t||!0}}update(t,n,o,r){return this.dirty==Xs||this.dirty!=Dr&&!this.inParent()||!t.sameMarkup(this.node)?!1:(this.updateOuterDeco(n),(this.dirty!=Dr||t.text!=this.node.text)&&t.text!=this.nodeDOM.nodeValue&&(this.nodeDOM.nodeValue=t.text,r.trackWrites==this.nodeDOM&&(r.trackWrites=null)),this.node=t,this.dirty=Dr,!0)}inParent(){let t=this.parent.contentDOM;for(let n=this.nodeDOM;n;n=n.parentNode)if(n==t)return!0;return!1}domFromPos(t){return{node:this.nodeDOM,offset:t}}localPosFromDOM(t,n,o){return t==this.nodeDOM?this.posAtStart+Math.min(n,this.node.text.length):super.localPosFromDOM(t,n,o)}ignoreMutation(t){return t.type!="characterData"&&t.type!="selection"}slice(t,n,o){let r=this.node.cut(t,n),s=document.createTextNode(r.text);return new pv(this.parent,r,this.outerDeco,this.innerDeco,s,s,o)}markDirty(t,n){super.markDirty(t,n),this.dom!=this.nodeDOM&&(t==0||n==this.nodeDOM.nodeValue.length)&&(this.dirty=Xs)}get domAtom(){return!1}isText(t){return this.node.text==t}}class jA extends Oh{parseRule(){return{ignore:!0}}matchesHack(t){return this.dirty==Dr&&this.dom.nodeName==t}get domAtom(){return!0}get ignoreForCoords(){return this.dom.nodeName=="IMG"}}class r3e extends Dl{constructor(t,n,o,r,s,i,l,a,u,c){super(t,n,o,r,s,i,l,u,c),this.spec=a}update(t,n,o,r){if(this.dirty==Xs)return!1;if(this.spec.update){let s=this.spec.update(t,n,o);return s&&this.updateInner(t,n,o,r),s}else return!this.contentDOM&&!t.isLeaf?!1:super.update(t,n,o,r)}selectNode(){this.spec.selectNode?this.spec.selectNode():super.selectNode()}deselectNode(){this.spec.deselectNode?this.spec.deselectNode():super.deselectNode()}setSelection(t,n,o,r){this.spec.setSelection?this.spec.setSelection(t,n,o):super.setSelection(t,n,o,r)}destroy(){this.spec.destroy&&this.spec.destroy(),super.destroy()}stopEvent(t){return this.spec.stopEvent?this.spec.stopEvent(t):!1}ignoreMutation(t){return this.spec.ignoreMutation?this.spec.ignoreMutation(t):super.ignoreMutation(t)}}function HA(e,t,n){let o=e.firstChild,r=!1;for(let s=0;s<t.length;s++){let i=t[s],l=i.dom;if(l.parentNode==e){for(;l!=o;)o=o9(o),r=!0;o=o.nextSibling}else r=!0,e.insertBefore(l,o);if(i instanceof mu){let a=o?o.previousSibling:e.lastChild;HA(i.contentDOM,i.children,n),o=a?a.nextSibling:e.firstChild}}for(;o;)o=o9(o),r=!0;r&&n.trackWrites==e&&(n.trackWrites=null)}const np=function(e){e&&(this.nodeName=e)};np.prototype=Object.create(null);const Da=[new np];function s2(e,t,n){if(e.length==0)return Da;let o=n?Da[0]:new np,r=[o];for(let s=0;s<e.length;s++){let i=e[s].type.attrs;if(i){i.nodeName&&r.push(o=new np(i.nodeName));for(let l in i){let a=i[l];a!=null&&(n&&r.length==1&&r.push(o=new np(t.isInline?"span":"div")),l=="class"?o.class=(o.class?o.class+" ":"")+a:l=="style"?o.style=(o.style?o.style+";":"")+a:l!="nodeName"&&(o[l]=a))}}}return r}function UA(e,t,n,o){if(n==Da&&o==Da)return t;let r=t;for(let s=0;s<o.length;s++){let i=o[s],l=n[s];if(s){let a;l&&l.nodeName==i.nodeName&&r!=e&&(a=r.parentNode)&&a.nodeName.toLowerCase()==i.nodeName||(a=document.createElement(i.nodeName),a.pmIsDeco=!0,a.appendChild(r),l=Da[0]),r=a}s3e(r,l||Da[0],i)}return r}function s3e(e,t,n){for(let o in t)o!="class"&&o!="style"&&o!="nodeName"&&!(o in n)&&e.removeAttribute(o);for(let o in n)o!="class"&&o!="style"&&o!="nodeName"&&n[o]!=t[o]&&e.setAttribute(o,n[o]);if(t.class!=n.class){let o=t.class?t.class.split(" ").filter(Boolean):[],r=n.class?n.class.split(" ").filter(Boolean):[];for(let s=0;s<o.length;s++)r.indexOf(o[s])==-1&&e.classList.remove(o[s]);for(let s=0;s<r.length;s++)o.indexOf(r[s])==-1&&e.classList.add(r[s]);e.classList.length==0&&e.removeAttribute("class")}if(t.style!=n.style){if(t.style){let o=/\s*([\w\-\xa1-\uffff]+)\s*:(?:"(?:\\.|[^"])*"|'(?:\\.|[^'])*'|\(.*?\)|[^;])*/g,r;for(;r=o.exec(t.style);)e.style.removeProperty(r[1])}n.style&&(e.style.cssText+=n.style)}}function WA(e,t,n){return UA(e,e,Da,s2(t,n,e.nodeType!=1))}function i2(e,t){if(e.length!=t.length)return!1;for(let n=0;n<e.length;n++)if(!e[n].type.eq(t[n].type))return!1;return!0}function o9(e){let t=e.nextSibling;return e.parentNode.removeChild(e),t}class i3e{constructor(t,n,o){this.lock=n,this.view=o,this.index=0,this.stack=[],this.changed=!1,this.top=t,this.preMatch=l3e(t.node.content,t)}destroyBetween(t,n){if(t!=n){for(let o=t;o<n;o++)this.top.children[o].destroy();this.top.children.splice(t,n-t),this.changed=!0}}destroyRest(){this.destroyBetween(this.index,this.top.children.length)}syncToMarks(t,n,o){let r=0,s=this.stack.length>>1,i=Math.min(s,t.length);for(;r<i&&(r==s-1?this.top:this.stack[r+1<<1]).matchesMark(t[r])&&t[r].type.spec.spanning!==!1;)r++;for(;r<s;)this.destroyRest(),this.top.dirty=Dr,this.index=this.stack.pop(),this.top=this.stack.pop(),s--;for(;s<t.length;){this.stack.push(this.top,this.index+1);let l=-1;for(let a=this.index;a<Math.min(this.index+3,this.top.children.length);a++){let u=this.top.children[a];if(u.matchesMark(t[s])&&!this.isLocked(u.dom)){l=a;break}}if(l>-1)l>this.index&&(this.changed=!0,this.destroyBetween(this.index,l)),this.top=this.top.children[this.index];else{let a=mu.create(this.top,t[s],n,o);this.top.children.splice(this.index,0,a),this.top=a,this.changed=!0}this.index=0,s++}}findNodeMatch(t,n,o,r){let s=-1,i;if(r>=this.preMatch.index&&(i=this.preMatch.matches[r-this.preMatch.index]).parent==this.top&&i.matchesNode(t,n,o))s=this.top.children.indexOf(i,this.index);else for(let l=this.index,a=Math.min(this.top.children.length,l+5);l<a;l++){let u=this.top.children[l];if(u.matchesNode(t,n,o)&&!this.preMatch.matched.has(u)){s=l;break}}return s<0?!1:(this.destroyBetween(this.index,s),this.index++,!0)}updateNodeAt(t,n,o,r,s){let i=this.top.children[r];return i.dirty==Xs&&i.dom==i.contentDOM&&(i.dirty=Ra),i.update(t,n,o,s)?(this.destroyBetween(this.index,r),this.index++,!0):!1}findIndexWithChild(t){for(;;){let n=t.parentNode;if(!n)return-1;if(n==this.top.contentDOM){let o=t.pmViewDesc;if(o){for(let r=this.index;r<this.top.children.length;r++)if(this.top.children[r]==o)return r}return-1}t=n}}updateNextNode(t,n,o,r,s,i){for(let l=this.index;l<this.top.children.length;l++){let a=this.top.children[l];if(a instanceof Dl){let u=this.preMatch.matched.get(a);if(u!=null&&u!=s)return!1;let c=a.dom,d,f=this.isLocked(c)&&!(t.isText&&a.node&&a.node.isText&&a.nodeDOM.nodeValue==t.text&&a.dirty!=Xs&&i2(n,a.outerDeco));if(!f&&a.update(t,n,o,r))return this.destroyBetween(this.index,l),a.dom!=c&&(this.changed=!0),this.index++,!0;if(!f&&(d=this.recreateWrapper(a,t,n,o,r,i)))return this.top.children[this.index]=d,d.contentDOM&&(d.dirty=Ra,d.updateChildren(r,i+1),d.dirty=Dr),this.changed=!0,this.index++,!0;break}}return!1}recreateWrapper(t,n,o,r,s,i){if(t.dirty||n.isAtom||!t.children.length||!t.node.content.eq(n.content))return null;let l=Dl.create(this.top,n,o,r,s,i);if(l.contentDOM){l.children=t.children,t.children=[];for(let a of l.children)a.parent=l}return t.destroy(),l}addNode(t,n,o,r,s){let i=Dl.create(this.top,t,n,o,r,s);i.contentDOM&&i.updateChildren(r,s+1),this.top.children.splice(this.index++,0,i),this.changed=!0}placeWidget(t,n,o){let r=this.index<this.top.children.length?this.top.children[this.index]:null;if(r&&r.matchesWidget(t)&&(t==r.widget||!r.widget.type.toDOM.parentNode))this.index++;else{let s=new zA(this.top,t,n,o);this.top.children.splice(this.index++,0,s),this.changed=!0}}addTextblockHacks(){let t=this.top.children[this.index-1],n=this.top;for(;t instanceof mu;)n=t,t=n.children[n.children.length-1];(!t||!(t instanceof pv)||/\n$/.test(t.node.text)||this.view.requiresGeckoHackNode&&/\s$/.test(t.node.text))&&((Io||mo)&&t&&t.dom.contentEditable=="false"&&this.addHackNode("IMG",n),this.addHackNode("BR",this.top))}addHackNode(t,n){if(n==this.top&&this.index<n.children.length&&n.children[this.index].matchesHack(t))this.index++;else{let o=document.createElement(t);t=="IMG"&&(o.className="ProseMirror-separator",o.alt=""),t=="BR"&&(o.className="ProseMirror-trailingBreak");let r=new jA(this.top,[],o,null);n!=this.top?n.children.push(r):n.children.splice(this.index++,0,r),this.changed=!0}}isLocked(t){return this.lock&&(t==this.lock||t.nodeType==1&&t.contains(this.lock.parentNode))}}function l3e(e,t){let n=t,o=n.children.length,r=e.childCount,s=new Map,i=[];e:for(;r>0;){let l;for(;;)if(o){let u=n.children[o-1];if(u instanceof mu)n=u,o=u.children.length;else{l=u,o--;break}}else{if(n==t)break e;o=n.parent.children.indexOf(n),n=n.parent}let a=l.node;if(a){if(a!=e.child(r-1))break;--r,s.set(l,r),i.push(l)}}return{index:r,matched:s,matches:i.reverse()}}function a3e(e,t){return e.type.side-t.type.side}function u3e(e,t,n,o){let r=t.locals(e),s=0;if(r.length==0){for(let u=0;u<e.childCount;u++){let c=e.child(u);o(c,r,t.forChild(s,c),u),s+=c.nodeSize}return}let i=0,l=[],a=null;for(let u=0;;){let c,d;for(;i<r.length&&r[i].to==s;){let y=r[i++];y.widget&&(c?(d||(d=[c])).push(y):c=y)}if(c)if(d){d.sort(a3e);for(let y=0;y<d.length;y++)n(d[y],u,!!a)}else n(c,u,!!a);let f,p;if(a)p=-1,f=a,a=null;else if(u<e.childCount)p=u,f=e.child(u++);else break;for(let y=0;y<l.length;y++)l[y].to<=s&&l.splice(y--,1);for(;i<r.length&&r[i].from<=s&&r[i].to>s;)l.push(r[i++]);let h=s+f.nodeSize;if(f.isText){let y=h;i<r.length&&r[i].from<y&&(y=r[i].from);for(let v=0;v<l.length;v++)l[v].to<y&&(y=l[v].to);y<h&&(a=f.cut(y-s),f=f.cut(0,y-s),h=y,p=-1)}else for(;i<r.length&&r[i].to<h;)i++;let m=f.isInline&&!f.isLeaf?l.filter(y=>!y.inline):l.slice();o(f,m,t.forChild(s,f),p),s=h}}function c3e(e){if(e.nodeName=="UL"||e.nodeName=="OL"){let t=e.style.cssText;e.style.cssText=t+"; list-style: square !important",window.getComputedStyle(e).listStyle,e.style.cssText=t}}function d3e(e,t,n,o){for(let r=0,s=0;r<e.childCount&&s<=o;){let i=e.child(r++),l=s;if(s+=i.nodeSize,!i.isText)continue;let a=i.text;for(;r<e.childCount;){let u=e.child(r++);if(s+=u.nodeSize,!u.isText)break;a+=u.text}if(s>=n){if(s>=o&&a.slice(o-t.length-l,o-l)==t)return o-t.length;let u=l<o?a.lastIndexOf(t,o-l-1):-1;if(u>=0&&u+t.length+l>=n)return l+u;if(n==o&&a.length>=o+t.length-l&&a.slice(o-l,o-l+t.length)==t)return o}}return-1}function l2(e,t,n,o,r){let s=[];for(let i=0,l=0;i<e.length;i++){let a=e[i],u=l,c=l+=a.size;u>=n||c<=t?s.push(a):(u<t&&s.push(a.slice(0,t-u,o)),r&&(s.push(r),r=void 0),c>n&&s.push(a.slice(n-u,a.size,o)))}return s}function gC(e,t=null){let n=e.domSelectionRange(),o=e.state.doc;if(!n.focusNode)return null;let r=e.docView.nearestDesc(n.focusNode),s=r&&r.size==0,i=e.docView.posFromDOM(n.focusNode,n.focusOffset,1);if(i<0)return null;let l=o.resolve(i),a,u;if(fv(n)){for(a=l;r&&!r.node;)r=r.parent;let c=r.node;if(r&&c.isAtom&&mt.isSelectable(c)&&r.parent&&!(c.isInline&&Dwe(n.focusNode,n.focusOffset,r.dom))){let d=r.posBefore;u=new mt(i==d?l:o.resolve(d))}}else{let c=e.docView.posFromDOM(n.anchorNode,n.anchorOffset,1);if(c<0)return null;a=o.resolve(c)}if(!u){let c=t=="pointer"||e.state.selection.head<l.pos&&!s?1:-1;u=vC(e,a,l,c)}return u}function KA(e){return e.editable?e.hasFocus():GA(e)&&document.activeElement&&document.activeElement.contains(e.dom)}function Oi(e,t=!1){let n=e.state.selection;if(qA(e,n),!!KA(e)){if(!t&&e.input.mouseDown&&e.input.mouseDown.allowDefault&&mo){let o=e.domSelectionRange(),r=e.domObserver.currentSelection;if(o.anchorNode&&r.anchorNode&&hu(o.anchorNode,o.anchorOffset,r.anchorNode,r.anchorOffset)){e.input.mouseDown.delayedSelectionSync=!0,e.domObserver.setCurSelection();return}}if(e.domObserver.disconnectSelection(),e.cursorWrapper)p3e(e);else{let{anchor:o,head:r}=n,s,i;r9&&!(n instanceof ht)&&(n.$from.parent.inlineContent||(s=s9(e,n.from)),!n.empty&&!n.$from.parent.inlineContent&&(i=s9(e,n.to))),e.docView.setSelection(o,r,e.root,t),r9&&(s&&i9(s),i&&i9(i)),n.visible?e.dom.classList.remove("ProseMirror-hideselection"):(e.dom.classList.add("ProseMirror-hideselection"),"onselectionchange"in document&&f3e(e))}e.domObserver.setCurSelection(),e.domObserver.connectSelection()}}const r9=Io||mo&&PA<63;function s9(e,t){let{node:n,offset:o}=e.docView.domFromPos(t,0),r=o<n.childNodes.length?n.childNodes[o]:null,s=o?n.childNodes[o-1]:null;if(Io&&r&&r.contentEditable=="false")return Dy(r);if((!r||r.contentEditable=="false")&&(!s||s.contentEditable=="false")){if(r)return Dy(r);if(s)return Dy(s)}}function Dy(e){return e.contentEditable="true",Io&&e.draggable&&(e.draggable=!1,e.wasDraggable=!0),e}function i9(e){e.contentEditable="false",e.wasDraggable&&(e.draggable=!0,e.wasDraggable=null)}function f3e(e){let t=e.dom.ownerDocument;t.removeEventListener("selectionchange",e.input.hideSelectionGuard);let n=e.domSelectionRange(),o=n.anchorNode,r=n.anchorOffset;t.addEventListener("selectionchange",e.input.hideSelectionGuard=()=>{(n.anchorNode!=o||n.anchorOffset!=r)&&(t.removeEventListener("selectionchange",e.input.hideSelectionGuard),setTimeout(()=>{(!KA(e)||e.state.selection.visible)&&e.dom.classList.remove("ProseMirror-hideselection")},20))})}function p3e(e){let t=e.domSelection(),n=document.createRange();if(!t)return;let o=e.cursorWrapper.dom,r=o.nodeName=="IMG";r?n.setStart(o.parentNode,no(o)+1):n.setStart(o,0),n.collapse(!0),t.removeAllRanges(),t.addRange(n),!r&&!e.state.selection.visible&&Go&&Rl<=11&&(o.disabled=!0,o.disabled=!1)}function qA(e,t){if(t instanceof mt){let n=e.docView.descAt(t.from);n!=e.lastSelectedViewDesc&&(l9(e),n&&n.selectNode(),e.lastSelectedViewDesc=n)}else l9(e)}function l9(e){e.lastSelectedViewDesc&&(e.lastSelectedViewDesc.parent&&e.lastSelectedViewDesc.deselectNode(),e.lastSelectedViewDesc=void 0)}function vC(e,t,n,o){return e.someProp("createSelectionBetween",r=>r(e,t,n))||ht.between(t,n,o)}function a9(e){return e.editable&&!e.hasFocus()?!1:GA(e)}function GA(e){let t=e.domSelectionRange();if(!t.anchorNode)return!1;try{return e.dom.contains(t.anchorNode.nodeType==3?t.anchorNode.parentNode:t.anchorNode)&&(e.editable||e.dom.contains(t.focusNode.nodeType==3?t.focusNode.parentNode:t.focusNode))}catch{return!1}}function h3e(e){let t=e.docView.domFromPos(e.state.selection.anchor,0),n=e.domSelectionRange();return hu(t.node,t.offset,n.anchorNode,n.anchorOffset)}function a2(e,t){let{$anchor:n,$head:o}=e.selection,r=t>0?n.max(o):n.min(o),s=r.parent.inlineContent?r.depth?e.doc.resolve(t>0?r.after():r.before()):null:r;return s&&bt.findFrom(s,t)}function _l(e,t){return e.dispatch(e.state.tr.setSelection(t).scrollIntoView()),!0}function u9(e,t,n){let o=e.state.selection;if(o instanceof ht)if(n.indexOf("s")>-1){let{$head:r}=o,s=r.textOffset?null:t<0?r.nodeBefore:r.nodeAfter;if(!s||s.isText||!s.isLeaf)return!1;let i=e.state.doc.resolve(r.pos+s.nodeSize*(t<0?-1:1));return _l(e,new ht(o.$anchor,i))}else if(o.empty){if(e.endOfTextblock(t>0?"forward":"backward")){let r=a2(e.state,t);return r&&r instanceof mt?_l(e,r):!1}else if(!(Er&&n.indexOf("m")>-1)){let r=o.$head,s=r.textOffset?null:t<0?r.nodeBefore:r.nodeAfter,i;if(!s||s.isText)return!1;let l=t<0?r.pos-s.nodeSize:r.pos;return s.isAtom||(i=e.docView.descAt(l))&&!i.contentDOM?mt.isSelectable(s)?_l(e,new mt(t<0?e.state.doc.resolve(r.pos-s.nodeSize):r)):Th?_l(e,new ht(e.state.doc.resolve(t<0?l:l+s.nodeSize))):!1:!1}}else return!1;else{if(o instanceof mt&&o.node.isInline)return _l(e,new ht(t>0?o.$to:o.$from));{let r=a2(e.state,t);return r?_l(e,r):!1}}}function Jg(e){return e.nodeType==3?e.nodeValue.length:e.childNodes.length}function op(e,t){let n=e.pmViewDesc;return n&&n.size==0&&(t<0||e.nextSibling||e.nodeName!="BR")}function Du(e,t){return t<0?m3e(e):g3e(e)}function m3e(e){let t=e.domSelectionRange(),n=t.focusNode,o=t.focusOffset;if(!n)return;let r,s,i=!1;for(vs&&n.nodeType==1&&o<Jg(n)&&op(n.childNodes[o],-1)&&(i=!0);;)if(o>0){if(n.nodeType!=1)break;{let l=n.childNodes[o-1];if(op(l,-1))r=n,s=--o;else if(l.nodeType==3)n=l,o=n.nodeValue.length;else break}}else{if(YA(n))break;{let l=n.previousSibling;for(;l&&op(l,-1);)r=n.parentNode,s=no(l),l=l.previousSibling;if(l)n=l,o=Jg(n);else{if(n=n.parentNode,n==e.dom)break;o=0}}}i?u2(e,n,o):r&&u2(e,r,s)}function g3e(e){let t=e.domSelectionRange(),n=t.focusNode,o=t.focusOffset;if(!n)return;let r=Jg(n),s,i;for(;;)if(o<r){if(n.nodeType!=1)break;let l=n.childNodes[o];if(op(l,1))s=n,i=++o;else break}else{if(YA(n))break;{let l=n.nextSibling;for(;l&&op(l,1);)s=l.parentNode,i=no(l)+1,l=l.nextSibling;if(l)n=l,o=0,r=Jg(n);else{if(n=n.parentNode,n==e.dom)break;o=r=0}}}s&&u2(e,s,i)}function YA(e){let t=e.pmViewDesc;return t&&t.node&&t.node.isBlock}function v3e(e,t){for(;e&&t==e.childNodes.length&&!Mh(e);)t=no(e)+1,e=e.parentNode;for(;e&&t<e.childNodes.length;){let n=e.childNodes[t];if(n.nodeType==3)return n;if(n.nodeType==1&&n.contentEditable=="false")break;e=n,t=0}}function y3e(e,t){for(;e&&!t&&!Mh(e);)t=no(e),e=e.parentNode;for(;e&&t;){let n=e.childNodes[t-1];if(n.nodeType==3)return n;if(n.nodeType==1&&n.contentEditable=="false")break;e=n,t=e.childNodes.length}}function u2(e,t,n){if(t.nodeType!=3){let s,i;(i=v3e(t,n))?(t=i,n=0):(s=y3e(t,n))&&(t=s,n=s.nodeValue.length)}let o=e.domSelection();if(!o)return;if(fv(o)){let s=document.createRange();s.setEnd(t,n),s.setStart(t,n),o.removeAllRanges(),o.addRange(s)}else o.extend&&o.extend(t,n);e.domObserver.setCurSelection();let{state:r}=e;setTimeout(()=>{e.state==r&&Oi(e)},50)}function c9(e,t){let n=e.state.doc.resolve(t);if(!(mo||Bwe)&&n.parent.inlineContent){let r=e.coordsAtPos(t);if(t>n.start()){let s=e.coordsAtPos(t-1),i=(s.top+s.bottom)/2;if(i>r.top&&i<r.bottom&&Math.abs(s.left-r.left)>1)return s.left<r.left?"ltr":"rtl"}if(t<n.end()){let s=e.coordsAtPos(t+1),i=(s.top+s.bottom)/2;if(i>r.top&&i<r.bottom&&Math.abs(s.left-r.left)>1)return s.left>r.left?"ltr":"rtl"}}return getComputedStyle(e.dom).direction=="rtl"?"rtl":"ltr"}function d9(e,t,n){let o=e.state.selection;if(o instanceof ht&&!o.empty||n.indexOf("s")>-1||Er&&n.indexOf("m")>-1)return!1;let{$from:r,$to:s}=o;if(!r.parent.inlineContent||e.endOfTextblock(t<0?"up":"down")){let i=a2(e.state,t);if(i&&i instanceof mt)return _l(e,i)}if(!r.parent.inlineContent){let i=t<0?r:s,l=o instanceof gr?bt.near(i,t):bt.findFrom(i,t);return l?_l(e,l):!1}return!1}function f9(e,t){if(!(e.state.selection instanceof ht))return!0;let{$head:n,$anchor:o,empty:r}=e.state.selection;if(!n.sameParent(o))return!0;if(!r)return!1;if(e.endOfTextblock(t>0?"forward":"backward"))return!0;let s=!n.textOffset&&(t<0?n.nodeBefore:n.nodeAfter);if(s&&!s.isText){let i=e.state.tr;return t<0?i.delete(n.pos-s.nodeSize,n.pos):i.delete(n.pos,n.pos+s.nodeSize),e.dispatch(i),!0}return!1}function p9(e,t,n){e.domObserver.stop(),t.contentEditable=n,e.domObserver.start()}function _3e(e){if(!Io||e.state.selection.$head.parentOffset>0)return!1;let{focusNode:t,focusOffset:n}=e.domSelectionRange();if(t&&t.nodeType==1&&n==0&&t.firstChild&&t.firstChild.contentEditable=="false"){let o=t.firstChild;p9(e,o,"true"),setTimeout(()=>p9(e,o,"false"),20)}return!1}function b3e(e){let t="";return e.ctrlKey&&(t+="c"),e.metaKey&&(t+="m"),e.altKey&&(t+="a"),e.shiftKey&&(t+="s"),t}function w3e(e,t){let n=t.keyCode,o=b3e(t);if(n==8||Er&&n==72&&o=="c")return f9(e,-1)||Du(e,-1);if(n==46&&!t.shiftKey||Er&&n==68&&o=="c")return f9(e,1)||Du(e,1);if(n==13||n==27)return!0;if(n==37||Er&&n==66&&o=="c"){let r=n==37?c9(e,e.state.selection.from)=="ltr"?-1:1:-1;return u9(e,r,o)||Du(e,r)}else if(n==39||Er&&n==70&&o=="c"){let r=n==39?c9(e,e.state.selection.from)=="ltr"?1:-1:1;return u9(e,r,o)||Du(e,r)}else{if(n==38||Er&&n==80&&o=="c")return d9(e,-1,o)||Du(e,-1);if(n==40||Er&&n==78&&o=="c")return _3e(e)||d9(e,1,o)||Du(e,1);if(o==(Er?"m":"c")&&(n==66||n==73||n==89||n==90))return!0}return!1}function ZA(e,t){e.someProp("transformCopied",p=>{t=p(t,e)});let n=[],{content:o,openStart:r,openEnd:s}=t;for(;r>1&&s>1&&o.childCount==1&&o.firstChild.childCount==1;){r--,s--;let p=o.firstChild;n.push(p.type.name,p.attrs!=p.type.defaultAttrs?p.attrs:null),o=p.content}let i=e.someProp("clipboardSerializer")||ta.fromSchema(e.state.schema),l=nN(),a=l.createElement("div");a.appendChild(i.serializeFragment(o,{document:l}));let u=a.firstChild,c,d=0;for(;u&&u.nodeType==1&&(c=tN[u.nodeName.toLowerCase()]);){for(let p=c.length-1;p>=0;p--){let h=l.createElement(c[p]);for(;a.firstChild;)h.appendChild(a.firstChild);a.appendChild(h),d++}u=a.firstChild}u&&u.nodeType==1&&u.setAttribute("data-pm-slice",`${r} ${s}${d?` -${d}`:""} ${JSON.stringify(n)}`);let f=e.someProp("clipboardTextSerializer",p=>p(t,e))||t.content.textBetween(0,t.content.size,`
116
117 `);return{dom:a,text:f,slice:t}}function JA(e,t,n,o,r){let s=r.parent.type.spec.code,i,l;if(!n&&!t)return null;let a=t&&(o||s||!n);if(a){if(e.someProp("transformPastedText",f=>{t=f(t,s||o,e)}),s)return t?new Ye(Ue.from(e.state.schema.text(t.replace(/\r\n?/g,`
118 `))),0,0):Ye.empty;let d=e.someProp("clipboardTextParser",f=>f(t,r,o,e));if(d)l=d;else{let f=r.marks(),{schema:p}=e.state,h=ta.fromSchema(p);i=document.createElement("div"),t.split(/(?:\r\n?|\n)+/).forEach(m=>{let y=i.appendChild(document.createElement("p"));m&&y.appendChild(h.serializeNode(p.text(m,f)))})}}else e.someProp("transformPastedHTML",d=>{n=d(n,e)}),i=S3e(n),Th&&$3e(i);let u=i&&i.querySelector("[data-pm-slice]"),c=u&&/^(\d+) (\d+)(?: -(\d+))? (.*)/.exec(u.getAttribute("data-pm-slice")||"");if(c&&c[3])for(let d=+c[3];d>0;d--){let f=i.firstChild;for(;f&&f.nodeType!=1;)f=f.nextSibling;if(!f)break;i=f}if(l||(l=(e.someProp("clipboardParser")||e.someProp("domParser")||fu.fromSchema(e.state.schema)).parseSlice(i,{preserveWhitespace:!!(a||c),context:r,ruleFromNode(f){return f.nodeName=="BR"&&!f.nextSibling&&f.parentNode&&!C3e.test(f.parentNode.nodeName)?{ignore:!0}:null}})),c)l=E3e(h9(l,+c[1],+c[2]),c[4]);else if(l=Ye.maxOpen(k3e(l.content,r),!0),l.openStart||l.openEnd){let d=0,f=0;for(let p=l.content.firstChild;d<l.openStart&&!p.type.spec.isolating;d++,p=p.firstChild);for(let p=l.content.lastChild;f<l.openEnd&&!p.type.spec.isolating;f++,p=p.lastChild);l=h9(l,d,f)}return e.someProp("transformPasted",d=>{l=d(l,e)}),l}const C3e=/^(a|abbr|acronym|b|cite|code|del|em|i|ins|kbd|label|output|q|ruby|s|samp|span|strong|sub|sup|time|u|tt|var)$/i;function k3e(e,t){if(e.childCount<2)return e;for(let n=t.depth;n>=0;n--){let r=t.node(n).contentMatchAt(t.index(n)),s,i=[];if(e.forEach(l=>{if(!i)return;let a=r.findWrapping(l.type),u;if(!a)return i=null;if(u=i.length&&s.length&&QA(a,s,l,i[i.length-1],0))i[i.length-1]=u;else{i.length&&(i[i.length-1]=eN(i[i.length-1],s.length));let c=XA(l,a);i.push(c),r=r.matchType(c.type),s=a}}),i)return Ue.from(i)}return e}function XA(e,t,n=0){for(let o=t.length-1;o>=n;o--)e=t[o].create(null,Ue.from(e));return e}function QA(e,t,n,o,r){if(r<e.length&&r<t.length&&e[r]==t[r]){let s=QA(e,t,n,o.lastChild,r+1);if(s)return o.copy(o.content.replaceChild(o.childCount-1,s));if(o.contentMatchAt(o.childCount).matchType(r==e.length-1?n.type:e[r+1]))return o.copy(o.content.append(Ue.from(XA(n,e,r+1))))}}function eN(e,t){if(t==0)return e;let n=e.content.replaceChild(e.childCount-1,eN(e.lastChild,t-1)),o=e.contentMatchAt(e.childCount).fillBefore(Ue.empty,!0);return e.copy(n.append(o))}function c2(e,t,n,o,r,s){let i=t<0?e.firstChild:e.lastChild,l=i.content;return e.childCount>1&&(s=0),r<o-1&&(l=c2(l,t,n,o,r+1,s)),r>=n&&(l=t<0?i.contentMatchAt(0).fillBefore(l,s<=r).append(l):l.append(i.contentMatchAt(i.childCount).fillBefore(Ue.empty,!0))),e.replaceChild(t<0?0:e.childCount-1,i.copy(l))}function h9(e,t,n){return t<e.openStart&&(e=new Ye(c2(e.content,-1,t,e.openStart,0,e.openEnd),t,e.openEnd)),n<e.openEnd&&(e=new Ye(c2(e.content,1,n,e.openEnd,0,0),e.openStart,n)),e}const tN={thead:["table"],tbody:["table"],tfoot:["table"],caption:["table"],colgroup:["table"],col:["table","colgroup"],tr:["table","tbody"],td:["table","tbody","tr"],th:["table","tbody","tr"]};let m9=null;function nN(){return m9||(m9=document.implementation.createHTMLDocument("title"))}function S3e(e){let t=/^(\s*<meta [^>]*>)*/.exec(e);t&&(e=e.slice(t[0].length));let n=nN().createElement("div"),o=/<([a-z][^>\s]+)/i.exec(e),r;if((r=o&&tN[o[1].toLowerCase()])&&(e=r.map(s=>"<"+s+">").join("")+e+r.map(s=>"</"+s+">").reverse().join("")),n.innerHTML=e,r)for(let s=0;s<r.length;s++)n=n.querySelector(r[s])||n;return n}function $3e(e){let t=e.querySelectorAll(mo?"span:not([class]):not([style])":"span.Apple-converted-space");for(let n=0;n<t.length;n++){let o=t[n];o.childNodes.length==1&&o.textContent==" "&&o.parentNode&&o.parentNode.replaceChild(e.ownerDocument.createTextNode(" "),o)}}function E3e(e,t){if(!e.size)return e;let n=e.content.firstChild.type.schema,o;try{o=JSON.parse(t)}catch{return e}let{content:r,openStart:s,openEnd:i}=e;for(let l=o.length-2;l>=0;l-=2){let a=n.nodes[o[l]];if(!a||a.hasRequiredAttrs())break;r=Ue.from(a.create(o[l+1],r)),s++,i++}return new Ye(r,s,i)}const Ao={},No={},x3e={touchstart:!0,touchmove:!0};class M3e{constructor(){this.shiftKey=!1,this.mouseDown=null,this.lastKeyCode=null,this.lastKeyCodeTime=0,this.lastClick={time:0,x:0,y:0,type:""},this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastIOSEnter=0,this.lastIOSEnterFallbackTimeout=-1,this.lastFocus=0,this.lastTouch=0,this.lastAndroidDelete=0,this.composing=!1,this.compositionNode=null,this.composingTimeout=-1,this.compositionNodes=[],this.compositionEndedAt=-2e8,this.compositionID=1,this.compositionPendingChanges=0,this.domChangeCount=0,this.eventHandlers=Object.create(null),this.hideSelectionGuard=null}}function T3e(e){for(let t in Ao){let n=Ao[t];e.dom.addEventListener(t,e.input.eventHandlers[t]=o=>{I3e(e,o)&&!yC(e,o)&&(e.editable||!(o.type in No))&&n(e,o)},x3e[t]?{passive:!0}:void 0)}Io&&e.dom.addEventListener("input",()=>null),d2(e)}function Il(e,t){e.input.lastSelectionOrigin=t,e.input.lastSelectionTime=Date.now()}function O3e(e){e.domObserver.stop();for(let t in e.input.eventHandlers)e.dom.removeEventListener(t,e.input.eventHandlers[t]);clearTimeout(e.input.composingTimeout),clearTimeout(e.input.lastIOSEnterFallbackTimeout)}function d2(e){e.someProp("handleDOMEvents",t=>{for(let n in t)e.input.eventHandlers[n]||e.dom.addEventListener(n,e.input.eventHandlers[n]=o=>yC(e,o))})}function yC(e,t){return e.someProp("handleDOMEvents",n=>{let o=n[t.type];return o?o(e,t)||t.defaultPrevented:!1})}function I3e(e,t){if(!t.bubbles)return!0;if(t.defaultPrevented)return!1;for(let n=t.target;n!=e.dom;n=n.parentNode)if(!n||n.nodeType==11||n.pmViewDesc&&n.pmViewDesc.stopEvent(t))return!1;return!0}function A3e(e,t){!yC(e,t)&&Ao[t.type]&&(e.editable||!(t.type in No))&&Ao[t.type](e,t)}No.keydown=(e,t)=>{let n=t;if(e.input.shiftKey=n.keyCode==16||n.shiftKey,!rN(e,n)&&(e.input.lastKeyCode=n.keyCode,e.input.lastKeyCodeTime=Date.now(),!(rs&&mo&&n.keyCode==13)))if(n.keyCode!=229&&e.domObserver.forceFlush(),pd&&n.keyCode==13&&!n.ctrlKey&&!n.altKey&&!n.metaKey){let o=Date.now();e.input.lastIOSEnter=o,e.input.lastIOSEnterFallbackTimeout=setTimeout(()=>{e.input.lastIOSEnter==o&&(e.someProp("handleKeyDown",r=>r(e,xa(13,"Enter"))),e.input.lastIOSEnter=0)},200)}else e.someProp("handleKeyDown",o=>o(e,n))||w3e(e,n)?n.preventDefault():Il(e,"key")};No.keyup=(e,t)=>{t.keyCode==16&&(e.input.shiftKey=!1)};No.keypress=(e,t)=>{let n=t;if(rN(e,n)||!n.charCode||n.ctrlKey&&!n.altKey||Er&&n.metaKey)return;if(e.someProp("handleKeyPress",r=>r(e,n))){n.preventDefault();return}let o=e.state.selection;if(!(o instanceof ht)||!o.$from.sameParent(o.$to)){let r=String.fromCharCode(n.charCode);!/[\r\n]/.test(r)&&!e.someProp("handleTextInput",s=>s(e,o.$from.pos,o.$to.pos,r))&&e.dispatch(e.state.tr.insertText(r).scrollIntoView()),n.preventDefault()}};function hv(e){return{left:e.clientX,top:e.clientY}}function N3e(e,t){let n=t.x-e.clientX,o=t.y-e.clientY;return n*n+o*o<100}function _C(e,t,n,o,r){if(o==-1)return!1;let s=e.state.doc.resolve(o);for(let i=s.depth+1;i>0;i--)if(e.someProp(t,l=>i>s.depth?l(e,n,s.nodeAfter,s.before(i),r,!0):l(e,n,s.node(i),s.before(i),r,!1)))return!0;return!1}function Mc(e,t,n){if(e.focused||e.focus(),e.state.selection.eq(t))return;let o=e.state.tr.setSelection(t);n=="pointer"&&o.setMeta("pointer",!0),e.dispatch(o)}function P3e(e,t){if(t==-1)return!1;let n=e.state.doc.resolve(t),o=n.nodeAfter;return o&&o.isAtom&&mt.isSelectable(o)?(Mc(e,new mt(n),"pointer"),!0):!1}function L3e(e,t){if(t==-1)return!1;let n=e.state.selection,o,r;n instanceof mt&&(o=n.node);let s=e.state.doc.resolve(t);for(let i=s.depth+1;i>0;i--){let l=i>s.depth?s.nodeAfter:s.node(i);if(mt.isSelectable(l)){o&&n.$from.depth>0&&i>=n.$from.depth&&s.before(n.$from.depth+1)==n.$from.pos?r=s.before(n.$from.depth):r=s.before(i);break}}return r!=null?(Mc(e,mt.create(e.state.doc,r),"pointer"),!0):!1}function R3e(e,t,n,o,r){return _C(e,"handleClickOn",t,n,o)||e.someProp("handleClick",s=>s(e,t,o))||(r?L3e(e,n):P3e(e,n))}function D3e(e,t,n,o){return _C(e,"handleDoubleClickOn",t,n,o)||e.someProp("handleDoubleClick",r=>r(e,t,o))}function F3e(e,t,n,o){return _C(e,"handleTripleClickOn",t,n,o)||e.someProp("handleTripleClick",r=>r(e,t,o))||V3e(e,n,o)}function V3e(e,t,n){if(n.button!=0)return!1;let o=e.state.doc;if(t==-1)return o.inlineContent?(Mc(e,ht.create(o,0,o.content.size),"pointer"),!0):!1;let r=o.resolve(t);for(let s=r.depth+1;s>0;s--){let i=s>r.depth?r.nodeAfter:r.node(s),l=r.before(s);if(i.inlineContent)Mc(e,ht.create(o,l+1,l+1+i.content.size),"pointer");else if(mt.isSelectable(i))Mc(e,mt.create(o,l),"pointer");else continue;return!0}}function bC(e){return Xg(e)}const oN=Er?"metaKey":"ctrlKey";Ao.mousedown=(e,t)=>{let n=t;e.input.shiftKey=n.shiftKey;let o=bC(e),r=Date.now(),s="singleClick";r-e.input.lastClick.time<500&&N3e(n,e.input.lastClick)&&!n[oN]&&(e.input.lastClick.type=="singleClick"?s="doubleClick":e.input.lastClick.type=="doubleClick"&&(s="tripleClick")),e.input.lastClick={time:r,x:n.clientX,y:n.clientY,type:s};let i=e.posAtCoords(hv(n));i&&(s=="singleClick"?(e.input.mouseDown&&e.input.mouseDown.done(),e.input.mouseDown=new B3e(e,i,n,!!o)):(s=="doubleClick"?D3e:F3e)(e,i.pos,i.inside,n)?n.preventDefault():Il(e,"pointer"))};class B3e{constructor(t,n,o,r){this.view=t,this.pos=n,this.event=o,this.flushed=r,this.delayedSelectionSync=!1,this.mightDrag=null,this.startDoc=t.state.doc,this.selectNode=!!o[oN],this.allowDefault=o.shiftKey;let s,i;if(n.inside>-1)s=t.state.doc.nodeAt(n.inside),i=n.inside;else{let c=t.state.doc.resolve(n.pos);s=c.parent,i=c.depth?c.before():0}const l=r?null:o.target,a=l?t.docView.nearestDesc(l,!0):null;this.target=a&&a.dom.nodeType==1?a.dom:null;let{selection:u}=t.state;(o.button==0&&s.type.spec.draggable&&s.type.spec.selectable!==!1||u instanceof mt&&u.from<=i&&u.to>i)&&(this.mightDrag={node:s,pos:i,addAttr:!!(this.target&&!this.target.draggable),setUneditable:!!(this.target&&vs&&!this.target.hasAttribute("contentEditable"))}),this.target&&this.mightDrag&&(this.mightDrag.addAttr||this.mightDrag.setUneditable)&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&(this.target.draggable=!0),this.mightDrag.setUneditable&&setTimeout(()=>{this.view.input.mouseDown==this&&this.target.setAttribute("contentEditable","false")},20),this.view.domObserver.start()),t.root.addEventListener("mouseup",this.up=this.up.bind(this)),t.root.addEventListener("mousemove",this.move=this.move.bind(this)),Il(t,"pointer")}done(){this.view.root.removeEventListener("mouseup",this.up),this.view.root.removeEventListener("mousemove",this.move),this.mightDrag&&this.target&&(this.view.domObserver.stop(),this.mightDrag.addAttr&&this.target.removeAttribute("draggable"),this.mightDrag.setUneditable&&this.target.removeAttribute("contentEditable"),this.view.domObserver.start()),this.delayedSelectionSync&&setTimeout(()=>Oi(this.view)),this.view.input.mouseDown=null}up(t){if(this.done(),!this.view.dom.contains(t.target))return;let n=this.pos;this.view.state.doc!=this.startDoc&&(n=this.view.posAtCoords(hv(t))),this.updateAllowDefault(t),this.allowDefault||!n?Il(this.view,"pointer"):R3e(this.view,n.pos,n.inside,t,this.selectNode)?t.preventDefault():t.button==0&&(this.flushed||Io&&this.mightDrag&&!this.mightDrag.node.isAtom||mo&&!this.view.state.selection.visible&&Math.min(Math.abs(n.pos-this.view.state.selection.from),Math.abs(n.pos-this.view.state.selection.to))<=2)?(Mc(this.view,bt.near(this.view.state.doc.resolve(n.pos)),"pointer"),t.preventDefault()):Il(this.view,"pointer")}move(t){this.updateAllowDefault(t),Il(this.view,"pointer"),t.buttons==0&&this.done()}updateAllowDefault(t){!this.allowDefault&&(Math.abs(this.event.x-t.clientX)>4||Math.abs(this.event.y-t.clientY)>4)&&(this.allowDefault=!0)}}Ao.touchstart=e=>{e.input.lastTouch=Date.now(),bC(e),Il(e,"pointer")};Ao.touchmove=e=>{e.input.lastTouch=Date.now(),Il(e,"pointer")};Ao.contextmenu=e=>bC(e);function rN(e,t){return e.composing?!0:Io&&Math.abs(t.timeStamp-e.input.compositionEndedAt)<500?(e.input.compositionEndedAt=-2e8,!0):!1}const z3e=rs?5e3:-1;No.compositionstart=No.compositionupdate=e=>{if(!e.composing){e.domObserver.flush();let{state:t}=e,n=t.selection.$to;if(t.selection instanceof ht&&(t.storedMarks||!n.textOffset&&n.parentOffset&&n.nodeBefore.marks.some(o=>o.type.spec.inclusive===!1)))e.markCursor=e.state.storedMarks||n.marks(),Xg(e,!0),e.markCursor=null;else if(Xg(e,!t.selection.empty),vs&&t.selection.empty&&n.parentOffset&&!n.textOffset&&n.nodeBefore.marks.length){let o=e.domSelectionRange();for(let r=o.focusNode,s=o.focusOffset;r&&r.nodeType==1&&s!=0;){let i=s<0?r.lastChild:r.childNodes[s-1];if(!i)break;if(i.nodeType==3){let l=e.domSelection();l&&l.collapse(i,i.nodeValue.length);break}else r=i,s=-1}}e.input.composing=!0}sN(e,z3e)};No.compositionend=(e,t)=>{e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=t.timeStamp,e.input.compositionPendingChanges=e.domObserver.pendingRecords().length?e.input.compositionID:0,e.input.compositionNode=null,e.input.compositionPendingChanges&&Promise.resolve().then(()=>e.domObserver.flush()),e.input.compositionID++,sN(e,20))};function sN(e,t){clearTimeout(e.input.composingTimeout),t>-1&&(e.input.composingTimeout=setTimeout(()=>Xg(e),t))}function iN(e){for(e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=H3e());e.input.compositionNodes.length>0;)e.input.compositionNodes.pop().markParentsDirty()}function j3e(e){let t=e.domSelectionRange();if(!t.focusNode)return null;let n=Lwe(t.focusNode,t.focusOffset),o=Rwe(t.focusNode,t.focusOffset);if(n&&o&&n!=o){let r=o.pmViewDesc,s=e.domObserver.lastChangedTextNode;if(n==s||o==s)return s;if(!r||!r.isText(o.nodeValue))return o;if(e.input.compositionNode==o){let i=n.pmViewDesc;if(!(!i||!i.isText(n.nodeValue)))return o}}return n||o}function H3e(){let e=document.createEvent("Event");return e.initEvent("event",!0,!0),e.timeStamp}function Xg(e,t=!1){if(!(rs&&e.domObserver.flushingSoon>=0)){if(e.domObserver.forceFlush(),iN(e),t||e.docView&&e.docView.dirty){let n=gC(e);return n&&!n.eq(e.state.selection)?e.dispatch(e.state.tr.setSelection(n)):(e.markCursor||t)&&!e.state.selection.empty?e.dispatch(e.state.tr.deleteSelection()):e.updateState(e.state),!0}return!1}}function U3e(e,t){if(!e.dom.parentNode)return;let n=e.dom.parentNode.appendChild(document.createElement("div"));n.appendChild(t),n.style.cssText="position: fixed; left: -10000px; top: 10px";let o=getSelection(),r=document.createRange();r.selectNodeContents(t),e.dom.blur(),o.removeAllRanges(),o.addRange(r),setTimeout(()=>{n.parentNode&&n.parentNode.removeChild(n),e.focus()},50)}const Up=Go&&Rl<15||pd&&zwe<604;Ao.copy=No.cut=(e,t)=>{let n=t,o=e.state.selection,r=n.type=="cut";if(o.empty)return;let s=Up?null:n.clipboardData,i=o.content(),{dom:l,text:a}=ZA(e,i);s?(n.preventDefault(),s.clearData(),s.setData("text/html",l.innerHTML),s.setData("text/plain",a)):U3e(e,l),r&&e.dispatch(e.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent","cut"))};function W3e(e){return e.openStart==0&&e.openEnd==0&&e.content.childCount==1?e.content.firstChild:null}function K3e(e,t){if(!e.dom.parentNode)return;let n=e.input.shiftKey||e.state.selection.$from.parent.type.spec.code,o=e.dom.parentNode.appendChild(document.createElement(n?"textarea":"div"));n||(o.contentEditable="true"),o.style.cssText="position: fixed; left: -10000px; top: 10px",o.focus();let r=e.input.shiftKey&&e.input.lastKeyCode!=45;setTimeout(()=>{e.focus(),o.parentNode&&o.parentNode.removeChild(o),n?Wp(e,o.value,null,r,t):Wp(e,o.textContent,o.innerHTML,r,t)},50)}function Wp(e,t,n,o,r){let s=JA(e,t,n,o,e.state.selection.$from);if(e.someProp("handlePaste",a=>a(e,r,s||Ye.empty)))return!0;if(!s)return!1;let i=W3e(s),l=i?e.state.tr.replaceSelectionWith(i,o):e.state.tr.replaceSelection(s);return e.dispatch(l.scrollIntoView().setMeta("paste",!0).setMeta("uiEvent","paste")),!0}function lN(e){let t=e.getData("text/plain")||e.getData("Text");if(t)return t;let n=e.getData("text/uri-list");return n?n.replace(/\r?\n/g," "):""}No.paste=(e,t)=>{let n=t;if(e.composing&&!rs)return;let o=Up?null:n.clipboardData,r=e.input.shiftKey&&e.input.lastKeyCode!=45;o&&Wp(e,lN(o),o.getData("text/html"),r,n)?n.preventDefault():K3e(e,n)};class aN{constructor(t,n,o){this.slice=t,this.move=n,this.node=o}}const uN=Er?"altKey":"ctrlKey";Ao.dragstart=(e,t)=>{let n=t,o=e.input.mouseDown;if(o&&o.done(),!n.dataTransfer)return;let r=e.state.selection,s=r.empty?null:e.posAtCoords(hv(n)),i;if(!(s&&s.pos>=r.from&&s.pos<=(r instanceof mt?r.to-1:r.to))){if(o&&o.mightDrag)i=mt.create(e.state.doc,o.mightDrag.pos);else if(n.target&&n.target.nodeType==1){let d=e.docView.nearestDesc(n.target,!0);d&&d.node.type.spec.draggable&&d!=e.docView&&(i=mt.create(e.state.doc,d.posBefore))}}let l=(i||e.state.selection).content(),{dom:a,text:u,slice:c}=ZA(e,l);(!n.dataTransfer.files.length||!mo||PA>120)&&n.dataTransfer.clearData(),n.dataTransfer.setData(Up?"Text":"text/html",a.innerHTML),n.dataTransfer.effectAllowed="copyMove",Up||n.dataTransfer.setData("text/plain",u),e.dragging=new aN(c,!n[uN],i)};Ao.dragend=e=>{let t=e.dragging;window.setTimeout(()=>{e.dragging==t&&(e.dragging=null)},50)};No.dragover=No.dragenter=(e,t)=>t.preventDefault();No.drop=(e,t)=>{let n=t,o=e.dragging;if(e.dragging=null,!n.dataTransfer)return;let r=e.posAtCoords(hv(n));if(!r)return;let s=e.state.doc.resolve(r.pos),i=o&&o.slice;i?e.someProp("transformPasted",h=>{i=h(i,e)}):i=JA(e,lN(n.dataTransfer),Up?null:n.dataTransfer.getData("text/html"),!1,s);let l=!!(o&&!n[uN]);if(e.someProp("handleDrop",h=>h(e,n,i||Ye.empty,l))){n.preventDefault();return}if(!i)return;n.preventDefault();let a=i?O2e(e.state.doc,s.pos,i):s.pos;a==null&&(a=s.pos);let u=e.state.tr;if(l){let{node:h}=o;h?h.replace(u):u.deleteSelection()}let c=u.mapping.map(a),d=i.openStart==0&&i.openEnd==0&&i.content.childCount==1,f=u.doc;if(d?u.replaceRangeWith(c,c,i.content.firstChild):u.replaceRange(c,c,i),u.doc.eq(f))return;let p=u.doc.resolve(c);if(d&&mt.isSelectable(i.content.firstChild)&&p.nodeAfter&&p.nodeAfter.sameMarkup(i.content.firstChild))u.setSelection(new mt(p));else{let h=u.mapping.map(a);u.mapping.maps[u.mapping.maps.length-1].forEach((m,y,v,w)=>h=w),u.setSelection(vC(e,p,u.doc.resolve(h)))}e.focus(),e.dispatch(u.setMeta("uiEvent","drop"))};Ao.focus=e=>{e.input.lastFocus=Date.now(),e.focused||(e.domObserver.stop(),e.dom.classList.add("ProseMirror-focused"),e.domObserver.start(),e.focused=!0,setTimeout(()=>{e.docView&&e.hasFocus()&&!e.domObserver.currentSelection.eq(e.domSelectionRange())&&Oi(e)},20))};Ao.blur=(e,t)=>{let n=t;e.focused&&(e.domObserver.stop(),e.dom.classList.remove("ProseMirror-focused"),e.domObserver.start(),n.relatedTarget&&e.dom.contains(n.relatedTarget)&&e.domObserver.currentSelection.clear(),e.focused=!1)};Ao.beforeinput=(e,t)=>{if(mo&&rs&&t.inputType=="deleteContentBackward"){e.domObserver.flushSoon();let{domChangeCount:o}=e.input;setTimeout(()=>{if(e.input.domChangeCount!=o||(e.dom.blur(),e.focus(),e.someProp("handleKeyDown",s=>s(e,xa(8,"Backspace")))))return;let{$cursor:r}=e.state.selection;r&&r.pos>0&&e.dispatch(e.state.tr.delete(r.pos-1,r.pos).scrollIntoView())},50)}};for(let e in No)Ao[e]=No[e];function Kp(e,t){if(e==t)return!0;for(let n in e)if(e[n]!==t[n])return!1;for(let n in t)if(!(n in e))return!1;return!0}class Qg{constructor(t,n){this.toDOM=t,this.spec=n||Ga,this.side=this.spec.side||0}map(t,n,o,r){let{pos:s,deleted:i}=t.mapResult(n.from+r,this.side<0?-1:1);return i?null:new zn(s-o,s-o,this)}valid(){return!0}eq(t){return this==t||t instanceof Qg&&(this.spec.key&&this.spec.key==t.spec.key||this.toDOM==t.toDOM&&Kp(this.spec,t.spec))}destroy(t){this.spec.destroy&&this.spec.destroy(t)}}class Fl{constructor(t,n){this.attrs=t,this.spec=n||Ga}map(t,n,o,r){let s=t.map(n.from+r,this.spec.inclusiveStart?-1:1)-o,i=t.map(n.to+r,this.spec.inclusiveEnd?1:-1)-o;return s>=i?null:new zn(s,i,this)}valid(t,n){return n.from<n.to}eq(t){return this==t||t instanceof Fl&&Kp(this.attrs,t.attrs)&&Kp(this.spec,t.spec)}static is(t){return t.type instanceof Fl}destroy(){}}class wC{constructor(t,n){this.attrs=t,this.spec=n||Ga}map(t,n,o,r){let s=t.mapResult(n.from+r,1);if(s.deleted)return null;let i=t.mapResult(n.to+r,-1);return i.deleted||i.pos<=s.pos?null:new zn(s.pos-o,i.pos-o,this)}valid(t,n){let{index:o,offset:r}=t.content.findIndex(n.from),s;return r==n.from&&!(s=t.child(o)).isText&&r+s.nodeSize==n.to}eq(t){return this==t||t instanceof wC&&Kp(this.attrs,t.attrs)&&Kp(this.spec,t.spec)}destroy(){}}class zn{constructor(t,n,o){this.from=t,this.to=n,this.type=o}copy(t,n){return new zn(t,n,this.type)}eq(t,n=0){return this.type.eq(t.type)&&this.from+n==t.from&&this.to+n==t.to}map(t,n,o){return this.type.map(t,this,n,o)}static widget(t,n,o){return new zn(t,t,new Qg(n,o))}static inline(t,n,o,r){return new zn(t,n,new Fl(o,r))}static node(t,n,o,r){return new zn(t,n,new wC(o,r))}get spec(){return this.type.spec}get inline(){return this.type instanceof Fl}get widget(){return this.type instanceof Qg}}const ec=[],Ga={};class an{constructor(t,n){this.local=t.length?t:ec,this.children=n.length?n:ec}static create(t,n){return n.length?e0(n,t,0,Ga):fo}find(t,n,o){let r=[];return this.findInner(t??0,n??1e9,r,0,o),r}findInner(t,n,o,r,s){for(let i=0;i<this.local.length;i++){let l=this.local[i];l.from<=n&&l.to>=t&&(!s||s(l.spec))&&o.push(l.copy(l.from+r,l.to+r))}for(let i=0;i<this.children.length;i+=3)if(this.children[i]<n&&this.children[i+1]>t){let l=this.children[i]+1;this.children[i+2].findInner(t-l,n-l,o,r+l,s)}}map(t,n,o){return this==fo||t.maps.length==0?this:this.mapInner(t,n,0,0,o||Ga)}mapInner(t,n,o,r,s){let i;for(let l=0;l<this.local.length;l++){let a=this.local[l].map(t,o,r);a&&a.type.valid(n,a)?(i||(i=[])).push(a):s.onRemove&&s.onRemove(this.local[l].spec)}return this.children.length?q3e(this.children,i||[],t,n,o,r,s):i?new an(i.sort(Ya),ec):fo}add(t,n){return n.length?this==fo?an.create(t,n):this.addInner(t,n,0):this}addInner(t,n,o){let r,s=0;t.forEach((l,a)=>{let u=a+o,c;if(c=dN(n,l,u)){for(r||(r=this.children.slice());s<r.length&&r[s]<a;)s+=3;r[s]==a?r[s+2]=r[s+2].addInner(l,c,u+1):r.splice(s,0,a,a+l.nodeSize,e0(c,l,u+1,Ga)),s+=3}});let i=cN(s?fN(n):n,-o);for(let l=0;l<i.length;l++)i[l].type.valid(t,i[l])||i.splice(l--,1);return new an(i.length?this.local.concat(i).sort(Ya):this.local,r||this.children)}remove(t){return t.length==0||this==fo?this:this.removeInner(t,0)}removeInner(t,n){let o=this.children,r=this.local;for(let s=0;s<o.length;s+=3){let i,l=o[s]+n,a=o[s+1]+n;for(let c=0,d;c<t.length;c++)(d=t[c])&&d.from>l&&d.to<a&&(t[c]=null,(i||(i=[])).push(d));if(!i)continue;o==this.children&&(o=this.children.slice());let u=o[s+2].removeInner(i,l+1);u!=fo?o[s+2]=u:(o.splice(s,3),s-=3)}if(r.length){for(let s=0,i;s<t.length;s++)if(i=t[s])for(let l=0;l<r.length;l++)r[l].eq(i,n)&&(r==this.local&&(r=this.local.slice()),r.splice(l--,1))}return o==this.children&&r==this.local?this:r.length||o.length?new an(r,o):fo}forChild(t,n){if(this==fo)return this;if(n.isLeaf)return an.empty;let o,r;for(let l=0;l<this.children.length;l+=3)if(this.children[l]>=t){this.children[l]==t&&(o=this.children[l+2]);break}let s=t+1,i=s+n.content.size;for(let l=0;l<this.local.length;l++){let a=this.local[l];if(a.from<i&&a.to>s&&a.type instanceof Fl){let u=Math.max(s,a.from)-s,c=Math.min(i,a.to)-s;u<c&&(r||(r=[])).push(a.copy(u,c))}}if(r){let l=new an(r.sort(Ya),ec);return o?new Sl([l,o]):l}return o||fo}eq(t){if(this==t)return!0;if(!(t instanceof an)||this.local.length!=t.local.length||this.children.length!=t.children.length)return!1;for(let n=0;n<this.local.length;n++)if(!this.local[n].eq(t.local[n]))return!1;for(let n=0;n<this.children.length;n+=3)if(this.children[n]!=t.children[n]||this.children[n+1]!=t.children[n+1]||!this.children[n+2].eq(t.children[n+2]))return!1;return!0}locals(t){return CC(this.localsInner(t))}localsInner(t){if(this==fo)return ec;if(t.inlineContent||!this.local.some(Fl.is))return this.local;let n=[];for(let o=0;o<this.local.length;o++)this.local[o].type instanceof Fl||n.push(this.local[o]);return n}forEachSet(t){t(this)}}an.empty=new an([],[]);an.removeOverlap=CC;const fo=an.empty;class Sl{constructor(t){this.members=t}map(t,n){const o=this.members.map(r=>r.map(t,n,Ga));return Sl.from(o)}forChild(t,n){if(n.isLeaf)return an.empty;let o=[];for(let r=0;r<this.members.length;r++){let s=this.members[r].forChild(t,n);s!=fo&&(s instanceof Sl?o=o.concat(s.members):o.push(s))}return Sl.from(o)}eq(t){if(!(t instanceof Sl)||t.members.length!=this.members.length)return!1;for(let n=0;n<this.members.length;n++)if(!this.members[n].eq(t.members[n]))return!1;return!0}locals(t){let n,o=!0;for(let r=0;r<this.members.length;r++){let s=this.members[r].localsInner(t);if(s.length)if(!n)n=s;else{o&&(n=n.slice(),o=!1);for(let i=0;i<s.length;i++)n.push(s[i])}}return n?CC(o?n:n.sort(Ya)):ec}static from(t){switch(t.length){case 0:return fo;case 1:return t[0];default:return new Sl(t.every(n=>n instanceof an)?t:t.reduce((n,o)=>n.concat(o instanceof an?o:o.members),[]))}}forEachSet(t){for(let n=0;n<this.members.length;n++)this.members[n].forEachSet(t)}}function q3e(e,t,n,o,r,s,i){let l=e.slice();for(let u=0,c=s;u<n.maps.length;u++){let d=0;n.maps[u].forEach((f,p,h,m)=>{let y=m-h-(p-f);for(let v=0;v<l.length;v+=3){let w=l[v+1];if(w<0||f>w+c-d)continue;let _=l[v]+c-d;p>=_?l[v+1]=f<=_?-2:-1:f>=c&&y&&(l[v]+=y,l[v+1]+=y)}d+=y}),c=n.maps[u].map(c,-1)}let a=!1;for(let u=0;u<l.length;u+=3)if(l[u+1]<0){if(l[u+1]==-2){a=!0,l[u+1]=-1;continue}let c=n.map(e[u]+s),d=c-r;if(d<0||d>=o.content.size){a=!0;continue}let f=n.map(e[u+1]+s,-1),p=f-r,{index:h,offset:m}=o.content.findIndex(d),y=o.maybeChild(h);if(y&&m==d&&m+y.nodeSize==p){let v=l[u+2].mapInner(n,y,c+1,e[u]+s+1,i);v!=fo?(l[u]=d,l[u+1]=p,l[u+2]=v):(l[u+1]=-2,a=!0)}else a=!0}if(a){let u=G3e(l,e,t,n,r,s,i),c=e0(u,o,0,i);t=c.local;for(let d=0;d<l.length;d+=3)l[d+1]<0&&(l.splice(d,3),d-=3);for(let d=0,f=0;d<c.children.length;d+=3){let p=c.children[d];for(;f<l.length&&l[f]<p;)f+=3;l.splice(f,0,c.children[d],c.children[d+1],c.children[d+2])}}return new an(t.sort(Ya),l)}function cN(e,t){if(!t||!e.length)return e;let n=[];for(let o=0;o<e.length;o++){let r=e[o];n.push(new zn(r.from+t,r.to+t,r.type))}return n}function G3e(e,t,n,o,r,s,i){function l(a,u){for(let c=0;c<a.local.length;c++){let d=a.local[c].map(o,r,u);d?n.push(d):i.onRemove&&i.onRemove(a.local[c].spec)}for(let c=0;c<a.children.length;c+=3)l(a.children[c+2],a.children[c]+u+1)}for(let a=0;a<e.length;a+=3)e[a+1]==-1&&l(e[a+2],t[a]+s+1);return n}function dN(e,t,n){if(t.isLeaf)return null;let o=n+t.nodeSize,r=null;for(let s=0,i;s<e.length;s++)(i=e[s])&&i.from>n&&i.to<o&&((r||(r=[])).push(i),e[s]=null);return r}function fN(e){let t=[];for(let n=0;n<e.length;n++)e[n]!=null&&t.push(e[n]);return t}function e0(e,t,n,o){let r=[],s=!1;t.forEach((l,a)=>{let u=dN(e,l,a+n);if(u){s=!0;let c=e0(u,l,n+a+1,o);c!=fo&&r.push(a,a+l.nodeSize,c)}});let i=cN(s?fN(e):e,-n).sort(Ya);for(let l=0;l<i.length;l++)i[l].type.valid(t,i[l])||(o.onRemove&&o.onRemove(i[l].spec),i.splice(l--,1));return i.length||r.length?new an(i,r):fo}function Ya(e,t){return e.from-t.from||e.to-t.to}function CC(e){let t=e;for(let n=0;n<t.length-1;n++){let o=t[n];if(o.from!=o.to)for(let r=n+1;r<t.length;r++){let s=t[r];if(s.from==o.from){s.to!=o.to&&(t==e&&(t=e.slice()),t[r]=s.copy(s.from,o.to),g9(t,r+1,s.copy(o.to,s.to)));continue}else{s.from<o.to&&(t==e&&(t=e.slice()),t[n]=o.copy(o.from,s.from),g9(t,r,o.copy(s.from,o.to)));break}}}return t}function g9(e,t,n){for(;t<e.length&&Ya(n,e[t])>0;)t++;e.splice(t,0,n)}function Fy(e){let t=[];return e.someProp("decorations",n=>{let o=n(e.state);o&&o!=fo&&t.push(o)}),e.cursorWrapper&&t.push(an.create(e.state.doc,[e.cursorWrapper.deco])),Sl.from(t)}const Y3e={childList:!0,characterData:!0,characterDataOldValue:!0,attributes:!0,attributeOldValue:!0,subtree:!0},Z3e=Go&&Rl<=11;class J3e{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}set(t){this.anchorNode=t.anchorNode,this.anchorOffset=t.anchorOffset,this.focusNode=t.focusNode,this.focusOffset=t.focusOffset}clear(){this.anchorNode=this.focusNode=null}eq(t){return t.anchorNode==this.anchorNode&&t.anchorOffset==this.anchorOffset&&t.focusNode==this.focusNode&&t.focusOffset==this.focusOffset}}class X3e{constructor(t,n){this.view=t,this.handleDOMChange=n,this.queue=[],this.flushingSoon=-1,this.observer=null,this.currentSelection=new J3e,this.onCharData=null,this.suppressingSelectionUpdates=!1,this.lastChangedTextNode=null,this.observer=window.MutationObserver&&new window.MutationObserver(o=>{for(let r=0;r<o.length;r++)this.queue.push(o[r]);Go&&Rl<=11&&o.some(r=>r.type=="childList"&&r.removedNodes.length||r.type=="characterData"&&r.oldValue.length>r.target.nodeValue.length)?this.flushSoon():this.flush()}),Z3e&&(this.onCharData=o=>{this.queue.push({target:o.target,type:"characterData",oldValue:o.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this)}flushSoon(){this.flushingSoon<0&&(this.flushingSoon=window.setTimeout(()=>{this.flushingSoon=-1,this.flush()},20))}forceFlush(){this.flushingSoon>-1&&(window.clearTimeout(this.flushingSoon),this.flushingSoon=-1,this.flush())}start(){this.observer&&(this.observer.takeRecords(),this.observer.observe(this.view.dom,Y3e)),this.onCharData&&this.view.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.connectSelection()}stop(){if(this.observer){let t=this.observer.takeRecords();if(t.length){for(let n=0;n<t.length;n++)this.queue.push(t[n]);window.setTimeout(()=>this.flush(),20)}this.observer.disconnect()}this.onCharData&&this.view.dom.removeEventListener("DOMCharacterDataModified",this.onCharData),this.disconnectSelection()}connectSelection(){this.view.dom.ownerDocument.addEventListener("selectionchange",this.onSelectionChange)}disconnectSelection(){this.view.dom.ownerDocument.removeEventListener("selectionchange",this.onSelectionChange)}suppressSelectionUpdates(){this.suppressingSelectionUpdates=!0,setTimeout(()=>this.suppressingSelectionUpdates=!1,50)}onSelectionChange(){if(a9(this.view)){if(this.suppressingSelectionUpdates)return Oi(this.view);if(Go&&Rl<=11&&!this.view.state.selection.empty){let t=this.view.domSelectionRange();if(t.focusNode&&hu(t.focusNode,t.focusOffset,t.anchorNode,t.anchorOffset))return this.flushSoon()}this.flush()}}setCurSelection(){this.currentSelection.set(this.view.domSelectionRange())}ignoreSelectionChange(t){if(!t.focusNode)return!0;let n=new Set,o;for(let s=t.focusNode;s;s=Hp(s))n.add(s);for(let s=t.anchorNode;s;s=Hp(s))if(n.has(s)){o=s;break}let r=o&&this.view.docView.nearestDesc(o);if(r&&r.ignoreMutation({type:"selection",target:o.nodeType==3?o.parentNode:o}))return this.setCurSelection(),!0}pendingRecords(){if(this.observer)for(let t of this.observer.takeRecords())this.queue.push(t);return this.queue}flush(){let{view:t}=this;if(!t.docView||this.flushingSoon>-1)return;let n=this.pendingRecords();n.length&&(this.queue=[]);let o=t.domSelectionRange(),r=!this.suppressingSelectionUpdates&&!this.currentSelection.eq(o)&&a9(t)&&!this.ignoreSelectionChange(o),s=-1,i=-1,l=!1,a=[];if(t.editable)for(let c=0;c<n.length;c++){let d=this.registerMutation(n[c],a);d&&(s=s<0?d.from:Math.min(d.from,s),i=i<0?d.to:Math.max(d.to,i),d.typeOver&&(l=!0))}if(vs&&a.length){let c=a.filter(d=>d.nodeName=="BR");if(c.length==2){let[d,f]=c;d.parentNode&&d.parentNode.parentNode==f.parentNode?f.remove():d.remove()}else{let{focusNode:d}=this.currentSelection;for(let f of c){let p=f.parentNode;p&&p.nodeName=="LI"&&(!d||tCe(t,d)!=p)&&f.remove()}}}let u=null;s<0&&r&&t.input.lastFocus>Date.now()-200&&Math.max(t.input.lastTouch,t.input.lastClick.time)<Date.now()-300&&fv(o)&&(u=gC(t))&&u.eq(bt.near(t.state.doc.resolve(0),1))?(t.input.lastFocus=0,Oi(t),this.currentSelection.set(o),t.scrollToSelection()):(s>-1||r)&&(s>-1&&(t.docView.markDirty(s,i),Q3e(t)),this.handleDOMChange(s,i,l,a),t.docView&&t.docView.dirty?t.updateState(t.state):this.currentSelection.eq(o)||Oi(t),this.currentSelection.set(o))}registerMutation(t,n){if(n.indexOf(t.target)>-1)return null;let o=this.view.docView.nearestDesc(t.target);if(t.type=="attributes"&&(o==this.view.docView||t.attributeName=="contenteditable"||t.attributeName=="style"&&!t.oldValue&&!t.target.getAttribute("style"))||!o||o.ignoreMutation(t))return null;if(t.type=="childList"){for(let c=0;c<t.addedNodes.length;c++){let d=t.addedNodes[c];n.push(d),d.nodeType==3&&(this.lastChangedTextNode=d)}if(o.contentDOM&&o.contentDOM!=o.dom&&!o.contentDOM.contains(t.target))return{from:o.posBefore,to:o.posAfter};let r=t.previousSibling,s=t.nextSibling;if(Go&&Rl<=11&&t.addedNodes.length)for(let c=0;c<t.addedNodes.length;c++){let{previousSibling:d,nextSibling:f}=t.addedNodes[c];(!d||Array.prototype.indexOf.call(t.addedNodes,d)<0)&&(r=d),(!f||Array.prototype.indexOf.call(t.addedNodes,f)<0)&&(s=f)}let i=r&&r.parentNode==t.target?no(r)+1:0,l=o.localPosFromDOM(t.target,i,-1),a=s&&s.parentNode==t.target?no(s):t.target.childNodes.length,u=o.localPosFromDOM(t.target,a,1);return{from:l,to:u}}else return t.type=="attributes"?{from:o.posAtStart-o.border,to:o.posAtEnd+o.border}:(this.lastChangedTextNode=t.target,{from:o.posAtStart,to:o.posAtEnd,typeOver:t.target.nodeValue==t.oldValue})}}let v9=new WeakMap,y9=!1;function Q3e(e){if(!v9.has(e)&&(v9.set(e,null),["normal","nowrap","pre-line"].indexOf(getComputedStyle(e.dom).whiteSpace)!==-1)){if(e.requiresGeckoHackNode=vs,y9)return;console.warn("ProseMirror expects the CSS white-space property to be set, preferably to 'pre-wrap'. It is recommended to load style/prosemirror.css from the prosemirror-view package."),y9=!0}}function _9(e,t){let n=t.startContainer,o=t.startOffset,r=t.endContainer,s=t.endOffset,i=e.domAtPos(e.state.selection.anchor);return hu(i.node,i.offset,r,s)&&([n,o,r,s]=[r,s,n,o]),{anchorNode:n,anchorOffset:o,focusNode:r,focusOffset:s}}function eCe(e,t){if(t.getComposedRanges){let r=t.getComposedRanges(e.root)[0];if(r)return _9(e,r)}let n;function o(r){r.preventDefault(),r.stopImmediatePropagation(),n=r.getTargetRanges()[0]}return e.dom.addEventListener("beforeinput",o,!0),document.execCommand("indent"),e.dom.removeEventListener("beforeinput",o,!0),n?_9(e,n):null}function tCe(e,t){for(let n=t.parentNode;n&&n!=e.dom;n=n.parentNode){let o=e.docView.nearestDesc(n,!0);if(o&&o.node.isBlock)return n}return null}function nCe(e,t,n){let{node:o,fromOffset:r,toOffset:s,from:i,to:l}=e.docView.parseRange(t,n),a=e.domSelectionRange(),u,c=a.anchorNode;if(c&&e.dom.contains(c.nodeType==1?c:c.parentNode)&&(u=[{node:c,offset:a.anchorOffset}],fv(a)||u.push({node:a.focusNode,offset:a.focusOffset})),mo&&e.input.lastKeyCode===8)for(let y=s;y>r;y--){let v=o.childNodes[y-1],w=v.pmViewDesc;if(v.nodeName=="BR"&&!w){s=y;break}if(!w||w.size)break}let d=e.state.doc,f=e.someProp("domParser")||fu.fromSchema(e.state.schema),p=d.resolve(i),h=null,m=f.parse(o,{topNode:p.parent,topMatch:p.parent.contentMatchAt(p.index()),topOpen:!0,from:r,to:s,preserveWhitespace:p.parent.type.whitespace=="pre"?"full":!0,findPositions:u,ruleFromNode:oCe,context:p});if(u&&u[0].pos!=null){let y=u[0].pos,v=u[1]&&u[1].pos;v==null&&(v=y),h={anchor:y+i,head:v+i}}return{doc:m,sel:h,from:i,to:l}}function oCe(e){let t=e.pmViewDesc;if(t)return t.parseRule();if(e.nodeName=="BR"&&e.parentNode){if(Io&&/^(ul|ol)$/i.test(e.parentNode.nodeName)){let n=document.createElement("div");return n.appendChild(document.createElement("li")),{skip:n}}else if(e.parentNode.lastChild==e||Io&&/^(tr|table)$/i.test(e.parentNode.nodeName))return{ignore:!0}}else if(e.nodeName=="IMG"&&e.getAttribute("mark-placeholder"))return{ignore:!0};return null}const rCe=/^(a|abbr|acronym|b|bd[io]|big|br|button|cite|code|data(list)?|del|dfn|em|i|ins|kbd|label|map|mark|meter|output|q|ruby|s|samp|small|span|strong|su[bp]|time|u|tt|var)$/i;function sCe(e,t,n,o,r){let s=e.input.compositionPendingChanges||(e.composing?e.input.compositionID:0);if(e.input.compositionPendingChanges=0,t<0){let P=e.input.lastSelectionTime>Date.now()-50?e.input.lastSelectionOrigin:null,N=gC(e,P);if(N&&!e.state.selection.eq(N)){if(mo&&rs&&e.input.lastKeyCode===13&&Date.now()-100<e.input.lastKeyCodeTime&&e.someProp("handleKeyDown",B=>B(e,xa(13,"Enter"))))return;let F=e.state.tr.setSelection(N);P=="pointer"?F.setMeta("pointer",!0):P=="key"&&F.scrollIntoView(),s&&F.setMeta("composition",s),e.dispatch(F)}return}let i=e.state.doc.resolve(t),l=i.sharedDepth(n);t=i.before(l+1),n=e.state.doc.resolve(n).after(l+1);let a=e.state.selection,u=nCe(e,t,n),c=e.state.doc,d=c.slice(u.from,u.to),f,p;e.input.lastKeyCode===8&&Date.now()-100<e.input.lastKeyCodeTime?(f=e.state.selection.to,p="end"):(f=e.state.selection.from,p="start"),e.input.lastKeyCode=null;let h=aCe(d.content,u.doc.content,u.from,f,p);if((pd&&e.input.lastIOSEnter>Date.now()-225||rs)&&r.some(P=>P.nodeType==1&&!rCe.test(P.nodeName))&&(!h||h.endA>=h.endB)&&e.someProp("handleKeyDown",P=>P(e,xa(13,"Enter")))){e.input.lastIOSEnter=0;return}if(!h)if(o&&a instanceof ht&&!a.empty&&a.$head.sameParent(a.$anchor)&&!e.composing&&!(u.sel&&u.sel.anchor!=u.sel.head))h={start:a.from,endA:a.to,endB:a.to};else{if(u.sel){let P=b9(e,e.state.doc,u.sel);if(P&&!P.eq(e.state.selection)){let N=e.state.tr.setSelection(P);s&&N.setMeta("composition",s),e.dispatch(N)}}return}e.input.domChangeCount++,e.state.selection.from<e.state.selection.to&&h.start==h.endB&&e.state.selection instanceof ht&&(h.start>e.state.selection.from&&h.start<=e.state.selection.from+2&&e.state.selection.from>=u.from?h.start=e.state.selection.from:h.endA<e.state.selection.to&&h.endA>=e.state.selection.to-2&&e.state.selection.to<=u.to&&(h.endB+=e.state.selection.to-h.endA,h.endA=e.state.selection.to)),Go&&Rl<=11&&h.endB==h.start+1&&h.endA==h.start&&h.start>u.from&&u.doc.textBetween(h.start-u.from-1,h.start-u.from+1)=="  "&&(h.start--,h.endA--,h.endB--);let m=u.doc.resolveNoCache(h.start-u.from),y=u.doc.resolveNoCache(h.endB-u.from),v=c.resolve(h.start),w=m.sameParent(y)&&m.parent.inlineContent&&v.end()>=h.endA,_;if((pd&&e.input.lastIOSEnter>Date.now()-225&&(!w||r.some(P=>P.nodeName=="DIV"||P.nodeName=="P"))||!w&&m.pos<u.doc.content.size&&!m.sameParent(y)&&(_=bt.findFrom(u.doc.resolve(m.pos+1),1,!0))&&_.head==y.pos)&&e.someProp("handleKeyDown",P=>P(e,xa(13,"Enter")))){e.input.lastIOSEnter=0;return}if(e.state.selection.anchor>h.start&&lCe(c,h.start,h.endA,m,y)&&e.someProp("handleKeyDown",P=>P(e,xa(8,"Backspace")))){rs&&mo&&e.domObserver.suppressSelectionUpdates();return}mo&&rs&&h.endB==h.start&&(e.input.lastAndroidDelete=Date.now()),rs&&!w&&m.start()!=y.start()&&y.parentOffset==0&&m.depth==y.depth&&u.sel&&u.sel.anchor==u.sel.head&&u.sel.head==h.endA&&(h.endB-=2,y=u.doc.resolveNoCache(h.endB-u.from),setTimeout(()=>{e.someProp("handleKeyDown",function(P){return P(e,xa(13,"Enter"))})},20));let S=h.start,x=h.endA,E,T,O;if(w){if(m.pos==y.pos)Go&&Rl<=11&&m.parentOffset==0&&(e.domObserver.suppressSelectionUpdates(),setTimeout(()=>Oi(e),20)),E=e.state.tr.delete(S,x),T=c.resolve(h.start).marksAcross(c.resolve(h.endA));else if(h.endA==h.endB&&(O=iCe(m.parent.content.cut(m.parentOffset,y.parentOffset),v.parent.content.cut(v.parentOffset,h.endA-v.start()))))E=e.state.tr,O.type=="add"?E.addMark(S,x,O.mark):E.removeMark(S,x,O.mark);else if(m.parent.child(m.index()).isText&&m.index()==y.index()-(y.textOffset?0:1)){let P=m.parent.textBetween(m.parentOffset,y.parentOffset);if(e.someProp("handleTextInput",N=>N(e,S,x,P)))return;E=e.state.tr.insertText(P,S,x)}}if(E||(E=e.state.tr.replace(S,x,u.doc.slice(h.start-u.from,h.endB-u.from))),u.sel){let P=b9(e,E.doc,u.sel);P&&!(mo&&rs&&e.composing&&P.empty&&(h.start!=h.endB||e.input.lastAndroidDelete<Date.now()-100)&&(P.head==S||P.head==E.mapping.map(x)-1)||Go&&P.empty&&P.head==S)&&E.setSelection(P)}T&&E.ensureMarks(T),s&&E.setMeta("composition",s),e.dispatch(E.scrollIntoView())}function b9(e,t,n){return Math.max(n.anchor,n.head)>t.content.size?null:vC(e,t.resolve(n.anchor),t.resolve(n.head))}function iCe(e,t){let n=e.firstChild.marks,o=t.firstChild.marks,r=n,s=o,i,l,a;for(let c=0;c<o.length;c++)r=o[c].removeFromSet(r);for(let c=0;c<n.length;c++)s=n[c].removeFromSet(s);if(r.length==1&&s.length==0)l=r[0],i="add",a=c=>c.mark(l.addToSet(c.marks));else if(r.length==0&&s.length==1)l=s[0],i="remove",a=c=>c.mark(l.removeFromSet(c.marks));else return null;let u=[];for(let c=0;c<t.childCount;c++)u.push(a(t.child(c)));if(Ue.from(u).eq(e))return{mark:l,type:i}}function lCe(e,t,n,o,r){if(n-t<=r.pos-o.pos||Vy(o,!0,!1)<r.pos)return!1;let s=e.resolve(t);if(!o.parent.isTextblock){let l=s.nodeAfter;return l!=null&&n==t+l.nodeSize}if(s.parentOffset<s.parent.content.size||!s.parent.isTextblock)return!1;let i=e.resolve(Vy(s,!0,!0));return!i.parent.isTextblock||i.pos>n||Vy(i,!0,!1)<n?!1:o.parent.content.cut(o.parentOffset).eq(i.parent.content)}function Vy(e,t,n){let o=e.depth,r=t?e.end():e.pos;for(;o>0&&(t||e.indexAfter(o)==e.node(o).childCount);)o--,r++,t=!1;if(n){let s=e.node(o).maybeChild(e.indexAfter(o));for(;s&&!s.isLeaf;)s=s.firstChild,r++}return r}function aCe(e,t,n,o,r){let s=e.findDiffStart(t,n);if(s==null)return null;let{a:i,b:l}=e.findDiffEnd(t,n+e.size,n+t.size);if(r=="end"){let a=Math.max(0,s-Math.min(i,l));o-=i+a-s}if(i<s&&e.size<t.size){let a=o<=s&&o>=i?s-o:0;s-=a,s&&s<t.size&&w9(t.textBetween(s-1,s+1))&&(s+=a?1:-1),l=s+(l-i),i=s}else if(l<s){let a=o<=s&&o>=l?s-o:0;s-=a,s&&s<e.size&&w9(e.textBetween(s-1,s+1))&&(s+=a?1:-1),i=s+(i-l),l=s}return{start:s,endA:i,endB:l}}function w9(e){if(e.length!=2)return!1;let t=e.charCodeAt(0),n=e.charCodeAt(1);return t>=56320&&t<=57343&&n>=55296&&n<=56319}class uCe{constructor(t,n){this._root=null,this.focused=!1,this.trackWrites=null,this.mounted=!1,this.markCursor=null,this.cursorWrapper=null,this.lastSelectedViewDesc=void 0,this.input=new M3e,this.prevDirectPlugins=[],this.pluginViews=[],this.requiresGeckoHackNode=!1,this.dragging=null,this._props=n,this.state=n.state,this.directPlugins=n.plugins||[],this.directPlugins.forEach(E9),this.dispatch=this.dispatch.bind(this),this.dom=t&&t.mount||document.createElement("div"),t&&(t.appendChild?t.appendChild(this.dom):typeof t=="function"?t(this.dom):t.mount&&(this.mounted=!0)),this.editable=S9(this),k9(this),this.nodeViews=$9(this),this.docView=n9(this.state.doc,C9(this),Fy(this),this.dom,this),this.domObserver=new X3e(this,(o,r,s,i)=>sCe(this,o,r,s,i)),this.domObserver.start(),T3e(this),this.updatePluginViews()}get composing(){return this.input.composing}get props(){if(this._props.state!=this.state){let t=this._props;this._props={};for(let n in t)this._props[n]=t[n];this._props.state=this.state}return this._props}update(t){t.handleDOMEvents!=this._props.handleDOMEvents&&d2(this);let n=this._props;this._props=t,t.plugins&&(t.plugins.forEach(E9),this.directPlugins=t.plugins),this.updateStateInner(t.state,n)}setProps(t){let n={};for(let o in this._props)n[o]=this._props[o];n.state=this.state;for(let o in t)n[o]=t[o];this.update(n)}updateState(t){this.updateStateInner(t,this._props)}updateStateInner(t,n){var o;let r=this.state,s=!1,i=!1;t.storedMarks&&this.composing&&(iN(this),i=!0),this.state=t;let l=r.plugins!=t.plugins||this._props.plugins!=n.plugins;if(l||this._props.plugins!=n.plugins||this._props.nodeViews!=n.nodeViews){let p=$9(this);dCe(p,this.nodeViews)&&(this.nodeViews=p,s=!0)}(l||n.handleDOMEvents!=this._props.handleDOMEvents)&&d2(this),this.editable=S9(this),k9(this);let a=Fy(this),u=C9(this),c=r.plugins!=t.plugins&&!r.doc.eq(t.doc)?"reset":t.scrollToSelection>r.scrollToSelection?"to selection":"preserve",d=s||!this.docView.matchesNode(t.doc,u,a);(d||!t.selection.eq(r.selection))&&(i=!0);let f=c=="preserve"&&i&&this.dom.style.overflowAnchor==null&&Uwe(this);if(i){this.domObserver.stop();let p=d&&(Go||mo)&&!this.composing&&!r.selection.empty&&!t.selection.empty&&cCe(r.selection,t.selection);if(d){let h=mo?this.trackWrites=this.domSelectionRange().focusNode:null;this.composing&&(this.input.compositionNode=j3e(this)),(s||!this.docView.update(t.doc,u,a,this))&&(this.docView.updateOuterDeco(u),this.docView.destroy(),this.docView=n9(t.doc,u,a,this.dom,this)),h&&!this.trackWrites&&(p=!0)}p||!(this.input.mouseDown&&this.domObserver.currentSelection.eq(this.domSelectionRange())&&h3e(this))?Oi(this,p):(qA(this,t.selection),this.domObserver.setCurSelection()),this.domObserver.start()}this.updatePluginViews(r),!((o=this.dragging)===null||o===void 0)&&o.node&&!r.doc.eq(t.doc)&&this.updateDraggedNode(this.dragging,r),c=="reset"?this.dom.scrollTop=0:c=="to selection"?this.scrollToSelection():f&&Wwe(f)}scrollToSelection(){let t=this.domSelectionRange().focusNode;if(!this.someProp("handleScrollToSelection",n=>n(this)))if(this.state.selection instanceof mt){let n=this.docView.domAfterPos(this.state.selection.from);n.nodeType==1&&ZS(this,n.getBoundingClientRect(),t)}else ZS(this,this.coordsAtPos(this.state.selection.head,1),t)}destroyPluginViews(){let t;for(;t=this.pluginViews.pop();)t.destroy&&t.destroy()}updatePluginViews(t){if(!t||t.plugins!=this.state.plugins||this.directPlugins!=this.prevDirectPlugins){this.prevDirectPlugins=this.directPlugins,this.destroyPluginViews();for(let n=0;n<this.directPlugins.length;n++){let o=this.directPlugins[n];o.spec.view&&this.pluginViews.push(o.spec.view(this))}for(let n=0;n<this.state.plugins.length;n++){let o=this.state.plugins[n];o.spec.view&&this.pluginViews.push(o.spec.view(this))}}else for(let n=0;n<this.pluginViews.length;n++){let o=this.pluginViews[n];o.update&&o.update(this,t)}}updateDraggedNode(t,n){let o=t.node,r=-1;if(this.state.doc.nodeAt(o.from)==o.node)r=o.from;else{let s=o.from+(this.state.doc.content.size-n.doc.content.size);(s>0&&this.state.doc.nodeAt(s))==o.node&&(r=s)}this.dragging=new aN(t.slice,t.move,r<0?void 0:mt.create(this.state.doc,r))}someProp(t,n){let o=this._props&&this._props[t],r;if(o!=null&&(r=n?n(o):o))return r;for(let i=0;i<this.directPlugins.length;i++){let l=this.directPlugins[i].props[t];if(l!=null&&(r=n?n(l):l))return r}let s=this.state.plugins;if(s)for(let i=0;i<s.length;i++){let l=s[i].props[t];if(l!=null&&(r=n?n(l):l))return r}}hasFocus(){if(Go){let t=this.root.activeElement;if(t==this.dom)return!0;if(!t||!this.dom.contains(t))return!1;for(;t&&this.dom!=t&&this.dom.contains(t);){if(t.contentEditable=="false")return!1;t=t.parentElement}return!0}return this.root.activeElement==this.dom}focus(){this.domObserver.stop(),this.editable&&Kwe(this.dom),Oi(this),this.domObserver.start()}get root(){let t=this._root;if(t==null){for(let n=this.dom.parentNode;n;n=n.parentNode)if(n.nodeType==9||n.nodeType==11&&n.host)return n.getSelection||(Object.getPrototypeOf(n).getSelection=()=>n.ownerDocument.getSelection()),this._root=n}return t||document}updateRoot(){this._root=null}posAtCoords(t){return Jwe(this,t)}coordsAtPos(t,n=1){return VA(this,t,n)}domAtPos(t,n=0){return this.docView.domFromPos(t,n)}nodeDOM(t){let n=this.docView.descAt(t);return n?n.nodeDOM:null}posAtDOM(t,n,o=-1){let r=this.docView.posFromDOM(t,n,o);if(r==null)throw new RangeError("DOM position not inside the editor");return r}endOfTextblock(t,n){return n3e(this,n||this.state,t)}pasteHTML(t,n){return Wp(this,"",t,!1,n||new ClipboardEvent("paste"))}pasteText(t,n){return Wp(this,t,null,!0,n||new ClipboardEvent("paste"))}destroy(){this.docView&&(O3e(this),this.destroyPluginViews(),this.mounted?(this.docView.update(this.state.doc,[],Fy(this),this),this.dom.textContent=""):this.dom.parentNode&&this.dom.parentNode.removeChild(this.dom),this.docView.destroy(),this.docView=null,Nwe())}get isDestroyed(){return this.docView==null}dispatchEvent(t){return A3e(this,t)}dispatch(t){let n=this._props.dispatchTransaction;n?n.call(this,t):this.updateState(this.state.apply(t))}domSelectionRange(){let t=this.domSelection();return t?Io&&this.root.nodeType===11&&Fwe(this.dom.ownerDocument)==this.dom&&eCe(this,t)||t:{focusNode:null,focusOffset:0,anchorNode:null,anchorOffset:0}}domSelection(){return this.root.getSelection()}}function C9(e){let t=Object.create(null);return t.class="ProseMirror",t.contenteditable=String(e.editable),e.someProp("attributes",n=>{if(typeof n=="function"&&(n=n(e.state)),n)for(let o in n)o=="class"?t.class+=" "+n[o]:o=="style"?t.style=(t.style?t.style+";":"")+n[o]:!t[o]&&o!="contenteditable"&&o!="nodeName"&&(t[o]=String(n[o]))}),t.translate||(t.translate="no"),[zn.node(0,e.state.doc.content.size,t)]}function k9(e){if(e.markCursor){let t=document.createElement("img");t.className="ProseMirror-separator",t.setAttribute("mark-placeholder","true"),t.setAttribute("alt",""),e.cursorWrapper={dom:t,deco:zn.widget(e.state.selection.from,t,{raw:!0,marks:e.markCursor})}}else e.cursorWrapper=null}function S9(e){return!e.someProp("editable",t=>t(e.state)===!1)}function cCe(e,t){let n=Math.min(e.$anchor.sharedDepth(e.head),t.$anchor.sharedDepth(t.head));return e.$anchor.start(n)!=t.$anchor.start(n)}function $9(e){let t=Object.create(null);function n(o){for(let r in o)Object.prototype.hasOwnProperty.call(t,r)||(t[r]=o[r])}return e.someProp("nodeViews",n),e.someProp("markViews",n),t}function dCe(e,t){let n=0,o=0;for(let r in e){if(e[r]!=t[r])return!0;n++}for(let r in t)o++;return n!=o}function E9(e){if(e.spec.state||e.spec.filterTransaction||e.spec.appendTransaction)throw new RangeError("Plugins passed directly to the view must not have a state component")}var pN=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},ct=(e,t,n)=>(pN(e,t,"read from private field"),n?n.call(e):t.get(e)),Zn=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},_n=(e,t,n,o)=>(pN(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n);function sa(e,t){return e.meta={package:"@milkdown/core",group:"System",...t},e}const hN={strong:(e,t,n,o)=>{const r=e.marker||n.options.strong||"*",s=n.enter("strong"),i=n.createTracker(o);let l=i.move(r+r);return l+=i.move(n.containerPhrasing(e,{before:l,after:r,...i.current()})),l+=i.move(r+r),s(),l},emphasis:(e,t,n,o)=>{const r=e.marker||n.options.emphasis||"*",s=n.enter("emphasis"),i=n.createTracker(o);let l=i.move(r);return l+=i.move(n.containerPhrasing(e,{before:l,after:r,...i.current()})),l+=i.move(r),s(),l}},bn=jt({},"editorView"),vf=jt({},"editorState"),By=jt([],"initTimer"),x9=jt({},"editor"),qp=jt([],"inputRules"),ys=jt([],"prosePlugins"),Gp=jt([],"remarkPlugins"),f2=jt([],"nodeView"),p2=jt([],"markView"),Za=jt(Kb().use(Vb).use(Hb),"remark"),rp=jt({handlers:hN},"remarkStringifyOptions"),$1=ea("ConfigReady");function fCe(e){const t=n=>(n.record($1),async()=>(await e(n),n.done($1),()=>{n.clearTimer($1)}));return sa(t,{displayName:"Config"}),t}const Ja=ea("InitReady");function pCe(e){const t=n=>(n.inject(x9,e).inject(ys,[]).inject(Gp,[]).inject(qp,[]).inject(f2,[]).inject(p2,[]).inject(rp,{handlers:hN}).inject(Za,Kb().use(Vb).use(Hb)).inject(By,[$1]).record(Ja),async()=>{await n.waitTimers(By);const o=n.get(rp);return n.set(Za,Kb().use(Vb).use(Hb,o)),n.done(Ja),()=>{n.remove(x9).remove(ys).remove(Gp).remove(qp).remove(f2).remove(p2).remove(rp).remove(Za).remove(By).clearTimer(Ja)}});return sa(t,{displayName:"Init"}),t}const Us=ea("SchemaReady"),zy=jt([],"schemaTimer"),ds=jt({},"schema"),Tc=jt([],"nodes"),Oc=jt([],"marks");function M9(e){var t;return{...e,parseDOM:(t=e.parseDOM)==null?void 0:t.map(n=>({priority:e.priority,...n}))}}const mN=e=>(e.inject(ds,{}).inject(Tc,[]).inject(Oc,[]).inject(zy,[Ja]).record(Us),async()=>{await e.waitTimers(zy);const t=e.get(Za),n=e.get(Gp).reduce((i,l)=>i.use(l.plugin,l.options),t);e.set(Za,n);const o=Object.fromEntries(e.get(Tc).map(([i,l])=>[i,M9(l)])),r=Object.fromEntries(e.get(Oc).map(([i,l])=>[i,M9(l)])),s=new Tve({nodes:o,marks:r});return e.set(ds,s),e.done(Us),()=>{e.remove(ds).remove(Tc).remove(Oc).remove(zy).clearTimer(Us)}});sa(mN,{displayName:"Schema"});var tc,Ca;let gN=class{constructor(){Zn(this,tc,void 0),Zn(this,Ca,void 0),_n(this,tc,new rI),_n(this,Ca,null),this.setCtx=t=>{_n(this,Ca,t)}}get ctx(){return ct(this,Ca)}create(t,n){const o=t.create(ct(this,tc).sliceMap);return o.set(n),o}get(t){return ct(this,tc).get(t).get()}remove(t){return ct(this,tc).remove(t)}call(t,n){if(ct(this,Ca)==null)throw ove();const o=this.get(t)(n),r=ct(this,Ca).get(bn);return o(r.state,r.dispatch,r)}};tc=new WeakMap,Ca=new WeakMap;function hCe(e="cmdKey"){return jt(()=>()=>!1,e)}const Dt=jt(new gN,"commands"),jy=jt([Us],"commandsTimer"),sp=ea("CommandsReady"),vN=e=>{const t=new gN;return t.setCtx(e),e.inject(Dt,t).inject(jy,[Us]).record(sp),async()=>(await e.waitTimers(jy),e.done(sp),()=>{e.remove(Dt).remove(jy).clearTimer(sp)})};sa(vN,{displayName:"Commands"});const E1=ea("ParserReady"),yN=()=>{throw J3()},Ic=jt(yN,"parser"),Hy=jt([],"parserTimer"),_N=e=>(e.inject(Ic,yN).inject(Hy,[Us]).record(E1),async()=>{await e.waitTimers(Hy);const t=e.get(Za),n=e.get(ds);return e.set(Ic,u2e.create(n,t)),e.done(E1),()=>{e.remove(Ic).remove(Hy).clearTimer(E1)}});sa(_N,{displayName:"Parser"});const ip=ea("SerializerReady"),Uy=jt([],"serializerTimer"),bN=()=>{throw J3()},Ac=jt(bN,"serializer"),wN=e=>(e.inject(Ac,bN).inject(Uy,[Us]).record(ip),async()=>{await e.waitTimers(Uy);const t=e.get(Za),n=e.get(ds);return e.set(Ac,d2e.create(n,t)),e.done(ip),()=>{e.remove(Ac).remove(Uy).clearTimer(ip)}});sa(wN,{displayName:"Serializer"});const x1=jt("","defaultValue"),M1=jt(e=>e,"stateOptions"),Wy=jt([],"editorStateTimer"),T1=ea("EditorStateReady");function mCe(e,t,n){if(typeof e=="string")return t(e);if(e.type==="html")return fu.fromSchema(n).parse(e.dom);if(e.type==="json")return Ll.fromJSON(n,e.value);throw Z0e(e)}const gCe=new wn("MILKDOWN_STATE_TRACKER");function vCe(e){const t=dv(z2e,fC,SA,$A);return e.Backspace=t,e}const CN=e=>(e.inject(x1,"").inject(vf,{}).inject(M1,t=>t).inject(Wy,[E1,ip,sp]).record(T1),async()=>{await e.waitTimers(Wy);const t=e.get(ds),n=e.get(Ic),o=e.get(qp),r=e.get(M1),s=e.get(ys),i=e.get(x1),l=mCe(i,n,t),a=[...s,new xn({key:gCe,state:{init:()=>{},apply:(d,f,p,h)=>{e.set(vf,h)}}}),Z2e({rules:o}),IA(vCe(Ewe))];e.set(ys,a);const u=r({schema:t,doc:l,plugins:a}),c=La.create(u);return e.set(vf,c),e.done(T1),()=>{e.remove(x1).remove(vf).remove(M1).remove(Wy).clearTimer(T1)}});sa(CN,{displayName:"EditorState"});const O1=ea("EditorViewReady"),Ky=jt([],"editorViewTimer"),lp=jt({},"editorViewOptions"),I1=jt(null,"root"),h2=jt(null,"rootDOM"),m2=jt({},"rootAttrs");function yCe(e,t){const n=document.createElement("div");n.className="milkdown",e.appendChild(n),t.set(h2,n);const o=t.get(m2);return Object.entries(o).forEach(([r,s])=>n.setAttribute(r,s)),n}function _Ce(e){e.classList.add("editor"),e.setAttribute("role","textbox")}const bCe=new wn("MILKDOWN_VIEW_CLEAR"),kN=e=>(e.inject(I1,document.body).inject(bn,{}).inject(lp,{}).inject(h2,null).inject(m2,{}).inject(Ky,[T1]).record(O1),async()=>{await e.wait(Ja);const t=e.get(I1)||document.body,n=typeof t=="string"?document.querySelector(t):t;e.update(ys,a=>[new xn({key:bCe,view:u=>{const c=n?yCe(n,e):void 0;return(()=>{if(c&&n){const d=u.dom;n.replaceChild(c,d),c.appendChild(d)}})(),{destroy:()=>{c!=null&&c.parentNode&&(c==null||c.parentNode.replaceChild(u.dom,c)),c==null||c.remove()}}}}),...a]),await e.waitTimers(Ky);const o=e.get(vf),r=e.get(lp),s=Object.fromEntries(e.get(f2)),i=Object.fromEntries(e.get(p2)),l=new uCe(n,{state:o,nodeViews:s,markViews:i,...r});return _Ce(l.dom),e.set(bn,l),e.done(O1),()=>{l==null||l.destroy(),e.remove(I1).remove(bn).remove(lp).remove(h2).remove(m2).remove(Ky).clearTimer(O1)}});sa(kN,{displayName:"EditorView"});var nc,$r,al,yf,A1,N1,rr,ul,oc,P1,rc,_f,L1,ka,bf;const wCe=class SN{constructor(){Zn(this,nc,void 0),Zn(this,$r,void 0),Zn(this,al,void 0),Zn(this,yf,void 0),Zn(this,A1,void 0),Zn(this,N1,void 0),Zn(this,rr,void 0),Zn(this,ul,void 0),Zn(this,oc,void 0),Zn(this,P1,void 0),Zn(this,rc,void 0),Zn(this,_f,void 0),Zn(this,L1,void 0),Zn(this,ka,void 0),Zn(this,bf,void 0),_n(this,nc,!1),_n(this,$r,"Idle"),_n(this,al,[]),_n(this,yf,()=>{}),_n(this,A1,new rI),_n(this,N1,new cve),_n(this,rr,new Map),_n(this,ul,new Map),_n(this,oc,new uve(ct(this,A1),ct(this,N1))),_n(this,P1,()=>{const t=fCe(async o=>{await Promise.all(ct(this,al).map(r=>r(o)))}),n=[mN,_N,wN,vN,CN,kN,pCe(this),t];ct(this,rc).call(this,n,ct(this,ul))}),_n(this,rc,(t,n)=>{t.forEach(o=>{const r=ct(this,oc).produce(ct(this,nc)?o.meta:void 0),s=o(r);n.set(o,{ctx:r,handler:s,cleanup:void 0})})}),_n(this,_f,(t,n=!1)=>Promise.all([t].flat().map(o=>{const r=ct(this,rr).get(o),s=r==null?void 0:r.cleanup;return n?ct(this,rr).delete(o):ct(this,rr).set(o,{ctx:void 0,handler:void 0,cleanup:void 0}),typeof s=="function"?s():s}))),_n(this,L1,async()=>{await Promise.all([...ct(this,ul).entries()].map(([t,{cleanup:n}])=>typeof n=="function"?n():n)),ct(this,ul).clear()}),_n(this,ka,t=>{_n(this,$r,t),ct(this,yf).call(this,t)}),_n(this,bf,t=>[...t.entries()].map(async([n,o])=>{const{ctx:r,handler:s}=o;if(!s)return;const i=await s();t.set(n,{ctx:r,handler:s,cleanup:i})})),this.enableInspector=(t=!0)=>(_n(this,nc,t),this),this.onStatusChange=t=>(_n(this,yf,t),this),this.config=t=>(ct(this,al).push(t),this),this.removeConfig=t=>(_n(this,al,ct(this,al).filter(n=>n!==t)),this),this.use=t=>{const n=[t].flat();return n.flat().forEach(o=>{ct(this,rr).set(o,{ctx:void 0,handler:void 0,cleanup:void 0})}),ct(this,$r)==="Created"&&ct(this,rc).call(this,n,ct(this,rr)),this},this.remove=async t=>ct(this,$r)==="OnCreate"?(console.warn("[Milkdown]: You are trying to remove plugins when the editor is creating, this is not recommended, please check your code."),new Promise(n=>{setTimeout(()=>{n(this.remove(t))},50)})):(await ct(this,_f).call(this,[t].flat(),!0),this),this.create=async()=>ct(this,$r)==="OnCreate"?this:(ct(this,$r)==="Created"&&await this.destroy(),ct(this,ka).call(this,"OnCreate"),ct(this,P1).call(this),ct(this,rc).call(this,[...ct(this,rr).keys()],ct(this,rr)),await Promise.all([ct(this,bf).call(this,ct(this,ul)),ct(this,bf).call(this,ct(this,rr))].flat()),ct(this,ka).call(this,"Created"),this),this.destroy=async(t=!1)=>ct(this,$r)==="Destroyed"||ct(this,$r)==="OnDestroy"?this:ct(this,$r)==="OnCreate"?new Promise(n=>{setTimeout(()=>{n(this.destroy(t))},50)}):(t&&_n(this,al,[]),ct(this,ka).call(this,"OnDestroy"),await ct(this,_f).call(this,[...ct(this,rr).keys()],t),await ct(this,L1).call(this),ct(this,ka).call(this,"Destroyed"),this),this.action=t=>t(ct(this,oc)),this.inspect=()=>ct(this,nc)?[...ct(this,ul).values(),...ct(this,rr).values()].map(({ctx:t})=>{var n;return(n=t==null?void 0:t.inspector)==null?void 0:n.read()}).filter(t=>!!t):(console.warn("[Milkdown]: You are trying to collect inspection when inspector is disabled, please enable inspector by `editor.enableInspector()` first."),[])}static make(){return new SN}get ctx(){return ct(this,oc)}get status(){return ct(this,$r)}};nc=new WeakMap,$r=new WeakMap,al=new WeakMap,yf=new WeakMap,A1=new WeakMap,N1=new WeakMap,rr=new WeakMap,ul=new WeakMap,oc=new WeakMap,P1=new WeakMap,rc=new WeakMap,_f=new WeakMap,L1=new WeakMap,ka=new WeakMap,bf=new WeakMap;let CCe=wCe,kCe=e=>crypto.getRandomValues(new Uint8Array(e)),SCe=(e,t,n)=>{let o=(2<<Math.log(e.length-1)/Math.LN2)-1,r=-~(1.6*o*t/e.length);return(s=t)=>{let i="";for(;;){let l=n(r),a=r;for(;a--;)if(i+=e[l[a]&o]||"",i.length===s)return i}}},$Ce=(e,t=21)=>SCe(e,t,kCe);$Ce("abcedfghicklmn",10);function Tt(e,t){const n=hCe(e),o=r=>async()=>{o.key=n,await r.wait(sp);const s=t(r);return r.get(Dt).create(n,s),o.run=i=>r.get(Dt).call(e,i),()=>{r.get(Dt).remove(n)}};return o}function er(e){const t=n=>async()=>{await n.wait(Us);const o=e(n);return n.update(qp,r=>[...r,o]),t.inputRule=o,()=>{n.update(qp,r=>r.filter(s=>s!==o))}};return t}function ECe(e,t){const n=o=>async()=>{const r=t(o);return o.update(Oc,s=>[...s.filter(i=>i[0]!==e),[e,r]]),n.id=e,n.schema=r,()=>{o.update(Oc,s=>s.filter(([i])=>i!==e))}};return n.type=o=>{const r=o.get(ds).marks[e];if(!r)throw rve(e);return r},n}function kC(e,t){const n=o=>async()=>{const r=t(o);return o.update(Tc,s=>[...s.filter(i=>i[0]!==e),[e,r]]),n.id=e,n.schema=r,()=>{o.update(Tc,s=>s.filter(([i])=>i!==e))}};return n.type=o=>{const r=o.get(ds).nodes[e];if(!r)throw nI(e);return r},n}function ao(e){let t;const n=o=>async()=>(await o.wait(Us),t=e(o),o.update(ys,r=>[...r,t]),()=>{o.update(ys,r=>r.filter(s=>s!==t))});return n.plugin=()=>t,n.key=()=>t.spec.key,n}function xCe(e){const t=n=>async()=>{await n.wait(Us);const o=e(n),r=IA(o);return n.update(ys,s=>[...s,r]),t.keymap=o,()=>{n.update(ys,s=>s.filter(i=>i!==r))}};return t}function In(e,t){const n=jt(e,t),o=r=>(r.inject(n),()=>()=>{r.remove(n)});return o.key=n,o}function Yn(e,t){const n=In(t,e),o=kC(e,s=>s.get(n.key)(s)),r=[n,o];return r.id=o.id,r.node=o,r.type=s=>o.type(s),r.schema=o.schema,r.ctx=n,r.key=n.key,r.extendSchema=s=>i=>()=>{const l=i.get(n.key),a=s(l)(i);i.update(Tc,u=>[...u.filter(c=>c[0]!==e),[e,a]]),r.schema=a},r}function Ih(e,t){const n=In(t,e),o=ECe(e,s=>s.get(n.key)(s)),r=[n,o];return r.id=o.id,r.mark=o,r.type=o.type,r.schema=o.schema,r.ctx=n,r.key=n.key,r.extendSchema=s=>i=>()=>{const l=i.get(n.key),a=s(l)(i);i.update(Oc,u=>[...u.filter(c=>c[0]!==e),[e,a]]),r.schema=a},r}function tr(e,t){const n=Object.fromEntries(Object.entries(t).map(([i,{shortcuts:l}])=>[i,l])),o=In(n,`${e}Keymap`),r=xCe(i=>{const l=i.get(o.key),a=Object.entries(t).flatMap(([u,{command:c}])=>[l[u]].flat().map(d=>[d,c(i)]));return Object.fromEntries(a)}),s=[o,r];return s.ctx=o,s.shortcuts=r,s.key=o.key,s.keymap=r.keymap,s}const $s=(e,t=()=>({}))=>In(t,`${e}Attr`),Ah=(e,t=()=>({}))=>In(t,`${e}Attr`);function Id(e,t,n){const o=In(n??{},e),r=i=>async()=>{await i.wait(Ja);const l={plugin:t(i),options:i.get(o.key)};return i.update(Gp,a=>[...a,l]),()=>{i.update(Gp,a=>a.filter(u=>u!==l))}},s=[o,r];return s.id=e,s.plugin=r,s.options=o,s}function MCe(){return e=>{const t=e.get(bn);return e.get(Ac)(t.state.doc)}}function TCe(e,t=!1){return n=>{const o=n.get(bn),r=n.get(Ic)(e);if(!r)return;if(!t){const{state:u}=o;return o.dispatch(u.tr.replace(0,u.doc.content.size,new Ye(r.content,0,0)))}const s=n.get(ds),i=n.get(M1),l=n.get(ys),a=La.create({schema:s,doc:r,plugins:l,...i});o.updateState(a)}}function mv(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}const OCe=[["ß","ss"],["ẞ","Ss"],["ä","ae"],["Ä","Ae"],["ö","oe"],["Ö","Oe"],["ü","ue"],["Ü","Ue"],["À","A"],["Á","A"],["Â","A"],["Ã","A"],["Ä","Ae"],["Å","A"],["Æ","AE"],["Ç","C"],["È","E"],["É","E"],["Ê","E"],["Ë","E"],["Ì","I"],["Í","I"],["Î","I"],["Ï","I"],["Ð","D"],["Ñ","N"],["Ò","O"],["Ó","O"],["Ô","O"],["Õ","O"],["Ö","Oe"],["Ő","O"],["Ø","O"],["Ù","U"],["Ú","U"],["Û","U"],["Ü","Ue"],["Ű","U"],["Ý","Y"],["Þ","TH"],["ß","ss"],["à","a"],["á","a"],["â","a"],["ã","a"],["ä","ae"],["å","a"],["æ","ae"],["ç","c"],["è","e"],["é","e"],["ê","e"],["ë","e"],["ì","i"],["í","i"],["î","i"],["ï","i"],["ð","d"],["ñ","n"],["ò","o"],["ó","o"],["ô","o"],["õ","o"],["ö","oe"],["ő","o"],["ø","o"],["ù","u"],["ú","u"],["û","u"],["ü","ue"],["ű","u"],["ý","y"],["þ","th"],["ÿ","y"],["ẞ","SS"],["à","a"],["À","A"],["á","a"],["Á","A"],["â","a"],["Â","A"],["ã","a"],["Ã","A"],["è","e"],["È","E"],["é","e"],["É","E"],["ê","e"],["Ê","E"],["ì","i"],["Ì","I"],["í","i"],["Í","I"],["ò","o"],["Ò","O"],["ó","o"],["Ó","O"],["ô","o"],["Ô","O"],["õ","o"],["Õ","O"],["ù","u"],["Ù","U"],["ú","u"],["Ú","U"],["ý","y"],["Ý","Y"],["ă","a"],["Ă","A"],["Đ","D"],["đ","d"],["ĩ","i"],["Ĩ","I"],["ũ","u"],["Ũ","U"],["ơ","o"],["Ơ","O"],["ư","u"],["Ư","U"],["ạ","a"],["Ạ","A"],["ả","a"],["Ả","A"],["ấ","a"],["Ấ","A"],["ầ","a"],["Ầ","A"],["ẩ","a"],["Ẩ","A"],["ẫ","a"],["Ẫ","A"],["ậ","a"],["Ậ","A"],["ắ","a"],["Ắ","A"],["ằ","a"],["Ằ","A"],["ẳ","a"],["Ẳ","A"],["ẵ","a"],["Ẵ","A"],["ặ","a"],["Ặ","A"],["ẹ","e"],["Ẹ","E"],["ẻ","e"],["Ẻ","E"],["ẽ","e"],["Ẽ","E"],["ế","e"],["Ế","E"],["ề","e"],["Ề","E"],["ể","e"],["Ể","E"],["ễ","e"],["Ễ","E"],["ệ","e"],["Ệ","E"],["ỉ","i"],["Ỉ","I"],["ị","i"],["Ị","I"],["ọ","o"],["Ọ","O"],["ỏ","o"],["Ỏ","O"],["ố","o"],["Ố","O"],["ồ","o"],["Ồ","O"],["ổ","o"],["Ổ","O"],["ỗ","o"],["Ỗ","O"],["ộ","o"],["Ộ","O"],["ớ","o"],["Ớ","O"],["ờ","o"],["Ờ","O"],["ở","o"],["Ở","O"],["ỡ","o"],["Ỡ","O"],["ợ","o"],["Ợ","O"],["ụ","u"],["Ụ","U"],["ủ","u"],["Ủ","U"],["ứ","u"],["Ứ","U"],["ừ","u"],["Ừ","U"],["ử","u"],["Ử","U"],["ữ","u"],["Ữ","U"],["ự","u"],["Ự","U"],["ỳ","y"],["Ỳ","Y"],["ỵ","y"],["Ỵ","Y"],["ỷ","y"],["Ỷ","Y"],["ỹ","y"],["Ỹ","Y"],["ء","e"],["آ","a"],["أ","a"],["ؤ","w"],["إ","i"],["ئ","y"],["ا","a"],["ب","b"],["ة","t"],["ت","t"],["ث","th"],["ج","j"],["ح","h"],["خ","kh"],["د","d"],["ذ","dh"],["ر","r"],["ز","z"],["س","s"],["ش","sh"],["ص","s"],["ض","d"],["ط","t"],["ظ","z"],["ع","e"],["غ","gh"],["ـ","_"],["ف","f"],["ق","q"],["ك","k"],["ل","l"],["م","m"],["ن","n"],["ه","h"],["و","w"],["ى","a"],["ي","y"],["َ‎","a"],["ُ","u"],["ِ‎","i"],["٠","0"],["١","1"],["٢","2"],["٣","3"],["٤","4"],["٥","5"],["٦","6"],["٧","7"],["٨","8"],["٩","9"],["چ","ch"],["ک","k"],["گ","g"],["پ","p"],["ژ","zh"],["ی","y"],["۰","0"],["۱","1"],["۲","2"],["۳","3"],["۴","4"],["۵","5"],["۶","6"],["۷","7"],["۸","8"],["۹","9"],["ټ","p"],["ځ","z"],["څ","c"],["ډ","d"],["ﺫ","d"],["ﺭ","r"],["ړ","r"],["ﺯ","z"],["ږ","g"],["ښ","x"],["ګ","g"],["ڼ","n"],["ۀ","e"],["ې","e"],["ۍ","ai"],["ٹ","t"],["ڈ","d"],["ڑ","r"],["ں","n"],["ہ","h"],["ھ","h"],["ے","e"],["А","A"],["а","a"],["Б","B"],["б","b"],["В","V"],["в","v"],["Г","G"],["г","g"],["Д","D"],["д","d"],["ъе","ye"],["Ъе","Ye"],["ъЕ","yE"],["ЪЕ","YE"],["Е","E"],["е","e"],["Ё","Yo"],["ё","yo"],["Ж","Zh"],["ж","zh"],["З","Z"],["з","z"],["И","I"],["и","i"],["ый","iy"],["Ый","Iy"],["ЫЙ","IY"],["ыЙ","iY"],["Й","Y"],["й","y"],["К","K"],["к","k"],["Л","L"],["л","l"],["М","M"],["м","m"],["Н","N"],["н","n"],["О","O"],["о","o"],["П","P"],["п","p"],["Р","R"],["р","r"],["С","S"],["с","s"],["Т","T"],["т","t"],["У","U"],["у","u"],["Ф","F"],["ф","f"],["Х","Kh"],["х","kh"],["Ц","Ts"],["ц","ts"],["Ч","Ch"],["ч","ch"],["Ш","Sh"],["ш","sh"],["Щ","Sch"],["щ","sch"],["Ъ",""],["ъ",""],["Ы","Y"],["ы","y"],["Ь",""],["ь",""],["Э","E"],["э","e"],["Ю","Yu"],["ю","yu"],["Я","Ya"],["я","ya"],["ă","a"],["Ă","A"],["ș","s"],["Ș","S"],["ț","t"],["Ț","T"],["ţ","t"],["Ţ","T"],["ş","s"],["Ş","S"],["ç","c"],["Ç","C"],["ğ","g"],["Ğ","G"],["ı","i"],["İ","I"],["ա","a"],["Ա","A"],["բ","b"],["Բ","B"],["գ","g"],["Գ","G"],["դ","d"],["Դ","D"],["ե","ye"],["Ե","Ye"],["զ","z"],["Զ","Z"],["է","e"],["Է","E"],["ը","y"],["Ը","Y"],["թ","t"],["Թ","T"],["ժ","zh"],["Ժ","Zh"],["ի","i"],["Ի","I"],["լ","l"],["Լ","L"],["խ","kh"],["Խ","Kh"],["ծ","ts"],["Ծ","Ts"],["կ","k"],["Կ","K"],["հ","h"],["Հ","H"],["ձ","dz"],["Ձ","Dz"],["ղ","gh"],["Ղ","Gh"],["ճ","tch"],["Ճ","Tch"],["մ","m"],["Մ","M"],["յ","y"],["Յ","Y"],["ն","n"],["Ն","N"],["շ","sh"],["Շ","Sh"],["ո","vo"],["Ո","Vo"],["չ","ch"],["Չ","Ch"],["պ","p"],["Պ","P"],["ջ","j"],["Ջ","J"],["ռ","r"],["Ռ","R"],["ս","s"],["Ս","S"],["վ","v"],["Վ","V"],["տ","t"],["Տ","T"],["ր","r"],["Ր","R"],["ց","c"],["Ց","C"],["ու","u"],["ՈՒ","U"],["Ու","U"],["փ","p"],["Փ","P"],["ք","q"],["Ք","Q"],["օ","o"],["Օ","O"],["ֆ","f"],["Ֆ","F"],["և","yev"],["ა","a"],["ბ","b"],["გ","g"],["დ","d"],["ე","e"],["ვ","v"],["ზ","z"],["თ","t"],["ი","i"],["კ","k"],["ლ","l"],["მ","m"],["ნ","n"],["ო","o"],["პ","p"],["ჟ","zh"],["რ","r"],["ს","s"],["ტ","t"],["უ","u"],["ფ","ph"],["ქ","q"],["ღ","gh"],["ყ","k"],["შ","sh"],["ჩ","ch"],["ც","ts"],["ძ","dz"],["წ","ts"],["ჭ","tch"],["ხ","kh"],["ჯ","j"],["ჰ","h"],["č","c"],["ď","d"],["ě","e"],["ň","n"],["ř","r"],["š","s"],["ť","t"],["ů","u"],["ž","z"],["Č","C"],["Ď","D"],["Ě","E"],["Ň","N"],["Ř","R"],["Š","S"],["Ť","T"],["Ů","U"],["Ž","Z"],["ހ","h"],["ށ","sh"],["ނ","n"],["ރ","r"],["ބ","b"],["ޅ","lh"],["ކ","k"],["އ","a"],["ވ","v"],["މ","m"],["ފ","f"],["ދ","dh"],["ތ","th"],["ލ","l"],["ގ","g"],["ޏ","gn"],["ސ","s"],["ޑ","d"],["ޒ","z"],["ޓ","t"],["ޔ","y"],["ޕ","p"],["ޖ","j"],["ޗ","ch"],["ޘ","tt"],["ޙ","hh"],["ޚ","kh"],["ޛ","th"],["ޜ","z"],["ޝ","sh"],["ޞ","s"],["ޟ","d"],["ޠ","t"],["ޡ","z"],["ޢ","a"],["ޣ","gh"],["ޤ","q"],["ޥ","w"],["ަ","a"],["ާ","aa"],["ި","i"],["ީ","ee"],["ު","u"],["ޫ","oo"],["ެ","e"],["ޭ","ey"],["ޮ","o"],["ޯ","oa"],["ް",""],["α","a"],["β","v"],["γ","g"],["δ","d"],["ε","e"],["ζ","z"],["η","i"],["θ","th"],["ι","i"],["κ","k"],["λ","l"],["μ","m"],["ν","n"],["ξ","ks"],["ο","o"],["π","p"],["ρ","r"],["σ","s"],["τ","t"],["υ","y"],["φ","f"],["χ","x"],["ψ","ps"],["ω","o"],["ά","a"],["έ","e"],["ί","i"],["ό","o"],["ύ","y"],["ή","i"],["ώ","o"],["ς","s"],["ϊ","i"],["ΰ","y"],["ϋ","y"],["ΐ","i"],["Α","A"],["Β","B"],["Γ","G"],["Δ","D"],["Ε","E"],["Ζ","Z"],["Η","I"],["Θ","TH"],["Ι","I"],["Κ","K"],["Λ","L"],["Μ","M"],["Ν","N"],["Ξ","KS"],["Ο","O"],["Π","P"],["Ρ","R"],["Σ","S"],["Τ","T"],["Υ","Y"],["Φ","F"],["Χ","X"],["Ψ","PS"],["Ω","O"],["Ά","A"],["Έ","E"],["Ί","I"],["Ό","O"],["Ύ","Y"],["Ή","I"],["Ώ","O"],["Ϊ","I"],["Ϋ","Y"],["ā","a"],["ē","e"],["ģ","g"],["ī","i"],["ķ","k"],["ļ","l"],["ņ","n"],["ū","u"],["Ā","A"],["Ē","E"],["Ģ","G"],["Ī","I"],["Ķ","K"],["Ļ","L"],["Ņ","N"],["Ū","U"],["č","c"],["š","s"],["ž","z"],["Č","C"],["Š","S"],["Ž","Z"],["ą","a"],["č","c"],["ę","e"],["ė","e"],["į","i"],["š","s"],["ų","u"],["ū","u"],["ž","z"],["Ą","A"],["Č","C"],["Ę","E"],["Ė","E"],["Į","I"],["Š","S"],["Ų","U"],["Ū","U"],["Ќ","Kj"],["ќ","kj"],["Љ","Lj"],["љ","lj"],["Њ","Nj"],["њ","nj"],["Тс","Ts"],["тс","ts"],["ą","a"],["ć","c"],["ę","e"],["ł","l"],["ń","n"],["ś","s"],["ź","z"],["ż","z"],["Ą","A"],["Ć","C"],["Ę","E"],["Ł","L"],["Ń","N"],["Ś","S"],["Ź","Z"],["Ż","Z"],["Є","Ye"],["І","I"],["Ї","Yi"],["Ґ","G"],["є","ye"],["і","i"],["ї","yi"],["ґ","g"],["IJ","IJ"],["ij","ij"],["¢","c"],["¥","Y"],["߿","b"],["৳","t"],["૱","Bo"],["฿","B"],["₠","CE"],["₡","C"],["₢","Cr"],["₣","F"],["₥","m"],["₦","N"],["₧","Pt"],["₨","Rs"],["₩","W"],["₫","s"],["€","E"],["₭","K"],["₮","T"],["₯","Dp"],["₰","S"],["₱","P"],["₲","G"],["₳","A"],["₴","S"],["₵","C"],["₶","tt"],["₷","S"],["₸","T"],["₹","R"],["₺","L"],["₽","P"],["₿","B"],["﹩","$"],["¢","c"],["¥","Y"],["₩","W"],["𝐀","A"],["𝐁","B"],["𝐂","C"],["𝐃","D"],["𝐄","E"],["𝐅","F"],["𝐆","G"],["𝐇","H"],["𝐈","I"],["𝐉","J"],["𝐊","K"],["𝐋","L"],["𝐌","M"],["𝐍","N"],["𝐎","O"],["𝐏","P"],["𝐐","Q"],["𝐑","R"],["𝐒","S"],["𝐓","T"],["𝐔","U"],["𝐕","V"],["𝐖","W"],["𝐗","X"],["𝐘","Y"],["𝐙","Z"],["𝐚","a"],["𝐛","b"],["𝐜","c"],["𝐝","d"],["𝐞","e"],["𝐟","f"],["𝐠","g"],["𝐡","h"],["𝐢","i"],["𝐣","j"],["𝐤","k"],["𝐥","l"],["𝐦","m"],["𝐧","n"],["𝐨","o"],["𝐩","p"],["𝐪","q"],["𝐫","r"],["𝐬","s"],["𝐭","t"],["𝐮","u"],["𝐯","v"],["𝐰","w"],["𝐱","x"],["𝐲","y"],["𝐳","z"],["𝐴","A"],["𝐵","B"],["𝐶","C"],["𝐷","D"],["𝐸","E"],["𝐹","F"],["𝐺","G"],["𝐻","H"],["𝐼","I"],["𝐽","J"],["𝐾","K"],["𝐿","L"],["𝑀","M"],["𝑁","N"],["𝑂","O"],["𝑃","P"],["𝑄","Q"],["𝑅","R"],["𝑆","S"],["𝑇","T"],["𝑈","U"],["𝑉","V"],["𝑊","W"],["𝑋","X"],["𝑌","Y"],["𝑍","Z"],["𝑎","a"],["𝑏","b"],["𝑐","c"],["𝑑","d"],["𝑒","e"],["𝑓","f"],["𝑔","g"],["𝑖","i"],["𝑗","j"],["𝑘","k"],["𝑙","l"],["𝑚","m"],["𝑛","n"],["𝑜","o"],["𝑝","p"],["𝑞","q"],["𝑟","r"],["𝑠","s"],["𝑡","t"],["𝑢","u"],["𝑣","v"],["𝑤","w"],["𝑥","x"],["𝑦","y"],["𝑧","z"],["𝑨","A"],["𝑩","B"],["𝑪","C"],["𝑫","D"],["𝑬","E"],["𝑭","F"],["𝑮","G"],["𝑯","H"],["𝑰","I"],["𝑱","J"],["𝑲","K"],["𝑳","L"],["𝑴","M"],["𝑵","N"],["𝑶","O"],["𝑷","P"],["𝑸","Q"],["𝑹","R"],["𝑺","S"],["𝑻","T"],["𝑼","U"],["𝑽","V"],["𝑾","W"],["𝑿","X"],["𝒀","Y"],["𝒁","Z"],["𝒂","a"],["𝒃","b"],["𝒄","c"],["𝒅","d"],["𝒆","e"],["𝒇","f"],["𝒈","g"],["𝒉","h"],["𝒊","i"],["𝒋","j"],["𝒌","k"],["𝒍","l"],["𝒎","m"],["𝒏","n"],["𝒐","o"],["𝒑","p"],["𝒒","q"],["𝒓","r"],["𝒔","s"],["𝒕","t"],["𝒖","u"],["𝒗","v"],["𝒘","w"],["𝒙","x"],["𝒚","y"],["𝒛","z"],["𝒜","A"],["𝒞","C"],["𝒟","D"],["𝒢","g"],["𝒥","J"],["𝒦","K"],["𝒩","N"],["𝒪","O"],["𝒫","P"],["𝒬","Q"],["𝒮","S"],["𝒯","T"],["𝒰","U"],["𝒱","V"],["𝒲","W"],["𝒳","X"],["𝒴","Y"],["𝒵","Z"],["𝒶","a"],["𝒷","b"],["𝒸","c"],["𝒹","d"],["𝒻","f"],["𝒽","h"],["𝒾","i"],["𝒿","j"],["𝓀","h"],["𝓁","l"],["𝓂","m"],["𝓃","n"],["𝓅","p"],["𝓆","q"],["𝓇","r"],["𝓈","s"],["𝓉","t"],["𝓊","u"],["𝓋","v"],["𝓌","w"],["𝓍","x"],["𝓎","y"],["𝓏","z"],["𝓐","A"],["𝓑","B"],["𝓒","C"],["𝓓","D"],["𝓔","E"],["𝓕","F"],["𝓖","G"],["𝓗","H"],["𝓘","I"],["𝓙","J"],["𝓚","K"],["𝓛","L"],["𝓜","M"],["𝓝","N"],["𝓞","O"],["𝓟","P"],["𝓠","Q"],["𝓡","R"],["𝓢","S"],["𝓣","T"],["𝓤","U"],["𝓥","V"],["𝓦","W"],["𝓧","X"],["𝓨","Y"],["𝓩","Z"],["𝓪","a"],["𝓫","b"],["𝓬","c"],["𝓭","d"],["𝓮","e"],["𝓯","f"],["𝓰","g"],["𝓱","h"],["𝓲","i"],["𝓳","j"],["𝓴","k"],["𝓵","l"],["𝓶","m"],["𝓷","n"],["𝓸","o"],["𝓹","p"],["𝓺","q"],["𝓻","r"],["𝓼","s"],["𝓽","t"],["𝓾","u"],["𝓿","v"],["𝔀","w"],["𝔁","x"],["𝔂","y"],["𝔃","z"],["𝔄","A"],["𝔅","B"],["𝔇","D"],["𝔈","E"],["𝔉","F"],["𝔊","G"],["𝔍","J"],["𝔎","K"],["𝔏","L"],["𝔐","M"],["𝔑","N"],["𝔒","O"],["𝔓","P"],["𝔔","Q"],["𝔖","S"],["𝔗","T"],["𝔘","U"],["𝔙","V"],["𝔚","W"],["𝔛","X"],["𝔜","Y"],["𝔞","a"],["𝔟","b"],["𝔠","c"],["𝔡","d"],["𝔢","e"],["𝔣","f"],["𝔤","g"],["𝔥","h"],["𝔦","i"],["𝔧","j"],["𝔨","k"],["𝔩","l"],["𝔪","m"],["𝔫","n"],["𝔬","o"],["𝔭","p"],["𝔮","q"],["𝔯","r"],["𝔰","s"],["𝔱","t"],["𝔲","u"],["𝔳","v"],["𝔴","w"],["𝔵","x"],["𝔶","y"],["𝔷","z"],["𝔸","A"],["𝔹","B"],["𝔻","D"],["𝔼","E"],["𝔽","F"],["𝔾","G"],["𝕀","I"],["𝕁","J"],["𝕂","K"],["𝕃","L"],["𝕄","M"],["𝕆","N"],["𝕊","S"],["𝕋","T"],["𝕌","U"],["𝕍","V"],["𝕎","W"],["𝕏","X"],["𝕐","Y"],["𝕒","a"],["𝕓","b"],["𝕔","c"],["𝕕","d"],["𝕖","e"],["𝕗","f"],["𝕘","g"],["𝕙","h"],["𝕚","i"],["𝕛","j"],["𝕜","k"],["𝕝","l"],["𝕞","m"],["𝕟","n"],["𝕠","o"],["𝕡","p"],["𝕢","q"],["𝕣","r"],["𝕤","s"],["𝕥","t"],["𝕦","u"],["𝕧","v"],["𝕨","w"],["𝕩","x"],["𝕪","y"],["𝕫","z"],["𝕬","A"],["𝕭","B"],["𝕮","C"],["𝕯","D"],["𝕰","E"],["𝕱","F"],["𝕲","G"],["𝕳","H"],["𝕴","I"],["𝕵","J"],["𝕶","K"],["𝕷","L"],["𝕸","M"],["𝕹","N"],["𝕺","O"],["𝕻","P"],["𝕼","Q"],["𝕽","R"],["𝕾","S"],["𝕿","T"],["𝖀","U"],["𝖁","V"],["𝖂","W"],["𝖃","X"],["𝖄","Y"],["𝖅","Z"],["𝖆","a"],["𝖇","b"],["𝖈","c"],["𝖉","d"],["𝖊","e"],["𝖋","f"],["𝖌","g"],["𝖍","h"],["𝖎","i"],["𝖏","j"],["𝖐","k"],["𝖑","l"],["𝖒","m"],["𝖓","n"],["𝖔","o"],["𝖕","p"],["𝖖","q"],["𝖗","r"],["𝖘","s"],["𝖙","t"],["𝖚","u"],["𝖛","v"],["𝖜","w"],["𝖝","x"],["𝖞","y"],["𝖟","z"],["𝖠","A"],["𝖡","B"],["𝖢","C"],["𝖣","D"],["𝖤","E"],["𝖥","F"],["𝖦","G"],["𝖧","H"],["𝖨","I"],["𝖩","J"],["𝖪","K"],["𝖫","L"],["𝖬","M"],["𝖭","N"],["𝖮","O"],["𝖯","P"],["𝖰","Q"],["𝖱","R"],["𝖲","S"],["𝖳","T"],["𝖴","U"],["𝖵","V"],["𝖶","W"],["𝖷","X"],["𝖸","Y"],["𝖹","Z"],["𝖺","a"],["𝖻","b"],["𝖼","c"],["𝖽","d"],["𝖾","e"],["𝖿","f"],["𝗀","g"],["𝗁","h"],["𝗂","i"],["𝗃","j"],["𝗄","k"],["𝗅","l"],["𝗆","m"],["𝗇","n"],["𝗈","o"],["𝗉","p"],["𝗊","q"],["𝗋","r"],["𝗌","s"],["𝗍","t"],["𝗎","u"],["𝗏","v"],["𝗐","w"],["𝗑","x"],["𝗒","y"],["𝗓","z"],["𝗔","A"],["𝗕","B"],["𝗖","C"],["𝗗","D"],["𝗘","E"],["𝗙","F"],["𝗚","G"],["𝗛","H"],["𝗜","I"],["𝗝","J"],["𝗞","K"],["𝗟","L"],["𝗠","M"],["𝗡","N"],["𝗢","O"],["𝗣","P"],["𝗤","Q"],["𝗥","R"],["𝗦","S"],["𝗧","T"],["𝗨","U"],["𝗩","V"],["𝗪","W"],["𝗫","X"],["𝗬","Y"],["𝗭","Z"],["𝗮","a"],["𝗯","b"],["𝗰","c"],["𝗱","d"],["𝗲","e"],["𝗳","f"],["𝗴","g"],["𝗵","h"],["𝗶","i"],["𝗷","j"],["𝗸","k"],["𝗹","l"],["𝗺","m"],["𝗻","n"],["𝗼","o"],["𝗽","p"],["𝗾","q"],["𝗿","r"],["𝘀","s"],["𝘁","t"],["𝘂","u"],["𝘃","v"],["𝘄","w"],["𝘅","x"],["𝘆","y"],["𝘇","z"],["𝘈","A"],["𝘉","B"],["𝘊","C"],["𝘋","D"],["𝘌","E"],["𝘍","F"],["𝘎","G"],["𝘏","H"],["𝘐","I"],["𝘑","J"],["𝘒","K"],["𝘓","L"],["𝘔","M"],["𝘕","N"],["𝘖","O"],["𝘗","P"],["𝘘","Q"],["𝘙","R"],["𝘚","S"],["𝘛","T"],["𝘜","U"],["𝘝","V"],["𝘞","W"],["𝘟","X"],["𝘠","Y"],["𝘡","Z"],["𝘢","a"],["𝘣","b"],["𝘤","c"],["𝘥","d"],["𝘦","e"],["𝘧","f"],["𝘨","g"],["𝘩","h"],["𝘪","i"],["𝘫","j"],["𝘬","k"],["𝘭","l"],["𝘮","m"],["𝘯","n"],["𝘰","o"],["𝘱","p"],["𝘲","q"],["𝘳","r"],["𝘴","s"],["𝘵","t"],["𝘶","u"],["𝘷","v"],["𝘸","w"],["𝘹","x"],["𝘺","y"],["𝘻","z"],["𝘼","A"],["𝘽","B"],["𝘾","C"],["𝘿","D"],["𝙀","E"],["𝙁","F"],["𝙂","G"],["𝙃","H"],["𝙄","I"],["𝙅","J"],["𝙆","K"],["𝙇","L"],["𝙈","M"],["𝙉","N"],["𝙊","O"],["𝙋","P"],["𝙌","Q"],["𝙍","R"],["𝙎","S"],["𝙏","T"],["𝙐","U"],["𝙑","V"],["𝙒","W"],["𝙓","X"],["𝙔","Y"],["𝙕","Z"],["𝙖","a"],["𝙗","b"],["𝙘","c"],["𝙙","d"],["𝙚","e"],["𝙛","f"],["𝙜","g"],["𝙝","h"],["𝙞","i"],["𝙟","j"],["𝙠","k"],["𝙡","l"],["𝙢","m"],["𝙣","n"],["𝙤","o"],["𝙥","p"],["𝙦","q"],["𝙧","r"],["𝙨","s"],["𝙩","t"],["𝙪","u"],["𝙫","v"],["𝙬","w"],["𝙭","x"],["𝙮","y"],["𝙯","z"],["𝙰","A"],["𝙱","B"],["𝙲","C"],["𝙳","D"],["𝙴","E"],["𝙵","F"],["𝙶","G"],["𝙷","H"],["𝙸","I"],["𝙹","J"],["𝙺","K"],["𝙻","L"],["𝙼","M"],["𝙽","N"],["𝙾","O"],["𝙿","P"],["𝚀","Q"],["𝚁","R"],["𝚂","S"],["𝚃","T"],["𝚄","U"],["𝚅","V"],["𝚆","W"],["𝚇","X"],["𝚈","Y"],["𝚉","Z"],["𝚊","a"],["𝚋","b"],["𝚌","c"],["𝚍","d"],["𝚎","e"],["𝚏","f"],["𝚐","g"],["𝚑","h"],["𝚒","i"],["𝚓","j"],["𝚔","k"],["𝚕","l"],["𝚖","m"],["𝚗","n"],["𝚘","o"],["𝚙","p"],["𝚚","q"],["𝚛","r"],["𝚜","s"],["𝚝","t"],["𝚞","u"],["𝚟","v"],["𝚠","w"],["𝚡","x"],["𝚢","y"],["𝚣","z"],["𝚤","l"],["𝚥","j"],["𝛢","A"],["𝛣","B"],["𝛤","G"],["𝛥","D"],["𝛦","E"],["𝛧","Z"],["𝛨","I"],["𝛩","TH"],["𝛪","I"],["𝛫","K"],["𝛬","L"],["𝛭","M"],["𝛮","N"],["𝛯","KS"],["𝛰","O"],["𝛱","P"],["𝛲","R"],["𝛳","TH"],["𝛴","S"],["𝛵","T"],["𝛶","Y"],["𝛷","F"],["𝛸","x"],["𝛹","PS"],["𝛺","O"],["𝛻","D"],["𝛼","a"],["𝛽","b"],["𝛾","g"],["𝛿","d"],["𝜀","e"],["𝜁","z"],["𝜂","i"],["𝜃","th"],["𝜄","i"],["𝜅","k"],["𝜆","l"],["𝜇","m"],["𝜈","n"],["𝜉","ks"],["𝜊","o"],["𝜋","p"],["𝜌","r"],["𝜍","s"],["𝜎","s"],["𝜏","t"],["𝜐","y"],["𝜑","f"],["𝜒","x"],["𝜓","ps"],["𝜔","o"],["𝜕","d"],["𝜖","E"],["𝜗","TH"],["𝜘","K"],["𝜙","f"],["𝜚","r"],["𝜛","p"],["𝜜","A"],["𝜝","V"],["𝜞","G"],["𝜟","D"],["𝜠","E"],["𝜡","Z"],["𝜢","I"],["𝜣","TH"],["𝜤","I"],["𝜥","K"],["𝜦","L"],["𝜧","M"],["𝜨","N"],["𝜩","KS"],["𝜪","O"],["𝜫","P"],["𝜬","S"],["𝜭","TH"],["𝜮","S"],["𝜯","T"],["𝜰","Y"],["𝜱","F"],["𝜲","X"],["𝜳","PS"],["𝜴","O"],["𝜵","D"],["𝜶","a"],["𝜷","v"],["𝜸","g"],["𝜹","d"],["𝜺","e"],["𝜻","z"],["𝜼","i"],["𝜽","th"],["𝜾","i"],["𝜿","k"],["𝝀","l"],["𝝁","m"],["𝝂","n"],["𝝃","ks"],["𝝄","o"],["𝝅","p"],["𝝆","r"],["𝝇","s"],["𝝈","s"],["𝝉","t"],["𝝊","y"],["𝝋","f"],["𝝌","x"],["𝝍","ps"],["𝝎","o"],["𝝏","a"],["𝝐","e"],["𝝑","i"],["𝝒","k"],["𝝓","f"],["𝝔","r"],["𝝕","p"],["𝝖","A"],["𝝗","B"],["𝝘","G"],["𝝙","D"],["𝝚","E"],["𝝛","Z"],["𝝜","I"],["𝝝","TH"],["𝝞","I"],["𝝟","K"],["𝝠","L"],["𝝡","M"],["𝝢","N"],["𝝣","KS"],["𝝤","O"],["𝝥","P"],["𝝦","R"],["𝝧","TH"],["𝝨","S"],["𝝩","T"],["𝝪","Y"],["𝝫","F"],["𝝬","X"],["𝝭","PS"],["𝝮","O"],["𝝯","D"],["𝝰","a"],["𝝱","v"],["𝝲","g"],["𝝳","d"],["𝝴","e"],["𝝵","z"],["𝝶","i"],["𝝷","th"],["𝝸","i"],["𝝹","k"],["𝝺","l"],["𝝻","m"],["𝝼","n"],["𝝽","ks"],["𝝾","o"],["𝝿","p"],["𝞀","r"],["𝞁","s"],["𝞂","s"],["𝞃","t"],["𝞄","y"],["𝞅","f"],["𝞆","x"],["𝞇","ps"],["𝞈","o"],["𝞉","a"],["𝞊","e"],["𝞋","i"],["𝞌","k"],["𝞍","f"],["𝞎","r"],["𝞏","p"],["𝞐","A"],["𝞑","V"],["𝞒","G"],["𝞓","D"],["𝞔","E"],["𝞕","Z"],["𝞖","I"],["𝞗","TH"],["𝞘","I"],["𝞙","K"],["𝞚","L"],["𝞛","M"],["𝞜","N"],["𝞝","KS"],["𝞞","O"],["𝞟","P"],["𝞠","S"],["𝞡","TH"],["𝞢","S"],["𝞣","T"],["𝞤","Y"],["𝞥","F"],["𝞦","X"],["𝞧","PS"],["𝞨","O"],["𝞩","D"],["𝞪","av"],["𝞫","g"],["𝞬","d"],["𝞭","e"],["𝞮","z"],["𝞯","i"],["𝞰","i"],["𝞱","th"],["𝞲","i"],["𝞳","k"],["𝞴","l"],["𝞵","m"],["𝞶","n"],["𝞷","ks"],["𝞸","o"],["𝞹","p"],["𝞺","r"],["𝞻","s"],["𝞼","s"],["𝞽","t"],["𝞾","y"],["𝞿","f"],["𝟀","x"],["𝟁","ps"],["𝟂","o"],["𝟃","a"],["𝟄","e"],["𝟅","i"],["𝟆","k"],["𝟇","f"],["𝟈","r"],["𝟉","p"],["𝟊","F"],["𝟋","f"],["⒜","(a)"],["⒝","(b)"],["⒞","(c)"],["⒟","(d)"],["⒠","(e)"],["⒡","(f)"],["⒢","(g)"],["⒣","(h)"],["⒤","(i)"],["⒥","(j)"],["⒦","(k)"],["⒧","(l)"],["⒨","(m)"],["⒩","(n)"],["⒪","(o)"],["⒫","(p)"],["⒬","(q)"],["⒭","(r)"],["⒮","(s)"],["⒯","(t)"],["⒰","(u)"],["⒱","(v)"],["⒲","(w)"],["⒳","(x)"],["⒴","(y)"],["⒵","(z)"],["Ⓐ","(A)"],["Ⓑ","(B)"],["Ⓒ","(C)"],["Ⓓ","(D)"],["Ⓔ","(E)"],["Ⓕ","(F)"],["Ⓖ","(G)"],["Ⓗ","(H)"],["Ⓘ","(I)"],["Ⓙ","(J)"],["Ⓚ","(K)"],["Ⓛ","(L)"],["Ⓝ","(N)"],["Ⓞ","(O)"],["Ⓟ","(P)"],["Ⓠ","(Q)"],["Ⓡ","(R)"],["Ⓢ","(S)"],["Ⓣ","(T)"],["Ⓤ","(U)"],["Ⓥ","(V)"],["Ⓦ","(W)"],["Ⓧ","(X)"],["Ⓨ","(Y)"],["Ⓩ","(Z)"],["ⓐ","(a)"],["ⓑ","(b)"],["ⓒ","(b)"],["ⓓ","(c)"],["ⓔ","(e)"],["ⓕ","(f)"],["ⓖ","(g)"],["ⓗ","(h)"],["ⓘ","(i)"],["ⓙ","(j)"],["ⓚ","(k)"],["ⓛ","(l)"],["ⓜ","(m)"],["ⓝ","(n)"],["ⓞ","(o)"],["ⓟ","(p)"],["ⓠ","(q)"],["ⓡ","(r)"],["ⓢ","(s)"],["ⓣ","(t)"],["ⓤ","(u)"],["ⓥ","(v)"],["ⓦ","(w)"],["ⓧ","(x)"],["ⓨ","(y)"],["ⓩ","(z)"],["Ċ","C"],["ċ","c"],["Ġ","G"],["ġ","g"],["Ħ","H"],["ħ","h"],["Ż","Z"],["ż","z"],["𝟎","0"],["𝟏","1"],["𝟐","2"],["𝟑","3"],["𝟒","4"],["𝟓","5"],["𝟔","6"],["𝟕","7"],["𝟖","8"],["𝟗","9"],["𝟘","0"],["𝟙","1"],["𝟚","2"],["𝟛","3"],["𝟜","4"],["𝟝","5"],["𝟞","6"],["𝟟","7"],["𝟠","8"],["𝟡","9"],["𝟢","0"],["𝟣","1"],["𝟤","2"],["𝟥","3"],["𝟦","4"],["𝟧","5"],["𝟨","6"],["𝟩","7"],["𝟪","8"],["𝟫","9"],["𝟬","0"],["𝟭","1"],["𝟮","2"],["𝟯","3"],["𝟰","4"],["𝟱","5"],["𝟲","6"],["𝟳","7"],["𝟴","8"],["𝟵","9"],["𝟶","0"],["𝟷","1"],["𝟸","2"],["𝟹","3"],["𝟺","4"],["𝟻","5"],["𝟼","6"],["𝟽","7"],["𝟾","8"],["𝟿","9"],["①","1"],["②","2"],["③","3"],["④","4"],["⑤","5"],["⑥","6"],["⑦","7"],["⑧","8"],["⑨","9"],["⑩","10"],["⑪","11"],["⑫","12"],["⑬","13"],["⑭","14"],["⑮","15"],["⑯","16"],["⑰","17"],["⑱","18"],["⑲","19"],["⑳","20"],["⑴","1"],["⑵","2"],["⑶","3"],["⑷","4"],["⑸","5"],["⑹","6"],["⑺","7"],["⑻","8"],["⑼","9"],["⑽","10"],["⑾","11"],["⑿","12"],["⒀","13"],["⒁","14"],["⒂","15"],["⒃","16"],["⒄","17"],["⒅","18"],["⒆","19"],["⒇","20"],["⒈","1."],["⒉","2."],["⒊","3."],["⒋","4."],["⒌","5."],["⒍","6."],["⒎","7."],["⒏","8."],["⒐","9."],["⒑","10."],["⒒","11."],["⒓","12."],["⒔","13."],["⒕","14."],["⒖","15."],["⒗","16."],["⒘","17."],["⒙","18."],["⒚","19."],["⒛","20."],["⓪","0"],["⓫","11"],["⓬","12"],["⓭","13"],["⓮","14"],["⓯","15"],["⓰","16"],["⓱","17"],["⓲","18"],["⓳","19"],["⓴","20"],["⓵","1"],["⓶","2"],["⓷","3"],["⓸","4"],["⓹","5"],["⓺","6"],["⓻","7"],["⓼","8"],["⓽","9"],["⓾","10"],["⓿","0"],["🙰","&"],["🙱","&"],["🙲","&"],["🙳","&"],["🙴","&"],["🙵","&"],["🙶",'"'],["🙷",'"'],["🙸",'"'],["‽","?!"],["🙹","?!"],["🙺","?!"],["🙻","?!"],["🙼","/"],["🙽","\\"],["🜇","AR"],["🜈","V"],["🜉","V"],["🜆","VR"],["🜅","VF"],["🜩","2"],["🜪","5"],["🝡","f"],["🝢","W"],["🝣","U"],["🝧","V"],["🝨","T"],["🝪","V"],["🝫","MB"],["🝬","VB"],["🝲","3B"],["🝳","3B"],["💯","100"],["🔙","BACK"],["🔚","END"],["🔛","ON!"],["🔜","SOON"],["🔝","TOP"],["🔞","18"],["🔤","abc"],["🔠","ABCD"],["🔡","abcd"],["🔢","1234"],["🔣","T&@%"],["#️⃣","#"],["*️⃣","*"],["0️⃣","0"],["1️⃣","1"],["2️⃣","2"],["3️⃣","3"],["4️⃣","4"],["5️⃣","5"],["6️⃣","6"],["7️⃣","7"],["8️⃣","8"],["9️⃣","9"],["🔟","10"],["🅰️","A"],["🅱️","B"],["🆎","AB"],["🆑","CL"],["🅾️","O"],["🅿","P"],["🆘","SOS"],["🅲","C"],["🅳","D"],["🅴","E"],["🅵","F"],["🅶","G"],["🅷","H"],["🅸","I"],["🅹","J"],["🅺","K"],["🅻","L"],["🅼","M"],["🅽","N"],["🆀","Q"],["🆁","R"],["🆂","S"],["🆃","T"],["🆄","U"],["🆅","V"],["🆆","W"],["🆇","X"],["🆈","Y"],["🆉","Z"]],ICe=(e,t)=>{for(const[n,o]of t)e=e.replace(new RegExp(mv(n),"g"),o);return e};function ACe(e,t){if(typeof e!="string")throw new TypeError(`Expected a string, got \`${typeof e}\``);t={customReplacements:[],...t};const n=new Map([...OCe,...t.customReplacements]);return e=e.normalize(),e=ICe(e,n),e=e.normalize("NFD").replace(/\p{Diacritic}/gu,"").normalize(),e}const NCe=[["&"," and "],["🦄"," unicorn "],["♥"," love "]],PCe=e=>e.replace(/([A-Z]{2,})(\d+)/g,"$1 $2").replace(/([a-z\d]+)([A-Z]{2,})/g,"$1 $2").replace(/([a-z\d])([A-Z])/g,"$1 $2").replace(/([A-Z]+)([A-Z][a-rt-z\d]+)/g,"$1 $2"),LCe=(e,t)=>{const n=mv(t);return e.replace(new RegExp(`${n}{2,}`,"g"),t).replace(new RegExp(`^${n}|${n}$`,"g"),"")},RCe=e=>{let t="a-z\\d";if(t+=e.lowercase?"":"A-Z",e.preserveCharacters.length>0)for(const n of e.preserveCharacters){if(n===e.separator)throw new Error(`The separator character \`${e.separator}\` cannot be included in preserved characters: ${e.preserveCharacters}`);t+=mv(n)}return new RegExp(`[^${t}]+`,"g")};function DCe(e,t){if(typeof e!="string")throw new TypeError(`Expected a string, got \`${typeof e}\``);t={separator:"-",lowercase:!0,decamelize:!0,customReplacements:[],preserveLeadingUnderscore:!1,preserveTrailingDash:!1,preserveCharacters:[],...t};const n=t.preserveLeadingUnderscore&&e.startsWith("_"),o=t.preserveTrailingDash&&e.endsWith("-"),r=new Map([...NCe,...t.customReplacements]);e=ACe(e,{customReplacements:r}),t.decamelize&&(e=PCe(e));const s=RCe(t);return t.lowercase&&(e=e.toLowerCase()),e=e.replace(/([a-zA-Z\d]+)'([ts])(\s|$)/g,"$1$2$3"),e=e.replace(s,t.separator),e=e.replace(/\\/g,""),t.separator&&(e=LCe(e,t.separator)),n&&(e=`_${e}`),o&&(e=`${e}-`),e}function FCe(e,t){return function(n,o){let{$from:r,$to:s,node:i}=n.selection;if(i&&i.isBlock||r.depth<2||!r.sameParent(s))return!1;let l=r.node(-1);if(l.type!=e)return!1;if(r.parent.content.size==0&&r.node(-1).childCount==r.indexAfter(-1)){if(r.depth==3||r.node(-3).type!=e||r.index(-2)!=r.node(-2).childCount-1)return!1;if(o){let d=Ue.empty,f=r.index(-1)?1:r.index(-2)?2:3;for(let v=r.depth-f;v>=r.depth-3;v--)d=Ue.from(r.node(v).copy(d));let p=r.indexAfter(-1)<r.node(-2).childCount?1:r.indexAfter(-2)<r.node(-3).childCount?2:3;d=d.append(Ue.from(e.createAndFill()));let h=r.before(r.depth-(f-1)),m=n.tr.replace(h,r.after(-p),new Ye(d,4-f,0)),y=-1;m.doc.nodesBetween(h,m.doc.content.size,(v,w)=>{if(y>-1)return!1;v.isTextblock&&v.content.size==0&&(y=w+1)}),y>-1&&m.setSelection(bt.near(m.doc.resolve(y))),o(m.scrollIntoView())}return!0}let a=s.pos==r.end()?l.contentMatchAt(0).defaultType:null,u=n.tr.delete(r.pos,s.pos),c=a?[t?{type:e,attrs:t}:null,{type:a}]:void 0;return tp(u.doc,r.pos,2,c)?(o&&o(u.split(r.pos,2,c).scrollIntoView()),!0):!1}}function $N(e){return function(t,n){let{$from:o,$to:r}=t.selection,s=o.blockRange(r,i=>i.childCount>0&&i.firstChild.type==e);return s?n?o.node(s.depth-1).type==e?VCe(t,n,e,s):BCe(t,n,s):!0:!1}}function VCe(e,t,n,o){let r=e.tr,s=o.end,i=o.$to.end(o.depth);s<i&&(r.step(new vo(s-1,i,s,i,new Ye(Ue.from(n.create(null,o.parent.copy())),1,0),1,!0)),o=new pI(r.doc.resolve(o.$from.pos),r.doc.resolve(i),o.depth));const l=rv(o);if(l==null)return!1;r.lift(o,l);let a=r.mapping.map(s,-1)-1;return sv(r.doc,a)&&r.join(a),t(r.scrollIntoView()),!0}function BCe(e,t,n){let o=e.tr,r=n.parent;for(let p=n.end,h=n.endIndex-1,m=n.startIndex;h>m;h--)p-=r.child(h).nodeSize,o.delete(p-1,p+1);let s=o.doc.resolve(n.start),i=s.nodeAfter;if(o.mapping.map(n.end)!=n.start+s.nodeAfter.nodeSize)return!1;let l=n.startIndex==0,a=n.endIndex==r.childCount,u=s.node(-1),c=s.index(-1);if(!u.canReplace(c+(l?0:1),c+1,i.content.append(a?Ue.empty:Ue.from(r))))return!1;let d=s.pos,f=d+i.nodeSize;return o.step(new vo(d-(l?1:0),f+(a?1:0),d+1,f-1,new Ye((l?Ue.empty:Ue.from(r.copy(Ue.empty))).append(a?Ue.empty:Ue.from(r.copy(Ue.empty))),l?0:1,a?0:1),l?0:1)),t(o.scrollIntoView()),!0}function zCe(e){return function(t,n){let{$from:o,$to:r}=t.selection,s=o.blockRange(r,u=>u.childCount>0&&u.firstChild.type==e);if(!s)return!1;let i=s.startIndex;if(i==0)return!1;let l=s.parent,a=l.child(i-1);if(a.type!=e)return!1;if(n){let u=a.lastChild&&a.lastChild.type==l.type,c=Ue.from(u?e.create():null),d=new Ye(Ue.from(e.create(null,Ue.from(l.type.create(null,c)))),u?3:1,0),f=s.start,p=s.end;n(t.tr.step(new vo(f-(u?3:1),p,f,p,d,1,!0)).scrollIntoView())}return!0}}function jCe(e){const t=new Map;if(!e||!e.type)throw new Error("mdast-util-definitions expected node");return Od(e,"definition",function(o){const r=T9(o.identifier);r&&!t.get(r)&&t.set(r,o)}),n;function n(o){const r=T9(o);return t.get(r)}}function T9(e){return String(e||"").toUpperCase()}function HCe(){return function(e){const t=jCe(e);Od(e,function(n,o,r){if(n.type==="definition"&&r!==void 0&&typeof o=="number")return r.children.splice(o,1),[jb,o];if(n.type==="imageReference"||n.type==="linkReference"){const s=t(n.identifier);if(s&&r&&typeof o=="number")return r.children[o]=n.type==="imageReference"?{type:"image",url:s.url,title:s.title,alt:n.alt}:{type:"link",url:s.url,title:s.title,children:n.children},[jb,o]}})}}function EN(e,t){var n;if(!(t.childCount>=1&&((n=t.lastChild)==null?void 0:n.type.name)==="hardbreak")){e.next(t.content);return}const o=[];t.content.forEach((r,s,i)=>{i!==t.childCount-1&&o.push(r)}),e.next(Ue.fromArray(o))}function ke(e,t){return Object.assign(e,{meta:{package:"@milkdown/preset-commonmark",...t}}),e}const SC=Ah("emphasis");ke(SC,{displayName:"Attr<emphasis>",group:"Emphasis"});const xu=Ih("emphasis",e=>({attrs:{marker:{default:e.get(rp).emphasis||"*"}},parseDOM:[{tag:"i"},{tag:"em"},{style:"font-style",getAttrs:t=>t==="italic"}],toDOM:t=>["em",e.get(SC.key)(t)],parseMarkdown:{match:t=>t.type==="emphasis",runner:(t,n,o)=>{t.openMark(o,{marker:n.marker}),t.next(n.children),t.closeMark(o)}},toMarkdown:{match:t=>t.type.name==="emphasis",runner:(t,n)=>{t.withMark(n,"emphasis",void 0,{marker:n.attrs.marker})}}}));ke(xu.mark,{displayName:"MarkSchema<emphasis>",group:"Emphasis"});ke(xu.ctx,{displayName:"MarkSchemaCtx<emphasis>",group:"Emphasis"});const gv=Tt("ToggleEmphasis",e=>()=>cv(xu.type(e)));ke(gv,{displayName:"Command<toggleEmphasisCommand>",group:"Emphasis"});const xN=er(e=>xh(/(?:^|[^*])\*([^*]+)\*$/,xu.type(e),{getAttr:()=>({marker:"*"}),updateCaptured:({fullMatch:t,start:n})=>t.startsWith("*")?{}:{fullMatch:t.slice(1),start:n+1}}));ke(xN,{displayName:"InputRule<emphasis>|Star",group:"Emphasis"});const MN=er(e=>xh(/(?:^|[^_])_([^_]+)_$/,xu.type(e),{getAttr:()=>({marker:"_"}),updateCaptured:({fullMatch:t,start:n})=>t.startsWith("_")?{}:{fullMatch:t.slice(1),start:n+1}}));ke(MN,{displayName:"InputRule<emphasis>|Underscore",group:"Emphasis"});const $C=tr("emphasisKeymap",{ToggleEmphasis:{shortcuts:"Mod-i",command:e=>{const t=e.get(Dt);return()=>t.call(gv.key)}}});ke($C.ctx,{displayName:"KeymapCtx<emphasis>",group:"Emphasis"});ke($C.shortcuts,{displayName:"Keymap<emphasis>",group:"Emphasis"});const EC=Ah("strong");ke(EC,{displayName:"Attr<strong>",group:"Strong"});const Ad=Ih("strong",e=>({attrs:{marker:{default:e.get(rp).strong||"*"}},parseDOM:[{tag:"b"},{tag:"strong"},{style:"font-style",getAttrs:t=>t==="bold"}],toDOM:t=>["strong",e.get(EC.key)(t)],parseMarkdown:{match:t=>t.type==="strong",runner:(t,n,o)=>{t.openMark(o,{marker:n.marker}),t.next(n.children),t.closeMark(o)}},toMarkdown:{match:t=>t.type.name==="strong",runner:(t,n)=>{t.withMark(n,"strong",void 0,{marker:n.attrs.marker})}}}));ke(Ad.mark,{displayName:"MarkSchema<strong>",group:"Strong"});ke(Ad.ctx,{displayName:"MarkSchemaCtx<strong>",group:"Strong"});const vv=Tt("ToggleStrong",e=>()=>cv(Ad.type(e)));ke(vv,{displayName:"Command<toggleStrongCommand>",group:"Strong"});const TN=er(e=>xh(/(?:\*\*|__)([^*_]+)(?:\*\*|__)$/,Ad.type(e),{getAttr:t=>({marker:t[0].startsWith("*")?"*":"_"})}));ke(TN,{displayName:"InputRule<strong>",group:"Strong"});const xC=tr("strongKeymap",{ToggleBold:{shortcuts:["Mod-b"],command:e=>{const t=e.get(Dt);return()=>t.call(vv.key)}}});ke(xC.ctx,{displayName:"KeymapCtx<strong>",group:"Strong"});ke(xC.shortcuts,{displayName:"Keymap<strong>",group:"Strong"});const MC=Ah("inlineCode");ke(MC,{displayName:"Attr<inlineCode>",group:"InlineCode"});const $i=Ih("inlineCode",e=>({priority:100,code:!0,inclusive:!1,parseDOM:[{tag:"code"}],toDOM:t=>["code",e.get(MC.key)(t)],parseMarkdown:{match:t=>t.type==="inlineCode",runner:(t,n,o)=>{t.openMark(o),t.addText(n.value),t.closeMark(o)}},toMarkdown:{match:t=>t.type.name==="inlineCode",runner:(t,n,o)=>{t.withMark(n,"inlineCode",o.text||"")}}}));ke($i.mark,{displayName:"MarkSchema<inlineCode>",group:"InlineCode"});ke($i.ctx,{displayName:"MarkSchemaCtx<inlineCode>",group:"InlineCode"});const yv=Tt("ToggleInlineCode",e=>()=>(t,n)=>{const{selection:o,tr:r}=t;if(o.empty)return!1;const{from:s,to:i}=o;return t.doc.rangeHasMark(s,i,$i.type(e))?(n==null||n(r.removeMark(s,i,$i.type(e))),!0):(Object.keys(t.schema.marks).filter(l=>l!==$i.type.name).map(l=>t.schema.marks[l]).forEach(l=>{r.removeMark(s,i,l)}),n==null||n(r.addMark(s,i,$i.type(e).create())),!0)});ke(yv,{displayName:"Command<toggleInlineCodeCommand>",group:"InlineCode"});const ON=er(e=>xh(/(?:\`)([^\`]+)(?:\`)$/,$i.type(e)));ke(ON,{displayName:"InputRule<inlineCodeInputRule>",group:"InlineCode"});const TC=tr("inlineCodeKeymap",{ToggleInlineCode:{shortcuts:"Mod-e",command:e=>{const t=e.get(Dt);return()=>t.call(yv.key)}}});ke(TC.ctx,{displayName:"KeymapCtx<inlineCode>",group:"InlineCode"});ke(TC.shortcuts,{displayName:"Keymap<inlineCode>",group:"InlineCode"});const OC=Ah("link");ke(OC,{displayName:"Attr<link>",group:"Link"});const fs=Ih("link",e=>({attrs:{href:{},title:{default:null}},parseDOM:[{tag:"a[href]",getAttrs:t=>{if(!(t instanceof HTMLElement))throw ii(t);return{href:t.getAttribute("href"),title:t.getAttribute("title")}}}],toDOM:t=>["a",{...e.get(OC.key)(t),...t.attrs}],parseMarkdown:{match:t=>t.type==="link",runner:(t,n,o)=>{const r=n.url,s=n.title;t.openMark(o,{href:r,title:s}),t.next(n.children),t.closeMark(o)}},toMarkdown:{match:t=>t.type.name==="link",runner:(t,n)=>{t.withMark(n,"link",void 0,{title:n.attrs.title,url:n.attrs.href})}}}));ke(fs.mark,{displayName:"MarkSchema<link>",group:"Link"});const IN=Tt("ToggleLink",e=>(t={})=>cv(fs.type(e),t));ke(IN,{displayName:"Command<toggleLinkCommand>",group:"Link"});const AN=Tt("UpdateLink",e=>(t={})=>(n,o)=>{if(!o)return!1;let r,s=-1;const{selection:i}=n,{from:l,to:a}=i;if(n.doc.nodesBetween(l,l===a?a+1:a,(h,m)=>{if(fs.type(e).isInSet(h.marks))return r=h,s=m,!1}),!r)return!1;const u=r.marks.find(({type:h})=>h===fs.type(e));if(!u)return!1;const c=s,d=s+r.nodeSize,{tr:f}=n,p=fs.type(e).create({...u.attrs,...t});return p?(o(f.removeMark(c,d,u).addMark(c,d,p).setSelection(new ht(f.selection.$anchor)).scrollIntoView()),!0):!1});ke(AN,{displayName:"Command<updateLinkCommand>",group:"Link"});const NN=kC("doc",()=>({content:"block+",parseMarkdown:{match:({type:e})=>e==="root",runner:(e,t,n)=>{e.injectRoot(t,n)}},toMarkdown:{match:e=>e.type.name==="doc",runner:(e,t)=>{e.openNode("root"),e.next(t.content)}}}));ke(NN,{displayName:"NodeSchema<doc>",group:"Doc"});const IC=$s("paragraph");ke(IC,{displayName:"Attr<paragraph>",group:"Paragraph"});const ji=Yn("paragraph",e=>({content:"inline*",group:"block",parseDOM:[{tag:"p"}],toDOM:t=>["p",e.get(IC.key)(t),0],parseMarkdown:{match:t=>t.type==="paragraph",runner:(t,n,o)=>{t.openNode(o),n.children?t.next(n.children):t.addText(n.value||""),t.closeNode()}},toMarkdown:{match:t=>t.type.name==="paragraph",runner:(t,n)=>{t.openNode("paragraph"),EN(t,n),t.closeNode()}}}));ke(ji.node,{displayName:"NodeSchema<paragraph>",group:"Paragraph"});ke(ji.ctx,{displayName:"NodeSchemaCtx<paragraph>",group:"Paragraph"});const AC=Tt("TurnIntoText",e=>()=>jp(ji.type(e)));ke(AC,{displayName:"Command<turnIntoTextCommand>",group:"Paragraph"});const NC=tr("paragraphKeymap",{TurnIntoText:{shortcuts:"Mod-Alt-0",command:e=>{const t=e.get(Dt);return()=>t.call(AC.key)}}});ke(NC.ctx,{displayName:"KeymapCtx<paragraph>",group:"Paragraph"});ke(NC.shortcuts,{displayName:"Keymap<paragraph>",group:"Paragraph"});const UCe=Array(6).fill(0).map((e,t)=>t+1);function WCe(e){return DCe(e.textContent)}const _v=In(WCe,"headingIdGenerator");ke(_v,{displayName:"Ctx<HeadingIdGenerator>",group:"Heading"});const PC=$s("heading");ke(PC,{displayName:"Attr<heading>",group:"Heading"});const Ws=Yn("heading",e=>{const t=e.get(_v.key);return{content:"inline*",group:"block",defining:!0,attrs:{id:{default:""},level:{default:1}},parseDOM:UCe.map(n=>({tag:`h${n}`,getAttrs:o=>{if(!(o instanceof HTMLElement))throw ii(o);return{level:n,id:o.id}}})),toDOM:n=>[`h${n.attrs.level}`,{...e.get(PC.key)(n),id:n.attrs.id||t(n)},0],parseMarkdown:{match:({type:n})=>n==="heading",runner:(n,o,r)=>{const s=o.depth;n.openNode(r,{level:s}),n.next(o.children),n.closeNode()}},toMarkdown:{match:n=>n.type.name==="heading",runner:(n,o)=>{n.openNode("heading",void 0,{depth:o.attrs.level}),EN(n,o),n.closeNode()}}}});ke(Ws.node,{displayName:"NodeSchema<heading>",group:"Heading"});ke(Ws.ctx,{displayName:"NodeSchemaCtx<heading>",group:"Heading"});const PN=er(e=>yA(/^(?<hashes>#+)\s$/,Ws.type(e),t=>{var n,o;const r=((o=(n=t.groups)==null?void 0:n.hashes)==null?void 0:o.length)||0,s=e.get(bn),{$from:i}=s.state.selection,l=i.node();if(l.type.name==="heading"){let a=Number(l.attrs.level)+Number(r);return a>6&&(a=6),{level:a}}return{level:r}}));ke(PN,{displayName:"InputRule<wrapInHeadingInputRule>",group:"Heading"});const bl=Tt("WrapInHeading",e=>t=>(t??(t=1),t<1?jp(ji.type(e)):jp(Ws.type(e),{level:t})));ke(bl,{displayName:"Command<wrapInHeadingCommand>",group:"Heading"});const LC=Tt("DowngradeHeading",e=>()=>(t,n,o)=>{const{$from:r}=t.selection,s=r.node();if(s.type!==Ws.type(e)||!t.selection.empty||r.parentOffset!==0)return!1;const i=s.attrs.level-1;return i?(n==null||n(t.tr.setNodeMarkup(t.selection.$from.before(),void 0,{...s.attrs,level:i})),!0):jp(ji.type(e))(t,n,o)});ke(LC,{displayName:"Command<downgradeHeadingCommand>",group:"Heading"});const RC=tr("headingKeymap",{TurnIntoH1:{shortcuts:"Mod-Alt-1",command:e=>{const t=e.get(Dt);return()=>t.call(bl.key,1)}},TurnIntoH2:{shortcuts:"Mod-Alt-2",command:e=>{const t=e.get(Dt);return()=>t.call(bl.key,2)}},TurnIntoH3:{shortcuts:"Mod-Alt-3",command:e=>{const t=e.get(Dt);return()=>t.call(bl.key,3)}},TurnIntoH4:{shortcuts:"Mod-Alt-4",command:e=>{const t=e.get(Dt);return()=>t.call(bl.key,4)}},TurnIntoH5:{shortcuts:"Mod-Alt-5",command:e=>{const t=e.get(Dt);return()=>t.call(bl.key,5)}},TurnIntoH6:{shortcuts:"Mod-Alt-6",command:e=>{const t=e.get(Dt);return()=>t.call(bl.key,6)}},DowngradeHeading:{shortcuts:["Delete","Backspace"],command:e=>{const t=e.get(Dt);return()=>t.call(LC.key)}}});ke(RC.ctx,{displayName:"KeymapCtx<heading>",group:"Heading"});ke(RC.shortcuts,{displayName:"Keymap<heading>",group:"Heading"});const DC=$s("blockquote");ke(DC,{displayName:"Attr<blockquote>",group:"Blockquote"});const Nd=Yn("blockquote",e=>({content:"block+",group:"block",defining:!0,parseDOM:[{tag:"blockquote"}],toDOM:t=>["blockquote",e.get(DC.key)(t),0],parseMarkdown:{match:({type:t})=>t==="blockquote",runner:(t,n,o)=>{t.openNode(o).next(n.children).closeNode()}},toMarkdown:{match:t=>t.type.name==="blockquote",runner:(t,n)=>{t.openNode("blockquote").next(n.content).closeNode()}}}));ke(Nd.node,{displayName:"NodeSchema<blockquote>",group:"Blockquote"});ke(Nd.ctx,{displayName:"NodeSchemaCtx<blockquote>",group:"Blockquote"});const LN=er(e=>uC(/^\s*>\s$/,Nd.type(e)));ke(LN,{displayName:"InputRule<wrapInBlockquoteInputRule>",group:"Blockquote"});const FC=Tt("WrapInBlockquote",e=>()=>hC(Nd.type(e)));ke(FC,{displayName:"Command<wrapInBlockquoteCommand>",group:"Blockquote"});const VC=tr("blockquoteKeymap",{WrapInBlockquote:{shortcuts:"Mod-Shift-b",command:e=>{const t=e.get(Dt);return()=>t.call(FC.key)}}});ke(VC.ctx,{displayName:"KeymapCtx<blockquote>",group:"Blockquote"});ke(VC.shortcuts,{displayName:"Keymap<blockquote>",group:"Blockquote"});const BC=$s("codeBlock",()=>({pre:{},code:{}}));ke(BC,{displayName:"Attr<codeBlock>",group:"CodeBlock"});const Pd=Yn("code_block",e=>({content:"text*",group:"block",marks:"",defining:!0,code:!0,attrs:{language:{default:""}},parseDOM:[{tag:"pre",preserveWhitespace:"full",getAttrs:t=>{if(!(t instanceof HTMLElement))throw ii(t);return{language:t.dataset.language}}}],toDOM:t=>{const n=e.get(BC.key)(t);return["pre",{...n.pre,"data-language":t.attrs.language},["code",n.code,0]]},parseMarkdown:{match:({type:t})=>t==="code",runner:(t,n,o)=>{const r=n.lang,s=n.value;t.openNode(o,{language:r}),s&&t.addText(s),t.closeNode()}},toMarkdown:{match:t=>t.type.name==="code_block",runner:(t,n)=>{var o;t.addNode("code",void 0,((o=n.content.firstChild)==null?void 0:o.text)||"",{lang:n.attrs.language})}}}));ke(Pd.node,{displayName:"NodeSchema<codeBlock>",group:"CodeBlock"});ke(Pd.ctx,{displayName:"NodeSchemaCtx<codeBlock>",group:"CodeBlock"});const RN=er(e=>yA(/^```(?<language>[a-z]*)?[\s\n]$/,Pd.type(e),t=>{var n;return{language:((n=t.groups)==null?void 0:n.language)??""}}));ke(RN,{displayName:"InputRule<createCodeBlockInputRule>",group:"CodeBlock"});const zC=Tt("CreateCodeBlock",e=>(t="")=>jp(Pd.type(e),{language:t}));ke(zC,{displayName:"Command<createCodeBlockCommand>",group:"CodeBlock"});const KCe=Tt("UpdateCodeBlockLanguage",()=>({pos:e,language:t}={pos:-1,language:""})=>(n,o)=>e>=0?(o==null||o(n.tr.setNodeAttribute(e,"language",t)),!0):!1);ke(KCe,{displayName:"Command<updateCodeBlockLanguageCommand>",group:"CodeBlock"});const jC=tr("codeBlockKeymap",{CreateCodeBlock:{shortcuts:"Mod-Alt-c",command:e=>{const t=e.get(Dt);return()=>t.call(zC.key)}}});ke(jC.ctx,{displayName:"KeymapCtx<codeBlock>",group:"CodeBlock"});ke(jC.shortcuts,{displayName:"Keymap<codeBlock>",group:"CodeBlock"});const HC=$s("image");ke(HC,{displayName:"Attr<image>",group:"Image"});const Ld=Yn("image",e=>({inline:!0,group:"inline",selectable:!0,draggable:!0,marks:"",atom:!0,defining:!0,isolating:!0,attrs:{src:{default:""},alt:{default:""},title:{default:""}},parseDOM:[{tag:"img[src]",getAttrs:t=>{if(!(t instanceof HTMLElement))throw ii(t);return{src:t.getAttribute("src")||"",alt:t.getAttribute("alt")||"",title:t.getAttribute("title")||t.getAttribute("alt")||""}}}],toDOM:t=>["img",{...e.get(HC.key)(t),...t.attrs}],parseMarkdown:{match:({type:t})=>t==="image",runner:(t,n,o)=>{const r=n.url,s=n.alt,i=n.title;t.addNode(o,{src:r,alt:s,title:i})}},toMarkdown:{match:t=>t.type.name==="image",runner:(t,n)=>{t.addNode("image",void 0,void 0,{title:n.attrs.title,url:n.attrs.src,alt:n.attrs.alt})}}}));ke(Ld.node,{displayName:"NodeSchema<image>",group:"Image"});ke(Ld.ctx,{displayName:"NodeSchemaCtx<image>",group:"Image"});const DN=Tt("InsertImage",e=>(t={})=>(n,o)=>{if(!o)return!0;const{src:r="",alt:s="",title:i=""}=t,l=Ld.type(e).create({src:r,alt:s,title:i});return l&&o(n.tr.replaceSelectionWith(l).scrollIntoView()),!0});ke(DN,{displayName:"Command<insertImageCommand>",group:"Image"});const FN=Tt("UpdateImage",e=>(t={})=>(n,o)=>{const r=awe(n.selection,Ld.type(e));if(!r)return!1;const{node:s,pos:i}=r,l={...s.attrs},{src:a,alt:u,title:c}=t;return a!==void 0&&(l.src=a),u!==void 0&&(l.alt=u),c!==void 0&&(l.title=c),o==null||o(n.tr.setNodeMarkup(i,void 0,l).scrollIntoView()),!0});ke(FN,{displayName:"Command<updateImageCommand>",group:"Image"});const qCe=er(e=>new Cr(/!\[(?<alt>.*?)]\((?<filename>.*?)\s*(?="|\))"?(?<title>[^"]+)?"?\)/,(t,n,o,r)=>{const[s,i,l="",a]=n;return s?t.tr.replaceWith(o,r,Ld.type(e).create({src:l,alt:i,title:a})):null}));ke(qCe,{displayName:"InputRule<insertImageInputRule>",group:"Image"});const t0=$s("hardbreak",e=>({"data-type":"hardbreak","data-is-inline":e.attrs.isInline}));ke(t0,{displayName:"Attr<hardbreak>",group:"Hardbreak"});const Xa=Yn("hardbreak",e=>({inline:!0,group:"inline",attrs:{isInline:{default:!1}},selectable:!1,parseDOM:[{tag:"br"},{tag:'span[data-type="hardbreak"]',getAttrs:()=>({isInline:!0})}],toDOM:t=>t.attrs.isInline?["span",e.get(t0.key)(t)," "]:["br",e.get(t0.key)(t)],parseMarkdown:{match:({type:t})=>t==="break",runner:(t,n,o)=>{var r;t.addNode(o,{isInline:!!((r=n.data)!=null&&r.isInline)})}},leafText:()=>`
119 `,toMarkdown:{match:t=>t.type.name==="hardbreak",runner:(t,n)=>{n.attrs.isInline?t.addNode("text",void 0,`
120 `):t.addNode("break")}}}));ke(Xa.node,{displayName:"NodeSchema<hardbreak>",group:"Hardbreak"});ke(Xa.ctx,{displayName:"NodeSchemaCtx<hardbreak>",group:"Hardbreak"});const UC=Tt("InsertHardbreak",e=>()=>(t,n)=>{var o;const{selection:r,tr:s}=t;if(!(r instanceof ht))return!1;if(r.empty){const i=r.$from.node();if(i.childCount>0&&((o=i.lastChild)==null?void 0:o.type.name)==="hardbreak")return n==null||n(s.replaceRangeWith(r.to-1,r.to,t.schema.node("paragraph")).setSelection(bt.near(s.doc.resolve(r.to))).scrollIntoView()),!0}return n==null||n(s.setMeta("hardbreak",!0).replaceSelectionWith(Xa.type(e).create()).scrollIntoView()),!0});ke(UC,{displayName:"Command<insertHardbreakCommand>",group:"Hardbreak"});const WC=tr("hardbreakKeymap",{InsertHardbreak:{shortcuts:"Shift-Enter",command:e=>{const t=e.get(Dt);return()=>t.call(UC.key)}}});ke(WC.ctx,{displayName:"KeymapCtx<hardbreak>",group:"Hardbreak"});ke(WC.shortcuts,{displayName:"Keymap<hardbreak>",group:"Hardbreak"});const KC=$s("hr");ke(KC,{displayName:"Attr<hr>",group:"Hr"});const Nh=Yn("hr",e=>({group:"block",parseDOM:[{tag:"hr"}],toDOM:t=>["hr",e.get(KC.key)(t)],parseMarkdown:{match:({type:t})=>t==="thematicBreak",runner:(t,n,o)=>{t.addNode(o)}},toMarkdown:{match:t=>t.type.name==="hr",runner:t=>{t.addNode("thematicBreak")}}}));ke(Nh.node,{displayName:"NodeSchema<hr>",group:"Hr"});ke(Nh.ctx,{displayName:"NodeSchemaCtx<hr>",group:"Hr"});const VN=er(e=>new Cr(/^(?:---|___\s|\*\*\*\s)$/,(t,n,o,r)=>{const{tr:s}=t;return n[0]&&s.replaceWith(o-1,r,Nh.type(e).create()),s}));ke(VN,{displayName:"InputRule<insertHrInputRule>",group:"Hr"});const BN=Tt("InsertHr",e=>()=>(t,n)=>{if(!n)return!0;const o=ji.node.type(e).create(),{tr:r,selection:s}=t,{from:i}=s,l=Nh.type(e).create();if(!l)return!0;const a=r.replaceSelectionWith(l).insert(i,o),u=bt.findFrom(a.doc.resolve(i),1,!0);return u&&n(a.setSelection(u).scrollIntoView()),!0});ke(BN,{displayName:"Command<insertHrCommand>",group:"Hr"});const qC=$s("bulletList");ke(qC,{displayName:"Attr<bulletList>",group:"BulletList"});const Mu=Yn("bullet_list",e=>({content:"listItem+",group:"block",attrs:{spread:{default:!1}},parseDOM:[{tag:"ul",getAttrs:t=>{if(!(t instanceof HTMLElement))throw ii(t);return{spread:t.dataset.spread}}}],toDOM:t=>["ul",{...e.get(qC.key)(t),"data-spread":t.attrs.spread},0],parseMarkdown:{match:({type:t,ordered:n})=>t==="list"&&!n,runner:(t,n,o)=>{const r=n.spread!=null?`${n.spread}`:"false";t.openNode(o,{spread:r}).next(n.children).closeNode()}},toMarkdown:{match:t=>t.type.name==="bullet_list",runner:(t,n)=>{t.openNode("list",void 0,{ordered:!1,spread:n.attrs.spread==="true"}).next(n.content).closeNode()}}}));ke(Mu.node,{displayName:"NodeSchema<bulletList>",group:"BulletList"});ke(Mu.ctx,{displayName:"NodeSchemaCtx<bulletList>",group:"BulletList"});const zN=er(e=>uC(/^\s*([-+*])\s$/,Mu.type(e)));ke(zN,{displayName:"InputRule<wrapInBulletListInputRule>",group:"BulletList"});const GC=Tt("WrapInBulletList",e=>()=>hC(Mu.type(e)));ke(GC,{displayName:"Command<wrapInBulletListCommand>",group:"BulletList"});const YC=tr("bulletListKeymap",{WrapInBulletList:{shortcuts:"Mod-Alt-8",command:e=>{const t=e.get(Dt);return()=>t.call(GC.key)}}});ke(YC.ctx,{displayName:"KeymapCtx<bulletListKeymap>",group:"BulletList"});ke(YC.shortcuts,{displayName:"Keymap<bulletListKeymap>",group:"BulletList"});const ZC=$s("orderedList");ke(ZC,{displayName:"Attr<orderedList>",group:"OrderedList"});const Tu=Yn("ordered_list",e=>({content:"listItem+",group:"block",attrs:{order:{default:1},spread:{default:!1}},parseDOM:[{tag:"ol",getAttrs:t=>{if(!(t instanceof HTMLElement))throw ii(t);return{spread:t.dataset.spread,order:t.hasAttribute("start")?Number(t.getAttribute("start")):1}}}],toDOM:t=>["ol",{...e.get(ZC.key)(t),...t.attrs.order===1?{}:t.attrs.order,"data-spread":t.attrs.spread},0],parseMarkdown:{match:({type:t,ordered:n})=>t==="list"&&!!n,runner:(t,n,o)=>{const r=n.spread!=null?`${n.spread}`:"true";t.openNode(o,{spread:r}).next(n.children).closeNode()}},toMarkdown:{match:t=>t.type.name==="ordered_list",runner:(t,n)=>{t.openNode("list",void 0,{ordered:!0,start:1,spread:n.attrs.spread==="true"}),t.next(n.content),t.closeNode()}}}));ke(Tu.node,{displayName:"NodeSchema<orderedList>",group:"OrderedList"});ke(Tu.ctx,{displayName:"NodeSchemaCtx<orderedList>",group:"OrderedList"});const jN=er(e=>uC(/^\s*(\d+)\.\s$/,Tu.type(e),t=>({order:Number(t[1])}),(t,n)=>n.childCount+n.attrs.order===Number(t[1])));ke(jN,{displayName:"InputRule<wrapInOrderedListInputRule>",group:"OrderedList"});const JC=Tt("WrapInOrderedList",e=>()=>hC(Tu.type(e)));ke(JC,{displayName:"Command<wrapInOrderedListCommand>",group:"OrderedList"});const XC=tr("orderedListKeymap",{WrapInOrderedList:{shortcuts:"Mod-Alt-7",command:e=>{const t=e.get(Dt);return()=>t.call(JC.key)}}});ke(XC.ctx,{displayName:"KeymapCtx<orderedList>",group:"OrderedList"});ke(XC.shortcuts,{displayName:"Keymap<orderedList>",group:"OrderedList"});const QC=$s("listItem");ke(QC,{displayName:"Attr<listItem>",group:"ListItem"});const Qs=Yn("list_item",e=>({group:"listItem",content:"(paragraph|blockquote) block*",attrs:{label:{default:"•"},listType:{default:"bullet"},spread:{default:"true"}},defining:!0,parseDOM:[{tag:"li",getAttrs:t=>{if(!(t instanceof HTMLElement))throw ii(t);return{label:t.dataset.label,listType:t.dataset.listType,spread:t.dataset.spread}}}],toDOM:t=>["li",{...e.get(QC.key)(t),"data-label":t.attrs.label,"data-list-type":t.attrs.listType,"data-spread":t.attrs.spread},0],parseMarkdown:{match:({type:t})=>t==="listItem",runner:(t,n,o)=>{const r=n.label!=null?`${n.label}.`:"•",s=n.label!=null?"ordered":"bullet",i=n.spread!=null?`${n.spread}`:"true";t.openNode(o,{label:r,listType:s,spread:i}),t.next(n.children),t.closeNode()}},toMarkdown:{match:t=>t.type.name==="list_item",runner:(t,n)=>{t.openNode("listItem",void 0,{spread:n.attrs.spread==="true"}),t.next(n.content),t.closeNode()}}}));ke(Qs.node,{displayName:"NodeSchema<listItem>",group:"ListItem"});ke(Qs.ctx,{displayName:"NodeSchemaCtx<listItem>",group:"ListItem"});const ek=Tt("SinkListItem",e=>()=>zCe(Qs.type(e)));ke(ek,{displayName:"Command<sinkListItemCommand>",group:"ListItem"});const tk=Tt("LiftListItem",e=>()=>$N(Qs.type(e)));ke(tk,{displayName:"Command<liftListItemCommand>",group:"ListItem"});const nk=Tt("SplitListItem",e=>()=>FCe(Qs.type(e)));ke(nk,{displayName:"Command<splitListItemCommand>",group:"ListItem"});function GCe(e){return(t,n,o)=>{const{selection:r}=t;if(!(r instanceof ht))return!1;const{empty:s,$from:i}=r;if(!s||i.parentOffset!==0)return!1;const l=i.node(-1);return l.type!==Qs.type(e)||l.firstChild!==i.node()||i.node(-2).childCount>1?!1:$N(Qs.type(e))(t,n,o)}}const ok=Tt("LiftFirstListItem",e=>()=>GCe(e));ke(ok,{displayName:"Command<liftFirstListItemCommand>",group:"ListItem"});const rk=tr("listItemKeymap",{NextListItem:{shortcuts:"Enter",command:e=>{const t=e.get(Dt);return()=>t.call(nk.key)}},SinkListItem:{shortcuts:["Tab","Mod-]"],command:e=>{const t=e.get(Dt);return()=>t.call(ek.key)}},LiftListItem:{shortcuts:["Shift-Tab","Mod-["],command:e=>{const t=e.get(Dt);return()=>t.call(tk.key)}},LiftFirstListItem:{shortcuts:["Backspace","Delete"],command:e=>{const t=e.get(Dt);return()=>t.call(ok.key)}}});ke(rk.ctx,{displayName:"KeymapCtx<listItem>",group:"ListItem"});ke(rk.shortcuts,{displayName:"Keymap<listItem>",group:"ListItem"});const HN=kC("text",()=>({group:"inline",parseMarkdown:{match:({type:e})=>e==="text",runner:(e,t)=>{e.addText(t.value)}},toMarkdown:{match:e=>e.type.name==="text",runner:(e,t)=>{e.addNode("text",void 0,t.text)}}}));ke(HN,{displayName:"NodeSchema<text>",group:"Text"});const sk=$s("html");ke(sk,{displayName:"Attr<html>",group:"Html"});const ik=Yn("html",e=>({atom:!0,group:"inline",inline:!0,attrs:{value:{default:""}},toDOM:t=>{const n=document.createElement("span"),o={...e.get(sk.key)(t),"data-value":t.attrs.value,"data-type":"html"};return n.textContent=t.attrs.value,["span",o,t.attrs.value]},parseDOM:[{tag:'span[data-type="html"]',getAttrs:t=>({value:t.dataset.value??""})}],parseMarkdown:{match:({type:t})=>t==="html",runner:(t,n,o)=>{t.addNode(o,{value:n.value})}},toMarkdown:{match:t=>t.type.name==="html",runner:(t,n)=>{t.addNode("html",void 0,n.attrs.value)}}}));ke(ik.node,{displayName:"NodeSchema<html>",group:"Html"});ke(ik.ctx,{displayName:"NodeSchemaCtx<html>",group:"Html"});const YCe=[NN,IC,ji,_v,PC,Ws,t0,Xa,DC,Nd,BC,Pd,KC,Nh,HC,Ld,qC,Mu,ZC,Tu,QC,Qs,SC,xu,EC,Ad,MC,$i,OC,fs,sk,ik,HN].flat(),ZCe=[LN,zN,jN,RN,VN,PN].flat(),JCe=[xN,MN,ON,TN],XCe=[AC,FC,bl,LC,zC,UC,BN,DN,FN,JC,GC,ek,nk,tk,ok,gv,yv,vv,IN,AN],QCe=[VC,jC,WC,RC,rk,XC,YC,NC,$C,TC,xC].flat(),lk=Id("remarkAddOrderInList",()=>()=>e=>{Od(e,"list",t=>{if(t.ordered){const n=t.start??1;t.children.forEach((o,r)=>{o.label=r+n})}})});ke(lk.plugin,{displayName:"Remark<remarkAddOrderInListPlugin>",group:"Remark"});ke(lk.options,{displayName:"RemarkConfig<remarkAddOrderInListPlugin>",group:"Remark"});const ak=Id("remarkLineBreak",()=>()=>e=>{const t=/[\t ]*(?:\r?\n|\r)/g;Od(e,"text",(n,o,r)=>{if(!n.value||typeof n.value!="string")return;const s=[];let i=0;t.lastIndex=0;let l=t.exec(n.value);for(;l;){const a=l.index;i!==a&&s.push({type:"text",value:n.value.slice(i,a)}),s.push({type:"break",data:{isInline:!0}}),i=a+l[0].length,l=t.exec(n.value)}if(s.length>0&&r&&typeof o=="number")return i<n.value.length&&s.push({type:"text",value:n.value.slice(i)}),r.children.splice(o,1,...s),o+s.length})});ke(ak.plugin,{displayName:"Remark<remarkLineBreak>",group:"Remark"});ke(ak.options,{displayName:"RemarkConfig<remarkLineBreak>",group:"Remark"});const uk=Id("remarkInlineLink",()=>HCe);ke(uk.plugin,{displayName:"Remark<remarkInlineLinkPlugin>",group:"Remark"});ke(uk.options,{displayName:"RemarkConfig<remarkInlineLinkPlugin>",group:"Remark"});const eke=e=>!!e.children,tke=e=>e.type==="html";function nke(e,t){return n(e,0,null)[0];function n(o,r,s){if(eke(o)){const i=[];for(let l=0,a=o.children.length;l<a;l++){const u=o.children[l];if(u){const c=n(u,l,o);if(c)for(let d=0,f=c.length;d<f;d++){const p=c[d];p&&i.push(p)}}}o.children=i}return t(o,r,s)}}const ck=Id("remarkHTMLTransformer",()=>()=>e=>{nke(e,(t,n,o)=>tke(t)?((o==null?void 0:o.type)==="root"&&(t.children=[{...t}],delete t.value,t.type="paragraph"),[t]):[t])});ke(ck.plugin,{displayName:"Remark<remarkHtmlTransformer>",group:"Remark"});ke(ck.options,{displayName:"RemarkConfig<remarkHtmlTransformer>",group:"Remark"});const dk=Id("remarkMarker",()=>()=>(e,t)=>{const n=o=>t.value.charAt(o.position.start.offset);Od(e,o=>["strong","emphasis"].includes(o.type),o=>{o.marker=n(o)})});ke(dk.plugin,{displayName:"Remark<remarkMarker>",group:"Remark"});ke(dk.options,{displayName:"RemarkConfig<remarkMarker>",group:"Remark"});const UN=ao(()=>{let e=!1;const t=new wn("MILKDOWN_INLINE_NODES_CURSOR"),n=new xn({key:t,state:{init(){return!1},apply(o){if(!o.selection.empty)return!1;const r=o.selection.$from,s=r.nodeBefore,i=r.nodeAfter;return!!(s&&i&&s.isInline&&!s.isText&&i.isInline&&!i.isText)}},props:{handleDOMEvents:{compositionend:(o,r)=>e?(e=!1,requestAnimationFrame(()=>{if(n.getState(o.state)){const s=o.state.selection.from;r.preventDefault(),o.dispatch(o.state.tr.insertText(r.data||"",s))}}),!0):!1,compositionstart:o=>(n.getState(o.state)&&(e=!0),!1),beforeinput:(o,r)=>{if(n.getState(o.state)&&r instanceof InputEvent&&r.data&&!e){const s=o.state.selection.from;return r.preventDefault(),o.dispatch(o.state.tr.insertText(r.data||"",s)),!0}return!1}},decorations(o){if(n.getState(o)){const r=o.selection.$from.pos,s=document.createElement("span"),i=zn.widget(r,s,{side:-1}),l=document.createElement("span"),a=zn.widget(r,l);return setTimeout(()=>{s.contentEditable="true",l.contentEditable="true"}),an.create(o.doc,[i,a])}return an.empty}}});return n});ke(UN,{displayName:"Prose<inlineNodesCursorPlugin>",group:"Prose"});const WN=ao(e=>new xn({key:new wn("MILKDOWN_HARDBREAK_MARKS"),appendTransaction:(t,n,o)=>{if(!t.length)return;const[r]=t;if(!r)return;const[s]=r.steps;if(r.getMeta("hardbreak")){if(!(s instanceof eo))return;const{from:i}=s;return o.tr.setNodeMarkup(i,Xa.type(e),void 0,[])}if(s instanceof Si){let i=o.tr;const{from:l,to:a}=s;return o.doc.nodesBetween(l,a,(u,c)=>{u.type===Xa.type(e)&&(i=i.setNodeMarkup(c,Xa.type(e),void 0,[]))}),i}}}));ke(WN,{displayName:"Prose<hardbreakClearMarkPlugin>",group:"Prose"});const fk=In(["table","code_block"],"hardbreakFilterNodes");ke(fk,{displayName:"Ctx<hardbreakFilterNodes>",group:"Prose"});const KN=ao(e=>{const t=e.get(fk.key);return new xn({key:new wn("MILKDOWN_HARDBREAK_FILTER"),filterTransaction:(n,o)=>{const r=n.getMeta("hardbreak"),[s]=n.steps;if(r&&s){const{from:i}=s,l=o.doc.resolve(i);let a=l.depth,u=!0;for(;a>0;)t.includes(l.node(a).type.name)&&(u=!1),a--;return u}return!0}})});ke(KN,{displayName:"Prose<hardbreakFilterPlugin>",group:"Prose"});const qN=ao(e=>{const t=new wn("MILKDOWN_HEADING_ID"),n=o=>{if(o.composing)return;const r=e.get(_v.key),s=o.state.tr.setMeta("addToHistory",!1);let i=!1;o.state.doc.descendants((l,a)=>{if(l.type===Ws.type(e)){if(l.textContent.trim().length===0)return;const u=l.attrs,c=r(l);u.id!==c&&(i=!0,s.setMeta(t,!0).setNodeMarkup(a,void 0,{...u,id:c}))}}),i&&o.dispatch(s)};return new xn({key:t,view:o=>(n(o),{update:(r,s)=>{r.state.doc.eq(s.doc)||n(r)}})})});ke(qN,{displayName:"Prose<syncHeadingIdPlugin>",group:"Prose"});const GN=ao(e=>{const t=n=>{if(n.composing||!n.editable)return;const o=Tu.type(e),r=Mu.type(e),s=Qs.type(e),i=n.state,l=(c,d)=>{let f=!1;const p=`${d+1}.`;return c.label!==p&&(c.label=p,f=!0),f};let a=i.tr,u=!1;i.doc.descendants((c,d,f,p)=>{if(c.type===r){const h=c.maybeChild(0);(h==null?void 0:h.type)===s&&h.attrs.listType==="ordered"&&(u=!0,a.setNodeMarkup(d,o,{spread:"true"}),c.descendants((m,y,v,w)=>{if(m.type===s){const _={...m.attrs};l(_,w)&&(a=a.setNodeMarkup(y,void 0,_))}return!1}))}else if(c.type===s&&(f==null?void 0:f.type)===o){const h={...c.attrs};let m=!1;h.listType!=="ordered"&&(h.listType="ordered",m=!0),f!=null&&f.maybeChild(0)&&(m=l(h,p)),m&&(a=a.setNodeMarkup(d,void 0,h),u=!0)}}),u&&n.dispatch(a.setMeta("addToHistory",!1))};return new xn({key:new wn("MILKDOWN_KEEP_LIST_ORDER"),view:n=>(t(n),{update:o=>{t(o)}})})});ke(GN,{displayName:"Prose<syncListOrderPlugin>",group:"Prose"});const oke=[WN,fk,KN,UN,lk,uk,ak,ck,dk,qN,GN].flat(),rke=[YCe,ZCe,JCe,XCe,QCe,oke].flat();var g2,v2;if(typeof WeakMap<"u"){let e=new WeakMap;g2=t=>e.get(t),v2=(t,n)=>(e.set(t,n),n)}else{const e=[];let n=0;g2=o=>{for(let r=0;r<e.length;r+=2)if(e[r]==o)return e[r+1]},v2=(o,r)=>(n==10&&(n=0),e[n++]=o,e[n++]=r)}var Xt=class{constructor(e,t,n,o){this.width=e,this.height=t,this.map=n,this.problems=o}findCell(e){for(let t=0;t<this.map.length;t++){const n=this.map[t];if(n!=e)continue;const o=t%this.width,r=t/this.width|0;let s=o+1,i=r+1;for(let l=1;s<this.width&&this.map[t+l]==n;l++)s++;for(let l=1;i<this.height&&this.map[t+this.width*l]==n;l++)i++;return{left:o,top:r,right:s,bottom:i}}throw new RangeError(`No cell with offset ${e} found`)}colCount(e){for(let t=0;t<this.map.length;t++)if(this.map[t]==e)return t%this.width;throw new RangeError(`No cell with offset ${e} found`)}nextCell(e,t,n){const{left:o,right:r,top:s,bottom:i}=this.findCell(e);return t=="horiz"?(n<0?o==0:r==this.width)?null:this.map[s*this.width+(n<0?o-1:r)]:(n<0?s==0:i==this.height)?null:this.map[o+this.width*(n<0?s-1:i)]}rectBetween(e,t){const{left:n,right:o,top:r,bottom:s}=this.findCell(e),{left:i,right:l,top:a,bottom:u}=this.findCell(t);return{left:Math.min(n,i),top:Math.min(r,a),right:Math.max(o,l),bottom:Math.max(s,u)}}cellsInRect(e){const t=[],n={};for(let o=e.top;o<e.bottom;o++)for(let r=e.left;r<e.right;r++){const s=o*this.width+r,i=this.map[s];n[i]||(n[i]=!0,!(r==e.left&&r&&this.map[s-1]==i||o==e.top&&o&&this.map[s-this.width]==i)&&t.push(i))}return t}positionAt(e,t,n){for(let o=0,r=0;;o++){const s=r+n.child(o).nodeSize;if(o==e){let i=t+e*this.width;const l=(e+1)*this.width;for(;i<l&&this.map[i]<r;)i++;return i==l?s-1:this.map[i]}r=s}}static get(e){return g2(e)||v2(e,ske(e))}};function ske(e){if(e.type.spec.tableRole!="table")throw new RangeError("Not a table node: "+e.type.name);const t=ike(e),n=e.childCount,o=[];let r=0,s=null;const i=[];for(let u=0,c=t*n;u<c;u++)o[u]=0;for(let u=0,c=0;u<n;u++){const d=e.child(u);c++;for(let h=0;;h++){for(;r<o.length&&o[r]!=0;)r++;if(h==d.childCount)break;const m=d.child(h),{colspan:y,rowspan:v,colwidth:w}=m.attrs;for(let _=0;_<v;_++){if(_+u>=n){(s||(s=[])).push({type:"overlong_rowspan",pos:c,n:v-_});break}const S=r+_*t;for(let x=0;x<y;x++){o[S+x]==0?o[S+x]=c:(s||(s=[])).push({type:"collision",row:u,pos:c,n:y-x});const E=w&&w[x];if(E){const T=(S+x)%t*2,O=i[T];O==null||O!=E&&i[T+1]==1?(i[T]=E,i[T+1]=1):O==E&&i[T+1]++}}}r+=y,c+=m.nodeSize}const f=(u+1)*t;let p=0;for(;r<f;)o[r++]==0&&p++;p&&(s||(s=[])).push({type:"missing",row:u,n:p}),c++}const l=new Xt(t,n,o,s);let a=!1;for(let u=0;!a&&u<i.length;u+=2)i[u]!=null&&i[u+1]<n&&(a=!0);return a&&lke(l,i,e),l}function ike(e){let t=-1,n=!1;for(let o=0;o<e.childCount;o++){const r=e.child(o);let s=0;if(n)for(let i=0;i<o;i++){const l=e.child(i);for(let a=0;a<l.childCount;a++){const u=l.child(a);i+u.attrs.rowspan>o&&(s+=u.attrs.colspan)}}for(let i=0;i<r.childCount;i++){const l=r.child(i);s+=l.attrs.colspan,l.attrs.rowspan>1&&(n=!0)}t==-1?t=s:t!=s&&(t=Math.max(t,s))}return t}function lke(e,t,n){e.problems||(e.problems=[]);const o={};for(let r=0;r<e.map.length;r++){const s=e.map[r];if(o[s])continue;o[s]=!0;const i=n.nodeAt(s);if(!i)throw new RangeError(`No cell with offset ${s} found`);let l=null;const a=i.attrs;for(let u=0;u<a.colspan;u++){const c=(r+u)%e.width,d=t[c*2];d!=null&&(!a.colwidth||a.colwidth[u]!=d)&&((l||(l=ake(a)))[u]=d)}l&&e.problems.unshift({type:"colwidth mismatch",pos:s,colwidth:l})}}function ake(e){if(e.colwidth)return e.colwidth.slice();const t=[];for(let n=0;n<e.colspan;n++)t.push(0);return t}function O9(e,t){if(typeof e=="string")return{};const n=e.getAttribute("data-colwidth"),o=n&&/^\d+(,\d+)*$/.test(n)?n.split(",").map(i=>Number(i)):null,r=Number(e.getAttribute("colspan")||1),s={colspan:r,rowspan:Number(e.getAttribute("rowspan")||1),colwidth:o&&o.length==r?o:null};for(const i in t){const l=t[i].getFromDOM,a=l&&l(e);a!=null&&(s[i]=a)}return s}function I9(e,t){const n={};e.attrs.colspan!=1&&(n.colspan=e.attrs.colspan),e.attrs.rowspan!=1&&(n.rowspan=e.attrs.rowspan),e.attrs.colwidth&&(n["data-colwidth"]=e.attrs.colwidth.join(","));for(const o in t){const r=t[o].setDOMAttr;r&&r(e.attrs[o],n)}return n}function uke(e){const t=e.cellAttributes||{},n={colspan:{default:1},rowspan:{default:1},colwidth:{default:null}};for(const o in t)n[o]={default:t[o].default};return{table:{content:"table_row+",tableRole:"table",isolating:!0,group:e.tableGroup,parseDOM:[{tag:"table"}],toDOM(){return["table",["tbody",0]]}},table_row:{content:"(table_cell | table_header)*",tableRole:"row",parseDOM:[{tag:"tr"}],toDOM(){return["tr",0]}},table_cell:{content:e.cellContent,attrs:n,tableRole:"cell",isolating:!0,parseDOM:[{tag:"td",getAttrs:o=>O9(o,t)}],toDOM(o){return["td",I9(o,t),0]}},table_header:{content:e.cellContent,attrs:n,tableRole:"header_cell",isolating:!0,parseDOM:[{tag:"th",getAttrs:o=>O9(o,t)}],toDOM(o){return["th",I9(o,t),0]}}}}function Wr(e){let t=e.cached.tableNodeTypes;if(!t){t=e.cached.tableNodeTypes={};for(const n in e.nodes){const o=e.nodes[n],r=o.spec.tableRole;r&&(t[r]=o)}}return t}var $l=new wn("selectingCells");function Ph(e){for(let t=e.depth-1;t>0;t--)if(e.node(t).type.spec.tableRole=="row")return e.node(0).resolve(e.before(t+1));return null}function Yr(e){const t=e.selection.$head;for(let n=t.depth;n>0;n--)if(t.node(n).type.spec.tableRole=="row")return!0;return!1}function bv(e){const t=e.selection;if("$anchorCell"in t&&t.$anchorCell)return t.$anchorCell.pos>t.$headCell.pos?t.$anchorCell:t.$headCell;if("node"in t&&t.node&&t.node.type.spec.tableRole=="cell")return t.$anchor;const n=Ph(t.$head)||cke(t.$head);if(n)return n;throw new RangeError(`No cell found around position ${t.head}`)}function cke(e){for(let t=e.nodeAfter,n=e.pos;t;t=t.firstChild,n++){const o=t.type.spec.tableRole;if(o=="cell"||o=="header_cell")return e.doc.resolve(n)}for(let t=e.nodeBefore,n=e.pos;t;t=t.lastChild,n--){const o=t.type.spec.tableRole;if(o=="cell"||o=="header_cell")return e.doc.resolve(n-t.nodeSize)}}function y2(e){return e.parent.type.spec.tableRole=="row"&&!!e.nodeAfter}function dke(e){return e.node(0).resolve(e.pos+e.nodeAfter.nodeSize)}function pk(e,t){return e.depth==t.depth&&e.pos>=t.start(-1)&&e.pos<=t.end(-1)}function YN(e,t,n){const o=e.node(-1),r=Xt.get(o),s=e.start(-1),i=r.nextCell(e.pos-s,t,n);return i==null?null:e.node(0).resolve(s+i)}function gu(e,t,n=1){const o={...e,colspan:e.colspan-n};return o.colwidth&&(o.colwidth=o.colwidth.slice(),o.colwidth.splice(t,n),o.colwidth.some(r=>r>0)||(o.colwidth=null)),o}function fke(e,t,n=1){const o={...e,colspan:e.colspan+n};if(o.colwidth){o.colwidth=o.colwidth.slice();for(let r=0;r<n;r++)o.colwidth.splice(t,0,0)}return o}function pke(e,t,n){const o=Wr(t.type.schema).header_cell;for(let r=0;r<e.height;r++)if(t.nodeAt(e.map[n+r*e.width]).type!=o)return!1;return!0}var hn=class mi extends bt{constructor(t,n=t){const o=t.node(-1),r=Xt.get(o),s=t.start(-1),i=r.rectBetween(t.pos-s,n.pos-s),l=t.node(0),a=r.cellsInRect(i).filter(c=>c!=n.pos-s);a.unshift(n.pos-s);const u=a.map(c=>{const d=o.nodeAt(c);if(!d)throw RangeError(`No cell with offset ${c} found`);const f=s+c+1;return new Yg(l.resolve(f),l.resolve(f+d.content.size))});super(u[0].$from,u[0].$to,u),this.$anchorCell=t,this.$headCell=n}map(t,n){const o=t.resolve(n.map(this.$anchorCell.pos)),r=t.resolve(n.map(this.$headCell.pos));if(y2(o)&&y2(r)&&pk(o,r)){const s=this.$anchorCell.node(-1)!=o.node(-1);return s&&this.isRowSelection()?mi.rowSelection(o,r):s&&this.isColSelection()?mi.colSelection(o,r):new mi(o,r)}return ht.between(o,r)}content(){const t=this.$anchorCell.node(-1),n=Xt.get(t),o=this.$anchorCell.start(-1),r=n.rectBetween(this.$anchorCell.pos-o,this.$headCell.pos-o),s={},i=[];for(let a=r.top;a<r.bottom;a++){const u=[];for(let c=a*n.width+r.left,d=r.left;d<r.right;d++,c++){const f=n.map[c];if(s[f])continue;s[f]=!0;const p=n.findCell(f);let h=t.nodeAt(f);if(!h)throw RangeError(`No cell with offset ${f} found`);const m=r.left-p.left,y=p.right-r.right;if(m>0||y>0){let v=h.attrs;if(m>0&&(v=gu(v,0,m)),y>0&&(v=gu(v,v.colspan-y,y)),p.left<r.left){if(h=h.type.createAndFill(v),!h)throw RangeError(`Could not create cell with attrs ${JSON.stringify(v)}`)}else h=h.type.create(v,h.content)}if(p.top<r.top||p.bottom>r.bottom){const v={...h.attrs,rowspan:Math.min(p.bottom,r.bottom)-Math.max(p.top,r.top)};p.top<r.top?h=h.type.createAndFill(v):h=h.type.create(v,h.content)}u.push(h)}i.push(t.child(a).copy(Ue.from(u)))}const l=this.isColSelection()&&this.isRowSelection()?t:i;return new Ye(Ue.from(l),1,1)}replace(t,n=Ye.empty){const o=t.steps.length,r=this.ranges;for(let i=0;i<r.length;i++){const{$from:l,$to:a}=r[i],u=t.mapping.slice(o);t.replace(u.map(l.pos),u.map(a.pos),i?Ye.empty:n)}const s=bt.findFrom(t.doc.resolve(t.mapping.slice(o).map(this.to)),-1);s&&t.setSelection(s)}replaceWith(t,n){this.replace(t,new Ye(Ue.from(n),0,0))}forEachCell(t){const n=this.$anchorCell.node(-1),o=Xt.get(n),r=this.$anchorCell.start(-1),s=o.cellsInRect(o.rectBetween(this.$anchorCell.pos-r,this.$headCell.pos-r));for(let i=0;i<s.length;i++)t(n.nodeAt(s[i]),r+s[i])}isColSelection(){const t=this.$anchorCell.index(-1),n=this.$headCell.index(-1);if(Math.min(t,n)>0)return!1;const o=t+this.$anchorCell.nodeAfter.attrs.rowspan,r=n+this.$headCell.nodeAfter.attrs.rowspan;return Math.max(o,r)==this.$headCell.node(-1).childCount}static colSelection(t,n=t){const o=t.node(-1),r=Xt.get(o),s=t.start(-1),i=r.findCell(t.pos-s),l=r.findCell(n.pos-s),a=t.node(0);return i.top<=l.top?(i.top>0&&(t=a.resolve(s+r.map[i.left])),l.bottom<r.height&&(n=a.resolve(s+r.map[r.width*(r.height-1)+l.right-1]))):(l.top>0&&(n=a.resolve(s+r.map[l.left])),i.bottom<r.height&&(t=a.resolve(s+r.map[r.width*(r.height-1)+i.right-1]))),new mi(t,n)}isRowSelection(){const t=this.$anchorCell.node(-1),n=Xt.get(t),o=this.$anchorCell.start(-1),r=n.colCount(this.$anchorCell.pos-o),s=n.colCount(this.$headCell.pos-o);if(Math.min(r,s)>0)return!1;const i=r+this.$anchorCell.nodeAfter.attrs.colspan,l=s+this.$headCell.nodeAfter.attrs.colspan;return Math.max(i,l)==n.width}eq(t){return t instanceof mi&&t.$anchorCell.pos==this.$anchorCell.pos&&t.$headCell.pos==this.$headCell.pos}static rowSelection(t,n=t){const o=t.node(-1),r=Xt.get(o),s=t.start(-1),i=r.findCell(t.pos-s),l=r.findCell(n.pos-s),a=t.node(0);return i.left<=l.left?(i.left>0&&(t=a.resolve(s+r.map[i.top*r.width])),l.right<r.width&&(n=a.resolve(s+r.map[r.width*(l.top+1)-1]))):(l.left>0&&(n=a.resolve(s+r.map[l.top*r.width])),i.right<r.width&&(t=a.resolve(s+r.map[r.width*(i.top+1)-1]))),new mi(t,n)}toJSON(){return{type:"cell",anchor:this.$anchorCell.pos,head:this.$headCell.pos}}static fromJSON(t,n){return new mi(t.resolve(n.anchor),t.resolve(n.head))}static create(t,n,o=n){return new mi(t.resolve(n),t.resolve(o))}getBookmark(){return new hke(this.$anchorCell.pos,this.$headCell.pos)}};hn.prototype.visible=!1;bt.jsonID("cell",hn);var hke=class ZN{constructor(t,n){this.anchor=t,this.head=n}map(t){return new ZN(t.map(this.anchor),t.map(this.head))}resolve(t){const n=t.resolve(this.anchor),o=t.resolve(this.head);return n.parent.type.spec.tableRole=="row"&&o.parent.type.spec.tableRole=="row"&&n.index()<n.parent.childCount&&o.index()<o.parent.childCount&&pk(n,o)?new hn(n,o):bt.near(o,1)}};function mke(e){if(!(e.selection instanceof hn))return null;const t=[];return e.selection.forEachCell((n,o)=>{t.push(zn.node(o,o+n.nodeSize,{class:"selectedCell"}))}),an.create(e.doc,t)}function gke({$from:e,$to:t}){if(e.pos==t.pos||e.pos<e.pos-6)return!1;let n=e.pos,o=t.pos,r=e.depth;for(;r>=0&&!(e.after(r+1)<e.end(r));r--,n++);for(let s=t.depth;s>=0&&!(t.before(s+1)>t.start(s));s--,o--);return n==o&&/row|table/.test(e.node(r).type.spec.tableRole)}function vke({$from:e,$to:t}){let n,o;for(let r=e.depth;r>0;r--){const s=e.node(r);if(s.type.spec.tableRole==="cell"||s.type.spec.tableRole==="header_cell"){n=s;break}}for(let r=t.depth;r>0;r--){const s=t.node(r);if(s.type.spec.tableRole==="cell"||s.type.spec.tableRole==="header_cell"){o=s;break}}return n!==o&&t.parentOffset===0}function yke(e,t,n){const o=(t||e).selection,r=(t||e).doc;let s,i;if(o instanceof mt&&(i=o.node.type.spec.tableRole)){if(i=="cell"||i=="header_cell")s=hn.create(r,o.from);else if(i=="row"){const l=r.resolve(o.from+1);s=hn.rowSelection(l,l)}else if(!n){const l=Xt.get(o.node),a=o.from+1,u=a+l.map[l.width*l.height-1];s=hn.create(r,a+1,u)}}else o instanceof ht&&gke(o)?s=ht.create(r,o.from):o instanceof ht&&vke(o)&&(s=ht.create(r,o.$from.start(),o.$from.end()));return s&&(t||(t=e.tr)).setSelection(s),t}var _ke=new wn("fix-tables");function JN(e,t,n,o){const r=e.childCount,s=t.childCount;e:for(let i=0,l=0;i<s;i++){const a=t.child(i);for(let u=l,c=Math.min(r,i+3);u<c;u++)if(e.child(u)==a){l=u+1,n+=a.nodeSize;continue e}o(a,n),l<r&&e.child(l).sameMarkup(a)?JN(e.child(l),a,n+1,o):a.nodesBetween(0,a.content.size,o,n+1),n+=a.nodeSize}}function bke(e,t){let n;const o=(r,s)=>{r.type.spec.tableRole=="table"&&(n=wke(e,r,s,n))};return t?t.doc!=e.doc&&JN(t.doc,e.doc,0,o):e.doc.descendants(o),n}function wke(e,t,n,o){const r=Xt.get(t);if(!r.problems)return o;o||(o=e.tr);const s=[];for(let a=0;a<r.height;a++)s.push(0);for(let a=0;a<r.problems.length;a++){const u=r.problems[a];if(u.type=="collision"){const c=t.nodeAt(u.pos);if(!c)continue;const d=c.attrs;for(let f=0;f<d.rowspan;f++)s[u.row+f]+=u.n;o.setNodeMarkup(o.mapping.map(n+1+u.pos),null,gu(d,d.colspan-u.n,u.n))}else if(u.type=="missing")s[u.row]+=u.n;else if(u.type=="overlong_rowspan"){const c=t.nodeAt(u.pos);if(!c)continue;o.setNodeMarkup(o.mapping.map(n+1+u.pos),null,{...c.attrs,rowspan:c.attrs.rowspan-u.n})}else if(u.type=="colwidth mismatch"){const c=t.nodeAt(u.pos);if(!c)continue;o.setNodeMarkup(o.mapping.map(n+1+u.pos),null,{...c.attrs,colwidth:u.colwidth})}}let i,l;for(let a=0;a<s.length;a++)s[a]&&(i==null&&(i=a),l=a);for(let a=0,u=n+1;a<r.height;a++){const c=t.child(a),d=u+c.nodeSize,f=s[a];if(f>0){let p="cell";c.firstChild&&(p=c.firstChild.type.spec.tableRole);const h=[];for(let y=0;y<f;y++){const v=Wr(e.schema)[p].createAndFill();v&&h.push(v)}const m=(a==0||i==a-1)&&l==a?u+1:d-1;o.insert(o.mapping.map(m),h)}u=d}return o.setMeta(_ke,{fixTables:!0})}function ia(e){const t=e.selection,n=bv(e),o=n.node(-1),r=n.start(-1),s=Xt.get(o);return{...t instanceof hn?s.rectBetween(t.$anchorCell.pos-r,t.$headCell.pos-r):s.findCell(n.pos-r),tableStart:r,map:s,table:o}}function XN(e,{map:t,tableStart:n,table:o},r){let s=r>0?-1:0;pke(t,o,r+s)&&(s=r==0||r==t.width?null:0);for(let i=0;i<t.height;i++){const l=i*t.width+r;if(r>0&&r<t.width&&t.map[l-1]==t.map[l]){const a=t.map[l],u=o.nodeAt(a);e.setNodeMarkup(e.mapping.map(n+a),null,fke(u.attrs,r-t.colCount(a))),i+=u.attrs.rowspan-1}else{const a=s==null?Wr(o.type.schema).cell:o.nodeAt(t.map[l+s]).type,u=t.positionAt(i,r,o);e.insert(e.mapping.map(n+u),a.createAndFill())}}return e}function Cke(e,t){if(!Yr(e))return!1;if(t){const n=ia(e);t(XN(e.tr,n,n.left))}return!0}function kke(e,t){if(!Yr(e))return!1;if(t){const n=ia(e);t(XN(e.tr,n,n.right))}return!0}function Ske(e,{map:t,table:n,tableStart:o},r){const s=e.mapping.maps.length;for(let i=0;i<t.height;){const l=i*t.width+r,a=t.map[l],u=n.nodeAt(a),c=u.attrs;if(r>0&&t.map[l-1]==a||r<t.width-1&&t.map[l+1]==a)e.setNodeMarkup(e.mapping.slice(s).map(o+a),null,gu(c,r-t.colCount(a)));else{const d=e.mapping.slice(s).map(o+a);e.delete(d,d+u.nodeSize)}i+=c.rowspan}}function $ke(e,t){if(!Yr(e))return!1;if(t){const n=ia(e),o=e.tr;if(n.left==0&&n.right==n.map.width)return!1;for(let r=n.right-1;Ske(o,n,r),r!=n.left;r--){const s=n.tableStart?o.doc.nodeAt(n.tableStart-1):o.doc;if(!s)throw RangeError("No table found");n.table=s,n.map=Xt.get(s)}t(o)}return!0}function Eke(e,{map:t,table:n,tableStart:o},r){let s=0;for(let u=0;u<r;u++)s+=n.child(u).nodeSize;const i=s+n.child(r).nodeSize,l=e.mapping.maps.length;e.delete(s+o,i+o);const a=new Set;for(let u=0,c=r*t.width;u<t.width;u++,c++){const d=t.map[c];if(!a.has(d)){if(a.add(d),r>0&&d==t.map[c-t.width]){const f=n.nodeAt(d).attrs;e.setNodeMarkup(e.mapping.slice(l).map(d+o),null,{...f,rowspan:f.rowspan-1}),u+=f.colspan-1}else if(r<t.height&&d==t.map[c+t.width]){const f=n.nodeAt(d),p=f.attrs,h=f.type.create({...p,rowspan:f.attrs.rowspan-1},f.content),m=t.positionAt(r+1,u,n);e.insert(e.mapping.slice(l).map(o+m),h),u+=p.colspan-1}}}}function xke(e,t){if(!Yr(e))return!1;if(t){const n=ia(e),o=e.tr;if(n.top==0&&n.bottom==n.map.height)return!1;for(let r=n.bottom-1;Eke(o,n,r),r!=n.top;r--){const s=n.tableStart?o.doc.nodeAt(n.tableStart-1):o.doc;if(!s)throw RangeError("No table found");n.table=s,n.map=Xt.get(n.table)}t(o)}return!0}function Mke(e,t){return function(n,o){if(!Yr(n))return!1;const r=bv(n);if(r.nodeAfter.attrs[e]===t)return!1;if(o){const s=n.tr;n.selection instanceof hn?n.selection.forEachCell((i,l)=>{i.attrs[e]!==t&&s.setNodeMarkup(l,null,{...i.attrs,[e]:t})}):s.setNodeMarkup(r.pos,null,{...r.nodeAfter.attrs,[e]:t}),o(s)}return!0}}function Tke(e){return function(t,n){if(!Yr(t))return!1;if(n){const o=Wr(t.schema),r=ia(t),s=t.tr,i=r.map.cellsInRect(e=="column"?{left:r.left,top:0,right:r.right,bottom:r.map.height}:e=="row"?{left:0,top:r.top,right:r.map.width,bottom:r.bottom}:r),l=i.map(a=>r.table.nodeAt(a));for(let a=0;a<i.length;a++)l[a].type==o.header_cell&&s.setNodeMarkup(r.tableStart+i[a],o.cell,l[a].attrs);if(s.steps.length==0)for(let a=0;a<i.length;a++)s.setNodeMarkup(r.tableStart+i[a],o.header_cell,l[a].attrs);n(s)}return!0}}function A9(e,t,n){const o=t.map.cellsInRect({left:0,top:0,right:e=="row"?t.map.width:1,bottom:e=="column"?t.map.height:1});for(let r=0;r<o.length;r++){const s=t.table.nodeAt(o[r]);if(s&&s.type!==n.header_cell)return!1}return!0}function hk(e,t){return t=t||{useDeprecatedLogic:!1},t.useDeprecatedLogic?Tke(e):function(n,o){if(!Yr(n))return!1;if(o){const r=Wr(n.schema),s=ia(n),i=n.tr,l=A9("row",s,r),a=A9("column",s,r),c=(e==="column"?l:e==="row"?a:!1)?1:0,d=e=="column"?{left:0,top:c,right:1,bottom:s.map.height}:e=="row"?{left:c,top:0,right:s.map.width,bottom:1}:s,f=e=="column"?a?r.cell:r.header_cell:e=="row"?l?r.cell:r.header_cell:r.cell;s.map.cellsInRect(d).forEach(p=>{const h=p+s.tableStart,m=i.doc.nodeAt(h);m&&i.setNodeMarkup(h,f,m.attrs)}),o(i)}return!0}}hk("row",{useDeprecatedLogic:!0});hk("column",{useDeprecatedLogic:!0});hk("cell",{useDeprecatedLogic:!0});function Oke(e,t){if(t<0){const n=e.nodeBefore;if(n)return e.pos-n.nodeSize;for(let o=e.index(-1)-1,r=e.before();o>=0;o--){const s=e.node(-1).child(o),i=s.lastChild;if(i)return r-1-i.nodeSize;r-=s.nodeSize}}else{if(e.index()<e.parent.childCount-1)return e.pos+e.nodeAfter.nodeSize;const n=e.node(-1);for(let o=e.indexAfter(-1),r=e.after();o<n.childCount;o++){const s=n.child(o);if(s.childCount)return r+1;r+=s.nodeSize}}return null}function QN(e){return function(t,n){if(!Yr(t))return!1;const o=Oke(bv(t),e);if(o==null)return!1;if(n){const r=t.doc.resolve(o);n(t.tr.setSelection(ht.between(r,dke(r))).scrollIntoView())}return!0}}function Ike(e,t){const n=e.selection.$anchor;for(let o=n.depth;o>0;o--)if(n.node(o).type.spec.tableRole=="table")return t&&t(e.tr.delete(n.before(o),n.after(o)).scrollIntoView()),!0;return!1}function $m(e,t){const n=e.selection;if(!(n instanceof hn))return!1;if(t){const o=e.tr,r=Wr(e.schema).cell.createAndFill().content;n.forEachCell((s,i)=>{s.content.eq(r)||o.replace(o.mapping.map(i+1),o.mapping.map(i+s.nodeSize-1),new Ye(r,0,0))}),o.docChanged&&t(o)}return!0}function Ake(e){if(!e.size)return null;let{content:t,openStart:n,openEnd:o}=e;for(;t.childCount==1&&(n>0&&o>0||t.child(0).type.spec.tableRole=="table");)n--,o--,t=t.child(0).content;const r=t.child(0),s=r.type.spec.tableRole,i=r.type.schema,l=[];if(s=="row")for(let a=0;a<t.childCount;a++){let u=t.child(a).content;const c=a?0:Math.max(0,n-1),d=a<t.childCount-1?0:Math.max(0,o-1);(c||d)&&(u=_2(Wr(i).row,new Ye(u,c,d)).content),l.push(u)}else if(s=="cell"||s=="header_cell")l.push(n||o?_2(Wr(i).row,new Ye(t,n,o)).content:t);else return null;return Nke(i,l)}function Nke(e,t){const n=[];for(let r=0;r<t.length;r++){const s=t[r];for(let i=s.childCount-1;i>=0;i--){const{rowspan:l,colspan:a}=s.child(i).attrs;for(let u=r;u<r+l;u++)n[u]=(n[u]||0)+a}}let o=0;for(let r=0;r<n.length;r++)o=Math.max(o,n[r]);for(let r=0;r<n.length;r++)if(r>=t.length&&t.push(Ue.empty),n[r]<o){const s=Wr(e).cell.createAndFill(),i=[];for(let l=n[r];l<o;l++)i.push(s);t[r]=t[r].append(Ue.from(i))}return{height:t.length,width:o,rows:t}}function _2(e,t){const n=e.createAndFill();return new mA(n).replace(0,n.content.size,t).doc}function Pke({width:e,height:t,rows:n},o,r){if(e!=o){const s=[],i=[];for(let l=0;l<n.length;l++){const a=n[l],u=[];for(let c=s[l]||0,d=0;c<o;d++){let f=a.child(d%a.childCount);c+f.attrs.colspan>o&&(f=f.type.createChecked(gu(f.attrs,f.attrs.colspan,c+f.attrs.colspan-o),f.content)),u.push(f),c+=f.attrs.colspan;for(let p=1;p<f.attrs.rowspan;p++)s[l+p]=(s[l+p]||0)+f.attrs.colspan}i.push(Ue.from(u))}n=i,e=o}if(t!=r){const s=[];for(let i=0,l=0;i<r;i++,l++){const a=[],u=n[l%t];for(let c=0;c<u.childCount;c++){let d=u.child(c);i+d.attrs.rowspan>r&&(d=d.type.create({...d.attrs,rowspan:Math.max(1,r-d.attrs.rowspan)},d.content)),a.push(d)}s.push(Ue.from(a))}n=s,t=r}return{width:e,height:t,rows:n}}function Lke(e,t,n,o,r,s,i){const l=e.doc.type.schema,a=Wr(l);let u,c;if(r>t.width)for(let d=0,f=0;d<t.height;d++){const p=n.child(d);f+=p.nodeSize;const h=[];let m;p.lastChild==null||p.lastChild.type==a.cell?m=u||(u=a.cell.createAndFill()):m=c||(c=a.header_cell.createAndFill());for(let y=t.width;y<r;y++)h.push(m);e.insert(e.mapping.slice(i).map(f-1+o),h)}if(s>t.height){const d=[];for(let h=0,m=(t.height-1)*t.width;h<Math.max(t.width,r);h++){const y=h>=t.width?!1:n.nodeAt(t.map[m+h]).type==a.header_cell;d.push(y?c||(c=a.header_cell.createAndFill()):u||(u=a.cell.createAndFill()))}const f=a.row.create(null,Ue.from(d)),p=[];for(let h=t.height;h<s;h++)p.push(f);e.insert(e.mapping.slice(i).map(o+n.nodeSize-2),p)}return!!(u||c)}function N9(e,t,n,o,r,s,i,l){if(i==0||i==t.height)return!1;let a=!1;for(let u=r;u<s;u++){const c=i*t.width+u,d=t.map[c];if(t.map[c-t.width]==d){a=!0;const f=n.nodeAt(d),{top:p,left:h}=t.findCell(d);e.setNodeMarkup(e.mapping.slice(l).map(d+o),null,{...f.attrs,rowspan:i-p}),e.insert(e.mapping.slice(l).map(t.positionAt(i,h,n)),f.type.createAndFill({...f.attrs,rowspan:p+f.attrs.rowspan-i})),u+=f.attrs.colspan-1}}return a}function P9(e,t,n,o,r,s,i,l){if(i==0||i==t.width)return!1;let a=!1;for(let u=r;u<s;u++){const c=u*t.width+i,d=t.map[c];if(t.map[c-1]==d){a=!0;const f=n.nodeAt(d),p=t.colCount(d),h=e.mapping.slice(l).map(d+o);e.setNodeMarkup(h,null,gu(f.attrs,i-p,f.attrs.colspan-(i-p))),e.insert(h+f.nodeSize,f.type.createAndFill(gu(f.attrs,0,i-p))),u+=f.attrs.rowspan-1}}return a}function L9(e,t,n,o,r){let s=n?e.doc.nodeAt(n-1):e.doc;if(!s)throw new Error("No table found");let i=Xt.get(s);const{top:l,left:a}=o,u=a+r.width,c=l+r.height,d=e.tr;let f=0;function p(){if(s=n?d.doc.nodeAt(n-1):d.doc,!s)throw new Error("No table found");i=Xt.get(s),f=d.mapping.maps.length}Lke(d,i,s,n,u,c,f)&&p(),N9(d,i,s,n,a,u,l,f)&&p(),N9(d,i,s,n,a,u,c,f)&&p(),P9(d,i,s,n,l,c,a,f)&&p(),P9(d,i,s,n,l,c,u,f)&&p();for(let h=l;h<c;h++){const m=i.positionAt(h,a,s),y=i.positionAt(h,u,s);d.replace(d.mapping.slice(f).map(m+n),d.mapping.slice(f).map(y+n),new Ye(r.rows[h-l],0,0))}p(),d.setSelection(new hn(d.doc.resolve(n+i.positionAt(l,a,s)),d.doc.resolve(n+i.positionAt(c-1,u-1,s)))),t(d)}var Rke=AA({ArrowLeft:Em("horiz",-1),ArrowRight:Em("horiz",1),ArrowUp:Em("vert",-1),ArrowDown:Em("vert",1),"Shift-ArrowLeft":xm("horiz",-1),"Shift-ArrowRight":xm("horiz",1),"Shift-ArrowUp":xm("vert",-1),"Shift-ArrowDown":xm("vert",1),Backspace:$m,"Mod-Backspace":$m,Delete:$m,"Mod-Delete":$m});function R1(e,t,n){return n.eq(e.selection)?!1:(t&&t(e.tr.setSelection(n).scrollIntoView()),!0)}function Em(e,t){return(n,o,r)=>{if(!r)return!1;const s=n.selection;if(s instanceof hn)return R1(n,o,bt.near(s.$headCell,t));if(e!="horiz"&&!s.empty)return!1;const i=eP(r,e,t);if(i==null)return!1;if(e=="horiz")return R1(n,o,bt.near(n.doc.resolve(s.head+t),t));{const l=n.doc.resolve(i),a=YN(l,e,t);let u;return a?u=bt.near(a,1):t<0?u=bt.near(n.doc.resolve(l.before(-1)),-1):u=bt.near(n.doc.resolve(l.after(-1)),1),R1(n,o,u)}}}function xm(e,t){return(n,o,r)=>{if(!r)return!1;const s=n.selection;let i;if(s instanceof hn)i=s;else{const a=eP(r,e,t);if(a==null)return!1;i=new hn(n.doc.resolve(a))}const l=YN(i.$headCell,e,t);return l?R1(n,o,new hn(i.$anchorCell,l)):!1}}function Dke(e,t){const n=e.state.doc,o=Ph(n.resolve(t));return o?(e.dispatch(e.state.tr.setSelection(new hn(o))),!0):!1}function Fke(e,t,n){if(!Yr(e.state))return!1;let o=Ake(n);const r=e.state.selection;if(r instanceof hn){o||(o={width:1,height:1,rows:[Ue.from(_2(Wr(e.state.schema).cell,n))]});const s=r.$anchorCell.node(-1),i=r.$anchorCell.start(-1),l=Xt.get(s).rectBetween(r.$anchorCell.pos-i,r.$headCell.pos-i);return o=Pke(o,l.right-l.left,l.bottom-l.top),L9(e.state,e.dispatch,i,l,o),!0}else if(o){const s=bv(e.state),i=s.start(-1);return L9(e.state,e.dispatch,i,Xt.get(s.node(-1)).findCell(s.pos-i),o),!0}else return!1}function Vke(e,t){var n;if(t.ctrlKey||t.metaKey)return;const o=R9(e,t.target);let r;if(t.shiftKey&&e.state.selection instanceof hn)s(e.state.selection.$anchorCell,t),t.preventDefault();else if(t.shiftKey&&o&&(r=Ph(e.state.selection.$anchor))!=null&&((n=qy(e,t))==null?void 0:n.pos)!=r.pos)s(r,t),t.preventDefault();else if(!o)return;function s(a,u){let c=qy(e,u);const d=$l.getState(e.state)==null;if(!c||!pk(a,c))if(d)c=a;else return;const f=new hn(a,c);if(d||!e.state.selection.eq(f)){const p=e.state.tr.setSelection(f);d&&p.setMeta($l,a.pos),e.dispatch(p)}}function i(){e.root.removeEventListener("mouseup",i),e.root.removeEventListener("dragstart",i),e.root.removeEventListener("mousemove",l),$l.getState(e.state)!=null&&e.dispatch(e.state.tr.setMeta($l,-1))}function l(a){const u=a,c=$l.getState(e.state);let d;if(c!=null)d=e.state.doc.resolve(c);else if(R9(e,u.target)!=o&&(d=qy(e,t),!d))return i();d&&s(d,u)}e.root.addEventListener("mouseup",i),e.root.addEventListener("dragstart",i),e.root.addEventListener("mousemove",l)}function eP(e,t,n){if(!(e.state.selection instanceof ht))return null;const{$head:o}=e.state.selection;for(let r=o.depth-1;r>=0;r--){const s=o.node(r);if((n<0?o.index(r):o.indexAfter(r))!=(n<0?0:s.childCount))return null;if(s.type.spec.tableRole=="cell"||s.type.spec.tableRole=="header_cell"){const l=o.before(r),a=t=="vert"?n>0?"down":"up":n>0?"right":"left";return e.endOfTextblock(a)?l:null}}return null}function R9(e,t){for(;t&&t!=e.dom;t=t.parentNode)if(t.nodeName=="TD"||t.nodeName=="TH")return t;return null}function qy(e,t){const n=e.posAtCoords({left:t.clientX,top:t.clientY});return n&&n?Ph(e.state.doc.resolve(n.pos)):null}var Bke=class{constructor(e,t){this.node=e,this.cellMinWidth=t,this.dom=document.createElement("div"),this.dom.className="tableWrapper",this.table=this.dom.appendChild(document.createElement("table")),this.colgroup=this.table.appendChild(document.createElement("colgroup")),b2(e,this.colgroup,this.table,t),this.contentDOM=this.table.appendChild(document.createElement("tbody"))}update(e){return e.type!=this.node.type?!1:(this.node=e,b2(e,this.colgroup,this.table,this.cellMinWidth),!0)}ignoreMutation(e){return e.type=="attributes"&&(e.target==this.table||this.colgroup.contains(e.target))}};function b2(e,t,n,o,r,s){var i;let l=0,a=!0,u=t.firstChild;const c=e.firstChild;if(c){for(let d=0,f=0;d<c.childCount;d++){const{colspan:p,colwidth:h}=c.child(d).attrs;for(let m=0;m<p;m++,f++){const y=r==f?s:h&&h[m],v=y?y+"px":"";l+=y||o,y||(a=!1),u?(u.style.width!=v&&(u.style.width=v),u=u.nextSibling):t.appendChild(document.createElement("col")).style.width=v}}for(;u;){const d=u.nextSibling;(i=u.parentNode)==null||i.removeChild(u),u=d}a?(n.style.width=l+"px",n.style.minWidth=""):(n.style.width="",n.style.minWidth=l+"px")}}var Or=new wn("tableColumnResizing");function zke({handleWidth:e=5,cellMinWidth:t=25,View:n=Bke,lastColumnResizable:o=!0}={}){const r=new xn({key:Or,state:{init(s,i){var l,a;const u=(a=(l=r.spec)==null?void 0:l.props)==null?void 0:a.nodeViews,c=Wr(i.schema).table.name;return n&&u&&(u[c]=(d,f)=>new n(d,t,f)),new jke(-1,!1)},apply(s,i){return i.apply(s)}},props:{attributes:s=>{const i=Or.getState(s);return i&&i.activeHandle>-1?{class:"resize-cursor"}:{}},handleDOMEvents:{mousemove:(s,i)=>{Hke(s,i,e,t,o)},mouseleave:s=>{Uke(s)},mousedown:(s,i)=>{Wke(s,i,t)}},decorations:s=>{const i=Or.getState(s);if(i&&i.activeHandle>-1)return Jke(s,i.activeHandle)},nodeViews:{}}});return r}var jke=class D1{constructor(t,n){this.activeHandle=t,this.dragging=n}apply(t){const n=this,o=t.getMeta(Or);if(o&&o.setHandle!=null)return new D1(o.setHandle,!1);if(o&&o.setDragging!==void 0)return new D1(n.activeHandle,o.setDragging);if(n.activeHandle>-1&&t.docChanged){let r=t.mapping.map(n.activeHandle,-1);return y2(t.doc.resolve(r))||(r=-1),new D1(r,n.dragging)}return n}};function Hke(e,t,n,o,r){const s=Or.getState(e.state);if(s&&!s.dragging){const i=qke(t.target);let l=-1;if(i){const{left:a,right:u}=i.getBoundingClientRect();t.clientX-a<=n?l=D9(e,t,"left",n):u-t.clientX<=n&&(l=D9(e,t,"right",n))}if(l!=s.activeHandle){if(!r&&l!==-1){const a=e.state.doc.resolve(l),u=a.node(-1),c=Xt.get(u),d=a.start(-1);if(c.colCount(a.pos-d)+a.nodeAfter.attrs.colspan-1==c.width-1)return}tP(e,l)}}}function Uke(e){const t=Or.getState(e.state);t&&t.activeHandle>-1&&!t.dragging&&tP(e,-1)}function Wke(e,t,n){var o;const r=(o=e.dom.ownerDocument.defaultView)!=null?o:window,s=Or.getState(e.state);if(!s||s.activeHandle==-1||s.dragging)return!1;const i=e.state.doc.nodeAt(s.activeHandle),l=Kke(e,s.activeHandle,i.attrs);e.dispatch(e.state.tr.setMeta(Or,{setDragging:{startX:t.clientX,startWidth:l}}));function a(c){r.removeEventListener("mouseup",a),r.removeEventListener("mousemove",u);const d=Or.getState(e.state);d!=null&&d.dragging&&(Gke(e,d.activeHandle,F9(d.dragging,c,n)),e.dispatch(e.state.tr.setMeta(Or,{setDragging:null})))}function u(c){if(!c.which)return a(c);const d=Or.getState(e.state);if(d&&d.dragging){const f=F9(d.dragging,c,n);Yke(e,d.activeHandle,f,n)}}return r.addEventListener("mouseup",a),r.addEventListener("mousemove",u),t.preventDefault(),!0}function Kke(e,t,{colspan:n,colwidth:o}){const r=o&&o[o.length-1];if(r)return r;const s=e.domAtPos(t);let l=s.node.childNodes[s.offset].offsetWidth,a=n;if(o)for(let u=0;u<n;u++)o[u]&&(l-=o[u],a--);return l/a}function qke(e){for(;e&&e.nodeName!="TD"&&e.nodeName!="TH";)e=e.classList&&e.classList.contains("ProseMirror")?null:e.parentNode;return e}function D9(e,t,n,o){const r=n=="right"?-o:o,s=e.posAtCoords({left:t.clientX+r,top:t.clientY});if(!s)return-1;const{pos:i}=s,l=Ph(e.state.doc.resolve(i));if(!l)return-1;if(n=="right")return l.pos;const a=Xt.get(l.node(-1)),u=l.start(-1),c=a.map.indexOf(l.pos-u);return c%a.width==0?-1:u+a.map[c-1]}function F9(e,t,n){const o=t.clientX-e.startX;return Math.max(n,e.startWidth+o)}function tP(e,t){e.dispatch(e.state.tr.setMeta(Or,{setHandle:t}))}function Gke(e,t,n){const o=e.state.doc.resolve(t),r=o.node(-1),s=Xt.get(r),i=o.start(-1),l=s.colCount(o.pos-i)+o.nodeAfter.attrs.colspan-1,a=e.state.tr;for(let u=0;u<s.height;u++){const c=u*s.width+l;if(u&&s.map[c]==s.map[c-s.width])continue;const d=s.map[c],f=r.nodeAt(d).attrs,p=f.colspan==1?0:l-s.colCount(d);if(f.colwidth&&f.colwidth[p]==n)continue;const h=f.colwidth?f.colwidth.slice():Zke(f.colspan);h[p]=n,a.setNodeMarkup(i+d,null,{...f,colwidth:h})}a.docChanged&&e.dispatch(a)}function Yke(e,t,n,o){const r=e.state.doc.resolve(t),s=r.node(-1),i=r.start(-1),l=Xt.get(s).colCount(r.pos-i)+r.nodeAfter.attrs.colspan-1;let a=e.domAtPos(r.start(-1)).node;for(;a&&a.nodeName!="TABLE";)a=a.parentNode;a&&b2(s,a.firstChild,a,o,l,n)}function Zke(e){return Array(e).fill(0)}function Jke(e,t){const n=[],o=e.doc.resolve(t),r=o.node(-1);if(!r)return an.empty;const s=Xt.get(r),i=o.start(-1),l=s.colCount(o.pos-i)+o.nodeAfter.attrs.colspan-1;for(let a=0;a<s.height;a++){const u=l+a*s.width;if((l==s.width-1||s.map[u]!=s.map[u+1])&&(a==0||s.map[u]!=s.map[u-s.width])){const c=s.map[u],d=i+c+r.nodeAt(c).nodeSize-1,f=document.createElement("div");f.className="column-resize-handle",n.push(zn.widget(d,f))}}return an.create(e.doc,n)}function Xke({allowTableNodeSelection:e=!1}={}){return new xn({key:$l,state:{init(){return null},apply(t,n){const o=t.getMeta($l);if(o!=null)return o==-1?null:o;if(n==null||!t.docChanged)return n;const{deleted:r,pos:s}=t.mapping.mapResult(n);return r?null:s}},props:{decorations:mke,handleDOMEvents:{mousedown:Vke},createSelectionBetween(t){return $l.getState(t.state)!=null?t.state.selection:null},handleTripleClick:Dke,handleKeyDown:Rke,handlePaste:Fke},appendTransaction(t,n,o){return yke(o,bke(o,n),e)}})}var n0=typeof navigator<"u"?navigator:null,mk=n0&&n0.userAgent||"",Qke=/Edge\/(\d+)/.exec(mk),e4e=/MSIE \d/.exec(mk),t4e=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(mk),n4e=!!(e4e||t4e||Qke),o4e=!n4e&&!!n0&&/Apple Computer/.test(n0.vendor),nP=new wn("safari-ime-span"),w2=!1,r4e={key:nP,props:{decorations:s4e,handleDOMEvents:{compositionstart:()=>{w2=!0},compositionend:()=>{w2=!1}}}};function s4e(e){const{$from:t,$to:n,to:o}=e.selection;if(w2&&t.sameParent(n)){const r=zn.widget(o,i4e,{ignoreSelection:!0,key:"safari-ime-span"});return an.create(e.doc,[r])}}function i4e(e){const t=e.dom.ownerDocument.createElement("span");return t.className="ProseMirror-safari-ime-span",t}var l4e=new xn(o4e?r4e:{key:nP});function V9(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let o=0,r=n.indexOf(t);for(;r!==-1;)o++,r=n.indexOf(t,r+t.length);return o}function a4e(e,t,n){const r=nv((n||{}).ignore||[]),s=u4e(t);let i=-1;for(;++i<s.length;)HI(e,"text",l);function l(u,c){let d=-1,f;for(;++d<c.length;){const p=c[d],h=f?f.children:void 0;if(r(p,h?h.indexOf(p):void 0,f))return;f=p}if(f)return a(u,c)}function a(u,c){const d=c[c.length-1],f=s[i][0],p=s[i][1];let h=0;const y=d.children.indexOf(u);let v=!1,w=[];f.lastIndex=0;let _=f.exec(u.value);for(;_;){const S=_.index,x={index:_.index,input:_.input,stack:[...c,u]};let E=p(..._,x);if(typeof E=="string"&&(E=E.length>0?{type:"text",value:E}:void 0),E===!1?f.lastIndex=S+1:(h!==S&&w.push({type:"text",value:u.value.slice(h,S)}),Array.isArray(E)?w.push(...E):E&&w.push(E),h=S+_[0].length,v=!0),!f.global)break;_=f.exec(u.value)}return v?(h<u.value.length&&w.push({type:"text",value:u.value.slice(h)}),d.children.splice(y,1,...w)):w=[u],y+w.length}}function u4e(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const n=!e[0]||Array.isArray(e[0])?e:[e];let o=-1;for(;++o<n.length;){const r=n[o];t.push([c4e(r[0]),d4e(r[1])])}return t}function c4e(e){return typeof e=="string"?new RegExp(mv(e),"g"):e}function d4e(e){return typeof e=="function"?e:function(){return e}}const Gy="phrasing",Yy=["autolink","link","image","label"];function f4e(){return{transforms:[_4e],enter:{literalAutolink:h4e,literalAutolinkEmail:Zy,literalAutolinkHttp:Zy,literalAutolinkWww:Zy},exit:{literalAutolink:y4e,literalAutolinkEmail:v4e,literalAutolinkHttp:m4e,literalAutolinkWww:g4e}}}function p4e(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Gy,notInConstruct:Yy},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Gy,notInConstruct:Yy},{character:":",before:"[ps]",after:"\\/",inConstruct:Gy,notInConstruct:Yy}]}}function h4e(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function Zy(e){this.config.enter.autolinkProtocol.call(this,e)}function m4e(e){this.config.exit.autolinkProtocol.call(this,e)}function g4e(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.type,t.url="http://"+this.sliceSerialize(e)}function v4e(e){this.config.exit.autolinkEmail.call(this,e)}function y4e(e){this.exit(e)}function _4e(e){a4e(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,b4e],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),w4e]],{ignore:["link","linkReference"]})}function b4e(e,t,n,o,r){let s="";if(!oP(r)||(/^w/i.test(t)&&(n=t+n,t="",s="http://"),!C4e(n)))return!1;const i=k4e(n+o);if(!i[0])return!1;const l={type:"link",title:null,url:s+t+i[0],children:[{type:"text",value:t+i[0]}]};return i[1]?[l,{type:"text",value:i[1]}]:l}function w4e(e,t,n,o){return!oP(o,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function C4e(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function k4e(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],o=n.indexOf(")");const r=V9(e,"(");let s=V9(e,")");for(;o!==-1&&r>s;)e+=n.slice(0,o+1),n=n.slice(o+1),o=n.indexOf(")"),s++;return[e,n]}function oP(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||pu(n)||ev(n))&&(!t||n!==47)}rP.peek=P4e;function S4e(){return{enter:{gfmFootnoteDefinition:E4e,gfmFootnoteDefinitionLabelString:x4e,gfmFootnoteCall:O4e,gfmFootnoteCallString:I4e},exit:{gfmFootnoteDefinition:T4e,gfmFootnoteDefinitionLabelString:M4e,gfmFootnoteCall:N4e,gfmFootnoteCallString:A4e}}}function $4e(){return{unsafe:[{character:"[",inConstruct:["phrasing","label","reference"]}],handlers:{footnoteDefinition:L4e,footnoteReference:rP}}}function E4e(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function x4e(){this.buffer()}function M4e(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=t,n.identifier=cs(this.sliceSerialize(e)).toLowerCase()}function T4e(e){this.exit(e)}function O4e(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function I4e(){this.buffer()}function A4e(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=t,n.identifier=cs(this.sliceSerialize(e)).toLowerCase()}function N4e(e){this.exit(e)}function rP(e,t,n,o){const r=n.createTracker(o);let s=r.move("[^");const i=n.enter("footnoteReference"),l=n.enter("reference");return s+=r.move(n.safe(n.associationId(e),{...r.current(),before:s,after:"]"})),l(),i(),s+=r.move("]"),s}function P4e(){return"["}function L4e(e,t,n,o){const r=n.createTracker(o);let s=r.move("[^");const i=n.enter("footnoteDefinition"),l=n.enter("label");return s+=r.move(n.safe(n.associationId(e),{...r.current(),before:s,after:"]"})),l(),s+=r.move("]:"+(e.children&&e.children.length>0?" ":"")),r.shift(4),s+=r.move(n.indentLines(n.containerFlow(e,r.current()),R4e)),i(),s}function R4e(e,t,n){return t===0?e:(n?"":" ")+e}const D4e=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];sP.peek=j4e;function F4e(){return{canContainEols:["delete"],enter:{strikethrough:B4e},exit:{strikethrough:z4e}}}function V4e(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:D4e}],handlers:{delete:sP}}}function B4e(e){this.enter({type:"delete",children:[]},e)}function z4e(e){this.exit(e)}function sP(e,t,n,o){const r=n.createTracker(o),s=n.enter("strikethrough");let i=r.move("~~");return i+=n.containerPhrasing(e,{...r.current(),before:i,after:"~"}),i+=r.move("~~"),s(),i}function j4e(){return"~"}function H4e(e,t={}){const n=(t.align||[]).concat(),o=t.stringLength||W4e,r=[],s=[],i=[],l=[];let a=0,u=-1;for(;++u<e.length;){const h=[],m=[];let y=-1;for(e[u].length>a&&(a=e[u].length);++y<e[u].length;){const v=U4e(e[u][y]);if(t.alignDelimiters!==!1){const w=o(v);m[y]=w,(l[y]===void 0||w>l[y])&&(l[y]=w)}h.push(v)}s[u]=h,i[u]=m}let c=-1;if(typeof n=="object"&&"length"in n)for(;++c<a;)r[c]=B9(n[c]);else{const h=B9(n);for(;++c<a;)r[c]=h}c=-1;const d=[],f=[];for(;++c<a;){const h=r[c];let m="",y="";h===99?(m=":",y=":"):h===108?m=":":h===114&&(y=":");let v=t.alignDelimiters===!1?1:Math.max(1,l[c]-m.length-y.length);const w=m+"-".repeat(v)+y;t.alignDelimiters!==!1&&(v=m.length+v+y.length,v>l[c]&&(l[c]=v),f[c]=v),d[c]=w}s.splice(1,0,d),i.splice(1,0,f),u=-1;const p=[];for(;++u<s.length;){const h=s[u],m=i[u];c=-1;const y=[];for(;++c<a;){const v=h[c]||"";let w="",_="";if(t.alignDelimiters!==!1){const S=l[c]-(m[c]||0),x=r[c];x===114?w=" ".repeat(S):x===99?S%2?(w=" ".repeat(S/2+.5),_=" ".repeat(S/2-.5)):(w=" ".repeat(S/2),_=w):_=" ".repeat(S)}t.delimiterStart!==!1&&!c&&y.push("|"),t.padding!==!1&&!(t.alignDelimiters===!1&&v==="")&&(t.delimiterStart!==!1||c)&&y.push(" "),t.alignDelimiters!==!1&&y.push(w),y.push(v),t.alignDelimiters!==!1&&y.push(_),t.padding!==!1&&y.push(" "),(t.delimiterEnd!==!1||c!==a-1)&&y.push("|")}p.push(t.delimiterEnd===!1?y.join("").replace(/ +$/,""):y.join(""))}return p.join(`
121 `)}function U4e(e){return e==null?"":String(e)}function W4e(e){return e.length}function B9(e){const t=typeof e=="string"?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}function K4e(){return{enter:{table:q4e,tableData:z9,tableHeader:z9,tableRow:Y4e},exit:{codeText:Z4e,table:G4e,tableData:Jy,tableHeader:Jy,tableRow:Jy}}}function q4e(e){const t=e._align;this.enter({type:"table",align:t.map(function(n){return n==="none"?null:n}),children:[]},e),this.data.inTable=!0}function G4e(e){this.exit(e),this.data.inTable=void 0}function Y4e(e){this.enter({type:"tableRow",children:[]},e)}function Jy(e){this.exit(e)}function z9(e){this.enter({type:"tableCell",children:[]},e)}function Z4e(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,J4e));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function J4e(e,t){return t==="|"?t:e}function X4e(e){const t=e||{},n=t.tableCellPadding,o=t.tablePipeAlign,r=t.stringLength,s=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
122 `,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:f,table:i,tableCell:a,tableRow:l}};function i(p,h,m,y){return u(c(p,m,y),p.align)}function l(p,h,m,y){const v=d(p,m,y),w=u([v]);return w.slice(0,w.indexOf(`
123 `))}function a(p,h,m,y){const v=m.enter("tableCell"),w=m.enter("phrasing"),_=m.containerPhrasing(p,{...y,before:s,after:s});return w(),v(),_}function u(p,h){return H4e(p,{align:h,alignDelimiters:o,padding:n,stringLength:r})}function c(p,h,m){const y=p.children;let v=-1;const w=[],_=h.enter("table");for(;++v<y.length;)w[v]=d(y[v],h,m);return _(),w}function d(p,h,m){const y=p.children;let v=-1;const w=[],_=h.enter("tableRow");for(;++v<y.length;)w[v]=a(y[v],p,h,m);return _(),w}function f(p,h,m){let y=oC.inlineCode(p,h,m);return m.stack.includes("tableCell")&&(y=y.replace(/\|/g,"\\$&")),y}}function Q4e(){return{exit:{taskListCheckValueChecked:j9,taskListCheckValueUnchecked:j9,paragraph:t6e}}}function e6e(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:n6e}}}function j9(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function t6e(e){const t=this.stack[this.stack.length-2];if(t&&t.type==="listItem"&&typeof t.checked=="boolean"){const n=this.stack[this.stack.length-1];n.type;const o=n.children[0];if(o&&o.type==="text"){const r=t.children;let s=-1,i;for(;++s<r.length;){const l=r[s];if(l.type==="paragraph"){i=l;break}}i===n&&(o.value=o.value.slice(1),o.value.length===0?n.children.shift():n.position&&o.position&&typeof o.position.start.offset=="number"&&(o.position.start.column++,o.position.start.offset++,n.position.start=Object.assign({},o.position.start)))}}this.exit(e)}function n6e(e,t,n,o){const r=e.children[0],s=typeof e.checked=="boolean"&&r&&r.type==="paragraph",i="["+(e.checked?"x":" ")+"] ",l=n.createTracker(o);s&&l.move(i);let a=oC.listItem(e,t,n,{...o,...l.current()});return s&&(a=a.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,u)),a;function u(c){return c+i}}function o6e(){return[f4e(),S4e(),F4e(),K4e(),Q4e()]}function r6e(e){return{extensions:[p4e(),$4e(),V4e(),X4e(e),e6e()]}}const s6e={tokenize:d6e,partial:!0},iP={tokenize:f6e,partial:!0},lP={tokenize:p6e,partial:!0},aP={tokenize:h6e,partial:!0},i6e={tokenize:m6e,partial:!0},uP={name:"wwwAutolink",tokenize:u6e,previous:dP},cP={name:"protocolAutolink",tokenize:c6e,previous:fP},Hi={name:"emailAutolink",tokenize:a6e,previous:pP},li={};function l6e(){return{text:li}}let pa=48;for(;pa<123;)li[pa]=Hi,pa++,pa===58?pa=65:pa===91&&(pa=97);li[43]=Hi;li[45]=Hi;li[46]=Hi;li[95]=Hi;li[72]=[Hi,cP];li[104]=[Hi,cP];li[87]=[Hi,uP];li[119]=[Hi,uP];function a6e(e,t,n){const o=this;let r,s;return i;function i(d){return!C2(d)||!pP.call(o,o.previous)||gk(o.events)?n(d):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),l(d))}function l(d){return C2(d)?(e.consume(d),l):d===64?(e.consume(d),a):n(d)}function a(d){return d===46?e.check(i6e,c,u)(d):d===45||d===95||Wo(d)?(s=!0,e.consume(d),a):c(d)}function u(d){return e.consume(d),r=!0,a}function c(d){return s&&r&&Eo(o.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(d)):n(d)}}function u6e(e,t,n){const o=this;return r;function r(i){return i!==87&&i!==119||!dP.call(o,o.previous)||gk(o.events)?n(i):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(s6e,e.attempt(iP,e.attempt(lP,s),n),n)(i))}function s(i){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(i)}}function c6e(e,t,n){const o=this;let r="",s=!1;return i;function i(d){return(d===72||d===104)&&fP.call(o,o.previous)&&!gk(o.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),r+=String.fromCodePoint(d),e.consume(d),l):n(d)}function l(d){if(Eo(d)&&r.length<5)return r+=String.fromCodePoint(d),e.consume(d),l;if(d===58){const f=r.toLowerCase();if(f==="http"||f==="https")return e.consume(d),a}return n(d)}function a(d){return d===47?(e.consume(d),s?u:(s=!0,a)):n(d)}function u(d){return d===null||qg(d)||nn(d)||pu(d)||ev(d)?n(d):e.attempt(iP,e.attempt(lP,c),n)(d)}function c(d){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(d)}}function d6e(e,t,n){let o=0;return r;function r(i){return(i===87||i===119)&&o<3?(o++,e.consume(i),r):i===46&&o===3?(e.consume(i),s):n(i)}function s(i){return i===null?n(i):t(i)}}function f6e(e,t,n){let o,r,s;return i;function i(u){return u===46||u===95?e.check(aP,a,l)(u):u===null||nn(u)||pu(u)||u!==45&&ev(u)?a(u):(s=!0,e.consume(u),i)}function l(u){return u===95?o=!0:(r=o,o=void 0),e.consume(u),i}function a(u){return r||o||!s?n(u):t(u)}}function p6e(e,t){let n=0,o=0;return r;function r(i){return i===40?(n++,e.consume(i),r):i===41&&o<n?s(i):i===33||i===34||i===38||i===39||i===41||i===42||i===44||i===46||i===58||i===59||i===60||i===63||i===93||i===95||i===126?e.check(aP,t,s)(i):i===null||nn(i)||pu(i)?t(i):(e.consume(i),r)}function s(i){return i===41&&o++,e.consume(i),r}}function h6e(e,t,n){return o;function o(l){return l===33||l===34||l===39||l===41||l===42||l===44||l===46||l===58||l===59||l===63||l===95||l===126?(e.consume(l),o):l===38?(e.consume(l),s):l===93?(e.consume(l),r):l===60||l===null||nn(l)||pu(l)?t(l):n(l)}function r(l){return l===null||l===40||l===91||nn(l)||pu(l)?t(l):o(l)}function s(l){return Eo(l)?i(l):n(l)}function i(l){return l===59?(e.consume(l),o):Eo(l)?(e.consume(l),i):n(l)}}function m6e(e,t,n){return o;function o(s){return e.consume(s),r}function r(s){return Wo(s)?n(s):t(s)}}function dP(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||nn(e)}function fP(e){return!Eo(e)}function pP(e){return!(e===47||C2(e))}function C2(e){return e===43||e===45||e===46||e===95||Wo(e)}function gk(e){let t=e.length,n=!1;for(;t--;){const o=e[t][1];if((o.type==="labelLink"||o.type==="labelImage")&&!o._balanced){n=!0;break}if(o._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}const g6e={tokenize:S6e,partial:!0};function v6e(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:w6e,continuation:{tokenize:C6e},exit:k6e}},text:{91:{name:"gfmFootnoteCall",tokenize:b6e},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:y6e,resolveTo:_6e}}}}function y6e(e,t,n){const o=this;let r=o.events.length;const s=o.parser.gfmFootnotes||(o.parser.gfmFootnotes=[]);let i;for(;r--;){const a=o.events[r][1];if(a.type==="labelImage"){i=a;break}if(a.type==="gfmFootnoteCall"||a.type==="labelLink"||a.type==="label"||a.type==="image"||a.type==="link")break}return l;function l(a){if(!i||!i._balanced)return n(a);const u=cs(o.sliceSerialize({start:i.end,end:o.now()}));return u.codePointAt(0)!==94||!s.includes(u.slice(1))?n(a):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(a),e.exit("gfmFootnoteCallLabelMarker"),t(a))}}function _6e(e,t){let n=e.length;for(;n--;)if(e[n][1].type==="labelImage"&&e[n][0]==="enter"){e[n][1];break}e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const o={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},r={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};r.end.column++,r.end.offset++,r.end._bufferIndex++;const s={type:"gfmFootnoteCallString",start:Object.assign({},r.end),end:Object.assign({},e[e.length-1][1].start)},i={type:"chunkString",contentType:"string",start:Object.assign({},s.start),end:Object.assign({},s.end)},l=[e[n+1],e[n+2],["enter",o,t],e[n+3],e[n+4],["enter",r,t],["exit",r,t],["enter",s,t],["enter",i,t],["exit",i,t],["exit",s,t],e[e.length-2],e[e.length-1],["exit",o,t]];return e.splice(n,e.length-n+1,...l),e}function b6e(e,t,n){const o=this,r=o.parser.gfmFootnotes||(o.parser.gfmFootnotes=[]);let s=0,i;return l;function l(d){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),a}function a(d){return d!==94?n(d):(e.enter("gfmFootnoteCallMarker"),e.consume(d),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",u)}function u(d){if(s>999||d===93&&!i||d===null||d===91||nn(d))return n(d);if(d===93){e.exit("chunkString");const f=e.exit("gfmFootnoteCallString");return r.includes(cs(o.sliceSerialize(f)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(d)}return nn(d)||(i=!0),s++,e.consume(d),d===92?c:u}function c(d){return d===91||d===92||d===93?(e.consume(d),s++,u):u(d)}}function w6e(e,t,n){const o=this,r=o.parser.gfmFootnotes||(o.parser.gfmFootnotes=[]);let s,i=0,l;return a;function a(h){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(h),e.exit("gfmFootnoteDefinitionLabelMarker"),u}function u(h){return h===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(h),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",c):n(h)}function c(h){if(i>999||h===93&&!l||h===null||h===91||nn(h))return n(h);if(h===93){e.exit("chunkString");const m=e.exit("gfmFootnoteDefinitionLabelString");return s=cs(o.sliceSerialize(m)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(h),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),f}return nn(h)||(l=!0),i++,e.consume(h),h===92?d:c}function d(h){return h===91||h===92||h===93?(e.consume(h),i++,c):c(h)}function f(h){return h===58?(e.enter("definitionMarker"),e.consume(h),e.exit("definitionMarker"),r.includes(s)||r.push(s),Vt(e,p,"gfmFootnoteDefinitionWhitespace")):n(h)}function p(h){return t(h)}}function C6e(e,t,n){return e.check($h,t,e.attempt(g6e,t,n))}function k6e(e){e.exit("gfmFootnoteDefinition")}function S6e(e,t,n){const o=this;return Vt(e,r,"gfmFootnoteDefinitionIndent",4+1);function r(s){const i=o.events[o.events.length-1];return i&&i[1].type==="gfmFootnoteDefinitionIndent"&&i[2].sliceSerialize(i[1],!0).length===4?t(s):n(s)}}function $6e(e){let n=(e||{}).singleTilde;const o={name:"strikethrough",tokenize:s,resolveAll:r};return n==null&&(n=!0),{text:{126:o},insideSpan:{null:[o]},attentionMarkers:{null:[126]}};function r(i,l){let a=-1;for(;++a<i.length;)if(i[a][0]==="enter"&&i[a][1].type==="strikethroughSequenceTemporary"&&i[a][1]._close){let u=a;for(;u--;)if(i[u][0]==="exit"&&i[u][1].type==="strikethroughSequenceTemporary"&&i[u][1]._open&&i[a][1].end.offset-i[a][1].start.offset===i[u][1].end.offset-i[u][1].start.offset){i[a][1].type="strikethroughSequence",i[u][1].type="strikethroughSequence";const c={type:"strikethrough",start:Object.assign({},i[u][1].start),end:Object.assign({},i[a][1].end)},d={type:"strikethroughText",start:Object.assign({},i[u][1].end),end:Object.assign({},i[a][1].start)},f=[["enter",c,l],["enter",i[u][1],l],["exit",i[u][1],l],["enter",d,l]],p=l.parser.constructs.insideSpan.null;p&&Rr(f,f.length,0,tv(p,i.slice(u+1,a),l)),Rr(f,f.length,0,[["exit",d,l],["enter",i[a][1],l],["exit",i[a][1],l],["exit",c,l]]),Rr(i,u-1,a-u+3,f),a=u+f.length-2;break}}for(a=-1;++a<i.length;)i[a][1].type==="strikethroughSequenceTemporary"&&(i[a][1].type="data");return i}function s(i,l,a){const u=this.previous,c=this.events;let d=0;return f;function f(h){return u===126&&c[c.length-1][1].type!=="characterEscape"?a(h):(i.enter("strikethroughSequenceTemporary"),p(h))}function p(h){const m=Gg(u);if(h===126)return d>1?a(h):(i.consume(h),d++,p);if(d<2&&!n)return a(h);const y=i.exit("strikethroughSequenceTemporary"),v=Gg(h);return y._open=!v||v===2&&!!m,y._close=!m||m===2&&!!v,l(h)}}}class E6e{constructor(){this.map=[]}add(t,n,o){x6e(this,t,n,o)}consume(t){if(this.map.sort(function(s,i){return s[0]-i[0]}),this.map.length===0)return;let n=this.map.length;const o=[];for(;n>0;)n-=1,o.push(t.slice(this.map[n][0]+this.map[n][1]),this.map[n][2]),t.length=this.map[n][0];o.push([...t]),t.length=0;let r=o.pop();for(;r;)t.push(...r),r=o.pop();this.map.length=0}}function x6e(e,t,n,o){let r=0;if(!(n===0&&o.length===0)){for(;r<e.map.length;){if(e.map[r][0]===t){e.map[r][1]+=n,e.map[r][2].push(...o);return}r+=1}e.map.push([t,n,o])}}function M6e(e,t){let n=!1;const o=[];for(;t<e.length;){const r=e[t];if(n){if(r[0]==="enter")r[1].type==="tableContent"&&o.push(e[t+1][1].type==="tableDelimiterMarker"?"left":"none");else if(r[1].type==="tableContent"){if(e[t-1][1].type==="tableDelimiterMarker"){const s=o.length-1;o[s]=o[s]==="left"?"center":"right"}}else if(r[1].type==="tableDelimiterRow")break}else r[0]==="enter"&&r[1].type==="tableDelimiterRow"&&(n=!0);t+=1}return o}function T6e(){return{flow:{null:{name:"table",tokenize:O6e,resolveAll:I6e}}}}function O6e(e,t,n){const o=this;let r=0,s=0,i;return l;function l(N){let F=o.events.length-1;for(;F>-1;){const Z=o.events[F][1].type;if(Z==="lineEnding"||Z==="linePrefix")F--;else break}const B=F>-1?o.events[F][1].type:null,Y=B==="tableHead"||B==="tableRow"?E:a;return Y===E&&o.parser.lazy[o.now().line]?n(N):Y(N)}function a(N){return e.enter("tableHead"),e.enter("tableRow"),u(N)}function u(N){return N===124||(i=!0,s+=1),c(N)}function c(N){return N===null?n(N):dt(N)?s>1?(s=0,o.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(N),e.exit("lineEnding"),p):n(N):Nt(N)?Vt(e,c,"whitespace")(N):(s+=1,i&&(i=!1,r+=1),N===124?(e.enter("tableCellDivider"),e.consume(N),e.exit("tableCellDivider"),i=!0,c):(e.enter("data"),d(N)))}function d(N){return N===null||N===124||nn(N)?(e.exit("data"),c(N)):(e.consume(N),N===92?f:d)}function f(N){return N===92||N===124?(e.consume(N),d):d(N)}function p(N){return o.interrupt=!1,o.parser.lazy[o.now().line]?n(N):(e.enter("tableDelimiterRow"),i=!1,Nt(N)?Vt(e,h,"linePrefix",o.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(N):h(N))}function h(N){return N===45||N===58?y(N):N===124?(i=!0,e.enter("tableCellDivider"),e.consume(N),e.exit("tableCellDivider"),m):x(N)}function m(N){return Nt(N)?Vt(e,y,"whitespace")(N):y(N)}function y(N){return N===58?(s+=1,i=!0,e.enter("tableDelimiterMarker"),e.consume(N),e.exit("tableDelimiterMarker"),v):N===45?(s+=1,v(N)):N===null||dt(N)?S(N):x(N)}function v(N){return N===45?(e.enter("tableDelimiterFiller"),w(N)):x(N)}function w(N){return N===45?(e.consume(N),w):N===58?(i=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(N),e.exit("tableDelimiterMarker"),_):(e.exit("tableDelimiterFiller"),_(N))}function _(N){return Nt(N)?Vt(e,S,"whitespace")(N):S(N)}function S(N){return N===124?h(N):N===null||dt(N)?!i||r!==s?x(N):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(N)):x(N)}function x(N){return n(N)}function E(N){return e.enter("tableRow"),T(N)}function T(N){return N===124?(e.enter("tableCellDivider"),e.consume(N),e.exit("tableCellDivider"),T):N===null||dt(N)?(e.exit("tableRow"),t(N)):Nt(N)?Vt(e,T,"whitespace")(N):(e.enter("data"),O(N))}function O(N){return N===null||N===124||nn(N)?(e.exit("data"),T(N)):(e.consume(N),N===92?P:O)}function P(N){return N===92||N===124?(e.consume(N),O):O(N)}}function I6e(e,t){let n=-1,o=!0,r=0,s=[0,0,0,0],i=[0,0,0,0],l=!1,a=0,u,c,d;const f=new E6e;for(;++n<e.length;){const p=e[n],h=p[1];p[0]==="enter"?h.type==="tableHead"?(l=!1,a!==0&&(H9(f,t,a,u,c),c=void 0,a=0),u={type:"table",start:Object.assign({},h.start),end:Object.assign({},h.end)},f.add(n,0,[["enter",u,t]])):h.type==="tableRow"||h.type==="tableDelimiterRow"?(o=!0,d=void 0,s=[0,0,0,0],i=[0,n+1,0,0],l&&(l=!1,c={type:"tableBody",start:Object.assign({},h.start),end:Object.assign({},h.end)},f.add(n,0,[["enter",c,t]])),r=h.type==="tableDelimiterRow"?2:c?3:1):r&&(h.type==="data"||h.type==="tableDelimiterMarker"||h.type==="tableDelimiterFiller")?(o=!1,i[2]===0&&(s[1]!==0&&(i[0]=i[1],d=Mm(f,t,s,r,void 0,d),s=[0,0,0,0]),i[2]=n)):h.type==="tableCellDivider"&&(o?o=!1:(s[1]!==0&&(i[0]=i[1],d=Mm(f,t,s,r,void 0,d)),s=i,i=[s[1],n,0,0])):h.type==="tableHead"?(l=!0,a=n):h.type==="tableRow"||h.type==="tableDelimiterRow"?(a=n,s[1]!==0?(i[0]=i[1],d=Mm(f,t,s,r,n,d)):i[1]!==0&&(d=Mm(f,t,i,r,n,d)),r=0):r&&(h.type==="data"||h.type==="tableDelimiterMarker"||h.type==="tableDelimiterFiller")&&(i[3]=n)}for(a!==0&&H9(f,t,a,u,c),f.consume(t.events),n=-1;++n<t.events.length;){const p=t.events[n];p[0]==="enter"&&p[1].type==="table"&&(p[1]._align=M6e(t.events,n))}return e}function Mm(e,t,n,o,r,s){const i=o===1?"tableHeader":o===2?"tableDelimiter":"tableData",l="tableContent";n[0]!==0&&(s.end=Object.assign({},sc(t.events,n[0])),e.add(n[0],0,[["exit",s,t]]));const a=sc(t.events,n[1]);if(s={type:i,start:Object.assign({},a),end:Object.assign({},a)},e.add(n[1],0,[["enter",s,t]]),n[2]!==0){const u=sc(t.events,n[2]),c=sc(t.events,n[3]),d={type:l,start:Object.assign({},u),end:Object.assign({},c)};if(e.add(n[2],0,[["enter",d,t]]),o!==2){const f=t.events[n[2]],p=t.events[n[3]];if(f[1].end=Object.assign({},p[1].end),f[1].type="chunkText",f[1].contentType="text",n[3]>n[2]+1){const h=n[2]+1,m=n[3]-n[2]-1;e.add(h,m,[])}}e.add(n[3]+1,0,[["exit",d,t]])}return r!==void 0&&(s.end=Object.assign({},sc(t.events,r)),e.add(r,0,[["exit",s,t]]),s=void 0),s}function H9(e,t,n,o,r){const s=[],i=sc(t.events,n);r&&(r.end=Object.assign({},i),s.push(["exit",r,t])),o.end=Object.assign({},i),s.push(["exit",o,t]),e.add(n+1,0,s)}function sc(e,t){const n=e[t],o=n[0]==="enter"?"start":"end";return n[1][o]}const A6e={name:"tasklistCheck",tokenize:P6e};function N6e(){return{text:{91:A6e}}}function P6e(e,t,n){const o=this;return r;function r(a){return o.previous!==null||!o._gfmTasklistFirstContentOfListItem?n(a):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(a),e.exit("taskListCheckMarker"),s)}function s(a){return nn(a)?(e.enter("taskListCheckValueUnchecked"),e.consume(a),e.exit("taskListCheckValueUnchecked"),i):a===88||a===120?(e.enter("taskListCheckValueChecked"),e.consume(a),e.exit("taskListCheckValueChecked"),i):n(a)}function i(a){return a===93?(e.enter("taskListCheckMarker"),e.consume(a),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),l):n(a)}function l(a){return dt(a)?t(a):Nt(a)?e.check({tokenize:L6e},t,n)(a):n(a)}}function L6e(e,t,n){return Vt(e,o,"whitespace");function o(r){return r===null?n(r):t(r)}}function R6e(e){return $I([l6e(),v6e(),$6e(e),T6e(),N6e()])}const D6e={};function F6e(e){const t=this,n=e||D6e,o=t.data(),r=o.micromarkExtensions||(o.micromarkExtensions=[]),s=o.fromMarkdownExtensions||(o.fromMarkdownExtensions=[]),i=o.toMarkdownExtensions||(o.toMarkdownExtensions=[]);r.push(R6e(n)),s.push(o6e()),i.push(r6e(n))}function gt(e,t){return Object.assign(e,{meta:{package:"@milkdown/preset-gfm",...t}}),e}const vk=Ah("strike_through");gt(vk,{displayName:"Attr<strikethrough>",group:"Strikethrough"});const Rd=Ih("strike_through",e=>({parseDOM:[{tag:"del"},{style:"text-decoration",getAttrs:t=>t==="line-through"}],toDOM:t=>["del",e.get(vk.key)(t)],parseMarkdown:{match:t=>t.type==="delete",runner:(t,n,o)=>{t.openMark(o),t.next(n.children),t.closeMark(o)}},toMarkdown:{match:t=>t.type.name==="strike_through",runner:(t,n)=>{t.withMark(n,"delete")}}}));gt(Rd.mark,{displayName:"MarkSchema<strikethrough>",group:"Strikethrough"});gt(Rd.ctx,{displayName:"MarkSchemaCtx<strikethrough>",group:"Strikethrough"});const wv=Tt("ToggleStrikeThrough",e=>()=>cv(Rd.type(e)));gt(wv,{displayName:"Command<ToggleStrikethrough>",group:"Strikethrough"});const hP=er(e=>xh(/~([^~]+)~$/,Rd.type(e)));gt(hP,{displayName:"InputRule<strikethrough>",group:"Strikethrough"});const yk=tr("strikeThroughKeymap",{ToggleStrikethrough:{shortcuts:"Mod-Alt-x",command:e=>{const t=e.get(Dt);return()=>t.call(wv.key)}}});gt(yk.ctx,{displayName:"KeymapCtx<strikethrough>",group:"Strikethrough"});gt(yk.shortcuts,{displayName:"Keymap<strikethrough>",group:"Strikethrough"});const Lh=uke({tableGroup:"block",cellContent:"paragraph",cellAttributes:{alignment:{default:"left",getFromDOM:e=>e.style.textAlign||"left",setDOMAttr:(e,t)=>{t.style=`text-align: ${e||"left"}`}}}}),Dd=Yn("table",()=>({...Lh.table,content:"table_header_row table_row+",disableDropCursor:!0,parseMarkdown:{match:e=>e.type==="table",runner:(e,t,n)=>{const o=t.align,r=t.children.map((s,i)=>({...s,align:o,isHeader:i===0}));e.openNode(n),e.next(r),e.closeNode()}},toMarkdown:{match:e=>e.type.name==="table",runner:(e,t)=>{var n;const o=(n=t.content.firstChild)==null?void 0:n.content;if(!o)return;const r=[];o.forEach(s=>{r.push(s.attrs.alignment)}),e.openNode("table",void 0,{align:r}),e.next(t.content),e.closeNode()}}}));gt(Dd.node,{displayName:"NodeSchema<table>",group:"Table"});gt(Dd.ctx,{displayName:"NodeSchemaCtx<table>",group:"Table"});const Cv=Yn("table_header_row",()=>({...Lh.table_row,disableDropCursor:!0,content:"(table_header)*",parseDOM:[{tag:"tr[data-is-header]"}],toDOM(){return["tr",{"data-is-header":!0},0]},parseMarkdown:{match:e=>!!(e.type==="tableRow"&&e.isHeader),runner:(e,t,n)=>{const o=t.align,r=t.children.map((s,i)=>({...s,align:o[i],isHeader:t.isHeader}));e.openNode(n),e.next(r),e.closeNode()}},toMarkdown:{match:e=>e.type.name==="table_header_row",runner:(e,t)=>{e.openNode("tableRow",void 0,{isHeader:!0}),e.next(t.content),e.closeNode()}}}));gt(Cv.node,{displayName:"NodeSchema<tableHeaderRow>",group:"Table"});gt(Cv.ctx,{displayName:"NodeSchemaCtx<tableHeaderRow>",group:"Table"});const Rh=Yn("table_row",()=>({...Lh.table_row,disableDropCursor:!0,content:"(table_cell)*",parseMarkdown:{match:e=>e.type==="tableRow",runner:(e,t,n)=>{const o=t.align,r=t.children.map((s,i)=>({...s,align:o[i]}));e.openNode(n),e.next(r),e.closeNode()}},toMarkdown:{match:e=>e.type.name==="table_row",runner:(e,t)=>{e.openNode("tableRow"),e.next(t.content),e.closeNode()}}}));gt(Rh.node,{displayName:"NodeSchema<tableRow>",group:"Table"});gt(Rh.ctx,{displayName:"NodeSchemaCtx<tableRow>",group:"Table"});const Dh=Yn("table_cell",()=>({...Lh.table_cell,disableDropCursor:!0,parseMarkdown:{match:e=>e.type==="tableCell"&&!e.isHeader,runner:(e,t,n)=>{const o=t.align;e.openNode(n,{alignment:o}).openNode(e.schema.nodes.paragraph).next(t.children).closeNode().closeNode()}},toMarkdown:{match:e=>e.type.name==="table_cell",runner:(e,t)=>{e.openNode("tableCell").next(t.content).closeNode()}}}));gt(Dh.node,{displayName:"NodeSchema<tableCell>",group:"Table"});gt(Dh.ctx,{displayName:"NodeSchemaCtx<tableCell>",group:"Table"});const kv=Yn("table_header",()=>({...Lh.table_header,disableDropCursor:!0,parseMarkdown:{match:e=>e.type==="tableCell"&&!!e.isHeader,runner:(e,t,n)=>{const o=t.align;e.openNode(n,{alignment:o}),e.openNode(e.schema.nodes.paragraph),e.next(t.children),e.closeNode(),e.closeNode()}},toMarkdown:{match:e=>e.type.name==="table_header",runner:(e,t)=>{e.openNode("tableCell"),e.next(t.content),e.closeNode()}}}));gt(kv.node,{displayName:"NodeSchema<tableHeader>",group:"Table"});gt(kv.ctx,{displayName:"NodeSchemaCtx<tableHeader>",group:"Table"});function mP(e,t=3,n=3){const o=Array(n).fill(0).map(()=>Dh.type(e).createAndFill()),r=Array(n).fill(0).map(()=>kv.type(e).createAndFill()),s=Array(t).fill(0).map((i,l)=>l===0?Cv.type(e).create(null,r):Rh.type(e).create(null,o));return Dd.type(e).create(null,s)}function Fh(e){return dC(t=>t.type.spec.tableRole==="table")(e)}function ic(e,t){const n=Fh(t.$from);if(!n)return;const o=Xt.get(n.node);if(!(e<0||e>=o.width))return o.cellsInRect({left:e,right:e+1,top:0,bottom:o.height}).map(r=>{const s=n.node.nodeAt(r);if(!s)return;const i=r+n.start;return{pos:i,start:i+1,node:s}}).filter(r=>r!=null)}function lc(e,t){const n=Fh(t.$from);if(!n)return;const o=Xt.get(n.node);if(!(e<0||e>=o.height))return o.cellsInRect({left:0,right:o.width,top:e,bottom:e+1}).map(r=>{const s=n.node.nodeAt(r);if(!s)return;const i=r+n.start;return{pos:i,start:i+1,node:s}}).filter(r=>r!=null)}function V6e(e){const t=Fh(e.$from);if(!t)return;const n=Xt.get(t.node);return n.cellsInRect({left:0,right:n.width,top:0,bottom:n.height}).map(o=>{const r=t.node.nodeAt(o),s=o+t.start;return{pos:s,start:s+1,node:r}})}function B6e(e){const t=V6e(e.selection);if(t&&t[0]){const n=e.doc.resolve(t[0].pos),o=t[t.length-1];if(o){const r=e.doc.resolve(o.pos);return uv(e.setSelection(new hn(r,n)))}}return e}function gP(e,t,{map:n,tableStart:o,table:r},s){const i=Array(s).fill(0).reduce((a,u,c)=>a+r.child(c).nodeSize,o),l=Array(n.width).fill(0).map((a,u)=>{const c=r.nodeAt(n.map[u]);return Dh.type(e).createAndFill({alignment:c==null?void 0:c.attrs.alignment})});return t.insert(i,Rh.type(e).create(null,l)),t}function vP(e){return(t,n)=>o=>{n=n??o.selection.from;const r=o.doc.resolve(n),s=dC(a=>a.type.name==="table")(r),i=s?{node:s.node,from:s.start}:void 0,l=e==="row";if(i){const a=Xt.get(i.node);if(t>=0&&t<(l?a.height:a.width)){const u=a.positionAt(l?t:a.height-1,l?a.width-1:t,i.node),c=o.doc.resolve(i.from+u),d=l?hn.rowSelection:hn.colSelection,f=a.positionAt(l?t:0,l?0:t,i.node),p=o.doc.resolve(i.from+f);return uv(o.setSelection(d(c,p)))}}return o}}const z6e=vP("row"),j6e=vP("col");function U9(e){return e[0].map((t,n)=>e.map(o=>o[n]))}function yP(e,t){const n=[],o=Xt.get(e);for(let r=0;r<o.height;r++){const s=e.child(r),i=[];for(let l=0;l<o.width;l++){if(!t[r][l])continue;const a=o.map[r*o.width+l],u=t[r][l],c=e.nodeAt(a).type.createChecked(Object.assign({},u.attrs),u.content,u.marks);i.push(c)}n.push(s.type.createChecked(s.attrs,i,s.marks))}return e.type.createChecked(e.attrs,n,e.marks)}function _P(e){const t=Xt.get(e),n=[];for(let o=0;o<t.height;o++){const r=[],s={};for(let i=0;i<t.width;i++){const l=t.map[o*t.width+i],a=e.nodeAt(l),u=t.findCell(l);if(s[l]||u.top!==o){r.push(null);continue}s[l]=!0,r.push(a)}n.push(r)}return n}function bP(e,t,n,o){const r=t[0]>n[0]?-1:1,s=e.splice(t[0],t.length),i=s.length%2===0?1:0;let l;return o===-1&&r===1?l=n[0]-1:o===1&&r===-1?l=n[n.length-1]-i+1:l=r===-1?n[0]:n[n.length-1]-i,e.splice(l,0,...s),e}function H6e(e,t,n,o){let r=U9(_P(e.node));return r=bP(r,t,n,o),r=U9(r),yP(e.node,r)}function U6e(e,t,n,o){let r=_P(e.node);return r=bP(r,t,n,o),yP(e.node,r)}function W9(e,t){let n=e,o=e;for(let c=e;c>=0;c--){const d=ic(c,t.selection);d&&d.forEach(f=>{const p=f.node.attrs.colspan+c-1;p>=n&&(n=c),p>o&&(o=p)})}for(let c=e;c<=o;c++){const d=ic(c,t.selection);d&&d.forEach(f=>{const p=f.node.attrs.colspan+c-1;f.node.attrs.colspan>1&&p>o&&(o=p)})}const r=[];for(let c=n;c<=o;c++){const d=ic(c,t.selection);d&&d.length&&r.push(c)}n=r[0],o=r[r.length-1];const s=ic(n,t.selection),i=lc(0,t.selection),l=t.doc.resolve(s[s.length-1].pos);let a;for(let c=o;c>=n;c--){const d=ic(c,t.selection);if(d&&d.length){for(let f=i.length-1;f>=0;f--)if(i[f].pos===d[0].pos){a=d[0];break}if(a)break}}const u=t.doc.resolve(a.pos);return{$anchor:l,$head:u,indexes:r}}function K9(e,t){let n=e,o=e;for(let c=e;c>=0;c--)lc(c,t.selection).forEach(d=>{const f=d.node.attrs.rowspan+c-1;f>=n&&(n=c),f>o&&(o=f)});for(let c=e;c<=o;c++)lc(c,t.selection).forEach(d=>{const f=d.node.attrs.rowspan+c-1;d.node.attrs.rowspan>1&&f>o&&(o=f)});const r=[];for(let c=n;c<=o;c++){const d=lc(c,t.selection);d&&d.length&&r.push(c)}n=r[0],o=r[r.length-1];const s=lc(n,t.selection),i=ic(0,t.selection),l=t.doc.resolve(s[s.length-1].pos);let a;for(let c=o;c>=n;c--){const d=lc(c,t.selection);if(d&&d.length){for(let f=i.length-1;f>=0;f--)if(i[f].pos===d[0].pos){a=d[0];break}if(a)break}}const u=t.doc.resolve(a.pos);return{$anchor:l,$head:u,indexes:r}}function W6e(e){const{tr:t,origin:n,target:o,select:r=!0,pos:s}=e,i=s!=null?t.doc.resolve(s):t.selection.$from,l=Fh(i);if(!l)return t;const{indexes:a}=W9(n,t),{indexes:u}=W9(o,t);if(a.includes(o))return t;const c=H6e(l,a,u,0),d=uv(t).replaceWith(l.pos,l.pos+l.node.nodeSize,c);if(!r)return d;const f=Xt.get(c),p=l.start,h=o,m=f.positionAt(f.height-1,h,c),y=d.doc.resolve(p+m),v=hn.colSelection,w=f.positionAt(0,h,c),_=d.doc.resolve(p+w);return d.setSelection(v(y,_))}function K6e(e){const{tr:t,origin:n,target:o,select:r=!0,pos:s}=e,i=s!=null?t.doc.resolve(s):t.selection.$from,l=Fh(i);if(!l)return t;const{indexes:a}=K9(n,t),{indexes:u}=K9(o,t);if(a.includes(o))return t;const c=U6e(l,a,u,0),d=uv(t).replaceWith(l.pos,l.pos+l.node.nodeSize,c);if(!r)return d;const f=Xt.get(c),p=l.start,h=o,m=f.positionAt(h,f.width-1,c),y=d.doc.resolve(p+m),v=hn.rowSelection,w=f.positionAt(h,0,c),_=d.doc.resolve(p+w);return d.setSelection(v(y,_))}const _k=Tt("GoToPrevTableCell",()=>()=>QN(-1));gt(_k,{displayName:"Command<goToPrevTableCellCommand>",group:"Table"});const bk=Tt("GoToNextTableCell",()=>()=>QN(1));gt(bk,{displayName:"Command<goToNextTableCellCommand>",group:"Table"});const wk=Tt("ExitTable",e=>()=>(t,n)=>{if(!Yr(t))return!1;const{$head:o}=t.selection,r=swe(o,Dd.type(e));if(!r)return!1;const{to:s}=r,i=t.tr.replaceWith(s,s,ji.type(e).createAndFill());return i.setSelection(bt.near(i.doc.resolve(s),1)).scrollIntoView(),n==null||n(i),!0});gt(wk,{displayName:"Command<breakTableCommand>",group:"Table"});const wP=Tt("InsertTable",e=>({row:t,col:n}={})=>(o,r)=>{const{selection:s,tr:i}=o,{from:l}=s,a=mP(e,t,n),u=i.replaceSelectionWith(a),c=bt.findFrom(u.doc.resolve(l),1,!0);return c&&u.setSelection(c),r==null||r(u),!0});gt(wP,{displayName:"Command<insertTableCommand>",group:"Table"});const CP=Tt("MoveRow",()=>({from:e,to:t,pos:n}={})=>(o,r)=>{const{tr:s}=o;return!!(r!=null&&r(K6e({tr:s,origin:e??0,target:t??0,pos:n,select:!0})))});gt(CP,{displayName:"Command<moveRowCommand>",group:"Table"});const kP=Tt("MoveCol",()=>({from:e,to:t,pos:n}={})=>(o,r)=>{const{tr:s}=o;return!!(r!=null&&r(W6e({tr:s,origin:e??0,target:t??0,pos:n,select:!0})))});gt(kP,{displayName:"Command<moveColCommand>",group:"Table"});const SP=Tt("SelectRow",()=>(e={index:0})=>(t,n)=>{const{tr:o}=t;return!!(n!=null&&n(z6e(e.index,e.pos)(o)))});gt(SP,{displayName:"Command<selectRowCommand>",group:"Table"});const $P=Tt("SelectCol",()=>(e={index:0})=>(t,n)=>{const{tr:o}=t;return!!(n!=null&&n(j6e(e.index,e.pos)(o)))});gt($P,{displayName:"Command<selectColCommand>",group:"Table"});const EP=Tt("SelectTable",()=>()=>(e,t)=>{const{tr:n}=e;return!!(t!=null&&t(B6e(n)))});gt(EP,{displayName:"Command<selectTableCommand>",group:"Table"});const xP=Tt("DeleteSelectedCells",()=>()=>(e,t)=>{const{selection:n}=e;if(!(n instanceof hn))return!1;const o=n.isRowSelection(),r=n.isColSelection();return o&&r?Ike(e,t):r?$ke(e,t):xke(e,t)});gt(xP,{displayName:"Command<deleteSelectedCellsCommand>",group:"Table"});const MP=Tt("AddColBefore",()=>()=>Cke);gt(MP,{displayName:"Command<addColBeforeCommand>",group:"Table"});const TP=Tt("AddColAfter",()=>()=>kke);gt(TP,{displayName:"Command<addColAfterCommand>",group:"Table"});const OP=Tt("AddRowBefore",e=>()=>(t,n)=>{if(!Yr(t))return!1;if(n){const o=ia(t);n(gP(e,t.tr,o,o.top))}return!0});gt(OP,{displayName:"Command<addRowBeforeCommand>",group:"Table"});const IP=Tt("AddRowAfter",e=>()=>(t,n)=>{if(!Yr(t))return!1;if(n){const o=ia(t);n(gP(e,t.tr,o,o.bottom))}return!0});gt(IP,{displayName:"Command<addRowAfterCommand>",group:"Table"});const AP=Tt("SetAlign",()=>(e="left")=>Mke("alignment",e));gt(AP,{displayName:"Command<setAlignCommand>",group:"Table"});const NP=er(e=>new Cr(/^\|(?<col>\d+)[xX](?<row>\d+)\|\s$/,(t,n,o,r)=>{var s,i;const l=t.doc.resolve(o);if(!l.node(-1).canReplaceWith(l.index(-1),l.indexAfter(-1),Dd.type(e)))return null;const a=mP(e,Number((s=n.groups)==null?void 0:s.row),Number((i=n.groups)==null?void 0:i.col)),u=t.tr.replaceRangeWith(o,r,a);return u.setSelection(ht.create(u.doc,o+3)).scrollIntoView()}));gt(NP,{displayName:"InputRule<insertTableInputRule>",group:"Table"});const Ck=tr("tableKeymap",{NextCell:{shortcuts:["Mod-]","Tab"],command:e=>{const t=e.get(Dt);return()=>t.call(bk.key)}},PrevCell:{shortcuts:["Mod-[","Shift-Tab"],command:e=>{const t=e.get(Dt);return()=>t.call(_k.key)}},ExitTable:{shortcuts:["Mod-Enter"],command:e=>{const t=e.get(Dt);return()=>t.call(wk.key)}}});gt(Ck.ctx,{displayName:"KeymapCtx<table>",group:"Table"});gt(Ck.shortcuts,{displayName:"Keymap<table>",group:"Table"});const Xy="footnote_definition",q9="footnoteDefinition",kk=Yn("footnote_definition",()=>({group:"block",content:"block+",defining:!0,attrs:{label:{default:""}},parseDOM:[{tag:`dl[data-type="${Xy}"]`,getAttrs:e=>{if(!(e instanceof HTMLElement))throw ii(e);return{label:e.dataset.label}},contentElement:"dd"}],toDOM:e=>{const t=e.attrs.label;return["dl",{"data-label":t,"data-type":Xy},["dt",t],["dd",0]]},parseMarkdown:{match:({type:e})=>e===q9,runner:(e,t,n)=>{e.openNode(n,{label:t.label}).next(t.children).closeNode()}},toMarkdown:{match:e=>e.type.name===Xy,runner:(e,t)=>{e.openNode(q9,void 0,{label:t.attrs.label,identifier:t.attrs.label}).next(t.content).closeNode()}}}));gt(kk.ctx,{displayName:"NodeSchemaCtx<footnodeDef>",group:"footnote"});gt(kk.node,{displayName:"NodeSchema<footnodeDef>",group:"footnote"});const Qy="footnote_reference",Sk=Yn("footnote_reference",()=>({group:"inline",inline:!0,atom:!0,attrs:{label:{default:""}},parseDOM:[{tag:`sup[data-type="${Qy}"]`,getAttrs:e=>{if(!(e instanceof HTMLElement))throw ii(e);return{label:e.dataset.label}}}],toDOM:e=>{const t=e.attrs.label;return["sup",{"data-label":t,"data-type":Qy},t]},parseMarkdown:{match:({type:e})=>e==="footnoteReference",runner:(e,t,n)=>{e.addNode(n,{label:t.label})}},toMarkdown:{match:e=>e.type.name===Qy,runner:(e,t)=>{e.addNode("footnoteReference",void 0,void 0,{label:t.attrs.label,identifier:t.attrs.label})}}}));gt(Sk.ctx,{displayName:"NodeSchemaCtx<footnodeRef>",group:"footnote"});gt(Sk.node,{displayName:"NodeSchema<footnodeRef>",group:"footnote"});const PP=Qs.extendSchema(e=>t=>{const n=e(t);return{...n,attrs:{...n.attrs,checked:{default:null}},parseDOM:[{tag:'li[data-item-type="task"]',getAttrs:o=>{if(!(o instanceof HTMLElement))throw ii(o);return{label:o.dataset.label,listType:o.dataset.listType,spread:o.dataset.spread,checked:o.dataset.checked?o.dataset.checked==="true":null}}},...(n==null?void 0:n.parseDOM)||[]],toDOM:o=>n.toDOM&&o.attrs.checked==null?n.toDOM(o):["li",{"data-item-type":"task","data-label":o.attrs.label,"data-list-type":o.attrs.listType,"data-spread":o.attrs.spread,"data-checked":o.attrs.checked},0],parseMarkdown:{match:({type:o})=>o==="listItem",runner:(o,r,s)=>{if(r.checked==null){n.parseMarkdown.runner(o,r,s);return}const i=r.label!=null?`${r.label}.`:"•",l=r.checked!=null?!!r.checked:null,a=r.label!=null?"ordered":"bullet",u=r.spread!=null?`${r.spread}`:"true";o.openNode(s,{label:i,listType:a,spread:u,checked:l}),o.next(r.children),o.closeNode()}},toMarkdown:{match:o=>o.type.name==="list_item",runner:(o,r)=>{if(r.attrs.checked==null){n.toMarkdown.runner(o,r);return}const s=r.attrs.label,i=r.attrs.listType,l=r.attrs.spread==="true",a=r.attrs.checked;o.openNode("listItem",void 0,{label:s,listType:i,spread:l,checked:a}),o.next(r.content),o.closeNode()}}}});gt(PP,{displayName:"NodeSchema<listItem>",group:"ListItem"});const LP=er(()=>new Cr(/^\[(?<checked>\s|x)\]\s$/,(e,t,n,o)=>{var r;const s=e.doc.resolve(n);let i=0,l=s.node(i);for(;l&&l.type.name!=="list_item";)i--,l=s.node(i);if(!l||l.attrs.checked!=null)return null;const a=((r=t.groups)==null?void 0:r.checked)==="x",u=s.before(i),c=e.tr;return c.deleteRange(n,o).setNodeMarkup(u,void 0,{...l.attrs,checked:a}),c}));gt(LP,{displayName:"InputRule<wrapInTaskListInputRule>",group:"ListItem"});const q6e=[yk,Ck].flat(),G6e=[NP,LP],Y6e=[hP],RP=ao(()=>l4e);gt(RP,{displayName:"Prose<autoInsertSpanPlugin>",group:"Prose"});const Z6e=ao(()=>zke({}));gt(Z6e,{displayName:"Prose<columnResizingPlugin>",group:"Prose"});const DP=ao(()=>Xke({allowTableNodeSelection:!0}));gt(DP,{displayName:"Prose<tableEditingPlugin>",group:"Prose"});const $k=Id("remarkGFM",()=>F6e);gt($k.plugin,{displayName:"Remark<remarkGFMPlugin>",group:"Remark"});gt($k.options,{displayName:"RemarkConfig<remarkGFMPlugin>",group:"Remark"});const J6e=new wn("MILKDOWN_KEEP_TABLE_ALIGN_PLUGIN");function X6e(e,t){let n=0;return t.forEach((o,r,s)=>{o===e&&(n=s)}),n}const FP=ao(()=>new xn({key:J6e,appendTransaction:(e,t,n)=>{let o;const r=(s,i)=>{if(o||(o=n.tr),s.type.name!=="table_cell")return;const l=n.doc.resolve(i),a=l.node(l.depth),u=l.node(l.depth-1).firstChild;if(!u)return;const c=X6e(s,a),d=u.maybeChild(c);if(!d)return;const f=d.attrs.alignment,p=s.attrs.alignment;f!==p&&o.setNodeMarkup(i,void 0,{...s.attrs,alignment:f})};return t.doc!==n.doc&&n.doc.descendants(r),o}}));gt(FP,{displayName:"Prose<keepTableAlignPlugin>",group:"Prose"});const Q6e=[FP,RP,$k,DP].flat(),e5e=[PP,Dd,Cv,Rh,kv,Dh,kk,Sk,vk,Rd].flat(),t5e=[bk,_k,wk,wP,CP,kP,SP,$P,EP,xP,OP,IP,MP,TP,AP,wv],n5e=[e5e,G6e,Y6e,q6e,t5e,Q6e].flat();var o0=200,qn=function(){};qn.prototype.append=function(t){return t.length?(t=qn.from(t),!this.length&&t||t.length<o0&&this.leafAppend(t)||this.length<o0&&t.leafPrepend(this)||this.appendInner(t)):this};qn.prototype.prepend=function(t){return t.length?qn.from(t).append(this):this};qn.prototype.appendInner=function(t){return new o5e(this,t)};qn.prototype.slice=function(t,n){return t===void 0&&(t=0),n===void 0&&(n=this.length),t>=n?qn.empty:this.sliceInner(Math.max(0,t),Math.min(this.length,n))};qn.prototype.get=function(t){if(!(t<0||t>=this.length))return this.getInner(t)};qn.prototype.forEach=function(t,n,o){n===void 0&&(n=0),o===void 0&&(o=this.length),n<=o?this.forEachInner(t,n,o,0):this.forEachInvertedInner(t,n,o,0)};qn.prototype.map=function(t,n,o){n===void 0&&(n=0),o===void 0&&(o=this.length);var r=[];return this.forEach(function(s,i){return r.push(t(s,i))},n,o),r};qn.from=function(t){return t instanceof qn?t:t&&t.length?new VP(t):qn.empty};var VP=function(e){function t(o){e.call(this),this.values=o}e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t;var n={length:{configurable:!0},depth:{configurable:!0}};return t.prototype.flatten=function(){return this.values},t.prototype.sliceInner=function(r,s){return r==0&&s==this.length?this:new t(this.values.slice(r,s))},t.prototype.getInner=function(r){return this.values[r]},t.prototype.forEachInner=function(r,s,i,l){for(var a=s;a<i;a++)if(r(this.values[a],l+a)===!1)return!1},t.prototype.forEachInvertedInner=function(r,s,i,l){for(var a=s-1;a>=i;a--)if(r(this.values[a],l+a)===!1)return!1},t.prototype.leafAppend=function(r){if(this.length+r.length<=o0)return new t(this.values.concat(r.flatten()))},t.prototype.leafPrepend=function(r){if(this.length+r.length<=o0)return new t(r.flatten().concat(this.values))},n.length.get=function(){return this.values.length},n.depth.get=function(){return 0},Object.defineProperties(t.prototype,n),t}(qn);qn.empty=new VP([]);var o5e=function(e){function t(n,o){e.call(this),this.left=n,this.right=o,this.length=n.length+o.length,this.depth=Math.max(n.depth,o.depth)+1}return e&&(t.__proto__=e),t.prototype=Object.create(e&&e.prototype),t.prototype.constructor=t,t.prototype.flatten=function(){return this.left.flatten().concat(this.right.flatten())},t.prototype.getInner=function(o){return o<this.left.length?this.left.get(o):this.right.get(o-this.left.length)},t.prototype.forEachInner=function(o,r,s,i){var l=this.left.length;if(r<l&&this.left.forEachInner(o,r,Math.min(s,l),i)===!1||s>l&&this.right.forEachInner(o,Math.max(r-l,0),Math.min(this.length,s)-l,i+l)===!1)return!1},t.prototype.forEachInvertedInner=function(o,r,s,i){var l=this.left.length;if(r>l&&this.right.forEachInvertedInner(o,r-l,Math.max(s,l)-l,i+l)===!1||s<l&&this.left.forEachInvertedInner(o,Math.min(r,l),s,i)===!1)return!1},t.prototype.sliceInner=function(o,r){if(o==0&&r==this.length)return this;var s=this.left.length;return r<=s?this.left.slice(o,r):o>=s?this.right.slice(o-s,r-s):this.left.slice(o,s).append(this.right.slice(0,r-s))},t.prototype.leafAppend=function(o){var r=this.right.leafAppend(o);if(r)return new t(this.left,r)},t.prototype.leafPrepend=function(o){var r=this.left.leafPrepend(o);if(r)return new t(r,this.right)},t.prototype.appendInner=function(o){return this.left.depth>=Math.max(this.right.depth,o.depth)+1?new t(this.left,new t(this.right,o)):new t(this,o)},t}(qn);const r5e=500;class is{constructor(t,n){this.items=t,this.eventCount=n}popEvent(t,n){if(this.eventCount==0)return null;let o=this.items.length;for(;;o--)if(this.items.get(o-1).selection){--o;break}let r,s;n&&(r=this.remapping(o,this.items.length),s=r.maps.length);let i=t.tr,l,a,u=[],c=[];return this.items.forEach((d,f)=>{if(!d.step){r||(r=this.remapping(o,f+1),s=r.maps.length),s--,c.push(d);return}if(r){c.push(new Rs(d.map));let p=d.step.map(r.slice(s)),h;p&&i.maybeStep(p).doc&&(h=i.mapping.maps[i.mapping.maps.length-1],u.push(new Rs(h,void 0,void 0,u.length+c.length))),s--,h&&r.appendMap(h,s)}else i.maybeStep(d.step);if(d.selection)return l=r?d.selection.map(r.slice(s)):d.selection,a=new is(this.items.slice(0,o).append(c.reverse().concat(u)),this.eventCount-1),!1},this.items.length,0),{remaining:a,transform:i,selection:l}}addTransform(t,n,o,r){let s=[],i=this.eventCount,l=this.items,a=!r&&l.length?l.get(l.length-1):null;for(let c=0;c<t.steps.length;c++){let d=t.steps[c].invert(t.docs[c]),f=new Rs(t.mapping.maps[c],d,n),p;(p=a&&a.merge(f))&&(f=p,c?s.pop():l=l.slice(0,l.length-1)),s.push(f),n&&(i++,n=void 0),r||(a=f)}let u=i-o.depth;return u>i5e&&(l=s5e(l,u),i-=u),new is(l.append(s),i)}remapping(t,n){let o=new Ec;return this.items.forEach((r,s)=>{let i=r.mirrorOffset!=null&&s-r.mirrorOffset>=t?o.maps.length-r.mirrorOffset:void 0;o.appendMap(r.map,i)},t,n),o}addMaps(t){return this.eventCount==0?this:new is(this.items.append(t.map(n=>new Rs(n))),this.eventCount)}rebased(t,n){if(!this.eventCount)return this;let o=[],r=Math.max(0,this.items.length-n),s=t.mapping,i=t.steps.length,l=this.eventCount;this.items.forEach(f=>{f.selection&&l--},r);let a=n;this.items.forEach(f=>{let p=s.getMirror(--a);if(p==null)return;i=Math.min(i,p);let h=s.maps[p];if(f.step){let m=t.steps[p].invert(t.docs[p]),y=f.selection&&f.selection.map(s.slice(a+1,p));y&&l++,o.push(new Rs(h,m,y))}else o.push(new Rs(h))},r);let u=[];for(let f=n;f<i;f++)u.push(new Rs(s.maps[f]));let c=this.items.slice(0,r).append(u).append(o),d=new is(c,l);return d.emptyItemCount()>r5e&&(d=d.compress(this.items.length-o.length)),d}emptyItemCount(){let t=0;return this.items.forEach(n=>{n.step||t++}),t}compress(t=this.items.length){let n=this.remapping(0,t),o=n.maps.length,r=[],s=0;return this.items.forEach((i,l)=>{if(l>=t)r.push(i),i.selection&&s++;else if(i.step){let a=i.step.map(n.slice(o)),u=a&&a.getMap();if(o--,u&&n.appendMap(u,o),a){let c=i.selection&&i.selection.map(n.slice(o));c&&s++;let d=new Rs(u.invert(),a,c),f,p=r.length-1;(f=r.length&&r[p].merge(d))?r[p]=f:r.push(d)}}else i.map&&o--},this.items.length,0),new is(qn.from(r.reverse()),s)}}is.empty=new is(qn.empty,0);function s5e(e,t){let n;return e.forEach((o,r)=>{if(o.selection&&t--==0)return n=r,!1}),e.slice(n)}class Rs{constructor(t,n,o,r){this.map=t,this.step=n,this.selection=o,this.mirrorOffset=r}merge(t){if(this.step&&t.step&&!t.selection){let n=t.step.merge(this.step);if(n)return new Rs(n.getMap().invert(),n,this.selection)}}}class wl{constructor(t,n,o,r,s){this.done=t,this.undone=n,this.prevRanges=o,this.prevTime=r,this.prevComposition=s}}const i5e=20;function l5e(e,t,n,o){let r=n.getMeta(Qa),s;if(r)return r.historyState;n.getMeta(c5e)&&(e=new wl(e.done,e.undone,null,0,-1));let i=n.getMeta("appendedTransaction");if(n.steps.length==0)return e;if(i&&i.getMeta(Qa))return i.getMeta(Qa).redo?new wl(e.done.addTransform(n,void 0,o,F1(t)),e.undone,G9(n.mapping.maps),e.prevTime,e.prevComposition):new wl(e.done,e.undone.addTransform(n,void 0,o,F1(t)),null,e.prevTime,e.prevComposition);if(n.getMeta("addToHistory")!==!1&&!(i&&i.getMeta("addToHistory")===!1)){let l=n.getMeta("composition"),a=e.prevTime==0||!i&&e.prevComposition!=l&&(e.prevTime<(n.time||0)-o.newGroupDelay||!a5e(n,e.prevRanges)),u=i?e_(e.prevRanges,n.mapping):G9(n.mapping.maps);return new wl(e.done.addTransform(n,a?t.selection.getBookmark():void 0,o,F1(t)),is.empty,u,n.time,l??e.prevComposition)}else return(s=n.getMeta("rebased"))?new wl(e.done.rebased(n,s),e.undone.rebased(n,s),e_(e.prevRanges,n.mapping),e.prevTime,e.prevComposition):new wl(e.done.addMaps(n.mapping.maps),e.undone.addMaps(n.mapping.maps),e_(e.prevRanges,n.mapping),e.prevTime,e.prevComposition)}function a5e(e,t){if(!t)return!1;if(!e.docChanged)return!0;let n=!1;return e.mapping.maps[0].forEach((o,r)=>{for(let s=0;s<t.length;s+=2)o<=t[s+1]&&r>=t[s]&&(n=!0)}),n}function G9(e){let t=[];for(let n=e.length-1;n>=0&&t.length==0;n--)e[n].forEach((o,r,s,i)=>t.push(s,i));return t}function e_(e,t){if(!e)return null;let n=[];for(let o=0;o<e.length;o+=2){let r=t.map(e[o],1),s=t.map(e[o+1],-1);r<=s&&n.push(r,s)}return n}function u5e(e,t,n){let o=F1(t),r=Qa.get(t).spec.config,s=(n?e.undone:e.done).popEvent(t,o);if(!s)return null;let i=s.selection.resolve(s.transform.doc),l=(n?e.done:e.undone).addTransform(s.transform,t.selection.getBookmark(),r,o),a=new wl(n?l:s.remaining,n?s.remaining:l,null,0,-1);return s.transform.setSelection(i).setMeta(Qa,{redo:n,historyState:a})}let t_=!1,Y9=null;function F1(e){let t=e.plugins;if(Y9!=t){t_=!1,Y9=t;for(let n=0;n<t.length;n++)if(t[n].spec.historyPreserveItems){t_=!0;break}}return t_}const Qa=new wn("history"),c5e=new wn("closeHistory");function d5e(e={}){return e={depth:e.depth||100,newGroupDelay:e.newGroupDelay||500},new xn({key:Qa,state:{init(){return new wl(is.empty,is.empty,null,0,-1)},apply(t,n,o){return l5e(n,o,t,e)}},config:e,props:{handleDOMEvents:{beforeinput(t,n){let o=n.inputType,r=o=="historyUndo"?zP:o=="historyRedo"?jP:null;return r?(n.preventDefault(),r(t.state,t.dispatch)):!1}}}})}function BP(e,t){return(n,o)=>{let r=Qa.getState(n);if(!r||(e?r.undone:r.done).eventCount==0)return!1;if(o){let s=u5e(r,n,e);s&&o(t?s.scrollIntoView():s)}return!0}}const zP=BP(!1,!0),jP=BP(!0,!0);function Fd(e,t){return Object.assign(e,{meta:{package:"@milkdown/plugin-history",...t}}),e}const Ek=Tt("Undo",()=>()=>zP);Fd(Ek,{displayName:"Command<undo>"});const xk=Tt("Redo",()=>()=>jP);Fd(xk,{displayName:"Command<redo>"});const Mk=In({},"historyProviderConfig");Fd(Mk,{displayName:"Ctx<historyProviderConfig>"});const HP=ao(e=>d5e(e.get(Mk.key)));Fd(HP,{displayName:"Ctx<historyProviderPlugin>"});const Tk=tr("historyKeymap",{Undo:{shortcuts:"Mod-z",command:e=>{const t=e.get(Dt);return()=>t.call(Ek.key)}},Redo:{shortcuts:["Mod-y","Shift-Mod-z"],command:e=>{const t=e.get(Dt);return()=>t.call(xk.key)}}});Fd(Tk.ctx,{displayName:"KeymapCtx<history>"});Fd(Tk.shortcuts,{displayName:"Keymap<history>"});const f5e=[Mk,HP,Tk,Ek,xk].flat();function k2(e){if(!e)return!1;if(Array.isArray(e))return e.length>1?!1:k2(e[0]);const t=e.content;return t?k2(t):e.type==="text"}function p5e(e){if(e.content.childCount===1){const t=e.content.firstChild;if((t==null?void 0:t.type.name)==="text"&&t.marks.length===0)return t;if((t==null?void 0:t.type.name)==="paragraph"&&t.childCount===1){const n=t.firstChild;if((n==null?void 0:n.type.name)==="text"&&n.marks.length===0)return n}}return!1}const UP=ao(e=>{const t=e.get(ds);e.update(lp,o=>({...o,editable:o.editable??(()=>!0)}));const n=new wn("MILKDOWN_CLIPBOARD");return new xn({key:n,props:{handlePaste:(o,r)=>{var s,i;const l=e.get(Ic),a=(i=(s=o.props).editable)==null?void 0:i.call(s,o.state),{clipboardData:u}=r;if(!a||!u||o.state.selection.$from.node().type.spec.code)return!1;const c=u.getData("text/plain"),d=u.getData("vscode-editor-data");if(d){const v=JSON.parse(d),w=v==null?void 0:v.mode;if(c&&w){const{tr:_}=o.state,S=iwe("code_block",t);return _.replaceSelectionWith(S.create({language:w})).setSelection(ht.near(_.doc.resolve(Math.max(0,_.selection.from-2)))).insertText(c.replace(/\r\n?/g,`
124 `)),o.dispatch(_),!0}}const f=u.getData("text/html");if(f.length===0&&c.length===0)return!1;const p=fu.fromSchema(t);let h;if(f.length===0){const v=l(c);if(!v||typeof v=="string")return!1;h=ta.fromSchema(t).serializeFragment(v.content)}else{const v=document.createElement("template");v.innerHTML=f,h=v.content.cloneNode(!0),v.remove()}const m=p.parseSlice(h),y=p5e(m);return y?(o.dispatch(o.state.tr.replaceSelectionWith(y,!0)),!0):(o.dispatch(o.state.tr.replaceSelection(m)),!0)},clipboardTextSerializer:o=>{const r=e.get(Ac);if(k2(o.content.toJSON()))return o.content.textBetween(0,o.content.size,`
125
126 `);const s=t.topNodeType.createAndFill(void 0,o.content);return s?r(s):""}}})});UP.meta={displayName:"Prose<clipboard>",package:"@milkdown/plugin-clipboard"};const Ok=In({shouldAppend:e=>!(!e||["heading","paragraph"].includes(e.type.name)),getNode:e=>e.schema.nodes.paragraph.create()},"trailingConfig");Ok.meta={package:"@milkdown/plugin-trailing",displayName:"Ctx<trailingConfig>"};const WP=ao(e=>{const t=new wn("MILKDOWN_TRAILING"),{shouldAppend:n,getNode:o}=e.get(Ok.key),r=new xn({key:t,state:{init:(s,i)=>{const l=i.tr.doc.lastChild;return n(l,i)},apply:(s,i,l,a)=>{if(!s.docChanged)return i;const u=s.doc.lastChild;return n(u,a)}},appendTransaction:(s,i,l)=>{const{doc:a,tr:u}=l,c=o==null?void 0:o(l),d=r.getState(l),f=a.content.size;if(!(!d||!c))return u.insert(f,c)}});return r});WP.meta={package:"@milkdown/plugin-trailing",displayName:"Prose<trailing>"};const h5e=[Ok,WP];var KP=(e=>(e.CodeMirror="code-mirror",e.LinkTooltip="link-tooltip",e.Cursor="cursor",e.BlockEdit="block-edit",e.Toolbar="toolbar",e.Placeholder="placeholder",e))(KP||{});const m5e={cursor:!0,"link-tooltip":!0,"block-edit":!0,placeholder:!0,toolbar:!0,"code-mirror":!0};async function g5e(e,t,n){switch(e){case"link-tooltip":{const{defineFeature:o}=await Yd(()=>Promise.resolve().then(()=>ADe),void 0);return o(t,n)}case"block-edit":{const{defineFeature:o}=await Yd(()=>Promise.resolve().then(()=>gFe),void 0);return o(t,n)}case"placeholder":{const{defineFeature:o}=await Yd(()=>Promise.resolve().then(()=>bFe),void 0);return o(t,n)}case"toolbar":{const{defineFeature:o}=await Yd(()=>Promise.resolve().then(()=>kFe),void 0);return o(t,n)}}}const v5e=jt([],"FeaturesCtx");function y5e(e){return t=>{t.inject(v5e,e)}}var _5e="Expected a function",Z9=0/0,b5e="[object Symbol]",w5e=/^\s+|\s+$/g,C5e=/^[-+]0x[0-9a-f]+$/i,k5e=/^0b[01]+$/i,S5e=/^0o[0-7]+$/i,$5e=parseInt,E5e=typeof On=="object"&&On&&On.Object===Object&&On,x5e=typeof self=="object"&&self&&self.Object===Object&&self,M5e=E5e||x5e||Function("return this")(),T5e=Object.prototype,O5e=T5e.toString,I5e=Math.max,A5e=Math.min,n_=function(){return M5e.Date.now()};function N5e(e,t,n){var o,r,s,i,l,a,u=0,c=!1,d=!1,f=!0;if(typeof e!="function")throw new TypeError(_5e);t=J9(t)||0,S2(n)&&(c=!!n.leading,d="maxWait"in n,s=d?I5e(J9(n.maxWait)||0,t):s,f="trailing"in n?!!n.trailing:f);function p(E){var T=o,O=r;return o=r=void 0,u=E,i=e.apply(O,T),i}function h(E){return u=E,l=setTimeout(v,t),c?p(E):i}function m(E){var T=E-a,O=E-u,P=t-T;return d?A5e(P,s-O):P}function y(E){var T=E-a,O=E-u;return a===void 0||T>=t||T<0||d&&O>=s}function v(){var E=n_();if(y(E))return w(E);l=setTimeout(v,m(E))}function w(E){return l=void 0,f&&o?p(E):(o=r=void 0,i)}function _(){l!==void 0&&clearTimeout(l),u=0,o=a=r=l=void 0}function S(){return l===void 0?i:w(n_())}function x(){var E=n_(),T=y(E);if(o=arguments,r=this,a=E,T){if(l===void 0)return h(a);if(d)return l=setTimeout(v,t),p(a)}return l===void 0&&(l=setTimeout(v,t)),i}return x.cancel=_,x.flush=S,x}function S2(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function P5e(e){return!!e&&typeof e=="object"}function L5e(e){return typeof e=="symbol"||P5e(e)&&O5e.call(e)==b5e}function J9(e){if(typeof e=="number")return e;if(L5e(e))return Z9;if(S2(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=S2(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace(w5e,"");var n=k5e.test(e);return n||S5e.test(e)?$5e(e.slice(2),n?2:8):C5e.test(e)?Z9:+e}var R5e=N5e;const Sv=_o(R5e);let qP=class{constructor(){this.beforeMountedListeners=[],this.mountedListeners=[],this.updatedListeners=[],this.markdownUpdatedListeners=[],this.blurListeners=[],this.focusListeners=[],this.destroyListeners=[],this.beforeMount=t=>(this.beforeMountedListeners.push(t),this),this.mounted=t=>(this.mountedListeners.push(t),this),this.updated=t=>(this.updatedListeners.push(t),this)}get listeners(){return{beforeMount:this.beforeMountedListeners,mounted:this.mountedListeners,updated:this.updatedListeners,markdownUpdated:this.markdownUpdatedListeners,blur:this.blurListeners,focus:this.focusListeners,destroy:this.destroyListeners}}markdownUpdated(t){return this.markdownUpdatedListeners.push(t),this}blur(t){return this.blurListeners.push(t),this}focus(t){return this.focusListeners.push(t),this}destroy(t){return this.destroyListeners.push(t),this}};const $2=jt(new qP,"listener"),D5e=new wn("MILKDOWN_LISTENER"),GP=e=>(e.inject($2,new qP),async()=>{await e.wait(Ja);const t=e.get($2),{listeners:n}=t;n.beforeMount.forEach(l=>l(e)),await e.wait(ip);const o=e.get(Ac);let r=null,s=null;const i=new xn({key:D5e,view:()=>({destroy:()=>{n.destroy.forEach(l=>l(e))}}),props:{handleDOMEvents:{focus:()=>(n.focus.forEach(l=>l(e)),!1),blur:()=>(n.blur.forEach(l=>l(e)),!1)}},state:{init:(l,a)=>{r=a.doc,s=o(a.doc)},apply:l=>!l.docChanged||l.getMeta("addToHistory")===!1?void 0:Sv(()=>{const{doc:a}=l;if(n.updated.length>0&&r&&!r.eq(a)&&n.updated.forEach(u=>{u(e,a,r)}),n.markdownUpdated.length>0&&r&&!r.eq(a)){const u=o(a);n.markdownUpdated.forEach(c=>{c(e,u,s)}),s=u}r=a},200)()}});e.update(ys,l=>l.concat(i)),await e.wait(O1),n.mounted.forEach(l=>l(e))});GP.meta={package:"@milkdown/plugin-listener",displayName:"Listener"};function F5e(e){return new Promise(t=>{const n=new FileReader;n.addEventListener("load",()=>{t({alt:e.name,src:n.result})},!1),n.readAsDataURL(e)})}const V5e=async(e,t)=>{const n=[];for(let r=0;r<e.length;r++){const s=e.item(r);s&&s.type.includes("image")&&n.push(s)}const{image:o}=t.nodes;if(!o)throw nI("image");return(await Promise.all(n.map(r=>F5e(r)))).map(({alt:r,src:s})=>o.createAndFill({src:s,alt:r}))},Nc=In({uploader:V5e,enableHtmlFileUploader:!1,uploadWidgetFactory:(e,t)=>{const n=document.createElement("span");return n.textContent="Upload in progress...",zn.widget(e,n,t)}},"uploadConfig");Nc.meta={package:"@milkdown/plugin-upload",displayName:"Ctx<uploadConfig>"};const YP=ao(e=>{const t=new wn("MILKDOWN_UPLOAD"),n=(r,s)=>{var i;const l=t.getState(r);if(!l)return-1;const a=l.find(void 0,void 0,u=>u.id===s);return a.length?((i=a[0])==null?void 0:i.from)??-1:-1},o=(r,s,i)=>{var l;if(!i||i.length<=0)return!1;const a=Symbol("upload symbol"),u=e.get(ds),{tr:c}=r.state,d=s instanceof DragEvent?((l=r.posAtCoords({left:s.clientX,top:s.clientY}))==null?void 0:l.pos)??c.selection.from:c.selection.from;r.dispatch(c.setMeta(t,{add:{id:a,pos:d}}));const{uploader:f}=e.get(Nc.key);return f(i,u).then(p=>{const h=n(r.state,a);h<0||r.dispatch(r.state.tr.replaceWith(h,h,p).setMeta(t,{remove:{id:a}}))}).catch(p=>{console.error(p)}),!0};return new xn({key:t,state:{init(){return an.empty},apply(r,s){const i=s.map(r.mapping,r.doc),l=r.getMeta(this);if(!l)return i;if(l.add){const{uploadWidgetFactory:a}=e.get(Nc.key),u=a(l.add.pos,{id:l.add.id});return i.add(r.doc,[u])}if(l.remove){const a=i.find(void 0,void 0,u=>u.id===l.remove.id);return i.remove(a)}return i}},props:{decorations(r){return this.getState(r)},handlePaste:(r,s)=>{var i,l;const{enableHtmlFileUploader:a}=e.get(Nc.key);return!(s instanceof ClipboardEvent)||!a&&(i=s.clipboardData)!=null&&i.getData("text/html")?!1:o(r,s,(l=s.clipboardData)==null?void 0:l.files)},handleDrop:(r,s)=>{var i;return s instanceof DragEvent?o(r,s,(i=s.dataTransfer)==null?void 0:i.files):!1}}})});YP.meta={package:"@milkdown/plugin-upload",displayName:"Prose<upload>"};const B5e=[Nc,YP];var ZP=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},Ms=(e,t,n)=>(ZP(e,t,"read from private field"),n?n.call(e):t.get(e)),Tm=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},Om=(e,t,n,o)=>(ZP(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),gi,wf,V1,B1;class JP{constructor({root:t,features:n={},featureConfigs:o={},defaultValue:r="",onUpdate:s=l=>{},handleCommonActions:i=(l,a)=>{}}){Tm(this,gi,void 0),Tm(this,wf,void 0),Tm(this,V1,void 0),Tm(this,B1,!0);const l=Object.entries({...m5e,...n}).filter(([,u])=>u).map(([u])=>u);Om(this,V1,(typeof t=="string"?document.querySelector(t):t)??document.body),Om(this,gi,CCe.make().config(y5e(l)).config(u=>{u.set(I1,Ms(this,V1)),u.set(x1,r),u.set(lp,{editable:()=>Ms(this,B1)})}).config(u=>{const c=async(d,f)=>await i("handleFileUpload",{ctx:u,files:d,schema:f});u.update(Nc.key,d=>({...d,uploader:c}))}).config(u=>{const c=u.get($2);c.markdownUpdated((d,f,p)=>{f!==p&&s(f)}),c.updated((d,f,p)=>{i("editor_updated",d)})}).use(rke).use(f5e).use(h5e).use(UP).use(GP).use(B5e).use(n5e));const a=[];l.forEach(u=>{const c=o[u];a.push(g5e(u,Ms(this,gi),c))}),Om(this,wf,Promise.all(a))}async create(){return await Ms(this,wf),Ms(this,gi).create()}async destroy(){return await Ms(this,wf),Ms(this,gi).destroy()}get editor(){return Ms(this,gi)}setReadonly(t){return Om(this,B1,!t),this}getMarkdown(){return Ms(this,gi).action(MCe())}getEditor(){return Ms(this,gi)}destroyEditor(){this.destroy()}}gi=new WeakMap;wf=new WeakMap;V1=new WeakMap;B1=new WeakMap;JP.Feature=KP;const z5e=Symbol("editorInfoCtxKey"),j5e=Q({name:"MilkdownProvider",setup:(e,{slots:t})=>{const n=K(null),o=K(void 0),r=K(void 0),s=K(!0);return wt(z5e,{loading:s,dom:n,editor:r,editorFactory:o}),()=>{var i;return k(fe,null,[(i=t.default)==null?void 0:i.call(t)])}}});var H5e=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},XP=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},E2=(e,t,n)=>(H5e(e,t,"access private method"),n),z1,x2;let U5e=class{constructor({node:t,view:n,getPos:o,decorations:r,innerDecorations:s,options:i}){XP(this,z1),this.selected=!1,this.selectNode=()=>{var l,a;this.selected=!0,(a=(l=this.options).selectNode)==null||a.call(l)},this.deselectNode=()=>{var l,a;this.selected=!1,(a=(l=this.options).deselectNode)==null||a.call(l)},this.shouldUpdate=l=>!(l.type!==this.node.type||l.sameMarkup(this.node)&&l.content.eq(this.node.content)),this.update=(l,a,u)=>{var c,d;const f=this.options.update;let p;return f&&(p=f(l,a,u)),typeof p!="boolean"&&(p=this.shouldUpdate(l)),this.node=l,this.decorations=a,this.innerDecorations=u,p&&((d=(c=this.options).onUpdate)==null||d.call(c)),p},this.shouldIgnoreMutation=l=>!this.dom||!this.contentDOM||this.node.isLeaf||this.node.isAtom?!0:l.type==="selection"?!1:this.contentDOM===l.target&&l.type==="attributes"?!0:!this.contentDOM.contains(l.target),this.ignoreMutation=l=>{if(!this.dom||!this.contentDOM)return!0;let a;const u=this.options.ignoreMutation;return u&&(a=u(l)),typeof a!="boolean"&&(a=this.shouldIgnoreMutation(l)),a},this.destroy=()=>{var l,a,u;(a=(l=this.options).destroy)==null||a.call(l),this.dom.remove(),(u=this.contentDOM)==null||u.remove()},this.setAttrs=l=>{const{dispatch:a,state:u}=this.view,c=this.getPos();if(typeof c=="number")return a(u.tr.setNodeMarkup(c,void 0,{...this.node.attrs,...l}))},this.node=t,this.view=n,this.getPos=o,this.decorations=r,this.innerDecorations=s,this.options=i,this.dom=this.createDOM(i.as),this.contentDOM=t.isLeaf?null:this.createContentDOM(i.contentAs),this.dom.setAttribute("data-node-view-root","true"),this.contentDOM&&(this.contentDOM.setAttribute("data-node-view-content","true"),this.contentDOM.style.whiteSpace="inherit"),this.setSelection=i.setSelection,this.stopEvent=i.stopEvent}createDOM(t){return E2(this,z1,x2).call(this,t)}createContentDOM(t){return E2(this,z1,x2).call(this,t)}get component(){return this.options.component}};z1=new WeakSet,x2=function(e){const{node:t}=this;return e==null?document.createElement(t.isInline?"span":"div"):e instanceof HTMLElement?e:e instanceof Function?e(t):document.createElement(e)};let W5e=class{constructor(t){this.view=t.view,this.options=t.options}get component(){return this.options.component}get root(){var t,n;let o=(n=(t=this.options).root)==null?void 0:n.call(t,this.view.dom);return o||(o=this.view.dom.parentElement??document.body),o}update(t,n){var o,r;this.view=t,this.prevState=n,(r=(o=this.options).update)==null||r.call(o,t,n)}destroy(){var t,n;(n=(t=this.options).destroy)==null||n.call(t)}};var M2,QP;let K5e=class{constructor({pos:t,spec:n,options:o}){XP(this,M2),this.pos=t,this.options=o,this.spec=n,this.dom=E2(this,M2,QP).call(this,o.as),this.dom.setAttribute("data-widget-view-root","true")}bind(t,n){this.view=t,this.getPos=n}get component(){return this.options.component}};M2=new WeakSet,QP=function(e){return e instanceof HTMLElement?e:document.createElement(e)};let Ik=(e=21)=>crypto.getRandomValues(new Uint8Array(e)).reduce((t,n)=>(n&=63,n<36?t+=n.toString(36):n<62?t+=(n-26).toString(36).toUpperCase():n>62?t+="-":t+="_",t),"");var q5e=Object.defineProperty,G5e=(e,t,n)=>t in e?q5e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Nr=(e,t,n)=>(G5e(e,typeof t!="symbol"?t+"":t,n),n);const Y5e=Symbol("[ProsemirrorAdapter]nodeViewContext"),Z5e=Symbol("[ProsemirrorAdapter]useNodeViewFactory");let J5e=class extends U5e{constructor(){super(...arguments),Nr(this,"key",Ik()),Nr(this,"context",{contentRef:t=>{t&&t instanceof HTMLElement&&this.contentDOM&&t.firstChild!==this.contentDOM&&t.appendChild(this.contentDOM)},view:this.view,getPos:this.getPos,setAttrs:this.setAttrs,node:Tn(this.node),selected:Tn(this.selected),decorations:Tn(this.decorations),innerDecorations:Tn(this.innerDecorations)}),Nr(this,"updateContext",()=>{Object.entries({node:this.node,selected:this.selected,decorations:this.decorations,innerDecorations:this.innerDecorations}).forEach(([t,n])=>{const o=this.context[t];o.value!==n&&(o.value=n)})}),Nr(this,"render",()=>{const t=this.component;return Ii(Q({name:"ProsemirrorNodeView",setup:()=>(wt(Y5e,this.context),()=>k(_s,{key:this.key,to:this.dom},{default:()=>[k(t,null,null)]}))}))})}};const X5e=(e,t)=>n=>(o,r,s,i,l)=>{const a=new J5e({node:o,view:r,getPos:s,decorations:i,innerDecorations:l,options:{...n,onUpdate(){var u;(u=n.onUpdate)==null||u.call(n),a.updateContext()},selectNode(){var u;(u=n.selectNode)==null||u.call(n),a.updateContext()},deselectNode(){var u;(u=n.deselectNode)==null||u.call(n),a.updateContext()},destroy(){var u;(u=n.destroy)==null||u.call(n),t(a)}}});return e(a),a},Q5e=Symbol("[ProsemirrorAdapter]nodeViewContext"),e8e=Symbol("[ProsemirrorAdapter]usePluginViewFactory");let t8e=class extends W5e{constructor(){super(...arguments),Nr(this,"key",Ik()),Nr(this,"context",{view:Tn(this.view),prevState:Tn(this.prevState)}),Nr(this,"updateContext",()=>{Object.entries({view:this.view,prevState:this.prevState}).forEach(([t,n])=>{const o=this.context[t];if(t==="view"){const r=Object.assign(Object.create(Object.getPrototypeOf(n)),n);o.value=r;return}o.value=n})}),Nr(this,"render",()=>{const t=this.component;return Ii(Q({name:"ProsemirrorNodeView",setup:()=>(wt(Q5e,this.context),()=>k(_s,{key:this.key,to:this.root},{default:()=>[k(t,null,null)]}))}))})}};const n8e=(e,t)=>n=>o=>{const r=new t8e({view:o,options:{...n,update:(s,i)=>{var l;(l=n.update)==null||l.call(n,s,i),r.updateContext()},destroy:()=>{var s;(s=n.destroy)==null||s.call(n),t(r)}}});return e(r),r},o8e=()=>{const e=K({}),t=at(),n=Ii({});return yd(()=>{n.updater=()=>{t==null||t.update()}}),ti(()=>{n.updater=void 0}),{portals:e,renderVueRenderer:o=>{var r;e.value[o.key]=o.render(),(r=n.updater)==null||r.call(n)},removeVueRenderer:o=>{delete e.value[o.key]}}},r8e=Symbol("[ProsemirrorAdapter]widgetViewContext"),s8e=Symbol("[ProsemirrorAdapter]useWidgetViewFactory");class i8e extends K5e{constructor(){super(...arguments),Nr(this,"key",Ik()),Nr(this,"context",{view:this.view,getPos:this.getPos,spec:this.spec}),Nr(this,"updateContext",()=>{Object.assign(this.context,{view:this.view,getPos:this.getPos,spec:this.spec})}),Nr(this,"render",()=>{const t=this.component;return Ii(Q({name:"ProsemirrorWidgetView",setup:()=>(wt(r8e,this.context),()=>k(_s,{key:this.key,to:this.dom},{default:()=>[k(t,null,null)]}))}))})}}const l8e=(e,t)=>n=>(o,r={})=>{const s=new i8e({pos:o,options:n}),i={...r,destroy:l=>{var a;(a=r.destroy)==null||a.call(r,l),t(s)}};return s.spec=i,zn.widget(o,(l,a)=>(s.bind(l,a),s.updateContext(),e(s),s.dom),i)},a8e=Q({name:"ProsemirrorAdapterProvider",setup:(e,{slots:t})=>{const{portals:n,renderVueRenderer:o,removeVueRenderer:r}=o8e(),s=X5e(o,r),i=n8e(o,r),l=l8e(o,r);return wt(Z5e,s),wt(e8e,i),wt(s8e,l),()=>{var a;return k(fe,null,[(a=t.default)==null?void 0:a.call(t),Object.values(n.value).map(u=>lt(u))])}}}),u8e={name:"CrepeEditor",emits:["update:modelValue","handleMediaUpload","editorCreated"],props:{modelValue:{type:String,default:""},placeholder:{type:String,default:"Type your message here!"},autofocus:{type:Boolean,default:!1},mentionQuery:{type:Object,default:()=>({})},autofocus_changed:{type:Boolean,default:!1},disable_mention:{type:Boolean,default:!1},disable_media:{type:Boolean,default:!1},defaultMentions:{type:Array,default:()=>[]},hasEveyoneMention:{type:Boolean,default:!1}},components:{MilkdownProvider:j5e,ProsemirrorAdapterProvider:a8e},data(){return{editor:null,currentContent:"",showMentionPop:!1,currentMentionSearch:"",mentionResults:[],justReplaced:!1,searchingMention:!1}},watch:{autofocus_changed(e){e&&this.focusOnEditor()}},methods:{updateContent(e){this.editor.action(t=>{const n=t.get(bn),{state:o}=n,{from:r}=o.selection,s=e,i=o.tr.insertText(s,r),l=r+s.length,a=i.setSelection(ht.create(i.doc,l));n.dispatch(a),n.focus()})},initEditor(){const e=this,t=new JP({root:this.$refs.crepe_editor_vue,defaultValue:this.modelValue,featureConfigs:{placeholder:{text:this.placeholder,mode:"doc"}},onUpdate(n){e.$emit("update:modelValue",n),e.currentContent=n},async handleCommonActions(n,o){if(n==="editor_updated"){if(e.disable_mention)return!1;e.checkforMention(o)}else if(n="handleFileUpload")return e.disable_media?[]:await e.handleFileUpload(o)}});t.create().then(()=>{this.focusOnEditor(),this.$emit("editorCreated"),this.editor=t.getEditor()})},focusOnEditor(){if(!this.autofocus)return;const e=this.$refs.crepe_editor_vue;if(e.querySelector(".ProseMirror")){let t=e.querySelector(".ProseMirror");if(t.focus(),t.hasChildNodes()){let n=window.getSelection(),o=document.createRange(),r=t.childElementCount>0?t.lastChild:t;o.setStart(r,1),o.setEnd(r,1),n.removeAllRanges(),n.addRange(o)}}},checkforMention(e){if(!this.currentContent.includes("@")||this.justReplaced){this.showMentionPop=!1,this.currentMentionSearch="";return}const n=e.get(bn),{state:o}=n,{selection:r}=o;if(!r)return;const i=o.doc.textBetween(0,r.to," ").match(/@([\w-_]+)$/);if(!i){this.showMentionPop=!1,this.currentMentionSearch="";return}let l=i[1];if(!l||l.length<3){if(this.defaultMentions&&this.defaultMentions.length){let a=l.toLowerCase(),u=this.defaultMentions.filter(c=>c.username.toLowerCase().includes(a)||c.display_name.toLowerCase().includes(a));u.length&&(this.currentMentionSearch=l,this.mentionResults=u,this.showMentionPop=!0)}return}if(this.currentMentionSearch&&(this.currentMentionSearch=l,this.searchingMention))return!1;this.searchingMention=!0,this.currentMentionSearch=l,this.$get("members",{mention:this.currentMentionSearch,...this.mentionQuery}).then(a=>{this.mentionResults=a.members.data,this.showMentionPop=!0}).finally(()=>{this.searchingMention=!1})},addMention(e){this.disable_mention||(this.currentContent=this.currentContent.replace("@"+this.currentMentionSearch,e+" "),this.editor.action(TCe(this.currentContent)),this.focusOnEditor(),this.showMentionPop=!1,this.currentMentionSearch="",this.justReplaced=!0,setTimeout(()=>{this.justReplaced=!1},2e3))},async handleFileUpload(e){const t=e.files;for(let n=0;n<t.length;n++){const o=t.item(n);o&&o.type.includes("image")&&this.$emit("handleMediaUpload",o)}return[]}},mounted(){this.initEditor()},beforeUnmount(){this.editor&&this.editor.destroy()}},c8e={style:{position:"relative"},class:"fcom_md_editor"},d8e={ref:"crepe_editor_vue",class:"crepe-editor feed_md_content fcom_md_seditor_wrapper"},f8e={class:"fcom_mention_pop_wrap"},p8e=b("span",{style:{}},null,-1),h8e={key:0},m8e={key:0},g8e=["onClick"],v8e=["src"],y8e={key:1},_8e={key:0};function b8e(e,t,n,o,r,s){const i=re("ProsemirrorAdapterProvider"),l=re("MilkdownProvider"),a=Po;return C(),M(fe,null,[k(l,null,{default:$(()=>[k(i,null,{default:$(()=>[b("div",c8e,[b("div",d8e,null,512)])]),_:1})]),_:1}),b("div",f8e,[k(a,{"popper-class":"fcom_mention_pop",ref:"mentionPopoverRef",placement:"bottom",visible:r.showMentionPop,width:300,persistent:!1},{reference:$(()=>[p8e]),default:$(()=>[r.justReplaced?W("",!0):(C(),M("div",h8e,[r.mentionResults.length?(C(),M("ul",m8e,[(C(!0),M(fe,null,nt(r.mentionResults,u=>(C(),M("li",{key:u.user_id,onClick:c=>s.addMention("@"+u.username)},[b("img",{alt:"",src:u.avatar},null,8,v8e),b("span",null,"@"+A(u.display_name)+" ("+A(u.username)+")",1)],8,g8e))),128))])):r.searchingMention?W("",!0):(C(),M("div",y8e,[b("p",null,[ne(A(e.$t("No results found. Please search by username"))+" ",1),e.isAdmin()&&n.hasEveyoneMention?(C(),M("span",_8e,A(e.$t("You can use @everyone to tag everyone.")),1)):W("",!0)])]))]))]),_:1},8,["visible"])])],64)}const eL=qe(u8e,[["render",b8e]]),w8e={name:"EmailNotification",components:{CrepeEditor:eL,Layout:ri,AppLayout:si},data(){return{loading:!1,saving:!1,email_settings:null}},methods:{getSettings(){this.loading=!0,this.$get("admin/email-settings").then(e=>{this.email_settings=e.email_settings}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},save(){this.saving=!0,this.$post("admin/email-settings",{email_settings:this.email_settings}).then(e=>{this.$notify.success(e.message)}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})}},mounted(){this.getSettings(),this.changeTitle(this.$t("Email Notification Settings"))}},C8e={style:{"margin-bottom":"20px"},class:"settings_router"},k8e={key:0,class:"white_loaded"},S8e={key:1,class:"fhr_content_layout_body"},$8e={class:"setting_body"},E8e={style:{"font-size":"18px",margin:"0",padding:"0"}},x8e={style:{margin:"5px 0","font-size":"90%","line-height":"120%"}},M8e=b("hr",null,null,-1),T8e={class:"fcom_help_text"},O8e={class:"fcom_help_text"},I8e={class:"fcom_help_text"},A8e={class:"fcom_help_text"},N8e={class:"fcom_extra_editor"},P8e={class:"fcom_help_text"},L8e=["innerHTML"],R8e=b("hr",null,null,-1),D8e={class:"setting_body"},F8e={style:{"font-size":"18px",margin:"0",padding:"0"}},V8e={style:{margin:"5px 0","font-size":"90%","line-height":"120%"}},B8e=b("hr",null,null,-1),z8e={key:0,class:"fcom_help_text"},j8e={key:0,class:"fcom_help_text"},H8e={key:0,class:"fcom_help_text"},U8e={class:"fcom_help_text"},W8e={key:0,class:"fcom_help_text"},K8e={class:"fcom_meta_text"},q8e=b("hr",null,null,-1),G8e={class:"setting_body"},Y8e={key:2};function Z8e(e,t,n,o,r,s){const i=pt,l=lo,a=At,u=io,c=vh,d=gh,f=re("crepe-editor"),p=Hn,h=Ss,m=vr,y=AO,v=so,w=re("layout"),_=re("app-layout"),S=zt("loading");return C(),q(_,{wrapper_class:"fcom_single_layout fcom_member_profile fcom_max_layout"},{default:$(()=>[k(w,{wrapper_class:"no_bg_layout fcom_setting_route",title:e.$t("Email Settings")},{actions:$(()=>[He((C(),q(i,{class:"fcom_primary_button",onClick:s.save},{default:$(()=>[b("span",null,A(e.$t("Save Settings")),1)]),_:1},8,["onClick"])),[[S,r.saving]])]),default:$(()=>[b("div",C8e,[r.loading?(C(),M("div",k8e,[k(l,{rows:5,animated:!0})])):r.email_settings?(C(),M("div",S8e,[k(v,{onSubmit:t[12]||(t[12]=et(x=>e.doNothing(),["prevent"])),modelValue:r.email_settings,"onUpdate:modelValue":t[13]||(t[13]=x=>r.email_settings=x),"label-position":"top"},{default:$(()=>[b("div",$8e,[b("h3",E8e,A(e.$t("Mailing Settings")),1),b("p",x8e,A(e.$t("Set your from name, email and email footer. These configuration will be used to send any emails from FluentCommunity.")),1),M8e,k(d,{gutter:30},{default:$(()=>[k(c,{sm:24,md:12},{default:$(()=>[k(u,{label:e.$t("From Name")},{default:$(()=>[k(a,{placeholder:e.$t("Email from name"),modelValue:r.email_settings.send_from_name,"onUpdate:modelValue":t[0]||(t[0]=x=>r.email_settings.send_from_name=x)},null,8,["placeholder","modelValue"]),b("div",T8e,[b("p",null,A(e.$t("Name that will be used to send emails")),1)])]),_:1},8,["label"])]),_:1}),k(c,{sm:24,md:12},{default:$(()=>[k(u,{label:e.$t("From Email")},{default:$(()=>[k(a,{placeholder:e.$t("Valid Email address"),modelValue:r.email_settings.send_from_email,"onUpdate:modelValue":t[1]||(t[1]=x=>r.email_settings.send_from_email=x)},null,8,["placeholder","modelValue"]),b("div",O8e,[b("p",null,A(e.$t("Provide Valid Email Address email as per your domain/SMTP settings. This email will be used to send emails like notifications")),1)])]),_:1},8,["label"])]),_:1})]),_:1}),k(d,{gutter:30},{default:$(()=>[k(c,{sm:24,md:12},{default:$(()=>[k(u,{label:e.$t("Reply to name (Optional)")},{default:$(()=>[k(a,{placeholder:e.$t("Optional Reply to email"),modelValue:r.email_settings.reply_to_name,"onUpdate:modelValue":t[2]||(t[2]=x=>r.email_settings.reply_to_name=x)},null,8,["placeholder","modelValue"]),b("div",I8e,[b("p",null,A(e.$t("Name that will be used for replyTo attribute")),1)])]),_:1},8,["label"])]),_:1}),k(c,{sm:24,md:12},{default:$(()=>[k(u,{label:e.$t("Reply to email (optional)")},{default:$(()=>[k(a,{placeholder:e.$t("Optional email"),modelValue:r.email_settings.reply_to_email,"onUpdate:modelValue":t[3]||(t[3]=x=>r.email_settings.reply_to_email=x)},null,8,["placeholder","modelValue"]),b("div",A8e,[b("p",null,A(e.$t("If someone reply to your notification email, this is where you would like to recieve")),1)])]),_:1},8,["label"])]),_:1})]),_:1}),k(u,{label:e.$t("Email Footer")},{default:$(()=>[b("div",N8e,[k(f,{modelValue:r.email_settings.email_footer,"onUpdate:modelValue":t[4]||(t[4]=x=>r.email_settings.email_footer=x),height:200},null,8,["modelValue"])]),b("div",P8e,[b("p",null,A(e.$t("This email footer will be used to send all the emails sent from FleuntCommuntiy. It's highly recommended to use your business name and address in the footer for compliance.")),1),b("p",{innerHTML:e.$t("Use %1s tag to insert dynamic notification settings URL. Other Smartcode: %2s for Site Name with permalink","{{manage_email_notification_url|Manage Your Email Notifications Preference}}","{{site_name_with_url}}")},null,8,L8e)])]),_:1},8,["label"]),e.has_pro?(C(),q(u,{key:0},{default:$(()=>[k(p,{modelValue:r.email_settings.disable_powered_by,"onUpdate:modelValue":t[5]||(t[5]=x=>r.email_settings.disable_powered_by=x),"true-label":"yes","false-label":"no"},{default:$(()=>[ne(A(e.$t("Disable powered by FluentCommunity in the email footer")),1)]),_:1},8,["modelValue"])]),_:1})):W("",!0)]),R8e,b("div",D8e,[b("h3",F8e,A(e.$t("Email Notification Settings")),1),b("p",V8e,A(e.$t("This is the default settings that will be applied to all the community members. Individual members can over-write the settings for their own preference")),1),B8e,k(u,{label:e.$t("Email on new comment")},{default:$(()=>[k(p,{modelValue:r.email_settings.com_my_post_mail,"onUpdate:modelValue":t[6]||(t[6]=x=>r.email_settings.com_my_post_mail=x),"true-value":"yes","false-value":"no"},{default:$(()=>[ne(A(e.$t("Send email to author when a new comment added to a post")),1)]),_:1},8,["modelValue"]),r.email_settings.com_my_post_mail!="yes"?(C(),M("div",z8e,[b("p",null,A(e.$t("You should enable this. Currently disabled.")),1)])):W("",!0)]),_:1},8,["label"]),k(u,{label:e.$t("Email on comment reply")},{default:$(()=>[k(p,{modelValue:r.email_settings.reply_my_com_mail,"onUpdate:modelValue":t[7]||(t[7]=x=>r.email_settings.reply_my_com_mail=x),"true-value":"yes","false-value":"no"},{default:$(()=>[ne(A(e.$t("Email authors when someone reply to their comments")),1)]),_:1},8,["modelValue"]),r.email_settings.reply_my_com_mail!="yes"?(C(),M("div",j8e,[b("p",null,A(e.$t("You should enable this. Currently disabled.")),1)])):W("",!0)]),_:1},8,["label"]),k(u,{label:e.$t("Email on Tagging / Mentioning")},{default:$(()=>[k(p,{modelValue:r.email_settings.mention_mail,"onUpdate:modelValue":t[8]||(t[8]=x=>r.email_settings.mention_mail=x),"true-value":"yes","false-value":"no"},{default:$(()=>[ne(A(e.$t("Send email when an admin/moderator tag (@everyone) on a post or when tagging someone in a post or comment")),1)]),_:1},8,["modelValue"]),r.email_settings.mention_mail!="yes"?(C(),M("div",H8e,[b("p",null,A(e.$t("You should enable this. Currently disabled.")),1)])):W("",!0)]),_:1},8,["label"]),k(u,null,{default:$(()=>[k(p,{"true-value":"yes","false-value":"no",modelValue:r.email_settings.digest_email_status,"onUpdate:modelValue":t[9]||(t[9]=x=>r.email_settings.digest_email_status=x)},{default:$(()=>[ne(A(e.$t("Enable Weekly Digest Email for community members")),1)]),_:1},8,["modelValue"]),b("div",U8e,[b("p",null,A(e.$t("Members can enable/disable their own digest status")),1)])]),_:1}),k(d,{gutter:30},{default:$(()=>[k(c,{sm:24,md:12},{default:$(()=>[k(u,{label:e.$t("In which day, the digest email will be sent")},{default:$(()=>[k(m,{modelValue:r.email_settings.digest_mail_day,"onUpdate:modelValue":t[10]||(t[10]=x=>r.email_settings.digest_mail_day=x),placeholder:e.$t("Select Digest Email Day")},{default:$(()=>[k(h,{value:"mon",label:e.$t("Every Monday")},null,8,["label"]),k(h,{value:"tue",label:e.$t("Every Tuesday")},null,8,["label"]),k(h,{value:"wed",label:e.$t("Every Wednesday")},null,8,["label"]),k(h,{value:"thu",label:e.$t("Every Thursday")},null,8,["label"]),k(h,{value:"fri",label:e.$t("Every Friday")},null,8,["label"]),k(h,{value:"sat",label:e.$t("Every Saturday")},null,8,["label"]),k(h,{value:"sun",label:e.$t("Every Sunday")},null,8,["label"])]),_:1},8,["modelValue","placeholder"]),r.email_settings.digest_email_status=="yes"?(C(),M("div",W8e,[b("p",null,A(e.$t("Email will be sent if there has any unread notifications for the user from the last email sent")),1)])):W("",!0)]),_:1},8,["label"])]),_:1}),k(c,{sm:24,md:12},{default:$(()=>[k(u,{label:e.$t("Time to send the digest email")},{default:$(()=>[k(y,{step:"00:10",start:"00:10",end:"23:59",modelValue:r.email_settings.daily_digest_time,"onUpdate:modelValue":t[11]||(t[11]=x=>r.email_settings.daily_digest_time=x)},null,8,["modelValue"]),b("p",K8e,A(e.$t("Approximate time when the digest emails will start sending for the members")),1)]),_:1},8,["label"])]),_:1})]),_:1})]),q8e,b("div",G8e,[He((C(),q(i,{onClick:s.save,disabled:r.saving,class:"fcom_primary_button"},{default:$(()=>[ne(A(e.$t("Save Settings")),1)]),_:1},8,["onClick","disabled"])),[[S,r.saving]])])]),_:1},8,["modelValue"])])):(C(),M("div",Y8e,[b("p",null,A(e.$t("Settings could not be loaded")),1)]))])]),_:1},8,["title"])]),_:1})}const J8e=qe(w8e,[["render",Z8e]]),X8e={name:"CustomizationSettings",components:{Layout:ri,AppLayout:si},data(){return{loading:!1,saving:!1,settings:null}},methods:{getSettings(){this.loading=!0,this.$get("settings/customization-settings").then(e=>{this.settings=e.settings}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},save(){this.saving=!0,this.$post("settings/customization-settings",{settings:this.settings}).then(e=>{this.$notify.success(e.message),window.location.reload()}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})}},mounted(){this.getSettings(),this.changeTitle(this.$t("Customization Settings"))}},Q8e={class:"settings_router"},eSe={key:0,class:"white_loaded"},tSe={key:1,class:"fhr_content_layout_body"},nSe={class:"setting_body"},oSe={class:"fcom_input_wrap"},rSe={class:"fcom_input_wrap"},sSe={class:"fcom_input_wrap"},iSe={key:0,class:"fcom_input_wrap"},lSe=["innerHTML"],aSe={key:1,style:{cursor:"pointer","font-weight":"bold"}},uSe={class:"fcom_input_wrap"},cSe={style:{"font-weight":"bold"}},dSe={class:"fcom_help_text"},fSe={target:"_blank",rel:"noopener",href:"https://wpmanageninja.com/affiliate/"},pSe={class:"fcom_input_wrap"},hSe={class:"fcom_input_wrap"},mSe={class:"fcom_input_wrap"},gSe={key:0},vSe={class:"fcom_help_text"},ySe={class:"fcom_input_wrap"},_Se={class:"fcom_help_text"},bSe={style:{"margin-top":"50px"},class:"fcom_input_wrap"},wSe={key:2};function CSe(e,t,n,o,r,s){const i=pt,l=lo,a=xie,u=Hn,c=At,d=Po,f=U0,p=Eu,h=io,m=so,y=re("layout"),v=re("app-layout"),w=zt("loading");return C(),q(v,{wrapper_class:"fcom_single_layout fcom_member_profile fcom_max_layout"},{default:$(()=>[k(y,{wrapper_class:"no_bg_layout fcom_setting_route",title:e.$t("Customize your portal")},{actions:$(()=>[He((C(),q(i,{class:"fcom_primary_button",onClick:s.save},{default:$(()=>[b("span",null,A(e.$t("Save Settings")),1)]),_:1},8,["onClick"])),[[w,r.saving]])]),default:$(()=>[b("div",Q8e,[r.loading?(C(),M("div",eSe,[k(l,{rows:5,animated:!0})])):r.settings?(C(),M("div",tSe,[b("div",nSe,[b("p",null,A(e.$t("Customize the UI features of the portal.")),1),k(a),k(m,{onSubmit:t[10]||(t[10]=et(_=>e.doNothing(),["prevent"])),modelValue:r.settings,"onUpdate:modelValue":t[11]||(t[11]=_=>r.settings=_),"label-position":"top"},{default:$(()=>[b("div",oSe,[k(u,{"true-value":"yes","false-value":"no",modelValue:r.settings.dark_mode,"onUpdate:modelValue":t[0]||(t[0]=_=>r.settings.dark_mode=_)},{default:$(()=>[ne(A(e.$t("Enable Dark Mode")),1)]),_:1},8,["modelValue"]),b("p",null,A(e.$t("Enables switching between dark and light interface themes, accommodating different lighting conditions and user preferences.")),1)]),b("div",rSe,[k(u,{"true-value":"yes","false-value":"no",modelValue:r.settings.fixed_page_header,"onUpdate:modelValue":t[1]||(t[1]=_=>r.settings.fixed_page_header=_)},{default:$(()=>[ne(A(e.$t("Enable Sticky Page headers across portal")),1)]),_:1},8,["modelValue"]),b("p",null,A(e.$t("When enabled, the page header will remain visible at the top of the screen as users scroll down the page.")),1)]),b("div",sSe,[k(u,{"true-value":"yes","false-value":"no",modelValue:r.settings.feed_link_on_sidebar,"onUpdate:modelValue":t[2]||(t[2]=_=>r.settings.feed_link_on_sidebar=_)},{default:$(()=>[ne(A(e.$t("Show Default Feed link on left sidebar")),1)]),_:1},8,["modelValue"]),b("p",null,A(e.$t("Adds the default Feed link in the sidebar, providing an extra access point to the all feeds page")),1)]),e.has_pro?(C(),M("div",iSe,[k(u,{"true-value":"yes","false-value":"no",modelValue:r.settings.show_powered_by,"onUpdate:modelValue":t[3]||(t[3]=_=>r.settings.show_powered_by=_)},{default:$(()=>[ne(A(e.$t("Show powered by text")),1)]),_:1},8,["modelValue"]),b("p",null,[ne(A(e.$t("Displays a 'Powered by FluentCommunity' link, showing support for the platform and increasing its visibility."))+" ",1),k(d,{persistent:!1,placement:"bottom",width:400,trigger:"click"},{reference:$(()=>[r.settings.affiliate_id?(C(),M("span",aSe,A(e.$t("Affiliate ID: %s",r.settings.affiliate_id)),1)):(C(),M("span",{key:0,style:{cursor:"pointer"},innerHTML:e.$t("%1sClick here%2s to add affiliate ID","<b>","</b>")},null,8,lSe))]),default:$(()=>[b("div",uSe,[b("label",cSe,A(e.$t("Your affiliate ID")),1),k(c,{style:{margin:"20px 0"},placeholder:e.$t("Affiliate ID"),type:"number",modelValue:r.settings.affiliate_id,"onUpdate:modelValue":t[4]||(t[4]=_=>r.settings.affiliate_id=_)},null,8,["placeholder","modelValue"]),He((C(),q(i,{onClick:s.save,disabled:r.saving,class:"fcom_primary_button"},{default:$(()=>[ne(A(e.$t("Save")),1)]),_:1},8,["onClick","disabled"])),[[w,r.saving]])]),b("div",dSe,[b("p",null,[ne(A(e.$t("Don't have an affiliate account?"))+" ",1),b("a",fSe,A(e.$t("Click here"))+".",1)])])]),_:1})])])):W("",!0),b("div",pSe,[k(u,{"true-value":"yes","false-value":"no",modelValue:r.settings.icon_on_header_menu,"onUpdate:modelValue":t[5]||(t[5]=_=>r.settings.icon_on_header_menu=_)},{default:$(()=>[ne(A(e.$t("Show icon on header menu items")),1)]),_:1},8,["modelValue"]),b("p",null,A(e.$t("Adds icons next to text in header menu items, enhancing visual appeal and improving navigation clarity.")),1)]),W("",!0),b("div",hSe,[k(u,{"true-value":"yes","false-value":"no",modelValue:r.settings.a11y_enhancement_style,"onUpdate:modelValue":t[7]||(t[7]=_=>r.settings.a11y_enhancement_style=_)},{default:$(()=>[ne(A(e.$t("Use Enhanced Color Contrast for Accessibility (a11y)")),1)]),_:1},8,["modelValue"]),b("p",null,A(e.$t("If you enable this, FluentCommunity will use enhanced color contrasts for different UI")),1)]),b("div",mSe,[k(h,{label:e.$t("Rich Media Post Layout")},{default:$(()=>[k(p,{modelValue:r.settings.rich_post_layout,"onUpdate:modelValue":t[8]||(t[8]=_=>r.settings.rich_post_layout=_)},{default:$(()=>[k(f,{value:"classic"},{default:$(()=>[ne(A(e.$t("Classic")),1)]),_:1}),k(f,{disabled:!e.has_pro,value:"modern"},{default:$(()=>[ne(A(e.$t("Modern"))+" ",1),e.has_pro?W("",!0):(C(),M("span",gSe,"("+A(e.$t("Available on pro"))+")",1))]),_:1},8,["disabled"])]),_:1},8,["modelValue"]),b("div",vSe,[b("p",null,A(e.$t("Classic: Image/Video after the content. Modern: Image/Video at first")),1)])]),_:1},8,["label"])]),b("div",ySe,[k(h,{label:e.$t("Post Title Requirements")},{default:$(()=>[k(p,{modelValue:r.settings.post_title_pref,"onUpdate:modelValue":t[9]||(t[9]=_=>r.settings.post_title_pref=_)},{default:$(()=>[k(f,{value:"optional"},{default:$(()=>[ne(A(e.$t("Optional")),1)]),_:1}),k(f,{value:"required"},{default:$(()=>[ne(A(e.$t("Required")),1)]),_:1}),k(f,{value:"disabled"},{default:$(()=>[ne(A(e.$t("Disabled")),1)]),_:1})]),_:1},8,["modelValue"]),b("div",_Se,[b("p",null,A(e.$t("When creating a new post, check if the post title is required or not")),1)])]),_:1},8,["label"])]),b("div",bSe,[He((C(),q(i,{onClick:s.save,disabled:r.saving,class:"fcom_primary_button"},{default:$(()=>[ne(A(e.$t("Save Settings")),1)]),_:1},8,["onClick","disabled"])),[[w,r.saving]])])]),_:1},8,["modelValue"])])])):(C(),M("div",wSe,[b("p",null,A(e.$t("Settings could not be loaded")),1)]))])]),_:1},8,["title"])]),_:1})}const kSe=qe(X8e,[["render",CSe]]),SSe={name:"UpgradeToProModal",props:{showModal:{type:Boolean,default:!0},upgrade_module:{type:String,required:!0}},data(){return{openModal:this.showModal,upgradeModule:F1e[this.upgrade_module]||{}}},watch:{openModal:function(){this.$emit("closeModal")}}},$Se={class:"fcom_upgrade_header"},ESe={class:"dialog_body"},xSe={class:"fcom_upgrade_banner"},MSe=["href"],TSe={class:"fcom_upgrade_content"},OSe={class:"fcom_feature_image"},ISe=["src","alt"],ASe={class:"fcom_upgrade_body"},NSe={class:"fcom_upgrade_description"},PSe=["href"];function LSe(e,t,n,o,r,s){const i=Ql;return C(),q(i,{"modal-class":"fcom_upgrade_dialog","close-on-click-modal":!1,"append-to-body":!0,size:"50%",modelValue:r.openModal,"onUpdate:modelValue":t[0]||(t[0]=l=>r.openModal=l),direction:"rtl"},{header:$(()=>[b("div",$Se,[b("h4",null,A(r.upgradeModule.headerTitle),1),b("p",null,A(r.upgradeModule.headerDescription),1)])]),default:$(()=>[b("div",ESe,[b("div",xSe,[b("p",null," 🎉 "+A(e.$t("Discover exciting new features now!")),1),b("a",{href:e.appVars.upgrade_url,target:"_blank"},A(e.$t("Upgrade Now")),9,MSe)]),b("div",TSe,[b("div",OSe,[b("img",{src:e.appVars.assets_url+"images/upgrades/"+r.upgradeModule.featureImage,alt:r.upgradeModule.headerTitle},null,8,ISe)]),b("div",ASe,[b("h4",null,A(r.upgradeModule.bodyTitle),1),b("p",NSe,A(r.upgradeModule.bodyDescription),1),b("a",{class:"el-button fcom_primary_button",href:e.appVars.upgrade_url,target:"_blank"},A(e.$t("Upgrade to Pro")),9,PSe)])])])]),_:1},8,["modelValue"])}const $v=qe(SSe,[["render",LSe]]),RSe={name:"StorageSettings",props:["features"],components:{UpgradeToProModal:$v},data(){return{openUpgradeModal:!1,storageConfig:!1,showSettings:!1,fetching:!1,saving:!1,s3Locations:{}}},methods:{fetchSettings(){this.fetching=!0,this.$get("admin/storage-settings").then(e=>{this.storageConfig=e.config,this.s3Locations=e.s3_locations}).catch(e=>{this.$handleError(e)}).finally(()=>{this.fetching=!1})},openSettings(){if(!this.has_pro){this.openUpgradeModal=!0;return}this.showSettings=!0},saveSettings(){this.saving=!0,this.$post("admin/storage-settings",{config:this.storageConfig}).then(e=>{this.$notify.success(e.message)}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})},maybeResetConfig(){let e=this.storageConfig.driver;this.storageConfig={driver:e}}},mounted(){this.has_pro&&this.fetchSettings()}},DSe={class:"fcom_storage_settings"},FSe={class:"dialog_header"},VSe={class:"dialog_left"},BSe={key:0,class:"white_loaded"},zSe={key:1,class:"dialog_body"},jSe={key:0},HSe=b("p",null,[ne(" Please "),b("a",{target:"_blank",rel:"noopener",href:"https://github.com/WPManageNinja/fluent-community-docs/blob/master/configure-cloudflare-r2.md"},"Read the documentation first "),ne(" to configure Cloudflare R2. ")],-1),USe=b("hr",null,null,-1),WSe={class:"fcom_cloudflare_settings"},KSe=b("p",null,[ne(" Please "),b("a",{target:"_blank",rel:"noopener",href:"https://github.com/WPManageNinja/fluent-community-docs/blob/master/configure-amazon-s3.md"},"Read the documentation first "),ne(" to configure Amazon S3. ")],-1),qSe=b("hr",null,null,-1),GSe={class:"fcom_s3_settings"},YSe={key:2},ZSe={class:"dialog_footer"},JSe={key:2};function XSe(e,t,n,o,r,s){const i=pt,l=lo,a=L3,u=Eu,c=io,d=At,f=Ss,p=vr,h=so,m=yh,y=re("UpgradeToProModal"),v=zt("loading");return C(),M(fe,null,[b("div",DSe,[k(i,{class:"fcom_secondary_button",onClick:t[0]||(t[0]=w=>s.openSettings())},{default:$(()=>{var w;return[ne(A(e.$t("Configure"))+" ("+A((w=r.storageConfig)==null?void 0:w.driver)+") ",1)]}),_:1})]),k(m,{"modal-class":"fcom_common_dialog",id:"fluent_comminity_body","close-on-click-modal":!1,"append-to-body":!0,width:e.dialogWidth,modelValue:r.showSettings,"onUpdate:modelValue":t[15]||(t[15]=w=>r.showSettings=w),direction:"rtl"},{header:$(({close:w})=>[b("div",FSe,[b("div",VSe,[b("div",null,[b("h4",null,A(e.$t("Configure Media Storage")),1)])])])]),default:$(()=>[r.fetching?(C(),M("div",BSe,[k(l,{rows:5,animated:!0})])):r.storageConfig?(C(),M("div",zSe,[r.storageConfig.is_defined?(C(),M("p",jSe,A(e.$t("__CLOUD_STORAGE_CONFIGURED")),1)):(C(),M(fe,{key:1},[k(h,{onSubmit:t[14]||(t[14]=et(w=>e.doNothing(),["prevent"])),"label-position":"top"},{default:$(()=>[k(c,{label:e.$t("Storage Location")},{default:$(()=>[k(u,{class:"fcom_radio_group",onChange:t[1]||(t[1]=w=>s.maybeResetConfig()),modelValue:r.storageConfig.driver,"onUpdate:modelValue":t[2]||(t[2]=w=>r.storageConfig.driver=w)},{default:$(()=>[k(a,{type:"primary",value:"local"},{default:$(()=>[ne(A(e.$t("Server Storage")),1)]),_:1}),k(a,{value:"cloudflare_r2"},{default:$(()=>[ne(A(e.$t("Cloudflare R2 (Recommended)")),1)]),_:1}),k(a,{value:"amazon_s3"},{default:$(()=>[ne(A(e.$t("Amazon S3")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["label"]),r.storageConfig.driver==="cloudflare_r2"?(C(),M(fe,{key:0},[HSe,USe,b("div",WSe,[k(c,{label:e.$t("Cloudflare Account ID")},{default:$(()=>[k(d,{placeholder:"eg: 1718cb5a51e65c8f19e8eec44a012hd32",modelValue:r.storageConfig.account_id,"onUpdate:modelValue":t[3]||(t[3]=w=>r.storageConfig.account_id=w)},null,8,["modelValue"])]),_:1},8,["label"]),k(c,{label:e.$t("Cloudflare Access Key")},{default:$(()=>[k(d,{type:"password",modelValue:r.storageConfig.access_key,"onUpdate:modelValue":t[4]||(t[4]=w=>r.storageConfig.access_key=w)},null,8,["modelValue"])]),_:1},8,["label"]),k(c,{label:e.$t("Cloudflare Secret Key")},{default:$(()=>[k(d,{type:"password",modelValue:r.storageConfig.secret_key,"onUpdate:modelValue":t[5]||(t[5]=w=>r.storageConfig.secret_key=w)},null,8,["modelValue"])]),_:1},8,["label"]),k(c,{label:e.$t("Cloudflare Bucket Name")},{default:$(()=>[k(d,{modelValue:r.storageConfig.bucket,"onUpdate:modelValue":t[6]||(t[6]=w=>r.storageConfig.bucket=w)},null,8,["modelValue"])]),_:1},8,["label"]),k(c,{label:e.$t("Cloudflare Bucket Public URL")},{default:$(()=>[k(d,{modelValue:r.storageConfig.public_url,"onUpdate:modelValue":t[7]||(t[7]=w=>r.storageConfig.public_url=w)},null,8,["modelValue"])]),_:1},8,["label"]),k(c,{label:e.$t("Bucket Sub-Folder (Optional)")},{default:$(()=>[k(d,{placeholder:e.$t("If you want to stores files a folder in the bucket"),modelValue:r.storageConfig.sub_folder,"onUpdate:modelValue":t[8]||(t[8]=w=>r.storageConfig.sub_folder=w)},null,8,["placeholder","modelValue"])]),_:1},8,["label"])])],64)):r.storageConfig.driver==="amazon_s3"?(C(),M(fe,{key:1},[KSe,qSe,b("div",GSe,[k(c,{label:e.$t("Amazon S3 Access Key")},{default:$(()=>[k(d,{type:"password",modelValue:r.storageConfig.access_key,"onUpdate:modelValue":t[9]||(t[9]=w=>r.storageConfig.access_key=w)},null,8,["modelValue"])]),_:1},8,["label"]),k(c,{label:e.$t("Amazon S3 Secret Key")},{default:$(()=>[k(d,{type:"password",modelValue:r.storageConfig.secret_key,"onUpdate:modelValue":t[10]||(t[10]=w=>r.storageConfig.secret_key=w)},null,8,["modelValue"])]),_:1},8,["label"]),k(c,{label:e.$t("Amazon S3 Bucket Name")},{default:$(()=>[k(d,{modelValue:r.storageConfig.bucket,"onUpdate:modelValue":t[11]||(t[11]=w=>r.storageConfig.bucket=w)},null,8,["modelValue"])]),_:1},8,["label"]),k(c,{label:e.$t("Amazon S3 Location")},{default:$(()=>[k(p,{modelValue:r.storageConfig.s3_endpoint,"onUpdate:modelValue":t[12]||(t[12]=w=>r.storageConfig.s3_endpoint=w),placeholder:e.$t("Select S3 Location")},{default:$(()=>[(C(!0),M(fe,null,nt(r.s3Locations,(w,_)=>(C(),q(f,{label:w,value:_},null,8,["label","value"]))),256))]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),k(c,{label:e.$t("Bucket Sub-Folder (Optional)")},{default:$(()=>[k(d,{placeholder:e.$t("If you want to stores files a folder in the bucket"),modelValue:r.storageConfig.sub_folder,"onUpdate:modelValue":t[13]||(t[13]=w=>r.storageConfig.sub_folder=w)},null,8,["placeholder","modelValue"])]),_:1},8,["label"])])],64)):(C(),M("p",YSe,A(e.$t("Your files will be stored in the default Uploads folder")),1))]),_:1}),b("div",ZSe,[He((C(),q(i,{class:"fcom_primary_button",disabled:r.saving,onClick:s.saveSettings},{default:$(()=>[ne(A(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])),[[v,r.saving]])])],64))])):(C(),M("div",JSe,[b("p",null,A(e.$t("Config could not be loaded")),1)]))]),_:1},8,["width","modelValue"]),r.openUpgradeModal?(C(),q(y,{key:0,showModal:r.openUpgradeModal,onCloseModal:t[16]||(t[16]=w=>r.openUpgradeModal=!1),upgrade_module:"media_module"},null,8,["showModal"])):W("",!0)],64)}const QSe=qe(RSe,[["render",XSe]]),e9e={name:"LeaderBoardConfig",props:["features"],emits:["saveSettings"],data(){return{levels:null,showSettings:!1,fetching:!1,saving:!1,openUpgradeModal:!1}},components:{UpgradeToProModal:$v},methods:{openSettings(){if(!this.has_pro){this.openUpgradeModal=!0;return}this.fetchSettings(),this.showSettings=!0},fetchSettings(){this.fetching=!0,this.$get("admin/leaderboards/levels").then(e=>{this.levels=e.levels}).catch(e=>{this.$handleError(e)}).finally(()=>{this.fetching=!1})},saveSettings(){let e=this.features.leader_board_module=="yes";this.$emit("saveSettings",!e),e&&this.saveLevelSettings()},saveLevelSettings(){this.saving=!0,this.$post("admin/leaderboards/levels",{levels:this.levels}).then(e=>{this.$notify.success(e.message),this.$emit("saveSettings",!0)}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})}}},t9e={class:"fcom_storage_settings"},n9e={key:0,class:"white_loaded"},o9e={key:1,class:"dialog_body"},r9e={class:"fcom_level_table"},s9e={class:"fcom_level_table_row fcom_header_row"},i9e=b("div",{class:"fcom_lavel_num"}," # ",-1),l9e={class:"fcom_lavel_desc"},a9e={class:"fcom_lavel_actions"},u9e={class:"fcom_lavel_num"},c9e={class:"fcom_lavel_desc"},d9e={class:"fcom_lavel_actions"},f9e={class:"dialog_footer"},p9e={key:2};function h9e(e,t,n,o,r,s){const i=pt,l=lo,a=Hn,u=io,c=At,d=so,f=Ql,p=re("UpgradeToProModal"),h=zt("loading");return C(),M(fe,null,[b("div",t9e,[k(i,{class:"fcom_secondary_button",onClick:t[0]||(t[0]=m=>s.openSettings())},{default:$(()=>[ne(A(e.$t("Settings")),1)]),_:1})]),k(f,{"modal-class":"fcom_common_dialog",id:"fluent_comminity_body","close-on-click-modal":!1,"append-to-body":!0,size:e.dialogWidth,modelValue:r.showSettings,"onUpdate:modelValue":t[3]||(t[3]=m=>r.showSettings=m),direction:"rtl"},{header:$(({close:m})=>[b("h4",null,A(e.$t("Leaderboard / Gamification Settings")),1)]),default:$(()=>[r.fetching?(C(),M("div",n9e,[k(l,{rows:5,animated:!0})])):r.levels?(C(),M("div",o9e,[k(d,{onSubmit:t[2]||(t[2]=et(m=>e.doNothing(),["prevent"])),"label-position":"top"},{default:$(()=>[k(u,null,{default:$(()=>[k(a,{modelValue:n.features.leader_board_module,"onUpdate:modelValue":t[1]||(t[1]=m=>n.features.leader_board_module=m),"true-label":"yes","false-label":"no",label:e.$t("Enable Leaderboards Module")},null,8,["modelValue","label"])]),_:1}),n.features.leader_board_module==="yes"?(C(),M(fe,{key:0},[b("h5",null,A(e.$t("Leaderboard Levels")),1),b("div",r9e,[b("div",s9e,[i9e,b("div",l9e,A(e.$t("Title & Description")),1),b("div",a9e,A(e.$t("Minimum Points")),1)]),(C(!0),M(fe,null,nt(r.levels,(m,y,v)=>(C(),M("div",{class:"fcom_level_table_row",key:y},[b("div",u9e,A(v+1),1),b("div",c9e,[k(c,{class:"fcom_bold_input",type:"text",modelValue:m.title,"onUpdate:modelValue":w=>m.title=w,placeholder:e.$t("Level Title")},null,8,["modelValue","onUpdate:modelValue","placeholder"]),k(c,{type:"text",modelValue:m.tagline,"onUpdate:modelValue":w=>m.tagline=w,placeholder:e.$t("Level Tagline")},null,8,["modelValue","onUpdate:modelValue","placeholder"])]),b("div",d9e,[k(u,{label:""},{default:$(()=>[k(c,{min:0,max:999999999,disabled:y==="level_1",type:"number",modelValue:m.min_points,"onUpdate:modelValue":w=>m.min_points=w,placeholder:e.$t("Minimum Points")},null,8,["disabled","modelValue","onUpdate:modelValue","placeholder"])]),_:2},1024)])]))),128))])],64)):W("",!0)]),_:1}),b("div",f9e,[He((C(),q(i,{class:"fcom_primary_button",disabled:r.saving,onClick:s.saveSettings},{default:$(()=>[ne(A(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])),[[h,r.saving]])])])):(C(),M("div",p9e,[b("p",null,A(e.$t("Config could not be loaded")),1)]))]),_:1},8,["size","modelValue"]),r.openUpgradeModal?(C(),q(p,{key:0,showModal:r.openUpgradeModal,onCloseModal:t[4]||(t[4]=m=>r.openUpgradeModal=!1),upgrade_module:"leader_board_module"},null,8,["showModal"])):W("",!0)],64)}const m9e=qe(e9e,[["render",h9e]]),g9e={name:"SvgShapeGenerator",emits:["update"],data(){return{currentColor:"",selectedShape:"circle",predefineColors:["#8000FF","#ff4500","#ff8c00","#ffd700","#90ee90","#0080FF","#1e90ff","#0000FF","#FFFF00","#BFFF00","#00FF00","#00FFBF","#00ced1","#00FFFF"]}},computed:{svgShapes(){return{circle:`<svg viewBox="0 0 24 24" fill="${this.currentColor}" width="24px" height="24px"><path d="M0 0h24v24H0z" fill="none"/><circle cx="12" cy="12" r="12"/></svg>`,square:`<svg viewBox="0 0 24 24" fill="${this.currentColor}" width="24px" height="24px"><path d="M0 0h24v24H0z" fill="none"/><rect x="0" y="0" width="24" height="24"/></svg>`,triangle:`<svg viewBox="0 0 24 24" fill="${this.currentColor}" width="24px" height="24px"><path d="M0 0h24v24H0z" fill="none"/><path d="M21 12L2 2v20z"/></svg>`,star:`<svg viewBox="0 0 24 24" width="24" height="24"><polygon points="12,2.4 14.6,8.4 21.6,8.4 15.6,13.2 18,19.6 12,15.6 6,19.6 8.4,13.2 2.4,8.4 9.4,8.4" fill="${this.currentColor}"/></svg>`,heart:`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path d="M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z" fill="${this.currentColor}"/></svg>`,diamond:`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><polygon points="12,2 22,12 12,22 2,12" fill="${this.currentColor}"/></svg>`}}},methods:{selectShape(e){this.selectedShape=e,this.$emit("update",this.svgShapes[e])},colorChanged(e){this.currentColor=e,this.$emit("update",this.svgShapes[this.selectedShape])}}},v9e={class:"fcom_svg_generator"},y9e={class:"fcom_form_item"},_9e={class:"fcom_form_item"},b9e=["innerHTML"];function w9e(e,t,n,o,r,s){const i=R3,l=L3,a=Eu;return C(),M("div",v9e,[b("div",y9e,[b("label",null,A(e.$t("Select Shape Color:")),1),k(i,{predefine:r.predefineColors,modelValue:r.currentColor,"onUpdate:modelValue":t[0]||(t[0]=u=>r.currentColor=u),onActiveChange:s.colorChanged,size:"large","show-alpha":""},null,8,["predefine","modelValue","onActiveChange"])]),b("div",_9e,[b("label",null,A(e.$t("Select Shape:")),1),k(a,{onChange:t[1]||(t[1]=u=>s.selectShape(r.selectedShape)),modelValue:r.selectedShape,"onUpdate:modelValue":t[2]||(t[2]=u=>r.selectedShape=u)},{default:$(()=>[(C(!0),M(fe,null,nt(s.svgShapes,(u,c)=>(C(),q(l,{key:c,value:c},{default:$(()=>[b("div",{innerHTML:u},null,8,b9e)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])])])}const C9e=qe(g9e,[["render",w9e]]);var Ak="emoji-mart";const k9e=JSON;var tL=typeof window<"u"&&"localStorage"in window;let T2,O2;function S9e(e){e||(e={}),T2=e.getter,O2=e.setter}function $9e(e){Ak=e}function E9e(e){for(let t in e){let n=e[t];nL(t,n)}}function nL(e,t){if(O2)O2(e,t);else{if(!tL)return;try{window.localStorage[`${Ak}.${e}`]=k9e.stringify(t)}catch{}}}function x9e(e){if(T2)return T2(e);if(!tL)return;try{var t=window.localStorage[`${Ak}.${e}`]}catch{return}if(t)return JSON.parse(t)}const hd={update:E9e,set:nL,get:x9e,setNamespace:$9e,setHandlers:S9e},o_={name:"a",unified:"b",non_qualified:"c",has_img_apple:"d",has_img_google:"e",has_img_twitter:"f",has_img_facebook:"h",keywords:"j",sheet:"k",emoticons:"l",text:"m",short_names:"n",added_in:"o"},oL=e=>{const t=[];var n=(o,r)=>{o&&(Array.isArray(o)?o:[o]).forEach(s=>{(r?s.split(/[-|_|\s]+/):[s]).forEach(i=>{i=i.toLowerCase(),t.indexOf(i)==-1&&t.push(i)})})};return n(e.short_names,!0),n(e.name,!0),n(e.keywords,!1),n(e.emoticons,!1),t.join(",")};function rL(e){var t=Object.getOwnPropertyNames(e);for(let n of t){let o=e[n];e[n]=o&&typeof o=="object"?rL(o):o}return Object.freeze(e)}const M9e=e=>{if(!e.compressed)return e;e.compressed=!1;for(let t in e.emojis){let n=e.emojis[t];for(let o in o_)n[o]=n[o_[o]],delete n[o_[o]];n.short_names||(n.short_names=[]),n.short_names.unshift(t),n.sheet_x=n.sheet[0],n.sheet_y=n.sheet[1],delete n.sheet,n.text||(n.text=""),n.added_in||(n.added_in=6),n.added_in=n.added_in.toFixed(1),n.search=oL(n)}return e=rL(e),e},r_=["+1","grinning","kissing_heart","heart_eyes","laughing","stuck_out_tongue_winking_eye","sweat_smile","joy","scream","disappointed","unamused","weary","sob","sunglasses","heart","hankey"];let Mr,Nk,I2={};function sL(){Nk=!0,Mr=hd.get("frequently")}function T9e(e){Nk||sL();var{id:t}=e;Mr||(Mr=I2),Mr[t]||(Mr[t]=0),Mr[t]+=1,hd.set("last",t),hd.set("frequently",Mr)}function O9e(e){if(Nk||sL(),!Mr){I2={};const i=[];let l=Math.min(e,r_.length);for(let a=0;a<l;a++)I2[r_[a]]=parseInt((l-a)/4,10)+1,i.push(r_[a]);return i}const t=e,n=[];for(let i in Mr)Mr.hasOwnProperty(i)&&n.push(i);const r=n.sort((i,l)=>Mr[i]-Mr[l]).reverse().slice(0,t),s=hd.get("last");return s&&r.indexOf(s)==-1&&(r.pop(),r.push(s)),r}const A2={add:T9e,get:O9e},I9e={activity:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path d="M12 0C5.373 0 0 5.372 0 12c0 6.627 5.373 12 12 12 6.628 0 12-5.373 12-12 0-6.628-5.372-12-12-12m9.949 11H17.05c.224-2.527 1.232-4.773 1.968-6.113A9.966 9.966 0 0 1 21.949 11M13 11V2.051a9.945 9.945 0 0 1 4.432 1.564c-.858 1.491-2.156 4.22-2.392 7.385H13zm-2 0H8.961c-.238-3.165-1.536-5.894-2.393-7.385A9.95 9.95 0 0 1 11 2.051V11zm0 2v8.949a9.937 9.937 0 0 1-4.432-1.564c.857-1.492 2.155-4.221 2.393-7.385H11zm4.04 0c.236 3.164 1.534 5.893 2.392 7.385A9.92 9.92 0 0 1 13 21.949V13h2.04zM4.982 4.887C5.718 6.227 6.726 8.473 6.951 11h-4.9a9.977 9.977 0 0 1 2.931-6.113M2.051 13h4.9c-.226 2.527-1.233 4.771-1.969 6.113A9.972 9.972 0 0 1 2.051 13m16.967 6.113c-.735-1.342-1.744-3.586-1.968-6.113h4.899a9.961 9.961 0 0 1-2.931 6.113"/></svg>',custom:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><g transform="translate(2.000000, 1.000000)"><rect id="Rectangle" x="8" y="0" width="3" height="21" rx="1.5"></rect><rect id="Rectangle" transform="translate(9.843, 10.549) rotate(60) translate(-9.843, -10.549) " x="8.343" y="0.049" width="3" height="21" rx="1.5"></rect><rect id="Rectangle" transform="translate(9.843, 10.549) rotate(-60) translate(-9.843, -10.549) " x="8.343" y="0.049" width="3" height="21" rx="1.5"></rect></g></svg>',flags:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path d="M0 0l6.084 24H8L1.916 0zM21 5h-4l-1-4H4l3 12h3l1 4h13L21 5zM6.563 3h7.875l2 8H8.563l-2-8zm8.832 10l-2.856 1.904L12.063 13h3.332zM19 13l-1.5-6h1.938l2 8H16l3-2z"/></svg>',foods:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path d="M17 4.978c-1.838 0-2.876.396-3.68.934.513-1.172 1.768-2.934 4.68-2.934a1 1 0 0 0 0-2c-2.921 0-4.629 1.365-5.547 2.512-.064.078-.119.162-.18.244C11.73 1.838 10.798.023 9.207.023 8.579.022 7.85.306 7 .978 5.027 2.54 5.329 3.902 6.492 4.999 3.609 5.222 0 7.352 0 12.969c0 4.582 4.961 11.009 9 11.009 1.975 0 2.371-.486 3-1 .629.514 1.025 1 3 1 4.039 0 9-6.418 9-11 0-5.953-4.055-8-7-8M8.242 2.546c.641-.508.943-.523.965-.523.426.169.975 1.405 1.357 3.055-1.527-.629-2.741-1.352-2.98-1.846.059-.112.241-.356.658-.686M15 21.978c-1.08 0-1.21-.109-1.559-.402l-.176-.146c-.367-.302-.816-.452-1.266-.452s-.898.15-1.266.452l-.176.146c-.347.292-.477.402-1.557.402-2.813 0-7-5.389-7-9.009 0-5.823 4.488-5.991 5-5.991 1.939 0 2.484.471 3.387 1.251l.323.276a1.995 1.995 0 0 0 2.58 0l.323-.276c.902-.78 1.447-1.251 3.387-1.251.512 0 5 .168 5 6 0 3.617-4.187 9-7 9"/></svg>',nature:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path d="M15.5 8a1.5 1.5 0 1 0 .001 3.001A1.5 1.5 0 0 0 15.5 8M8.5 8a1.5 1.5 0 1 0 .001 3.001A1.5 1.5 0 0 0 8.5 8"/><path d="M18.933 0h-.027c-.97 0-2.138.787-3.018 1.497-1.274-.374-2.612-.51-3.887-.51-1.285 0-2.616.133-3.874.517C7.245.79 6.069 0 5.093 0h-.027C3.352 0 .07 2.67.002 7.026c-.039 2.479.276 4.238 1.04 5.013.254.258.882.677 1.295.882.191 3.177.922 5.238 2.536 6.38.897.637 2.187.949 3.2 1.102C8.04 20.6 8 20.795 8 21c0 1.773 2.35 3 4 3 1.648 0 4-1.227 4-3 0-.201-.038-.393-.072-.586 2.573-.385 5.435-1.877 5.925-7.587.396-.22.887-.568 1.104-.788.763-.774 1.079-2.534 1.04-5.013C23.929 2.67 20.646 0 18.933 0M3.223 9.135c-.237.281-.837 1.155-.884 1.238-.15-.41-.368-1.349-.337-3.291.051-3.281 2.478-4.972 3.091-5.031.256.015.731.27 1.265.646-1.11 1.171-2.275 2.915-2.352 5.125-.133.546-.398.858-.783 1.313M12 22c-.901 0-1.954-.693-2-1 0-.654.475-1.236 1-1.602V20a1 1 0 1 0 2 0v-.602c.524.365 1 .947 1 1.602-.046.307-1.099 1-2 1m3-3.48v.02a4.752 4.752 0 0 0-1.262-1.02c1.092-.516 2.239-1.334 2.239-2.217 0-1.842-1.781-2.195-3.977-2.195-2.196 0-3.978.354-3.978 2.195 0 .883 1.148 1.701 2.238 2.217A4.8 4.8 0 0 0 9 18.539v-.025c-1-.076-2.182-.281-2.973-.842-1.301-.92-1.838-3.045-1.853-6.478l.023-.041c.496-.826 1.49-1.45 1.804-3.102 0-2.047 1.357-3.631 2.362-4.522C9.37 3.178 10.555 3 11.948 3c1.447 0 2.685.192 3.733.57 1 .9 2.316 2.465 2.316 4.48.313 1.651 1.307 2.275 1.803 3.102.035.058.068.117.102.178-.059 5.967-1.949 7.01-4.902 7.19m6.628-8.202c-.037-.065-.074-.13-.113-.195a7.587 7.587 0 0 0-.739-.987c-.385-.455-.648-.768-.782-1.313-.076-2.209-1.241-3.954-2.353-5.124.531-.376 1.004-.63 1.261-.647.636.071 3.044 1.764 3.096 5.031.027 1.81-.347 3.218-.37 3.235"/></svg>',objects:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path d="M12 0a9 9 0 0 0-5 16.482V21s2.035 3 5 3 5-3 5-3v-4.518A9 9 0 0 0 12 0zm0 2c3.86 0 7 3.141 7 7s-3.14 7-7 7-7-3.141-7-7 3.14-7 7-7zM9 17.477c.94.332 1.946.523 3 .523s2.06-.19 3-.523v.834c-.91.436-1.925.689-3 .689a6.924 6.924 0 0 1-3-.69v-.833zm.236 3.07A8.854 8.854 0 0 0 12 21c.965 0 1.888-.167 2.758-.451C14.155 21.173 13.153 22 12 22c-1.102 0-2.117-.789-2.764-1.453z"/><path d="M14.745 12.449h-.004c-.852-.024-1.188-.858-1.577-1.824-.421-1.061-.703-1.561-1.182-1.566h-.009c-.481 0-.783.497-1.235 1.537-.436.982-.801 1.811-1.636 1.791l-.276-.043c-.565-.171-.853-.691-1.284-1.794-.125-.313-.202-.632-.27-.913-.051-.213-.127-.53-.195-.634C7.067 9.004 7.039 9 6.99 9A1 1 0 0 1 7 7h.01c1.662.017 2.015 1.373 2.198 2.134.486-.981 1.304-2.058 2.797-2.075 1.531.018 2.28 1.153 2.731 2.141l.002-.008C14.944 8.424 15.327 7 16.979 7h.032A1 1 0 1 1 17 9h-.011c-.149.076-.256.474-.319.709a6.484 6.484 0 0 1-.311.951c-.429.973-.79 1.789-1.614 1.789"/></svg>',smileys:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path d="M12 0C5.373 0 0 5.373 0 12s5.373 12 12 12 12-5.373 12-12S18.627 0 12 0m0 22C6.486 22 2 17.514 2 12S6.486 2 12 2s10 4.486 10 10-4.486 10-10 10"/><path d="M8 7a2 2 0 1 0-.001 3.999A2 2 0 0 0 8 7M16 7a2 2 0 1 0-.001 3.999A2 2 0 0 0 16 7M15.232 15c-.693 1.195-1.87 2-3.349 2-1.477 0-2.655-.805-3.347-2H15m3-2H6a6 6 0 1 0 12 0"/></svg>',people:'<svg xmlns:svg="http://www.w3.org/2000/svg" height="24" width="24" viewBox="0 0 24 24"> <path id="path3814" d="m 3.3591089,21.17726 c 0.172036,0.09385 4.265994,2.29837 8.8144451,2.29837 4.927767,0 8.670894,-2.211883 8.82782,-2.306019 0.113079,-0.06785 0.182268,-0.190051 0.182267,-0.321923 0,-3.03119 -0.929494,-5.804936 -2.617196,-7.810712 -1.180603,-1.403134 -2.661918,-2.359516 -4.295699,-2.799791 4.699118,-2.236258 3.102306,-9.28617162 -2.097191,-9.28617162 -5.1994978,0 -6.7963103,7.04991362 -2.097192,9.28617162 -1.6337821,0.440275 -3.1150971,1.396798 -4.2956991,2.799791 -1.687703,2.005776 -2.617196,4.779522 -2.617196,7.810712 1.2e-6,0.137378 0.075039,0.263785 0.195641,0.329572 z M 8.0439319,5.8308783 C 8.0439309,2.151521 12.492107,0.30955811 15.093491,2.9109411 17.694874,5.5123241 15.852911,9.9605006 12.173554,9.9605 9.8938991,9.9579135 8.0465186,8.1105332 8.0439319,5.8308783 Z m -1.688782,7.6894977 c 1.524535,-1.811449 3.5906601,-2.809035 5.8184041,-2.809035 2.227744,0 4.293869,0.997586 5.818404,2.809035 1.533639,1.822571 2.395932,4.339858 2.439152,7.108301 -0.803352,0.434877 -4.141636,2.096112 -8.257556,2.096112 -3.8062921,0 -7.3910861,-1.671043 -8.2573681,-2.104981 0.04505,-2.765017 0.906968,-5.278785 2.438964,-7.099432 z" /> <path id="path3816" d="M 12.173828 0.38867188 C 9.3198513 0.38867187 7.3770988 2.3672285 6.8652344 4.6308594 C 6.4218608 6.5916015 7.1153562 8.7676117 8.9648438 10.126953 C 7.6141249 10.677376 6.3550511 11.480944 5.3496094 12.675781 C 3.5629317 14.799185 2.6015625 17.701475 2.6015625 20.847656 C 2.6015654 21.189861 2.7894276 21.508002 3.0898438 21.671875 C 3.3044068 21.788925 7.4436239 24.039062 12.173828 24.039062 C 17.269918 24.039062 21.083568 21.776786 21.291016 21.652344 C 21.57281 21.483266 21.746097 21.176282 21.746094 20.847656 C 21.746094 17.701475 20.78277 14.799185 18.996094 12.675781 C 17.990455 11.480591 16.733818 10.675362 15.382812 10.125 C 17.231132 8.7655552 17.925675 6.5910701 17.482422 4.6308594 C 16.970557 2.3672285 15.027805 0.38867188 12.173828 0.38867188 z M 12.792969 2.3007812 C 13.466253 2.4161792 14.125113 2.7383941 14.695312 3.3085938 C 15.835712 4.4489931 15.985604 5.9473549 15.46875 7.1953125 C 14.951896 8.4432701 13.786828 9.3984378 12.173828 9.3984375 C 10.197719 9.3961954 8.607711 7.806187 8.6054688 5.8300781 C 8.6054683 4.2170785 9.5606362 3.0520102 10.808594 2.5351562 C 11.432573 2.2767293 12.119685 2.1853833 12.792969 2.3007812 z M 12.173828 11.273438 C 14.233647 11.273438 16.133674 12.185084 17.5625 13.882812 C 18.93069 15.508765 19.698347 17.776969 19.808594 20.283203 C 18.807395 20.800235 15.886157 22.162109 12.173828 22.162109 C 8.7614632 22.162109 5.6245754 20.787069 4.5390625 20.265625 C 4.6525896 17.766717 5.4203315 15.504791 6.7851562 13.882812 C 8.2139827 12.185084 10.11401 11.273438 12.173828 11.273438 z " /> </svg>',places:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path d="M6.5 12C5.122 12 4 13.121 4 14.5S5.122 17 6.5 17 9 15.879 9 14.5 7.878 12 6.5 12m0 3c-.275 0-.5-.225-.5-.5s.225-.5.5-.5.5.225.5.5-.225.5-.5.5M17.5 12c-1.378 0-2.5 1.121-2.5 2.5s1.122 2.5 2.5 2.5 2.5-1.121 2.5-2.5-1.122-2.5-2.5-2.5m0 3c-.275 0-.5-.225-.5-.5s.225-.5.5-.5.5.225.5.5-.225.5-.5.5"/><path d="M22.482 9.494l-1.039-.346L21.4 9h.6c.552 0 1-.439 1-.992 0-.006-.003-.008-.003-.008H23c0-1-.889-2-1.984-2h-.642l-.731-1.717C19.262 3.012 18.091 2 16.764 2H7.236C5.909 2 4.738 3.012 4.357 4.283L3.626 6h-.642C1.889 6 1 7 1 8h.003S1 8.002 1 8.008C1 8.561 1.448 9 2 9h.6l-.043.148-1.039.346a2.001 2.001 0 0 0-1.359 2.097l.751 7.508a1 1 0 0 0 .994.901H3v1c0 1.103.896 2 2 2h2c1.104 0 2-.897 2-2v-1h6v1c0 1.103.896 2 2 2h2c1.104 0 2-.897 2-2v-1h1.096a.999.999 0 0 0 .994-.901l.751-7.508a2.001 2.001 0 0 0-1.359-2.097M6.273 4.857C6.402 4.43 6.788 4 7.236 4h9.527c.448 0 .834.43.963.857L19.313 9H4.688l1.585-4.143zM7 21H5v-1h2v1zm12 0h-2v-1h2v1zm2.189-3H2.811l-.662-6.607L3 11h18l.852.393L21.189 18z"/></svg>',recent:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path d="M13 4h-2l-.001 7H9v2h2v2h2v-2h4v-2h-4z"/><path d="M12 0C5.373 0 0 5.373 0 12s5.373 12 12 12 12-5.373 12-12S18.627 0 12 0m0 22C6.486 22 2 17.514 2 12S6.486 2 12 2s10 4.486 10 10-4.486 10-10 10"/></svg>',symbols:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24"><path d="M0 0h11v2H0zM4 11h3V6h4V4H0v2h4zM15.5 17c1.381 0 2.5-1.116 2.5-2.493s-1.119-2.493-2.5-2.493S13 13.13 13 14.507 14.119 17 15.5 17m0-2.986c.276 0 .5.222.5.493 0 .272-.224.493-.5.493s-.5-.221-.5-.493.224-.493.5-.493M21.5 19.014c-1.381 0-2.5 1.116-2.5 2.493S20.119 24 21.5 24s2.5-1.116 2.5-2.493-1.119-2.493-2.5-2.493m0 2.986a.497.497 0 0 1-.5-.493c0-.271.224-.493.5-.493s.5.222.5.493a.497.497 0 0 1-.5.493M22 13l-9 9 1.513 1.5 8.99-9.009zM17 11c2.209 0 4-1.119 4-2.5V2s.985-.161 1.498.949C23.01 4.055 23 6 23 6s1-1.119 1-3.135C24-.02 21 0 21 0h-2v6.347A5.853 5.853 0 0 0 17 6c-2.209 0-4 1.119-4 2.5s1.791 2.5 4 2.5M10.297 20.482l-1.475-1.585a47.54 47.54 0 0 1-1.442 1.129c-.307-.288-.989-1.016-2.045-2.183.902-.836 1.479-1.466 1.729-1.892s.376-.871.376-1.336c0-.592-.273-1.178-.818-1.759-.546-.581-1.329-.871-2.349-.871-1.008 0-1.79.293-2.344.879-.556.587-.832 1.181-.832 1.784 0 .813.419 1.748 1.256 2.805-.847.614-1.444 1.208-1.794 1.784a3.465 3.465 0 0 0-.523 1.833c0 .857.308 1.56.924 2.107.616.549 1.423.823 2.42.823 1.173 0 2.444-.379 3.813-1.137L8.235 24h2.819l-2.09-2.383 1.333-1.135zm-6.736-6.389a1.02 1.02 0 0 1 .73-.286c.31 0 .559.085.747.254a.849.849 0 0 1 .283.659c0 .518-.419 1.112-1.257 1.784-.536-.651-.805-1.231-.805-1.742a.901.901 0 0 1 .302-.669M3.74 22c-.427 0-.778-.116-1.057-.349-.279-.232-.418-.487-.418-.766 0-.594.509-1.288 1.527-2.083.968 1.134 1.717 1.946 2.248 2.438-.921.507-1.686.76-2.3.76"/></svg>'},A9e={props:{i18n:{type:Object,required:!0},color:{type:String},categories:{type:Array,required:!0},activeCategory:{type:Object,default(){return{}}}},emits:["click"],created(){this.svgs=I9e}},N9e={role:"tablist",class:"emoji-mart-anchors"},P9e=["aria-label","aria-selected","data-title","onClick"],L9e=["innerHTML"];function R9e(e,t,n,o,r,s){return C(),M("div",N9e,[(C(!0),M(fe,null,nt(n.categories,i=>(C(),M("button",{role:"tab",type:"button","aria-label":i.name,"aria-selected":i.id==n.activeCategory.id,key:i.id,class:D({"emoji-mart-anchor":!0,"emoji-mart-anchor-selected":i.id==n.activeCategory.id}),style:Qe({color:i.id==n.activeCategory.id?n.color:""}),"data-title":n.i18n.categories[i.id],onClick:l=>e.$emit("click",i)},[b("div",{"aria-hidden":"true",innerHTML:e.svgs[i.id]},null,8,L9e),b("span",{"aria-hidden":"true",class:"emoji-mart-anchor-bar",style:Qe({backgroundColor:n.color})},null,4)],14,P9e))),128))])}const D9e=qe(A9e,[["render",R9e]]),F9e=String,V9e=F9e.fromCodePoint||function(){var t=16384,n=[],o,r,s=-1,i=arguments.length;if(!i)return"";for(var l="";++s<i;){var a=Number(arguments[s]);if(!isFinite(a)||a<0||a>1114111||Math.floor(a)!=a)throw RangeError("Invalid code point: "+a);a<=65535?n.push(a):(a-=65536,o=(a>>10)+55296,r=a%1024+56320,n.push(o,r)),(s+1===i||n.length>t)&&(l+=String.fromCharCode.apply(null,n),n.length=0)}return l};function B9e(e){var t=e.split("-"),n=t.map(o=>`0x${o}`);return V9e.apply(null,n)}function X9(e){return e.reduce((t,n)=>(t.indexOf(n)===-1&&t.push(n),t),[])}function z9e(e,t){const n=X9(e),o=X9(t);return n.filter(r=>o.indexOf(r)>=0)}function iL(e,t){var n={};for(let o in e){let r=e[o],s=r;t.hasOwnProperty(o)&&(s=t[o]),typeof s=="object"&&(s=iL(r,s)),n[o]=s}return n}function j9e(){if(typeof document>"u")return 0;const e=document.createElement("div");e.style.width="100px",e.style.height="100px",e.style.overflow="scroll",e.style.position="absolute",e.style.top="-9999px",document.body.appendChild(e);const t=e.offsetWidth-e.clientWidth;return document.body.removeChild(e),t}const H9e=61,U9e=/^(?:\:([^\:]+)\:)(?:\:skin-tone-(\d)\:)?$/,Q9=["1F3FA","1F3FB","1F3FC","1F3FD","1F3FE","1F3FF"];class W9e{constructor(t,{emojisToShowFilter:n,include:o,exclude:r,custom:s,recent:i,recentLength:l=20}={}){this._data=M9e(t),this._emojisFilter=n||null,this._include=o||null,this._exclude=r||null,this._custom=s||[],this._recent=i||A2.get(l),this._emojis={},this._nativeEmojis={},this._emoticons={},this._categories=[],this._recentCategory={id:"recent",name:"Recent",emojis:[]},this._customCategory={id:"custom",name:"Custom",emojis:[]},this._searchIndex={},this.buildIndex(),Object.freeze(this)}buildIndex(){let t=this._data.categories;if(this._include&&(t=t.filter(n=>this._include.includes(n.id)),t=t.sort((n,o)=>{const r=this._include.indexOf(n.id),s=this._include.indexOf(o.id);return r<s?-1:r>s?1:0})),t.forEach(n=>{if(!this.isCategoryNeeded(n.id))return;let o={id:n.id,name:n.name,emojis:[]};n.emojis.forEach(r=>{let s=this.addEmoji(r);s&&o.emojis.push(s)}),o.emojis.length&&this._categories.push(o)}),this.isCategoryNeeded("custom")){if(this._custom.length>0)for(let n of this._custom)this.addCustomEmoji(n);this._customCategory.emojis.length&&this._categories.push(this._customCategory)}this.isCategoryNeeded("recent")&&(this._recent.length&&this._recent.map(n=>{for(let o of this._customCategory.emojis)if(o.id===n){this._recentCategory.emojis.push(o);return}this.hasEmoji(n)&&this._recentCategory.emojis.push(this.emoji(n))}),this._recentCategory.emojis.length&&this._categories.unshift(this._recentCategory))}findEmoji(t,n){let o=t.match(U9e);if(o&&(t=o[1],o[2]&&(n=parseInt(o[2],10))),this._data.aliases.hasOwnProperty(t)&&(t=this._data.aliases[t]),this._emojis.hasOwnProperty(t)){let r=this._emojis[t];return n?r.getSkin(n):r}return this._nativeEmojis.hasOwnProperty(t)?this._nativeEmojis[t]:null}categories(){return this._categories}emoji(t){this._data.aliases.hasOwnProperty(t)&&(t=this._data.aliases[t]);let n=this._emojis[t];if(!n)throw new Error("Can not find emoji by id: "+t);return n}firstEmoji(){let t=this._emojis[Object.keys(this._emojis)[0]];if(!t)throw new Error("Can not get first emoji");return t}hasEmoji(t){return this._data.aliases.hasOwnProperty(t)&&(t=this._data.aliases[t]),!!this._emojis[t]}nativeEmoji(t){return this._nativeEmojis.hasOwnProperty(t)?this._nativeEmojis[t]:null}search(t,n){if(n||(n=75),!t.length)return null;if(t=="-"||t=="-1")return[this.emoji("-1")];let o=t.toLowerCase().split(/[\s|,|\-|_]+/),r=[];o.length>2&&(o=[o[0],o[1]]),r=o.map(i=>{let l=this._emojis,a=this._searchIndex,u=0;for(let c=0;c<i.length;c++){const d=i[c];if(u++,a[d]||(a[d]={}),a=a[d],!a.results){let f={};a.results=[],a.emojis={};for(let p in l){let h=l[p],m=h._data.search,y=i.substr(0,u),v=m.indexOf(y);if(v!=-1){let w=v+1;y==p&&(w=0),a.results.push(h),a.emojis[p]=h,f[p]=w}}a.results.sort((p,h)=>{var m=f[p.id],y=f[h.id];return m-y})}l=a.emojis}return a.results}).filter(i=>i);var s=null;return r.length>1?s=z9e.apply(null,r):r.length?s=r[0]:s=[],s&&s.length>n&&(s=s.slice(0,n)),s}addCustomEmoji(t){let n=Object.assign({},t,{id:t.short_names[0],custom:!0});n.search||(n.search=oL(n));let o=new r0(n);return this._emojis[o.id]=o,this._customCategory.emojis.push(o),o}addEmoji(t){let n=this._data.emojis[t];if(!this.isEmojiNeeded(n))return!1;let o=new r0(n);if(this._emojis[t]=o,o.native&&(this._nativeEmojis[o.native]=o),o._skins)for(let r in o._skins){let s=o._skins[r];s.native&&(this._nativeEmojis[s.native]=s)}return o.emoticons&&o.emoticons.forEach(r=>{this._emoticons[r]||(this._emoticons[r]=t)}),o}isCategoryNeeded(t){let n=this._include&&this._include.length?this._include.indexOf(t)>-1:!0,o=this._exclude&&this._exclude.length?this._exclude.indexOf(t)>-1:!1;return!(!n||o)}isEmojiNeeded(t){return this._emojisFilter?this._emojisFilter(t):!0}}class r0{constructor(t){if(this._data=Object.assign({},t),this._skins=null,this._data.skin_variations){this._skins=[];for(var n in Q9){let o=Q9[n],r=this._data.skin_variations[o],s=Object.assign({},t);for(let i in r)s[i]=r[i];delete s.skin_variations,s.skin_tone=parseInt(n)+1,this._skins.push(new r0(s))}}this._sanitized=K9e(this._data);for(let o in this._sanitized)this[o]=this._sanitized[o];this.short_names=this._data.short_names,this.short_name=this._data.short_names[0],Object.freeze(this)}getSkin(t){return t&&t!="native"&&this._skins?this._skins[t-1]:this}getPosition(){let t=H9e-1,n=+(100/t*this._data.sheet_x).toFixed(2),o=+(100/t*this._data.sheet_y).toFixed(2);return`${n}% ${o}%`}ariaLabel(){return[this.native].concat(this.short_names).filter(Boolean).join(", ")}}class lL{constructor(t,n,o,r,s,i,l){this._emoji=t,this._native=r,this._skin=n,this._set=o,this._fallback=s,this.canRender=this._canRender(),this.cssClass=this._cssClass(),this.cssStyle=this._cssStyle(l),this.content=this._content(),this.title=i===!0?t.short_name:null,this.ariaLabel=t.ariaLabel(),Object.freeze(this)}getEmoji(){return this._emoji.getSkin(this._skin)}_canRender(){return this._isCustom()||this._isNative()||this._hasEmoji()||this._fallback}_cssClass(){return["emoji-set-"+this._set,"emoji-type-"+this._emojiType()]}_cssStyle(t){let n={};return this._isCustom()?n={backgroundImage:"url("+this.getEmoji()._data.imageUrl+")",backgroundSize:"100%",width:t+"px",height:t+"px"}:this._hasEmoji()&&!this._isNative()&&(n={backgroundPosition:this.getEmoji().getPosition()}),t&&(this._isNative()?n=Object.assign(n,{fontSize:Math.round(t*.95*10)/10+"px"}):n=Object.assign(n,{width:t+"px",height:t+"px"})),n}_content(){return this._isCustom()?"":this._isNative()?this.getEmoji().native:this._hasEmoji()?"":this._fallback?this._fallback(this.getEmoji()):null}_isNative(){return this._native}_isCustom(){return this.getEmoji().custom}_hasEmoji(){if(!this.getEmoji()._data)return!1;const t=this.getEmoji()._data["has_img_"+this._set];return t===void 0?!0:t}_emojiType(){return this._isCustom()?"custom":this._isNative()?"native":this._hasEmoji()?"image":"fallback"}}function K9e(e){var{name:t,short_names:n,skin_tone:o,skin_variations:r,emoticons:s,unified:i,custom:l,imageUrl:a}=e,u=e.id||n[0],c=`:${u}:`;return l?{id:u,name:t,colons:c,emoticons:s,custom:l,imageUrl:a}:(o&&(c+=`:skin-tone-${o}:`),{id:u,name:t,colons:c,emoticons:s,unified:i.toLowerCase(),skin:o||(r?1:null),native:B9e(i)})}const q9e={native:{type:Boolean,default:!1},tooltip:{type:Boolean,default:!1},fallback:{type:Function},skin:{type:Number,default:1},set:{type:String,default:"apple"},emoji:{type:[String,Object],required:!0},size:{type:Number,default:null},tag:{type:String,default:"span"}},G9e={perLine:{type:Number,default:9},maxSearchResults:{type:Number,default:75},emojiSize:{type:Number,default:24},title:{type:String,default:"Emoji Mart™"},emoji:{type:String,default:"department_store"},color:{type:String,default:"#ae65c5"},set:{type:String,default:"apple"},skin:{type:Number,default:null},defaultSkin:{type:Number,default:1},native:{type:Boolean,default:!1},emojiTooltip:{type:Boolean,default:!1},autoFocus:{type:Boolean,default:!1},i18n:{type:Object,default(){return{}}},showPreview:{type:Boolean,default:!0},showSearch:{type:Boolean,default:!0},showCategories:{type:Boolean,default:!0},showSkinTones:{type:Boolean,default:!0},infiniteScroll:{type:Boolean,default:!0},pickerStyles:{type:Object,default(){return{}}}},Y9e={props:{...q9e,data:{type:Object,required:!0}},emits:["click","mouseenter","mouseleave"],computed:{view(){return new lL(this.emojiObject,this.skin,this.set,this.native,this.fallback,this.tooltip,this.size)},sanitizedData(){return this.emojiObject._sanitized},title(){return this.tooltip?this.emojiObject.short_name:null},emojiObject(){return typeof this.emoji=="string"?this.data.findEmoji(this.emoji):this.emoji}},created(){},methods:{onClick(){this.$emit("click",this.emojiObject)},onMouseEnter(){this.$emit("mouseenter",this.emojiObject)},onMouseLeave(){this.$emit("mouseleave",this.emojiObject)}}};function Z9e(e,t,n,o,r,s){return s.view.canRender?(C(),q(Lt(e.tag),{key:0,title:s.view.title,"aria-label":s.view.ariaLabel,"data-title":s.title,class:"emoji-mart-emoji",onMouseenter:s.onMouseEnter,onMouseleave:s.onMouseLeave,onClick:s.onClick},{default:$(()=>[b("span",{class:D(s.view.cssClass),style:Qe(s.view.cssStyle)},A(s.view.content),7)]),_:1},40,["title","aria-label","data-title","onMouseenter","onMouseleave","onClick"])):W("",!0)}const aL=qe(Y9e,[["render",Z9e]]),J9e={props:{data:{type:Object,required:!0},i18n:{type:Object,required:!0},id:{type:String,required:!0},name:{type:String,required:!0},emojis:{type:Array},emojiProps:{type:Object,required:!0}},methods:{activeClass:function(e){return!this.emojiProps.selectedEmoji||!this.emojiProps.selectedEmojiCategory?"":this.emojiProps.selectedEmoji.id==e.id&&this.emojiProps.selectedEmojiCategory.id==this.id?"emoji-mart-emoji-selected":""}},computed:{isVisible(){return!!this.emojis},isSearch(){return this.name=="Search"},hasResults(){return this.emojis.length>0},emojiObjects(){return this.emojis.map(e=>{let t=e,n=new lL(e,this.emojiProps.skin,this.emojiProps.set,this.emojiProps.native,this.emojiProps.fallback,this.emojiProps.emojiTooltip,this.emojiProps.emojiSize);return{emojiObject:t,emojiView:n}})}},components:{Emoji:aL}},X9e=["aria-label"],Q9e={class:"emoji-mart-category-label"},e$e={class:"emoji-mart-category-label"},t$e=["aria-label","data-title","title","onMouseenter","onMouseleave","onClick"],n$e={key:0},o$e={class:"emoji-mart-no-results-label"};function r$e(e,t,n,o,r,s){const i=re("emoji");return s.isVisible&&(s.isSearch||s.hasResults)?(C(),M("section",{key:0,class:D({"emoji-mart-category":!0,"emoji-mart-no-results":!s.hasResults}),"aria-label":n.i18n.categories[n.id]},[b("div",Q9e,[b("h3",e$e,A(n.i18n.categories[n.id]),1)]),(C(!0),M(fe,null,nt(s.emojiObjects,({emojiObject:l,emojiView:a})=>(C(),M(fe,null,[a.canRender?(C(),M("button",{"aria-label":a.ariaLabel,role:"option","aria-selected":"false","aria-posinset":"1","aria-setsize":"1812",type:"button","data-title":l.short_name,key:l.id,title:a.title,class:D(["emoji-mart-emoji",s.activeClass(l)]),onMouseenter:u=>n.emojiProps.onEnter(a.getEmoji()),onMouseleave:u=>n.emojiProps.onLeave(a.getEmoji()),onClick:u=>n.emojiProps.onClick(a.getEmoji())},[b("span",{class:D(a.cssClass),style:Qe(a.cssStyle)},A(a.content),7)],42,t$e)):W("",!0)],64))),256)),s.hasResults?W("",!0):(C(),M("div",n$e,[k(i,{data:n.data,emoji:"sleuth_or_spy",native:n.emojiProps.native,skin:n.emojiProps.skin,set:n.emojiProps.set},null,8,["data","native","skin","set"]),b("div",o$e,A(n.i18n.notfound),1)]))],10,X9e)):W("",!0)}const s$e=qe(J9e,[["render",r$e]]),i$e={props:{skin:{type:Number,required:!0}},emits:["change"],data(){return{opened:!1}},methods:{onClick(e){this.opened&&e!=this.skin&&this.$emit("change",e),this.opened=!this.opened}}},l$e=["onClick"];function a$e(e,t,n,o,r,s){return C(),M("div",{class:D({"emoji-mart-skin-swatches":!0,"emoji-mart-skin-swatches-opened":r.opened})},[(C(),M(fe,null,nt(6,i=>b("span",{key:i,class:D({"emoji-mart-skin-swatch":!0,"emoji-mart-skin-swatch-selected":n.skin==i})},[b("span",{class:D("emoji-mart-skin emoji-mart-skin-tone-"+i),onClick:l=>s.onClick(i)},null,10,l$e)],2)),64))],2)}const u$e=qe(i$e,[["render",a$e]]),c$e={props:{data:{type:Object,required:!0},title:{type:String,required:!0},emoji:{type:[String,Object]},idleEmoji:{type:[String,Object],required:!0},showSkinTones:{type:Boolean,default:!0},emojiProps:{type:Object,required:!0},skinProps:{type:Object,required:!0},onSkinChange:{type:Function,required:!0}},computed:{emojiData(){return this.emoji?this.emoji:{}},emojiShortNames(){return this.emojiData.short_names},emojiEmoticons(){return this.emojiData.emoticons}},components:{Emoji:aL,Skins:u$e}},d$e={class:"emoji-mart-preview"},f$e={class:"emoji-mart-preview-emoji"},p$e={class:"emoji-mart-preview-data"},h$e={class:"emoji-mart-preview-name"},m$e={class:"emoji-mart-preview-shortnames"},g$e={class:"emoji-mart-preview-emoticons"},v$e={class:"emoji-mart-preview-emoji"},y$e={class:"emoji-mart-preview-data"},_$e={class:"emoji-mart-title-label"},b$e={key:0,class:"emoji-mart-preview-skins"};function w$e(e,t,n,o,r,s){const i=re("emoji"),l=re("skins");return C(),M("div",d$e,[n.emoji?(C(),M(fe,{key:0},[b("div",f$e,[k(i,{data:n.data,emoji:n.emoji,native:n.emojiProps.native,skin:n.emojiProps.skin,set:n.emojiProps.set},null,8,["data","emoji","native","skin","set"])]),b("div",p$e,[b("div",h$e,A(n.emoji.name),1),b("div",m$e,[(C(!0),M(fe,null,nt(s.emojiShortNames,a=>(C(),M("span",{key:a,class:"emoji-mart-preview-shortname"},":"+A(a)+":",1))),128))]),b("div",g$e,[(C(!0),M(fe,null,nt(s.emojiEmoticons,a=>(C(),M("span",{key:a,class:"emoji-mart-preview-emoticon"},A(a),1))),128))])])],64)):(C(),M(fe,{key:1},[b("div",v$e,[k(i,{data:n.data,emoji:n.idleEmoji,native:n.emojiProps.native,skin:n.emojiProps.skin,set:n.emojiProps.set},null,8,["data","emoji","native","skin","set"])]),b("div",y$e,[b("span",_$e,A(n.title),1)]),n.showSkinTones?(C(),M("div",b$e,[k(l,{skin:n.skinProps.skin,onChange:t[0]||(t[0]=a=>n.onSkinChange(a))},null,8,["skin"])])):W("",!0)],64))])}const C$e=qe(c$e,[["render",w$e]]),k$e={props:{data:{type:Object,required:!0},i18n:{type:Object,required:!0},autoFocus:{type:Boolean,default:!1},onSearch:{type:Function,required:!0},onArrowLeft:{type:Function,required:!1},onArrowRight:{type:Function,required:!1},onArrowDown:{type:Function,required:!1},onArrowUp:{type:Function,required:!1},onEnter:{type:Function,required:!1}},emits:["search","enter","arrowUp","arrowDown","arrowRight","arrowLeft"],data(){return{value:""}},computed:{emojiIndex(){return this.data}},watch:{value(){this.$emit("search",this.value)}},methods:{clear(){this.value=""}},mounted(){let e=this.$el.querySelector("input");this.autoFocus&&e.focus()}},S$e={class:"emoji-mart-search"},$$e=["placeholder"],E$e=b("span",{class:"hidden",id:"emoji-picker-search-description"},"Use the left, right, up and down arrow keys to navigate the emoji search results.",-1);function x$e(e,t,n,o,r,s){return C(),M("div",S$e,[He(b("input",{type:"text",placeholder:n.i18n.search,role:"textbox","aria-autocomplete":"list","aria-owns":"emoji-mart-list","aria-label":"Search for an emoji","aria-describedby":"emoji-mart-search-description",onKeydown:[t[0]||(t[0]=Pt(i=>e.$emit("arrowLeft",i),["left"])),t[1]||(t[1]=Pt(()=>e.$emit("arrowRight"),["right"])),t[2]||(t[2]=Pt(()=>e.$emit("arrowDown"),["down"])),t[3]||(t[3]=Pt(i=>e.$emit("arrowUp",i),["up"])),t[4]||(t[4]=Pt(()=>e.$emit("enter"),["enter"]))],"onUpdate:modelValue":t[5]||(t[5]=i=>r.value=i)},null,40,$$e),[[Bc,r.value]]),E$e])}const M$e=qe(k$e,[["render",x$e]]);var T$e=typeof window<"u";T$e&&function(){for(var e=0,t=["ms","moz","webkit","o"],n=0;n<t.length&&!window.requestAnimationFrame;++n)window.requestAnimationFrame=window[t[n]+"RequestAnimationFrame"],window.cancelAnimationFrame=window[t[n]+"CancelAnimationFrame"]||window[t[n]+"CancelRequestAnimationFrame"];window.requestAnimationFrame||(window.requestAnimationFrame=function(o,r){var s=new Date().getTime(),i=Math.max(0,16-(s-e)),l=window.setTimeout(function(){o(s+i)},i);return e=s+i,l}),window.cancelAnimationFrame||(window.cancelAnimationFrame=function(o){clearTimeout(o)})}();class O$e{constructor(t){this._vm=t,this._data=t.data,this._perLine=t.perLine,this._categories=[],this._categories.push(...this._data.categories()),this._categories=this._categories.filter(n=>n.emojis.length>0),this._categories[0].first=!0,Object.freeze(this._categories),this.activeCategory=this._categories[0],this.searchEmojis=null,this.previewEmoji=null,this.previewEmojiCategoryIdx=0,this.previewEmojiIdx=-1}onScroll(){const n=this._vm.$refs.scroll.scrollTop;let o=this.filteredCategories[0];for(let r=0,s=this.filteredCategories.length;r<s;r++){let i=this.filteredCategories[r],l=this._vm.getCategoryComponent(r);if(l&&l.$el.offsetTop-50>n)break;o=i}this.activeCategory=o}get allCategories(){return this._categories}get filteredCategories(){return this.searchEmojis?[{id:"search",name:"Search",emojis:this.searchEmojis}]:this._categories.filter(t=>t.emojis.length>0)}get previewEmojiCategory(){return this.previewEmojiCategoryIdx>=0?this.filteredCategories[this.previewEmojiCategoryIdx]:null}onAnchorClick(t){if(this.searchEmojis)return;let n=this.filteredCategories.indexOf(t),o=this._vm.getCategoryComponent(n),r=()=>{if(o){let s=o.$el.offsetTop;t.first&&(s=0),this._vm.$refs.scroll.scrollTop=s}};this._vm.infiniteScroll?r():this.activeCategory=this.filteredCategories[n]}onSearch(t){let n=this._data.search(t,this.maxSearchResults);this.searchEmojis=n,this.previewEmojiCategoryIdx=0,this.previewEmojiIdx=0,this.updatePreviewEmoji()}onEmojiEnter(t){this.previewEmoji=t,this.previewEmojiIdx=-1,this.previewEmojiCategoryIdx=-1}onEmojiLeave(t){this.previewEmoji=null}onArrowLeft(){this.previewEmojiIdx>0?this.previewEmojiIdx-=1:(this.previewEmojiCategoryIdx-=1,this.previewEmojiCategoryIdx<0?this.previewEmojiCategoryIdx=0:this.previewEmojiIdx=this.filteredCategories[this.previewEmojiCategoryIdx].emojis.length-1),this.updatePreviewEmoji()}onArrowRight(){this.previewEmojiIdx<this.emojisLength(this.previewEmojiCategoryIdx)-1?this.previewEmojiIdx+=1:(this.previewEmojiCategoryIdx+=1,this.previewEmojiCategoryIdx>=this.filteredCategories.length?this.previewEmojiCategoryIdx=this.filteredCategories.length-1:this.previewEmojiIdx=0),this.updatePreviewEmoji()}onArrowDown(){if(this.previewEmojiIdx==-1)return this.onArrowRight();const t=this.filteredCategories[this.previewEmojiCategoryIdx].emojis.length;let n=this._perLine;this.previewEmojiIdx+n>t&&(n=t%this._perLine);for(let o=0;o<n;o++)this.onArrowRight();this.updatePreviewEmoji()}onArrowUp(){let t=this._perLine;this.previewEmojiIdx-t<0&&(this.previewEmojiCategoryIdx>0?t=this.filteredCategories[this.previewEmojiCategoryIdx-1].emojis.length%this._perLine:t=0);for(let n=0;n<t;n++)this.onArrowLeft();this.updatePreviewEmoji()}updatePreviewEmoji(){this.previewEmoji=this.filteredCategories[this.previewEmojiCategoryIdx].emojis[this.previewEmojiIdx],this._vm.$nextTick(()=>{const t=this._vm.$refs.scroll,n=t.querySelector(".emoji-mart-emoji-selected"),o=t.offsetTop-t.offsetHeight;n&&n.offsetTop+n.offsetHeight>o+t.scrollTop&&(t.scrollTop+=n.offsetHeight),n&&n.offsetTop<t.scrollTop&&(t.scrollTop-=n.offsetHeight)})}emojisLength(t){return t==-1?0:this.filteredCategories[t].emojis.length}}const I$e={search:"Search",notfound:"No Emoji Found",categories:{search:"Search Results",recent:"Frequently Used",smileys:"Smileys & Emotion",people:"People & Body",nature:"Animals & Nature",foods:"Food & Drink",activity:"Activity",places:"Travel & Places",objects:"Objects",symbols:"Symbols",flags:"Flags",custom:"Custom"}},A$e={props:{...G9e,data:{type:Object,required:!0}},emits:["select","skin-change"],data(){return{activeSkin:this.skin||hd.get("skin")||this.defaultSkin,view:new O$e(this)}},computed:{customStyles(){return{width:this.calculateWidth+"px",...this.pickerStyles}},emojiProps(){return{native:this.native,skin:this.activeSkin,set:this.set,emojiTooltip:this.emojiTooltip,emojiSize:this.emojiSize,selectedEmoji:this.view.previewEmoji,selectedEmojiCategory:this.view.previewEmojiCategory,onEnter:this.onEmojiEnter.bind(this),onLeave:this.onEmojiLeave.bind(this),onClick:this.onEmojiClick.bind(this)}},skinProps(){return{skin:this.activeSkin}},calculateWidth(){return this.perLine*(this.emojiSize+12)+12+2+j9e()},filteredCategories(){return this.view.filteredCategories},mergedI18n(){return Object.freeze(iL(I$e,this.i18n))},idleEmoji(){try{return this.data.emoji(this.emoji)}catch(e){return console.error("Default preview emoji `"+this.emoji+"` is not available, check the Picker `emoji` property"),console.error(e),this.data.firstEmoji()}}},watch:{skin(){this.onSkinChange(this.skin)}},methods:{onScroll(){this.infiniteScroll&&!this.waitingForPaint&&(this.waitingForPaint=!0,window.requestAnimationFrame(this.onScrollPaint.bind(this)))},onScrollPaint(){this.waitingForPaint=!1,this.view.onScroll()},onAnchorClick(e){this.view.onAnchorClick(e)},onSearch(e){this.view.onSearch(e)},onEmojiEnter(e){this.view.onEmojiEnter(e)},onEmojiLeave(e){this.view.onEmojiLeave(e)},onArrowLeft(e){const t=this.view.previewEmojiIdx;this.view.onArrowLeft(),e&&this.view.previewEmojiIdx!==t&&e.preventDefault()},onArrowRight(){this.view.onArrowRight()},onArrowDown(){this.view.onArrowDown()},onArrowUp(e){this.view.onArrowUp(),e.preventDefault()},onEnter(){this.view.previewEmoji&&(this.$emit("select",this.view.previewEmoji),A2.add(this.view.previewEmoji))},onEmojiClick(e){this.$emit("select",e),A2.add(e)},onTextSelect(e){e.stopPropagation()},onSkinChange(e){this.activeSkin=e,hd.update({skin:e}),this.$emit("skin-change",e)},getCategoryComponent(e){let t=this.$refs["categories_"+e];return t&&"0"in t?t[0]:t}},components:{Anchors:D9e,Category:s$e,Preview:C$e,Search:M$e}},N$e={key:0,class:"emoji-mart-bar emoji-mart-bar-anchors"},P$e={id:"emoji-mart-list",ref:"scrollContent",role:"listbox","aria-expanded":"true"},L$e={key:0,class:"emoji-mart-bar emoji-mart-bar-preview"};function R$e(e,t,n,o,r,s){const i=re("anchors"),l=re("search"),a=re("category"),u=re("preview");return C(),M("section",{class:"emoji-mart emoji-mart-static",style:Qe(s.customStyles)},[e.showCategories?(C(),M("div",N$e,[k(i,{data:n.data,i18n:s.mergedI18n,color:e.color,categories:r.view.allCategories,"active-category":r.view.activeCategory,onClick:s.onAnchorClick},null,8,["data","i18n","color","categories","active-category","onClick"])])):W("",!0),he(e.$slots,"searchTemplate",{data:n.data,i18n:e.i18n,autoFocus:e.autoFocus,onSearch:s.onSearch},()=>[e.showSearch?(C(),q(l,{key:0,ref:"search",data:n.data,i18n:s.mergedI18n,"auto-focus":e.autoFocus,"on-search":s.onSearch,onSearch:s.onSearch,onArrowLeft:s.onArrowLeft,onArrowRight:s.onArrowRight,onArrowDown:s.onArrowDown,onArrowUp:s.onArrowUp,onEnter:s.onEnter,onSelect:s.onTextSelect},null,8,["data","i18n","auto-focus","on-search","onSearch","onArrowLeft","onArrowRight","onArrowDown","onArrowUp","onEnter","onSelect"])):W("",!0)]),b("div",{role:"tabpanel",class:"emoji-mart-scroll",ref:"scroll",onScroll:t[0]||(t[0]=(...c)=>s.onScroll&&s.onScroll(...c))},[b("div",P$e,[he(e.$slots,"customCategory"),(C(!0),M(fe,null,nt(r.view.filteredCategories,(c,d)=>He((C(),q(a,{ref_for:!0,ref:"categories_"+d,key:c.id,data:n.data,i18n:s.mergedI18n,id:c.id,name:c.name,emojis:c.emojis,"emoji-props":s.emojiProps},null,8,["data","i18n","id","name","emojis","emoji-props"])),[[en,e.infiniteScroll||c==r.view.activeCategory]])),128))],512)],544),he(e.$slots,"previewTemplate",{data:n.data,title:e.title,emoji:r.view.previewEmoji,idleEmoji:s.idleEmoji,showSkinTones:e.showSkinTones,emojiProps:s.emojiProps,skinProps:s.skinProps,onSkinChange:s.onSkinChange},()=>[e.showPreview?(C(),M("div",L$e,[k(u,{data:n.data,title:e.title,emoji:r.view.previewEmoji,"idle-emoji":s.idleEmoji,"show-skin-tones":e.showSkinTones,"emoji-props":s.emojiProps,"skin-props":s.skinProps,"on-skin-change":s.onSkinChange},null,8,["data","title","emoji","idle-emoji","show-skin-tones","emoji-props","skin-props","on-skin-change"])])):W("",!0)])],4)}const D$e=qe(A$e,[["render",R$e]]),F$e={name:"EmojiPicker",components:{Picker:D$e},emits:["emoji-selected"],props:{close_on_select:{type:Boolean,default:!1}},data(){return{isEmojiPickerVisible:!1,emojiIndex:null,imojiLoading:!1,errorMessage:"",isLoading:!1}},methods:{onEmojiSelect(e){this.$emit("emoji-selected",e.native),this.close_on_select&&this.$refs.fcom_emoji_popover.hide()},handleClickOutside(e){if(this.isEmojiPickerVisible){const t=this.$refs.container;t&&!t.contains(e.target)&&(this.isEmojiPickerVisible=!1)}},loadEmojiAssets(){if(this.isLoading)return;this.isLoading=!0,window.fcomEmojiIndex&&(this.emojiIndex=window.fcomEmojiIndex);let e=this.appVars.assets_url+"libs/static/tw_emojis.json";this.imojiLoading=!0,fetch(e).then(t=>t.json()).then(t=>{t?(window.fcomEmojiIndex=new W9e(t),this.emojiIndex=window.fcomEmojiIndex,this.imojiLoading=!1):this.errorMessage="Emoji loading failed"}).catch(t=>{this.errorMessage="Emoji loading failed"}).finally(()=>{this.isLoading=!1})}}},V$e={style:{position:"relative"},ref:"container"},B$e=b("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[b("g",null,[b("circle",{cx:"9.99996",cy:"10.0013",r:"8.33333",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{d:"M6.66663 12.5C7.42673 13.512 8.6369 14.1667 9.99996 14.1667C11.363 14.1667 12.5732 13.512 13.3333 12.5",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M6.6741 7.5L6.66663 7.5Z",fill:"currentColor"}),b("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M13.3333 7.5L13.3258 7.5Z",fill:"currentColor"}),b("path",{d:"M6.6741 7.5L6.66663 7.5M13.3333 7.5L13.3258 7.5",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})])],-1),z$e={key:0,class:"emoji-mart emoji-mart-static",style:{width:"320px",padding:"10px 20px"}},j$e={key:0},H$e={style:{"text-align":"center","margin-bottom":"20px"}},U$e={key:1,class:"fcom_emoji_holder"};function W$e(e,t,n,o,r,s){const i=Ne,l=pt,a=lo,u=re("Picker"),c=Po;return C(),M("div",V$e,[k(c,{placement:"bottom",width:320,trigger:"click",persistent:!1,ref:"fcom_emoji_popover",onShow:s.loadEmojiAssets,"popper-class":"fcom_emoji_popover ffcom_emoji"},{reference:$(()=>[k(l,{"aria-label":"Pick Imoji",text:""},{default:$(()=>[k(i,null,{default:$(()=>[B$e]),_:1})]),_:1})]),default:$(()=>[r.imojiLoading?(C(),M("div",z$e,[r.errorMessage?(C(),M("div",j$e,A(r.errorMessage),1)):(C(),M(fe,{key:1},[b("div",H$e,A(e.$t("Loading.....")),1),k(a,{animated:!0,rows:3})],64))])):r.emojiIndex?(C(),M("div",U$e,[k(u,{title:e.$t("Space Emoji"),color:"#66b1ff",showPreview:!1,ref:"picker",data:r.emojiIndex,set:"twitter",onSelect:s.onEmojiSelect,emojiSize:22,sheetSize:32,emojiTooltip:!1},null,8,["title","data","onSelect"])])):W("",!0)]),_:1},8,["onShow"])],512)}const uL=qe(F$e,[["render",W$e]]),K$e={name:"LogoEmojiSelector",components:{EmojiPicker:uL,ImageUploader:Md,SvgShapeGenerator:C9e},props:{config:{type:Object,required:!0,default:()=>({emoji:"",logo:"",shape_svg:""})},fallback_mark:{type:String,default:'<span class="fcom_no_avatar"></span>'},custom_svg:{type:Boolean,default:!1}},data(){return{emoji:this.config.emoji||"",logo:this.config.logo||"",shape_svg:this.config.shape_svg||"",visible:!1,selectedTab:"emoji"}},methods:{setData(e){e=="emoji"?(this.logo="",this.shape_svg=""):e=="shape_svg"?(this.emoji="",this.logo=""):(this.emoji="",this.shape_svg=""),this.$emit("update",{logo:this.logo,emoji:this.emoji,shape_svg:this.shape_svg})},handleLogoPhotoUpload(e){this.logo=e,this.setData("logo")},handleShapeChanged(e){this.shape_svg=e,this.setData("shape_svg")}},computed:{currentMark(){return this.logo?`<img alt="" src="${this.logo}" style="width: 20px; height: 20px; aspect-ratio: 1/1;">`:this.emoji.trim()?`<span style="font-size: 20px">${this.emoji.trim()}</span>`:this.shape_svg?'<i class="fcom_shape el-icon">'+this.shape_svg+"</i>":this.fallback_mark}},mounted(){this.logo?this.selectedTab="logo":this.emoji?this.selectedTab="emoji":this.shape_svg&&(this.selectedTab="shape")}},q$e=["innerHTML"];function G$e(e,t,n,o,r,s){const i=pt,l=re("EmojiPicker"),a=At,u=IO,c=re("SvgShapeGenerator"),d=Ed,f=re("ImageUploader"),p=OO,h=Po;return C(),q(h,{placement:"bottom",width:450,persistent:!1,style:{padding:"0"},visible:r.visible,ref:"logo_emoji_pop",class:"logo_emoji_pop"},{reference:$(()=>[k(i,{onClick:t[0]||(t[0]=m=>r.visible=!r.visible),text:""},{default:$(()=>[b("span",{class:"logo_emoji_holder",style:{cursor:"pointer"},innerHTML:s.currentMark||""},null,8,q$e)]),_:1})]),default:$(()=>[k(p,{modelValue:r.selectedTab,"onUpdate:modelValue":t[6]||(t[6]=m=>r.selectedTab=m),type:"border-card"},{default:$(()=>[k(u,{name:"emoji",label:e.$t("Emoji")},{default:$(()=>[k(a,{onChange:t[2]||(t[2]=m=>s.setData("emoji")),modelValue:r.emoji,"onUpdate:modelValue":t[3]||(t[3]=m=>r.emoji=m),placeholder:e.$t("Select or paste your emoji here"),style:{width:"100%"}},{append:$(()=>[k(l,{close_on_select:!0,onEmojiSelected:t[1]||(t[1]=m=>{r.emoji=m,s.setData("emoji")})})]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),k(u,{name:"shape",label:e.$t("Shape")},{default:$(()=>[k(c,{onUpdate:s.handleShapeChanged},null,8,["onUpdate"])]),_:1},8,["label"]),n.custom_svg?(C(),q(u,{key:0,name:"shape_svg",label:e.$t("Custom SVG")},{default:$(()=>[k(a,{rows:4,type:"textarea",onChange:t[4]||(t[4]=m=>s.setData("shape_svg")),modelValue:r.shape_svg,"onUpdate:modelValue":t[5]||(t[5]=m=>r.shape_svg=m),placeholder:e.$t("Paste your SVG here"),style:{width:"100%"}},null,8,["modelValue","placeholder"])]),_:1},8,["label"])):W("",!0),k(u,{name:"logo",label:e.$t("Custom Image")},{default:$(()=>[r.logo?(C(),q(d,{key:0,alt:e.$t("Logo"),src:r.logo,style:{"max-width":"100px"}},null,8,["alt","src"])):W("",!0),k(f,{additionalData:{resize:!0,max_width:400},onUploaded:s.handleLogoPhotoUpload},null,8,["onUploaded"])]),_:1},8,["label"])]),_:1},8,["modelValue"]),k(i,{onClick:t[7]||(t[7]=m=>{r.visible=!1}),type:"success",plain:"",style:{"margin-top":"20px"}},{default:$(()=>[ne(A(e.$t("Close")),1)]),_:1})]),_:1},8,["visible"])}const Ev=qe(K$e,[["render",G$e]]),Y$e={name:"UserBadgesConfig",components:{LogoEmojiSelector:Ev,UpgradeToProModal:$v},props:["features"],emits:["saveSettings"],data(){return{badges:null,showSettings:!1,fetching:!1,saving:!1,editingBadge:null,showEditBagdeModal:!1,openUpgradeModal:!1}},methods:{openSettings(){if(!this.has_pro){this.openUpgradeModal=!0;return}this.fetchSettings(),this.showSettings=!0},fetchSettings(){this.fetching=!0,this.$get("admin/user-badges").then(e=>{this.badges=e.badges}).catch(e=>{this.$handleError(e)}).finally(()=>{this.fetching=!1})},saveSettings(){let e=this.features.user_badge=="yes";this.$emit("saveSettings",!e),e&&this.saveBadgeSettings()},saveBadgeSettings(){this.saving=!0,this.$post("admin/user-badges",{badges:this.badges}).then(e=>{this.$notify.success(e.message),this.$emit("saveSettings",!1);let t=e.badges;this.badges=Object.values(t),this.features.user_badge=="yes"?this.appVars.user_badges=t:this.appVars.user_badges=null}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})},initAddNew(){this.badges.push({title:"",config:{emoji:"",shape_svg:"",logo:""},show_label:"yes",color:"",background_color:""}),this.editingBadge=this.badges[this.badges.length-1],this.showEditBagdeModal=!0},initEdit(e){this.editingBadge=e,this.showEditBagdeModal=!0},closeEdit(){this.showEditBagdeModal=!1,this.editingBadge=null,this.saveBadgeSettings()}}},cL=e=>(J$("data-v-45693b4b"),e=e(),X$(),e),Z$e={class:"fcom_storage_settings"},J$e={key:0,class:"white_loaded"},X$e={key:1},Q$e={class:"header_user_badge"},eEe={style:{"margin-bottom":"30px"},class:"fcom_user_badges fcom_manager_table"},tEe={class:"fcom_badge_preview"},nEe={class:"fcom_table_action_col",style:{display:"flex",gap:"10px"}},oEe=cL(()=>b("div",{class:"action_item clickable"},[b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"16",viewBox:"0 0 14 16",fill:"none"},[b("path",{d:"M12 3.66602L11.5868 10.3494C11.4813 12.057 11.4285 12.9108 11.0005 13.5246C10.7889 13.8281 10.5164 14.0842 10.2005 14.2767C9.56141 14.666 8.70599 14.666 6.99516 14.666C5.28208 14.666 4.42554 14.666 3.78604 14.276C3.46987 14.0831 3.19733 13.8266 2.98579 13.5226C2.55792 12.9077 2.5063 12.0528 2.40307 10.3428L2 3.66602",stroke:"currentColor","stroke-linecap":"round"}),b("path",{d:"M1 3.66634H13M9.70382 3.66634L9.2487 2.72749C8.94638 2.10385 8.79522 1.79202 8.53448 1.59755C8.47664 1.55441 8.4154 1.51604 8.35135 1.48281C8.06261 1.33301 7.71608 1.33301 7.02302 1.33301C6.31255 1.33301 5.95732 1.33301 5.66379 1.48909C5.59873 1.52368 5.53666 1.5636 5.4782 1.60845C5.21443 1.81081 5.06709 2.13404 4.7724 2.78051L4.36862 3.66634",stroke:"currentColor","stroke-linecap":"round"}),b("path",{d:"M5.33325 11L5.33325 7",stroke:"currentColor","stroke-linecap":"round"}),b("path",{d:"M8.66675 11L8.66675 7",stroke:"currentColor","stroke-linecap":"round"})])],-1)),rEe=["onClick"],sEe=cL(()=>b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 14 14",fill:"none"},[b("path",{d:"M0.666748 7.00033C0.666748 4.01476 0.666748 2.52198 1.59424 1.59449C2.52174 0.666992 4.01452 0.666992 7.00008 0.666992C9.98564 0.666992 11.4784 0.666992 12.4059 1.59449C13.3334 2.52198 13.3334 4.01476 13.3334 7.00033C13.3334 9.98589 13.3334 11.4787 12.4059 12.4062C11.4784 13.3337 9.98564 13.3337 7.00008 13.3337C4.01452 13.3337 2.52174 13.3337 1.59424 12.4062C0.666748 11.4787 0.666748 9.98589 0.666748 7.00033Z",stroke:"currentColor","stroke-linejoin":"round"}),b("path",{d:"M5.66675 9.33398C5.66675 9.88627 5.21903 10.334 4.66675 10.334C4.11446 10.334 3.66675 9.88627 3.66675 9.33398C3.66675 8.7817 4.11446 8.33398 4.66675 8.33398C5.21903 8.33398 5.66675 8.7817 5.66675 9.33398Z",stroke:"currentColor"}),b("path",{d:"M10.3335 4.66699C10.3335 4.11471 9.88578 3.66699 9.3335 3.66699C8.78121 3.66699 8.3335 4.11471 8.3335 4.66699C8.3335 5.21928 8.78121 5.66699 9.3335 5.66699C9.88578 5.66699 10.3335 5.21928 10.3335 4.66699Z",stroke:"currentColor"}),b("path",{d:"M4.66675 8.33366L4.66675 3.66699",stroke:"currentColor","stroke-linecap":"round"}),b("path",{d:"M9.3335 5.66732L9.3335 10.334",stroke:"currentColor","stroke-linecap":"round"})],-1)),iEe=[sEe],lEe={key:2};function aEe(e,t,n,o,r,s){const i=pt,l=lo,a=Hn,u=io,c=Y0,d=re("UserBadge"),f=G0,p=so,h=Ql,m=re("logo-emoji-selector"),y=At,v=R3,w=vh,_=gh,S=yh,x=re("UpgradeToProModal"),E=zt("loading");return C(),M(fe,null,[b("div",Z$e,[k(i,{class:"fcom_secondary_button",onClick:t[0]||(t[0]=T=>s.openSettings())},{default:$(()=>[ne(A(e.$t("Settings")),1)]),_:1})]),k(h,{"modal-class":"fcom_common_dialog",id:"fluent_comminity_body","close-on-click-modal":!1,"append-to-body":!0,size:e.dialogWidth,modelValue:r.showSettings,"onUpdate:modelValue":t[4]||(t[4]=T=>r.showSettings=T),direction:"rtl"},{header:$(()=>[b("h4",null,A(e.$t("User Badge Settings")),1)]),default:$(()=>[r.fetching?(C(),M("div",J$e,[k(l,{rows:5,animated:!0})])):r.badges?(C(),M("div",X$e,[k(p,{onSubmit:t[3]||(t[3]=et(T=>e.doNothing(),["prevent"])),"label-position":"top"},{default:$(()=>[k(u,null,{default:$(()=>[k(a,{"true-label":"yes","false-label":"no",modelValue:n.features.user_badge,"onUpdate:modelValue":t[1]||(t[1]=T=>n.features.user_badge=T),label:e.$t("Enable User Badge Module"),size:"large"},null,8,["modelValue","label"])]),_:1}),n.features.user_badge==="yes"?(C(),M(fe,{key:0},[b("div",Q$e,[b("h3",null,A(e.$t("User Badges")),1),k(i,{class:"fcom_secondary_button",onClick:t[2]||(t[2]=T=>s.initAddNew()),size:"small"},{default:$(()=>[ne(A(e.$t("Add New")),1)]),_:1})]),b("div",eEe,[k(f,{stripe:"","empty-text":e.$t("No Badges has been configured"),data:r.badges},{default:$(()=>[k(c,{prop:"title",label:e.$t("Title"),width:"200px"},null,8,["label"]),k(c,{label:e.$t("Preview")},{default:$(T=>[b("div",tEe,[k(d,{is_preview:!0,badge:T.row},null,8,["badge"])])]),_:1},8,["label"]),k(c,{width:"150px",label:e.$t("Actions")},{default:$(T=>[b("div",nEe,[oEe,b("div",{onClick:O=>s.initEdit(T.row),class:"action_item clickable"},iEe,8,rEe)])]),_:1},8,["label"])]),_:1},8,["empty-text","data"])])],64)):W("",!0),k(u,null,{default:$(()=>[He((C(),q(i,{class:"fcom_primary_button",disabled:r.saving,onClick:s.saveSettings},{default:$(()=>[ne(A(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])),[[E,r.saving]])]),_:1})]),_:1})])):(C(),M("div",lEe,[b("p",null,A(e.$t("Config could not be loaded")),1)]))]),_:1},8,["size","modelValue"]),k(S,{"append-to-body":!0,modelValue:r.showEditBagdeModal,"onUpdate:modelValue":t[14]||(t[14]=T=>r.showEditBagdeModal=T),title:e.$t("Edit Badge"),width:"30%"},{default:$(()=>[r.editingBadge?(C(),q(p,{key:0,onSubmit:t[13]||(t[13]=et(T=>e.doNothing(),["prevent"])),"label-position":"top"},{default:$(()=>[k(u,{label:e.$t("Title")},{default:$(()=>[k(y,{modelValue:r.editingBadge.title,"onUpdate:modelValue":t[6]||(t[6]=T=>r.editingBadge.title=T),placeholder:e.$t("Badge Title")},{prepend:$(()=>{var T,O;return[k(m,{fallback_mark:"",custom_svg:!0,onUpdate:t[5]||(t[5]=P=>{r.editingBadge.config.emoji=P.emoji,r.editingBadge.config.logo=P.logo,r.editingBadge.config.shape_svg=P.shape_svg}),config:{logo:r.editingBadge.config.logo,emoji:((T=r.editingBadge.config)==null?void 0:T.emoji)||"",shape_svg:(O=r.editingBadge.config)==null?void 0:O.shape_svg}},null,8,["config"])]}),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),k(u,null,{default:$(()=>[k(a,{modelValue:r.editingBadge.show_label,"onUpdate:modelValue":t[7]||(t[7]=T=>r.editingBadge.show_label=T),"true-value":"yes","false-value":"no"},{default:$(()=>[ne(A(e.$t("Show Label on Badge")),1)]),_:1},8,["modelValue"])]),_:1}),r.editingBadge.show_label=="yes"?(C(),M(fe,{key:0},[k(_,{gutter:20},{default:$(()=>[k(w,{span:12},{default:$(()=>[k(u,{label:e.$t("Color")},{default:$(()=>[k(v,{onActiveChange:t[8]||(t[8]=T=>{r.editingBadge.color=T}),modelValue:r.editingBadge.color,"onUpdate:modelValue":t[9]||(t[9]=T=>r.editingBadge.color=T)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1}),k(w,{span:12},{default:$(()=>[k(u,{label:e.$t("Background Color")},{default:$(()=>[k(v,{onActiveChange:t[10]||(t[10]=T=>{r.editingBadge.background_color=T}),modelValue:r.editingBadge.background_color,"onUpdate:modelValue":t[11]||(t[11]=T=>r.editingBadge.background_color=T)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1})]),_:1}),b("p",null,A(e.$t("For best UI, keep the colors empty")),1)],64)):W("",!0),k(u,null,{default:$(()=>[k(i,{class:"fcom_primary_button",onClick:t[12]||(t[12]=T=>s.closeEdit())},{default:$(()=>[ne(A(e.$t("Save")),1)]),_:1})]),_:1})]),_:1})):W("",!0)]),_:1},8,["modelValue","title"]),r.openUpgradeModal?(C(),q(x,{key:0,showModal:r.openUpgradeModal,onCloseModal:t[15]||(t[15]=T=>r.openUpgradeModal=!1),upgrade_module:"user_badge_module"},null,8,["showModal"])):W("",!0)],64)}const uEe=qe(Y$e,[["render",aEe],["__scopeId","data-v-45693b4b"]]),cEe={name:"Features",components:{UserBadgesConfig:uEe,LeaderBoardConfig:m9e,StorageSettings:QSe,Layout:ri,AppLayout:si,UpgradeToProModal:$v},data(){return{features:null,addOns:{},loading:!1,installing:!1,openGiphyUpgradeModal:!1,openEmojiUpgradeModal:!1}},methods:{saveFeatures(e=!0){if(this.features.giphy_module==="yes"&&QO(this.features.giphy_api_key)){this.$handleError("Giphy API Key is required");return}this.$post("settings/features",{features:this.features}).then(t=>{e&&(this.$notify.success(t.message||this.$t("Settings saved successfully")),location.reload())}).catch(t=>{this.$handleError(t)})},getFeatures(){this.loading=!0,this.$get("settings/features").then(e=>{this.features=e.features,this.addOns=e.addOns}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},installPlugin(e){this.installing=!0,this.$post("settings/install_plugin",{plugin:e}).then(t=>{t.is_installed?this.$notify.success(t.message):this.$notify.error(this.$t("Sorry, the selected plugins could not be installed")),this.getFeatures()}).catch(t=>{this.$handleError(t)}).finally(()=>{this.installing=!1})}},mounted(){this.getFeatures(),this.changeTitle(this.$t("Features Settings"))}},dEe={class:"settings_router"},fEe={key:0,class:"white_loaded"},pEe=b("hr",null,null,-1),hEe={key:1,style:{"margin-bottom":"30px"}},mEe={class:"fhr_content_layout_body"},gEe={class:"setting_header"},vEe={class:"fcom_advancde_fetaures"},yEe={key:0,class:"setting_body"},_Ee={class:"setting_item"},bEe={class:"setting_field_placeholder"},wEe={class:"title"},CEe={class:"info"},kEe={class:"settings_field_data"},SEe={class:"align-right"},$Ee={class:"setting_item"},EEe={class:"setting_field_placeholder"},xEe={class:"title"},MEe={class:"info"},TEe={class:"settings_field_data"},OEe={class:"align-right"},IEe={class:"setting_item"},AEe={class:"setting_field_placeholder"},NEe={class:"title"},PEe={class:"info"},LEe={class:"settings_field_data"},REe={class:"align-right"},DEe={class:"fcom_module_popover_content"},FEe={class:"setting_item"},VEe={class:"setting_field_placeholder"},BEe={class:"title"},zEe={class:"info"},jEe={class:"settings_field_data"},HEe={class:"align-right"},UEe={key:0,class:"fcom_giphy_api",style:{"margin-bottom":"5px"}},WEe={class:"fcom_module_popover_content"},KEe={class:"setting_item"},qEe={class:"setting_field_placeholder"},GEe={class:"title"},YEe={class:"info"},ZEe={class:"settings_field_data"},JEe={class:"align-right"},XEe={class:"fcom_module_popover_content"},QEe={class:"setting_item"},e7e={class:"setting_field_placeholder"},t7e={class:"title"},n7e={class:"info"},o7e={class:"settings_field_data"},r7e={class:"align-right"},s7e={class:"fhr_content_layout_body"},i7e={class:"setting_header"},l7e={class:"fcom_advancde_fetaures"},a7e={key:0,class:"setting_body"},u7e={class:"setting_field_placeholder"},c7e={class:"title recommend_plugin",style:{display:"flex","align-items":"flex-start"}},d7e={class:"avatar",style:{"margin-right":"15px"}},f7e=["src"],p7e=["href"],h7e={class:"info"},m7e={class:"settings_field_data"},g7e={class:"align-right"},v7e=["href"];function y7e(e,t,n,o,r,s){const i=lo,l=mh,a=re("LeaderBoardConfig"),u=re("UserBadgesConfig"),c=Hn,d=pt,f=Po,p=At,h=re("UpgradeToProModal"),m=re("storage-settings"),y=re("layout"),v=re("app-layout");return C(),q(v,{wrapper_class:"fcom_single_layout fcom_member_profile fcom_max_layout"},{default:$(()=>[k(y,{wrapper_class:"no_bg_layout fcom_setting_route",title:e.$t("Advanced Features & Addons")},{default:$(()=>[b("div",dEe,[r.loading?(C(),M("div",fEe,[k(i,{rows:5,animated:!0}),pEe,k(i,{rows:7,animated:!0})])):(C(),M("div",hEe,[b("div",mEe,[b("div",gEe,[b("h2",null,A(e.$t("Advanced Features")),1)]),b("div",vEe,[r.features?(C(),M("div",yEe,[b("div",_Ee,[b("div",bEe,[b("div",wEe,[ne(A(e.$t("Leaderboards Module"))+" ",1),e.has_pro?(C(),M(fe,{key:0},[r.features.leader_board_module==="no"?(C(),q(l,{key:0,type:"info",size:"small"},{default:$(()=>[ne(A(e.$t("Disabled")),1)]),_:1})):r.features.leader_board_module==="yes"?(C(),q(l,{key:1,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(A(e.$t("Enabled")),1)]),_:1})):W("",!0)],64)):W("",!0)]),b("div",CEe,A(e.$t("__LEADERBOARD_DESC")),1)]),b("div",kEe,[b("div",SEe,[k(a,{onSaveSettings:s.saveFeatures,features:r.features},null,8,["onSaveSettings","features"])])])]),b("div",$Ee,[b("div",EEe,[b("div",xEe,[ne(A(e.$t("User Badges"))+" ",1),e.has_pro?(C(),M(fe,{key:0},[r.features.user_badge==="no"?(C(),q(l,{key:0,type:"info",size:"small"},{default:$(()=>[ne(A(e.$t("Disabled")),1)]),_:1})):r.features.user_badge==="yes"?(C(),q(l,{key:1,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(A(e.$t("Enabled")),1)]),_:1})):W("",!0)],64)):W("",!0)]),b("div",MEe,A(e.$t("__USER_BADGE_DESC")),1)]),b("div",TEe,[b("div",OEe,[k(u,{onSaveSettings:s.saveFeatures,features:r.features},null,8,["onSaveSettings","features"])])])]),b("div",IEe,[b("div",AEe,[b("div",NEe,[ne(A(e.$t("Course Module"))+" ",1),r.features.course_module==="no"?(C(),q(l,{key:0,type:"info",size:"small"},{default:$(()=>[ne(A(e.$t("Disabled")),1)]),_:1})):r.features.course_module==="yes"?(C(),q(l,{key:1,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(A(e.$t("Enabled")),1)]),_:1})):W("",!0)]),b("div",PEe,A(e.$t("__COURSE_STRUCTURED_LESSONS")),1)]),b("div",LEe,[b("div",REe,[k(f,{persistent:!1,placement:"bottom",title:e.$t("Course Module Settings"),width:400,trigger:"click"},{reference:$(()=>[k(d,{size:"default",class:"fcom_secondary_button"},{default:$(()=>[ne(A(e.$t("Settings")),1)]),_:1})]),default:$(()=>[b("div",DEe,[k(c,{modelValue:r.features.course_module,"onUpdate:modelValue":t[0]||(t[0]=w=>r.features.course_module=w),"true-label":"yes","false-label":"no",label:e.$t("Enable Course Module"),size:"large"},null,8,["modelValue","label"]),k(d,{class:"fcom_primary_button",size:"default",onClick:s.saveFeatures},{default:$(()=>[ne(A(e.$t("Save")),1)]),_:1},8,["onClick"])])]),_:1},8,["title"])])])]),b("div",FEe,[b("div",VEe,[b("div",BEe,[ne(A(e.$t("Giphy Module"))+" ",1),e.has_pro?(C(),M(fe,{key:0},[r.features.giphy_module==="no"?(C(),q(l,{key:0,type:"info",size:"small",effect:"dark"},{default:$(()=>[ne(A(e.$t("Disabled")),1)]),_:1})):r.features.giphy_module==="yes"?(C(),q(l,{key:1,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(A(e.$t("Enabled")),1)]),_:1})):W("",!0)],64)):W("",!0)]),b("div",zEe,A(e.$t("Unlock potential by using giphy when creating a new article , post or comment")),1)]),b("div",jEe,[b("div",HEe,[r.openGiphyUpgradeModal?W("",!0):(C(),q(f,{key:0,persistent:!1,placement:"bottom",title:e.$t("Giphy Module Settings"),width:400,trigger:"click"},{reference:$(()=>[k(d,{size:"default",class:"fcom_secondary_button",onClick:t[3]||(t[3]=w=>!e.has_pro&&(r.openGiphyUpgradeModal=!0))},{default:$(()=>[ne(A(e.$t("Settings")),1)]),_:1})]),default:$(()=>[r.features.giphy_module==="yes"?(C(),M("div",UEe,[k(p,{modelValue:r.features.giphy_api_key,"onUpdate:modelValue":t[1]||(t[1]=w=>r.features.giphy_api_key=w),placeholder:e.$t("Giphy API Key")},null,8,["modelValue","placeholder"])])):W("",!0),b("div",WEe,[k(c,{"true-value":"yes","false-value":"no",modelValue:r.features.giphy_module,"onUpdate:modelValue":t[2]||(t[2]=w=>r.features.giphy_module=w),label:e.$t("Enable Giphy Module"),size:"large"},null,8,["modelValue","label"]),k(d,{class:"fcom_primary_button",size:"default",onClick:s.saveFeatures},{default:$(()=>[ne(A(e.$t("Save")),1)]),_:1},8,["onClick"])])]),_:1},8,["title"])),r.openGiphyUpgradeModal?(C(),q(h,{key:1,showModal:r.openGiphyUpgradeModal,onCloseModal:t[4]||(t[4]=w=>r.openGiphyUpgradeModal=!1),upgrade_module:"giphy_module"},null,8,["showModal"])):W("",!0)])])]),b("div",KEe,[b("div",qEe,[b("div",GEe,[ne(A(e.$t("Emoji Module"))+" ",1),e.has_pro?(C(),M(fe,{key:0},[r.features.emoji_module==="no"?(C(),q(l,{key:0,type:"info",size:"small",effect:"dark"},{default:$(()=>[ne(A(e.$t("Disabled")),1)]),_:1})):r.features.emoji_module==="yes"?(C(),q(l,{key:1,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(A(e.$t("Enabled")),1)]),_:1})):W("",!0)],64)):W("",!0)]),b("div",YEe,A(e.$t("__EMOJIS_DESC")),1)]),b("div",ZEe,[b("div",JEe,[r.openEmojiUpgradeModal?W("",!0):(C(),q(f,{key:0,persistent:!1,placement:"bottom",title:e.$t("Emoji Settings"),width:400,trigger:"click"},{reference:$(()=>[k(d,{size:"default",class:"fcom_secondary_button",onClick:t[6]||(t[6]=w=>!e.has_pro&&(r.openEmojiUpgradeModal=!0))},{default:$(()=>[ne(A(e.$t("Settings")),1)]),_:1})]),default:$(()=>[b("div",XEe,[k(c,{"true-value":"yes","false-value":"no",modelValue:r.features.emoji_module,"onUpdate:modelValue":t[5]||(t[5]=w=>r.features.emoji_module=w),label:e.$t("Enable Emoji"),size:"large"},null,8,["modelValue","label"]),k(d,{class:"fcom_primary_button",size:"default",onClick:s.saveFeatures},{default:$(()=>[ne(A(e.$t("Save")),1)]),_:1},8,["onClick"])])]),_:1},8,["title"])),r.openEmojiUpgradeModal?(C(),q(h,{key:1,showModal:r.openEmojiUpgradeModal,onCloseModal:t[7]||(t[7]=w=>r.openEmojiUpgradeModal=!1),upgrade_module:"emoji_module"},null,8,["showModal"])):W("",!0)])])]),b("div",QEe,[b("div",e7e,[b("div",t7e,[ne(A(e.$t("Media Module"))+" ",1),r.features.cloud_storage==="yes"?(C(),q(l,{key:0,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(A(e.$t("Enabled")),1)]),_:1})):r.features.cloud_storage==="no"?(C(),q(l,{key:1,type:"info",size:"small"},{default:$(()=>[ne(A(e.$t("Local")),1)]),_:1})):W("",!0)]),b("div",n7e,A(e.$t("__CLOUD_STORAGE_DESC")),1)]),b("div",o7e,[b("div",r7e,[k(m,{features:r.features},null,8,["features"])])])])])):W("",!0)])])])),b("div",s7e,[b("div",i7e,[b("h2",null,A(e.$t("Recommended Plugins and Addons")),1)]),b("div",l7e,[r.features?(C(),M("div",a7e,[(C(!0),M(fe,null,nt(r.addOns,(w,_)=>(C(),M("div",{key:_,class:"setting_item"},[b("div",u7e,[b("div",c7e,[b("div",d7e,[b("img",{alt:"",src:w.logo,style:{width:"60px"}},null,8,f7e)]),b("div",null,[b("a",{target:"_blank",href:w.learn_more_url},A(w.title),9,p7e),w.is_installed?(C(),q(l,{key:0,type:"success",size:"small",effect:"light",style:{"margin-left":"8px"}},{default:$(()=>[ne(A(e.$t("Installed")),1)]),_:1})):W("",!0),b("div",h7e,A(w.description),1)])])]),b("div",m7e,[b("div",g7e,[w.is_installed?(C(),M("a",{key:1,href:w.settings_url,class:"el-button el-button--default fcom_secondary_button"},A(e.$t("View Settings")),9,v7e)):(C(),q(d,{key:0,class:"fcom_secondary_button",onClick:S=>s.installPlugin(_)},{default:$(()=>[ne(A(w.action_text),1)]),_:2},1032,["onClick"]))])])]))),128))])):W("",!0)])])])]),_:1},8,["title"])]),_:1})}const _7e=qe(cEe,[["render",y7e]]),b7e={name:"FluentDnD",props:{items:{type:Array,required:!0},itemClass:{type:String},itemStyle:{type:String},rowKey:{type:String,default:"id"}},emits:["dragStart","dragEnd","drop"],data(){return{draggingIndex:null,startIndex:null}},methods:{dragStart(e,t){this.draggingIndex=t,this.startIndex=t,e.dataTransfer.effectAllowed="move",e.dataTransfer.setData("text/plain",""),this.$emit("dragEnd",t)},dragEnd(){this.draggingIndex=null,this.startIndex=null},dragOver(e,t){if(e.preventDefault(),this.draggingIndex===null)return;const n=this.items[this.draggingIndex],o=this.items[t];if(n===o)return;const r=e.currentTarget.getBoundingClientRect(),s=r.top+r.height/2,i=e.clientY;(this.draggingIndex<t&&i>s||this.draggingIndex>t&&i<s)&&(this.reorderItems(this.draggingIndex,t),this.draggingIndex=t)},dropEnd(e,t){this.draggingIndex===null||this.startIndex===t||(this.draggingIndex=null,this.$emit("drop",{index:t,newItems:this.items}))},reorderItems(e,t){const n=this.items.splice(e,1)[0];this.items.splice(t,0,n)}}},w7e={class:"drag-container"},C7e=["onDragstart","onDragover","onDrop"];function k7e(e,t,n,o,r,s){return C(),M("div",w7e,[k(w0,{name:"flip-list",tag:"div",class:"drag-group"},{default:$(()=>[(C(!0),M(fe,null,nt(n.items,(i,l)=>(C(),M("div",{key:i[n.rowKey],onDragstart:a=>s.dragStart(a,l),onDragend:t[0]||(t[0]=(...a)=>s.dragEnd&&s.dragEnd(...a)),onDragover:et(a=>s.dragOver(a,l),["prevent"]),onDrop:et(a=>s.dropEnd(a,l),["prevent"]),draggable:!0,class:D(["drag-item",`${n.itemClass} hello_${l}`,{dragging:r.draggingIndex===l}]),style:Qe(n.itemStyle)},[he(e.$slots,"item",{data:i,index:l},void 0,!0)],46,C7e))),128))]),_:3})])}const xv=qe(b7e,[["render",k7e],["__scopeId","data-v-51d9f44b"]]),S7e={name:"MenuGroupSettings",components:{FluentDnD:xv,LogoEmojiSelector:Ev},data(){return{loading:!1,saving:!1,editingItem:null,editLinkModal:!1,isDragging:!1,isSpaceDragging:!1,draggingIndex:null,draggedSpaceIndex:null}},emits:["save"],props:{menuItems:{type:Array,required:!0},title:{type:String,required:!0},has_svg:{type:Boolean,default:!0},use_icon_selector:{type:Boolean,default:!1},has_enable_disable:{type:Boolean,default:!0},custom_svg:{type:Boolean,default:!1}},methods:{initEditLink(e){this.editingItem=e,this.editLinkModal=!0},removeLink(e){this.$confirm(this.$t("Are you sure you want to remove this link?"),this.$t("Warning"),{confirmButtonText:this.$t("Yes"),cancelButtonText:this.$t("Cancel"),type:"warning"}).then(()=>{this.menuItems.splice(e,1),this.saveMenuItems()}).catch(()=>{})},createOrUpdateLink(){this.editingItem.slug||(this.editingItem.slug="fcom_custom_"+this.editingItem.title.toLowerCase().replace(/[^a-z0-9]/g,"_"),this.menuItems.push(this.editingItem)),this.editLinkModal=!1,this.saveMenuItems(),this.editingItem=null},saveMenuItems(){this.$emit("save")},drop({index:e}){this.draggingIndex=null,this.saveMenuItems()}}},$7e={key:0,class:"fcom_section_primary"},E7e={class:"fcom_section_primary_item"},x7e={class:"fcom_section_primary_item_title"},M7e={class:"fcom_heading_item"},T7e={class:"fcom_section_item_actions"},O7e={class:"fcom_section_items menu-items-container"},I7e={key:0,style:{padding:"1rem"}},A7e={class:"fcom_section_item_title"},N7e={class:"fcom_heading_item"},P7e=b("div",{class:"fcom_drag_handle"}," ⋮⋮ ",-1),L7e={key:0,class:"community_avatar"},R7e=["src"],D7e={key:1,class:"fcom_emoji"},F7e={key:2,class:"fcom_shape"},V7e=["innerHTML"],B7e={class:"fcom_section_item_actions"},z7e={key:0},j7e={key:1},H7e={key:0};function U7e(e,t,n,o,r,s){const i=pt,l=Ne,a=mh,u=re("FluentDnD"),c=re("logo-emoji-selector"),d=At,f=io,p=Hn,h=so,m=Ql;return C(),M(fe,null,[n.menuItems?(C(),M("div",$7e,[b("div",E7e,[b("div",x7e,[b("div",M7e,[he(e.$slots,"title",{},()=>[b("h4",null,A(n.title),1)])])]),b("div",T7e,[k(i,{class:"fcom_primary_button",onClick:t[0]||(t[0]=y=>s.initEditLink({enabled:"yes",new_tab:"yes"}))},{default:$(()=>[ne(A(e.$t("Add New Link")),1)]),_:1})])]),b("div",O7e,[n.menuItems.length?W("",!0):(C(),M("div",I7e,[b("p",null,A(e.$t("No link has been added for this section")),1)])),k(u,{items:n.menuItems,"row-key":"slug",onDrop:s.drop,"item-class":"fcom_section_item","item-style":"padding: 15px 15px 15px 35px"},{item:$(({data:y,index:v})=>[b("div",A7e,[b("p",N7e,[n.use_icon_selector?(C(),M(fe,{key:0},[P7e,y.icon_image?(C(),M("div",L7e,[k(l,null,{default:$(()=>[b("img",{alt:"",style:{"max-width":"16px","max-height":"16px"},src:y.icon_image},null,8,R7e)]),_:2},1024)])):y.emoji?(C(),M("span",D7e,A(y.emoji),1)):y.shape_svg?(C(),M("span",F7e,[k(l,{innerHTML:y.shape_svg},null,8,["innerHTML"])])):W("",!0)],64)):y.icon_svg?(C(),q(l,{key:1},{default:$(()=>[b("span",{innerHTML:y.icon_svg},null,8,V7e)]),_:2},1024)):W("",!0),b("span",null,A(y.title),1),y.is_unavailable=="yes"?(C(),q(a,{key:2,type:"danger"},{default:$(()=>[ne(A(e.$t("unavailable")),1)]),_:1})):y.enabled=="yes"?(C(),q(a,{key:3,type:"success"},{default:$(()=>[ne(A(e.$t("enabled")),1)]),_:1})):(C(),q(a,{key:4,type:"info"},{default:$(()=>[ne(A(e.$t("disabled")),1)]),_:1}))])]),b("div",B7e,[b("div",null,[k(i,{onClick:w=>s.initEditLink(y),size:"small"},{default:$(()=>[ne(A(e.$t("Edit")),1)]),_:2},1032,["onClick"]),y.is_system!="yes"?(C(),q(i,{key:0,onClick:w=>s.removeLink(v),type:"danger",plain:"",size:"small"},{default:$(()=>[ne(A(e.$t("Delete")),1)]),_:2},1032,["onClick"])):W("",!0)])])]),_:1},8,["items","onDrop"])])])):W("",!0),k(m,{"modal-class":"fcom_common_dialog",id:"fluent_comminity_body",class:"fcom_high_drawer","close-on-click-modal":!1,size:e.drawerWidth,modelValue:r.editLinkModal,"onUpdate:modelValue":t[9]||(t[9]=y=>r.editLinkModal=y),direction:"rtl"},{header:$(()=>[r.editLinkModal&&r.editLinkModal.slug?(C(),M("h4",z7e,A(e.$t("Edit Link")),1)):(C(),M("h4",j7e,A(e.$t("Add Custom Link")),1))]),default:$(()=>[r.editingItem?(C(),M("div",H7e,[k(h,{onSubmit:t[8]||(t[8]=et(y=>e.doNothing(),["prevent"])),"label-position":"top"},{default:$(()=>[k(f,{label:e.$t("Name of the Link")},{default:$(()=>[k(d,{placeholder:e.$t("Public Name of the item"),modelValue:r.editingItem.title,"onUpdate:modelValue":t[2]||(t[2]=y=>r.editingItem.title=y)},tu({_:2},[n.use_icon_selector&&r.editingItem.is_system!="yesw"?{name:"prepend",fn:$(()=>[k(c,{custom_svg:n.custom_svg,fallback_mark:"",onUpdate:t[1]||(t[1]=y=>{r.editingItem.emoji=y.emoji,r.editingItem.icon_image=y.logo,r.editingItem.shape_svg=y.shape_svg}),config:{logo:r.editingItem.icon_image,emoji:r.editingItem.emoji||"",shape_svg:r.editingItem.shape_svg||""}},null,8,["custom_svg","config"])]),key:"0"}:void 0]),1032,["placeholder","modelValue"])]),_:1},8,["label"]),k(f,{label:e.$t("URL")},{default:$(()=>[k(d,{disabled:r.editingItem.is_system,type:"url",placeholder:e.$t("Url of the item"),modelValue:r.editingItem.permalink,"onUpdate:modelValue":t[3]||(t[3]=y=>r.editingItem.permalink=y)},null,8,["disabled","placeholder","modelValue"])]),_:1},8,["label"]),n.has_svg?(C(),q(f,{key:0,label:e.$t("SVG Code for Icon (Simplified SVG Code) / Emoji")},{default:$(()=>[k(d,{placeholder:e.$t("SVG Code. No url please / You can use emoji"),type:"textarea",rows:3,modelValue:r.editingItem.icon_svg,"onUpdate:modelValue":t[4]||(t[4]=y=>r.editingItem.icon_svg=y)},null,8,["placeholder","modelValue"])]),_:1},8,["label"])):W("",!0),n.has_enable_disable?(C(),q(f,{key:1},{default:$(()=>[k(p,{"true-value":"yes","false-value":"no",modelValue:r.editingItem.enabled,"onUpdate:modelValue":t[5]||(t[5]=y=>r.editingItem.enabled=y)},{default:$(()=>[ne(A(e.$t("Enable this link")),1)]),_:1},8,["modelValue"])]),_:1})):W("",!0),r.editingItem.is_system?W("",!0):(C(),q(f,{key:2},{default:$(()=>[k(p,{"true-value":"yes","false-value":"no",modelValue:r.editingItem.new_tab,"onUpdate:modelValue":t[6]||(t[6]=y=>r.editingItem.new_tab=y)},{default:$(()=>[ne(A(e.$t("Open this link on new tab")),1)]),_:1},8,["modelValue"])]),_:1})),k(f,null,{default:$(()=>[k(i,{class:"fcom_primary_button",onClick:t[7]||(t[7]=y=>s.createOrUpdateLink())},{default:$(()=>[ne(A(e.$t("Save")),1)]),_:1})]),_:1})]),_:1})])):W("",!0)]),_:1},8,["size","modelValue"])],64)}const dL=qe(S7e,[["render",U7e]]),W7e={name:"EditableContentInput",$emit:["update:modelValue"],props:{modelValue:{type:String,default:""},placeholder:{type:String,default:"Write something..."},wrapper_class:{type:String,default:""},show_button:{type:Boolean,default:!1}},computed:{listeners(){return{input:this.onInput}}},mounted(){this.$refs.editable.innerText=this.modelValue},methods:{onInput(e){let t=e.target.innerText,n=window.getSelection().getRangeAt(0).startOffset;t&&(t=t.replace(/<br>/g," "),t=t.replace(/<[^>]*>?/gm,""),t=t.replace(/&nbsp;/g,""),t=t.replace(/\n/g," ")),this.$refs.editable.focus(),this.$refs.editable.innerText=t,this.$emit("update:modelValue",t),this.$nextTick(()=>{this.$refs.editable.innerText=t,this.$refs.editable.focus();let o=document.createRange(),r=window.getSelection();o.selectNodeContents(this.$refs.editable);const s=Math.min(n,t.length);o.setStart(this.$refs.editable.childNodes[0]||this.$refs.editable,s),o.collapse(!0),r.removeAllRanges(),r.addRange(o)})},onClickInput(e){this.$refs.editable.innerText||(this.$refs.editable.focus(),window.getSelection().selectAllChildren(this.$refs.editable),window.getSelection().collapseToEnd())}}},K7e=["data-ph"];function q7e(e,t,n,o,r,s){return C(),M("div",un({class:[n.wrapper_class,"fcom_editable_input"],ref:"editable",onClick:t[0]||(t[0]=(...i)=>s.onClickInput&&s.onClickInput(...i)),contenteditable:"","data-ph":n.placeholder},vE(s.listeners,!0)),null,16,K7e)}const G7e=qe(W7e,[["render",q7e]]),Y7e={name:"MenuSettings",components:{EditableContentInput:G7e,MenuGroupSettings:dL,Layout:ri,AppLayout:si},data(){return{menuSettings:null,loading:!1,saving:!1}},methods:{fetchMenuItems(){this.loading=!0,this.$get("settings/menu-settings").then(e=>{this.menuSettings=e.menuSettings}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},saveMenuItems(){this.saving=!0,this.$post("settings/menu-settings",{menuSettings:this.menuSettings}).then(e=>{this.$notify.success(e.message),this.$eventBus.emit("reloadMenu")}).catch(e=>{this.$handleError(e),this.fetchMenuItems()}).finally(()=>{this.saving=!1})},addFooterGroup(){this.menuSettings.afterCommunityLinkGroups.push({title:"",items:[]})}},mounted(){this.fetchMenuItems()}},Z7e={class:"settings_router"},J7e={key:0},X7e={class:"fcom_card_sections"},Q7e={class:"fcom_card_sections"},exe={class:"fcom_card_sections"},txe={key:0,class:"fcom_card_sections"},nxe={class:"fcom_section_primary_item"},oxe={class:"fcom_section_primary_item_title"},rxe={class:"fcom_heading_item"},sxe={style:{"justify-content":"center"},class:"fcom_section_primary_item"},ixe={key:1,class:"white_loaded"};function lxe(e,t,n,o,r,s){const i=pt,l=re("menu-group-settings"),a=At,u=lo,c=re("layout"),d=re("app-layout");return C(),q(d,{wrapper_class:"fcom_single_layout fcom_member_profile fcom_max_layout"},{default:$(()=>[k(c,{wrapper_class:"no_bg_layout",title:e.$t("Menu Settings")},{actions:$(()=>[k(i,{class:"fcom_primary_button",disabled:r.saving||r.loading,onClick:s.saveMenuItems},{default:$(()=>[b("span",null,A(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])]),default:$(()=>[b("div",Z7e,[r.menuSettings?(C(),M("div",J7e,[b("div",X7e,[r.menuSettings.mainMenuItems?(C(),q(l,{key:0,custom_svg:!0,use_icon_selector:!0,has_svg:!1,onSave:t[0]||(t[0]=f=>s.saveMenuItems()),title:e.$t("Primary Menu Items"),menuItems:r.menuSettings.mainMenuItems},null,8,["title","menuItems"])):W("",!0)]),b("div",Q7e,[r.menuSettings.profileDropdownItems?(C(),q(l,{key:0,custom_svg:!0,use_icon_selector:!0,has_svg:!1,onSave:t[1]||(t[1]=f=>s.saveMenuItems()),title:e.$t("Profile Dropdown Items"),menuItems:r.menuSettings.profileDropdownItems},null,8,["title","menuItems"])):W("",!0)]),b("div",exe,[r.menuSettings.beforeCommunityMenuItems?(C(),q(l,{key:0,custom_svg:!0,use_icon_selector:!0,has_svg:!1,onSave:t[2]||(t[2]=f=>s.saveMenuItems()),title:e.$t("Top Links (At Sidebar)"),menuItems:r.menuSettings.beforeCommunityMenuItems},null,8,["title","menuItems"])):W("",!0)]),r.menuSettings.afterCommunityLinkGroups?(C(),M("div",txe,[b("div",nxe,[b("div",oxe,[b("div",rxe,[b("h4",null,A(e.$t("Sidebar Bottom Link Groups")),1)])])]),(C(!0),M(fe,null,nt(r.menuSettings.afterCommunityLinkGroups,f=>(C(),M("div",null,[k(l,{custom_svg:!0,has_svg:!1,use_icon_selector:!0,onSave:t[3]||(t[3]=p=>s.saveMenuItems()),title:e.$t("Sidebar Bottom Link Groups"),menuItems:f.items},{title:$(()=>[k(a,{modelValue:f.title,"onUpdate:modelValue":p=>f.title=p,placeholder:e.$t("Group Title")},{append:$(()=>[k(i,{onClick:s.saveMenuItems,text:""},{default:$(()=>[ne(A(e.$t("save")),1)]),_:1},8,["onClick"])]),_:2},1032,["modelValue","onUpdate:modelValue","placeholder"])]),_:2},1032,["title","menuItems"])]))),256)),b("div",sxe,[k(i,{onClick:t[4]||(t[4]=f=>s.addFooterGroup())},{default:$(()=>[ne(A(e.$t("Add Another Group")),1)]),_:1})])])):W("",!0)])):(C(),M("div",ixe,[k(u,{animated:!0,rows:10})]))])]),_:1},8,["title"])]),_:1})}const axe=qe(Y7e,[["render",lxe]]),uxe={name:"SlugInput",emits:["update:modelValue"],props:{modelValue:{type:String,default:""},placeholder:{type:String,default:""},disabled:{type:Boolean,default:!1}},data(){return{model:this.modelValue}},methods:{updateSlug(){this.model=this.model.replace(/\s/g,"-"),this.model=this.model.replace(/[^a-zA-Z0-9-_]/g,""),this.$emit("update:modelValue",this.model)}}};function cxe(e,t,n,o,r,s){const i=At;return C(),q(i,{disabled:n.disabled,modelValue:r.model,"onUpdate:modelValue":t[0]||(t[0]=l=>r.model=l),placeholder:n.placeholder,onInput:s.updateSlug},null,8,["disabled","modelValue","placeholder","onInput"])}const Pk=qe(uxe,[["render",cxe]]),dxe={name:"TopicSelector",props:["modelValue"],emits:["update:modelValue"],data(){return{topics:[],selected:this.modelValue,loading:!1}},methods:{fetchTopics(){this.loading=!0,this.$get("admin/topics",{optionsOnly:!0}).then(e=>{this.topics=e.topics}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})}},watch:{selected(){this.$emit("update:modelValue",this.selected)}},mounted(){this.fetchTopics()}};function fxe(e,t,n,o,r,s){const i=Ss,l=vr,a=zt("loading");return He((C(),q(l,{"multiple-limit":20,modelValue:r.selected,"onUpdate:modelValue":t[0]||(t[0]=u=>r.selected=u),multiple:!0,clearable:"",filterable:"",placeholder:e.$t("Choose up to 20 topics")},{default:$(()=>[(C(!0),M(fe,null,nt(r.topics,u=>(C(),q(i,{key:u.slug,label:u.title,value:u.id},{default:$(()=>[b("span",null,A(u.title),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])),[[a,r.loading]])}const fL=qe(dxe,[["render",fxe]]),pxe={name:"CreateSpaceForm",emits:["completed"],components:{SlugInput:Pk,ImageUploader:Md,LogoEmojiSelector:Ev,TopicSelector:fL},props:{community:{required:!1,default:null},parent_id:{required:!1,default:null},savingCount:{required:!1,default:0}},data(){return{saving:!1,privacies:L1e,form:{title:"",slug:"",privacy:"private",parent_id:"",description:"",settings:{custom_lock_screen:"no",restricted_post_only:"no",emoji:"🚀",shape_svg:"",can_request_join:"yes",layout_style:"timeline",show_sidebar:"yes"},topic_ids:[]},dataLoaded:!1,showingSections:["basic"]}},watch:{savingCount(){this.submit()}},methods:{submit(){this.saving=!0;let e="spaces",t={space:this.form},n=this.$post;this.form.id&&(e+="/"+this.form.slug+"/by-slug",t={data:{title:this.form.title,privacy:this.form.privacy,description:this.form.description,group_chat_support:this.form.group_chat_support,settings:this.form.settings,logo:this.form.logo,parent_id:this.form.parent_id,cover_photo:this.form.cover_photo,topic_ids:this.form.topic_ids}},n=this.$put),n(e,t).then(o=>{if(this.$eventBus.emit("reloadMenu"),!this.form.id){let r=this.$router.resolve({name:"space_feeds",params:{space:o.space.slug}}).href;window.location.href=r;return}this.$notify.success(o.message),this.$emit("completed",o.space)}).catch(o=>{this.form.id||(this.showingSections=["basic"]),this.$handleError(o)}).finally(()=>{this.saving=!1})},handleCoverPhotoUpload(e){this.form.cover_photo=e},handleLogoPhotoUpload(e){this.form.logo=e}},mounted(){if(this.community&&this.community.id){this.community.chat_thread_id&&(this.community.group_chat_support="yes"),this.form=this.community;let e=[];this.community.topics&&this.each(this.community.topics,t=>{e.push(t.id)}),this.form.topic_ids=e}else this.parent_id?(this.form.parent_id=this.parent_id,this.$route.query.parent_id):this.$route.query.parent_id&&(this.form.parent_id=this.$route.query.parent_id);this.form.id&&(this.showingSections=["basic","customization"]),this.dataLoaded=!0}},hxe={key:0},mxe={style:{"font-weight":"bold"}},gxe=["innerHTML"],vxe={key:0},yxe={class:"fcom_lined_checkboxes"},_xe={class:"fcom_help_text"},bxe={class:"fcom_help_text"},wxe=["href"],Cxe={class:"fcom_help_text"},kxe={class:"fcom_help_text"},Sxe={key:0},$xe={key:1},Exe={class:"fcom_space_form_bottom"};function xxe(e,t,n,o,r,s){const i=re("logo-emoji-selector"),l=At,a=io,u=re("SlugInput"),c=Ss,d=vr,f=U0,p=Eu,h=Hn,m=re("topic-selector"),y=Ed,v=re("ImageUploader"),w=pt,_=so,S=zt("loading");return C(),q(_,{onSubmit:t[17]||(t[17]=et(x=>e.doNothing(),["prevent"])),modelValue:r.form,"onUpdate:modelValue":t[18]||(t[18]=x=>r.form=x),"label-position":"top",class:"fcom_space_form"},{default:$(()=>[r.showingSections.indexOf("basic")!==-1?(C(),M(fe,{key:0},[r.form.id?W("",!0):(C(),M("h4",hxe,A(e.$t("Basic Info")),1)),k(a,{label:e.$t("Space Title")},{default:$(()=>[k(l,{type:"text",placeholder:e.$t("Your Space Title"),modelValue:r.form.title,"onUpdate:modelValue":t[1]||(t[1]=x=>r.form.title=x)},{prepend:$(()=>{var x,E;return[r.dataLoaded?(C(),q(i,{key:0,onUpdate:t[0]||(t[0]=T=>{r.form.settings.emoji=T.emoji,r.form.logo=T.logo,r.form.settings.shape_svg=T.shape_svg}),config:{logo:r.form.logo,emoji:((x=r.form.settings)==null?void 0:x.emoji)||"",shape_svg:(E=r.form.settings)==null?void 0:E.shape_svg}},null,8,["config"])):W("",!0)]}),_:1},8,["placeholder","modelValue"])]),_:1},8,["label"]),k(a,{label:e.$t("Slug")},{default:$(()=>[k(u,{disabled:!!r.form.id,modelValue:r.form.slug,"onUpdate:modelValue":t[2]||(t[2]=x=>r.form.slug=x),placeholder:e.$t("Space Slug (no space or special chars)")},null,8,["disabled","modelValue","placeholder"])]),_:1},8,["label"]),k(a,{label:e.$t("Description")},{default:$(()=>[k(l,{type:"textarea",rows:3,placeholder:e.$t("Space Description"),modelValue:r.form.description,"onUpdate:modelValue":t[3]||(t[3]=x=>r.form.description=x)},null,8,["placeholder","modelValue"])]),_:1},8,["label"]),k(a,{label:e.$t("Privacy")},{default:$(()=>[k(d,{"popper-class":"rich_select",modelValue:r.form.privacy,"onUpdate:modelValue":t[4]||(t[4]=x=>r.form.privacy=x),placeholder:e.$t("Select Privacy")},{default:$(()=>[(C(!0),M(fe,null,nt(r.privacies,(x,E)=>(C(),q(c,{key:E,label:x.label,value:E},{default:$(()=>[b("span",mxe,A(e.$labelize(x.label)),1),b("p",{innerHTML:x.description},null,8,gxe)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),r.form.privacy=="private"?(C(),q(a,{key:1,label:e.$t("Lock Screen Type")},{default:$(()=>[k(p,{modelValue:r.form.settings.custom_lock_screen,"onUpdate:modelValue":t[5]||(t[5]=x=>r.form.settings.custom_lock_screen=x)},{default:$(()=>[k(f,{value:"yes"},{default:$(()=>[ne(A(e.$t("Custom Lock Screen")),1)]),_:1}),k(f,{value:"no"},{default:$(()=>[ne(A(e.$t("Default Lock Screen")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["label"])):W("",!0),r.form.settings.custom_lock_screen=="no"?(C(),q(a,{key:2},{default:$(()=>[k(h,{"true-value":"yes","false-value":"no",modelValue:r.form.settings.can_request_join,"onUpdate:modelValue":t[6]||(t[6]=x=>r.form.settings.can_request_join=x)},{default:$(()=>[ne(A(e.$t("Allow users to request to join this Space")),1)]),_:1},8,["modelValue"])]),_:1})):W("",!0),k(a,{label:e.$t("Menu Group")},{default:$(()=>[k(d,{modelValue:r.form.parent_id,"onUpdate:modelValue":t[7]||(t[7]=x=>r.form.parent_id=x)},{default:$(()=>[(C(!0),M(fe,null,nt(e.appVars.space_groups,x=>(C(),q(c,{key:x.id,value:x.id.toString(),label:x.title},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])]),_:1},8,["label"])],64)):W("",!0),r.showingSections.indexOf("customization")!==-1?(C(),M(fe,{key:1},[r.form.id?W("",!0):(C(),M("h4",vxe,A(e.$t("Customization")),1)),r.form.settings?(C(),q(a,{key:1,label:e.$t("Features Customizations")},{default:$(()=>[b("div",yxe,[k(h,{"true-value":"yes","false-value":"no",modelValue:r.form.settings.restricted_post_only,"onUpdate:modelValue":t[8]||(t[8]=x=>r.form.settings.restricted_post_only=x)},{default:$(()=>[ne(A(e.$t("Only admin or moderators can create post")),1)]),_:1},8,["modelValue"]),k(h,{"true-value":"yes","false-value":"no",modelValue:r.form.settings.show_sidebar,"onUpdate:modelValue":t[9]||(t[9]=x=>r.form.settings.show_sidebar=x)},{default:$(()=>[ne(A(e.$t("Show Right Sidebar on Space")),1)]),_:1},8,["modelValue"])])]),_:1},8,["label"])):W("",!0),k(a,{label:e.$t("Default layout styles")},{default:$(()=>[k(p,{modelValue:r.form.settings.layout_style,"onUpdate:modelValue":t[10]||(t[10]=x=>r.form.settings.layout_style=x)},{default:$(()=>[k(f,{value:"timeline"},{default:$(()=>[ne(A(e.$t("Timeline")),1)]),_:1}),k(f,{value:"list"},{default:$(()=>[ne(A(e.$t("List")),1)]),_:1})]),_:1},8,["modelValue"]),b("div",_xe,[b("p",null,A(e.$t("User can change the layout style for their own preference")),1)])]),_:1},8,["label"]),e.has_pro&&r.form.id?(C(),q(a,{key:2,label:e.$t("Topic navigation")},{default:$(()=>[k(m,{modelValue:r.form.topic_ids,"onUpdate:modelValue":t[11]||(t[11]=x=>r.form.topic_ids=x)},null,8,["modelValue"]),b("div",bxe,[b("p",null,[ne(A(e.$t("Categorize your posts and allow members to filter spaces with the topic navigation bar. You can define up to 20 topics per space"))+" ",1),b("a",{target:"_blank",rel:"noopener",href:e.$getRouteLink("admin/settings/topics-settings")},A(e.$t("Manage all topics.")),9,wxe)])])]),_:1},8,["label"])):W("",!0),e.appVars.has_chat?(C(),q(a,{key:3,label:e.$t("Group Chat?")},{default:$(()=>[k(h,{"true-value":"yes","false-value":"no",modelValue:r.form.group_chat_support,"onUpdate:modelValue":t[12]||(t[12]=x=>r.form.group_chat_support=x)},{default:$(()=>[ne(A(e.$t("Enable group chat for this space members")),1)]),_:1},8,["modelValue"])]),_:1},8,["label"])):W("",!0),k(a,{label:e.$t("Thumbnail / Open Graph Image (Recommended Size: 1200 x 630)")},{default:$(()=>[r.form.settings.og_image?(C(),q(y,{key:0,alt:e.$t("Thumbnail / Open Graph Image"),src:r.form.settings.og_image,style:{"max-width":"100px"}},null,8,["alt","src"])):W("",!0),k(v,{isTextBtn:!1,can_remove:!!r.form.settings.og_image,additionalData:{resize:!0,max_width:1200,max_height:630},onUploaded:t[13]||(t[13]=x=>{r.form.settings.og_image=x})},null,8,["can_remove"]),b("div",Cxe,[b("p",null,A(e.$t("Will be used on card preview and social sharing preview.")),1)])]),_:1},8,["label"]),k(a,{label:e.$t("Featured Image (Recommended size: 1600x500) - Optional")},{default:$(()=>[r.form.cover_photo?(C(),q(y,{key:0,alt:e.$t("Featured Image Preview"),src:r.form.cover_photo,style:{"max-width":"100px"}},null,8,["alt","src"])):W("",!0),k(v,{isTextBtn:!1,can_remove:!!r.form.cover_photo,additionalData:{resize:!0,max_width:1600},onUploaded:s.handleCoverPhotoUpload},null,8,["can_remove","onUploaded"]),b("div",kxe,[b("p",null,A(e.$t("If you add this image, it will be shown on the space homepage")),1)])]),_:1},8,["label"]),k(a,{style:{"margin-top":"45px"}},{default:$(()=>[r.showingSections.indexOf("basic")===-1?(C(),q(w,{key:0,class:"plain_button",text:"",onClick:t[14]||(t[14]=()=>{r.showingSections=["basic"]})},{default:$(()=>[b("span",null,A(e.$t("Go Back")),1)]),_:1})):W("",!0),He((C(),q(w,{class:"fcom_primary_button",disabled:r.saving,onClick:t[15]||(t[15]=x=>s.submit())},{default:$(()=>[r.form.id?(C(),M("span",Sxe,A(e.$t("Update Info")),1)):(C(),M("span",$xe,A(e.$t("Create")),1))]),_:1},8,["disabled"])),[[S,r.saving]])]),_:1})],64)):(C(),q(a,{key:2},{default:$(()=>[b("div",Exe,[k(w,{onClick:t[16]||(t[16]=()=>{r.showingSections=["customization"]}),class:"fcom_primary_button"},{default:$(()=>[b("span",null,A(e.$t("Continue")),1)]),_:1})])]),_:1}))]),_:1},8,["modelValue"])}const Mxe=qe(pxe,[["render",xxe]]),Txe={name:"CreateGroupForm",emits:["completed"],components:{ImageUploader:Md},props:{group:{required:!1,default:{title:"",slug:"",description:"",settings:{always_show_spaces:"yes"}}}},data(){return{saving:!1,form:{}}},methods:{submit(){this.saving=!0;let e="spaces/space_groups",t={title:this.form.title,description:this.form.description,settings:this.form.settings,slug:this.form.slug},n=this.$post;this.form.id&&(e+="/"+this.form.id,n=this.$put),n(e,t).then(o=>{this.$eventBus.emit("reloadMenu"),this.form={},this.$notify.success(o.message),this.$emit("completed",o.group)}).catch(o=>{this.$handleError(o)}).finally(()=>{this.saving=!1})}},mounted(){this.group&&this.group.id?this.form=this.group:this.form={title:"",slug:"",description:"",settings:{always_show_spaces:"yes"}}}},Oxe=b("span",null,"#",-1),Ixe={key:0},Axe={key:1};function Nxe(e,t,n,o,r,s){const i=At,l=io,a=Hn,u=pt,c=so,d=zt("loading");return C(),q(c,{onSubmit:t[5]||(t[5]=et(f=>e.doNothing(),["prevent"])),modelValue:r.form,"onUpdate:modelValue":t[6]||(t[6]=f=>r.form=f),"label-position":"top"},{default:$(()=>[k(l,{label:e.$t("Group Title")},{default:$(()=>[k(i,{type:"text",placeholder:e.$t("Your Group Title"),modelValue:r.form.title,"onUpdate:modelValue":t[0]||(t[0]=f=>r.form.title=f)},null,8,["placeholder","modelValue"])]),_:1},8,["label"]),k(l,{label:e.$t("Slug")},{default:$(()=>[k(i,{disabled:!!r.form.id,type:"text",placeholder:e.$t("Group Slug (no space or special chars)"),modelValue:r.form.slug,"onUpdate:modelValue":t[1]||(t[1]=f=>r.form.slug=f)},{prefix:$(()=>[Oxe]),_:1},8,["disabled","placeholder","modelValue"])]),_:1},8,["label"]),k(l,{label:e.$t("Description")},{default:$(()=>[k(i,{type:"textarea",rows:3,placeholder:e.$t("Group Description"),modelValue:r.form.description,"onUpdate:modelValue":t[2]||(t[2]=f=>r.form.description=f)},null,8,["placeholder","modelValue"])]),_:1},8,["label"]),r.form.settings?(C(),q(l,{key:0,label:e.$t("Appearance")},{default:$(()=>[k(a,{"true-value":"yes","false-value":"no",modelValue:r.form.settings.always_show_spaces,"onUpdate:modelValue":t[3]||(t[3]=f=>r.form.settings.always_show_spaces=f)},{default:$(()=>[ne(A(e.$t("Show Spaces even if the user is not a member of any space")),1)]),_:1},8,["modelValue"])]),_:1},8,["label"])):W("",!0),k(l,null,{default:$(()=>[He((C(),q(u,{class:"fcom_primary_button",disabled:r.saving,onClick:t[4]||(t[4]=f=>s.submit())},{default:$(()=>[r.form.id?(C(),M("span",Ixe,A(e.$t("Update Info")),1)):(C(),M("span",Axe,A(e.$t("Create")),1))]),_:1},8,["disabled"])),[[d,r.saving]])]),_:1})]),_:1},8,["modelValue"])}const Pxe=qe(Txe,[["render",Nxe]]),Lxe={name:"MoveGroupPopup",props:{groups:{type:Array,default:()=>[]},currentSpace:{type:[Array,Object],default:null},openedSpaceId:{type:[String,Number],default:null}},data(){var e;return{isVisible:!1,selectedGroupId:null,currentGroupId:(e=this.currentSpace)==null?void 0:e.parent_id,working:!1}},watch:{openedSpaceId(e){this.isVisible=e==this.currentSpace.id}},computed:{filteredGroups(){return this.groups.filter(e=>e.id!=this.currentGroupId)}},methods:{togglePopover(){this.$emit("togglePopover",this.currentSpace.id)},moveSpace(){this.working=!0,this.$patch("spaces/space_groups/move-space",{space_id:this.currentSpace.id,group_id:this.selectedGroupId}).then(e=>{this.$notify.success(e.message),this.$emit("moved")}).catch(e=>{this.$handleError(e)}).finally(()=>{this.working=!1})}}};function Rxe(e,t,n,o,r,s){const i=re("MoreFilled"),l=Ne,a=pt,u=Ss,c=vr,d=io,f=so,p=Po,h=zt("loading");return C(),q(p,{persistent:!1,placement:"bottom",width:350,visible:r.isVisible,onHide:t[2]||(t[2]=m=>r.isVisible=!1)},{reference:$(()=>[k(a,{"aria-label":e.$t("View actions"),onClick:s.togglePopover,class:"fcom_dot_menu edit_action",size:"small",text:""},{default:$(()=>[k(l,null,{default:$(()=>[k(i)]),_:1})]),_:1},8,["aria-label","onClick"])]),default:$(()=>[k(f,{onSubmit:t[1]||(t[1]=et(m=>e.doNothing(),["prevent"])),"label-position":"top"},{default:$(()=>[k(d,{label:e.$t("Select Group")},{default:$(()=>[k(c,{modelValue:r.selectedGroupId,"onUpdate:modelValue":t[0]||(t[0]=m=>r.selectedGroupId=m)},{default:$(()=>[(C(!0),M(fe,null,nt(s.filteredGroups,m=>(C(),q(u,{key:m.id,label:m.title,value:m.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1},8,["label"]),k(d,null,{default:$(()=>[He((C(),q(a,{disabled:!r.selectedGroupId||r.working,onClick:s.moveSpace,class:"fcom_primary_button"},{default:$(()=>[ne(A(e.$t("Move Space")),1)]),_:1},8,["disabled","onClick"])),[[h,r.working]])]),_:1})]),_:1})]),_:1},8,["visible"])}const Dxe=qe(Lxe,[["render",Rxe]]),Fxe={name:"AllCommunities",components:{FluentDnD:xv,CreateSpaceForm:Mxe,CreateGroupForm:Pxe,Layout:ri,AppLayout:si,MoveGroupPopup:Dxe},data(){return{groups:[],loading:!0,joining:!1,openedSpaceId:null,createSpaceModal:!1,createGroupModal:!1,editingGroup:null,draggingIndexGroup:null,draggingIndexSpace:null}},computed:{communityCounts(){return this.groups.reduce((e,t)=>{var n;return e+(((n=t.spaces)==null?void 0:n.length)||0)},0)}},methods:{handleTogglePopover(e){this.openedSpaceId=this.openedSpaceId==e?null:e},getGroups(){this.loading=!0,this.editingGroup=null,this.$get("spaces/space_groups").then(e=>{this.groups=e.groups;const t=[];this.groups.forEach(n=>{t.push({id:n.id,title:n.title})}),this.appVars.space_groups=t}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},initEditGroup(e){this.editingGroup=e,this.createGroupModal=!0},resetGroupsIndexes(){const e={};cu(this.groups,(t,n)=>{e[t.id]=n+1}),this.$patch("spaces/space_groups/re-index",{indexes:e}).catch(t=>{this.$handleError(t)}).finally(()=>{this.$eventBus.emit("reloadMenu")})},resetSpaceIndexes(e){this.$patch("spaces/space_groups/re-index-spaces",{indexes:e}).then(t=>{this.$notify.success(t.message)}).catch(t=>{this.$handleError(t)}).finally(()=>{this.$eventBus.emit("reloadMenu")})},removeGroup(e){if(e&&e.spaces.length){this.$messageBox({title:this.$t("Can not be deleted"),message:this.$t("You can not delete a group with spaces. Please move the spaces to a different group first."),type:"warning",confirmButtonText:this.$t("Got it!")});return}this.$confirm(this.$t("Are you sure you want to remove this group?"),this.$t("Warning"),{confirmButtonText:this.$t("Yes, Delete this group"),cancelButtonText:this.$t("Cancel"),type:"warning"}).then(()=>{this.$del("spaces/space_groups/"+e.id).then(()=>{this.getGroups(),this.$eventBus.emit("reloadMenu")}).catch(t=>{this.$handleError(t)})})},getTypeTitle(e){return e=="community"?"space":e},dropGroup({index:e}){const t=this.groups.splice(e,1)[0];this.groups.splice(e,0,t),this.resetGroupsIndexes(),this.draggingIndexGroup=null},dropSpace({newItems:e,index:t}){const n=e[0].parent_id;let o=this.groups.find(i=>Number(i.id)===Number(n)).spaces||[];const r=o.splice(t,1)[0];o.splice(t,0,r);let s=[];cu(o,(i,l)=>{s.push(i.id)}),this.resetSpaceIndexes(s),this.draggingIndexSpace=null}},mounted(){this.getGroups()}},Vxe={class:"settings_router"},Bxe={class:"fcom_communities"},zxe={class:"fcom_card_sections"},jxe={class:"fcom_card_section_heading"},Hxe={class:"fcom_section_primary_item"},Uxe={class:"fcom_section_primary_item_title"},Wxe=b("div",{class:"fcom_drag_handle"}," ⋮⋮ ",-1),Kxe={class:"fcom_heading_item"},qxe={class:"fcom_section_item_actions"},Gxe={class:"fcom_section_items"},Yxe={class:"fcom_section_item_title"},Zxe=b("div",{class:"fcom_drag_handle"}," ⋮⋮ ",-1),Jxe={class:"fcom_heading_item"},Xxe={class:"fcom_section_item_actions"},Qxe=["href"];function eMe(e,t,n,o,r,s){const i=pt,l=lo,a=mh,u=re("MoveGroupPopup"),c=re("FluentDnD"),d=re("layout"),f=re("app-layout"),p=re("create-group-form"),h=Ql,m=zt("loading");return C(),M(fe,null,[k(f,{wrapper_class:"fcom_single_layout fcom_member_profile fcom_max_layout"},{default:$(()=>[k(d,{wrapper_class:"no_bg_layout",title:e.$t("All Space Groups")},{actions:$(()=>[k(i,{class:"fcom_primary_button",onClick:t[0]||(t[0]=y=>r.createGroupModal=!0)},{default:$(()=>[ne(A(e.$t("Create New Group")),1)]),_:1})]),default:$(()=>[b("div",Vxe,[He((C(),M("div",Bxe,[b("div",zxe,[He((C(),M("div",jxe,[b("h3",null,A(e.$_n("%d Group","%d Groups",r.groups.length))+" • "+A(e.$_n("%d Space","%d Spaces",s.communityCounts)),1)])),[[m,r.loading]]),r.loading?(C(),q(l,{key:0,animated:!0,row:5})):W("",!0),k(c,{items:r.groups,onDrop:s.dropGroup},{item:$(({data:y})=>[b("div",Hxe,[b("div",Uxe,[Wxe,b("div",Kxe,[b("h4",null,A(e.$t("Group:"))+" "+A(y.title),1)])]),b("div",qxe,[k(i,{class:"fcom_secondary_button",onClick:v=>s.initEditGroup(y)},{default:$(()=>[ne(A(e.$t("Edit Info")),1)]),_:2},1032,["onClick"]),k(i,{onClick:v=>s.removeGroup(y),type:"danger",plain:""},{default:$(()=>[ne(A(e.$t("Delete")),1)]),_:2},1032,["onClick"])])]),b("div",Gxe,[k(c,{items:y.spaces,"item-class":"fcom_section_item","item-style":"padding: 15px 15px 15px 35px",onDrop:s.dropSpace},{item:$(({data:v,index:w})=>[b("div",Yxe,[Zxe,b("p",Jxe,[ne(A(v.title)+" ",1),v.status!="published"?(C(),q(a,{key:0,type:"info"},{default:$(()=>[ne(A(e.$labelize(v.status)),1)]),_:2},1024)):W("",!0),k(a,null,{default:$(()=>[ne(A(s.getTypeTitle(v.type)),1)]),_:2},1024)])]),b("div",Xxe,[b("a",{class:"el-button el-button--small el-button--secondary",href:v.permalink},A(e.$t("View")),9,Qxe),k(u,{groups:r.groups,currentSpace:v,openedSpaceId:r.openedSpaceId,onTogglePopover:s.handleTogglePopover,onMoved:t[1]||(t[1]=_=>s.getGroups())},null,8,["groups","currentSpace","openedSpaceId","onTogglePopover"])])]),_:2},1032,["items","onDrop"])])]),_:1},8,["items","onDrop"])])])),[[m,r.loading]])])]),_:1},8,["title"])]),_:1}),k(h,{"modal-class":"fcom_common_dialog",id:"fluent_comminity_body","close-on-click-modal":!1,"append-to-body":!0,size:e.dialogWidth,modelValue:r.createGroupModal,"onUpdate:modelValue":t[3]||(t[3]=y=>r.createGroupModal=y),direction:"rtl"},{header:$(()=>[b("h4",null,A(e.$t("Create a new Group")),1)]),default:$(()=>[r.createGroupModal?(C(),q(p,{key:0,group:r.editingGroup,onCompleted:t[2]||(t[2]=y=>{r.createGroupModal=!1,s.getGroups()})},null,8,["group"])):W("",!0)]),_:1},8,["size","modelValue"])],64)}const tMe=qe(Fxe,[["render",eMe]]),nMe={name:"CreateSpaceForm",components:{TopicSelector:fL,SlugInput:Pk,ImageUploader:Md,LogoEmojiSelector:Ev},emits:["completed","close"],props:{course:{required:!1,default:{title:"",description:"",privacy:"public",course_type:"self_paced",cover_photo:"",parent_id:"",status:"draft",category_ids:[],settings:{emoji:"",custom_lock_screen:"no",shape_svg:""}}},savingCount:{required:!1,default:0},parent_id:{required:!1,default:null}},data(){return{saving:!1,privacies:R1e,form:{slug:"",title:"",description:"",privacy:"public",course_type:"self_paced",cover_photo:"",parent_id:"",status:"draft",category_ids:[],settings:{emoji:"",custom_lock_screen:"no",shape_svg:""}},courseTypes:D1e,dataLoaded:!1}},watch:{savingCount(){this.submit(!0)}},methods:{submit(e=!1){this.saving=!0;let t="admin/courses",n=this.form,o=this.$post;this.form.id&&(t+="/"+this.form.id,n={title:this.form.title,privacy:this.form.privacy,course_type:this.form.course_type,description:this.form.description,status:this.form.status,cover_photo:this.form.cover_photo,parent_id:this.form.parent_id,settings:this.form.settings,category_ids:this.form.category_ids},o=this.$put),o(t,n).then(r=>{if(!this.form.id){let s=this.$getRouteLink("admin/manage-courses/edit/"+r.course.id+"/lessons");window.location.href=s,this.form={};return}this.$eventBus.emit("reloadMenu"),this.$notify.success(r.message),this.$emit("completed",r.course),e&&this.$emit("close")}).catch(r=>{this.$handleError(r)}).finally(()=>{this.saving=!1})},handlePhotoUpload(e){this.form.cover_photo=e}},mounted(){this.course.id?this.form=this.course:this.parent_id&&(this.form.parent_id=this.parent_id),this.dataLoaded=!0}},oMe={style:{"font-weight":"bold"}},rMe={style:{"font-weight":"bold"}},sMe={class:"fcom_help_text"},iMe=["href"],lMe={class:"fcom_help_text"},aMe={key:0},uMe={key:1},cMe={key:1},dMe=["href"];function fMe(e,t,n,o,r,s){const i=re("logo-emoji-selector"),l=At,a=io,u=re("SlugInput"),c=Ss,d=vr,f=U0,p=Eu,h=re("topic-selector"),m=Ed,y=re("ImageUploader"),v=pt,w=so,_=zt("loading");return e.hasFeature("has_course")?(C(),q(w,{key:0,onSubmit:t[11]||(t[11]=et(S=>e.doNothing(),["prevent"])),modelValue:r.form,"onUpdate:modelValue":t[12]||(t[12]=S=>r.form=S),"label-position":"top"},{default:$(()=>[k(a,{label:e.$t("Course Title")},{default:$(()=>[k(l,{type:"text",placeholder:e.$t("Your Course Title"),modelValue:r.form.title,"onUpdate:modelValue":t[1]||(t[1]=S=>r.form.title=S)},{prepend:$(()=>{var S,x;return[r.dataLoaded?(C(),q(i,{key:0,custom_svg:!0,onUpdate:t[0]||(t[0]=E=>{r.form.settings.emoji=E.emoji,r.form.logo=E.logo,r.form.settings.shape_svg=E.shape_svg}),config:{logo:r.form.logo,emoji:(S=r.form.settings)==null?void 0:S.emoji,shape_svg:((x=r.form.settings)==null?void 0:x.shape_svg)||""}},null,8,["config"])):W("",!0)]}),_:1},8,["placeholder","modelValue"])]),_:1},8,["label"]),k(a,{label:e.$t("Slug")},{default:$(()=>[k(u,{disabled:!!r.form.id,modelValue:r.form.slug,"onUpdate:modelValue":t[2]||(t[2]=S=>r.form.slug=S),placeholder:e.$t("Course Slug (no space or special chars)")},null,8,["disabled","modelValue","placeholder"]),b("pre",null,A(r.form.slug),1)]),_:1},8,["label"]),k(a,{label:e.$t("Short Description")},{default:$(()=>[k(l,{type:"textarea",rows:3,placeholder:e.$t("Course Description"),modelValue:r.form.description,"onUpdate:modelValue":t[3]||(t[3]=S=>r.form.description=S)},null,8,["placeholder","modelValue"])]),_:1},8,["label"]),k(a,{label:e.$t("Privacy")},{default:$(()=>[k(d,{"popper-class":"rich_select",modelValue:r.form.privacy,"onUpdate:modelValue":t[4]||(t[4]=S=>r.form.privacy=S),placeholder:e.$t("Select Privacy")},{default:$(()=>[(C(!0),M(fe,null,nt(r.privacies,(S,x)=>(C(),q(c,{key:x,label:S.label,value:x},{default:$(()=>[b("span",oMe,A(S.label),1),b("p",null,A(S.description),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),r.form.privacy!="public"?(C(),q(a,{key:0,label:e.$t("Lock Screen Type")},{default:$(()=>[k(p,{modelValue:r.form.settings.custom_lock_screen,"onUpdate:modelValue":t[5]||(t[5]=S=>r.form.settings.custom_lock_screen=S)},{default:$(()=>[k(f,{value:"yes"},{default:$(()=>[ne(A(e.$t("Custom")),1)]),_:1}),k(f,{value:"no"},{default:$(()=>[ne(A(e.$t("Default")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["label"])):W("",!0),k(a,{label:e.$t("Menu Group")},{default:$(()=>[k(d,{modelValue:r.form.parent_id,"onUpdate:modelValue":t[6]||(t[6]=S=>r.form.parent_id=S)},{default:$(()=>[(C(!0),M(fe,null,nt(e.appVars.space_groups,S=>(C(),q(c,{key:S.id,value:S.id.toString(),label:S.title},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])]),_:1},8,["label"]),k(a,{label:e.$t("Enrollment Type")},{default:$(()=>[k(d,{"popper-class":"rich_select",modelValue:r.form.course_type,"onUpdate:modelValue":t[7]||(t[7]=S=>r.form.course_type=S),placeholder:e.$t("Select Type")},{default:$(()=>[(C(!0),M(fe,null,nt(r.courseTypes,(S,x)=>(C(),q(c,{key:x,label:S.label,value:x},{default:$(()=>[b("span",rMe,A(S.label),1),b("p",null,A(S.description),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),k(a,{label:e.$t("Status")},{default:$(()=>[k(p,{modelValue:r.form.status,"onUpdate:modelValue":t[8]||(t[8]=S=>r.form.status=S)},{default:$(()=>[k(f,{value:"published"},{default:$(()=>[ne(A(e.$t("Published")),1)]),_:1}),k(f,{value:"draft"},{default:$(()=>[ne(A(e.$t("Draft")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.has_pro&&r.form.id?(C(),q(a,{key:1,label:e.$t("Topic navigation")},{default:$(()=>[k(h,{modelValue:r.form.category_ids,"onUpdate:modelValue":t[9]||(t[9]=S=>r.form.category_ids=S)},null,8,["modelValue"]),b("div",sMe,[b("p",null,[ne(A(e.$t("Categorize your course and allow members to filter courses with the topic navigation bar in the courses directory. You can define up to 20 topics per course."))+" ",1),b("a",{target:"_blank",rel:"noopener",href:e.$getRouteLink("admin/settings/topics-settings")},A(e.$t("Manage all topics.")),9,iMe)])])]),_:1},8,["label"])):W("",!0),k(a,{label:e.$t("Thumbnail / Open Graph Image (Recommended Size: 1200 x 630)")},{default:$(()=>[r.form.cover_photo?(C(),q(m,{key:0,alt:e.$t("Cover Photo"),src:r.form.cover_photo,style:{"max-width":"100px"}},null,8,["alt","src"])):W("",!0),k(y,{isTextBtn:!1,can_remove:!!r.form.cover_photo,additionalData:{resize:!0,max_width:1200,max_height:630},onUploaded:s.handlePhotoUpload},null,8,["can_remove","onUploaded"]),b("div",lMe,[b("p",null,A(e.$t("Will be used on course card preview and social sharing preview.")),1)])]),_:1},8,["label"]),k(a,null,{default:$(()=>[He((C(),q(v,{class:"fcom_primary_button",disabled:r.saving,onClick:t[10]||(t[10]=S=>s.submit())},{default:$(()=>[r.form.id?(C(),M("span",aMe,A(e.$t("Update Info")),1)):(C(),M("span",uMe,A(e.$t("Create")),1))]),_:1},8,["disabled"])),[[_,r.saving]])]),_:1})]),_:1},8,["modelValue"])):(C(),M("div",cMe,[b("p",null,A(e.$t("Course Module is disabled. Please enable the course module first")),1),b("a",{class:"el-button el-button--default fcom_primary_button",href:e.$getRouteLink("admin/settings/features")},A(e.$t("Go to features settings")),9,dMe)]))}const pL=qe(nMe,[["render",fMe]]),pMe={name:"GroupIcon"},hMe={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},mMe=b("path",{d:"M13.8494 12C14.3489 12 14.7462 11.6856 15.103 11.2461C15.8333 10.3463 14.6342 9.62723 14.1769 9.27507C13.712 8.91708 13.1929 8.71428 12.6667 8.66667M12 7.33333C12.9205 7.33333 13.6667 6.58714 13.6667 5.66667C13.6667 4.74619 12.9205 4 12 4",stroke:"currentColor","stroke-linecap":"round"},null,-1),gMe=b("path",{d:"M2.15096 12C1.65143 12 1.2541 11.6856 0.897356 11.2461C0.167051 10.3463 1.36611 9.62723 1.82342 9.27507C2.28831 8.91708 2.80738 8.71428 3.33366 8.66667M3.66699 7.33333C2.74652 7.33333 2.00033 6.58714 2.00033 5.66667C2.00033 4.74619 2.74652 4 3.66699 4",stroke:"currentColor","stroke-linecap":"round"},null,-1),vMe=b("path",{d:"M5.38953 10.0738C4.70834 10.495 2.92232 11.3551 4.01013 12.4313C4.54151 12.957 5.13334 13.333 5.87741 13.333H10.1232C10.8673 13.333 11.4591 12.957 11.9905 12.4313C13.0783 11.3551 11.2923 10.495 10.6111 10.0738C9.01375 9.08608 6.9869 9.08608 5.38953 10.0738Z",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round"},null,-1),yMe=b("path",{d:"M10.3337 4.99984C10.3337 6.2885 9.28899 7.33317 8.00033 7.33317C6.71166 7.33317 5.66699 6.2885 5.66699 4.99984C5.66699 3.71117 6.71166 2.6665 8.00033 2.6665C9.28899 2.6665 10.3337 3.71117 10.3337 4.99984Z",stroke:"currentColor"},null,-1),_Me=[mMe,gMe,vMe,yMe];function bMe(e,t,n,o,r,s){return C(),M("svg",hMe,_Me)}const wMe=qe(pMe,[["render",bMe]]),CMe={name:"ManageCourses",components:{CreateCourseForm:pL,AppLayout:si,Layout:ri,GroupIcon:wMe},data(){return{courses:[],loading:!0,pagination:{current_page:1,per_page:50,total:0},type:"all",newCourseModal:!1,is_admin:!1}},methods:{fetchCourses(){this.loading=!0,this.$get("admin/courses",{page:this.pagination.current_page,per_page:this.pagination.per_page,type:this.type}).then(e=>{this.courses=e.courses.data,this.is_admin=e.is_admin,this.pagination.total=e.courses.total}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},getExcerpt(e,t=200){if(!e)return"";let n=e.replace(/(<([^>]+)>)/ig,"");return n.length>t&&(n=n.substring(0,t)+"..."),n},navigateToEditLessons(e){this.$router.push({name:"edit_lessons",params:{course_id:e}})}},mounted(){this.fetchCourses()}},kMe={class:"fcom_courses"},SMe={class:"fcom_box_card_list"},$Me=["onClick"],EMe=["src"],xMe={key:1,class:"fcom_no_image"},MMe={class:"fcom_box_card_info"},TMe={class:"fcom_box_card_name"},OMe={class:"fcom_box_card_by"},IMe={class:"fcom_box_card_details"},AMe={class:"inline_details"},NMe=b("span",{class:"fcom_inline_separator"},null,-1),PMe={class:"inline_details"},LMe={key:0,class:"fcom_box_card_description"},RMe={class:"fcom_box_card_action"},DMe=["onClick"];function FMe(e,t,n,o,r,s){const i=pt,l=mh,a=re("router-link"),u=re("GroupIcon"),c=Ne,d=re("layout"),f=re("app-layout"),p=re("create-course-form"),h=Ql,m=zt("loading");return C(),M(fe,null,[k(f,{wrapper_class:"fcom_single_layout fcom_max_layout"},{default:$(()=>[k(d,{wrapper_class:"no_bg_layout",title:e.$t("Manage Courses")},{actions:$(()=>[k(i,{class:"fcom_primary_button",onClick:t[0]||(t[0]=y=>r.newCourseModal=!0)},{default:$(()=>[ne(A(e.$t("Add Course")),1)]),_:1})]),default:$(()=>[He((C(),M("div",kMe,[b("div",SMe,[(C(!0),M(fe,null,nt(r.courses,y=>(C(),M("div",{key:y.id,class:"fcom_each_box_card"},[b("div",{class:"fcom_box_card_avatar",onClick:v=>s.navigateToEditLessons(y.id)},[y.cover_photo?(C(),M("img",{key:0,src:y.cover_photo,alt:""},null,8,EMe)):(C(),M("div",xMe))],8,$Me),b("div",MMe,[b("div",TMe,[k(a,{class:"course_route",to:{name:"edit_lessons",params:{course_id:y.id}}},{default:$(()=>[ne(A(s.getExcerpt(y.title,20))+" ",1),y.status=="draft"?(C(),q(l,{key:0,type:"info"},{default:$(()=>[ne(A(y.status),1)]),_:2},1024)):W("",!0)]),_:2},1032,["to"]),b("span",OMe,A(e.$t("by %s",y==null?void 0:y.owner.display_name)),1)]),b("div",IMe,[b("div",AMe,[b("span",null,A(e.$_n("%d Section","%d Sections",y.sectionsCount)),1),NMe,b("span",null,A(e.$_n("%d Lesson","%d Lessons",y.lessonsCount)),1)]),b("div",PMe,[k(c,null,{default:$(()=>[k(u)]),_:1}),ne(" "+A(e.$_n("%d student","%d students",y.students_count||0)),1)])]),y.description?(C(),M("div",LMe,A(s.getExcerpt(y.description,40)),1)):W("",!0),b("div",RMe,[b("button",{class:"fcom_card_button",onClick:v=>s.navigateToEditLessons(y.id)},A(e.$t("Manage")),9,DMe)])])]))),128))])])),[[m,r.loading]])]),_:1},8,["title"])]),_:1}),k(h,{"close-on-click-modal":!1,"append-to-body":!0,size:e.drawerWidth,modelValue:r.newCourseModal,"onUpdate:modelValue":t[2]||(t[2]=y=>r.newCourseModal=y),direction:"rtl"},{header:$(()=>[b("h4",null,A(e.$t("Create a new course")),1)]),default:$(()=>[r.newCourseModal?(C(),q(p,{key:0,onCompleted:t[1]||(t[1]=y=>{r.newCourseModal=!1})})):W("",!0)]),_:1},8,["size","modelValue"])],64)}const VMe=qe(CMe,[["render",FMe]]),BMe={name:"BgImageUpload",emits:["update:modelValue"],props:{modelValue:{type:String,required:!1},button_text:{type:String,default:"Upload Image"},can_remove:{type:Boolean,default:!1},is_multiple:{type:Boolean,default:!1},additional_data:{type:Object,default:()=>({})}},data(){return{imageUrl:this.modelValue}},computed:{action_url(){return this.appVars.rest.url+"/feeds/media-upload"},headers(){return{"X-WP-Nonce":this.appVars.rest.nonce}}},methods:{handleSuccess(e){this.imageUrl=e.media.url,this.$emit("update:modelValue",this.imageUrl)},handleError(e){this.$handleError(JSON.parse(e.message))},removeImage(){this.imageUrl="",this.$emit("update:modelValue","")}}};function zMe(e,t,n,o,r,s){const i=Ed,l=pt,a=DO,u=re("CloseBold"),c=Ne;return C(),M(fe,null,[k(a,{action:s.action_url,headers:s.headers,accept:"image/*",class:"fcom_bg_upload",multiple:n.is_multiple,data:n.additional_data,"show-file-list":!1,"on-success":s.handleSuccess,"on-error":s.handleError},{default:$(()=>[he(e.$slots,"trigger",{},()=>[he(e.$slots,"default",{},()=>[r.imageUrl?(C(),q(i,{key:0,alt:e.$t("Image Preview"),src:r.imageUrl},null,8,["alt","src"])):(C(),q(l,{key:1,class:"fcom_btn_upload",text:""},{default:$(()=>[ne(A(n.button_text),1)]),_:1}))])])]),_:3},8,["action","headers","multiple","data","on-success","on-error"]),r.imageUrl&&n.can_remove?(C(),q(l,{key:0,class:"fcom_bg_remove",text:"",size:"small",onClick:s.removeImage},{default:$(()=>[k(c,null,{default:$(()=>[k(u)]),_:1})]),_:1},8,["onClick"])):W("",!0)],64)}const jMe=qe(BMe,[["render",zMe]]),HMe={name:"LockscreenMeta",components:{BgImageUpload:jMe},props:["lockscreen"],emits:["editField"],data(){return{editing:!1,editTab:"content",editingField:null}},computed:{lockscreenFields(){return this.lockscreen},getFieldIcon(){return e=>{const t={image:"Picture",block:"Tickets",lesson:"Memo"};return e.name=="action"?"Iphone":t[e.type]}}},methods:{toggleHidden(e){e.hidden=!e.hidden},updateField(e){this.editing=!0,this.editingField=e;const t=e.type=="block"?e:null;this.$emit("editField",t)},backToFields(){this.editing=!1,this.editingField=null,this.$emit("editField",null)},moveUp(e){if(e==0)return;const t=this.lockscreen[e],n=this.lockscreen[e-1];this.lockscreen.splice(e-1,2,t,n)},moveDown(e){if(e==this.lockscreen.length-1)return;const t=this.lockscreen[e],n=this.lockscreen[e+1];this.lockscreen.splice(e,2,n,t)},handlePhotoUpload(e){this.editingField.background_image=e}}},UMe={key:0,class:"fcom_lockscreen_meta"},WMe={class:"fcom_meta_section lockscreen_meta"},KMe={class:"fcom_description"},qMe={class:"fcom_meta_section lockscreen_meta"},GMe={class:"fcom_meta_label"},YMe={class:"fcom_meta_content"},ZMe={class:"fcom_meta_block"},JMe={class:"fcom_block_label"},XMe={class:"fcom_meta_sorting"},QMe={class:"fcom_block_action"},eTe={key:1,class:"fcom_lockscreen_meta"},tTe={class:"fcom_edit_title"},nTe={class:"fcom_edit_content"},oTe={class:"fcom_color_input_wrap"},rTe={class:"fcom_color_input_wrap"},sTe={class:"fcom_color_input_wrap"},iTe={class:"fcom_color_input_wrap"},lTe={class:"fcom_color_input_wrap"},aTe={key:1,class:"fcom_description"};function uTe(e,t,n,o,r,s){const i=Ne,l=re("Top"),a=re("Bottom"),u=re("EditPen"),c=re("Hide"),d=re("View"),f=re("Back"),p=At,h=io,m=so,y=IO,v=re("BgImageUpload"),w=R3,_=OO;return r.editing?(C(),M("div",eTe,[b("div",tTe,[k(i,{onClick:s.backToFields},{default:$(()=>[k(f)]),_:1},8,["onClick"]),b("p",null,A(r.editingField.label),1)]),b("div",nTe,[r.editingField.type=="image"?(C(),q(_,{key:0,modelValue:r.editTab,"onUpdate:modelValue":t[17]||(t[17]=S=>r.editTab=S),class:"demo-tabs"},{default:$(()=>[k(y,{label:e.$t("Content"),name:"content"},{default:$(()=>[k(m,{onSubmit:t[4]||(t[4]=et(S=>e.doNothing(),["prevent"])),model:r.editingField,"label-position":"top",class:"form-container"},{default:$(()=>[k(h,{label:e.$t("Heading")},{default:$(()=>[k(p,{modelValue:r.editingField.heading,"onUpdate:modelValue":t[0]||(t[0]=S=>r.editingField.heading=S),class:"ttt",placeholder:e.$t("Heading")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),k(h,{label:e.$t("Description")},{default:$(()=>[k(p,{modelValue:r.editingField.description,"onUpdate:modelValue":t[1]||(t[1]=S=>r.editingField.description=S),type:"textarea",placeholder:e.$t("Description")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),k(h,{label:e.$t("Button Label")},{default:$(()=>[k(p,{modelValue:r.editingField.button_text,"onUpdate:modelValue":t[2]||(t[2]=S=>r.editingField.button_text=S),placeholder:e.$t("Button Label")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),k(h,{label:e.$t("Button Link")},{default:$(()=>[k(p,{modelValue:r.editingField.button_link,"onUpdate:modelValue":t[3]||(t[3]=S=>r.editingField.button_link=S)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["label"]),k(y,{label:e.$t("Design"),name:"design"},{default:$(()=>[k(m,{onSubmit:t[16]||(t[16]=et(S=>e.doNothing(),["prevent"])),model:r.editingField,"label-position":"top",class:"form-container"},{default:$(()=>[k(h,{label:e.$t("Background Image"),class:"fcom_bg_image"},{default:$(()=>[k(v,{modelValue:r.editingField.background_image,"onUpdate:modelValue":t[5]||(t[5]=S=>r.editingField.background_image=S),can_remove:!0},null,8,["modelValue"])]),_:1},8,["label"]),k(h,{label:e.$t("Overlay Color")},{default:$(()=>[b("div",oTe,[k(w,{modelValue:r.editingField.overlay_color,"onUpdate:modelValue":t[6]||(t[6]=S=>r.editingField.overlay_color=S)},null,8,["modelValue"]),k(p,{modelValue:r.editingField.overlay_color,"onUpdate:modelValue":t[7]||(t[7]=S=>r.editingField.overlay_color=S)},null,8,["modelValue"])])]),_:1},8,["label"]),k(h,{label:e.$t("Heading Color")},{default:$(()=>[b("div",rTe,[k(w,{modelValue:r.editingField.heading_color,"onUpdate:modelValue":t[8]||(t[8]=S=>r.editingField.heading_color=S)},null,8,["modelValue"]),k(p,{modelValue:r.editingField.heading_color,"onUpdate:modelValue":t[9]||(t[9]=S=>r.editingField.heading_color=S)},null,8,["modelValue"])])]),_:1},8,["label"]),k(h,{label:e.$t("Text Color")},{default:$(()=>[b("div",sTe,[k(w,{modelValue:r.editingField.text_color,"onUpdate:modelValue":t[10]||(t[10]=S=>r.editingField.text_color=S)},null,8,["modelValue"]),k(p,{modelValue:r.editingField.text_color,"onUpdate:modelValue":t[11]||(t[11]=S=>r.editingField.text_color=S)},null,8,["modelValue"])])]),_:1},8,["label"]),k(h,{label:e.$t("Button Label")},{default:$(()=>[b("div",iTe,[k(w,{modelValue:r.editingField.button_text_color,"onUpdate:modelValue":t[12]||(t[12]=S=>r.editingField.button_text_color=S)},null,8,["modelValue"]),k(p,{modelValue:r.editingField.button_text_color,"onUpdate:modelValue":t[13]||(t[13]=S=>r.editingField.button_text_color=S)},null,8,["modelValue"])])]),_:1},8,["label"]),k(h,{label:e.$t("Button Background")},{default:$(()=>[b("div",lTe,[k(w,{modelValue:r.editingField.button_color,"onUpdate:modelValue":t[14]||(t[14]=S=>r.editingField.button_color=S),"show-alpha":""},null,8,["modelValue"]),k(p,{modelValue:r.editingField.button_color,"onUpdate:modelValue":t[15]||(t[15]=S=>r.editingField.button_color=S)},null,8,["modelValue"])])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["label"])]),_:1},8,["modelValue"])):r.editingField.type=="block"?(C(),M("div",aTe,A(e.$t("Edit the field from block editor ")),1)):W("",!0)])])):(C(),M("div",UMe,[b("div",WMe,[b("div",KMe,[b("p",null,A(e.$t("This page is only visible to non-members viewing a private space.")),1)])]),b("div",qMe,[b("div",GMe,A(e.$t("Page Blocks")),1),b("div",YMe,[b("ul",ZMe,[(C(!0),M(fe,null,nt(s.lockscreenFields,(S,x)=>(C(),M("li",{class:D(["fcom_block_list",{block_hidden:S.hidden}])},[b("div",JMe,[k(i,{class:"fcom_el_icon"},{default:$(()=>[(C(),q(Lt(s.getFieldIcon(S))))]),_:2},1024),b("p",null,A(S.label),1)]),b("div",XMe,[k(i,{onClick:E=>s.moveUp(x)},{default:$(()=>[k(l)]),_:2},1032,["onClick"]),k(i,{onClick:E=>s.moveDown(x)},{default:$(()=>[k(a)]),_:2},1032,["onClick"])]),b("div",QMe,[k(i,{onClick:E=>s.updateField(S)},{default:$(()=>[k(u)]),_:2},1032,["onClick"]),S.hidden?(C(),q(i,{key:0,onClick:E=>s.toggleHidden(S)},{default:$(()=>[k(c)]),_:2},1032,["onClick"])):(C(),q(i,{key:1,onClick:E=>s.toggleHidden(S)},{default:$(()=>[k(d)]),_:2},1032,["onClick"]))])],2))),256))])])])]))}const cTe=qe(HMe,[["render",uTe]]),dTe={name:"BlockEditor",emits:["update:modelValue"],props:{modelValue:{type:String,required:!1}},data(){return{loading:!0,has_error:!1,all_loaded:!1,html:this.modelValue}},methods:{attach(){const e=this.$refs.block_editor;this.loading=!1,this.all_loaded=!0,window.wp.attachEditor(e,{iso:{toolbar:{undo:!0,navigation:!0,documentInspector:null},blocks:{allowBlocks:["core/button","core/buttons","core/code","core/column","core/columns","core/embed","core/group","core/heading","core/image","core/list","core/list-item","core/missing","core/paragraph","core/preformatted","core/pullquote","core/quote","core/separator","core/spacer","core/table","core/verse"]},__experimentalOnChange:function(t){console.log(t)},sidebar:{inserter:!1,inspector:!0}},editor:{__experimentalOnChange:function(t){console.log(t)},__experimentalOnInput(t){console.log(t)},__experimentalOnSelection(t){console.log(t)},onSaveContent:function(t){console.log(t)}}}),e.addEventListener("change",t=>{this.html=t.target.value,this.$emit("update:modelValue",t.target.value)})},loadScript(e){return new Promise((t,n)=>{const o=document.createElement("script");o.src=e,o.onload=t,o.onerror=n,document.head.append(o)})},async loadScripts(){const e=this.appVars.block_editor_assets.scripts;for(const t in e)try{await this.loadScript(e[t]),console.log(`${t} JS loaded`)}catch(n){this.has_error=!0,console.error(`Failed to load js ${t}:`,n)}this.attach()},loadCSSFile(e){return new Promise((t,n)=>{const o=document.createElement("link");o.rel="stylesheet",o.href=e,o.onload=t,o.onerror=n,document.head.append(o)})},async loadCSSFiles(){const t=this.appVars.block_editor_assets.styles.map(this.loadCSSFile);try{await Promise.all(t),console.log("All CSS files loaded")}catch(n){console.error("Failed to load some CSS files:",n)}}},mounted(){window.fl_block_editor_loaded?this.attach():(this.loadCSSFiles(),this.loadScripts(),window.fl_block_editor_loaded=!0)},beforeUnmount(){window.wp.detachEditor(this.$refs.block_editor)}},fTe={class:"fcom_block_editor"};function pTe(e,t,n,o,r,s){const i=lo;return C(),M("div",fTe,[He(b("div",null,[b("textarea",{ref:"block_editor",id:"fcom_block_editor",name:"block_editor"},A(r.html),513)],512),[[en,r.all_loaded]]),r.all_loaded?W("",!0):(C(),q(i,{key:0,class:"white_loaded",rows:7,animated:!0}))])}const hL=qe(dTe,[["render",pTe]]),hTe={name:"MediaPreview",components:{Postcard:HZ},props:["feed","media_item"],computed:{media(){return this.feed?this.feed.meta.media_preview:this.media_item}},methods:{getDomainName(e){return e?e.split("/")[2].replace("www.",""):""},getAspectRatio(e,t){if(e&&t){let n=e/t;return n<1?16/9:n}return 1}}},mTe={key:0},gTe=["innerHTML"],vTe=["href"],yTe={key:0,class:"feed_media_image"},_Te=["src"],bTe={key:1,class:"feed_media_content"},wTe={class:"media_domain"},CTe={class:"feed_media_title"};function kTe(e,t,n,o,r,s){const i=lo,l=Ed;return C(),M("div",{class:D(["feed_media","feed_media_"+s.media.type])},[s.media.type=="oembed"||s.media.type=="iframe_html"?(C(),M(fe,{key:0},[s.media.content_type=="video"?(C(),M("div",mTe,[b("div",{class:"feed_media_ext_video",innerHTML:s.media.html},null,8,gTe)])):W("",!0)],64)):s.media.type=="image"||s.media.is_uploaded?(C(),M("div",{key:1,class:D(["feed_media_provider_"+s.media.provider,"feed_media_image feed_custom_uploaded"])},[k(l,{alt:"",style:Qe({width:"100%",aspectRatio:s.getAspectRatio(s.media.width,s.media.height)}),src:s.media.image,lazy:!0,previewSrcList:[s.media.image],loading:"lazy","zoom-rate":1.2,"max-scale":7,"preview-teleported":!0,"min-scale":.2,"initial-index":1,class:D("fcom_media_provider_"+s.media.provider),fit:"scale-down"},{placeholder:$(()=>[k(i,{animated:!0})]),_:1},8,["style","src","previewSrcList","class"])],2)):(C(),M("a",{key:2,href:s.media.url,target:"_blank",rel:"noopener",class:"feed_media_link"},[s.media.image?(C(),M("div",yTe,[b("img",{alt:"",src:s.media.image},null,8,_Te)])):W("",!0),s.media.title?(C(),M("div",bTe,[b("div",wTe,A(s.getDomainName(s.media.url)),1),b("div",CTe,A(s.media.title),1),W("",!0)])):W("",!0)],8,vTe))],2)}const Mv=qe(hTe,[["render",kTe]]),STe={name:"MediaEmbeder",emits:["embeded"],props:{media:{type:Object,default:()=>({type:"oembed",url:"",inner_html:"",content_type:"video"})},box_title:{type:String,default:""},box_description:{type:String,default:""},has_iframe:{type:Boolean,default:!0}},components:{MediaPreview:Mv},computed:{showPreview(){return this.media.html&&!this.showInput}},data(){return{appReady:!1,showInput:!1,fetching:!1}},methods:{fetchData(){this.media.url&&(this.fetching=!0,this.$get("feeds/oembed",{url:this.media.url}).then(e=>{this.media.html=e.oembed.html,this.media.provider=e.oembed.provider,this.media.title=e.oembed.title,this.media.author_name=e.oembed.author_name,this.media.type=e.oembed.type,this.media.content_type="video",this.$emit("embeded",this.media),this.showInput=!1}).catch(e=>{this.$handleError(e)}).finally(()=>{this.fetching=!1}))}},mounted(){typeof this.media!="object"&&(this.media={type:"oembed",url:"",inner_html:""}),this.appReady=!0,this.media.html||this.fetchData()}},$Te={key:0},ETe={key:0,class:"fcom_media_editor_actions"},xTe={key:1,class:"fcom_media_editor fcom_media_embeder"},MTe={key:2,class:"fcom_course_media"};function TTe(e,t,n,o,r,s){const i=pt,l=L3,a=Eu,u=At,c=re("media-preview"),d=zt("loading");return r.appReady?He((C(),M("div",$Te,[n.has_iframe?(C(),M("div",ETe,[s.showPreview?(C(),q(i,{key:0,onClick:t[0]||(t[0]=f=>r.showInput=!0),type:"danger",size:"small",text:""},{default:$(()=>[ne(A(e.$t("Edit media")),1)]),_:1})):(C(),q(a,{key:1,onChange:t[1]||(t[1]=f=>{n.media.html="",n.media.url=""}),size:"small",modelValue:n.media.type,"onUpdate:modelValue":t[2]||(t[2]=f=>n.media.type=f)},{default:$(()=>[k(l,{label:e.$t("Oembed"),value:"oembed"},null,8,["label"]),k(l,{label:e.$t("Custom HTML Code"),value:"iframe_html"},null,8,["label"])]),_:1},8,["modelValue"]))])):W("",!0),s.showPreview?(C(),M("div",MTe,[k(c,{media_item:n.media},null,8,["media_item"])])):(C(),M("div",xTe,[n.media.type=="iframe_html"&&n.has_iframe?(C(),M(fe,{key:0},[b("h3",null,A(e.$t("Add Video from custom HTML Code")),1),k(u,{rows:5,modelValue:n.media.html,"onUpdate:modelValue":t[3]||(t[3]=f=>n.media.html=f),type:"textarea",placeholder:e.$t("Paste an iframe code")},null,8,["modelValue","placeholder"]),k(i,{style:{"margin-top":"20px"},onClick:t[4]||(t[4]=f=>r.showInput=!1),class:"fcom_secondary_button"},{default:$(()=>[ne(A(e.$t("Embed")),1)]),_:1})],64)):(C(),M(fe,{key:1},[b("h3",null,A(n.box_title||e.$t("Featured media")),1),b("p",null,A(n.box_description||e.$t("Embed from Vimeo, YouTube, Wistia and more")),1),k(u,{size:"large",modelValue:n.media.url,"onUpdate:modelValue":t[5]||(t[5]=f=>n.media.url=f),type:"url",placeholder:e.$t("Paste a URL to embed")},{append:$(()=>[k(i,{onClick:s.fetchData,class:"fcom_primary_button"},{default:$(()=>[ne(A(e.$t("Embed")),1)]),_:1},8,["onClick"])]),_:1},8,["modelValue","placeholder"])],64))]))])),[[d,r.fetching]]):W("",!0)}const Lk=qe(STe,[["render",TTe]]),OTe={name:"_LessonEditor",props:["sections"],computed:{lessonsCount(){return this.sections.reduce((e,t)=>e+t.lessons.length,0)},sectionsCount(){return this.sections.reduce((e,t)=>e+(t.lessons.length?1:0),0)}}},ITe={class:"fcom_course_sections"},ATe={class:"fcom_course_intro"},NTe={class:"fcom_course_labels"},PTe={class:"fcom_course_info"},LTe=b("span",null," • ",-1),RTe={class:"fcom_card_sections"},DTe={class:"fcom_section_items"},FTe={key:0,class:"fcom_section_primary_item"},VTe={class:"fcom_section_primary_item_title"},BTe={class:"fcom_section_primary_item_actions"},zTe={class:"fcom_meta_text"},jTe={class:"fcom_section_item_title"},HTe={class:"fcom_heading_item clickable"};function UTe(e,t,n,o,r,s){const i=re("ArrowRight"),l=re("ArrowDown"),a=Ne,u=re("Lock");return C(),M("div",ITe,[b("div",ATe,[b("div",NTe,[b("h3",null,A(e.$t("Course content")),1),b("p",PTe,[ne(A(e.$t("%s topics",s.sectionsCount))+" ",1),LTe,ne(" "+A(e.$t("%s lessons",s.lessonsCount)),1)])])]),b("div",RTe,[b("div",DTe,[(C(!0),M(fe,null,nt(n.sections,c=>(C(),M("div",{key:c.id,class:"fcom_section_primary"},[c.lessons.length?(C(),M("div",FTe,[b("div",VTe,[k(a,{class:"clickable",onClick:d=>c.is_closed=!c.is_closed},{default:$(()=>[c.is_closed?(C(),q(i,{key:0})):(C(),q(l,{key:1}))]),_:2},1032,["onClick"]),b("h4",null,A(c.title),1)]),b("div",BTe,[b("span",zTe,A(e.$t("%d lessons",c.lessons.length)),1)])])):W("",!0),c.is_closed?W("",!0):(C(!0),M(fe,{key:1},nt(c.lessons,d=>(C(),M("div",{key:d.id,class:"fcom_section_item"},[b("div",jTe,[b("p",HTe,[k(a,null,{default:$(()=>[k(u)]),_:1}),ne(" "+A(d.title),1)])])]))),128))]))),128))])])])}const WTe=qe(OTe,[["render",UTe]]),KTe={name:"LockScreenEditor",props:["title","lockscreen","sections","saving","loading"],emits:["save","close"],components:{LessonEditor:WTe,MediaEmbeder:Lk,BlockEditor:hL,LockscreenMeta:cTe},data(){return{editingField:null}},computed:{lockscreenFields(){return this.lockscreen.filter(e=>!e.hidden)},imageStyles(){return e=>({backgroundImage:`url(${e.background_image})`,backgroundColor:e.overlay_color})},headingStyles(){return e=>({color:e.heading_color})},descriptionStyles(){return e=>({color:e.text_color})},buttonStyles(){return e=>({backgroundColor:e.button_color,color:e.button_text_color})}},methods:{updateHeading(e,t){t.heading=e.target.innerText},updateDescription(e,t){t.description=e.target.innerText},updateButtonLabel(e,t){t.button_text=e.target.innerText},visibleBlock(e){this.editingField=e},updateEditField(e){this.editingField=e,(e==null?void 0:e.type)==="block"&&setTimeout(()=>{const t=document.getElementById("fcomBlockContent");t&&t.scrollIntoView({behavior:"smooth"})},300)},saveChanges(){this.editingField=null,this.$emit("save")}}},qTe={class:"fcom_editor_topbar"},GTe={class:"fcom_editor_content"},YTe={class:"fcom_item"},ZTe={class:"fcom_content"},JTe=["onInput"],XTe=["onInput"],QTe=["onInput"],eOe={key:1,class:"fcom_content_wrap"},tOe={key:0,id:"fcomBlockContent"},nOe=["onClick","innerHTML"],oOe={key:2,class:"fcom_content_wrap"};function rOe(e,t,n,o,r,s){const i=re("lockscreen-meta"),l=jT,a=re("Lock"),u=Ne,c=re("block-editor"),d=re("lesson-editor"),f=lo,p=ks,h=W0;return C(),M(fe,null,[k(l,{class:"fcol_full_editor_side lockscreen_editor",width:"250px"},{default:$(()=>[he(e.$slots,"before_meta"),k(i,{lockscreen:n.lockscreen,onEditField:s.updateEditField},null,8,["lockscreen","onEditField"])]),_:3}),k(h,{class:"fcom_full_editor_main lockscreen_editor"},{default:$(()=>[k(p,null,{default:$(()=>[b("div",qTe,[k(u,null,{default:$(()=>[k(a)]),_:1}),b("h3",null,A(n.title),1)]),b("div",GTe,[(C(!0),M(fe,null,nt(s.lockscreenFields,m=>{var y;return C(),M("div",YTe,[m.type=="image"?(C(),M("div",{key:0,class:"fcom_image_wrap",style:Qe(s.imageStyles(m))},[b("div",ZTe,[b("h2",{style:Qe(s.headingStyles(m)),contenteditable:"true",onInput:v=>s.updateHeading(v,m)},A(m.heading),45,JTe),b("p",{style:Qe(s.descriptionStyles(m)),contenteditable:"true",onInput:v=>s.updateDescription(v,m)},A(m.description),45,XTe),b("button",{class:"fcom_btn",style:Qe(s.buttonStyles(m)),contenteditable:"true",onInput:v=>s.updateButtonLabel(v,m)},A(m.button_text),45,QTe)])],4)):W("",!0),m.type=="block"?(C(),M("div",eOe,[((y=r.editingField)==null?void 0:y.type)=="block"?(C(),M("div",tOe,[k(c,{modelValue:m.content,"onUpdate:modelValue":v=>m.content=v},null,8,["modelValue","onUpdate:modelValue"])])):(C(),M("div",{key:1,onClick:v=>s.visibleBlock(m),innerHTML:m.content},null,8,nOe))])):W("",!0),m.type=="lesson"?(C(),M("div",oOe,[n.loading?(C(),q(f,{key:1,rows:5,animated:!0})):(C(),q(d,{key:0,sections:n.sections},null,8,["sections"]))])):W("",!0)])}),256))])]),_:1})]),_:1})],64)}const sOe=qe(KTe,[["render",rOe]]),iOe={name:"CourseLockscreen",props:["spaceProfile","savingCount"],emits:["close"],components:{LockScreenEditor:sOe},data(){return{saving:!1,loading:!1,sections:[],lockscreen:null}},watch:{savingCount(){this.saveChanges(!0)}},methods:{getSections(){this.loading=!0,this.$get("admin/courses/"+this.spaceProfile.id+"/sections",{conditions:["only_published"],with_lock_screen:!0}).then(e=>{this.sections=e.sections,this.lockscreen=e.lockscreen}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},saveChanges(e=!1){this.lockscreen&&(this.saving=!0,this.$put("admin/courses/"+this.spaceProfile.id+"/lockscreens",{lockscreen:this.lockscreen}).then(t=>{this.$notify.success(t.message),e&&this.$emit("close")}).catch(t=>{this.$handleError(t)}).finally(()=>{this.saving=!1}))}},mounted(){this.getSections()}},lOe={key:0,class:"fcom_lockscreen_meta"},aOe={class:"fcom_description"};function uOe(e,t,n,o,r,s){const i=re("lock-screen-editor");return r.lockscreen?(C(),q(i,{key:0,title:n.spaceProfile.title,lockscreen:r.lockscreen,sections:r.sections,saving:r.saving,loading:r.loading,onSave:s.saveChanges,onClose:t[0]||(t[0]=l=>e.$emit("close"))},{before_meta:$(()=>[n.spaceProfile.settings.custom_lock_screen!="yes"?(C(),M("div",lOe,[b("div",aOe,[b("p",null,A(e.$t("__LOCK_SCRREN_DESC")),1)])])):W("",!0)]),_:1},8,["title","lockscreen","sections","saving","loading","onSave"])):W("",!0)}const cOe=qe(iOe,[["render",uOe]]),dOe={name:"ManageSpaceLinks",components:{MenuGroupSettings:dL},props:["spaceProfile","savingCount"],emits:["close"],data(){return{saving:!1}},watch:{savingCount(){this.saveMenuItems(!0)}},methods:{saveMenuItems(e=!1){this.saving=!0;let t="spaces/"+this.spaceProfile.slug+"/links";this.spaceProfile.type=="course"&&(t="admin/courses/"+this.spaceProfile.id+"/links"),this.$post(t,{links:this.spaceProfile.settings.links}).then(n=>{this.$notify.success(n.message),this.spaceProfile.settings.links=n.links,e&&this.$emit("close")}).catch(n=>{this.$handleError(n)}).finally(()=>{this.saving=!1})}}},fOe={style:{"max-width":"800px",padding:"20px",margin:"0 auto"}},pOe={class:"fcom_card_sections"};function hOe(e,t,n,o,r,s){const i=re("menu-group-settings"),l=ks,a=W0;return C(),q(a,{class:"fcom_full_editor_main lockscreen_editor"},{default:$(()=>[k(l,null,{default:$(()=>[b("div",fOe,[b("div",pOe,[k(i,{custom_svg:!0,use_icon_selector:!0,has_svg:!1,onSave:t[0]||(t[0]=u=>s.saveMenuItems()),title:e.$t("Manage Links"),menuItems:n.spaceProfile.settings.links},null,8,["title","menuItems"])])])]),_:1})]),_:1})}const mOe=qe(dOe,[["render",hOe]]),gOe={name:"SpaceCustomizer",props:["course"],emits:["close","completed"],components:{ManageSpaceLinks:mOe,CourseLockscreen:cOe,CreateCourseForm:pL},data(){return{saving:!1,currentTab:"general",savingCount:0}},methods:{saveChanges(){this.savingCount=this.savingCount+1}}},vOe={key:0,class:"fcom_full_editor"},yOe={class:"fcom_full_editor_header"},_Oe={class:"fcom_editor_menu object_menu"},bOe={class:"fcom_space_menu_ul"},wOe={class:"full_editor_actions"},COe={style:{"max-width":"600px",padding:"20px",margin:"0 auto"}};function kOe(e,t,n,o,r,s){const i=re("ArrowLeft"),l=Ne,a=pt,u=HT,c=re("create-course-form"),d=ks,f=W0,p=re("course-lockscreen"),h=re("manage-space-links"),m=zT,y=zt("loading");return n.course.id?(C(),M("div",vOe,[k(m,null,{default:$(()=>[k(u,{class:"fcom_full_editor_header_wrap"},{default:$(()=>[b("div",yOe,[b("div",{onClick:t[0]||(t[0]=v=>e.$emit("completed")),class:"fcom_back_header"},[k(l,null,{default:$(()=>[k(i)]),_:1}),ne(" "+A(n.course.title),1)]),b("div",_Oe,[b("ul",bOe,[b("li",{onClick:t[1]||(t[1]=v=>r.currentTab="general")},[b("a",{class:D({"router-link-exact-active":r.currentTab==="general"}),href:"#"},A(e.$t("General Settings")),3)]),n.course.privacy=="private"?(C(),M("li",{key:0,onClick:t[2]||(t[2]=v=>r.currentTab="lock_screen")},[b("a",{class:D({"router-link-exact-active":r.currentTab==="lock_screen"}),href:"#"},A(e.$t("Lock Screen")),3)])):W("",!0),b("li",{onClick:t[3]||(t[3]=v=>r.currentTab="manage_links")},[b("a",{class:D({"router-link-exact-active":r.currentTab==="manage_links"}),href:"#"},A(e.$t("Course Links")),3)])])]),b("div",wOe,[He((C(),q(a,{class:"fcom_primary_button",disabled:r.saving,onClick:s.saveChanges,bg:""},{default:$(()=>[ne(A(e.$t("Save Changes & Close")),1)]),_:1},8,["disabled","onClick"])),[[y,r.saving]])])])]),_:1}),k(m,{class:"fcom_full_editor_container"},{default:$(()=>[r.currentTab=="general"?(C(),q(f,{key:0,class:"fcom_full_editor_main lockscreen_editor"},{default:$(()=>[k(d,null,{default:$(()=>[b("div",COe,[k(c,{onClose:t[4]||(t[4]=v=>e.$emit("close")),savingCount:r.savingCount,course:n.course},null,8,["savingCount","course"])])]),_:1})]),_:1})):r.currentTab=="lock_screen"?(C(),q(p,{key:1,savingCount:r.savingCount,spaceProfile:n.course,onClose:t[5]||(t[5]=v=>e.$emit("close"))},null,8,["savingCount","spaceProfile"])):r.currentTab=="manage_links"?(C(),q(h,{key:2,savingCount:r.savingCount,onClose:t[6]||(t[6]=v=>e.$emit("close")),spaceProfile:n.course},null,8,["savingCount","spaceProfile"])):W("",!0)]),_:1})]),_:1})])):W("",!0)}const SOe=qe(gOe,[["render",kOe]]),$Oe={name:"EditCourseRoute",components:{CourseCustomizer:SOe,AppLayout:si,Layout:ri},props:["course_id"],data(){return{course:{},loading:!0,menuItems:[{name:"course_overview",route:"course_overview",title:this.$t("Overview")},{name:"lessons",route:"edit_lessons",title:this.$t("Lessons")},{name:"students",route:"course_students",title:this.$t("Students")}],customizeCourse:!1}},methods:{fetchCourse(){this.loading=!0,this.$get("admin/courses/"+this.course_id).then(e=>{this.course=e.course}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},initDeleteCourse(){this.$refs.course_actions.hide(),this.$confirm(this.$t("Are you sure you want to delete this course?"),this.$t("Warning"),{confirmButtonText:this.$t("Yes, Delete the course"),cancelButtonText:this.$t("No"),type:"warning"}).then(()=>{this.$promt(this.$t("Please Type %s to confirm. Please note, all the lessons, topics, students progress will be deleted.",'"DELETE"'),this.$t("Delete Course"),{confirmButtonText:this.$t("Confirm Delete"),cancelButtonText:this.$t("Cancel")}).then(e=>{e.value==="DELETE"?this.deleteCourse():this.$notify.error(this.$t("The verification string does not match"))})})},deleteCourse(){this.loading=!0,this.$del("admin/courses/"+this.course.id).then(e=>{this.$notify.success(e.message),this.$router.push({name:"manage_courses"})}).catch(e=>{this.$handleError(e),this.loading=!1})},toViewCourse(){let e=this.$getRouteLink("course/:course_slug/lessons",{course_slug:this.course.slug});window.location.href=e}},mounted(){this.fetchCourse()}},EOe={class:"object_menu"},xOe={class:"fcom_space_menu_ul"},MOe={class:"actions_items"},TOe={key:0,class:"white_loaded"},OOe={key:2},IOe={key:0};function AOe(e,t,n,o,r,s){const i=ane,l=lne,a=re("router-link"),u=re("MoreFilled"),c=Ne,d=pt,f=Po,p=lo,h=re("router-view"),m=re("layout"),y=re("app-layout"),v=re("course-customizer");return C(),M(fe,null,[k(y,{wrapper_class:"fcom_single_layout fcom_max_layout"},{default:$(()=>[k(m,{wrapper_class:"no_bg_layout",title:e.$t("Courses")},{title:$(()=>[k(l,null,{default:$(()=>[k(i,{to:{name:"manage_courses"}},{default:$(()=>[ne(A(e.$t("Courses")),1)]),_:1}),r.course.id?(C(),q(i,{key:0},{default:$(()=>[ne(A(r.course.title)+" ",1),b("span",{class:"fcom_edit_course fcom_secondary_button clickable",onClick:t[0]||(t[0]=w=>{r.customizeCourse=!0})},A(e.$t("Edit")),1)]),_:1})):W("",!0)]),_:1})]),actions:$(()=>[b("div",EOe,[b("ul",xOe,[(C(!0),M(fe,null,nt(r.menuItems,w=>(C(),M("li",{key:w.name,class:D("course_inner_menu_"+w.name)},[k(a,{to:{name:w.route,params:{course_id:r.course.id}}},{default:$(()=>[ne(A(w.title),1)]),_:2},1032,["to"])],2))),128)),b("li",null,[k(f,{placement:"bottom",ref:"course_actions",persistent:!1,width:200,trigger:"click"},{reference:$(()=>[k(d,{"aria-label":e.$t("View actions"),class:"fcom_dot_menu",size:"small",text:""},{default:$(()=>[k(c,null,{default:$(()=>[k(u)]),_:1})]),_:1},8,["aria-label"])]),default:$(()=>[b("ul",MOe,[b("li",{onClick:t[1]||(t[1]=w=>s.toViewCourse())},A(e.$t("View Course")),1),b("li",{onClick:t[2]||(t[2]=()=>{e.$refs.course_actions.hide(),r.customizeCourse=!0})},A(e.$t("Edit Course")),1),b("li",{onClick:t[3]||(t[3]=(...w)=>s.initDeleteCourse&&s.initDeleteCourse(...w))},A(e.$t("Delete Course")),1)])]),_:1},512)])])])]),default:$(()=>[r.loading?(C(),M("div",TOe,[k(p,{loading:r.loading,animation:"pulse",row:"10"},null,8,["loading"])])):r.course.id?(C(),q(h,{key:1,course:r.course},null,8,["course"])):(C(),M("div",OOe,[b("h3",null,A(e.$t("Sorry, the course can not be loaded")),1)]))]),_:1},8,["title"])]),_:1}),r.customizeCourse&&r.course.id?(C(),M("div",IOe,[(C(),q(_s,{to:"body"},[k(v,{course:r.course,onClose:t[4]||(t[4]=w=>{r.customizeCourse=null,s.fetchCourse()}),onCompleted:t[5]||(t[5]=w=>{r.customizeCourse=null,s.fetchCourse()})},null,8,["course"])]))])):W("",!0)],64)}const NOe=qe($Oe,[["render",AOe]]),POe={name:"LengthInput",props:["modelValue"],data(){return{muinutes:0,seconds:0}},methods:{updateLength(){this.$emit("update:modelValue",parseInt(this.muinutes)*60+parseInt(this.seconds))}},mounted(){this.modelValue&&(this.muinutes=Math.floor(this.modelValue/60)||"",this.seconds=this.modelValue%60||"")}},LOe={class:"fcom_length_input"};function ROe(e,t,n,o,r,s){const i=At;return C(),M("div",LOe,[k(i,{type:"number",modelValue:r.muinutes,"onUpdate:modelValue":t[0]||(t[0]=l=>r.muinutes=l),onChange:s.updateLength,min:0,max:1444,size:"small"},{append:$(()=>[ne(A(e.$t("min")),1)]),_:1},8,["modelValue","onChange"]),k(i,{type:"number",modelValue:r.seconds,"onUpdate:modelValue":t[1]||(t[1]=l=>r.seconds=l),onChange:s.updateLength,min:0,max:59,size:"small"},{append:$(()=>[ne(A(e.$t("sec")),1)]),_:1},8,["modelValue","onChange"])])}const DOe=qe(POe,[["render",ROe]]),FOe={name:"CourseMeta",components:{LengthInput:DOe},props:["lesson"]},VOe={class:"fcom_course_meta"},BOe={class:"fcom_meta_section"},zOe={class:"fcom_meta_label"},jOe={class:"fcom_meta_content"},HOe={key:0,class:"fcom_meta_section"},UOe={class:"fcom_meta_label"},WOe={class:"fcom_meta_content"};function KOe(e,t,n,o,r,s){const i=Hn,l=re("length-input");return C(),M("div",VOe,[b("div",BOe,[b("div",zOe,A(e.$t("Features Settings")),1),b("div",jOe,[k(i,{modelValue:n.lesson.meta.enable_media,"onUpdate:modelValue":t[0]||(t[0]=a=>n.lesson.meta.enable_media=a),"true-value":"yes","false-value":"no"},{default:$(()=>[ne(A(e.$t("Enable Video Embed")),1)]),_:1},8,["modelValue"]),k(i,{modelValue:n.lesson.meta.enable_comments,"onUpdate:modelValue":t[1]||(t[1]=a=>n.lesson.meta.enable_comments=a),"true-value":"yes","false-value":"no"},{default:$(()=>[ne(A(e.$t("Enable Comments")),1)]),_:1},8,["modelValue"])])]),n.lesson.meta.enable_media=="yes"?(C(),M("div",HOe,[b("div",UOe,A(e.$t("Video length")),1),b("div",WOe,[k(l,{modelValue:n.lesson.meta.video_length,"onUpdate:modelValue":t[2]||(t[2]=a=>n.lesson.meta.video_length=a)},null,8,["modelValue"])])])):W("",!0)])}const qOe=qe(FOe,[["render",KOe]]),GOe={name:"LessonEditor",props:["lesson","section","course","editingIndex"],emits:["saved","close","changeLesson"],components:{BlockEditor:hL,MediaEmbeder:Lk,LessonMeta:qOe},data(){return{saving:!1}},methods:{saveData(){this.saving=!0,this.$put("admin/courses/"+this.lesson.space_id+"/lessons/"+this.lesson.id,{lesson:{id:this.lesson.id,parent_id:this.lesson.parent_id,space_id:this.lesson.space_id,title:this.lesson.title,message:this.lesson.message,meta:this.lesson.meta,status:this.lesson.status}}).then(e=>{this.$notify.success(e.message),this.$emit("saved",e.lesson)}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})}},mounted(){document.body.classList.add("fcom-no-scroll")},beforeUnmount(){document.body.classList.remove("fcom-no-scroll")}},YOe={class:"fcom_full_editor"},ZOe={class:"fcom_full_editor_header"},JOe={key:0},XOe={class:"full_editor_actions"},QOe={class:"fcom_editor_wrap"},eIe={style:{"margin-bottom":"10px"},class:"fcom_lesson_camp"},tIe={class:"fcom_lesson_nav"},nIe={class:"fcom_lesson_title"},oIe={class:"fcom_lesson_content"};function rIe(e,t,n,o,r,s){const i=re("ArrowLeft"),l=Ne,a=re("arrow-down"),u=pt,c=bh,d=wh,f=_h,p=HT,h=re("lesson-meta"),m=jT,y=re("ArrowRight"),v=At,w=re("media-embeder"),_=re("block-editor"),S=ks,x=W0,E=zT,T=zt("loading");return C(),M("div",YOe,[k(E,null,{default:$(()=>[k(p,{class:"fcom_full_editor_header_wrap"},{default:$(()=>[b("div",ZOe,[b("div",{onClick:t[0]||(t[0]=O=>e.$emit("close")),class:"fcom_back_header"},[k(l,null,{default:$(()=>[k(i)]),_:1}),ne(" "+A(e.$t("Back to Lessons"))+" ",1),n.course&&n.course.title?(C(),M("span",JOe,"("+A(n.course.title)+")",1)):W("",!0)]),b("div",XOe,[k(f,{onCommand:t[1]||(t[1]=O=>{n.lesson.status=O}),trigger:"click"},{dropdown:$(()=>[k(d,null,{default:$(()=>[k(c,{command:"draft"},{default:$(()=>[ne(A(e.$t("Draft")),1)]),_:1}),k(c,{command:"published"},{default:$(()=>[ne(A(e.$t("Published")),1)]),_:1})]),_:1})]),default:$(()=>[k(u,{type:n.lesson.status=="published"?"success":"info",bg:"",text:"",class:"el-dropdown-link"},{default:$(()=>[ne(A(e.$labelize(n.lesson.status))+" ",1),k(l,{class:"el-icon--right"},{default:$(()=>[k(a)]),_:1})]),_:1},8,["type"])]),_:1}),He((C(),q(u,{style:{"margin-left":"15px"},disabled:r.saving,onClick:s.saveData,class:"fcom_primary_button"},{default:$(()=>[ne(A(e.$t("Save")),1)]),_:1},8,["disabled","onClick"])),[[T,r.saving]])])])]),_:1}),k(E,{class:"fcom_full_editor_container"},{default:$(()=>[k(m,{class:"fcol_full_editor_side",width:"250px"},{default:$(()=>[k(h,{lesson:n.lesson},null,8,["lesson"])]),_:1}),k(x,{class:"fcom_full_editor_main"},{default:$(()=>[k(S,null,{default:$(()=>[b("div",QOe,[b("div",eIe,[b("div",null,A(e.$t("Lesson %1s of %2s - %3s",n.editingIndex+1,n.section.lessons.length,n.section.title)),1),b("div",tIe,[k(u,{onClick:t[2]||(t[2]=O=>e.$emit("changeLesson",n.editingIndex-1)),disabled:n.editingIndex===0,size:"small"},{default:$(()=>[k(l,null,{default:$(()=>[k(i)]),_:1})]),_:1},8,["disabled"]),k(u,{onClick:t[3]||(t[3]=O=>e.$emit("changeLesson",n.editingIndex+1)),disabled:n.editingIndex+1===n.section.lessons.length,size:"small"},{default:$(()=>[k(l,null,{default:$(()=>[k(y)]),_:1})]),_:1},8,["disabled"])])]),b("div",nIe,[k(v,{ref:"create_status",type:"text",class:"fcom_input_h1",modelValue:n.lesson.title,"onUpdate:modelValue":t[4]||(t[4]=O=>n.lesson.title=O),size:"large",placeholder:e.$t("Lesson Title")},null,8,["modelValue","placeholder"])]),n.lesson.meta.enable_media=="yes"?(C(),q(w,{key:0,style:{margin:"30px 0"},media:n.lesson.meta.media},null,8,["media"])):W("",!0),b("div",oIe,[k(_,{modelValue:n.lesson.message,"onUpdate:modelValue":t[5]||(t[5]=O=>n.lesson.message=O)},null,8,["modelValue"])])])]),_:1})]),_:1})]),_:1})]),_:1})])}const mL=qe(GOe,[["render",rIe]]),sIe={name:"LessonLine",emits:["showEditor","updated"],props:["lesson"],components:{LessonEditor:mL},data(){return{editing_title:!1,editingLesson:!1}},methods:{updateLessonStatus(e){if(this.lesson.status===e)return!1;this.lesson.status=e,this.$emit("updated",this.lesson,["status"])},updateLessonTitle(){this.editing_title=!1,this.$emit("updated",this.lesson,["title"])},showEditor(){this.editing_title=!0,this.$nextTick(()=>{this.$refs.lesson_title_edit.focus()})},handleLessonAction(e){e==="edit_title"?this.showEditor():e==="delete"?this.$emit("deleteLesson",this.lesson):e==="edit_lesson"&&this.$emit("showEditor",this.lesson)}}},iIe={key:0,class:"fcom_heading_item"},lIe={class:"fcom_section_item_actions"};function aIe(e,t,n,o,r,s){const i=pt,l=At,a=re("arrow-down"),u=Ne,c=bh,d=wh,f=_h,p=re("MoreFilled");return C(),M(fe,null,[b("div",{class:D([{fcom_title_editing:r.editing_title},"fcom_section_item_title fcom_title_editable"])},[he(e.$slots,"before_section_heading"),r.editing_title?(C(),q(l,{key:1,onKeydown:t[1]||(t[1]=Pt(h=>r.editing_title=!1,["esc"])),ref:"lesson_title_edit",onKeyup:Pt(s.updateLessonTitle,["enter"]),modelValue:n.lesson.title,"onUpdate:modelValue":t[2]||(t[2]=h=>n.lesson.title=h)},{append:$(()=>[k(i,{onClick:s.updateLessonTitle},{default:$(()=>[ne(A(e.$t("save")),1)]),_:1},8,["onClick"])]),_:1},8,["onKeyup","modelValue"])):(C(),M("p",iIe,[b("span",{onClick:t[0]||(t[0]=h=>e.$emit("showEditor",n.lesson))},A(n.lesson.title),1)]))],2),b("div",lIe,[k(i,{onClick:t[3]||(t[3]=h=>e.$emit("showEditor",n.lesson)),class:"fcom_show_hover",text:""},{default:$(()=>[ne(A(e.$t("Edit lesson")),1)]),_:1}),k(f,{onCommand:t[4]||(t[4]=h=>{s.updateLessonStatus(h)}),trigger:"click"},{dropdown:$(()=>[k(d,null,{default:$(()=>[k(c,{command:"draft"},{default:$(()=>[ne(A(e.$t("Draft")),1)]),_:1}),k(c,{command:"published"},{default:$(()=>[ne(A(e.$t("Published")),1)]),_:1})]),_:1})]),default:$(()=>[k(i,{class:D(["el-dropdown-link",`fcom_button_${n.lesson.status==="published"?"success":"info"}`]),bg:"",text:""},{default:$(()=>[ne(A(e.$labelize(n.lesson.status))+" ",1),k(u,{class:"el-icon--right"},{default:$(()=>[k(a)]),_:1})]),_:1},8,["class"])]),_:1}),k(f,{onCommand:s.handleLessonAction,trigger:"click"},{dropdown:$(()=>[k(d,null,{default:$(()=>[k(c,{command:"edit_lesson"},{default:$(()=>[ne(A(e.$t("Edit Lesson Content")),1)]),_:1}),k(c,{command:"edit_title"},{default:$(()=>[ne(A(e.$t("Edit Title")),1)]),_:1}),k(c,{command:"delete"},{default:$(()=>[ne(A(e.$t("Delete Lesson")),1)]),_:1})]),_:1})]),default:$(()=>[k(i,{"aria-label":e.$t("View actions"),size:"small",class:"fcom_dot_menu",text:""},{default:$(()=>[k(u,null,{default:$(()=>[k(p)]),_:1})]),_:1},8,["aria-label"])]),_:1},8,["onCommand"])])],64)}const uIe=qe(sIe,[["render",aIe]]),cIe={name:"SectionScheduler",components:{CaretBottom:FY},props:["section","course"],data(){return{saving:!1,show:!1,time:"09:00",date:"",unlock_after:0}},methods:{saveSchedule(){let e=this.date+" "+this.time+":00";if(!dayjs(e).isValid()){this.$notify.error(this.$t("Please select a valid date and time"));return}this.section.scheduled_at=e,this.patchCourse({scheduled_at:e},()=>{this.show=!1})},saveUnlockDays(){this.patchCourse({reactions_count:this.unlock_after},()=>{this.section.reactions_count=this.unlock_after,this.show=!1})},patchCourse(e={},t=null){this.saving=!0,this.$patch("admin/courses/"+this.course.id+"/sections/"+this.section.id,e).then(n=>{this.$notify.success(this.$t("Schedule has been updated")),t&&t(n)}).catch(n=>{this.$handleError(n)}).finally(()=>{this.saving=!1})},initUnlockDay(){if(this.show){this.show=!1;return}this.unlock_after=parseInt(this.section.reactions_count),this.show=!0},initPicker(){if(this.show){this.show=!1;return}let e=this.section.scheduled_at;if(!e){this.show=!0;return}this.date=dayjs(e).format("YYYY-MM-DD"),this.time=dayjs(e).format("HH:mm"),this.show=!0}}},dIe={style:{"padding-left":"10px"},class:"fcom_section_scheduler"},fIe={class:"fcom_scheduler_form"},pIe={class:"fcom_input_group"},hIe={class:"el_inline_date_picker"},mIe={class:"fcom_input_group"},gIe={class:"fcom_input_group"},vIe={class:"fcom_scheduler_form"},yIe={class:"fcom_input_group"},_Ie={class:"fcom_label"},bIe={class:"fcom_input_group"};function wIe(e,t,n,o,r,s){const i=re("CaretBottom"),l=Ne,a=lie,u=AO,c=pt,d=Po,f=Gle,p=zt("loading");return C(),M("div",dIe,[n.course.settings.course_type=="scheduled"?(C(),q(d,{key:0,persistent:!1,placement:"bottom",width:400,visible:r.show},{reference:$(()=>[b("button",{onClick:t[0]||(t[0]=(...h)=>s.initPicker&&s.initPicker(...h)),class:"fcom_input_select_btn"},[b("span",null,A(n.section.scheduled_at?e.smartDate(n.section.scheduled_at,!0,!0):e.$t("Select drip date")),1),k(l,null,{default:$(()=>[k(i)]),_:1})])]),default:$(()=>[b("div",fIe,[b("div",pIe,[b("div",hIe,[k(a,{"value-format":"YYYY-MM-DD",format:"YYYY-MM-DD",teleported:!1,"popper-class":"el_inline_date_picker_box",modelValue:r.date,"onUpdate:modelValue":t[1]||(t[1]=h=>r.date=h)},null,8,["modelValue"])])]),b("div",mIe,[k(u,{modelValue:r.time,"onUpdate:modelValue":t[2]||(t[2]=h=>r.time=h),start:"00:00",end:"23:59",steps:15},null,8,["modelValue"])]),b("div",gIe,[He((C(),q(c,{disabled:r.saving,type:"success",onClick:s.saveSchedule},{default:$(()=>[ne(A(e.$t("Update Date")),1)]),_:1},8,["disabled","onClick"])),[[p,r.saving]])])])]),_:1},8,["visible"])):W("",!0),n.course.settings.course_type=="structured"?(C(),q(d,{key:1,persistent:!1,placement:"bottom",width:400,visible:r.show},{reference:$(()=>[b("button",{onClick:t[3]||(t[3]=(...h)=>s.initUnlockDay&&s.initUnlockDay(...h)),class:"fcom_input_select_btn"},[b("span",null,A(n.section.reactions_count?e.$t("after %d days of enrollment",n.section.reactions_count):e.$t("Immediately")),1),k(l,null,{default:$(()=>[k(i)]),_:1})])]),default:$(()=>[b("div",vIe,[b("div",yIe,[b("div",_Ie,A(e.$t("Unlock section after")),1),k(f,{modelValue:r.unlock_after,"onUpdate:modelValue":t[4]||(t[4]=h=>r.unlock_after=h),min:0,max:1e3,"controls-position":"right",precision:0},null,8,["modelValue"]),ne(" "+A(e.$t("Days")),1)]),b("div",bIe,[He((C(),q(c,{disabled:r.saving,type:"success",onClick:s.saveUnlockDays},{default:$(()=>[ne(A(e.$t("Update")),1)]),_:1},8,["disabled","onClick"])),[[p,r.saving]])])])]),_:1},8,["visible"])):W("",!0)])}const CIe=qe(cIe,[["render",wIe]]),kIe={name:"SectionPart",props:["section","course"],emits:["reload"],components:{LessonEditor:mL,LessonLine:uIe,SectionScheduler:CIe,FluentDnD:xv},data(){return{editing_title:!1,addingLesson:!1,newLesson:{title:""},working:!1,editingLesson:null,editingIndex:0}},computed:{hasSchedule(){return this.course.settings.course_type==="scheduled"||this.course.settings.course_type==="structured"}},methods:{updateLessonStatus(e,t){e.status=t},showTitleEditor(){this.editing_title=!0,this.$nextTick(()=>{this.$refs.fcom_section_title_editor.focus()})},patchSection(e){let t={};e.forEach(n=>{t[n]=this.section[n]}),this.editing_title=!1,this.$patch("admin/courses/"+this.course.id+"/sections/"+this.section.id,t).then(n=>{console.log(n)}).catch(n=>{this.$handleError(n)})},handleLessonUpdated(e,t){let n={};t.forEach(o=>{n[o]=e[o]}),this.editing_title=!1,this.$patch("admin/courses/"+this.course.id+"/lessons/"+e.id,n).then(o=>{this.$notify.success(o.message)}).catch(o=>{this.$handleError(o)})},addLesson(e,t=!1){e&&e.preventDefault(),this.addingLesson=!0,this.$post("admin/courses/"+this.course.id+"/lessons",{...this.newLesson,section_id:parseInt(this.section.id)}).then(n=>{this.section.lessons.push(n.lesson),this.$refs.add_lesson.hide(),this.newLesson.title="",t&&this.$nextTick(()=>{let o=this.section.lessons.length-1;this.editingLesson=this.section.lessons[o],this.editingIndex=o})}).catch(n=>{this.$handleError(n)}).finally(()=>{this.addingLesson=!1})},handleSectionAction(e){if(e=="edit_title"){this.showTitleEditor();return}e=="delete"&&this.$confirm(this.$t("Are you sure you want to delete this section? All the associate lessons and enrollment data will be deleted too."),{confirmButtonText:this.$t("Yes, Delete"),cancelButtonText:this.$t("Cancel"),type:"warning",title:this.$t("Are you sure?"),showInput:!0,dangerouslyUseHTMLString:!0,inputPlaceholder:this.$t("Type %s to confirm","DELETE"),inputValidator(t){return t.toLowerCase()==="delete"?!0:this.$t("You must type %s to confirm","DELETE")},inputErrorMessage:this.$t("You must type %s to confirm","DELETE")}).then(t=>{if(t.value!="DELETE"){this.$notify.error({title:"Error",message:this.$t("You must type %s to confirm","DELETE")});return}this.working=!0,this.$del("admin/courses/"+this.course.id+"/sections/"+this.section.id).then(n=>{this.$emit("reload")}).catch(n=>{this.$handleError(n)}).finally(()=>{this.working=!1})}).catch(()=>{})},handleDeleteLesson(e){this.$confirm(this.$t("Are you sure you want to delete this lesson? All the associate date will be deleted too."),{confirmButtonText:this.$t("Yes, Delete"),cancelButtonText:this.$t("Cancel"),type:"warning",title:this.$t("Are you sure?")}).then(()=>{this.working=!0,this.$del("admin/courses/"+this.course.id+"/lessons/"+e.id).then(t=>{this.$emit("reload")}).catch(t=>{this.$handleError(t)}).finally(()=>{this.working=!1})}).catch(()=>{})},handleChangeLesson(e){this.editingLesson=null,this.editingIndex=0,this.$nextTick(()=>{this.editingLesson=this.section.lessons[e],this.editingIndex=e})},initLessonEditor(e,t){this.editingLesson=e,this.editingIndex=t},dropLesson({index:e}){const t=this.section.lessons.splice(e,1)[0];this.section.lessons.splice(e,0,t),this.resetLessonIndexes()},resetLessonIndexes(){const e={};cu(this.section.lessons,(t,n)=>{e[t.id]=n+1}),this.$patch("admin/courses/"+this.course.id+"/sections/"+this.section.id+"/indexes",{indexes:e}).then(t=>{this.$notify.success(t.message)}).catch(t=>{this.$handleError(t)})}}},SIe={class:"fcom_section_primary"},$Ie={class:"fcom_section_primary_item"},EIe={key:0,class:"fcom_heading_item"},xIe={class:"fcom_section_config fcom_label_schedule"},MIe={class:"fcom_section_config fcom_label_email"},TIe={style:{"margin-left":"15px"}},OIe={class:"meta_line"},IIe={class:"fcom_section_primary_item_actions fcom_label_actions"},AIe={key:0,class:"fcom_section_items"},NIe=b("div",{class:"fcom_drag_handle"}," ⋮⋮ ",-1),PIe={key:0};function LIe(e,t,n,o,r,s){const i=pt,l=At,a=re("section-scheduler"),u=io,c=so,d=Po,f=re("MoreFilled"),p=Ne,h=bh,m=wh,y=_h,v=re("lesson-line"),w=re("FluentDnD"),_=re("LessonEditor"),S=zt("loading");return C(),M(fe,null,[He((C(),M("div",SIe,[b("div",$Ie,[b("div",{class:D(["fcom_section_primary_item_title fcom_title_editable fcom_label_lesson",{fcom_title_editing:r.editing_title}])},[he(e.$slots,"before_section_heading"),r.editing_title?(C(),q(l,{key:1,ref:"fcom_section_title_editor",onKeyup:t[2]||(t[2]=Pt(x=>s.patchSection(["title"]),["enter"])),modelValue:n.section.title,"onUpdate:modelValue":t[3]||(t[3]=x=>n.section.title=x)},{append:$(()=>[k(i,{onClick:t[1]||(t[1]=x=>s.patchSection(["title"]))},{default:$(()=>[ne(A(e.$t("save")),1)]),_:1})]),_:1},8,["modelValue"])):(C(),M("h4",EIe,[b("span",{onClick:t[0]||(t[0]=x=>r.editing_title=!0)},A(n.section.title),1)]))],2),s.hasSchedule?(C(),M(fe,{key:0},[b("div",xIe,[k(a,{section:n.section,course:n.course},null,8,["section","course"])]),b("div",MIe,[b("div",TIe,[b("span",OIe,A(e.$t("n/a")),1)])])],64)):W("",!0),b("div",IIe,[k(d,{persistent:!1,ref:"add_lesson",placement:"bottom",width:400,trigger:"click"},{reference:$(()=>[k(i,{class:"fcom_secondary_button"},{default:$(()=>[ne(A(e.$t("Add Lesson")),1)]),_:1})]),default:$(()=>[k(c,{onSubmit:[t[6]||(t[6]=et(x=>e.doNothing(),["prevent"])),s.addLesson],"label-position":"top"},{default:$(()=>[k(u,{label:e.$t("Lesson Title")},{default:$(()=>[k(l,{modelValue:r.newLesson.title,"onUpdate:modelValue":t[4]||(t[4]=x=>r.newLesson.title=x),placeholder:e.$t("Enter Lesson title")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),k(u,null,{default:$(()=>[He((C(),q(i,{disabled:r.addingLesson,class:"fcom_secondary_button",onClick:s.addLesson},{default:$(()=>[ne(A(e.$t("Add")),1)]),_:1},8,["disabled","onClick"])),[[S,r.addingLesson]]),He((C(),q(i,{disabled:r.addingLesson,class:"fcom_primary_button",onClick:t[5]||(t[5]=()=>{s.addLesson(!1,!0)})},{default:$(()=>[ne(A(e.$t("Add & Edit")),1)]),_:1},8,["disabled"])),[[S,r.addingLesson]])]),_:1})]),_:1},8,["onSubmit"])]),_:1},512),k(y,{onCommand:s.handleSectionAction,trigger:"click"},{dropdown:$(()=>[k(m,null,{default:$(()=>[k(h,{command:"edit_title"},{default:$(()=>[ne(A(e.$t("Edit Title")),1)]),_:1}),k(h,{command:"delete"},{default:$(()=>[ne(A(e.$t("Delete section")),1)]),_:1})]),_:1})]),default:$(()=>[k(i,{"aria-label":e.$t("View actions"),size:"small",class:"fcom_dot_menu",style:{"margin-left":"10px"},text:""},{default:$(()=>[k(p,null,{default:$(()=>[k(f)]),_:1})]),_:1},8,["aria-label"])]),_:1},8,["onCommand"])])]),n.section.lessons.length?(C(),M("div",AIe,[k(w,{items:n.section.lessons,onDrop:s.dropLesson,"item-class":"fcom_section_item"},{item:$(({data:x})=>[(C(),q(v,{onDeleteLesson:s.handleDeleteLesson,onUpdated:s.handleLessonUpdated,key:x.id,onShowEditor:E=>s.initLessonEditor(x,e.lessonIndex),lesson:x},{before_section_heading:$(()=>[NIe]),_:2},1032,["onDeleteLesson","onUpdated","onShowEditor","lesson"]))]),_:1},8,["items","onDrop"])])):W("",!0)])),[[S,r.working]]),r.editingLesson?(C(),M("div",PIe,[(C(),q(_s,{to:"body"},[k(_,{course:n.course,onChangeLesson:s.handleChangeLesson,section:n.section,editingIndex:r.editingIndex,onClose:t[7]||(t[7]=x=>{r.editingLesson=null}),lesson:r.editingLesson},null,8,["course","onChangeLesson","section","editingIndex","lesson"])]))])):W("",!0)],64)}const RIe=qe(kIe,[["render",LIe]]),DIe={name:"EditLessons",props:["course"],components:{SectionPart:RIe,FluentDnD:xv},data(){return{sections:[],loading:!1,newSection:{title:""},addingSection:!1}},computed:{lessonsCount(){let e=0;return cu(this.sections,t=>{e+=t.lessons.length}),e}},methods:{fetchSections(){this.loading=!0,this.$get("admin/courses/"+this.course.id+"/sections").then(e=>{this.sections=e.sections}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},dropSection({indx:e}){const t=this.sections.splice(e,1)[0];this.sections.splice(e,0,t),this.resetSectionIndexes()},addSection(){this.addingSection=!0,this.$post("admin/courses/"+this.course.id+"/sections",this.newSection).then(e=>{this.sections.push(e.section),this.$refs.add_section.hide(),this.newSection.title=""}).catch(e=>{this.$handleError(e)}).finally(()=>{this.addingSection=!1})},resetSectionIndexes(){const e={};cu(this.sections,(t,n)=>{e[t.id]=n+1}),this.$patch("admin/courses/"+this.course.id+"/sections/indexes",{indexes:e}).then(t=>{this.$notify.success(t.message)}).catch(t=>{this.$handleError(t)})}},mounted(){this.fetchSections()}},FIe={class:"fcom_course_lessons"},VIe={class:"fcom_settings_header"},BIe={class:"fcom_settings_header_meta"},zIe={class:"fcom_settings_header_meta_item"},jIe={class:"fcom_card_section_heading"},HIe={class:"fcom_section_labels"},UIe={class:"fcom_lebel fcom_label_lesson"},WIe={class:"fcom_lebel fcom_label_schedule"},KIe={class:"fcom_lebel fcom_label_email"},qIe=b("div",{class:"fcom_lebel fcom_label_actions"},null,-1),GIe=b("div",{class:"fcom_drag_handle"}," ⋮⋮ ",-1);function YIe(e,t,n,o,r,s){const i=pt,l=At,a=io,u=so,c=Po,d=lo,f=re("section-part"),p=re("FluentDnD"),h=zt("loading");return C(),M("div",FIe,[b("div",VIe,[b("div",null,[b("h2",null,A(e.$t("Lessons")),1),b("div",BIe,[b("div",zIe,[b("b",null,A(e.$t("Type:")),1),ne(" "+A(e.$labelize(n.course.settings.course_type))+" • ",1),b("b",null,A(e.$t("Status:")),1),ne(" "+A(e.$labelize(n.course.status))+" • ",1),b("b",null,A(e.$t("Visibility:")),1),ne(" "+A(e.$labelize(n.course.privacy)),1)])])])]),b("div",{class:D(["fcom_card_sections","fcom_course_type_"+n.course.settings.course_type])},[He((C(),M("div",jIe,[b("h3",null,A(e.$_n("%d Section","%d Sections",r.sections.length))+" • "+A(e.$_n("%d Lesson","%d Lessons",s.lessonsCount)),1),k(c,{persistent:!1,ref:"add_section",placement:"bottom",width:400,trigger:"click"},{reference:$(()=>[k(i,{class:"fcom_primary_button",bg:""},{default:$(()=>[ne(A(e.$t("+ Add Section")),1)]),_:1})]),default:$(()=>[k(u,{onSubmit:t[1]||(t[1]=et(m=>e.doNothing(),["prevent"])),"label-position":"top"},{default:$(()=>[k(a,{label:e.$t("Section Title")},{default:$(()=>[k(l,{onKeydown:Pt(et(s.addSection,["prevent"]),["enter"]),modelValue:r.newSection.title,"onUpdate:modelValue":t[0]||(t[0]=m=>r.newSection.title=m),placeholder:e.$t("Enter Section title")},null,8,["onKeydown","modelValue","placeholder"])]),_:1},8,["label"]),k(a,null,{default:$(()=>[He((C(),q(i,{disabled:r.addingSection,class:"fcom_primary_button",onClick:s.addSection},{default:$(()=>[ne(A(e.$t("Save")),1)]),_:1},8,["disabled","onClick"])),[[h,r.addingSection]])]),_:1})]),_:1})]),_:1},512)])),[[h,r.loading]]),r.loading?(C(),q(d,{key:0,animated:!0,rows:10})):W("",!0),b("div",HIe,[b("div",UIe,A(e.$t("Lesson name")),1),b("div",WIe,A(e.$t("Schedule")),1),b("div",KIe,A(e.$t("E-mail")),1),qIe]),k(p,{items:r.sections,onDrop:s.dropSection,"item-class":"fcom_section_item"},{item:$(({data:m})=>[k(f,{onReload:s.fetchSections,course:n.course,section:m},{before_section_heading:$(()=>[GIe]),_:2},1032,["onReload","course","section"])]),_:1},8,["items","onDrop"])],2)])}const ZIe=qe(DIe,[["render",YIe]]),JIe={name:"Pagination",emits:["fetch","per_page_change"],computed:{layout(){return this.isMobile?"total, sizes, prev, next":"total, sizes, prev, pager, next"}},props:{pagination:{required:!0,type:Object},extra_sizes:{required:!1,type:Array,default(){return[]}},hide_on_single:{required:!1,type:Boolean,default(){return!0}}},computed:{page_sizes(){const e=[];this.pagination.per_page<10&&e.push(this.pagination.per_page);const t=[10,20,50,80,100,120,150];return[...e,...t,...this.extra_sizes]}},methods:{changePage(e){this.pagination.page=e,this.$emit("fetch")},changeSize(e){this.pagination.per_page=e,this.$emit("per_page_change",e),this.$emit("fetch")}}};function XIe(e,t,n,o,r,s){const i=tue;return C(),q(i,{class:"fcom-pagination",background:!1,size:"small",layout:"total, sizes, prev, pager, next",onCurrentChange:s.changePage,onSizeChange:s.changeSize,"hide-on-single-page":n.hide_on_single,"current-page":n.pagination.page,"page-sizes":s.page_sizes,"page-size":n.pagination.per_page,total:n.pagination.total},null,8,["onCurrentChange","onSizeChange","hide-on-single-page","current-page","page-sizes","page-size","total"])}const gL=qe(JIe,[["render",XIe]]),QIe={name:"AddStudentForm",props:["course"],emits:["completed"],data(){return{users:[],loading:!1,saving:!1,userId:null}},methods:{fetchUsers(e=""){this.loading=!0,this.$get("admin/courses/users/search",{context:"add_member",search:e,course_id:this.course.id}).then(t=>{this.users=t.users.data}).catch(t=>{this.$handleError(t)}).finally(()=>{this.loading=!1})},addStudent(){this.saving=!0,this.$post("admin/courses/"+this.course.id+"/students",{user_id:this.userId}).then(e=>{this.$notify.success(e.message),this.$emit("completed")}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})}},mounted(){this.fetchUsers()}},eAe={style:{float:"left"}},tAe={style:{float:"right",color:"#8492a6","font-size":"13px"}};function nAe(e,t,n,o,r,s){const i=Ss,l=vr,a=io,u=pt,c=so,d=zt("loading");return C(),q(c,{onSubmit:t[2]||(t[2]=et(f=>e.doNothing(),["prevent"])),"label-position":"top"},{default:$(()=>[k(a,{label:e.$t("User")},{default:$(()=>[k(l,{class:"rich_select",filterable:"",remote:"",loading:r.loading,"remote-method":s.fetchUsers,placeholder:e.$t("Select User"),modelValue:r.userId,"onUpdate:modelValue":t[0]||(t[0]=f=>r.userId=f)},{default:$(()=>[(C(!0),M(fe,null,nt(r.users,f=>(C(),q(i,{key:f.ID,label:f.display_name+" ("+f.ID+")",value:f.ID},{default:$(()=>[b("span",eAe,A(f.display_name),1),b("span",tAe,A(f.ID),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["loading","remote-method","placeholder","modelValue"])]),_:1},8,["label"]),he(e.$slots,"after_form",{},()=>[k(a,null,{default:$(()=>[He((C(),q(u,{class:"fcom_primary_button",disabled:r.saving,onClick:t[1]||(t[1]=f=>s.addStudent())},{default:$(()=>[ne(A(e.$t("Add Student")),1)]),_:1},8,["disabled"])),[[d,r.saving]])]),_:1})])]),_:3})}const oAe=qe(QIe,[["render",nAe]]),rAe={name:"CourseMembers",props:["course","course_id"],components:{UserRouteLink:X0,Pagination:gL,AddStudentForm:oAe},data(){return{students:[],search:"",loading:!0,working:!1,isAddStdOpen:!1,SearchIcon:Ii(XZ),pagination:{page:1,per_page:20,total:0}}},methods:{updateStudents(e){this.students=this.students.filter(t=>t.user_id!==e.user_id)},studentAdded(){this.isAddStdOpen=!1,this.fetchStudents()},toSearch(){this.pagination.page=1,this.fetchStudents()},removeStudentPrompt(e){this.$confirm(this.$t("Are you sure you want to remove this student from this course?"),this.$t("Remove Student?"),{confirmButtonText:this.$t("Remove"),cancelButtonText:this.$t("Cancel"),type:"error"}).then(()=>{this.removeStudent(e)})},removeStudent(e){this.$del("admin/courses/"+this.course.id+"/students/"+e.user_id).then(t=>{this.$notify.success(t.message),this.updateStudents(e)}).catch(t=>{this.$handleError(t)})},fetchStudents(){this.loading=!0,this.$get("admin/courses/"+this.course.id+"/students",{page:this.pagination.page,per_page:this.pagination.per_page,search:this.search}).then(e=>{this.students=e.students.data,this.pagination.total=e.students.total,window.scrollTo(0,0)}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})}},mounted(){this.fetchStudents()}},sAe={class:"fcom_course_members"},iAe={class:"fcom_course_member_header"},lAe={class:"fcom_course_member_actions"},aAe={class:"table_user_card"},uAe={class:"card_avatar"},cAe={class:"card_info"},dAe={class:"card_name"},fAe={class:"meta_line"},pAe={class:"progress_wrap"};function hAe(e,t,n,o,r,s){const i=pt,l=At,a=re("UserAvatar"),u=re("UserRouteLink"),c=Y0,d=gO,f=re("MoreFilled"),p=Ne,h=bh,m=wh,y=_h,v=G0,w=re("pagination"),_=re("add-student-form"),S=Ql,x=zt("loading");return C(),M("div",sAe,[b("div",iAe,[b("h3",null,A(e.$t("Course Students")),1),b("div",lAe,[k(l,{onKeyup:t[1]||(t[1]=Pt(E=>s.toSearch(),["enter"])),modelValue:r.search,"onUpdate:modelValue":t[2]||(t[2]=E=>r.search=E),placeholder:e.$t("Search Members...")},{append:$(()=>[k(i,{onClick:t[0]||(t[0]=E=>s.toSearch()),text:"",icon:r.SearchIcon},null,8,["icon"])]),_:1},8,["modelValue","placeholder"]),k(i,{class:"fcom_primary_button el-button",onClick:t[3]||(t[3]=E=>r.isAddStdOpen=!0)},{default:$(()=>[ne(A(e.$t("Add Student")),1)]),_:1})])]),He((C(),q(v,{data:r.students,style:{width:"100%"}},{default:$(()=>[k(c,{prop:"ID",label:e.$t("Name"),"min-width":"200"},{default:$(E=>[b("div",aAe,[b("div",uAe,[k(a,{xprofile:E.row},null,8,["xprofile"])]),b("div",cAe,[b("div",dAe,[k(u,{show_badge:!0,xprofile:E.row},null,8,["xprofile"])]),b("div",fAe,A(e.getExcerpt(E.row.short_description,160)),1)])])]),_:1},8,["label"]),k(c,{width:"160",prop:"progress",label:e.$t("Progress")},{default:$(E=>[b("div",pAe,[k(d,{percentage:parseInt(E.row.progress)},null,8,["percentage"])])]),_:1},8,["label"]),k(c,{width:"160",label:e.$t("Start Date")},{default:$(E=>[ne(A(e.smartDate(E.row.space_pivot.created_at,!0)),1)]),_:1},8,["label"]),k(c,{width:"50"},{default:$(E=>[k(y,{trigger:"click"},{dropdown:$(()=>[k(m,null,{default:$(()=>[k(h,{onClick:T=>s.removeStudentPrompt(E.row)},{default:$(()=>[ne(A(e.$t("Remove")),1)]),_:2},1032,["onClick"])]),_:2},1024)]),default:$(()=>[k(i,{"aria-label":e.$t("View actions"),class:"fcom_dot_menu",size:"small",text:""},{default:$(()=>[k(p,null,{default:$(()=>[k(f)]),_:1})]),_:1},8,["aria-label"])]),_:2},1024)]),_:1})]),_:1},8,["data"])),[[x,r.loading]]),k(w,{hide_on_single:!0,onFetch:s.fetchStudents,pagination:r.pagination},null,8,["onFetch","pagination"]),k(S,{modelValue:r.isAddStdOpen,"onUpdate:modelValue":t[4]||(t[4]=E=>r.isAddStdOpen=E),"close-on-click-modal":!1,"append-to-body":!0,size:e.dialogWidth,direction:"rtl"},{header:$(()=>[b("h4",null,A(e.$t("Add Student")),1)]),default:$(()=>[k(_,{onCompleted:s.studentAdded,course:n.course},null,8,["onCompleted","course"])]),_:1},8,["modelValue","size"])])}const mAe=qe(rAe,[["render",hAe]]),gAe={name:"ChatIcon"},vAe={width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},yAe=b("path",{d:"M6.66732 11.25H13.334M6.66732 7.08333H10.0007",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"},null,-1),_Ae=b("path",{d:"M5.08267 15.833C3.99924 15.7264 3.18762 15.401 2.6433 14.8567C1.66699 13.8804 1.66699 12.309 1.66699 9.16634V8.74967C1.66699 5.60698 1.66699 4.03563 2.6433 3.05932C3.61961 2.08301 5.19096 2.08301 8.33366 2.08301H11.667C14.8097 2.08301 16.381 2.08301 17.3573 3.05932C18.3337 4.03563 18.3337 5.60698 18.3337 8.74967V9.16634C18.3337 12.309 18.3337 13.8804 17.3573 14.8567C16.381 15.833 14.8097 15.833 11.667 15.833C11.1999 15.8434 10.8279 15.879 10.4625 15.9622C9.46385 16.1921 8.5391 16.7031 7.62522 17.1487C6.32307 17.7837 5.67199 18.1012 5.2634 17.8039C4.48174 17.2218 5.24577 15.4179 5.41699 14.583",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round"},null,-1),bAe=[yAe,_Ae];function wAe(e,t,n,o,r,s){return C(),M("svg",vAe,bAe)}const CAe=qe(gAe,[["render",wAe]]),kAe={name:"HeartIcon",props:{filled:{default:!1}}},SAe={key:0,viewBox:"0 0 24 24","aria-hidden":"true"},$Ae=b("g",null,[b("path",{d:"M20.884 13.19c-1.351 2.48-4.001 5.12-8.379 7.67l-.503.3-.504-.3c-4.379-2.55-7.029-5.19-8.382-7.67-1.36-2.5-1.41-4.86-.514-6.67.887-1.79 2.647-2.91 4.601-3.01 1.651-.09 3.368.56 4.798 2.01 1.429-1.45 3.146-2.1 4.796-2.01 1.954.1 3.714 1.22 4.601 3.01.896 1.81.846 4.17-.514 6.67z"})],-1),EAe=[$Ae],xAe={key:1,viewBox:"0 0 24 24","aria-hidden":"true"},MAe=b("g",null,[b("path",{d:"M16.697 5.5c-1.222-.06-2.679.51-3.89 2.16l-.805 1.09-.806-1.09C9.984 6.01 8.526 5.44 7.304 5.5c-1.243.07-2.349.78-2.91 1.91-.552 1.12-.633 2.78.479 4.82 1.074 1.97 3.257 4.27 7.129 6.61 3.87-2.34 6.052-4.64 7.126-6.61 1.111-2.04 1.03-3.7.477-4.82-.561-1.13-1.666-1.84-2.908-1.91zm4.187 7.69c-1.351 2.48-4.001 5.12-8.379 7.67l-.503.3-.504-.3c-4.379-2.55-7.029-5.19-8.382-7.67-1.36-2.5-1.41-4.86-.514-6.67.887-1.79 2.647-2.91 4.601-3.01 1.651-.09 3.368.56 4.798 2.01 1.429-1.45 3.146-2.1 4.796-2.01 1.954.1 3.714 1.22 4.601 3.01.896 1.81.846 4.17-.514 6.67z"})],-1),TAe=[MAe];function OAe(e,t,n,o,r,s){return n.filled?(C(),M("svg",SAe,EAe)):(C(),M("svg",xAe,TAe))}const vL=qe(kAe,[["render",OAe]]),IAe={name:"SurveyEditForm",props:["form"],emits:["cancel"],data(){return{}},methods:{addOption(){this.form.options.push({label:"",slug:""})},removeOption(e){this.form.options.splice(e,1)}}},AAe={class:"fcom_compose_app_form"},NAe={class:"fcom_app_header"},PAe={class:"fcom_app_options"},LAe={class:"fcom_app_pref"},RAe={class:"fcom_app_footer"};function DAe(e,t,n,o,r,s){const i=pt,l=At,a=re("Plus"),u=Ne,c=Hn;return C(),M("div",AAe,[b("div",NAe,[b("h5",null,A(e.$t("Poll Options")),1),b("div",null,[k(i,{onClick:t[0]||(t[0]=d=>e.$emit("cancel")),size:"small",text:""},{default:$(()=>[ne(A(e.$t("cancel")),1)]),_:1})])]),b("div",PAe,[(C(!0),M(fe,null,nt(n.form.options,(d,f)=>(C(),M("div",{class:"fcom_app_option",key:"option_"+f},[k(l,{modelValue:d.label,"onUpdate:modelValue":p=>d.label=p,type:"text",placeholder:e.$t("Your option text")},tu({_:2},[!d.slug&&f!==0?{name:"suffix",fn:$(()=>[k(i,{onClick:p=>s.removeOption(f),text:"",size:"small"},{default:$(()=>[ne("x")]),_:2},1032,["onClick"])]),key:"0"}:void 0]),1032,["modelValue","onUpdate:modelValue","placeholder"])]))),128)),b("div",LAe,[k(i,{onClick:s.addOption,text:"",size:"small"},{default:$(()=>[k(u,null,{default:$(()=>[k(a)]),_:1}),b("span",null,A(e.$t("Add More")),1)]),_:1},8,["onClick"])])]),b("div",RAe,[b("h5",null,A(e.$t("Poll Settings")),1),k(c,{modelValue:n.form.type,"onUpdate:modelValue":t[1]||(t[1]=d=>n.form.type=d),"true-value":"multi-choice","false-value":"single_choice"},{default:$(()=>[ne(A(e.$t("Users can choose multiple options")),1)]),_:1},8,["modelValue"])])])}const FAe=qe(IAe,[["render",DAe]]),VAe={name:"GiphyIcon"},BAe={width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},zAe=DE('<path d="M12.9287 10.09H14.7095" stroke="currentColor" stroke-width="1.4" stroke-linecap="round" stroke-linejoin="round"></path><path d="M15.0781 8.20333H12.9277V11.98" stroke="currentColor" stroke-width="1.4" stroke-linecap="round" stroke-linejoin="round"></path><path d="M10.3458 8.19998V11.98" stroke="currentColor" stroke-width="1.4" stroke-linecap="round" stroke-linejoin="round"></path><path d="M7.74961 8.2H6.48961C5.44549 8.2 4.59961 9.04588 4.59961 10.09V10.09C4.59961 11.1341 5.44549 11.98 6.48961 11.98H7.74961V10.09H6.69961" stroke="currentColor" stroke-width="1.4" stroke-linecap="round" stroke-linejoin="round"></path><path d="M4.5 19C2.567 19 1 17.433 1 15.5L1 4.49999C1 2.567 2.567 0.999992 4.5 0.999992H15.5C17.433 0.999992 19 2.567 19 4.49999V15.5C19 17.433 17.433 19 15.5 19H4.5Z" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"></path>',5),jAe=[zAe];function HAe(e,t,n,o,r,s){return C(),M("svg",BAe,jAe)}const UAe=qe(VAe,[["render",HAe]]),WAe={name:"Giphy",components:{GiphyIcon:UAe},data(){return{gifs:[],searchQuery:"",offset:0,limit:20,loading:!1}},methods:{loadGifs(){var t,n;if(((n=(t=this.$gloablStorage)==null?void 0:t.gifs)==null?void 0:n.length)>0&&!this.searchQuery){this.gifs=this.$gloablStorage.gifs;return}this.loading=!0;const e={limit:this.limit,offset:this.offset,q:this.searchQuery.trim()};this.$get("giphy",e).then(o=>{this.gifs=this.offset===0?o.gifs:this.gifs.concat(o.gifs),!this.searchQuery&&this.offset===0&&(this.$gloablStorage.gifs=this.gifs),this.offset+=this.limit}).catch(o=>{this.$handleError(o)}).finally(()=>{this.loading=!1})},handleGiphyClick(){this.offset=0,this.searchQuery="",this.loadGifs()},handleSearch:wpe(function(){this.offset=0,this.loadGifs()},300),handleScroll(e){e.target.scrollHeight-e.target.scrollTop===e.target.clientHeight&&!this.loading&&this.loadGifs()},selectGiphy(e){this.$emit("selected-giphy",e),this.$refs.popover.hide()}}},KAe={class:"fcom_giphy_composer"},qAe={class:"search-container"},GAe=["onLoad","src","alt","onClick"],YAe={key:0,class:"img_loading"},ZAe={key:1,class:"no_result"},JAe=b("div",{class:"fcom_giphy_powered_by"},[b("span",{class:"powered_by"},"POWERED BY "),b("span",null,"GIPHY")],-1);function XAe(e,t,n,o,r,s){const i=At,l=vh,a=gh,u=re("GiphyIcon"),c=Ne,d=pt,f=Po,p=zt("loading");return C(),M("div",KAe,[k(f,{placement:"top-end",width:300,persistent:!1,trigger:"click","popper-class":"fcom_giphy_popover",ref:"popover"},{reference:$(()=>[k(d,{"aria-label":"Pick GIF",text:"",onClick:s.handleGiphyClick},{default:$(()=>[k(c,{class:D(["fcom_apps_icon"])},{default:$(()=>[k(u)]),_:1})]),_:1},8,["onClick"])]),default:$(()=>[He((C(),M("div",qAe,[k(i,{modelValue:r.searchQuery,"onUpdate:modelValue":t[0]||(t[0]=h=>r.searchQuery=h),placeholder:e.$t("Search Gifs"),onInput:s.handleSearch},null,8,["modelValue","placeholder","onInput"]),b("div",{class:"gif_container",onScroll:t[1]||(t[1]=(...h)=>s.handleScroll&&s.handleScroll(...h))},[r.gifs.length>0?(C(),q(a,{key:0,gutter:5},{default:$(()=>[(C(!0),M(fe,null,nt(r.gifs,h=>(C(),q(l,{span:12,key:h.id,class:"gif_item"},{default:$(()=>[b("img",{alt:"",onLoad:m=>h.loaded=!0,src:h.images.preview_gif.url,onClick:m=>s.selectGiphy(h)},null,40,GAe),h.loaded?W("",!0):(C(),M("p",YAe))]),_:2},1024))),128))]),_:1})):(C(),M("p",ZAe,A(e.$t("No results")),1))],32),JAe])),[[p,r.loading]])]),_:1},512)])}const QAe=qe(WAe,[["render",XAe]]),eNe={name:"VideoIcon"},tNe={width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},nNe=b("rect",{x:"1",y:"1",width:"18",height:"18",rx:"3.5",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"},null,-1),oNe=b("path",{d:"M8.90484 7.14604L12.663 9.3589C13.1383 9.6384 13.1383 10.3237 12.663 10.6032L8.90484 12.816C8.4208 13.1013 7.80896 12.7534 7.80896 12.1934V7.76865C7.80896 7.20869 8.4208 6.86076 8.90484 7.14604Z",fill:"currentColor"},null,-1),rNe=[nNe,oNe];function sNe(e,t,n,o,r,s){return C(),M("svg",tNe,rNe)}const iNe=qe(eNe,[["render",sNe]]),lNe={name:"VideoEmbeder",emits:["embeded"],components:{MediaEmbeder:Lk,VideoIcon:iNe},data(){return{videoUrl:"",showVideoPop:!1,media:{type:"oembed",url:"",inner_html:"",content_type:"video"}}},methods:{show(){this.showVideoPop=!0},embeded(e){this.$emit("embeded",e),this.showVideoPop=!1,this.media={type:"oembed",url:"",inner_html:"",content_type:"video"}}}},aNe={class:"fcom_video_embeder"};function uNe(e,t,n,o,r,s){const i=re("VideoIcon"),l=Ne,a=pt,u=re("media-embeder"),c=yh;return C(),M("div",aNe,[k(a,{"aria-label":"Add Video",text:"",onClick:s.show},{default:$(()=>[k(l,{class:D(["fcom_apps_icon"])},{default:$(()=>[k(i)]),_:1})]),_:1},8,["onClick"]),r.showVideoPop?(C(),q(c,{key:0,title:e.$t("Attach video"),modelValue:r.showVideoPop,"onUpdate:modelValue":t[0]||(t[0]=d=>r.showVideoPop=d),width:e.dialogWidth,style:{"max-width":"600px"},"append-to-body":!0},{default:$(()=>[k(u,{box_title:e.$t("Add Featured Video for this post"),has_iframe:!1,onEmbeded:s.embeded,media:r.media},null,8,["box_title","onEmbeded","media"])]),_:1},8,["title","modelValue","width"])):W("",!0)])}const cNe=qe(lNe,[["render",uNe]]),dNe=window.fluentComAdmin.auth,fNe={name:"FeedTextComposer",components:{MediaPreview:Mv,Giphy:QAe,ImageUploader:Md,SurveyEditForm:FAe,MarkdownEditor:eL,EmojiPicker:uL,VideoEmbeder:cNe},emits:["editorCreated"],props:{placeholder:{type:String,default(){return"What's happening, "+dNe.first_name}},disabled:{type:Boolean,default(){return!1}},autofocus:{type:Boolean,default(){return!0}},content:{type:Object,default(){return{message:"",media_images:[]}}},mentionQuery:{type:Object,default(){return{}}},autofocus_changed:{type:Boolean,default(){return!1}},multipleMedia:{type:Boolean,default(){return!1}},surveyApp:{type:Boolean,default(){return!1}},videoApp:{type:Boolean,default(){return!1}},defaultMentions:{type:Array,default(){return[]}},hasEveyoneMention:{type:Boolean,default(){return!1}}},computed:{hasActiveApp(){return!!this.content.survey}},data(){return{mentionResults:[],mentionSearch:"",uploading:!1,isEmojiPickerVisible:!1}},methods:{insertEmoji(e){this.$refs.markdownEditor&&this.$refs.markdownEditor.updateContent(e)},checkHasImageForCommentsEdit(e){return e.media&&e.media.media_url},removeImageFromComments(){this.content.media=null},checkForImage(e){for(let t=0;t<e.clipboardData.items.length;++t){let n=e.clipboardData.items[t];if(n.kind=="file"&&n.type.startsWith("image/")){const o=n.getAsFile(),r=e.clipboardData.getData("text")||"clipboard-image.png";this.uploadImage(new File([o],r,{type:o.type}))}}},uploadImage(e){this.uploading=!0;var t=new FormData;t.append("file",e),t.append("max_width",1e3),t.append("resize",!0),this.$uploadFile("feeds/media-upload",t).then(n=>{this.handleMediaUpload(n.media.url)}).catch(n=>{this.$handleError(n)}).finally(()=>{this.uploading=!1})},handleMediaUpload(e,t="uploader"){var n,o;if(this.content.media_images||(this.content.media_images=[]),(o=(n=this.content)==null?void 0:n.meta)!=null&&o.media_preview&&(this.content.meta.media_preview=null),this.multipleMedia||(this.content.media_images=[]),this.content.media_images.length>=this.appVars.features.max_media_per_post){this.$notify.error(this.$t("You can only upload maximum %s images for a post",this.appVars.features.max_media_per_post));return}this.content.media_images.push({url:e,provider:t,type:"image",height:0,width:0}),this.content.media=null},initSurveyForm(){this.content.survey||(this.content.survey={type:"single_choice",options:[{slug:"",label:this.$t("First choice")},{slug:"",label:""}]})},selectedGiphy(e){var n,o;this.content.meta||(this.content.meta=[]),(n=this.content)!=null&&n.media_images&&(this.content.media_images=[]),(o=this.content)!=null&&o.media&&(this.content.media=null);const t={image:e.images.downsized_medium.url,height:e.images.downsized_medium.height,width:e.images.downsized_medium.width,type:"image",provider:"giphy"};this.content.meta={media_preview:t}},handleVideoAttachment(e){this.content.media_images=[],this.content.meta=[],this.content.media=e}},mounted(){this.autofocus&&this.$nextTick(()=>{this.$refs.create_status&&this.$refs.create_status.focus()})}},pNe={class:"fcom_text_composer"},hNe={class:"fcom_editor status_text_input"},mNe={key:0,style:{position:"relative","text-align":"center"}},gNe={key:1,class:"fcom_media_items"},vNe={key:0,class:"fcom_media_images"},yNe=["src","alt"],_Ne={key:1},bNe={class:"fcom_media_images"},wNe=["src","alt"],CNe={key:2,class:"fcrom_media_images"},kNe=["src","alt"],SNe={key:3,class:"fcrom_media_images"},$Ne={class:"fcrom_media_image"},ENe=["src","alt"],xNe={class:"fcom_composer_footer"},MNe={class:"fcom_composer_apps"},TNe=b("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},[b("path",{d:"M7.49996 18.3327H12.5C16.6666 18.3327 18.3333 16.666 18.3333 12.4993V7.49935C18.3333 3.33268 16.6666 1.66602 12.5 1.66602H7.49996C3.33329 1.66602 1.66663 3.33268 1.66663 7.49935V12.4993C1.66663 16.666 3.33329 18.3327 7.49996 18.3327Z",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{d:"M7.50004 8.33333C8.42052 8.33333 9.16671 7.58714 9.16671 6.66667C9.16671 5.74619 8.42052 5 7.50004 5C6.57957 5 5.83337 5.74619 5.83337 6.66667C5.83337 7.58714 6.57957 8.33333 7.50004 8.33333Z",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{d:"M2.22498 15.7918L6.33331 13.0335C6.99164 12.5918 7.94164 12.6418 8.53331 13.1501L8.80831 13.3918C9.45831 13.9501 10.5083 13.9501 11.1583 13.3918L14.625 10.4168C15.275 9.85846 16.325 9.85846 16.975 10.4168L18.3333 11.5835",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"})],-1),ONe={key:0},INe=b("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},[b("path",{d:"M1.66663 18.334H18.3333",stroke:"#525866","stroke-width":"1.5","stroke-miterlimit":"10","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{d:"M8.125 3.33268V18.3327H11.875V3.33268C11.875 2.41602 11.5 1.66602 10.375 1.66602H9.625C8.5 1.66602 8.125 2.41602 8.125 3.33268Z",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{d:"M2.5 8.33268V18.3327H5.83333V8.33268C5.83333 7.41602 5.5 6.66602 4.5 6.66602H3.83333C2.83333 6.66602 2.5 7.41602 2.5 8.33268Z",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{d:"M14.1666 12.5007V18.334H17.5V12.5007C17.5 11.584 17.1666 10.834 16.1666 10.834H15.5C14.5 10.834 14.1666 11.584 14.1666 12.5007Z",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"})],-1),ANe={class:"fcom_composer_actions"};function NNe(e,t,n,o,r,s){var y,v,w,_,S,x,E,T,O;const i=re("MarkdownEditor"),l=re("SurveyEditForm"),a=pt,u=re("media-preview"),c=Ne,d=re("image-uploader"),f=re("video-embeder"),p=re("EmojiPicker"),h=re("Giphy"),m=zt("loading");return C(),M(fe,null,[b("div",pNe,[b("div",hNe,[he(e.$slots,"before_input"),k(i,{ref:"markdownEditor",hasEveyoneMention:n.hasEveyoneMention,placeholder:n.placeholder,onEditorCreated:t[0]||(t[0]=()=>{e.$emit("editorCreated")}),autofocus:n.autofocus,onHandleMediaUpload:s.uploadImage,defaultMentions:n.defaultMentions,mentionQuery:n.mentionQuery,autofocus_changed:n.autofocus_changed,modelValue:n.content.message,"onUpdate:modelValue":t[1]||(t[1]=P=>n.content.message=P)},null,8,["hasEveyoneMention","placeholder","autofocus","onHandleMediaUpload","defaultMentions","mentionQuery","autofocus_changed","modelValue"]),he(e.$slots,"after_input")]),n.content.survey?(C(),q(l,{key:0,onCancel:t[2]||(t[2]=P=>n.content.survey=null),form:n.content.survey},null,8,["form"])):(C(),M(fe,{key:1},[(v=(y=n.content)==null?void 0:y.media)!=null&&v.type?(C(),M("div",mNe,[k(a,{onClick:t[3]||(t[3]=P=>{n.content.media=null}),text:"",type:"danger"},{default:$(()=>[ne(A(e.$t("Remove Media")),1)]),_:1}),k(u,{media_item:n.content.media},null,8,["media_item"])])):(w=n.content)!=null&&w.meta?(C(),M("div",gNe,[(S=(_=n.content.meta)==null?void 0:_.media_items)!=null&&S.length?(C(!0),M(fe,{key:0},nt(n.content.meta.media_items,(P,N)=>(C(),M("div",{key:N},[P.type=="image"?(C(),M("div",vNe,[b("img",{class:"fcom_media_image",src:P.url,alt:e.$t("Media image")},null,8,yNe),k(a,{class:"fcom_media_images_cross_button",link:"",onClick:F=>n.content.meta.media_items.splice(N,1)},{default:$(()=>[ne(" x ")]),_:2},1032,["onClick"])])):W("",!0)]))),128)):((E=(x=n.content.meta)==null?void 0:x.media_preview)==null?void 0:E.type)=="image"||(O=(T=n.content.meta)==null?void 0:T.media_preview)!=null&&O.image?(C(),M("div",_Ne,[b("div",bNe,[b("img",{class:"fcom_media_image",src:n.content.meta.media_preview.image,alt:e.$t("Media Preview image")},null,8,wNe),k(a,{class:"fcom_media_images_cross_button",link:"",onClick:t[4]||(t[4]=P=>n.content.meta.media_preview=null)},{default:$(()=>[ne(" x ")]),_:1})])])):W("",!0)])):n.content.media_images&&n.content.media_images.length?(C(),M("div",CNe,[(C(!0),M(fe,null,nt(n.content.media_images,(P,N)=>(C(),M("div",{class:"fcrom_media_image",key:N},[b("img",{src:P.url,alt:e.$t("Media image")},null,8,kNe),k(a,{link:"",onClick:F=>n.content.media_images.splice(N,1)},{default:$(()=>[ne(" x ")]),_:2},1032,["onClick"])]))),128))])):s.checkHasImageForCommentsEdit(n.content)?(C(),M("div",SNe,[b("div",$Ne,[b("img",{src:n.content.media.media_url,alt:e.$t("Media image")},null,8,ENe),k(a,{link:"",onClick:t[5]||(t[5]=P=>s.removeImageFromComments())},{default:$(()=>[ne(" x ")]),_:1})])])):W("",!0)],64))]),He((C(),M("div",xNe,[b("div",MNe,[s.hasActiveApp?W("",!0):(C(),M(fe,{key:0},[e.appVars.features.max_media_per_post?(C(),q(d,{key:0,additionalData:{resize:!0,max_width:1e3},isMultiple:n.multipleMedia,onUploading:t[6]||(t[6]=()=>{r.uploading=!0}),onCompleted:t[7]||(t[7]=()=>{r.uploading=!1}),onUploaded:s.handleMediaUpload},{default:$(()=>[He((C(),q(a,{"aria-label":"Upload Media",text:""},{default:$(()=>[k(c,{class:"fcom_status_img_icon"},{default:$(()=>[TNe]),_:1}),r.uploading?(C(),M("span",ONe,A(e.$t("Uploading...")),1)):W("",!0)]),_:1})),[[m,r.uploading]])]),_:1},8,["isMultiple","onUploaded"])):W("",!0),n.videoApp&&e.hasFeature("video_embeder")?(C(),q(f,{key:1,onEmbeded:s.handleVideoAttachment},null,8,["onEmbeded"])):W("",!0),n.surveyApp&&e.hasFeature("has_survey_poll")?(C(),q(a,{key:2,"aria-label":"Create Poll",onClick:s.initSurveyForm,text:""},{default:$(()=>[k(c,{class:"fcom_apps_icon"},{default:$(()=>[INe]),_:1})]),_:1},8,["onClick"])):W("",!0),e.hasFeature("emoji_app")?(C(),q(p,{key:3,onEmojiSelected:s.insertEmoji},null,8,["onEmojiSelected"])):W("",!0),e.hasFeature("giphy_app")?(C(),q(h,{key:4,onSelectedGiphy:s.selectedGiphy},null,8,["onSelectedGiphy"])):W("",!0)],64))]),b("div",ANe,[he(e.$slots,"default")])])),[[m,r.uploading]])],64)}const yL=qe(fNe,[["render",NNe]]),PNe={name:"CommentReacts",components:{UserRouteLink:X0},data(){return{centerDialogVisible:!1,reactions:null,loading:!1}},props:{comment:{required:!0,default:null}},methods:{getReactions(){this.reactions||(this.loading=!0,this.$get("comments/"+this.comment.id+"/reactions").then(e=>{this.reactions=e.reactions}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1}))}}},LNe={style:{"margin-left":"5px"}},RNe={key:0},DNe={key:1},FNe={class:"fcom_user_lists"},VNe={key:2};function BNe(e,t,n,o,r,s){const i=lo,l=re("UserAvatar"),a=re("UserRouteLink"),u=ks,c=Po;return C(),q(c,{persistent:!1,placement:"bottom",title:e.$t("Likes"),width:200,trigger:"click",onShow:s.getReactions},{reference:$(()=>[b("span",LNe,A(n.comment.reactions_count),1)]),default:$(()=>[r.loading?(C(),M("div",RNe,[k(i,{animated:!0,rows:1})])):r.reactions?(C(),M("div",DNe,[k(u,{"max-height":"300px"},{default:$(()=>[b("ul",FNe,[(C(!0),M(fe,null,nt(r.reactions,d=>(C(),M("li",null,[d.xprofile?(C(),M(fe,{key:0},[k(l,{with_level:!1,xprofile:d.xprofile},null,8,["xprofile"]),k(a,{show_badge:!0,xprofile:d.xprofile},null,8,["xprofile"])],64)):W("",!0)]))),256))])]),_:1})])):(C(),M("div",VNe,[b("p",null,A(e.$t("Failed to load the list")),1)]))]),_:1},8,["title","onShow"])}const zNe=qe(PNe,[["render",BNe]]),jNe={name:"SingleComment",components:{FeedTextComposer:yL,MediaPreview:Mv},props:["comment"],emits:["deleted","updated","copyLink"],data(){return{working:!1,isEdit:!1}},methods:{deleteComment(){this.$confirm(this.$t("Are you sure you want to delete this comment and associate data?"),this.$t("Warning"),{confirmButtonText:this.$t("Delete"),cancelButtonText:this.$t("Cancel"),type:"warning"}).then(()=>{this.working=!0,this.$del("feeds/"+this.comment.post_id+"/comments/"+this.comment.id).then(e=>{this.$emit("deleted"),this.$notify.success(e.message)}).catch(e=>{this.$handleError(e)}).finally(()=>{this.working=!1})})},editComment(){this.working=!0,this.$get(`comments/${this.comment.id}`).then(e=>{Object.assign(this.comment,e.comment),this.isEdit=!0}).catch(e=>{this.$handleError(e)}).finally(()=>{this.working=!1,this.$refs.comment_actions.hide()})},updateComment(){this.comment.message&&(this.working=!0,this.isEdit=!0,this.$post(`feeds/${this.comment.post_id}/comments/${this.comment.id}`,{comment:this.comment.message,media_images:this.comment.media_images,meta:this.comment.meta}).then(e=>{this.$notify.success((e==null?void 0:e.message)||this.$t("Comment updated successfully")),Object.assign(this.comment,e.comment),this.comment.media_images=[]}).catch(e=>{this.$handleError(e)}).finally(()=>{this.isEdit=!1,this.working=!1}))},renderedComment(e){const n=/(?:https?:\/\/)?(?:www\.)?youtube\.com\/watch\?v=([a-zA-Z0-9_-]+)/.exec(e);if(n&&n[1]){let s=n[1];if(s){let i=`<div class="feed_media_ext_video"><iframe src="https://www.youtube.com/embed/${s}" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe></div>`;e+=i}}let o=window.location.origin,r=new RegExp(o,"g");return e=e.replace(/<a(.*?)href="(.*?)"(.*?)>/g,(s,i,l,a)=>l.match(r)?`<a${i}href="${l}"${a}>`:`<a${i}href="${l}" target="_blank"${a}>`),e},copyCommentLink(e){this.$emit("copyLink",e),this.$refs.comment_actions.hide()}}},HNe={key:0,class:"person_avatar"},UNe={class:"comment_wrap"},WNe={key:0,class:"comment_text"},KNe={class:"comment_text_head"},qNe={class:"comment_text_head_name"},GNe=["title"],YNe={style:{"margin-left":"auto"},class:"comment_actions"},ZNe={class:"actions_items"},JNe=["innerHTML"],XNe={key:0,class:"comment_text_media"},QNe={key:1,class:"comment_text"};function ePe(e,t,n,o,r,s){const i=re("UserAvatar"),l=re("UserRouteLink"),a=re("MoreFilled"),u=Ne,c=pt,d=Po,f=re("MediaPreview"),p=re("feed-text-composer"),h=zt("loading");return C(),M(fe,null,[n.comment.xprofile?(C(),M("div",HNe,[k(i,{with_level:!1,xprofile:n.comment.xprofile,is_rounded:!0},null,8,["xprofile"])])):W("",!0),He((C(),M("div",UNe,[r.isEdit?(C(),M("div",QNe,[k(p,{multipleMedia:!1,content:n.comment,autofocus:!0,onUpdated:t[5]||(t[5]=m=>r.isEdit=!1)},{default:$(()=>[b("div",null,[k(c,{onClick:t[3]||(t[3]=m=>r.isEdit=!1)},{default:$(()=>[ne(A(e.$t("Cancel")),1)]),_:1}),k(c,{type:"primary",onClick:t[4]||(t[4]=m=>s.updateComment(n.comment))},{default:$(()=>[ne(A(e.$t("Update")),1)]),_:1})])]),_:1},8,["content"])])):(C(),M("div",WNe,[b("div",KNe,[b("div",qNe,[k(l,{show_badge:!0,xprofile:n.comment.xprofile},null,8,["xprofile"])]),b("div",{title:n.comment.created_at,class:"comment_text_head_time"},A(e.humanDateDiff(n.comment.created_at)),9,GNe),b("div",YNe,[k(d,{persistent:!1,placement:"bottom",ref:"comment_actions",width:200,trigger:"click"},{reference:$(()=>[k(c,{"aria-label":e.$t("View comment actions"),class:"fcom_dot_menu",size:"small",text:""},{default:$(()=>[k(u,null,{default:$(()=>[k(a)]),_:1})]),_:1},8,["aria-label"])]),default:$(()=>[b("ul",ZNe,[b("li",{onClick:t[0]||(t[0]=m=>s.copyCommentLink(n.comment))},A(e.$t("Copy Link")),1),e.canEditComment(n.comment)?(C(),M("li",{key:0,onClick:t[1]||(t[1]=m=>s.editComment())},A(e.$t("Edit")),1)):W("",!0),e.canDeleteComment(n.comment)?(C(),M("li",{key:1,onClick:t[2]||(t[2]=m=>s.deleteComment())},A(e.$t("Delete")),1)):W("",!0)])]),_:1},512)])]),b("div",{class:"comment_text_body feed_md_content",innerHTML:s.renderedComment(n.comment.message_rendered)},null,8,JNe),n.comment.meta.media_preview?(C(),M("div",XNe,[k(f,{media_item:n.comment.meta.media_preview},null,8,["media_item"])])):W("",!0)])),he(e.$slots,"after_comment_text")])),[[h,r.working]])],64)}const tPe=qe(jNe,[["render",ePe]]),nPe={name:"IndividualCommentReply",components:{FeedTextComposer:yL,HeartIcon:vL,SingleComment:tPe,CommentReactions:zNe},props:["comment","comments"],data(){return{commenting:!0,replyingComment:{},newComment:{message:"",media_images:[]},saving:!1}},watch:{comment:{handler(){this.updateReplyingComment()},immediate:!0}},methods:{toggleCommentBox(){this.commenting=!this.commenting},toggleLike(e){this.$emit("toggleLike",e)},postComment(){if(!this.newComment.message){this.$notify({title:this.$t("Error"),message:this.$t("Please write a reply first"),type:"error"});return}this.saving=!0,this.$post("feeds/"+this.comment.post_id+"/comments",{comment:this.newComment.message,parent_id:this.comment.id,media_images:this.newComment.media_images}).then(e=>{this.comment.comments.push(e.comment),this.newComment={message:"",media_images:[]}}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})},updateReplyingComment(){this.comment.parent_id&&this.comments?(this.replyingComment=this.comments.find(e=>e.id===parseInt(this.comment.parent_id))||this.comment,this.replyingComment.comments=this.comments.filter(e=>parseInt(e.parent_id)===this.replyingComment.id)):this.replyingComment=this.comment}},mounted(){this.updateReplyingComment()}},oPe={class:"fcom_course_comment each_comment"},rPe={key:0,class:"person_avatar"},sPe=["src","alt"],iPe={class:"comment_wrap"},lPe={class:"comment_text"},aPe={class:"comment_text_head"},uPe={class:"comment_text_head_name"},cPe={class:"comment_text_head_time"},dPe=["innerHTML"],fPe={class:"reply_box"},pPe={class:"fcom_comments_react"},hPe={class:"child_comments"},mPe=["id"],gPe={class:"reply_box"},vPe=["onClick"],yPe={class:"fcom_comments_react fcom_reaction_list"},_Pe={key:0,class:"child_reply_wrap"},bPe={class:"feed_commenting"},wPe={class:"person_avatar"},CPe=["src"],kPe={class:"feed_comment_input comment_text"};function SPe(e,t,n,o,r,s){const i=re("UserRouteLink"),l=re("HeartIcon"),a=Ne,u=re("CommentReactions"),c=re("single-comment"),d=pt,f=re("FeedTextComposer"),p=zt("loading");return C(),M("div",oPe,[r.replyingComment.xprofile?(C(),M("div",rPe,[b("img",{src:r.replyingComment.xprofile.avatar,alt:e.$t("avatar")},null,8,sPe)])):W("",!0),b("div",iPe,[b("div",lPe,[b("div",aPe,[b("div",uPe,[k(i,{xprofile:r.replyingComment.xprofile},null,8,["xprofile"])]),b("div",cPe,A(e.humanDateDiff(r.replyingComment.created_at)),1)]),b("div",{class:"comment_text_body",innerHTML:r.replyingComment.message_rendered},null,8,dPe)]),b("div",fPe,[b("span",{onClick:t[0]||(t[0]=(...h)=>s.toggleCommentBox&&s.toggleCommentBox(...h)),class:"reply_btn"},A(e.$t("Reply")),1),b("span",{style:{"margin-left":"14px"},class:D([{fcom_is_liked:r.replyingComment.liked},"reply_btn"])},[b("div",pPe,[k(a,{class:D({user_reacted:r.replyingComment.liked}),onClick:t[1]||(t[1]=h=>s.toggleLike(n.comment))},{default:$(()=>[k(l,{filled:r.replyingComment.liked},null,8,["filled"])]),_:1},8,["class"]),parseInt(r.replyingComment.reactions_count)?(C(),q(u,{key:0,comment:n.comment},null,8,["comment"])):W("",!0)])],2)]),b("div",hPe,[(C(!0),M(fe,null,nt(r.replyingComment.comments,(h,m)=>(C(),M("div",{id:"comment_"+h.id,class:"each_comment"},[k(c,{onDeleted:y=>e.handleCommentDelete(m),comment:h},{after_comment_text:$(()=>[b("div",gPe,[b("span",{onClick:y=>s.toggleCommentBox(h),class:"reply_btn"},A(e.$t("Reply")),9,vPe),b("span",{style:{"margin-left":"14px"},class:D([{fcom_is_liked:h.liked},"reply_btn"])},[b("div",yPe,[k(a,{class:D({user_reacted:h.liked}),onClick:y=>s.toggleLike(h)},{default:$(()=>[k(l,{filled:h.liked},null,8,["filled"])]),_:2},1032,["class","onClick"]),parseInt(h.reactions_count)?(C(),q(u,{key:0,comment:h},null,8,["comment"])):W("",!0)])],2)])]),_:2},1032,["onDeleted","comment"])],8,mPe))),256))]),r.commenting?(C(),M("div",_Pe,[b("div",bPe,[b("div",wPe,[b("img",{alt:"",src:e.auth.avatar},null,8,CPe)]),b("div",kPe,[k(f,{mentionQuery:{space_id:r.replyingComment.space_id},autofocus_changed:r.commenting,autofocus:r.commenting,disabled:r.saving,placeholder:e.$t("Write a reply"),content:r.newComment},{default:$(()=>[He((C(),q(d,{disabled:r.saving,class:"fcom_primary_button",onClick:t[2]||(t[2]=h=>s.postComment())},{default:$(()=>[ne(A(e.$t("Reply")),1)]),_:1},8,["disabled"])),[[p,r.saving]])]),_:1},8,["mentionQuery","autofocus_changed","autofocus","disabled","placeholder","content"])])])])):W("",!0)])])}const $Pe=qe(nPe,[["render",SPe]]),EPe={name:"CourseComments",props:["course"],components:{IndividualCommentReply:$Pe,Pagination:gL,ChatIcon:CAe,HeartIcon:vL},data(){return{comments:[],loading:!0,pagination:{page:1,per_page:10,total:0},working:!1,replyingComemnt:null,isReplying:!1}},methods:{fetchComments(){this.loading=!0,this.$get("admin/courses/"+this.course.id+"/comments",{page:this.pagination.page,per_page:this.pagination.per_page}).then(e=>{this.comments=e.comments.data,this.pagination.total=e.comments.total,window.scrollTo(0,0)}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},toggleLike(e){const t=!e.liked;this.$post("feeds/"+e.post_id+"/comments/"+e.id+"/reactions",{state:t?1:0}).then(n=>{e.liked=n.liked,e.reactions_count=n.reactions_count}).catch(n=>{this.$handleError(n)})},deleteComment(e,t){this.$confirm(this.$t("Are you sure you want to delete this comment and associate data?"),"Warning",{confirmButtonText:this.$t("Delete"),cancelButtonText:this.$t("Cancel"),type:"warning"}).then(()=>{this.working=!0,this.$del("feeds/"+e.post_id+"/comments/"+e.id).then(n=>{this.comments.splice(t,1),this.$notify.success(n.message)}).catch(n=>{this.$handleError(n)}).finally(()=>{this.working=!1})})},initCommentReply(e){this.replyingComemnt=e,this.$nextTick(()=>{this.isReplying=!0})}},mounted(){this.fetchComments()}},xPe={key:0,class:"white_loaded"},MPe={class:"fcom_course_comments_header"},TPe={key:0},OPe={class:"course_comments feed_comments overview_comments"},IPe={key:0,class:"person_avatar"},APe={class:"comment_wrap"},NPe={class:"comment_text"},PPe={class:"comment_text_head"},LPe={class:"comment_text_head_name"},RPe={class:"comment_text_head_time"},DPe={class:"comment_actions"},FPe={class:"actions_items"},VPe=["onClick"],BPe={class:"comment_text_details"},zPe=["href"],jPe=["innerHTML"],HPe={class:"comment_text_actions"},UPe={key:0},WPe={key:1};function KPe(e,t,n,o,r,s){const i=lo,l=re("UserAvatar"),a=re("UserRouteLink"),u=re("MoreFilled"),c=Ne,d=pt,f=Po,p=re("ChatIcon"),h=re("HeartIcon"),m=re("pagination"),y=re("IndividualCommentReply"),v=Ql,w=zt("loading");return r.loading?(C(),M("div",xPe,[k(i,{row:5})])):(C(),M(fe,{key:1},[b("div",MPe,[r.pagination.total?(C(),M("h5",TPe,A(e.$t("Comments (%s)",r.pagination.total)),1)):W("",!0)]),b("div",OPe,[(C(!0),M(fe,null,nt(r.comments,(_,S)=>(C(),M("div",{key:_.id,class:"fcom_course_comment each_comment"},[_.xprofile?(C(),M("div",IPe,[k(l,{with_level:!1,xprofile:_.xprofile},null,8,["xprofile"])])):W("",!0),b("div",APe,[b("div",NPe,[b("div",PPe,[b("div",LPe,[k(a,{xprofile:_.xprofile},null,8,["xprofile"])]),b("div",RPe,A(e.humanDateDiff(_.created_at)),1),He((C(),M("div",DPe,[e.canDeleteComment(_)?(C(),q(f,{key:0,persistent:!1,placement:"bottom",width:200,trigger:"click"},{reference:$(()=>[k(d,{"aria-label":e.$t("View actions"),class:"fcom_dot_menu",text:""},{default:$(()=>[k(c,null,{default:$(()=>[k(u)]),_:1})]),_:1},8,["aria-label"])]),default:$(()=>[b("ul",FPe,[b("li",{onClick:x=>s.deleteComment(_,S)},"Delete",8,VPe)])]),_:2},1024)):W("",!0)])),[[w,r.working]])]),b("div",BPe,[b("a",{href:e.$getRouteLink("course/:course_slug/lessons/:lesson_slug/view?comment_id=:comment_id&show_comments=true",{course_slug:n.course.slug,lesson_slug:_.post.slug,comment_id:_.id})},[ne(A(e.$t("Commented in"))+" ",1),b("b",null,A(e.getExcerpt(_.post.title,60)),1)],8,zPe)]),b("div",{class:"comment_text_body",innerHTML:_.message_rendered},null,8,jPe),b("div",HPe,[k(d,{onClick:x=>s.initCommentReply(_),text:""},{default:$(()=>[k(c,null,{default:$(()=>[k(p)]),_:1}),b("span",null,A(e.$t("Reply")),1)]),_:2},1032,["onClick"]),k(d,{text:""},{default:$(()=>[k(c,{class:D({user_reacted:_.liked}),onClick:x=>s.toggleLike(_)},{default:$(()=>[k(h,{filled:_.liked},null,8,["filled"])]),_:2},1032,["class","onClick"]),b("span",null,A(_.reactions_count||""),1)]),_:2},1024)])])])]))),128)),r.pagination.total?W("",!0):(C(),M("div",UPe,[b("h5",null,A(e.$t("No comments from any lessons yet! Comments from all the lessons will be shown here")),1)]))]),k(m,{pagination:r.pagination,onFetch:s.fetchComments},null,8,["pagination","onFetch"]),k(v,{"append-to-body":!0,modelValue:r.isReplying,"onUpdate:modelValue":t[0]||(t[0]=_=>r.isReplying=_),size:e.dialogWidth},{header:$(()=>{var _;return[b("p",null,[ne(A(e.$t("Replying to"))+" ",1),b("b",null,A((_=r.replyingComemnt)==null?void 0:_.post.title),1)])]}),default:$(()=>[r.replyingComemnt?(C(),q(y,{key:0,comment:r.replyingComemnt,comments:r.comments,onToggleLike:s.toggleLike},null,8,["comment","comments","onToggleLike"])):(C(),M("h3",WPe,A(e.$t("Replying to Let's check this out! Let's do it Replying to Let's check this out! Let's do it")),1))]),_:1},8,["modelValue","size"])],64))}const qPe=qe(EPe,[["render",KPe]]),GPe={name:"CourseOverview",props:["course","course_id"],components:{CourseComments:qPe}},YPe={class:"fcom_cards fcom_cards_2"},ZPe={class:"fcom_card"},JPe={class:"fcom_card_body"},XPe={class:"fcom_card"},QPe={class:"fcom_card_body"};function eLe(e,t,n,o,r,s){const i=re("course-comments");return C(),M(fe,null,[b("div",YPe,[b("div",ZPe,[b("div",JPe,[b("p",null,A(e.$t("Students")),1),b("h3",null,A(n.course.students_count),1)])]),b("div",XPe,[b("div",QPe,[b("p",null,A(e.$t("Average completion rate")),1),b("h3",null,A(n.course.overAllProgress)+"%",1)])])]),k(i,{course:n.course},null,8,["course"])],64)}const tLe=qe(GPe,[["render",eLe]]),nLe={name:"SpaceIcon",props:["space_profile"]},oLe=["alt","src"],rLe={key:1,class:"fcom_emoji"},sLe={key:2,class:"fcom_shape"},iLe={key:3,class:"fcom_no_avatar"};function lLe(e,t,n,o,r,s){var l,a,u,c;const i=Ne;return n.space_profile.logo?(C(),M("img",{key:0,alt:e.$t("Space Logo"),src:n.space_profile.logo},null,8,oLe)):(l=n.space_profile.settings)!=null&&l.emoji?(C(),M("span",rLe,A((a=n.space_profile.settings)==null?void 0:a.emoji),1)):(u=n.space_profile.settings)!=null&&u.shape_svg?(C(),M("span",sLe,[k(i,{innerHTML:(c=n.space_profile.settings)==null?void 0:c.shape_svg},null,8,["innerHTML"])])):(C(),M("span",iLe))}const aLe=qe(nLe,[["render",lLe]]),uLe={name:"AllTopics",components:{SlugInput:Pk,SpaceIcon:aLe,Layout:ri,AppLayout:si},data(){return{topics:[],saving:!1,loading:!1,search:"",showModal:!1,editing_topic:{title:"",slug:"",space_ids:[],admin_only:"no"},all_spaces:[],formattedSpaceGroups:{}}},methods:{updateTopic(){this.saving=!0,this.$post("admin/topics",this.editing_topic).then(e=>{this.$notify.success(e.message),this.fetch(),this.showModal=!1}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})},showForm(e){this.editing_topic=e||{title:"",slug:"",space_ids:[],admin_only:"no"},this.showModal=!0},fetch(){this.loading=!0,this.$get("admin/topics",{search:this.search}).then(e=>{this.topics=e.topics,this.all_spaces=e.all_spaces,this.formatSpaceGroups()}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},removeTopic(e){this.$confirm(this.$t("Are you sure you want to remove this topic?"),this.$t("Warning"),{confirmButtonText:this.$t("Yes, Remove"),cancelButtonText:this.$t("Cancel"),type:"warning"}).then(()=>{this.saving=!0,this.$del("admin/topics/"+e.id).then(t=>{this.$notify.success(t.message),this.fetch()}).catch(t=>{this.$handleError(t)}).finally(()=>{this.saving=!1})})},formatSpaceGroups(){let e=this.all_spaces,t=this.appVars.space_groups,n=[],o=[];this.each(t,r=>{let s=e.filter(i=>{let l=i.parent_id==r.id;return l&&o.push(i.slug),l});s.length&&n.push({label:r.title,spaces:s})}),this.formattedSpaceGroups=n},formatTopics(e){let t=this.all_spaces,n=[];return e.forEach(o=>{let r=t.find(s=>s.id==o);r&&n.push(r.title)}),n.join(", ")}},mounted(){this.has_pro&&this.fetch(),this.changeTitle(this.$t("Topics Settings"))}},cLe=["href"],dLe={class:""},fLe={class:"fhr_content_layout_body"},pLe={key:0},hLe={style:{"margin-bottom":"10px"},class:"fcom_manager_actions"},mLe={class:"bulk_search"},gLe=b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},[b("path",{d:"M14.5833 14.584L18.3333 18.334",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{d:"M16.6667 9.16699C16.6667 5.02486 13.3088 1.66699 9.16666 1.66699C5.02453 1.66699 1.66666 5.02486 1.66666 9.16699C1.66666 13.3091 5.02453 16.667 9.16666 16.667C13.3088 16.667 16.6667 13.3091 16.6667 9.16699Z",stroke:"currentColor","stroke-width":"1.5","stroke-linejoin":"round"})],-1),vLe={class:"fcom_table_action_col"},yLe={key:1,class:"setting_body",style:{"text-align":"center"}},_Le=b("p",null,"Create Post Topic and assign to your spaces. Then users can choose one or multiple topic for each post. This feature is available on the premium version of FluentCommunity. Please upgrade to pro",-1),bLe=["href"],wLe={class:"dialog_header"},CLe={class:"dialog_left"},kLe=b("div",{class:"header_icon"},[b("svg",{viewBox:"0 0 24 24",width:"20",height:"20",color:"currentColor",fill:"none"},[b("path",{d:"M2.73552 11.6867C1.78253 12.7511 1.76203 14.3569 2.63665 15.4865C4.37226 17.7281 6.2719 19.6277 8.51351 21.3633C9.64313 22.238 11.2489 22.2175 12.3133 21.2645C15.203 18.6771 17.8494 15.9731 20.4033 13.0016C20.6558 12.7078 20.8137 12.3477 20.8492 11.9619C21.0059 10.2561 21.3279 5.34144 19.9932 4.00675C18.6586 2.67207 13.7439 2.99408 12.0381 3.15083C11.6523 3.18627 11.2922 3.34421 10.9984 3.59671C8.02692 6.15064 5.32291 8.797 2.73552 11.6867Z",stroke:"currentColor","stroke-width":"1.5"}),b("path",{opacity:"0.4",d:"M7.5 14.5L9.5 16.5",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{d:"M18 6L22 2",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round"})])],-1),SLe={key:0,class:"dialog_body"},$Le={key:0,class:"fcom_space_title"},ELe={key:0},xLe={key:1},MLe={class:"fcom_help_text"};function TLe(e,t,n,o,r,s){const i=re("Plus"),l=Ne,a=pt,u=At,c=Y0,d=G0,f=re("layout"),p=re("app-layout"),h=io,m=re("slug-input"),y=re("SpaceIcon"),v=Ss,w=xae,_=vr,S=Hn,x=so,E=yh,T=zt("loading");return C(),M(fe,null,[k(p,{wrapper_class:"fcom_single_layout fcom_member_profile fcom_max_layout"},{default:$(()=>[k(f,{wrapper_class:"no_bg_layout fcom_setting_route",title:e.$t("Topics")},{actions:$(()=>[e.has_pro?(C(),q(a,{key:0,class:"fcom_primary_button",onClick:t[0]||(t[0]=O=>s.showForm(null))},{default:$(()=>[k(l,null,{default:$(()=>[k(i)]),_:1}),b("span",null,A(e.$t("New Topic")),1)]),_:1})):(C(),M("a",{key:1,target:"_blank",rel:"noopener",href:e.appVars.upgrade_url,class:"el-button el-button--danger"},A(e.$t("Upgrade to Pro")),9,cLe))]),default:$(()=>[b("div",dLe,[b("div",fLe,[e.has_pro?(C(),M("div",pLe,[b("p",null,A(e.$t("Categorize your content and allow members to filter posts with the topic navigation bar in spaces.")),1),b("div",hLe,[b("div",mLe,[k(u,{modelValue:r.search,"onUpdate:modelValue":t[1]||(t[1]=O=>r.search=O),onKeydown:Pt(s.fetch,["enter"]),placeholder:e.$t("Search"),class:"el-input-round"},{prefix:$(()=>[gLe]),_:1},8,["modelValue","onKeydown","placeholder"])])]),He((C(),q(d,{data:r.topics},{default:$(()=>[k(c,{label:e.$t("Title"),"min-width":"160"},{default:$(O=>[ne(A(O.row.title),1)]),_:1},8,["label"]),k(c,{label:e.$t("Spaces"),"min-width":"200"},{default:$(O=>[b("span",null,A(s.formatTopics(O.row.space_ids)),1)]),_:1},8,["label"]),k(c,{label:e.$t("Admin Only?"),width:"140"},{default:$(O=>[b("span",null,A(O.row.admin_only=="yes"?e.$t("Yes"):e.$t("No")),1)]),_:1},8,["label"]),k(c,{label:e.$t("Actions"),width:"180"},{default:$(O=>[b("div",vLe,[k(a,{onClick:P=>s.showForm(O.row),size:"small"},{default:$(()=>[ne(A(e.$t("Edit")),1)]),_:2},1032,["onClick"]),k(a,{onClick:P=>s.removeTopic(O.row),type:"danger",plain:"",size:"small"},{default:$(()=>[ne(A(e.$t("Remove")),1)]),_:2},1032,["onClick"])])]),_:1},8,["label"])]),_:1},8,["data"])),[[T,r.loading]])])):(C(),M("div",yLe,[_Le,b("a",{target:"_blank",rel:"noopener",href:e.appVars.upgrade_url,class:"el-button el-button--danger"},A(e.$t("Upgrade to Pro")),9,bLe)]))])])]),_:1},8,["title"])]),_:1}),k(E,{"modal-class":"fcom_common_dialog",id:"fluent_comminity_body","close-on-click-modal":!1,"append-to-body":!0,width:e.dialogWidth,modelValue:r.showModal,"onUpdate:modelValue":t[8]||(t[8]=O=>r.showModal=O),direction:"rtl"},{header:$(({close:O})=>[b("div",wLe,[b("div",CLe,[kLe,b("div",null,[b("h4",null,A(e.$t(r.editing_topic.id?"Update Tipic":"Add Topic")),1)])])])]),default:$(()=>[r.showModal?(C(),M("div",SLe,[k(x,{onSubmit:t[6]||(t[6]=et(O=>e.doNothing(),["prevent"])),modelValue:r.editing_topic,"onUpdate:modelValue":t[7]||(t[7]=O=>r.editing_topic=O),"label-position":"top"},{default:$(()=>[k(h,{label:e.$t("Topic Title")},{default:$(()=>[k(u,{placeholder:e.$t("Title of your topic"),modelValue:r.editing_topic.title,"onUpdate:modelValue":t[2]||(t[2]=O=>r.editing_topic.title=O),type:"text"},null,8,["placeholder","modelValue"])]),_:1},8,["label"]),k(h,{label:e.$t("Topic Slug")},{default:$(()=>[k(m,{disabled:!!r.editing_topic.id,modelValue:r.editing_topic.slug,"onUpdate:modelValue":t[3]||(t[3]=O=>r.editing_topic.slug=O),placeholder:e.$t("Slug of your topic")},null,8,["disabled","modelValue","placeholder"])]),_:1},8,["label"]),k(h,{label:e.$t("Space visibility")},{default:$(()=>[k(_,{modelValue:r.editing_topic.space_ids,"onUpdate:modelValue":t[4]||(t[4]=O=>r.editing_topic.space_ids=O),multiple:"",placeholder:e.$t("Select Spaces"),style:{width:"100%"}},{default:$(()=>[(C(!0),M(fe,null,nt(r.formattedSpaceGroups,O=>(C(),q(w,{key:O.label,label:O.label},{default:$(()=>[(C(!0),M(fe,null,nt(O.spaces,P=>(C(),q(v,{key:P.slug,label:P.title,value:P.id.toString()},{default:$(()=>[P.id?(C(),M("span",$Le,[k(y,{space_profile:P},null,8,["space_profile"]),b("span",null,[ne(A(e.getExcerpt(P.title,50))+" ",1),P.type=="course"?(C(),M("span",ELe," ("+A(e.$t("course"))+")",1)):W("",!0)])])):(C(),M("span",xLe,A(e.getExcerpt(P.title,50)),1))]),_:2},1032,["label","value"]))),128))]),_:2},1032,["label"]))),128))]),_:1},8,["modelValue","placeholder"]),b("div",MLe,[b("p",null,A(e.$t("Select spaces where this topic will be visible.")),1)])]),_:1},8,["label"]),k(h,null,{default:$(()=>[k(S,{modelValue:r.editing_topic.admin_only,"onUpdate:modelValue":t[5]||(t[5]=O=>r.editing_topic.admin_only=O),"true-value":"yes","false-value":"no"},{default:$(()=>[ne(A(e.$t("Only admins and moderators can select this topic")),1)]),_:1},8,["modelValue"])]),_:1}),k(h,null,{default:$(()=>[He((C(),q(a,{type:"primary",onClick:s.updateTopic,disabled:r.saving},{default:$(()=>[ne(A(e.$t("Save")),1)]),_:1},8,["onClick","disabled"])),[[T,r.saving]])]),_:1})]),_:1},8,["modelValue"])])):W("",!0)]),_:1},8,["width","modelValue"])],64)}const OLe=qe(uLe,[["render",TLe]]),ILe=[{path:"/settings",component:kfe,meta:{active_menu:"settings"},children:[{name:"settings",path:"",component:dhe,meta:{active_menu:"settings"}},{name:"customization",path:"customization",component:kSe,meta:{active_menu:"settings"}},{name:"admin_moderators",path:"moderators",component:G0e,meta:{active_menu:"settings"}},{name:"email_notifications",path:"email-notifications",component:J8e,meta:{active_menu:"settings"}},{name:"features",path:"features",component:_7e,meta:{active_menu:"settings"}},{name:"menu_settings",path:"menu-settings",component:axe,meta:{active_menu:"settings"}},{path:"space_groups",name:"space_groups",component:tMe,meta:{active_menu:"settings"}},{path:"topics-settings",name:"all_topics",component:OLe,meta:{active_menu:"settings"}}]},{path:"/manage-courses",component:VMe,name:"manage_courses",meta:{active_menu:"manage_courses"}},{path:"/manage-courses/edit/:course_id",component:NOe,props:!0,meta:{active_menu:"manage_courses"},children:[{name:"edit_lessons",path:"lessons",component:ZIe,props:!0,meta:{active_menu:"manage_courses"}},{name:"course_students",path:"students",component:mAe,props:!0,meta:{active_menu:"manage_courses"}},{name:"course_overview",path:"overview",component:tLe,props:!0,meta:{active_menu:"manage_courses"}}]}],ALe={name:"VerifiedSign"},NLe={class:"fcom_verified"},PLe=b("svg",{viewBox:"0 0 22 22","aria-label":"Verified account",role:"img","data-testid":"icon-verified"},[b("g",null,[b("path",{d:"M20.396 11c-.018-.646-.215-1.275-.57-1.816-.354-.54-.852-.972-1.438-1.246.223-.607.27-1.264.14-1.897-.131-.634-.437-1.218-.882-1.687-.47-.445-1.053-.75-1.687-.882-.633-.13-1.29-.083-1.897.14-.273-.587-.704-1.086-1.245-1.44S11.647 1.62 11 1.604c-.646.017-1.273.213-1.813.568s-.969.854-1.24 1.44c-.608-.223-1.267-.272-1.902-.14-.635.13-1.22.436-1.69.882-.445.47-.749 1.055-.878 1.688-.13.633-.08 1.29.144 1.896-.587.274-1.087.705-1.443 1.245-.356.54-.555 1.17-.574 1.817.02.647.218 1.276.574 1.817.356.54.856.972 1.443 1.245-.224.606-.274 1.263-.144 1.896.13.634.433 1.218.877 1.688.47.443 1.054.747 1.687.878.633.132 1.29.084 1.897-.136.274.586.705 1.084 1.246 1.439.54.354 1.17.551 1.816.569.647-.016 1.276-.213 1.817-.567s.972-.854 1.245-1.44c.604.239 1.266.296 1.903.164.636-.132 1.22-.447 1.68-.907.46-.46.776-1.044.908-1.681s.075-1.299-.165-1.903c.586-.274 1.084-.705 1.439-1.246.354-.54.551-1.17.569-1.816zM9.662 14.85l-3.429-3.428 1.293-1.302 2.072 2.072 4.4-4.794 1.347 1.246z"})])],-1),LLe=[PLe];function RLe(e,t,n,o,r,s){return C(),M("span",NLe,LLe)}const DLe=qe(ALe,[["render",RLe]]),FLe={name:"UserBadge",props:["badge","is_preview","profile"],computed:{renderingBadge(){var e;if(!this.appVars.user_badges&&!this.is_preview)return null;if(this.profile){let t=this.profile.badge_slug;return t||(t=(e=this.profile.meta)==null?void 0:e.badge_slug),t?this.appVars.user_badges[t]:null}return this.badge}}},VLe=["title"],BLe=["src"],zLe={key:1,class:"fcom_emoji"},jLe={key:2,class:"fcom_shape"},HLe={key:1};function ULe(e,t,n,o,r,s){const i=Ne;return s.renderingBadge?(C(),M("div",{key:0,class:D([{user_icon_only:s.renderingBadge.show_label!="yes"},"user_badge"])},[b("div",{style:Qe({backgroundColor:s.renderingBadge.background_color,color:s.renderingBadge.color,borderColor:s.renderingBadge.color}),title:s.renderingBadge.title,class:"user_badge_inner"},[s.renderingBadge.config?(C(),M(fe,{key:0},[s.renderingBadge.config.logo?(C(),M("img",{key:0,alt:"",src:s.renderingBadge.config.logo},null,8,BLe)):s.renderingBadge.config.emoji?(C(),M("span",zLe,A(s.renderingBadge.config.emoji),1)):s.renderingBadge.config.shape_svg?(C(),M("span",jLe,[k(i,{innerHTML:s.renderingBadge.config.shape_svg},null,8,["innerHTML"])])):W("",!0)],64)):W("",!0),s.renderingBadge.show_label=="yes"?(C(),M("span",HLe,A(s.renderingBadge.title),1)):W("",!0)],12,VLe)],2)):W("",!0)}const WLe=qe(FLe,[["render",ULe]]),KLe={name:"WelcomeBanner",components:{MediaPreview:Mv},data(){return{config:this.appVars.welcome_banner}},computed:{showMedia(){return this.config&&this.config.mediaType=="video"&&this.config.bannerVideo},showCtaButtons(){var e;return this.config&&((e=this.config.ctaButtons)==null?void 0:e.length)&&this.config.ctaButtons.some(t=>t.link&&t.label)},isRemovable(){return this.config&&this.config.allowClose=="yes"},showBanner(){if(!this.isRemovable)return!0;let e=this.Storage.get(this.getCloseKey,!1);return e?new Date().getTime()>e:!0},getCloseKey(){return this.appVars.user_id?"fcom_welcome_banner_closed_auth":"fcom_welcome_banner_closed_guest"}},methods:{closeBanner(){this.config=null;let e=new Date().getTime()+7*24*60*60*1e3;this.Storage.set(this.getCloseKey,e)}}},qLe={key:0,class:"fcom_welcome_box"},GLe={key:2,class:"fcom_welcome_title"},YLe=["innerHTML"],ZLe={key:4,class:"fcom_welcome_cta_buttons"},JLe=["href","target"];function XLe(e,t,n,o,r,s){const i=re("media-preview"),l=Ed,a=re("MoreFilled"),u=Ne,c=pt,d=bh,f=wh,p=_h;return r.config&&s.showBanner?(C(),M("div",qLe,[s.showMedia?(C(),q(i,{key:0,media_item:r.config.bannerVideo},null,8,["media_item"])):r.config.bannerImage?(C(),q(l,{key:1,class:"feed_media",alt:e.$t("Image Preview"),src:r.config.bannerImage},null,8,["alt","src"])):W("",!0),r.config.title?(C(),M("h2",GLe,A(r.config.title),1)):W("",!0),r.config.description_rendered?(C(),M("div",{key:3,class:"fcom_welcome_sub",innerHTML:r.config.description_rendered},null,8,YLe)):W("",!0),s.showCtaButtons?(C(),M("div",ZLe,[(C(!0),M(fe,null,nt(r.config.ctaButtons,h=>(C(),M(fe,null,[h.link&&h.label?(C(),M("a",{key:0,href:h.link,target:h.newTab=="yes"?"_blank":"_self",class:D({"el-button fcom_primary_button":h.type=="primary","el-button fcom_secondary_button":h.type=="secondary","el-button is-text":h.type=="text","el-link fcom_link_button":h.type=="link"})},A(h.label),11,JLe)):W("",!0)],64))),256))])):W("",!0),s.isRemovable?(C(),q(p,{key:5,trigger:"click",class:"fcom_welcome_close"},{dropdown:$(()=>[k(f,null,{default:$(()=>[k(d,{onClick:s.closeBanner},{default:$(()=>[ne(A(e.$t("Hide Banner")),1)]),_:1},8,["onClick"])]),_:1})]),default:$(()=>[k(c,{"aria-label":e.$t("Hide Banner"),class:"fcom_dot_menu",size:"small",text:""},{default:$(()=>[k(u,null,{default:$(()=>[k(a)]),_:1})]),_:1},8,["aria-label"])]),_:1})):W("",!0)])):W("",!0)}const QLe=qe(KLe,[["render",XLe]]);Yd(()=>Promise.resolve().then(()=>$Fe),void 0);const eRe=[BY,rZ,uZ,BZ,tJ,bZ,$Z,sJ,AY,RY,nM,eM,AZ,MY,xZ,N0,Qx,kZ,c3,js,oJ,au,Su,jY,Y_,lJ,dZ,vZ,WZ,EY,YY,RZ,u3,hZ,OY,XY,PZ,Xx,tM,l3];function ap(e){const t=[];if(typeof e=="object"&&e.join===void 0)for(const n in e)t.push(ap(e[n]));else if(typeof e=="object"&&e.join!==void 0)for(const n in e)t.push(ap(e[n]));else typeof e=="function"||typeof e=="string"&&t.push(e);return t.join("<br />")}const Wn=ww(bfe);Wn.use(Ode);Wn.config.globalProperties.appVars=window.fluentComAdmin;Wn.config.globalProperties.auth=window.fluentComAdmin.auth;Wn.config.globalProperties.has_pro=!!window.fluentComAdmin.pro;let N2="40%",P2="60%";window.innerWidth<600?(P2="95%",N2="90%"):window.innerWidth<800&&(P2="80%",N2="80%");eRe.forEach(e=>{Wn.component(e.name,e)});Wn.component("VerifiedSign",DLe);Wn.component("UserAvatar",eI);Wn.component("UserRouteLink",X0);Wn.component("WelcomeBanner",QLe);Wn.component("UserBadge",WLe);function e$(){Wn.use(window.FluentCommunityUtil.eventBus);const e=window.FluentCommunityUtil.Rest;Wn.mixin({data(){return{Storage:window.FluentCommunityUtil.Storage,is_rtl:!1,drawerWidth:N2,dialogWidth:P2,feedMonitorCache:{},mounted:!1,isMobile:window.innerWidth<=768,has_leaderboard:this.appVars.features.leaderboard}},methods:{$get:e.get,$post:e.post,$uploadFile:e.uploadFile,$put:e.put,$del:e.delete,$patch:e.patch,changeTitle(r){document.title=r+" - "+this.appVars.site_title},$handleError(r){let s="";typeof r=="string"?s=r:r&&r.message?s=r.message:s=ap(r),s||(s="Something is wrong!"),typeof s!="string"&&(s=ap(s)),this.$notify({type:"error",title:"Error",message:s,dangerouslyUseHTMLString:!0})},convertToText:ap,$t(r){r=window.fluentComAdmin.i18n[r]||r;const s=Array.prototype.slice.call(arguments,1);if(s.length===0)return r;const i=/%(\d*)s|%d/g;let l=0;return r=r.replace(i,(a,u)=>{if(u){const c=parseInt(u,10)-1;return c<s.length?s[c]:a}else return l<s.length?s[l++]:a}),r},$_n(r,s,i){return i>1?this.$t(s,i):this.$t(r,i)},$labelize(r){return r?(r=r.charAt(0).toUpperCase()+r.slice(1),window.fluentComAdmin.i18n[r]?window.fluentComAdmin.i18n[r]:r.replace(/_/g," ").replace(/\b\w/g,s=>s.toUpperCase())):""},dayjs,relativeTimeFromUtc(r){return dayjs.utc(r).local().fromNow()},$storeLocalData(r,s){this.Storage.set(r,s)},$getLocalData(r,s=""){return this.Storage.get(r,s)},ucFirst(r){return r?r.charAt(0).toUpperCase()+r.slice(1):""},ucWords(r){return r?r.replace(/\b[a-z]/g,function(s){return s.toUpperCase()}):""},smartDate(r,s=!1,i=!1){if(!r)return"";let l="D MMM, YYYY";dayjs(r).isSame(new Date,"year")?(l="D MMM",s&&(Math.abs(dayjs(r).diff(new Date,"days"))<=5||i)&&(dayjs(r).minute()==0?l="D MMM, ha":l="D MMM, hh:mma")):s&&i&&(l="D MMM, YYYY, hh:mma");const a=dayjs(r);return a.isValid()?a.format(l):null},hasPermission(r){return this.appVars.permissions[r]},isAdmin(){return!!this.appVars.permissions.community_admin},canDeleteFeed(r){return this.auth.user_id&&(r.user_id==this.auth.user_id||this.hasPermission("delete_any_feed"))},canEditFeed(r){return this.auth.user_id&&(r.user_id==this.auth.user_id||this.hasPermission("edit_any_feed"))},canDeleteComment(r){return this.auth&&(r.user_id==this.auth.user_id||this.hasPermission("delete_any_comment"))},canEditComment(r){return this.auth.user_id&&(r.user_id==this.auth.user_id||this.hasPermission("edit_any_comment"))},hasSpaceAccess(r){return r?this.appVars.user_membership_slugs.indexOf(r)!==-1:!0},hasInPermission(r,s){return!s||typeof s!="object"?!1:s[r]},hasCurrentSpacePermission(r){return window.fcom_current_community?this.hasInPermission(r,window.fcom_current_community.permissions):!1},hasPermissionOrInCurrentSpace(r){return this.hasPermission(r)?!0:this.hasCurrentSpacePermission(r)},humanDateDiff(r){if(!r)return"";const s=dayjs.utc(r,"YYYY-MM-DD HH:mm:ss");if(!s.isValid())return"";const i=s.add(this.appVars.date_offset,"s");return dayjs(i.format("YYYY-MM-DD HH:mm:ss")).from(dayjs(dayjs.utc().format("YYYY-MM-DD HH:mm:ss")))},hasCommentPermission(r){var s;return this.auth.user_id?!r.space_id&&!r.course_id?this.auth.user_id&&(r.user_id==this.auth.user_id||r.privacy=="public"):this.hasSpaceAccess((s=r.space)==null?void 0:s.slug):!1},getExcerpt(r,s=250){if(!r)return"";let i=r.replace(/(<([^>]+)>)/ig,"");return i=i.replace(/(\*\*|__)(.*?)\1/g,"$2"),i=i.replace(/(#+)(.*)/g,"$2"),i=i.replace(/\[(.*?)\]\((.*?)\)/g,"$1"),i.length>s&&(i=i.substring(0,s)+"..."),i},$convertToBoolean(r){return r==="true"||r===!0||r===1||r==="1"||r==="yes"||r==="on"},each:cu,hasFeature(r){return this.appVars.features[r]},isCommunityModerator(){return window.fluentComAdmin.auth.community_roles.some(r=>r==="admin"||r==="moderator")},isSpaceModerator(r){var i,l;return["admin","moderator"].includes((l=(i=r.membership)==null?void 0:i.pivot)==null?void 0:l.role)},getCurrentAuthUrl(){let r=window.location.href,s=this.appVars.auth_url;return s=s.replace(/(\?|&)redirect_to=[^&]+/,""),s.indexOf("?")===-1?s+="?":s+="&",s+"redirect_to="+encodeURIComponent(r)},$formatNumber(r){return r&&r.toString().replace(/\B(?=(\d{3})+(?!\d))/g,",")},$getRouteLink(r,s={}){return cu(s,(i,l)=>{r=r.replace(":"+l,i)}),this.appVars.portal_url+r},isOnline(r){if(!r)return!1;const i=dayjs.utc(r,"YYYY-MM-DD HH:mm:ss").add(this.appVars.date_offset,"seconds").diff(dayjs.utc(),"minutes");return i<=5&&i>=0},doNothing(){console.log("OK")}},mounted(){window.fcom_mounted||(window.fcom_mounted=!0,this.isMobile&&dayjs.updateLocale("en",{relativeTime:{future:"in %s",past:"%s",s:"now",m:"1m",mm:"%dm",h:"1 h",hh:"%d h",d:"%dd",dd:"%dd",M:"1 mo",MM:"%d mo",y:"%d y",yy:"%d y"}}))}}),Wn.config.globalProperties.$notify=nfe,Wn.config.globalProperties.$confirm=fy.confirm,Wn.config.globalProperties.$promt=fy.prompt,Wn.config.globalProperties.$messageBox=fy,Wn.config.globalProperties.$gloablStorage={};const t=window.FluentCommunityUtil.hooks.applyFilters("fluent_com_portal_admin_routes",ILe);let n=null;window.fluentComAdmin.routing_system=="hash"?n=y6({routes:t,history:tj()}):n=y6({routes:t,history:ix(window.fluentComAdmin.portal_slug)});const o=window.FluentCommunityUtil.hooks.applyFilters("fluent_com_portal_admin_app",Wn);window.fluentFrameworkApp=o.use(n).mount("#fluent_com_portal"),window.fluentFrameworkAppRouter=n}window.FluentCommunityUtil?e$():document.addEventListener("fluentCommunityUtilReady",function(){e$()});var Fa,Pc;class tRe{constructor(t){xs(this,Fa,void 0);xs(this,Pc,new Set);Lo(this,Fa,t)}get current(){return kt(this,Fa)}set current(t){kt(this,Fa)!=t&&(Lo(this,Fa,t),kt(this,Pc).forEach(n=>n(t)))}on(t){return kt(this,Pc).add(t),()=>kt(this,Pc).delete(t)}}Fa=new WeakMap,Pc=new WeakMap;const _L=e=>new tRe(e),L2=Symbol.for("atomico.hooks");globalThis[L2]=globalThis[L2]||{};let md=globalThis[L2];const nRe=Symbol.for("Atomico.suspense"),bL=Symbol.for("Atomico.effect"),oRe=Symbol.for("Atomico.layoutEffect"),wL=Symbol.for("Atomico.insertionEffect"),Vh=(e,t,n)=>{const{i:o,hooks:r}=md.c,s=r[o]=r[o]||{};return s.value=e(s.value),s.effect=t,s.tag=n,md.c.i++,r[o].value},Rk=e=>Vh((t=_L(e))=>t),CL=()=>Vh((e=_L(md.c.host))=>e),kL=()=>md.c.update,rRe=(e,t,n=0)=>{let o={},r=!1;const s=()=>r,i=(u,c)=>{for(const d in o){const f=o[d];f.effect&&f.tag===u&&(f.value=f.effect(f.value,c))}};return{load:u=>{md.c={host:t,hooks:o,update:e,i:0,id:n};let c;try{r=!1,c=u()}catch(d){if(d!==nRe)throw d;r=!0}finally{md.c=null}return c},cleanEffects:u=>(i(wL,u),()=>(i(oRe,u),()=>{i(bL,u)})),isSuspense:s}},Bh=Symbol.for;function SL(e,t){const n=e.length;if(n!==t.length)return!1;for(let o=0;o<n;o++){let r=e[o],s=t[o];if(r!==s)return!1}return!0}const Ci=e=>typeof e=="function",up=e=>typeof e=="object",{isArray:sRe}=Array,R2=(e,t)=>(t?e instanceof HTMLStyleElement:!0)&&"hydrate"in((e==null?void 0:e.dataset)||{});function $L(e,t){let n;const o=r=>{let{length:s}=r;for(let i=0;i<s;i++){const l=r[i];if(l&&Array.isArray(l))o(l);else{const a=typeof l;if(l==null||a==="function"||a==="boolean")continue;a==="string"||a==="number"?(n==null&&(n=""),n+=l):(n!=null&&(t(n),n=null),t(l))}}};o(e),n!=null&&t(n)}const EL=(e,t,n)=>(e.addEventListener(t,n),()=>e.removeEventListener(t,n));let xL=class{constructor(t,n,o){this.message=n,this.target=t,this.value=o}};class iRe extends xL{}class lRe extends xL{}const s0="Custom",aRe=null,uRe={true:1,"":1,1:1};function cRe(e,t,n,o,r){const{type:s,reflect:i,event:l,value:a,attr:u=fRe(t)}=(n==null?void 0:n.name)!=s0&&up(n)&&n!=aRe?n:{type:n},c=(s==null?void 0:s.name)===s0&&s.map,d=a!=null?s==Function||!Ci(a)?()=>a:a:null;Object.defineProperty(e,t,{configurable:!0,set(f){const p=this[t];d&&s!=Boolean&&f==null&&(f=d());const{error:h,value:m}=(c?mRe:gRe)(s,f);if(h&&m!=null)throw new iRe(this,`The value defined for prop '${t}' must be of type '${s.name}'`,m);p!=m&&(this._props[t]=m??void 0,this.update(),l&&dRe(this,l),this.updated.then(()=>{i&&(this._ignoreAttr=u,pRe(this,s,u,this[t]),this._ignoreAttr=null)}))},get(){return this._props[t]}}),d&&(r[t]=d()),o[u]={prop:t,type:s}}const dRe=(e,{type:t,base:n=CustomEvent,...o})=>e.dispatchEvent(new n(t,o)),fRe=e=>e.replace(/([A-Z])/g,"-$1").toLowerCase(),pRe=(e,t,n,o)=>o==null||t==Boolean&&!o?e.removeAttribute(n):e.setAttribute(n,(t==null?void 0:t.name)===s0&&(t!=null&&t.serialize)?t==null?void 0:t.serialize(o):up(o)?JSON.stringify(o):t==Boolean?"":o),hRe=(e,t)=>e==Boolean?!!uRe[t]:e==Number?Number(t):e==String?t:e==Array||e==Object?JSON.parse(t):e.name==s0?t:new e(t),mRe=({map:e},t)=>{try{return{value:e(t),error:!1}}catch{return{value:t,error:!0}}},gRe=(e,t)=>e==null||t==null?{value:t,error:!1}:e!=String&&t===""?{value:void 0,error:!1}:e==Object||e==Array||e==Symbol?{value:t,error:{}.toString.call(t)!==`[object ${e.name}]`}:t instanceof e?{value:t,error:e==Number&&Number.isNaN(t.valueOf())}:e==String||e==Number||e==Boolean?{value:t,error:e==Number?typeof t!="number"?!0:Number.isNaN(t):e==String?typeof t!="string":typeof t!="boolean"}:{value:t,error:!0};let vRe=0;const yRe=e=>{var n;const t=((n=(e==null?void 0:e.dataset)||{})==null?void 0:n.hydrate)||"";return t||"c"+vRe++},zh=(e,t=HTMLElement)=>{const n={},o={},r="prototype"in t&&t.prototype instanceof Element,s=r?t:"base"in t?t.base:HTMLElement,{props:i,styles:l}=r?e:t;class a extends s{constructor(){super(),this._setup(),this._render=()=>e({...this._props});for(const c in o)this[c]=o[c]}static get styles(){return[super.styles,l]}async _setup(){if(this._props)return;this._props={};let c,d;this.mounted=new Promise(y=>this.mount=()=>{y(),c!=this.parentNode&&(d!=c?this.unmounted.then(this.update):this.update()),c=this.parentNode}),this.unmounted=new Promise(y=>this.unmount=()=>{y(),(c!=this.parentNode||!this.isConnected)&&(f.cleanEffects(!0)()(),d=this.parentNode,c=null)}),this.symbolId=this.symbolId||Symbol(),this.symbolIdParent=Symbol();const f=rRe(()=>this.update(),this,yRe(this));let p,h=!0;const m=R2(this);this.update=()=>(p||(p=!0,this.updated=(this.updated||this.mounted).then(()=>{try{const y=f.load(this._render),v=f.cleanEffects();return y&&y.render(this,this.symbolId,m),p=!1,h&&!f.isSuspense()&&(h=!1,!m&&_Re(this)),v()}finally{p=!1}}).then(y=>{y&&y()})),this.updated),this.update()}connectedCallback(){this.mount(),super.connectedCallback&&super.connectedCallback()}disconnectedCallback(){super.disconnectedCallback&&super.disconnectedCallback(),this.unmount()}attributeChangedCallback(c,d,f){if(n[c]){if(c===this._ignoreAttr||d===f)return;const{prop:p,type:h}=n[c];try{this[p]=hRe(h,f)}catch{throw new lRe(this,`The value defined as attr '${c}' cannot be parsed by type '${h.name}'`,f)}}else super.attributeChangedCallback(c,d,f)}static get props(){return{...super.props,...i}}static get observedAttributes(){const c=super.observedAttributes||[];for(const d in i)cRe(this.prototype,d,i[d],n,o);return Object.keys(n).concat(c)}}return a};function _Re(e){const{styles:t}=e.constructor,{shadowRoot:n}=e;if(n&&t.length){const o=[];$L(t,r=>{r&&(r instanceof Element?n.appendChild(r.cloneNode(!0)):o.push(r))}),o.length&&(n.adoptedStyleSheets=o)}}const ML=e=>(t,n)=>{Vh(([o,r]=[])=>((r||!r)&&(r&&SL(r,n)?o=o||!0:(Ci(o)&&o(),o=null)),[o,n]),([o,r],s)=>s?(Ci(o)&&o(),[]):[o||t(),r],e)},i0=ML(bL),bRe=ML(wL);class wRe extends Array{constructor(t,n){let o=!0;const r=s=>{try{n(s,this,o)}finally{o=!1}};super(void 0,r,n),r(t)}}const TL=e=>{const t=kL();return Vh((n=new wRe(e,(o,r,s)=>{o=Ci(o)?o(r[0]):o,o!==r[0]&&(r[0]=o,s||t())}))=>n)},D2=(e,t)=>{const[n]=Vh(([o,r,s=0]=[])=>((!r||r&&!SL(r,t))&&(o=e()),[o,t,s]));return n},Fu=(e,t)=>D2(()=>e,t),F2=Bh("atomico/options");globalThis[F2]=globalThis[F2]||{sheet:!!document.adoptedStyleSheets};const OL=globalThis[F2];new Promise(e=>{OL.ssr||(document.readyState==="loading"?EL(document,"DOMContentLoaded",e):e())});const CRe={checked:1,value:1,selected:1},kRe={list:1,type:1,size:1,form:1,width:1,height:1,src:1,href:1,slot:1},SRe={shadowDom:1,staticNode:1,cloneNode:1,children:1,key:1},j1={},V2=[];class B2 extends Text{}const $Re=Bh("atomico/id"),cp=Bh("atomico/type"),s_=Bh("atomico/ref"),IL=Bh("atomico/vnode"),ERe=()=>{};function xRe(e,t,n){return NL(this,e,t,n)}const AL=(e,t,...n)=>{const o=t||j1;let{children:r}=o;if(r=r??(n.length?n:V2),e===ERe)return r;const s=e?e instanceof Node?1:e.prototype instanceof HTMLElement&&2:0;if(s===!1&&e instanceof Function)return e(r!=V2?{children:r,...o}:o);const i=OL.render||xRe;return{[cp]:IL,type:e,props:o,children:r,key:o.key,shadow:o.shadowDom,static:o.staticNode,raw:s,is:o.is,clone:o.cloneNode,render:i}};function NL(e,t,n=$Re,o,r){let s;if(t&&t[n]&&t[n].vnode==e||e[cp]!=IL)return t;(e||!t)&&(r=r||e.type=="svg",s=e.type!="host"&&(e.raw==1?(t&&e.clone?t[s_]:t)!=e.type:e.raw==2?!(t instanceof e.type):t?t[s_]||t.localName!=e.type:!t),s&&e.type!=null&&(e.raw==1&&e.clone?(o=!0,t=e.type.cloneNode(!0),t[s_]=e.type):t=e.raw==1?e.type:e.raw==2?new e.type:r?document.createElementNS("http://www.w3.org/2000/svg",e.type):document.createElement(e.type,e.is?{is:e.is}:void 0)));const i=t[n]?t[n]:j1,{vnode:l=j1,cycle:a=0}=i;let{fragment:u,handlers:c}=i;const{children:d=V2,props:f=j1}=l;if(c=s?{}:c||{},e.static&&!s)return t;if(e.shadow&&!t.shadowRoot&&t.attachShadow({mode:"open",...e.shadow}),e.props!=f&&ORe(t,f,e.props,c,r),e.children!==d){const p=e.shadow?t.shadowRoot:t;u=TRe(e.children,u,p,n,!a&&o,r&&e.type=="foreignObject"?!1:r)}return t[n]={vnode:e,handlers:c,fragment:u,cycle:a+1},t}function MRe(e,t){const n=new B2(""),o=new B2("");let r;if(e[t?"prepend":"append"](n),t){let{lastElementChild:s}=e;for(;s;){const{previousElementSibling:i}=s;if(R2(s,!0)&&!R2(i,!0)){r=s;break}s=i}}return r?r.before(o):e.append(o),{markStart:n,markEnd:o}}function TRe(e,t,n,o,r,s){e=e==null?null:sRe(e)?e:[e];const i=t||MRe(n,r),{markStart:l,markEnd:a,keyes:u}=i;let c;const d=u&&new Set;let f=l;if(e&&$L(e,p=>{if(typeof p=="object"&&!p[cp])return;const h=p[cp]&&p.key,m=u&&h!=null&&u.get(h);f!=a&&f===m?d.delete(f):f=f==a?a:f.nextSibling;const y=u?m:f;let v=y;if(p[cp])v=NL(p,y,o,r,s);else{const w=p+"";!(v instanceof Text)||v instanceof B2?v=new Text(w):v.data!=w&&(v.data=w)}v!=f&&(u&&d.delete(v),!y||u?(n.insertBefore(v,f),u&&f!=a&&d.add(f)):y==a?n.insertBefore(v,a):(n.replaceChild(v,y),f=v)),h!=null&&(c=c||new Map,c.set(h,v))}),f=f==a?a:f.nextSibling,t&&f!=a)for(;f!=a;){const p=f;f=f.nextSibling,p.remove()}return d&&d.forEach(p=>p.remove()),i.keyes=c,i}function ORe(e,t,n,o,r){for(const s in t)!(s in n)&&t$(e,s,t[s],null,r,o);for(const s in n)t$(e,s,t[s],n[s],r,o)}function t$(e,t,n,o,r,s){if(t=t=="class"&&!r?"className":t,n=n??null,o=o??null,t in e&&CRe[t]&&(n=e[t]),!(o===n||SRe[t]||t[0]=="_"))if(e.localName==="slot"&&t==="assignNode"&&"assign"in e)e.assign(o);else if(t[0]=="o"&&t[1]=="n"&&(Ci(o)||Ci(n)))IRe(e,t.slice(2),o,s);else if(t=="ref")o&&(Ci(o)?o(e):o.current=e);else if(t=="style"){const{style:i}=e;n=n||"",o=o||"";const l=up(n),a=up(o);if(l)for(const u in n)if(a)!(u in o)&&n$(i,u,null);else break;if(a)for(const u in o){const c=o[u];l&&n[u]===c||n$(i,u,c)}else i.cssText=o}else{const i=t[0]=="$"?t.slice(1):t;i===t&&(!r&&!kRe[t]&&t in e||Ci(o)||Ci(n))?e[t]=o??"":o==null?e.removeAttribute(i):e.setAttribute(i,up(o)?JSON.stringify(o):o)}}function IRe(e,t,n,o){if(o.handleEvent||(o.handleEvent=r=>o[r.type].call(e,r)),n){if(!o[t]){const r=n.capture||n.once||n.passive?Object.assign({},n):null;e.addEventListener(t,o,r)}o[t]=n}else o[t]&&(e.removeEventListener(t,o),delete o[t])}function n$(e,t,n){let o="setProperty";n==null&&(o="removeProperty",n=null),~t.indexOf("-")?e[o](t,n):e[t]=n}const ARe=AL("host",{style:"display: contents"}),NRe="value",PRe=(e,t)=>{const n=CL(),o=Rk();bRe(()=>EL(n.current,"ConnectContext",r=>{r.composedPath().at(0)!==r.currentTarget&&e===r.detail.id&&(r.stopPropagation(),r.detail.connect(o))}),[e]),o.current=t},LRe=e=>{const t=zh(({value:n})=>(PRe(t,n),ARe),{props:{value:{type:Object,value:()=>e}}});return t[NRe]=e,t};LRe({dispatch(e,t){}});const RRe=0,Vu=1,Im=2,Am=3,o$=4,Cf=5,z2=6,PL=0,DRe=2,LL=3,RL=4,DL=Cf,FRe=z2,FL=(e,t,n,o)=>{let r;t[0]=0;for(let s=1;s<t.length;s++){const i=t[s++],l=t[s]?(t[0]|=i?1:2,n[t[s++]]):t[++s];i===LL?o[0]=l:i===RL?o[1]=Object.assign(o[1]||{},l):i===DL?(o[1]=o[1]||{})[t[++s]]=l:i===FRe?o[1][t[++s]]+=l+"":i?(r=e.apply(l,FL(e,l,n,["",null])),o.push(r),l[0]?t[0]|=2:(t[s-2]=PL,t[s]=r)):o.push(l)}return o},VRe=function(e){let t=Vu,n="",o="",r=[0],s,i;const l=a=>{t===Vu&&(a||(n=n.replace(/^\s*\n\s*|\s*\n\s*$/g,"")))?r.push(PL,a,n):t===Am&&(a||n)?(r.push(LL,a,n),t=Im):t===Im&&n==="..."&&a?r.push(RL,a,0):t===Im&&n&&!a?r.push(DL,0,!0,n):t>=Cf&&((n||!a&&t===Cf)&&(r.push(t,0,n,i),t=z2),a&&(r.push(t,a,0,i),t=z2)),n=""};for(let a=0;a<e.length;a++){a&&(t===Vu&&l(),l(a));for(let u=0;u<e[a].length;u++)s=e[a][u],t===Vu?s==="<"?(l(),r=[r],t=Am):n+=s:t===o$?n==="--"&&s===">"?(t=Vu,n=""):n=s+n[0]:o?s===o?o="":n+=s:s==='"'||s==="'"?o=s:s===">"?(l(),t=Vu):t&&(s==="="?(t=Cf,i=n,n=""):s==="/"&&(t<Cf||e[a][u+1]===">")?(l(),t===Am&&(r=r[0]),t=r,(r=r[0]).push(DRe,0,t),t=RRe):s===" "||s===" "||s===`
127 `||s==="\r"?(l(),t=Im):n+=s),t===Am&&n==="!--"&&(t=o$,r=r[0])}return l(),r},BRe=new Map;function $t(e){let t=BRe;return t=FL(AL,t.get(e)||(t.set(e,t=VRe(e)),t),arguments,[]),t.length>1?t:t[0]}var Dk=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},Bu=(e,t,n)=>(Dk(e,t,"read from private field"),n?n.call(e):t.get(e)),zu=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},ju=(e,t,n,o)=>(Dk(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),zRe=(e,t,n)=>(Dk(e,t,"access private method"),n),H1,U1,kf,Sf,W1,j2,VL;let Fk=class{constructor(t){zu(this,j2),zu(this,H1,void 0),zu(this,U1,void 0),zu(this,kf,void 0),zu(this,Sf,void 0),zu(this,W1,void 0),ju(this,kf,!1),this.onShow=()=>{},this.onHide=()=>{},ju(this,W1,(n,o)=>{var r;const{state:s,composing:i}=n,{selection:l,doc:a}=s,{ranges:u}=l,c=Math.min(...u.map(p=>p.$from.pos)),d=Math.max(...u.map(p=>p.$to.pos)),f=o&&o.doc.eq(a)&&o.selection.eq(l);if(Bu(this,kf)||((r=n.dom.parentElement)==null||r.appendChild(this.element),ju(this,kf,!0)),!(i||f)){if(!Bu(this,U1).call(this,n,o)){this.hide();return}tb({getBoundingClientRect:()=>av(n,c,d)},this.element,{placement:"top",middleware:[eb(),X_(Bu(this,Sf))]}).then(({x:p,y:h})=>{Object.assign(this.element.style,{left:`${p}px`,top:`${h}px`})}),this.show()}}),this.update=(n,o)=>{Sv(Bu(this,W1),Bu(this,H1))(n,o)},this.destroy=()=>{},this.show=n=>{this.element.dataset.show="true",n&&tb(n,this.element,{placement:"top",middleware:[eb(),X_(Bu(this,Sf))]}).then(({x:o,y:r})=>{Object.assign(this.element.style,{left:`${o}px`,top:`${r}px`})}),this.onShow()},this.hide=()=>{this.element.dataset.show!=="false"&&(this.element.dataset.show="false",this.onHide())},this.element=t.content,ju(this,H1,t.debounce??200),ju(this,U1,t.shouldShow??zRe(this,j2,VL)),ju(this,Sf,t.offset),this.element.dataset.show="false"}};H1=new WeakMap,U1=new WeakMap,kf=new WeakMap,Sf=new WeakMap,W1=new WeakMap,j2=new WeakSet,VL=function(e){const{doc:t,selection:n}=e.state,{empty:o,from:r,to:s}=n,i=!t.textBetween(r,s).length&&e.state.selection instanceof ht,l=this.element.contains(document.activeElement),a=!e.hasFocus()&&!l,u=!e.editable;return!(a||o||i||u)};function Vk(e){const t=In({},`${e}_TOOLTIP_SPEC`),n=ao(r=>{const s=r.get(t.key);return new xn({key:new wn(`${e}_TOOLTIP`),...s})}),o=[t,n];return o.key=t.key,o.pluginKey=n.key,t.meta={package:"@milkdown/plugin-tooltip",displayName:`Ctx<tooltipSpec>|${e}`},n.meta={package:"@milkdown/plugin-tooltip",displayName:`Prose<tooltip>|${e}`},o}function BL(e){var t,n,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var r=e.length;for(t=0;t<r;t++)e[t]&&(n=BL(e[t]))&&(o&&(o+=" "),o+=n)}else for(n in e)e[n]&&(o&&(o+=" "),o+=n);return o}function ac(){for(var e,t,n=0,o="",r=arguments.length;n<r;n++)(e=arguments[n])&&(t=BL(e))&&(o&&(o+=" "),o+=t);return o}var jRe=Object.defineProperty,r$=Object.getOwnPropertySymbols,HRe=Object.prototype.hasOwnProperty,URe=Object.prototype.propertyIsEnumerable,s$=(e,t,n)=>t in e?jRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WRe=(e,t)=>{for(var n in t||(t={}))HRe.call(t,n)&&s$(e,n,t[n]);if(r$)for(var n of r$(t))URe.call(t,n)&&s$(e,n,t[n]);return e};function Ou(e,t){return Object.assign(e,{meta:WRe({package:"@milkdown/components"},t)}),e}var KRe=Object.defineProperty,i$=Object.getOwnPropertySymbols,qRe=Object.prototype.hasOwnProperty,GRe=Object.prototype.propertyIsEnumerable,l$=(e,t,n)=>t in e?KRe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Bk=(e,t)=>{for(var n in t||(t={}))qRe.call(t,n)&&l$(e,n,t[n]);if(i$)for(var n of i$(t))GRe.call(t,n)&&l$(e,n,t[n]);return e};const YRe={mode:"preview"},Ri=In(Bk({},YRe),"linkTooltipStateCtx");Ou(Ri,{displayName:"State<link-tooltip>",group:"LinkTooltip"});const ZRe={addLink:()=>{},editLink:()=>{},removeLink:()=>{}},gd=In(Bk({},ZRe),"linkTooltipAPICtx");Ou(Ri,{displayName:"API<link-tooltip>",group:"LinkTooltip"});const JRe={linkIcon:()=>"🔗",editButton:()=>"✎",removeButton:()=>"⌫",confirmButton:()=>$t`Confirm ⏎`,onCopyLink:()=>{},inputPlaceholder:"Paste link..."},Tv=In(Bk({},JRe),"linkTooltipConfigCtx");Ou(Ri,{displayName:"Config<link-tooltip>",group:"LinkTooltip"});const jh=Vk("LINK_PREVIEW");Ou(jh[0],{displayName:"PreviewTooltipSpec<link-tooltip>",group:"LinkTooltip"});Ou(jh[1],{displayName:"PreviewTooltipPlugin<link-tooltip>",group:"LinkTooltip"});const Ov=Vk("LINK_EDIT");Ou(Ov[0],{displayName:"EditTooltipSpec<link-tooltip>",group:"LinkTooltip"});Ou(Ov[1],{displayName:"EditTooltipPlugin<link-tooltip>",group:"LinkTooltip"});function XRe(e,t,n,o,r){let s={start:-1,end:-1};return n.nodesBetween(o,r,(i,l)=>{if(s.start>-1)return!1;s.start===-1&&e.isInSet(i.marks)&&t===i&&(s={start:l,end:l+Math.max(i.textContent.length,1)})}),s}function QRe(e,t,n){const o=t.posAtCoords({left:n.clientX,top:n.clientY});if(!o)return;const{pos:r}=o,s=t.state.doc.nodeAt(r);if(!s)return;const i=s.marks.find(a=>a.type===fs.mark.type(e));if(!(!i||!jh.pluginKey()))return{show:!0,pos:r,node:s,mark:i}}function zL(e,t){const n=customElements.get(e);if(n==null){customElements.define(e,t);return}n!==t&&console.warn(`Custom element ${e} has been defined before.`)}const jL=({config:e,src:t,onEdit:n,onRemove:o})=>{const r=l=>{l.stopPropagation(),l.preventDefault(),n==null||n()},s=l=>{l.stopPropagation(),l.preventDefault(),o==null||o()};return $t`
128 <host>
129 <div class="link-preview" onmousedown=${l=>{l.preventDefault(),navigator.clipboard&&t&&navigator.clipboard.writeText(t).then(()=>{e==null||e.onCopyLink(t)}).catch(a=>{throw a})}}>
130 <span class="link-icon">
131 ${e==null?void 0:e.linkIcon()}
132 </span>
133 <a href=${t} target="_blank" class="link-display">${t}</a>
134 <span class="button link-edit-button" onmousedown=${r}>
135 ${e==null?void 0:e.editButton()}
136 </span>
137 <span class="button link-remove-button" onmousedown=${s}>
138 ${e==null?void 0:e.removeButton()}
139 </span>
140 </div>
141 </host>
142 `};jL.props={config:Object,src:String,onEdit:Function,onRemove:Function};const HL=zh(jL);var UL=e=>{throw TypeError(e)},WL=(e,t,n)=>t.has(e)||UL("Cannot "+n),rn=(e,t,n)=>(WL(e,t,"read from private field"),n?n.call(e):t.get(e)),Xi=(e,t,n)=>t.has(e)?UL("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Nm=(e,t,n,o)=>(WL(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),cl,es,$f,Ef,K1,q1,G1,xf;class eDe{constructor(t,n){this.ctx=t,Xi(this,cl,new HL),Xi(this,es),Xi(this,$f,this.ctx.use(Ri.key)),Xi(this,Ef,!1),Xi(this,K1,({mode:o})=>{o==="edit"&&rn(this,xf).call(this)}),Xi(this,q1,()=>{Nm(this,Ef,!0)}),Xi(this,G1,()=>{Nm(this,Ef,!1)}),Xi(this,xf,()=>{rn(this,es).hide(),rn(this,es).element.removeEventListener("mouseenter",rn(this,q1)),rn(this,es).element.removeEventListener("mouseleave",rn(this,G1))}),this.show=(o,r,s,i)=>{rn(this,cl).config=this.ctx.get(Tv.key),rn(this,cl).src=o.attrs.href,rn(this,cl).onEdit=()=>{this.ctx.get(gd.key).editLink(o,r,s)},rn(this,cl).onRemove=()=>{this.ctx.get(gd.key).removeLink(r,s),rn(this,xf).call(this)},rn(this,es).show({getBoundingClientRect:()=>i}),rn(this,es).element.addEventListener("mouseenter",rn(this,q1)),rn(this,es).element.addEventListener("mouseleave",rn(this,G1))},this.hide=()=>{rn(this,Ef)||rn(this,xf).call(this)},this.update=()=>{},this.destroy=()=>{rn(this,$f).off(rn(this,K1)),rn(this,es).destroy(),rn(this,cl).remove()},Nm(this,es,new Fk({debounce:0,content:rn(this,cl),shouldShow:()=>!1})),rn(this,es).update(n),Nm(this,$f,t.use(Ri.key)),rn(this,$f).on(rn(this,K1))}}cl=new WeakMap;es=new WeakMap;$f=new WeakMap;Ef=new WeakMap;K1=new WeakMap;q1=new WeakMap;G1=new WeakMap;xf=new WeakMap;zL("milkdown-link-preview",HL);function tDe(e){let t;const o=Sv((s,i)=>{if(!t||!s.hasFocus()||e.get(Ri.key).mode==="edit")return;const a=QRe(e,s,i);if(a){const u=s.state.doc.resolve(a.pos),c=XRe(a.mark,a.node,s.state.doc,u.before(),u.after()),d=c.start,f=c.end;t.show(a.mark,d,f,av(s,d,f));return}t.hide()},200),r=()=>{setTimeout(()=>{t==null||t.hide()},200)};e.set(jh.key,{props:{handleDOMEvents:{mousemove:o,mouseleave:r}},view:s=>(t=new eDe(e,s),t)})}const KL=({src:e,onConfirm:t,onCancel:n,config:o})=>{const r=Rk(),[s,i]=TL(e);i0(()=>{i(e??"")},[e]);const l=()=>{var u,c;t==null||t((c=(u=r.current)==null?void 0:u.value)!=null?c:"")},a=u=>{var c,d;u.stopPropagation(),u.key==="Enter"&&(t==null||t((d=(c=r.current)==null?void 0:c.value)!=null?d:""),u.preventDefault()),u.key==="Escape"&&(n==null||n(),u.preventDefault())};return $t`
143 <host>
144 <div class="link-edit">
145 <input
146 class="input-area"
147 placeholder=${o==null?void 0:o.inputPlaceholder}
148 ref=${r}
149 onkeydown=${a}
150 oninput=${u=>i(u.target.value)}
151 value=${s}
152 />
153 <span class=${ac("button confirm",!s&&"hidden")} onclick=${l}>
154 ${o==null?void 0:o.confirmButton()}
155 </span>
156 </div>
157 </host>
158 `};KL.props={config:Object,src:String,onConfirm:Function,onCancel:Function};const qL=zh(KL);var nDe=Object.defineProperty,oDe=Object.defineProperties,rDe=Object.getOwnPropertyDescriptors,a$=Object.getOwnPropertySymbols,sDe=Object.prototype.hasOwnProperty,iDe=Object.prototype.propertyIsEnumerable,GL=e=>{throw TypeError(e)},u$=(e,t,n)=>t in e?nDe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Pm=(e,t)=>{for(var n in t||(t={}))sDe.call(t,n)&&u$(e,n,t[n]);if(a$)for(var n of a$(t))iDe.call(t,n)&&u$(e,n,t[n]);return e},c$=(e,t)=>oDe(e,rDe(t)),YL=(e,t,n)=>t.has(e)||GL("Cannot "+n),gn=(e,t,n)=>(YL(e,t,"read from private field"),n?n.call(e):t.get(e)),Hu=(e,t,n)=>t.has(e)?GL("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Lm=(e,t,n,o)=>(YL(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),As,dl,fl,Sa,H2,Y1;const d$={from:-1,to:-1,mark:null};class lDe{constructor(t,n){this.ctx=t,Hu(this,As,new qL),Hu(this,dl),Hu(this,fl,Pm({},d$)),Hu(this,Sa,()=>{gn(this,dl).hide(),this.ctx.update(Ri.key,o=>c$(Pm({},o),{mode:"preview"})),Lm(this,fl,Pm({},d$))}),Hu(this,H2,o=>{const r=this.ctx.get(bn),{from:s,to:i,mark:l}=gn(this,fl),a=fs.type(this.ctx);if(l&&l.attrs.href===o){gn(this,Sa).call(this);return}const u=r.state.tr;l&&u.removeMark(s,i,l),u.addMark(s,i,a.create({href:o})),r.dispatch(u),gn(this,Sa).call(this)}),Hu(this,Y1,(o,r,s)=>{const i=this.ctx.get(Tv.key);gn(this,As).config=i,gn(this,As).src=o,this.ctx.update(Ri.key,a=>c$(Pm({},a),{mode:"edit"}));const l=this.ctx.get(bn);l.dispatch(l.state.tr.setSelection(ht.create(l.state.doc,r,s))),gn(this,dl).show({getBoundingClientRect:()=>av(l,r,s)}),requestAnimationFrame(()=>{var a;(a=gn(this,As).querySelector("input"))==null||a.focus()})}),this.update=o=>{const{state:r}=o,{selection:s}=r;if(!(s instanceof ht))return;const{from:i,to:l}=s;i===gn(this,fl).from&&l===gn(this,fl).to||gn(this,Sa).call(this)},this.destroy=()=>{gn(this,dl).destroy(),gn(this,As).remove()},this.addLink=(o,r)=>{Lm(this,fl,{from:o,to:r,mark:null}),gn(this,Y1).call(this,"",o,r)},this.editLink=(o,r,s)=>{Lm(this,fl,{from:r,to:s,mark:o}),gn(this,Y1).call(this,o.attrs.href,r,s)},this.removeLink=(o,r)=>{const s=this.ctx.get(bn),i=s.state.tr;i.removeMark(o,r,fs.type(this.ctx)),s.dispatch(i),gn(this,Sa).call(this)},Lm(this,dl,new Fk({content:gn(this,As),debounce:0,shouldShow:()=>!1})),gn(this,dl).onHide=()=>{gn(this,As).update().catch(o=>{throw o}),n.dom.focus({preventScroll:!0})},gn(this,dl).update(n),gn(this,As).onConfirm=gn(this,H2),gn(this,As).onCancel=gn(this,Sa)}}As=new WeakMap;dl=new WeakMap;fl=new WeakMap;Sa=new WeakMap;H2=new WeakMap;Y1=new WeakMap;var aDe=Object.defineProperty,uDe=Object.defineProperties,cDe=Object.getOwnPropertyDescriptors,f$=Object.getOwnPropertySymbols,dDe=Object.prototype.hasOwnProperty,fDe=Object.prototype.propertyIsEnumerable,p$=(e,t,n)=>t in e?aDe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,pDe=(e,t)=>{for(var n in t||(t={}))dDe.call(t,n)&&p$(e,n,t[n]);if(f$)for(var n of f$(t))fDe.call(t,n)&&p$(e,n,t[n]);return e},hDe=(e,t)=>uDe(e,cDe(t));zL("milkdown-link-edit",qL);function mDe(e){let t;e.update(gd.key,n=>hDe(pDe({},n),{addLink:(o,r)=>{t==null||t.addLink(o,r)},editLink:(o,r,s)=>{t==null||t.editLink(o,r,s)},removeLink:(o,r)=>{t==null||t.removeLink(o,r)}})),e.set(Ov.key,{view:n=>(t=new lDe(e,n),t)})}function gDe(e){tDe(e),mDe(e)}const vDe=[Ri,gd,Tv,jh,Ov].flat();$t`
159 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
160 <path d="M4.25 20.5C4.0375 20.5 3.85942 20.4281 3.71575 20.2843C3.57192 20.1404 3.5 19.9622 3.5 19.7498C3.5 19.5371 3.57192 19.359 3.71575 19.2155C3.85942 19.0718 4.0375 19 4.25 19H19.75C19.9625 19 20.1406 19.0719 20.2843 19.2158C20.4281 19.3596 20.5 19.5378 20.5 19.7502C20.5 19.9629 20.4281 20.141 20.2843 20.2845C20.1406 20.4282 19.9625 20.5 19.75 20.5H4.25ZM8.25 16.625C8.0375 16.625 7.85942 16.5531 7.71575 16.4093C7.57192 16.2654 7.5 16.0872 7.5 15.8748C7.5 15.6621 7.57192 15.484 7.71575 15.3405C7.85942 15.1968 8.0375 15.125 8.25 15.125H15.75C15.9625 15.125 16.1406 15.1969 16.2843 15.3408C16.4281 15.4846 16.5 15.6628 16.5 15.8753C16.5 16.0879 16.4281 16.266 16.2843 16.4095C16.1406 16.5532 15.9625 16.625 15.75 16.625H8.25ZM4.25 12.75C4.0375 12.75 3.85942 12.6781 3.71575 12.5343C3.57192 12.3904 3.5 12.2122 3.5 11.9998C3.5 11.7871 3.57192 11.609 3.71575 11.4655C3.85942 11.3218 4.0375 11.25 4.25 11.25H19.75C19.9625 11.25 20.1406 11.3219 20.2843 11.4658C20.4281 11.6096 20.5 11.7878 20.5 12.0003C20.5 12.2129 20.4281 12.391 20.2843 12.5345C20.1406 12.6782 19.9625 12.75 19.75 12.75H4.25ZM8.25 8.875C8.0375 8.875 7.85942 8.80308 7.71575 8.65925C7.57192 8.51542 7.5 8.33725 7.5 8.12475C7.5 7.91208 7.57192 7.734 7.71575 7.5905C7.85942 7.44683 8.0375 7.375 8.25 7.375H15.75C15.9625 7.375 16.1406 7.44692 16.2843 7.59075C16.4281 7.73458 16.5 7.91275 16.5 8.12525C16.5 8.33792 16.4281 8.516 16.2843 8.6595C16.1406 8.80317 15.9625 8.875 15.75 8.875H8.25ZM4.25 5C4.0375 5 3.85942 4.92808 3.71575 4.78425C3.57192 4.64042 3.5 4.46225 3.5 4.24975C3.5 4.03708 3.57192 3.859 3.71575 3.7155C3.85942 3.57183 4.0375 3.5 4.25 3.5H19.75C19.9625 3.5 20.1406 3.57192 20.2843 3.71575C20.4281 3.85958 20.5 4.03775 20.5 4.25025C20.5 4.46292 20.4281 4.641 20.2843 4.7845C20.1406 4.92817 19.9625 5 19.75 5H4.25Z"/>
161 </svg>
162 `;$t`
163 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
164 <path d="M4.25 20.5C4.0375 20.5 3.85942 20.4281 3.71575 20.2843C3.57192 20.1404 3.5 19.9622 3.5 19.7498C3.5 19.5371 3.57192 19.359 3.71575 19.2155C3.85942 19.0718 4.0375 19 4.25 19H19.75C19.9625 19 20.1406 19.0719 20.2843 19.2158C20.4281 19.3596 20.5 19.5378 20.5 19.7502C20.5 19.9629 20.4281 20.141 20.2843 20.2845C20.1406 20.4282 19.9625 20.5 19.75 20.5H4.25ZM4.25 16.625C4.0375 16.625 3.85942 16.5531 3.71575 16.4093C3.57192 16.2654 3.5 16.0872 3.5 15.8748C3.5 15.6621 3.57192 15.484 3.71575 15.3405C3.85942 15.1968 4.0375 15.125 4.25 15.125H13.75C13.9625 15.125 14.1406 15.1969 14.2843 15.3408C14.4281 15.4846 14.5 15.6628 14.5 15.8753C14.5 16.0879 14.4281 16.266 14.2843 16.4095C14.1406 16.5532 13.9625 16.625 13.75 16.625H4.25ZM4.25 12.75C4.0375 12.75 3.85942 12.6781 3.71575 12.5343C3.57192 12.3904 3.5 12.2122 3.5 11.9998C3.5 11.7871 3.57192 11.609 3.71575 11.4655C3.85942 11.3218 4.0375 11.25 4.25 11.25H19.75C19.9625 11.25 20.1406 11.3219 20.2843 11.4658C20.4281 11.6096 20.5 11.7878 20.5 12.0003C20.5 12.2129 20.4281 12.391 20.2843 12.5345C20.1406 12.6782 19.9625 12.75 19.75 12.75H4.25ZM4.25 8.875C4.0375 8.875 3.85942 8.80308 3.71575 8.65925C3.57192 8.51542 3.5 8.33725 3.5 8.12475C3.5 7.91208 3.57192 7.734 3.71575 7.5905C3.85942 7.44683 4.0375 7.375 4.25 7.375H13.75C13.9625 7.375 14.1406 7.44692 14.2843 7.59075C14.4281 7.73458 14.5 7.91275 14.5 8.12525C14.5 8.33792 14.4281 8.516 14.2843 8.6595C14.1406 8.80317 13.9625 8.875 13.75 8.875H4.25ZM4.25 5C4.0375 5 3.85942 4.92808 3.71575 4.78425C3.57192 4.64042 3.5 4.46225 3.5 4.24975C3.5 4.03708 3.57192 3.859 3.71575 3.7155C3.85942 3.57183 4.0375 3.5 4.25 3.5H19.75C19.9625 3.5 20.1406 3.57192 20.2843 3.71575C20.4281 3.85958 20.5 4.03775 20.5 4.25025C20.5 4.46292 20.4281 4.641 20.2843 4.7845C20.1406 4.92817 19.9625 5 19.75 5H4.25Z"/>
165 </svg>
166 `;$t`
167 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
168 <path d="M4.25 5C4.0375 5 3.85942 4.92808 3.71575 4.78425C3.57192 4.64042 3.5 4.46225 3.5 4.24975C3.5 4.03708 3.57192 3.859 3.71575 3.7155C3.85942 3.57183 4.0375 3.5 4.25 3.5H19.75C19.9625 3.5 20.1406 3.57192 20.2843 3.71575C20.4281 3.85958 20.5 4.03775 20.5 4.25025C20.5 4.46292 20.4281 4.641 20.2843 4.7845C20.1406 4.92817 19.9625 5 19.75 5H4.25ZM10.25 8.875C10.0375 8.875 9.85942 8.80308 9.71575 8.65925C9.57192 8.51542 9.5 8.33725 9.5 8.12475C9.5 7.91208 9.57192 7.734 9.71575 7.5905C9.85942 7.44683 10.0375 7.375 10.25 7.375H19.75C19.9625 7.375 20.1406 7.44692 20.2843 7.59075C20.4281 7.73458 20.5 7.91275 20.5 8.12525C20.5 8.33792 20.4281 8.516 20.2843 8.6595C20.1406 8.80317 19.9625 8.875 19.75 8.875H10.25ZM4.25 12.75C4.0375 12.75 3.85942 12.6781 3.71575 12.5343C3.57192 12.3904 3.5 12.2122 3.5 11.9998C3.5 11.7871 3.57192 11.609 3.71575 11.4655C3.85942 11.3218 4.0375 11.25 4.25 11.25H19.75C19.9625 11.25 20.1406 11.3219 20.2843 11.4658C20.4281 11.6096 20.5 11.7878 20.5 12.0003C20.5 12.2129 20.4281 12.391 20.2843 12.5345C20.1406 12.6782 19.9625 12.75 19.75 12.75H4.25ZM10.25 16.625C10.0375 16.625 9.85942 16.5531 9.71575 16.4093C9.57192 16.2654 9.5 16.0872 9.5 15.8748C9.5 15.6621 9.57192 15.484 9.71575 15.3405C9.85942 15.1968 10.0375 15.125 10.25 15.125H19.75C19.9625 15.125 20.1406 15.1969 20.2843 15.3408C20.4281 15.4846 20.5 15.6628 20.5 15.8753C20.5 16.0879 20.4281 16.266 20.2843 16.4095C20.1406 16.5532 19.9625 16.625 19.75 16.625H10.25ZM4.25 20.5C4.0375 20.5 3.85942 20.4281 3.71575 20.2843C3.57192 20.1404 3.5 19.9622 3.5 19.7498C3.5 19.5371 3.57192 19.359 3.71575 19.2155C3.85942 19.0718 4.0375 19 4.25 19H19.75C19.9625 19 20.1406 19.0719 20.2843 19.2158C20.4281 19.3596 20.5 19.5378 20.5 19.7502C20.5 19.9629 20.4281 20.141 20.2843 20.2845C20.1406 20.4282 19.9625 20.5 19.75 20.5H4.25Z"/>
169 </svg>
170 `;const yDe=$t`
171 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
172 <path d="M8.85758 18.625C8.4358 18.625 8.07715 18.4772 7.78163 18.1817C7.48613 17.8862 7.33838 17.5275 7.33838 17.1058V6.8942C7.33838 6.47242 7.48613 6.11377 7.78163 5.81825C8.07715 5.52275 8.4358 5.375 8.85758 5.375H12.1999C13.2191 5.375 14.1406 5.69231 14.9643 6.32693C15.788 6.96154 16.1999 7.81603 16.1999 8.89038C16.1999 9.63779 16.0194 10.2471 15.6585 10.7183C15.2976 11.1894 14.9088 11.5314 14.4922 11.7442C15.005 11.9211 15.4947 12.2708 15.9614 12.7933C16.428 13.3157 16.6614 14.0192 16.6614 14.9038C16.6614 16.182 16.1902 17.1217 15.2479 17.723C14.3056 18.3243 13.3563 18.625 12.3999 18.625H8.85758ZM9.4883 16.6327H12.3191C13.1063 16.6327 13.6627 16.4141 13.9884 15.9769C14.314 15.5397 14.4768 15.1205 14.4768 14.7192C14.4768 14.3179 14.314 13.8987 13.9884 13.4615C13.6627 13.0243 13.0909 12.8057 12.273 12.8057H9.4883V16.6327ZM9.4883 10.875H12.0826C12.6903 10.875 13.172 10.7013 13.5278 10.3539C13.8836 10.0064 14.0615 9.59037 14.0615 9.10575C14.0615 8.59035 13.8733 8.16918 13.497 7.84225C13.1207 7.51533 12.6595 7.35188 12.1133 7.35188H9.4883V10.875Z"/>
173 </svg>
174 `;$t`
175 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
176 <g clip-path="url(#clip0_952_6527)">
177 <circle cx="12" cy="12" r="3"/>
178 </g>
179 <defs>
180 <clipPath id="clip0_952_6527">
181 <rect width="24" height="24"/>
182 </clipPath>
183 </defs>
184 </svg>
185 `;const _De=$t`
186 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
187 <g clip-path="url(#clip0_977_8070)">
188 <path d="M4 10.5C3.17 10.5 2.5 11.17 2.5 12C2.5 12.83 3.17 13.5 4 13.5C4.83 13.5 5.5 12.83 5.5 12C5.5 11.17 4.83 10.5 4 10.5ZM4 4.5C3.17 4.5 2.5 5.17 2.5 6C2.5 6.83 3.17 7.5 4 7.5C4.83 7.5 5.5 6.83 5.5 6C5.5 5.17 4.83 4.5 4 4.5ZM4 16.5C3.17 16.5 2.5 17.18 2.5 18C2.5 18.82 3.18 19.5 4 19.5C4.82 19.5 5.5 18.82 5.5 18C5.5 17.18 4.83 16.5 4 16.5ZM8 19H20C20.55 19 21 18.55 21 18C21 17.45 20.55 17 20 17H8C7.45 17 7 17.45 7 18C7 18.55 7.45 19 8 19ZM8 13H20C20.55 13 21 12.55 21 12C21 11.45 20.55 11 20 11H8C7.45 11 7 11.45 7 12C7 12.55 7.45 13 8 13ZM7 6C7 6.55 7.45 7 8 7H20C20.55 7 21 6.55 21 6C21 5.45 20.55 5 20 5H8C7.45 5 7 5.45 7 6Z"/>
189 </g>
190 <defs>
191 <clipPath id="clip0_977_8070">
192 <rect width="24" height="24"/>
193 </clipPath>
194 </defs>
195 </svg>
196 `;$t`
197 <svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 24 24">
198 <path fill="currentColor" d="M9 22a1 1 0 0 1-1-1v-3H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2h-6.1l-3.7 3.71c-.2.19-.45.29-.7.29zm1-6v3.08L13.08 16H20V4H4v12z"/>
199 </svg>
200 `;$t`
201 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
202 <g clip-path="url(#clip0_1803_1151)">
203 <path d="M19 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H19C20.1 21 21 20.1 21 19V5C21 3.9 20.1 3 19 3ZM10.71 16.29C10.32 16.68 9.69 16.68 9.3 16.29L5.71 12.7C5.32 12.31 5.32 11.68 5.71 11.29C6.1 10.9 6.73 10.9 7.12 11.29L10 14.17L16.88 7.29C17.27 6.9 17.9 6.9 18.29 7.29C18.68 7.68 18.68 8.31 18.29 8.7L10.71 16.29Z"/>
204 </g>
205 <defs>
206 <clipPath id="clip0_1803_1151">
207 <rect width="24" height="24"/>
208 </clipPath>
209 </defs>
210 </svg>
211 `;$t`
212 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
213 <g clip-path="url(#clip0_1803_535)">
214 <path d="M18 19H6C5.45 19 5 18.55 5 18V6C5 5.45 5.45 5 6 5H18C18.55 5 19 5.45 19 6V18C19 18.55 18.55 19 18 19ZM19 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H19C20.1 21 21 20.1 21 19V5C21 3.9 20.1 3 19 3Z"/>
215 </g>
216 <defs>
217 <clipPath id="clip0_1803_535">
218 <rect width="24" height="24"/>
219 </clipPath>
220 </defs>
221 </svg>
222 `;$t`
223 <svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="w-6 h-6">
224 <path stroke-linecap="round" stroke-linejoin="round" d="M19.5 8.25l-7.5 7.5-7.5-7.5" />
225 </svg>
226 `;$t`
227 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
228 <g clip-path="url(#clip0_1098_15553)">
229 <path d="M18.3007 5.70973C17.9107 5.31973 17.2807 5.31973 16.8907 5.70973L12.0007 10.5897L7.1107 5.69973C6.7207 5.30973 6.0907 5.30973 5.7007 5.69973C5.3107 6.08973 5.3107 6.71973 5.7007 7.10973L10.5907 11.9997L5.7007 16.8897C5.3107 17.2797 5.3107 17.9097 5.7007 18.2997C6.0907 18.6897 6.7207 18.6897 7.1107 18.2997L12.0007 13.4097L16.8907 18.2997C17.2807 18.6897 17.9107 18.6897 18.3007 18.2997C18.6907 17.9097 18.6907 17.2797 18.3007 16.8897L13.4107 11.9997L18.3007 7.10973C18.6807 6.72973 18.6807 6.08973 18.3007 5.70973Z"/>
230 </g>
231 <defs>
232 <clipPath id="clip0_1098_15553">
233 <rect width="24" height="24"/>
234 </clipPath>
235 </defs>
236 </svg>
237 `;const ZL=$t`
238 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
239 <g clip-path="url(#clip0_977_8081)">
240 <path d="M9.4 16.6L4.8 12L9.4 7.4L8 6L2 12L8 18L9.4 16.6ZM14.6 16.6L19.2 12L14.6 7.4L16 6L22 12L16 18L14.6 16.6Z"/>
241 </g>
242 <defs>
243 <clipPath id="clip0_977_8081">
244 <rect width="24" height="24"/>
245 </clipPath>
246 </defs>
247 </svg>
248 `,bDe=$t`
249 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none">
250 <g clip-path="url(#clip0_1013_1606)">
251 <path d="M9.00012 16.1998L5.50012 12.6998C5.11012 12.3098 4.49012 12.3098 4.10012 12.6998C3.71012 13.0898 3.71012 13.7098 4.10012 14.0998L8.29012 18.2898C8.68012 18.6798 9.31012 18.6798 9.70012 18.2898L20.3001 7.69982C20.6901 7.30982 20.6901 6.68982 20.3001 6.29982C19.9101 5.90982 19.2901 5.90982 18.9001 6.29982L9.00012 16.1998Z" fill="#817567"/>
252 </g>
253 <defs>
254 <clipPath id="clip0_1013_1606">
255 <rect width="24" height="24" />
256 </clipPath>
257 </defs>
258 </svg>
259 `;$t`
260 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
261 <g clip-path="url(#clip0_977_7900)">
262 <path fill-rule="evenodd" clip-rule="evenodd" d="M19 13H5C4.45 13 4 12.55 4 12C4 11.45 4.45 11 5 11H19C19.55 11 20 11.45 20 12C20 12.55 19.55 13 19 13Z"/>
263 </g>
264 <defs>
265 <clipPath id="clip0_977_7900">
266 <rect width="24" height="24"/>
267 </clipPath>
268 </defs>
269 </svg>
270 `;$t`
271 <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
272 <path d="M3.5 9.83366C3.35833 9.83366 3.23961 9.78571 3.14383 9.68983C3.04794 9.59394 3 9.47516 3 9.33349C3 9.19171 3.04794 9.07299 3.14383 8.97733C3.23961 8.88155 3.35833 8.83366 3.5 8.83366H12.5C12.6417 8.83366 12.7604 8.8816 12.8562 8.97749C12.9521 9.07338 13 9.19216 13 9.33383C13 9.4756 12.9521 9.59433 12.8562 9.68999C12.7604 9.78577 12.6417 9.83366 12.5 9.83366H3.5ZM3.5 7.16699C3.35833 7.16699 3.23961 7.11905 3.14383 7.02316C3.04794 6.92727 3 6.80849 3 6.66683C3 6.52505 3.04794 6.40633 3.14383 6.31066C3.23961 6.21488 3.35833 6.16699 3.5 6.16699H12.5C12.6417 6.16699 12.7604 6.21494 12.8562 6.31083C12.9521 6.40671 13 6.52549 13 6.66716C13 6.80894 12.9521 6.92766 12.8562 7.02333C12.7604 7.1191 12.6417 7.16699 12.5 7.16699H3.5Z"/>
273 </svg>
274 `;const wDe=$t`
275 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
276 <g clip-path="url(#clip0_1013_1585)">
277 <path d="M14.06 9.02L14.98 9.94L5.92 19H5V18.08L14.06 9.02ZM17.66 3C17.41 3 17.15 3.1 16.96 3.29L15.13 5.12L18.88 8.87L20.71 7.04C21.1 6.65 21.1 6.02 20.71 5.63L18.37 3.29C18.17 3.09 17.92 3 17.66 3ZM14.06 6.19L3 17.25V21H6.75L17.81 9.94L14.06 6.19Z"/>
278 </g>
279 <defs>
280 <clipPath id="clip0_1013_1585">
281 <rect width="24" height="24"/>
282 </clipPath>
283 </defs>
284 </svg>
285 `;$t`
286 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
287 <g clip-path="url(#clip0_992_5553)">
288 <path d="M19 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H19C20.1 21 21 20.1 21 19V5C21 3.9 20.1 3 19 3ZM19 19H5V5H19V19ZM12 17H14V7H10V9H12V17Z"/>
289 </g>
290 <defs>
291 <clipPath id="clip0_992_5553">
292 <rect width="24" height="24"/>
293 </clipPath>
294 </defs>
295 </svg>
296 `;const CDe=$t`
297 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
298 <g clip-path="url(#clip0_992_5559)">
299 <path d="M19 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H19C20.1 21 21 20.1 21 19V5C21 3.9 20.1 3 19 3ZM19 19H5V5H19V19ZM15 15H11V13H13C14.1 13 15 12.11 15 11V9C15 7.89 14.1 7 13 7H9V9H13V11H11C9.9 11 9 11.89 9 13V17H15V15Z"/>
300 </g>
301 <defs>
302 <clipPath id="clip0_992_5559">
303 <rect width="24" height="24"/>
304 </clipPath>
305 </defs>
306 </svg>
307 `,kDe=$t`
308 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
309 <g clip-path="url(#clip0_992_5565)">
310 <path d="M19 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H19C20.1 21 21 20.1 21 19V5C21 3.9 20.1 3 19 3ZM19 19H5V5H19V19ZM15 15V13.5C15 12.67 14.33 12 13.5 12C14.33 12 15 11.33 15 10.5V9C15 7.89 14.1 7 13 7H9V9H13V11H11V13H13V15H9V17H13C14.1 17 15 16.11 15 15Z"/>
311 </g>
312 <defs>
313 <clipPath id="clip0_992_5565">
314 <rect width="24" height="24"/>
315 </clipPath>
316 </defs>
317 </svg>
318 `,SDe=$t`
319 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
320 <g clip-path="url(#clip0_977_7757)">
321 <path d="M19.04 3H5.04004C3.94004 3 3.04004 3.9 3.04004 5V19C3.04004 20.1 3.94004 21 5.04004 21H19.04C20.14 21 21.04 20.1 21.04 19V5C21.04 3.9 20.14 3 19.04 3ZM19.04 19H5.04004V5H19.04V19ZM13.04 17H15.04V7H13.04V11H11.04V7H9.04004V13H13.04V17Z"/>
322 </g>
323 <defs>
324 <clipPath id="clip0_977_7757">
325 <rect width="24" height="24"/>
326 </clipPath>
327 </defs>
328 </svg>
329 `;$t`
330 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
331 <g clip-path="url(#clip0_977_7760)">
332 <path d="M19 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H19C20.1 21 21 20.1 21 19V5C21 3.9 20.1 3 19 3ZM19 19H5V5H19V19ZM15 15V13C15 11.89 14.1 11 13 11H11V9H15V7H9V13H13V15H9V17H13C14.1 17 15 16.11 15 15Z"/>
333 </g>
334 <defs>
335 <clipPath id="clip0_977_7760">
336 <rect width="24" height="24"/>
337 </clipPath>
338 </defs>
339 </svg>
340 `;$t`
341 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
342 <g clip-path="url(#clip0_977_7763)">
343 <path d="M11 17H13C14.1 17 15 16.11 15 15V13C15 11.89 14.1 11 13 11H11V9H15V7H11C9.9 7 9 7.89 9 9V15C9 16.11 9.9 17 11 17ZM11 13H13V15H11V13ZM19 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H19C20.1 21 21 20.1 21 19V5C21 3.9 20.1 3 19 3ZM19 19H5V5H19V19Z"/>
344 </g>
345 <defs>
346 <clipPath id="clip0_977_7763">
347 <rect width="24" height="24"/>
348 </clipPath>
349 </defs>
350 </svg>
351 `;$t`
352 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
353 <g clip-path="url(#clip0_977_8075)">
354 <path d="M19 5V19H5V5H19ZM19 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H19C20.1 21 21 20.1 21 19V5C21 3.9 20.1 3 19 3ZM14.14 11.86L11.14 15.73L9 13.14L6 17H18L14.14 11.86Z"/>
355 </g>
356 <defs>
357 <clipPath id="clip0_977_8075">
358 <rect width="24" height="24"/>
359 </clipPath>
360 </defs>
361 </svg>
362 `;const $De=$t`
363 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
364 <path d="M6.29811 18.625C6.04505 18.625 5.83115 18.5375 5.65641 18.3626C5.48166 18.1877 5.39429 17.9736 5.39429 17.7203C5.39429 17.467 5.48166 17.2532 5.65641 17.0788C5.83115 16.9045 6.04505 16.8173 6.29811 16.8173H9.21159L12.452 7.18265H9.53851C9.28545 7.18265 9.07155 7.0952 8.89681 6.9203C8.72206 6.7454 8.63469 6.5313 8.63469 6.278C8.63469 6.02472 8.72206 5.81089 8.89681 5.63652C9.07155 5.46217 9.28545 5.375 9.53851 5.375H16.8847C17.1377 5.375 17.3516 5.46245 17.5264 5.63735C17.7011 5.81225 17.7885 6.02634 17.7885 6.27962C17.7885 6.53293 17.7011 6.74676 17.5264 6.92113C17.3516 7.09548 17.1377 7.18265 16.8847 7.18265H14.2789L11.0385 16.8173H13.6443C13.8973 16.8173 14.1112 16.9048 14.286 17.0797C14.4607 17.2546 14.5481 17.4687 14.5481 17.722C14.5481 17.9752 14.4607 18.1891 14.286 18.3634C14.1112 18.5378 13.8973 18.625 13.6443 18.625H6.29811Z"/>
365 </svg>
366 `,JL=$t`
367 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
368 <path d="M17.0385 19.5003V16.5388H14.0769V15.0388H17.0385V12.0773H18.5384V15.0388H21.5V16.5388H18.5384V19.5003H17.0385ZM10.8077 16.5388H7.03845C5.78282 16.5388 4.7125 16.0963 3.8275 15.2114C2.9425 14.3266 2.5 13.2564 2.5 12.0009C2.5 10.7454 2.9425 9.67504 3.8275 8.78979C4.7125 7.90454 5.78282 7.46191 7.03845 7.46191H10.8077V8.96186H7.03845C6.1987 8.96186 5.48235 9.25834 4.8894 9.85129C4.29645 10.4442 3.99998 11.1606 3.99998 12.0003C3.99998 12.8401 4.29645 13.5564 4.8894 14.1494C5.48235 14.7423 6.1987 15.0388 7.03845 15.0388H10.8077V16.5388ZM8.25 12.7503V11.2504H15.75V12.7503H8.25ZM21.5 12.0003H20C20 11.1606 19.7035 10.4442 19.1106 9.85129C18.5176 9.25834 17.8013 8.96186 16.9615 8.96186H13.1923V7.46191H16.9615C18.2171 7.46191 19.2875 7.90441 20.1725 8.78939C21.0575 9.67439 21.5 10.7447 21.5 12.0003Z"/>
369 </svg>
370 `;$t`
371 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
372 <g clip-path="url(#clip0_971_7680)">
373 <path d="M11 18C11 19.1 10.1 20 9 20C7.9 20 7 19.1 7 18C7 16.9 7.9 16 9 16C10.1 16 11 16.9 11 18ZM9 10C7.9 10 7 10.9 7 12C7 13.1 7.9 14 9 14C10.1 14 11 13.1 11 12C11 10.9 10.1 10 9 10ZM9 4C7.9 4 7 4.9 7 6C7 7.1 7.9 8 9 8C10.1 8 11 7.1 11 6C11 4.9 10.1 4 9 4ZM15 8C16.1 8 17 7.1 17 6C17 4.9 16.1 4 15 4C13.9 4 13 4.9 13 6C13 7.1 13.9 8 15 8ZM15 10C13.9 10 13 10.9 13 12C13 13.1 13.9 14 15 14C16.1 14 17 13.1 17 12C17 10.9 16.1 10 15 10ZM15 16C13.9 16 13 16.9 13 18C13 19.1 13.9 20 15 20C16.1 20 17 19.1 17 18C17 16.9 16.1 16 15 16Z" />
374 </g>
375 <defs>
376 <clipPath id="clip0_971_7680">
377 <rect width="24" height="24"/>
378 </clipPath>
379 </defs>
380 </svg>
381 `;const EDe=$t`
382 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
383 <g clip-path="url(#clip0_977_8067)">
384 <path d="M8 7H20C20.55 7 21 6.55 21 6C21 5.45 20.55 5 20 5H8C7.45 5 7 5.45 7 6C7 6.55 7.45 7 8 7ZM20 17H8C7.45 17 7 17.45 7 18C7 18.55 7.45 19 8 19H20C20.55 19 21 18.55 21 18C21 17.45 20.55 17 20 17ZM20 11H8C7.45 11 7 11.45 7 12C7 12.55 7.45 13 8 13H20C20.55 13 21 12.55 21 12C21 11.45 20.55 11 20 11ZM4.5 16H2.5C2.22 16 2 16.22 2 16.5C2 16.78 2.22 17 2.5 17H4V17.5H3.5C3.22 17.5 3 17.72 3 18C3 18.28 3.22 18.5 3.5 18.5H4V19H2.5C2.22 19 2 19.22 2 19.5C2 19.78 2.22 20 2.5 20H4.5C4.78 20 5 19.78 5 19.5V16.5C5 16.22 4.78 16 4.5 16ZM2.5 5H3V7.5C3 7.78 3.22 8 3.5 8C3.78 8 4 7.78 4 7.5V4.5C4 4.22 3.78 4 3.5 4H2.5C2.22 4 2 4.22 2 4.5C2 4.78 2.22 5 2.5 5ZM4.5 10H2.5C2.22 10 2 10.22 2 10.5C2 10.78 2.22 11 2.5 11H3.8L2.12 12.96C2.04 13.05 2 13.17 2 13.28V13.5C2 13.78 2.22 14 2.5 14H4.5C4.78 14 5 13.78 5 13.5C5 13.22 4.78 13 4.5 13H3.2L4.88 11.04C4.96 10.95 5 10.83 5 10.72V10.5C5 10.22 4.78 10 4.5 10Z"/>
385 </g>
386 <defs>
387 <clipPath id="clip0_977_8067">
388 <rect width="24" height="24"/>
389 </clipPath>
390 </defs>
391 </svg>
392 `;$t`
393 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
394 <g clip-path="url(#clip0_971_7676)">
395 <path d="M18 13H13V18C13 18.55 12.55 19 12 19C11.45 19 11 18.55 11 18V13H6C5.45 13 5 12.55 5 12C5 11.45 5.45 11 6 11H11V6C11 5.45 11.45 5 12 5C12.55 5 13 5.45 13 6V11H18C18.55 11 19 11.45 19 12C19 12.55 18.55 13 18 13Z"/>
396 </g>
397 <defs>
398 <clipPath id="clip0_971_7676">
399 <rect width="24" height="24"/>
400 </clipPath>
401 </defs>
402 </svg>
403 `;const xDe=$t`
404 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
405 <g clip-path="url(#clip0_977_7897)">
406 <path d="M7.17 17C7.68 17 8.15 16.71 8.37 16.26L9.79 13.42C9.93 13.14 10 12.84 10 12.53V8C10 7.45 9.55 7 9 7H5C4.45 7 4 7.45 4 8V12C4 12.55 4.45 13 5 13H7L5.97 15.06C5.52 15.95 6.17 17 7.17 17ZM17.17 17C17.68 17 18.15 16.71 18.37 16.26L19.79 13.42C19.93 13.14 20 12.84 20 12.53V8C20 7.45 19.55 7 19 7H15C14.45 7 14 7.45 14 8V12C14 12.55 14.45 13 15 13H17L15.97 15.06C15.52 15.95 16.17 17 17.17 17Z"/>
407 </g>
408 <defs>
409 <clipPath id="clip0_977_7897">
410 <rect width="24" height="24"/>
411 </clipPath>
412 </defs>
413 </svg>
414 `,MDe=$t`
415 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
416 <path d="M7.30775 20.4997C6.81058 20.4997 6.385 20.3227 6.031 19.9687C5.677 19.6147 5.5 19.1892 5.5 18.692V5.99973H5.25C5.0375 5.99973 4.85942 5.92782 4.71575 5.78398C4.57192 5.64015 4.5 5.46198 4.5 5.24948C4.5 5.03682 4.57192 4.85873 4.71575 4.71523C4.85942 4.57157 5.0375 4.49973 5.25 4.49973H9C9 4.2549 9.08625 4.04624 9.25875 3.87374C9.43108 3.7014 9.63967 3.61523 9.8845 3.61523H14.1155C14.3603 3.61523 14.5689 3.7014 14.7413 3.87374C14.9138 4.04624 15 4.2549 15 4.49973H18.75C18.9625 4.49973 19.1406 4.57165 19.2843 4.71548C19.4281 4.85932 19.5 5.03748 19.5 5.24998C19.5 5.46265 19.4281 5.64073 19.2843 5.78423C19.1406 5.9279 18.9625 5.99973 18.75 5.99973H18.5V18.692C18.5 19.1892 18.323 19.6147 17.969 19.9687C17.615 20.3227 17.1894 20.4997 16.6923 20.4997H7.30775ZM17 5.99973H7V18.692C7 18.7818 7.02883 18.8556 7.0865 18.9132C7.14417 18.9709 7.21792 18.9997 7.30775 18.9997H16.6923C16.7821 18.9997 16.8558 18.9709 16.9135 18.9132C16.9712 18.8556 17 18.7818 17 18.692V5.99973ZM10.1543 16.9997C10.3668 16.9997 10.5448 16.9279 10.6885 16.7842C10.832 16.6404 10.9037 16.4622 10.9037 16.2497V8.74973C10.9037 8.53723 10.8318 8.35907 10.688 8.21523C10.5443 8.07157 10.3662 7.99973 10.1535 7.99973C9.941 7.99973 9.76292 8.07157 9.61925 8.21523C9.47575 8.35907 9.404 8.53723 9.404 8.74973V16.2497C9.404 16.4622 9.47583 16.6404 9.6195 16.7842C9.76333 16.9279 9.94158 16.9997 10.1543 16.9997ZM13.8465 16.9997C14.059 16.9997 14.2371 16.9279 14.3807 16.7842C14.5243 16.6404 14.596 16.4622 14.596 16.2497V8.74973C14.596 8.53723 14.5242 8.35907 14.3805 8.21523C14.2367 8.07157 14.0584 7.99973 13.8458 7.99973C13.6333 7.99973 13.4552 8.07157 13.3115 8.21523C13.168 8.35907 13.0962 8.53723 13.0962 8.74973V16.2497C13.0962 16.4622 13.1682 16.6404 13.312 16.7842C13.4557 16.9279 13.6338 16.9997 13.8465 16.9997Z"/>
417 </svg>
418 `;$t`
419 <svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="w-6 h-6">
420 <path stroke-linecap="round" stroke-linejoin="round" d="M21 21l-5.197-5.197m0 0A7.5 7.5 0 105.196 5.196a7.5 7.5 0 0010.607 10.607z" />
421 </svg>
422 `;const TDe=$t`
423 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
424 <path d="M3.25 13.7404C3.0375 13.7404 2.85938 13.6684 2.71563 13.5246C2.57188 13.3808 2.5 13.2026 2.5 12.99C2.5 12.7774 2.57188 12.5993 2.71563 12.4558C2.85938 12.3122 3.0375 12.2404 3.25 12.2404H20.75C20.9625 12.2404 21.1406 12.3123 21.2843 12.4561C21.4281 12.5999 21.5 12.7781 21.5 12.9907C21.5 13.2033 21.4281 13.3814 21.2843 13.525C21.1406 13.6686 20.9625 13.7404 20.75 13.7404H3.25ZM10.9423 10.2596V6.62495H6.5673C6.2735 6.62495 6.02377 6.52201 5.8181 6.31613C5.61245 6.11026 5.50963 5.86027 5.50963 5.56615C5.50963 5.27205 5.61245 5.02083 5.8181 4.8125C6.02377 4.60417 6.2735 4.5 6.5673 4.5H17.4423C17.7361 4.5 17.9858 4.60294 18.1915 4.80883C18.3971 5.01471 18.5 5.2647 18.5 5.5588C18.5 5.85292 18.3971 6.10413 18.1915 6.31245C17.9858 6.52078 17.7361 6.62495 17.4423 6.62495H13.0673V10.2596H10.9423ZM10.9423 15.7211H13.0673V18.4423C13.0673 18.7361 12.9643 18.9858 12.7584 19.1915C12.5526 19.3971 12.3026 19.5 12.0085 19.5C11.7144 19.5 11.4631 19.3962 11.2548 19.1887C11.0465 18.9811 10.9423 18.7291 10.9423 18.4327V15.7211Z"/>
425 </svg>
426 `;$t`
427 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
428 <g clip-path="url(#clip0_977_8078)">
429 <path d="M20 3H5C3.9 3 3 3.9 3 5V19C3 20.1 3.9 21 5 21H20C21.1 21 22 20.1 22 19V5C22 3.9 21.1 3 20 3ZM20 5V8H5V5H20ZM15 19H10V10H15V19ZM5 10H8V19H5V10ZM17 19V10H20V19H17Z"/>
430 </g>
431 <defs>
432 <clipPath id="clip0_977_8078">
433 <rect width="24" height="24"/>
434 </clipPath>
435 </defs>
436 </svg>
437 `;const ODe=$t`
438 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
439 <g clip-path="url(#clip0_992_5547)">
440 <path d="M5 5.5C5 6.33 5.67 7 6.5 7H10.5V17.5C10.5 18.33 11.17 19 12 19C12.83 19 13.5 18.33 13.5 17.5V7H17.5C18.33 7 19 6.33 19 5.5C19 4.67 18.33 4 17.5 4H6.5C5.67 4 5 4.67 5 5.5Z"/>
441 </g>
442 <defs>
443 <clipPath id="clip0_992_5547">
444 <rect width="24" height="24"/>
445 </clipPath>
446 </defs>
447 </svg>
448 `;$t`
449 <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">
450 <path d="M5.66936 16.3389L9.39244 12.6158C9.54115 12.4671 9.71679 12.3937 9.91936 12.3957C10.1219 12.3976 10.2975 12.4761 10.4463 12.6312C10.5847 12.7823 10.654 12.9585 10.654 13.1599C10.654 13.3613 10.5847 13.5363 10.4463 13.6851L6.32704 17.8197C6.14627 18.0004 5.93538 18.0908 5.69436 18.0908C5.45333 18.0908 5.24243 18.0004 5.06166 17.8197L3.01744 15.7754C2.87899 15.637 2.81136 15.4629 2.81456 15.2533C2.81776 15.0437 2.88859 14.8697 3.02706 14.7312C3.16551 14.5928 3.34008 14.5235 3.55076 14.5235C3.76144 14.5235 3.93494 14.5928 4.07126 14.7312L5.66936 16.3389ZM5.66936 8.72359L9.39244 5.00049C9.54115 4.85177 9.71679 4.77838 9.91936 4.78031C10.1219 4.78223 10.2975 4.86075 10.4463 5.01586C10.5847 5.16691 10.654 5.34314 10.654 5.54454C10.654 5.74592 10.5847 5.92097 10.4463 6.06969L6.32704 10.2043C6.14627 10.3851 5.93538 10.4755 5.69436 10.4755C5.45333 10.4755 5.24243 10.3851 5.06166 10.2043L3.01744 8.16009C2.87899 8.02162 2.81136 7.84759 2.81456 7.63799C2.81776 7.42837 2.88859 7.25433 3.02706 7.11586C3.16551 6.97741 3.34008 6.90819 3.55076 6.90819C3.76144 6.90819 3.93494 6.97741 4.07126 7.11586L5.66936 8.72359ZM13.7597 16.5581C13.5472 16.5581 13.3691 16.4862 13.2253 16.3424C13.0816 16.1986 13.0097 16.0204 13.0097 15.8078C13.0097 15.5952 13.0816 15.4171 13.2253 15.2735C13.3691 15.13 13.5472 15.0582 13.7597 15.0582H20.7597C20.9722 15.0582 21.1503 15.1301 21.2941 15.2739C21.4378 15.4177 21.5097 15.5959 21.5097 15.8085C21.5097 16.0211 21.4378 16.1992 21.2941 16.3427C21.1503 16.4863 20.9722 16.5581 20.7597 16.5581H13.7597ZM13.7597 8.94276C13.5472 8.94276 13.3691 8.87085 13.2253 8.72704C13.0816 8.58324 13.0097 8.40504 13.0097 8.19244C13.0097 7.97985 13.0816 7.80177 13.2253 7.65819C13.3691 7.5146 13.5472 7.44281 13.7597 7.44281H20.7597C20.9722 7.44281 21.1503 7.51471 21.2941 7.65851C21.4378 7.80233 21.5097 7.98053 21.5097 8.19311C21.5097 8.40571 21.4378 8.5838 21.2941 8.72739C21.1503 8.87097 20.9722 8.94276 20.7597 8.94276H13.7597Z"/>
451 </svg>
452 `;const IDe=(e,t)=>{e.config(gDe).config(n=>{n.update(Tv.key,o=>({...o,linkIcon:(t==null?void 0:t.linkIcon)??(()=>JL),editButton:(t==null?void 0:t.editButton)??(()=>wDe),removeButton:(t==null?void 0:t.removeButton)??(()=>MDe),confirmButton:(t==null?void 0:t.confirmButton)??(()=>bDe),inputPlaceholder:(t==null?void 0:t.inputPlaceholder)??"Paste link...",onCopyLink:(t==null?void 0:t.onCopyLink)??(()=>{})}))}).use(vDe)},ADe=Object.freeze(Object.defineProperty({__proto__:null,defineFeature:IDe},Symbol.toStringTag,{value:"Module"}));var XL="Expected a function",h$=0/0,NDe="[object Symbol]",PDe=/^\s+|\s+$/g,LDe=/^[-+]0x[0-9a-f]+$/i,RDe=/^0b[01]+$/i,DDe=/^0o[0-7]+$/i,FDe=parseInt,VDe=typeof On=="object"&&On&&On.Object===Object&&On,BDe=typeof self=="object"&&self&&self.Object===Object&&self,zDe=VDe||BDe||Function("return this")(),jDe=Object.prototype,HDe=jDe.toString,UDe=Math.max,WDe=Math.min,i_=function(){return zDe.Date.now()};function KDe(e,t,n){var o,r,s,i,l,a,u=0,c=!1,d=!1,f=!0;if(typeof e!="function")throw new TypeError(XL);t=m$(t)||0,l0(n)&&(c=!!n.leading,d="maxWait"in n,s=d?UDe(m$(n.maxWait)||0,t):s,f="trailing"in n?!!n.trailing:f);function p(E){var T=o,O=r;return o=r=void 0,u=E,i=e.apply(O,T),i}function h(E){return u=E,l=setTimeout(v,t),c?p(E):i}function m(E){var T=E-a,O=E-u,P=t-T;return d?WDe(P,s-O):P}function y(E){var T=E-a,O=E-u;return a===void 0||T>=t||T<0||d&&O>=s}function v(){var E=i_();if(y(E))return w(E);l=setTimeout(v,m(E))}function w(E){return l=void 0,f&&o?p(E):(o=r=void 0,i)}function _(){l!==void 0&&clearTimeout(l),u=0,o=a=r=l=void 0}function S(){return l===void 0?i:w(i_())}function x(){var E=i_(),T=y(E);if(o=arguments,r=this,a=E,T){if(l===void 0)return h(a);if(d)return l=setTimeout(v,t),p(a)}return l===void 0&&(l=setTimeout(v,t)),i}return x.cancel=_,x.flush=S,x}function qDe(e,t,n){var o=!0,r=!0;if(typeof e!="function")throw new TypeError(XL);return l0(n)&&(o="leading"in n?!!n.leading:o,r="trailing"in n?!!n.trailing:r),KDe(e,t,{leading:o,maxWait:t,trailing:r})}function l0(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function GDe(e){return!!e&&typeof e=="object"}function YDe(e){return typeof e=="symbol"||GDe(e)&&HDe.call(e)==NDe}function m$(e){if(typeof e=="number")return e;if(YDe(e))return h$;if(l0(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=l0(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace(PDe,"");var n=RDe.test(e);return n||DDe.test(e)?FDe(e.slice(2),n?2:8):LDe.test(e)?h$:+e}var ZDe=qDe;const JDe=_o(ZDe);var QL=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},Ht=(e,t,n)=>(QL(e,t,"read from private field"),n?n.call(e):t.get(e)),co=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},sn=(e,t,n,o)=>(QL(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n);function Iv(e,t){return Object.assign(e,{meta:{package:"@milkdown/plugin-block",...t}}),e}const XDe=e=>!cC(t=>t.type.name==="table")(e),Hh=In({filterNodes:XDe},"blockConfig");Iv(Hh,{displayName:"Ctx<blockConfig>"});function QDe(e,t,n){var o;if(!e.dom.parentElement)return null;const r=(o=e.posAtCoords({left:t.x,top:t.y}))==null?void 0:o.inside;if(r==null||r<0)return null;let s=e.state.doc.resolve(r),i=e.state.doc.nodeAt(r),l=e.nodeDOM(r);const a=c=>{const d=s.depth>=1&&s.index(s.depth)===0;if(!(c||d))return;const f=s.before(s.depth);i=e.state.doc.nodeAt(f),l=e.nodeDOM(f),s=e.state.doc.resolve(f),n(s,i)||a(!0)},u=n(s,i);return a(!u),!l||!i?null:{node:i,$pos:s,el:l}}let g$=null;function eFe(){return g$||(g$=document.implementation.createHTMLDocument("title"))}const tFe={thead:["table"],tbody:["table"],tfoot:["table"],caption:["table"],colgroup:["table"],col:["table","colgroup"],tr:["table","tbody"],td:["table","tbody","tr"],th:["table","tbody","tr"]};function nFe(e,t){const n=[];let{openStart:o,openEnd:r,content:s}=t;for(;o>1&&r>1&&s.childCount===1&&s.firstChild.childCount===1;){o-=1,r-=1;const p=s.firstChild;n.push(p.type.name,p.attrs!==p.type.defaultAttrs?p.attrs:null),s=p.content}const i=e.someProp("clipboardSerializer")||ta.fromSchema(e.state.schema),l=eFe(),a=l.createElement("div");a.appendChild(i.serializeFragment(s,{document:l}));let u=a.firstChild,c,d=0;for(;u&&u.nodeType===1&&(c=tFe[u.nodeName.toLowerCase()]);){for(let p=c.length-1;p>=0;p--){const h=l.createElement(c[p]);for(;a.firstChild;)h.appendChild(a.firstChild);a.appendChild(h),d++}u=a.firstChild}u&&u.nodeType===1&&u.setAttribute("data-pm-slice",`${o} ${r}${d?` -${d}`:""} ${JSON.stringify(n)}`);const f=e.someProp("clipboardTextSerializer",p=>p(t,e))||t.content.textBetween(0,t.content.size,`
453
454 `);return{dom:a,text:f}}const v$=Sm.ie&&Sm.ie_version<15||Sm.ios&&Sm.webkit_version<604,y$=20;var dp,Z1,uc,Ns,Mf,Ps,U2,eR,cc,Tf,dc,fc,J1,Of,If,Af,X1,pc;class oFe{constructor(){co(this,U2),co(this,cc),co(this,dp,void 0),co(this,Z1,void 0),co(this,uc,void 0),co(this,Ns,void 0),co(this,Mf,void 0),co(this,Ps,void 0),co(this,dc,void 0),co(this,fc,void 0),co(this,J1,void 0),co(this,Of,void 0),co(this,If,void 0),co(this,Af,void 0),co(this,X1,void 0),co(this,pc,void 0),sn(this,Z1,()=>{if(!Ht(this,Ns))return null;const t=Ht(this,Ns),n=Ht(this,cc,Tf);if(n&&mt.isSelectable(t.node)){const o=mt.create(n.state.doc,t.$pos.pos);return n.dispatch(n.state.tr.setSelection(o)),n.focus(),sn(this,uc,o),o}return null}),sn(this,uc,null),sn(this,Ns,null),sn(this,Mf,void 0),sn(this,Ps,!1),sn(this,fc,()=>{var t;(t=Ht(this,dc))==null||t.call(this,{type:"hide"}),sn(this,Ns,null)}),sn(this,J1,t=>{var n;sn(this,Ns,t),(n=Ht(this,dc))==null||n.call(this,{type:"show",active:t})}),this.bind=(t,n)=>{sn(this,dp,t),sn(this,dc,n)},this.addEvent=t=>{t.addEventListener("mousedown",Ht(this,Of)),t.addEventListener("mouseup",Ht(this,If)),t.addEventListener("dragstart",Ht(this,Af))},this.removeEvent=t=>{t.removeEventListener("mousedown",Ht(this,Of)),t.removeEventListener("mouseup",Ht(this,If)),t.removeEventListener("dragstart",Ht(this,Af))},this.unBind=()=>{sn(this,dc,void 0)},sn(this,Of,()=>{var t;sn(this,Mf,(t=Ht(this,Ns))==null?void 0:t.el.getBoundingClientRect()),Ht(this,Z1).call(this)}),sn(this,If,()=>{if(!Ht(this,Ps)){requestAnimationFrame(()=>{var t;Ht(this,Mf)&&((t=Ht(this,cc,Tf))==null||t.focus())});return}sn(this,Ps,!1),sn(this,uc,null)}),sn(this,Af,t=>{var n;sn(this,Ps,!0);const o=Ht(this,cc,Tf);if(!o)return;o.dom.dataset.dragging="true";const r=Ht(this,uc);if(t.dataTransfer&&r){const s=r.content();t.dataTransfer.effectAllowed="copyMove";const{dom:i,text:l}=nFe(o,s);t.dataTransfer.clearData(),t.dataTransfer.setData(v$?"Text":"text/html",i.innerHTML),v$||t.dataTransfer.setData("text/plain",l);const a=(n=Ht(this,Ns))==null?void 0:n.el;a&&t.dataTransfer.setDragImage(a,0,0),o.dragging={slice:s,move:!0}}}),this.keydownCallback=t=>(Ht(this,fc).call(this),sn(this,Ps,!1),t.dom.dataset.dragging="false",!1),sn(this,X1,JDe((t,n)=>{if(!t.editable)return;const o=t.dom.getBoundingClientRect(),r=o.left+o.width/2;if(!(t.root.elementFromPoint(r,n.clientY)instanceof Element)){Ht(this,fc).call(this);return}const s=Ht(this,U2,eR);if(!s)return;const i=QDe(t,{x:r,y:n.clientY},s);if(!i){Ht(this,fc).call(this);return}Ht(this,J1).call(this,i)},200)),this.mousemoveCallback=(t,n)=>(t.composing||!t.editable||Ht(this,X1).call(this,t,n),!1),this.dragoverCallback=(t,n)=>{var o;if(Ht(this,Ps)){const r=(o=Ht(this,cc,Tf))==null?void 0:o.dom.parentElement;if(!r)return!1;const s=r.scrollHeight>r.clientHeight,i=r.getBoundingClientRect();if(s){if(r.scrollTop>0&&Math.abs(n.y-i.y)<y$){const a=r.scrollTop>10?r.scrollTop-10:0;return r.scrollTop=a,!1}const l=Math.round(t.dom.getBoundingClientRect().height);if(Math.round(r.scrollTop+i.height)<l&&Math.abs(n.y-(i.height+i.y))<y$){const a=r.scrollTop+10;return r.scrollTop=a,!1}}}return!1},this.dragenterCallback=t=>{t.dragging&&(sn(this,Ps,!0),t.dom.dataset.dragging="true")},this.dragleaveCallback=(t,n)=>{const o=n.clientX,r=n.clientY;(o<0||r<0||o>window.innerWidth||r>window.innerHeight)&&(sn(this,Ns,null),Ht(this,pc).call(this,t))},this.dropCallback=t=>(Ht(this,pc).call(this,t),!1),this.dragendCallback=t=>{Ht(this,pc).call(this,t)},sn(this,pc,t=>{sn(this,Ps,!1),t.dom.dataset.dragging="false"})}}dp=new WeakMap,Z1=new WeakMap,uc=new WeakMap,Ns=new WeakMap,Mf=new WeakMap,Ps=new WeakMap,U2=new WeakSet,eR=function(){var e;return(e=Ht(this,dp))==null?void 0:e.get(Hh.key).filterNodes},cc=new WeakSet,Tf=function(){var e;return(e=Ht(this,dp))==null?void 0:e.get(bn)},dc=new WeakMap,fc=new WeakMap,J1=new WeakMap,Of=new WeakMap,If=new WeakMap,Af=new WeakMap,X1=new WeakMap,pc=new WeakMap;const tR=In(new oFe,"blockService");Iv(Hh,{displayName:"Ctx<blockService>"});const zk=In({},"blockSpec");Iv(Hh,{displayName:"Ctx<blockSpec>"});const jk=ao(e=>{const t=new wn("MILKDOWN_BLOCK"),n=e.get(tR.key),o=e.get(zk.key);return new xn({key:t,...o,props:{...o.props,handleDOMEvents:{drop:r=>n.dropCallback(r),pointermove:(r,s)=>n.mousemoveCallback(r,s),keydown:r=>n.keydownCallback(r),dragover:(r,s)=>n.dragoverCallback(r,s),dragleave:(r,s)=>n.dragleaveCallback(r,s),dragenter:r=>n.dragenterCallback(r),dragend:r=>n.dragendCallback(r)}}})});Iv(jk,{displayName:"Prose<block>"});const Hk=[zk,Hh,tR,jk];Hk.key=zk.key;Hk.pluginKey=jk.key;var Uk=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},El=(e,t,n)=>(Uk(e,t,"read from private field"),n?n.call(e):t.get(e)),ha=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},ma=(e,t,n,o)=>(Uk(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),rFe=(e,t,n)=>(Uk(e,t,"access private method"),n);function sFe(e){const t=In({},`${e}_SLASH_SPEC`),n=ao(r=>{const s=r.get(t.key);return new xn({key:new wn(`${e}_SLASH`),...s})}),o=[t,n];return o.key=t.key,o.pluginKey=n.key,t.meta={package:"@milkdown/plugin-slash",displayName:`Ctx<slashSpec>|${e}`},n.meta={package:"@milkdown/plugin-slash",displayName:`Prose<slash>|${e}`},o}var Nf,Q1,hc,eg,tg,ng,W2,nR;class iFe{constructor(t){ha(this,W2),ha(this,Nf,void 0),ha(this,Q1,void 0),ha(this,hc,void 0),ha(this,eg,void 0),ha(this,tg,void 0),ha(this,ng,void 0),ma(this,Nf,!1),this.onShow=()=>{},this.onHide=()=>{},ma(this,ng,(n,o)=>{var r;const{state:s,composing:i}=n,{selection:l,doc:a}=s,{ranges:u}=l,c=Math.min(...u.map(p=>p.$from.pos)),d=Math.max(...u.map(p=>p.$to.pos)),f=o&&o.doc.eq(a)&&o.selection.eq(l);if(El(this,Nf)||((r=n.dom.parentElement)==null||r.appendChild(this.element),ma(this,Nf,!0)),!(i||f)){if(!El(this,eg).call(this,n,o)){this.hide();return}tb({getBoundingClientRect:()=>av(n,c,d)},this.element,{placement:"bottom-start",middleware:[eb(),X_(El(this,tg))]}).then(({x:p,y:h})=>{Object.assign(this.element.style,{left:`${p}px`,top:`${h}px`})}),this.show()}}),this.update=(n,o)=>{Sv(El(this,ng),El(this,Q1))(n,o)},this.getContent=(n,o=r=>r.type.name==="paragraph")=>{const{selection:r}=n.state,{empty:s,$from:i}=r,l=n.state.selection instanceof ht,a=this.element.contains(document.activeElement),u=!n.hasFocus()&&!a,c=!n.editable,d=!lwe(o)(n.state.selection);if(!(u||c||!s||!l||d))return i.parent.textBetween(Math.max(0,i.parentOffset-500),i.parentOffset,void 0,"")},this.destroy=()=>{},this.show=()=>{this.element.dataset.show="true",this.onShow()},this.hide=()=>{this.element.dataset.show="false",this.onHide()},this.element=t.content,ma(this,Q1,t.debounce??200),ma(this,eg,t.shouldShow??rFe(this,W2,nR)),ma(this,hc,t.trigger??"/"),ma(this,tg,t.offset)}}Nf=new WeakMap,Q1=new WeakMap,hc=new WeakMap,eg=new WeakMap,tg=new WeakMap,ng=new WeakMap,W2=new WeakSet,nR=function(e){const t=this.getContent(e);if(!t)return!1;const n=t.at(-1);return n?Array.isArray(El(this,hc))?El(this,hc).includes(n):El(this,hc)===n:!1};function oR(e){return e.$from.parent.type.name==="code_block"}function rR(e){var n;const t=(n=e.$from.node(e.$from.depth-1))==null?void 0:n.type;return(t==null?void 0:t.name)==="list_item"}function sR(e,t){customElements.get(e)==null&&customElements.define(e,t)}function Wk(e){const{$from:t,$to:n}=e.selection,{pos:o}=t,{pos:r}=n;return e=e.deleteRange(o-t.node().content.size,r),e}function lFe(e,t,n=null){const{from:o,to:r}=e.selection;return e.setBlockType(o,r,t,n)}function aFe(e,t,n=null){const{$from:o,$to:r}=e.selection,s=o.blockRange(r),i=s&&iC(s,t,n);return i?e.wrap(s,i):null}function uFe(e,t,n=null){const o=t.createAndFill(n);return o?e.replaceSelectionWith(o):null}function Rm(e,t=null){return(n,o)=>{if(o){const r=lFe(Wk(n.tr),e,t);o(r.scrollIntoView())}return!0}}function l_(e,t=null){return(n,o)=>{const r=aFe(Wk(n.tr),e,t);return r?(o&&o(r.scrollIntoView()),!0):!1}}function cFe(e,t=null){return(n,o)=>{const r=uFe(Wk(n.tr),e,t);return r?(o&&o(r.scrollIntoView()),!0):!1}}var xl,Lc;class dFe{constructor(){xs(this,xl,void 0);xs(this,Lc,void 0);Lo(this,xl,[]),this.clear=()=>(Lo(this,xl,[]),this),Lo(this,Lc,t=>{const n={group:t,addItem:(o,r)=>{const s={key:o,...r};return t.items.push(s),n},clear:()=>(t.items=[],n)};return n}),this.addGroup=(t,n)=>{const r={key:t,label:n,items:[]};return kt(this,xl).push(r),kt(this,Lc).call(this,r)},this.getGroup=t=>{const n=kt(this,xl).find(o=>o.key===t);if(!n)throw new Error(`Group with key ${t} not found`);return kt(this,Lc).call(this,n)},this.build=()=>kt(this,xl)}}xl=new WeakMap,Lc=new WeakMap;function Ts(e){return window.fluentComAdmin.i18n[e]||e}function fFe(e,t){var s,i,l,a,u,c,d,f,p;const n=new dFe;n.addGroup("text",(t==null?void 0:t.slashMenuTextGroupLabel)??Ts("Text")).addItem("text",{label:(t==null?void 0:t.slashMenuTextGroupLabel)??Ts("Text"),icon:((s=t==null?void 0:t.slashMenuTextIcon)==null?void 0:s.call(t))??ODe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;Rm(ji.type(h))(v,y)}}).addItem("h2",{label:(t==null?void 0:t.slashMenuH2Label)??Ts("Heading 2"),icon:((i=t==null?void 0:t.slashMenuH2Icon)==null?void 0:i.call(t))??CDe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;Rm(Ws.type(h),{level:2})(v,y)}}).addItem("h3",{label:(t==null?void 0:t.slashMenuH3Label)??Ts("Heading 3"),icon:((l=t==null?void 0:t.slashMenuH3Icon)==null?void 0:l.call(t))??kDe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;Rm(Ws.type(h),{level:3})(v,y)}}).addItem("h4",{label:(t==null?void 0:t.slashMenuH4Label)??Ts("Heading 4"),icon:((a=t==null?void 0:t.slashMenuH4Icon)==null?void 0:a.call(t))??SDe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;Rm(Ws.type(h),{level:4})(v,y)}}).addItem("quote",{label:(t==null?void 0:t.slashMenuQuoteLabel)??Ts("Quote"),icon:((u=t==null?void 0:t.slashMenuQuoteIcon)==null?void 0:u.call(t))??xDe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;l_(Nd.type(h))(v,y)}}).addItem("code",{label:(t==null?void 0:t.slashMenuCodeBlockLabel)??Ts("Code"),icon:((c=t==null?void 0:t.slashMenuCodeBlockIcon)==null?void 0:c.call(t))??ZL,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;cFe(Pd.type(h))(v,y)}}),n.addGroup("list",(t==null?void 0:t.slashMenuListGroupLabel)??Ts("List")).addItem("bullet-list",{label:(t==null?void 0:t.slashMenuBulletListLabel)??Ts("Bullet List"),icon:((d=t==null?void 0:t.slashMenuBulletListIcon)==null?void 0:d.call(t))??_De,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;l_(Mu.type(h))(v,y)}}).addItem("ordered-list",{label:(t==null?void 0:t.slashMenuOrderedListLabel)??Ts("Ordered List"),icon:((f=t==null?void 0:t.slashMenuOrderedListIcon)==null?void 0:f.call(t))??EDe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;l_(Tu.type(h))(v,y)}}),(p=t==null?void 0:t.buildMenu)==null||p.call(t,n);let o=n.build();e&&(o=o.map(h=>{const m=h.items.filter(y=>y.label.toLowerCase().includes(e.toLowerCase()));return{...h,items:m}}).filter(h=>h.items.length>0));const r=o.flatMap(h=>h.items);return r.forEach((h,m)=>{Object.assign(h,{index:m})}),o.reduce((h,m)=>{const y=h+m.items.length;return Object.assign(m,{range:[h,y]}),y},0),{groups:o,size:r.length}}const iR=({show:e,hide:t,ctx:n,filter:o,config:r})=>{const{groups:s,size:i}=D2(()=>fFe(o,r),[o]),l=CL(),[a,u]=TL(0),c=D2(()=>l.current.getRootNode(),[l]),d=Rk({x:-999,y:-999}),f=Fu(w=>{const _=d.current;if(!_)return;const{x:S,y:x}=w;_.x=S,_.y=x},[]);i0(()=>{i===0&&e&&(t==null||t())},[i,e]);const p=Fu((w,_)=>{u(S=>{const x=typeof w=="function"?w(S):w;return _==null||_(x),x})},[]),h=Fu(w=>{const _=l.current.querySelector(`[data-index="${w}"]`),S=l.current.querySelector(".menu-groups");!_||!S||(S.scrollTop=_.offsetTop-S.offsetTop)},[]),m=Fu(w=>{const _=s.flatMap(S=>S.items).at(w);_&&n&&_.onRun(n),t==null||t()},[s]),y=Fu(w=>{if(w.key==="Escape"){w.preventDefault(),t==null||t();return}if(w.key==="ArrowDown")return w.preventDefault(),p(_=>_<i-1?_+1:_,h);if(w.key==="ArrowUp")return w.preventDefault(),p(_=>_<=0?_:_-1,h);if(w.key==="ArrowLeft")return w.preventDefault(),p(_=>{const S=s.find(E=>E.range[0]<=_&&E.range[1]>_);if(!S)return _;const x=s[s.indexOf(S)-1];return x?x.range[1]-1:_},h);if(w.key==="ArrowRight")return w.preventDefault(),p(_=>{const S=s.find(E=>E.range[0]<=_&&E.range[1]>_);if(!S)return _;const x=s[s.indexOf(S)+1];return x?x.range[0]:_},h);w.key==="Enter"&&(w.preventDefault(),m(a))},[t,s,a]),v=Fu(w=>_=>{const S=d.current;if(!S)return;const{x,y:E}=_;x===S.x&&E===S.y||p(w)},[]);return i0(()=>(e?c.addEventListener("keydown",y,{capture:!0}):c.removeEventListener("keydown",y,{capture:!0}),()=>{c.removeEventListener("keydown",y,{capture:!0})}),[e,y]),$t`
455 <host onmousedown=${w=>w.preventDefault()}>
456 <div class="menu-groups" onmousemove=${f}>
457 ${s.map(w=>$t`
458 <div key=${w.key} class="menu-group">
459 <ul>
460 ${w.items.map(_=>$t`<li
461 key=${_.key}
462 data-index=${_.index}
463 class=${a===_.index?"hover":""}
464 onmouseenter=${v(_.index)}
465 onmousedown=${()=>{var S;(S=l.current.querySelector(`[data-index="${_.index}"]`))==null||S.classList.add("active")}}
466 onmouseup=${()=>{var S;(S=l.current.querySelector(`[data-index="${_.index}"]`))==null||S.classList.remove("active"),m(_.index)}}
467 >
468 ${_.icon}
469 <span>${_.label}</span>
470 </li>`)}
471 </ul>
472 </div>
473 `)}
474 </div>
475 </host>
476 `};iR.props={ctx:Object,config:Object,show:Boolean,filter:String,hide:Function};const lR=zh(iR),aR=sFe("CREPE_MENU"),uR=In({show:()=>{},hide:()=>{}},"menuAPICtx");sR("milkdown-slash-menu",lR);function pFe(e,t){e.set(aR.key,{view:n=>new hFe(e,n,t)})}var sr,Fs,Ml;class hFe{constructor(t,n,o){xs(this,sr,void 0);xs(this,Fs,void 0);xs(this,Ml,void 0);Lo(this,Ml,null),this.update=s=>{kt(this,Fs).update(s)},this.show=s=>{Lo(this,Ml,s),kt(this,sr).filter="",kt(this,Fs).show()},this.hide=()=>{Lo(this,Ml,null),kt(this,Fs).hide()},this.destroy=()=>{kt(this,Fs).destroy(),kt(this,sr).remove()},Lo(this,sr,new lR),kt(this,sr).hide=this.hide,kt(this,sr).ctx=t,kt(this,sr).config=o;const r=this;Lo(this,Fs,new iFe({content:kt(this,sr),debounce:20,shouldShow(s){if(oR(s.state.selection)||rR(s.state.selection))return!1;const i=this.getContent(s,a=>["paragraph","heading"].includes(a.type.name));if(i==null)return!1;const l=kt(r,Ml);return kt(r,sr).filter=i.startsWith("/")?i.slice(1):i,typeof l=="number"?s.state.doc.resolve(l).node()!==s.state.doc.resolve(s.state.selection.from).node()?(Lo(r,Ml,null),!1):!0:!!i.startsWith("/")},offset:10})),kt(this,Fs).onShow=()=>{kt(this,sr).show=!0},kt(this,Fs).onHide=()=>{kt(this,sr).show=!1},this.update(n),t.set(uR.key,{show:s=>this.show(s),hide:()=>this.hide()})}}sr=new WeakMap,Fs=new WeakMap,Ml=new WeakMap;const mFe=(e,t)=>{e.config(n=>pFe(n,t)).use(uR).use(Hk).use(aR)},gFe=Object.freeze(Object.defineProperty({__proto__:null,defineFeature:mFe},Symbol.toStringTag,{value:"Module"}));function vFe(e){var t;return e.childCount<=1&&!((t=e.firstChild)!=null&&t.content.size)}function yFe(e,t){const{selection:n}=e;if(!n.empty)return null;const o=n.$anchor,r=o.parent;if(r.content.size>0||cC(l=>l.type.name==="table")(o))return null;const i=o.before();return zn.node(i,i+r.nodeSize,{class:"crepe-placeholder","data-placeholder":t})}const a0=In({text:"Please enter...",mode:"block"},"placeholderConfigCtx"),cR=ao(e=>new xn({key:new wn("CREPE_PLACEHOLDER"),props:{decorations:t=>{const n=e.get(a0.key);if(n.mode==="doc"&&!vFe(t.doc)||oR(t.selection)||rR(t.selection))return null;const o=n.text??"Please enter...",r=yFe(t,o);return r?an.create(t.doc,[r]):null}}})),_Fe=(e,t)=>{e.config(n=>{t&&n.update(a0.key,o=>({...o,...t}))}).use(cR).use(a0)},bFe=Object.freeze(Object.defineProperty({__proto__:null,defineFeature:_Fe,placeholderConfig:a0,placeholderPlugin:cR},Symbol.toStringTag,{value:"Module"})),dR=({ctx:e,hide:t,show:n,config:o})=>{var l,a,u,c,d;const r=kL();i0(()=>{r()},[n]);const s=f=>p=>{p.preventDefault(),e&&f(e),r()},i=f=>{if(!e)return!1;const p=e.get(bn),{state:{doc:h,selection:m}}=p;return h.rangeHasMark(m.from,m.to,f)};return $t`<host>
477 <button
478 class=${ac("toolbar-item",e&&i(Ad.type(e))&&"active")}
479 onmousedown=${s(f=>{f.get(Dt).call(vv.key)})}
480 >
481 ${((l=o==null?void 0:o.boldIcon)==null?void 0:l.call(o))??yDe}
482 </button>
483 <button
484 class=${ac("toolbar-item",e&&i(xu.type(e))&&"active")}
485 onmousedown=${s(f=>{f.get(Dt).call(gv.key)})}
486 >
487 ${((a=o==null?void 0:o.italicIcon)==null?void 0:a.call(o))??$De}
488 </button>
489 <button
490 class=${ac("toolbar-item",e&&i(Rd.type(e))&&"active")}
491 onmousedown=${s(f=>{f.get(Dt).call(wv.key)})}
492 >
493 ${((u=o==null?void 0:o.strikethroughIcon)==null?void 0:u.call(o))??TDe}
494 </button>
495 <div class="divider"></div>
496 <button
497 class=${ac("toolbar-item",e&&i($i.type(e))&&"active")}
498 onmousedown=${s(f=>{f.get(Dt).call(yv.key)})}
499 >
500 ${((c=o==null?void 0:o.codeIcon)==null?void 0:c.call(o))??ZL}
501 </button>
502 <button
503 class=${ac("toolbar-item",e&&i(fs.type(e))&&"active")}
504 onmousedown=${s(f=>{const p=f.get(bn),{selection:h}=p.state;if(i(fs.type(f))){f.get(gd.key).removeLink(h.from,h.to);return}f.get(gd.key).addLink(h.from,h.to),t==null||t()})}
505 >
506 ${((d=o==null?void 0:o.linkIcon)==null?void 0:d.call(o))??JL}
507 </button>
508 </host>`};dR.props={ctx:Object,hide:Function,show:Boolean,config:Object};const fR=zh(dR),_$=Vk("CREPE_TOOLBAR");var _i,So;class wFe{constructor(t,n,o){xs(this,_i,void 0);xs(this,So,void 0);this.update=(s,i)=>{kt(this,_i).update(s,i)},this.destroy=()=>{kt(this,_i).destroy(),kt(this,So).remove()},this.hide=()=>{kt(this,_i).hide()};const r=new fR;Lo(this,So,r),kt(this,So).ctx=t,kt(this,So).hide=this.hide,kt(this,So).config=o,Lo(this,_i,new Fk({content:kt(this,So),debounce:20,offset:10,shouldShow(s){const{doc:i,selection:l}=s.state,{empty:a,from:u,to:c}=l,d=!i.textBetween(u,c).length&&l instanceof ht,f=!(l instanceof ht),p=s.dom.getRootNode().activeElement,h=r.contains(p),m=!s.hasFocus()&&!h,y=!s.editable;return!(m||f||a||d||y)}})),kt(this,_i).onShow=()=>{kt(this,So).show=!0,setTimeout(()=>{let s=kt(this,So).style.left;s=parseInt(s),console.log(s),s<0?(kt(this,So).style.left=0,console.log(kt(this,So))):s>350&&(kt(this,So).style.left="350px")},0)},kt(this,_i).onHide=()=>{kt(this,So).show=!1},this.update(n)}}_i=new WeakMap,So=new WeakMap;sR("milkdown-toolbar",fR);const CFe=(e,t)=>{e.config(n=>{n.set(_$.key,{view:o=>new wFe(n,o,t)})}).use(_$)},kFe=Object.freeze(Object.defineProperty({__proto__:null,defineFeature:CFe},Symbol.toStringTag,{value:"Module"})),SFe="",$Fe=Object.freeze(Object.defineProperty({__proto__:null,default:SFe},Symbol.toStringTag,{value:"Module"}))});export default EFe();
509