| 1 |
var $R=(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)),Ms=(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=$R((fr,pr)=>{const ER="modulepreload",xR=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=xR(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":ER,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=()=>{},Fm=()=>!1,yu=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),q2=e=>e.startsWith("onUpdate:"),zt=Object.assign,G2=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},TR=Object.prototype.hasOwnProperty,vt=(e,t)=>TR.call(e,t),Te=Array.isArray,gc=e=>vd(e)==="[object Map]",_u=e=>vd(e)==="[object Set]",sg=e=>vd(e)==="[object Date]",MR=e=>vd(e)==="[object RegExp]",Qe=e=>typeof e=="function",tt=e=>typeof e=="string",Vr=e=>typeof e=="symbol",pt=e=>e!==null&&typeof e=="object",Y2=e=>(pt(e)||Qe(e))&&Qe(e.then)&&Qe(e.catch),b$=Object.prototype.toString,vd=e=>b$.call(e),Bm=e=>vd(e).slice(8,-1),ig=e=>vd(e)==="[object Object]",Z2=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"),OR=yr("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"),d0=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},IR=/-(\w)/g,yn=d0(e=>e.replace(IR,(t,n)=>n?n.toUpperCase():"")),AR=/\B([A-Z])/g,zo=d0(e=>e.replace(AR,"-$1").toLowerCase()),Gl=d0(e=>e.charAt(0).toUpperCase()+e.slice(1)),vc=d0(e=>e?`on${Gl(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})},lg=e=>{const t=parseFloat(e);return isNaN(t)?e:t},ag=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:{}),NR="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",PR=yr(NR);function et(e){if(Te(e)){const t={};for(let n=0;n<e.length;n++){const o=e[n],r=tt(o)?k$(o):et(o);if(r)for(const s in r)t[s]=r[s]}return t}else if(tt(e)||pt(e))return e}const LR=/;(?![^(]*\))/g,RR=/:([^]+)/,DR=/\/\*[^]*?\*\//g;function k$(e){const t={};return e.replace(DR,"").split(LR).forEach(n=>{if(n){const o=n.split(RR);o.length>1&&(t[o[0].trim()]=o[1].trim())}}),t}function D(e){let t="";if(tt(e))t=e;else if(Te(e))for(let n=0;n<e.length;n++){const o=D(e[n]);o&&(t+=o+" ")}else if(pt(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}function J2(e){if(!e)return null;let{class:t,style:n}=e;return t&&!tt(t)&&(e.class=D(t)),n&&(e.style=et(n)),e}const VR="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",FR="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",BR="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",zR="area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr",jR=yr(VR),HR=yr(FR),UR=yr(BR),WR=yr(zR),KR="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",qR=yr(KR);function S$(e){return!!e||e===""}function GR(e,t){if(e.length!==t.length)return!1;let n=!0;for(let o=0;n&&o<e.length;o++)n=Fl(e[o],t[o]);return n}function Fl(e,t){if(e===t)return!0;let n=sg(e),o=sg(t);if(n||o)return n&&o?e.getTime()===t.getTime():!1;if(n=Vr(e),o=Vr(t),n||o)return e===t;if(n=Te(e),o=Te(t),n||o)return n&&o?GR(e,t):!1;if(n=pt(e),o=pt(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||!Fl(e[i],t[i]))return!1}}return String(e)===String(t)}function f0(e,t){return e.findIndex(n=>Fl(n,t))}const O=e=>tt(e)?e:e==null?"":Te(e)||pt(e)&&(e.toString===b$||!Qe(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[Nv(o,s)+" =>"]=r,n),{})}:_u(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>Nv(n))}:Vr(t)?Nv(t):pt(t)&&!Te(t)&&!ig(t)?String(t):t,Nv=(e,t="")=>{var n;return Vr(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 X2{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 X2(e)}function x$(e,t=ir){t&&t.active&&t.effects.push(e)}function Q2(){return ir}function ew(e){ir&&ir.cleanups.push(e)}let za;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,Yl();for(let t=0;t<this._depsLength;t++){const n=this.deps[t];if(n.computed&&(YR(n.computed),this._dirtyLevel>=4))break}this._dirtyLevel===1&&(this._dirtyLevel=0),Zl()}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=za;try{return Nl=!0,za=this,this._runnings++,Xk(this),this.fn()}finally{Qk(this),this._runnings--,za=n,Nl=t}}stop(){var t;this.active&&(Xk(this),Qk(this),(t=this.onStop)==null||t.call(this),this.active=!1)}}function YR(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++)T$(e.deps[t],e);e.deps.length=e._depsLength}}function T$(e,t){const n=e.get(t);n!==void 0&&t._trackId!==n&&(e.delete(t),e.size===0&&e.cleanup())}function ZR(e,t){e.effect instanceof Rc&&(e=e.effect.fn);const n=new Rc(e,yt,()=>{n.dirty&&n.run()});t&&(zt(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 JR(e){e.effect.stop()}let Nl=!0,u_=0;const M$=[];function Yl(){M$.push(Nl),Nl=!1}function Zl(){const e=M$.pop();Nl=e===void 0?!0:e}function tw(){u_++}function nw(){for(u_--;!u_&&c_.length;)c_.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&&T$(o,e),e.deps[e._depsLength++]=t):e._depsLength++}}const c_=[];function I$(e,t,n){tw();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&&c_.push(o.scheduler)))}nw()}const A$=(e,t)=>{const n=new Map;return n.cleanup=e,n.computed=t,n},ug=new WeakMap,ja=Symbol(""),d_=Symbol("");function Yo(e,t,n){if(Nl&&za){let o=ug.get(e);o||ug.set(e,o=new Map);let r=o.get(n);r||o.set(n,r=A$(()=>o.delete(n))),O$(za,r)}}function Ei(e,t,n,o,r,s){const i=ug.get(e);if(!i)return;let l=[];if(t==="clear")l=[...i.values()];else if(n==="length"&&Te(e)){const a=Number(o);i.forEach((u,c)=>{(c==="length"||!Vr(c)&&c>=a)&&l.push(u)})}else switch(n!==void 0&&l.push(i.get(n)),t){case"add":Te(e)?Z2(n)&&l.push(i.get("length")):(l.push(i.get(ja)),gc(e)&&l.push(i.get(d_)));break;case"delete":Te(e)||(l.push(i.get(ja)),gc(e)&&l.push(i.get(d_)));break;case"set":gc(e)&&l.push(i.get(ja));break}tw();for(const a of l)a&&I$(a,4);nw()}function XR(e,t){var n;return(n=ug.get(e))==null?void 0:n.get(t)}const QR=yr("__proto__,__v_isRef,__isVue"),N$=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Vr)),e4=eD();function eD(){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){Yl(),tw();const o=Mt(this)[t].apply(this,n);return nw(),Zl(),o}}),e}function tD(e){Vr(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$:F$:s?V$:D$).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(o)?t:void 0;const i=Te(t);if(!r){if(i&&vt(e4,n))return Reflect.get(e4,n,o);if(n==="hasOwnProperty")return tD}const l=Reflect.get(t,n,o);return(Vr(n)?N$.has(n):QR(n))||(r||Yo(t,"get",n),s)?l:on(l)?i&&Z2(n)?l:l.value:pt(l)?r?bu(l):Vn(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)),!Te(t)&&on(s)&&!on(o))return a?!1:(s.value=o,!0)}const i=Te(t)&&Z2(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(!Vr(n)||!N$.has(n))&&Yo(t,"has",n),o}ownKeys(t){return Yo(t,"iterate",Te(t)?"length":ja),Reflect.ownKeys(t)}}class R$ extends P${constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const nD=new L$,oD=new R$,rD=new L$(!0),sD=new R$(!0),ow=e=>e,p0=e=>Reflect.getPrototypeOf(e);function qh(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}=p0(r),l=o?ow:n?iw: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 Gh(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 Yh(e,t=!1){return e=e.__v_raw,!t&&Yo(Mt(e),"iterate",ja),Reflect.get(e,"size",e)}function t4(e){e=Mt(e);const t=Mt(this);return p0(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}=p0(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}=p0(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 Zh(e,t){return function(o,r){const s=this,i=s.__v_raw,l=Mt(i),a=t?ow:e?iw:pp;return!e&&Yo(l,"iterate",ja),i.forEach((u,c)=>o.call(r,a(u),a(c),s))}}function Jh(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?ow:t?iw:pp;return!t&&Yo(s,"iterate",a?d_:ja),{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 iD(){const e={get(s){return qh(this,s)},get size(){return Yh(this)},has:Gh,add:t4,set:n4,delete:o4,clear:r4,forEach:Zh(!1,!1)},t={get(s){return qh(this,s,!1,!0)},get size(){return Yh(this)},has:Gh,add:t4,set:n4,delete:o4,clear:r4,forEach:Zh(!1,!0)},n={get(s){return qh(this,s,!0)},get size(){return Yh(this,!0)},has(s){return Gh.call(this,s,!0)},add:Wi("add"),set:Wi("set"),delete:Wi("delete"),clear:Wi("clear"),forEach:Zh(!0,!1)},o={get(s){return qh(this,s,!0,!0)},get size(){return Yh(this,!0)},has(s){return Gh.call(this,s,!0)},add:Wi("add"),set:Wi("set"),delete:Wi("delete"),clear:Wi("clear"),forEach:Zh(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(s=>{e[s]=Jh(s,!1,!1),n[s]=Jh(s,!0,!1),t[s]=Jh(s,!1,!0),o[s]=Jh(s,!0,!0)}),[e,n,t,o]}const[lD,aD,uD,cD]=iD();function h0(e,t){const n=t?e?cD:uD:e?aD:lD;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 dD={get:h0(!1,!1)},fD={get:h0(!1,!0)},pD={get:h0(!0,!1)},hD={get:h0(!0,!0)},D$=new WeakMap,V$=new WeakMap,F$=new WeakMap,B$=new WeakMap;function mD(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function gD(e){return e.__v_skip||!Object.isExtensible(e)?0:mD(Bm(e))}function Vn(e){return Dc(e)?e:m0(e,!1,nD,dD,D$)}function rw(e){return m0(e,!1,rD,fD,V$)}function bu(e){return m0(e,!0,oD,pD,F$)}function vD(e){return m0(e,!0,sD,hD,B$)}function m0(e,t,n,o,r){if(!pt(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const s=r.get(e);if(s)return s;const i=gD(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 sw(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=>pt(e)?Vn(e):e,iw=e=>pt(e)?bu(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),lw(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=Qe(e);return s?(o=e,r=yt):(o=e.get,r=e.set),new z$(o,r,s||!r,n)}function lw(e){var t;Nl&&za&&(e=Mt(e),O$(za,(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 q(e){return H$(e,!1)}function Mn(e){return H$(e,!0)}function H$(e,t){return on(e)?e:new yD(e,t)}class yD{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 lw(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 _D(e){bc(e,4)}function g(e){return on(e)?e.value:e}function bD(e){return Qe(e)?e():g(e)}const wD={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 aw(e){return _c(e)?e:new Proxy(e,wD)}class CD{constructor(t){this.dep=void 0,this.__v_isRef=!0;const{get:n,set:o}=t(()=>lw(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 CD(e)}function ni(e){const t=Te(e)?new Array(e.length):{};for(const n in e)t[n]=W$(e,n);return t}class kD{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 XR(Mt(this._object),this._key)}}class SD{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:Qe(e)?new SD(e):pt(e)&&arguments.length>1?W$(e,t,n):q(e)}function W$(e,t,n){const o=e[t];return on(o)?o:new kD(e,t,n)}const $D={GET:"get",HAS:"has",ITERATE:"iterate"},ED={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 xD(e,t){}const TD={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"},MD={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){wu(r,t,n)}}function hr(e,t,n,o){if(Qe(e)){const r=xi(e,t,n,o);return r&&Y2(r)&&r.catch(s=>{wu(s,t,n)}),r}if(Te(e)){const r=[];for(let s=0;s<e.length;s++)r.push(hr(e[s],t,n,o));return r}}function wu(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){Yl(),xi(a,null,10,[e,i,l]),Zl();return}}OD(e,n,r,o)}function OD(e,t,n,o=!0){console.error(e)}let hp=!1,f_=!1;const ho=[];let zs=0;const wc=[];let pl=null,xa=0;const K$=Promise.resolve();let uw=null;function ot(e){const t=uw||K$;return e?t.then(this?e.bind(this):e):t}function ID(e){let t=zs+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 g0(e){(!ho.length||!ho.includes(e,hp&&e.allowRecurse?zs+1:zs))&&(e.id==null?ho.push(e):ho.splice(ID(e.id),0,e),q$())}function q$(){!hp&&!f_&&(f_=!0,uw=K$.then(G$))}function AD(e){const t=ho.indexOf(e);t>zs&&ho.splice(t,1)}function cg(e){Te(e)?wc.push(...e):(!pl||!pl.includes(e,e.allowRecurse?xa+1:xa))&&wc.push(e),q$()}function s4(e,t,n=hp?zs+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 dg(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,xa=0;xa<pl.length;xa++)pl[xa]();pl=null,xa=0}}const mp=e=>e.id==null?1/0:e.id,ND=(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){f_=!1,hp=!0,ho.sort(ND);const t=yt;try{for(zs=0;zs<ho.length;zs++){const n=ho[zs];n&&n.active!==!1&&xi(n,null,14)}}finally{zs=0,ho.length=0,dg(),hp=!1,uw=null,(ho.length||wc.length)&&G$()}}let Uu,Xh=[];function Y$(e,t){var n,o;Uu=e,Uu?(Uu.enabled=!0,Xh.forEach(({event:r,args:s})=>Uu.emit(r,...s)),Xh=[]):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,Xh=[])},3e3)):Xh=[]}function PD(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(lg))}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(!Qe(e)){const a=u=>{const c=Z$(u,t,!0);c&&(l=!0,zt(i,c))};!n&&t.mixins.length&&t.mixins.forEach(a),e.extends&&a(e.extends),e.mixins&&e.mixins.forEach(a)}return!s&&!l?(pt(e)&&o.set(e,null),null):(Te(s)?s.forEach(a=>i[a]=null):zt(i,s),pt(e)&&o.set(e,i),i)}function v0(e,t){return!e||!yu(t)?!1:(t=t.slice(2).replace(/Once$/,""),vt(e,t[0].toLowerCase()+t.slice(1))||vt(e,zo(t))||vt(e,t))}let Ln=null,y0=null;function gp(e){const t=Ln;return Ln=e,y0=e&&e.type.__scopeId||null,t}function J$(e){y0=e}function X$(){y0=null}const LD=e=>$;function $(e,t=Ln,n){if(!t||e._n)return e;const o=(...r)=>{o._d&&w_(-1);const s=gp(t);let i;try{i=e(...r)}finally{gp(s),o._d&&w_(1)}return i};return o._n=!0,o._c=!0,o._d=!0,o}function zm(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:DD(a)}}catch(S){Rf.length=0,wu(S,e,1),y=k(Gn)}let _=y;if(v&&m!==!1){const S=Object.keys(v),{shapeFlag:x}=_;S.length&&x&7&&(i&&S.some(q2)&&(v=VD(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 RD(e,t=!0){let n;for(let o=0;o<e.length;o++){const r=e[o];if(yo(r)){if(r.type!==Gn||r.children==="v-if"){if(n)return;n=r}}else return}return n}const DD=e=>{let t;for(const n in e)(n==="class"||n==="style"||yu(n))&&((t||(t={}))[n]=e[n]);return t},VD=(e,t)=>{const n={};for(const o in e)(!q2(o)||!(o.slice(9)in t))&&(n[o]=e[o]);return n};function FD(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]&&!v0(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]&&!v0(n,s))return!0}return!1}function cw({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 dw="components",BD="directives";function oe(e,t){return fw(dw,e,!0,t)||e}const Q$=Symbol.for("v-ndc");function Lt(e){return tt(e)?fw(dw,e,!1)||e:e||Q$}function Dt(e){return fw(BD,e)}function fw(e,t,n=!0,o=!1){const r=Ln||Hn;if(r){const s=r.type;if(e===dw){const l=E_(s,!1);if(l&&(l===t||l===yn(t)||l===Gl(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[Gl(yn(t))])}const eE=e=>e.__isSuspense;let p_=0;const zD={name:"Suspense",__isSuspense:!0,process(e,t,n,o,r,s,i,l,a,u){if(e==null)HD(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}UD(e,t,n,o,r,i,l,a,u)}},hydrate:WD,create:pw,normalize:KD},jD=zD;function vp(e,t){const n=e.props&&e.props[t];Qe(n)&&n()}function HD(e,t,n,o,r,s,i,l,a){const{p:u,o:{createElement:c}}=a,d=c("div"),f=e.suspense=pw(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 UD(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=p_++,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=p_++,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 pw(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=qD(e);w&&t!=null&&t.pendingBranch&&(v=t.pendingId,t.deps++);const _=e.props?ag(e.props.timeout):void 0,S=s,x={vnode:e,parent:t,parentComponent:n,namespace:i,container:o,hiddenContainer:r,deps:0,pendingId:p_++,timeout:typeof _=="number"?_:-1,activeBranch:null,pendingBranch:null,isInFallback:!c,isHydrating:c,isUnmounted:!1,effects:[],resolve(E=!1,M=!1){const{vnode:A,activeBranch:P,pendingBranch:N,pendingId:V,effects:B,parentComponent:Y,container:Z}=x;let W=!1;x.isHydrating?x.isHydrating=!1:E||(W=P&&N.transition&&N.transition.mode==="out-in",W&&(P.transition.afterLeave=()=>{V===x.pendingId&&(f(N,Z,s===S?h(P):s,0),cg(B))}),P&&(m(P.el)!==x.hiddenContainer&&(s=h(P)),p(P,Y,x,!0)),W||f(N,Z,s,0)),Cc(x,N),x.pendingBranch=null,x.isInFallback=!1;let H=x.parent,F=!1;for(;H;){if(H.pendingBranch){H.effects.push(...B),F=!0;break}H=H.parent}!F&&!W&&cg(B),x.effects=[],w&&t&&t.pendingBranch&&v===t.pendingId&&(t.deps--,t.deps===0&&!M&&t.resolve()),vp(A,"onResolve")},fallback(E){if(!x.pendingBranch)return;const{vnode:M,activeBranch:A,parentComponent:P,container:N,namespace:V}=x;vp(M,"onFallback");const B=h(A),Y=()=>{x.isInFallback&&(d(null,E,N,B,P,null,V,l,a),Cc(x,E))},Z=E.transition&&E.transition.mode==="out-in";Z&&(A.transition.afterLeave=Y),x.isInFallback=!0,p(A,P,null,!0),Z||Y()},move(E,M,A){x.activeBranch&&f(x.activeBranch,E,M,A),x.container=E},next(){return x.activeBranch&&h(x.activeBranch)},registerDep(E,M){const A=!!x.pendingBranch;A&&x.deps++;const P=E.vnode.el;E.asyncDep.catch(N=>{wu(N,E,0)}).then(N=>{if(E.isUnmounted||x.isUnmounted||x.pendingId!==E.suspenseId)return;E.asyncResolved=!0;const{vnode:V}=E;S_(E,N,!1),P&&(V.el=P);const B=!P&&E.subTree.el;M(E,V,m(P||E.subTree.el),P?null:h(E.subTree),x,i,a),B&&y(B),cw(E,V.el),A&&--x.deps===0&&x.resolve()})},unmount(E,M){x.isUnmounted=!0,x.activeBranch&&p(x.activeBranch,n,E,M),x.pendingBranch&&p(x.pendingBranch,n,E,M)}};return x}function WD(e,t,n,o,r,s,i,l,a){const u=t.suspense=pw(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 KD(e){const{shapeFlag:t,children:n}=e,o=t&32;e.ssContent=a4(o?n.default:n),e.ssFallback=o?a4(n.fallback):k(Gn)}function a4(e){let t;if(Qe(e)){const n=ou&&e._c;n&&(e._d=!1,C()),e=e(),n&&(e._d=!0,t=jo,PE())}return Te(e)&&(e=RD(e)),e=ur(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(n=>n!==e)),e}function tE(e,t){t&&t.pendingBranch?Te(e)?t.effects.push(...e):t.effects.push(e):cg(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,cw(o,r))}function qD(e){var t;return((t=e.props)==null?void 0:t.suspensible)!=null&&e.props.suspensible!==!1}const nE=Symbol.for("v-scx"),oE=()=>ze(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 Qh={};function Me(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=(...M)=>{E(...M),x()}}const a=Hn,u=E=>o===!0?E:Oa(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):Te(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(Qe(E))return xi(E,a,2)})):Qe(e)?t?c=()=>xi(e,a,2):c=()=>(p&&p(),hr(e,a,3,[h])):c=yt,t&&o){const E=c;c=()=>Oa(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(Qh):Qh;const v=()=>{if(!(!_.active||!_.dirty))if(t){const E=_.run();(o||d||(f?E.some((M,A)=>ps(M,y[A])):ps(E,y)))&&(p&&p(),hr(t,a,3,[E,y===Qh?void 0:f&&y[0]===Qh?[]:y,h]),y=E)}else _.run()};v.allowRecurse=!!t;let w;r==="sync"?w=v:r==="post"?w=()=>no(v,a&&a.suspense):(v.pre=!0,a&&(v.id=a.uid),w=()=>g0(v));const _=new Rc(c,yt,w),S=Q2(),x=()=>{_.stop(),S&&G2(S.effects,_)};return t?n?v():y=_.run():r==="post"?no(_.run.bind(_),a&&a.suspense):_.run(),m&&m.push(x),x}function GD(e,t,n){const o=this.proxy,r=tt(e)?e.includes(".")?iE(o,e):()=>o[e]:e.bind(o,o);let s;Qe(t)?s=t:(s=t.handler,n=t);const i=ru(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 Oa(e,t,n=0,o){if(!pt(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))Oa(e.value,t,n,o);else if(Te(e))for(let r=0;r<e.length;r++)Oa(e[r],t,n,o);else if(_u(e)||gc(e))e.forEach(r=>{Oa(r,t,n,o)});else if(ig(e))for(const r in e)Oa(e[r],t,n,o);return e}function Fe(e,t){if(Ln===null)return e;const n=w0(Ln)||Ln.proxy,o=e.dirs||(e.dirs=[]);for(let r=0;r<t.length;r++){let[s,i,l,a=Wt]=t[r];s&&(Qe(s)&&(s={mounted:s,updated:s}),s.deep&&Oa(i),o.push({dir:s,instance:n,value:i,oldValue:void 0,arg:l,modifiers:a}))}return e}function Fs(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&&(Yl(),hr(a,n,8,[e.el,l,e,t]),Zl())}}const hl=Symbol("_leaveCb"),em=Symbol("_enterCb");function hw(){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],mw={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},YD={name:"BaseTransition",props:mw,setup(e,{slots:t}){const n=at(),o=hw();return()=>{const r=t.default&&_0(t.default(),!0);if(!r||!r.length)return;let s=r[0];if(r.length>1){for(const f of r)if(f.type!==Gn){s=f;break}}const i=Mt(e),{mode:l}=i;if(o.isLeaving)return Pv(s);const a=u4(s);if(!a)return Pv(s);const u=Vc(a,i,o,n);nu(a,u);const c=n.subTree,d=c&&u4(c);if(d&&d.type!==Gn&&!ss(a,d)){const f=Vc(d,i,o,n);if(nu(d,f),l==="out-in")return o.isLeaving=!0,f.afterLeave=()=>{o.isLeaving=!1,n.update.active!==!1&&(n.effect.dirty=!0,n.update())},Pv(s);l==="in-out"&&a.type!==Gn&&(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=YD;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 Vc(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=(A,P)=>{A&&hr(A,o,9,P)},E=(A,P)=>{const N=P[1];x(A,P),Te(A)?A.every(V=>V.length<=1)&&N():A.length<=1&&N()},M={mode:s,persisted:i,beforeEnter(A){let P=l;if(!n.isMounted)if(r)P=m||l;else return;A[hl]&&A[hl](!0);const N=S[_];N&&ss(e,N)&&N.el[hl]&&N.el[hl](),x(P,[A])},enter(A){let P=a,N=u,V=c;if(!n.isMounted)if(r)P=y||a,N=v||u,V=w||c;else return;let B=!1;const Y=A[em]=Z=>{B||(B=!0,Z?x(V,[A]):x(N,[A]),M.delayedLeave&&M.delayedLeave(),A[em]=void 0)};P?E(P,[A,Y]):Y()},leave(A,P){const N=String(e.key);if(A[em]&&A[em](!0),n.isUnmounting)return P();x(d,[A]);let V=!1;const B=A[hl]=Y=>{V||(V=!0,P(),Y?x(h,[A]):x(p,[A]),A[hl]=void 0,S[N]===e&&delete S[N])};S[N]=e,f?E(f,[A,B]):B()},clone(A){return Vc(A,t,n,o)}};return M}function Pv(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 nu(e,t){e.shapeFlag&6&&e.component?nu(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 _0(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(_0(i.children,t,l))):(t||i.type!==Gn)&&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 Qe(e)?(()=>zt({name:e.name},t,{setup:e}))():e}const Ha=e=>!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function ZD(e){Qe(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=Hn;if(u)return()=>Lv(u,p);const h=w=>{a=null,wu(w,p,13,!o)};if(i&&p.suspense||Jp)return f().then(w=>()=>Lv(w,p)).catch(w=>(h(w),()=>o?k(o,{error:w}):null));const m=q(!1),y=q(),v=q(!!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,g0(p.parent.update))}).catch(w=>{h(w),y.value=w}),()=>{if(m.value&&u)return Lv(u,p);if(y.value&&o)return k(o,{error:y.value});if(n&&!v.value)return k(n)}}})}function Lv(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,JD={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 M=w.component;u(w,_,S,0,l),a(M.vnode,w,_,S,M,l,x,w.slotScopeIds,E),no(()=>{M.isDeactivated=!1,M.a&&yc(M.a);const A=w.props&&w.props.onVnodeMounted;A&&Fo(A,M.parent,w)},l)},o.deactivate=w=>{const _=w.component;u(w,f,null,1,l),no(()=>{_.da&&yc(_.da);const S=w.props&&w.props.onVnodeUnmounted;S&&Fo(S,_.parent,w),_.isDeactivated=!0},l)};function p(w){Rv(w),c(w,n,l,!0)}function h(w){r.forEach((_,S)=>{const x=E_(_.type);x&&(!w||!w(x))&&m(S)})}function m(w){const _=r.get(w);!i||!ss(_,i)?p(_):i&&Rv(i),r.delete(w),s.delete(w)}Me(()=>[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,Dv(n.subTree))};return Ct(v),Vi(v),En(()=>{r.forEach(w=>{const{subTree:_,suspense:S}=n,x=Dv(_);if(w.type===x.type&&w.key===x.key){Rv(x);const E=x.component.da;E&&no(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=Dv(_);const x=S.type,E=E_(Ha(S)?S.type.__asyncResolved||{}:x),{include:M,exclude:A,max:P}=e;if(M&&(!E||!Zd(M,E))||A&&E&&Zd(A,E))return i=S,_;const N=S.key==null?x:S.key,V=r.get(N);return S.el&&(S=hs(S),_.shapeFlag&128&&(_.ssContent=S)),y=N,V?(S.el=V.el,S.component=V.component,S.transition&&nu(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}}},XD=JD;function Zd(e,t){return Te(e)?e.some(n=>Zd(n,t)):tt(e)?e.split(",").includes(t):MR(e)?e.test(t):!1}function uE(e,t){cE(e,"a",t)}function gw(e,t){cE(e,"da",t)}function cE(e,t,n=Hn){const o=e.__wdc||(e.__wdc=()=>{let r=n;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(b0(t,o,n),n){let r=n.parent;for(;r&&r.parent;)Zp(r.parent.vnode)&&QD(o,t,n,r),r=r.parent}}function QD(e,t,n,o){const r=b0(t,e,o,!0);oi(()=>{G2(o[t],r)},n)}function Rv(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function Dv(e){return e.shapeFlag&128?e.ssContent:e}function b0(e,t,n=Hn,o=!1){if(n){const r=n[e]||(n[e]=[]),s=t.__weh||(t.__weh=(...i)=>{if(n.isUnmounted)return;Yl();const l=ru(n),a=hr(t,n,e,i);return l(),Zl(),a});return o?r.unshift(s):r.push(s),s}}const Di=e=>(t,n=Hn)=>(!Jp||e==="sp")&&b0(e,(...o)=>t(...o),n),yd=Di("bm"),Ct=Di("m"),dE=Di("bu"),Vi=Di("u"),En=Di("bum"),oi=Di("um"),fE=Di("sp"),pE=Di("rtg"),hE=Di("rtc");function mE(e,t=Hn){b0("ec",e,t)}function nt(e,t,n,o){let r;const s=n&&n[o];if(Te(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(pt(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 Bl(e,t){for(let n=0;n<t.length;n++){const o=t[n];if(Te(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(Ln.isCE||Ln.parent&&Ha(Ln.parent)&&Ln.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=K(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===Gn||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 h_=e=>e?FE(e)?w0(e)||e.proxy:h_(e.parent):null,Pf=zt(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=>h_(e.parent),$root:e=>h_(e.root),$emit:e=>e.emit,$options:e=>vw(e),$forceUpdate:e=>e.f||(e.f=()=>{e.effect.dirty=!0,g0(e.update)}),$nextTick:e=>e.n||(e.n=ot.bind(e.proxy)),$watch:e=>GD.bind(e)}),Vv=(e,t)=>e!==Wt&&!e.__isScriptSetup&&vt(e,t),m_={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(Vv(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];g_&&(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 Vv(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)||Vv(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)}},eV=zt({},m_,{get(e,t){if(t!==Symbol.unscopables)return m_.get(e,t,e)},has(e,t){return t[0]!=="_"&&!PR(t)}});function tV(){return null}function nV(){return null}function oV(e){}function rV(e){}function sV(){return null}function iV(){}function lV(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 Te(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function aV(e,t){const n=yp(e);for(const o in t){if(o.startsWith("__skip"))continue;let r=n[o];r?Te(r)||Qe(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 uV(e,t){return!e||!t?e||t:Te(e)&&Te(t)?e.concat(t):zt({},yp(e),yp(t))}function cV(e,t){const n={};for(const o in e)t.includes(o)||Object.defineProperty(n,o,{enumerable:!0,get:()=>e[o]});return n}function dV(e){const t=at();let n=e();return k_(),Y2(n)&&(n=n.catch(o=>{throw ru(t),o})),[n,()=>ru(t)]}let g_=!0;function fV(e){const t=vw(e),n=e.proxy,o=e.ctx;g_=!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:M,errorCaptured:A,serverPrefetch:P,expose:N,inheritAttrs:V,components:B,directives:Y,filters:Z}=t;if(u&&pV(u,o,null),i)for(const F in i){const U=i[F];Qe(U)&&(o[F]=U.bind(n))}if(r){const F=r.call(n,n);pt(F)&&(e.data=Vn(F))}if(g_=!0,s)for(const F in s){const U=s[F],L=Qe(U)?U.bind(n,n):Qe(U.get)?U.get.bind(n,n):yt,I=!Qe(U)&&Qe(U.set)?U.set.bind(n):yt,X=R({get:L,set:I});Object.defineProperty(o,F,{enumerable:!0,configurable:!0,get:()=>X.value,set:re=>X.value=re})}if(l)for(const F in l)_E(l[F],o,n,F);if(a){const F=Qe(a)?a.call(n):a;Reflect.ownKeys(F).forEach(U=>{wt(U,F[U])})}c&&c4(c,e,"c");function H(F,U){Te(U)?U.forEach(L=>F(L.bind(n))):U&&F(U.bind(n))}if(H(yd,d),H(Ct,f),H(dE,p),H(Vi,h),H(uE,m),H(gw,y),H(mE,A),H(hE,E),H(pE,M),H(En,w),H(oi,S),H(fE,P),Te(N))if(N.length){const F=e.exposed||(e.exposed={});N.forEach(U=>{Object.defineProperty(F,U,{get:()=>n[U],set:L=>n[U]=L})})}else e.exposed||(e.exposed={});x&&e.render===yt&&(e.render=x),V!=null&&(e.inheritAttrs=V),B&&(e.components=B),Y&&(e.directives=Y)}function pV(e,t,n=yt){Te(e)&&(e=v_(e));for(const o in e){const r=e[o];let s;pt(r)?"default"in r?s=ze(r.from||o,r.default,!0):s=ze(r.from||o):s=ze(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(Te(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];Qe(s)&&Me(r,s)}else if(Qe(e))Me(r,e.bind(n));else if(pt(e))if(Te(e))e.forEach(s=>_E(s,t,n,o));else{const s=Qe(e.handler)?e.handler.bind(n):t[e.handler];Qe(s)&&Me(r,s,e)}}function vw(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=>fg(a,u,i,!0)),fg(a,t,i)),pt(t)&&s.set(t,a),a}function fg(e,t,n,o=!1){const{mixins:r,extends:s}=t;s&&fg(e,s,n,!0),r&&r.forEach(i=>fg(e,i,n,!0));for(const i in t)if(!(o&&i==="expose")){const l=hV[i]||n&&n[i];e[i]=l?l(e[i],t[i]):t[i]}return e}const hV={data:d4,props:f4,emits:f4,methods:Jd,computed:Jd,beforeCreate:ko,created:ko,beforeMount:ko,mounted:ko,beforeUpdate:ko,updated:ko,beforeDestroy:ko,beforeUnmount:ko,destroyed:ko,unmounted:ko,activated:ko,deactivated:ko,errorCaptured:ko,serverPrefetch:ko,components:Jd,directives:Jd,watch:gV,provide:d4,inject:mV};function d4(e,t){return t?e?function(){return zt(Qe(e)?e.call(this,this):e,Qe(t)?t.call(this,this):t)}:t:e}function mV(e,t){return Jd(v_(e),v_(t))}function v_(e){if(Te(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function ko(e,t){return e?[...new Set([].concat(e,t))]:t}function Jd(e,t){return e?zt(Object.create(null),e,t):t}function f4(e,t){return e?Te(e)&&Te(t)?[...new Set([...e,...t])]:zt(Object.create(null),yp(e),yp(t??{})):t}function gV(e,t){if(!e)return t;if(!t)return e;const n=zt(Object.create(null),e);for(const o in t)n[o]=ko(e[o],t[o]);return n}function bE(){return{app:null,config:{isNativeTag:Fm,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 vV=0;function yV(e,t){return function(o,r=null){Qe(o)||(o=zt({},o)),r!=null&&!pt(r)&&(r=null);const s=bE(),i=new WeakSet;let l=!1;const a=s.app={_uid:vV++,_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&&Qe(u.install)?(i.add(u),u.install(a,...c)):Qe(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,w0(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(Hn){let n=Hn.provides;const o=Hn.parent&&Hn.parent.provides;o===n&&(n=Hn.provides=Object.create(o)),n[e]=t}}function ze(e,t,n=!1){const o=Hn||Ln;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&&Qe(t)?t.call(o&&o.proxy):t}}function _V(){return!!(Hn||Ln||kc)}const wE=Object.create(null),y_=()=>Object.create(wE),CE=e=>Object.getPrototypeOf(e)===wE;function bV(e,t,n,o=!1){const r={},s=y_();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:rw(r):e.type.props?e.props=r:e.props=s,e.attrs=s}function wV(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(v0(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]=__(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]=__(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:v0(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]=__(r,a,d,u[d],e,!vt(u,d))}}return i}function __(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&&Qe(a)){const{propsDefaults:u}=r;if(n in u)o=u[n];else{const c=ru(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(!Qe(e)){const c=d=>{a=!0;const[f,p]=SE(d,t,!0);zt(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 pt(e)&&o.set(e,mc),mc;if(Te(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]=Te(f)||Qe(f)?{type:f}:zt({},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 pt(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 Te(t)?t.findIndex(n=>m4(n,e)):Qe(t)&&m4(t,e)?0:-1}const $E=e=>e[0]==="_"||e==="$stable",yw=e=>Te(e)?e.map(ur):[ur(e)],CV=(e,t,n)=>{if(t._n)return t;const o=$((...r)=>yw(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(Qe(s))t[r]=CV(r,s,o);else if(s!=null){const i=yw(s);t[r]=()=>i}}},xE=(e,t)=>{const n=yw(t);e.slots.default=()=>n},kV=(e,t)=>{if(e.vnode.shapeFlag&32){const n=t._;n?(e.slots=Mt(t),w$(e.slots,"_",n)):EE(t,e.slots=y_())}else e.slots=y_(),t&&xE(e,t)},SV=(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:(zt(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 pg(e,t,n,o,r=!1){if(Te(e)){e.forEach((f,p)=>pg(f,t&&(Te(t)?t[p]:t),n,o,r));return}if(Ha(o)&&!r)return;const s=o.shapeFlag&4?w0(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)),Qe(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?Te(m)&&G2(m,s):Te(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,no(h,n)):h()}}}let Ki=!1;const $V=e=>e.namespaceURI.includes("svg")&&e.tagName!=="foreignObject",EV=e=>e.namespaceURI.includes("MathML"),tm=e=>{if($V(e))return"svg";if(EV(e))return"mathml"},nm=e=>e.nodeType===8;function xV(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),dg(),S._vnode=_;return}Ki=!1,d(S.firstChild,_,null,null,null),dg(),S._vnode=_,Ki&&console.error("Hydration completed but contains mismatches.")},d=(_,S,x,E,M,A=!1)=>{A=A||!!S.dynamicChildren;const P=nm(_)&&_.data==="[",N=()=>m(_,S,x,E,M,P),{type:V,ref:B,shapeFlag:Y,patchFlag:Z}=S;let W=_.nodeType;S.el=_,Z===-2&&(A=!1,S.dynamicChildren=null);let H=null;switch(V){case Ai:W!==3?S.children===""?(a(S.el=r(""),i(_),_),H=_):H=N():(_.data!==S.children&&(Ki=!0,_.data=S.children),H=s(_));break;case Gn:w(_)?(H=s(_),v(S.el=_.content.firstChild,_,x)):W!==8||P?H=N():H=s(_);break;case Ua:if(P&&(_=s(_),W=_.nodeType),W===1||W===3){H=_;const F=!S.children.length;for(let U=0;U<S.staticCount;U++)F&&(S.children+=H.nodeType===1?H.outerHTML:H.data),U===S.staticCount-1&&(S.anchor=H),H=s(H);return P?s(H):H}else N();break;case fe:P?H=h(_,S,x,E,M,A):H=N();break;default:if(Y&1)(W!==1||S.type.toLowerCase()!==_.tagName.toLowerCase())&&!w(_)?H=N():H=f(_,S,x,E,M,A);else if(Y&6){S.slotScopeIds=M;const F=i(_);if(P?H=y(_):nm(_)&&_.data==="teleport start"?H=y(_,_.data,"teleport end"):H=s(_),t(S,F,null,x,E,tm(F),A),Ha(S)){let U;P?(U=k(fe),U.anchor=H?H.previousSibling:F.lastChild):U=_.nodeType===3?ne(""):k("div"),U.el=_,S.component.subTree=U}}else Y&64?W!==8?H=N():H=S.type.hydrate(_,S,x,E,M,A,e,p):Y&128&&(H=S.type.hydrate(_,S,x,E,tm(i(_)),M,A,e,d))}return B!=null&&pg(B,null,E,S),H},f=(_,S,x,E,M,A)=>{A=A||!!S.dynamicChildren;const{type:P,props:N,patchFlag:V,shapeFlag:B,dirs:Y,transition:Z}=S,W=P==="input"||P==="option";if(W||V!==-1){Y&&Fs(S,null,x,"created");let H=!1;if(w(_)){H=IE(E,Z)&&x&&x.vnode.props&&x.vnode.props.appear;const U=_.content.firstChild;H&&Z.beforeEnter(U),v(U,_,x),S.el=_=U}if(B&16&&!(N&&(N.innerHTML||N.textContent))){let U=p(_.firstChild,S,_,x,E,M,A);for(;U;){Ki=!0;const L=U;U=U.nextSibling,l(L)}}else B&8&&_.textContent!==S.children&&(Ki=!0,_.textContent=S.children);if(N)if(W||!A||V&48)for(const U in N)(W&&(U.endsWith("value")||U==="indeterminate")||yu(U)&&!Al(U)||U[0]===".")&&o(_,U,null,N[U],void 0,void 0,x);else N.onClick&&o(_,"onClick",null,N.onClick,void 0,void 0,x);let F;(F=N&&N.onVnodeBeforeMount)&&Fo(F,x,S),Y&&Fs(S,null,x,"beforeMount"),((F=N&&N.onVnodeMounted)||Y||H)&&tE(()=>{F&&Fo(F,x,S),H&&Z.enter(_),Y&&Fs(S,null,x,"mounted")},E)}return _.nextSibling},p=(_,S,x,E,M,A,P)=>{P=P||!!S.dynamicChildren;const N=S.children,V=N.length;for(let B=0;B<V;B++){const Y=P?N[B]:N[B]=ur(N[B]);if(_)_=d(_,Y,E,M,A,P);else{if(Y.type===Ai&&!Y.children)continue;Ki=!0,n(null,Y,x,null,E,M,tm(x),A)}}return _},h=(_,S,x,E,M,A)=>{const{slotScopeIds:P}=S;P&&(M=M?M.concat(P):P);const N=i(_),V=p(s(_),S,N,x,E,M,A);return V&&nm(V)&&V.data==="]"?s(S.anchor=V):(Ki=!0,a(S.anchor=u("]"),N,V),V)},m=(_,S,x,E,M,A)=>{if(Ki=!0,S.el=null,A){const V=y(_);for(;;){const B=s(_);if(B&&B!==V)l(B);else break}}const P=s(_),N=i(_);return l(_),n(null,S,N,P,x,E,tm(N),M),P},y=(_,S="[",x="]")=>{let E=0;for(;_;)if(_=s(_),_&&nm(_)&&(_.data===S&&E++,_.data===x)){if(E===0)return s(_);E--}return _},v=(_,S,x)=>{const E=S.parentNode;E&&E.replaceChild(_,S);let M=x;for(;M;)M.vnode.el===S&&(M.vnode.el=M.subTree.el=_),M=M.parent},w=_=>_.nodeType===1&&_.tagName.toLowerCase()==="template";return[c,d]}const no=tE;function TE(e){return OE(e)}function ME(e){return OE(e,xV)}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),re(G,ye,Ae,!0),G=null),J.patchFlag===-2&&(Pe=!1,J.dynamicChildren=null);const{type:me,ref:He,shapeFlag:Ze}=J;switch(me){case Ai:y(G,J,ue,_e);break;case Gn:v(G,J,ue,_e);break;case Ua: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)}He!=null&&ye&&pg(He,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:He,shapeFlag:Ze,transition:ce,dirs:te}=G;if(Pe=G.el=i(G.type,Ae,He&&He.is,He),Ze&8?c(Pe,G.children):Ze&16&&A(G.children,Pe,null,_e,ye,Fv(G,Ae),Le,Ee),te&&Fs(G,null,_e,"created"),M(Pe,G,G.scopeId,Le,_e),He){for(const Be in He)Be!=="value"&&!Al(Be)&&s(Pe,Be,null,He[Be],Ae,G.children,_e,ye,xe);"value"in He&&s(Pe,"value",null,He.value,Ae),(me=He.onVnodeBeforeMount)&&Fo(me,_e,G)}te&&Fs(G,null,_e,"beforeMount");const pe=IE(ye,ce);pe&&ce.beforeEnter(Pe),o(Pe,J,ue),((me=He&&He.onVnodeMounted)||pe||te)&&no(()=>{me&&Fo(me,_e,G),pe&&ce.enter(Pe),te&&Fs(G,null,_e,"mounted")},ye)},M=(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;M(G,Le,Le.scopeId,Le.slotScopeIds,ye.parent)}}},A=(G,J,ue,_e,ye,Ae,Le,Ee,Pe=0)=>{for(let me=Pe;me<G.length;me++){const He=G[me]=Ee?ml(G[me]):ur(G[me]);m(null,He,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:He}=J;Pe|=G.patchFlag&16;const Ze=G.props||Wt,ce=J.props||Wt;let te;if(ue&&ca(ue,!1),(te=ce.onVnodeBeforeUpdate)&&Fo(te,ue,J,G),He&&Fs(J,G,ue,"beforeUpdate"),ue&&ca(ue,!0),me?N(G.dynamicChildren,me,Ee,ue,_e,Fv(J,ye),Ae):Le||U(G,J,Ee,null,ue,_e,Fv(J,ye),Ae,!1),Pe>0){if(Pe&16)V(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 Be=0;Be<pe.length;Be++){const Xe=pe[Be],$e=Ze[Xe],ie=ce[Xe];(ie!==$e||Xe==="value")&&s(Ee,Xe,$e,ie,ye,G.children,ue,_e,xe)}}Pe&1&&G.children!==J.children&&c(Ee,J.children)}else!Le&&me==null&&V(Ee,J,Ze,ce,ue,_e,ye);((te=ce.onVnodeUpdated)||He)&&no(()=>{te&&Fo(te,ue,J,G),He&&Fs(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],He=Pe.el&&(Pe.type===fe||!ss(Pe,me)||Pe.shapeFlag&70)?d(Pe.el):ue;m(Pe,me,He,null,_e,ye,Ae,Le,!0)}},V=(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(""),He=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(He,ue,_e),A(J.children||[],ue,He,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)&&_w(G,J,!0)):U(G,J,ue,He,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):W(G,J,Pe)},Z=(G,J,ue,_e,ye,Ae,Le)=>{const Ee=G.component=VE(G,_e,ye);if(Zp(G)&&(Ee.ctx.renderer=le),BE(Ee),Ee.asyncDep){if(ye&&ye.registerDep(Ee,H),!G.el){const Pe=Ee.subTree=k(Gn);v(null,Pe,J,ue)}}else H(Ee,G,J,ue,ye,Ae,Le)},W=(G,J,ue)=>{const _e=J.component=G.component;if(FD(G,J,ue))if(_e.asyncDep&&!_e.asyncResolved){F(_e,J,ue);return}else _e.next=J,AD(_e.update),_e.effect.dirty=!0,_e.update();else J.el=G.el,_e.vnode=J},H=(G,J,ue,_e,ye,Ae,Le)=>{const Ee=()=>{if(G.isMounted){let{next:He,bu:Ze,u:ce,parent:te,vnode:pe}=G;{const we=AE(G);if(we){He&&(He.el=pe.el,F(G,He,Le)),we.asyncDep.then(()=>{G.isUnmounted||Ee()});return}}let Be=He,Xe;ca(G,!1),He?(He.el=pe.el,F(G,He,Le)):He=pe,Ze&&yc(Ze),(Xe=He.props&&He.props.onVnodeBeforeUpdate)&&Fo(Xe,te,He,pe),ca(G,!0);const $e=zm(G),ie=G.subTree;G.subTree=$e,m(ie,$e,d(ie.el),ee(ie),G,ye,Ae),He.el=$e.el,Be===null&&cw(G,$e.el),ce&&no(ce,ye),(Xe=He.props&&He.props.onVnodeUpdated)&&no(()=>Fo(Xe,te,He,pe),ye)}else{let He;const{el:Ze,props:ce}=J,{bm:te,m:pe,parent:Be}=G,Xe=Ha(J);if(ca(G,!1),te&&yc(te),!Xe&&(He=ce&&ce.onVnodeBeforeMount)&&Fo(He,Be,J),ca(G,!0),Ze&&Ge){const $e=()=>{G.subTree=zm(G),Ge(Ze,G.subTree,G,ye,null)};Xe?J.type.__asyncLoader().then(()=>!G.isUnmounted&&$e()):$e()}else{const $e=G.subTree=zm(G);m(null,$e,ue,_e,G,ye,Ae),J.el=$e.el}if(pe&&no(pe,ye),!Xe&&(He=ce&&ce.onVnodeMounted)){const $e=J;no(()=>Fo(He,Be,$e),ye)}(J.shapeFlag&256||Be&&Ha(Be.vnode)&&Be.vnode.shapeFlag&256)&&G.a&&no(G.a,ye),G.isMounted=!0,J=ue=_e=null}},Pe=G.effect=new Rc(Ee,yt,()=>g0(me),G.scope),me=G.update=()=>{Pe.dirty&&Pe.run()};me.id=G.uid,ca(G,!0),me()},F=(G,J,ue)=>{J.component=G;const _e=G.vnode.props;G.vnode=J,G.next=null,wV(G,J.props,_e,ue),SV(G,J.children,ue),Yl(),s4(G),Zl()},U=(G,J,ue,_e,ye,Ae,Le,Ee,Pe=!1)=>{const me=G&&G.children,He=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?(He&16&&xe(me,ye,Ae),Ze!==me&&c(ue,Ze)):He&16?te&16?I(me,Ze,ue,_e,ye,Ae,Le,Ee,Pe):xe(me,ye,Ae,!0):(He&8&&c(ue,""),te&16&&A(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,He=J.length,Ze=Math.min(me,He);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>He?xe(G,ye,Ae,!0,!1,Ze):A(J,ue,_e,ye,Ae,Le,Ee,Pe,Ze)},I=(G,J,ue,_e,ye,Ae,Le,Ee,Pe)=>{let me=0;const He=J.length;let Ze=G.length-1,ce=He-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<He?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;)re(G[me],ye,Ae,!0),me++;else{const te=me,pe=me,Be=new Map;for(me=pe;me<=ce;me++){const st=J[me]=Pe?ml(J[me]):ur(J[me]);st.key!=null&&Be.set(st.key,me)}let Xe,$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){re(st,ye,Ae,!0);continue}let se;if(st.key!=null)se=Be.get(st.key);else for(Xe=pe;Xe<=ce;Xe++)if(Se[Xe-pe]===0&&ss(st,J[Xe])){se=Xe;break}se===void 0?re(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 Ve=we?TV(Se):mc;for(Xe=Ve.length-1,me=ie-1;me>=0;me--){const st=pe+me,se=J[st],De=st+1<He?J[st+1].el:_e;Se[me]===0?m(null,se,ue,De,ye,Ae,Le,Ee,Pe):we&&(Xe<0||me!==Ve[Xe]?X(se,ue,De,2):Xe--)}}},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===Ua){_(G,J,ue);return}if(_e!==2&&me&1&&Ee)if(_e===0)Ee.beforeEnter(Ae),o(Ae,J,ue),no(()=>Ee.enter(Ae),ye);else{const{leave:Ze,delayLeave:ce,afterLeave:te}=Ee,pe=()=>o(Ae,J,ue),Be=()=>{Ze(Ae,()=>{pe(),te&&te()})};ce?ce(Ae,pe,Be):Be()}else o(Ae,J,ue)},re=(G,J,ue,_e=!1,ye=!1)=>{const{type:Ae,props:Le,ref:Ee,children:Pe,dynamicChildren:me,shapeFlag:He,patchFlag:Ze,dirs:ce}=G;if(Ee!=null&&pg(Ee,null,ue,G,!0),He&256){J.ctx.deactivate(G);return}const te=He&1&&ce,pe=!Ha(G);let Be;if(pe&&(Be=Le&&Le.onVnodeBeforeUnmount)&&Fo(Be,J,G),He&6)Oe(G.component,ue,_e);else{if(He&128){G.suspense.unmount(ue,_e);return}te&&Fs(G,null,J,"beforeUnmount"),He&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&&He&16)&&xe(Pe,J,ue),_e&&z(G)}(pe&&(Be=Le&&Le.onVnodeUnmounted)||te)&&no(()=>{Be&&Fo(Be,J,G),te&&Fs(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===Ua){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,re(Le,G,J,ue)),Ee&&no(Ee,J),no(()=>{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++)re(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&&re(J._vnode,null,null,!0):m(J._vnode||null,G,J,null,null,null,ue),de||(de=!0,s4(),dg(),de=!1),J._vnode=G},le={p:m,um:re,m:X,r:z,mt:Z,mc:A,pc:U,pbc:N,n:ee,o:e};let Ie,Ge;return t&&([Ie,Ge]=t(le)),{render:ve,hydrate:Ie,createApp:yV(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 ca({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function IE(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function _w(e,t,n=!1){const o=e.children,r=t.children;if(Te(o)&&Te(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||_w(i,l)),l.type===Ai&&(l.el=i.el)}}function TV(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 MV=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,b_=(e,t)=>{const n=e&&e.to;return tt(n)?t?t(n):null:n},OV={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 M=t.target=b_(t.props,h),A=t.targetAnchor=m("");M&&(p(A,M),i==="svg"||v4(M)?i="svg":(i==="mathml"||y4(M))&&(i="mathml"));const P=(N,V)=>{w&16&&c(_,N,V,r,s,i,l,a)};v?P(n,E):M&&P(M,A)}else{t.el=e.el;const x=t.anchor=e.anchor,E=t.target=e.target,M=t.targetAnchor=e.targetAnchor,A=Lf(e.props),P=A?n:E,N=A?x:M;if(i==="svg"||v4(E)?i="svg":(i==="mathml"||y4(E))&&(i="mathml"),S?(f(e.dynamicChildren,S,P,r,s,i,l),_w(e,t,!0)):a||d(e,t,P,N,r,s,i,l,!1),v)A?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):om(t,n,x,u,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const V=t.target=b_(t.props,h);V&&om(t,V,null,u,0)}else A&&om(t,E,M,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:om,hydrate:IV};function om(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 IV(e,t,n,o,r,s,{o:{nextSibling:i,parentNode:l,querySelector:a}},u){const c=t.target=b_(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=OV;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"),Gn=Symbol.for("v-cmt"),Ua=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 ou=1;function w_(e){ou+=e}function LE(e){return e.dynamicChildren=ou>0?jo||mc:null,PE(),ou>0&&jo&&jo.push(e),e}function T(e,t,n,o,r,s){return LE(b(e,t,n,o,r,s,!0))}function K(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 AV(e){}const RE=({key:e})=>e??null,jm=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?tt(e)||on(e)||Qe(e)?{i:Ln,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&&jm(t),scopeId:y0,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:Ln};return l?(ww(a,n),s&128&&e.normalize(a)):n&&(a.shapeFlag|=tt(n)?8:16),ou>0&&!i&&jo&&(a.patchFlag>0||s&6)&&a.patchFlag!==32&&jo.push(a),a}const k=NV;function NV(e,t=null,n=null,o=0,r=null,s=!1){if((!e||e===Q$)&&(e=Gn),yo(e)){const l=hs(e,t,!0);return n&&ww(l,n),ou>0&&!s&&jo&&(l.shapeFlag&6?jo[jo.indexOf(e)]=l:jo.push(l)),l.patchFlag|=-2,l}if(FV(e)&&(e=e.__vccOpts),t){t=bw(t);let{class:l,style:a}=t;l&&!tt(l)&&(t.class=D(l)),pt(a)&&(sw(a)&&!Te(a)&&(a=zt({},a)),t.style=et(a))}const i=tt(e)?1:eE(e)?128:MV(e)?64:pt(e)?4:Qe(e)?2:0;return b(e,t,n,o,r,i,s,!0)}function bw(e){return e?sw(e)||CE(e)?zt({},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?Te(r)?r.concat(jm(t)):[r,jm(t)]:jm(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(Ua,null,e);return n.staticCount=t,n}function j(e="",t=!1){return t?(C(),K(Gn,null,e)):k(Gn,null,e)}function ur(e){return e==null||typeof e=="boolean"?k(Gn):Te(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 ww(e,t){let n=0;const{shapeFlag:o}=e;if(t==null)t=null;else if(Te(t))n=16;else if(typeof t=="object")if(o&65){const r=t.default;r&&(r._c&&(r._d=!1),ww(e,r()),r._c&&(r._d=!0));return}else{n=32;const r=t._;!r&&!CE(t)?t._ctx=Ln:r===3&&Ln&&(Ln.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else Qe(t)?(t={default:t,_ctx:Ln},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=et([t.style,o.style]);else if(yu(r)){const s=t[r],i=o[r];i&&s!==i&&!(Te(s)&&s.includes(i))&&(t[r]=s?[].concat(s,i):i)}else r!==""&&(t[r]=o[r])}return t}function Fo(e,t,n,o=null){hr(e,t,7,[n,o])}const PV=bE();let LV=0;function VE(e,t,n){const o=e.type,r=(t?t.appContext:e.appContext)||PV,s={uid:LV++,vnode:e,type:o,parent:t,appContext:r,root:null,next:null,subTree:null,effect:null,update:null,scope:new X2(!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=PD.bind(null,s),e.ce&&e.ce(s),s}let Hn=null;const at=()=>Hn||Ln;let hg,C_;{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)}};hg=t("__VUE_INSTANCE_SETTERS__",n=>Hn=n),C_=t("__VUE_SSR_SETTERS__",n=>Jp=n)}const ru=e=>{const t=Hn;return hg(e),e.scope.on(),()=>{e.scope.off(),hg(t)}},k_=()=>{Hn&&Hn.scope.off(),hg(null)};function FE(e){return e.vnode.shapeFlag&4}let Jp=!1;function BE(e,t=!1){t&&C_(t);const{props:n,children:o}=e.vnode,r=FE(e);bV(e,n,r,t),kV(e,o);const s=r?RV(e,t):void 0;return t&&C_(!1),s}function RV(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,m_);const{setup:o}=n;if(o){const r=e.setupContext=o.length>1?HE(e):null,s=ru(e);Yl();const i=xi(o,e,0,[e.props,r]);if(Zl(),s(),Y2(i)){if(i.then(k_,k_),t)return i.then(l=>{S_(e,l,t)}).catch(l=>{wu(l,e,0)});e.asyncDep=i}else S_(e,i,t)}else jE(e,t)}function S_(e,t,n){Qe(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:pt(t)&&(e.setupState=aw(t)),jE(e,n)}let mg,$_;function zE(e){mg=e,$_=t=>{t.render._rc&&(t.withProxy=new Proxy(t.ctx,eV))}}const DV=()=>!mg;function jE(e,t,n){const o=e.type;if(!e.render){if(!t&&mg&&!o.render){const r=o.template||vw(e).template;if(r){const{isCustomElement:s,compilerOptions:i}=e.appContext.config,{delimiters:l,compilerOptions:a}=o,u=zt(zt({isCustomElement:s,delimiters:l},i),a);o.render=mg(r,u)}}e.render=o.render||yt,$_&&$_(e)}{const r=ru(e);Yl();try{fV(e)}finally{Zl(),r()}}}const VV={get(e,t){return Yo(e,"get",""),e[t]}};function HE(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,VV),slots:e.slots,emit:e.emit,expose:t}}function w0(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(aw(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_(e,t=!0){return Qe(e)?e.displayName||e.name:e.name||t&&e.__name}function FV(e){return Qe(e)&&"__vccOpts"in e}const R=(e,t)=>j$(e,t,Jp);function BV(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?pt(t)&&!Te(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 zV(){}function jV(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 ou>0&&jo&&jo.push(e),!0}const WE="3.4.23",KE=yt,HV=MD,UV=Uu,WV=Y$,KV={createComponentInstance:VE,setupComponent:BE,renderComponentRoot:zm,setCurrentRenderingInstance:gp,isVNode:yo,normalizeVNode:ur},qV=KV,GV=null,YV=null,ZV=null;/** |
| 14 |
* @vue/runtime-dom v3.4.23 |
| 15 |
* (c) 2018-present Yuxi (Evan) You and Vue contributors |
| 16 |
* @license MIT |
| 17 |
**/const JV="http://www.w3.org/2000/svg",XV="http://www.w3.org/1998/Math/MathML",gl=typeof document<"u"?document:null,_4=gl&&gl.createElement("template"),QV={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(JV,e):t==="mathml"?gl.createElementNS(XV,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",Fc=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},eF=_r.props=zt({},mw,qE),da=(e,t=[])=>{Te(e)?e.forEach(n=>n(...t)):e&&e(...t)},b4=e=>e?Te(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=tF(r),m=h&&h[0],y=h&&h[1],{onBeforeEnter:v,onEnter:w,onEnterCancelled:_,onLeave:S,onLeaveCancelled:x,onBeforeAppear:E=v,onAppear:M=w,onAppearCancelled:A=_}=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()},V=B=>(Y,Z)=>{const W=B?M:w,H=()=>P(Y,B,Z);da(W,[Y,H]),w4(()=>{Qi(Y,B?a:s),fi(Y,B?c:l),b4(W)||C4(Y,o,m,H)})};return zt(t,{onBeforeEnter(B){da(v,[B]),fi(B,s),fi(B,i)},onBeforeAppear(B){da(E,[B]),fi(B,a),fi(B,u)},onEnter:V(!1),onAppear:V(!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))}),da(S,[B,Z])},onEnterCancelled(B){P(B,!1),da(_,[B])},onAppearCancelled(B){P(B,!0),da(A,[B])},onLeaveCancelled(B){N(B),da(x,[B])}})}function tF(e){if(e==null)return null;if(pt(e))return[Bv(e.enter),Bv(e.leave)];{const t=Bv(e);return[t,t]}}function Bv(e){return ag(e)}function fi(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Fc]||(e[Fc]=new Set)).add(t)}function Qi(e,t){t.split(/\s+/).forEach(o=>o&&e.classList.remove(o));const n=e[Fc];n&&(n.delete(t),n.size||(e[Fc]=void 0))}function w4(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let nF=0;function C4(e,t,n,o){const r=e._endId=++nF,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 oF(e,t,n){const o=e[Fc];o&&(t=(t?[t,...o]:[...o]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const gg=Symbol("_vod"),JE=Symbol("_vsh"),en={beforeMount(e,{value:t},{transition:n}){e[gg]=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[gg]:"none",e[JE]=!t}function rF(){en.getSSRProps=({value:e})=>{if(!e)return{style:{display:"none"}}}}const XE=Symbol("");function sF(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=>T_(s,r))},o=()=>{const r=e(t.proxy);x_(t.subTree,r),n(r)};Ct(()=>{rE(o);const r=new MutationObserver(o);r.observe(t.subTree.el.parentNode,{childList:!0}),oi(()=>r.disconnect())})}function x_(e,t){if(e.shapeFlag&128){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push(()=>{x_(n.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(e.shapeFlag&1&&e.el)T_(e.el,t);else if(e.type===fe)e.children.forEach(n=>x_(n,t));else if(e.type===Ua){let{el:n,anchor:o}=e;for(;n&&(T_(n,t),n!==o);)n=n.nextSibling}}function T_(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 iF=/(^|;)\s*display\s*:/;function lF(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&&Hm(o,l,"")}else for(const i in t)n[i]==null&&Hm(o,i,"");for(const i in n)i==="display"&&(s=!0),Hm(o,i,n[i])}else if(r){if(t!==n){const i=o[XE];i&&(n+=";"+i),o.cssText=n,s=iF.test(n)}}else t&&e.removeAttribute("style");gg in e&&(e[gg]=s?o.display:"",e[JE]&&(o.display="none"))}const $4=/\s*!important$/;function Hm(e,t,n){if(Te(n))n.forEach(o=>Hm(e,t,o));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const o=aF(e,t);$4.test(n)?e.setProperty(zo(o),n.replace($4,""),"important"):e[o]=n}}const E4=["Webkit","Moz","ms"],zv={};function aF(e,t){const n=zv[t];if(n)return n;let o=yn(t);if(o!=="filter"&&o in e)return zv[t]=o;o=Gl(o);for(let r=0;r<E4.length;r++){const s=E4[r]+o;if(s in e)return zv[t]=s}return t}const x4="http://www.w3.org/1999/xlink";function uF(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=qR(t);n==null||s&&!S$(n)?e.removeAttribute(t):e.setAttribute(t,s?"":n)}}function cF(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 dF(e,t,n,o){e.removeEventListener(t,n,o)}const T4=Symbol("_vei");function fF(e,t,n,o,r=null){const s=e[T4]||(e[T4]={}),i=s[t];if(o&&i)i.value=o;else{const[l,a]=pF(t);if(o){const u=s[t]=gF(o,r);bi(e,l,u,a)}else i&&(dF(e,l,i,a),s[t]=void 0)}}const M4=/(?:Once|Passive|Capture)$/;function pF(e){let t;if(M4.test(e)){t={};let o;for(;o=e.match(M4);)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 jv=0;const hF=Promise.resolve(),mF=()=>jv||(hF.then(()=>jv=0),jv=Date.now());function gF(e,t){const n=o=>{if(!o._vts)o._vts=Date.now();else if(o._vts<=n.attached)return;hr(vF(o,n.value),t,5,[o])};return n.value=e,n.attached=mF(),n}function vF(e,t){if(Te(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,yF=(e,t,n,o,r,s,i,l,a)=>{const u=r==="svg";t==="class"?oF(e,o,u):t==="style"?lF(e,n,o):yu(t)?q2(t)||fF(e,t,n,o,i):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):_F(e,t,o,u))?cF(e,t,o,s,i,l,a):(t==="true-value"?e._trueValue=o:t==="false-value"&&(e._falseValue=o),uF(e,t,o,u))};function _F(e,t,n,o){if(o)return!!(t==="innerHTML"||t==="textContent"||t in e&&O4(t)&&Qe(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 C0{constructor(s){super(n,s,t)}}return o.def=n,o}/*! #__NO_SIDE_EFFECTS__ */const bF=e=>QE(e,c7),wF=typeof HTMLElement<"u"?HTMLElement:class{};class C0 extends wF{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&&!Te(s))for(const a in s){const u=s[a];(u===Number||u&&u.type===Number)&&(a in this._props&&(this._props[a]=ag(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=Te(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=ag(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,zt({},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 C0){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 CF(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,vg=Symbol("_moveCb"),I4=Symbol("_enterCb"),n7={name:"TransitionGroup",props:zt({},eF,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=at(),o=hw();let r,s;return Vi(()=>{if(!r.length)return;const i=e.moveClass||`${e.name||"v"}-move`;if(!xF(r[0].el,n.vnode.el,i))return;r.forEach(SF),r.forEach($F);const l=r.filter(EF);ZE(),l.forEach(a=>{const u=a.el,c=u.style;fi(u,i),c.transform=c.webkitTransform=c.transitionDuration="";const d=u[vg]=f=>{f&&f.target!==u||(!f||/transform$/.test(f.propertyName))&&(u.removeEventListener("transitionend",d),u[vg]=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),nu(c,Vc(c,l,o,n)),e7.set(c,c.el.getBoundingClientRect()))}s=t.default?_0(t.default()):[];for(let u=0;u<s.length;u++){const c=s[u];c.key!=null&&nu(c,Vc(c,l,o,n))}return k(a,null,s)}}},kF=e=>delete e.mode;n7.props;const k0=n7;function SF(e){const t=e.el;t[vg]&&t[vg](),t[I4]&&t[I4]()}function $F(e){t7.set(e,e.el.getBoundingClientRect())}function EF(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 xF(e,t,n){const o=e.cloneNode(),r=e[Fc];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 zl=e=>{const t=e.props["onUpdate:modelValue"]||!1;return Te(t)?n=>yc(t,n):t};function TF(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]=zl(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=lg(l)),e[Pr](l)}),n&&bi(e,"change",()=>{e.value=e.value.trim()}),t||(bi(e,"compositionstart",TF),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]=zl(s),e.composing)return;const i=(r||e.type==="number")&&!/^0\d/.test(e.value)?lg(e.value):e.value,l=t??"";i!==l&&(document.activeElement===e&&e.type!=="range"&&(n||o&&e.value.trim()===l)||(e.value=l))}},su={deep:!0,created(e,t,n){e[Pr]=zl(n),bi(e,"change",()=>{const o=e._modelValue,r=zc(e),s=e.checked,i=e[Pr];if(Te(o)){const l=f0(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(_u(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]=zl(n),N4(e,t,n)}};function N4(e,{value:t,oldValue:n},o){e._modelValue=t,Te(t)?e.checked=f0(t,o.props.value)>-1:_u(t)?e.checked=t.has(o.props.value):t!==n&&(e.checked=Fl(t,r7(e,!0)))}const Xp={created(e,{value:t},n){e.checked=Fl(t,n.props.value),e[Pr]=zl(n),bi(e,"change",()=>{e[Pr](zc(e))})},beforeUpdate(e,{value:t,oldValue:n},o){e[Pr]=zl(o),t!==n&&(e.checked=Fl(t,o.props.value))}},o7={deep:!0,created(e,{value:t,modifiers:{number:n}},o){const r=_u(t);bi(e,"change",()=>{const s=Array.prototype.filter.call(e.options,i=>i.selected).map(i=>n?lg(zc(i)):zc(i));e[Pr](e.multiple?r?new Set(s):s:s[0]),e._assigning=!0,ot(()=>{e._assigning=!1})}),e[Pr]=zl(o)},mounted(e,{value:t,modifiers:{number:n}}){P4(e,t)},beforeUpdate(e,t,n){e[Pr]=zl(n)},updated(e,{value:t,modifiers:{number:n}}){e._assigning||P4(e,t)}};function P4(e,t,n){const o=e.multiple,r=Te(t);if(!(o&&!r&&!_u(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=f0(t,a)>-1}else l.selected=t.has(a);else if(Fl(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){rm(e,t,n,null,"created")},mounted(e,t,n){rm(e,t,n,null,"mounted")},beforeUpdate(e,t,n,o){rm(e,t,n,o,"beforeUpdate")},updated(e,t,n,o){rm(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 su;case"radio":return Xp;default:return Bc}}}function rm(e,t,n,o,r){const i=i7(e.tagName,n.props&&n.props.type)[r];i&&i(e,t,n,o)}function MF(){Bc.getSSRProps=({value:e})=>({value:e}),Xp.getSSRProps=({value:e},t)=>{if(t.props&&Fl(t.props.value,e))return{checked:!0}},su.getSSRProps=({value:e},t)=>{if(Te(e)){if(t.props&&f0(e,t.props.value)>-1)return{checked:!0}}else if(_u(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 OF=["ctrl","shift","alt","meta"],IF={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)=>OF.some(n=>e[`${n}Key`]&&!t.includes(n))},Je=(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=IF[t[i]];if(l&&l(r,t))return}return e(r,...s)})},AF={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||AF[i]===s))return e(r)})},l7=zt({patchProp:yF},QV);let Df,L4=!1;function a7(){return Df||(Df=TE(l7))}function u7(){return Df=L4?Df:ME(l7),L4=!0,Df}const Ni=(...e)=>{a7().render(...e)},c7=(...e)=>{u7().hydrate(...e)},Cw=(...e)=>{const t=a7().createApp(...e),{mount:n}=t;return t.mount=o=>{const r=f7(o);if(!r)return;const s=t._component;!Qe(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},NF=(...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 PF=()=>{R4||(R4=!0,MF(),rF())},LF=Object.freeze(Object.defineProperty({__proto__:null,BaseTransition:lE,BaseTransitionPropsValidators:mw,Comment:Gn,DeprecationTypes:ZV,EffectScope:X2,ErrorCodes:TD,ErrorTypeStrings:HV,Fragment:fe,KeepAlive:XD,ReactiveEffect:Rc,Static:Ua,Suspense:jD,Teleport:_s,Text:Ai,TrackOpTypes:$D,Transition:_r,TransitionGroup:k0,TriggerOpTypes:ED,VueElement:C0,assertNumber:xD,callWithAsyncErrorHandling:hr,callWithErrorHandling:xi,camelize:yn,capitalize:Gl,cloneVNode:hs,compatUtils:YV,computed:R,createApp:Cw,createBlock:K,createCommentVNode:j,createElementBlock:T,createElementVNode:b,createHydrationRenderer:ME,createPropsRestProxy:cV,createRenderer:TE,createSSRApp:NF,createSlots:Bl,createStaticVNode:DE,createTextVNode:ne,createVNode:k,customRef:U$,defineAsyncComponent:ZD,defineComponent:Q,defineCustomElement:QE,defineEmits:nV,defineExpose:oV,defineModel:iV,defineOptions:rV,defineProps:tV,defineSSRCustomElement:bF,defineSlots:sV,devtools:UV,effect:ZR,effectScope:E$,getCurrentInstance:at,getCurrentScope:Q2,getTransitionRawChildren:_0,guardReactiveProps:bw,h:lt,handleError:wu,hasInjectionContext:_V,hydrate:c7,initCustomFormatter:zV,initDirectivesForSSR:PF,inject:ze,isMemoSame:UE,isProxy:sw,isReactive:_c,isReadonly:Dc,isRef:on,isRuntimeOnly:DV,isShallow:fp,isVNode:yo,markRaw:Ii,mergeDefaults:aV,mergeModels:uV,mergeProps:un,nextTick:ot,normalizeClass:D,normalizeProps:J2,normalizeStyle:et,onActivated:uE,onBeforeMount:yd,onBeforeUnmount:En,onBeforeUpdate:dE,onDeactivated:gw,onErrorCaptured:mE,onMounted:Ct,onRenderTracked:hE,onRenderTriggered:pE,onScopeDispose:ew,onServerPrefetch:fE,onUnmounted:oi,onUpdated:Vi,openBlock:C,popScopeId:X$,provide:wt,proxyRefs:aw,pushScopeId:J$,queuePostFlushCb:cg,reactive:Vn,readonly:bu,ref:q,registerRuntimeCompiler:zE,render:Ni,renderList:nt,renderSlot:he,resolveComponent:oe,resolveDirective:Dt,resolveDynamicComponent:Lt,resolveFilter:GV,resolveTransitionHooks:Vc,setBlockTracking:w_,setDevtoolsHook:WV,setTransitionHooks:nu,shallowReactive:rw,shallowReadonly:vD,shallowRef:Mn,ssrContextKey:nE,ssrUtils:qV,stop:JR,toDisplayString:O,toHandlerKey:vc,toHandlers:vE,toRaw:Mt,toRef:pn,toRefs:ni,toValue:bD,transformVNodeArgs:AV,triggerRef:_D,unref:g,useAttrs:_d,useCssModule:CF,useCssVars:sF,useModel:BV,useSSRContext:oE,useSlots:Kr,useTransitionState:hw,vModelCheckbox:su,vModelDynamic:s7,vModelRadio:Xp,vModelSelect:o7,vModelText:Bc,vShow:en,version:WE,warn:KE,watch:Me,watchEffect:ls,watchPostEffect:rE,watchSyncEffect:sE,withAsyncContext:dV,withCtx:$,withDefaults:lV,withDirectives:Fe,withKeys:Pt,withMemo:jV,withModifiers:Je,withScopeId:LD},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(""),Vf=Symbol(""),kw=Symbol(""),yg=Symbol(""),p7=Symbol(""),iu=Symbol(""),h7=Symbol(""),m7=Symbol(""),Sw=Symbol(""),$w=Symbol(""),Qp=Symbol(""),Ew=Symbol(""),g7=Symbol(""),xw=Symbol(""),Tw=Symbol(""),Mw=Symbol(""),Ow=Symbol(""),Iw=Symbol(""),Aw=Symbol(""),v7=Symbol(""),y7=Symbol(""),S0=Symbol(""),_g=Symbol(""),Nw=Symbol(""),Pw=Symbol(""),bp=Symbol(""),eh=Symbol(""),Lw=Symbol(""),M_=Symbol(""),RF=Symbol(""),O_=Symbol(""),bg=Symbol(""),DF=Symbol(""),VF=Symbol(""),Rw=Symbol(""),FF=Symbol(""),BF=Symbol(""),Dw=Symbol(""),_7=Symbol(""),jc={[_p]:"Fragment",[Vf]:"Teleport",[kw]:"Suspense",[yg]:"KeepAlive",[p7]:"BaseTransition",[iu]:"openBlock",[h7]:"createBlock",[m7]:"createElementBlock",[Sw]:"createVNode",[$w]:"createElementVNode",[Qp]:"createCommentVNode",[Ew]:"createTextVNode",[g7]:"createStaticVNode",[xw]:"resolveComponent",[Tw]:"resolveDynamicComponent",[Mw]:"resolveDirective",[Ow]:"resolveFilter",[Iw]:"withDirectives",[Aw]:"renderList",[v7]:"renderSlot",[y7]:"createSlots",[S0]:"toDisplayString",[_g]:"mergeProps",[Nw]:"normalizeClass",[Pw]:"normalizeStyle",[bp]:"normalizeProps",[eh]:"guardReactiveProps",[Lw]:"toHandlers",[M_]:"camelize",[RF]:"capitalize",[O_]:"toHandlerKey",[bg]:"setBlockTracking",[DF]:"pushScopeId",[VF]:"popScopeId",[Rw]:"withCtx",[FF]:"unref",[BF]:"isRef",[Dw]:"withMemo",[_7]:"isMemoSame"};function zF(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 jF(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(iu),e.helper(Wc(e.inSSR,u))):e.helper(Uc(e.inSSR,u)),i&&e.helper(Iw)),{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 jn(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 I_(e,t,n,o=!0){return{type:19,test:e,consequent:t,alternate:n,newline:o,loc:br}}function HF(e,t,n=!1){return{type:20,index:e,value:t,isVNode:n,loc:br}}function UF(e){return{type:21,body:e,loc:br}}function Uc(e,t){return e||t?Sw:$w}function Wc(e,t){return e||t?h7:m7}function Vw(e,{helper:t,removeHelper:n,inSSR:o}){e.isBlock||(e.isBlock=!0,n(Uc(o,e.isComponent)),t(iu),t(Wc(o,e.isComponent)))}const D4=new Uint8Array([123,123]),V4=new Uint8Array([125,125]);function F4(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 wg(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 WF{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=V4,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=V4}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):F4(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(wg("</"+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=F4(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 Wa(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 Wa(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 Vf;case"Suspense":case"suspense":return kw;case"KeepAlive":case"keep-alive":return yg;case"BaseTransition":case"base-transition":return p7}}const KF=/^\d|[^\$\w]/,Bw=e=>!KF.test(e),qF=/[A-Za-z_$\xA0-\uFFFF]/,GF=/[\.\?\w$\xA0-\uFFFF]/,YF=/\s+[.[]\s*|\s*[.[]\s+/g,ZF=e=>{e=e.trim().replace(YF,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?qF:GF).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=ZF;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 $0(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)&&Ia(s.arg,t))return s}}function Ia(e,t){return!!(e&&Ho(e)&&e.content===t)}function JF(e){return e.props.some(t=>t.type===7&&t.name==="bind"&&(!t.arg||t.arg.type!==4||!t.arg.isStatic))}function Hv(e){return e.type===5||e.type===2}function XF(e){return e.type===7&&e.name==="slot"}function Cg(e){return e.type===1&&e.tagType===3}function kg(e){return e.type===1&&e.tagType===2}const QF=new Set([bp,eh]);function k7(e,t=[]){if(e&&!tt(e)&&e.type===14){const n=e.callee;if(!tt(n)&&QF.has(n))return k7(e.arguments[0],t.concat(e))}return[e,t]}function Sg(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===Lw?o=jn(n.helper(_g),[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=jn(n.helper(_g),[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 eB(e){return e.type===14&&e.callee===Dw?e.arguments[1].returns:e}const tB=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,S7={parseMode:"base",ns:0,delimiters:["{{","}}"],getNamespace:()=>0,isVoidTag:Fm,isPreTag:Fm,isCustomElement:Fm,onError:Fw,onWarn:b7,comments:!1,prefixIdentifiers:!1};let Gt=S7,Sp=null,Ti="",po=null,Ft=null,Do="",pi=-1,ya=-1,$g=0,vl=!1,A_=null;const Cn=[],Sn=new WF(Cn,{onerr:ai,ontext(e,t){sm(eo(e,t),e,t)},ontextentity(e,t,n){sm(e,t,n)},oninterpolation(e,t){if(vl)return sm(eo(e,t),e,t);let n=e+Sn.delimiterOpen.length,o=t-Sn.delimiterClose.length;for(;lr(Ti.charCodeAt(n));)n++;for(;lr(Ti.charCodeAt(o-1));)o--;let r=eo(n,o);r.includes("&")&&(r=Gt.decodeEntities(r,!1)),N_({type:5,content:Wm(r,!1,zn(n,o)),loc:zn(e,t)})},onopentagname(e,t){const n=eo(e,t);po={type:1,tag:n,ns:Gt.getNamespace(n,Cn[0],Gt.ns),tagType:0,props:[],children:[],loc:zn(e-1,t),codegenNode:void 0}},onopentagend(e){H4(e)},onclosetag(e,t){const n=eo(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();Um(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&&Um(Cn.shift(),e)},onattribname(e,t){Ft={type:6,name:eo(e,t),nameLoc:zn(e,t),value:void 0,loc:zn(e)}},ondirname(e,t){const n=eo(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:zn(e,t),value:void 0,loc:zn(e)};else if(Ft={type:7,name:o,rawName:n,exp:void 0,arg:void 0,modifiers:n==="."?["prop"]:[],loc:zn(e)},o==="pre"){vl=Sn.inVPre=!0,A_=po;const r=po.props;for(let s=0;s<r.length;s++)r[s].type===7&&(r[s]=dB(r[s]))}},ondirarg(e,t){if(e===t)return;const n=eo(e,t);if(vl)Ft.name+=n,Aa(Ft.nameLoc,t);else{const o=n[0]!=="[";Ft.arg=Wm(o?n:n.slice(1,-1),o,zn(e,t),o?3:0)}},ondirmodifier(e,t){const n=eo(e,t);if(vl)Ft.name+="."+n,Aa(Ft.nameLoc,t);else if(Ft.name==="slot"){const o=Ft.arg;o&&(o.content+="."+n,Aa(o.loc,t))}else Ft.modifiers.push(n)},onattribdata(e,t){Do+=eo(e,t),pi<0&&(pi=e),ya=t},onattribentity(e,t,n){Do+=e,pi<0&&(pi=t),ya=n},onattribnameend(e){const t=Ft.loc.start.offset,n=eo(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(Aa(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?zn(pi,ya):zn(pi-1,ya+1)},Sn.inSFCRoot&&po.tag==="template"&&Ft.name==="lang"&&Do&&Do!=="html"&&Sn.enterRCDATA(wg("</template"),0);else{let n=0;Ft.exp=Wm(Do,!1,zn(pi,ya),0,n),Ft.name==="for"&&(Ft.forParseResult=oB(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=ya=-1},oncomment(e,t){Gt.comments&&N_({type:3,content:eo(e,t),loc:zn(e-4,t+3)})},onend(){const e=Ti.length;for(let t=0;t<Cn.length;t++)Um(Cn[t],e-1),ai(24,Cn[t].loc.start.offset)},oncdata(e,t){Cn[0].ns!==0?sm(eo(e,t),e,t):ai(1,e-9)},onprocessinginstruction(e){(Cn[0]?Cn[0].ns:Gt.ns)===0&&ai(21,e-1)}}),j4=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,nB=/^\(|\)$/g;function oB(e){const t=e.loc,n=e.content,o=n.match(tB);if(!o)return;const[,r,s]=o,i=(d,f,p=!1)=>{const h=t.start.offset+f,m=h+d.length;return Wm(d,!1,zn(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(nB,"").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 eo(e,t){return Ti.slice(e,t)}function H4(e){Sn.inSFCRoot&&(po.innerLoc=zn(e+1,e+1)),N_(po);const{tag:t,ns:n}=po;n===0&&Gt.isPreTag(t)&&$g++,Gt.isVoidTag(t)?Um(po,e):(Cn.unshift(po),(n===1||n===2)&&(Sn.inXML=!0)),po=null}function sm(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,Aa(s.loc,n)):r.children.push({type:2,content:e,loc:zn(t,n)})}function Um(e,t,n=!1){n?Aa(e.loc,$7(t,60)):Aa(e.loc,rB(t,62)+1),Sn.inSFCRoot&&(e.children.length?e.innerLoc.end=zt({},e.children[e.children.length-1].loc.end):e.innerLoc.end=zt({},e.innerLoc.start),e.innerLoc.source=eo(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:iB(e)&&(e.tagType=1)),Sn.inRCDATA||(e.children=E7(e.children,e.tag)),r===0&&Gt.isPreTag(o)&&$g--,A_===e&&(vl=Sn.inVPre=!1,A_=null),Sn.inXML&&(Cn[0]?Cn[0].ns:Gt.ns)===0&&(Sn.inXML=!1);{const s=e.props;if(!Sn.inSFCRoot&&Wa("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:eo(e.children[0].loc.start.offset,e.children[e.children.length-1].loc.end.offset),loc:i.loc})}}function rB(e,t){let n=e;for(;Ti.charCodeAt(n)!==t&&n<Ti.length-1;)n++;return n}function $7(e,t){let n=e;for(;Ti.charCodeAt(n)!==t&&n>=0;)n--;return n}const sB=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&&sB.has(t[n].name))return!0}return!1}function iB({tag:e,props:t}){var n;if(Gt.isCustomElement(e))return!1;if(e==="component"||lB(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"&&Ia(r.arg,"is")&&Cp("COMPILER_IS_ON_ELEMENT",Gt,r.loc))return!0}return!1}function lB(e){return e>64&&e<91}const aB=/\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($g)l.content=l.content.replace(aB,` |
| 22 |
`);else if(uB(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&&cB(l.content)))?(s=!0,e[i]=null):l.content=" "}else r&&(l.content=x7(l.content))}if($g&&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 uB(e){for(let t=0;t<e.length;t++)if(!lr(e.charCodeAt(t)))return!1;return!0}function cB(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 N_(e){(Cn[0]||Sp).children.push(e)}function zn(e,t){return{start:Sn.getPos(e),end:t==null?t:Sn.getPos(t),source:t==null?t:eo(e,t)}}function Aa(e,t){e.end=Sn.getPos(t),e.source=eo(e.start.offset,t)}function dB(e){const t={type:6,name:e.rawName,nameLoc:zn(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 Wm(e,t=!1,n,o=0,r=0){return St(e,t,n,o)}function ai(e,t,n){Gt.onError(vn(e,zn(t,t)))}function fB(){Sn.reset(),po=null,Ft=null,Do="",pi=-1,ya=-1,Cn.length=0}function pB(e,t){if(fB(),Ti=e,Gt=zt({},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=wg(n[0]),Sn.delimiterClose=wg(n[1]));const o=Sp=jF([],e);return Sn.parse(Ti),o.loc=zn(0,e.length),o.children=E7(o.children),Sp=null,o}function hB(e,t){Km(e,t,T7(e,e.children[0]))}function T7(e,t){const{children:n}=e;return n.length===1&&t.type===1&&!kg(t)}function Km(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++,Km(l,t),a&&t.scopes.vSlot--}else if(l.type===11)Km(l,t,l.children.length===1);else if(l.type===9)for(let a=0;a<l.branches.length;a++)Km(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&&Te(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(iu),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)||Vr(a))continue;const u=Ar(a,t);if(u===0)return 0;u<i&&(i=u)}return i;default:return 0}}const mB=new Set([Nw,Pw,bp,eh]);function M7(e,t){if(e.type===14&&!tt(e.callee)&&mB.has(e.callee)){const n=e.arguments[0];if(n.type===4)return Ar(n,t);if(n.type===14)return M7(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=M7(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 gB(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 M=t.replace(/\?.*$/,"").match(/([^/\\]+)\.\w+$/),A={filename:t,selfName:M&&Gl(yn(M[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=A.helpers.get(P)||0;return A.helpers.set(P,N+1),P},removeHelper(P){const N=A.helpers.get(P);if(N){const V=N-1;V?A.helpers.set(P,V):A.helpers.delete(P)}},helperString(P){return`_${jc[A.helper(P)]}`},replaceNode(P){A.parent.children[A.childIndex]=A.currentNode=P},removeNode(P){const N=A.parent.children,V=P?N.indexOf(P):A.currentNode?A.childIndex:-1;!P||P===A.currentNode?(A.currentNode=null,A.onNodeRemoved()):A.childIndex>V&&(A.childIndex--,A.onNodeRemoved()),A.parent.children.splice(V,1)},onNodeRemoved:yt,addIdentifiers(P){},removeIdentifiers(P){},hoist(P){tt(P)&&(P=St(P)),A.hoists.push(P);const N=St(`_hoisted_${A.hoists.length}`,!1,P.loc,2);return N.hoisted=P,N},cache(P,N=!1){return HF(A.cached++,P,N)}};return A.filters=new Set,A}function vB(e,t){const n=gB(e,t);E0(e,n),t.hoistStatic&&hB(e,n),t.ssr||yB(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 yB(e,t){const{helper:n}=t,{children:o}=e;if(o.length===1){const r=o[0];if(T7(e,r)&&r.codegenNode){const s=r.codegenNode;s.type===13&&Vw(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 _B(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,E0(r,t))}}function E0(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&&(Te(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(S0);break;case 9:for(let s=0;s<e.branches.length;s++)E0(e.branches[s],t);break;case 10:case 11:case 1:case 0:_B(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(XF))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 x0="/*#__PURE__*/",P7=e=>`${jc[e]}: _${jc[e]}`;function bB(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 wB(e,t={}){const n=bB(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";CB(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&&(Uv(e.components,"component",n),(e.directives.length||e.temps>0)&&a()),e.directives.length&&(Uv(e.directives,"directive",n),e.temps>0&&a()),e.filters&&e.filters.length&&(a(),Uv(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 CB(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=[Sw,$w,Qp,Ew,g7].filter(f=>c.includes(f)).map(P7).join(", ");r(`const { ${d} } = _Vue |
| 27 |
`,-1)}kB(e.hoists,t),s(),r("return ")}function Uv(e,t,{helper:n,push:o,newline:r,isTS:s}){const i=n(t==="filter"?Ow:t==="component"?xw: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 kB(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 zw(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):Te(l)?zw(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(Vr(e)){t.push(t.helper(e));return}switch(e.type){case 1:case 9:case 11:go(e.codegenNode,t);break;case 2:SB(e,t);break;case 4:L7(e,t);break;case 5:$B(e,t);break;case 12:go(e.codegenNode,t);break;case 8:R7(e,t);break;case 3:xB(e,t);break;case 13:TB(e,t);break;case 14:OB(e,t);break;case 15:IB(e,t);break;case 17:AB(e,t);break;case 18:NB(e,t);break;case 19:PB(e,t);break;case 20:LB(e,t);break;case 21:nh(e.body,t,!0,!1);break}}function SB(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 $B(e,t){const{push:n,helper:o,pure:r}=t;r&&n(x0),n(`${o(S0)}(`),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 EB(e,t){const{push:n}=t;if(e.type===8)n("["),R7(e,t),n("]");else if(e.isStatic){const o=Bw(e.content)?e.content:JSON.stringify(e.content);n(o,-2,e)}else n(`[${e.content}]`,-3,e)}function xB(e,t){const{push:n,helper:o,pure:r}=t;r&&n(x0),n(`${o(Qp)}(${JSON.stringify(e.content)})`,-3,e)}function TB(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(Iw)+"("),d&&n(`(${o(iu)}(${f?"true":""}), `),r&&n(x0);const h=d?Wc(t.inSSR,p):Uc(t.inSSR,p);n(o(h)+"(",-2,e),nh(MB([s,i,l,a,u]),t),n(")"),d&&n(")"),c&&(n(", "),go(c,t),n(")"))}function MB(e){let t=e.length;for(;t--&&e[t]==null;);return e.slice(0,t+1).map(n=>n||"null")}function OB(e,t){const{push:n,helper:o,pure:r}=t,s=tt(e.callee)?e.callee:o(e.callee);r&&n(x0),n(s+"(",-2,e),nh(e.arguments,t),n(")")}function IB(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];EB(u,t),n(": "),go(c,t),a<i.length-1&&(n(","),s())}l&&r(),n(l?"}":" }")}function AB(e,t){zw(e.elements,t)}function NB(e,t){const{push:n,indent:o,deindent:r}=t,{params:s,returns:i,body:l,newline:a,isSlot:u}=e;u&&n(`_${jc[Rw]}(`),n("(",-2,e),Te(s)?nh(s,t):s&&go(s,t),n(") => "),(a||l)&&(n("{"),o()),i?(a&&n("return "),Te(i)?zw(i,t):go(i,t)):l&&go(l,t),(a||l)&&(r(),n("}")),u&&(e.isNonScopedSlot&&n(", undefined, true"),n(")"))}function PB(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=!Bw(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 LB(e,t){const{push:n,helper:o,indent:r,deindent:s,newline:i}=t;n(`_cache[${e.index}] || (`),e.isVNode&&(r(),n(`${o(bg)}(-1),`),i()),n(`_cache[${e.index}] = `),go(e.value,t),e.isVNode&&(n(","),i(),n(`${o(bg)}(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 RB=N7(/^(if|else|else-if)$/,(e,t,n)=>DB(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=VB(o.codegenNode);u.alternate=K4(r,a+o.branches.length-1,n)}}}));function DB(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);E0(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:$0(e,"key"),isTemplateIf:n}}function K4(e,t,n){return e.condition?I_(e.condition,q4(e,t,n),jn(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 Sg(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=eB(a);return u.type===13&&Vw(u,n),Sg(u,r,n),a}}function VB(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 FB=N7("for",(e,t,n)=>{const{helper:o,removeHelper:r}=n;return BB(e,t,n,s=>{const i=jn(o(Aw),[s.source]),l=Cg(e),a=ts(e,"memo"),u=$0(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=kg(e)?e:l&&e.children.length===1&&kg(e.children[0])?e.children[0]:null;if(v?(h=v.codegenNode,l&&d&&Sg(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&&Sg(h,d,n),h.isBlock!==!f&&(h.isBlock?(r(iu),r(Wc(n.inSSR,h.isComponent))):r(Uc(n.inSSR,h.isComponent))),h.isBlock=!f,h.isBlock?(o(iu),o(Wc(n.inSSR,h.isComponent))):o(Uc(n.inSSR,h.isComponent))),a){const w=Hc(P_(s.parseResult,[St("_cached")]));w.body=UF([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(P_(s.parseResult),h,!0))}})});function BB(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:Cg(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 P_({value:e,key:t,index:n},o=[]){return zB([e,t,n,...o])}function zB(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),jB=(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--}}},HB=(e,t,n,o)=>Hc(e,n,!1,!0,n.length?n[0].loc:o);function UB(e,t,n=HB){t.helper(Rw);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(!Cg(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:M}=w;let A;Ho(x)?A=x?x.content:"default":l=!0;const P=ts(v,"for"),N=n(E,P,_,S);let V,B;if(V=ts(v,"if"))l=!0,i.push(I_(V.exp,im(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&&Cg(Z)&&ts(Z,"if")){o.splice(y,1),y--;let W=i[i.length-1];for(;W.alternate.type===19;)W=W.alternate;W.alternate=B.exp?I_(B.exp,im(x,N,p++),G4):im(x,N,p++)}else t.onError(vn(30,B.loc))}else if(P){l=!0;const Y=P.forParseResult;Y?(D7(Y),i.push(jn(t.helper(Aw),[Y.source,Hc(P_(Y),im(x,N),!0)]))):t.onError(vn(32,P.loc))}else{if(A){if(f.has(A)){t.onError(vn(38,M));continue}f.add(A),A==="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=>V7(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:qm(e.children)?3:1;let m=Ir(s.concat($n("_",St(h+"",!1))),r);return i.length&&(m=jn(t.helper(y7),[m,th(i)])),{slots:m,hasDynamicSlots:l}}function im(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 qm(e){for(let t=0;t<e.length;t++){const n=e[t];switch(n.type){case 1:if(n.tagType===2||qm(n.children))return!0;break;case 9:if(qm(n.branches))return!0;break;case 10:case 11:if(qm(n.children))return!0;break}}return!1}function V7(e){return e.type!==2&&e.type!==12?!0:e.type===2?!!e.content.trim():V7(e.content)}const F7=new WeakMap,WB=(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?KB(e,t):`"${o}"`;const l=pt(i)&&i.callee===Tw;let a,u,c,d=0,f,p,h,m=l||i===Vf||i===kw||!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=>GB(w,t))):void 0,y.shouldUseBlock&&(m=!0)}if(e.children.length>0)if(i===yg&&(m=!0,d|=1024),s&&i!==Vf&&i!==yg){const{slots:v,hasDynamicSlots:w}=UB(e,t);u=v,w&&(d|=1024)}else if(e.children.length===1&&i!==Vf){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=YB(p))),e.codegenNode=wp(t,i,a,u,c,f,h,!!m,!1,s,e.loc)};function KB(e,t,n=!1){let{tag:o}=e;const r=L_(o),s=$0(e,"is",!1,!0);if(s)if(r||Wa("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 jn(t.helper(Tw),[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(xw),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)},M=({key:P,value:N})=>{if(Ho(P)){const V=P.content,B=yu(V);if(B&&(!o||r)&&V.toLowerCase()!=="onclick"&&V!=="onUpdate:modelValue"&&!Al(V)&&(w=!0),B&&Al(V)&&(S=!0),B&&N.type===14&&(N=N.arguments[0]),N.type===20||(N.type===4||N.type===8)&&Ar(N,t)>0)return;V==="ref"?m=!0:V==="class"?y=!0:V==="style"?v=!0:V!=="key"&&!x.includes(V)&&x.push(V),o&&(V==="class"||V==="style")&&!x.includes(V)&&x.push(V)}else _=!0};for(let P=0;P<n.length;P++){const N=n[P];if(N.type===6){const{loc:V,name:B,nameLoc:Y,value:Z}=N;let W=!0;if(B==="ref"&&(m=!0,t.scopes.vFor>0&&u.push($n(St("ref_for",!0),St("true")))),B==="is"&&(L_(i)||Z&&Z.content.startsWith("vue:")||Wa("COMPILER_IS_ON_ELEMENT",t)))continue;u.push($n(St(B,!0,Y),St(Z?Z.content:"",W,Z?Z.loc:V)))}else{const{name:V,arg:B,exp:Y,loc:Z,modifiers:W}=N,H=V==="bind",F=V==="on";if(V==="slot"){o||t.onError(vn(40,Z));continue}if(V==="once"||V==="memo"||V==="is"||H&&Ia(B,"is")&&(L_(i)||Wa("COMPILER_IS_ON_ELEMENT",t))||F&&s)continue;if((H&&Ia(B,"key")||F&&f&&Ia(B,"vue:before-update"))&&(p=!0),H&&Ia(B,"ref")&&t.scopes.vFor>0&&u.push($n(St("ref_for",!0),St("true"))),!B&&(H||F)){if(_=!0,Y)if(H){if(E(),Wa("COMPILER_V_BIND_OBJECT_ORDER",t)){c.unshift(Y);continue}c.push(Y)}else E({type:14,loc:Z,callee:t.helper(Lw),arguments:o?[Y]:[Y,"true"]});else t.onError(vn(H?34:35,Z));continue}H&&W.includes("prop")&&(h|=32);const U=t.directiveTransforms[V];if(U){const{props:L,needRuntime:I}=U(N,e,t);!s&&L.forEach(M),F&&B&&!Ho(B)?E(Ir(L,l)):u.push(...L),I&&(d.push(N),Vr(I)&&F7.set(N,I))}else OR(V)||(d.push(N),f&&(p=!0))}}let A;if(c.length?(E(),c.length>1?A=jn(t.helper(_g),c,l):A=c[0]):u.length&&(A=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&&A)switch(A.type){case 15:let P=-1,N=-1,V=!1;for(let Z=0;Z<A.properties.length;Z++){const W=A.properties[Z].key;Ho(W)?W.content==="class"?P=Z:W.content==="style"&&(N=Z):W.isHandlerKey||(V=!0)}const B=A.properties[P],Y=A.properties[N];V?A=jn(t.helper(bp),[A]):(B&&!Ho(B.value)&&(B.value=jn(t.helper(Nw),[B.value])),Y&&(v||Y.value.type===4&&Y.value.content.trim()[0]==="["||Y.value.type===17)&&(Y.value=jn(t.helper(Pw),[Y.value])));break;case 14:break;default:A=jn(t.helper(bp),[jn(t.helper(eh),[A])]);break}return{props:A,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"||yu(s))&&qB(i,r):(t.set(s,r),n.push(r))}return n}function qB(e,t){e.value.type===17?e.value.elements.push(t.value):e.value=th([e.value,t.value],e.loc)}function GB(e,t){const n=[],o=F7.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 YB(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 L_(e){return e==="component"||e==="Component"}const ZB=(e,t)=>{if(kg(e)){const{children:n,loc:o}=e,{slotName:r,slotProps:s}=JB(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=jn(t.helper(v7),i,o)}};function JB(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"&&Ia(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 XB=/^\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(O_)}(`,i,")"]);else l=i,l.children.unshift(`${n.helperString(O_)}(`),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||XB.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},QB=(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(")"))},ez=(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(Hv(i)){r=!0;for(let l=s+1;l<n.length;l++){const a=n[l];if(Hv(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(Hv(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:jn(t.helper(Ew),l)}}}}},J4=new WeakSet,tz=(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(bg),()=>{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)),lm();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)),lm();const a=!1;if(!i.trim()||!C7(i)&&!a)return n.onError(vn(42,o.loc)),lm();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=>(Bw(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 lm(p)};function lm(e=[]){return{props:e}}const nz=/[\w).+\-_$\]]/,oz=(e,t)=>{Wa("COMPILER_FILTERS",t)&&(e.type===5&&Eg(e.content,t),e.type===1&&e.props.forEach(n=>{n.type===7&&n.name!=="for"&&n.exp&&Eg(n.exp,t)}))};function Eg(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?Eg(e,t):o.type===5&&Eg(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||!nz.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=rz(h,m[p],t);e.content=h}}function rz(e,t,n){n.helper(Ow);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,sz=(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&&Vw(o,t),e.codegenNode=jn(t.helper(Dw),[n.exp,Hc(void 0,o),"_cache",String(t.cached++)]))})}};function iz(e){return[[tz,RB,sz,FB,oz,ZB,WB,jB,ez],{on:z7,bind:QB,model:j7}]}function lz(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=zt({},t,{prefixIdentifiers:r}),i=tt(e)?pB(e,s):e,[l,a]=iz();return vB(i,zt({},s,{nodeTransforms:[...l,...t.nodeTransforms||[]],directiveTransforms:zt({},a,t.directiveTransforms||{})})),wB(i,s)}const az=()=>({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(""),R_=Symbol(""),q7=Symbol(""),G7=Symbol(""),Y7=Symbol(""),Z7=Symbol(""),J7=Symbol("");zF({[H7]:"vModelRadio",[U7]:"vModelCheckbox",[W7]:"vModelText",[K7]:"vModelSelect",[R_]:"vModelDynamic",[q7]:"withModifiers",[G7]:"withKeys",[Y7]:"vShow",[Z7]:"Transition",[J7]:"TransitionGroup"});let Au;function uz(e,t=!1){return Au||(Au=document.createElement("div")),t?(Au.innerHTML=`<div foo="${e.replace(/"/g,""")}">`,Au.children[0].getAttribute("foo")):(Au.innerHTML=e,Au.textContent)}const cz={parseMode:"html",isVoidTag:WR,isNativeTag:e=>jR(e)||HR(e)||UR(e),isPreTag:e=>e==="pre",decodeEntities:uz,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}},dz=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:fz(t.value.content,t.loc),modifiers:[],loc:t.loc})})},fz=(e,t)=>{const n=k$(e);return St(JSON.stringify(n),!1,t,3)};function Pl(e,t){return vn(e,t)}const pz=(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))]}},hz=(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:jn(n.helperString(S0),[o],r):St("",!0))]}},mz=(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=$0(t,"type");if(a){if(a.type===7)i=R_;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 JF(t)&&(i=R_)}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},gz=yr("passive,once,capture"),vz=yr("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),yz=yr("left,right"),X7=yr("onkeyup,onkeydown,onkeypress",!0),_z=(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)||gz(a)?i.push(a):yz(a)?Ho(e)?X7(e.content)?r.push(a):s.push(a):(r.push(a),s.push(a)):vz(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,bz=(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}=_z(s,r,n,e.loc);if(a.includes("right")&&(s=e6(s,"onContextmenu")),a.includes("middle")&&(s=e6(s,"onMouseup")),a.length&&(i=jn(n.helper(q7),[i,JSON.stringify(a)])),l.length&&(!Ho(s)||X7(s.content))&&(i=jn(n.helper(G7),[i,JSON.stringify(l)])),u.length){const c=u.map(Gl).join("");s=Ho(s)?St(`${s.content}${c}`,!0):as(["(",s,`) + "${c}"`])}return{props:[$n(s,i)]}}),wz=(e,t,n)=>{const{exp:o,loc:r}=e;return o||n.onError(Pl(61,r)),{props:[],needRuntime:n.helper(Y7)}},Cz=(e,t)=>{e.type===1&&e.tagType===0&&(e.tag==="script"||e.tag==="style")&&t.removeNode()},kz=[dz],Sz={cloak:az,html:pz,text:hz,model:mz,on:bz,show:wz};function $z(e,t={}){return lz(e,zt({},cz,t,{nodeTransforms:[Cz,...kz,...t.nodeTransforms||[]],directiveTransforms:zt({},Sz,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 Ez(e){let t=t6.get(e??Wt);return t||(t=Object.create(null),t6.set(e??Wt,t)),t}function xz(e,t){if(!tt(e))if(e.nodeType)e=e.innerHTML;else return yt;const n=e,o=Ez(t),r=o[n];if(r)return r;if(e[0]==="#"){const a=document.querySelector(e);e=a?a.innerHTML:""}const s=zt({hoistStatic:!0,onError:void 0,onWarn:yt},t);!s.isCustomElement&&typeof customElements<"u"&&(s.isCustomElement=a=>!!customElements.get(a));const{code:i}=$z(e,s),l=new Function("Vue",i)(LF);return l._rc=!0,o[n]=l}zE(xz);/*! |
| 36 |
* vue-router v4.3.2 |
| 37 |
* (c) 2024 Eduardo San Martin Morote |
| 38 |
* @license MIT |
| 39 |
*/const Wu=typeof document<"u";function Tz(e){return e.__esModule||e[Symbol.toStringTag]==="Module"}const Qt=Object.assign;function Wv(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 Ff=()=>{},ms=Array.isArray,Q7=/#/g,Mz=/&/g,Oz=/\//g,Iz=/=/g,Az=/\?/g,ex=/\+/g,Nz=/%5B/g,Pz=/%5D/g,tx=/%5E/g,Lz=/%60/g,nx=/%7B/g,Rz=/%7C/g,ox=/%7D/g,Dz=/%20/g;function jw(e){return encodeURI(""+e).replace(Rz,"|").replace(Nz,"[").replace(Pz,"]")}function Vz(e){return jw(e).replace(nx,"{").replace(ox,"}").replace(tx,"^")}function D_(e){return jw(e).replace(ex,"%2B").replace(Dz,"+").replace(Q7,"%23").replace(Mz,"%26").replace(Lz,"`").replace(nx,"{").replace(ox,"}").replace(tx,"^")}function Fz(e){return D_(e).replace(Iz,"%3D")}function Bz(e){return jw(e).replace(Q7,"%23").replace(Az,"%3F")}function zz(e){return e==null?"":Bz(e).replace(Oz,"%2F")}function $p(e){try{return decodeURIComponent(""+e)}catch{}return""+e}const jz=/\/$/,Hz=e=>e.replace(jz,"");function Kv(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=qz(o??t,n),{fullPath:o+(s&&"?")+s+i,path:o,query:r,hash:$p(i)}}function Uz(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 Wz(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(!Kz(e[n],t[n]))return!1;return!0}function Kz(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 qz(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 Gz(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),Hz(e)}const Yz=/^[^#]+#/;function Zz(e,t){return e.replace(Yz,"#")+t}function Jz(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 T0=()=>({left:window.scrollX,top:window.scrollY});function Xz(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=Jz(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 V_=new Map;function Qz(e,t){V_.set(e,t)}function ej(e){const t=V_.get(e);return V_.delete(e),t}let tj=()=>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 nj(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:T0()}),"")}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?T0():null}}function oj(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:tj()+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:T0()});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=Gz(e);const t=oj(e),n=nj(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:Zz.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 rj(e){return e=location.host?e||location.pathname+location.search:"",e.includes("#")||(e+="#"),ix(e)}function sj(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="[^/]+?",ij={sensitive:!1,strict:!1,start:!0,end:!0},lj=/[.+*?^${}()[\]/\\]/g;function aj(e,t){const n=Qt({},ij,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(lj,"\\$&"),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 uj(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 cj(e,t){let n=0;const o=e.score,r=t.score;for(;n<o.length&&n<r.length;){const s=uj(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 dj={type:0,value:""},fj=/[a-zA-Z0-9_]/;function pj(e){if(!e)return[[]];if(e==="/")return[[dj]];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:fj.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 hj(e,t,n){const o=aj(pj(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 mj(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=gj(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=hj(_,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)}:Ff}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&&cj(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:yj(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 gj(e){return{path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:void 0,beforeEnter:e.beforeEnter,props:vj(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 vj(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 yj(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 _j(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=Fz(n),o==null){o!==void 0&&(t+=(t.length?"&":"")+n);continue}(ms(o)?o.map(s=>s&&D_(s)):[o&&D_(o)]).forEach(s=>{s!==void 0&&(t+=(t.length?"&":"")+n,s!=null&&(t+="="+s))})}return t}function bj(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 wj=Symbol(""),p6=Symbol(""),Hw=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):sj(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 qv(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(Cj(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=Tz(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 Cj(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function h6(e){const t=ze(Hw),n=ze(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&&Ej(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 $j(a)?t[g(e.replace)?"replace":"push"](g(e.to)).catch(Ff):Promise.resolve()}return{route:o,href:R(()=>o.value.href),isActive:s,isExactActive:i,navigate:l}}const kj=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=Vn(h6(e)),{options:o}=ze(Hw),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)}}}),Sj=kj;function $j(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 Ej(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,xj=Q({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const o=ze(F_),r=R(()=>e.route||o.value),s=ze(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(wj,l),wt(F_,r);const a=q();return Me(()=>[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 Tj=xj;function y6(e){const t=mj(e.routes,e),n=e.parseQuery||_j,o=e.stringifyQuery||f6,r=e.history,s=jd(),i=jd(),l=jd(),a=Mn(Yi);let u=Yi;Wu&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const c=Wv.bind(null,ee=>""+ee),d=Wv.bind(null,zz),f=Wv.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=Kv(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:Kv(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=Uz(o,Qt({},ee,{hash:Vz(Ie),path:le.path})),G=r.createHref(Ge);return Qt({fullPath:Ge,hash:Ie,query:o===f6?bj(ee.query):ee.query||{}},le,{redirectedFrom:void 0,href:G})}function w(ee){return typeof ee=="string"?Kv(n,ee,a.value.path):Qt({},ee)}function _(ee,de){if(u!==ee)return qc(8,{from:de,to:ee})}function S(ee){return M(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 M(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 M(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&&Wz(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):U(ye,ue,le)).then(ye=>{if(ye){if(ui(ye,2))return M(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 V(ue,le,ye),ye})}function A(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]=Mj(ee,de);ve=qv(le.reverse(),"beforeRouteLeave",ee,de);for(const J of le)J.leaveGuards.forEach(ue=>{ve.push(yl(ue,ee,de))});const G=A.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=qv(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=qv(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 V(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){M(Qt(Ie,{replace:!0}),le).catch(Ff);return}u=le;const Ge=a.value;Wu&&Qz(r6(Ge.fullPath,ve.delta),T0()),N(le,Ge).catch(G=>ui(G,12)?G:ui(G,2)?(M(G.to,le).then(J=>{ui(J,20)&&!ve.delta&&ve.type===Ep.pop&&r.go(-1,!1)}).catch(Ff),Promise.reject()):(ve.delta&&r.go(-ve.delta,!1),U(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)),V(le,Ge,G)}).catch(Ff)}))}let W=jd(),H=jd(),F;function U(ee,de,ve){I(ee);const le=H.list();return le.length?le.forEach(Ie=>Ie(ee,de,ve)):console.error(ee),Promise.reject(ee)}function L(){return F&&a.value!==Yi?Promise.resolve():new Promise((ee,de)=>{W.add([ee,de])})}function I(ee){return F||(F=!ee,Z(),W.list().forEach(([de,ve])=>ee?ve(ee):de()),W.reset()),ee}function X(ee,de,ve,le){const{scrollBehavior:Ie}=e;if(!Wu||!Ie)return Promise.resolve();const Ge=!ve&&ej(r6(ee.fullPath,0))||(le||!ve)&&history.state&&history.state.scroll||null;return ot().then(()=>Ie(ee,de,Ge)).then(G=>G&&Xz(G)).catch(G=>U(G,ee,de))}const re=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:re,back:()=>re(-1),forward:()=>re(1),beforeEach:s.add,beforeResolve:i.add,afterEach:l.add,onError:H.add,isReady:L,install(ee){const de=this;ee.component("RouterLink",Sj),ee.component("RouterView",Tj),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(Hw,de),ee.provide(cx,rw(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,F=!1),le()}}};function xe(ee){return ee.reduce((de,ve)=>de.then(()=>P(ve)),Promise.resolve())}return Oe}function Mj(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 Oj='a[href],button:not([disabled]),button:not([hidden]),:not([tabindex="-1"]),input:not([disabled]),input:not([type="hidden"]),select:not([disabled]),textarea:not([disabled])',Ij=e=>getComputedStyle(e).position==="fixed"?!1:e.offsetParent!==null,_6=e=>Array.from(e.querySelectorAll(Oj)).filter(t=>Aj(t)&&Ij(t)),Aj=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}},Pn=(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 Nj=Object.defineProperty,Pj=Object.defineProperties,Lj=Object.getOwnPropertyDescriptors,w6=Object.getOwnPropertySymbols,Rj=Object.prototype.hasOwnProperty,Dj=Object.prototype.propertyIsEnumerable,C6=(e,t,n)=>t in e?Nj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Vj=(e,t)=>{for(var n in t||(t={}))Rj.call(t,n)&&C6(e,n,t[n]);if(w6)for(var n of w6(t))Dj.call(t,n)&&C6(e,n,t[n]);return e},Fj=(e,t)=>Pj(e,Lj(t));function k6(e,t){var n;const o=Mn();return ls(()=>{o.value=e()},Fj(Vj({},t),{flush:(n=t==null?void 0:t.flush)!=null?n:"sync"})),bu(o)}var S6;const xt=typeof window<"u",Bj=e=>typeof e<"u",zj=e=>typeof e=="function",jj=e=>typeof e=="string",Gc=()=>{},Hj=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 Uj(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 Wj(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 Kj(e){return e}function oh(e){return Q2()?(ew(e),!0):!1}function qj(e,t=200,n={}){return dx(Uj(t,n),e)}function Gj(e,t=200,n={}){const o=q(e.value),r=qj(()=>{o.value=e.value},t,n);return Me(e,()=>r()),o}function Yj(e,t=200,n=!1,o=!0,r=!1){return dx(Wj(t,n,o,r),e)}function Zj(e,t=!0){at()?Ct(e):t?e():ot(e)}function B_(e,t,n={}){const{immediate:o=!0}=n,r=q(!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:bu(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,Jj=xt?window.document:void 0;function Rn(...e){let t,n,o,r;if(jj(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=Me(()=>[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;Hj&&!$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=[Rn(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}),Rn(o,"pointerdown",f=>{const p=ki(e);p&&(l=!f.composedPath().includes(p)&&!a(f))},{passive:!0}),i&&Rn(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=q(),o=()=>n.value=!!e();return o(),Zj(o,t),n}function Xj(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 Qj({document:e=Jj}={}){if(!e)return q("visible");const t=q(e.visibilityState);return Rn(e,"visibilitychange",()=>{t.value=e.visibilityState}),t}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 Bo(e,t,n={}){const o=n,{window:r=rh}=o,s=nH(o,["window"]);let i;const l=px(()=>r&&"ResizeObserver"in r),a=()=>{i&&(i.disconnect(),i=void 0)},u=Me(()=>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 M6=Object.getOwnPropertySymbols,oH=Object.prototype.hasOwnProperty,rH=Object.prototype.propertyIsEnumerable,sH=(e,t)=>{var n={};for(var o in e)oH.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&&rH.call(e,o)&&(n[o]=e[o]);return n};function iH(e,t,n={}){const o=n,{window:r=rh}=o,s=sH(o,["window"]);let i;const l=px(()=>r&&"MutationObserver"in r),a=()=>{i&&(i.disconnect(),i=void 0)},u=Me(()=>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 lH=Object.defineProperty,I6=Object.getOwnPropertySymbols,aH=Object.prototype.hasOwnProperty,uH=Object.prototype.propertyIsEnumerable,A6=(e,t,n)=>t in e?lH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cH=(e,t)=>{for(var n in t||(t={}))aH.call(t,n)&&A6(e,n,t[n]);if(I6)for(var n of I6(t))uH.call(t,n)&&A6(e,n,t[n]);return e};const dH={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]};cH({linear:Kj},dH);function fH(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?zj(l)?l(v):Xj(v):v,y=()=>Bj(e[t])?m(e[t]):d;if(a){const v=y(),w=q(v);return Me(()=>e[t],_=>w.value=m(_)),Me(w,_=>{(_!==e[t]||c)&&p(h,_)},{deep:c}),w}else return R({get(){return y()},set(v){p(h,v)}})}function pH({window:e=rh}={}){if(!e)return q(!1);const t=q(e.document.hasFocus());return Rn(e,"blur",()=>{t.value=!1}),Rn(e,"focus",()=>{t.value=!0}),t}const hH=()=>xt&&/firefox/i.test(window.navigator.userAgent),mH=(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},Uw=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 gH=typeof global=="object"&&global&&global.Object===Object&&global;const hx=gH;var vH=typeof self=="object"&&self&&self.Object===Object&&self,yH=hx||vH||Function("return this")();const bs=yH;var _H=bs.Symbol;const Fr=_H;var mx=Object.prototype,bH=mx.hasOwnProperty,wH=mx.toString,Hd=Fr?Fr.toStringTag:void 0;function CH(e){var t=bH.call(e,Hd),n=e[Hd];try{e[Hd]=void 0;var o=!0}catch{}var r=wH.call(e);return o&&(t?e[Hd]=n:delete e[Hd]),r}var kH=Object.prototype,SH=kH.toString;function $H(e){return SH.call(e)}var EH="[object Null]",xH="[object Undefined]",N6=Fr?Fr.toStringTag:void 0;function Cu(e){return e==null?e===void 0?xH:EH:N6&&N6 in Object(e)?CH(e):$H(e)}function Gs(e){return e!=null&&typeof e=="object"}var TH="[object Symbol]";function M0(e){return typeof e=="symbol"||Gs(e)&&Cu(e)==TH}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 MH=Array.isArray;const Mo=MH;var OH=1/0,P6=Fr?Fr.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(M0(e))return L6?L6.call(e):"";var t=e+"";return t=="0"&&1/e==-OH?"-0":t}var IH=/\s/;function AH(e){for(var t=e.length;t--&&IH.test(e.charAt(t)););return t}var NH=/^\s+/;function PH(e){return e&&e.slice(0,AH(e)+1).replace(NH,"")}function Oo(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var R6=0/0,LH=/^[-+]0x[0-9a-f]+$/i,RH=/^0b[01]+$/i,DH=/^0o[0-7]+$/i,VH=parseInt;function z_(e){if(typeof e=="number")return e;if(M0(e))return R6;if(Oo(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Oo(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=PH(e);var n=RH.test(e);return n||DH.test(e)?VH(e.slice(2),n?2:8):LH.test(e)?R6:+e}var D6=1/0,FH=17976931348623157e292;function BH(e){if(!e)return e===0?e:0;if(e=z_(e),e===D6||e===-D6){var t=e<0?-1:1;return t*FH}return e===e?e:0}function zH(e){var t=BH(e),n=t%1;return t===t?n?t-n:t:0}function Ww(e){return e}var jH="[object AsyncFunction]",HH="[object Function]",UH="[object GeneratorFunction]",WH="[object Proxy]";function Kw(e){if(!Oo(e))return!1;var t=Cu(e);return t==HH||t==UH||t==jH||t==WH}var KH=bs["__core-js_shared__"];const Gv=KH;var V6=function(){var e=/[^.]+$/.exec(Gv&&Gv.keys&&Gv.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function qH(e){return!!V6&&V6 in e}var GH=Function.prototype,YH=GH.toString;function ku(e){if(e!=null){try{return YH.call(e)}catch{}try{return e+""}catch{}}return""}var ZH=/[\\^$.*+?()[\]{}|]/g,JH=/^\[object .+?Constructor\]$/,XH=Function.prototype,QH=Object.prototype,eU=XH.toString,tU=QH.hasOwnProperty,nU=RegExp("^"+eU.call(tU).replace(ZH,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function oU(e){if(!Oo(e)||qH(e))return!1;var t=Kw(e)?nU:JH;return t.test(ku(e))}function rU(e,t){return e==null?void 0:e[t]}function Su(e,t){var n=rU(e,t);return oU(n)?n:void 0}var sU=Su(bs,"WeakMap");const j_=sU;var F6=Object.create,iU=function(){function e(){}return function(t){if(!Oo(t))return{};if(F6)return F6(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();const lU=iU;function aU(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 uU=800,cU=16,dU=Date.now;function fU(e){var t=0,n=0;return function(){var o=dU(),r=cU-(o-n);if(n=o,r>0){if(++t>=uU)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function pU(e){return function(){return e}}var hU=function(){try{var e=Su(Object,"defineProperty");return e({},"",{}),e}catch{}}();const xg=hU;var mU=xg?function(e,t){return xg(e,"toString",{configurable:!0,enumerable:!1,value:pU(t),writable:!0})}:Ww;const gU=mU;var vU=fU(gU);const _x=vU;function yU(e,t){for(var n=-1,o=e==null?0:e.length;++n<o&&t(e[n],n,e)!==!1;);return e}function _U(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 bU=9007199254740991,wU=/^(?:0|[1-9]\d*)$/;function O0(e,t){var n=typeof e;return t=t??bU,!!t&&(n=="number"||n!="symbol"&&wU.test(e))&&e>-1&&e%1==0&&e<t}function qw(e,t,n){t=="__proto__"&&xg?xg(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 CU=Object.prototype,kU=CU.hasOwnProperty;function Gw(e,t,n){var o=e[t];(!(kU.call(e,t)&&sh(o,n))||n===void 0&&!(t in e))&&qw(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?qw(n,l,a):Gw(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),aU(e,this,l)}}function SU(e,t){return _x(bx(e,t,Ww),e+"")}var $U=9007199254740991;function Yw(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=$U}function bd(e){return e!=null&&Yw(e.length)&&!Kw(e)}function EU(e,t,n){if(!Oo(n))return!1;var o=typeof t;return(o=="number"?bd(n)&&O0(t,n.length):o=="string"&&t in n)?sh(n[t],e):!1}function xU(e){return SU(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&&EU(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 TU=Object.prototype;function Zw(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||TU;return e===n}function MU(e,t){for(var n=-1,o=Array(e);++n<e;)o[n]=t(n);return o}var OU="[object Arguments]";function z6(e){return Gs(e)&&Cu(e)==OU}var wx=Object.prototype,IU=wx.hasOwnProperty,AU=wx.propertyIsEnumerable,NU=z6(function(){return arguments}())?z6:function(e){return Gs(e)&&IU.call(e,"callee")&&!AU.call(e,"callee")};const xp=NU;function PU(){return!1}var Cx=typeof fr=="object"&&fr&&!fr.nodeType&&fr,j6=Cx&&typeof pr=="object"&&pr&&!pr.nodeType&&pr,LU=j6&&j6.exports===Cx,H6=LU?bs.Buffer:void 0,RU=H6?H6.isBuffer:void 0,DU=RU||PU;const Tp=DU;var VU="[object Arguments]",FU="[object Array]",BU="[object Boolean]",zU="[object Date]",jU="[object Error]",HU="[object Function]",UU="[object Map]",WU="[object Number]",KU="[object Object]",qU="[object RegExp]",GU="[object Set]",YU="[object String]",ZU="[object WeakMap]",JU="[object ArrayBuffer]",XU="[object DataView]",QU="[object Float32Array]",eW="[object Float64Array]",tW="[object Int8Array]",nW="[object Int16Array]",oW="[object Int32Array]",rW="[object Uint8Array]",sW="[object Uint8ClampedArray]",iW="[object Uint16Array]",lW="[object Uint32Array]",cn={};cn[QU]=cn[eW]=cn[tW]=cn[nW]=cn[oW]=cn[rW]=cn[sW]=cn[iW]=cn[lW]=!0;cn[VU]=cn[FU]=cn[JU]=cn[BU]=cn[XU]=cn[zU]=cn[jU]=cn[HU]=cn[UU]=cn[WU]=cn[KU]=cn[qU]=cn[GU]=cn[YU]=cn[ZU]=!1;function aW(e){return Gs(e)&&Yw(e.length)&&!!cn[Cu(e)]}function Jw(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,uW=zf&&zf.exports===kx,Yv=uW&&hx.process,cW=function(){try{var e=zf&&zf.require&&zf.require("util").types;return e||Yv&&Yv.binding&&Yv.binding("util")}catch{}}();const Zc=cW;var U6=Zc&&Zc.isTypedArray,dW=U6?Jw(U6):aW;const Xw=dW;var fW=Object.prototype,pW=fW.hasOwnProperty;function Sx(e,t){var n=Mo(e),o=!n&&xp(e),r=!n&&!o&&Tp(e),s=!n&&!o&&!r&&Xw(e),i=n||o||r||s,l=i?MU(e.length,String):[],a=l.length;for(var u in e)(t||pW.call(e,u))&&!(i&&(u=="length"||r&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||O0(u,a)))&&l.push(u);return l}function $x(e,t){return function(n){return e(t(n))}}var hW=$x(Object.keys,Object);const mW=hW;var gW=Object.prototype,vW=gW.hasOwnProperty;function yW(e){if(!Zw(e))return mW(e);var t=[];for(var n in Object(e))vW.call(e,n)&&n!="constructor"&&t.push(n);return t}function lh(e){return bd(e)?Sx(e):yW(e)}function _W(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var bW=Object.prototype,wW=bW.hasOwnProperty;function CW(e){if(!Oo(e))return _W(e);var t=Zw(e),n=[];for(var o in e)o=="constructor"&&(t||!wW.call(e,o))||n.push(o);return n}function ah(e){return bd(e)?Sx(e,!0):CW(e)}var kW=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,SW=/^\w*$/;function Qw(e,t){if(Mo(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||M0(e)?!0:SW.test(e)||!kW.test(e)||t!=null&&e in Object(t)}var $W=Su(Object,"create");const Mp=$W;function EW(){this.__data__=Mp?Mp(null):{},this.size=0}function xW(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var TW="__lodash_hash_undefined__",MW=Object.prototype,OW=MW.hasOwnProperty;function IW(e){var t=this.__data__;if(Mp){var n=t[e];return n===TW?void 0:n}return OW.call(t,e)?t[e]:void 0}var AW=Object.prototype,NW=AW.hasOwnProperty;function PW(e){var t=this.__data__;return Mp?t[e]!==void 0:NW.call(t,e)}var LW="__lodash_hash_undefined__";function RW(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Mp&&t===void 0?LW:t,this}function lu(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])}}lu.prototype.clear=EW;lu.prototype.delete=xW;lu.prototype.get=IW;lu.prototype.has=PW;lu.prototype.set=RW;function DW(){this.__data__=[],this.size=0}function I0(e,t){for(var n=e.length;n--;)if(sh(e[n][0],t))return n;return-1}var VW=Array.prototype,FW=VW.splice;function BW(e){var t=this.__data__,n=I0(t,e);if(n<0)return!1;var o=t.length-1;return n==o?t.pop():FW.call(t,n,1),--this.size,!0}function zW(e){var t=this.__data__,n=I0(t,e);return n<0?void 0:t[n][1]}function jW(e){return I0(this.__data__,e)>-1}function HW(e,t){var n=this.__data__,o=I0(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}function Fi(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])}}Fi.prototype.clear=DW;Fi.prototype.delete=BW;Fi.prototype.get=zW;Fi.prototype.has=jW;Fi.prototype.set=HW;var UW=Su(bs,"Map");const Op=UW;function WW(){this.size=0,this.__data__={hash:new lu,map:new(Op||Fi),string:new lu}}function KW(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function A0(e,t){var n=e.__data__;return KW(t)?n[typeof t=="string"?"string":"hash"]:n.map}function qW(e){var t=A0(this,e).delete(e);return this.size-=t?1:0,t}function GW(e){return A0(this,e).get(e)}function YW(e){return A0(this,e).has(e)}function ZW(e,t){var n=A0(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=WW;Bi.prototype.delete=qW;Bi.prototype.get=GW;Bi.prototype.has=YW;Bi.prototype.set=ZW;var JW="Expected a function";function e3(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(JW);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(e3.Cache||Bi),n}e3.Cache=Bi;var XW=500;function QW(e){var t=e3(e,function(o){return n.size===XW&&n.clear(),o}),n=t.cache;return t}var eK=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,tK=/\\(\\)?/g,nK=QW(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(eK,function(n,o,r,s){t.push(r?s.replace(tK,"$1"):o||n)}),t});const oK=nK;function rK(e){return e==null?"":vx(e)}function N0(e,t){return Mo(e)?e:Qw(e,t)?[e]:oK(rK(e))}var sK=1/0;function uh(e){if(typeof e=="string"||M0(e))return e;var t=e+"";return t=="0"&&1/e==-sK?"-0":t}function t3(e,t){t=N0(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 Mr(e,t,n){var o=e==null?void 0:t3(e,t);return o===void 0?n:o}function n3(e,t){for(var n=-1,o=t.length,r=e.length;++n<o;)e[r+n]=t[n];return e}var W6=Fr?Fr.isConcatSpreadable:void 0;function iK(e){return Mo(e)||xp(e)||!!(W6&&e&&e[W6])}function o3(e,t,n,o,r){var s=-1,i=e.length;for(n||(n=iK),r||(r=[]);++s<i;){var l=e[s];t>0&&n(l)?t>1?o3(l,t-1,n,o,r):n3(r,l):o||(r[r.length]=l)}return r}function Ex(e){var t=e==null?0:e.length;return t?o3(e,1):[]}function lK(e){return _x(bx(e,void 0,Ex),e+"")}var aK=$x(Object.getPrototypeOf,Object);const r3=aK;var uK="[object Object]",cK=Function.prototype,dK=Object.prototype,xx=cK.toString,fK=dK.hasOwnProperty,pK=xx.call(Object);function hK(e){if(!Gs(e)||Cu(e)!=uK)return!1;var t=r3(e);if(t===null)return!0;var n=fK.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&xx.call(n)==pK}function Tg(){if(!arguments.length)return[];var e=arguments[0];return Mo(e)?e:[e]}function mK(){this.__data__=new Fi,this.size=0}function gK(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function vK(e){return this.__data__.get(e)}function yK(e){return this.__data__.has(e)}var _K=200;function bK(e,t){var n=this.__data__;if(n instanceof Fi){var o=n.__data__;if(!Op||o.length<_K-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 Fi(e);this.size=t.size}us.prototype.clear=mK;us.prototype.delete=gK;us.prototype.get=vK;us.prototype.has=yK;us.prototype.set=bK;function wK(e,t){return e&&ih(t,lh(t),e)}function CK(e,t){return e&&ih(t,ah(t),e)}var Tx=typeof fr=="object"&&fr&&!fr.nodeType&&fr,K6=Tx&&typeof pr=="object"&&pr&&!pr.nodeType&&pr,kK=K6&&K6.exports===Tx,q6=kK?bs.Buffer:void 0,G6=q6?q6.allocUnsafe:void 0;function Mx(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 SK(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 $K=Object.prototype,EK=$K.propertyIsEnumerable,Y6=Object.getOwnPropertySymbols,xK=Y6?function(e){return e==null?[]:(e=Object(e),SK(Y6(e),function(t){return EK.call(e,t)}))}:Ox;const s3=xK;function TK(e,t){return ih(e,s3(e),t)}var MK=Object.getOwnPropertySymbols,OK=MK?function(e){for(var t=[];e;)n3(t,s3(e)),e=r3(e);return t}:Ox;const Ix=OK;function IK(e,t){return ih(e,Ix(e),t)}function Ax(e,t,n){var o=t(e);return Mo(e)?o:n3(o,n(e))}function H_(e){return Ax(e,lh,s3)}function AK(e){return Ax(e,ah,Ix)}var NK=Su(bs,"DataView");const U_=NK;var PK=Su(bs,"Promise");const W_=PK;var LK=Su(bs,"Set");const K_=LK;var Z6="[object Map]",RK="[object Object]",J6="[object Promise]",X6="[object Set]",Q6="[object WeakMap]",e5="[object DataView]",DK=ku(U_),VK=ku(Op),FK=ku(W_),BK=ku(K_),zK=ku(j_),_a=Cu;(U_&&_a(new U_(new ArrayBuffer(1)))!=e5||Op&&_a(new Op)!=Z6||W_&&_a(W_.resolve())!=J6||K_&&_a(new K_)!=X6||j_&&_a(new j_)!=Q6)&&(_a=function(e){var t=Cu(e),n=t==RK?e.constructor:void 0,o=n?ku(n):"";if(o)switch(o){case DK:return e5;case VK:return Z6;case FK:return J6;case BK:return X6;case zK:return Q6}return t});const Ip=_a;var jK=Object.prototype,HK=jK.hasOwnProperty;function UK(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]=="string"&&HK.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var WK=bs.Uint8Array;const Mg=WK;function i3(e){var t=new e.constructor(e.byteLength);return new Mg(t).set(new Mg(e)),t}function KK(e,t){var n=t?i3(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var qK=/\w*$/;function GK(e){var t=new e.constructor(e.source,qK.exec(e));return t.lastIndex=e.lastIndex,t}var t5=Fr?Fr.prototype:void 0,n5=t5?t5.valueOf:void 0;function YK(e){return n5?Object(n5.call(e)):{}}function Nx(e,t){var n=t?i3(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var ZK="[object Boolean]",JK="[object Date]",XK="[object Map]",QK="[object Number]",eq="[object RegExp]",tq="[object Set]",nq="[object String]",oq="[object Symbol]",rq="[object ArrayBuffer]",sq="[object DataView]",iq="[object Float32Array]",lq="[object Float64Array]",aq="[object Int8Array]",uq="[object Int16Array]",cq="[object Int32Array]",dq="[object Uint8Array]",fq="[object Uint8ClampedArray]",pq="[object Uint16Array]",hq="[object Uint32Array]";function mq(e,t,n){var o=e.constructor;switch(t){case rq:return i3(e);case ZK:case JK:return new o(+e);case sq:return KK(e,n);case iq:case lq:case aq:case uq:case cq:case dq:case fq:case pq:case hq:return Nx(e,n);case XK:return new o;case QK:case nq:return new o(e);case eq:return GK(e);case tq:return new o;case oq:return YK(e)}}function Px(e){return typeof e.constructor=="function"&&!Zw(e)?lU(r3(e)):{}}var gq="[object Map]";function vq(e){return Gs(e)&&Ip(e)==gq}var o5=Zc&&Zc.isMap,yq=o5?Jw(o5):vq;const _q=yq;var bq="[object Set]";function wq(e){return Gs(e)&&Ip(e)==bq}var r5=Zc&&Zc.isSet,Cq=r5?Jw(r5):wq;const kq=Cq;var Sq=1,$q=2,Eq=4,Lx="[object Arguments]",xq="[object Array]",Tq="[object Boolean]",Mq="[object Date]",Oq="[object Error]",Rx="[object Function]",Iq="[object GeneratorFunction]",Aq="[object Map]",Nq="[object Number]",Dx="[object Object]",Pq="[object RegExp]",Lq="[object Set]",Rq="[object String]",Dq="[object Symbol]",Vq="[object WeakMap]",Fq="[object ArrayBuffer]",Bq="[object DataView]",zq="[object Float32Array]",jq="[object Float64Array]",Hq="[object Int8Array]",Uq="[object Int16Array]",Wq="[object Int32Array]",Kq="[object Uint8Array]",qq="[object Uint8ClampedArray]",Gq="[object Uint16Array]",Yq="[object Uint32Array]",ln={};ln[Lx]=ln[xq]=ln[Fq]=ln[Bq]=ln[Tq]=ln[Mq]=ln[zq]=ln[jq]=ln[Hq]=ln[Uq]=ln[Wq]=ln[Aq]=ln[Nq]=ln[Dx]=ln[Pq]=ln[Lq]=ln[Rq]=ln[Dq]=ln[Kq]=ln[qq]=ln[Gq]=ln[Yq]=!0;ln[Oq]=ln[Rx]=ln[Vq]=!1;function jf(e,t,n,o,r,s){var i,l=t&Sq,a=t&$q,u=t&Eq;if(n&&(i=r?n(e,o,r,s):n(e)),i!==void 0)return i;if(!Oo(e))return e;var c=Mo(e);if(c){if(i=UK(e),!l)return yx(e,i)}else{var d=Ip(e),f=d==Rx||d==Iq;if(Tp(e))return Mx(e,l);if(d==Dx||d==Lx||f&&!r){if(i=a||f?{}:Px(e),!l)return a?IK(e,CK(i,e)):TK(e,wK(i,e))}else{if(!ln[d])return r?e:{};i=mq(e,d,l)}}s||(s=new us);var p=s.get(e);if(p)return p;s.set(e,i),kq(e)?e.forEach(function(y){i.add(jf(y,t,n,y,e,s))}):_q(e)&&e.forEach(function(y,v){i.set(v,jf(y,t,n,v,e,s))});var h=u?a?AK:H_:a?ah:lh,m=c?void 0:h(e);return yU(m||e,function(y,v){m&&(v=y,y=e[v]),Gw(i,v,jf(y,t,n,v,e,s))}),i}var Zq=4;function s5(e){return jf(e,Zq)}var Jq=1,Xq=4;function i5(e){return jf(e,Jq|Xq)}var Qq="__lodash_hash_undefined__";function eG(e){return this.__data__.set(e,Qq),this}function tG(e){return this.__data__.has(e)}function Og(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new Bi;++t<n;)this.add(e[t])}Og.prototype.add=Og.prototype.push=eG;Og.prototype.has=tG;function nG(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 oG(e,t){return e.has(t)}var rG=1,sG=2;function Vx(e,t,n,o,r,s){var i=n&rG,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&sG?new Og: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(!nG(t,function(v,w){if(!oG(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 iG(e){var t=-1,n=Array(e.size);return e.forEach(function(o,r){n[++t]=[r,o]}),n}function lG(e){var t=-1,n=Array(e.size);return e.forEach(function(o){n[++t]=o}),n}var aG=1,uG=2,cG="[object Boolean]",dG="[object Date]",fG="[object Error]",pG="[object Map]",hG="[object Number]",mG="[object RegExp]",gG="[object Set]",vG="[object String]",yG="[object Symbol]",_G="[object ArrayBuffer]",bG="[object DataView]",l5=Fr?Fr.prototype:void 0,Zv=l5?l5.valueOf:void 0;function wG(e,t,n,o,r,s,i){switch(n){case bG:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case _G:return!(e.byteLength!=t.byteLength||!s(new Mg(e),new Mg(t)));case cG:case dG:case hG:return sh(+e,+t);case fG:return e.name==t.name&&e.message==t.message;case mG:case vG:return e==t+"";case pG:var l=iG;case gG:var a=o&aG;if(l||(l=lG),e.size!=t.size&&!a)return!1;var u=i.get(e);if(u)return u==t;o|=uG,i.set(e,t);var c=Vx(l(e),l(t),o,r,s,i);return i.delete(e),c;case yG:if(Zv)return Zv.call(e)==Zv.call(t)}return!1}var CG=1,kG=Object.prototype,SG=kG.hasOwnProperty;function $G(e,t,n,o,r,s){var i=n&CG,l=H_(e),a=l.length,u=H_(t),c=u.length;if(a!=c&&!i)return!1;for(var d=a;d--;){var f=l[d];if(!(i?f in t:SG.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 EG=1,a5="[object Arguments]",u5="[object Array]",am="[object Object]",xG=Object.prototype,c5=xG.hasOwnProperty;function TG(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?am:a,u=u==a5?am:u;var c=a==am,d=u==am,f=a==u;if(f&&Tp(e)){if(!Tp(t))return!1;i=!0,c=!1}if(f&&!c)return s||(s=new us),i||Xw(e)?Vx(e,t,n,o,r,s):wG(e,t,a,n,o,r,s);if(!(n&EG)){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),$G(e,t,n,o,r,s)):!1}function P0(e,t,n,o,r){return e===t?!0:e==null||t==null||!Gs(e)&&!Gs(t)?e!==e&&t!==t:TG(e,t,n,o,P0,r)}var MG=1,OG=2;function IG(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?P0(c,u,MG|OG,o,d):f))return!1}}return!0}function Fx(e){return e===e&&!Oo(e)}function AG(e){for(var t=lh(e),n=t.length;n--;){var o=t[n],r=e[o];t[n]=[o,r,Fx(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 NG(e){var t=AG(e);return t.length==1&&t[0][2]?Bx(t[0][0],t[0][1]):function(n){return n===e||IG(n,e,t)}}function PG(e,t){return e!=null&&t in Object(e)}function LG(e,t,n){t=N0(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&&Yw(r)&&O0(i,r)&&(Mo(e)||xp(e)))}function zx(e,t){return e!=null&&LG(e,t,PG)}var RG=1,DG=2;function VG(e,t){return Qw(e)&&Fx(t)?Bx(uh(e),t):function(n){var o=Mr(n,e);return o===void 0&&o===t?zx(n,e):P0(t,o,RG|DG)}}function FG(e){return function(t){return t==null?void 0:t[e]}}function BG(e){return function(t){return t3(t,e)}}function zG(e){return Qw(e)?FG(uh(e)):BG(e)}function jx(e){return typeof e=="function"?e:e==null?Ww:typeof e=="object"?Mo(e)?VG(e[0],e[1]):NG(e):zG(e)}function jG(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 HG=jG();const Hx=HG;function UG(e,t){return e&&Hx(e,t,lh)}function WG(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 KG=WG(UG);const qG=KG;var GG=function(){return bs.Date.now()};const Jv=GG;var YG="Expected a function",ZG=Math.max,JG=Math.min;function jl(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(YG);t=z_(t)||0,Oo(n)&&(c=!!n.leading,d="maxWait"in n,s=d?ZG(z_(n.maxWait)||0,t):s,f="trailing"in n?!!n.trailing:f);function p(E){var M=o,A=r;return o=r=void 0,u=E,i=e.apply(A,M),i}function h(E){return u=E,l=setTimeout(v,t),c?p(E):i}function m(E){var M=E-a,A=E-u,P=t-M;return d?JG(P,s-A):P}function y(E){var M=E-a,A=E-u;return a===void 0||M>=t||M<0||d&&A>=s}function v(){var E=Jv();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(Jv())}function x(){var E=Jv(),M=y(E);if(o=arguments,r=this,a=E,M){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 q_(e,t,n){(n!==void 0&&!sh(e[t],n)||n===void 0&&!(t in e))&&qw(e,t,n)}function XG(e){return Gs(e)&&bd(e)}function G_(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function QG(e){return ih(e,ah(e))}function eY(e,t,n,o,r,s,i){var l=G_(e,n),a=G_(t,n),u=i.get(a);if(u){q_(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&&Tp(a),h=!f&&!p&&Xw(a);c=a,f||p||h?Mo(l)?c=l:XG(l)?c=yx(l):p?(d=!1,c=Mx(a,!0)):h?(d=!1,c=Nx(a,!0)):c=[]:hK(a)||xp(a)?(c=l,xp(l)?c=QG(l):(!Oo(l)||Kw(l))&&(c=Px(a))):d=!1}d&&(i.set(a,c),r(c,a,o,s,i),i.delete(a)),q_(e,n,c)}function Ux(e,t,n,o,r){e!==t&&Hx(t,function(s,i){if(r||(r=new us),Oo(s))eY(e,t,i,n,Ux,o,r);else{var l=o?o(G_(e,i),s,i+"",e,t,r):void 0;l===void 0&&(l=s),q_(e,i,l)}},ah)}var tY=Math.max,nY=Math.min;function oY(e,t,n){var o=e==null?0:e.length;if(!o)return-1;var r=o-1;return n!==void 0&&(r=zH(n),r=n<0?tY(o+r,0):nY(r,o-1)),_U(e,jx(t),r,!0)}function rY(e,t){var n=-1,o=bd(e)?Array(e.length):[];return qG(e,function(r,s,i){o[++n]=t(r,s,i)}),o}function sY(e,t){var n=Mo(e)?gx:rY;return n(e,jx(t))}function iY(e,t){return o3(sY(e,t),1)}function Ig(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 Hl(e,t){return P0(e,t)}function To(e){return e==null}function Wx(e){return e===void 0}var lY=xU(function(e,t,n){Ux(e,t,n)});const aY=lY;function Kx(e,t,n,o){if(!Oo(e))return e;t=N0(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=Oo(c)?c:O0(t[r+1])?[]:{})}Gw(l,a,u),l=l[a]}return e}function uY(e,t,n){for(var o=-1,r=t.length,s={};++o<r;){var i=t[o],l=t3(e,i);n(l,i)&&Kx(s,N0(i,e),l)}return s}function cY(e,t){return uY(e,t,function(n,o){return zx(e,o)})}var dY=lK(function(e,t){return e==null?{}:cY(e,t)});const fY=dY;function pY(e,t,n){return e==null?e:Kx(e,t,n)}var hY="Expected a function";function Xv(e,t,n){var o=!0,r=!0;if(typeof e!="function")throw new TypeError(hY);return Oo(n)&&(o="leading"in n?!!n.leading:o,r="trailing"in n?!!n.trailing:r),jl(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||Te(e)&&e.length===0||pt(e)&&!Object.keys(e).length,gs=e=>typeof Element>"u"?!1:e instanceof Element,Ap=e=>To(e),mY=e=>tt(e)?!Number.isNaN(Number(e)):!1,gY=e=>xt?window.requestAnimationFrame(e):setTimeout(e,16),vY=(e="")=>e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d"),Cl=e=>Gl(e),Y_=e=>Object.keys(e),yY=e=>Object.entries(e),Gm=(e,t,n)=>({get value(){return Mr(e,t,n)},set value(o){pY(e,t,o)}});class _Y extends Error{constructor(t){super(t),this.name="ElementPlusError"}}function ws(e,t){throw new _Y(`[${e}] ${t}`)}const Gx=(e="")=>e.split(" ").filter(t=>!!t.trim()),Mi=(e,t)=>{if(!e||!t)return!1;if(t.includes(" "))throw new Error("className should not contain space.");return e.classList.contains(t)},au=(e,t)=>{!e||!t.trim()||e.classList.add(...Gx(t))},Ys=(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)||mY(e))return`${e}${t}`;if(tt(e))return e}const bY=(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))},wY=(e,t)=>{if(!xt)return;let n=e;for(;n;){if([window,document,document.documentElement].includes(n))return window;if(bY(n,t))return n;n=n.parentNode}return n};let um;const CY=e=>{var t;if(!xt)return 0;if(um!==void 0)return um;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),um=o-s,um};function kY(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 SY=Q({name:"ArrowDown",__name:"arrow-down",setup(e){return(t,n)=>(C(),T("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"})]))}}),$u=SY,$Y=Q({name:"ArrowLeft",__name:"arrow-left",setup(e){return(t,n)=>(C(),T("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"})]))}}),uu=$Y,EY=Q({name:"ArrowRight",__name:"arrow-right",setup(e){return(t,n)=>(C(),T("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"})]))}}),Us=EY,xY=Q({name:"ArrowUp",__name:"arrow-up",setup(e){return(t,n)=>(C(),T("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"})]))}}),L0=xY,TY=Q({name:"Avatar",__name:"avatar",setup(e){return(t,n)=>(C(),T("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"})]))}}),MY=TY,OY=Q({name:"Back",__name:"back",setup(e){return(t,n)=>(C(),T("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"})]))}}),IY=OY,AY=Q({name:"Bell",__name:"bell",setup(e){return(t,n)=>(C(),T("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"})]))}}),NY=AY,PY=Q({name:"Bottom",__name:"bottom",setup(e){return(t,n)=>(C(),T("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"})]))}}),LY=PY,RY=Q({name:"Calendar",__name:"calendar",setup(e){return(t,n)=>(C(),T("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"})]))}}),DY=RY,VY=Q({name:"CameraFilled",__name:"camera-filled",setup(e){return(t,n)=>(C(),T("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"})]))}}),FY=VY,BY=Q({name:"CaretBottom",__name:"caret-bottom",setup(e){return(t,n)=>(C(),T("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[b("path",{fill:"currentColor",d:"m192 384 320 384 320-384z"})]))}}),zY=BY,jY=Q({name:"ChatDotRound",__name:"chat-dot-round",setup(e){return(t,n)=>(C(),T("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"})]))}}),HY=jY,UY=Q({name:"ChatDotSquare",__name:"chat-dot-square",setup(e){return(t,n)=>(C(),T("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"})]))}}),WY=UY,KY=Q({name:"Check",__name:"check",setup(e){return(t,n)=>(C(),T("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=KY,qY=Q({name:"CircleCheck",__name:"circle-check",setup(e){return(t,n)=>(C(),T("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"})]))}}),l3=qY,GY=Q({name:"CircleCloseFilled",__name:"circle-close-filled",setup(e){return(t,n)=>(C(),T("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=GY,YY=Q({name:"CircleClose",__name:"circle-close",setup(e){return(t,n)=>(C(),T("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=YY,ZY=Q({name:"Clock",__name:"clock",setup(e){return(t,n)=>(C(),T("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=ZY,JY=Q({name:"CloseBold",__name:"close-bold",setup(e){return(t,n)=>(C(),T("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"})]))}}),XY=JY,QY=Q({name:"Close",__name:"close",setup(e){return(t,n)=>(C(),T("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"})]))}}),Zs=QY,eZ=Q({name:"Comment",__name:"comment",setup(e){return(t,n)=>(C(),T("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"})]))}}),tZ=eZ,nZ=Q({name:"CopyDocument",__name:"copy-document",setup(e){return(t,n)=>(C(),T("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"})]))}}),oZ=nZ,rZ=Q({name:"DArrowLeft",__name:"d-arrow-left",setup(e){return(t,n)=>(C(),T("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=rZ,sZ=Q({name:"DArrowRight",__name:"d-arrow-right",setup(e){return(t,n)=>(C(),T("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=sZ,iZ=Q({name:"DeleteFilled",__name:"delete-filled",setup(e){return(t,n)=>(C(),T("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"})]))}}),lZ=iZ,aZ=Q({name:"Delete",__name:"delete",setup(e){return(t,n)=>(C(),T("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=aZ,uZ=Q({name:"Document",__name:"document",setup(e){return(t,n)=>(C(),T("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"})]))}}),cZ=uZ,dZ=Q({name:"EditPen",__name:"edit-pen",setup(e){return(t,n)=>(C(),T("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"})]))}}),fZ=dZ,pZ=Q({name:"Expand",__name:"expand",setup(e){return(t,n)=>(C(),T("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"})]))}}),hZ=pZ,mZ=Q({name:"FullScreen",__name:"full-screen",setup(e){return(t,n)=>(C(),T("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=mZ,gZ=Q({name:"Guide",__name:"guide",setup(e){return(t,n)=>(C(),T("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"})]))}}),vZ=gZ,yZ=Q({name:"Hide",__name:"hide",setup(e){return(t,n)=>(C(),T("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"})]))}}),eT=yZ,_Z=Q({name:"HomeFilled",__name:"home-filled",setup(e){return(t,n)=>(C(),T("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"})]))}}),bZ=_Z,wZ=Q({name:"InfoFilled",__name:"info-filled",setup(e){return(t,n)=>(C(),T("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"})]))}}),a3=wZ,CZ=Q({name:"Iphone",__name:"iphone",setup(e){return(t,n)=>(C(),T("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"})]))}}),kZ=CZ,SZ=Q({name:"Loading",__name:"loading",setup(e){return(t,n)=>(C(),T("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"})]))}}),u3=SZ,$Z=Q({name:"Lock",__name:"lock",setup(e){return(t,n)=>(C(),T("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"})]))}}),EZ=$Z,xZ=Q({name:"Memo",__name:"memo",setup(e){return(t,n)=>(C(),T("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"})]))}}),TZ=xZ,MZ=Q({name:"Message",__name:"message",setup(e){return(t,n)=>(C(),T("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"})]))}}),OZ=MZ,IZ=Q({name:"Minus",__name:"minus",setup(e){return(t,n)=>(C(),T("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"})]))}}),AZ=IZ,NZ=Q({name:"MoreFilled",__name:"more-filled",setup(e){return(t,n)=>(C(),T("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"})]))}}),Z_=NZ,PZ=Q({name:"More",__name:"more",setup(e){return(t,n)=>(C(),T("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"})]))}}),LZ=PZ,RZ=Q({name:"Notebook",__name:"notebook",setup(e){return(t,n)=>(C(),T("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"})]))}}),DZ=RZ,VZ=Q({name:"Operation",__name:"operation",setup(e){return(t,n)=>(C(),T("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"})]))}}),FZ=VZ,BZ=Q({name:"PictureFilled",__name:"picture-filled",setup(e){return(t,n)=>(C(),T("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"})]))}}),zZ=BZ,jZ=Q({name:"Picture",__name:"picture",setup(e){return(t,n)=>(C(),T("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"})]))}}),HZ=jZ,UZ=Q({name:"Plus",__name:"plus",setup(e){return(t,n)=>(C(),T("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"})]))}}),c3=UZ,WZ=Q({name:"Postcard",__name:"postcard",setup(e){return(t,n)=>(C(),T("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"})]))}}),KZ=WZ,qZ=Q({name:"Reading",__name:"reading",setup(e){return(t,n)=>(C(),T("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"})]))}}),GZ=qZ,YZ=Q({name:"RefreshLeft",__name:"refresh-left",setup(e){return(t,n)=>(C(),T("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"})]))}}),tT=YZ,ZZ=Q({name:"RefreshRight",__name:"refresh-right",setup(e){return(t,n)=>(C(),T("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"})]))}}),JZ=ZZ,XZ=Q({name:"ScaleToOriginal",__name:"scale-to-original",setup(e){return(t,n)=>(C(),T("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"})]))}}),QZ=XZ,eJ=Q({name:"Search",__name:"search",setup(e){return(t,n)=>(C(),T("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"})]))}}),tJ=eJ,nJ=Q({name:"SuccessFilled",__name:"success-filled",setup(e){return(t,n)=>(C(),T("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"})]))}}),d3=nJ,oJ=Q({name:"Tickets",__name:"tickets",setup(e){return(t,n)=>(C(),T("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"})]))}}),rJ=oJ,sJ=Q({name:"Timer",__name:"timer",setup(e){return(t,n)=>(C(),T("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"})]))}}),iJ=sJ,lJ=Q({name:"Top",__name:"top",setup(e){return(t,n)=>(C(),T("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"})]))}}),aJ=lJ,uJ=Q({name:"UploadFilled",__name:"upload-filled",setup(e){return(t,n)=>(C(),T("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"})]))}}),cJ=uJ,dJ=Q({name:"View",__name:"view",setup(e){return(t,n)=>(C(),T("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"})]))}}),nT=dJ,fJ=Q({name:"WarningFilled",__name:"warning-filled",setup(e){return(t,n)=>(C(),T("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"})]))}}),f3=fJ,pJ=Q({name:"ZoomIn",__name:"zoom-in",setup(e){return(t,n)=>(C(),T("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"})]))}}),oT=pJ,hJ=Q({name:"ZoomOut",__name:"zoom-out",setup(e){return(t,n)=>(C(),T("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"})]))}}),mJ=hJ;const rT="__epPropKey",Ce=e=>e,gJ=e=>pt(e)&&!!e[rT],R0=(e,t)=>{if(!pt(e)||gJ(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,[rT]:!0};return vt(e,"default")&&(a.default=r),a},Ke=e=>Ig(Object.entries(e).map(([t,n])=>[t,R0(n,t)])),Io=Ce([String,Object,Function]),sT={Close:Zs},vJ={Close:Zs,SuccessFilled:d3,InfoFilled:a3,WarningFilled:f3,CircleCloseFilled:Zx},Ag={success:d3,warning:f3,error:Zx,info:a3},iT={validating:u3,success:l3,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},yJ=(e,t)=>(e.install=n=>{e._context=n._context,n.config.globalProperties[t]=e},e),_J=(e,t)=>(e.install=n=>{n.directive(t,e)},e),Zn=e=>(e.install=yt,e),p3=(...e)=>t=>{e.forEach(n=>{Qe(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"},bJ=["year","years","month","date","dates","week","datetime","datetimerange","daterange","monthrange"],Jt="update:modelValue",Cd="change",Ym="input",Jl=["","default","small","large"],wJ=e=>["",...Jl].includes(e);var Zm=(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))(Zm||{});const Jm=e=>{const t=Te(e)?e:[e],n=[];return t.forEach(o=>{var r;Te(o)?n.push(...Jm(o)):yo(o)&&Te(o.children)?n.push(...Jm(o.children)):(n.push(o),yo(o)&&((r=o.component)!=null&&r.subTree)&&n.push(...Jm(o.component.subTree)))}),n},ns=e=>!e&&e!==0?[]:Array.isArray(e)?e:[e],lT=e=>/([\uAC00-\uD7AF\u3130-\u318F])+/gi.test(e),Eo=e=>e,CJ=["class","style"],kJ=/^on[A-Z]/,aT=(e={})=>{const{excludeListeners:t=!1,excludeKeys:n}=e,o=R(()=>((n==null?void 0:n.value)||[]).concat(CJ)),r=at();return R(r?()=>{var s;return Ig(Object.entries((s=r.proxy)==null?void 0:s.$attrs).filter(([i])=>!o.value.includes(i)&&!(t&&kJ.test(i))))}:()=>({}))},Ka=({from:e,replacement:t,scope:n,version:o,ref:r,type:s="API"},i)=>{Me(()=>g(i),l=>{},{immediate:!0})},uT=(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,M=_-m-v+f,A=N=>{let V=d+N.clientX-u,B=f+N.clientY-c;o!=null&&o.value||(V=Math.min(Math.max(V,S),E),B=Math.min(Math.max(B,x),M)),r={offsetX:V,offsetY:B},e.value&&(e.value.style.transform=`translate(${Zo(V)}, ${Zo(B)})`)},P=()=>{document.removeEventListener("mousemove",A),document.removeEventListener("mouseup",P)};document.addEventListener("mousemove",A),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 SJ={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 $J=e=>(t,n)=>EJ(t,n,g(e)),EJ=(e,t,n)=>Mr(n,e,e).replace(/\{(\w+)\}/g,(o,r)=>{var s;return`${(s=t==null?void 0:t[r])!=null?s:`{${r}}`}`}),xJ=e=>{const t=R(()=>g(e).name),n=on(e)?e:q(e);return{lang:t,locale:n,t:$J(e)}},cT=Symbol("localeContextKey"),Kt=e=>{const t=e||ze(cT,q());return xJ(R(()=>t.value||SJ))},Hf="el",TJ="is-",fa=(e,t,n,o,r)=>{let s=`${e}-${t}`;return n&&(s+=`-${n}`),o&&(s+=`__${o}`),r&&(s+=`--${r}`),s},dT=Symbol("namespaceContextKey"),h3=e=>{const t=e||(at()?ze(dT,q(Hf)):q(Hf));return R(()=>g(t)||Hf)},Re=(e,t)=>{const n=h3(t);return{namespace:n,b:(m="")=>fa(n.value,e,m,"",""),e:m=>m?fa(n.value,e,"",m,""):"",m:m=>m?fa(n.value,e,"","",m):"",be:(m,y)=>m&&y?fa(n.value,e,m,y,""):"",em:(m,y)=>m&&y?fa(n.value,e,"",m,y):"",bm:(m,y)=>m&&y?fa(n.value,e,m,"",y):"",bem:(m,y,v)=>m&&y&&v?fa(n.value,e,m,y,v):"",is:(m,...y)=>{const v=y.length>=1?y[0]:!0;return m&&v?`${TJ}${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}`}},fT=(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||Mi(document.body,o.value))return;let r=0,s=!1,i="0";const l=()=>{setTimeout(()=>{Ys(document==null?void 0:document.body,o.value),s&&document&&(document.body.style.width=i)},200)};Me(e,a=>{if(!a){l();return}s=!Mi(document.body,o.value),s&&(i=document.body.style.width),r=CY(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)`),au(document.body,o.value)}),ew(()=>l())},MJ=R0({type:Ce(Boolean),default:null}),OJ=R0({type:Ce(Function)}),pT=e=>{const t=`update:${e}`,n=`onUpdate:${e}`,o=[t],r={[e]:MJ,[n]:OJ};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(()=>Qe(h[n])),y=R(()=>h[e]===null),v=M=>{i.value!==!0&&(i.value=!0,l&&(l.value=M),Qe(c)&&c(M))},w=M=>{i.value!==!1&&(i.value=!1,l&&(l.value=M),Qe(d)&&d(M))},_=M=>{if(h.disabled===!0||Qe(u)&&!u())return;const A=m.value&&xt;A&&p(t,!0),(y.value||!A)&&v(M)},S=M=>{if(h.disabled===!0||!xt)return;const A=m.value&&xt;A&&p(t,!1),(y.value||!A)&&w(M)},x=M=>{Br(M)&&(h.disabled&&M?m.value&&p(t,!1):i.value!==M&&(M?v():w()))},E=()=>{i.value?S():_()};return Me(()=>h[e],x),a&&f.appContext.config.globalProperties.$route!==void 0&&Me(()=>({...f.proxy.$route}),()=>{a.value&&i.value&&S()}),Ct(()=>{x(h[e])}),{hide:S,show:_,toggle:E,hasUpdateHandler:m}},useModelToggleProps:r,useModelToggleEmits:o}};pT("modelValue");const hT=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",m3="auto",ch=[Ko,zr,jr,qo],Qc="start",Np="end",IJ="clippingParents",mT="viewport",Ud="popper",AJ="reference",d5=ch.reduce(function(e,t){return e.concat([t+"-"+Qc,t+"-"+Np])},[]),D0=[].concat(ch,[m3]).reduce(function(e,t){return e.concat([t,t+"-"+Qc,t+"-"+Np])},[]),NJ="beforeRead",PJ="read",LJ="afterRead",RJ="beforeMain",DJ="main",VJ="afterMain",FJ="beforeWrite",BJ="write",zJ="afterWrite",jJ=[NJ,PJ,LJ,RJ,DJ,VJ,FJ,BJ,zJ];function Js(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 g3(e){if(typeof ShadowRoot>"u")return!1;var t=Cs(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function HJ(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)||!Js(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 UJ(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)||!Js(r)||(Object.assign(r.style,l),Object.keys(s).forEach(function(a){r.removeAttribute(a)}))})}}var gT={name:"applyStyles",enabled:!0,phase:"write",fn:HJ,effect:UJ,requires:["computeStyles"]};function Ws(e){return e.split("-")[0]}var qa=Math.max,Ng=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 v3(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 vT(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&g3(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 WJ(e){return["table","td","th"].indexOf(Js(e))>=0}function Xl(e){return((ed(e)?e.ownerDocument:e.document)||window.document).documentElement}function V0(e){return Js(e)==="html"?e:e.assignedSlot||e.parentNode||(g3(e)?e.host:null)||Xl(e)}function f5(e){return!Lr(e)||Pi(e).position==="fixed"?null:e.offsetParent}function KJ(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=V0(e);for(g3(r)&&(r=r.host);Lr(r)&&["html","body"].indexOf(Js(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&&WJ(n)&&Pi(n).position==="static";)n=f5(n);return n&&(Js(n)==="html"||Js(n)==="body"&&Pi(n).position==="static")?t:n||KJ(e)||t}function y3(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Uf(e,t,n){return qa(e,Ng(t,n))}function qJ(e,t,n){var o=Uf(e,t,n);return o>n?n:o}function yT(){return{top:0,right:0,bottom:0,left:0}}function _T(e){return Object.assign({},yT(),e)}function bT(e,t){return t.reduce(function(n,o){return n[o]=e,n},{})}var GJ=function(e,t){return e=typeof e=="function"?e(Object.assign({},t.rects,{placement:t.placement})):e,_T(typeof e!="number"?e:bT(e,ch))};function YJ(e){var t,n=e.state,o=e.name,r=e.options,s=n.elements.arrow,i=n.modifiersData.popperOffsets,l=Ws(n.placement),a=y3(l),u=[qo,jr].indexOf(l)>=0,c=u?"height":"width";if(!(!s||!i)){var d=GJ(r.padding,n),f=v3(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+_,M=Uf(S,E,x),A=a;n.modifiersData[o]=(t={},t[A]=M,t.centerOffset=M-E,t)}}function ZJ(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)||!vT(t.elements.popper,r)||(t.elements.arrow=r))}var JJ={name:"arrow",enabled:!0,phase:"main",fn:YJ,effect:ZJ,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function od(e){return e.split("-")[1]}var XJ={top:"auto",right:"auto",bottom:"auto",left:"auto"};function QJ(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),M="clientHeight",A="clientWidth";if(E===Cs(n)&&(E=Xl(n),Pi(E).position!=="static"&&l==="absolute"&&(M="scrollHeight",A="scrollWidth")),E=E,r===Ko||(r===qo||r===jr)&&s===Np){S=zr;var P=d&&E===x&&x.visualViewport?x.visualViewport.height:E[M];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[A];p-=N-o.width,p*=a?1:-1}}var V=Object.assign({position:l},u&&XJ),B=c===!0?QJ({x:p,y:m}):{x:p,y:m};if(p=B.x,m=B.y,a){var Y;return Object.assign({},V,(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({},V,(t={},t[S]=w?m+"px":"",t[_]=v?p+"px":"",t.transform="",t))}function eX(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:Ws(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 wT={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:eX,data:{}},cm={passive:!0};function tX(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,cm)}),l&&a.addEventListener("resize",n.update,cm),function(){s&&u.forEach(function(c){c.removeEventListener("scroll",n.update,cm)}),l&&a.removeEventListener("resize",n.update,cm)}}var CT={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:tX,data:{}},nX={left:"right",right:"left",bottom:"top",top:"bottom"};function Xm(e){return e.replace(/left|right|bottom|top/g,function(t){return nX[t]})}var oX={start:"end",end:"start"};function h5(e){return e.replace(/start|end/g,function(t){return oX[t]})}function _3(e){var t=Cs(e),n=t.pageXOffset,o=t.pageYOffset;return{scrollLeft:n,scrollTop:o}}function b3(e){return nd(Xl(e)).left+_3(e).scrollLeft}function rX(e){var t=Cs(e),n=Xl(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+b3(e),y:l}}function sX(e){var t,n=Xl(e),o=_3(e),r=(t=e.ownerDocument)==null?void 0:t.body,s=qa(n.scrollWidth,n.clientWidth,r?r.scrollWidth:0,r?r.clientWidth:0),i=qa(n.scrollHeight,n.clientHeight,r?r.scrollHeight:0,r?r.clientHeight:0),l=-o.scrollLeft+b3(e),a=-o.scrollTop;return Pi(r||n).direction==="rtl"&&(l+=qa(n.clientWidth,r?r.clientWidth:0)-s),{width:s,height:i,x:l,y:a}}function w3(e){var t=Pi(e),n=t.overflow,o=t.overflowX,r=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+r+o)}function kT(e){return["html","body","#document"].indexOf(Js(e))>=0?e.ownerDocument.body:Lr(e)&&w3(e)?e:kT(V0(e))}function Wf(e,t){var n;t===void 0&&(t=[]);var o=kT(e),r=o===((n=e.ownerDocument)==null?void 0:n.body),s=Cs(o),i=r?[s].concat(s.visualViewport||[],w3(o)?o:[]):o,l=t.concat(i);return r?l:l.concat(Wf(V0(i)))}function J_(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function iX(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===mT?J_(rX(e)):ed(t)?iX(t):J_(sX(Xl(e)))}function lX(e){var t=Wf(V0(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)&&vT(r,o)&&Js(r)!=="body"}):[]}function aX(e,t,n){var o=t==="clippingParents"?lX(e):[].concat(t),r=[].concat(o,[n]),s=r[0],i=r.reduce(function(l,a){var u=m5(e,a);return l.top=qa(u.top,l.top),l.right=Ng(u.right,l.right),l.bottom=Ng(u.bottom,l.bottom),l.left=qa(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 ST(e){var t=e.reference,n=e.element,o=e.placement,r=o?Ws(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?y3(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?IJ:s,l=n.rootBoundary,a=l===void 0?mT: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=_T(typeof h!="number"?h:bT(h,ch)),y=c===Ud?AJ:Ud,v=e.rects.popper,w=e.elements[f?y:c],_=aX(ed(w)?w:w.contextElement||Xl(e.elements.popper),i,a),S=nd(e.elements.reference),x=ST({reference:S,element:v,strategy:"absolute",placement:r}),E=J_(Object.assign({},v,x)),M=c===Ud?E:S,A={top:_.top-M.top+m.top,bottom:M.bottom-_.bottom+m.bottom,left:_.left-M.left+m.left,right:M.right-_.right+m.right},P=e.modifiersData.offset;if(c===Ud&&P){var N=P[r];Object.keys(A).forEach(function(V){var B=[jr,zr].indexOf(V)>=0?1:-1,Y=[Ko,zr].indexOf(V)>=0?"y":"x";A[V]+=N[Y]*B})}return A}function uX(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?D0: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})[Ws(m)],h},{});return Object.keys(p).sort(function(h,m){return p[h]-p[m]})}function cX(e){if(Ws(e)===m3)return[];var t=Xm(e);return[h5(e),t,h5(t)]}function dX(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=Ws(y),w=v===y,_=a||(w||!h?[Xm(y)]:cX(y)),S=[y].concat(_).reduce(function(ge,Oe){return ge.concat(Ws(Oe)===m3?uX(t,{placement:Oe,boundary:c,rootBoundary:d,padding:u,flipVariations:h,allowedAutoPlacements:m}):Oe)},[]),x=t.rects.reference,E=t.rects.popper,M=new Map,A=!0,P=S[0],N=0;N<S.length;N++){var V=S[N],B=Ws(V),Y=od(V)===Qc,Z=[Ko,zr].indexOf(B)>=0,W=Z?"width":"height",H=Pp(t,{placement:V,boundary:c,rootBoundary:d,altBoundary:f,padding:u}),F=Z?Y?jr:qo:Y?zr:Ko;x[W]>E[W]&&(F=Xm(F));var U=Xm(F),L=[];if(s&&L.push(H[B]<=0),l&&L.push(H[F]<=0,H[U]<=0),L.every(function(ge){return ge})){P=V,A=!1;break}M.set(V,L)}if(A)for(var I=h?3:1,X=function(ge){var Oe=S.find(function(xe){var ee=M.get(xe);if(ee)return ee.slice(0,ge).every(function(de){return de})});if(Oe)return P=Oe,"break"},re=I;re>0;re--){var z=X(re);if(z==="break")break}t.placement!==P&&(t.modifiersData[o]._skip=!0,t.placement=P,t.reset=!0)}}var fX={name:"flip",enabled:!0,phase:"main",fn:dX,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 pX(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 hX={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:pX};function mX(e,t,n){var o=Ws(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 gX(e){var t=e.state,n=e.options,o=e.name,r=n.offset,s=r===void 0?[0,0]:r,i=D0.reduce(function(c,d){return c[d]=mX(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 vX={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:gX};function yX(e){var t=e.state,n=e.name;t.modifiersData[n]=ST({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}var $T={name:"popperOffsets",enabled:!0,phase:"read",fn:yX,data:{}};function _X(e){return e==="x"?"y":"x"}function bX(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=Ws(t.placement),w=od(t.placement),_=!w,S=y3(v),x=_X(S),E=t.modifiersData.popperOffsets,M=t.rects.reference,A=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),V=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,W=S==="y"?zr:jr,H=S==="y"?"height":"width",F=E[S],U=F+y[Z],L=F-y[W],I=p?-A[H]/2:0,X=w===Qc?M[H]:A[H],re=w===Qc?-A[H]:-M[H],z=t.elements.arrow,ge=p&&z?v3(z):{width:0,height:0},Oe=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:yT(),xe=Oe[Z],ee=Oe[W],de=Uf(0,M[H],ge[H]),ve=_?M[H]/2-I-de-xe-N.mainAxis:X-de-xe-N.mainAxis,le=_?-M[H]/2+I+de+ee+N.mainAxis:re+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=V==null?void 0:V[S])!=null?Y:0,J=F+ve-G-Ge,ue=F+le-G,_e=Uf(p?Ng(U,J):U,F,p?qa(L,ue):L);E[S]=_e,B[S]=_e-F}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],He=Ee-y[Le],Ze=[Ko,qo].indexOf(v)!==-1,ce=(ye=V==null?void 0:V[x])!=null?ye:0,te=Ze?me:Ee-M[Pe]-A[Pe]-ce+N.altAxis,pe=Ze?Ee+M[Pe]+A[Pe]-ce-N.altAxis:He,Be=p&&Ze?qJ(te,Ee,pe):Uf(p?te:me,Ee,p?pe:He);E[x]=Be,B[x]=Be-Ee}t.modifiersData[o]=B}}var wX={name:"preventOverflow",enabled:!0,phase:"main",fn:bX,requiresIfExists:["offset"]};function CX(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function kX(e){return e===Cs(e)||!Lr(e)?_3(e):CX(e)}function SX(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 $X(e,t,n){n===void 0&&(n=!1);var o=Lr(t),r=Lr(t)&&SX(t),s=Xl(t),i=nd(e,r),l={scrollLeft:0,scrollTop:0},a={x:0,y:0};return(o||!o&&!n)&&((Js(t)!=="body"||w3(s))&&(l=kX(t)),Lr(t)?(a=nd(t,!0),a.x+=t.clientLeft,a.y+=t.clientTop):s&&(a.x=b3(s))),{x:i.left+l.scrollLeft-a.x,y:i.top+l.scrollTop-a.y,width:i.width,height:i.height}}function EX(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 xX(e){var t=EX(e);return jJ.reduce(function(n,o){return n.concat(t.filter(function(r){return r.phase===o}))},[])}function TX(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function MX(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 C3(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=xX(MX([].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:$X(y,dh(v),u.options.strategy==="fixed"),popper:v3(v)},u.reset=!1,u.placement=u.options.placement,u.orderedModifiers.forEach(function(A){return u.modifiersData[A.name]=Object.assign({},A.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,M=_.name;typeof S=="function"&&(u=S({state:u,options:E,name:M,instance:f})||u)}}}},update:TX(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}}C3();var OX=[CT,$T,wT,gT];C3({defaultModifiers:OX});var IX=[CT,$T,wT,gT,vX,fX,wX,JJ,hX],AX=C3({defaultModifiers:IX});const NX=(e,t,n={})=>{const o={name:"updateState",enabled:!0,phase:"write",fn:({state:a})=>{const u=PX(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=Mn(),i=q({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 Me(r,a=>{const u=g(s);u&&u.setOptions(a)},{deep:!0}),Me([e,t],([a,u])=>{l(),!(!a||!u)&&(s.value=AX(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 PX(e){const t=Object.keys(e.elements),n=Ig(t.map(r=>[r,e.styles[r]||{}])),o=Ig(t.map(r=>[r,e.attributes[r]]));return{styles:n,attributes:o}}const k3=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}}},LX=(e,t=0)=>{if(t===0)return e;const n=q(!1);let o=0;const r=()=>{o&&clearTimeout(o),o=window.setTimeout(()=>{n.value=e.value},t)};return Ct(r),Me(()=>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},RX=Symbol("elIdInjection"),ET=()=>at()?ze(RX,w5):w5,Hr=e=>{const t=ET(),n=h3();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))},DX=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 xT=()=>{const e=h3(),t=ET(),n=R(()=>`${e.value}-popper-container-${t.prefix}`),o=R(()=>`#${n.value}`);return{id:n,selector:o}},VX=e=>{const t=document.createElement("div");return t.id=e,document.body.appendChild(t),t},FX=()=>{const{id:e,selector:t}=xT();return yd(()=>{xt&&!k5&&!document.body.querySelector(t.value)&&(k5=VX(e.value))}),{id:e,selector:t}},BX=Ke({showAfter:{type:Number,default:0},hideAfter:{type:Number,default:200},autoClose:{type:Number,default:0}}),zX=({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))}}},TT=Symbol("elForwardRef"),jX=e=>{wt(TT,{setForwardRef:n=>{e.value=n}})},HX=e=>({mounted(t){e(t)},updated(t){e(t)},unmounted(){e(null)}}),S5={current:0},$5=q(0),MT=2e3,E5=Symbol("elZIndexContextKey"),OT=Symbol("zIndexContextKey"),F0=e=>{const t=at()?ze(E5,S5):S5,n=e||(at()?ze(OT,void 0):void 0),o=R(()=>{const i=g(n);return _t(i)?i:MT}),r=R(()=>o.value+$5.value),s=()=>(t.current++,$5.value=t.current,r.value);return!xt&&ze(E5),{initialZIndex:o,currentZIndex:r,nextZIndex:s}},x5=Math.min,Kf=Math.max,Pg=Math.round,Ul=e=>({x:e,y:e}),UX={left:"right",right:"left",bottom:"top",top:"bottom"},WX={start:"end",end:"start"};function S3(e,t){return typeof e=="function"?e(t):e}function rd(e){return e.split("-")[0]}function B0(e){return e.split("-")[1]}function KX(e){return e==="x"?"y":"x"}function IT(e){return e==="y"?"height":"width"}function $3(e){return["top","bottom"].includes(rd(e))?"y":"x"}function AT(e){return KX($3(e))}function qX(e,t,n){n===void 0&&(n=!1);const o=B0(e),r=AT(e),s=IT(r);let i=r==="x"?o===(n?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=Lg(i)),[i,Lg(i)]}function GX(e){const t=Lg(e);return[X_(e),t,X_(t)]}function X_(e){return e.replace(/start|end/g,t=>WX[t])}function YX(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 ZX(e,t,n,o){const r=B0(e);let s=YX(rd(e),n==="start",o);return r&&(s=s.map(i=>i+"-"+r),t&&(s=s.concat(s.map(X_)))),s}function Lg(e){return e.replace(/left|right|bottom|top/g,t=>UX[t])}function JX(e){return{top:0,right:0,bottom:0,left:0,...e}}function XX(e){return typeof e!="number"?JX(e):{top:e,right:e,bottom:e,left:e}}function Rg(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function T5(e,t,n){let{reference:o,floating:r}=e;const s=$3(t),i=AT(t),l=IT(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(B0(t)){case"start":p[i]-=f*(n&&u?-1:1);break;case"end":p[i]+=f*(n&&u?-1:1);break}return p}const QX=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}=T5(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}=T5(u,f,a)),m=-1)}return{x:c,y:d,placement:f,strategy:r,middlewareData:p}};async function eQ(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}=S3(t,e),h=XX(p),y=l[f?d==="floating"?"reference":"floating":d],v=Rg(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=Rg(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 tQ=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}=S3(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?[Lg(l)]:GX(l));!f&&h!=="none"&&S.push(...ZX(l,m,h,_));const x=[l,...S],E=await eQ(t,y),M=[];let A=((o=s.flip)==null?void 0:o.overflows)||[];if(c&&M.push(E[v]),d){const B=qX(r,i,_);M.push(E[B[0]],E[B[1]])}if(A=[...A,{placement:r,overflows:M}],!M.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:A},reset:{placement:Y}};let Z=(N=A.filter(W=>W.overflows[0]<=0).sort((W,H)=>W.overflows[1]-H.overflows[1])[0])==null?void 0:N.placement;if(!Z)switch(p){case"bestFit":{var V;const W=(V=A.map(H=>[H.placement,H.overflows.filter(F=>F>0).reduce((F,U)=>F+U,0)]).sort((H,F)=>H[1]-F[1])[0])==null?void 0:V[0];W&&(Z=W);break}case"initialPlacement":Z=l;break}if(r!==Z)return{reset:{placement:Z}}}return{}}}};async function nQ(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=B0(n),a=$3(n)==="y",u=["left","top"].includes(i)?-1:1,c=s&&a?-1:1,d=S3(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 Q_=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 nQ(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 Wl(e){return NT(e)?(e.nodeName||"").toLowerCase():"#document"}function mr(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ql(e){var t;return(t=(NT(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function NT(e){return e instanceof Node||e instanceof mr(e).Node}function Li(e){return e instanceof Element||e instanceof mr(e).Element}function Xs(e){return e instanceof HTMLElement||e instanceof mr(e).HTMLElement}function M5(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 oQ(e){return["table","td","th"].includes(Wl(e))}function E3(e){const t=x3(),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 rQ(e){let t=sd(e);for(;Xs(t)&&!z0(t);){if(E3(t))return t;t=sd(t)}return null}function x3(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function z0(e){return["html","body","#document"].includes(Wl(e))}function Ur(e){return mr(e).getComputedStyle(e)}function j0(e){return Li(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function sd(e){if(Wl(e)==="html")return e;const t=e.assignedSlot||e.parentNode||M5(e)&&e.host||Ql(e);return M5(t)?t.host:t}function PT(e){const t=sd(e);return z0(t)?e.ownerDocument?e.ownerDocument.body:e.body:Xs(t)&&fh(t)?t:PT(t)}function eb(e,t,n){var o;t===void 0&&(t=[]),n===void 0&&(n=!0);const r=PT(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?eb(i.frameElement):[]):t.concat(r,eb(r,[],n))}function LT(e){const t=Ur(e);let n=parseFloat(t.width)||0,o=parseFloat(t.height)||0;const r=Xs(e),s=r?e.offsetWidth:n,i=r?e.offsetHeight:o,l=Pg(n)!==s||Pg(o)!==i;return l&&(n=s,o=i),{width:n,height:o,$:l}}function RT(e){return Li(e)?e:e.contextElement}function Sc(e){const t=RT(e);if(!Xs(t))return Ul(1);const n=t.getBoundingClientRect(),{width:o,height:r,$:s}=LT(t);let i=(s?Pg(n.width):n.width)/o,l=(s?Pg(n.height):n.height)/r;return(!i||!Number.isFinite(i))&&(i=1),(!l||!Number.isFinite(l))&&(l=1),{x:i,y:l}}const sQ=Ul(0);function DT(e){const t=mr(e);return!x3()||!t.visualViewport?sQ:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function iQ(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=RT(e);let i=Ul(1);t&&(o?Li(o)&&(i=Sc(o)):i=Sc(e));const l=iQ(s,n,o)?DT(s):Ul(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 Rg({width:c,height:d,x:a,y:u})}const lQ=[":popover-open",":modal"];function VT(e){return lQ.some(t=>{try{return e.matches(t)}catch{return!1}})}function aQ(e){let{elements:t,rect:n,offsetParent:o,strategy:r}=e;const s=r==="fixed",i=Ql(o),l=t?VT(t.floating):!1;if(o===i||l&&s)return n;let a={scrollLeft:0,scrollTop:0},u=Ul(1);const c=Ul(0),d=Xs(o);if((d||!d&&!s)&&((Wl(o)!=="body"||fh(i))&&(a=j0(o)),Xs(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 uQ(e){return Array.from(e.getClientRects())}function FT(e){return Lp(Ql(e)).left+j0(e).scrollLeft}function cQ(e){const t=Ql(e),n=j0(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+FT(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 dQ(e,t){const n=mr(e),o=Ql(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=x3();(!u||u&&t==="fixed")&&(l=r.offsetLeft,a=r.offsetTop)}return{width:s,height:i,x:l,y:a}}function fQ(e,t){const n=Lp(e,!0,t==="fixed"),o=n.top+e.clientTop,r=n.left+e.clientLeft,s=Xs(e)?Sc(e):Ul(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=dQ(e,n);else if(t==="document")o=cQ(Ql(e));else if(Li(t))o=fQ(t,n);else{const r=DT(e);o={...t,x:t.x-r.x,y:t.y-r.y}}return Rg(o)}function BT(e,t){const n=sd(e);return n===t||!Li(n)||z0(n)?!1:Ur(n).position==="fixed"||BT(n,t)}function pQ(e,t){const n=t.get(e);if(n)return n;let o=eb(e,[],!1).filter(l=>Li(l)&&Wl(l)!=="body"),r=null;const s=Ur(e).position==="fixed";let i=s?sd(e):e;for(;Li(i)&&!z0(i);){const l=Ur(i),a=E3(i);!a&&l.position==="fixed"&&(r=null),(s?!a&&!r:!a&&l.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||fh(i)&&!a&&BT(e,i))?o=o.filter(c=>c!==i):r=l,i=sd(i)}return t.set(e,o),o}function hQ(e){let{element:t,boundary:n,rootBoundary:o,strategy:r}=e;const i=[...n==="clippingAncestors"?pQ(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 mQ(e){const{width:t,height:n}=LT(e);return{width:t,height:n}}function gQ(e,t,n){const o=Xs(t),r=Ql(t),s=n==="fixed",i=Lp(e,!0,s,t);let l={scrollLeft:0,scrollTop:0};const a=Ul(0);if(o||!o&&!s)if((Wl(t)!=="body"||fh(r))&&(l=j0(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=FT(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!Xs(e)||Ur(e).position==="fixed"?null:t?t(e):e.offsetParent}function zT(e,t){const n=mr(e);if(!Xs(e)||VT(e))return n;let o=I5(e,t);for(;o&&oQ(o)&&Ur(o).position==="static";)o=I5(o,t);return o&&(Wl(o)==="html"||Wl(o)==="body"&&Ur(o).position==="static"&&!E3(o))?n:o||rQ(e)||n}const vQ=async function(e){const t=this.getOffsetParent||zT,n=this.getDimensions;return{reference:gQ(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,...await n(e.floating)}}};function yQ(e){return Ur(e).direction==="rtl"}const _Q={convertOffsetParentRelativeRectToViewportRelativeRect:aQ,getDocumentElement:Ql,getClippingRect:hQ,getOffsetParent:zT,getElementRects:vQ,getClientRects:uQ,getDimensions:mQ,getScale:Sc,isElement:Li,isRTL:yQ},tb=tQ,nb=(e,t,n)=>{const o=new Map,r={platform:_Q,...n},s={...r.platform,_c:o};return QX(e,t,{...r,platform:s})};function bQ(e){const t=q();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 wQ=(e,t,n)=>Jm(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),CQ=(e,t)=>{const n={},o=Mn([]);return{children:o,addChild:i=>{n[i.uid]=i,o.value=wQ(e,t,n)},removeChild:i=>{delete n[i],o.value=o.value.filter(l=>l.uid!==i)}}},qr=R0({type:String,values:Jl,required:!1}),jT=Symbol("size"),kQ=()=>{const e=ze(jT,{});return R(()=>g(e.size)||"")};function T3(e,{afterFocus:t,beforeBlur:n,afterBlur:o}={}){const r=at(),{emit:s}=r,i=Mn(),l=q(!1),a=d=>{l.value||(l.value=!0,s("focus",d),t==null||t())},u=d=>{var f;Qe(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 Me(i,d=>{d&&d.setAttribute("tabindex","-1")}),Rn(i,"click",c),{wrapperRef:i,isFocused:l,handleFocus:a,handleBlur:u}}const SQ=["",void 0,null],$Q=void 0,M3=Ke({emptyValues:Array,valueOnClear:{type:[String,Number,Boolean,Function],default:void 0,validator:e=>Qe(e)?!e():!e}}),HT=(e,t)=>{const n=ph();n.value=n.value||{};const o=R(()=>e.emptyValues||n.value.emptyValues||SQ),r=R(()=>Qe(e.valueOnClear)?e.valueOnClear():e.valueOnClear!==void 0?e.valueOnClear:Qe(n.value.valueOnClear)?n.value.valueOnClear():n.value.valueOnClear!==void 0?n.value.valueOnClear:t!==void 0?t:$Q),s=i=>o.value.includes(i);return o.value.includes(r.value),{emptyValues:o,valueOnClear:r,isEmptyValue:s}},UT=Symbol(),Dg=q();function ph(e,t=void 0){const n=at()?ze(UT,Dg):Dg;return e?R(()=>{var o,r;return(r=(o=n.value)==null?void 0:o[e])!=null?r:t}):n}function O3(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=F0(R(()=>{var l;return((l=n.value)==null?void 0:l.zIndex)||MT})),i=R(()=>{var l;return g(t)||((l=n.value)==null?void 0:l.size)||""});return EQ(R(()=>g(n)||{})),{ns:o,locale:r,zIndex:s,size:i}}const EQ=(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?xQ(s.value,a):a});return i(UT,l),i(cT,R(()=>l.value.locale)),i(dT,R(()=>l.value.namespace)),i(OT,R(()=>l.value.zIndex)),i(jT,{size:R(()=>l.value.size||"")}),(n||!Dg.value)&&(Dg.value=l.value),l},xQ=(e,t)=>{const n=[...new Set([...Y_(e),...Y_(t)])],o={};for(const r of n)o[r]=t[r]!==void 0?t[r]:e[r];return o};var je=(e,t)=>{const n=e.__vccOpts||e;for(const[o,r]of t)n[o]=r;return n};const TQ=Ke({size:{type:Ce([Number,String])},color:{type:String}}),MQ=Q({name:"ElIcon",inheritAttrs:!1}),OQ=Q({...MQ,props:TQ,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(),T("i",un({class:g(n).b(),style:g(o)},r.$attrs),[he(r.$slots,"default")],16))}});var IQ=je(OQ,[["__file","icon.vue"]]);const Ne=Zt(IQ),kd=Symbol("formContextKey"),cu=Symbol("formItemContextKey"),Jo=(e,t={})=>{const n=q(void 0),o=t.prop?n:hT("size"),r=t.global?n:kQ(),s=t.form?{size:void 0}:ze(kd,void 0),i=t.formItem?{size:void 0}:ze(cu,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=hT("disabled"),n=ze(kd,void 0);return R(()=>t.value||g(e)||(n==null?void 0:n.disabled)||!1)},ri=()=>{const e=ze(kd,void 0),t=ze(cu,void 0);return{form:e,formItem:t}},Sd=(e,{formItemContext:t,disableIdGeneration:n,disableIdManagement:o})=>{n||(n=q(!1)),o||(o=q(!1));const r=q();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=Me([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})}),oi(()=>{s&&s(),t!=null&&t.removeInputId&&r.value&&t.removeInputId(r.value)}),{isLabeledByFormItem:i,inputId:r}},AQ=Ke({size:{type:String,values:Jl},disabled:Boolean}),NQ=Ke({...AQ,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]}}),PQ={validate:(e,t,n)=>(Te(e)||tt(e))&&Br(t)&&tt(n)};function LQ(){const e=q([]),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 dm=(e,t)=>{const n=Tg(t);return n.length>0?e.filter(o=>o.prop&&n.includes(o.prop)):e},RQ="ElForm",DQ=Q({name:RQ}),VQ=Q({...DQ,props:NQ,emits:PQ,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&&dm(r,_).forEach(S=>S.resetField())},f=(_=[])=>{dm(r,_).forEach(S=>S.clearValidate())},p=R(()=>!!o.model),h=_=>{if(r.length===0)return[];const S=dm(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(M){x={...x,...M}}return Object.keys(x).length===0?!0:Promise.reject(x)},v=async(_=[],S)=>{const x=!Qe(S);try{const E=await y(_);return E===!0&&(S==null||S(E)),E}catch(E){if(E instanceof Error)throw E;const M=E;return o.scrollToError&&w(Object.keys(M)[0]),S==null||S(!1,M),x&&Promise.reject(M)}},w=_=>{var S;const x=dm(r,_)[0];x&&((S=x.$el)==null||S.scrollIntoView(o.scrollIntoViewOptions))};return Me(()=>o.rules,()=>{o.validateOnRuleChange&&m().catch(_=>void 0)},{deep:!0}),wt(kd,Vn({...ni(o),emit:n,resetFields:d,clearValidate:f,validateField:v,getField:a,addField:u,removeField:c,...LQ()})),t({validate:m,validateField:v,resetFields:d,clearValidate:f,scrollToField:w}),(_,S)=>(C(),T("form",{class:D(g(l))},[he(_.$slots,"default")],2))}});var FQ=je(VQ,[["__file","form.vue"]]);function Na(){return Na=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},Na.apply(this,arguments)}function BQ(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Rp(e,t)}function ob(e){return ob=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},ob(e)}function Rp(e,t){return Rp=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(o,r){return o.__proto__=r,o},Rp(e,t)}function zQ(){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 Qm(e,t,n){return zQ()?Qm=Reflect.construct.bind():Qm=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},Qm.apply(null,arguments)}function jQ(e){return Function.toString.call(e).indexOf("[native code]")!==-1}function rb(e){var t=typeof Map=="function"?new Map:void 0;return rb=function(o){if(o===null||!jQ(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 Qm(o,arguments,ob(this).constructor)}return r.prototype=Object.create(o.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),Rp(r,o)},rb(e)}var HQ=/%[sdj%]/g,UQ=function(){};typeof process<"u"&&process.env;function sb(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(HQ,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 WQ(e){return e==="string"||e==="url"||e==="hex"||e==="email"||e==="date"||e==="pattern"}function Wn(e,t){return!!(e==null||t==="array"&&Array.isArray(e)&&!e.length||WQ(t)&&typeof e=="string"&&!e)}function KQ(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 qQ(e){var t=[];return Object.keys(e).forEach(function(n){t.push.apply(t,e[n]||[])}),t}var N5=function(e){BQ(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}(rb(Error));function GQ(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,sb(v))):f(r)},m=qQ(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,sb(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):KQ(y,n,h)})});return d.catch(function(f){return f}),d}function YQ(e){return!!(e&&e.message!==void 0)}function ZQ(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=ZQ(t,e.fullFields):o=t[n.field||e.fullField],YQ(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]=Na({},e[n],o):e[n]=o}}return e}var WT=function(t,n,o,r,s,i){t.required&&(!o.hasOwnProperty(t.field)||Wn(n,i||t.type))&&r.push(dr(s.messages.required,t.fullField))},JQ=function(t,n,o,r,s){(/^\s+$/.test(n)||n==="")&&r.push(dr(s.messages.whitespace,t.fullField))},fm,XQ=function(){if(fm)return fm;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 fm=new RegExp("(?:^"+w+"$)","i"),fm},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(XQ())},hex:function(t){return typeof t=="string"&&!!t.match(R5.hex)}},QQ=function(t,n,o,r,s){if(t.required&&n===void 0){WT(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))},eee=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",tee=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(", ")))},nee=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:WT,whitespace:JQ,type:QQ,range:eee,enum:tee,pattern:nee},oee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(Wn(n,"string")&&!t.required)return o();Rt.required(t,n,r,i,s,"string"),Wn(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)},ree=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(Wn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&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(n===""&&(n=void 0),Wn(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(Wn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&Rt.type(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(Wn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),Wn(n)||Rt.type(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(Wn(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)},uee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(Wn(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)},cee=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)},dee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(Wn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&Rt.type(t,n,r,i,s)}o(i)},fee="enum",pee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(Wn(n)&&!t.required)return o();Rt.required(t,n,r,i,s),n!==void 0&&Rt[fee](t,n,r,i,s)}o(i)},hee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(Wn(n,"string")&&!t.required)return o();Rt.required(t,n,r,i,s),Wn(n,"string")||Rt.pattern(t,n,r,i,s)}o(i)},mee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(Wn(n,"date")&&!t.required)return o();if(Rt.required(t,n,r,i,s),!Wn(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)},gee=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)},Qv=function(t,n,o,r,s){var i=t.type,l=[],a=t.required||!t.required&&r.hasOwnProperty(t.field);if(a){if(Wn(n,i)&&!t.required)return o();Rt.required(t,n,r,l,s,i),Wn(n,i)||Rt.type(t,n,r,l,s)}o(l)},vee=function(t,n,o,r,s){var i=[],l=t.required||!t.required&&r.hasOwnProperty(t.field);if(l){if(Wn(n)&&!t.required)return o();Rt.required(t,n,r,i,s)}o(i)},qf={string:oee,method:ree,number:see,boolean:iee,regexp:lee,integer:aee,float:uee,array:cee,object:dee,enum:pee,pattern:hee,date:mee,url:Qv,hex:Qv,email:Qv,required:gee,any:vee};function ib(){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 lb=ib(),hh=function(){function e(n){this.rules=null,this._messages=lb,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(ib(),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=sb(y),u(y,v)):u(null,l)}if(a.messages){var d=this.messages();d===lb&&(d=ib()),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=Na({},l)),v=l[m]=_.transform(v)),typeof _=="function"?_={validator:_}:_=Na({},_),_.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 GQ(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,M){return Na({},M,{fullField:v.fullField+"."+E,fullFields:v.fullFields?[].concat(v.fullFields,[E]):[E]})}function S(E){E===void 0&&(E=[]);var M=Array.isArray(E)?E:[E];!a.suppressWarning&&M.length&&e.warning("async-validator:",M),M.length&&v.message!==void 0&&(M=[].concat(v.message));var A=M.map(P5(v,l));if(a.first&&A.length)return h[v.field]=1,y(A);if(!w)y(A);else{if(v.required&&!m.value)return v.message!==void 0?A=[].concat(v.message).map(P5(v,l)):a.error&&(A=[a.error(v,dr(a.messages.required,v.field))]),y(A);var P={};v.defaultField&&Object.keys(m.value).map(function(B){P[B]=v.defaultField}),P=Na({},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 V=new e(N);V.messages(a.messages),m.rule.options&&(m.rule.options.messages=a.messages,m.rule.options.error=a.error),V.validate(m.value,m.rule.options||a,function(B){var Y=[];A&&A.length&&Y.push.apply(Y,A),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=UQ;hh.messages=lb;hh.validators=qf;const yee=["","error","validating","success"],_ee=Ke({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:yee},for:String,inlineMessage:{type:[String,Boolean],default:""},showMessage:{type:Boolean,default:!0},size:{type:String,values:Jl}}),D5="ElLabelWrap";var bee=Q({name:D5,props:{isAutoWidth:Boolean,updateAll:Boolean},setup(e,{slots:t}){const n=ze(kd,void 0),o=ze(cu);o||ws(D5,"usage: <el-form-item><label-wrap /></el-form-item>");const r=Re("form"),s=q(),i=q(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")}),Vi(()=>u()),Me(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 wee=["role","aria-labelledby"],Cee=Q({name:"ElFormItem"}),kee=Q({...Cee,props:_ee,setup(e,{expose:t}){const n=e,o=Kr(),r=ze(kd,void 0),s=ze(cu,void 0),i=Jo(void 0,{formItem:!1}),l=Re("form-item"),a=Hr().value,u=q([]),c=q(""),d=Gj(c,100),f=q(""),p=q();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)),M=R(()=>n.for||(u.value.length===1?u.value[0]:void 0)),A=R(()=>!M.value&&E.value),P=!!s,N=R(()=>{const ee=r==null?void 0:r.model;if(!(!ee||!n.prop))return Gm(ee,n.prop).value}),V=R(()=>{const{required:ee}=n,de=[];n.rules&&de.push(...Tg(n.rules));const ve=r==null?void 0:r.rules;if(ve&&n.prop){const le=Gm(ve,n.prop).value;le&&de.push(...Tg(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(()=>V.value.length>0),Y=ee=>V.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(()=>V.value.some(ee=>ee.required)),W=R(()=>{var ee;return d.value==="error"&&n.showMessage&&((ee=r==null?void 0:r.showMessage)!=null?ee:!0)}),H=R(()=>`${n.label||""}${(r==null?void 0:r.labelSuffix)||""}`),F=ee=>{c.value=ee},U=ee=>{var de,ve;const{errors:le,fields:Ie}=ee;(!le||!Ie)&&console.error(ee),F("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=()=>{F("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=>(U(le),Promise.reject(le)))},X=async(ee,de)=>{if(m||!n.prop)return!1;const ve=Qe(de);if(!B.value)return de==null||de(!1),!1;const le=Y(ee);return le.length===0?(de==null||de(!0),!0):(F("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)}))},re=()=>{F(""),f.value="",m=!1},z=async()=>{const ee=r==null?void 0:r.model;if(!ee||!n.prop)return;const de=Gm(ee,n.prop);m=!0,de.value=s5(h),await ot(),re(),m=!1},ge=ee=>{u.value.includes(ee)||u.value.push(ee)},Oe=ee=>{u.value=u.value.filter(de=>de!==ee)};Me(()=>n.error,ee=>{f.value=ee||"",F(ee?"error":"")},{immediate:!0}),Me(()=>n.validateStatus,ee=>F(ee||""));const xe=Vn({...ni(n),$el:p,size:i,validateState:c,labelId:a,inputIds:u,isGroup:A,hasLabel:E,fieldValue:N,addInputId:ge,removeInputId:Oe,resetField:z,clearValidate:re,validate:X});return wt(cu,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:re,resetField:z}),(ee,de)=>{var ve;return C(),T("div",{ref_key:"formItemRef",ref:p,class:D(g(w)),role:g(A)?"group":void 0,"aria-labelledby":g(A)?g(a):void 0},[k(g(bee),{"is-auto-width":g(y).width==="auto","update-all":((ve=g(r))==null?void 0:ve.labelWidth)==="auto"},{default:$(()=>[g(E)?(C(),K(Lt(g(M)?"label":"div"),{key:0,id:g(a),for:g(M),class:D(g(l).e("label")),style:et(g(y))},{default:$(()=>[he(ee.$slots,"label",{label:g(H)},()=>[ne(O(g(H)),1)])]),_:3},8,["id","for","class","style"])):j("v-if",!0)]),_:3},8,["is-auto-width","update-all"]),b("div",{class:D(g(l).e("content")),style:et(g(v))},[he(ee.$slots,"default"),k(k0,{name:`${g(l).namespace.value}-zoom-in-top`},{default:$(()=>[g(W)?he(ee.$slots,"error",{key:0,error:f.value},()=>[b("div",{class:D(g(S))},O(f.value),3)]):j("v-if",!0)]),_:3},8,["name"])],6)],10,wee)}}});var KT=je(kee,[["__file","form-item.vue"]]);const Fn=Zt(FQ,{FormItem:KT}),Bn=Zn(KT);let Jr;const See=` |
| 51 |
height:0 !important; |
| 52 |
visibility:hidden !important; |
| 53 |
${hH()?"":"overflow:hidden !important;"} |
| 54 |
position:absolute !important; |
| 55 |
z-index:-1000 !important; |
| 56 |
top:0 !important; |
| 57 |
right:0 !important; |
| 58 |
`,$ee=["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 Eee(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:$ee.map(i=>`${i}:${t.getPropertyValue(i)}`).join(";"),paddingSize:o,borderSize:r,boxSizing:n}}function V5(e,t=1,n){var o;Jr||(Jr=document.createElement("textarea"),document.body.appendChild(Jr));const{paddingSize:r,borderSize:s,boxSizing:i,contextStyle:l}=Eee(e);Jr.setAttribute("style",`${l};${See}`),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 xee=Ke({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:Io},prefixIcon:{type:Io},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:()=>Eo({})},autofocus:{type:Boolean,default:!1}}),Tee={[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},Mee=["role"],Oee=["id","minlength","maxlength","type","disabled","readonly","autocomplete","tabindex","aria-label","placeholder","form","autofocus"],Iee=["id","minlength","maxlength","tabindex","disabled","readonly","autocomplete","aria-label","placeholder","form","autofocus"],Aee=Q({name:"ElInput",inheritAttrs:!1}),Nee=Q({...Aee,props:xee,emits:Tee,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=aT({excludeKeys:R(()=>Object.keys(i.value))}),{form:c,formItem:d}=ri(),{inputId:f}=Sd(o,{formItemContext:d}),p=Jo(),h=Gr(),m=Re("input"),y=Re("textarea"),v=Mn(),w=Mn(),_=q(!1),S=q(!1),x=q(!1),E=q(),M=Mn(o.inputStyle),A=R(()=>v.value||w.value),{wrapperRef:P,isFocused:N,handleFocus:V,handleBlur:B}=T3(A,{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)||""),W=R(()=>Z.value&&iT[Z.value]),H=R(()=>x.value?nT:eT),F=R(()=>[r.style]),U=R(()=>[o.inputStyle,M.value,{resize:o.resize}]),L=R(()=>To(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)),re=R(()=>o.showWordLimit&&!!o.maxlength&&(o.type==="text"||o.type==="textarea")&&!h.value&&!o.readonly&&!o.showPassword),z=R(()=>L.value.length),ge=R(()=>!!re.value&&z.value>Number(o.maxlength)),Oe=R(()=>!!s.suffix||!!o.suffixIcon||I.value||o.showPassword||re.value||!!Z.value&&Y.value),[xe,ee]=bQ(v);Bo(w,ce=>{if(le(),!re.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=pt(te)?te.minRows:void 0,Be=pt(te)?te.maxRows:void 0,Xe=V5(w.value,pe,Be);M.value={overflowY:"hidden",...Xe},ot(()=>{w.value.offsetHeight,M.value=Xe})}else M.value={minHeight:V5(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=A.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,Be=pe[pe.length-1]||"";S.value=!lT(Be)},_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=A.value)==null||ce.focus()},Le=()=>{var ce;return(ce=A.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)},He=()=>{var ce;(ce=A.value)==null||ce.select()},Ze=()=>{n(Jt,""),n("change",""),n("clear"),n("input","")};return Me(()=>o.modelValue,()=>{var ce;ot(()=>de()),o.validateEvent&&((ce=d==null?void 0:d.validate)==null||ce.call(d,"change").catch(te=>void 0))}),Me(L,()=>Ie()),Me(()=>o.type,async()=>{await ot(),Ie(),de()}),Ct(()=>{!o.formatter&&o.parser,Ie(),ot(de)}),t({input:v,textarea:w,ref:A,textareaStyle:U,autosize:pn(o,"autosize"),focus:Ae,blur:Le,select:He,clear:Ze,resizeTextarea:de}),(ce,te)=>(C(),T("div",un(g(i),{class:g(l),style:g(F),role:ce.containerRole,onMouseenter:Pe,onMouseleave:Ee}),[j(" input "),ce.type!=="textarea"?(C(),T(fe,{key:0},[j(" prepend slot "),ce.$slots.prepend?(C(),T("div",{key:0,class:D(g(m).be("group","prepend"))},[he(ce.$slots,"prepend")],2)):j("v-if",!0),b("div",{ref_key:"wrapperRef",ref:P,class:D(g(a))},[j(" prefix slot "),ce.$slots.prefix||ce.prefixIcon?(C(),T("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(),K(g(Ne),{key:0,class:D(g(m).e("icon"))},{default:$(()=>[(C(),K(Lt(ce.prefixIcon)))]),_:1},8,["class"])):j("v-if",!0)],2)],2)):j("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(V)&&g(V)(...pe)),onBlur:te[1]||(te[1]=(...pe)=>g(B)&&g(B)(...pe)),onChange:G,onKeydown:me}),null,16,Oee),j(" suffix slot "),g(Oe)?(C(),T("span",{key:1,class:D(g(m).e("suffix"))},[b("span",{class:D(g(m).e("suffix-inner"))},[!g(I)||!g(X)||!g(re)?(C(),T(fe,{key:0},[he(ce.$slots,"suffix"),ce.suffixIcon?(C(),K(g(Ne),{key:0,class:D(g(m).e("icon"))},{default:$(()=>[(C(),K(Lt(ce.suffixIcon)))]),_:1},8,["class"])):j("v-if",!0)],64)):j("v-if",!0),g(I)?(C(),K(g(Ne),{key:1,class:D([g(m).e("icon"),g(m).e("clear")]),onMousedown:Je(g(yt),["prevent"]),onClick:Ze},{default:$(()=>[k(g(wd))]),_:1},8,["class","onMousedown"])):j("v-if",!0),g(X)?(C(),K(g(Ne),{key:2,class:D([g(m).e("icon"),g(m).e("password")]),onClick:ye},{default:$(()=>[(C(),K(Lt(g(H))))]),_:1},8,["class"])):j("v-if",!0),g(re)?(C(),T("span",{key:3,class:D(g(m).e("count"))},[b("span",{class:D(g(m).e("count-inner"))},O(g(z))+" / "+O(ce.maxlength),3)],2)):j("v-if",!0),g(Z)&&g(W)&&g(Y)?(C(),K(g(Ne),{key:4,class:D([g(m).e("icon"),g(m).e("validateIcon"),g(m).is("loading",g(Z)==="validating")])},{default:$(()=>[(C(),K(Lt(g(W))))]),_:1},8,["class"])):j("v-if",!0)],2)],2)):j("v-if",!0)],2),j(" append slot "),ce.$slots.append?(C(),T("div",{key:1,class:D(g(m).be("group","append"))},[he(ce.$slots,"append")],2)):j("v-if",!0)],64)):(C(),T(fe,{key:1},[j(" 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(U),"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(V)&&g(V)(...pe)),onBlur:te[3]||(te[3]=(...pe)=>g(B)&&g(B)(...pe)),onChange:G,onKeydown:me}),null,16,Iee),g(re)?(C(),T("span",{key:0,style:et(E.value),class:D(g(m).e("count"))},O(g(z))+" / "+O(ce.maxlength),7)):j("v-if",!0)],64))],16,Mee))}});var Pee=je(Nee,[["__file","input.vue"]]);const Tt=Zt(Pee),Pu=4,Lee={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"}},Ree=({move:e,size:t,bar:n})=>({[n.size]:t,transform:`translate${n.axis}(${e}%)`}),I3=Symbol("scrollbarContextKey"),Dee=Ke({vertical:Boolean,size:String,move:Number,ratio:{type:Number,required:!0},always:Boolean}),Vee="Thumb",Fee=Q({__name:"thumb",props:Dee,setup(e){const t=e,n=ze(I3),o=Re("scrollbar");n||ws(Vee,"can not inject scrollbar context");const r=q(),s=q(),i=q({}),l=q(!1);let a=!1,u=!1,c=xt?document.onselectstart:null;const d=R(()=>Lee[t.vertical?"vertical":"horizontal"]),f=R(()=>Ree({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 M;if(E.stopPropagation(),E.ctrlKey||[1,2].includes(E.button))return;(M=window.getSelection())==null||M.removeAllRanges(),y(E);const A=E.currentTarget;A&&(i.value[d.value.axis]=A[d.value.offset]-(E[d.value.client]-A.getBoundingClientRect()[d.value.direction]))},m=E=>{if(!s.value||!r.value||!n.wrapElement)return;const M=Math.abs(E.target.getBoundingClientRect()[d.value.direction]-E[d.value.client]),A=s.value[d.value.offset]/2,P=(M-A)*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 M=i.value[d.value.axis];if(!M)return;const A=(r.value.getBoundingClientRect()[d.value.direction]-E[d.value.client])*-1,P=s.value[d.value.offset]-M,N=(A-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 Rn(pn(n,"scrollbarElement"),"mousemove",_),Rn(pn(n,"scrollbarElement"),"mouseleave",S),(E,M)=>(C(),K(_r,{name:g(o).b("fade"),persisted:""},{default:$(()=>[Fe(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:et(g(f)),onMousedown:h},null,38)],34),[[en,E.always||l.value]])]),_:1},8,["name"]))}});var F5=je(Fee,[["__file","thumb.vue"]]);const Bee=Ke({always:{type:Boolean,default:!0},minSize:{type:Number,required:!0}}),zee=Q({__name:"bar",props:Bee,setup(e,{expose:t}){const n=e,o=ze(I3),r=q(0),s=q(0),i=q(""),l=q(""),a=q(1),u=q(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(),T(fe,null,[k(F5,{move:r.value,ratio:u.value,size:i.value,always:f.always},null,8,["move","ratio","size","always"]),k(F5,{move:s.value,ratio:a.value,size:l.value,vertical:"",always:f.always},null,8,["move","ratio","size","always"])],64))}});var jee=je(zee,[["__file","bar.vue"]]);const Hee=Ke({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"]}}),Uee={scroll:({scrollTop:e,scrollLeft:t})=>[e,t].every(_t)},Wee="ElScrollbar",Kee=Q({name:Wee}),qee=Q({...Kee,props:Hee,emits:Uee,setup(e,{expose:t,emit:n}){const o=e,r=Re("scrollbar");let s,i;const l=q(),a=q(),u=q(),c=q(),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){pt(_)?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 Me(()=>o.noresize,_=>{_?(s==null||s(),i==null||i()):({stop:s}=Bo(u,w),i=Rn("resize",w))},{immediate:!0}),Me(()=>[o.maxHeight,o.height],()=>{o.native||ot(()=>{var _;w(),a.value&&((_=c.value)==null||_.handleScroll(a.value))})}),wt(I3,Vn({scrollbarElement:l,wrapElement:a})),Ct(()=>{o.native||ot(()=>{w()})}),Vi(()=>w()),t({wrapRef:a,update:w,scrollTo:m,setScrollTop:y,setScrollLeft:v,handleScroll:h}),(_,S)=>(C(),T("div",{ref_key:"scrollbarRef",ref:l,class:D(g(r).b())},[b("div",{ref_key:"wrapRef",ref:a,class:D(g(f)),style:et(g(d)),onScroll:h},[(C(),K(Lt(_.tag),{id:_.id,ref_key:"resizeRef",ref:u,class:D(g(p)),style:et(_.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?j("v-if",!0):(C(),K(jee,{key:0,ref_key:"barRef",ref:c,always:_.always,"min-size":_.minSize},null,8,["always","min-size"]))],2))}});var Gee=je(qee,[["__file","scrollbar.vue"]]);const ks=Zt(Gee),A3=Symbol("popper"),qT=Symbol("popperContent"),Yee=["dialog","grid","group","listbox","menu","navigation","tooltip","tree"],GT=Ke({role:{type:String,values:Yee,default:"tooltip"}}),Zee=Q({name:"ElPopper",inheritAttrs:!1}),Jee=Q({...Zee,props:GT,setup(e,{expose:t}){const n=e,o=q(),r=q(),s=q(),i=q(),l=R(()=>n.role),a={triggerRef:o,popperInstanceRef:r,contentRef:s,referenceRef:i,role:l};return t(a),wt(A3,a),(u,c)=>he(u.$slots,"default")}});var Xee=je(Jee,[["__file","popper.vue"]]);const YT=Ke({arrowOffset:{type:Number,default:5}}),Qee=Q({name:"ElPopperArrow",inheritAttrs:!1}),ete=Q({...Qee,props:YT,setup(e,{expose:t}){const n=e,o=Re("popper"),{arrowOffset:r,arrowRef:s,arrowStyle:i}=ze(qT,void 0);return Me(()=>n.arrowOffset,l=>{r.value=l}),En(()=>{s.value=void 0}),t({arrowRef:s}),(l,a)=>(C(),T("span",{ref_key:"arrowRef",ref:s,class:D(g(o).e("arrow")),style:et(g(i)),"data-popper-arrow":""},null,6))}});var tte=je(ete,[["__file","arrow.vue"]]);const nte="ElOnlyChild",ZT=Q({name:nte,setup(e,{slots:t,attrs:n}){var o;const r=ze(TT),s=HX((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=JT(l);return a?Fe(hs(a,n),[[s]]):null}}});function JT(e){if(!e)return null;const t=e;for(const n of t){if(pt(n))switch(n.type){case Gn:continue;case Ai:case"svg":return B5(n);case fe:return JT(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 XT=Ke({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}),ote=Q({name:"ElPopperTrigger",inheritAttrs:!1}),rte=Q({...ote,props:XT,setup(e,{expose:t}){const n=e,{role:o,triggerRef:r}=ze(A3,void 0);jX(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(()=>{Me(()=>n.virtualRef,c=>{c&&(r.value=ki(c))},{immediate:!0}),Me(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=Me([s,i,l,a],f=>{["aria-controls","aria-describedby","aria-haspopup","aria-expanded"].forEach((p,h)=>{To(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?j("v-if",!0):(C(),K(g(ZT),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 ste=je(rte,[["__file","trigger.vue"]]);const ey="focus-trap.focus-after-trapped",ty="focus-trap.focus-after-released",ite="focus-trap.focusout-prevented",z5={cancelable:!0,bubbles:!1},lte={cancelable:!0,bubbles:!1},j5="focusAfterTrapped",H5="focusAfterReleased",N3=Symbol("elFocusTrap"),P3=q(),H0=q(0),L3=q(0);let pm=0;const QT=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(!ate(n,t))return n},ate=(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},ute=e=>{const t=QT(e),n=U5(t,e),o=U5(t.reverse(),e);return[n,o]},cte=e=>e instanceof HTMLInputElement&&"select"in e,el=(e,t)=>{if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),L3.value=window.performance.now(),e!==n&&cte(e)&&t&&e.select()}};function W5(e,t){const n=[...e],o=e.indexOf(t);return o!==-1&&n.splice(o,1),n}const dte=()=>{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)}}},fte=(e,t=!1)=>{const n=document.activeElement;for(const o of e)if(el(o,t),document.activeElement!==n)return},K5=dte(),pte=()=>H0.value>L3.value,hm=()=>{P3.value="pointer",H0.value=window.performance.now()},q5=()=>{P3.value="keyboard",H0.value=window.performance.now()},hte=()=>(Ct(()=>{pm===0&&(document.addEventListener("mousedown",hm),document.addEventListener("touchstart",hm),document.addEventListener("keydown",q5)),pm++}),En(()=>{pm--,pm<=0&&(document.removeEventListener("mousedown",hm),document.removeEventListener("touchstart",hm),document.removeEventListener("keydown",q5))}),{focusReason:P3,lastUserFocusTimestamp:H0,lastAutomatedFocusTimestamp:L3}),mm=e=>new CustomEvent(ite,{...lte,detail:e}),mte=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=q();let o,r;const{focusReason:s}=hte();DX(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,M=document.activeElement;if(E&&M){const A=_,[P,N]=ute(A);if(P&&N){if(!S&&M===N){const B=mm({focusReason:s.value});t("focusout-prevented",B),B.defaultPrevented||(h.preventDefault(),x&&el(P,!0))}else if(S&&[P,A].includes(M)){const B=mm({focusReason:s.value});t("focusout-prevented",B),B.defaultPrevented||(h.preventDefault(),x&&el(N,!0))}}else if(M===A){const B=mm({focusReason:s.value});t("focusout-prevented",B),B.defaultPrevented||h.preventDefault()}}};wt(N3,{focusTrapRef:n,onKeydown:l}),Me(()=>e.focusTrapEl,h=>{h&&(n.value=h)},{immediate:!0}),Me([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;!To(y)&&!m.contains(y)&&setTimeout(()=>{if(!i.paused&&e.trapped){const v=mm({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(ey,z5);h.addEventListener(ey,a),h.dispatchEvent(v),v.defaultPrevented||ot(()=>{let w=e.focusStartEl;tt(w)||(el(w),document.activeElement!==w&&(w="first")),w==="first"&&fte(QT(h),!0),(document.activeElement===m||w==="container")&&el(h)})}}}function p(){const h=g(n);if(h){h.removeEventListener(ey,a);const m=new CustomEvent(ty,{...z5,detail:{focusReason:s.value}});h.addEventListener(ty,u),h.dispatchEvent(m),!m.defaultPrevented&&(s.value=="keyboard"||!pte()||h.contains(document.activeElement))&&el(o??document.body),h.removeEventListener(ty,u),K5.remove(i)}}return Ct(()=>{e.trapped&&f(),Me(()=>e.trapped,h=>{h?f():p()})}),En(()=>{e.trapped&&p()}),{onKeydown:l}}});function gte(e,t,n,o,r,s){return he(e.$slots,"default",{handleKeydown:e.onKeydown})}var U0=je(mte,[["render",gte],["__file","focus-trap.vue"]]);const vte=["fixed","absolute"],yte=Ke({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:D0,default:"bottom"},popperOptions:{type:Ce(Object),default:()=>({})},strategy:{type:String,values:vte,default:"absolute"}}),eM=Ke({...yte,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}),_te={mouseenter:e=>e instanceof MouseEvent,mouseleave:e=>e instanceof MouseEvent,focus:()=>!0,blur:()=>!0,close:()=>!0},bte=(e,t=[])=>{const{placement:n,strategy:o,popperOptions:r}=e,s={placement:n,strategy:o,...r,modifiers:[...Cte(e),...t]};return kte(s,r==null?void 0:r.modifiers),s},wte=e=>{if(xt)return ki(e)};function Cte(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 kte(e,t){t&&(e.modifiers=[...e.modifiers,...t??[]])}const Ste=0,$te=e=>{const{popperInstanceRef:t,contentRef:n,triggerRef:o,role:r}=ze(A3,void 0),s=q(),i=q(),l=R(()=>({name:"eventListeners",enabled:!!e.visible})),a=R(()=>{var v;const w=g(s),_=(v=g(i))!=null?v:Ste;return{name:"arrow",enabled:!Wx(w),options:{element:w,padding:_}}}),u=R(()=>({onFirstUpdate:()=>{h()},...bte(e,[g(a),g(l)])})),c=R(()=>wte(e.referenceEl)||g(o)),{attributes:d,state:f,styles:p,update:h,forceUpdate:m,instanceRef:y}=NX(c,n,u);return Me(y,v=>t.value=v),Ct(()=>{Me(()=>{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}},Ete=(e,{attributes:t,styles:n,role:o})=>{const{nextZIndex:r}=F0(),s=Re("popper"),i=R(()=>g(t).popper),l=q(_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()}}},xte=(e,t)=>{const n=q(!1),o=q();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")}}},Tte=Q({name:"ElPopperContent"}),Mte=Q({...Tte,props:eM,emits:_te,setup(e,{expose:t,emit:n}){const o=e,{focusStartRef:r,trapped:s,onFocusAfterReleased:i,onFocusAfterTrapped:l,onFocusInTrap:a,onFocusoutPrevented:u,onReleaseRequested:c}=xte(o,n),{attributes:d,arrowRef:f,contentRef:p,styles:h,instanceRef:m,role:y,update:v}=$te(o),{ariaModal:w,arrowStyle:_,contentAttrs:S,contentClass:x,contentStyle:E,updateZIndex:M}=Ete(o,{styles:h,attributes:d,role:y}),A=ze(cu,void 0),P=q();wt(qT,{arrowStyle:_,arrowRef:f,arrowOffset:P}),A&&(A.addInputId||A.removeInputId)&&wt(cu,{...A,addInputId:yt,removeInputId:yt});let N;const V=(Y=!0)=>{v(),Y&&M()},B=()=>{V(!1),o.visible&&o.focusOnShow?s.value=!0:o.visible===!1&&(s.value=!1)};return Ct(()=>{Me(()=>o.triggerTargetEl,(Y,Z)=>{N==null||N(),N=void 0;const W=g(Y||p.value),H=g(Z||p.value);gs(W)&&(N=Me([y,()=>o.ariaLabel,w,()=>o.id],F=>{["role","aria-label","aria-modal","id"].forEach((U,L)=>{To(F[L])?W.removeAttribute(U):W.setAttribute(U,F[L])})},{immediate:!0})),H!==W&&gs(H)&&["role","aria-label","aria-modal","id"].forEach(F=>{H.removeAttribute(F)})},{immediate:!0}),Me(()=>o.visible,B,{immediate:!0})}),En(()=>{N==null||N(),N=void 0}),t({popperContentRef:p,popperInstanceRef:m,updatePopper:V,contentStyle:E}),(Y,Z)=>(C(),T("div",un({ref_key:"contentRef",ref:p},g(S),{style:g(E),class:g(x),tabindex:"-1",onMouseenter:Z[0]||(Z[0]=W=>Y.$emit("mouseenter",W)),onMouseleave:Z[1]||(Z[1]=W=>Y.$emit("mouseleave",W))}),[k(g(U0),{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 Ote=je(Mte,[["__file","content.vue"]]);const Ite=Zt(Xee),W0=Symbol("elTooltip"),ar=Ke({...BX,...eM,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=Ke({...XT,disabled:Boolean,trigger:{type:Ce([String,Array]),default:"hover"},triggerKeys:{type:Ce(Array),default:()=>[rt.enter,rt.space]}}),{useModelToggleProps:Ate,useModelToggleEmits:Nte,useModelToggle:Pte}=pT("visible"),Lte=Ke({...GT,...Ate,...ar,...Dp,...YT,showArrow:{type:Boolean,default:!0}}),Rte=[...Nte,"before-show","before-hide","show","hide","open","close"],Dte=(e,t)=>Te(e)?e.includes(t):e===t,Lu=(e,t,n)=>o=>{Dte(g(e),t)&&n(o)},Vte=Q({name:"ElTooltipTrigger"}),Fte=Q({...Vte,props:Dp,setup(e,{expose:t}){const n=e,o=Re("tooltip"),{controlled:r,id:s,open:i,onOpen:l,onClose:a,onToggle:u}=ze(W0,void 0),c=q(null),d=()=>{if(g(r)||n.disabled)return!0},f=pn(n,"trigger"),p=Pn(d,Lu(f,"hover",l)),h=Pn(d,Lu(f,"hover",a)),m=Pn(d,Lu(f,"click",S=>{S.button===0&&u(S)})),y=Pn(d,Lu(f,"focus",l)),v=Pn(d,Lu(f,"focus",a)),w=Pn(d,Lu(f,"contextmenu",S=>{S.preventDefault(),u(S)})),_=Pn(d,S=>{const{code:x}=S;n.triggerKeys.includes(x)&&(S.preventDefault(),u(S))});return t({triggerRef:c}),(S,x)=>(C(),K(g(ste),{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 Bte=je(Fte,[["__file","trigger.vue"]]);const zte=Q({name:"ElTooltipContent",inheritAttrs:!1}),jte=Q({...zte,props:ar,setup(e,{expose:t}){const n=e,{selector:o}=xT(),r=Re("tooltip"),s=q(null),i=q(!1),{controlled:l,id:a,open:u,trigger:c,onClose:d,onOpen:f,onShow:p,onHide:h,onBeforeShow:m,onBeforeHide:y}=ze(W0,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 F;return(F=n.style)!=null?F:{}}),M=R(()=>!g(u)),A=()=>{h()},P=()=>{if(g(l))return!0},N=Pn(P,()=>{n.enterable&&g(c)==="hover"&&f()}),V=Pn(P,()=>{g(c)==="hover"&&d()}),B=()=>{var F,U;(U=(F=s.value)==null?void 0:F.updatePopper)==null||U.call(F),m==null||m()},Y=()=>{y==null||y()},Z=()=>{p(),H=fx(R(()=>{var F;return(F=s.value)==null?void 0:F.popperContentRef}),()=>{if(g(l))return;g(c)!=="hover"&&d()})},W=()=>{n.virtualTriggering||d()};let H;return Me(()=>g(u),F=>{F||H==null||H()},{flush:"post"}),Me(()=>n.content,()=>{var F,U;(U=(F=s.value)==null?void 0:F.updatePopper)==null||U.call(F)}),t({contentRef:s}),(F,U)=>(C(),K(_s,{disabled:!F.teleported,to:g(x)},[k(_r,{name:g(v),onAfterLeave:A,onBeforeEnter:B,onAfterEnter:Z,onBeforeLeave:Y},{default:$(()=>[g(_)?Fe((C(),K(g(Ote),un({key:0,id:g(a),ref_key:"contentRef",ref:s},F.$attrs,{"aria-label":F.ariaLabel,"aria-hidden":g(M),"boundaries-padding":F.boundariesPadding,"fallback-placements":F.fallbackPlacements,"gpu-acceleration":F.gpuAcceleration,offset:F.offset,placement:F.placement,"popper-options":F.popperOptions,strategy:F.strategy,effect:F.effect,enterable:F.enterable,pure:F.pure,"popper-class":F.popperClass,"popper-style":[F.popperStyle,g(E)],"reference-el":F.referenceEl,"trigger-target-el":F.triggerTargetEl,visible:g(S),"z-index":F.zIndex,onMouseenter:g(N),onMouseleave:g(V),onBlur:W,onClose:g(d)}),{default:$(()=>[i.value?j("v-if",!0):he(F.$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)]]):j("v-if",!0)]),_:3},8,["name"])],8,["disabled","to"]))}});var Hte=je(jte,[["__file","content.vue"]]);const Ute=["innerHTML"],Wte={key:1},Kte=Q({name:"ElTooltip"}),qte=Q({...Kte,props:Lte,emits:Rte,setup(e,{expose:t,emit:n}){const o=e;FX();const r=Hr(),s=q(),i=q(),l=()=>{var v;const w=g(s);w&&((v=w.popperInstanceRef)==null||v.update())},a=q(!1),u=q(),{show:c,hide:d,hasUpdateHandler:f}=Pte({indicator:a,toggleReason:u}),{onOpen:p,onClose:h}=zX({showAfter:pn(o,"showAfter"),hideAfter:pn(o,"hideAfter"),autoClose:pn(o,"autoClose"),open:c,close:d}),m=R(()=>Br(o.visible)&&!f.value);wt(W0,{controlled:m,id:r,open:bu(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}),Me(()=>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 gw(()=>a.value&&d()),t({popperRef:s,contentRef:i,isFocusInsideContent:y,updatePopper:l,onOpen:p,onClose:h,hide:d}),(v,w)=>(C(),K(g(Ite),{ref_key:"popperRef",ref:s,role:v.role},{default:$(()=>[k(Bte,{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}):j("v-if",!0)]),_:3},8,["disabled","trigger","trigger-keys","virtual-ref","virtual-triggering"]),k(Hte,{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(),T("span",{key:0,innerHTML:v.content},null,8,Ute)):(C(),T("span",Wte,O(v.content),1))]),v.showArrow?(C(),K(g(tte),{key:0,"arrow-offset":v.arrowOffset},null,8,["arrow-offset"])):j("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 Gte=je(qte,[["__file","tooltip.vue"]]);const Eu=Zt(Gte),Yte=Ke({size:{type:[Number,String],values:Jl,default:"",validator:e=>_t(e)},shape:{type:String,values:["circle","square"],default:"circle"},icon:{type:Io},src:{type:String,default:""},alt:String,srcSet:String,fit:{type:Ce(String),default:"cover"}}),Zte={error:e=>e instanceof Event},Jte=["src","alt","srcset"],Xte=Q({name:"ElAvatar"}),Qte=Q({...Xte,props:Yte,emits:Zte,setup(e,{emit:t}){const n=e,o=Re("avatar"),r=q(!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}));Me(()=>n.src,()=>r.value=!1);function a(u){r.value=!0,t("error",u)}return(u,c)=>(C(),T("span",{class:D(g(s)),style:et(g(i))},[(u.src||u.srcSet)&&!r.value?(C(),T("img",{key:0,src:u.src,alt:u.alt,srcset:u.srcSet,style:et(g(l)),onError:a},null,44,Jte)):u.icon?(C(),K(g(Ne),{key:1},{default:$(()=>[(C(),K(Lt(u.icon)))]),_:1})):he(u.$slots,"default",{key:2})],6))}});var ene=je(Qte,[["__file","avatar.vue"]]);const tne=Zt(ene),tM=Symbol("breadcrumbKey"),nne=Ke({separator:{type:String,default:"/"},separatorIcon:{type:Io}}),one=["aria-label"],rne=Q({name:"ElBreadcrumb"}),sne=Q({...rne,props:nne,setup(e){const t=e,{t:n}=Kt(),o=Re("breadcrumb"),r=q();return wt(tM,t),Ct(()=>{const s=r.value.querySelectorAll(`.${o.e("item")}`);s.length&&s[s.length-1].setAttribute("aria-current","page")}),(s,i)=>(C(),T("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,one))}});var ine=je(sne,[["__file","breadcrumb.vue"]]);const lne=Ke({to:{type:Ce([String,Object]),default:""},replace:{type:Boolean,default:!1}}),ane=Q({name:"ElBreadcrumbItem"}),une=Q({...ane,props:lne,setup(e){const t=e,n=at(),o=ze(tM,void 0),r=Re("breadcrumb"),s=n.appContext.config.globalProperties.$router,i=q(),l=()=>{!t.to||!s||(t.replace?s.replace(t.to):s.push(t.to))};return(a,u)=>{var c,d;return C(),T("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(),K(g(Ne),{key:0,class:D(g(r).e("separator"))},{default:$(()=>[(C(),K(Lt(g(o).separatorIcon)))]),_:1},8,["class"])):(C(),T("span",{key:1,class:D(g(r).e("separator")),role:"presentation"},O((d=g(o))==null?void 0:d.separator),3))],2)}}});var nM=je(une,[["__file","breadcrumb-item.vue"]]);const cne=Zt(ine,{BreadcrumbItem:nM}),dne=Zn(nM),oM=Symbol("buttonGroupContextKey"),fne=(e,t)=>{Ka({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=ze(oM,void 0),o=ph("button"),{form:r}=ri(),s=Jo(R(()=>n==null?void 0:n.size)),i=Gr(),l=q(),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)}}},pne=["default","primary","success","warning","info","danger","text",""],hne=["button","submit","reset"],ab=Ke({size:qr,disabled:Boolean,type:{type:String,values:pne,default:""},icon:{type:Io},nativeType:{type:String,values:hne,default:"button"},loading:Boolean,loadingIcon:{type:Io,default:()=>u3},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"}}),mne={click:e=>e instanceof MouseEvent};function lo(e,t){gne(e)&&(e="100%");var n=vne(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 gm(e){return Math.min(1,Math.max(0,e))}function gne(e){return typeof e=="string"&&e.indexOf(".")!==-1&&parseFloat(e)===1}function vne(e){return typeof e=="string"&&e.indexOf("%")!==-1}function rM(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function vm(e){return e<=1?"".concat(Number(e)*100,"%"):e}function Pa(e){return e.length===1?"0"+e:String(e)}function yne(e,t,n){return{r:lo(e,255)*255,g:lo(t,255)*255,b:lo(n,255)*255}}function G5(e,t,n){e=lo(e,255),t=lo(t,255),n=lo(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 ny(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 _ne(e,t,n){var o,r,s;if(e=lo(e,360),t=lo(t,100),n=lo(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=ny(l,i,e+1/3),r=ny(l,i,e),s=ny(l,i,e-1/3)}return{r:o*255,g:r*255,b:s*255}}function Y5(e,t,n){e=lo(e,255),t=lo(t,255),n=lo(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 bne(e,t,n){e=lo(e,360)*6,t=lo(t,100),n=lo(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=[Pa(Math.round(e).toString(16)),Pa(Math.round(t).toString(16)),Pa(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 wne(e,t,n,o,r){var s=[Pa(Math.round(e).toString(16)),Pa(Math.round(t).toString(16)),Pa(Math.round(n).toString(16)),Pa(Cne(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 Cne(e){return Math.round(parseFloat(e)*255).toString(16)}function J5(e){return or(e)/255}function or(e){return parseInt(e,16)}function kne(e){return{r:e>>16,g:(e&65280)>>8,b:e&255}}var ub={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 Sne(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=xne(e)),typeof e=="object"&&(ci(e.r)&&ci(e.g)&&ci(e.b)?(t=yne(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=vm(e.s),r=vm(e.v),t=bne(e.h,o,r),i=!0,l="hsv"):ci(e.h)&&ci(e.s)&&ci(e.l)&&(o=vm(e.s),s=vm(e.l),t=_ne(e.h,o,s),i=!0,l="hsl"),Object.prototype.hasOwnProperty.call(e,"a")&&(n=e.a)),n=rM(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 $ne="[-\\+]?\\d+%?",Ene="[-\\+]?\\d*\\.\\d+%?",Ml="(?:".concat(Ene,")|(?:").concat($ne,")"),oy="[\\s|\\(]+(".concat(Ml,")[,|\\s]+(").concat(Ml,")[,|\\s]+(").concat(Ml,")\\s*\\)?"),ry="[\\s|\\(]+(".concat(Ml,")[,|\\s]+(").concat(Ml,")[,|\\s]+(").concat(Ml,")[,|\\s]+(").concat(Ml,")\\s*\\)?"),Xr={CSS_UNIT:new RegExp(Ml),rgb:new RegExp("rgb"+oy),rgba:new RegExp("rgba"+ry),hsl:new RegExp("hsl"+oy),hsla:new RegExp("hsla"+ry),hsv:new RegExp("hsv"+oy),hsva:new RegExp("hsva"+ry),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 xne(e){if(e=e.trim().toLowerCase(),e.length===0)return!1;var t=!1;if(ub[e])e=ub[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 Tne=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=kne(t)),this.originalInput=t;var r=Sne(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=rM(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),wne(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(lo(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(lo(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(ub);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=gm(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=gm(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=gm(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=gm(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 Mne(e){const t=Gr(),n=Re("button");return R(()=>{let o={};const r=e.color;if(r){const s=new Tne(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 One=Q({name:"ElButton"}),Ine=Q({...One,props:ab,emits:mne,setup(e,{expose:t,emit:n}){const o=e,r=Mne(o),s=Re("button"),{_ref:i,_size:l,_type:a,_disabled:u,_props:c,shouldAddSpace:d,handleClick:f}=fne(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(),K(Lt(h.tag),un({ref_key:"_ref",ref:i},g(c),{class:g(p),style:g(r),onClick:g(f)}),{default:$(()=>[h.loading?(C(),T(fe,{key:0},[h.$slots.loading?he(h.$slots,"loading",{key:0}):(C(),K(g(Ne),{key:1,class:D(g(s).is("loading"))},{default:$(()=>[(C(),K(Lt(h.loadingIcon)))]),_:1},8,["class"]))],64)):h.icon||h.$slots.icon?(C(),K(g(Ne),{key:1},{default:$(()=>[h.icon?(C(),K(Lt(h.icon),{key:0})):he(h.$slots,"icon",{key:1})]),_:3})):j("v-if",!0),h.$slots.default?(C(),T("span",{key:2,class:D({[g(s).em("text","expand")]:g(d)})},[he(h.$slots,"default")],2)):j("v-if",!0)]),_:3},16,["class","style","onClick"]))}});var Ane=je(Ine,[["__file","button.vue"]]);const Nne={size:ab.size,type:ab.type},Pne=Q({name:"ElButtonGroup"}),Lne=Q({...Pne,props:Nne,setup(e){const t=e;wt(oM,Vn({size:pn(t,"size"),type:pn(t,"type")}));const n=Re("button");return(o,r)=>(C(),T("div",{class:D(`${g(n).b("group")}`)},[he(o.$slots,"default")],2))}});var sM=je(Lne,[["__file","button-group.vue"]]);const ct=Zt(Ane,{ButtonGroup:sM});Zn(sM);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 iM={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 W=["th","st","nd","rd"],H=Z%100;return"["+Z+(W[(H-20)%10]||W[H]||W[0])+"]"}},_=function(Z,W,H){var F=String(Z);return!F||F.length>=W?Z:""+Array(W+1-F.length).join(H)+Z},S={s:_,z:function(Z){var W=-Z.utcOffset(),H=Math.abs(W),F=Math.floor(H/60),U=H%60;return(W<=0?"+":"-")+_(F,2,"0")+":"+_(U,2,"0")},m:function Z(W,H){if(W.date()<H.date())return-Z(H,W);var F=12*(H.year()-W.year())+(H.month()-W.month()),U=W.clone().add(F,d),L=H-U<0,I=W.clone().add(F+(L?-1:1),d);return+(-(F+(H-U)/(L?U-I:I-U))||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 M="$isDayjsObject",A=function(Z){return Z instanceof B||!(!Z||!Z[M])},P=function Z(W,H,F){var U;if(!W)return x;if(typeof W=="string"){var L=W.toLowerCase();E[L]&&(U=L),H&&(E[L]=H,U=L);var I=W.split("-");if(!U&&I.length>1)return Z(I[0])}else{var X=W.name;E[X]=W,U=X}return!F&&U&&(x=U),U||!F&&x},N=function(Z,W){if(A(Z))return Z.clone();var H=typeof W=="object"?W:{};return H.date=Z,H.args=arguments,new B(H)},V=S;V.l=P,V.i=A,V.w=function(Z,W){return N(Z,{locale:W.$L,utc:W.$u,x:W.$x,$offset:W.$offset})};var B=function(){function Z(H){this.$L=P(H.locale,null,!0),this.parse(H),this.$x=this.$x||H.x||{},this[M]=!0}var W=Z.prototype;return W.parse=function(H){this.$d=function(F){var U=F.date,L=F.utc;if(U===null)return new Date(NaN);if(V.u(U))return new Date;if(U instanceof Date)return new Date(U);if(typeof U=="string"&&!/Z$/i.test(U)){var I=U.match(y);if(I){var X=I[2]-1||0,re=(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,re)):new Date(I[1],X,I[3]||1,I[4]||0,I[5]||0,I[6]||0,re)}}return new Date(U)}(H),this.init()},W.init=function(){var H=this.$d;this.$y=H.getFullYear(),this.$M=H.getMonth(),this.$D=H.getDate(),this.$W=H.getDay(),this.$H=H.getHours(),this.$m=H.getMinutes(),this.$s=H.getSeconds(),this.$ms=H.getMilliseconds()},W.$utils=function(){return V},W.isValid=function(){return this.$d.toString()!==m},W.isSame=function(H,F){var U=N(H);return this.startOf(F)<=U&&U<=this.endOf(F)},W.isAfter=function(H,F){return N(H)<this.startOf(F)},W.isBefore=function(H,F){return this.endOf(F)<N(H)},W.$g=function(H,F,U){return V.u(H)?this[F]:this.set(U,H)},W.unix=function(){return Math.floor(this.valueOf()/1e3)},W.valueOf=function(){return this.$d.getTime()},W.startOf=function(H,F){var U=this,L=!!V.u(F)||F,I=V.p(H),X=function(ve,le){var Ie=V.w(U.$u?Date.UTC(U.$y,le,ve):new Date(U.$y,le,ve),U);return L?Ie:Ie.endOf(u)},re=function(ve,le){return V.w(U.toDate()[ve].apply(U.toDate("s"),(L?[0,0,0,0]:[23,59,59,999]).slice(le)),U)},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 re(xe+"Hours",0);case a:return re(xe+"Minutes",1);case l:return re(xe+"Seconds",2);case i:return re(xe+"Milliseconds",3);default:return this.clone()}},W.endOf=function(H){return this.startOf(H,!1)},W.$set=function(H,F){var U,L=V.p(H),I="set"+(this.$u?"UTC":""),X=(U={},U[u]=I+"Date",U[h]=I+"Date",U[d]=I+"Month",U[p]=I+"FullYear",U[a]=I+"Hours",U[l]=I+"Minutes",U[i]=I+"Seconds",U[s]=I+"Milliseconds",U)[L],re=L===u?this.$D+(F-this.$W):F;if(L===d||L===p){var z=this.clone().set(h,1);z.$d[X](re),z.init(),this.$d=z.set(h,Math.min(this.$D,z.daysInMonth())).$d}else X&&this.$d[X](re);return this.init(),this},W.set=function(H,F){return this.clone().$set(H,F)},W.get=function(H){return this[V.p(H)]()},W.add=function(H,F){var U,L=this;H=Number(H);var I=V.p(F),X=function(ge){var Oe=N(L);return V.w(Oe.date(Oe.date()+Math.round(ge*H)),L)};if(I===d)return this.set(d,this.$M+H);if(I===p)return this.set(p,this.$y+H);if(I===u)return X(1);if(I===c)return X(7);var re=(U={},U[l]=o,U[a]=r,U[i]=n,U)[I]||1,z=this.$d.getTime()+H*re;return V.w(z,this)},W.subtract=function(H,F){return this.add(-1*H,F)},W.format=function(H){var F=this,U=this.$locale();if(!this.isValid())return U.invalidDate||m;var L=H||"YYYY-MM-DDTHH:mm:ssZ",I=V.z(this),X=this.$H,re=this.$m,z=this.$M,ge=U.weekdays,Oe=U.months,xe=U.meridiem,ee=function(le,Ie,Ge,G){return le&&(le[Ie]||le(F,L))||Ge[Ie].slice(0,G)},de=function(le){return V.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(F.$y).slice(-2);case"YYYY":return V.s(F.$y,4,"0");case"M":return z+1;case"MM":return V.s(z+1,2,"0");case"MMM":return ee(U.monthsShort,z,Oe,3);case"MMMM":return ee(Oe,z);case"D":return F.$D;case"DD":return V.s(F.$D,2,"0");case"d":return String(F.$W);case"dd":return ee(U.weekdaysMin,F.$W,ge,2);case"ddd":return ee(U.weekdaysShort,F.$W,ge,3);case"dddd":return ge[F.$W];case"H":return String(X);case"HH":return V.s(X,2,"0");case"h":return de(1);case"hh":return de(2);case"a":return ve(X,re,!0);case"A":return ve(X,re,!1);case"m":return String(re);case"mm":return V.s(re,2,"0");case"s":return String(F.$s);case"ss":return V.s(F.$s,2,"0");case"SSS":return V.s(F.$ms,3,"0");case"Z":return I}return null}(le)||I.replace(":","")})},W.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},W.diff=function(H,F,U){var L,I=this,X=V.p(F),re=N(H),z=(re.utcOffset()-this.utcOffset())*o,ge=this-re,Oe=function(){return V.m(I,re)};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 U?L:V.a(L)},W.daysInMonth=function(){return this.endOf(d).$D},W.$locale=function(){return E[this.$L]},W.locale=function(H,F){if(!H)return this.$L;var U=this.clone(),L=P(H,F,!0);return L&&(U.$L=L),U},W.clone=function(){return V.w(this.$d,this)},W.toDate=function(){return new Date(this.valueOf())},W.toJSON=function(){return this.isValid()?this.toISOString():null},W.toISOString=function(){return this.$d.toISOString()},W.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(W){return this.$g(W,Z[0],Z[1])}}),N.extend=function(Z,W){return Z.$i||(Z(W,B,N),Z.$i=!0),N},N.locale=P,N.isDayjs=A,N.unix=function(Z){return N(1e3*Z)},N.en=E[x],N.Ls=E,N.p={},N})})(iM);var Rne=iM.exports;const ut=_o(Rne);var lM={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,V){var B=V&&V.toUpperCase();return N||v[V]||n[V]||v[B].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(Y,Z,W){return Z||W.slice(1)})})).match(o),_=w.length,S=0;S<_;S+=1){var x=w[S],E=p[x],M=E&&E[0],A=E&&E[1];w[S]=A?{regex:M,parser:A}:x.replace(/^\[|\]$/g,"")}return function(P){for(var N={},V=0,B=0;V<_;V+=1){var Y=w[V];if(typeof Y=="string")B+=Y.length;else{var Z=Y.regex,W=Y.parser,H=P.slice(B),F=Z.exec(H)[0];W.call(N,F),P=P.replace(F,"")}}return function(U){var L=U.afternoon;if(L!==void 0){var I=U.hours;L?I<12&&(U.hours+=12):I===12&&(U.hours=0),delete U.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,M=S.args;this.$u=E;var A=M[1];if(typeof A=="string"){var P=M[2]===!0,N=M[3]===!0,V=P||N,B=M[2];N&&(B=M[2]),l=this.$locale(),!P&&B&&(l=v.Ls[B]),this.$d=function(H,F,U){try{if(["x","X"].indexOf(F)>-1)return new Date((F==="X"?1e3:1)*H);var L=h(F)(H),I=L.year,X=L.month,re=L.day,z=L.hours,ge=L.minutes,Oe=L.seconds,xe=L.milliseconds,ee=L.zone,de=new Date,ve=re||(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)):U?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,A,E),this.init(),B&&B!==!0&&(this.$L=this.locale(B).$L),V&&x!=this.format(A)&&(this.$d=new Date("")),l={}}else if(A instanceof Array)for(var Y=A.length,Z=1;Z<=Y;Z+=1){M[1]=A[Z-1];var W=v.apply(this,M);if(W.isValid()){this.$d=W.$d,this.$L=W.$L,this.init();break}Z===Y&&(this.$d=new Date(""))}else _.call(this,S)}}})})(lM);var Dne=lM.exports;const aM=_o(Dne),X5=["hours","minutes","seconds"],Q5="HH:mm:ss",qu="YYYY-MM-DD",Vne={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}`},sy=(e,t)=>[e>0?e-1:void 0,e,e<t?e+1:void 0],uM=e=>Array.from(Array.from({length:e}).keys()),cM=e=>e.replace(/\W?m{1,2}|\W?ZZ/g,"").replace(/\W?h{1,2}|\W?s{1,3}|\W?a/gi,"").trim(),dM=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=sg(e),o=sg(t);return n&&o?e.getTime()===t.getTime():!n&&!o?e===t:!1},t8=function(e,t){const n=Te(e),o=Te(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)},iy=(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},fM=Ke({disabledHours:{type:Ce(Function)},disabledMinutes:{type:Ce(Function)},disabledSeconds:{type:Ce(Function)}}),Fne=Ke({visible:Boolean,actualVisible:{type:Boolean,default:void 0},format:{type:String,default:""}}),pM=Ke({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,...fM,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}),Bne=["id","name","placeholder","value","disabled","readonly"],zne=["id","name","placeholder","value","disabled","readonly"],jne=Q({name:"Picker"}),Hne=Q({...jne,props:pM,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}=ri(),d=ze("ElPopperOptions",{}),{valueOnClear:f}=HT(o,null),p=q(),h=q(),m=q(!1),y=q(!1),v=q(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")]);Me(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(It=>void 0)))},M=se=>{if(!t8(o.modelValue,se)){let De;Te(se)?De=se.map(It=>o8(It,o.valueFormat,s.value)):se&&(De=o8(se,o.valueFormat,s.value)),n("update:modelValue",se&&De,s.value)}},A=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,It)=>{const mn=P.value;mn.length&&(!It||It==="min"?(mn[0].setSelectionRange(se,De),mn[0].focus()):It==="max"&&(mn[1].setSelectionRange(se,De),mn[1].focus()))},V=()=>{L(!0,!0),ot(()=>{_=!1})},B=(se="",De=!1)=>{De||(_=!0),m.value=De;let It;Te(se)?It=se.map(mn=>mn.toDate()):It=se&&se.toDate(),me.value=null,M(It)},Y=()=>{y.value=!0},Z=()=>{n("visible-change",!0)},W=se=>{(se==null?void 0:se.key)===rt.esc&&L(!0,!0)},H=()=>{y.value=!1,m.value=!1,_=!1,n("visible-change",!1)},F=()=>{m.value=!0},U=()=>{m.value=!1},L=(se=!0,De=!1)=>{_=De;const[It,mn]=g(P);let Kn=It;!se&&Ae.value&&(Kn=mn),Kn&&Kn.focus()},I=se=>{o.readonly||z.value||m.value||_||(m.value=!0,n("focus",se))};let X;const re=se=>{const De=async()=>{setTimeout(()=>{var It;X===De&&(!((It=p.value)!=null&&It.isFocusInsideContent()&&!w)&&P.value.filter(mn=>mn.contains(document.activeElement)).length===0&&(He(),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()):Te(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);Hl(De,se)||(se=De,M(Te(se)?se.map(It=>It.toDate()):se.toDate()))}return Te(se)&&se.some(De=>!De)&&(se=[]),se}),Oe=R(()=>{if(!ae.value.panelReady)return"";const se=ce(ge.value);return Te(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:DY)),Ie=q(!1),Ge=se=>{o.readonly||z.value||Ie.value&&(se.stopPropagation(),V(),M(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||Te(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),It=g(Pe);De&&(se.target===De||se.composedPath().includes(De))||se.target===It||se.composedPath().includes(It)||(m.value=!1)});const me=q(null),He=()=>{if(me.value){const se=Ze(Oe.value);se&&te(se)&&(M(Te(se)?se.map(De=>De.toDate()):se.toDate()),me.value=null)}me.value===""&&(M(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(A(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)))&&(He(),m.value=!1),se.stopPropagation();return}if(me.value){se.stopPropagation();return}ae.value.handleKeydownInput&&ae.value.handleKeydownInput(se)},Be=se=>{me.value=se,m.value||(m.value=!0)},Xe=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,It=Ze(De&&De[0]),mn=g(ge);if(It&&It.isValid()){me.value=[ce(It),((se=Oe.value)==null?void 0:se[1])||null];const Kn=[It,mn&&(mn[1]||null)];te(Kn)&&(M(Kn),me.value=null)}},we=()=>{var se;const De=g(me),It=Ze(De&&De[1]),mn=g(ge);if(It&&It.isValid()){me.value=[((se=g(Oe))==null?void 0:se[0])||null,ce(It)];const Kn=[mn&&mn[0],It];te(Kn)&&(M(Kn),me.value=null)}},ae=q({}),Se=se=>{ae.value[se[0]]=se[1],ae.value.panelReady=!0},Ve=se=>{n("calendar-change",se)},st=(se,De,It)=>{n("panel-change",se,De,It)};return wt("EP_PICKER_BASE",{props:o}),t({focus:L,handleFocusInput:I,handleBlurInput:re,handleOpen:F,handleClose:U,onPick:B}),(se,De)=>(C(),K(g(Eu),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:H}),{default:$(()=>[g(Ae)?(C(),T("div",{key:1,ref_key:"inputRef",ref:h,class:D(g(S)),style:et(se.$attrs.style),onClick:I,onMouseenter:ue,onMouseleave:_e,onTouchstart:ye,onKeydown:pe},[g(le)?(C(),K(g(Ne),{key:0,class:D([g(l).e("icon"),g(a).e("icon")]),onMousedown:Je(J,["prevent"]),onTouchstart:ye},{default:$(()=>[(C(),K(Lt(g(le))))]),_:1},8,["class","onMousedown"])):j("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:Xe,onChange:ie,onFocus:I,onBlur:re},null,42,Bne),he(se.$slots,"range-separator",{},()=>[b("span",{class:D(g(a).b("separator"))},O(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:re,onInput:$e,onChange:we},null,42,zne),se.clearIcon?(C(),K(g(Ne),{key:1,class:D(g(x)),onClick:Ge},{default:$(()=>[(C(),K(Lt(se.clearIcon)))]),_:1},8,["class"])):j("v-if",!0)],38)):(C(),K(g(Tt),{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:et(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:Be,onFocus:I,onBlur:re,onKeydown:pe,onChange:He,onMousedown:J,onMouseenter:ue,onMouseleave:_e,onTouchstart:ye,onClick:De[0]||(De[0]=Je(()=>{},["stop"]))},{prefix:$(()=>[g(le)?(C(),K(g(Ne),{key:0,class:D(g(l).e("icon")),onMousedown:Je(J,["prevent"]),onTouchstart:ye},{default:$(()=>[(C(),K(Lt(g(le))))]),_:1},8,["class","onMousedown"])):j("v-if",!0)]),suffix:$(()=>[Ie.value&&se.clearIcon?(C(),K(g(Ne),{key:0,class:D(`${g(l).e("icon")} clear-icon`),onClick:Je(Ge,["stop"])},{default:$(()=>[(C(),K(Lt(se.clearIcon)))]),_:1},8,["class","onClick"])):j("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:Ve,onPanelChange:st,onKeydown:W,onMousedown:De[1]||(De[1]=Je(()=>{},["stop"]))})]),_:3},16,["visible","transition","popper-class","popper-options"]))}});var Une=je(Hne,[["__file","picker.vue"]]);const Wne=Ke({...Fne,datetimeRole:String,parsedValue:{type:Ce(Object)}}),Kne=({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}}},ly=e=>{const t=(o,r)=>o||r,n=o=>o!==!0;return e.map(t).filter(n)},hM=(e,t,n)=>({getHoursList:(i,l)=>iy(24,e&&(()=>e==null?void 0:e(i,l))),getMinutesList:(i,l,a)=>iy(60,t&&(()=>t==null?void 0:t(i,l,a))),getSecondsList:(i,l,a,u)=>iy(60,n&&(()=>n==null?void 0:n(i,l,a,u)))}),qne=(e,t,n)=>{const{getHoursList:o,getMinutesList:r,getSecondsList:s}=hM(e,t,n);return{getAvailableHours:(u,c)=>ly(o(u,c)),getAvailableMinutes:(u,c,d)=>ly(r(u,c,d)),getAvailableSeconds:(u,c,d,f)=>ly(s(u,c,d,f))}},Gne=e=>{const t=q(e.parsedValue);return Me(()=>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)}},Yne=100,Zne=600,Vg={beforeMount(e,t){const n=t.value,{interval:o=Yne,delay:r=Zne}=Qe(n)?{}:n;let s,i;const l=()=>Qe(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))})}},cb="_trap-focus-children",La=[],i8=e=>{if(La.length===0)return;const t=La[La.length-1][cb];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())}},Jne={beforeMount(e){e[cb]=_6(e),La.push(e),La.length<=1&&document.addEventListener("keydown",i8)},updated(e){ot(()=>{e[cb]=_6(e)})},unmounted(){La.shift(),La.length===0&&document.removeEventListener("keydown",i8)}};var l8=!1,Ta,db,fb,e1,t1,mM,n1,pb,hb,mb,gM,gb,vb,vM,yM;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(gb=/\b(iPhone|iP[ao]d)/.exec(e),vb=/\b(iP[ao]d)/.exec(e),mb=/Android/i.exec(e),vM=/FBAN\/\w+;/i.exec(e),yM=/Mobile/i.exec(e),gM=!!/Win64/.exec(e),t){Ta=t[1]?parseFloat(t[1]):t[5]?parseFloat(t[5]):NaN,Ta&&document&&document.documentMode&&(Ta=document.documentMode);var o=/(?:Trident\/(\d+.\d+))/.exec(e);mM=o?parseFloat(o[1])+4:Ta,db=t[2]?parseFloat(t[2]):NaN,fb=t[3]?parseFloat(t[3]):NaN,e1=t[4]?parseFloat(t[4]):NaN,e1?(t=/(?:Chrome\/(\d+\.\d+))/.exec(e),t1=t&&t[1]?parseFloat(t[1]):NaN):t1=NaN}else Ta=db=fb=t1=e1=NaN;if(n){if(n[1]){var r=/(?:Mac OS X (\d+(?:[._]\d+)?))/.exec(e);n1=r?parseFloat(r[1].replace("_",".")):!0}else n1=!1;pb=!!n[2],hb=!!n[3]}else n1=pb=hb=!1}}var yb={ie:function(){return Ro()||Ta},ieCompatibilityMode:function(){return Ro()||mM>Ta},ie64:function(){return yb.ie()&&gM},firefox:function(){return Ro()||db},opera:function(){return Ro()||fb},webkit:function(){return Ro()||e1},safari:function(){return yb.webkit()},chrome:function(){return Ro()||t1},windows:function(){return Ro()||pb},osx:function(){return Ro()||n1},linux:function(){return Ro()||hb},iphone:function(){return Ro()||gb},mobile:function(){return Ro()||gb||vb||mb||yM},nativeApp:function(){return Ro()||vM},android:function(){return Ro()||mb},ipad:function(){return Ro()||vb}},Xne=yb,ym=!!(typeof window<"u"&&window.document&&window.document.createElement),Qne={canUseDOM:ym,canUseWorkers:typeof Worker<"u",canUseEventListeners:ym&&!!(window.addEventListener||window.attachEvent),canUseViewport:ym&&!!window.screen,isInWorker:!ym},_M=Qne,bM;_M.canUseDOM&&(bM=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0);function eoe(e,t){if(!_M.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&&bM&&e==="wheel"&&(o=document.implementation.hasFeature("Events.wheel","3.0")),o}var toe=eoe,a8=10,u8=40,c8=800;function wM(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}}wM.getEventType=function(){return Xne.firefox()?"DOMMouseScroll":toe("wheel")?"wheel":"mousewheel"};var noe=wM;/** |
| 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 ooe=function(e,t){if(e&&e.addEventListener){const n=function(o){const r=noe(o);t&&Reflect.apply(t,this,[o,r])};e.addEventListener("wheel",n,{passive:!0})}},roe={beforeMount(e,t){ooe(e,t.value)}},soe=Ke({role:{type:String,required:!0},spinnerDate:{type:Ce(Object),required:!0},showSeconds:{type:Boolean,default:!0},arrowControl:Boolean,amPmMode:{type:Ce(String),default:""},...fM}),ioe=["onClick"],loe=["onMouseenter"],aoe=Q({__name:"basic-time-spinner",props:soe,emits:["change","select-range","set-option"],setup(e,{emit:t}){const n=e,o=Re("time"),{getHoursList:r,getMinutesList:s,getSecondsList:i}=hM(n.disabledHours,n.disabledMinutes,n.disabledSeconds);let l=!1;const a=q(),u=q(),c=q(),d=q(),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(),re=L.second();return{hours:I,minutes:X,seconds:re}}),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:sy(L,23),minutes:sy(I,59),seconds:sy(X,59)}}),v=jl(L=>{l=!1,S(L)},200),w=L=>{if(!!!n.amPmMode)return"";const X=n.amPmMode==="A";let re=L<12?" am":" pm";return X&&(re=re.toUpperCase()),re},_=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,re]=I;t("select-range",X,re),a.value=L},S=L=>{M(L,g(h)[L])},x=()=>{S("hours"),S("minutes"),S("seconds")},E=L=>L.querySelector(`.${o.namespace.value}-scrollbar__wrap`),M=(L,I)=>{if(n.arrowControl)return;const X=g(f[L]);X&&X.$el&&(E(X.$el).scrollTop=Math.max(0,I*A(L)))},A=L=>{const I=g(f[L]),X=I==null?void 0:I.$el.querySelector("li");return X&&Number.parseFloat(kl(X,"height"))||0},P=()=>{V(1)},N=()=>{V(-1)},V=L=>{a.value||_("hours");const I=a.value,X=g(h)[I],re=a.value==="hours"?24:60,z=B(I,X,L,re);Y(I,z),M(I,z),ot(()=>_(I))},B=(L,I,X,re)=>{let z=(I+X+re)%re;const ge=g(m)[L];for(;ge[z]&&z!==I;)z=(z+X+re)%re;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),M(L,I))},W=L=>{l=!0,v(L);const I=Math.min(Math.round((E(g(f[L]).$el).scrollTop-(H(L)*.5-10)/A(L)+3)/A(L)),L==="hours"?23:59);Y(L,I)},H=L=>g(f[L]).$el.offsetHeight,F=()=>{const L=I=>{const X=g(f[I]);X&&X.$el&&(E(X.$el).onscroll=()=>{W(I)})};L("hours"),L("minutes"),L("seconds")};Ct(()=>{ot(()=>{!n.arrowControl&&F(),x(),n.role==="start"&&_("hours")})});const U=(L,I)=>{f[I].value=L};return t("set-option",[`${n.role}_scrollDown`,V]),t("set-option",[`${n.role}_emitSelectRange`,_]),Me(()=>n.spinnerDate,()=>{l||x()}),(L,I)=>(C(),T("div",{class:D([g(o).b("spinner"),{"has-seconds":L.showSeconds}])},[L.arrowControl?j("v-if",!0):(C(!0),T(fe,{key:0},nt(g(p),X=>(C(),K(g(ks),{key:X,ref_for:!0,ref:re=>U(re,X),class:D(g(o).be("spinner","wrapper")),"wrap-style":"max-height: inherit;","view-class":g(o).be("spinner","list"),noresize:"",tag:"ul",onMouseenter:re=>_(X),onMousemove:re=>S(X)},{default:$(()=>[(C(!0),T(fe,null,nt(g(m)[X],(re,z)=>(C(),T("li",{key:z,class:D([g(o).be("spinner","item"),g(o).is("active",z===g(h)[X]),g(o).is("disabled",re)]),onClick:ge=>Z(X,{value:z,disabled:re})},[X==="hours"?(C(),T(fe,{key:0},[ne(O(("0"+(L.amPmMode?z%12||12:z)).slice(-2))+O(w(z)),1)],64)):(C(),T(fe,{key:1},[ne(O(("0"+z).slice(-2)),1)],64))],10,ioe))),128))]),_:2},1032,["class","view-class","onMouseenter","onMousemove"]))),128)),L.arrowControl?(C(!0),T(fe,{key:1},nt(g(p),X=>(C(),T("div",{key:X,class:D([g(o).be("spinner","wrapper"),g(o).is("arrow")]),onMouseenter:re=>_(X)},[Fe((C(),K(g(Ne),{class:D(["arrow-up",g(o).be("spinner","arrow")])},{default:$(()=>[k(g(L0))]),_:1},8,["class"])),[[g(Vg),N]]),Fe((C(),K(g(Ne),{class:D(["arrow-down",g(o).be("spinner","arrow")])},{default:$(()=>[k(g($u))]),_:1},8,["class"])),[[g(Vg),P]]),b("ul",{class:D(g(o).be("spinner","list"))},[(C(!0),T(fe,null,nt(g(y)[X],(re,z)=>(C(),T("li",{key:z,class:D([g(o).be("spinner","item"),g(o).is("active",re===g(h)[X]),g(o).is("disabled",g(m)[X][re])])},[typeof re=="number"?(C(),T(fe,{key:0},[X==="hours"?(C(),T(fe,{key:0},[ne(O(("0"+(L.amPmMode?re%12||12:re)).slice(-2))+O(w(re)),1)],64)):(C(),T(fe,{key:1},[ne(O(("0"+re).slice(-2)),1)],64))],64)):j("v-if",!0)],2))),128))],2)],42,loe))),128)):j("v-if",!0)],2))}});var uoe=je(aoe,[["__file","basic-time-spinner.vue"]]);const coe=Q({__name:"panel-time-pick",props:Wne,emits:["pick","select-range","set-picker-option"],setup(e,{emit:t}){const n=e,o=ze("EP_PICKER_BASE"),{arrowControl:r,disabledHours:s,disabledMinutes:i,disabledSeconds:l,defaultValue:a}=o.props,{getAvailableHours:u,getAvailableMinutes:c,getAvailableSeconds:d}=qne(s,i,l),f=Re("time"),{t:p,lang:h}=Kt(),m=q([0,2]),y=Gne(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=U=>{const L=ut(U).locale(h.value),I=Z(L);return L.isSame(I)},x=()=>{t("pick",y.value,!1)},E=(U=!1,L=!1)=>{L||t("pick",n.parsedValue,U)},M=U=>{if(!n.visible)return;const L=Z(U).millisecond(0);t("pick",L,!0)},A=(U,L)=>{t("select-range",U,L),m.value=[U,L]},P=U=>{const L=[0,3].concat(w.value?[6]:[]),I=["hours","minutes"].concat(w.value?["seconds"]:[]),re=(L.indexOf(m.value[0])+U+L.length)%L.length;V.start_emitSelectRange(I[re])},N=U=>{const L=U.code,{left:I,right:X,up:re,down:z}=rt;if([I,X].includes(L)){P(L===I?-1:1),U.preventDefault();return}if([re,z].includes(L)){const ge=L===re?-1:1;V.start_scrollDown(ge),U.preventDefault();return}},{timePickerOptions:V,onSetOption:B,getAvailableTime:Y}=Kne({getAvailableHours:u,getAvailableMinutes:c,getAvailableSeconds:d}),Z=U=>Y(U,n.datetimeRole||"",!0),W=U=>U?ut(U,n.format).locale(h.value):null,H=U=>U?U.format(n.format):null,F=()=>ut(a).locale(h.value);return t("set-picker-option",["isValidValue",S]),t("set-picker-option",["formatToString",H]),t("set-picker-option",["parseUserInput",W]),t("set-picker-option",["handleKeydownInput",N]),t("set-picker-option",["getRangeAvailableTime",Z]),t("set-picker-option",["getDefaultValue",F]),(U,L)=>(C(),K(_r,{name:g(v)},{default:$(()=>[U.actualVisible||U.visible?(C(),T("div",{key:0,class:D(g(f).b("panel"))},[b("div",{class:D([g(f).be("panel","content"),{"has-seconds":g(w)}])},[k(uoe,{ref:"spinner",role:U.datetimeRole||"start","arrow-control":g(r),"show-seconds":g(w),"am-pm-mode":g(_),"spinner-date":U.parsedValue,"disabled-hours":g(s),"disabled-minutes":g(i),"disabled-seconds":g(l),onChange:M,onSetOption:g(B),onSelectRange:A},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},O(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())},O(g(p)("el.datepicker.confirm")),3)],2)],2)):j("v-if",!0)]),_:1},8,["name"]))}});var _b=je(coe,[["__file","panel-time-pick.vue"]]),CM={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)}}})})(CM);var doe=CM.exports;const foe=_o(doe),kM={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}},SM={[Jt]:e=>tt(e)||_t(e)||Br(e),change:e=>tt(e)||_t(e)||Br(e)},$d=Symbol("checkboxGroupContextKey"),poe=({model:e,isChecked:t})=>{const n=ze($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}},hoe=(e,{model:t,isLimitExceeded:n,hasOwnLabel:o,isDisabled:r,isLabeledByFormItem:s})=>{const i=ze($d,void 0),{formItem:l}=ri(),{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 Me(()=>e.modelValue,()=>{p.value&&(l==null||l.validate("change").catch(h=>void 0))}),{handleChange:d,onClickRoot:f}},moe=e=>{const t=q(!1),{emit:n}=at(),o=ze($d,void 0),r=R(()=>Uo(o)===!1),s=q(!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&&Te(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}},goe=(e,t,{model:n})=>{const o=ze($d,void 0),r=q(!1),s=R(()=>Ap(e.value)?e.label:e.value),i=R(()=>{const c=n.value;return Br(c)?c:Te(c)?pt(s.value)?c.map(Mt).some(d=>Hl(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}},$M=(e,t)=>{const{formItem:n}=ri(),{model:o,isGroup:r,isLimitExceeded:s}=moe(e),{isFocused:i,isChecked:l,checkboxButtonSize:a,checkboxSize:u,hasOwnLabel:c,actualValue:d}=goe(e,t,{model:o}),{isDisabled:f}=poe({model:o,isChecked:l}),{inputId:p,isLabeledByFormItem:h}=Sd(e,{formItemContext:n,disableIdGeneration:c,disableIdManagement:r}),{handleChange:m,onClickRoot:y}=hoe(e,{model:o,isLimitExceeded:s,hasOwnLabel:c,isDisabled:f,isLabeledByFormItem:h});return(()=>{function w(){var _,S;Te(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()})(),Ka({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))),Ka({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)),Ka({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}},voe=["id","indeterminate","name","tabindex","disabled","true-value","false-value"],yoe=["id","indeterminate","disabled","value","name","tabindex"],_oe=Q({name:"ElCheckbox"}),boe=Q({..._oe,props:kM,emits:SM,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}=$M(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(),K(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?Fe((C(),T("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]=Je(()=>{},["stop"]))},null,42,voe)),[[su,g(c)]]):Fe((C(),T("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]=Je(()=>{},["stop"]))},null,42,yoe)),[[su,g(c)]]),b("span",{class:D(g(h).e("inner"))},null,2)],2),g(u)?(C(),T("span",{key:0,class:D(g(h).e("label"))},[he(v.$slots,"default"),v.$slots.default?j("v-if",!0):(C(),T(fe,{key:0},[ne(O(v.label),1)],64))],2)):j("v-if",!0)]}),_:3},8,["class","aria-controls","onClick"]))}});var woe=je(boe,[["__file","checkbox.vue"]]);const Coe=["name","tabindex","disabled","true-value","false-value"],koe=["name","tabindex","disabled","value"],Soe=Q({name:"ElCheckboxButton"}),$oe=Q({...Soe,props:kM,emits:SM,setup(e){const t=e,n=Kr(),{isFocused:o,isChecked:r,isDisabled:s,checkboxButtonSize:i,model:l,actualValue:a,handleChange:u}=$M(t,n),c=ze($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(),T("label",{class:D(g(p))},[h.trueValue||h.falseValue||h.trueLabel||h.falseLabel?Fe((C(),T("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]=Je(()=>{},["stop"]))},null,42,Coe)),[[su,g(l)]]):Fe((C(),T("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]=Je(()=>{},["stop"]))},null,42,koe)),[[su,g(l)]]),h.$slots.default||h.label?(C(),T("span",{key:2,class:D(g(d).be("button","inner")),style:et(g(r)?g(f):void 0)},[he(h.$slots,"default",{},()=>[ne(O(h.label),1)])],6)):j("v-if",!0)],2)}}});var EM=je($oe,[["__file","checkbox-button.vue"]]);const Eoe=Ke({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}}),xoe={[Jt]:e=>Te(e),change:e=>Te(e)},Toe=Q({name:"ElCheckboxGroup"}),Moe=Q({...Toe,props:Eoe,emits:xoe,setup(e,{emit:t}){const n=e,o=Re("checkbox"),{formItem:r}=ri(),{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,{...fY(ni(n),["size","min","max","disabled","validateEvent","fill","textColor"]),modelValue:a,changeEvent:l}),Me(()=>n.modelValue,()=>{n.validateEvent&&(r==null||r.validate("change").catch(u=>void 0))}),(u,c)=>{var d;return C(),K(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 xM=je(Moe,[["__file","checkbox-group.vue"]]);const In=Zt(woe,{CheckboxButton:EM,CheckboxGroup:xM});Zn(EM);const Ooe=Zn(xM),TM=Ke({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}}),Ioe=Ke({...TM,border:Boolean}),MM={[Jt]:e=>tt(e)||_t(e)||Br(e),[Cd]:e=>tt(e)||_t(e)||Br(e)},OM=Symbol("radioGroupKey"),IM=(e,t)=>{const n=q(),o=ze(OM,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=q(!1),c=R(()=>a.value||r.value&&i.value!==s.value?-1:0);return Ka({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}},Aoe=["value","name","disabled"],Noe=Q({name:"ElRadio"}),Poe=Q({...Noe,props:Ioe,emits:MM,setup(e,{emit:t}){const n=e,o=Re("radio"),{radioRef:r,radioGroup:s,focus:i,size:l,disabled:a,modelValue:u,actualValue:c}=IM(n,t);function d(){ot(()=>t("change",u.value))}return(f,p)=>{var h;return C(),T("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))])},[Fe(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]=Je(()=>{},["stop"]))},null,42,Aoe),[[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]=Je(()=>{},["stop"]))},[he(f.$slots,"default",{},()=>[ne(O(f.label),1)])],34)],2)}}});var Loe=je(Poe,[["__file","radio.vue"]]);const Roe=Ke({...TM}),Doe=["value","name","disabled"],Voe=Q({name:"ElRadioButton"}),Foe=Q({...Voe,props:Roe,setup(e){const t=e,n=Re("radio"),{radioRef:o,focus:r,size:s,disabled:i,modelValue:l,radioGroup:a,actualValue:u}=IM(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(),T("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))])},[Fe(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]=Je(()=>{},["stop"]))},null,42,Doe),[[Xp,g(l)]]),b("span",{class:D(g(n).be("button","inner")),style:et(g(l)===g(u)?g(c):{}),onKeydown:f[4]||(f[4]=Je(()=>{},["stop"]))},[he(d.$slots,"default",{},()=>[ne(O(d.label),1)])],38)],2)}}});var AM=je(Foe,[["__file","radio-button.vue"]]);const Boe=Ke({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}}),zoe=MM,joe=["id","aria-label","aria-labelledby"],Hoe=Q({name:"ElRadioGroup"}),Uoe=Q({...Hoe,props:Boe,emits:zoe,setup(e,{emit:t}){const n=e,o=Re("radio"),r=Hr(),s=q(),{formItem:i}=ri(),{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(OM,Vn({...ni(n),changeEvent:u,name:c})),Me(()=>n.modelValue,()=>{n.validateEvent&&(i==null||i.validate("change").catch(d=>void 0))}),(d,f)=>(C(),T("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,joe))}});var NM=je(Uoe,[["__file","radio-group.vue"]]);const mh=Zt(Loe,{RadioButton:AM,RadioGroup:NM}),ea=Zn(NM),R3=Zn(AM),PM=Ke({type:{type:String,values:["primary","success","info","warning","danger"],default:"primary"},closable:Boolean,disableTransitions:Boolean,hit:Boolean,color:String,size:{type:String,values:Jl},effect:{type:String,values:["dark","light","plain"],default:"light"},round:Boolean}),Woe={close:e=>e instanceof MouseEvent,click:e=>e instanceof MouseEvent},Koe=Q({name:"ElTag"}),qoe=Q({...Koe,props:PM,emits:Woe,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(),T("span",{key:0,class:D(g(s)),style:et({backgroundColor:a.color}),onClick:l},[b("span",{class:D(g(r).e("content"))},[he(a.$slots,"default")],2),a.closable?(C(),K(g(Ne),{key:0,class:D(g(r).e("close")),onClick:Je(i,["stop"])},{default:$(()=>[k(g(Zs))]),_:1},8,["class","onClick"])):j("v-if",!0)],6)):(C(),K(_r,{key:1,name:`${g(r).namespace.value}-zoom-in-center`,appear:""},{default:$(()=>[b("span",{class:D(g(s)),style:et({backgroundColor:a.color}),onClick:l},[b("span",{class:D(g(r).e("content"))},[he(a.$slots,"default")],2),a.closable?(C(),K(g(Ne),{key:0,class:D(g(r).e("close")),onClick:Je(i,["stop"])},{default:$(()=>[k(g(Zs))]),_:1},8,["class","onClick"])):j("v-if",!0)],6)]),_:3},8,["name"]))}});var Goe=je(qoe,[["__file","tag.vue"]]);const gh=Zt(Goe),LM=Symbol("rowContextKey"),Yoe=["start","center","end","space-around","space-between","space-evenly"],Zoe=["top","middle","bottom"],Joe=Ke({tag:{type:String,default:"div"},gutter:{type:Number,default:0},justify:{type:String,values:Yoe,default:"start"},align:{type:String,values:Zoe}}),Xoe=Q({name:"ElRow"}),Qoe=Q({...Xoe,props:Joe,setup(e){const t=e,n=Re("row"),o=R(()=>t.gutter);wt(LM,{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(),K(Lt(i.tag),{class:D(g(s)),style:et(g(r))},{default:$(()=>[he(i.$slots,"default")]),_:3},8,["class","style"]))}});var ere=je(Qoe,[["__file","row.vue"]]);const vh=Zt(ere),tre=Ke({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:()=>Eo({})},sm:{type:Ce([Number,Object]),default:()=>Eo({})},md:{type:Ce([Number,Object]),default:()=>Eo({})},lg:{type:Ce([Number,Object]),default:()=>Eo({})},xl:{type:Ce([Number,Object]),default:()=>Eo({})}}),nre=Q({name:"ElCol"}),ore=Q({...nre,props:tre,setup(e){const t=e,{gutter:n}=ze(LM,{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]}`)):pt(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(),K(Lt(i.tag),{class:D(g(s)),style:et(g(r))},{default:$(()=>[he(i.$slots,"default")]),_:3},8,["class","style"]))}});var rre=je(ore,[["__file","col.vue"]]);const yh=Zt(rre),sre=Ke({color:{type:Ce(Object),required:!0},vertical:{type:Boolean,default:!1}});let ay=!1;function Vp(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,ay=!1,(i=t.end)==null||i.call(t,s)},r=function(s){var i;ay||(s.preventDefault(),document.onselectstart=()=>!1,document.ondragstart=()=>!1,document.addEventListener("mousemove",n),document.addEventListener("mouseup",o),document.addEventListener("touchmove",n),document.addEventListener("touchend",o),ay=!0,(i=t.start)==null||i.call(t,s))};e.addEventListener("mousedown",r),e.addEventListener("touchstart",r)}const ire=e=>{const t=at(),n=Mn(),o=Mn();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}=Uw(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}},lre=(e,{bar:t,thumb:n,handleDrag:o})=>{const r=at(),s=Re("color-alpha-slider"),i=q(0),l=q(0),a=q();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(_)}};Vp(t.value,w),Vp(n.value,w),f()}),Me(()=>e.color.get("alpha"),()=>f()),Me(()=>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}},are="ElColorAlphaSlider",ure=Q({name:are}),cre=Q({...ure,props:sre,setup(e,{expose:t}){const n=e,{bar:o,thumb:r,handleDrag:s,handleClick:i}=ire(n),{rootKls:l,barKls:a,barStyle:u,thumbKls:c,thumbStyle:d,update:f}=lre(n,{bar:o,thumb:r,handleDrag:s});return t({update:f,bar:o,thumb:r}),(p,h)=>(C(),T("div",{class:D(g(l))},[b("div",{ref_key:"bar",ref:o,class:D(g(a)),style:et(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:et(g(d))},null,6)],2))}});var dre=je(cre,[["__file","alpha-slider.vue"]]);const fre=Q({name:"ElColorHueSlider",props:{color:{type:Object,required:!0},vertical:Boolean},setup(e){const t=Re("color-hue-slider"),n=at(),o=q(),r=q(),s=q(0),i=q(0),l=R(()=>e.color.get("hue"));Me(()=>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}=Uw(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)}};Vp(r.value,p),Vp(o.value,p),f()}),{bar:r,thumb:o,thumbLeft:s,thumbTop:i,hueValue:l,handleClick:a,update:f,ns:t}}});function pre(e,t,n,o,r,s){return C(),T("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:et({left:e.thumbLeft+"px",top:e.thumbTop+"px"})},null,6)],2)}var hre=je(fre,[["render",pre],["__file","hue-slider.vue"]]);const mre=Ke({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}}),gre={[Jt]:e=>tt(e)||To(e),[Cd]:e=>tt(e)||To(e),activeChange:e=>tt(e)||To(e),focus:e=>e instanceof FocusEvent,blur:e=>e instanceof FocusEvent},RM=Symbol("colorPickerContextKey"),d8=function(e,t,n){return[e,t*n/((e=(2-t)*n)<1?e:2-e)||0,e/2]},vre=function(e){return typeof e=="string"&&e.includes(".")&&Number.parseFloat(e)===1},yre=function(e){return typeof e=="string"&&e.includes("%")},$c=function(e,t){vre(e)&&(e="100%");const n=yre(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"},o1=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)?"":`#${o1(e)}${o1(t)}${o1(n)}`},uy={A:10,B:11,C:12,D:13,E:14,F:15},pa=function(e){return e.length===2?(uy[e[0].toUpperCase()]||+e[0])*16+(uy[e[1].toUpperCase()]||+e[1]):uy[e[1].toUpperCase()]||+e[1]},_re=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}=_re(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=pa(o[0]+o[0]),s=pa(o[1]+o[1]),i=pa(o[2]+o[2])):(o.length===6||o.length===8)&&(r=pa(o.slice(0,2)),s=pa(o.slice(2,4)),i=pa(o.slice(4,6))),o.length===8?this._alpha=pa(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))}${o1(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 bre=Q({props:{colors:{type:Array,required:!0},color:{type:Object,required:!0}},setup(e){const t=Re("color-predefine"),{currentColor:n}=ze(RM),o=q(s(e.colors,e.color));Me(()=>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}}}),wre=["onClick"];function Cre(e,t,n,o,r,s){return C(),T("div",{class:D(e.ns.b())},[b("div",{class:D(e.ns.e("colors"))},[(C(!0),T(fe,null,nt(e.rgbaColors,(i,l)=>(C(),T("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:et({backgroundColor:i.value})},null,4)],10,wre))),128))],2)],2)}var kre=je(bre,[["render",Cre],["__file","predefine.vue"]]);const Sre=Q({name:"ElSlPanel",props:{color:{type:Object,required:!0}},setup(e){const t=Re("color-svpanel"),n=at(),o=q(0),r=q(0),s=q("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}=Uw(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 Me(()=>i.value,()=>{l()}),Ct(()=>{Vp(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}}}),$re=b("div",null,null,-1),Ere=[$re];function xre(e,t,n,o,r,s){return C(),T("div",{class:D(e.ns.b()),style:et({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:et({top:e.cursorTop+"px",left:e.cursorLeft+"px"})},Ere,6)],6)}var Tre=je(Sre,[["render",xre],["__file","sv-panel.vue"]]);const Mre=["onKeydown"],Ore=["id","aria-label","aria-labelledby","aria-description","aria-disabled","tabindex"],Ire=Q({name:"ElColorPicker"}),Are=Q({...Ire,props:mre,emits:gre,setup(e,{expose:t,emit:n}){const o=e,{t:r}=Kt(),s=Re("color"),{formItem:i}=ri(),l=Jo(),a=Gr(),{inputId:u,isLabeledByFormItem:c}=Sd(o,{formItemContext:i}),d=q(),f=q(),p=q(),h=q(),m=q(),y=q(),{isFocused:v,handleFocus:w,handleBlur:_}=T3(m,{beforeBlur(le){var Ie;return(Ie=h.value)==null?void 0:Ie.isFocusInsideContent(le)},afterBlur(){H(!1),I()}}),S=le=>{if(a.value)return ve();w(le)};let x=!0;const E=Vn(new Gf({enableAlpha:o.showAlpha,format:o.colorFormat||"",value:o.modelValue})),M=q(!1),A=q(!1),P=q(""),N=R(()=>!o.modelValue&&!A.value?"transparent":W(E,o.showAlpha)),V=R(()=>!o.modelValue&&!A.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 W(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 H(le){M.value=le}const F=jl(H,100,{leading:!0});function U(){a.value||H(!0)}function L(){F(!1),I()}function I(){ot(()=>{o.modelValue?E.fromString(o.modelValue):(E.value="",ot(()=>{A.value=!1}))})}function X(){a.value||F(!M.value)}function re(){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)),F(!1),ot(()=>{const Ie=new Gf({enableAlpha:o.showAlpha,format:o.colorFormat||"",value:o.modelValue});E.compare(Ie)||I()})}function ge(){F(!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(M.value&&(L(),v.value)){const Ie=new FocusEvent("focus",le);_(Ie)}}function xe(le){le.preventDefault(),le.stopPropagation(),H(!1),I()}function ee(le){switch(le.code){case rt.enter:case rt.space:le.preventDefault(),le.stopPropagation(),U(),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=V.value)}),Me(()=>o.modelValue,le=>{le?le&&le!==E.value&&(x=!1,E.fromString(le)):A.value=!1}),Me(()=>V.value,le=>{P.value=le,x&&n("activeChange",le),x=!0}),Me(()=>E.value,()=>{!o.modelValue&&!A.value&&(A.value=!0)}),Me(()=>M.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(RM,{currentColor:V}),t({color:E,show:U,hide:L,focus:de,blur:ve}),(le,Ie)=>(C(),K(g(Eu),{ref_key:"popper",ref:h,visible:M.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=>H(!1))},{content:$(()=>[Fe((C(),T("div",{onKeydown:Pt(xe,["esc"])},[b("div",{class:D(g(s).be("dropdown","main-wrapper"))},[k(hre,{ref_key:"hue",ref:d,class:"hue-slider",color:g(E),vertical:""},null,8,["color"]),k(Tre,{ref_key:"sv",ref:f,color:g(E)},null,8,["color"])],2),le.showAlpha?(C(),K(dre,{key:0,ref_key:"alpha",ref:p,color:g(E)},null,8,["color"])):j("v-if",!0),le.predefine?(C(),K(kre,{key:1,ref:"predefine",color:g(E),colors:le.predefine},null,8,["color","colors"])):j("v-if",!0),b("div",{class:D(g(s).be("dropdown","btns"))},[b("span",{class:D(g(s).be("dropdown","value"))},[k(g(Tt),{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(re,["enter"]),onBlur:re},null,8,["modelValue","onKeyup"])],2),k(g(ct),{class:D(g(s).be("dropdown","link-btn")),text:"",size:"small",onClick:ge},{default:$(()=>[ne(O(g(r)("el.colorpicker.clear")),1)]),_:1},8,["class"]),k(g(ct),{plain:"",size:"small",class:D(g(s).be("dropdown","btn")),onClick:z},{default:$(()=>[ne(O(g(r)("el.colorpicker.confirm")),1)]),_:1},8,["class"])],2)],40,Mre)),[[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(),T("div",{key:0,class:D(g(s).be("picker","mask"))},null,2)):j("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:et({backgroundColor:g(N)})},[Fe(k(g(Ne),{class:D([g(s).be("picker","icon"),g(s).is("icon-arrow-down")])},{default:$(()=>[k(g($u))]),_:1},8,["class"]),[[en,le.modelValue||A.value]]),Fe(k(g(Ne),{class:D([g(s).be("picker","empty"),g(s).is("icon-close")])},{default:$(()=>[k(g(Zs))]),_:1},8,["class"]),[[en,!le.modelValue&&!A.value]])],6)],2)],2)],42,Ore)]),_:1},8,["visible","popper-class","transition"]))}});var Nre=je(Are,[["__file","color-picker.vue"]]);const D3=Zt(Nre),Pre=Q({name:"ElContainer"}),Lre=Q({...Pre,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(),T("section",{class:D([g(o).b(),g(o).is("vertical",g(r))])},[he(s.$slots,"default")],2))}});var Rre=je(Lre,[["__file","container.vue"]]);const Dre=Q({name:"ElAside"}),Vre=Q({...Dre,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(),T("aside",{class:D(g(n).b()),style:et(g(o))},[he(r.$slots,"default")],6))}});var DM=je(Vre,[["__file","aside.vue"]]);const Fre=Q({name:"ElFooter"}),Bre=Q({...Fre,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(),T("footer",{class:D(g(n).b()),style:et(g(o))},[he(r.$slots,"default")],6))}});var VM=je(Bre,[["__file","footer.vue"]]);const zre=Q({name:"ElHeader"}),jre=Q({...zre,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(),T("header",{class:D(g(n).b()),style:et(g(o))},[he(r.$slots,"default")],6))}});var FM=je(jre,[["__file","header.vue"]]);const Hre=Q({name:"ElMain"}),Ure=Q({...Hre,setup(e){const t=Re("main");return(n,o)=>(C(),T("main",{class:D(g(t).b())},[he(n.$slots,"default")],2))}});var BM=je(Ure,[["__file","main.vue"]]);const zM=Zt(Rre,{Aside:DM,Footer:VM,Header:FM,Main:BM}),jM=Zn(DM);Zn(VM);const HM=Zn(FM),K0=Zn(BM);var UM={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)}}})})(UM);var Wre=UM.exports;const Kre=_o(Wre);var WM={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)}}})})(WM);var qre=WM.exports;const Gre=_o(qre);var KM={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}}})})(KM);var Yre=KM.exports;const Zre=_o(Yre);var qM={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")}}})})(qM);var Jre=qM.exports;const Xre=_o(Jre);var GM={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)}}})})(GM);var Qre=GM.exports;const ese=_o(Qre);var YM={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)}}})})(YM);var tse=YM.exports;const nse=_o(tse),V3=Symbol(),ose=Ke({...pM,type:{type:Ce(String),default:"date"}}),rse=["date","dates","year","years","month","week","range"],F3=Ke({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})}}),ZM=Ke({type:{type:Ce(String),required:!0,values:bJ},dateFormat:String,timeFormat:String}),JM=Ke({unlinkPanels:Boolean,parsedValue:{type:Ce(Array)}}),B3=e=>({type:String,values:rse,default:e}),sse=Ke({...ZM,parsedValue:{type:Ce([Object,Array])},visible:{type:Boolean},format:{type:String,default:""}}),ise=Ke({...F3,cellClassName:{type:Ce(Function)},showWeekNumber:Boolean,selectionMode:B3("date")}),lse=["changerange","pick","select"],bb=e=>{if(!Te(e))return!1;const[t,n]=e;return ut.isDayjs(t)&&ut.isDayjs(n)&&t.isSameOrBefore(n)},XM=(e,{lang:t,unit:n,unlinkPanels:o})=>{let r;if(Te(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)]},ase=(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)}},wb=(e="")=>["normal","today"].includes(e),use=(e,t)=>{const{lang:n}=Kt(),o=q(),r=q(),s=q(),i=q(),l=q([[],[],[],[],[],[]]);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(),re=L.subtract(1,"month").daysInMonth();return{startOfMonthDay:I,dateCountOfMonth:X,dateCountOfLastMonth:re}}),y=R(()=>e.selectionMode==="dates"?ns(e.parsedValue):[]),v=(L,{count:I,rowIndex:X,columnIndex:re})=>{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(re+X*7>=ee)return L.text=I,!0;L.text=Oe-(ee-re%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},re)=>{const{disabledDate:z,cellClassName:ge}=e,Oe=g(y),xe=v(L,{count:re,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],re=U(L[I+1]);L[I].inRange=re,L[I].start=re,L[X].inRange=re,L[X].end=re}},S=R(()=>{const{minDate:L,maxDate:I,rangeState:X,showWeekNumber:re}=e,z=g(d),ge=g(l),Oe="day";let xe=1;if(re)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 ase({row:6,column:7},ge,{startDate:L,columnIndexOffset:re?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});Me(()=>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"&&wb(L.type)&&M(L,e.parsedValue),M=(L,I)=>I?ut(I).locale(g(n)).isSame(e.date.date(Number(L.text)),"day"):!1,A=(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 re=X.parentNode.rowIndex-1,z=X.cellIndex;g(S)[re][z].disabled||(re!==g(s)||z!==g(i))&&(s.value=re,i.value=z,t("changerange",{selecting:!0,endDate:A(re,z)}))},N=L=>!g(h)&&(L==null?void 0:L.text)===1&&L.type==="normal"||L.isCurrent,V=L=>{a||g(h)||e.selectionMode!=="date"||F(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))},W=L=>{const I=L.week(),X=`${L.year()}w${I}`;t("pick",{year:L.year(),week:I,value:X,date:L.startOf("week")})},H=(L,I)=>{const X=I?ns(e.parsedValue).filter(re=>(re==null?void 0:re.valueOf())!==L.valueOf()):ns(e.parsedValue).concat([L]);t("pick",X)},F=(L,I=!1)=>{const X=L.target.closest("td");if(!X)return;const re=X.parentNode.rowIndex-1,z=X.cellIndex,ge=g(S)[re][z];if(ge.disabled||ge.type==="week")return;const Oe=A(re,z);switch(e.selectionMode){case"range":{Z(Oe);break}case"date":{t("pick",Oe,I);break}case"week":{W(Oe);break}case"dates":{H(Oe,!!ge.selected);break}}},U=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:U,isSelectedCell:N,handlePickDate:F,handleMouseUp:Y,handleMouseDown:B,handleMouseMove:P,handleFocus:V}},cse=(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 wb(c.type)&&!c.disabled?(d.push("available"),c.type==="today"&&d.push("today")):d.push(c.type),t(c)&&d.push("current"),c.inRange&&(wb(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}},dse=Ke({cell:{type:Ce(Object)}});var fse=Q({name:"ElDatePickerCell",props:dse,setup(e){const t=Re("date-table-cell"),{slots:n}=ze(V3);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 pse=["aria-label"],hse={key:0,scope:"col"},mse=["aria-label"],gse=["aria-current","aria-selected","tabindex"],vse=Q({__name:"basic-date-table",props:ise,emits:lse,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}=use(o,n),{tableLabel:v,tableKls:w,weekLabel:_,getCellClasses:S,getRowKls:x,t:E}=cse(o,{isCurrent:u,isWeekActive:c});return t({focus:a}),(M,A)=>(C(),T("table",{"aria-label":g(v),class:D(g(w)),cellspacing:"0",cellpadding:"0",role:"grid",onClick:A[1]||(A[1]=(...P)=>g(f)&&g(f)(...P)),onMousemove:A[2]||(A[2]=(...P)=>g(m)&&g(m)(...P)),onMousedown:A[3]||(A[3]=Je((...P)=>g(h)&&g(h)(...P),["prevent"])),onMouseup:A[4]||(A[4]=(...P)=>g(p)&&g(p)(...P))},[b("tbody",{ref_key:"tbodyRef",ref:i},[b("tr",null,[M.showWeekNumber?(C(),T("th",hse,O(g(_)),1)):j("v-if",!0),(C(!0),T(fe,null,nt(g(r),(P,N)=>(C(),T("th",{key:N,"aria-label":g(E)("el.datepicker.weeksFull."+P),scope:"col"},O(g(E)("el.datepicker.weeks."+P)),9,mse))),128))]),(C(!0),T(fe,null,nt(g(s),(P,N)=>(C(),T("tr",{key:N,class:D(g(x)(P[1]))},[(C(!0),T(fe,null,nt(P,(V,B)=>(C(),T("td",{key:`${N}.${B}`,ref_for:!0,ref:Y=>g(d)(V)&&(l.value=Y),class:D(g(S)(V)),"aria-current":V.isCurrent?"date":void 0,"aria-selected":V.isCurrent,tabindex:g(d)(V)?0:-1,onFocus:A[0]||(A[0]=(...Y)=>g(y)&&g(y)(...Y))},[k(g(fse),{cell:V},null,8,["cell"])],42,gse))),128))],2))),128))],512)],42,pse))}});var Cb=je(vse,[["__file","basic-date-table.vue"]]);const yse=Ke({...F3,selectionMode:B3("month")}),_se=["aria-label"],bse=["aria-selected","aria-label","tabindex","onKeydown"],wse={class:"cell"},Cse=Q({__name:"basic-month-table",props:yse,emits:["changerange","pick","select"],setup(e,{expose:t,emit:n}){const o=e,r=(S,x,E)=>{const M=ut().locale(E).startOf("month").month(x).year(S),A=M.daysInMonth();return uM(A).map(P=>M.add(P,"day").toDate())},s=Re("month-table"),{t:i,lang:l}=Kt(),a=q(),u=q(),c=q(o.date.locale("en").localeData().monthsShort().map(S=>S.toLowerCase())),d=q([[],[],[]]),f=q(),p=q(),h=R(()=>{var S,x;const E=d.value,M=ut().locale(l.value).startOf("month");for(let A=0;A<3;A++){const P=E[A];for(let N=0;N<4;N++){const V=P[N]||(P[N]={row:A,column:N,type:"normal",inRange:!1,start:!1,end:!1,text:-1,disabled:!1});V.type="normal";const B=A*4+N,Y=o.date.startOf("year").month(B),Z=o.rangeState.endDate||o.maxDate||o.rangeState.selecting&&o.minDate||null;V.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)?(V.start=!!(Z&&Y.isSame(Z,"month")),V.end=o.minDate&&Y.isSame(o.minDate,"month")):(V.start=!!(o.minDate&&Y.isSame(o.minDate,"month")),V.end=!!(Z&&Y.isSame(Z,"month"))),M.isSame(Y)&&(V.type="today"),V.text=B,V.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(),M=new Date,A=S.text;return x.disabled=o.disabledDate?r(E,A,l.value).every(o.disabledDate):!1,x.current=ns(o.parsedValue).findIndex(P=>ut.isDayjs(P)&&P.year()===E&&P.month()===A)>=0,x.today=M.getFullYear()===E&&M.getMonth()===A,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(M=>M.year()===x&&M.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 M=E.parentNode.rowIndex,A=E.cellIndex;h.value[M][A].disabled||(M!==f.value||A!==p.value)&&(f.value=M,p.value=A,n("changerange",{selecting:!0,endDate:o.date.startOf("year").month(M*4+A)}))},_=S=>{var x;const E=(x=S.target)==null?void 0:x.closest("td");if((E==null?void 0:E.tagName)!=="TD"||Mi(E,"disabled"))return;const M=E.cellIndex,P=E.parentNode.rowIndex*4+M,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 Me(()=>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(),T("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),T(fe,null,nt(g(h),(E,M)=>(C(),T("tr",{key:M},[(C(!0),T(fe,null,nt(E,(A,P)=>(C(),T("td",{key:P,ref_for:!0,ref:N=>v(A)&&(u.value=N),class:D(y(A)),"aria-selected":`${v(A)}`,"aria-label":g(i)(`el.datepicker.month${+A.text+1}`),tabindex:v(A)?0:-1,onKeydown:[Pt(Je(_,["prevent","stop"]),["space"]),Pt(Je(_,["prevent","stop"]),["enter"])]},[b("div",null,[b("span",wse,O(g(i)("el.datepicker.months."+c.value[A.text])),1)])],42,bse))),128))]))),128))],512)],42,_se))}});var kb=je(Cse,[["__file","basic-month-table.vue"]]);const{date:kse,disabledDate:Sse,parsedValue:$se}=F3,Ese=Ke({date:kse,disabledDate:Sse,parsedValue:$se,selectionMode:B3("year")}),xse=["aria-label"],Tse=["aria-selected","tabindex","onKeydown"],Mse={class:"cell"},Ose={key:1},Ise=Q({__name:"basic-year-table",props:Ese,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 uM(_).map(S=>v.add(S,"day").toDate())},s=Re("year-table"),{t:i,lang:l}=Kt(),a=q(),u=q(),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(Mi(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 _=Mi(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 Me(()=>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(),T("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(),T(fe,null,nt(3,(v,w)=>b("tr",{key:w},[(C(),T(fe,null,nt(4,(_,S)=>(C(),T(fe,{key:w+"_"+S},[w*4+S<10?(C(),T("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(Je(h,["prevent","stop"]),["space"]),Pt(Je(h,["prevent","stop"]),["enter"])]},[b("div",null,[b("span",Mse,O(g(c)+w*4+S),1)])],42,Tse)):(C(),T("td",Ose))],64))),64))])),64))],512)],10,xse))}});var Ase=je(Ise,[["__file","basic-year-table.vue"]]);const Nse=["onClick"],Pse=["aria-label"],Lse=["aria-label"],Rse=["aria-label"],Dse=["aria-label"],Vse=Q({__name:"panel-date-pick",props:sse,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=ze("EP_PICKER_BASE"),d=ze(W0),{shortcuts:f,disabledDate:p,cellClassName:h,defaultTime:m}=c.props,y=pn(c.props,"defaultValue"),v=q(),w=q(ut().locale(u.value)),_=q(!1);let S=!1;const x=R(()=>ut(m).locale(u.value)),E=R(()=>w.value.month()),M=R(()=>w.value.year()),A=q([]),P=q(null),N=q(null),V=ie=>A.value.length>0?o(ie,A.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(Te(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;V(ae)||(ae=A.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)},W=ie=>{const we=ie?"add":"subtract";w.value=w.value[we](1,"month"),$e("month")},H=ie=>{const we=w.value,ae=ie?"add":"subtract";w.value=F.value==="year"?we[ae](10,"year"):we[ae](1,"year"),$e("year")},F=q("date"),U=R(()=>{const ie=a("el.datepicker.year");if(F.value==="year"){const we=Math.floor(M.value/10)*10;return ie?`${we} ${ie} - ${we+9} ${ie}`:`${we} - ${we+9}`}return`${M.value} ${ie}`}),L=ie=>{const we=Qe(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"?F.value:I.value),re=R(()=>!!f.length),z=async ie=>{w.value=w.value.startOf("month").month(ie),I.value==="month"?Y(w.value,!1):(F.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),F.value="month",["month","year","date","week"].includes(I.value)&&(Y(w.value,!0),await ot(),pe())),$e("year")},Oe=async ie=>{F.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=F.value==="date",Se=F.value==="year";return ie&&ae||we&&Se}),de=R(()=>p?n.parsedValue?Te(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))&&V(we)&&(w.value=ut().locale(u.value),Y(w.value))},Ge=R(()=>n.timeFormat||dM(n.format)),G=R(()=>n.dateFormat||cM(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=q(!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:Ve,second:st}=Le(ie),se=n.parsedValue?n.parsedValue.hour(Se).minute(Ve).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()&&V(we)){const{year:ae,month:Se,date:Ve}=Le(w.value);w.value=we.year(ae).month(Se).date(Ve),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:Ve}=Le(w.value);w.value=we.hour(ae).minute(Se).second(Ve),P.value=null,Y(w.value,!0)}},He=ie=>ut.isDayjs(ie)&&ie.isValid()&&(p?!p(ie.toDate()):!0),Ze=ie=>Te(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"&&Xe(rt.down))},Be=ie=>{const{code:we}=ie;[rt.up,rt.down,rt.left,rt.right,rt.home,rt.end,rt.pageUp,rt.pageDown].includes(we)&&(Xe(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))},Xe=ie=>{var we;const{up:ae,down:Se,left:Ve,right:st,home:se,end:De,pageUp:It,pageDown:mn}=rt,Kn={year:{[ae]:-4,[Se]:4,[Ve]:-1,[st]:1,offset:(qt,nr)=>qt.setFullYear(qt.getFullYear()+nr)},month:{[ae]:-4,[Se]:4,[Ve]:-1,[st]:1,offset:(qt,nr)=>qt.setMonth(qt.getMonth()+nr)},week:{[ae]:-1,[Se]:1,[Ve]:-1,[st]:1,offset:(qt,nr)=>qt.setDate(qt.getDate()+nr*7)},date:{[ae]:-7,[Se]:7,[Ve]:-1,[st]:1,[se]:qt=>-qt.getDay(),[De]:qt=>-qt.getDay()+6,[It]: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=Kn[X.value];if(!qt)return;if(qt.offset(Zr,Qe(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,F.value)};return Me(()=>I.value,ie=>{if(["month","year"].includes(ie)){F.value=ie;return}else if(ie==="years"){F.value="year";return}F.value="date"},{immediate:!0}),Me(()=>F.value,()=>{d==null||d.updatePopper()}),Me(()=>y.value,ie=>{ie&&(w.value=te())},{immediate:!0}),Me(()=>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",He]),t("set-picker-option",["formatToString",Ze]),t("set-picker-option",["parseUserInput",ce]),t("set-picker-option",["handleFocusPicker",pe]),(ie,we)=>(C(),T("div",{class:D([g(r).b(),g(s).b(),{"has-sidebar":ie.$slots.sidebar||g(re),"has-time":g(xe)}])},[b("div",{class:D(g(r).e("body-wrapper"))},[he(ie.$slots,"sidebar",{class:D(g(r).e("sidebar"))}),g(re)?(C(),T("div",{key:0,class:D(g(r).e("sidebar"))},[(C(!0),T(fe,null,nt(g(f),(ae,Se)=>(C(),T("button",{key:Se,type:"button",class:D(g(r).e("shortcut")),onClick:Ve=>L(ae)},O(ae.text),11,Nse))),128))],2)):j("v-if",!0),b("div",{class:D(g(r).e("body"))},[g(xe)?(C(),T("div",{key:0,class:D(g(s).e("time-header"))},[b("span",{class:D(g(s).e("editor-wrap"))},[k(g(Tt),{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),Fe((C(),T("span",{class:D(g(s).e("editor-wrap"))},[k(g(Tt),{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(_b),{visible:_e.value,format:g(Ge),"parsed-value":w.value,onPick:Ee},null,8,["visible","format","parsed-value"])],2)),[[g(id),Ae]])],2)):j("v-if",!0),Fe(b("div",{class:D([g(s).e("header"),(F.value==="year"||F.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=>H(!1))},[k(g(Ne),null,{default:$(()=>[k(g(Jc))]),_:1})],10,Pse),Fe(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=>W(!1))},[k(g(Ne),null,{default:$(()=>[k(g(uu))]),_:1})],10,Lse),[[en,F.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"))},O(g(U)),35),Fe(b("span",{role:"button","aria-live":"polite",tabindex:"0",class:D([g(s).e("header-label"),{active:F.value==="month"}]),onKeydown:we[6]||(we[6]=Pt(ae=>Oe("month"),["enter"])),onClick:we[7]||(we[7]=ae=>Oe("month"))},O(g(a)(`el.datepicker.month${g(E)+1}`)),35),[[en,F.value==="date"]]),b("span",{class:D(g(s).e("next-btn"))},[Fe(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=>W(!0))},[k(g(Ne),null,{default:$(()=>[k(g(Us))]),_:1})],10,Rse),[[en,F.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=>H(!0))},[k(g(Ne),null,{default:$(()=>[k(g(Xc))]),_:1})],10,Dse)],2)],2),[[en,F.value!=="time"]]),b("div",{class:D(g(r).e("content")),onKeydown:Be},[F.value==="date"?(C(),K(Cb,{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"])):j("v-if",!0),F.value==="year"?(C(),K(Ase,{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"])):j("v-if",!0),F.value==="month"?(C(),K(kb,{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"])):j("v-if",!0)],34)],2)],2),Fe(b("div",{class:D(g(r).e("footer"))},[Fe(k(g(ct),{text:"",size:"small",class:D(g(r).e("link-btn")),disabled:g(le),onClick:Ie},{default:$(()=>[ne(O(g(a)("el.datepicker.now")),1)]),_:1},8,["class","disabled"]),[[en,g(I)!=="dates"&&g(I)!=="years"]]),k(g(ct),{plain:"",size:"small",class:D(g(r).e("link-btn")),disabled:g(de),onClick:ve},{default:$(()=>[ne(O(g(a)("el.datepicker.confirm")),1)]),_:1},8,["class","disabled"])],2),[[en,g(ee)]])],2))}});var Fse=je(Vse,[["__file","panel-date-pick.vue"]]);const Bse=Ke({...ZM,...JM}),zse=e=>{const{emit:t}=at(),n=_d(),o=Kr();return s=>{const i=Qe(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})}},QM=(e,{defaultValue:t,leftDate:n,rightDate:o,unit:r,onParsedValueChanged:s})=>{const{emit:i}=at(),{pickerNs:l}=ze(V3),a=Re("date-range-picker"),{t:u,lang:c}=Kt(),d=zse(c),f=q(),p=q(),h=q({endDate:null,selecting:!1}),m=_=>{h.value=_},y=(_=!1)=>{const S=g(f),x=g(p);bb([S,x])&&i("pick",[S,x],_)},v=_=>{h.value.selecting=_,_||(h.value.endDate=null)},w=()=>{const[_,S]=XM(g(t),{lang:g(c),unit:r,unlinkPanels:e.unlinkPanels});f.value=void 0,p.value=void 0,n.value=_,o.value=S};return Me(t,_=>{_&&w()},{immediate:!0}),Me(()=>e.parsedValue,_=>{if(Te(_)&&_.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}},jse=["onClick"],Hse=["aria-label"],Use=["aria-label"],Wse=["disabled","aria-label"],Kse=["disabled","aria-label"],qse=["disabled","aria-label"],Gse=["disabled","aria-label"],Yse=["aria-label"],Zse=["aria-label"],_m="month",Jse=Q({__name:"panel-date-range",props:Bse,emits:["pick","set-picker-option","calendar-change","panel-change"],setup(e,{emit:t}){const n=e,o=ze("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=q(ut().locale(d.value)),p=q(ut().locale(d.value).add(1,_m)),{minDate:h,maxDate:m,rangeState:y,ppNs:v,drpNs:w,handleChangeRange:_,handleRangeConfirm:S,handleShortcutClick:x,onSelect:E,t:M}=QM(n,{defaultValue:c,leftDate:f,rightDate:p,unit:_m,onParsedValueChanged:we}),A=q({min:null,max:null}),P=q({min:null,max:null}),N=R(()=>`${f.value.year()} ${M("el.datepicker.year")} ${M(`el.datepicker.month${f.value.month()+1}`)}`),V=R(()=>`${p.value.year()} ${M("el.datepicker.year")} ${M(`el.datepicker.month${p.value.month()+1}`)}`),B=R(()=>f.value.year()),Y=R(()=>f.value.month()),Z=R(()=>p.value.year()),W=R(()=>p.value.month()),H=R(()=>!!u.value.length),F=R(()=>A.value.min!==null?A.value.min:h.value?h.value.format(re.value):""),U=R(()=>A.value.max!==null?A.value.max:m.value||h.value?(m.value||h.value).format(re.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||dM(i)),re=R(()=>n.dateFormat||cM(i)),z=ae=>bb(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,W.value)}),J=R(()=>n.unlinkPanels&&Z.value*12+W.value-(B.value*12+Y.value+1)>=12),ue=R(()=>!(h.value&&m.value&&!y.value.selecting&&bb([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 Ve=ae.minDate,st=ae.maxDate,se=ye(Ve,0),De=ye(st,1);m.value===De&&h.value===se||(t("calendar-change",[Ve.toDate(),st&&st.toDate()]),m.value=De,h.value=se,!(!Se||_e.value)&&S())},Le=q(!1),Ee=q(!1),Pe=()=>{Le.value=!1},me=()=>{Ee.value=!1},He=(ae,Se)=>{A.value[Se]=ae;const Ve=ut(ae,re.value).locale(d.value);if(Ve.isValid()){if(r&&r(Ve.toDate()))return;Se==="min"?(f.value=Ve,h.value=(h.value||f.value).year(Ve.year()).month(Ve.month()).date(Ve.date()),!n.unlinkPanels&&(!m.value||m.value.isBefore(h.value))&&(p.value=Ve.add(1,"month"),m.value=h.value.add(1,"month"))):(p.value=Ve,m.value=(m.value||p.value).year(Ve.year()).month(Ve.month()).date(Ve.date()),!n.unlinkPanels&&(!h.value||h.value.isAfter(m.value))&&(f.value=Ve.subtract(1,"month"),h.value=m.value.subtract(1,"month")))}},Ze=(ae,Se)=>{A.value[Se]=null},ce=(ae,Se)=>{P.value[Se]=ae;const Ve=ut(ae,X.value).locale(d.value);Ve.isValid()&&(Se==="min"?(Le.value=!0,h.value=(h.value||f.value).hour(Ve.hour()).minute(Ve.minute()).second(Ve.second()),(!m.value||m.value.isBefore(h.value))&&(m.value=h.value)):(Ee.value=!0,m.value=(m.value||p.value).hour(Ve.hour()).minute(Ve.minute()).second(Ve.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,Ve)=>{P.value.min||(ae&&(f.value=ae,h.value=(h.value||f.value).hour(ae.hour()).minute(ae.minute()).second(ae.second())),Ve||(Le.value=Se),(!m.value||m.value.isBefore(h.value))&&(m.value=h.value,p.value=ae))},Be=(ae,Se,Ve)=>{P.value.max||(ae&&(p.value=ae,m.value=(m.value||p.value).hour(ae.hour()).minute(ae.minute()).second(ae.second())),Ve||(Ee.value=Se),m.value&&m.value.isBefore(h.value)&&(h.value=m.value))},Xe=()=>{f.value=XM(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=>Te(ae)?ae.map(Se=>Se.format(i)):ae.format(i),ie=ae=>Te(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 Ve=(ae==null?void 0:ae.year())||0,st=(ae==null?void 0:ae.month())||0,se=Se.year(),De=Se.month();p.value=Ve===se&&st===De?Se.add(1,_m):Se}else p.value=f.value.add(1,_m),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",Xe]),(ae,Se)=>(C(),T("div",{class:D([g(v).b(),g(w).b(),{"has-sidebar":ae.$slots.sidebar||g(H),"has-time":g(_e)}])},[b("div",{class:D(g(v).e("body-wrapper"))},[he(ae.$slots,"sidebar",{class:D(g(v).e("sidebar"))}),g(H)?(C(),T("div",{key:0,class:D(g(v).e("sidebar"))},[(C(!0),T(fe,null,nt(g(u),(Ve,st)=>(C(),T("button",{key:st,type:"button",class:D(g(v).e("shortcut")),onClick:se=>g(x)(Ve)},O(Ve.text),11,jse))),128))],2)):j("v-if",!0),b("div",{class:D(g(v).e("body"))},[g(_e)?(C(),T("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(Tt),{size:"small",disabled:g(y).selecting,placeholder:g(M)("el.datepicker.startDate"),class:D(g(w).e("editor")),"model-value":g(F),"validate-event":!1,onInput:Se[0]||(Se[0]=Ve=>He(Ve,"min")),onChange:Se[1]||(Se[1]=Ve=>Ze(Ve,"min"))},null,8,["disabled","placeholder","class","model-value"])],2),Fe((C(),T("span",{class:D(g(w).e("time-picker-wrap"))},[k(g(Tt),{size:"small",class:D(g(w).e("editor")),disabled:g(y).selecting,placeholder:g(M)("el.datepicker.startTime"),"model-value":g(L),"validate-event":!1,onFocus:Se[2]||(Se[2]=Ve=>Le.value=!0),onInput:Se[3]||(Se[3]=Ve=>ce(Ve,"min")),onChange:Se[4]||(Se[4]=Ve=>te(Ve,"min"))},null,8,["class","disabled","placeholder","model-value"]),k(g(_b),{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(Us))]),_:1})]),b("span",{class:D([g(w).e("editors-wrap"),"is-right"])},[b("span",{class:D(g(w).e("time-picker-wrap"))},[k(g(Tt),{size:"small",class:D(g(w).e("editor")),disabled:g(y).selecting,placeholder:g(M)("el.datepicker.endDate"),"model-value":g(U),readonly:!g(h),"validate-event":!1,onInput:Se[5]||(Se[5]=Ve=>He(Ve,"max")),onChange:Se[6]||(Se[6]=Ve=>Ze(Ve,"max"))},null,8,["class","disabled","placeholder","model-value","readonly"])],2),Fe((C(),T("span",{class:D(g(w).e("time-picker-wrap"))},[k(g(Tt),{size:"small",class:D(g(w).e("editor")),disabled:g(y).selecting,placeholder:g(M)("el.datepicker.endTime"),"model-value":g(I),readonly:!g(h),"validate-event":!1,onFocus:Se[7]||(Se[7]=Ve=>g(h)&&(Ee.value=!0)),onInput:Se[8]||(Se[8]=Ve=>ce(Ve,"max")),onChange:Se[9]||(Se[9]=Ve=>te(Ve,"max"))},null,8,["class","disabled","placeholder","model-value","readonly"]),k(g(_b),{"datetime-role":"end",visible:Ee.value,format:g(X),"parsed-value":p.value,onPick:Be},null,8,["visible","format","parsed-value"])],2)),[[g(id),me]])],2)],2)):j("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(M)("el.datepicker.prevYear"),onClick:ge},[k(g(Ne),null,{default:$(()=>[k(g(Jc))]),_:1})],10,Hse),b("button",{type:"button",class:D([g(v).e("icon-btn"),"arrow-left"]),"aria-label":g(M)("el.datepicker.prevMonth"),onClick:Oe},[k(g(Ne),null,{default:$(()=>[k(g(uu))]),_:1})],10,Use),ae.unlinkPanels?(C(),T("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(M)("el.datepicker.nextYear"),onClick:de},[k(g(Ne),null,{default:$(()=>[k(g(Xc))]),_:1})],10,Wse)):j("v-if",!0),ae.unlinkPanels?(C(),T("button",{key:1,type:"button",disabled:!g(G),class:D([[g(v).e("icon-btn"),{"is-disabled":!g(G)}],"arrow-right"]),"aria-label":g(M)("el.datepicker.nextMonth"),onClick:ve},[k(g(Ne),null,{default:$(()=>[k(g(Us))]),_:1})],10,Kse)):j("v-if",!0),b("div",null,O(g(N)),1)],2),k(Cb,{"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(),T("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(M)("el.datepicker.prevYear"),onClick:le},[k(g(Ne),null,{default:$(()=>[k(g(Jc))]),_:1})],10,qse)):j("v-if",!0),ae.unlinkPanels?(C(),T("button",{key:1,type:"button",disabled:!g(G),class:D([[g(v).e("icon-btn"),{"is-disabled":!g(G)}],"arrow-left"]),"aria-label":g(M)("el.datepicker.prevMonth"),onClick:Ie},[k(g(Ne),null,{default:$(()=>[k(g(uu))]),_:1})],10,Gse)):j("v-if",!0),b("button",{type:"button","aria-label":g(M)("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,Yse),b("button",{type:"button",class:D([g(v).e("icon-btn"),"arrow-right"]),"aria-label":g(M)("el.datepicker.nextMonth"),onClick:ee},[k(g(Ne),null,{default:$(()=>[k(g(Us))]),_:1})],10,Zse),b("div",null,O(g(V)),1)],2),k(Cb,{"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(),T("div",{key:0,class:D(g(v).e("footer"))},[g(a)?(C(),K(g(ct),{key:0,text:"",size:"small",class:D(g(v).e("link-btn")),onClick:Xe},{default:$(()=>[ne(O(g(M)("el.datepicker.clear")),1)]),_:1},8,["class"])):j("v-if",!0),k(g(ct),{plain:"",size:"small",class:D(g(v).e("link-btn")),disabled:g(ue),onClick:Se[10]||(Se[10]=Ve=>g(S)(!1))},{default:$(()=>[ne(O(g(M)("el.datepicker.confirm")),1)]),_:1},8,["class","disabled"])],2)):j("v-if",!0)],2))}});var Xse=je(Jse,[["__file","panel-date-range.vue"]]);const Qse=Ke({...JM}),eie=["pick","set-picker-option","calendar-change"],tie=({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}},nie=["onClick"],oie=["disabled"],rie=["disabled"],bm="year",sie=Q({name:"DatePickerMonthRange"}),iie=Q({...sie,props:Qse,emits:eie,setup(e,{emit:t}){const n=e,{lang:o}=Kt(),r=ze("EP_PICKER_BASE"),{shortcuts:s,disabledDate:i,format:l}=r.props,a=pn(r.props,"defaultValue"),u=q(ut().locale(o.value)),c=q(ut().locale(o.value).add(1,bm)),{minDate:d,maxDate:f,rangeState:p,ppNs:h,drpNs:m,handleChangeRange:y,handleRangeConfirm:v,handleShortcutClick:w,onSelect:_}=QM(n,{defaultValue:a,leftDate:u,rightDate:c,unit:bm,onParsedValueChanged:H}),S=R(()=>!!s.length),{leftPrevYear:x,rightNextYear:E,leftNextYear:M,rightPrevYear:A,leftLabel:P,rightLabel:N,leftYear:V,rightYear:B}=tie({unlinkPanels:pn(n,"unlinkPanels"),leftDate:u,rightDate:c}),Y=R(()=>n.unlinkPanels&&B.value>V.value+1),Z=(F,U=!0)=>{const L=F.minDate,I=F.maxDate;f.value===I&&d.value===L||(t("calendar-change",[L.toDate(),I&&I.toDate()]),f.value=I,d.value=L,U&&v())},W=F=>F.map(U=>U.format(l));function H(F,U){if(n.unlinkPanels&&U){const L=(F==null?void 0:F.year())||0,I=U.year();c.value=L===I?U.add(1,bm):U}else c.value=u.value.add(1,bm)}return t("set-picker-option",["formatToString",W]),(F,U)=>(C(),T("div",{class:D([g(h).b(),g(m).b(),{"has-sidebar":!!F.$slots.sidebar||g(S)}])},[b("div",{class:D(g(h).e("body-wrapper"))},[he(F.$slots,"sidebar",{class:D(g(h).e("sidebar"))}),g(S)?(C(),T("div",{key:0,class:D(g(h).e("sidebar"))},[(C(!0),T(fe,null,nt(g(s),(L,I)=>(C(),T("button",{key:I,type:"button",class:D(g(h).e("shortcut")),onClick:X=>g(w)(L)},O(L.text),11,nie))),128))],2)):j("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:U[0]||(U[0]=(...L)=>g(x)&&g(x)(...L))},[k(g(Ne),null,{default:$(()=>[k(g(Jc))]),_:1})],2),F.unlinkPanels?(C(),T("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:U[1]||(U[1]=(...L)=>g(M)&&g(M)(...L))},[k(g(Ne),null,{default:$(()=>[k(g(Xc))]),_:1})],10,oie)):j("v-if",!0),b("div",null,O(g(P)),1)],2),k(kb,{"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"))},[F.unlinkPanels?(C(),T("button",{key:0,type:"button",disabled:!g(Y),class:D([[g(h).e("icon-btn"),{"is-disabled":!g(Y)}],"d-arrow-left"]),onClick:U[2]||(U[2]=(...L)=>g(A)&&g(A)(...L))},[k(g(Ne),null,{default:$(()=>[k(g(Jc))]),_:1})],10,rie)):j("v-if",!0),b("button",{type:"button",class:D([g(h).e("icon-btn"),"d-arrow-right"]),onClick:U[3]||(U[3]=(...L)=>g(E)&&g(E)(...L))},[k(g(Ne),null,{default:$(()=>[k(g(Xc))]),_:1})],2),b("div",null,O(g(N)),1)],2),k(kb,{"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 lie=je(iie,[["__file","panel-month-range.vue"]]);const aie=function(e){switch(e){case"daterange":case"datetimerange":return Xse;case"monthrange":return lie;default:return Fse}};ut.extend(foe);ut.extend(Kre);ut.extend(aM);ut.extend(Gre);ut.extend(Zre);ut.extend(Xre);ut.extend(ese);ut.extend(nse);var uie=Q({name:"ElDatePicker",install:null,props:ose,emits:["update:modelValue"],setup(e,{expose:t,emit:n,slots:o}){const r=Re("picker-panel");wt("ElPopperOptions",Vn(pn(e,"popperOptions"))),wt(V3,{slots:o,pickerNs:r});const s=q();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:Vne[e.type]||qu,c=aie(e.type);return k(Une,un(e,{format:u,type:e.type,ref:s,"onUpdate:modelValue":l}),{default:d=>k(c,d,null),"range-separator":o["range-separator"]})}}});const r1=uie;r1.install=e=>{e.component(r1.name,r1)};const cie=r1,die=Ke({mask:{type:Boolean,default:!0},customMaskEvent:{type:Boolean,default:!1},overlayClass:{type:Ce([String,Array,Object])},zIndex:{type:Ce([String,Number])}}),fie={click:e=>e instanceof MouseEvent},pie="overlay";var hie=Q({name:"ElOverlay",props:die,emits:fie,setup(e,{slots:t,emit:n}){const o=Re(pie),r=a=>{n("click",a)},{onClick:s,onMousedown:i,onMouseup:l}=k3(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")],Zm.STYLE|Zm.CLASS|Zm.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 z3=hie,eO=Symbol("dialogInjectionKey"),tO=Ke({center:Boolean,alignCenter:Boolean,closeIcon:{type:Io},draggable:Boolean,overflow:Boolean,fullscreen:Boolean,showClose:{type:Boolean,default:!0},title:{type:String,default:""},ariaLevel:{type:String,default:"2"}}),mie={close:()=>!0},gie=["aria-level"],vie=["aria-label"],yie=["id"],_ie=Q({name:"ElDialogContent"}),bie=Q({..._ie,props:tO,emits:mie,setup(e){const t=e,{t:n}=Kt(),{Close:o}=sT,{dialogRef:r,headerRef:s,bodyId:i,ns:l,style:a}=ze(eO),{focusTrapRef:u}=ze(N3),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=p3(u,r),f=R(()=>t.draggable),p=R(()=>t.overflow);return uT(r,s,f,p),(h,m)=>(C(),T("div",{ref:g(d),class:D(g(c)),style:et(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"))},O(h.title),11,gie)]),h.showClose?(C(),T("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(),K(Lt(h.closeIcon||g(o))))]),_:1},8,["class"])],10,vie)):j("v-if",!0)],2),b("div",{id:g(i),class:D(g(l).e("body"))},[he(h.$slots,"default")],10,yie),h.$slots.footer?(C(),T("footer",{key:0,class:D(g(l).e("footer"))},[he(h.$slots,"footer")],2)):j("v-if",!0)],6))}});var wie=je(bie,[["__file","dialog-content.vue"]]);const nO=Ke({...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}=F0();let i="";const l=Hr(),a=Hr(),u=q(!1),c=q(!1),d=q(!1),f=q((n=e.zIndex)!=null?n:s());let p,h;const m=ph("namespace",Hf),y=R(()=>{const W={},H=`--${m.value}-dialog`;return e.fullscreen||(e.top&&(W[`${H}-margin-top`]=e.top),e.width&&(W[`${H}-width`]=Zo(e.width))),W}),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}=B_(()=>P(),e.openDelay):P()}function E(){p==null||p(),h==null||h(),e.closeDelay&&e.closeDelay>0?{stop:h}=B_(()=>N(),e.closeDelay):N()}function M(){function W(H){H||(c.value=!0,u.value=!1)}e.beforeClose?e.beforeClose(W):E()}function A(){e.closeOnClickModal&&M()}function P(){xt&&(u.value=!0)}function N(){u.value=!1}function V(){r("openAutoFocus")}function B(){r("closeAutoFocus")}function Y(W){var H;((H=W.detail)==null?void 0:H.focusReason)==="pointer"&&W.preventDefault()}e.lockScroll&&fT(u);function Z(){e.closeOnPressEscape&&M()}return Me(()=>e.modelValue,W=>{W?(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()}),Me(()=>e.fullscreen,W=>{t.value&&(W?(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:M,onModalClick:A,close:E,doClose:N,onOpenAutoFocus:V,onCloseAutoFocus:B,onCloseRequested:Z,onFocusoutPrevented:Y,titleId:l,bodyId:a,closed:c,style:y,overlayDialogStyle:v,rendered:d,visible:u,zIndex:f}},Cie=["aria-label","aria-labelledby","aria-describedby"],kie=Q({name:"ElDialog",inheritAttrs:!1}),Sie=Q({...kie,props:nO,emits:oO,setup(e,{expose:t}){const n=e,o=Kr();Ka({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=q(),i=q(),l=q(),{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:M}=rO(n,s);wt(eO,{dialogRef:s,headerRef:i,bodyId:c,ns:r,rendered:p,style:d});const A=k3(_),P=R(()=>n.draggable&&!n.fullscreen);return t({visible:a,dialogContentRef:l}),(N,V)=>(C(),K(_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:$(()=>[Fe(k(g(z3),{"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:et(g(f)),onClick:V[0]||(V[0]=(...B)=>g(A).onClick&&g(A).onClick(...B)),onMousedown:V[1]||(V[1]=(...B)=>g(A).onMousedown&&g(A).onMousedown(...B)),onMouseup:V[2]||(V[2]=(...B)=>g(A).onMouseup&&g(A).onMouseup(...B))},[k(g(U0),{loop:"",trapped:g(a),"focus-start-el":"container",onFocusAfterTrapped:g(S),onFocusAfterReleased:g(x),onFocusoutPrevented:g(M),onReleaseRequested:g(E)},{default:$(()=>[g(p)?(C(),K(wie,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)}),Bl({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"])):j("v-if",!0)]),_:3},8,["trapped","onFocusAfterTrapped","onFocusAfterReleased","onFocusoutPrevented","onReleaseRequested"])],46,Cie)]),_:3},8,["mask","overlay-class","z-index"]),[[en,g(a)]])]),_:3},8,["onAfterEnter","onAfterLeave","onBeforeLeave"])],8,["to","disabled"]))}});var $ie=je(Sie,[["__file","dialog.vue"]]);const _h=Zt($ie),Eie=Ke({direction:{type:String,values:["horizontal","vertical"],default:"horizontal"},contentPosition:{type:String,values:["left","center","right"],default:"center"},borderStyle:{type:Ce(String),default:"solid"}}),xie=Q({name:"ElDivider"}),Tie=Q({...xie,props:Eie,setup(e){const t=e,n=Re("divider"),o=R(()=>n.cssVar({"border-style":t.borderStyle}));return(r,s)=>(C(),T("div",{class:D([g(n).b(),g(n).m(r.direction)]),style:et(g(o)),role:"separator"},[r.$slots.default&&r.direction!=="vertical"?(C(),T("div",{key:0,class:D([g(n).e("text"),g(n).is(r.contentPosition)])},[he(r.$slots,"default")],2)):j("v-if",!0)],6))}});var Mie=je(Tie,[["__file","divider.vue"]]);const sO=Zt(Mie),Oie=Ke({...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"}}),Iie=oO,Aie=["aria-label","aria-labelledby","aria-describedby"],Nie=["id","aria-level"],Pie=["aria-label"],Lie=["id"],Rie=Q({name:"ElDrawer",inheritAttrs:!1}),Die=Q({...Rie,props:Oie,emits:Iie,setup(e,{expose:t}){const n=e,o=Kr();Ka({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=q(),s=q(),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"),M=R(()=>Zo(n.size));return t({handleClose:x,afterEnter:a,afterLeave:u}),(A,P)=>(C(),K(_s,{to:"body",disabled:!A.appendToBody},[k(_r,{name:g(i).b("fade"),onAfterEnter:g(a),onAfterLeave:g(u),onBeforeLeave:g(c),persisted:""},{default:$(()=>[Fe(k(g(z3),{mask:A.modal,"overlay-class":A.modalClass,"z-index":g(m),onClick:g(y)},{default:$(()=>[k(g(U0),{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":A.title||void 0,"aria-labelledby":A.title?void 0:g(p),"aria-describedby":g(h)},A.$attrs,{class:[g(i).b(),A.direction,g(d)&&"open"],style:g(E)?"width: "+g(M):"height: "+g(M),role:"dialog",onClick:P[1]||(P[1]=Je(()=>{},["stop"]))}),[b("span",{ref_key:"focusStartRef",ref:s,class:D(g(i).e("sr-focus")),tabindex:"-1"},null,2),A.withHeader?(C(),T("header",{key:0,class:D(g(i).e("header"))},[A.$slots.title?he(A.$slots,"title",{key:1},()=>[j(" DEPRECATED SLOT ")]):he(A.$slots,"header",{key:0,close:g(x),titleId:g(p),titleClass:g(i).e("title")},()=>[A.$slots.title?j("v-if",!0):(C(),T("span",{key:0,id:g(p),role:"heading","aria-level":A.headerAriaLevel,class:D(g(i).e("title"))},O(A.title),11,Nie))]),A.showClose?(C(),T("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(Zs))]),_:1},8,["class"])],10,Pie)):j("v-if",!0)],2)):j("v-if",!0),g(f)?(C(),T("div",{key:1,id:g(h),class:D(g(i).e("body"))},[he(A.$slots,"default")],10,Lie)):j("v-if",!0),A.$slots.footer?(C(),T("div",{key:2,class:D(g(i).e("footer"))},[he(A.$slots,"footer")],2)):j("v-if",!0)],16,Aie)]),_: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 Vie=je(Die,[["__file","drawer.vue"]]);const ta=Zt(Vie),Fie=Q({inheritAttrs:!1});function Bie(e,t,n,o,r,s){return he(e.$slots,"default")}var zie=je(Fie,[["render",Bie],["__file","collection.vue"]]);const jie=Q({name:"ElCollectionItem",inheritAttrs:!1});function Hie(e,t,n,o,r,s){return he(e.$slots,"default")}var Uie=je(jie,[["render",Hie],["__file","collection-item.vue"]]);const iO="data-el-collection-item",lO=e=>{const t=`El${e}Collection`,n=`${t}Item`,o=Symbol(t),r=Symbol(n),s={...zie,name:t,setup(){const l=q(null),a=new Map;wt(o,{itemMap:a,getItems:()=>{const c=g(l);if(!c)return[];const d=Array.from(c.querySelectorAll(`[${iO}]`));return[...a.values()].sort((p,h)=>d.indexOf(p.ref)-d.indexOf(h.ref))},collectionRef:l})}},i={...Uie,name:n,setup(l,{attrs:a}){const u=q(null),c=ze(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}},Wie=Ke({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:Kie,ElCollectionItem:qie,COLLECTION_INJECTION_KEY:j3,COLLECTION_ITEM_INJECTION_KEY:Gie}=lO("RovingFocusGroup"),H3=Symbol("elRovingFocusGroup"),aO=Symbol("elRovingFocusGroupItem"),Yie={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"},Zie=(e,t)=>{if(t!=="rtl")return e;switch(e){case rt.right:return rt.left;case rt.left:return rt.right;default:return e}},Jie=(e,t,n)=>{const o=Zie(e.key,n);if(!(t==="vertical"&&[rt.left,rt.right].includes(o))&&!(t==="horizontal"&&[rt.up,rt.down].includes(o)))return Yie[o]},Xie=(e,t)=>e.map((n,o)=>e[(o+t)%e.length]),U3=e=>{const{activeElement:t}=document;for(const n of e)if(n===t||(n.focus(),t!==document.activeElement))return},m8="currentTabIdChange",g8="rovingFocusGroup.entryFocus",Qie={bubbles:!1,cancelable:!0},ele=Q({name:"ElRovingFocusGroupImpl",inheritAttrs:!1,props:Wie,emits:[m8,"entryFocus"],setup(e,{emit:t}){var n;const o=q((n=e.currentTabId||e.defaultCurrentTabId)!=null?n:null),r=q(!1),s=q(!1),i=q(null),{getItems:l}=ze(j3,void 0),a=R(()=>[{outline:"none"},e.style]),u=m=>{t(m8,m)},c=()=>{r.value=!0},d=Pn(m=>{var y;(y=e.onMousedown)==null||y.call(e,m)},()=>{s.value=!0}),f=Pn(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,Qie);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)),A=[x,E,...S].filter(Boolean).map(P=>P.ref);U3(A)}}s.value=!1}),p=Pn(m=>{var y;(y=e.onBlur)==null||y.call(e,m)},()=>{r.value=!1}),h=(...m)=>{t("entryFocus",...m)};wt(H3,{currentTabbedId:bu(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}),Me(()=>e.currentTabId,m=>{o.value=m??null}),Rn(i,g8,h)}});function tle(e,t,n,o,r,s){return he(e.$slots,"default")}var nle=je(ele,[["render",tle],["__file","roving-focus-group-impl.vue"]]);const ole=Q({name:"ElRovingFocusGroup",components:{ElFocusGroupCollection:Kie,ElRovingFocusGroupImpl:nle}});function rle(e,t,n,o,r,s){const i=oe("el-roving-focus-group-impl"),l=oe("el-focus-group-collection");return C(),K(l,null,{default:$(()=>[k(i,J2(bw(e.$attrs)),{default:$(()=>[he(e.$slots,"default")]),_:3},16)]),_:3})}var sle=je(ole,[["render",rle],["__file","roving-focus-group.vue"]]);const ile=Q({components:{ElRovingFocusCollectionItem:qie},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}=ze(H3,void 0),{getItems:i}=ze(j3,void 0),l=Hr(),a=q(null),u=Pn(p=>{t("mousedown",p)},p=>{e.focusable?r(g(l)):p.preventDefault()}),c=Pn(p=>{t("focus",p)},()=>{r(g(l))}),d=Pn(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=Jie(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?Xie(S,x+1):S.slice(x+1);break}}ot(()=>{U3(S)})}}),f=R(()=>n.value===g(l));return wt(aO,{rovingFocusGroupItemRef:a,tabIndex:R(()=>g(f)?0:-1),handleMousedown:u,handleFocus:c,handleKeydown:d}),{id:l,handleKeydown:d,handleFocus:c,handleMousedown:u}}});function lle(e,t,n,o,r,s){const i=oe("el-roving-focus-collection-item");return C(),K(i,{id:e.id,focusable:e.focusable,active:e.active},{default:$(()=>[he(e.$slots,"default")]),_:3},8,["id","focusable","active"])}var ale=je(ile,[["render",lle],["__file","roving-focus-item.vue"]]);const s1=Ke({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}),uO=Ke({command:{type:[Object,String,Number],default:()=>({})},disabled:Boolean,divided:Boolean,textValue:String,icon:{type:Io}}),ule=Ke({onKeydown:{type:Ce(Function)}}),cle=[rt.down,rt.pageDown,rt.home],cO=[rt.up,rt.pageUp,rt.end],dle=[...cle,...cO],{ElCollection:fle,ElCollectionItem:ple,COLLECTION_INJECTION_KEY:hle,COLLECTION_ITEM_INJECTION_KEY:mle}=lO("Dropdown"),q0=Symbol("elDropdown"),{ButtonGroup:gle}=ct,vle=Q({name:"ElDropdown",components:{ElButton:ct,ElButtonGroup:gle,ElScrollbar:ks,ElDropdownCollection:fle,ElTooltip:Eu,ElRovingFocusGroup:sle,ElOnlyChild:ZT,ElIcon:Ne,ArrowDown:$u},props:s1,emits:["visible-change","click","command"],setup(e,{emit:t}){const n=at(),o=Re("dropdown"),{t:r}=Kt(),s=q(),i=q(),l=q(null),a=q(null),u=q(null),c=q(null),d=q(!1),f=[rt.enter,rt.space,rt.down],p=R(()=>({maxHeight:Zo(e.maxHeight)})),h=R(()=>[o.m(x.value)]),m=R(()=>Tg(e.trigger)),y=Hr().value,v=R(()=>e.id||y);Me([s,m],([F,U],[L])=>{var I,X,re;(I=L==null?void 0:L.$el)!=null&&I.removeEventListener&&L.$el.removeEventListener("pointerenter",M),(X=F==null?void 0:F.$el)!=null&&X.removeEventListener&&F.$el.removeEventListener("pointerenter",M),(re=F==null?void 0:F.$el)!=null&&re.addEventListener&&U.includes("hover")&&F.$el.addEventListener("pointerenter",M)},{immediate:!0}),En(()=>{var F,U;(U=(F=s.value)==null?void 0:F.$el)!=null&&U.removeEventListener&&s.value.$el.removeEventListener("pointerenter",M)});function w(){_()}function _(){var F;(F=l.value)==null||F.onClose()}function S(){var F;(F=l.value)==null||F.onOpen()}const x=Jo();function E(...F){t("command",...F)}function M(){var F,U;(U=(F=s.value)==null?void 0:F.$el)==null||U.focus()}function A(){}function P(){const F=g(a);m.value.includes("hover")&&(F==null||F.focus()),c.value=null}function N(F){c.value=F}function V(F){d.value||(F.preventDefault(),F.stopImmediatePropagation())}function B(){t("visible-change",!0)}function Y(F){(F==null?void 0:F.type)==="keydown"&&a.value.focus()}function Z(){t("visible-change",!1)}return wt(q0,{contentRef:a,role:R(()=>e.role),triggerId:v,isUsingKeyboard:d,onItemEnter:A,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:F=>{t("click",F)},handleEntryFocus:V,handleClose:_,handleOpen:S,handleBeforeShowTooltip:B,handleShowTooltip:Y,handleBeforeHideTooltip:Z,onFocusAfterTrapped:F=>{var U,L;F.preventDefault(),(L=(U=a.value)==null?void 0:U.focus)==null||L.call(U,{preventScroll:!0})},popperRef:l,contentRef:a,triggeringElementRef:s,referenceElementRef:i}}});function yle(e,t,n,o,r,s){var i;const l=oe("el-dropdown-collection"),a=oe("el-roving-focus-group"),u=oe("el-scrollbar"),c=oe("el-only-child"),d=oe("el-tooltip"),f=oe("el-button"),p=oe("arrow-down"),h=oe("el-icon"),m=oe("el-button-group");return C(),T("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},Bl({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(),K(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})):j("v-if",!0)],2)}var _le=je(vle,[["render",yle],["__file","dropdown.vue"]]);const ble=Q({name:"DropdownItemImpl",components:{ElIcon:Ne},props:uO,emits:["pointermove","pointerleave","click","clickimpl"],setup(e,{emit:t}){const n=Re("dropdown"),{role:o}=ze(q0,void 0),{collectionItemRef:r}=ze(mle,void 0),{collectionItemRef:s}=ze(Gie,void 0),{rovingFocusGroupItemRef:i,tabIndex:l,handleFocus:a,handleKeydown:u,handleMousedown:c}=ze(aO,void 0),d=p3(r,s,i),f=R(()=>o.value==="menu"?"menuitem":o.value==="navigation"?"link":"button"),p=Pn(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:{[iO]:""},role:f,tabIndex:l,handleFocus:a,handleKeydown:p,handleMousedown:c}}}),wle=["aria-disabled","tabindex","role"];function Cle(e,t,n,o,r,s){const i=oe("el-icon");return C(),T(fe,null,[e.divided?(C(),T("li",un({key:0,role:"separator",class:e.ns.bem("menu","item","divided")},e.$attrs),null,16)):j("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]=Je((...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(),K(i,{key:0},{default:$(()=>[(C(),K(Lt(e.icon)))]),_:1})):j("v-if",!0),he(e.$slots,"default")],16,wle)],64)}var kle=je(ble,[["render",Cle],["__file","dropdown-item-impl.vue"]]);const dO=()=>{const e=ze("elDropdown",{}),t=R(()=>e==null?void 0:e.dropdownSize);return{elDropdown:e,_elDropdownSize:t}},Sle=Q({name:"ElDropdownItem",components:{ElDropdownCollectionItem:ple,ElRovingFocusItem:ale,ElDropdownItemImpl:kle},inheritAttrs:!1,props:uO,emits:["pointermove","pointerleave","click"],setup(e,{emit:t,attrs:n}){const{elDropdown:o}=dO(),r=at(),s=q(null),i=R(()=>{var p,h;return(h=(p=g(s))==null?void 0:p.textContent)!=null?h:""}),{onItemEnter:l,onItemLeave:a}=ze(q0,void 0),u=Pn(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=Pn(p=>(t("pointerleave",p),p.defaultPrevented),b6(p=>{a(p)})),d=Pn(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 $le(e,t,n,o,r,s){var i;const l=oe("el-dropdown-item-impl"),a=oe("el-roving-focus-item"),u=oe("el-dropdown-collection-item");return C(),K(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 fO=je(Sle,[["render",$le],["__file","dropdown-item.vue"]]);const Ele=Q({name:"ElDropdownMenu",props:ule,setup(e){const t=Re("dropdown"),{_elDropdownSize:n}=dO(),o=n.value,{focusTrapRef:r,onKeydown:s}=ze(N3,void 0),{contentRef:i,role:l,triggerId:a}=ze(q0,void 0),{collectionRef:u,getItems:c}=ze(hle,void 0),{rovingFocusGroupRef:d,rovingFocusGroupRootStyle:f,tabIndex:p,onBlur:h,onFocus:m,onMousedown:y}=ze(H3,void 0),{collectionRef:v}=ze(j3,void 0),w=R(()=>[t.b("menu"),t.bm("menu",o==null?void 0:o.value)]),_=p3(i,u,r,d,v),S=Pn(E=>{var M;(M=e.onKeydown)==null||M.call(e,E)},E=>{const{currentTarget:M,code:A,target:P}=E;if(M.contains(P),rt.tab===A&&E.stopImmediatePropagation(),E.preventDefault(),P!==g(i)||!dle.includes(A))return;const V=c().filter(B=>!B.disabled).map(B=>B.ref);cO.includes(A)&&V.reverse(),U3(V)});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}}}),xle=["role","aria-labelledby"];function Tle(e,t,n,o,r,s){return C(),T("ul",{ref:e.dropdownListWrapperRef,class:D(e.dropdownKls),style:et(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]=Je((...i)=>e.handleKeydown&&e.handleKeydown(...i),["self"])),onMousedown:t[3]||(t[3]=Je((...i)=>e.onMousedown&&e.onMousedown(...i),["self"]))},[he(e.$slots,"default")],46,xle)}var pO=je(Ele,[["render",Tle],["__file","dropdown-menu.vue"]]);const bh=Zt(_le,{DropdownItem:fO,DropdownMenu:pO}),wh=Zn(fO),Ch=Zn(pO),Mle=Ke({urlList:{type:Ce(Array),default:()=>Eo([])},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)}}),Ole={close:()=>!0,switch:e=>_t(e),rotate:e=>_t(e)},Ile=["src","crossorigin"],Ale=Q({name:"ElImageViewer"}),Nle=Q({...Ale,props:Mle,emits:Ole,setup(e,{expose:t,emit:n}){var o;const r=e,s={CONTAIN:{name:"contain",icon:Ii(Qx)},ORIGINAL:{name:"original",icon:Ii(QZ)}},{t:i}=Kt(),l=Re("image-viewer"),{nextZIndex:a}=F0(),u=q(),c=q([]),d=E$(),f=q(!0),p=q(r.initialIndex),h=Mn(s.CONTAIN),m=q({scale:1,deg:0,offsetX:0,offsetY:0,enableTransition:!1}),y=q((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)]),M=R(()=>{const{scale:I,deg:X,offsetX:re,offsetY:z,enableTransition:ge}=m.value;let Oe=re/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 A(){N(),n("close")}function P(){const I=Xv(re=>{switch(re.code){case rt.esc:r.closeOnPressEscape&&A();break;case rt.space:W();break;case rt.left:F();break;case rt.up:L("zoomIn");break;case rt.right:U();break;case rt.down:L("zoomOut");break}}),X=Xv(re=>{const z=re.deltaY||re.deltaX;L(z<0?"zoomIn":"zoomOut",{zoomRate:r.zoomRate,enableTransition:!1})});d.run(()=>{Rn(document,"keydown",I),Rn(document,"wheel",X)})}function N(){d.stop()}function V(){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:re}=m.value,z=I.pageX,ge=I.pageY,Oe=Xv(ee=>{m.value={...m.value,offsetX:X+ee.pageX-z,offsetY:re+ee.pageY-ge}}),xe=Rn(document,"mousemove",Oe);Rn(document,"mouseup",()=>{xe()}),I.preventDefault()}function Z(){m.value={scale:1,deg:0,offsetX:0,offsetY:0,enableTransition:!1}}function W(){if(f.value)return;const I=Y_(s),X=Object.values(s),re=h.value.name,ge=(X.findIndex(Oe=>Oe.name===re)+1)%I.length;h.value=s[I[ge]],Z()}function H(I){const X=r.urlList.length;p.value=(I+X)%X}function F(){w.value&&!r.infinite||H(p.value-1)}function U(){_.value&&!r.infinite||H(p.value+1)}function L(I,X={}){if(f.value)return;const{minScale:re,maxScale:z}=r,{zoomRate:ge,rotateDeg:Oe,enableTransition:xe}={zoomRate:r.zoomRate,rotateDeg:90,enableTransition:!0,...X};switch(I){case"zoomOut":m.value.scale>re&&(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 Me(S,()=>{ot(()=>{const I=c.value[0];I!=null&&I.complete||(f.value=!0)})}),Me(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:H}),(I,X)=>(C(),K(_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:et({zIndex:y.value})},[b("div",{class:D(g(l).e("mask")),onClick:X[0]||(X[0]=Je(re=>I.hideOnClickModal&&A(),["self"]))},null,2),j(" CLOSE "),b("span",{class:D([g(l).e("btn"),g(l).e("close")]),onClick:A},[k(g(Ne),null,{default:$(()=>[k(g(Zs))]),_:1})],2),j(" ARROW "),g(v)?j("v-if",!0):(C(),T(fe,{key:0},[b("span",{class:D(g(x)),onClick:F},[k(g(Ne),null,{default:$(()=>[k(g(uu))]),_:1})],2),b("span",{class:D(g(E)),onClick:U},[k(g(Ne),null,{default:$(()=>[k(g(Us))]),_:1})],2)],64)),j(" 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]=re=>L("zoomOut"))},{default:$(()=>[k(g(mJ))]),_:1}),k(g(Ne),{onClick:X[2]||(X[2]=re=>L("zoomIn"))},{default:$(()=>[k(g(oT))]),_:1}),b("i",{class:D(g(l).e("actions__divider"))},null,2),k(g(Ne),{onClick:W},{default:$(()=>[(C(),K(Lt(g(h).icon)))]),_:1}),b("i",{class:D(g(l).e("actions__divider"))},null,2),k(g(Ne),{onClick:X[3]||(X[3]=re=>L("anticlockwise"))},{default:$(()=>[k(g(tT))]),_:1}),k(g(Ne),{onClick:X[4]||(X[4]=re=>L("clockwise"))},{default:$(()=>[k(g(JZ))]),_:1})],2)],2),j(" CANVAS "),b("div",{class:D(g(l).e("canvas"))},[(C(!0),T(fe,null,nt(I.urlList,(re,z)=>Fe((C(),T("img",{ref_for:!0,ref:ge=>c.value[z]=ge,key:re,src:re,style:et(g(M)),class:D(g(l).e("img")),crossorigin:I.crossorigin,onLoad:V,onError:B,onMousedown:Y},null,46,Ile)),[[en,z===p.value]])),128))],2),he(I.$slots,"default")],6)]),_:3})],8,["disabled"]))}});var Ple=je(Nle,[["__file","image-viewer.vue"]]);const Lle=Zt(Ple),Rle=Ke({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:()=>Eo([])},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)}}),Dle={load:e=>e instanceof Event,error:e=>e instanceof Event,switch:e=>_t(e),close:()=>!0,show:()=>!0},Vle=["src","loading","crossorigin"],Fle={key:0},Ble=Q({name:"ElImage",inheritAttrs:!1}),zle=Q({...Ble,props:Rle,emits:Dle,setup(e,{emit:t}){const n=e;let o="";const{t:r}=Kt(),s=Re("image"),i=_d(),l=aT(),a=q(),u=q(!1),c=q(!0),d=q(!1),f=q(),p=q(),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:U}=n;return xt&&U?{objectFit:U}:{}}),S=R(()=>{const{previewSrcList:U}=n;return Array.isArray(U)&&U.length>0}),x=R(()=>{const{previewSrcList:U,initialIndex:L}=n;let I=L;return L>U.length-1&&(I=0),I}),E=R(()=>n.loading==="eager"?!1:!h&&n.loading==="lazy"||n.lazy),M=()=>{xt&&(c.value=!0,u.value=!1,a.value=n.src)};function A(U){c.value=!1,u.value=!1,t("load",U)}function P(U){c.value=!1,u.value=!0,t("error",U)}function N(){mH(f.value,p.value)&&(M(),Y())}const V=Yj(N,200,!0);async function B(){var U;if(!xt)return;await ot();const{scrollContainer:L}=n;gs(L)?p.value=L:tt(L)&&L!==""?p.value=(U=document.querySelector(L))!=null?U:void 0:f.value&&(p.value=wY(f.value)),p.value&&(m=Rn(p,"scroll",V),setTimeout(()=>N(),100))}function Y(){!xt||!p.value||!V||(m==null||m(),p.value=void 0)}function Z(U){if(U.ctrlKey){if(U.deltaY<0)return U.preventDefault(),!1;if(U.deltaY>0)return U.preventDefault(),!1}}function W(){S.value&&(y=Rn("wheel",Z,{passive:!1}),o=document.body.style.overflow,document.body.style.overflow="hidden",d.value=!0,t("show"))}function H(){y==null||y(),document.body.style.overflow=o,d.value=!1,t("close")}function F(U){t("switch",U)}return Me(()=>n.src,()=>{E.value?(c.value=!0,u.value=!1,Y(),B()):M()}),Ct(()=>{E.value?B():M()}),(U,L)=>(C(),T("div",{ref_key:"container",ref:f,class:D([g(s).b(),U.$attrs.class]),style:et(g(w))},[u.value?he(U.$slots,"error",{key:0},()=>[b("div",{class:D(g(s).e("error"))},O(g(r)("el.image.error")),3)]):(C(),T(fe,{key:1},[a.value!==void 0?(C(),T("img",un({key:0},g(l),{src:a.value,loading:U.loading,style:g(_),class:g(v),crossorigin:U.crossorigin,onClick:W,onLoad:A,onError:P}),null,16,Vle)):j("v-if",!0),c.value?(C(),T("div",{key:1,class:D(g(s).e("wrapper"))},[he(U.$slots,"placeholder",{},()=>[b("div",{class:D(g(s).e("placeholder"))},null,2)])],2)):j("v-if",!0)],64)),g(S)?(C(),T(fe,{key:2},[d.value?(C(),K(g(Lle),{key:0,"z-index":U.zIndex,"initial-index":g(x),infinite:U.infinite,"zoom-rate":U.zoomRate,"min-scale":U.minScale,"max-scale":U.maxScale,"url-list":U.previewSrcList,"hide-on-click-modal":U.hideOnClickModal,teleported:U.previewTeleported,"close-on-press-escape":U.closeOnPressEscape,onClose:H,onSwitch:F},{default:$(()=>[U.$slots.viewer?(C(),T("div",Fle,[he(U.$slots,"viewer")])):j("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"])):j("v-if",!0)],64)):j("v-if",!0)],6))}});var jle=je(zle,[["__file","image.vue"]]);const Ed=Zt(jle),Hle=Ke({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}}),Ule={[Cd]:(e,t)=>t!==e,blur:e=>e instanceof FocusEvent,focus:e=>e instanceof FocusEvent,[Ym]:e=>_t(e)||To(e),[Jt]:e=>_t(e)||To(e)},Wle=["aria-label","onKeydown"],Kle=["aria-label","onKeydown"],qle=Q({name:"ElInputNumber"}),Gle=Q({...qle,props:Hle,emits:Ule,setup(e,{expose:t,emit:n}){const o=e,{t:r}=Kt(),s=Re("input-number"),i=q(),l=Vn({currentValue:o.modelValue,userInput:null}),{formItem:a}=ri(),u=R(()=>_t(o.modelValue)&&o.modelValue<=o.min),c=R(()=>_t(o.modelValue)&&o.modelValue>=o.max),d=R(()=>{const W=v(o.step);return Uo(o.precision)?Math.max(v(o.modelValue),W):(W>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 W=l.currentValue;if(To(W))return"";if(_t(W)){if(Number.isNaN(W))return"";Uo(o.precision)||(W=W.toFixed(o.precision))}return W}),y=(W,H)=>{if(Uo(H)&&(H=d.value),H===0)return Math.round(W);let F=String(W);const U=F.indexOf(".");if(U===-1||!F.replace(".","").split("")[U+H])return W;const X=F.length;return F.charAt(X-1)==="5"&&(F=`${F.slice(0,Math.max(0,X-1))}6`),Number.parseFloat(Number(F).toFixed(H))},v=W=>{if(To(W))return 0;const H=W.toString(),F=H.indexOf(".");let U=0;return F!==-1&&(U=H.length-F-1),U},w=(W,H=1)=>_t(W)?y(W+o.step*H):l.currentValue,_=()=>{if(o.readonly||h.value||c.value)return;const W=Number(m.value)||0,H=w(W);E(H),n(Ym,l.currentValue),Y()},S=()=>{if(o.readonly||h.value||u.value)return;const W=Number(m.value)||0,H=w(W,-1);E(H),n(Ym,l.currentValue),Y()},x=(W,H)=>{const{max:F,min:U,step:L,precision:I,stepStrictly:X,valueOnClear:re}=o;F<U&&ws("InputNumber","min should not be greater than max.");let z=Number(W);if(To(W)||Number.isNaN(z))return null;if(W===""){if(re===null)return null;z=tt(re)?{min:U,max:F}[re]:re}return X&&(z=y(Math.round(z/L)*L,I)),Uo(I)||(z=y(z,I)),(z>F||z<U)&&(z=z>F?F:U,H&&n(Jt,z)),z},E=(W,H=!0)=>{var F;const U=l.currentValue,L=x(W);if(!H){n(Jt,L);return}U===L&&W||(l.userInput=null,n(Jt,L),U!==L&&n(Cd,L,U),o.validateEvent&&((F=a==null?void 0:a.validate)==null||F.call(a,"change").catch(I=>void 0)),l.currentValue=L)},M=W=>{l.userInput=W;const H=W===""?null:Number(W);n(Ym,H),E(H,!1)},A=W=>{const H=W!==""?Number(W):"";(_t(H)&&!Number.isNaN(H)||W==="")&&E(H),Y(),l.userInput=null},P=()=>{var W,H;(H=(W=i.value)==null?void 0:W.focus)==null||H.call(W)},N=()=>{var W,H;(H=(W=i.value)==null?void 0:W.blur)==null||H.call(W)},V=W=>{n("focus",W)},B=W=>{var H;l.userInput=null,n("blur",W),o.validateEvent&&((H=a==null?void 0:a.validate)==null||H.call(a,"blur").catch(F=>void 0))},Y=()=>{l.currentValue!==o.modelValue&&(l.currentValue=o.modelValue)},Z=W=>{document.activeElement===W.target&&W.preventDefault()};return Me(()=>o.modelValue,(W,H)=>{const F=x(W,!0);l.userInput===null&&F!==H&&(l.currentValue=F)},{immediate:!0}),Ct(()=>{var W;const{min:H,max:F,modelValue:U}=o,L=(W=i.value)==null?void 0:W.input;if(L.setAttribute("role","spinbutton"),Number.isFinite(F)?L.setAttribute("aria-valuemax",String(F)):L.removeAttribute("aria-valuemax"),Number.isFinite(H)?L.setAttribute("aria-valuemin",String(H)):L.removeAttribute("aria-valuemin"),L.setAttribute("aria-valuenow",l.currentValue||l.currentValue===0?String(l.currentValue):""),L.setAttribute("aria-disabled",String(h.value)),!_t(U)&&U!=null){let I=Number(U);Number.isNaN(I)&&(I=null),n(Jt,I)}}),Vi(()=>{var W,H;const F=(W=i.value)==null?void 0:W.input;F==null||F.setAttribute("aria-valuenow",`${(H=l.currentValue)!=null?H:""}`)}),t({focus:P,blur:N}),(W,H)=>(C(),T("div",{class:D([g(s).b(),g(s).m(g(p)),g(s).is("disabled",g(h)),g(s).is("without-controls",!W.controls),g(s).is("controls-right",g(f))]),onDragstart:H[0]||(H[0]=Je(()=>{},["prevent"]))},[W.controls?Fe((C(),T("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(W.$slots,"decrease-icon",{},()=>[k(g(Ne),null,{default:$(()=>[g(f)?(C(),K(g($u),{key:0})):(C(),K(g(AZ),{key:1}))]),_:1})])],42,Wle)),[[g(Vg),S]]):j("v-if",!0),W.controls?Fe((C(),T("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(W.$slots,"increase-icon",{},()=>[k(g(Ne),null,{default:$(()=>[g(f)?(C(),K(g(L0),{key:0})):(C(),K(g(c3),{key:1}))]),_:1})])],42,Kle)),[[g(Vg),_]]):j("v-if",!0),k(g(Tt),{id:W.id,ref_key:"input",ref:i,type:"number",step:W.step,"model-value":g(m),placeholder:W.placeholder,readonly:W.readonly,disabled:g(h),size:g(p),max:W.max,min:W.min,name:W.name,label:W.label,"validate-event":!1,onWheel:Z,onKeydown:[Pt(Je(_,["prevent"]),["up"]),Pt(Je(S,["prevent"]),["down"])],onBlur:B,onFocus:V,onInput:M,onChange:A},null,8,["id","step","model-value","placeholder","readonly","disabled","size","max","min","name","label","onKeydown"])],34))}});var Yle=je(Gle,[["__file","input-number.vue"]]);const hO=Zt(Yle),mO=Symbol("elPaginationKey"),Zle=Ke({disabled:Boolean,currentPage:{type:Number,default:1},prevText:{type:String},prevIcon:{type:Io}}),Jle={click:e=>e instanceof MouseEvent},Xle=["disabled","aria-label","aria-disabled"],Qle={key:0},eae=Q({name:"ElPaginationPrev"}),tae=Q({...eae,props:Zle,emits:Jle,setup(e){const t=e,{t:n}=Kt(),o=R(()=>t.disabled||t.currentPage<=1);return(r,s)=>(C(),T("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(),T("span",Qle,O(r.prevText),1)):(C(),K(g(Ne),{key:1},{default:$(()=>[(C(),K(Lt(r.prevIcon)))]),_:1}))],8,Xle))}});var nae=je(tae,[["__file","prev.vue"]]);const oae=Ke({disabled:Boolean,currentPage:{type:Number,default:1},pageCount:{type:Number,default:50},nextText:{type:String},nextIcon:{type:Io}}),rae=["disabled","aria-label","aria-disabled"],sae={key:0},iae=Q({name:"ElPaginationNext"}),lae=Q({...iae,props:oae,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(),T("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(),T("span",sae,O(r.nextText),1)):(C(),K(g(Ne),{key:1},{default:$(()=>[(C(),K(Lt(r.nextIcon)))]),_:1}))],8,rae))}});var aae=je(lae,[["__file","next.vue"]]);const gO=Symbol("ElSelectGroup"),G0=Symbol("ElSelect");function uae(e,t){const n=ze(G0),o=ze(gO,{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||(pt(e.value)?"":e.value)),l=R(()=>e.value||e.label||""),a=R(()=>e.disabled||t.groupDisabled||s.value),u=at(),c=(p=[],h)=>{if(pt(e.value)){const m=n.props.valueKey;return p&&p.some(y=>Mt(Mr(y,m))===Mr(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(vY(p),"i");t.visible=h.test(i.value)||e.created};return Me(()=>i.value,()=>{!e.created&&!n.props.remote&&n.setSelected()}),Me(()=>e.value,(p,h)=>{const{remote:m,valueKey:y}=n.props;if(Hl(p,h)||(n.onOptionDestroy(h,u.proxy),n.onOptionCreate(u.proxy)),!e.created&&!m){if(y&&pt(p)&&pt(h)&&p[y]===h[y])return;n.setSelected()}}),Me(()=>o.disabled,()=>{t.groupDisabled=o.disabled},{immediate:!0}),{select:n,currentLabel:i,currentValue:l,itemSelected:r,isDisabled:a,hoverItem:d,updateOption:f}}const cae=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=Vn({index:-1,groupDisabled:!1,visible:!0,hover:!1}),{currentLabel:s,itemSelected:i,isDisabled:l,select:a,hoverItem:u,updateOption:c}=uae(e,r),{visible:d,hover:f}=ni(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}}}),dae=["id","aria-disabled","aria-selected"];function fae(e,t,n,o,r,s){return Fe((C(),T("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]=Je((...i)=>e.selectOptionClick&&e.selectOptionClick(...i),["stop"]))},[he(e.$slots,"default",{},()=>[b("span",null,O(e.currentLabel),1)])],42,dae)),[[en,e.visible]])}var W3=je(cae,[["render",fae],["__file","option.vue"]]);const pae=Q({name:"ElSelectDropdown",componentName:"ElSelectDropdown",setup(){const e=ze(G0),t=Re("select"),n=R(()=>e.props.popperClass),o=R(()=>e.props.multiple),r=R(()=>e.props.fitInputWidth),s=q("");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 hae(e,t,n,o,r,s){return C(),T("div",{class:D([e.ns.b("dropdown"),e.ns.is("multiple",e.isMultiple),e.popperClass]),style:et({[e.isFitInputWidth?"width":"minWidth"]:e.minWidth})},[e.$slots.header?(C(),T("div",{key:0,class:D(e.ns.be("dropdown","header"))},[he(e.$slots,"header")],2)):j("v-if",!0),he(e.$slots,"default"),e.$slots.footer?(C(),T("div",{key:1,class:D(e.ns.be("dropdown","footer"))},[he(e.$slots,"footer")],2)):j("v-if",!0)],6)}var mae=je(pae,[["render",hae],["__file","select-dropdown.vue"]]);function gae(e){const t=q(!1);return{handleCompositionStart:()=>{t.value=!0},handleCompositionUpdate:s=>{const i=s.target.value,l=i[i.length-1]||"";t.value=!lT(l)},handleCompositionEnd:s=>{t.value&&(t.value=!1,Qe(e)&&e(s))}}}const vae=11,yae=(e,t)=>{const{t:n}=Kt(),o=Hr(),r=Re("select"),s=Re("input"),i=Vn({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=q(null),a=q(null),u=q(null),c=q(null),d=q(null),f=q(null),p=q(null),h=q(null),m=q(null),y=q(null),v=q(null),w=q(null),{wrapperRef:_,isFocused:S,handleFocus:x,handleBlur:E}=T3(d,{afterFocus(){e.automaticDropdown&&!M.value&&(M.value=!0,i.menuVisibleOnFocus=!0)},beforeBlur(be){var qe,tn;return((qe=u.value)==null?void 0:qe.isFocusInsideContent(be))||((tn=c.value)==null?void 0:tn.isFocusInsideContent(be))},afterBlur(){M.value=!1,i.menuVisibleOnFocus=!1}}),M=q(!1),A=q(),{form:P,formItem:N}=ri(),{inputId:V}=Sd(e,{formItemContext:N}),{valueOnClear:B,isEmptyValue:Y}=HT(e),Z=R(()=>e.disabled||(P==null?void 0:P.disabled)),W=R(()=>e.multiple?Te(e.modelValue)&&e.modelValue.length>0:!Y(e.modelValue)),H=R(()=>e.clearable&&!Z.value&&i.inputHovering&&W.value),F=R(()=>e.remote&&e.filterable&&!e.remoteShowSuffix?"":e.suffixIcon),U=R(()=>r.is("reverse",F.value&&M.value)),L=R(()=>(N==null?void 0:N.validateState)||""),I=R(()=>iT[L.value]),X=R(()=>e.remote?300:0),re=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()),qe=[];return i.optionValues.forEach(tn=>{const Tn=be.findIndex(Ui=>Ui.value===tn);Tn>-1&&qe.push(be[Tn])}),qe.length>=be.length?qe:be}),Oe=R(()=>Array.from(i.cachedOptions.values())),xe=R(()=>{const be=ge.value.filter(qe=>!qe.created).some(qe=>qe.currentLabel===i.inputValue);return e.filterable&&e.allowCreate&&i.inputValue!==""&&!be}),ee=()=>{e.filterable&&Qe(e.filterMethod)||e.filterable&&e.remote&&Qe(e.remoteMethod)||ge.value.forEach(be=>{var qe;(qe=be.updateOption)==null||qe.call(be,i.inputValue)})},de=Jo(),ve=R(()=>["small"].includes(de.value)?"small":"default"),le=R({get(){return M.value&&re.value!==!1},set(be){M.value=be}}),Ie=R(()=>Te(e.modelValue)?e.modelValue.length===0&&!i.inputValue:e.filterable?!i.inputValue:!0),Ge=R(()=>{var be;const qe=(be=e.placeholder)!=null?be:n("el.select.placeholder");return e.multiple||!W.value?qe:i.selectedLabel});Me(()=>e.modelValue,(be,qe)=>{e.multiple&&e.filterable&&!e.reserveKeyword&&(i.inputValue="",G("")),ue(),!Hl(be,qe)&&e.validateEvent&&(N==null||N.validate("change").catch(tn=>void 0))},{flush:"post",deep:!0}),Me(()=>M.value,be=>{be?G(i.inputValue):(i.inputValue="",i.previousQuery=null,i.isBeforeHide=!0),t("visible-change",be)}),Me(()=>i.options.entries(),()=>{var be;if(!xt)return;const qe=((be=l.value)==null?void 0:be.querySelectorAll("input"))||[];(!e.filterable&&!e.defaultFirstOption&&!Uo(e.modelValue)||!Array.from(qe).includes(document.activeElement))&&ue(),e.defaultFirstOption&&(e.filterable||e.remote)&&z.value&&J()},{flush:"post"}),Me(()=>i.hoveringIndex,be=>{_t(be)&&be>-1?A.value=ge.value[be]||{}:A.value={},ge.value.forEach(qe=>{qe.hover=A.value===qe})}),ls(()=>{i.isBeforeHide||ee()});const G=be=>{i.previousQuery!==be&&(i.previousQuery=be,e.filterable&&Qe(e.filterMethod)?e.filterMethod(be):e.filterable&&e.remote&&Qe(e.remoteMethod)&&e.remoteMethod(be),e.defaultFirstOption&&(e.filterable||e.remote)&&z.value?ot(J):ot(ye))},J=()=>{const be=ge.value.filter(Tn=>Tn.visible&&!Tn.disabled&&!Tn.states.groupDisabled),qe=be.find(Tn=>Tn.created),tn=be[0];i.hoveringIndex=we(ge.value,qe||tn)},ue=()=>{if(e.multiple)i.selectedLabel="";else{const qe=_e(e.modelValue);i.selectedLabel=qe.currentLabel,i.selected=qe;return}const be=[];Te(e.modelValue)&&e.modelValue.forEach(qe=>{be.push(_e(qe))}),i.selected=be},_e=be=>{let qe;const tn=Bm(be).toLowerCase()==="object",Tn=Bm(be).toLowerCase()==="null",Ui=Bm(be).toLowerCase()==="undefined";for(let ua=i.cachedOptions.size-1;ua>=0;ua--){const Ts=Oe.value[ua];if(tn?Mr(Ts.value,e.valueKey)===Mr(be,e.valueKey):Ts.value===be){qe={value:be,currentLabel:Ts.currentLabel,isDisabled:Ts.isDisabled};break}}if(qe)return qe;const Iu=tn?be.label:!Tn&&!Ui?be:"";return{value:be,currentLabel:Iu}},ye=()=>{e.multiple?i.hoveringIndex=ge.value.findIndex(be=>i.selected.some(qe=>Fd(qe)===Fd(be))):i.hoveringIndex=ge.value.findIndex(be=>Fd(be)===Fd(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,qe;(qe=(be=u.value)==null?void 0:be.updatePopper)==null||qe.call(be)},me=()=>{var be,qe;(qe=(be=c.value)==null?void 0:be.updatePopper)==null||qe.call(be)},He=()=>{i.inputValue.length>0&&!M.value&&(M.value=!0),G(i.inputValue)},Ze=be=>{if(i.inputValue=be.target.value,e.remote)ce();else return He()},ce=jl(()=>{He()},X.value),te=be=>{Hl(e.modelValue,be)||t(Cd,be)},pe=be=>oY(be,qe=>!i.disabledOptions.has(qe)),Be=be=>{if(e.multiple&&be.code!==rt.delete&&be.target.value.length<=0){const qe=e.modelValue.slice(),tn=pe(qe);if(tn<0)return;qe.splice(tn,1),t(Jt,qe),te(qe)}},Xe=(be,qe)=>{const tn=i.selected.indexOf(qe);if(tn>-1&&!Z.value){const Tn=e.modelValue.slice();Tn.splice(tn,1),t(Jt,Tn),te(Tn),t("remove-tag",qe.value)}be.stopPropagation(),Kn()},$e=be=>{be.stopPropagation();const qe=e.multiple?[]:B.value;if(e.multiple)for(const tn of i.selected)tn.isDisabled&&qe.push(tn.value);t(Jt,qe),te(qe),i.hoveringIndex=-1,M.value=!1,t("clear"),Kn()},ie=be=>{if(e.multiple){const qe=(e.modelValue||[]).slice(),tn=we(qe,be.value);tn>-1?qe.splice(tn,1):(e.multipleLimit<=0||qe.length<e.multipleLimit)&&qe.push(be.value),t(Jt,qe),te(qe),be.created&&G(""),e.filterable&&!e.reserveKeyword&&(i.inputValue="")}else t(Jt,be.value),te(be.value),M.value=!1;Kn(),!M.value&&ot(()=>{ae(be)})},we=(be=[],qe)=>{if(!pt(qe))return be.indexOf(qe);const tn=e.valueKey;let Tn=-1;return be.some((Ui,Iu)=>Mt(Mr(Ui,tn))===Mr(qe,tn)?(Tn=Iu,!0):!1),Tn},ae=be=>{var qe,tn,Tn,Ui,Iu;const Kh=Te(be)?be[0]:be;let ua=null;if(Kh!=null&&Kh.value){const Ts=ge.value.filter(Gk=>Gk.value===Kh.value);Ts.length>0&&(ua=Ts[0].$el)}if(u.value&&ua){const Ts=(Ui=(Tn=(tn=(qe=u.value)==null?void 0:qe.popperRef)==null?void 0:tn.contentRef)==null?void 0:Tn.querySelector)==null?void 0:Ui.call(Tn,`.${r.be("dropdown","wrap")}`);Ts&&kY(Ts,ua)}(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)},Ve=(be,qe)=>{i.options.get(be)===qe&&i.options.delete(be)},{handleCompositionStart:st,handleCompositionUpdate:se,handleCompositionEnd:De}=gae(be=>Ze(be)),It=R(()=>{var be,qe;return(qe=(be=u.value)==null?void 0:be.popperRef)==null?void 0:qe.contentRef}),mn=()=>{i.isBeforeHide=!1,ot(()=>ae(i.selected))},Kn=()=>{var be;(be=d.value)==null||be.focus()},Zr=()=>{nr()},qt=be=>{$e(be)},nr=be=>{if(M.value=!1,S.value){const qe=new FocusEvent("focus",be);ot(()=>E(qe))}},gR=()=>{i.inputValue.length>0?i.inputValue="":M.value=!1},Kk=()=>{Z.value||(i.menuVisibleOnFocus?i.menuVisibleOnFocus=!1:M.value=!M.value)},vR=()=>{M.value?ge.value[i.hoveringIndex]&&ie(ge.value[i.hoveringIndex]):Kk()},Fd=be=>pt(be.value)?Mr(be.value,e.valueKey):be.value,yR=R(()=>ge.value.filter(be=>be.visible).every(be=>be.disabled)),_R=R(()=>e.multiple?e.collapseTags?i.selected.slice(0,e.maxCollapseTags):i.selected:[]),bR=R(()=>e.multiple?e.collapseTags?i.selected.slice(e.maxCollapseTags):[]:[]),qk=be=>{if(!M.value){M.value=!0;return}if(!(i.options.size===0||z.value===0)&&!yR.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 qe=ge.value[i.hoveringIndex];(qe.disabled===!0||qe.states.groupDisabled===!0||!qe.visible)&&qk(be),ot(()=>ae(A.value))}},wR=()=>{if(!a.value)return 0;const be=window.getComputedStyle(a.value);return Number.parseFloat(be.gap||"6px")},CR=R(()=>{const be=wR();return{maxWidth:`${v.value&&e.maxCollapseTags===1?i.selectionWidth-i.collapseItemWidth-be:i.selectionWidth}px`}}),kR=R(()=>({maxWidth:`${i.selectionWidth}px`})),SR=R(()=>({width:`${Math.max(i.calculatorWidth,vae)}px`}));return e.multiple&&!Te(e.modelValue)&&t(Jt,[]),!e.multiple&&Te(e.modelValue)&&t(Jt,""),Bo(a,Ae),Bo(f,Le),Bo(m,Pe),Bo(_,Pe),Bo(y,me),Bo(v,Ee),Ct(()=>{ue()}),{inputId:V,contentId:o,nsSelect:r,nsInput:s,states:i,isFocused:S,expanded:M,optionsArray:ge,hoverOption:A,selectSize:de,filteredOptionsCount:z,resetCalculatorWidth:Le,updateTooltip:Pe,updateTagTooltip:me,debouncedOnInputChange:ce,onInput:Ze,deletePrevTag:Be,deleteTag:Xe,deleteSelected:$e,handleOptionSelect:ie,scrollToOption:ae,hasModelValue:W,shouldShowPlaceholder:Ie,currentPlaceholder:Ge,showClose:H,iconComponent:F,iconReverse:U,validateState:L,validateIcon:I,showNewOption:xe,updateOptions:ee,collapseTagSize:ve,setSelected:ue,selectDisabled:Z,emptyText:re,handleCompositionStart:st,handleCompositionUpdate:se,handleCompositionEnd:De,onOptionCreate:Se,onOptionDestroy:Ve,handleMenuEnter:mn,handleFocus:x,focus:Kn,blur:Zr,handleBlur:E,handleClearClick:qt,handleClickOutside:nr,handleEsc:gR,toggleMenu:Kk,selectOption:vR,getValueKey:Fd,navigateOptions:qk,dropdownMenuVisible:le,showTagList:_R,collapseTagList:bR,tagStyle:CR,collapseTagStyle:kR,inputStyle:SR,popperRef:It,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 _ae=Q({name:"ElOptions",setup(e,{slots:t}){const n=ze(G0);let o=[];return()=>{var r,s;const i=(r=t.default)==null?void 0:r.call(t),l=[];function a(u){Te(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)&&!Te(c.children)&&Qe((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):Te(c.children)&&a(c.children)})}return i.length&&a((s=i[0])==null?void 0:s.children),Hl(l,o)||(o=l,n&&(n.states.optionValues=l)),i}}});const bae=Ke({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:Io,default:wd},fitInputWidth:Boolean,suffixIcon:{type:Io,default:$u},tagType:{...PM.type,default:"info"},validateEvent:{type:Boolean,default:!0},remoteShowSuffix:Boolean,placement:{type:Ce(String),values:D0,default:"bottom-start"},fallbackPlacements:{type:Ce(Array),default:["bottom-start","top-start","right","left"]},ariaLabel:{type:String,default:void 0},...M3}),v8="ElSelect",wae=Q({name:v8,componentName:v8,components:{ElInput:Tt,ElSelectMenu:mae,ElOption:W3,ElOptions:_ae,ElTag:gh,ElScrollbar:ks,ElTooltip:Eu,ElIcon:Ne},directives:{ClickOutside:id},props:bae,emits:[Jt,Cd,"remove-tag","clear","visible-change","focus","blur"],setup(e,{emit:t}){const n=yae(e,t);return wt(G0,Vn({props:e,states:n.states,optionsArray:n.optionsArray,handleOptionSelect:n.handleOptionSelect,onOptionCreate:n.onOptionCreate,onOptionDestroy:n.onOptionDestroy,selectRef:n.selectRef,setSelected:n.setSelected})),{...n}}}),Cae=["id","disabled","autocomplete","readonly","aria-activedescendant","aria-controls","aria-expanded","aria-label"],kae=["textContent"];function Sae(e,t,n,o,r,s){const i=oe("el-tag"),l=oe("el-tooltip"),a=oe("el-icon"),u=oe("el-option"),c=oe("el-options"),d=oe("el-scrollbar"),f=oe("el-select-menu"),p=Dt("click-outside");return Fe((C(),T("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]=Je((...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(),T("div",{key:0,ref:"prefixRef",class:D(e.nsSelect.e("prefix"))},[he(e.$slots,"prefix")],2)):j("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),T(fe,null,nt(e.showTagList,m=>(C(),T("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:et(e.tagStyle),onClose:y=>e.deleteTag(y,m)},{default:$(()=>[b("span",{class:D(e.nsSelect.e("tags-text"))},O(m.currentLabel),3)]),_:2},1032,["closable","size","type","style","onClose"])],2))),128)),e.collapseTags&&e.states.selected.length>e.maxCollapseTags?(C(),K(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:et(e.collapseTagStyle)},{default:$(()=>[b("span",{class:D(e.nsSelect.e("tags-text"))}," + "+O(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),T(fe,null,nt(e.collapseTagList,m=>(C(),T("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"))},O(m.currentLabel),3)]),_:2},1032,["closable","size","type","onClose"])],2))),128))],2)]),_:1},8,["disabled","effect","teleported"])):j("v-if",!0)]):j("v-if",!0),e.selectDisabled?j("v-if",!0):(C(),T("div",{key:1,class:D([e.nsSelect.e("selected-item"),e.nsSelect.e("input-wrapper"),e.nsSelect.is("hidden",!e.filterable)])},[Fe(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:et(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(Je(m=>e.navigateOptions("next"),["stop","prevent"]),["down"])),t[4]||(t[4]=Pt(Je(m=>e.navigateOptions("prev"),["stop","prevent"]),["up"])),t[5]||(t[5]=Pt(Je((...m)=>e.handleEsc&&e.handleEsc(...m),["stop","prevent"]),["esc"])),t[6]||(t[6]=Pt(Je((...m)=>e.selectOption&&e.selectOption(...m),["stop","prevent"]),["enter"])),t[7]||(t[7]=Pt(Je((...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]=Je((...m)=>e.toggleMenu&&e.toggleMenu(...m),["stop"]))},null,46,Cae),[[Bc,e.states.inputValue]]),e.filterable?(C(),T("span",{key:0,ref:"calculatorRef","aria-hidden":"true",class:D(e.nsSelect.e("input-calculator")),textContent:O(e.states.inputValue)},null,10,kae)):j("v-if",!0)],2)),e.shouldShowPlaceholder?(C(),T("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,O(e.currentPlaceholder),1)],2)):j("v-if",!0)],2),b("div",{ref:"suffixRef",class:D(e.nsSelect.e("suffix"))},[e.iconComponent&&!e.showClose?(C(),K(a,{key:0,class:D([e.nsSelect.e("caret"),e.nsSelect.e("icon"),e.iconReverse])},{default:$(()=>[(C(),K(Lt(e.iconComponent)))]),_:1},8,["class"])):j("v-if",!0),e.showClose&&e.clearIcon?(C(),K(a,{key:1,class:D([e.nsSelect.e("caret"),e.nsSelect.e("icon")]),onClick:e.handleClearClick},{default:$(()=>[(C(),K(Lt(e.clearIcon)))]),_:1},8,["class","onClick"])):j("v-if",!0),e.validateState&&e.validateIcon?(C(),K(a,{key:2,class:D([e.nsInput.e("icon"),e.nsInput.e("validateIcon")])},{default:$(()=>[(C(),K(Lt(e.validateIcon)))]),_:1},8,["class"])):j("v-if",!0)],2)],2)]}),content:$(()=>[k(f,{ref:"menuRef"},{default:$(()=>[e.$slots.header?(C(),T("div",{key:0,class:D(e.nsSelect.be("dropdown","header")),onClick:t[13]||(t[13]=Je(()=>{},["stop"]))},[he(e.$slots,"header")],2)):j("v-if",!0),Fe(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(),K(u,{key:0,value:e.states.inputValue,created:!0},null,8,["value"])):j("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(),T("div",{key:1,class:D(e.nsSelect.be("dropdown","loading"))},[he(e.$slots,"loading")],2)):e.loading||e.filteredOptionsCount===0?(C(),T("div",{key:2,class:D(e.nsSelect.be("dropdown","empty"))},[he(e.$slots,"empty",{},()=>[b("span",null,O(e.emptyText),1)])],2)):j("v-if",!0),e.$slots.footer?(C(),T("div",{key:3,class:D(e.nsSelect.be("dropdown","footer")),onClick:t[14]||(t[14]=Je(()=>{},["stop"]))},[he(e.$slots,"footer")],2)):j("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 $ae=je(wae,[["render",Sae],["__file","select.vue"]]);const Eae=Q({name:"ElOptionGroup",componentName:"ElOptionGroup",props:{label:String,disabled:Boolean},setup(e){const t=Re("select"),n=q(null),o=at(),r=q([]);wt(gO,Vn({...ni(e)}));const s=R(()=>r.value.some(a=>a.visible===!0)),i=a=>{const u=[];return Te(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()}),iH(n,l,{attributes:!0,subtree:!0,childList:!0}),{groupRef:n,visible:s,ns:t}}});function xae(e,t,n,o,r,s){return Fe((C(),T("ul",{ref:"groupRef",class:D(e.ns.be("group","wrap"))},[b("li",{class:D(e.ns.be("group","title"))},O(e.label),3),b("li",null,[b("ul",{class:D(e.ns.b("group"))},[he(e.$slots,"default")],2)])],2)),[[en,e.visible]])}var vO=je(Eae,[["render",xae],["__file","option-group.vue"]]);const vr=Zt($ae,{Option:W3,OptionGroup:vO}),Ss=Zn(W3),Tae=Zn(vO),K3=()=>ze(mO,{}),Mae=Ke({pageSize:{type:Number,required:!0},pageSizes:{type:Ce(Array),default:()=>Eo([10,20,30,40,50,100])},popperClass:{type:String},disabled:Boolean,teleported:Boolean,size:{type:String,values:Jl}}),Oae=Q({name:"ElPaginationSizes"}),Iae=Q({...Oae,props:Mae,emits:["page-size-change"],setup(e,{emit:t}){const n=e,{t:o}=Kt(),r=Re("pagination"),s=K3(),i=q(n.pageSize);Me(()=>n.pageSizes,(u,c)=>{if(!Hl(u,c)&&Array.isArray(u)){const d=u.includes(n.pageSize)?n.pageSize:n.pageSizes[0];t("page-size-change",d)}}),Me(()=>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(),T("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),T(fe,null,nt(g(l),d=>(C(),K(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 Aae=je(Iae,[["__file","sizes.vue"]]);const Nae=Ke({size:{type:String,values:Jl}}),Pae=["disabled"],Lae=Q({name:"ElPaginationJumper"}),Rae=Q({...Lae,props:Nae,setup(e){const{t}=Kt(),n=Re("pagination"),{pageCount:o,disabled:r,currentPage:s,changeEvent:i}=K3(),l=q(),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(),T("span",{class:D(g(n).e("jump")),disabled:g(r)},[b("span",{class:D([g(n).e("goto")])},O(g(t)("el.pagination.goto")),3),k(g(Tt),{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")])},O(g(t)("el.pagination.pageClassifier")),3)],10,Pae))}});var Dae=je(Rae,[["__file","jumper.vue"]]);const Vae=Ke({total:{type:Number,default:1e3}}),Fae=["disabled"],Bae=Q({name:"ElPaginationTotal"}),zae=Q({...Bae,props:Vae,setup(e){const{t}=Kt(),n=Re("pagination"),{disabled:o}=K3();return(r,s)=>(C(),T("span",{class:D(g(n).e("total")),disabled:g(o)},O(g(t)("el.pagination.total",{total:r.total})),11,Fae))}});var jae=je(zae,[["__file","total.vue"]]);const Hae=Ke({currentPage:{type:Number,default:1},pageCount:{type:Number,required:!0},pagerCount:{type:Number,default:7},disabled:Boolean}),Uae=["onKeyup"],Wae=["aria-current","aria-label","tabindex"],Kae=["tabindex","aria-label"],qae=["aria-current","aria-label","tabindex"],Gae=["tabindex","aria-label"],Yae=["aria-current","aria-label","tabindex"],Zae=Q({name:"ElPaginationPager"}),Jae=Q({...Zae,props:Hae,emits:["change"],setup(e,{emit:t}){const n=e,o=Re("pager"),r=Re("icon"),{t:s}=Kt(),i=q(!1),l=q(!1),a=q(!1),u=q(!1),c=q(!1),d=q(!1),f=R(()=>{const S=n.pagerCount,x=(S-1)/2,E=Number(n.currentPage),M=Number(n.pageCount);let A=!1,P=!1;M>S&&(E>S-x&&(A=!0),E<M-x&&(P=!0));const N=[];if(A&&!P){const V=M-(S-2);for(let B=V;B<M;B++)N.push(B)}else if(!A&&P)for(let V=2;V<S;V++)N.push(V);else if(A&&P){const V=Math.floor(S/2)-1;for(let B=E-V;B<=E+V;B++)N.push(B)}else for(let V=2;V<M;V++)N.push(V);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 M=n.pageCount,A=n.currentPage,P=n.pagerCount-2;x.className.includes("more")&&(x.className.includes("quickprev")?E=A-P:x.className.includes("quicknext")&&(E=A+P)),Number.isNaN(+E)||(E<1&&(E=1),E>M&&(E=M)),E!==A&&t("change",E)}return(S,x)=>(C(),T("ul",{class:D(g(o).b()),onClick:_,onKeyup:Pt(w,["enter"])},[S.pageCount>0?(C(),T("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,Wae)):j("v-if",!0),i.value?(C(),T("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(),K(g(Jc),{key:0})):(C(),K(g(Z_),{key:1}))],42,Kae)):j("v-if",!0),(C(!0),T(fe,null,nt(g(f),E=>(C(),T("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)},O(E),11,qae))),128)),l.value?(C(),T("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(),K(g(Xc),{key:0})):(C(),K(g(Z_),{key:1}))],42,Gae)):j("v-if",!0),S.pageCount>1?(C(),T("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)},O(S.pageCount),11,Yae)):j("v-if",!0)],42,Uae))}});var Xae=je(Jae,[["__file","pager.vue"]]);const Co=e=>typeof e!="number",Qae=Ke({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:()=>Eo([10,20,30,40,50,100])},popperClass:{type:String,default:""},prevText:{type:String,default:""},prevIcon:{type:Io,default:()=>uu},nextText:{type:String,default:""},nextIcon:{type:Io,default:()=>Us},teleported:{type:Boolean,default:!0},small:Boolean,background:Boolean,disabled:Boolean,hideOnSinglePage:Boolean}),eue={"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 tue=Q({name:y8,props:Qae,emits:eue,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(Co(e.total)&&Co(e.pageCount)||!Co(e.currentPage)&&!i)return!1;if(e.layout.includes("sizes")){if(Co(e.pageCount)){if(!Co(e.total)&&!Co(e.pageSize)&&!l)return!1}else if(!l)return!1}return!0}),u=q(Co(e.defaultPageSize)?10:e.defaultPageSize),c=q(Co(e.defaultCurrentPage)?1:e.defaultCurrentPage),d=R({get(){return Co(e.pageSize)?u.value:e.pageSize},set(_){Co(e.pageSize)&&(u.value=_),l&&(t("update:page-size",_),t("size-change",_))}}),f=R(()=>{let _=0;return Co(e.pageCount)?Co(e.total)||(_=Math.max(1,Math.ceil(e.total/d.value))):_=e.pageCount,_}),p=R({get(){return Co(e.currentPage)?c.value:e.currentPage},set(_){let S=_;_<1?S=1:_>f.value&&(S=f.value),Co(e.currentPage)&&(c.value=S),i&&(t("update:current-page",S),t("current-change",S))}});Me(f,_=>{p.value>_&&(p.value=_)}),Me([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(mO,{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=[],M=lt("div",{class:r.e("rightwrapper")},E),A={prev:lt(nae,{disabled:e.disabled,currentPage:p.value,prevText:e.prevText,prevIcon:e.prevIcon,onClick:y}),jumper:lt(Dae,{size:e.small?"small":"default"}),pager:lt(Xae,{currentPage:p.value,pageCount:f.value,pagerCount:e.pagerCount,onChange:h,disabled:e.disabled}),next:lt(aae,{disabled:e.disabled,currentPage:p.value,pageCount:f.value,nextText:e.nextText,nextIcon:e.nextIcon,onClick:v}),sizes:lt(Aae,{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(jae,{total:Co(e.total)?0:e.total})},P=e.layout.split(",").map(V=>V.trim());let N=!1;return P.forEach(V=>{if(V==="->"){N=!0;return}N?E.push(A[V]):x.push(A[V])}),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(M)),lt("div",{class:[r.b(),r.is("background",e.background),{[r.m("small")]:e.small}]},x)}}});const nue=Zt(tue),oue=Ke({trigger:Dp.trigger,placement:s1.placement,disabled:Dp.disabled,visible:ar.visible,transition:ar.transition,popperOptions:s1.popperOptions,tabindex:s1.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}}),rue={"update:visible":e=>Br(e),"before-enter":()=>!0,"before-leave":()=>!0,"after-enter":()=>!0,"after-leave":()=>!0},sue="onUpdate:visible",iue=Q({name:"ElPopover"}),lue=Q({...iue,props:oue,emits:rue,setup(e,{expose:t,emit:n}){const o=e,r=R(()=>o[sue]),s=Re("popover"),i=q(),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(),K(g(Eu),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(),T("div",{key:0,class:D(g(s).e("title")),role:"title"},O(y.title),3)):j("v-if",!0),he(y.$slots,"default",{},()=>[ne(O(y.content),1)])]),default:$(()=>[y.$slots.reference?he(y.$slots,"reference",{key:0}):j("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 aue=je(lue,[["__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 uue={mounted(e,t){_8(e,t)},updated(e,t){_8(e,t)}};const cue="popover",due=_J(uue,cue),bo=Zt(aue,{directive:due}),fue=Ke({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}%`}}),pue=["aria-valuenow"],hue={viewBox:"0 0 100 100"},mue=["d","stroke","stroke-linecap","stroke-width"],gue=["d","stroke","opacity","stroke-linecap","stroke-width"],vue={key:0},yue=Q({name:"ElProgress"}),_ue=Q({...yue,props:fue,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"?f3:t.type==="line"?t.status==="success"?l3:wd:t.status==="success"?Yx:Zs),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,M)=>tt(E)?{color:E,percentage:(M+1)*S}:E).sort((E,M)=>E.percentage-M.percentage)}const w=_=>{var S;const{color:x}=t;if(Qe(x))return x(_);if(tt(x))return x;{const E=v(x);for(const M of E)if(M.percentage>_)return M.color;return(S=E[E.length-1])==null?void 0:S.color}};return(_,S)=>(C(),T("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(),T("div",{key:0,class:D(g(o).b("bar"))},[b("div",{class:D(g(o).be("bar","outer")),style:et({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:et(g(r))},[(_.showText||_.$slots.default)&&_.textInside?(C(),T("div",{key:0,class:D(g(o).be("bar","innerText"))},[he(_.$slots,"default",{percentage:_.percentage},()=>[b("span",null,O(g(y)),1)])],2)):j("v-if",!0)],6)],6)],2)):(C(),T("div",{key:1,class:D(g(o).b("circle")),style:et({height:`${_.width}px`,width:`${_.width}px`})},[(C(),T("svg",hue,[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:et(g(d))},null,14,mue),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:et(g(f))},null,14,gue)]))],6)),(_.showText||_.$slots.default)&&!_.textInside?(C(),T("div",{key:2,class:D(g(o).e("text")),style:et({fontSize:`${g(m)}px`})},[he(_.$slots,"default",{percentage:_.percentage},()=>[_.status?(C(),K(g(Ne),{key:1},{default:$(()=>[(C(),K(Lt(g(h))))]),_:1})):(C(),T("span",vue,O(g(y)),1))])],6)):j("v-if",!0)],10,pue))}});var bue=je(_ue,[["__file","progress.vue"]]);const yO=Zt(bue),wue=Ke({animated:{type:Boolean,default:!1},count:{type:Number,default:1},rows:{type:Number,default:3},loading:{type:Boolean,default:!0},throttle:{type:Number}}),Cue=Ke({variant:{type:String,values:["circle","rect","h1","h3","text","caption","p","image","button"],default:"text"}}),kue=Q({name:"ElSkeletonItem"}),Sue=Q({...kue,props:Cue,setup(e){const t=Re("skeleton");return(n,o)=>(C(),T("div",{class:D([g(t).e("item"),g(t).e(n.variant)])},[n.variant==="image"?(C(),K(g(zZ),{key:0})):j("v-if",!0)],2))}});var Fg=je(Sue,[["__file","skeleton-item.vue"]]);const $ue=Q({name:"ElSkeleton"}),Eue=Q({...$ue,props:wue,setup(e,{expose:t}){const n=e,o=Re("skeleton"),r=LX(pn(n,"loading"),n.throttle);return t({uiLoading:r}),(s,i)=>g(r)?(C(),T("div",un({key:0,class:[g(o).b(),g(o).is("animated",s.animated)]},s.$attrs),[(C(!0),T(fe,null,nt(s.count,l=>(C(),T(fe,{key:l},[s.loading?he(s.$slots,"template",{key:l},()=>[k(Fg,{class:D(g(o).is("first")),variant:"p"},null,8,["class"]),(C(!0),T(fe,null,nt(s.rows,a=>(C(),K(Fg,{key:a,class:D([g(o).e("paragraph"),g(o).is("last",a===s.rows&&s.rows>1)]),variant:"p"},null,8,["class"]))),128))]):j("v-if",!0)],64))),128))],16)):he(s.$slots,"default",J2(un({key:1},s.$attrs)))}});var xue=je(Eue,[["__file","skeleton.vue"]]);const Jn=Zt(xue,{SkeletonItem:Fg});Zn(Fg);const cy=function(e){var t;return(t=e.target)==null?void 0:t.closest("td")},Tue=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"?Mr(l,u):u(l,a,e))):(t!=="$key"&&pt(l)&&"$value"in l&&(l=l.$value),[pt(l)?Mr(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)},_O=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?_O(e,o[0]):null},io=(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)},Ra=function(e,t){const n={};return(e||[]).forEach((o,r)=>{n[io(o,t)]={row:o,index:r}}),n};function Oue(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 q3(e){return e===""||e!==void 0&&(e=Number.parseInt(e,10),Number.isNaN(e)&&(e="")),e}function bO(e){return e===""||e!==void 0&&(e=q3(e),Number.isNaN(e)&&(e=80)),e}function Iue(e){return typeof e=="number"?e:typeof e=="string"?/^\d+(?:px)?$/.test(e)?Number.parseInt(e,10):e:null}function Aue(...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,Te(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 Nue(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 Pue(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(Eu,{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 wO(e){return e.children?iY(e.children,wO):[e]}function w8(e,t){return e+t.colSpan}const CO=(e,t,n,o)=>{let r=0,s=e;const i=n.states.columns.value;if(o){const a=wO(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}:{}},G3=(e,t,n,o,r,s=0)=>{const i=[],{direction:l,start:a,after:u}=CO(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 Y3=(e,t,n,o)=>{const{direction:r,start:s=0,after:i=0}=CO(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 Lue(e){const t=at(),n=q(!1),o=q([]);return{updateExpandRows:()=>{const a=e.data.value||[],u=e.rowKey.value;if(n.value)o.value=a.slice();else if(u){const c=Ra(o.value,u);o.value=a.reduce((d,f)=>{const p=io(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=Ra(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?!!Ra(o.value,u)[io(a,u)]:o.value.includes(a)},states:{expandRows:o,defaultExpandAll:n}}}function Rue(e){const t=at(),n=q(null),o=q(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=>io(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=io(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 Due(e){const t=q([]),n=q({}),o=q(16),r=q(!1),s=q({}),i=q("hasChildren"),l=q("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 M=io(E,v);x.children.push(M),E[i.value]&&!_[M]&&(_[M]={children:[]})}),_[S]=x}}),_}),d=v=>{const w=e.rowKey.value,_={};return Nue(v,(S,x,E)=>{const M=io(S,w);Array.isArray(x)?_[M]={children:x.map(A=>io(A,w)),level:E}:r.value&&(_[M]={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),M={};if(E.length){const A=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=A[B],Z={...S[B]};if(Z.expanded=N(Y,B),Z.lazy){const{loaded:W=!1,loading:H=!1}=Y||{};Z.loaded=!!W,Z.loading=!!H,P.push(B)}M[B]=Z});const V=Object.keys(x);r.value&&V.length&&P.length&&V.forEach(B=>{const Y=A[B],Z=x[B].children;if(P.includes(B)){if(M[B].children.length!==0)throw new Error("[ElTable]children must be an empty array.");M[B].children=Z}else{const{loaded:W=!1,loading:H=!1}=Y||{};M[B]={lazy:!0,loaded:!!W,loading:!!H,expanded:N(Y,B),children:Z,level:""}}})}n.value=M,(_=a.store)==null||_.updateTableScrollY()};Me(()=>t.value,()=>{f(!0)}),Me(()=>u.value,()=>{f()}),Me(()=>c.value,()=>{f()});const p=v=>{t.value=v,f()},h=(v,w)=>{a.store.assertRowKey();const _=e.rowKey.value,S=io(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,_=io(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 Vue=(e,t)=>{const n=t.sortingColumn;return!n||typeof n.sortable=="string"?e:Tue(e,t.sortProp,t.sortOrder,n.sortMethod,n.sortBy)},i1=e=>{const t=[];return e.forEach(n=>{n.children&&n.children.length>0?t.push.apply(t,i1(n.children)):t.push(n)}),t};function Fue(){var e;const t=at(),{size:n}=ni((e=t.proxy)==null?void 0:e.$props),o=q(null),r=q([]),s=q([]),i=q(!1),l=q([]),a=q([]),u=q([]),c=q([]),d=q([]),f=q([]),p=q([]),h=q([]),m=[],y=q(0),v=q(0),w=q(0),_=q(!1),S=q([]),x=q(!1),E=q(!1),M=q(null),A=q({}),P=q(null),N=q(null),V=q(null),B=q(null),Y=q(null);Me(r,()=>t.state&&F(!1),{deep:!0});const Z=()=>{if(!o.value)throw new Error("[ElTable] prop row-key is required")},W=$e=>{var ie;(ie=$e.children)==null||ie.forEach(we=>{we.fixed=$e.fixed,W(we)})},H=()=>{l.value.forEach(Se=>{W(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=i1($e),we=i1(c.value),ae=i1(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},F=($e,ie=!1)=>{$e&&H(),ie?t.state.doLayout():t.state.debouncedUpdateLayout()},U=$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=Ra(S.value,o.value),we=Ra(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(),re=($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 Ve=(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;M.value?M.value.call(null,st,De)&&Yf(S.value,st,we)&&(ae=!0):Yf(S.value,st,we)&&(ae=!0),Se+=xe(io(st,Ve))}),ae&&t.emit("selection-change",S.value?S.value.slice():[]),t.emit("select-all",S.value)},ge=()=>{const $e=Ra(S.value,o.value);r.value.forEach(ie=>{const we=io(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=Ra(S.value,o.value));const Se=function(De){return ae?!!ae[io(De,o.value)]:S.value.includes(De)};let Ve=!0,st=0,se=0;for(let De=0,It=(r.value||[]).length;De<It;De++){const mn=(we=(ie=t==null?void 0:t.store)==null?void 0:ie.states)==null?void 0:we.rowKey.value,Kn=De+se,Zr=r.value[De],qt=M.value&&M.value.call(null,Zr,Kn);if(Se(Zr))st++;else if(!M.value||qt){Ve=!1;break}se+=xe(io(Zr,mn))}st===0&&(Ve=!1),_.value=Ve},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(Ve=>{ae+=xe(Ve)})),ae},ee=($e,ie)=>{Array.isArray($e)||($e=[$e]);const we={};return $e.forEach(ae=>{A.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,V.value=ie,B.value=we},ve=()=>{let $e=g(s);Object.keys(A.value).forEach(ie=>{const we=A.value[ie];if(!we||we.length===0)return;const ae=_O({columns:u.value},ie);ae&&ae.filterMethod&&($e=$e.filter(Se=>we.some(Ve=>ae.filterMethod.call(null,Ve,Se,ae))))}),P.value=$e},le=()=>{r.value=Vue(P.value,{sortingColumn:N.value,sortProp:V.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(Ve=>Mue({columns:u.value},Ve));ae.forEach(Ve=>{const st=Se.find(se=>se.id===Ve);st&&(st.filteredValue=[])}),t.store.commit("filterChange",{column:Se,values:[],silent:!0,multi:!0})}else ae.forEach(Se=>{const Ve=u.value.find(st=>st.id===Se);Ve&&(Ve.filteredValue=[])}),A.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}=Lue({data:r,rowKey:o}),{updateTreeExpandKeys:Le,toggleTreeExpansion:Ee,updateTreeData:Pe,loadOrToggle:me,states:He}=Due({data:r,rowKey:o}),{updateCurrentRowData:Ze,updateCurrentRow:ce,setCurrentRowKey:te,states:pe}=Rue({data:r,rowKey:o});return{assertRowKey:Z,updateColumns:H,scheduleLayout:F,isSelected:U,clearSelection:L,cleanSelection:I,getSelectionRows:X,toggleRowSelection:re,_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:M,filters:A,filteredData:P,sortingColumn:N,sortProp:V,sortOrder:B,hoverRow:Y,...ye,...He,...pe}}}function Sb(e,t){return e.map(n=>{var o;return n.id===t.id?t:((o=n.children)!=null&&o.length&&(n.children=Sb(n.children,t)),n)})}function $b(e){e.forEach(t=>{var n,o;t.no=(n=t.getColumnIndex)==null?void 0:n.call(t),(o=t.children)!=null&&o.length&&$b(t.children)}),e.sort((t,n)=>t.no-n.no)}function Bue(){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=Sb(c,a)):(c.push(l),d=c),$b(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&&($b(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=Sb(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 zue(e,t){if(!e)throw new Error("Table is required.");const n=Bue();return n.toggleAllSelection=jl(n._toggleAllSelection,10),Object.keys(Zf).forEach(o=>{kO(SO(t,o),o,n)}),jue(n,t),n}function jue(e,t){Object.keys(Zf).forEach(n=>{Me(()=>SO(t,n),o=>{kO(o,n,e)})})}function kO(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 SO(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 Hue{constructor(t){this.observers=[],this.table=null,this.store=null,this.columns=[],this.fit=!0,this.showHeader=!0,this.height=q(null),this.scrollX=q(!1),this.scrollY=q(!1),this.bodyWidth=q(null),this.fixedWidth=q(null),this.rightFixedWidth=q(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=Iue(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:Uue}=In,Wue=Q({name:"ElTableFilterPanel",components:{ElCheckbox:In,ElCheckboxGroup:Uue,ElScrollbar:ks,ElTooltip:Eu,ElIcon:Ne,ArrowDown:$u,ArrowUp:L0},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=q(!1),i=q(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()};Me(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}}}),Kue={key:0},que=["disabled"],Gue=["label","onClick"];function Yue(e,t,n,o,r,s){const i=oe("el-checkbox"),l=oe("el-checkbox-group"),a=oe("el-scrollbar"),u=oe("arrow-up"),c=oe("arrow-down"),d=oe("el-icon"),f=oe("el-tooltip"),p=Dt("click-outside");return C(),K(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(),T("div",Kue,[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),T(fe,null,nt(e.filters,h=>(C(),K(i,{key:h.value,value:h.value},{default:$(()=>[ne(O(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))},O(e.t("el.table.confirmFilter")),11,que),b("button",{type:"button",onClick:t[2]||(t[2]=(...h)=>e.handleReset&&e.handleReset(...h))},O(e.t("el.table.resetFilter")),1)],2)])):(C(),T("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))},O(e.t("el.table.clearFilter")),3),(C(!0),T(fe,null,nt(e.filters,h=>(C(),T("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)},O(h.text),11,Gue))),128))],2))]),default:$(()=>[Fe((C(),T("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(),K(u,{key:0})):(C(),K(c,{key:1}))]),_:1})],2)),[[p,e.hideFilterPanel,e.popperPaneRef]])]),_:1},8,["visible","placement","popper-class"])}var Zue=je(Wue,[["render",Yue],["__file","filter-panel.vue"]]);function $O(e){const t=at();yd(()=>{n.value.addObserver(t)}),Ct(()=>{o(n.value),r(n.value)}),Vi(()=>{o(n.value),r(n.value)}),oi(()=>{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 si=Symbol("ElTable");function Jue(e,t){const n=at(),o=ze(si),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=q(null),a=q(!1),u=q({}),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;au(S,"noclick"),u.value={startMouseLeft:m.clientX,startLeft:x.right-_,startColumnLeft:x.left-_,tableLeft:_};const M=v==null?void 0:v.refs.resizeProxy;M.style.left=`${u.value.startLeft}px`,document.onselectstart=function(){return!1},document.ondragstart=function(){return!1};const A=N=>{const V=N.clientX-u.value.startMouseLeft,B=u.value.startLeft+V;M.style.left=`${Math.max(E,B)}px`},P=()=>{if(a.value){const{startColumnLeft:N,startLeft:V}=u.value,Y=Number.parseInt(M.style.left,10)-N;y.width=y.realWidth=Y,v==null||v.emit("header-dragend",y.width,V-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",A),document.removeEventListener("mouseup",P),document.onselectstart=null,document.ondragstart=null,setTimeout(()=>{Ys(S,"noclick")},0)};document.addEventListener("mousemove",A),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",Mi(w,"is-sortable")&&(w.style.cursor="col-resize"),l.value=y):a.value||(S.cursor="",Mi(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&&Mi(S,"noclick")){Ys(S,"noclick");return}if(!y.sortable)return;const x=e.store.states;let E=x.sortProp.value,M;const A=x.sortingColumn.value;(A!==y||A===y&&A.order===null)&&(A&&(A.order=null),x.sortingColumn.value=y,E=y.property),_?M=y.order=_:M=y.order=null,x.sortProp.value=E,x.sortOrder.value=M,o==null||o.store.commit("changeSortCondition")};return{handleHeaderClick:s,handleHeaderContextMenu:i,handleMouseDown:c,handleMouseMove:d,handleMouseOut:f,handleSortClick:h,handleFilterClick:r}}function Xue(e){const t=ze(si),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=Y3(a,c.fixed,e.store,u);return ld(p,"left"),ld(p,"right"),Object.assign({},f,p)},getHeaderCellClass:(l,a,u,c)=>{const d=G3(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 EO=e=>{const t=[];return e.forEach(n=>{n.children?(t.push(n),t.push.apply(t,EO(n.children))):t.push(n)}),t},Que=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 EO(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 ece(e){const t=ze(si),n=R(()=>Que(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 tce=Q({name:"ElTableHeader",components:{ElCheckbox:In},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=ze(si),r=Re("table"),s=q({}),{onColumnsChange:i,onScrollableChange:l}=$O(o);Ct(async()=>{await ot(),await ot();const{prop:E,order:M}=e.defaultSort;o==null||o.store.commit("sort",{prop:E,order:M,init:!0})});const{handleHeaderClick:a,handleHeaderContextMenu:u,handleMouseDown:c,handleMouseMove:d,handleMouseOut:f,handleSortClick:p,handleFilterClick:h}=Jue(e,t),{getHeaderRowStyle:m,getHeaderRowClass:y,getHeaderCellStyle:v,getHeaderCellClass:w}=Xue(e),{isGroup:_,toggleAllSelection:S,columnRows:x}=ece(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&<("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&<(Zue,{store:p,placement:w.filterPlacement||"bottom-start",column:w,upDataColumn:(S,x)=>{w[S]=x}})])]))))))}});function nce(e){const t=ze(si),n=q(""),o=q(lt("div")),r=(h,m,y)=>{var v;const w=t,_=cy(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=jl(h=>{e.store.commit("setHoverRow",h)},30),u=jl(()=>{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,_=cy(h),S=(v=w==null?void 0:w.vnode.el)==null?void 0:v.dataset.prefix;if(_){const F=b8({columns:e.store.states.columns.value},_,S);_.rowSpan>1&&d(_.rowSpan,h,au);const U=w.hoverState={cell:_,column:F,row:m};w==null||w.emit("cell-mouse-enter",U.row,U.column,U.cell,h)}if(!y)return;const x=h.target.querySelector(".cell");if(!(Mi(x,`${S}-tooltip`)&&x.childNodes.length))return;const E=document.createRange();E.setStart(x,0),E.setEnd(x,x.childNodes.length);let M=E.getBoundingClientRect().width,A=E.getBoundingClientRect().height;M-Math.floor(M)<.001&&(M=Math.floor(M)),A-Math.floor(A)<.001&&(A=Math.floor(A));const{top:V,left:B,right:Y,bottom:Z}=c(x),W=B+Y,H=V+Z;(M+W>x.offsetWidth||A+H>x.offsetHeight||x.scrollWidth>x.offsetWidth)&&Pue(y,_.innerText||_.textContent,_,w)},handleCellMouseLeave:h=>{const m=cy(h);if(!m)return;m.rowSpan>1&&d(m.rowSpan,h,Ys);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 oce(e){const t=ze(si),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=Y3(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=G3(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 rce(e){const t=ze(si),n=Re("table"),{handleDoubleClick:o,handleClick:r,handleContextMenu:s,handleMouseEnter:i,handleMouseLeave:l,handleCellMouseEnter:a,handleCellMouseLeave:u,tooltipContent:c,tooltipTrigger:d}=nce(e),{getRowStyle:f,getRowClass:p,getCellStyle:h,getCellClass:m,getSpan:y,getColspanRealWidth:v}=oce(e),w=R(()=>e.store.states.columns.value.findIndex(({type:M})=>M==="default")),_=(M,A)=>{const P=t.props.rowKey;return P?io(M,P):A},S=(M,A,P,N=!1)=>{const{tooltipEffect:V,tooltipOptions:B,store:Y}=e,{indent:Z,columns:W}=Y.states,H=p(M,A);let F=!0;return P&&(H.push(n.em("row",`level-${P.level}`)),F=P.display),lt("tr",{style:[F?null:{display:"none"},f(M,A)],class:H,key:_(M,A),onDblclick:L=>o(L,M),onClick:L=>r(L,M),onContextmenu:L=>s(L,M),onMouseenter:()=>i(A),onMouseleave:l},W.value.map((L,I)=>{const{rowspan:X,colspan:re}=y(M,L,A,I);if(!X||!re)return null;const z=Object.assign({},L);z.realWidth=v(W.value,re,I);const ge={store:e.store,_self:e.context||t,column:z,row:M,$index:A,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=`${A},${I}`,xe=z.columnKey||z.rawColumnKey||"",ee=x(I,L,ge),de=L.showOverflowTooltip&&aY({effect:V},B,L.showOverflowTooltip);return lt("td",{style:h(A,I,M,L),class:m(A,I,M,L,re-1),key:`${xe}${Oe}`,rowspan:X,colspan:re,onMouseenter:ve=>a(ve,M,de),onMouseleave:u},[ee])}))},x=(M,A,P)=>A.renderCell(P);return{wrappedRowRender:(M,A)=>{const P=e.store,{isRowExpanded:N,assertRowKey:V}=P,{treeData:B,lazyTreeNodeMap:Y,childrenColumnName:Z,rowKey:W}=P.states,H=P.states.columns.value;if(H.some(({type:U})=>U==="expand")){const U=N(M),L=S(M,A,void 0,U),I=t.renderExpanded;return U?I?[[L,lt("tr",{key:`expanded-row__${L.key}`},[lt("td",{colspan:H.length,class:`${n.e("cell")} ${n.e("expanded-cell")}`},[I({row:M,$index:A,store:P,expanded:U})])])]]:(console.error("[Element Error]renderExpanded is required."),L):[[L]]}else if(Object.keys(B.value).length){V();const U=io(M,W.value);let L=B.value[U],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(M,A,I)];if(L){let re=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=io(ee,W.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)),re++,X.push(S(ee,A+re,de)),L){const le=Y.value[ve]||ee[Z.value];z(le,L)}})};L.display=!0;const ge=Y.value[U]||M[Z.value];z(ge,L)}return X}else return S(M,A,void 0)},tooltipContent:c,tooltipTrigger:d}}const sce={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 ice=Q({name:"ElTableBody",props:sce,setup(e){const t=at(),n=ze(si),o=Re("table"),{wrappedRowRender:r,tooltipContent:s,tooltipTrigger:i}=rce(e),{onColumnsChange:l,onScrollableChange:a}=$O(n),u=[];return Me(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,M;return((E=y[x])==null?void 0:E.colSpan)>1&&(v=(M=y[x])==null?void 0:M.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){au(x[_],"hover-cell"),u.push(x[_]);break}m--}})}else u.forEach(v=>Ys(v,"hover-cell")),u.length=0;!e.store.states.isComplex.value||!xt||gY(()=>{const v=h[d],w=h[c];v&&!v.classList.contains("hover-fixed-row")&&Ys(v,"hover-row"),w&&au(w,"hover-row")})}),oi(()=>{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 lce(){const e=ze(si),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 ace(e){const{columns:t}=lce(),n=Re("table");return{getCellClasses:(s,i)=>{const l=s[i],a=[n.e("cell"),l.id,l.align,l.labelClassName,...G3(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=Y3(i,s.fixed,e.store);return ld(l,"left"),ld(l,"right"),l},columns:t}}var uce=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}=ace(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 cce(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 dce(e,t,n,o){const r=q(!1),s=q(null),i=q(!1),l=L=>{i.value=L},a=q({width:null,height:null,headerHeight:null}),u=q(!1),c={display:"inline-block",verticalAlign:"middle"},d=q(),f=q(0),p=q(0),h=q(0),m=q(0),y=q(0);ls(()=>{t.setHeight(e.height)}),ls(()=>{t.setMaxHeight(e.maxHeight)}),Me(()=>[e.currentRowKey,n.states.rowKey],([L,I])=>{!g(I)||!g(L)||n.setCurrentRowKey(`${L}`)},{immediate:!0}),Me(()=>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:re}=I;Math.abs(X)>=Math.abs(re)&&(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(re=>!re.startsWith("is-scrolling-"));X.push(t.scrollX.value?I:"is-scrolling-none"),L.className=X.join(" ")},M=L=>{const{tableWrapper:I}=o.refs;E(I,L)},A=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";A(xe)||M(xe);return}const L=o.refs.scrollBarRef.wrapRef;if(!L)return;const{scrollLeft:I,offsetWidth:X,scrollWidth:re}=L,{headerWrapper:z,footerWrapper:ge}=o.refs;z&&(z.scrollLeft=I),ge&&(ge.scrollLeft=I);const Oe=re-X-1;I>=Oe?M("is-scrolling-right"):M(I===0?"is-scrolling-left":"is-scrolling-middle")},N=()=>{o.refs.scrollBarRef&&(o.refs.scrollBarRef.wrapRef&&Rn(o.refs.scrollBarRef.wrapRef,"scroll",P,{passive:!0}),e.fit?Bo(o.vnode.el,V):Rn(window,"resize",V),Bo(o.refs.bodyWrapper,()=>{var L,I;V(),(I=(L=o.refs)==null?void 0:L.scrollBarRef)==null||I.update()}))},V=()=>{var L,I,X,re;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=((re=o.refs.appendWrapper)==null?void 0:re.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),W=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}}),H=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`}:{}),F=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:W,handleFixedMousewheel:(L,I)=>{const X=o.refs.bodyWrapper;if(Math.abs(I.spinY)>0){const re=X.scrollTop;I.pixelY<0&&re!==0&&L.preventDefault(),I.pixelY>0&&X.scrollHeight-X.clientHeight>re&&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:H,scrollbarStyle:F}}function fce(e){const t=q(),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()}),oi(()=>{var o;(o=t.value)==null||o.disconnect()})}var pce={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 xO(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))))}xO.props=["columns","tableLayout"];const hce=()=>{const e=q(),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 mce=1;const gce=Q({name:"ElTable",directives:{Mousewheel:roe},components:{TableHeader:tce,TableBody:ice,TableFooter:uce,ElScrollbar:ks,hColgroup:xO},props:pce,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(si,o);const r=zue(o,e);o.store=r;const s=new Hue({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}=cce(r),{isHidden:y,renderExpanded:v,setDragVisible:w,isGroup:_,handleMouseLeave:S,handleHeaderFooterMousewheel:x,tableSize:E,emptyBlockStyle:M,handleFixedMousewheel:A,resizeProxyVisible:P,bodyWidth:N,resizeState:V,doLayout:B,tableBodyStyles:Y,tableLayout:Z,scrollbarViewStyle:W,tableInnerStyle:H,scrollbarStyle:F}=dce(e,s,r,o),{scrollBarRef:U,scrollTo:L,setScrollLeft:I,setScrollTop:X}=hce(),re=jl(B,50),z=`${n.namespace.value}-table_${mce++}`;o.tableId=z,o.state={isGroup:_,resizeState:V,doLayout:B,debouncedUpdateLayout:re};const ge=R(()=>e.sumText||t("el.table.sumText")),Oe=R(()=>e.emptyText||t("el.table.emptyText"));return fce(o),{ns:n,layout:s,store:r,handleHeaderFooterMousewheel:x,handleMouseLeave:S,tableId:z,tableSize:E,isHidden:y,isEmpty:i,renderExpanded:v,resizeProxyVisible:P,resizeState:V,isGroup:_,bodyWidth:N,tableBodyStyles:Y,emptyBlockStyle:M,debouncedUpdateLayout:re,handleFixedMousewheel:A,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:W,tableInnerStyle:H,scrollbarStyle:F,scrollBarRef:U,scrollTo:L,setScrollLeft:I,setScrollTop:X}}}),vce=["data-prefix"],yce={ref:"hiddenColumns",class:"hidden-columns"};function _ce(e,t,n,o,r,s){const i=oe("hColgroup"),l=oe("table-header"),a=oe("table-body"),u=oe("table-footer"),c=oe("el-scrollbar"),d=Dt("mousewheel");return C(),T("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:et(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:et(e.tableInnerStyle)},[b("div",yce,[he(e.$slots,"default")],512),e.showHeader&&e.tableLayout==="fixed"?Fe((C(),T("div",{key:0,ref:"headerWrapper",class:D(e.ns.e("header-wrapper"))},[b("table",{ref:"tableHeader",class:D(e.ns.e("header")),style:et(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]]):j("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:et({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(),K(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"])):j("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(),K(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"])):j("v-if",!0)],6),e.isEmpty?(C(),T("div",{key:0,ref:"emptyBlock",style:et(e.emptyBlockStyle),class:D(e.ns.e("empty-block"))},[b("span",{class:D(e.ns.e("empty-text"))},[he(e.$slots,"empty",{},()=>[ne(O(e.computedEmptyText),1)])],2)],6)):j("v-if",!0),e.$slots.append?(C(),T("div",{key:1,ref:"appendWrapper",class:D(e.ns.e("append-wrapper"))},[he(e.$slots,"append")],2)):j("v-if",!0)]),_:3},8,["view-style","wrap-style","always"])],2),e.showSummary&&e.tableLayout==="fixed"?Fe((C(),T("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:et(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]]):j("v-if",!0),e.border||e.isGroup?(C(),T("div",{key:2,class:D(e.ns.e("border-left-patch"))},null,2)):j("v-if",!0)],6),Fe(b("div",{ref:"resizeProxy",class:D(e.ns.e("column-resize-proxy"))},null,2),[[en,e.resizeProxyVisible]])],46,vce)}var bce=je(gce,[["render",_ce],["__file","table.vue"]]);const wce={selection:"table-column--selection",expand:"table__expand-column"},Cce={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:""}},kce=e=>wce[e]||"",Sce={selection:{renderHeader({store:e,column:t}){function n(){return e.states.data.value&&e.states.data.value.length===0}return lt(In,{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(In,{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(Us)]})]})},sortable:!1,resizable:!1}};function $ce({row:e,column:t,$index:n}){var o;const r=t.property,s=r&&Gm(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 Ece({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=Us;t.loading&&(a=u3),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 xce(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)&&Me(()=>t[u],c=>{let d=c;u==="width"&&a==="realWidth"&&(d=q3(c)),u==="minWidth"&&a==="realMinWidth"&&(d=bO(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)&&Me(()=>t[u],c=>{n.columnConfig.value[a]=c})})}}}function Tce(e,t,n){const o=at(),r=q(""),s=q(!1),i=q(),l=q(),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=q(q3(e.width)),f=q(bO(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=Sce[x]||{};Object.keys(E).forEach(A=>{const P=E[A];A!=="className"&&P!==void 0&&(S[A]=P)});const M=kce(x);if(M){const A=`${g(a.namespace)}-${M}`;S.className=S.className?`${S.className} ${A}`:A}return S},m=S=>{Array.isArray(S)?S.forEach(E=>x(E)):x(S);function x(E){var M;((M=E==null?void 0:E.type)==null?void 0:M.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||$ce,S.renderCell=E=>{let M=null;if(t.default){const Y=t.default(E);M=Y.some(Z=>Z.type!==Gn)?Y:x(E)}else M=x(E);const{columns:A}=n.value.store.states,P=A.value.findIndex(Y=>Y.type==="default"),N=c.value&&E.cellIndex===P,V=Ece(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(M),lt("div",B,[V,M])}),S},getPropsData:(...S)=>S.reduce((x,E)=>(Array.isArray(E)&&E.forEach(M=>{x[M]=e[M]}),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 Oce=1;var TO=Q({name:"ElTableColumn",components:{ElCheckbox:In},props:Mce,setup(e,{slots:t}){const n=at(),o=q({}),r=R(()=>{let _=n.parent;for(;_&&!_.tableId;)_=_.parent;return _}),{registerNormalWatchers:s,registerComplexWatchers:i}=xce(r,e),{columnId:l,isSubColumn:a,realHeaderAlign:u,columnOrTableParent:c,setColumnWidth:d,setColumnForcedProps:f,setColumnRenders:p,getPropsData:h,getColumnElIndex:m,realAlign:y,updateColumnOrder:v}=Tce(e,t,r),w=c.value;l.value=`${w.tableId||w.columnId}_column_${Oce++}`,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={...Cce[_],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 V=h(["columnKey","label","className","labelClassName","type","renderHeader","formatter","fixed","resizable"],["sortMethod","sortBy","sortOrders"],["selectable","reserveSelection"],["filterMethod","filters","filterMultiple","filterOpened","filteredValue","filterPlacement","filterClassName"]);V=Oue(E,V),V=Aue(p,d,f)(V),o.value=V,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 Y0=Zt(bce,{TableColumn:TO}),Z0=Zn(TO),J0=Symbol("tabsRootContextKey"),Ice=Ke({tabs:{type:Ce(Array),default:()=>Eo([])}}),MO="ElTabBar",Ace=Q({name:MO}),Nce=Q({...Ace,props:Ice,setup(e,{expose:t}){const n=e,o=at(),r=ze(J0);r||ws(MO,"<el-tabs><el-tab-bar /></el-tabs>");const s=Re("tabs"),i=q(),l=q(),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 Me(()=>n.tabs,async()=>{await ot(),u()},{immediate:!0}),Bo(i,()=>u()),t({ref:i,update:u}),(c,d)=>(C(),T("div",{ref_key:"barRef",ref:i,class:D([g(s).e("active-bar"),g(s).is(g(r).props.tabPosition)]),style:et(l.value)},null,6))}});var Pce=je(Nce,[["__file","tab-bar.vue"]]);const Lce=Ke({panes:{type:Ce(Array),default:()=>Eo([])},currentName:{type:[String,Number],default:""},editable:Boolean,type:{type:String,values:["card","border-card",""],default:""},stretch:Boolean}),Rce={tabClick:(e,t,n)=>n instanceof Event,tabRemove:(e,t)=>t instanceof Event},S8="ElTabNav",Dce=Q({name:S8,props:Lce,emits:Rce,setup(e,{expose:t,emit:n}){const o=at(),r=ze(J0);r||ws(S8,"<el-tabs><tab-nav /></el-tabs>");const s=Re("tabs"),i=Qj(),l=pH(),a=q(),u=q(),c=q(),d=q(),f=q(!1),p=q(0),h=q(!1),m=q(!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 V=N>P?N-P:0;p.value=V},_=()=>{if(!a.value||!u.value)return;const P=u.value[`offset${Cl(y.value)}`],N=a.value[`offset${Cl(y.value)}`],V=p.value;if(P-V<=N)return;const B=P-V>N*2?V+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 V=a.value,B=["top","bottom"].includes(r.props.tabPosition),Y=N.getBoundingClientRect(),Z=V.getBoundingClientRect(),W=B?P.offsetWidth-Z.width:P.offsetHeight-Z.height,H=p.value;let F=H;B?(Y.left<Z.left&&(F=H-(Z.left-Y.left)),Y.right>Z.right&&(F=H+Y.right-Z.right)):(Y.top<Z.top&&(F=H-(Z.top-Y.top)),Y.bottom>Z.bottom&&(F=H+(Y.bottom-Z.bottom))),F=Math.max(F,0),p.value=Math.min(F,W)},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)}`],V=a.value[`offset${Cl(y.value)}`],B=p.value;V<N?(f.value=f.value||{},f.value.prev=B,f.value.next=B+V<N,N-B<V&&(p.value=N-V)):(f.value=!1,B>0&&(p.value=0))},E=P=>{const N=P.code,{up:V,down:B,left:Y,right:Z}=rt;if(![V,B,Y,Z].includes(N))return;const W=Array.from(P.currentTarget.querySelectorAll("[role=tab]:not(.is-disabled)")),H=W.indexOf(P.target);let F;N===Y||N===V?H===0?F=W.length-1:F=H-1:H<W.length-1?F=H+1:F=0,W[F].focus({preventScroll:!0}),W[F].click(),M()},M=()=>{m.value&&(h.value=!0)},A=()=>h.value=!1;return Me(i,P=>{P==="hidden"?m.value=!1:P==="visible"&&setTimeout(()=>m.value=!0,50)}),Me(l,P=>{P?setTimeout(()=>m.value=!0,50):m.value=!1}),Bo(c,x),Ct(()=>setTimeout(()=>S(),0)),Vi(()=>x()),t({scrollToActiveTab:S,removeFocus:A}),Me(()=>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(uu,null,null)]})]),k("span",{class:[s.e("nav-next"),s.is("disabled",!f.value.next)],onClick:_},[k(Ne,null,{default:()=>[k(Us,null,null)]})])]:null,N=e.panes.map((V,B)=>{var Y,Z,W,H;const F=V.uid,U=V.props.disabled,L=(Z=(Y=V.props.name)!=null?Y:V.index)!=null?Z:`${B}`,I=!U&&(V.isClosable||e.editable);V.index=`${B}`;const X=I?k(Ne,{class:"is-icon-close",onClick:ge=>n("tabRemove",V,ge)},{default:()=>[k(Zs,null,null)]}):null,re=((H=(W=V.slots).label)==null?void 0:H.call(W))||V.props.label,z=!U&&V.active?0:-1;return k("div",{ref:`tab-${F}`,class:[s.e("item"),s.is(r.props.tabPosition),s.is("active",V.active),s.is("disabled",U),s.is("closable",I),s.is("focus",h.value)],id:`tab-${L}`,key:`tab-${F}`,"aria-controls":`pane-${L}`,role:"tab","aria-selected":V.active,tabindex:z,onFocus:()=>M(),onBlur:()=>A(),onClick:ge=>{A(),n("tabClick",V,L,ge)},onKeydown:ge=>{I&&(ge.code===rt.delete||ge.code===rt.backspace)&&n("tabRemove",V,ge)}},[re,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(Pce,{ref:d,tabs:[...e.panes]},null),N])])])}}}),Vce=Ke({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}),dy=e=>tt(e)||_t(e),Fce={[Jt]:e=>dy(e),tabClick:(e,t)=>t instanceof Event,tabChange:e=>dy(e),edit:(e,t)=>["remove","add"].includes(t),tabRemove:e=>dy(e),tabAdd:()=>!0},Bce=Q({name:"ElTabs",props:Vce,emits:Fce,setup(e,{emit:t,slots:n,expose:o}){var r;const s=Re("tabs"),{children:i,addChild:l,removeChild:a}=CQ(at(),"ElTabPane"),u=q(),c=q((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 Me(()=>e.modelValue,m=>d(m)),Me(c,async()=>{var m;await ot(),(m=u.value)==null||m.scrollToActiveTab()}),wt(J0,{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(c3,null,null)]})]):null,v=k("div",{class:[s.e("header"),s.is(e.tabPosition)]},[y,k(Dce,{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]])}}}),zce=Ke({label:{type:String,default:""},name:{type:[String,Number]},closable:Boolean,disabled:Boolean,lazy:Boolean}),jce=["id","aria-hidden","aria-labelledby"],OO="ElTabPane",Hce=Q({name:OO}),Uce=Q({...Hce,props:zce,setup(e){const t=e,n=at(),o=Kr(),r=ze(J0);r||ws(OO,"usage: <el-tabs><el-tab-pane /></el-tabs/>");const s=Re("tab-pane"),i=q(),l=R(()=>t.closable||r.props.closable),a=k6(()=>{var p;return r.currentName.value===((p=t.name)!=null?p:i.value)}),u=q(a.value),c=R(()=>{var p;return(p=t.name)!=null?p:i.value}),d=k6(()=>!t.lazy||u.value||a.value);Me(a,p=>{p&&(u.value=!0)});const f=Vn({uid:n.uid,slots:o,props:t,paneName:c,active:a,index:i,isClosable:l});return Ct(()=>{r.registerPane(f)}),oi(()=>{r.unregisterPane(f.uid)}),(p,h)=>g(d)?Fe((C(),T("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,jce)),[[en,g(a)]]):j("v-if",!0)}});var IO=je(Uce,[["__file","tab-pane.vue"]]);const AO=Zt(Bce,{TabPane:IO}),NO=Zn(IO),Wce=Ke({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},fy=(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)}`,Kce=(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)},qce=Q({name:"ElTimeSelect"}),Gce=Q({...qce,props:Wce,emits:["change","blur","focus","update:modelValue"],setup(e,{expose:t}){const n=e;ut.extend(aM);const{Option:o}=vr,r=Re("input"),s=q(),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&&fy(w,c.value)<=0;)_=ut(w,"HH:mm").locale(l.value).format(n.format),v.push({value:_,disabled:fy(w,f.value||"-1:-1")<=0||fy(w,p.value||"100:100")>=0}),w=Kce(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(),K(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(),K(g(Ne),{key:0,class:D(g(r).e("prefix-icon"))},{default:$(()=>[(C(),K(Lt(v.prefixIcon)))]),_:1},8,["class"])):j("v-if",!0)]),default:$(()=>[(C(!0),T(fe,null,nt(g(h),_=>(C(),K(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 l1=je(Gce,[["__file","time-select.vue"]]);l1.install=e=>{e.component(l1.name,l1)};const Yce=l1,PO=Yce,LO=Symbol("uploadContextKey"),Zce="ElUpload";class Jce 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 Jce(o,n.status,t.method,e)}function Xce(e){const t=e.responseText||e.response;if(!t)return t;try{return JSON.parse(t)}catch{return t}}const Qce=e=>{typeof XMLHttpRequest>"u"&&ws(Zce,"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))Te(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(Xce(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))To(i)||t.setRequestHeader(s,String(i));return t.send(o),t},RO=["text","picture","picture-card"];let ede=1;const Eb=()=>Date.now()+ede++,DO=Ke({action:{type:String,default:"#"},headers:{type:Ce(Object)},method:{type:String,default:"post"},data:{type:Ce([Object,Function,Promise]),default:()=>Eo({})},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:()=>Eo([])},autoUpload:{type:Boolean,default:!0},listType:{type:String,values:RO,default:"text"},httpRequest:{type:Ce(Function),default:Qce},disabled:Boolean,limit:Number}),tde=Ke({...DO,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)}}),nde=Ke({files:{type:Ce(Array),default:()=>Eo([])},disabled:{type:Boolean,default:!1},handlePreview:{type:Ce(Function),default:yt},listType:{type:String,values:RO,default:"text"},crossorigin:{type:Ce(String)}}),ode={remove:e=>!!e},rde=["onKeydown"],sde=["src","crossorigin"],ide=["onClick"],lde=["title"],ade=["onClick"],ude=["onClick"],cde=Q({name:"ElUploadList"}),dde=Q({...cde,props:nde,emits:ode,setup(e,{emit:t}){const n=e,{t:o}=Kt(),r=Re("upload"),s=Re("icon"),i=Re("list"),l=Gr(),a=q(!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(),K(k0,{tag:"ul",class:D(g(u)),name:g(i).b()},{default:$(()=>[(C(!0),T(fe,null,nt(d.files,p=>(C(),T("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(),T("img",{key:0,class:D(g(r).be("list","item-thumbnail")),src:p.url,crossorigin:d.crossorigin,alt:""},null,10,sde)):j("v-if",!0),p.status==="uploading"||d.listType!=="picture-card"?(C(),T("div",{key:1,class:D(g(r).be("list","item-info"))},[b("a",{class:D(g(r).be("list","item-name")),onClick:Je(h=>d.handlePreview(p),["prevent"])},[k(g(Ne),{class:D(g(s).m("document"))},{default:$(()=>[k(g(cZ))]),_:1},8,["class"]),b("span",{class:D(g(r).be("list","item-file-name")),title:p.name},O(p.name),11,lde)],10,ide),p.status==="uploading"?(C(),K(g(yO),{key:0,type:d.listType==="picture-card"?"circle":"line","stroke-width":d.listType==="picture-card"?6:2,percentage:Number(p.percentage),style:et(d.listType==="picture-card"?"":"margin-top: 0.5rem")},null,8,["type","stroke-width","percentage","style"])):j("v-if",!0)],2)):j("v-if",!0),b("label",{class:D(g(r).be("list","item-status-label"))},[d.listType==="text"?(C(),K(g(Ne),{key:0,class:D([g(s).m("upload-success"),g(s).m("circle-check")])},{default:$(()=>[k(g(l3))]),_:1},8,["class"])):["picture-card","picture"].includes(d.listType)?(C(),K(g(Ne),{key:1,class:D([g(s).m("upload-success"),g(s).m("check")])},{default:$(()=>[k(g(Yx))]),_:1},8,["class"])):j("v-if",!0)],2),g(l)?j("v-if",!0):(C(),K(g(Ne),{key:2,class:D(g(s).m("close")),onClick:h=>c(p)},{default:$(()=>[k(g(Zs))]),_:2},1032,["class","onClick"])),j(" Due to close btn only appears when li gets focused disappears after li gets blurred, thus keyboard navigation can never reach close btn"),j(" This is a bug which needs to be fixed "),j(" TODO: Fix the incorrect navigation interaction "),g(l)?j("v-if",!0):(C(),T("i",{key:3,class:D(g(s).m("close-tip"))},O(g(o)("el.upload.deleteTip")),3)),d.listType==="picture-card"?(C(),T("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(oT))]),_:1},8,["class"])],10,ade),g(l)?j("v-if",!0):(C(),T("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,ude))],2)):j("v-if",!0)])],42,rde))),128)),he(d.$slots,"append")]),_:3},8,["class","name"]))}});var x8=je(dde,[["__file","upload-list.vue"]]);const fde=Ke({disabled:{type:Boolean,default:!1}}),pde={file:e=>Te(e)},hde=["onDrop","onDragover"],VO="ElUploadDrag",mde=Q({name:VO}),gde=Q({...mde,props:fde,emits:pde,setup(e,{emit:t}){ze(LO)||ws(VO,"usage: <el-upload><el-upload-dragger /></el-upload>");const o=Re("upload"),r=q(!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(),T("div",{class:D([g(o).b("dragger"),g(o).is("dragover",r.value)]),onDrop:Je(i,["prevent"]),onDragover:Je(l,["prevent"]),onDragleave:u[0]||(u[0]=Je(c=>r.value=!1,["prevent"]))},[he(a.$slots,"default")],42,hde))}});var vde=je(gde,[["__file","upload-dragger.vue"]]);const yde=Ke({...DO,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}}),_de=["onKeydown"],bde=["name","multiple","accept"],wde=Q({name:"ElUploadContent",inheritAttrs:!1}),Cde=Q({...wde,props:yde,setup(e,{expose:t}){const n=e,o=Re("upload"),r=Gr(),s=Mn({}),i=Mn(),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 M=E;M.uid=Eb(),S(M),y&&a(M)}},a=async m=>{if(i.value.value="",!n.beforeUpload)return c(m);let y,v={};try{const _=n.data,S=n.beforeUpload(m);v=ig(n.data)?i5(n.data):n.data,y=await S,ig(n.data)&&Hl(_,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)=>Qe(m)?m(y):m,c=async(m,y)=>{const{headers:v,data:w,method:_,withCredentials:S,name:x,action:E,onProgress:M,onSuccess:A,onError:P,httpRequest:N}=n;try{y=await u(y??w,m)}catch{n.onRemove(m);return}const{uid:V}=m,B={headers:v||{},withCredentials:S,file:m,data:y,method:_,filename:x,action:E,onProgress:Z=>{M(Z,m)},onSuccess:Z=>{A(Z,m),delete s.value[V]},onError:Z=>{P(Z,m),delete s.value[V]}},Y=N(B);s.value[V]=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=>{yY(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(),T("div",{class:D([g(o).b(),g(o).m(m.listType),g(o).is("drag",m.drag)]),tabindex:"0",onClick:f,onKeydown:Pt(Je(p,["self"]),["enter","space"])},[m.drag?(C(),K(vde,{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]=Je(()=>{},["stop"]))},null,42,bde)],42,_de))}});var T8=je(Cde,[["__file","upload-content.vue"]]);const M8="ElUpload",O8=e=>{var t;(t=e.url)!=null&&t.startsWith("blob:")&&URL.revokeObjectURL(e.url)},kde=(e,t)=>{const n=fH(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=>{To(f.uid)&&(f.uid=Eb());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(M8,"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 Me(()=>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}))}),Me(n,f=>{for(const p of f)p.uid||(p.uid=Eb()),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}},Sde=Q({name:"ElUpload"}),$de=Q({...Sde,props:tde,setup(e,{expose:t}){const n=e,o=Gr(),r=Mn(),{abort:s,submit:i,clearFiles:l,uploadFiles:a,handleStart:u,handleError:c,handleRemove:d,handleSuccess:f,handleProgress:p,revokeFileObjectURL:h}=kde(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(LO,{accept:pn(n,"accept")}),t({abort:s,submit:i,clearFiles:l,handleStart:u,handleRemove:d}),(v,w)=>(C(),T("div",null,[g(m)&&v.showFileList?(C(),K(x8,{key:0,disabled:g(o),"list-type":v.listType,files:g(a),crossorigin:v.crossorigin,"handle-preview":v.onPreview,onRemove:g(d)},Bl({append:$(()=>[k(T8,un({ref_key:"uploadRef",ref:r},g(y)),{default:$(()=>[v.$slots.trigger?he(v.$slots,"trigger",{key:0}):j("v-if",!0),!v.$slots.trigger&&v.$slots.default?he(v.$slots,"default",{key:1}):j("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"])):j("v-if",!0),!g(m)||g(m)&&!v.showFileList?(C(),K(T8,un({key:1,ref_key:"uploadRef",ref:r},g(y)),{default:$(()=>[v.$slots.trigger?he(v.$slots,"trigger",{key:0}):j("v-if",!0),!v.$slots.trigger&&v.$slots.default?he(v.$slots,"default",{key:1}):j("v-if",!0)]),_:3},16)):j("v-if",!0),v.$slots.trigger?he(v.$slots,"default",{key:2}):j("v-if",!0),he(v.$slots,"tip"),!g(m)&&v.showFileList?(C(),K(x8,{key:3,disabled:g(o),"list-type":v.listType,files:g(a),crossorigin:v.crossorigin,"handle-preview":v.onPreview,onRemove:g(d)},Bl({_:2},[v.$slots.file?{name:"default",fn:$(({file:_})=>[he(v.$slots,"file",{file:_})])}:void 0]),1032,["disabled","list-type","files","crossorigin","handle-preview","onRemove"])):j("v-if",!0)]))}});var Ede=je($de,[["__file","upload.vue"]]);const FO=Zt(Ede);function xde(e){let t;const n=q(!1),o=Vn({...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()):(Ys(f,p.bm("parent","relative")),f.removeAttribute("loading-number")),Ys(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=Cw(Q({name:"ElLoading",setup(f,{expose:p}){const{ns:h,zIndex:m}=O3("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:$(()=>[Fe(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{...ni(o),setText:r,removeElLoadingChild:i,close:l,handleAfterLeave:a,vm:d,get $el(){return d.$el}}}let wm;const xb=function(e={}){if(!xt)return;const t=Tde(e);if(t.fullscreen&&wm)return wm;const n=xde({...t,closed:()=>{var r;(r=t.closed)==null||r.call(t),t.fullscreen&&(wm=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&&(wm=n),n},Tde=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)?Ys(t,o.bm("parent","relative")):au(t,o.bm("parent","relative")),e.fullscreen&&e.lock?au(t,o.bm("parent","hidden")):Ys(t,o.bm("parent","hidden"))},a1=Symbol("ElLoading"),A8=(e,t)=>{var n,o,r,s;const i=t.instance,l=f=>pt(t.value)?t.value[f]:void 0,a=f=>{const p=tt(f)&&(i==null?void 0:i[f])||f;return p&&q(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[a1]={options:d,instance:xb(d)}},Ode=(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[a1];t.oldValue!==t.value&&(t.value&&!t.oldValue?A8(e,t):t.value&&t.oldValue?pt(t.value)&&Ode(t.value,n.options):n==null||n.instance.close())},unmounted(e){var t;(t=e[a1])==null||t.instance.close(),e[a1]=null}},Ide={install(e){e.directive("loading",N8),e.config.globalProperties.$loading=xb},directive:N8,service:xb},Ade=Q({name:"ElMessageBox",directives:{TrapFocus:Jne},components:{ElButton:ct,ElFocusTrap:U0,ElInput:Tt,ElOverlay:z3,ElIcon:Ne,...vJ},inheritAttrs:!1,props:{buttonSize:{type:String,validator:wJ},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}=O3("message-box",R(()=>e.buttonSize)),{t:i}=n,{nextZIndex:l}=o,a=q(!1),u=Vn({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 H=u.type;return{[r.bm("icon",H)]:H&&Ag[H]}}),d=Hr(),f=Hr(),p=R(()=>u.icon||Ag[u.type]||""),h=R(()=>!!u.message),m=q(),y=q(),v=q(),w=q(),_=q(),S=R(()=>u.confirmButtonClass);Me(()=>u.inputValue,async H=>{await ot(),e.boxType==="prompt"&&H!==null&&B()},{immediate:!0}),Me(()=>a.value,H=>{var F,U;H&&(e.boxType!=="prompt"&&(u.autofocus?v.value=(U=(F=_.value)==null?void 0:F.$el)!=null?U:m.value:v.value=m.value),u.zIndex=l()),e.boxType==="prompt"&&(H?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);uT(m,y,x,E),Ct(async()=>{await ot(),e.closeOnHashChange&&window.addEventListener("hashchange",M)}),En(()=>{e.closeOnHashChange&&window.removeEventListener("hashchange",M)});function M(){a.value&&(a.value=!1,ot(()=>{u.action&&t("action",u.action)}))}const A=()=>{e.closeOnClickModal&&V(u.distinguishCancelAndClose?"close":"cancel")},P=k3(A),N=H=>{if(u.inputType!=="textarea")return H.preventDefault(),V("confirm")},V=H=>{var F;e.boxType==="prompt"&&H==="confirm"&&!B()||(u.action=H,u.beforeClose?(F=u.beforeClose)==null||F.call(u,H,u,M):M())},B=()=>{if(e.boxType==="prompt"){const H=u.inputPattern;if(H&&!H.test(u.inputValue||""))return u.editorErrorMessage=u.inputErrorMessage||i("el.messagebox.error"),u.validateError=!0,!1;const F=u.inputValidator;if(typeof F=="function"){const U=F(u.inputValue);if(U===!1)return u.editorErrorMessage=u.inputErrorMessage||i("el.messagebox.error"),u.validateError=!0,!1;if(typeof U=="string")return u.editorErrorMessage=U,u.validateError=!0,!1}}return u.editorErrorMessage="",u.validateError=!1,!0},Y=()=>{const H=w.value.$refs;return H.input||H.textarea},Z=()=>{V("close")},W=()=>{e.closeOnPressEscape&&Z()};return e.lockScroll&&fT(a),{...ni(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:M,handleClose:Z,onCloseRequested:W,handleWrapperClick:A,handleInputEnter:N,handleAction:V,t:i}}}),Nde=["aria-label","aria-describedby"],Pde=["aria-label"],Lde=["id"];function Rde(e,t,n,o,r,s){const i=oe("el-icon"),l=oe("close"),a=oe("el-input"),u=oe("el-button"),c=oe("el-focus-trap"),d=oe("el-overlay");return C(),K(_r,{name:"fade-in-linear",onAfterLeave:t[11]||(t[11]=f=>e.$emit("vanish")),persisted:""},{default:$(()=>[Fe(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:et(e.customStyle),tabindex:"-1",onClick:t[7]||(t[7]=Je(()=>{},["stop"]))},[e.title!==null&&e.title!==void 0?(C(),T("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(),K(i,{key:0,class:D([e.ns.e("status"),e.typeClass])},{default:$(()=>[(C(),K(Lt(e.iconComponent)))]),_:1},8,["class"])):j("v-if",!0),b("span",null,O(e.title),1)],2),e.showClose?(C(),T("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(Je(f=>e.handleAction(e.distinguishCancelAndClose?"close":"cancel"),["prevent"]),["enter"]))},[k(i,{class:D(e.ns.e("close"))},{default:$(()=>[k(l)]),_:1},8,["class"])],42,Pde)):j("v-if",!0)],2)):j("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(),K(i,{key:0,class:D([e.ns.e("status"),e.typeClass])},{default:$(()=>[(C(),K(Lt(e.iconComponent)))]),_:1},8,["class"])):j("v-if",!0),e.hasMessage?(C(),T("div",{key:1,class:D(e.ns.e("message"))},[he(e.$slots,"default",{},()=>[e.dangerouslyUseHTMLString?(C(),K(Lt(e.showInput?"label":"p"),{key:1,for:e.showInput?e.inputId:void 0,innerHTML:e.message},null,8,["for","innerHTML"])):(C(),K(Lt(e.showInput?"label":"p"),{key:0,for:e.showInput?e.inputId:void 0},{default:$(()=>[ne(O(e.dangerouslyUseHTMLString?"":e.message),1)]),_:1},8,["for"]))])],2)):j("v-if",!0)],2),Fe(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:et({visibility:e.editorErrorMessage?"visible":"hidden"})},O(e.editorErrorMessage),7)],2),[[en,e.showInput]])],10,Lde),b("div",{class:D(e.ns.e("btns"))},[e.showCancelButton?(C(),K(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(Je(f=>e.handleAction("cancel"),["prevent"]),["enter"]))},{default:$(()=>[ne(O(e.cancelButtonText||e.t("el.messagebox.cancel")),1)]),_:1},8,["loading","class","round","size"])):j("v-if",!0),Fe(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(Je(f=>e.handleAction("confirm"),["prevent"]),["enter"]))},{default:$(()=>[ne(O(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,Nde)]),_:3},8,["z-index","overlay-class","mask"]),[[en,e.visible]])]),_:3})}var Dde=je(Ade,[["render",Rde],["__file","index.vue"]]);const Fp=new Map,Vde=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(Dde,e,Qe(e.message)||yo(e.message)?{default:Qe(e.message)?e.message:()=>e.message}:null);return o.appContext=n,Ni(o,t),Vde(e).appendChild(t.firstElementChild),o.component},Bde=()=>document.createElement("div"),zde=(e,t)=>{const n=Bde();e.onVanish=()=>{Ni(null,n),Fp.delete(r)},e.onAction=s=>{const i=Fp.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=zde(e,t??xd._context);Fp.set(s,{options:e,callback:n,resolve:o,reject:r})})}const jde=["alert","confirm","prompt"],Hde={alert:{closeOnPressEscape:!1,closeOnClickModal:!1},confirm:{showCancelButton:!0},prompt:{showCancelButton:!0,showInput:!0}};jde.forEach(e=>{xd[e]=Ude(e)});function Ude(e){return(t,n,o,r)=>{let s="";return pt(n)?(o=n,s=""):Uo(n)?s="":s=n,xd(Object.assign({title:s,message:t,type:"",...Hde[e]},o,{boxType:e}),r)}}xd.close=()=>{Fp.forEach((e,t)=>{t.doClose()}),Fp.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 py=nl,BO=["success","info","warning","error"],Wde=Ke({customClass:{type:String,default:""},dangerouslyUseHTMLString:{type:Boolean,default:!1},duration:{type:Number,default:4500},icon:{type:Io},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:[...BO,""],default:""},zIndex:Number}),Kde={destroy:()=>!0},qde=["id"],Gde=["textContent"],Yde={key:0},Zde=["innerHTML"],Jde=Q({name:"ElNotification"}),Xde=Q({...Jde,props:Wde,emits:Kde,setup(e,{expose:t}){const n=e,{ns:o,zIndex:r}=O3("notification"),{nextZIndex:s,currentZIndex:i}=r,{Close:l}=sT,a=q(!1);let u;const c=R(()=>{const _=n.type;return _&&Ag[n.type]?o.m(_):""}),d=R(()=>n.type&&Ag[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}=B_(()=>{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}),Rn(document,"keydown",w),t({visible:a,close:v}),(_,S)=>(C(),K(_r,{name:g(o).b("fade"),onBeforeLeave:_.onClose,onAfterLeave:S[1]||(S[1]=x=>_.$emit("destroy")),persisted:""},{default:$(()=>[Fe(b("div",{id:_.id,class:D([g(o).b(),_.customClass,g(f)]),style:et(g(h)),role:"alert",onMouseenter:y,onMouseleave:m,onClick:S[0]||(S[0]=(...x)=>_.onClick&&_.onClick(...x))},[g(d)?(C(),K(g(Ne),{key:0,class:D([g(o).e("icon"),g(c)])},{default:$(()=>[(C(),K(Lt(g(d))))]),_:1},8,["class"])):j("v-if",!0),b("div",{class:D(g(o).e("group"))},[b("h2",{class:D(g(o).e("title")),textContent:O(_.title)},null,10,Gde),Fe(b("div",{class:D(g(o).e("content")),style:et(_.title?void 0:{margin:0})},[he(_.$slots,"default",{},()=>[_.dangerouslyUseHTMLString?(C(),T(fe,{key:1},[j(" Caution here, message could've been compromised, never use user's input as message "),b("p",{innerHTML:_.message},null,8,Zde)],2112)):(C(),T("p",Yde,O(_.message),1))])],6),[[en,_.message]]),_.showClose?(C(),K(g(Ne),{key:0,class:D(g(o).e("closeBtn")),onClick:Je(v,["stop"])},{default:$(()=>[k(g(l))]),_:1},8,["class","onClick"])):j("v-if",!0)],2)],46,qde),[[en,a.value]])]),_:3},8,["name","onBeforeLeave"]))}});var Qde=je(Xde,[["__file","notification.vue"]]);const Bg={"top-left":[],"top-right":[],"bottom-left":[],"bottom-right":[]},Tb=16;let efe=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;Bg[n].forEach(({vm:c})=>{var d;o+=(((d=c.el)==null?void 0:d.offsetHeight)||0)+Tb}),o+=Tb;const r=`notification_${efe++}`,s=e.onClose,i={...e,offset:o,id:r,onClose:()=>{tfe(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(Qde,i,yo(i.message)?{default:()=>i.message}:null);return u.appContext=t??ad._context,u.props.onDestroy=()=>{Ni(null,a)},Ni(u,a),Bg[n].push({vm:u}),l.appendChild(a.firstElementChild),{close:()=>{u.component.exposed.visible.value=!1}}};BO.forEach(e=>{ad[e]=(t={})=>((typeof t=="string"||yo(t))&&(t={message:t}),ad({...t,type:e}))});function tfe(e,t,n){const o=Bg[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-Tb;d.props.offset=f}}function nfe(){for(const e of Object.values(Bg))e.forEach(({vm:t})=>{t.component.exposed.visible.value=!1})}ad.closeAll=nfe;ad._context=null;const ofe=yJ(ad,"$notify"),We=(e,t)=>{const n=e.__vccOpts||e;for(const[o,r]of t)n[o]=r;return n},rfe={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>'},{label:this.$t("Privacy Settings"),route:"privacy_settings",icon_svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="20" height="20" color="currentColor" fill="none"><path d="M10.8338 1.53871C11.5609 1.15376 12.4391 1.15376 13.1662 1.53871C14.3681 2.17509 16.8304 3.32075 19.7836 3.8341C20.873 4.02349 21.75 4.95478 21.75 6.12325V11.0511C21.75 14.5419 19.9704 17.2085 18.0079 19.0834C16.0479 20.9559 13.848 22.0975 12.8466 22.5619C12.3057 22.8127 11.6943 22.8127 11.1534 22.5619C10.152 22.0975 7.95205 20.9559 5.99214 19.0834C4.02964 17.2085 2.25 14.5419 2.25 11.0511V6.12325C2.25 4.95478 3.12696 4.02349 4.21644 3.8341C7.1696 3.32075 9.63189 2.17509 10.8338 1.53871Z" fill="currentColor" /></svg>'}]}},watch:{},methods:{},created(){this.isSmallScreen=window.innerWidth<=1024},mounted(){}},sfe={class:"fcom_general_menu"},ife=["href"],lfe={class:"el-icon"},afe={class:"fcom_communities_menu"},ufe={style:{"margin-left":"18px","font-size":"0.875rem","font-weight":"bold","margin-bottom":"10px",color:"currentColor"}},cfe={style:{"margin-bottom":"30px"},class:"fcom_general_menu"},dfe={class:"community_avatar"},ffe={class:"fcom_shape"},pfe={class:"community_name"},hfe={style:{"margin-left":"18px","font-size":"0.875rem","font-weight":"bold","margin-bottom":"10px",color:"currentColor"}},mfe={class:"fcom_general_menu"},gfe={class:"community_avatar"},vfe={class:"fcom_shape"},yfe=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),_fe={class:"community_name"};function bfe(e,t,n,o,r,s){const i=oe("router-view"),l=oe("Back"),a=Ne,u=oe("router-link");return C(),T(fe,null,[k(i,{class:D(e.appVars.route_classes)},null,8,["class"]),(C(),K(_s,{to:"#fcom_menu_sidebar"},[b("ul",sfe,[b("li",null,[b("a",{href:e.appVars.portal_url},[b("i",lfe,[k(l)]),b("span",null,O(e.$t("Back to home")),1)],8,ife)])]),b("div",afe,[b("h4",ufe,O(e.$t("Portal Settings")),1),b("ul",cfe,[(C(!0),T(fe,null,nt(r.menuItems,c=>(C(),T("li",{key:c.name,class:D("course_inner_menu_"+c.name)},[k(u,{to:{name:c.route}},{default:$(()=>[b("div",dfe,[b("span",ffe,[k(a,{innerHTML:c.icon_svg},null,8,["innerHTML"])])]),b("span",pfe,O(c.label),1)]),_:2},1032,["to"])],2))),128))]),e.hasFeature("has_course")?(C(),T(fe,{key:0},[b("h4",hfe,O(e.$t("Course Management")),1),b("ul",mfe,[b("li",null,[k(u,{to:{name:"manage_courses"}},{default:$(()=>[b("div",gfe,[b("span",vfe,[k(a,null,{default:$(()=>[yfe]),_:1})])]),b("span",_fe,O(e.$t("Manage Courses")),1)]),_:1})])])],64)):j("",!0)])]))],64)}const wfe=We(rfe,[["render",bfe]]),Cfe={name:"SettingsRoute",components:{},data(){return{loading:!1}}};function kfe(e,t,n,o,r,s){const i=oe("router-view");return C(),K(i)}const Sfe=We(Cfe,[["render",kfe]]),$fe={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 Efe(e,t,n,o,r,s){const i=ct,l=FO,a=oe("CloseBold"),u=Ne,c=Dt("loading");return C(),T(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",{},()=>[Fe((C(),K(i,{disabled:r.loading,text:n.isTextBtn,class:"fcom_plain_button"},{default:$(()=>[ne(O(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(),K(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(),K(u,{key:0},{default:$(()=>[k(a)]),_:1})):j("",!0),b("span",null,O(e.$t("Remove")),1)]),_:1},8,["text"])):j("",!0)],64)}const Td=We($fe,[["render",Efe]]);function xfe(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var kh=xfe,Tfe=typeof On=="object"&&On&&On.Object===Object&&On,zO=Tfe,Mfe=zO,Ofe=typeof self=="object"&&self&&self.Object===Object&&self,Ife=Mfe||Ofe||Function("return this")(),zi=Ife,Afe=zi,Nfe=function(){return Afe.Date.now()},Pfe=Nfe,Lfe=/\s/;function Rfe(e){for(var t=e.length;t--&&Lfe.test(e.charAt(t)););return t}var Dfe=Rfe,Vfe=Dfe,Ffe=/^\s+/;function Bfe(e){return e&&e.slice(0,Vfe(e)+1).replace(Ffe,"")}var zfe=Bfe,jfe=zi,Hfe=jfe.Symbol,jO=Hfe,P8=jO,HO=Object.prototype,Ufe=HO.hasOwnProperty,Wfe=HO.toString,Kd=P8?P8.toStringTag:void 0;function Kfe(e){var t=Ufe.call(e,Kd),n=e[Kd];try{e[Kd]=void 0;var o=!0}catch{}var r=Wfe.call(e);return o&&(t?e[Kd]=n:delete e[Kd]),r}var qfe=Kfe,Gfe=Object.prototype,Yfe=Gfe.toString;function Zfe(e){return Yfe.call(e)}var Jfe=Zfe,L8=jO,Xfe=qfe,Qfe=Jfe,epe="[object Null]",tpe="[object Undefined]",R8=L8?L8.toStringTag:void 0;function npe(e){return e==null?e===void 0?tpe:epe:R8&&R8 in Object(e)?Xfe(e):Qfe(e)}var Sh=npe;function ope(e){return e!=null&&typeof e=="object"}var X0=ope,rpe=Sh,spe=X0,ipe="[object Symbol]";function lpe(e){return typeof e=="symbol"||spe(e)&&rpe(e)==ipe}var ape=lpe,upe=zfe,D8=kh,cpe=ape,V8=0/0,dpe=/^[-+]0x[0-9a-f]+$/i,fpe=/^0b[01]+$/i,ppe=/^0o[0-7]+$/i,hpe=parseInt;function mpe(e){if(typeof e=="number")return e;if(cpe(e))return V8;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=upe(e);var n=fpe.test(e);return n||ppe.test(e)?hpe(e.slice(2),n?2:8):dpe.test(e)?V8:+e}var gpe=mpe,vpe=kh,hy=Pfe,F8=gpe,ype="Expected a function",_pe=Math.max,bpe=Math.min;function wpe(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(ype);t=F8(t)||0,vpe(n)&&(c=!!n.leading,d="maxWait"in n,s=d?_pe(F8(n.maxWait)||0,t):s,f="trailing"in n?!!n.trailing:f);function p(E){var M=o,A=r;return o=r=void 0,u=E,i=e.apply(A,M),i}function h(E){return u=E,l=setTimeout(v,t),c?p(E):i}function m(E){var M=E-a,A=E-u,P=t-M;return d?bpe(P,s-A):P}function y(E){var M=E-a,A=E-u;return a===void 0||M>=t||M<0||d&&A>=s}function v(){var E=hy();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(hy())}function x(){var E=hy(),M=y(E);if(o=arguments,r=this,a=E,M){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 UO=wpe;const Cpe=_o(UO);var kpe=UO,Spe=kh,$pe="Expected a function";function Epe(e,t,n){var o=!0,r=!0;if(typeof e!="function")throw new TypeError($pe);return Spe(n)&&(o="leading"in n?!!n.leading:o,r="trailing"in n?!!n.trailing:r),kpe(e,t,{leading:o,maxWait:t,trailing:r})}var xpe=Epe;const Tpe=_o(xpe),Mpe={name:"ContentLayout",props:["title","content_class","wrapper_class"],data(){return{throttledScrollHandler:null}},created(){this.throttledScrollHandler=Tpe(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}},Ope={key:0,class:"fhr_content_layout_header"},Ipe={role:"region","aria-label":"Actions",class:"fhr_page_actions"};function Ape(e,t,n,o,r,s){const i=ks;return C(),T("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(),T("div",Ope,[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"},O(n.title),1)]),b("div",Ipe,[he(e.$slots,"actions")])])):j("",!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 $s=We(Mpe,[["render",Ape]]),Npe={name:"AppLayout",props:["wrapper_class"]},Ppe={class:"feeds_main"};function Lpe(e,t,n,o,r,s){const i=oe("router-view");return C(),T("div",{class:D([n.wrapper_class,"feeds"])},[b("div",Ppe,[he(e.$slots,"before_route_view"),he(e.$slots,"default",{},()=>[k(i)]),he(e.$slots,"after_route_view")])],2)}const Es=We(Npe,[["render",Lpe]]),Rpe={name:"GeneralSettings",components:{ImageUploader:Td,Layout:$s,AppLayout:Es,CopyDocument:oZ},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"))}},Dpe={class:"settings_router"},Vpe={class:"fhr_content_layout_body"},Fpe={class:"setting_body"},Bpe={class:"settings_title"},zpe={class:"settings_subtitle"},jpe={class:"settings_title"},Hpe={class:"settings_subtitle"},Upe=["src"],Wpe={class:"settings_title"},Kpe={class:"settings_subtitle"},qpe=["src"],Gpe={class:"settings_title"},Ype={class:"settings_subtitle"},Zpe=["src"],Jpe={class:"settings_title"},Xpe={class:"settings_subtitle"},Qpe={class:"fcom_help_text"},ehe={class:"settings_title"},the={class:"settings_subtitle"},nhe={class:"settings_title"},ohe={class:"settings_subtitle"},rhe={class:"help_text"},she={class:"settings_title"},ihe={class:"settings_subtitle"},lhe={class:"settings_title"},ahe={class:"settings_subtitle"},uhe={class:"settings_title"},che={class:"settings_subtitle"};function dhe(e,t,n,o,r,s){const i=ct,l=yh,a=Tt,u=Bn,c=vh,d=oe("image-uploader"),f=In,p=mh,h=ea,m=Ss,y=vr,v=oe("CopyDocument"),w=Ne,_=Fn,S=Jn,x=oe("layout"),E=oe("app-layout");return C(),K(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,O(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])]),default:$(()=>[b("div",Dpe,[b("div",Vpe,[b("div",Fpe,[r.settings?(C(),K(_,{key:0,onSubmit:t[10]||(t[10]=Je(M=>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",Bpe,O(e.$t("Community Title")),1),b("span",zpe,O(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]=M=>r.settings.site_title=M)},null,8,["placeholder","modelValue"])]),_:1})]),_:1})]),_:1}),k(c,{gutter:20,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",jpe,O(e.$t("Site Logo (For Light Background)")),1),b("span",Hpe,O(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(),T("img",{key:0,alt:"",class:"settings_img",src:r.settings.logo},null,8,Upe)):j("",!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]=M=>{r.settings.logo=M})},null,8,["button_text","can_remove"])]),_:1})]),_:1})]),_:1}),k(c,{gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",Wpe,O(e.$t("Site Logo (For Dark Mode)")),1),b("span",Kpe,O(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(),T("img",{key:0,alt:"",class:"settings_img",src:r.settings.white_logo},null,8,qpe)):j("",!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]=M=>{r.settings.white_logo=M})},null,8,["button_text","can_remove"])]),_:1})]),_:1})]),_:1}),k(c,{gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",Gpe,O(e.$t("Default Open Graph Image")),1),b("span",Ype,O(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(),T("img",{key:0,alt:"",style:{"max-height":"100px"},class:"settings_img",src:r.settings.featured_image},null,8,Zpe)):j("",!0),k(d,{additionalData:{resize:!1,max_width:1600,skip_convert:"yes"},button_text:r.settings.featured_image?e.$t("Change"):e.$t("Set Open Graph Image"),can_remove:!!r.settings.featured_image,className:"setting_img_upload",isTextBtn:!1,removeIcon:!1,onUploaded:t[3]||(t[3]=M=>{r.settings.featured_image=M})},null,8,["button_text","can_remove"])]),_:1})]),_:1})]),_:1}),k(c,{gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",Jpe,O(e.$t("Global Post Status")),1),b("span",Xpe,O(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]=M=>r.settings.disable_global_posts=M)},{default:$(()=>[ne(O(e.$t("Enable Global Posts Status Form")),1)]),_:1},8,["modelValue"]),b("div",Qpe,[b("p",null,O(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",ehe,O(e.$t("Portal Access Settings")),1),b("span",the,O(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]=M=>r.settings.access.acess_level=M)},{default:$(()=>[k(p,{value:"public"},{default:$(()=>[ne(O(e.$t("Everyone")),1)]),_:1}),k(p,{value:"logged_in"},{default:$(()=>[ne(O(e.$t("Only Logged In Users")),1)]),_:1}),k(p,{value:"role_based"},{default:$(()=>[ne(O(e.$t("Only Selected User Roles")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1})]),_:1})]),_:1}),s.isRoleBase?(C(),K(c,{key:0,gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",nhe,O(e.$t("User Roles")),1),b("span",ohe,O(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]=M=>r.settings.access.access_roles=M),multiple:""},{default:$(()=>[(C(!0),T(fe,null,nt(r.user_roles,(M,A)=>(C(),K(m,{key:A,label:M,value:A},null,8,["label","value"]))),128))]),_:1},8,["placeholder","modelValue"]),b("span",rhe,O(e.$t("__ALL_ADMIN_ACCESS_DESC")),1)]),_:1})]),_:1})]),_:1})):j("",!0),s.isRoleBase?(C(),K(c,{key:1,gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",she,O(e.$t("Not Matched User Roles")),1),b("span",ihe,O(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]=M=>r.settings.restricted_role_content=M)},null,8,["modelValue"])]),_:1})]),_:1})]),_:1})):j("",!0),r.settings.access.acess_level!="public"?(C(),K(c,{key:2,gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",lhe,O(e.$t("Redirect URL")),1),b("span",ahe,O(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]=M=>r.settings.auth_url=M)},null,8,["modelValue"])]),_:1})]),_:1})]),_:1})):j("",!0),r.settings.access.acess_level!="public"?(C(),K(c,{key:3,gutter:30,class:"setting_row"},{default:$(()=>[k(l,{sm:12},{default:$(()=>[b("p",uhe,O(e.$t("Login URL")),1),b("span",che,O(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]=M=>s.copyToClipboard(s.loginUrl))},{default:$(()=>[k(v)]),_:1}),b("span",null,O(e.$t("Copy")),1)]),_:1},8,["value","placeholder"])]),_:1})]),_:1})]),_:1})):j("",!0),k(c,{gutter:30},{default:$(()=>[k(i,{class:"fcom_primary_button",disabled:r.saving||r.loading,onClick:s.saveSettings},{default:$(()=>[b("span",null,O(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])]),_:1})]),_:1})):r.loading?(C(),K(S,{key:1,animated:!0,rows:10})):j("",!0)])])])]),_:1},8,["title"])]),_:1})}const fhe=We(Rpe,[["render",dhe]]),phe={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()}},hhe={style:{float:"left"}},mhe={style:{float:"right",color:"#8492a6","font-size":"13px"}},ghe={key:1},vhe={class:"dialog_footer"},yhe={key:0},_he={key:1};function bhe(e,t,n,o,r,s){const i=Ss,l=vr,a=Bn,u=In,c=Ooe,d=ct,f=Fn,p=Dt("loading");return C(),K(f,{onSubmit:t[3]||(t[3]=Je(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(),T("p",ghe,O(e.$t("Editing manager role for %s",r.form.editing_user.display_name)),1)):(C(),K(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),T(fe,null,nt(r.users,h=>(C(),K(i,{key:h.ID,label:h.display_name+" ("+h.user_email+")",value:h.ID},{default:$(()=>[b("span",hhe,O(h.display_name),1),b("span",mhe,O(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(O(e.$t("Space Admin (All Access)")),1)]),_:1}),k(u,{disabled:r.form.roles.includes("admin"),value:"moderator"},{default:$(()=>[ne(O(e.$t("Space Moderator")),1)]),_:1},8,["disabled"]),k(u,{disabled:r.form.roles.includes("admin"),value:"course_admin"},{default:$(()=>[ne(O(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(O(e.$t("Course Creator")),1)]),_:1},8,["disabled"])]),_:1},8,["modelValue"])]),_:1},8,["label"]),b("div",vhe,[he(e.$slots,"after_form",{},()=>[Fe((C(),K(d,{class:"fcom_primary_button",disabled:r.adding,onClick:t[2]||(t[2]=h=>s.addManager())},{default:$(()=>[r.form.editing_user?(C(),T("span",yhe,O(e.$t("Update Role")),1)):(C(),T("span",_he,O(e.$t("Add Manager")),1))]),_:1},8,["disabled"])),[[p,r.adding]])])])]),_:3},8,["modelValue"])}const whe=We(phe,[["render",bhe]]);function Che(e,t){for(var n=-1,o=e==null?0:e.length;++n<o&&t(e[n],n,e)!==!1;);return e}var khe=Che;function She(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 $he=She,Ehe=$he,xhe=Ehe(),The=xhe;function Mhe(e,t){for(var n=-1,o=Array(e);++n<e;)o[n]=t(n);return o}var Ohe=Mhe,Ihe=Sh,Ahe=X0,Nhe="[object Arguments]";function Phe(e){return Ahe(e)&&Ihe(e)==Nhe}var Lhe=Phe,B8=Lhe,Rhe=X0,WO=Object.prototype,Dhe=WO.hasOwnProperty,Vhe=WO.propertyIsEnumerable,Fhe=B8(function(){return arguments}())?B8:function(e){return Rhe(e)&&Dhe.call(e,"callee")&&!Vhe.call(e,"callee")},KO=Fhe,Bhe=Array.isArray,Z3=Bhe,zg={exports:{}};function zhe(){return!1}var jhe=zhe;zg.exports;(function(e,t){var n=zi,o=jhe,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})(zg,zg.exports);var qO=zg.exports,Hhe=9007199254740991,Uhe=/^(?:0|[1-9]\d*)$/;function Whe(e,t){var n=typeof e;return t=t??Hhe,!!t&&(n=="number"||n!="symbol"&&Uhe.test(e))&&e>-1&&e%1==0&&e<t}var Khe=Whe,qhe=9007199254740991;function Ghe(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=qhe}var GO=Ghe,Yhe=Sh,Zhe=GO,Jhe=X0,Xhe="[object Arguments]",Qhe="[object Array]",eme="[object Boolean]",tme="[object Date]",nme="[object Error]",ome="[object Function]",rme="[object Map]",sme="[object Number]",ime="[object Object]",lme="[object RegExp]",ame="[object Set]",ume="[object String]",cme="[object WeakMap]",dme="[object ArrayBuffer]",fme="[object DataView]",pme="[object Float32Array]",hme="[object Float64Array]",mme="[object Int8Array]",gme="[object Int16Array]",vme="[object Int32Array]",yme="[object Uint8Array]",_me="[object Uint8ClampedArray]",bme="[object Uint16Array]",wme="[object Uint32Array]",dn={};dn[pme]=dn[hme]=dn[mme]=dn[gme]=dn[vme]=dn[yme]=dn[_me]=dn[bme]=dn[wme]=!0;dn[Xhe]=dn[Qhe]=dn[dme]=dn[eme]=dn[fme]=dn[tme]=dn[nme]=dn[ome]=dn[rme]=dn[sme]=dn[ime]=dn[lme]=dn[ame]=dn[ume]=dn[cme]=!1;function Cme(e){return Jhe(e)&&Zhe(e.length)&&!!dn[Yhe(e)]}var kme=Cme;function Sme(e){return function(t){return e(t)}}var $me=Sme,jg={exports:{}};jg.exports;(function(e,t){var n=zO,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})(jg,jg.exports);var Eme=jg.exports,xme=kme,Tme=$me,z8=Eme,j8=z8&&z8.isTypedArray,Mme=j8?Tme(j8):xme,YO=Mme,Ome=Ohe,Ime=KO,Ame=Z3,Nme=qO,Pme=Khe,Lme=YO,Rme=Object.prototype,Dme=Rme.hasOwnProperty;function Vme(e,t){var n=Ame(e),o=!n&&Ime(e),r=!n&&!o&&Nme(e),s=!n&&!o&&!r&&Lme(e),i=n||o||r||s,l=i?Ome(e.length,String):[],a=l.length;for(var u in e)(t||Dme.call(e,u))&&!(i&&(u=="length"||r&&(u=="offset"||u=="parent")||s&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||Pme(u,a)))&&l.push(u);return l}var Fme=Vme,Bme=Object.prototype;function zme(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||Bme;return e===n}var ZO=zme;function jme(e,t){return function(n){return e(t(n))}}var Hme=jme,Ume=Hme,Wme=Ume(Object.keys,Object),Kme=Wme,qme=ZO,Gme=Kme,Yme=Object.prototype,Zme=Yme.hasOwnProperty;function Jme(e){if(!qme(e))return Gme(e);var t=[];for(var n in Object(e))Zme.call(e,n)&&n!="constructor"&&t.push(n);return t}var JO=Jme,Xme=Sh,Qme=kh,e1e="[object AsyncFunction]",t1e="[object Function]",n1e="[object GeneratorFunction]",o1e="[object Proxy]";function r1e(e){if(!Qme(e))return!1;var t=Xme(e);return t==t1e||t==n1e||t==e1e||t==o1e}var XO=r1e,s1e=XO,i1e=GO;function l1e(e){return e!=null&&i1e(e.length)&&!s1e(e)}var J3=l1e,a1e=Fme,u1e=JO,c1e=J3;function d1e(e){return c1e(e)?a1e(e):u1e(e)}var f1e=d1e,p1e=The,h1e=f1e;function m1e(e,t){return e&&p1e(e,t,h1e)}var g1e=m1e,v1e=J3;function y1e(e,t){return function(n,o){if(n==null)return n;if(!v1e(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 _1e=y1e,b1e=g1e,w1e=_1e,C1e=w1e(b1e),k1e=C1e;function S1e(e){return e}var $1e=S1e,E1e=$1e;function x1e(e){return typeof e=="function"?e:E1e}var T1e=x1e,M1e=khe,O1e=k1e,I1e=T1e,A1e=Z3;function N1e(e,t){var n=A1e(e)?M1e:O1e;return n(e,I1e(t))}var P1e=N1e,L1e=P1e;const du=_o(L1e);function Et(e){return window.fluentComAdmin.i18n[e]||e}const R1e={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")}},D1e={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.")}},V1e={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 B1e=zi,z1e=B1e["__core-js_shared__"],j1e=z1e,my=j1e,H8=function(){var e=/[^.]+$/.exec(my&&my.keys&&my.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function H1e(e){return!!H8&&H8 in e}var U1e=H1e,W1e=Function.prototype,K1e=W1e.toString;function q1e(e){if(e!=null){try{return K1e.call(e)}catch{}try{return e+""}catch{}}return""}var QO=q1e,G1e=XO,Y1e=U1e,Z1e=kh,J1e=QO,X1e=/[\\^$.*+?()[\]{}|]/g,Q1e=/^\[object .+?Constructor\]$/,ege=Function.prototype,tge=Object.prototype,nge=ege.toString,oge=tge.hasOwnProperty,rge=RegExp("^"+nge.call(oge).replace(X1e,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function sge(e){if(!Z1e(e)||Y1e(e))return!1;var t=G1e(e)?rge:Q1e;return t.test(J1e(e))}var ige=sge;function lge(e,t){return e==null?void 0:e[t]}var age=lge,uge=ige,cge=age;function dge(e,t){var n=cge(e,t);return uge(n)?n:void 0}var $h=dge,fge=$h,pge=zi,hge=fge(pge,"DataView"),mge=hge,gge=$h,vge=zi,yge=gge(vge,"Map"),_ge=yge,bge=$h,wge=zi,Cge=bge(wge,"Promise"),kge=Cge,Sge=$h,$ge=zi,Ege=Sge($ge,"Set"),xge=Ege,Tge=$h,Mge=zi,Oge=Tge(Mge,"WeakMap"),Ige=Oge,Mb=mge,Ob=_ge,Ib=kge,Ab=xge,Nb=Ige,eI=Sh,Md=QO,U8="[object Map]",Age="[object Object]",W8="[object Promise]",K8="[object Set]",q8="[object WeakMap]",G8="[object DataView]",Nge=Md(Mb),Pge=Md(Ob),Lge=Md(Ib),Rge=Md(Ab),Dge=Md(Nb),ba=eI;(Mb&&ba(new Mb(new ArrayBuffer(1)))!=G8||Ob&&ba(new Ob)!=U8||Ib&&ba(Ib.resolve())!=W8||Ab&&ba(new Ab)!=K8||Nb&&ba(new Nb)!=q8)&&(ba=function(e){var t=eI(e),n=t==Age?e.constructor:void 0,o=n?Md(n):"";if(o)switch(o){case Nge:return G8;case Pge:return U8;case Lge:return W8;case Rge:return K8;case Dge:return q8}return t});var Vge=ba,Fge=JO,Bge=Vge,zge=KO,jge=Z3,Hge=J3,Uge=qO,Wge=ZO,Kge=YO,qge="[object Map]",Gge="[object Set]",Yge=Object.prototype,Zge=Yge.hasOwnProperty;function Jge(e){if(e==null)return!0;if(Hge(e)&&(jge(e)||typeof e=="string"||typeof e.splice=="function"||Uge(e)||Kge(e)||zge(e)))return!e.length;var t=Bge(e);if(t==qge||t==Gge)return!e.size;if(Wge(e))return!Fge(e).length;for(var n in e)if(Zge.call(e,n))return!1;return!0}var Xge=Jge;const tI=_o(Xge),Qge={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),tI(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}}},e0e={class:"fcom_social_links"},t0e=["href","title"];function n0e(e,t,n,o,r,s){const i=Ne,l=oe("router-link");return C(),T("div",e0e,[(C(!0),T(fe,null,nt(s.socialLinks,a=>(C(),T("a",{rel:"noopener nofollow",target:"_blank",href:a.url,key:a.title,title:a.title},[k(i,{innerHTML:a.icon},null,8,["innerHTML"])],8,t0e))),128)),n.isOwn&&!s.socialLinks.length?(C(),K(l,{key:0,to:{name:"update_profile",params:{username:n.xprofile.username}}},{default:$(()=>[ne(O("+ "+e.$t("Add social links")),1)]),_:1},8,["to"])):j("",!0)])}const o0e=We(Qge,[["render",n0e]]),r0e={name:"UserRouteLink",props:{xprofile:{default:()=>({})},show_pop:{type:Boolean,default(){return!0}},show_badge:{type:Boolean,default(){return!1}}},components:{SocialLinks:o0e},data(){return{showingPop:!1,userLevel:null}},methods:{initShow(){this.showingPop=!0,this.has_leaderboard&&!this.userLevel&&(this.userLevel=Yu(this.xprofile.total_points))}}},s0e=["href"],i0e=["href"],l0e={key:0,class:"fcom_profile_pop"},a0e={class:"fcom_profile_pop_avatar"},u0e={key:0,class:"fcom_prfile_tagline"},c0e={class:"fcom_level_name"},d0e={style:{display:"block"},class:"fcoml_level_sub meta_line"},f0e={class:"fcom_profile_pop_info"},p0e=["href"],h0e={class:"fcom_user_name"},m0e={key:0,class:"fcom_profile_pop_bio"},g0e={class:"meta_line"},v0e={key:1,class:"meta_line"},y0e={class:"fcom_profile_btns"},_0e=["href"],b0e=["href"];function w0e(e,t,n,o,r,s){const i=oe("verified-sign"),l=oe("UserBadge"),a=oe("UserAvatar"),u=yh,c=oe("SocialLinks"),d=vh,f=bo;return n.show_pop?(C(),K(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(O(n.xprofile.display_name||e.$t("No name"))+" ",1),n.xprofile.is_verified?(C(),K(i,{key:0})):j("",!0),n.show_badge?(C(),K(l,{key:1,profile:n.xprofile},null,8,["profile"])):j("",!0)],8,i0e)])]),default:$(()=>[r.showingPop?(C(),T("div",l0e,[k(d,{gutter:20},{default:$(()=>[k(u,{sm:24,md:8},{default:$(()=>[b("div",a0e,[k(a,{xprofile:n.xprofile},null,8,["xprofile"]),r.userLevel?(C(),T("div",u0e,[b("div",c0e,O(r.userLevel.title),1),b("div",d0e,O(r.userLevel.tagline),1)])):j("",!0)])]),_:1}),k(u,{sm:24,md:16},{default:$(()=>[b("div",f0e,[b("a",{href:e.$getRouteLink("u/:username",{username:n.xprofile.username}),class:"user_route"},[ne(O(n.xprofile.display_name)+" ",1),n.xprofile.is_verified?(C(),K(i,{key:0})):j("",!0),n.show_badge?(C(),K(l,{key:1,profile:n.xprofile},null,8,["profile"])):j("",!0)],8,p0e),b("span",h0e," @"+O(n.xprofile.username),1),n.xprofile.short_description?(C(),T("div",m0e,O(e.getExcerpt(n.xprofile.short_description,160)),1)):j("",!0),b("div",g0e,O(e.$t("Joined: %s",e.humanDateDiff(n.xprofile.created_at))),1),n.xprofile.last_activity?(C(),T("div",v0e,O(e.$t("Last seen: %s",e.humanDateDiff(n.xprofile.last_activity))),1)):j("",!0),b("div",y0e,[b("a",{class:"el-button el-button--primary is-text is-has-bg",href:e.$getRouteLink("u/:username",{username:n.xprofile.username})},O(e.$t("View Profile")),9,_0e),e.appVars.has_chat?(C(),T("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})},O(e.$t("Message")),9,b0e)):j("",!0)]),k(c,{style:{"justify-content":"left"},xprofile:n.xprofile,isOwn:!1},null,8,["xprofile"])])]),_:1})]),_:1})])):j("",!0)]),_:3},8,["onShow"])):(C(),T("a",{key:0,href:e.$getRouteLink("u/:username",{username:n.xprofile.username}),class:"user_route"},[he(e.$slots,"default",{},()=>[ne(O(n.xprofile.display_name)+" ",1),n.xprofile.is_verified?(C(),K(i,{key:0})):j("",!0),n.show_badge?(C(),K(l,{key:1,profile:n.xprofile},null,8,["profile"])):j("",!0)])],8,s0e))}const Q0=We(r0e,[["render",w0e]]),C0e={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"}}},k0e=["src"],S0e={key:1,class:"fcom_no_image"},$0e={key:0,role:"region","aria-label":"User Level",class:"fcom_user_level_mark"};function E0e(e,t,n,o,r,s){return C(),T("div",{class:D([{fcom_avatar_is_rounded:n.is_rounded,is_member_online:n.is_online},"fcom_user_avatar"])},[b("span",{style:et(s.getOutlineStyle),class:D({fcom_compilation_avatar:s.withCompletion})},[n.xprofile?(C(),T("img",{key:0,onError:t[0]||(t[0]=(...i)=>s.setAltImg&&s.setAltImg(...i)),src:n.xprofile.avatar,alt:""},null,40,k0e)):(C(),T("span",S0e))],6),s.level||n.is_online?(C(),T("div",$0e,[b("span",null,O(s.level),1)])):j("",!0)],2)}const nI=We(C0e,[["render",E0e]]),x0e={name:"ModeratorSettings",components:{UserAvatar:nI,UserRouteLink:Q0,ManagerForm:whe,Layout:$s,AppLayout:Es},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"))}},T0e=["href"],M0e={class:"settings_router manager_section"},O0e={class:"fhr_content_layout_body"},I0e={key:0,class:"setting_body"},A0e={class:"fcom_manager_actions"},N0e={class:"bulk_search"},P0e=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),L0e={class:"fcom_manager_table"},R0e={class:"user_col"},D0e={class:"user_info"},V0e={class:"user_id"},F0e={class:"user_email"},B0e={class:"fcom_table_action_col"},z0e={key:1,class:"setting_body",style:{"text-align":"center"}},j0e=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),H0e=["href"],U0e={class:"dialog_header"},W0e={class:"dialog_left"},K0e=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),q0e={class:"dialog_body"};function G0e(e,t,n,o,r,s){const i=oe("Plus"),l=Ne,a=ct,u=Tt,c=tne,d=oe("user-route-link"),f=Z0,p=Y0,h=oe("layout"),m=oe("app-layout"),y=oe("manager-form"),v=_h,w=Dt("loading");return C(),T(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(),K(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,O(e.$t("Add Manager")),1)]),_:1})):(C(),T("a",{key:1,target:"_blank",rel:"noopener",href:e.appVars.upgrade_url,class:"el-button el-button--danger"},O(e.$t("Upgrade to Pro")),9,T0e))]),default:$(()=>[b("div",M0e,[b("div",O0e,[e.has_pro?(C(),T("div",I0e,[b("div",A0e,[b("div",N0e,[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:$(()=>[P0e]),_:1},8,["modelValue","onKeydown","placeholder"])])]),b("div",L0e,[Fe((C(),K(p,{data:r.managers},{default:$(()=>[k(f,{label:e.$t("Members"),sortable:"","min-width":"160"},{default:$(_=>[b("div",R0e,[k(c,{src:_.row.xprofile.avatar},null,8,["src"]),b("div",D0e,[b("div",null,[k(d,{xprofile:_.row.xprofile},null,8,["xprofile"]),b("span",V0e,"#"+O(_.row.ID),1)]),b("span",F0e,O(_.row.user_email),1)])])]),_:1},8,["label"]),k(f,{label:e.$t("Role"),sortable:""},{default:$(_=>[b("span",null,O(s.formatRoles(_.row.community_role.value)),1)]),_:1},8,["label"]),k(f,null,{default:$(_=>[b("div",B0e,[k(a,{onClick:S=>s.showForm(_.row),size:"small"},{default:$(()=>[ne(O(e.$t("Edit")),1)]),_:2},1032,["onClick"]),k(a,{onClick:S=>s.removeManager(_.row),type:"danger",plain:"",size:"small"},{default:$(()=>[ne(O(e.$t("Remove")),1)]),_:2},1032,["onClick"])])]),_:1})]),_:1},8,["data"])),[[w,r.loading]])])])):(C(),T("div",z0e,[j0e,b("a",{target:"_blank",rel:"noopener",href:e.appVars.upgrade_url,class:"el-button el-button--danger"},O(e.$t("Upgrade to Pro")),9,H0e)]))])])]),_: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",U0e,[b("div",W0e,[K0e,b("div",null,[b("h4",null,O(e.$t(r.editing_manager.editing_user?"Update Role":"Add Manager")),1),b("p",null,O(e.$t("you can edit your role here")),1)])])])]),default:$(()=>[b("div",q0e,[r.showModal?(C(),K(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"])):j("",!0)])]),_:1},8,["width","modelValue"])],64)}const Y0e=We(x0e,[["render",G0e]]);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 Z0e=(e,t)=>typeof t=="function"?"[Function]":t,ud=e=>JSON.stringify(e,Z0e);function J0e(e){return new wr(Xo.docTypeError,`Doc type error, unsupported type: ${ud(e)}`)}function X0e(e){return new wr(Xo.contextNotFound,`Context "${e}" not found, do you forget to inject it?`)}function Q0e(e){return new wr(Xo.timerNotFound,`Timer "${e}" not found, do you forget to record it?`)}function X3(){return new wr(Xo.ctxCallOutOfScope,"Should not call a context out of the plugin.")}function eve(...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 oI(){return new wr(Xo.stackOverFlow,"Stack over flow, cannot pop on an empty stack.")}function tve(e){return new wr(Xo.parserMatchError,`Cannot match target parser for node: ${ud(e)}.`)}function nve(e){return new wr(Xo.serializerMatchError,`Cannot match target serializer for node: ${ud(e)}.`)}function ove(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 rve(){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 rI(e){return new wr(Xo.missingNodeInSchema,`Missing node in schema, milkdown cannot find "${e}" in schema.`)}function sve(e){return new wr(Xo.missingMarkInSchema,`Missing mark in schema, milkdown cannot find "${e}" in schema.`)}var sI=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},it=(e,t,n)=>(sI(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)=>(sI(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n);let iI=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 X0e(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 As,ol,Qd;let ive=class{constructor(t,n,o){kn(this,As,void 0),kn(this,ol,void 0),kn(this,Qd,void 0),Ut(this,As,[]),Ut(this,Qd,()=>{it(this,As).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,As).push(t),()=>{Ut(this,As,it(this,As).filter(n=>n!==t))}}once(t){const n=this.on(o=>{t(o),n()});return n}off(t){Ut(this,As,it(this,As).filter(n=>n!==t))}offAll(){Ut(this,As,[])}};As=new WeakMap,ol=new WeakMap,Qd=new WeakMap;let lve=class{constructor(t,n){this.id=Symbol(`Context-${n}`),this.name=n,this._defaultValue=t,this._typeInfo=()=>{throw X3()}}create(t,n=this._defaultValue){return new ive(t,n,this)}};const jt=(e,t)=>new lve(e,t);var u1,c1,d1,Zu,ef,wa,tf,nf,of;let ave=class{constructor(t,n,o){kn(this,u1,void 0),kn(this,c1,void 0),kn(this,d1,void 0),kn(this,Zu,void 0),kn(this,ef,void 0),kn(this,wa,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,wa,new Map),Ut(this,tf,new Map),this.read=()=>({metadata:it(this,u1),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,wa)].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,wa).set(r,{start:Date.now(),duration:0})},this.onClear=r=>{it(this,wa).delete(r)},this.onDone=r=>{const s=it(this,wa).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,c1).get(r).get()),Ut(this,of,r=>it(this,d1).get(r).status),Ut(this,c1,t),Ut(this,d1,n),Ut(this,u1,o)}};u1=new WeakMap,c1=new WeakMap,d1=new WeakMap,Zu=new WeakMap,ef=new WeakMap,wa=new WeakMap,tf=new WeakMap,nf=new WeakMap,of=new WeakMap;var rl,sl,f1,Qr;const uve=class lI{constructor(t,n,o){kn(this,rl,void 0),kn(this,sl,void 0),kn(this,f1,void 0),kn(this,Qr,void 0),this.produce=r=>r&&Object.keys(r).length?new lI(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,f1,o),o&&Ut(this,Qr,new ave(t,n,o))}get meta(){return it(this,f1)}get inspector(){return it(this,Qr)}};rl=new WeakMap,sl=new WeakMap,f1=new WeakMap,Qr=new WeakMap;let cve=uve,dve=class{constructor(){this.store=new Map,this.get=t=>{const n=this.store.get(t.id);if(!n)throw Q0e(t.name);return n},this.remove=t=>{this.store.delete(t.id)},this.has=t=>this.store.has(t.id)}};var Ju,Ca,rf,il,sf,p1;let fve=class{constructor(t,n){kn(this,Ju,void 0),kn(this,Ca,void 0),kn(this,rf,void 0),kn(this,il,void 0),kn(this,sf,void 0),kn(this,p1,void 0),Ut(this,Ju,null),Ut(this,Ca,null),Ut(this,il,"pending"),this.start=()=>(it(this,Ju)??Ut(this,Ju,new Promise((o,r)=>{Ut(this,Ca,s=>{s instanceof CustomEvent&&s.detail.id===it(this,rf)&&(Ut(this,il,"resolved"),it(this,sf).call(this),s.stopImmediatePropagation(),o())}),it(this,p1).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,Ca))})),it(this,Ju)),this.done=()=>{const o=new CustomEvent(this.type.name,{detail:{id:it(this,rf)}});dispatchEvent(o)},Ut(this,sf,()=>{it(this,Ca)&&removeEventListener(this.type.name,it(this,Ca))}),Ut(this,p1,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,Ca=new WeakMap,rf=new WeakMap,il=new WeakMap,sf=new WeakMap,p1=new WeakMap;let pve=class{constructor(t,n=3e3){this.create=o=>new fve(o,this),this.id=Symbol(`Timer-${t}`),this.name=t,this.timeout=n}};const na=(e,t=3e3)=>new pve(e,t);function to(e){this.content=e}to.prototype={constructor:to,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 to(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 to(n)},addToStart:function(e,t){return new to([e,t].concat(this.remove(e).content))},addToEnd:function(e,t){var n=this.remove(e).content.slice();return n.push(e,t),new to(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 to(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=to.from(e),e.size?new to(e.content.concat(this.subtract(e).content)):this},append:function(e){return e=to.from(e),e.size?new to(this.subtract(e).content.concat(e.content)):this},subtract:function(e){var t=this;e=to.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}};to.from=function(e){if(e instanceof to)return e;var t=[];if(e)for(var n in e)t.push(n,e[n]);return new to(t)};function aI(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=aI(r.content,s.content,n+1);if(i!=null)return i}n+=r.nodeSize}}function uI(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=uI(i.content,l.content,n-1,o-1);if(u)return u}n-=a,o-=a}}let Ue=class So{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 So(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 So(o,r)}cutByIndex(t,n){return t==n?So.empty:t==0&&n==this.content.length?this:new So(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 So(r,s)}addToStart(t){return new So([t].concat(this.content),this.size+t.nodeSize)}addToEnd(t){return new So(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 aI(this,t,n)}findDiffEnd(t,n=this.size,o=t.size){return uI(this,t,n,o)}findIndex(t,n=-1){if(t==0)return Cm(0,t);if(t==this.size)return Cm(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?Cm(o+1,i):Cm(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 So.empty;if(!Array.isArray(n))throw new RangeError("Invalid input for Fragment.fromJSON");return new So(n.map(t.nodeFromJSON))}static fromArray(t){if(!t.length)return So.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 So(n||t,o)}static from(t){if(!t)return So.empty;if(t instanceof So)return t;if(Array.isArray(t))return this.fromArray(t);if(t.attrs)return new So([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 gy={index:0,offset:0};function Cm(e,t){return gy.index=e,gy.offset=t,gy}function Hg(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(!Hg(e[o],t[o]))return!1}else{for(let o in e)if(!(o in t)||!Hg(e[o],t[o]))return!1;for(let o in t)if(!(o in e))return!1}return!0}let Yt=class Pb{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&&Hg(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 Pb.none;if(t instanceof Pb)return[t];let n=t.slice();return n.sort((o,r)=>o.type.rank-r.type.rank),n}};Yt.none=[];class Ug 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=dI(this.content,t+this.openStart,n);return o&&new Ye(o,this.openStart,this.openEnd)}removeBetween(t,n){return new Ye(cI(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 cI(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(cI(s.content,t-r-1,n-r-1)))}function dI(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=dI(i.content,t-s-1,n);return l&&e.replaceChild(r,i.copy(l))}function hve(e,t,n){if(n.openStart>e.depth)throw new Ug("Inserted content deeper than insertion position");if(e.depth-n.openStart!=t.depth-n.openEnd)throw new Ug("Inconsistent open depths");return fI(e,t,n,0)}function fI(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=fI(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 Ya(i,l.cut(0,e.parentOffset).append(n.content).append(l.cut(t.parentOffset)))}else{let{start:i,end:l}=mve(n,e);return Ya(s,hI(e,i,l,t,o))}else return Ya(s,Wg(e,t,o))}function pI(e,t){if(!t.type.compatibleContent(e.type))throw new Ug("Cannot join "+t.type.name+" onto "+e.type.name)}function Lb(e,t,n){let o=e.node(n);return pI(o,t.node(n)),o}function Ga(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&&(Ga(e.nodeAfter,o),s++));for(let l=s;l<i;l++)Ga(r.child(l),o);t&&t.depth==n&&t.textOffset&&Ga(t.nodeBefore,o)}function Ya(e,t){return e.type.checkContent(t),e.copy(t)}function hI(e,t,n,o,r){let s=e.depth>r&&Lb(e,t,r+1),i=o.depth>r&&Lb(n,o,r+1),l=[];return Jf(null,e,r,l),s&&i&&t.index(r)==n.index(r)?(pI(s,i),Ga(Ya(s,hI(e,t,n,o,r+1)),l)):(s&&Ga(Ya(s,Wg(e,t,r+1)),l),Jf(t,n,r,l),i&&Ga(Ya(i,Wg(n,o,r+1)),l)),Jf(o,null,r,l),new Ue(l)}function Wg(e,t,n){let o=[];if(Jf(null,e,n,o),e.depth>n){let r=Lb(e,t,n+1);Ga(Ya(r,Wg(e,t,n+1)),o)}return Jf(t,null,n,o),new Ue(o)}function mve(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 mI(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 gve);let r=o.elts[o.i]=Bp.resolve(t,n);return o.i=(o.i+1)%vve,r}}class gve{constructor(){this.elts=[],this.i=0}}const vve=12,Y8=new WeakMap;class mI{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 yve=Object.create(null);let Ll=class Rb{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&&Hg(this.attrs,n||t.defaultAttrs||yve)&&Yt.sameSet(this.marks,o||Yt.none)}copy(t=null){return t==this.content?this:new Rb(this.type,this.attrs,t,this.marks)}mark(t){return t==this.marks?this:new Rb(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 hve(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()+")"),gI(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 Kg 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):gI(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 Kg(this.type,this.attrs,this.text,t)}withText(t){return t==this.text?this:new Kg(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 gI(e,t){for(let n=e.length-1;n>=0;n--)t=e[n].type.name+"("+t+")";return t}class fu{constructor(t){this.validEnd=t,this.next=[],this.wrapCache=[]}static parse(t,n){let o=new _ve(t,n);if(o.next==null)return fu.empty;let r=vI(o);o.next&&o.err("Unexpected trailing text");let s=Eve($ve(r));return xve(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 |
`)}}fu.empty=new fu(!0);class _ve{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 vI(e){let t=[];do t.push(bve(e));while(e.eat("|"));return t.length==1?t[0]:{type:"choice",exprs:t}}function bve(e){let t=[];do t.push(wve(e));while(e.next&&e.next!=")"&&e.next!="|");return t.length==1?t[0]:{type:"seq",exprs:t}}function wve(e){let t=Sve(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=Cve(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 Cve(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 kve(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 Sve(e){if(e.eat("(")){let t=vI(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=kve(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 $ve(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 yI(e,t){return t-e}function J8(e,t){let n=[];return o(t),n.sort(yI);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 Eve(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 fu(o.indexOf(e.length-1)>-1);for(let i=0;i<r.length;i++){let l=r[i][1].sort(yI);s.next.push({type:r[i][0],next:t[l.join(",")]||n(l)})}return s}}function xve(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 _I(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 bI(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 wI(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 CI(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 kI{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=CI(t,o.attrs),this.defaultAttrs=_I(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==fu.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:bI(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){wI(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 kI(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 Tve(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"?Tve(t,n,o.validate):o.validate}get isRequired(){return!this.hasDefault}}class ev{constructor(t,n,o,r){this.name=t,this.rank=n,this.schema=o,this.spec=r,this.attrs=CI(t,r.attrs),this.excluded=null;let s=_I(this.attrs);this.instance=s?new Yt(this,s):null}create(t=null){return!t&&this.instance?this.instance:new Yt(this,bI(this.attrs,t))}static compile(t,n){let o=Object.create(null),r=0;return t.forEach((s,i)=>o[s]=new ev(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){wI(this.attrs,t,"mark",this.name)}excludes(t){return this.excluded.indexOf(t)>-1}}class Ove{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=to.from(t.nodes),n.marks=to.from(t.marks||{}),this.nodes=X8.compile(this.spec.nodes,this),this.marks=ev.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]=fu.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 Kg(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 Ive(e){return e.tag!=null}function Ave(e){return e.style!=null}class pu{constructor(t,n){this.schema=t,this.rules=n,this.tags=[],this.styles=[];let o=this.matchedStyles=[];n.forEach(r=>{if(Ive(r))this.tags.push(r);else if(Ave(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(Lve(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 pu(t,pu.schemaRules(t)))}}const SI={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},Nve={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},$I={ol:!0,ul:!0},qg=1,Gg=2,Xf=4;function eS(e,t,n){return t!=null?(t?qg:0)|(t==="full"?Gg:0):e&&e.whitespace=="pre"?qg|Gg:n&~Xf}class km{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&qg)){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&&!SI.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 km(r.type,r.attrs,Yt.none,!0,n.topMatch||r.type.contentMatch,i):o?s=new km(null,null,Yt.none,!0,null,i):s=new km(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&Gg||r.inlineContext(t)||/[^ \t\r\n\u000c]/.test(o)){if(r.options&qg)r.options&Gg?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;$I.hasOwnProperty(r)&&this.parser.normalizeLists&&Pve(t);let i=this.options.ruleFromNode&&this.options.ruleFromNode(t)||(s=this.parser.matchTag(t,this,o));if(i?i.ignore:Nve.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(SI.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 km(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 Pve(e){for(let t=e.firstChild,n=null;t;t=t.nextSibling){let o=t.nodeType==1?t.nodeName.toLowerCase():null;o&&$I.hasOwnProperty(o)&&n?(n.appendChild(t),t=n):o=="li"?n=t:o&&(n=null)}}function Lve(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 oa{constructor(t,n){this.nodes=t,this.marks=n}serializeFragment(t,n={},o){o||(o=vy(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}=h1(vy(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&&h1(vy(o),r(t,n),null,t.attrs)}static renderSpec(t,n,o=null,r){return h1(t,n,o,r)}static fromSchema(t){return t.cached.domSerializer||(t.cached.domSerializer=new oa(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 vy(e){return e.document||window.document}const sS=new WeakMap;function Rve(e){let t=sS.get(e);return t===void 0&&sS.set(e,t=Dve(e)),t}function Dve(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 h1(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=Rve(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}=h1(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 Vve={};function Q3(e,t){const n=t||Vve,o=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,r=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return EI(e,o,r)}function EI(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]=EI(e[r],t,n);return o.join("")}function Fve(e){return!!(e&&typeof e=="object")}const lS=document.createElement("i");function eC(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 xI(e){const t={};let n=-1;for(;++n<e.length;)Bve(t,e[n]);return t}function Bve(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];zve(r[i],Array.isArray(l)?l:l?[l]:[])}}}function zve(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 TI(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 xo=ra(/[A-Za-z]/),Wo=ra(/[\dA-Za-z]/),jve=ra(/[#-'*+\--9=?A-Z^-~]/);function Yg(e){return e!==null&&(e<32||e===127)}const Db=ra(/\d/),Hve=ra(/[\dA-Fa-f]/),Uve=ra(/[!-/:-@[-`{-~]/);function ft(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 tv=ra(/\p{P}|\p{S}/u),hu=ra(/\s/);function ra(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Bt(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 Wve={tokenize:Kve};function Kve(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"),Bt(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 ft(l)?(e.consume(l),e.exit("chunkText"),s):(e.consume(l),i)}}const qve={tokenize:Gve},uS={tokenize:Yve};function Gve(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 M=S;for(;M<t.events.length;)t.events[M][1].end=Object.assign({},E),M++;return Rr(t.events,x+1,0,t.events.slice(S)),t.events.length=M,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 ft(_)?(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 M=t.events.length;let A=M,P,N;for(;A--;)if(t.events[A][0]==="exit"&&t.events[A][1].type==="chunkFlow"){if(P){N=t.events[A][1].end;break}P=!0}for(v(o),E=M;E<t.events.length;)t.events[E][1].end=Object.assign({},N),E++;Rr(t.events,A+1,0,t.events.slice(M)),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 Yve(e,t,n){return Bt(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Zg(e){if(e===null||nn(e)||hu(e))return 1;if(tv(e))return 2}function nv(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 Vb={name:"attention",tokenize:Jve,resolveAll:Zve};function Zve(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,nv(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 Jve(e,t){const n=this.parser.constructs.attentionMarkers.null,o=this.previous,r=Zg(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=Zg(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 Xve={name:"autolink",tokenize:Qve};function Qve(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 xo(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||Yg(p)?n(p):(e.consume(p),a)}function u(p){return p===64?(e.consume(p),c):jve(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 Eh={tokenize:eye,partial:!0};function eye(e,t,n){return o;function o(s){return Nt(s)?Bt(e,r,"linePrefix")(s):r(s)}function r(s){return s===null||ft(s)?t(s):n(s)}}const MI={name:"blockQuote",tokenize:tye,continuation:{tokenize:nye},exit:oye};function tye(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 nye(e,t,n){const o=this;return r;function r(i){return Nt(i)?Bt(e,s,"linePrefix",o.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(i):s(i)}function s(i){return e.attempt(MI,t,n)(i)}}function oye(e){e.exit("blockQuote")}const OI={name:"characterEscape",tokenize:rye};function rye(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 Uve(s)?(e.enter("characterEscapeValue"),e.consume(s),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(s)}}const II={name:"characterReference",tokenize:sye};function sye(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=Hve,c):(e.enter("characterReferenceValue"),s=7,i=Db,c(d))}function c(d){if(d===59&&r){const f=e.exit("characterReferenceValue");return i===Wo&&!eC(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:lye,partial:!0},fS={name:"codeFenced",tokenize:iye,concrete:!0};function iye(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 M=o.events[o.events.length-1];return s=M&&M[1].type==="linePrefix"?M[2].sliceSerialize(M[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)?Bt(e,d,"whitespace")(E):d(E))}function d(E){return E===null||ft(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||ft(E)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),d(E)):Nt(E)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),Bt(e,p,"whitespace")(E)):E===96&&E===l?n(E):(e.consume(E),f)}function p(E){return E===null||ft(E)?d(E):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),h(E))}function h(E){return E===null||ft(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)?Bt(e,w,"linePrefix",s+1)(E):w(E)}function w(E){return E===null||ft(E)?e.check(dS,m,S)(E):(e.enter("codeFlowValue"),_(E))}function _(E){return E===null||ft(E)?(e.exit("codeFlowValue"),w(E)):(e.consume(E),_)}function S(E){return e.exit("codeFenced"),t(E)}function x(E,M,A){let P=0;return N;function N(W){return E.enter("lineEnding"),E.consume(W),E.exit("lineEnding"),V}function V(W){return E.enter("codeFencedFence"),Nt(W)?Bt(E,B,"linePrefix",o.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(W):B(W)}function B(W){return W===l?(E.enter("codeFencedFenceSequence"),Y(W)):A(W)}function Y(W){return W===l?(P++,E.consume(W),Y):P>=i?(E.exit("codeFencedFenceSequence"),Nt(W)?Bt(E,Z,"whitespace")(W):Z(W)):A(W)}function Z(W){return W===null||ft(W)?(E.exit("codeFencedFence"),M(W)):A(W)}}}function lye(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 yy={name:"codeIndented",tokenize:uye},aye={tokenize:cye,partial:!0};function uye(e,t,n){const o=this;return r;function r(u){return e.enter("codeIndented"),Bt(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):ft(u)?e.attempt(aye,i,a)(u):(e.enter("codeFlowValue"),l(u))}function l(u){return u===null||ft(u)?(e.exit("codeFlowValue"),i(u)):(e.consume(u),l)}function a(u){return e.exit("codeIndented"),t(u)}}function cye(e,t,n){const o=this;return r;function r(i){return o.parser.lazy[o.now().line]?n(i):ft(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),r):Bt(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):ft(i)?r(i):n(i)}}const dye={name:"codeText",tokenize:hye,resolve:fye,previous:pye};function fye(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 pye(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function hye(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)):ft(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||ft(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 mye{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 AI(e){const t={};let n=-1,o,r,s,i,l,a,u;const c=new mye(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,gye(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 gye(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 vye={tokenize:bye,resolve:_ye},yye={tokenize:wye,partial:!0};function _ye(e){return AI(e),e}function bye(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):ft(l)?e.check(yye,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 wye(e,t,n){const o=this;return r;function r(i){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),Bt(e,s,"linePrefix")}function s(i){if(i===null||ft(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 NI(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||Yg(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||ft(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||Yg(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 PI(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):ft(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||ft(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 LI(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):ft(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),Bt(e,u,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),c(f))}function c(f){return f===i||f===null||ft(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 ft(r)?(e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),n=!0,o):Nt(r)?Bt(e,o,n?"linePrefix":"lineSuffix")(r):t(r)}}const Cye={name:"definition",tokenize:Sye},kye={tokenize:$ye,partial:!0};function Sye(e,t,n){const o=this;let r;return s;function s(p){return e.enter("definition"),i(p)}function i(p){return PI.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 NI(e,c,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(p)}function c(p){return e.attempt(kye,d,d)(p)}function d(p){return Nt(p)?Bt(e,f,"whitespace")(p):f(p)}function f(p){return p===null||ft(p)?(e.exit("definition"),o.parser.defined.push(r),t(p)):n(p)}}function $ye(e,t,n){return o;function o(l){return nn(l)?Qf(e,r)(l):n(l)}function r(l){return LI(e,s,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(l)}function s(l){return Nt(l)?Bt(e,i,"whitespace")(l):i(l)}function i(l){return l===null||ft(l)?t(l):n(l)}}const Eye={name:"hardBreakEscape",tokenize:xye};function xye(e,t,n){return o;function o(s){return e.enter("hardBreakEscape"),e.consume(s),r}function r(s){return ft(s)?(e.exit("hardBreakEscape"),t(s)):n(s)}}const Tye={name:"headingAtx",tokenize:Oye,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 Oye(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||ft(c)?(e.exit("atxHeading"),t(c)):Nt(c)?Bt(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 Iye=["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"],Aye={name:"htmlFlow",tokenize:Rye,resolveTo:Lye,concrete:!0},Nye={tokenize:Vye,partial:!0},Pye={tokenize:Dye,partial:!0};function Lye(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 Rye(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):xo(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):xo(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 xo(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)):Iye.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||xo(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,M):Nt(z)?(e.consume(z),E):A(z)}function M(z){return z===a?(e.consume(z),a=null,P):z===null||ft(z)?n(z):(e.consume(z),M)}function A(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),A)}function P(z){return z===47||z===62||Nt(z)?_(z):n(z)}function N(z){return z===62?(e.consume(z),V):n(z)}function V(z){return z===null||ft(z)?B(z):Nt(z)?(e.consume(z),V):n(z)}function B(z){return z===45&&r===2?(e.consume(z),H):z===60&&r===1?(e.consume(z),F):z===62&&r===4?(e.consume(z),X):z===63&&r===3?(e.consume(z),I):z===93&&r===5?(e.consume(z),L):ft(z)&&(r===6||r===7)?(e.exit("htmlFlowData"),e.check(Nye,re,Y)(z)):z===null||ft(z)?(e.exit("htmlFlowData"),Y(z)):(e.consume(z),B)}function Y(z){return e.check(Pye,Z,re)(z)}function Z(z){return e.enter("lineEnding"),e.consume(z),e.exit("lineEnding"),W}function W(z){return z===null||ft(z)?Y(z):(e.enter("htmlFlowData"),B(z))}function H(z){return z===45?(e.consume(z),I):B(z)}function F(z){return z===47?(e.consume(z),i="",U):B(z)}function U(z){if(z===62){const ge=i.toLowerCase();return pS.includes(ge)?(e.consume(z),X):B(z)}return xo(z)&&i.length<8?(e.consume(z),i+=String.fromCharCode(z),U):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||ft(z)?(e.exit("htmlFlowData"),re(z)):(e.consume(z),X)}function re(z){return e.exit("htmlFlow"),t(z)}}function Dye(e,t,n){const o=this;return r;function r(i){return ft(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 Vye(e,t,n){return o;function o(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),e.attempt(Eh,t,n)}}const Fye={name:"htmlText",tokenize:Bye};function Bye(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),_):xo(I)?(e.consume(I),A):n(I)}function u(I){return I===45?(e.consume(I),c):I===91?(e.consume(I),s=0,h):xo(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):ft(I)?(i=d,F(I)):(e.consume(I),d)}function f(I){return I===45?(e.consume(I),p):d(I)}function p(I){return I===62?H(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):ft(I)?(i=m,F(I)):(e.consume(I),m)}function y(I){return I===93?(e.consume(I),v):m(I)}function v(I){return I===62?H(I):I===93?(e.consume(I),v):m(I)}function w(I){return I===null||I===62?H(I):ft(I)?(i=w,F(I)):(e.consume(I),w)}function _(I){return I===null?n(I):I===63?(e.consume(I),S):ft(I)?(i=_,F(I)):(e.consume(I),_)}function S(I){return I===62?H(I):_(I)}function x(I){return xo(I)?(e.consume(I),E):n(I)}function E(I){return I===45||Wo(I)?(e.consume(I),E):M(I)}function M(I){return ft(I)?(i=M,F(I)):Nt(I)?(e.consume(I),M):H(I)}function A(I){return I===45||Wo(I)?(e.consume(I),A):I===47||I===62||nn(I)?P(I):n(I)}function P(I){return I===47?(e.consume(I),H):I===58||I===95||xo(I)?(e.consume(I),N):ft(I)?(i=P,F(I)):Nt(I)?(e.consume(I),P):H(I)}function N(I){return I===45||I===46||I===58||I===95||Wo(I)?(e.consume(I),N):V(I)}function V(I){return I===61?(e.consume(I),B):ft(I)?(i=V,F(I)):Nt(I)?(e.consume(I),V):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):ft(I)?(i=B,F(I)):Nt(I)?(e.consume(I),B):(e.consume(I),Z)}function Y(I){return I===r?(e.consume(I),r=void 0,W):I===null?n(I):ft(I)?(i=Y,F(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 W(I){return I===47||I===62||nn(I)?P(I):n(I)}function H(I){return I===62?(e.consume(I),e.exit("htmlTextData"),e.exit("htmlText"),t):n(I)}function F(I){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(I),e.exit("lineEnding"),U}function U(I){return Nt(I)?Bt(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 tC={name:"labelEnd",tokenize:Kye,resolveTo:Wye,resolveAll:Uye},zye={tokenize:qye},jye={tokenize:Gye},Hye={tokenize:Yye};function Uye(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 Wye(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,nv(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 Kye(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(zye,c,i?c:d)(f):f===91?e.attempt(jye,c,i?u:d)(f):i?c(f):d(f)}function u(f){return e.attempt(Hye,c,d)(f)}function c(f){return t(f)}function d(f){return s._balanced=!0,n(f)}}function qye(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):NI(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?LI(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 Gye(e,t,n){const o=this;return r;function r(l){return PI.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 Yye(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 Zye={name:"labelStartImage",tokenize:Jye,resolveAll:tC.resolveAll};function Jye(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 Xye={name:"labelStartLink",tokenize:Qye,resolveAll:tC.resolveAll};function Qye(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 _y={name:"lineEnding",tokenize:e_e};function e_e(e,t){return n;function n(o){return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),Bt(e,t,"linePrefix")}}const m1={name:"thematicBreak",tokenize:t_e};function t_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||ft(u))?(e.exit("thematicBreak"),t(u)):n(u)}function a(u){return u===r?(e.consume(u),o++,a):(e.exit("thematicBreakSequence"),Nt(u)?Bt(e,l,"whitespace")(u):l(u))}}const Vo={name:"list",tokenize:r_e,continuation:{tokenize:s_e},exit:l_e},n_e={tokenize:a_e,partial:!0},o_e={tokenize:i_e,partial:!0};function r_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:Db(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(m1,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 Db(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(Eh,o.interrupt?n:c,e.attempt(n_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 s_e(e,t,n){const o=this;return o.containerState._closeFlow=void 0,e.check(Eh,r,s);function r(l){return o.containerState.furtherBlankLines=o.containerState.furtherBlankLines||o.containerState.initialBlankLine,Bt(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(o_e,t,i)(l))}function i(l){return o.containerState._closeFlow=!0,o.interrupt=void 0,Bt(e,e.attempt(Vo,t,n),"linePrefix",o.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(l)}}function i_e(e,t,n){const o=this;return Bt(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 l_e(e){e.exit(this.containerState.type)}function a_e(e,t,n){const o=this;return Bt(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:c_e,resolveTo:u_e};function u_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 c_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)?Bt(e,a,"lineSuffix")(u):a(u))}function a(u){return u===null||ft(u)?(e.exit("setextHeadingLine"),t(u)):n(u)}}const d_e={tokenize:f_e};function f_e(e){const t=this,n=e.attempt(Eh,o,e.attempt(this.parser.constructs.flowInitial,r,Bt(e,e.attempt(this.parser.constructs.flow,r,e.attempt(vye,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 p_e={resolveAll:DI()},h_e=RI("string"),m_e=RI("text");function RI(e){return{tokenize:t,resolveAll:DI(e==="text"?g_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 DI(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 g_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 v_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:M(x),check:M(E),interrupt:M(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(V){return i=xr(i,V),y(),i[i.length-1]!==null?[]:(A(t,0),u.events=nv(s,u.events,u),u.events)}function f(V,B){return __e(p(V),B)}function p(V){return y_e(i,V)}function h(){const{line:V,column:B,offset:Y,_index:Z,_bufferIndex:W}=o;return{line:V,column:B,offset:Y,_index:Z,_bufferIndex:W}}function m(V){r[V.line]=V.column,N()}function y(){let V;for(;o._index<i.length;){const B=i[o._index];if(typeof B=="string")for(V=o._index,o._bufferIndex<0&&(o._bufferIndex=0);o._index===V&&o._bufferIndex<B.length;)v(B.charCodeAt(o._bufferIndex));else v(B)}}function v(V){c=c(V)}function w(V){ft(V)?(o.line++,o.column=1,o.offset+=V===-3?2:1,N()):V!==-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=V}function _(V,B){const Y=B||{};return Y.type=V,Y.start=h(),u.events.push(["enter",Y,u]),l.push(Y),Y}function S(V){const B=l.pop();return B.end=h(),u.events.push(["exit",B,u]),B}function x(V,B){A(V,B.from)}function E(V,B){B.restore()}function M(V,B){return Y;function Y(Z,W,H){let F,U,L,I;return Array.isArray(Z)?re(Z):"tokenize"in Z?re([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 re(Ie)(de)}}function re(xe){return F=xe,U=0,xe.length===0?H:z(xe[U])}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 V(L,I),W}function Oe(xe){return I.restore(),++U<F.length?z(F[U]):H}}}function A(V,B){V.resolveAll&&!s.includes(V)&&s.push(V),V.resolve&&Rr(u.events,B,u.events.length-B,V.resolve(u.events.slice(B),u)),V.resolveTo&&(u.events=V.resolveTo(u.events,u))}function P(){const V=h(),B=u.previous,Y=u.currentConstruct,Z=u.events.length,W=Array.from(l);return{restore:H,from:Z};function H(){o=V,u.previous=B,u.currentConstruct=Y,u.events.length=Z,l=W,N()}}function N(){o.line in r&&o.column<2&&(o.column=r[o.line],o.offset+=r[o.line]-1)}}function y_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 __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 b_e={42:Vo,43:Vo,45:Vo,48:Vo,49:Vo,50:Vo,51:Vo,52:Vo,53:Vo,54:Vo,55:Vo,56:Vo,57:Vo,62:MI},w_e={91:Cye},C_e={[-2]:yy,[-1]:yy,32:yy},k_e={35:Tye,42:m1,45:[hS,m1],60:Aye,61:hS,95:m1,96:fS,126:fS},S_e={38:II,92:OI},$_e={[-5]:_y,[-4]:_y,[-3]:_y,33:Zye,38:II,42:Vb,60:[Xve,Fye],91:Xye,92:[Eye,OI],93:tC,95:Vb,96:dye},E_e={null:[Vb,p_e]},x_e={null:[42,95]},T_e={null:[]},M_e=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:x_e,contentInitial:w_e,disable:T_e,document:b_e,flow:k_e,flowInitial:C_e,insideSpan:E_e,string:S_e,text:$_e},Symbol.toStringTag,{value:"Module"}));function O_e(e){const n=xI([M_e,...(e||{}).extensions||[]]),o={defined:[],lazy:{},constructs:n,content:r(Wve),document:r(qve),flow:r(d_e),string:r(h_e),text:r(m_e)};return o;function r(s){return i;function i(l){return v_e(o,s,l)}}}function I_e(e){for(;!AI(e););return e}const mS=/[\0\t\n\r]/g;function A_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 N_e=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function VI(e){return e.replace(N_e,P_e)}function P_e(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const r=n.charCodeAt(1),s=r===120||r===88;return TI(n.slice(s?2:1),s?16:10)}return eC(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 FI={}.hasOwnProperty;function L_e(e,t,n){return typeof t!="string"&&(n=t,t=void 0),R_e(n)(I_e(O_e(n).document().write(A_e()(e,t,!0))))}function R_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(He),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(W),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(F),label:L,labelText:U,lineEnding:V,link:a(H),listItem:a(),listOrdered:a(),listUnordered:a(),paragraph:a(),referenceString:ge,resourceDestinationString:I,resourceTitleString:X,resource:re,setextHeading:a(A),setextHeadingLineSequence:M,setextHeadingText:E,strong:a(),thematicBreak:a()}};BI(t,(e||{}).mdastExtensions||[]);const n={};return o;function o(te){let pe={type:"root",children:[]};const Be={stack:[pe],tokenStack:[],config:t,enter:l,exit:u,buffer:i,resume:c,data:n},Xe=[];let $e=-1;for(;++$e<te.length;)if(te[$e][1].type==="listOrdered"||te[$e][1].type==="listUnordered")if(te[$e][0]==="enter")Xe.push($e);else{const ie=Xe.pop();$e=r(te,ie,$e)}for($e=-1;++$e<te.length;){const ie=t[te[$e][0]];FI.call(ie,te[$e][1].type)&&ie[te[$e][1].type].call(Object.assign({sliceSerialize:te[$e][2].sliceSerialize},Be),te[$e][1])}if(Be.tokenStack.length>0){const ie=Be.tokenStack[Be.tokenStack.length-1];(ie[1]||yS).call(Be,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,Be){let Xe=pe-1,$e=-1,ie=!1,we,ae,Se,Ve;for(;++Xe<=Be;){const st=te[Xe];switch(st[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{st[0]==="enter"?$e++:$e--,Ve=void 0;break}case"lineEndingBlank":{st[0]==="enter"&&(we&&!Ve&&!$e&&!Se&&(Se=Xe),Ve=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Ve=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=Xe;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||Xe,0,["exit",we,st[2]]),Xe++,Be++}if(st[1].type==="listItemPrefix"){const se={type:"listItem",_spread:!1,start:Object.assign({},st[1].start),end:void 0};we=se,te.splice(Xe,0,["enter",se,st[2]]),Xe++,Be++,Se=void 0,Ve=!0}}}return te[pe][1]._spread=ie,Be}function s(te,pe){return Be;function Be(Xe){l.call(this,te(Xe),Xe),pe&&pe.call(this,Xe)}}function i(){this.stack.push({type:"fragment",children:[]})}function l(te,pe,Be){this.stack[this.stack.length-1].children.push(te),this.stack.push(te),this.tokenStack.push([pe,Be]),te.position={start:Ji(pe.start),end:void 0}}function a(te){return pe;function pe(Be){te&&te.call(this,Be),u.call(this,Be)}}function u(te,pe){const Be=this.stack.pop(),Xe=this.tokenStack.pop();if(Xe)Xe[0].type!==te.type&&(pe?pe.call(this,te,Xe[0]):(Xe[1]||yS).call(this,te,Xe[0]));else throw new Error("Cannot close `"+te.type+"` ("+ep({start:te.start,end:te.end})+"): it’s not open");Be.position.end=Ji(te.end)}function c(){return Q3(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(),Be=this.stack[this.stack.length-1];Be.label=pe,Be.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 Be=this.sliceSerialize(te).length;pe.depth=Be}}function E(){this.data.setextHeadingSlurpLineEnding=!0}function M(te){const pe=this.stack[this.stack.length-1];pe.depth=this.sliceSerialize(te).codePointAt(0)===61?1:2}function A(){this.data.setextHeadingSlurpLineEnding=void 0}function P(te){const Be=this.stack[this.stack.length-1].children;let Xe=Be[Be.length-1];(!Xe||Xe.type!=="text")&&(Xe=Ze(),Xe.position={start:Ji(te.start),end:void 0},Be.push(Xe)),this.stack.push(Xe)}function N(te){const pe=this.stack.pop();pe.value+=this.sliceSerialize(te),pe.position.end=Ji(te.end)}function V(te){const pe=this.stack[this.stack.length-1];if(this.data.atHardBreak){const Be=pe.children[pe.children.length-1];Be.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 W(){const te=this.resume(),pe=this.stack[this.stack.length-1];pe.value=te}function H(){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 F(){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 U(te){const pe=this.sliceSerialize(te),Be=this.stack[this.stack.length-2];Be.label=VI(pe),Be.identifier=cs(pe).toLowerCase()}function L(){const te=this.stack[this.stack.length-1],pe=this.resume(),Be=this.stack[this.stack.length-1];if(this.data.inReference=!0,Be.type==="link"){const Xe=te.children;Be.children=Xe}else Be.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 re(){this.data.inReference=void 0}function z(){this.data.referenceType="collapsed"}function ge(te){const pe=this.resume(),Be=this.stack[this.stack.length-1];Be.label=pe,Be.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),Be=this.data.characterReferenceType;let Xe;Be?(Xe=TI(pe,Be==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):Xe=eC(pe);const $e=this.stack[this.stack.length-1];$e.value+=Xe}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 He(){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 BI(e,t){let n=-1;for(;++n<t.length;){const o=t[n];Array.isArray(o)?BI(e,o):D_e(e,o)}}function D_e(e,t){let n;for(n in t)if(FI.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 Bb(e){const t=this;t.parser=n;function n(o){return L_e(o,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}const _S={}.hasOwnProperty;function V_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 zI(e,t){let n=-1,o;if(t.extensions)for(;++n<t.extensions.length;)zI(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":{B_e(e[o],t[o]);break}default:e.options[o]=t[o]}return e}function bS(e,t){t&&e.push(...t)}function B_e(e,t){t&&Object.assign(e,t)}function z_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()),j_e);return r(),i}function j_e(e,t,n){return">"+(n?"":" ")+e}function jI(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 |
`&&jI(n.stack,n.unsafe[r]))return/[ \t]/.test(o.before)?"":" ";return`\\ |
| 83 |
`}function H_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 zb(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 U_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 W_e(e,t,n,o){const r=U_e(n),s=e.value||"",i=r==="`"?"GraveAccent":"Tilde";if(zb(e,n)){const d=n.enter("codeIndented"),f=n.indentLines(s,K_e);return d(),f}const l=n.createTracker(o),a=r.repeat(Math.max(H_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 K_e(e,t,n){return(n?"":" ")+e}function nC(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 q_e(e,t,n,o){const r=nC(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 G_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}HI.peek=Y_e;function HI(e,t,n,o){const r=G_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 Y_e(e,t,n){return n.options.emphasis||"*"}const ov=function(e){if(e==null)return Q_e;if(typeof e=="function")return rv(e);if(typeof e=="object")return Array.isArray(e)?Z_e(e):J_e(e);if(typeof e=="string")return X_e(e);throw new Error("Expected function, string, or object as test")};function Z_e(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=ov(e[n]);return rv(o);function o(...r){let s=-1;for(;++s<t.length;)if(t[s].apply(this,r))return!0;return!1}}function J_e(e){const t=e;return rv(n);function n(o){const r=o;let s;for(s in e)if(r[s]!==t[s])return!1;return!0}}function X_e(e){return rv(t);function t(n){return n&&n.type===e}}function rv(e){return t;function t(n,o,r){return!!(ebe(n)&&e.call(this,n,typeof o=="number"?o:void 0,r||void 0))}}function Q_e(){return!0}function ebe(e){return e!==null&&typeof e=="object"&&"type"in e}const UI=[],tbe=!0,jb=!1,Hb="skip";function WI(e,t,n,o){let r;typeof t=="function"&&typeof n!="function"?(o=n,n=t):r=t;const s=ov(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=UI,h,m,y;if((!t||s(a,u,c[c.length-1]||void 0))&&(p=nbe(n(a,c)),p[0]===jb))return p;if("children"in a&&a.children){const v=a;if(v.children&&p[0]!==Hb)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]===jb)return h;m=typeof h[1]=="number"?h[1]:m+i}}return p}}}function nbe(e){return Array.isArray(e)?e:typeof e=="number"?[tbe,e]:e==null?UI:[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),WI(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 KI(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,jb}),!!((!e.depth||e.depth<3)&&Q3(e)&&(t.options.setext||n))}function obe(e,t,n,o){const r=Math.max(Math.min(6,e.depth||1),1),s=n.createTracker(o);if(KI(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}qI.peek=rbe;function qI(e){return e.value||""}function rbe(){return"<"}GI.peek=sbe;function GI(e,t,n,o){const r=nC(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 sbe(){return"!"}YI.peek=ibe;function YI(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 ibe(){return"!"}ZI.peek=lbe;function ZI(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 lbe(){return"`"}function JI(e,t){const n=Q3(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))}XI.peek=abe;function XI(e,t,n,o){const r=nC(n),s=r==='"'?"Quote":"Apostrophe",i=n.createTracker(o);let l,a;if(JI(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 abe(e,t,n){return JI(e,n)?"<":"["}QI.peek=ube;function QI(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 ube(){return"["}function oC(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 cbe(e){const t=oC(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 dbe(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 eA(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 fbe(e,t,n,o){const r=n.enter("list"),s=n.bulletCurrent;let i=e.ordered?dbe(n):oC(n);const l=e.ordered?i==="."?")":".":cbe(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),eA(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 pbe(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 hbe(e,t,n,o){const r=pbe(n);let s=n.bulletCurrent||oC(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 mbe(e,t,n,o){const r=n.enter("paragraph"),s=n.enter("phrasing"),i=n.containerPhrasing(e,o);return s(),r(),i}const gbe=ov(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function vbe(e,t,n,o){return(e.children.some(function(i){return gbe(i)})?n.containerPhrasing:n.containerFlow).call(n,e,o)}function ybe(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}tA.peek=_be;function tA(e,t,n,o){const r=ybe(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 _be(e,t,n){return n.options.strong||"*"}function bbe(e,t,n,o){return n.safe(e.value,o)}function wbe(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 Cbe(e,t,n){const o=(eA(n)+(n.options.ruleSpaces?" ":"")).repeat(wbe(n));return n.options.ruleSpaces?o.slice(0,-1):o}const rC={blockquote:z_e,break:CS,code:W_e,definition:q_e,emphasis:HI,hardBreak:CS,heading:obe,html:qI,image:GI,imageReference:YI,inlineCode:ZI,link:XI,linkReference:QI,list:fbe,listItem:hbe,paragraph:mbe,root:vbe,strong:tA,text:bbe,thematicBreak:Cbe},kbe=[Sbe];function Sbe(e,t,n,o){if(t.type==="code"&&zb(t,o)&&(e.type==="list"||e.type===t.type&&zb(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"&&KI(t,o))?void 0:n.spread?1:0}const ha=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"],$be=[{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:ha},{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:ha},{atBreak:!0,before:"\\d+",character:")"},{character:")",inConstruct:"destinationRaw"},{atBreak:!0,character:"*",after:`(?:[ \r |
| 95 |
*])`},{character:"*",inConstruct:"phrasing",notInConstruct:ha},{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:ha},{character:"<",inConstruct:"destinationLiteral"},{atBreak:!0,character:"="},{atBreak:!0,character:">"},{character:">",inConstruct:"destinationLiteral"},{atBreak:!0,character:"["},{character:"[",inConstruct:"phrasing",notInConstruct:ha},{character:"[",inConstruct:["label","reference"]},{character:"\\",after:"[\\r\\n]",inConstruct:"phrasing"},{character:"]",inConstruct:["label","reference"]},{atBreak:!0,character:"_"},{character:"_",inConstruct:"phrasing",notInConstruct:ha},{atBreak:!0,character:"`"},{character:"`",inConstruct:["codeFencedLangGraveAccent","codeFencedMetaGraveAccent"]},{character:"`",inConstruct:"phrasing",notInConstruct:ha},{atBreak:!0,character:"~"}];function Ebe(e){return e.label||!e.identifier?e.label||"":VI(e.identifier)}function xbe(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 Tbe(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(Obe(a,r[l+1],e,t)))}return o.pop(),i.join("")}function Obe(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 Ibe=/\r?\n|\r/g;function Abe(e,t){const n=[];let o=0,r=0,s;for(;s=Ibe.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 Nbe(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(!jI(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(Pbe);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 Pbe(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 Lbe(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 Rbe(e,t={}){const n={enter:r,indentLines:Abe,associationId:Ebe,containerPhrasing:Bbe,containerFlow:zbe,createTracker:Lbe,compilePattern:xbe,safe:jbe,stack:[],unsafe:[...$be],join:[...kbe],handlers:{...rC},options:{},indexStack:[],handle:void 0};zI(n,t),n.options.tightDefinitions&&n.join.push(Fbe),n.handle=V_e("type",{invalid:Dbe,unknown:Vbe,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 Dbe(e){throw new Error("Cannot handle value `"+e+"`, expected node")}function Vbe(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 Bbe(e,t){return Tbe(e,this,t)}function zbe(e,t){return Mbe(e,this,t)}function jbe(e,t){return Nbe(this,e,t)}function Ub(e){const t=this;t.compiler=n;function n(o){return Rbe(o,{...t.data("settings"),...e,extensions:t.data("toMarkdownExtensions")||[]})}}function SS(e){if(e)throw e}var g1=Object.prototype.hasOwnProperty,nA=Object.prototype.toString,$S=Object.defineProperty,ES=Object.getOwnPropertyDescriptor,xS=function(t){return typeof Array.isArray=="function"?Array.isArray(t):nA.call(t)==="[object Array]"},TS=function(t){if(!t||nA.call(t)!=="[object Object]")return!1;var n=g1.call(t,"constructor"),o=t.constructor&&t.constructor.prototype&&g1.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!o)return!1;var r;for(r in t);return typeof r>"u"||g1.call(t,r)},MS=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(g1.call(t,n)){if(ES)return ES(t,n).value}else return;return t[n]},Hbe=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&&(TS(r)||(s=xS(r)))?(s?(s=!1,i=o&&xS(o)?o:[]):i=o&&TS(o)?o:{},MS(l,{name:n,newValue:e(c,i,r)})):typeof r<"u"&&MS(l,{name:n,newValue:r}));return l};const by=_o(Hbe);function Wb(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 Ube(){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?Wbe(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 Wbe(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 Ds={basename:Kbe,dirname:qbe,extname:Gbe,join:Ybe,sep:"/"};function Kbe(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');xh(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 qbe(e){if(xh(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 Gbe(e){xh(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 Ybe(...e){let t=-1,n;for(;++t<e.length;)xh(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":Zbe(n)}function Zbe(e){xh(e);const t=e.codePointAt(0)===47;let n=Jbe(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function Jbe(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 xh(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const Xbe={cwd:Qbe};function Qbe(){return"/"}function Kb(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function e2e(e){if(typeof e=="string")e=new URL(e);else if(!Kb(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 t2e(e)}function t2e(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 wy=["history","path","basename","stem","extname","dirname"];class n2e{constructor(t){let n;t?Kb(t)?n={path:t}:typeof t=="string"||o2e(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":Xbe.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let o=-1;for(;++o<wy.length;){const s=wy[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)wy.includes(r)||(this[r]=n[r])}get basename(){return typeof this.path=="string"?Ds.basename(this.path):void 0}set basename(t){ky(t,"basename"),Cy(t,"basename"),this.path=Ds.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?Ds.dirname(this.path):void 0}set dirname(t){IS(this.basename,"dirname"),this.path=Ds.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?Ds.extname(this.path):void 0}set extname(t){if(Cy(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=Ds.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){Kb(t)&&(t=e2e(t)),ky(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?Ds.basename(this.path,this.extname):void 0}set stem(t){ky(t,"stem"),Cy(t,"stem"),this.path=Ds.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 Cy(e,t){if(e&&e.includes(Ds.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+Ds.sep+"`")}function ky(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 o2e(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const r2e=function(e){const o=this.constructor.prototype,r=o[e],s=function(){return r.apply(s,arguments)};return Object.setPrototypeOf(s,o),s},s2e={}.hasOwnProperty;class sC extends r2e{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=Ube()}copy(){const t=new sC;let n=-1;for(;++n<this.attachers.length;){const o=this.attachers[n];t.use(...o)}return t.data(by(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(Ey("data",this.frozen),this.namespace[t]=n,this):s2e.call(this.namespace,t)&&this.namespace[t]||void 0:t?(Ey("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=Sm(t),o=this.parser||this.Parser;return Sy("parse",o),o(String(n),n)}process(t,n){const o=this;return this.freeze(),Sy("process",this.parser||this.Parser),$y("process",this.compiler||this.Compiler),n?r(void 0,n):new Promise(r);function r(s,i){const l=Sm(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);l2e(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(),Sy("processSync",this.parser||this.Parser),$y("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=Sm(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=Sm(n),r=this.compiler||this.Compiler;return $y("stringify",r),AS(t),r(t,o)}use(t,...n){const o=this.attachers,r=this.namespace;if(Ey("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=by(!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];Wb(m)&&Wb(p)&&(p=by(!0,m,p)),o[f]=[u,p,...h]}}}}const qb=new sC().freeze();function Sy(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function $y(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function Ey(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(!Wb(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 Sm(e){return i2e(e)?e:new n2e(e)}function i2e(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function l2e(e){return typeof e=="string"||a2e(e)}function a2e(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}var oA=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},At=(e,t,n)=>(oA(e,t,"read from private field"),n?n.call(e):t.get(e)),Nn=(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)=>(oA(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n);let rA=class{},sA=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 oI();return t}}},u2e=class iA extends rA{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 iA(t,n,o)}};var Ns,lf,v1,y1,_1,af,uf;const Gb=class extends sA{constructor(t){super(),Nn(this,Ns,void 0),Nn(this,lf,void 0),Nn(this,v1,void 0),Nn(this,y1,void 0),Nn(this,_1,void 0),Nn(this,af,void 0),Nn(this,uf,void 0),fn(this,Ns,Yt.none),fn(this,lf,n=>n.isText),fn(this,v1,(n,o)=>{if(At(this,lf).call(this,n)&&At(this,lf).call(this,o)&&Yt.sameSet(n.marks,o.marks))return this.schema.text(n.text+o.text,n.marks)}),fn(this,y1,n=>{const o=Object.values({...this.schema.nodes,...this.schema.marks}).find(r=>r.spec.parseMarkdown.match(n));if(!o)throw tve(n);return o}),fn(this,_1,n=>{const o=At(this,y1).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(u2e.create(n,[],o)),this),fn(this,af,()=>{fn(this,Ns,Yt.none);const n=this.close();return At(this,uf).call(this,n.type,n.attrs,n.content)}),this.closeNode=()=>(At(this,af).call(this),this),fn(this,uf,(n,o,r)=>{const s=n.createAndFill(o,r,At(this,Ns));if(!s)throw eve(n,o,r);return this.push(s),s}),this.addNode=(n,o,r)=>(At(this,uf).call(this,n,o,r),this),this.openMark=(n,o)=>{const r=n.create(o);return fn(this,Ns,r.addToSet(At(this,Ns))),this},this.closeMark=n=>(fn(this,Ns,n.removeFromSet(At(this,Ns))),this),this.addText=n=>{const o=this.top();if(!o)throw oI();const r=o.pop(),s=this.schema.text(n,At(this,Ns));if(!r)return o.push(s),this;const i=At(this,v1).call(this,r,s);return i?(o.push(i),this):(o.push(r,s),this)},this.build=()=>{let n;do n=At(this,af).call(this);while(this.size());return n},this.next=(n=[])=>([n].flat().forEach(o=>At(this,_1).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}};Ns=new WeakMap,lf=new WeakMap,v1=new WeakMap,y1=new WeakMap,_1=new WeakMap,af=new WeakMap,uf=new WeakMap,Gb.create=(e,t)=>{const n=new Gb(e);return o=>(n.run(t,o),n.toDoc())};let c2e=Gb;const Yb=class extends rA{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()}}};Yb.create=(e,t,n,o={})=>new Yb(e,t,n,o);let PS=Yb;const d2e=e=>Object.prototype.hasOwnProperty.call(e,"size");var hi,cf,b1,w1,df,C1,ff,k1,S1,Xu,ka,$1,pf;const Zb=class extends sA{constructor(t){super(),Nn(this,hi,void 0),Nn(this,cf,void 0),Nn(this,b1,void 0),Nn(this,w1,void 0),Nn(this,df,void 0),Nn(this,C1,void 0),Nn(this,ff,void 0),Nn(this,k1,void 0),Nn(this,S1,void 0),Nn(this,Xu,void 0),Nn(this,ka,void 0),Nn(this,$1,void 0),Nn(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 nve(n.type);return o}),fn(this,b1,n=>At(this,cf).call(this,n).spec.toMarkdown.runner(this,n)),fn(this,w1,(n,o)=>At(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=>!At(this,w1).call(this,s,n))&&At(this,b1).call(this,n),o.forEach(s=>At(this,pf).call(this,s))}),fn(this,C1,(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=At(this,C1).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(At(this,ff).call(this,f))}}return r.concat(s)},[])),n}),fn(this,k1,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,S1,(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&&At(this,ka).call(this,"text",void 0,r);const c=o();return s.length&&At(this,ka).call(this,"text",void 0,s),c}),fn(this,Xu,(n=!1)=>{const o=this.close(),r=()=>At(this,ka).call(this,o.type,o.children,o.value,o.props);return n?At(this,S1).call(this,o,r):r()}),this.closeNode=()=>(At(this,Xu).call(this),this),fn(this,ka,(n,o,r,s)=>{const i=PS.create(n,o,r,s),l=At(this,ff).call(this,At(this,k1).call(this,i));return this.push(l),l}),this.addNode=(n,o,r,s)=>(At(this,ka).call(this,n,o,r,s),this),fn(this,$1,(n,o,r,s)=>n.isInSet(At(this,hi))?this:(fn(this,hi,n.addToSet(At(this,hi))),this.openNode(o,r,{...s,isMark:!0}))),fn(this,pf,n=>{n.isInSet(At(this,hi))&&(fn(this,hi,n.type.removeFromSet(At(this,hi))),At(this,Xu).call(this,!0))}),this.withMark=(n,o,r,s)=>(At(this,$1).call(this,n,o,r,s),this),this.closeMark=n=>(At(this,pf).call(this,n),this),this.build=()=>{let n=null;do n=At(this,Xu).call(this);while(this.size());return n},this.next=n=>d2e(n)?(n.forEach(o=>{At(this,df).call(this,o)}),this):(At(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,b1=new WeakMap,w1=new WeakMap,df=new WeakMap,C1=new WeakMap,ff=new WeakMap,k1=new WeakMap,S1=new WeakMap,Xu=new WeakMap,ka=new WeakMap,$1=new WeakMap,pf=new WeakMap,Zb.create=(e,t)=>{const n=new Zb(e);return o=>(n.run(o),n.toString(t))};let f2e=Zb;const lA=65535,aA=Math.pow(2,16);function p2e(e,t){return e+t*aA}function LS(e){return e&lA}function h2e(e){return(e-(e&lA))/aA}const uA=1,cA=2,E1=4,dA=8;class Jb{constructor(t,n,o){this.pos=t,this.delInfo=n,this.recover=o}get deleted(){return(this.delInfo&dA)>0}get deletedBefore(){return(this.delInfo&(uA|E1))>0}get deletedAfter(){return(this.delInfo&(cA|E1))>0}get deletedAcross(){return(this.delInfo&E1)>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+h2e(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:p2e(l/3,t-a),m=t==a?cA:t==d?uA:E1;return(n<0?t!=a:t!=d)&&(m|=dA),new Jb(p,m,h)}r+=c-u}return o?t+r:new Jb(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 Jb(t,r,null)}}const xy=Object.create(null);class wo{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=xy[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 xy)throw new RangeError("Duplicate use of step JSON ID "+t);return xy[t]=n,n.prototype.jsonID=t,n}}class Dn{constructor(t,n){this.doc=t,this.failed=n}static ok(t){return new Dn(t,null)}static fail(t){return new Dn(null,t)}static fromReplace(t,n,o,r){try{return Dn.ok(t.replace(n,o,r))}catch(s){if(s instanceof Ug)return Dn.fail(s.message);throw s}}}function iC(e,t,n){let o=[];for(let r=0;r<e.childCount;r++){let s=e.child(r);s.content.size&&(s=s.copy(iC(s.content,t,s))),s.isInline&&(s=t(s,n,r)),o.push(s)}return Ue.fromArray(o)}class Si extends wo{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(iC(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 Dn.fromReplace(t,this.from,this.to,s)}invert(){return new Hs(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))}}wo.jsonID("addMark",Si);class Hs extends wo{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(iC(n.content,r=>r.mark(this.mark.removeFromSet(r.marks)),t),n.openStart,n.openEnd);return Dn.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 Hs(n.pos,o.pos,this.mark)}merge(t){return t instanceof Hs&&t.mark.eq(this.mark)&&this.from<=t.to&&this.to>=t.from?new Hs(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 Hs(n.from,n.to,t.markFromJSON(n.mark))}}wo.jsonID("removeMark",Hs);class Ol extends wo{constructor(t,n){super(),this.pos=t,this.mark=n}apply(t){let n=t.nodeAt(this.pos);if(!n)return Dn.fail("No node at mark step's position");let o=n.type.create(n.attrs,null,this.mark.addToSet(n.marks));return Dn.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))}}wo.jsonID("addNodeMark",Ol);class cd extends wo{constructor(t,n){super(),this.pos=t,this.mark=n}apply(t){let n=t.nodeAt(this.pos);if(!n)return Dn.fail("No node at mark step's position");let o=n.type.create(n.attrs,null,this.mark.removeFromSet(n.marks));return Dn.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))}}wo.jsonID("removeNodeMark",cd);class oo extends wo{constructor(t,n,o,r=!1){super(),this.from=t,this.to=n,this.slice=o,this.structure=r}apply(t){return this.structure&&Xb(t,this.from,this.to)?Dn.fail("Structure replace would overwrite content"):Dn.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 oo(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 oo(n.pos,Math.max(n.pos,o.pos),this.slice)}merge(t){if(!(t instanceof oo)||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 oo(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 oo(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 oo(n.from,n.to,Ye.fromJSON(t,n.slice),!!n.structure)}}wo.jsonID("replace",oo);class vo extends wo{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&&(Xb(t,this.from,this.gapFrom)||Xb(t,this.gapTo,this.to)))return Dn.fail("Structure gap-replace would overwrite content");let n=t.slice(this.gapFrom,this.gapTo);if(n.openStart||n.openEnd)return Dn.fail("Gap is not a flat range");let o=this.slice.insertAt(this.insert,n.content);return o?Dn.fromReplace(t,this.from,this.to,o):Dn.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)}}wo.jsonID("replaceAround",vo);function Xb(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 m2e(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 Hs(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 g2e(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 ev){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 Hs(i.from,i.to,i.style)))}function fA(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 oo(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 Hs(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 oo(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 v2e(e,t,n){return(t==0||e.canReplace(t,e.childCount))&&(n==e.childCount||e.canReplace(0,n))}function sv(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||!v2e(r,s,i))break}return null}function y2e(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 lC(e,t,n=null,o=e){let r=_2e(e,t),s=r&&b2e(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 _2e(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 b2e(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 w2e(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 C2e(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)&&$2e(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&&S2e(e,i,l,s),fA(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&&k2e(e,i,l,s),!1}})}function k2e(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 S2e(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 $2e(e,t,n){let o=e.resolve(t),r=o.index();return o.parent.canReplaceWith(r,r+1,n)}function E2e(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 x2e(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 oo(t,t,new Ye(s.append(i),n,n),!0))}function iv(e,t){let n=e.resolve(t),o=n.index();return T2e(n.nodeBefore,n.nodeAfter)&&n.parent.canReplace(o,o+1)}function T2e(e,t){return!!(e&&t&&!e.isLeaf&&e.canAppend(t))}function M2e(e,t,n){let o=new oo(t-n,t+n,Ye.empty,!0);e.step(o)}function O2e(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 I2e(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 aC(e,t,n=t,o=Ye.empty){if(t==n&&!o.size)return null;let r=e.resolve(t),s=e.resolve(n);return pA(r,s,o)?new oo(t,n,o):new A2e(r,s,o).fit()}function pA(e,t,n){return!n.openStart&&!n.openEnd&&e.start()==t.start()&&e.parent.canReplace(e.index(),t.index(),n.content)}class A2e{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 oo(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=Ty(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=Ty(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=Ty(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(hA(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 Ty(e,t){for(let n=0;n<t;n++)e=e.firstChild.content;return e}function hA(e,t,n){if(t<=0)return e;let o=e.content;return t>1&&(o=o.replaceChild(0,hA(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&&!N2e(n,s.content,i)?l:null}function N2e(e,t,n){for(let o=n;o<t.childCount;o++)if(!e.allowsMarks(t.child(o).marks))return!0;return!1}function P2e(e){return e.spec.defining||e.spec.definingForContent}function L2e(e,t,n,o){if(!o.size)return e.deleteRange(t,n);let r=e.doc.resolve(t),s=e.doc.resolve(n);if(pA(r,s,o))return e.step(new oo(t,n,o));let i=gA(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=P2e(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(mA(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 mA(e,t,n,o,r){if(t<n){let s=e.firstChild;e=e.replaceChild(0,s.copy(mA(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 R2e(e,t,n,o){if(!o.isInline&&t==n&&e.doc.resolve(t).parent.content.size){let r=O2e(e.doc,t,o.type);r!=null&&(t=n=r)}e.replaceRange(t,n,new Ye(Ue.from(o),0,0))}function D2e(e,t,n){let o=e.doc.resolve(t),r=e.doc.resolve(n),s=gA(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 gA(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 wo{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 Dn.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 Dn.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)}}wo.jsonID("attr",xc);class zp extends wo{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 Dn.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)}}wo.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 vA{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=aC(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 L2e(this,t,n,o),this}replaceRangeWith(t,n,o){return R2e(this,t,n,o),this}deleteRange(t,n){return D2e(this,t,n),this}lift(t,n){return y2e(this,t,n),this}join(t,n=1){return M2e(this,t,n),this}wrap(t,n){return w2e(this,t,n),this}setBlockType(t,n=t,o,r=null){return C2e(this,t,n,o,r),this}setNodeMarkup(t,n,o=null,r){return E2e(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 x2e(this,t,n,o),this}addMark(t,n,o){return m2e(this,t,n,o),this}removeMark(t,n,o){return g2e(this,t,n,o),this}clearIncompatible(t,n,o){return fA(this,t,n,o),this}}const Oy=Object.create(null);class bt{constructor(t,n,o){this.$anchor=t,this.$head=n,this.ranges=o||[new Jg(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&&FS(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),FS(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=Oy[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 Oy)throw new RangeError("Duplicate use of selection JSON ID "+t);return Oy[t]=n,n.prototype.jsonID=t,n}getBookmark(){return ht.between(this.$anchor,this.$head).getBookmark()}}bt.prototype.visible=!0;class Jg{constructor(t,n){this.$from=t,this.$to=n}}let DS=!1;function VS(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){VS(t),VS(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 lv(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 lv{constructor(t,n){this.anchor=t,this.head=n}map(t){return new lv(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 uC(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 uC{constructor(t){this.anchor=t}map(t){let{deleted:n,pos:o}=t.mapResult(this.anchor);return n?new lv(o,o):new uC(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 V2e}}bt.jsonID("all",gr);const V2e={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 FS(e,t,n){let o=e.steps.length-1;if(o<t)return;let r=e.steps[o];if(!(r instanceof oo||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,$m=2,zS=4;class F2e extends vA{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)&~$m,this.storedMarks=null,this}get selectionSet(){return(this.updated&BS)>0}setStoredMarks(t){return this.storedMarks=t,this.updated|=$m,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&$m)>0}addStep(t,n){super.addStep(t,n),this.updated=this.updated&~$m,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 B2e=[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 Iy{constructor(t,n){this.schema=t,this.plugins=[],this.pluginsByKey=Object.create(null),this.fields=B2e.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 Da{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 Da(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 Iy(t.doc?t.doc.type.schema:t.schema,t.plugins),o=new Da(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 Iy(this.schema,t.plugins),o=n.fields,r=new Da(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 Iy(t.schema,t.plugins),s=new Da(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 yA(e,t,n){for(let o in e){let r=e[o];r instanceof Function?r=r.bind(t):o=="handleDOMEvents"&&(r=yA(r,t,{})),n[o]=r}return n}class xn{constructor(t){this.spec=t,this.props={},t.props&&yA(t.props,this,this.props),this.key=t.key?t.key.key:_A("plugin")}getState(t){return t[this.key]}}const Ay=Object.create(null);function _A(e){return e in Ay?e+"$"+ ++Ay[e]:(Ay[e]=0,e+"$")}class wn{constructor(t="key"){this.key=_A(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"?z2e(n):n,this.undoable=o.undoable!==!1,this.inCode=o.inCode||!1}}function z2e(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 j2e=(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 cC(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&&lC(d,t,a);if(!f)return null;u.wrap(d,f);let p=u.doc.resolve(i-1).nodeBefore;return p&&p.type==t&&iv(u.doc,i-1)&&(!o||o(s,p))&&u.join(i-1),u})}function bA(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 Kl=typeof navigator<"u"?navigator:null,HS=typeof document<"u"?document:null,sa=Kl&&Kl.userAgent||"",Qb=/Edge\/(\d+)/.exec(sa),wA=/MSIE \d/.exec(sa),e2=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(sa),av=!!(wA||e2||Qb),H2e=wA?document.documentMode:e2?+e2[1]:Qb?+Qb[1]:0,CA=!av&&/gecko\/(\d+)/i.test(sa),U2e=CA&&+(/Firefox\/(\d+)/.exec(sa)||[0,0])[1],t2=!av&&/Chrome\/(\d+)/.exec(sa),W2e=!!t2,K2e=t2?+t2[1]:0,kA=!av&&!!Kl&&/Apple Computer/.test(Kl.vendor),SA=kA&&(/Mobile\/\w+/.test(sa)||!!Kl&&Kl.maxTouchPoints>2),q2e=SA||(Kl?/Mac/.test(Kl.platform):!1),G2e=/Android \d/.test(sa),$A=!!HS&&"webkitFontSmoothing"in HS.documentElement.style,Y2e=$A?+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]:0;var Em=Object.freeze({__proto__:null,android:G2e,chrome:W2e,chrome_version:K2e,gecko:CA,gecko_version:U2e,ie:av,ie_version:H2e,ios:SA,mac:q2e,safari:kA,webkit:$A,webkit_version:Y2e});function Ny(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 Z2e=new wn("MILKDOWN_CUSTOM_INPUTRULES");function J2e({rules:e}){const t=new xn({key:Z2e,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 Ny(n,o,r,s,e,t)},handleDOMEvents:{compositionend:n=>(setTimeout(()=>{const{$cursor:o}=n.state.selection;o&&Ny(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?Ny(n,r.pos,r.pos,` |
| 113 |
`,e,t):!1}}});return t}function Th(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 X2e=Object.defineProperty,Q2e=Object.defineProperties,ewe=Object.getOwnPropertyDescriptors,US=Object.getOwnPropertySymbols,twe=Object.prototype.hasOwnProperty,nwe=Object.prototype.propertyIsEnumerable,WS=(e,t,n)=>t in e?X2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,owe=(e,t)=>{for(var n in t||(t={}))twe.call(t,n)&&WS(e,n,t[n]);if(US)for(var n of US(t))nwe.call(t,n)&&WS(e,n,t[n]);return e},rwe=(e,t)=>Q2e(e,ewe(t));function KS(e=0,t=0,n=0){return Math.min(Math.max(e,t),n)}function uv(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 rwe(owe({},v),{toJSON:()=>v})}function cv(e){return Object.assign(Object.create(e),e).setTime(Date.now())}function swe(e,t){return Array.isArray(e)&&e.includes(t.type)||t.type===e}function dC(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 iwe(e,t){return dC(n=>n.type===t)(e)}function lwe(e,t){const n=t.nodes[e];if(!n)throw ove("node",e);return n}function fC(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 awe(e){return t=>fC(e)(t.$from)}function uwe(e,t){if(!(e instanceof mt))return;const{node:n,$from:o}=e;if(swe(t,n))return{node:n,pos:o.pos,start:o.start(o.depth),depth:o.depth}}const pC=(e,t)=>e.selection.empty?!1:(t&&t(e.tr.deleteSelection().scrollIntoView()),!0);function cwe(e,t){let{$cursor:n}=e.selection;return!n||(t?!t.endOfTextblock("backward",e):n.parentOffset>0)?null:n}const EA=(e,t,n)=>{let o=cwe(e,n);if(!o)return!1;let r=TA(o);if(!r){let i=o.blockRange(),l=i&&sv(i);return l==null?!1:(t&&t(e.tr.lift(i,l).scrollIntoView()),!0)}let s=r.nodeBefore;if(OA(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=aC(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 xA=(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=TA(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 TA(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 dwe(e,t){let{$cursor:n}=e.selection;return!n||(t?!t.endOfTextblock("forward",e):n.parentOffset<n.parent.content.size)?null:n}const fwe=(e,t,n)=>{let o=dwe(e,n);if(!o)return!1;let r=MA(o);if(!r)return!1;let s=r.nodeAfter;if(OA(e,r,t,1))return!0;if(o.parent.content.size==0&&(fd(s,"start")||mt.isSelectable(s))){let i=aC(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},pwe=(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=MA(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 MA(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 hwe=(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 hC(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 mwe=(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=hC(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},gwe=(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=hC(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},vwe=(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&&sv(o);return r==null?!1:(t&&t(e.tr.lift(o,r).scrollIntoView()),!0)};function ywe(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:hC(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 _we=ywe(),bwe=(e,t)=>(t&&t(e.tr.setSelection(new gr(e.doc))),!0);function wwe(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||iv(e.doc,t.pos))?!1:(n&&n(e.tr.clearIncompatible(t.pos,o.type,o.contentMatchAt(o.childCount)).join(t.pos).scrollIntoView()),!0)}function OA(e,t,n,o){let r=t.nodeBefore,s=t.nodeAfter,i,l,a=r.type.spec.isolating||s.type.spec.isolating;if(!a&&wwe(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;iv(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&&sv(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 IA(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 Cwe=IA(-1),kwe=IA(1);function mC(e,t=null){return function(n,o){let{$from:r,$to:s}=n.selection,i=r.blockRange(s),l=i&&lC(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 Swe(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 $we(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 Jg(o,o.doc.resolve(i+1))),o=o.doc.resolve(i+1+s.content.size),!1}),o.pos<r.pos&&t.push(new Jg(o,r))}return t}function dv(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||!Swe(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=$we(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 fv(...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 Py=fv(pC,EA,xA),qS=fv(pC,fwe,pwe);const yi={Enter:fv(hwe,gwe,vwe,_we),"Mod-Enter":mwe,Backspace:Py,"Mod-Backspace":Py,"Shift-Backspace":Py,Delete:qS,"Mod-Delete":qS,"Mod-a":bwe},AA={"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":Cwe,"Ctrl-e":kwe};for(let e in yi)AA[e]=yi[e];const Ewe=typeof navigator<"u"?/Mac|iP(hone|[oa]d)/.test(navigator.platform):typeof os<"u"&&os.platform?os.platform()=="darwin":!1,xwe=Ewe?AA:yi;var ql={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:"'"},Xg={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},Twe=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 ro=0;ro<10;ro++)ql[48+ro]=ql[96+ro]=String(ro);for(var ro=1;ro<=24;ro++)ql[ro+111]="F"+ro;for(var ro=65;ro<=90;ro++)ql[ro]=String.fromCharCode(ro+32),Xg[ro]=String.fromCharCode(ro);for(var Ly in ql)Xg.hasOwnProperty(Ly)||(Xg[Ly]=ql[Ly]);function Owe(e){var t=Twe&&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?Xg:ql)[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 Iwe=typeof navigator<"u"?/Mac|iP(hone|[oa]d)/.test(navigator.platform):!1;function Awe(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))Iwe?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 Nwe(e){let t=Object.create(null);for(let n in e)t[Awe(n)]=e[n];return t}function Ry(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 NA(e){return new xn({props:{handleKeyDown:PA(e)}})}function PA(e){let t=Nwe(e);return function(n,o){let r=Owe(o),s,i=t[Ry(r,o)];if(i&&i(n.state,n.dispatch,n))return!0;if(r.length==1&&r!=" "){if(o.shiftKey){let l=t[Ry(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=ql[o.keyCode])&&s!=r){let l=t[Ry(s,o)];if(l&&l(n.state,n.dispatch,n))return!0}}return!1}}const so=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 n2=null;const vi=function(e,t,n){let o=n2||(n2=document.createRange());return o.setEnd(e,n??e.nodeValue.length),o.setStart(e,t||0),o},Pwe=function(){n2=null},mu=function(e,t,n,o){return n&&(GS(e,t,n,o,-1)||GS(e,t,n,o,1))},Lwe=/^(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:js(e))){let s=e.parentNode;if(!s||s.nodeType!=1||Mh(e)||Lwe.test(e.nodeName)||e.contentEditable=="false")return!1;t=so(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?js(e):0}else return!1}}function js(e){return e.nodeType==3?e.nodeValue.length:e.childNodes.length}function Rwe(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=js(e)}else if(e.parentNode&&!Mh(e))t=so(e),e=e.parentNode;else return null}}function Dwe(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=so(e)+1,e=e.parentNode;else return null}}function Vwe(e,t,n){for(let o=t==0,r=t==js(e);o||r;){if(e==n)return!0;let s=so(e);if(e=e.parentNode,!e)return!1;o=o&&s==0,r=r&&s==js(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 pv=function(e){return e.focusNode&&mu(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)};function Ma(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 Bwe(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 Qs=typeof navigator<"u"?navigator:null,YS=typeof document<"u"?document:null,ia=Qs&&Qs.userAgent||"",o2=/Edge\/(\d+)/.exec(ia),LA=/MSIE \d/.exec(ia),r2=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(ia),Go=!!(LA||r2||o2),Rl=LA?document.documentMode:r2?+r2[1]:o2?+o2[1]:0,vs=!Go&&/gecko\/(\d+)/i.test(ia);vs&&+(/Firefox\/(\d+)/.exec(ia)||[0,0])[1];const s2=!Go&&/Chrome\/(\d+)/.exec(ia),mo=!!s2,RA=s2?+s2[1]:0,Ao=!Go&&!!Qs&&/Apple Computer/.test(Qs.vendor),pd=Ao&&(/Mobile\/\w+/.test(ia)||!!Qs&&Qs.maxTouchPoints>2),Er=pd||(Qs?/Mac/.test(Qs.platform):!1),zwe=Qs?/Win/.test(Qs.platform):!1,rs=/Android \d/.test(ia),Oh=!!YS&&"webkitFontSmoothing"in YS.documentElement.style,jwe=Oh?+(/\bAppleWebKit\/(\d+)/.exec(navigator.userAgent)||[0,0])[1]:0;function Hwe(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 Uwe(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?Hwe(s):Uwe(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 Wwe(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:DA(e.dom)}}function DA(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 Kwe({refDOM:e,refTop:t,stack:n}){let o=e?e.getBoundingClientRect().top:0;VA(n,o==0?0:o-t)}function VA(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 qwe(e){if(e.setActive)return e.setActive();if(Ru)return e.focus(Ru);let t=DA(e);e.focus(Ru==null?{get preventScroll(){return Ru={preventScroll:!0},!0}}:void 0),Ru||(Ru=!1,VA(t,0))}function FA(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?Gwe(n,r):!n||o&&n.nodeType==1?{node:e,offset:s}:FA(n,r)}function Gwe(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&&gC(t,s))return{node:e,offset:r+(t.left>=(s.left+s.right)/2?1:0)}}return{node:e,offset:0}}function gC(e,t){return e.left>=t.left-1&&e.left<=t.right+1&&e.top>=t.top-1&&e.top<=t.bottom+1}function Ywe(e,t){let n=e.parentNode;return n&&/^li$/i.test(n.nodeName)&&t.left<e.getBoundingClientRect().left?n:e}function Zwe(e,t,n){let{node:o,offset:r}=FA(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 Jwe(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 BA(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(gC(t,u))return BA(i,t,u)}}if((s=(s+1)%o)==r)break}return e}function Xwe(e,t){let n=e.dom.ownerDocument,o,r=0,s=Bwe(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(!gC(t,u)||(i=BA(e.dom,t,u),!i))return null}if(Ao)for(let u=i;o&&u;u=Hp(u))u.draggable&&(o=void 0);if(i=Ywe(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;Oh&&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=Jwe(e,o,r,t))}l==null&&(l=Zwe(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 Qwe=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/;function zA(e,t,n){let{node:o,offset:r,atom:s}=e.docView.domFromPos(t,n<0?-1:1),i=Oh||vs;if(o.nodeType==3)if(i&&(Qwe.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==js(o))){let a=o.childNodes[r-1];if(a.nodeType==1)return Dy(a.getBoundingClientRect(),!1)}if(s==null&&r<js(o)){let a=o.childNodes[r];if(a.nodeType==1)return Dy(a.getBoundingClientRect(),!0)}return Dy(o.getBoundingClientRect(),n>=0)}if(s==null&&r&&(n<0||r==js(o))){let a=o.childNodes[r-1],u=a.nodeType==3?vi(a,js(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<js(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 Dy(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 jA(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 e3e(e,t,n){let o=t.selection,r=n=="up"?o.$from:o.$to;return jA(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=zA(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 t3e=/[\u0590-\u08ac]/;function n3e(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?!t3e.test(o.parent.textContent)||!l.modify?n=="left"||n=="backward"?s:i:jA(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 o3e(e,t,n){return XS==t&&QS==n?e9:(XS=t,QS=n,e9=n=="up"||n=="down"?e3e(e,t,n):n3e(e,t,n))}const Dr=0,t9=1,Va=2,ei=3;class Ih{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>so(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 UA){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 HA&&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?so(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?so(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=so(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=so(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||Ao)&&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:so(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&&Ao)&&mu(l.node,l.offset,u.anchorNode,u.anchorOffset)&&mu(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?Va:t9,t==l&&n==a&&(s.contentLost||s.dom.parentNode!=this.contentDOM)?s.dirty=ei:s.markDirty(t-l,n-l);return}else s.dirty=s.dom==s.contentDOM&&s.dom.parentNode==this.contentDOM&&!s.children.length?Va:ei}o=i}this.dirty=Va}markParentsDirty(){let t=1;for(let n=this.parent;n;n=n.parent,t++){let o=t==1?Va:t9;n.dirty<o&&(n.dirty=o)}}get domAtom(){return!1}get ignoreForCoords(){return!1}isText(t){return!1}}class HA extends Ih{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 r3e extends Ih{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 gu extends Ih{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=oa.renderSpec(document,n.type.spec.toDOM(n,o),null,n.attrs)),new gu(t,n,i.dom,i.contentDOM||i.dom)}parseRule(){return this.dirty&ei||this.mark.type.spec.reparseInView?null:{mark:this.mark.type.name,attrs:this.mark.attrs,contentElement:this.contentDOM}}matchesMark(t){return this.dirty!=ei&&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=gu.create(this.parent,this.mark,!0,o),s=this.children,i=this.size;n<i&&(s=a2(s,n,i,o)),t>0&&(s=a2(s,0,t,o));for(let l=0;l<s.length;l++)s[l].parent=r;return r.children=s,r}}class Dl extends Ih{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}=oa.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=qA(c,o,n),u?a=new s3e(t,n,o,r,c,d||null,f,u,s,i+1):n.isText?new hv(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)&&l2(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 l3e(this,i&&i.node,t);c3e(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==Va)&&(i&&this.protectLocalComposition(t,i),WA(this.contentDOM,this.children,t),pd&&d3e(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=f3e(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 r3e(this,s,n,r);t.input.compositionNodes.push(i),this.children=a2(this.children,o,o+r.length,t,i)}update(t,n,o,r){return this.dirty==ei||!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(l2(t,this.outerDeco))return;let n=this.nodeDOM.nodeType!=1,o=this.dom;this.dom=KA(this.dom,this.nodeDOM,i2(this.outerDeco,this.node,n),i2(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){qA(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 hv 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==ei||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 hv(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=ei)}get domAtom(){return!1}isText(t){return this.node.text==t}}class UA extends Ih{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 s3e 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==ei)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 WA(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 gu){let a=o?o.previousSibling:e.lastChild;WA(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 Fa=[new np];function i2(e,t,n){if(e.length==0)return Fa;let o=n?Fa[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 KA(e,t,n,o){if(n==Fa&&o==Fa)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=Fa[0]),r=a}i3e(r,l||Fa[0],i)}return r}function i3e(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 qA(e,t,n){return KA(e,e,Fa,i2(t,n,e.nodeType!=1))}function l2(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 l3e{constructor(t,n,o){this.lock=n,this.view=o,this.index=0,this.stack=[],this.changed=!1,this.top=t,this.preMatch=a3e(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=gu.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==ei&&i.dom==i.contentDOM&&(i.dirty=Va),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!=ei&&l2(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=Va,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 HA(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 gu;)n=t,t=n.children[n.children.length-1];(!t||!(t instanceof hv)||/\n$/.test(t.node.text)||this.view.requiresGeckoHackNode&&/\s$/.test(t.node.text))&&((Ao||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 UA(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 a3e(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 gu)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 u3e(e,t){return e.type.side-t.type.side}function c3e(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(u3e);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 d3e(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 f3e(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 a2(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 vC(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(pv(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&&Vwe(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=yC(e,a,l,c)}return u}function GA(e){return e.editable?e.hasFocus():ZA(e)&&document.activeElement&&document.activeElement.contains(e.dom)}function Oi(e,t=!1){let n=e.state.selection;if(YA(e,n),!!GA(e)){if(!t&&e.input.mouseDown&&e.input.mouseDown.allowDefault&&mo){let o=e.domSelectionRange(),r=e.domObserver.currentSelection;if(o.anchorNode&&r.anchorNode&&mu(o.anchorNode,o.anchorOffset,r.anchorNode,r.anchorOffset)){e.input.mouseDown.delayedSelectionSync=!0,e.domObserver.setCurSelection();return}}if(e.domObserver.disconnectSelection(),e.cursorWrapper)h3e(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&&p3e(e))}e.domObserver.setCurSelection(),e.domObserver.connectSelection()}}const r9=Ao||mo&&RA<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(Ao&&r&&r.contentEditable=="false")return Vy(r);if((!r||r.contentEditable=="false")&&(!s||s.contentEditable=="false")){if(r)return Vy(r);if(s)return Vy(s)}}function Vy(e){return e.contentEditable="true",Ao&&e.draggable&&(e.draggable=!1,e.wasDraggable=!0),e}function i9(e){e.contentEditable="false",e.wasDraggable&&(e.draggable=!0,e.wasDraggable=null)}function p3e(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(()=>{(!GA(e)||e.state.selection.visible)&&e.dom.classList.remove("ProseMirror-hideselection")},20))})}function h3e(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,so(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 YA(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 yC(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:ZA(e)}function ZA(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 m3e(e){let t=e.docView.domFromPos(e.state.selection.anchor,0),n=e.domSelectionRange();return mu(t.node,t.offset,n.anchorNode,n.anchorOffset)}function u2(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=u2(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)):Oh?_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=u2(e.state,t);return r?_l(e,r):!1}}}function Qg(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?g3e(e):v3e(e)}function g3e(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<Qg(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(JA(n))break;{let l=n.previousSibling;for(;l&&op(l,-1);)r=n.parentNode,s=so(l),l=l.previousSibling;if(l)n=l,o=Qg(n);else{if(n=n.parentNode,n==e.dom)break;o=0}}}i?c2(e,n,o):r&&c2(e,r,s)}function v3e(e){let t=e.domSelectionRange(),n=t.focusNode,o=t.focusOffset;if(!n)return;let r=Qg(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(JA(n))break;{let l=n.nextSibling;for(;l&&op(l,1);)s=l.parentNode,i=so(l)+1,l=l.nextSibling;if(l)n=l,o=0,r=Qg(n);else{if(n=n.parentNode,n==e.dom)break;o=r=0}}}s&&c2(e,s,i)}function JA(e){let t=e.pmViewDesc;return t&&t.node&&t.node.isBlock}function y3e(e,t){for(;e&&t==e.childNodes.length&&!Mh(e);)t=so(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 _3e(e,t){for(;e&&!t&&!Mh(e);)t=so(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 c2(e,t,n){if(t.nodeType!=3){let s,i;(i=y3e(t,n))?(t=i,n=0):(s=_3e(t,n))&&(t=s,n=s.nodeValue.length)}let o=e.domSelection();if(!o)return;if(pv(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||zwe)&&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=u2(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 b3e(e){if(!Ao||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 w3e(e){let t="";return e.ctrlKey&&(t+="c"),e.metaKey&&(t+="m"),e.altKey&&(t+="a"),e.shiftKey&&(t+="s"),t}function C3e(e,t){let n=t.keyCode,o=w3e(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 b3e(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 XA(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")||oa.fromSchema(e.state.schema),l=rN(),a=l.createElement("div");a.appendChild(i.serializeFragment(o,{document:l}));let u=a.firstChild,c,d=0;for(;u&&u.nodeType==1&&(c=oN[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 QA(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=oa.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=$3e(n),Oh&&E3e(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")||pu.fromSchema(e.state.schema)).parseSlice(i,{preserveWhitespace:!!(a||c),context:r,ruleFromNode(f){return f.nodeName=="BR"&&!f.nextSibling&&f.parentNode&&!k3e.test(f.parentNode.nodeName)?{ignore:!0}:null}})),c)l=x3e(h9(l,+c[1],+c[2]),c[4]);else if(l=Ye.maxOpen(S3e(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 k3e=/^(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 S3e(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&&tN(a,s,l,i[i.length-1],0))i[i.length-1]=u;else{i.length&&(i[i.length-1]=nN(i[i.length-1],s.length));let c=eN(l,a);i.push(c),r=r.matchType(c.type),s=a}}),i)return Ue.from(i)}return e}function eN(e,t,n=0){for(let o=t.length-1;o>=n;o--)e=t[o].create(null,Ue.from(e));return e}function tN(e,t,n,o,r){if(r<e.length&&r<t.length&&e[r]==t[r]){let s=tN(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(eN(n,e,r+1))))}}function nN(e,t){if(t==0)return e;let n=e.content.replaceChild(e.childCount-1,nN(e.lastChild,t-1)),o=e.contentMatchAt(e.childCount).fillBefore(Ue.empty,!0);return e.copy(n.append(o))}function d2(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=d2(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(d2(e.content,-1,t,e.openStart,0,e.openEnd),t,e.openEnd)),n<e.openEnd&&(e=new Ye(d2(e.content,1,n,e.openEnd,0,0),e.openStart,n)),e}const oN={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 rN(){return m9||(m9=document.implementation.createHTMLDocument("title"))}function $3e(e){let t=/^(\s*<meta [^>]*>)*/.exec(e);t&&(e=e.slice(t[0].length));let n=rN().createElement("div"),o=/<([a-z][^>\s]+)/i.exec(e),r;if((r=o&&oN[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 E3e(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 x3e(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 No={},Po={},T3e={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 O3e(e){for(let t in No){let n=No[t];e.dom.addEventListener(t,e.input.eventHandlers[t]=o=>{A3e(e,o)&&!_C(e,o)&&(e.editable||!(o.type in Po))&&n(e,o)},T3e[t]?{passive:!0}:void 0)}Ao&&e.dom.addEventListener("input",()=>null),f2(e)}function Il(e,t){e.input.lastSelectionOrigin=t,e.input.lastSelectionTime=Date.now()}function I3e(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 f2(e){e.someProp("handleDOMEvents",t=>{for(let n in t)e.input.eventHandlers[n]||e.dom.addEventListener(n,e.input.eventHandlers[n]=o=>_C(e,o))})}function _C(e,t){return e.someProp("handleDOMEvents",n=>{let o=n[t.type];return o?o(e,t)||t.defaultPrevented:!1})}function A3e(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 N3e(e,t){!_C(e,t)&&No[t.type]&&(e.editable||!(t.type in Po))&&No[t.type](e,t)}Po.keydown=(e,t)=>{let n=t;if(e.input.shiftKey=n.keyCode==16||n.shiftKey,!iN(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,Ma(13,"Enter"))),e.input.lastIOSEnter=0)},200)}else e.someProp("handleKeyDown",o=>o(e,n))||C3e(e,n)?n.preventDefault():Il(e,"key")};Po.keyup=(e,t)=>{t.keyCode==16&&(e.input.shiftKey=!1)};Po.keypress=(e,t)=>{let n=t;if(iN(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 mv(e){return{left:e.clientX,top:e.clientY}}function P3e(e,t){let n=t.x-e.clientX,o=t.y-e.clientY;return n*n+o*o<100}function bC(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 Tc(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 L3e(e,t){if(t==-1)return!1;let n=e.state.doc.resolve(t),o=n.nodeAfter;return o&&o.isAtom&&mt.isSelectable(o)?(Tc(e,new mt(n),"pointer"),!0):!1}function R3e(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?(Tc(e,mt.create(e.state.doc,r),"pointer"),!0):!1}function D3e(e,t,n,o,r){return bC(e,"handleClickOn",t,n,o)||e.someProp("handleClick",s=>s(e,t,o))||(r?R3e(e,n):L3e(e,n))}function V3e(e,t,n,o){return bC(e,"handleDoubleClickOn",t,n,o)||e.someProp("handleDoubleClick",r=>r(e,t,o))}function F3e(e,t,n,o){return bC(e,"handleTripleClickOn",t,n,o)||e.someProp("handleTripleClick",r=>r(e,t,o))||B3e(e,n,o)}function B3e(e,t,n){if(n.button!=0)return!1;let o=e.state.doc;if(t==-1)return o.inlineContent?(Tc(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)Tc(e,ht.create(o,l+1,l+1+i.content.size),"pointer");else if(mt.isSelectable(i))Tc(e,mt.create(o,l),"pointer");else continue;return!0}}function wC(e){return e0(e)}const sN=Er?"metaKey":"ctrlKey";No.mousedown=(e,t)=>{let n=t;e.input.shiftKey=n.shiftKey;let o=wC(e),r=Date.now(),s="singleClick";r-e.input.lastClick.time<500&&P3e(n,e.input.lastClick)&&!n[sN]&&(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(mv(n));i&&(s=="singleClick"?(e.input.mouseDown&&e.input.mouseDown.done(),e.input.mouseDown=new z3e(e,i,n,!!o)):(s=="doubleClick"?V3e:F3e)(e,i.pos,i.inside,n)?n.preventDefault():Il(e,"pointer"))};class z3e{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[sN],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(mv(t))),this.updateAllowDefault(t),this.allowDefault||!n?Il(this.view,"pointer"):D3e(this.view,n.pos,n.inside,t,this.selectNode)?t.preventDefault():t.button==0&&(this.flushed||Ao&&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)?(Tc(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)}}No.touchstart=e=>{e.input.lastTouch=Date.now(),wC(e),Il(e,"pointer")};No.touchmove=e=>{e.input.lastTouch=Date.now(),Il(e,"pointer")};No.contextmenu=e=>wC(e);function iN(e,t){return e.composing?!0:Ao&&Math.abs(t.timeStamp-e.input.compositionEndedAt)<500?(e.input.compositionEndedAt=-2e8,!0):!1}const j3e=rs?5e3:-1;Po.compositionstart=Po.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(),e0(e,!0),e.markCursor=null;else if(e0(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}lN(e,j3e)};Po.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++,lN(e,20))};function lN(e,t){clearTimeout(e.input.composingTimeout),t>-1&&(e.input.composingTimeout=setTimeout(()=>e0(e),t))}function aN(e){for(e.composing&&(e.input.composing=!1,e.input.compositionEndedAt=U3e());e.input.compositionNodes.length>0;)e.input.compositionNodes.pop().markParentsDirty()}function H3e(e){let t=e.domSelectionRange();if(!t.focusNode)return null;let n=Rwe(t.focusNode,t.focusOffset),o=Dwe(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 U3e(){let e=document.createEvent("Event");return e.initEvent("event",!0,!0),e.timeStamp}function e0(e,t=!1){if(!(rs&&e.domObserver.flushingSoon>=0)){if(e.domObserver.forceFlush(),aN(e),t||e.docView&&e.docView.dirty){let n=vC(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 W3e(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&&jwe<604;No.copy=Po.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}=XA(e,i);s?(n.preventDefault(),s.clearData(),s.setData("text/html",l.innerHTML),s.setData("text/plain",a)):W3e(e,l),r&&e.dispatch(e.state.tr.deleteSelection().scrollIntoView().setMeta("uiEvent","cut"))};function K3e(e){return e.openStart==0&&e.openEnd==0&&e.content.childCount==1?e.content.firstChild:null}function q3e(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=QA(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=K3e(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 uN(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," "):""}Po.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,uN(o),o.getData("text/html"),r,n)?n.preventDefault():q3e(e,n)};class cN{constructor(t,n,o){this.slice=t,this.move=n,this.node=o}}const dN=Er?"altKey":"ctrlKey";No.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(mv(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}=XA(e,l);(!n.dataTransfer.files.length||!mo||RA>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 cN(c,!n[dN],i)};No.dragend=e=>{let t=e.dragging;window.setTimeout(()=>{e.dragging==t&&(e.dragging=null)},50)};Po.dragover=Po.dragenter=(e,t)=>t.preventDefault();Po.drop=(e,t)=>{let n=t,o=e.dragging;if(e.dragging=null,!n.dataTransfer)return;let r=e.posAtCoords(mv(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=QA(e,uN(n.dataTransfer),Up?null:n.dataTransfer.getData("text/html"),!1,s);let l=!!(o&&!n[dN]);if(e.someProp("handleDrop",h=>h(e,n,i||Ye.empty,l))){n.preventDefault();return}if(!i)return;n.preventDefault();let a=i?I2e(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(yC(e,p,u.doc.resolve(h)))}e.focus(),e.dispatch(u.setMeta("uiEvent","drop"))};No.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))};No.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)};No.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,Ma(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 Po)No[e]=Po[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 t0{constructor(t,n){this.toDOM=t,this.spec=n||Za,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 Un(s-o,s-o,this)}valid(){return!0}eq(t){return this==t||t instanceof t0&&(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 Vl{constructor(t,n){this.attrs=t,this.spec=n||Za}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 Un(s,i,this)}valid(t,n){return n.from<n.to}eq(t){return this==t||t instanceof Vl&&Kp(this.attrs,t.attrs)&&Kp(this.spec,t.spec)}static is(t){return t.type instanceof Vl}destroy(){}}class CC{constructor(t,n){this.attrs=t,this.spec=n||Za}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 Un(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 CC&&Kp(this.attrs,t.attrs)&&Kp(this.spec,t.spec)}destroy(){}}class Un{constructor(t,n,o){this.from=t,this.to=n,this.type=o}copy(t,n){return new Un(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 Un(t,t,new t0(n,o))}static inline(t,n,o,r){return new Un(t,n,new Vl(o,r))}static node(t,n,o,r){return new Un(t,n,new CC(o,r))}get spec(){return this.type.spec}get inline(){return this.type instanceof Vl}get widget(){return this.type instanceof t0}}const ec=[],Za={};class an{constructor(t,n){this.local=t.length?t:ec,this.children=n.length?n:ec}static create(t,n){return n.length?n0(n,t,0,Za):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||Za)}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?G3e(this.children,i||[],t,n,o,r,s):i?new an(i.sort(Ja),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=pN(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,n0(c,l,u+1,Za)),s+=3}});let i=fN(s?hN(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(Ja):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 Vl){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(Ja),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 kC(this.localsInner(t))}localsInner(t){if(this==fo)return ec;if(t.inlineContent||!this.local.some(Vl.is))return this.local;let n=[];for(let o=0;o<this.local.length;o++)this.local[o].type instanceof Vl||n.push(this.local[o]);return n}forEachSet(t){t(this)}}an.empty=new an([],[]);an.removeOverlap=kC;const fo=an.empty;class Sl{constructor(t){this.members=t}map(t,n){const o=this.members.map(r=>r.map(t,n,Za));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?kC(o?n:n.sort(Ja)):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 G3e(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=Y3e(l,e,t,n,r,s,i),c=n0(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(Ja),l)}function fN(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 Un(r.from+t,r.to+t,r.type))}return n}function Y3e(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 pN(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 hN(e){let t=[];for(let n=0;n<e.length;n++)e[n]!=null&&t.push(e[n]);return t}function n0(e,t,n,o){let r=[],s=!1;t.forEach((l,a)=>{let u=pN(e,l,a+n);if(u){s=!0;let c=n0(u,l,n+a+1,o);c!=fo&&r.push(a,a+l.nodeSize,c)}});let i=fN(s?hN(e):e,-n).sort(Ja);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 Ja(e,t){return e.from-t.from||e.to-t.to}function kC(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&&Ja(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 Z3e={childList:!0,characterData:!0,characterDataOldValue:!0,attributes:!0,attributeOldValue:!0,subtree:!0},J3e=Go&&Rl<=11;class X3e{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 Q3e{constructor(t,n){this.view=t,this.handleDOMChange=n,this.queue=[],this.flushingSoon=-1,this.observer=null,this.currentSelection=new X3e,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()}),J3e&&(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,Z3e)),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&&mu(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||nCe(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&&pv(o)&&(u=vC(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),eCe(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?so(r)+1:0,l=o.localPosFromDOM(t.target,i,-1),a=s&&s.parentNode==t.target?so(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 eCe(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 mu(i.node,i.offset,r,s)&&([n,o,r,s]=[r,s,n,o]),{anchorNode:n,anchorOffset:o,focusNode:r,focusOffset:s}}function tCe(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 nCe(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 oCe(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}],pv(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")||pu.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:rCe,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 rCe(e){let t=e.pmViewDesc;if(t)return t.parseRule();if(e.nodeName=="BR"&&e.parentNode){if(Ao&&/^(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||Ao&&/^(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 sCe=/^(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 iCe(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=vC(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,Ma(13,"Enter"))))return;let V=e.state.tr.setSelection(N);P=="pointer"?V.setMeta("pointer",!0):P=="key"&&V.scrollIntoView(),s&&V.setMeta("composition",s),e.dispatch(V)}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=oCe(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=uCe(d.content,u.doc.content,u.from,f,p);if((pd&&e.input.lastIOSEnter>Date.now()-225||rs)&&r.some(P=>P.nodeType==1&&!sCe.test(P.nodeName))&&(!h||h.endA>=h.endB)&&e.someProp("handleKeyDown",P=>P(e,Ma(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,Ma(13,"Enter")))){e.input.lastIOSEnter=0;return}if(e.state.selection.anchor>h.start&&aCe(c,h.start,h.endA,m,y)&&e.someProp("handleKeyDown",P=>P(e,Ma(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,Ma(13,"Enter"))})},20));let S=h.start,x=h.endA,E,M,A;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),M=c.resolve(h.start).marksAcross(c.resolve(h.endA));else if(h.endA==h.endB&&(A=lCe(m.parent.content.cut(m.parentOffset,y.parentOffset),v.parent.content.cut(v.parentOffset,h.endA-v.start()))))E=e.state.tr,A.type=="add"?E.addMark(S,x,A.mark):E.removeMark(S,x,A.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)}M&&E.ensureMarks(M),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:yC(e,t.resolve(n.anchor),t.resolve(n.head))}function lCe(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 aCe(e,t,n,o,r){if(n-t<=r.pos-o.pos||By(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(By(s,!0,!0));return!i.parent.isTextblock||i.pos>n||By(i,!0,!1)<n?!1:o.parent.content.cut(o.parentOffset).eq(i.parent.content)}function By(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 uCe(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 cCe{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 Q3e(this,(o,r,s,i)=>iCe(this,o,r,s,i)),this.domObserver.start(),O3e(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&&f2(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&&(aN(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);fCe(p,this.nodeViews)&&(this.nodeViews=p,s=!0)}(l||n.handleDOMEvents!=this._props.handleDOMEvents)&&f2(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&&Wwe(this);if(i){this.domObserver.stop();let p=d&&(Go||mo)&&!this.composing&&!r.selection.empty&&!t.selection.empty&&dCe(r.selection,t.selection);if(d){let h=mo?this.trackWrites=this.domSelectionRange().focusNode:null;this.composing&&(this.input.compositionNode=H3e(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())&&m3e(this))?Oi(this,p):(YA(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&&Kwe(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 cN(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&&qwe(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 Xwe(this,t)}coordsAtPos(t,n=1){return zA(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 o3e(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&&(I3e(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,Pwe())}get isDestroyed(){return this.docView==null}dispatchEvent(t){return N3e(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?Ao&&this.root.nodeType===11&&Fwe(this.dom.ownerDocument)==this.dom&&tCe(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"),[Un.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:Un.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 dCe(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 fCe(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 mN=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},dt=(e,t,n)=>(mN(e,t,"read from private field"),n?n.call(e):t.get(e)),Qn=(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)=>(mN(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n);function la(e,t){return e.meta={package:"@milkdown/core",group:"System",...t},e}const gN={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"),zy=jt([],"initTimer"),x9=jt({},"editor"),qp=jt([],"inputRules"),ys=jt([],"prosePlugins"),Gp=jt([],"remarkPlugins"),p2=jt([],"nodeView"),h2=jt([],"markView"),Xa=jt(qb().use(Bb).use(Ub),"remark"),rp=jt({handlers:gN},"remarkStringifyOptions"),x1=na("ConfigReady");function pCe(e){const t=n=>(n.record(x1),async()=>(await e(n),n.done(x1),()=>{n.clearTimer(x1)}));return la(t,{displayName:"Config"}),t}const Qa=na("InitReady");function hCe(e){const t=n=>(n.inject(x9,e).inject(ys,[]).inject(Gp,[]).inject(qp,[]).inject(p2,[]).inject(h2,[]).inject(rp,{handlers:gN}).inject(Xa,qb().use(Bb).use(Ub)).inject(zy,[x1]).record(Qa),async()=>{await n.waitTimers(zy);const o=n.get(rp);return n.set(Xa,qb().use(Bb).use(Ub,o)),n.done(Qa),()=>{n.remove(x9).remove(ys).remove(Gp).remove(qp).remove(p2).remove(h2).remove(rp).remove(Xa).remove(zy).clearTimer(Qa)}});return la(t,{displayName:"Init"}),t}const Ks=na("SchemaReady"),jy=jt([],"schemaTimer"),ds=jt({},"schema"),Mc=jt([],"nodes"),Oc=jt([],"marks");function T9(e){var t;return{...e,parseDOM:(t=e.parseDOM)==null?void 0:t.map(n=>({priority:e.priority,...n}))}}const vN=e=>(e.inject(ds,{}).inject(Mc,[]).inject(Oc,[]).inject(jy,[Qa]).record(Ks),async()=>{await e.waitTimers(jy);const t=e.get(Xa),n=e.get(Gp).reduce((i,l)=>i.use(l.plugin,l.options),t);e.set(Xa,n);const o=Object.fromEntries(e.get(Mc).map(([i,l])=>[i,T9(l)])),r=Object.fromEntries(e.get(Oc).map(([i,l])=>[i,T9(l)])),s=new Ove({nodes:o,marks:r});return e.set(ds,s),e.done(Ks),()=>{e.remove(ds).remove(Mc).remove(Oc).remove(jy).clearTimer(Ks)}});la(vN,{displayName:"Schema"});var tc,Sa;let yN=class{constructor(){Qn(this,tc,void 0),Qn(this,Sa,void 0),_n(this,tc,new iI),_n(this,Sa,null),this.setCtx=t=>{_n(this,Sa,t)}}get ctx(){return dt(this,Sa)}create(t,n){const o=t.create(dt(this,tc).sliceMap);return o.set(n),o}get(t){return dt(this,tc).get(t).get()}remove(t){return dt(this,tc).remove(t)}call(t,n){if(dt(this,Sa)==null)throw rve();const o=this.get(t)(n),r=dt(this,Sa).get(bn);return o(r.state,r.dispatch,r)}};tc=new WeakMap,Sa=new WeakMap;function mCe(e="cmdKey"){return jt(()=>()=>!1,e)}const Vt=jt(new yN,"commands"),Hy=jt([Ks],"commandsTimer"),sp=na("CommandsReady"),_N=e=>{const t=new yN;return t.setCtx(e),e.inject(Vt,t).inject(Hy,[Ks]).record(sp),async()=>(await e.waitTimers(Hy),e.done(sp),()=>{e.remove(Vt).remove(Hy).clearTimer(sp)})};la(_N,{displayName:"Commands"});const T1=na("ParserReady"),bN=()=>{throw X3()},Ic=jt(bN,"parser"),Uy=jt([],"parserTimer"),wN=e=>(e.inject(Ic,bN).inject(Uy,[Ks]).record(T1),async()=>{await e.waitTimers(Uy);const t=e.get(Xa),n=e.get(ds);return e.set(Ic,c2e.create(n,t)),e.done(T1),()=>{e.remove(Ic).remove(Uy).clearTimer(T1)}});la(wN,{displayName:"Parser"});const ip=na("SerializerReady"),Wy=jt([],"serializerTimer"),CN=()=>{throw X3()},Ac=jt(CN,"serializer"),kN=e=>(e.inject(Ac,CN).inject(Wy,[Ks]).record(ip),async()=>{await e.waitTimers(Wy);const t=e.get(Xa),n=e.get(ds);return e.set(Ac,f2e.create(n,t)),e.done(ip),()=>{e.remove(Ac).remove(Wy).clearTimer(ip)}});la(kN,{displayName:"Serializer"});const M1=jt("","defaultValue"),O1=jt(e=>e,"stateOptions"),Ky=jt([],"editorStateTimer"),I1=na("EditorStateReady");function gCe(e,t,n){if(typeof e=="string")return t(e);if(e.type==="html")return pu.fromSchema(n).parse(e.dom);if(e.type==="json")return Ll.fromJSON(n,e.value);throw J0e(e)}const vCe=new wn("MILKDOWN_STATE_TRACKER");function yCe(e){const t=fv(j2e,pC,EA,xA);return e.Backspace=t,e}const SN=e=>(e.inject(M1,"").inject(vf,{}).inject(O1,t=>t).inject(Ky,[T1,ip,sp]).record(I1),async()=>{await e.waitTimers(Ky);const t=e.get(ds),n=e.get(Ic),o=e.get(qp),r=e.get(O1),s=e.get(ys),i=e.get(M1),l=gCe(i,n,t),a=[...s,new xn({key:vCe,state:{init:()=>{},apply:(d,f,p,h)=>{e.set(vf,h)}}}),J2e({rules:o}),NA(yCe(xwe))];e.set(ys,a);const u=r({schema:t,doc:l,plugins:a}),c=Da.create(u);return e.set(vf,c),e.done(I1),()=>{e.remove(M1).remove(vf).remove(O1).remove(Ky).clearTimer(I1)}});la(SN,{displayName:"EditorState"});const A1=na("EditorViewReady"),qy=jt([],"editorViewTimer"),lp=jt({},"editorViewOptions"),N1=jt(null,"root"),m2=jt(null,"rootDOM"),g2=jt({},"rootAttrs");function _Ce(e,t){const n=document.createElement("div");n.className="milkdown",e.appendChild(n),t.set(m2,n);const o=t.get(g2);return Object.entries(o).forEach(([r,s])=>n.setAttribute(r,s)),n}function bCe(e){e.classList.add("editor"),e.setAttribute("role","textbox")}const wCe=new wn("MILKDOWN_VIEW_CLEAR"),$N=e=>(e.inject(N1,document.body).inject(bn,{}).inject(lp,{}).inject(m2,null).inject(g2,{}).inject(qy,[I1]).record(A1),async()=>{await e.wait(Qa);const t=e.get(N1)||document.body,n=typeof t=="string"?document.querySelector(t):t;e.update(ys,a=>[new xn({key:wCe,view:u=>{const c=n?_Ce(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(qy);const o=e.get(vf),r=e.get(lp),s=Object.fromEntries(e.get(p2)),i=Object.fromEntries(e.get(h2)),l=new cCe(n,{state:o,nodeViews:s,markViews:i,...r});return bCe(l.dom),e.set(bn,l),e.done(A1),()=>{l==null||l.destroy(),e.remove(N1).remove(bn).remove(lp).remove(m2).remove(g2).remove(qy).clearTimer(A1)}});la($N,{displayName:"EditorView"});var nc,$r,al,yf,P1,L1,rr,ul,oc,R1,rc,_f,D1,$a,bf;const CCe=class EN{constructor(){Qn(this,nc,void 0),Qn(this,$r,void 0),Qn(this,al,void 0),Qn(this,yf,void 0),Qn(this,P1,void 0),Qn(this,L1,void 0),Qn(this,rr,void 0),Qn(this,ul,void 0),Qn(this,oc,void 0),Qn(this,R1,void 0),Qn(this,rc,void 0),Qn(this,_f,void 0),Qn(this,D1,void 0),Qn(this,$a,void 0),Qn(this,bf,void 0),_n(this,nc,!1),_n(this,$r,"Idle"),_n(this,al,[]),_n(this,yf,()=>{}),_n(this,P1,new iI),_n(this,L1,new dve),_n(this,rr,new Map),_n(this,ul,new Map),_n(this,oc,new cve(dt(this,P1),dt(this,L1))),_n(this,R1,()=>{const t=pCe(async o=>{await Promise.all(dt(this,al).map(r=>r(o)))}),n=[vN,wN,kN,_N,SN,$N,hCe(this),t];dt(this,rc).call(this,n,dt(this,ul))}),_n(this,rc,(t,n)=>{t.forEach(o=>{const r=dt(this,oc).produce(dt(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=dt(this,rr).get(o),s=r==null?void 0:r.cleanup;return n?dt(this,rr).delete(o):dt(this,rr).set(o,{ctx:void 0,handler:void 0,cleanup:void 0}),typeof s=="function"?s():s}))),_n(this,D1,async()=>{await Promise.all([...dt(this,ul).entries()].map(([t,{cleanup:n}])=>typeof n=="function"?n():n)),dt(this,ul).clear()}),_n(this,$a,t=>{_n(this,$r,t),dt(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=>(dt(this,al).push(t),this),this.removeConfig=t=>(_n(this,al,dt(this,al).filter(n=>n!==t)),this),this.use=t=>{const n=[t].flat();return n.flat().forEach(o=>{dt(this,rr).set(o,{ctx:void 0,handler:void 0,cleanup:void 0})}),dt(this,$r)==="Created"&&dt(this,rc).call(this,n,dt(this,rr)),this},this.remove=async t=>dt(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 dt(this,_f).call(this,[t].flat(),!0),this),this.create=async()=>dt(this,$r)==="OnCreate"?this:(dt(this,$r)==="Created"&&await this.destroy(),dt(this,$a).call(this,"OnCreate"),dt(this,R1).call(this),dt(this,rc).call(this,[...dt(this,rr).keys()],dt(this,rr)),await Promise.all([dt(this,bf).call(this,dt(this,ul)),dt(this,bf).call(this,dt(this,rr))].flat()),dt(this,$a).call(this,"Created"),this),this.destroy=async(t=!1)=>dt(this,$r)==="Destroyed"||dt(this,$r)==="OnDestroy"?this:dt(this,$r)==="OnCreate"?new Promise(n=>{setTimeout(()=>{n(this.destroy(t))},50)}):(t&&_n(this,al,[]),dt(this,$a).call(this,"OnDestroy"),await dt(this,_f).call(this,[...dt(this,rr).keys()],t),await dt(this,D1).call(this),dt(this,$a).call(this,"Destroyed"),this),this.action=t=>t(dt(this,oc)),this.inspect=()=>dt(this,nc)?[...dt(this,ul).values(),...dt(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 EN}get ctx(){return dt(this,oc)}get status(){return dt(this,$r)}};nc=new WeakMap,$r=new WeakMap,al=new WeakMap,yf=new WeakMap,P1=new WeakMap,L1=new WeakMap,rr=new WeakMap,ul=new WeakMap,oc=new WeakMap,R1=new WeakMap,rc=new WeakMap,_f=new WeakMap,D1=new WeakMap,$a=new WeakMap,bf=new WeakMap;let kCe=CCe,SCe=e=>crypto.getRandomValues(new Uint8Array(e)),$Ce=(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}}},ECe=(e,t=21)=>$Ce(e,t,SCe);ECe("abcedfghicklmn",10);function Ot(e,t){const n=mCe(e),o=r=>async()=>{o.key=n,await r.wait(sp);const s=t(r);return r.get(Vt).create(n,s),o.run=i=>r.get(Vt).call(e,i),()=>{r.get(Vt).remove(n)}};return o}function er(e){const t=n=>async()=>{await n.wait(Ks);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 xCe(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 sve(e);return r},n}function SC(e,t){const n=o=>async()=>{const r=t(o);return o.update(Mc,s=>[...s.filter(i=>i[0]!==e),[e,r]]),n.id=e,n.schema=r,()=>{o.update(Mc,s=>s.filter(([i])=>i!==e))}};return n.type=o=>{const r=o.get(ds).nodes[e];if(!r)throw rI(e);return r},n}function ao(e){let t;const n=o=>async()=>(await o.wait(Ks),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 TCe(e){const t=n=>async()=>{await n.wait(Ks);const o=e(n),r=NA(o);return n.update(ys,s=>[...s,r]),t.keymap=o,()=>{n.update(ys,s=>s.filter(i=>i!==r))}};return t}function An(e,t){const n=jt(e,t),o=r=>(r.inject(n),()=>()=>{r.remove(n)});return o.key=n,o}function Xn(e,t){const n=An(t,e),o=SC(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(Mc,u=>[...u.filter(c=>c[0]!==e),[e,a]]),r.schema=a},r}function Ah(e,t){const n=An(t,e),o=xCe(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=An(n,`${e}Keymap`),r=TCe(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 xs=(e,t=()=>({}))=>An(t,`${e}Attr`),Nh=(e,t=()=>({}))=>An(t,`${e}Attr`);function Id(e,t,n){const o=An(n??{},e),r=i=>async()=>{await i.wait(Qa);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 OCe(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(O1),l=n.get(ys),a=Da.create({schema:s,doc:r,plugins:l,...i});o.updateState(a)}}function gv(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}const ICe=[["ß","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"]],ACe=(e,t)=>{for(const[n,o]of t)e=e.replace(new RegExp(gv(n),"g"),o);return e};function NCe(e,t){if(typeof e!="string")throw new TypeError(`Expected a string, got \`${typeof e}\``);t={customReplacements:[],...t};const n=new Map([...ICe,...t.customReplacements]);return e=e.normalize(),e=ACe(e,n),e=e.normalize("NFD").replace(/\p{Diacritic}/gu,"").normalize(),e}const PCe=[["&"," and "],["🦄"," unicorn "],["♥"," love "]],LCe=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"),RCe=(e,t)=>{const n=gv(t);return e.replace(new RegExp(`${n}{2,}`,"g"),t).replace(new RegExp(`^${n}|${n}$`,"g"),"")},DCe=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+=gv(n)}return new RegExp(`[^${t}]+`,"g")};function VCe(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([...PCe,...t.customReplacements]);e=NCe(e,{customReplacements:r}),t.decamelize&&(e=LCe(e));const s=DCe(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=RCe(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 xN(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?BCe(t,n,e,s):zCe(t,n,s):!0:!1}}function BCe(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 mI(r.doc.resolve(o.$from.pos),r.doc.resolve(i),o.depth));const l=sv(o);if(l==null)return!1;r.lift(o,l);let a=r.mapping.map(s,-1)-1;return iv(r.doc,a)&&r.join(a),t(r.scrollIntoView()),!0}function zCe(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 jCe(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 HCe(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=M9(o.identifier);r&&!t.get(r)&&t.set(r,o)}),n;function n(o){const r=M9(o);return t.get(r)}}function M9(e){return String(e||"").toUpperCase()}function UCe(){return function(e){const t=HCe(e);Od(e,function(n,o,r){if(n.type==="definition"&&r!==void 0&&typeof o=="number")return r.children.splice(o,1),[Hb,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},[Hb,o]}})}}function TN(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 $C=Nh("emphasis");ke($C,{displayName:"Attr<emphasis>",group:"Emphasis"});const xu=Ah("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($C.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 vv=Ot("ToggleEmphasis",e=>()=>dv(xu.type(e)));ke(vv,{displayName:"Command<toggleEmphasisCommand>",group:"Emphasis"});const MN=er(e=>Th(/(?:^|[^*])\*([^*]+)\*$/,xu.type(e),{getAttr:()=>({marker:"*"}),updateCaptured:({fullMatch:t,start:n})=>t.startsWith("*")?{}:{fullMatch:t.slice(1),start:n+1}}));ke(MN,{displayName:"InputRule<emphasis>|Star",group:"Emphasis"});const ON=er(e=>Th(/(?:^|[^_])_([^_]+)_$/,xu.type(e),{getAttr:()=>({marker:"_"}),updateCaptured:({fullMatch:t,start:n})=>t.startsWith("_")?{}:{fullMatch:t.slice(1),start:n+1}}));ke(ON,{displayName:"InputRule<emphasis>|Underscore",group:"Emphasis"});const EC=tr("emphasisKeymap",{ToggleEmphasis:{shortcuts:"Mod-i",command:e=>{const t=e.get(Vt);return()=>t.call(vv.key)}}});ke(EC.ctx,{displayName:"KeymapCtx<emphasis>",group:"Emphasis"});ke(EC.shortcuts,{displayName:"Keymap<emphasis>",group:"Emphasis"});const xC=Nh("strong");ke(xC,{displayName:"Attr<strong>",group:"Strong"});const Ad=Ah("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(xC.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 yv=Ot("ToggleStrong",e=>()=>dv(Ad.type(e)));ke(yv,{displayName:"Command<toggleStrongCommand>",group:"Strong"});const IN=er(e=>Th(/(?:\*\*|__)([^*_]+)(?:\*\*|__)$/,Ad.type(e),{getAttr:t=>({marker:t[0].startsWith("*")?"*":"_"})}));ke(IN,{displayName:"InputRule<strong>",group:"Strong"});const TC=tr("strongKeymap",{ToggleBold:{shortcuts:["Mod-b"],command:e=>{const t=e.get(Vt);return()=>t.call(yv.key)}}});ke(TC.ctx,{displayName:"KeymapCtx<strong>",group:"Strong"});ke(TC.shortcuts,{displayName:"Keymap<strong>",group:"Strong"});const MC=Nh("inlineCode");ke(MC,{displayName:"Attr<inlineCode>",group:"InlineCode"});const $i=Ah("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 _v=Ot("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(_v,{displayName:"Command<toggleInlineCodeCommand>",group:"InlineCode"});const AN=er(e=>Th(/(?:\`)([^\`]+)(?:\`)$/,$i.type(e)));ke(AN,{displayName:"InputRule<inlineCodeInputRule>",group:"InlineCode"});const OC=tr("inlineCodeKeymap",{ToggleInlineCode:{shortcuts:"Mod-e",command:e=>{const t=e.get(Vt);return()=>t.call(_v.key)}}});ke(OC.ctx,{displayName:"KeymapCtx<inlineCode>",group:"InlineCode"});ke(OC.shortcuts,{displayName:"Keymap<inlineCode>",group:"InlineCode"});const IC=Nh("link");ke(IC,{displayName:"Attr<link>",group:"Link"});const fs=Ah("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(IC.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 NN=Ot("ToggleLink",e=>(t={})=>dv(fs.type(e),t));ke(NN,{displayName:"Command<toggleLinkCommand>",group:"Link"});const PN=Ot("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(PN,{displayName:"Command<updateLinkCommand>",group:"Link"});const LN=SC("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(LN,{displayName:"NodeSchema<doc>",group:"Doc"});const AC=xs("paragraph");ke(AC,{displayName:"Attr<paragraph>",group:"Paragraph"});const ji=Xn("paragraph",e=>({content:"inline*",group:"block",parseDOM:[{tag:"p"}],toDOM:t=>["p",e.get(AC.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"),TN(t,n),t.closeNode()}}}));ke(ji.node,{displayName:"NodeSchema<paragraph>",group:"Paragraph"});ke(ji.ctx,{displayName:"NodeSchemaCtx<paragraph>",group:"Paragraph"});const NC=Ot("TurnIntoText",e=>()=>jp(ji.type(e)));ke(NC,{displayName:"Command<turnIntoTextCommand>",group:"Paragraph"});const PC=tr("paragraphKeymap",{TurnIntoText:{shortcuts:"Mod-Alt-0",command:e=>{const t=e.get(Vt);return()=>t.call(NC.key)}}});ke(PC.ctx,{displayName:"KeymapCtx<paragraph>",group:"Paragraph"});ke(PC.shortcuts,{displayName:"Keymap<paragraph>",group:"Paragraph"});const WCe=Array(6).fill(0).map((e,t)=>t+1);function KCe(e){return VCe(e.textContent)}const bv=An(KCe,"headingIdGenerator");ke(bv,{displayName:"Ctx<HeadingIdGenerator>",group:"Heading"});const LC=xs("heading");ke(LC,{displayName:"Attr<heading>",group:"Heading"});const qs=Xn("heading",e=>{const t=e.get(bv.key);return{content:"inline*",group:"block",defining:!0,attrs:{id:{default:""},level:{default:1}},parseDOM:WCe.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(LC.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}),TN(n,o),n.closeNode()}}}});ke(qs.node,{displayName:"NodeSchema<heading>",group:"Heading"});ke(qs.ctx,{displayName:"NodeSchemaCtx<heading>",group:"Heading"});const RN=er(e=>bA(/^(?<hashes>#+)\s$/,qs.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(RN,{displayName:"InputRule<wrapInHeadingInputRule>",group:"Heading"});const bl=Ot("WrapInHeading",e=>t=>(t??(t=1),t<1?jp(ji.type(e)):jp(qs.type(e),{level:t})));ke(bl,{displayName:"Command<wrapInHeadingCommand>",group:"Heading"});const RC=Ot("DowngradeHeading",e=>()=>(t,n,o)=>{const{$from:r}=t.selection,s=r.node();if(s.type!==qs.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(RC,{displayName:"Command<downgradeHeadingCommand>",group:"Heading"});const DC=tr("headingKeymap",{TurnIntoH1:{shortcuts:"Mod-Alt-1",command:e=>{const t=e.get(Vt);return()=>t.call(bl.key,1)}},TurnIntoH2:{shortcuts:"Mod-Alt-2",command:e=>{const t=e.get(Vt);return()=>t.call(bl.key,2)}},TurnIntoH3:{shortcuts:"Mod-Alt-3",command:e=>{const t=e.get(Vt);return()=>t.call(bl.key,3)}},TurnIntoH4:{shortcuts:"Mod-Alt-4",command:e=>{const t=e.get(Vt);return()=>t.call(bl.key,4)}},TurnIntoH5:{shortcuts:"Mod-Alt-5",command:e=>{const t=e.get(Vt);return()=>t.call(bl.key,5)}},TurnIntoH6:{shortcuts:"Mod-Alt-6",command:e=>{const t=e.get(Vt);return()=>t.call(bl.key,6)}},DowngradeHeading:{shortcuts:["Delete","Backspace"],command:e=>{const t=e.get(Vt);return()=>t.call(RC.key)}}});ke(DC.ctx,{displayName:"KeymapCtx<heading>",group:"Heading"});ke(DC.shortcuts,{displayName:"Keymap<heading>",group:"Heading"});const VC=xs("blockquote");ke(VC,{displayName:"Attr<blockquote>",group:"Blockquote"});const Nd=Xn("blockquote",e=>({content:"block+",group:"block",defining:!0,parseDOM:[{tag:"blockquote"}],toDOM:t=>["blockquote",e.get(VC.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 DN=er(e=>cC(/^\s*>\s$/,Nd.type(e)));ke(DN,{displayName:"InputRule<wrapInBlockquoteInputRule>",group:"Blockquote"});const FC=Ot("WrapInBlockquote",e=>()=>mC(Nd.type(e)));ke(FC,{displayName:"Command<wrapInBlockquoteCommand>",group:"Blockquote"});const BC=tr("blockquoteKeymap",{WrapInBlockquote:{shortcuts:"Mod-Shift-b",command:e=>{const t=e.get(Vt);return()=>t.call(FC.key)}}});ke(BC.ctx,{displayName:"KeymapCtx<blockquote>",group:"Blockquote"});ke(BC.shortcuts,{displayName:"Keymap<blockquote>",group:"Blockquote"});const zC=xs("codeBlock",()=>({pre:{},code:{}}));ke(zC,{displayName:"Attr<codeBlock>",group:"CodeBlock"});const Pd=Xn("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(zC.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 VN=er(e=>bA(/^```(?<language>[a-z]*)?[\s\n]$/,Pd.type(e),t=>{var n;return{language:((n=t.groups)==null?void 0:n.language)??""}}));ke(VN,{displayName:"InputRule<createCodeBlockInputRule>",group:"CodeBlock"});const jC=Ot("CreateCodeBlock",e=>(t="")=>jp(Pd.type(e),{language:t}));ke(jC,{displayName:"Command<createCodeBlockCommand>",group:"CodeBlock"});const qCe=Ot("UpdateCodeBlockLanguage",()=>({pos:e,language:t}={pos:-1,language:""})=>(n,o)=>e>=0?(o==null||o(n.tr.setNodeAttribute(e,"language",t)),!0):!1);ke(qCe,{displayName:"Command<updateCodeBlockLanguageCommand>",group:"CodeBlock"});const HC=tr("codeBlockKeymap",{CreateCodeBlock:{shortcuts:"Mod-Alt-c",command:e=>{const t=e.get(Vt);return()=>t.call(jC.key)}}});ke(HC.ctx,{displayName:"KeymapCtx<codeBlock>",group:"CodeBlock"});ke(HC.shortcuts,{displayName:"Keymap<codeBlock>",group:"CodeBlock"});const UC=xs("image");ke(UC,{displayName:"Attr<image>",group:"Image"});const Ld=Xn("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(UC.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 FN=Ot("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(FN,{displayName:"Command<insertImageCommand>",group:"Image"});const BN=Ot("UpdateImage",e=>(t={})=>(n,o)=>{const r=uwe(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(BN,{displayName:"Command<updateImageCommand>",group:"Image"});const GCe=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(GCe,{displayName:"InputRule<insertImageInputRule>",group:"Image"});const o0=xs("hardbreak",e=>({"data-type":"hardbreak","data-is-inline":e.attrs.isInline}));ke(o0,{displayName:"Attr<hardbreak>",group:"Hardbreak"});const eu=Xn("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(o0.key)(t)," "]:["br",e.get(o0.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(eu.node,{displayName:"NodeSchema<hardbreak>",group:"Hardbreak"});ke(eu.ctx,{displayName:"NodeSchemaCtx<hardbreak>",group:"Hardbreak"});const WC=Ot("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(eu.type(e).create()).scrollIntoView()),!0});ke(WC,{displayName:"Command<insertHardbreakCommand>",group:"Hardbreak"});const KC=tr("hardbreakKeymap",{InsertHardbreak:{shortcuts:"Shift-Enter",command:e=>{const t=e.get(Vt);return()=>t.call(WC.key)}}});ke(KC.ctx,{displayName:"KeymapCtx<hardbreak>",group:"Hardbreak"});ke(KC.shortcuts,{displayName:"Keymap<hardbreak>",group:"Hardbreak"});const qC=xs("hr");ke(qC,{displayName:"Attr<hr>",group:"Hr"});const Ph=Xn("hr",e=>({group:"block",parseDOM:[{tag:"hr"}],toDOM:t=>["hr",e.get(qC.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(Ph.node,{displayName:"NodeSchema<hr>",group:"Hr"});ke(Ph.ctx,{displayName:"NodeSchemaCtx<hr>",group:"Hr"});const zN=er(e=>new Cr(/^(?:---|___\s|\*\*\*\s)$/,(t,n,o,r)=>{const{tr:s}=t;return n[0]&&s.replaceWith(o-1,r,Ph.type(e).create()),s}));ke(zN,{displayName:"InputRule<insertHrInputRule>",group:"Hr"});const jN=Ot("InsertHr",e=>()=>(t,n)=>{if(!n)return!0;const o=ji.node.type(e).create(),{tr:r,selection:s}=t,{from:i}=s,l=Ph.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(jN,{displayName:"Command<insertHrCommand>",group:"Hr"});const GC=xs("bulletList");ke(GC,{displayName:"Attr<bulletList>",group:"BulletList"});const Tu=Xn("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(GC.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(Tu.node,{displayName:"NodeSchema<bulletList>",group:"BulletList"});ke(Tu.ctx,{displayName:"NodeSchemaCtx<bulletList>",group:"BulletList"});const HN=er(e=>cC(/^\s*([-+*])\s$/,Tu.type(e)));ke(HN,{displayName:"InputRule<wrapInBulletListInputRule>",group:"BulletList"});const YC=Ot("WrapInBulletList",e=>()=>mC(Tu.type(e)));ke(YC,{displayName:"Command<wrapInBulletListCommand>",group:"BulletList"});const ZC=tr("bulletListKeymap",{WrapInBulletList:{shortcuts:"Mod-Alt-8",command:e=>{const t=e.get(Vt);return()=>t.call(YC.key)}}});ke(ZC.ctx,{displayName:"KeymapCtx<bulletListKeymap>",group:"BulletList"});ke(ZC.shortcuts,{displayName:"Keymap<bulletListKeymap>",group:"BulletList"});const JC=xs("orderedList");ke(JC,{displayName:"Attr<orderedList>",group:"OrderedList"});const Mu=Xn("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(JC.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(Mu.node,{displayName:"NodeSchema<orderedList>",group:"OrderedList"});ke(Mu.ctx,{displayName:"NodeSchemaCtx<orderedList>",group:"OrderedList"});const UN=er(e=>cC(/^\s*(\d+)\.\s$/,Mu.type(e),t=>({order:Number(t[1])}),(t,n)=>n.childCount+n.attrs.order===Number(t[1])));ke(UN,{displayName:"InputRule<wrapInOrderedListInputRule>",group:"OrderedList"});const XC=Ot("WrapInOrderedList",e=>()=>mC(Mu.type(e)));ke(XC,{displayName:"Command<wrapInOrderedListCommand>",group:"OrderedList"});const QC=tr("orderedListKeymap",{WrapInOrderedList:{shortcuts:"Mod-Alt-7",command:e=>{const t=e.get(Vt);return()=>t.call(XC.key)}}});ke(QC.ctx,{displayName:"KeymapCtx<orderedList>",group:"OrderedList"});ke(QC.shortcuts,{displayName:"Keymap<orderedList>",group:"OrderedList"});const ek=xs("listItem");ke(ek,{displayName:"Attr<listItem>",group:"ListItem"});const ti=Xn("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(ek.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(ti.node,{displayName:"NodeSchema<listItem>",group:"ListItem"});ke(ti.ctx,{displayName:"NodeSchemaCtx<listItem>",group:"ListItem"});const tk=Ot("SinkListItem",e=>()=>jCe(ti.type(e)));ke(tk,{displayName:"Command<sinkListItemCommand>",group:"ListItem"});const nk=Ot("LiftListItem",e=>()=>xN(ti.type(e)));ke(nk,{displayName:"Command<liftListItemCommand>",group:"ListItem"});const ok=Ot("SplitListItem",e=>()=>FCe(ti.type(e)));ke(ok,{displayName:"Command<splitListItemCommand>",group:"ListItem"});function YCe(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!==ti.type(e)||l.firstChild!==i.node()||i.node(-2).childCount>1?!1:xN(ti.type(e))(t,n,o)}}const rk=Ot("LiftFirstListItem",e=>()=>YCe(e));ke(rk,{displayName:"Command<liftFirstListItemCommand>",group:"ListItem"});const sk=tr("listItemKeymap",{NextListItem:{shortcuts:"Enter",command:e=>{const t=e.get(Vt);return()=>t.call(ok.key)}},SinkListItem:{shortcuts:["Tab","Mod-]"],command:e=>{const t=e.get(Vt);return()=>t.call(tk.key)}},LiftListItem:{shortcuts:["Shift-Tab","Mod-["],command:e=>{const t=e.get(Vt);return()=>t.call(nk.key)}},LiftFirstListItem:{shortcuts:["Backspace","Delete"],command:e=>{const t=e.get(Vt);return()=>t.call(rk.key)}}});ke(sk.ctx,{displayName:"KeymapCtx<listItem>",group:"ListItem"});ke(sk.shortcuts,{displayName:"Keymap<listItem>",group:"ListItem"});const WN=SC("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(WN,{displayName:"NodeSchema<text>",group:"Text"});const ik=xs("html");ke(ik,{displayName:"Attr<html>",group:"Html"});const lk=Xn("html",e=>({atom:!0,group:"inline",inline:!0,attrs:{value:{default:""}},toDOM:t=>{const n=document.createElement("span"),o={...e.get(ik.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(lk.node,{displayName:"NodeSchema<html>",group:"Html"});ke(lk.ctx,{displayName:"NodeSchemaCtx<html>",group:"Html"});const ZCe=[LN,AC,ji,bv,LC,qs,o0,eu,VC,Nd,zC,Pd,qC,Ph,UC,Ld,GC,Tu,JC,Mu,ek,ti,$C,xu,xC,Ad,MC,$i,IC,fs,ik,lk,WN].flat(),JCe=[DN,HN,UN,VN,zN,RN].flat(),XCe=[MN,ON,AN,IN],QCe=[NC,FC,bl,RC,jC,WC,jN,FN,BN,XC,YC,tk,ok,nk,rk,vv,_v,yv,NN,PN],eke=[BC,HC,KC,DC,sk,QC,ZC,PC,EC,OC,TC].flat(),ak=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(ak.plugin,{displayName:"Remark<remarkAddOrderInListPlugin>",group:"Remark"});ke(ak.options,{displayName:"RemarkConfig<remarkAddOrderInListPlugin>",group:"Remark"});const uk=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(uk.plugin,{displayName:"Remark<remarkLineBreak>",group:"Remark"});ke(uk.options,{displayName:"RemarkConfig<remarkLineBreak>",group:"Remark"});const ck=Id("remarkInlineLink",()=>UCe);ke(ck.plugin,{displayName:"Remark<remarkInlineLinkPlugin>",group:"Remark"});ke(ck.options,{displayName:"RemarkConfig<remarkInlineLinkPlugin>",group:"Remark"});const tke=e=>!!e.children,nke=e=>e.type==="html";function oke(e,t){return n(e,0,null)[0];function n(o,r,s){if(tke(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 dk=Id("remarkHTMLTransformer",()=>()=>e=>{oke(e,(t,n,o)=>nke(t)?((o==null?void 0:o.type)==="root"&&(t.children=[{...t}],delete t.value,t.type="paragraph"),[t]):[t])});ke(dk.plugin,{displayName:"Remark<remarkHtmlTransformer>",group:"Remark"});ke(dk.options,{displayName:"RemarkConfig<remarkHtmlTransformer>",group:"Remark"});const fk=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(fk.plugin,{displayName:"Remark<remarkMarker>",group:"Remark"});ke(fk.options,{displayName:"RemarkConfig<remarkMarker>",group:"Remark"});const KN=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=Un.widget(r,s,{side:-1}),l=document.createElement("span"),a=Un.widget(r,l);return setTimeout(()=>{s.contentEditable="true",l.contentEditable="true"}),an.create(o.doc,[i,a])}return an.empty}}});return n});ke(KN,{displayName:"Prose<inlineNodesCursorPlugin>",group:"Prose"});const qN=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 oo))return;const{from:i}=s;return o.tr.setNodeMarkup(i,eu.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===eu.type(e)&&(i=i.setNodeMarkup(c,eu.type(e),void 0,[]))}),i}}}));ke(qN,{displayName:"Prose<hardbreakClearMarkPlugin>",group:"Prose"});const pk=An(["table","code_block"],"hardbreakFilterNodes");ke(pk,{displayName:"Ctx<hardbreakFilterNodes>",group:"Prose"});const GN=ao(e=>{const t=e.get(pk.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(GN,{displayName:"Prose<hardbreakFilterPlugin>",group:"Prose"});const YN=ao(e=>{const t=new wn("MILKDOWN_HEADING_ID"),n=o=>{if(o.composing)return;const r=e.get(bv.key),s=o.state.tr.setMeta("addToHistory",!1);let i=!1;o.state.doc.descendants((l,a)=>{if(l.type===qs.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(YN,{displayName:"Prose<syncHeadingIdPlugin>",group:"Prose"});const ZN=ao(e=>{const t=n=>{if(n.composing||!n.editable)return;const o=Mu.type(e),r=Tu.type(e),s=ti.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(ZN,{displayName:"Prose<syncListOrderPlugin>",group:"Prose"});const rke=[qN,pk,GN,KN,ak,ck,uk,dk,fk,YN,ZN].flat(),ske=[ZCe,JCe,XCe,QCe,eke,rke].flat();var v2,y2;if(typeof WeakMap<"u"){let e=new WeakMap;v2=t=>e.get(t),y2=(t,n)=>(e.set(t,n),n)}else{const e=[];let n=0;v2=o=>{for(let r=0;r<e.length;r+=2)if(e[r]==o)return e[r+1]},y2=(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 v2(e)||y2(e,ike(e))}};function ike(e){if(e.type.spec.tableRole!="table")throw new RangeError("Not a table node: "+e.type.name);const t=lke(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 M=(S+x)%t*2,A=i[M];A==null||A!=E&&i[M+1]==1?(i[M]=E,i[M+1]=1):A==E&&i[M+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&&ake(l,i,e),l}function lke(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 ake(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=uke(a)))[u]=d)}l&&e.problems.unshift({type:"colwidth mismatch",pos:s,colwidth:l})}}function uke(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 cke(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 Lh(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 wv(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=Lh(t.$head)||dke(t.$head);if(n)return n;throw new RangeError(`No cell found around position ${t.head}`)}function dke(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 _2(e){return e.parent.type.spec.tableRole=="row"&&!!e.nodeAfter}function fke(e){return e.node(0).resolve(e.pos+e.nodeAfter.nodeSize)}function hk(e,t){return e.depth==t.depth&&e.pos>=t.start(-1)&&e.pos<=t.end(-1)}function JN(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 vu(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 pke(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 hke(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 Jg(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(_2(o)&&_2(r)&&hk(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=vu(v,0,m)),y>0&&(v=vu(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 mke(this.$anchorCell.pos,this.$headCell.pos)}};hn.prototype.visible=!1;bt.jsonID("cell",hn);var mke=class XN{constructor(t,n){this.anchor=t,this.head=n}map(t){return new XN(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&&hk(n,o)?new hn(n,o):bt.near(o,1)}};function gke(e){if(!(e.selection instanceof hn))return null;const t=[];return e.selection.forEachCell((n,o)=>{t.push(Un.node(o,o+n.nodeSize,{class:"selectedCell"}))}),an.create(e.doc,t)}function vke({$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 yke({$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 _ke(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&&vke(o)?s=ht.create(r,o.from):o instanceof ht&&yke(o)&&(s=ht.create(r,o.$from.start(),o.$from.end()));return s&&(t||(t=e.tr)).setSelection(s),t}var bke=new wn("fix-tables");function QN(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)?QN(e.child(l),a,n+1,o):a.nodesBetween(0,a.content.size,o,n+1),n+=a.nodeSize}}function wke(e,t){let n;const o=(r,s)=>{r.type.spec.tableRole=="table"&&(n=Cke(e,r,s,n))};return t?t.doc!=e.doc&&QN(t.doc,e.doc,0,o):e.doc.descendants(o),n}function Cke(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,vu(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(bke,{fixTables:!0})}function aa(e){const t=e.selection,n=wv(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 eP(e,{map:t,tableStart:n,table:o},r){let s=r>0?-1:0;hke(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,pke(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 kke(e,t){if(!Yr(e))return!1;if(t){const n=aa(e);t(eP(e.tr,n,n.left))}return!0}function Ske(e,t){if(!Yr(e))return!1;if(t){const n=aa(e);t(eP(e.tr,n,n.right))}return!0}function $ke(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,vu(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 Eke(e,t){if(!Yr(e))return!1;if(t){const n=aa(e),o=e.tr;if(n.left==0&&n.right==n.map.width)return!1;for(let r=n.right-1;$ke(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 xke(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 Tke(e,t){if(!Yr(e))return!1;if(t){const n=aa(e),o=e.tr;if(n.top==0&&n.bottom==n.map.height)return!1;for(let r=n.bottom-1;xke(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=wv(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 Oke(e){return function(t,n){if(!Yr(t))return!1;if(n){const o=Wr(t.schema),r=aa(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 mk(e,t){return t=t||{useDeprecatedLogic:!1},t.useDeprecatedLogic?Oke(e):function(n,o){if(!Yr(n))return!1;if(o){const r=Wr(n.schema),s=aa(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}}mk("row",{useDeprecatedLogic:!0});mk("column",{useDeprecatedLogic:!0});mk("cell",{useDeprecatedLogic:!0});function Ike(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 tP(e){return function(t,n){if(!Yr(t))return!1;const o=Ike(wv(t),e);if(o==null)return!1;if(n){const r=t.doc.resolve(o);n(t.tr.setSelection(ht.between(r,fke(r))).scrollIntoView())}return!0}}function Ake(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 xm(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 Nke(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=b2(Wr(i).row,new Ye(u,c,d)).content),l.push(u)}else if(s=="cell"||s=="header_cell")l.push(n||o?b2(Wr(i).row,new Ye(t,n,o)).content:t);else return null;return Pke(i,l)}function Pke(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 b2(e,t){const n=e.createAndFill();return new vA(n).replace(0,n.content.size,t).doc}function Lke({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(vu(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 Rke(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,vu(f.attrs,i-p,f.attrs.colspan-(i-p))),e.insert(h+f.nodeSize,f.type.createAndFill(vu(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}Rke(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 Dke=PA({ArrowLeft:Tm("horiz",-1),ArrowRight:Tm("horiz",1),ArrowUp:Tm("vert",-1),ArrowDown:Tm("vert",1),"Shift-ArrowLeft":Mm("horiz",-1),"Shift-ArrowRight":Mm("horiz",1),"Shift-ArrowUp":Mm("vert",-1),"Shift-ArrowDown":Mm("vert",1),Backspace:xm,"Mod-Backspace":xm,Delete:xm,"Mod-Delete":xm});function V1(e,t,n){return n.eq(e.selection)?!1:(t&&t(e.tr.setSelection(n).scrollIntoView()),!0)}function Tm(e,t){return(n,o,r)=>{if(!r)return!1;const s=n.selection;if(s instanceof hn)return V1(n,o,bt.near(s.$headCell,t));if(e!="horiz"&&!s.empty)return!1;const i=nP(r,e,t);if(i==null)return!1;if(e=="horiz")return V1(n,o,bt.near(n.doc.resolve(s.head+t),t));{const l=n.doc.resolve(i),a=JN(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),V1(n,o,u)}}}function Mm(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=nP(r,e,t);if(a==null)return!1;i=new hn(n.doc.resolve(a))}const l=JN(i.$headCell,e,t);return l?V1(n,o,new hn(i.$anchorCell,l)):!1}}function Vke(e,t){const n=e.state.doc,o=Lh(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=Nke(n);const r=e.state.selection;if(r instanceof hn){o||(o={width:1,height:1,rows:[Ue.from(b2(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=Lke(o,l.right-l.left,l.bottom-l.top),L9(e.state,e.dispatch,i,l,o),!0}else if(o){const s=wv(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 Bke(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=Lh(e.state.selection.$anchor))!=null&&((n=Gy(e,t))==null?void 0:n.pos)!=r.pos)s(r,t),t.preventDefault();else if(!o)return;function s(a,u){let c=Gy(e,u);const d=$l.getState(e.state)==null;if(!c||!hk(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=Gy(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 nP(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 Gy(e,t){const n=e.posAtCoords({left:t.clientX,top:t.clientY});return n&&n?Lh(e.state.doc.resolve(n.pos)):null}var zke=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")),w2(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,w2(e,this.colgroup,this.table,this.cellMinWidth),!0)}ignoreMutation(e){return e.type=="attributes"&&(e.target==this.table||this.colgroup.contains(e.target))}};function w2(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 jke({handleWidth:e=5,cellMinWidth:t=25,View:n=zke,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 Hke(-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)=>{Uke(s,i,e,t,o)},mouseleave:s=>{Wke(s)},mousedown:(s,i)=>{Kke(s,i,t)}},decorations:s=>{const i=Or.getState(s);if(i&&i.activeHandle>-1)return Xke(s,i.activeHandle)},nodeViews:{}}});return r}var Hke=class F1{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 F1(o.setHandle,!1);if(o&&o.setDragging!==void 0)return new F1(n.activeHandle,o.setDragging);if(n.activeHandle>-1&&t.docChanged){let r=t.mapping.map(n.activeHandle,-1);return _2(t.doc.resolve(r))||(r=-1),new F1(r,n.dragging)}return n}};function Uke(e,t,n,o,r){const s=Or.getState(e.state);if(s&&!s.dragging){const i=Gke(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}oP(e,l)}}}function Wke(e){const t=Or.getState(e.state);t&&t.activeHandle>-1&&!t.dragging&&oP(e,-1)}function Kke(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=qke(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&&(Yke(e,d.activeHandle,V9(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=V9(d.dragging,c,n);Zke(e,d.activeHandle,f,n)}}return r.addEventListener("mouseup",a),r.addEventListener("mousemove",u),t.preventDefault(),!0}function qke(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 Gke(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=Lh(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 V9(e,t,n){const o=t.clientX-e.startX;return Math.max(n,e.startWidth+o)}function oP(e,t){e.dispatch(e.state.tr.setMeta(Or,{setHandle:t}))}function Yke(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():Jke(f.colspan);h[p]=n,a.setNodeMarkup(i+d,null,{...f,colwidth:h})}a.docChanged&&e.dispatch(a)}function Zke(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&&w2(s,a.firstChild,a,o,l,n)}function Jke(e){return Array(e).fill(0)}function Xke(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(Un.widget(d,f))}}return an.create(e.doc,n)}function Qke({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:gke,handleDOMEvents:{mousedown:Bke},createSelectionBetween(t){return $l.getState(t.state)!=null?t.state.selection:null},handleTripleClick:Vke,handleKeyDown:Dke,handlePaste:Fke},appendTransaction(t,n,o){return _ke(o,wke(o,n),e)}})}var r0=typeof navigator<"u"?navigator:null,gk=r0&&r0.userAgent||"",e4e=/Edge\/(\d+)/.exec(gk),t4e=/MSIE \d/.exec(gk),n4e=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(gk),o4e=!!(t4e||n4e||e4e),r4e=!o4e&&!!r0&&/Apple Computer/.test(r0.vendor),rP=new wn("safari-ime-span"),C2=!1,s4e={key:rP,props:{decorations:i4e,handleDOMEvents:{compositionstart:()=>{C2=!0},compositionend:()=>{C2=!1}}}};function i4e(e){const{$from:t,$to:n,to:o}=e.selection;if(C2&&t.sameParent(n)){const r=Un.widget(o,l4e,{ignoreSelection:!0,key:"safari-ime-span"});return an.create(e.doc,[r])}}function l4e(e){const t=e.dom.ownerDocument.createElement("span");return t.className="ProseMirror-safari-ime-span",t}var a4e=new xn(r4e?s4e:{key:rP});function F9(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 u4e(e,t,n){const r=ov((n||{}).ignore||[]),s=c4e(t);let i=-1;for(;++i<s.length;)WI(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 c4e(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([d4e(r[0]),f4e(r[1])])}return t}function d4e(e){return typeof e=="string"?new RegExp(gv(e),"g"):e}function f4e(e){return typeof e=="function"?e:function(){return e}}const Yy="phrasing",Zy=["autolink","link","image","label"];function p4e(){return{transforms:[b4e],enter:{literalAutolink:m4e,literalAutolinkEmail:Jy,literalAutolinkHttp:Jy,literalAutolinkWww:Jy},exit:{literalAutolink:_4e,literalAutolinkEmail:y4e,literalAutolinkHttp:g4e,literalAutolinkWww:v4e}}}function h4e(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:Yy,notInConstruct:Zy},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:Yy,notInConstruct:Zy},{character:":",before:"[ps]",after:"\\/",inConstruct:Yy,notInConstruct:Zy}]}}function m4e(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function Jy(e){this.config.enter.autolinkProtocol.call(this,e)}function g4e(e){this.config.exit.autolinkProtocol.call(this,e)}function v4e(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 y4e(e){this.config.exit.autolinkEmail.call(this,e)}function _4e(e){this.exit(e)}function b4e(e){u4e(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,w4e],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),C4e]],{ignore:["link","linkReference"]})}function w4e(e,t,n,o,r){let s="";if(!sP(r)||(/^w/i.test(t)&&(n=t+n,t="",s="http://"),!k4e(n)))return!1;const i=S4e(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 C4e(e,t,n,o){return!sP(o,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function k4e(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 S4e(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=F9(e,"(");let s=F9(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 sP(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||hu(n)||tv(n))&&(!t||n!==47)}iP.peek=L4e;function $4e(){return{enter:{gfmFootnoteDefinition:x4e,gfmFootnoteDefinitionLabelString:T4e,gfmFootnoteCall:I4e,gfmFootnoteCallString:A4e},exit:{gfmFootnoteDefinition:O4e,gfmFootnoteDefinitionLabelString:M4e,gfmFootnoteCall:P4e,gfmFootnoteCallString:N4e}}}function E4e(){return{unsafe:[{character:"[",inConstruct:["phrasing","label","reference"]}],handlers:{footnoteDefinition:R4e,footnoteReference:iP}}}function x4e(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function T4e(){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 O4e(e){this.exit(e)}function I4e(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function A4e(){this.buffer()}function N4e(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 P4e(e){this.exit(e)}function iP(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 L4e(){return"["}function R4e(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()),D4e)),i(),s}function D4e(e,t,n){return t===0?e:(n?"":" ")+e}const V4e=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];lP.peek=H4e;function F4e(){return{canContainEols:["delete"],enter:{strikethrough:z4e},exit:{strikethrough:j4e}}}function B4e(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:V4e}],handlers:{delete:lP}}}function z4e(e){this.enter({type:"delete",children:[]},e)}function j4e(e){this.exit(e)}function lP(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 H4e(){return"~"}function U4e(e,t={}){const n=(t.align||[]).concat(),o=t.stringLength||K4e,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=W4e(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 W4e(e){return e==null?"":String(e)}function K4e(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 q4e(){return{enter:{table:G4e,tableData:z9,tableHeader:z9,tableRow:Z4e},exit:{codeText:J4e,table:Y4e,tableData:Xy,tableHeader:Xy,tableRow:Xy}}}function G4e(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 Y4e(e){this.exit(e),this.data.inTable=void 0}function Z4e(e){this.enter({type:"tableRow",children:[]},e)}function Xy(e){this.exit(e)}function z9(e){this.enter({type:"tableCell",children:[]},e)}function J4e(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,X4e));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function X4e(e,t){return t==="|"?t:e}function Q4e(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 U4e(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=rC.inlineCode(p,h,m);return m.stack.includes("tableCell")&&(y=y.replace(/\|/g,"\\$&")),y}}function e6e(){return{exit:{taskListCheckValueChecked:j9,taskListCheckValueUnchecked:j9,paragraph:n6e}}}function t6e(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:o6e}}}function j9(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function n6e(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 o6e(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=rC.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 r6e(){return[p4e(),$4e(),F4e(),q4e(),e6e()]}function s6e(e){return{extensions:[h4e(),E4e(),B4e(),Q4e(e),t6e()]}}const i6e={tokenize:f6e,partial:!0},aP={tokenize:p6e,partial:!0},uP={tokenize:h6e,partial:!0},cP={tokenize:m6e,partial:!0},l6e={tokenize:g6e,partial:!0},dP={name:"wwwAutolink",tokenize:c6e,previous:pP},fP={name:"protocolAutolink",tokenize:d6e,previous:hP},Hi={name:"emailAutolink",tokenize:u6e,previous:mP},li={};function a6e(){return{text:li}}let ma=48;for(;ma<123;)li[ma]=Hi,ma++,ma===58?ma=65:ma===91&&(ma=97);li[43]=Hi;li[45]=Hi;li[46]=Hi;li[95]=Hi;li[72]=[Hi,fP];li[104]=[Hi,fP];li[87]=[Hi,dP];li[119]=[Hi,dP];function u6e(e,t,n){const o=this;let r,s;return i;function i(d){return!k2(d)||!mP.call(o,o.previous)||vk(o.events)?n(d):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),l(d))}function l(d){return k2(d)?(e.consume(d),l):d===64?(e.consume(d),a):n(d)}function a(d){return d===46?e.check(l6e,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&&xo(o.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(d)):n(d)}}function c6e(e,t,n){const o=this;return r;function r(i){return i!==87&&i!==119||!pP.call(o,o.previous)||vk(o.events)?n(i):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(i6e,e.attempt(aP,e.attempt(uP,s),n),n)(i))}function s(i){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(i)}}function d6e(e,t,n){const o=this;let r="",s=!1;return i;function i(d){return(d===72||d===104)&&hP.call(o,o.previous)&&!vk(o.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),r+=String.fromCodePoint(d),e.consume(d),l):n(d)}function l(d){if(xo(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||Yg(d)||nn(d)||hu(d)||tv(d)?n(d):e.attempt(aP,e.attempt(uP,c),n)(d)}function c(d){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(d)}}function f6e(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 p6e(e,t,n){let o,r,s;return i;function i(u){return u===46||u===95?e.check(cP,a,l)(u):u===null||nn(u)||hu(u)||u!==45&&tv(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 h6e(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(cP,t,s)(i):i===null||nn(i)||hu(i)?t(i):(e.consume(i),r)}function s(i){return i===41&&o++,e.consume(i),r}}function m6e(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)||hu(l)?t(l):n(l)}function r(l){return l===null||l===40||l===91||nn(l)||hu(l)?t(l):o(l)}function s(l){return xo(l)?i(l):n(l)}function i(l){return l===59?(e.consume(l),o):xo(l)?(e.consume(l),i):n(l)}}function g6e(e,t,n){return o;function o(s){return e.consume(s),r}function r(s){return Wo(s)?n(s):t(s)}}function pP(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||nn(e)}function hP(e){return!xo(e)}function mP(e){return!(e===47||k2(e))}function k2(e){return e===43||e===45||e===46||e===95||Wo(e)}function vk(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 v6e={tokenize:$6e,partial:!0};function y6e(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:C6e,continuation:{tokenize:k6e},exit:S6e}},text:{91:{name:"gfmFootnoteCall",tokenize:w6e},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:_6e,resolveTo:b6e}}}}function _6e(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 b6e(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 w6e(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 C6e(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),Bt(e,p,"gfmFootnoteDefinitionWhitespace")):n(h)}function p(h){return t(h)}}function k6e(e,t,n){return e.check(Eh,t,e.attempt(v6e,t,n))}function S6e(e){e.exit("gfmFootnoteDefinition")}function $6e(e,t,n){const o=this;return Bt(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 E6e(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,nv(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=Zg(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=Zg(h);return y._open=!v||v===2&&!!m,y._close=!m||m===2&&!!v,l(h)}}}class x6e{constructor(){this.map=[]}add(t,n,o){T6e(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 T6e(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 O6e(){return{flow:{null:{name:"table",tokenize:I6e,resolveAll:A6e}}}}function I6e(e,t,n){const o=this;let r=0,s=0,i;return l;function l(N){let V=o.events.length-1;for(;V>-1;){const Z=o.events[V][1].type;if(Z==="lineEnding"||Z==="linePrefix")V--;else break}const B=V>-1?o.events[V][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):ft(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)?Bt(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)?Bt(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)?Bt(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||ft(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)?Bt(e,S,"whitespace")(N):S(N)}function S(N){return N===124?h(N):N===null||ft(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"),M(N)}function M(N){return N===124?(e.enter("tableCellDivider"),e.consume(N),e.exit("tableCellDivider"),M):N===null||ft(N)?(e.exit("tableRow"),t(N)):Nt(N)?Bt(e,M,"whitespace")(N):(e.enter("data"),A(N))}function A(N){return N===null||N===124||nn(N)?(e.exit("data"),M(N)):(e.consume(N),N===92?P:A)}function P(N){return N===92||N===124?(e.consume(N),A):A(N)}}function A6e(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 x6e;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=Om(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=Om(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=Om(f,t,s,r,n,d)):i[1]!==0&&(d=Om(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 Om(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 N6e={name:"tasklistCheck",tokenize:L6e};function P6e(){return{text:{91:N6e}}}function L6e(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 ft(a)?t(a):Nt(a)?e.check({tokenize:R6e},t,n)(a):n(a)}}function R6e(e,t,n){return Bt(e,o,"whitespace");function o(r){return r===null?n(r):t(r)}}function D6e(e){return xI([a6e(),y6e(),E6e(e),O6e(),P6e()])}const V6e={};function F6e(e){const t=this,n=e||V6e,o=t.data(),r=o.micromarkExtensions||(o.micromarkExtensions=[]),s=o.fromMarkdownExtensions||(o.fromMarkdownExtensions=[]),i=o.toMarkdownExtensions||(o.toMarkdownExtensions=[]);r.push(D6e(n)),s.push(r6e()),i.push(s6e(n))}function gt(e,t){return Object.assign(e,{meta:{package:"@milkdown/preset-gfm",...t}}),e}const yk=Nh("strike_through");gt(yk,{displayName:"Attr<strikethrough>",group:"Strikethrough"});const Rd=Ah("strike_through",e=>({parseDOM:[{tag:"del"},{style:"text-decoration",getAttrs:t=>t==="line-through"}],toDOM:t=>["del",e.get(yk.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 Cv=Ot("ToggleStrikeThrough",e=>()=>dv(Rd.type(e)));gt(Cv,{displayName:"Command<ToggleStrikethrough>",group:"Strikethrough"});const gP=er(e=>Th(/~([^~]+)~$/,Rd.type(e)));gt(gP,{displayName:"InputRule<strikethrough>",group:"Strikethrough"});const _k=tr("strikeThroughKeymap",{ToggleStrikethrough:{shortcuts:"Mod-Alt-x",command:e=>{const t=e.get(Vt);return()=>t.call(Cv.key)}}});gt(_k.ctx,{displayName:"KeymapCtx<strikethrough>",group:"Strikethrough"});gt(_k.shortcuts,{displayName:"Keymap<strikethrough>",group:"Strikethrough"});const Rh=cke({tableGroup:"block",cellContent:"paragraph",cellAttributes:{alignment:{default:"left",getFromDOM:e=>e.style.textAlign||"left",setDOMAttr:(e,t)=>{t.style=`text-align: ${e||"left"}`}}}}),Dd=Xn("table",()=>({...Rh.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 kv=Xn("table_header_row",()=>({...Rh.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(kv.node,{displayName:"NodeSchema<tableHeaderRow>",group:"Table"});gt(kv.ctx,{displayName:"NodeSchemaCtx<tableHeaderRow>",group:"Table"});const Dh=Xn("table_row",()=>({...Rh.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(Dh.node,{displayName:"NodeSchema<tableRow>",group:"Table"});gt(Dh.ctx,{displayName:"NodeSchemaCtx<tableRow>",group:"Table"});const Vh=Xn("table_cell",()=>({...Rh.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(Vh.node,{displayName:"NodeSchema<tableCell>",group:"Table"});gt(Vh.ctx,{displayName:"NodeSchemaCtx<tableCell>",group:"Table"});const Sv=Xn("table_header",()=>({...Rh.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(Sv.node,{displayName:"NodeSchema<tableHeader>",group:"Table"});gt(Sv.ctx,{displayName:"NodeSchemaCtx<tableHeader>",group:"Table"});function vP(e,t=3,n=3){const o=Array(n).fill(0).map(()=>Vh.type(e).createAndFill()),r=Array(n).fill(0).map(()=>Sv.type(e).createAndFill()),s=Array(t).fill(0).map((i,l)=>l===0?kv.type(e).create(null,r):Dh.type(e).create(null,o));return Dd.type(e).create(null,s)}function Fh(e){return fC(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 B6e(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 z6e(e){const t=B6e(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 cv(e.setSelection(new hn(r,n)))}}return e}function yP(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 Vh.type(e).createAndFill({alignment:c==null?void 0:c.attrs.alignment})});return t.insert(i,Dh.type(e).create(null,l)),t}function _P(e){return(t,n)=>o=>{n=n??o.selection.from;const r=o.doc.resolve(n),s=fC(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 cv(o.setSelection(d(c,p)))}}return o}}const j6e=_P("row"),H6e=_P("col");function U9(e){return e[0].map((t,n)=>e.map(o=>o[n]))}function bP(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 wP(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 CP(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 U6e(e,t,n,o){let r=U9(wP(e.node));return r=CP(r,t,n,o),r=U9(r),bP(e.node,r)}function W6e(e,t,n,o){let r=wP(e.node);return r=CP(r,t,n,o),bP(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 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}=W9(n,t),{indexes:u}=W9(o,t);if(a.includes(o))return t;const c=U6e(l,a,u,0),d=cv(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 q6e(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=W6e(l,a,u,0),d=cv(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 bk=Ot("GoToPrevTableCell",()=>()=>tP(-1));gt(bk,{displayName:"Command<goToPrevTableCellCommand>",group:"Table"});const wk=Ot("GoToNextTableCell",()=>()=>tP(1));gt(wk,{displayName:"Command<goToNextTableCellCommand>",group:"Table"});const Ck=Ot("ExitTable",e=>()=>(t,n)=>{if(!Yr(t))return!1;const{$head:o}=t.selection,r=iwe(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(Ck,{displayName:"Command<breakTableCommand>",group:"Table"});const kP=Ot("InsertTable",e=>({row:t,col:n}={})=>(o,r)=>{const{selection:s,tr:i}=o,{from:l}=s,a=vP(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(kP,{displayName:"Command<insertTableCommand>",group:"Table"});const SP=Ot("MoveRow",()=>({from:e,to:t,pos:n}={})=>(o,r)=>{const{tr:s}=o;return!!(r!=null&&r(q6e({tr:s,origin:e??0,target:t??0,pos:n,select:!0})))});gt(SP,{displayName:"Command<moveRowCommand>",group:"Table"});const $P=Ot("MoveCol",()=>({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($P,{displayName:"Command<moveColCommand>",group:"Table"});const EP=Ot("SelectRow",()=>(e={index:0})=>(t,n)=>{const{tr:o}=t;return!!(n!=null&&n(j6e(e.index,e.pos)(o)))});gt(EP,{displayName:"Command<selectRowCommand>",group:"Table"});const xP=Ot("SelectCol",()=>(e={index:0})=>(t,n)=>{const{tr:o}=t;return!!(n!=null&&n(H6e(e.index,e.pos)(o)))});gt(xP,{displayName:"Command<selectColCommand>",group:"Table"});const TP=Ot("SelectTable",()=>()=>(e,t)=>{const{tr:n}=e;return!!(t!=null&&t(z6e(n)))});gt(TP,{displayName:"Command<selectTableCommand>",group:"Table"});const MP=Ot("DeleteSelectedCells",()=>()=>(e,t)=>{const{selection:n}=e;if(!(n instanceof hn))return!1;const o=n.isRowSelection(),r=n.isColSelection();return o&&r?Ake(e,t):r?Eke(e,t):Tke(e,t)});gt(MP,{displayName:"Command<deleteSelectedCellsCommand>",group:"Table"});const OP=Ot("AddColBefore",()=>()=>kke);gt(OP,{displayName:"Command<addColBeforeCommand>",group:"Table"});const IP=Ot("AddColAfter",()=>()=>Ske);gt(IP,{displayName:"Command<addColAfterCommand>",group:"Table"});const AP=Ot("AddRowBefore",e=>()=>(t,n)=>{if(!Yr(t))return!1;if(n){const o=aa(t);n(yP(e,t.tr,o,o.top))}return!0});gt(AP,{displayName:"Command<addRowBeforeCommand>",group:"Table"});const NP=Ot("AddRowAfter",e=>()=>(t,n)=>{if(!Yr(t))return!1;if(n){const o=aa(t);n(yP(e,t.tr,o,o.bottom))}return!0});gt(NP,{displayName:"Command<addRowAfterCommand>",group:"Table"});const PP=Ot("SetAlign",()=>(e="left")=>Mke("alignment",e));gt(PP,{displayName:"Command<setAlignCommand>",group:"Table"});const LP=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=vP(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(LP,{displayName:"InputRule<insertTableInputRule>",group:"Table"});const kk=tr("tableKeymap",{NextCell:{shortcuts:["Mod-]","Tab"],command:e=>{const t=e.get(Vt);return()=>t.call(wk.key)}},PrevCell:{shortcuts:["Mod-[","Shift-Tab"],command:e=>{const t=e.get(Vt);return()=>t.call(bk.key)}},ExitTable:{shortcuts:["Mod-Enter"],command:e=>{const t=e.get(Vt);return()=>t.call(Ck.key)}}});gt(kk.ctx,{displayName:"KeymapCtx<table>",group:"Table"});gt(kk.shortcuts,{displayName:"Keymap<table>",group:"Table"});const Qy="footnote_definition",q9="footnoteDefinition",Sk=Xn("footnote_definition",()=>({group:"block",content:"block+",defining:!0,attrs:{label:{default:""}},parseDOM:[{tag:`dl[data-type="${Qy}"]`,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":Qy},["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===Qy,runner:(e,t)=>{e.openNode(q9,void 0,{label:t.attrs.label,identifier:t.attrs.label}).next(t.content).closeNode()}}}));gt(Sk.ctx,{displayName:"NodeSchemaCtx<footnodeDef>",group:"footnote"});gt(Sk.node,{displayName:"NodeSchema<footnodeDef>",group:"footnote"});const e_="footnote_reference",$k=Xn("footnote_reference",()=>({group:"inline",inline:!0,atom:!0,attrs:{label:{default:""}},parseDOM:[{tag:`sup[data-type="${e_}"]`,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":e_},t]},parseMarkdown:{match:({type:e})=>e==="footnoteReference",runner:(e,t,n)=>{e.addNode(n,{label:t.label})}},toMarkdown:{match:e=>e.type.name===e_,runner:(e,t)=>{e.addNode("footnoteReference",void 0,void 0,{label:t.attrs.label,identifier:t.attrs.label})}}}));gt($k.ctx,{displayName:"NodeSchemaCtx<footnodeRef>",group:"footnote"});gt($k.node,{displayName:"NodeSchema<footnodeRef>",group:"footnote"});const RP=ti.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(RP,{displayName:"NodeSchema<listItem>",group:"ListItem"});const DP=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(DP,{displayName:"InputRule<wrapInTaskListInputRule>",group:"ListItem"});const G6e=[_k,kk].flat(),Y6e=[LP,DP],Z6e=[gP],VP=ao(()=>a4e);gt(VP,{displayName:"Prose<autoInsertSpanPlugin>",group:"Prose"});const J6e=ao(()=>jke({}));gt(J6e,{displayName:"Prose<columnResizingPlugin>",group:"Prose"});const FP=ao(()=>Qke({allowTableNodeSelection:!0}));gt(FP,{displayName:"Prose<tableEditingPlugin>",group:"Prose"});const Ek=Id("remarkGFM",()=>F6e);gt(Ek.plugin,{displayName:"Remark<remarkGFMPlugin>",group:"Remark"});gt(Ek.options,{displayName:"RemarkConfig<remarkGFMPlugin>",group:"Remark"});const X6e=new wn("MILKDOWN_KEEP_TABLE_ALIGN_PLUGIN");function Q6e(e,t){let n=0;return t.forEach((o,r,s)=>{o===e&&(n=s)}),n}const BP=ao(()=>new xn({key:X6e,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=Q6e(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(BP,{displayName:"Prose<keepTableAlignPlugin>",group:"Prose"});const e5e=[BP,VP,Ek,FP].flat(),t5e=[RP,Dd,kv,Dh,Sv,Vh,Sk,$k,yk,Rd].flat(),n5e=[wk,bk,Ck,kP,SP,$P,EP,xP,TP,MP,AP,NP,OP,IP,PP,Cv],o5e=[t5e,Y6e,Z6e,G6e,n5e,e5e].flat();var s0=200,Yn=function(){};Yn.prototype.append=function(t){return t.length?(t=Yn.from(t),!this.length&&t||t.length<s0&&this.leafAppend(t)||this.length<s0&&t.leafPrepend(this)||this.appendInner(t)):this};Yn.prototype.prepend=function(t){return t.length?Yn.from(t).append(this):this};Yn.prototype.appendInner=function(t){return new r5e(this,t)};Yn.prototype.slice=function(t,n){return t===void 0&&(t=0),n===void 0&&(n=this.length),t>=n?Yn.empty:this.sliceInner(Math.max(0,t),Math.min(this.length,n))};Yn.prototype.get=function(t){if(!(t<0||t>=this.length))return this.getInner(t)};Yn.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)};Yn.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};Yn.from=function(t){return t instanceof Yn?t:t&&t.length?new zP(t):Yn.empty};var zP=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<=s0)return new t(this.values.concat(r.flatten()))},t.prototype.leafPrepend=function(r){if(this.length+r.length<=s0)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}(Yn);Yn.empty=new zP([]);var r5e=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}(Yn);const s5e=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 Vs(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 Vs(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 Vs(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>l5e&&(l=i5e(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 Vs(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 Vs(h,m,y))}else o.push(new Vs(h))},r);let u=[];for(let f=n;f<i;f++)u.push(new Vs(s.maps[f]));let c=this.items.slice(0,r).append(u).append(o),d=new is(c,l);return d.emptyItemCount()>s5e&&(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 Vs(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(Yn.from(r.reverse()),s)}}is.empty=new is(Yn.empty,0);function i5e(e,t){let n;return e.forEach((o,r)=>{if(o.selection&&t--==0)return n=r,!1}),e.slice(n)}class Vs{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 Vs(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 l5e=20;function a5e(e,t,n,o){let r=n.getMeta(tu),s;if(r)return r.historyState;n.getMeta(d5e)&&(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(tu))return i.getMeta(tu).redo?new wl(e.done.addTransform(n,void 0,o,B1(t)),e.undone,G9(n.mapping.maps),e.prevTime,e.prevComposition):new wl(e.done,e.undone.addTransform(n,void 0,o,B1(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||!u5e(n,e.prevRanges)),u=i?t_(e.prevRanges,n.mapping):G9(n.mapping.maps);return new wl(e.done.addTransform(n,a?t.selection.getBookmark():void 0,o,B1(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),t_(e.prevRanges,n.mapping),e.prevTime,e.prevComposition):new wl(e.done.addMaps(n.mapping.maps),e.undone.addMaps(n.mapping.maps),t_(e.prevRanges,n.mapping),e.prevTime,e.prevComposition)}function u5e(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 t_(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 c5e(e,t,n){let o=B1(t),r=tu.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(tu,{redo:n,historyState:a})}let n_=!1,Y9=null;function B1(e){let t=e.plugins;if(Y9!=t){n_=!1,Y9=t;for(let n=0;n<t.length;n++)if(t[n].spec.historyPreserveItems){n_=!0;break}}return n_}const tu=new wn("history"),d5e=new wn("closeHistory");function f5e(e={}){return e={depth:e.depth||100,newGroupDelay:e.newGroupDelay||500},new xn({key:tu,state:{init(){return new wl(is.empty,is.empty,null,0,-1)},apply(t,n,o){return a5e(n,o,t,e)}},config:e,props:{handleDOMEvents:{beforeinput(t,n){let o=n.inputType,r=o=="historyUndo"?HP:o=="historyRedo"?UP:null;return r?(n.preventDefault(),r(t.state,t.dispatch)):!1}}}})}function jP(e,t){return(n,o)=>{let r=tu.getState(n);if(!r||(e?r.undone:r.done).eventCount==0)return!1;if(o){let s=c5e(r,n,e);s&&o(t?s.scrollIntoView():s)}return!0}}const HP=jP(!1,!0),UP=jP(!0,!0);function Vd(e,t){return Object.assign(e,{meta:{package:"@milkdown/plugin-history",...t}}),e}const xk=Ot("Undo",()=>()=>HP);Vd(xk,{displayName:"Command<undo>"});const Tk=Ot("Redo",()=>()=>UP);Vd(Tk,{displayName:"Command<redo>"});const Mk=An({},"historyProviderConfig");Vd(Mk,{displayName:"Ctx<historyProviderConfig>"});const WP=ao(e=>f5e(e.get(Mk.key)));Vd(WP,{displayName:"Ctx<historyProviderPlugin>"});const Ok=tr("historyKeymap",{Undo:{shortcuts:"Mod-z",command:e=>{const t=e.get(Vt);return()=>t.call(xk.key)}},Redo:{shortcuts:["Mod-y","Shift-Mod-z"],command:e=>{const t=e.get(Vt);return()=>t.call(Tk.key)}}});Vd(Ok.ctx,{displayName:"KeymapCtx<history>"});Vd(Ok.shortcuts,{displayName:"Keymap<history>"});const p5e=[Mk,WP,Ok,xk,Tk].flat();function S2(e){if(!e)return!1;if(Array.isArray(e))return e.length>1?!1:S2(e[0]);const t=e.content;return t?S2(t):e.type==="text"}function h5e(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 KP=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=lwe("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=pu.fromSchema(t);let h;if(f.length===0){const v=l(c);if(!v||typeof v=="string")return!1;h=oa.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=h5e(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(S2(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):""}}})});KP.meta={displayName:"Prose<clipboard>",package:"@milkdown/plugin-clipboard"};const Ik=An({shouldAppend:e=>!(!e||["heading","paragraph"].includes(e.type.name)),getNode:e=>e.schema.nodes.paragraph.create()},"trailingConfig");Ik.meta={package:"@milkdown/plugin-trailing",displayName:"Ctx<trailingConfig>"};const qP=ao(e=>{const t=new wn("MILKDOWN_TRAILING"),{shouldAppend:n,getNode:o}=e.get(Ik.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});qP.meta={package:"@milkdown/plugin-trailing",displayName:"Prose<trailing>"};const m5e=[Ik,qP];var GP=(e=>(e.CodeMirror="code-mirror",e.LinkTooltip="link-tooltip",e.Cursor="cursor",e.BlockEdit="block-edit",e.Toolbar="toolbar",e.Placeholder="placeholder",e))(GP||{});const g5e={cursor:!0,"link-tooltip":!0,"block-edit":!0,placeholder:!0,toolbar:!0,"code-mirror":!0};async function v5e(e,t,n){switch(e){case"link-tooltip":{const{defineFeature:o}=await Yd(()=>Promise.resolve().then(()=>iVe),void 0);return o(t,n)}case"block-edit":{const{defineFeature:o}=await Yd(()=>Promise.resolve().then(()=>UVe),void 0);return o(t,n)}case"placeholder":{const{defineFeature:o}=await Yd(()=>Promise.resolve().then(()=>GVe),void 0);return o(t,n)}case"toolbar":{const{defineFeature:o}=await Yd(()=>Promise.resolve().then(()=>JVe),void 0);return o(t,n)}}}const y5e=jt([],"FeaturesCtx");function _5e(e){return t=>{t.inject(y5e,e)}}var b5e="Expected a function",Z9=0/0,w5e="[object Symbol]",C5e=/^\s+|\s+$/g,k5e=/^[-+]0x[0-9a-f]+$/i,S5e=/^0b[01]+$/i,$5e=/^0o[0-7]+$/i,E5e=parseInt,x5e=typeof On=="object"&&On&&On.Object===Object&&On,T5e=typeof self=="object"&&self&&self.Object===Object&&self,M5e=x5e||T5e||Function("return this")(),O5e=Object.prototype,I5e=O5e.toString,A5e=Math.max,N5e=Math.min,o_=function(){return M5e.Date.now()};function P5e(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(b5e);t=J9(t)||0,$2(n)&&(c=!!n.leading,d="maxWait"in n,s=d?A5e(J9(n.maxWait)||0,t):s,f="trailing"in n?!!n.trailing:f);function p(E){var M=o,A=r;return o=r=void 0,u=E,i=e.apply(A,M),i}function h(E){return u=E,l=setTimeout(v,t),c?p(E):i}function m(E){var M=E-a,A=E-u,P=t-M;return d?N5e(P,s-A):P}function y(E){var M=E-a,A=E-u;return a===void 0||M>=t||M<0||d&&A>=s}function v(){var E=o_();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(o_())}function x(){var E=o_(),M=y(E);if(o=arguments,r=this,a=E,M){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 $2(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function L5e(e){return!!e&&typeof e=="object"}function R5e(e){return typeof e=="symbol"||L5e(e)&&I5e.call(e)==w5e}function J9(e){if(typeof e=="number")return e;if(R5e(e))return Z9;if($2(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=$2(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace(C5e,"");var n=S5e.test(e);return n||$5e.test(e)?E5e(e.slice(2),n?2:8):k5e.test(e)?Z9:+e}var D5e=P5e;const $v=_o(D5e);let YP=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 E2=jt(new YP,"listener"),V5e=new wn("MILKDOWN_LISTENER"),ZP=e=>(e.inject(E2,new YP),async()=>{await e.wait(Qa);const t=e.get(E2),{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:V5e,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:$v(()=>{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(A1),n.mounted.forEach(l=>l(e))});ZP.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 B5e=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 rI("image");return(await Promise.all(n.map(r=>F5e(r)))).map(({alt:r,src:s})=>o.createAndFill({src:s,alt:r}))},Nc=An({uploader:B5e,enableHtmlFileUploader:!1,uploadWidgetFactory:(e,t)=>{const n=document.createElement("span");return n.textContent="Upload in progress...",Un.widget(e,n,t)}},"uploadConfig");Nc.meta={package:"@milkdown/plugin-upload",displayName:"Ctx<uploadConfig>"};const JP=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}}})});JP.meta={package:"@milkdown/plugin-upload",displayName:"Prose<upload>"};const z5e=[Nc,JP];var XP=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},Os=(e,t,n)=>(XP(e,t,"read from private field"),n?n.call(e):t.get(e)),Im=(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)},Am=(e,t,n,o)=>(XP(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),gi,wf,z1,j1;class QP{constructor({root:t,features:n={},featureConfigs:o={},defaultValue:r="",onUpdate:s=l=>{},handleCommonActions:i=(l,a)=>{}}){Im(this,gi,void 0),Im(this,wf,void 0),Im(this,z1,void 0),Im(this,j1,!0);const l=Object.entries({...g5e,...n}).filter(([,u])=>u).map(([u])=>u);Am(this,z1,(typeof t=="string"?document.querySelector(t):t)??document.body),Am(this,gi,kCe.make().config(_5e(l)).config(u=>{u.set(N1,Os(this,z1)),u.set(M1,r),u.set(lp,{editable:()=>Os(this,j1)})}).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(E2);c.markdownUpdated((d,f,p)=>{f!==p&&s(f)}),c.updated((d,f,p)=>{i("editor_updated",d)})}).use(ske).use(p5e).use(m5e).use(KP).use(ZP).use(z5e).use(o5e));const a=[];l.forEach(u=>{const c=o[u];a.push(v5e(u,Os(this,gi),c))}),Am(this,wf,Promise.all(a))}async create(){return await Os(this,wf),Os(this,gi).create()}async destroy(){return await Os(this,wf),Os(this,gi).destroy()}get editor(){return Os(this,gi)}setReadonly(t){return Am(this,j1,!t),this}getMarkdown(){return Os(this,gi).action(MCe())}getEditor(){return Os(this,gi)}destroyEditor(){this.destroy()}}gi=new WeakMap;wf=new WeakMap;z1=new WeakMap;j1=new WeakMap;QP.Feature=GP;const j5e=Symbol("editorInfoCtxKey"),H5e=Q({name:"MilkdownProvider",setup:(e,{slots:t})=>{const n=q(null),o=q(void 0),r=q(void 0),s=q(!0);return wt(j5e,{loading:s,dom:n,editor:r,editorFactory:o}),()=>{var i;return k(fe,null,[(i=t.default)==null?void 0:i.call(t)])}}});var U5e=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},eL=(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)},x2=(e,t,n)=>(U5e(e,t,"access private method"),n),H1,T2;let W5e=class{constructor({node:t,view:n,getPos:o,decorations:r,innerDecorations:s,options:i}){eL(this,H1),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 x2(this,H1,T2).call(this,t)}createContentDOM(t){return x2(this,H1,T2).call(this,t)}get component(){return this.options.component}};H1=new WeakSet,T2=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 K5e=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,tL;let q5e=class{constructor({pos:t,spec:n,options:o}){eL(this,M2),this.pos=t,this.options=o,this.spec=n,this.dom=x2(this,M2,tL).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,tL=function(e){return e instanceof HTMLElement?e:document.createElement(e)};let Ak=(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 G5e=Object.defineProperty,Y5e=(e,t,n)=>t in e?G5e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Nr=(e,t,n)=>(Y5e(e,typeof t!="symbol"?t+"":t,n),n);const Z5e=Symbol("[ProsemirrorAdapter]nodeViewContext"),J5e=Symbol("[ProsemirrorAdapter]useNodeViewFactory");let X5e=class extends W5e{constructor(){super(...arguments),Nr(this,"key",Ak()),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:Mn(this.node),selected:Mn(this.selected),decorations:Mn(this.decorations),innerDecorations:Mn(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(Z5e,this.context),()=>k(_s,{key:this.key,to:this.dom},{default:()=>[k(t,null,null)]}))}))})}};const Q5e=(e,t)=>n=>(o,r,s,i,l)=>{const a=new X5e({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},e8e=Symbol("[ProsemirrorAdapter]nodeViewContext"),t8e=Symbol("[ProsemirrorAdapter]usePluginViewFactory");let n8e=class extends K5e{constructor(){super(...arguments),Nr(this,"key",Ak()),Nr(this,"context",{view:Mn(this.view),prevState:Mn(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(e8e,this.context),()=>k(_s,{key:this.key,to:this.root},{default:()=>[k(t,null,null)]}))}))})}};const o8e=(e,t)=>n=>o=>{const r=new n8e({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},r8e=()=>{const e=q({}),t=at(),n=Ii({});return yd(()=>{n.updater=()=>{t==null||t.update()}}),oi(()=>{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]}}},s8e=Symbol("[ProsemirrorAdapter]widgetViewContext"),i8e=Symbol("[ProsemirrorAdapter]useWidgetViewFactory");class l8e extends q5e{constructor(){super(...arguments),Nr(this,"key",Ak()),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(s8e,this.context),()=>k(_s,{key:this.key,to:this.dom},{default:()=>[k(t,null,null)]}))}))})}}const a8e=(e,t)=>n=>(o,r={})=>{const s=new l8e({pos:o,options:n}),i={...r,destroy:l=>{var a;(a=r.destroy)==null||a.call(r,l),t(s)}};return s.spec=i,Un.widget(o,(l,a)=>(s.bind(l,a),s.updateContext(),e(s),s.dom),i)},u8e=Q({name:"ProsemirrorAdapterProvider",setup:(e,{slots:t})=>{const{portals:n,renderVueRenderer:o,removeVueRenderer:r}=r8e(),s=Q5e(o,r),i=o8e(o,r),l=a8e(o,r);return wt(J5e,s),wt(t8e,i),wt(i8e,l),()=>{var a;return k(fe,null,[(a=t.default)==null?void 0:a.call(t),Object.values(n.value).map(u=>lt(u))])}}}),c8e={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:H5e,ProsemirrorAdapterProvider:u8e},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 QP({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;if(l=="everyone"&&this.isAdmin()){this.mentionResults=[{username:"everyone",display_name:this.$t("Tag Everyone")}],this.showMentionPop=!0;return}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(OCe(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()}},d8e={style:{position:"relative"},class:"fcom_md_editor"},f8e={ref:"crepe_editor_vue",class:"crepe-editor feed_md_content fcom_md_seditor_wrapper"},p8e={class:"fcom_mention_pop_wrap"},h8e=b("span",{style:{}},null,-1),m8e={key:0},g8e={key:0},v8e=["onClick"],y8e=["src"],_8e={key:1},b8e={key:0};function w8e(e,t,n,o,r,s){const i=oe("ProsemirrorAdapterProvider"),l=oe("MilkdownProvider"),a=bo;return C(),T(fe,null,[k(l,null,{default:$(()=>[k(i,null,{default:$(()=>[b("div",d8e,[b("div",f8e,null,512)])]),_:1})]),_:1}),b("div",p8e,[k(a,{"popper-class":"fcom_mention_pop",ref:"mentionPopoverRef",placement:"bottom",visible:r.showMentionPop,width:300,persistent:!1},{reference:$(()=>[h8e]),default:$(()=>[r.justReplaced?j("",!0):(C(),T("div",m8e,[r.mentionResults.length?(C(),T("ul",g8e,[(C(!0),T(fe,null,nt(r.mentionResults,u=>(C(),T("li",{key:u.user_id,onClick:c=>s.addMention("@"+u.username)},[u.avatar?(C(),T("img",{key:0,alt:"",src:u.avatar},null,8,y8e)):j("",!0),b("span",null,O(u.display_name)+" (@"+O(u.username)+")",1)],8,v8e))),128))])):r.searchingMention?j("",!0):(C(),T("div",_8e,[b("p",null,[ne(O(e.$t("No results found. Please search by username"))+" ",1),e.isAdmin()&&n.hasEveyoneMention?(C(),T("span",b8e,O(e.$t("You can use @everyone to tag everyone.")),1)):j("",!0)])]))]))]),_:1},8,["visible"])])],64)}const nL=We(c8e,[["render",w8e]]),C8e={name:"EmailNotification",components:{CrepeEditor:nL,Layout:$s,AppLayout:Es},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"))}},k8e={style:{"margin-bottom":"20px"},class:"settings_router"},S8e={key:0,class:"white_loaded"},$8e={key:1,class:"fhr_content_layout_body"},E8e={class:"setting_body"},x8e={style:{"font-size":"18px",margin:"0",padding:"0"}},T8e={style:{margin:"5px 0","font-size":"90%","line-height":"120%"}},M8e=b("hr",null,null,-1),O8e={class:"fcom_help_text"},I8e={class:"fcom_help_text"},A8e={class:"fcom_help_text"},N8e={class:"fcom_help_text"},P8e={class:"fcom_extra_editor"},L8e={class:"fcom_help_text"},R8e=["innerHTML"],D8e=b("hr",null,null,-1),V8e={class:"setting_body"},F8e={style:{"font-size":"18px",margin:"0",padding:"0"}},B8e={style:{margin:"5px 0","font-size":"90%","line-height":"120%"}},z8e=b("hr",null,null,-1),j8e={key:0,class:"fcom_help_text"},H8e={key:0,class:"fcom_help_text"},U8e={key:0,class:"fcom_help_text"},W8e={class:"fcom_help_text"},K8e={key:0,class:"fcom_help_text"},q8e={class:"fcom_meta_text"},G8e=b("hr",null,null,-1),Y8e={class:"setting_body"},Z8e={key:2};function J8e(e,t,n,o,r,s){const i=ct,l=Jn,a=Tt,u=Bn,c=yh,d=vh,f=oe("crepe-editor"),p=In,h=Ss,m=vr,y=PO,v=Fn,w=oe("layout"),_=oe("app-layout"),S=Dt("loading");return C(),K(_,{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:$(()=>[Fe((C(),K(i,{class:"fcom_primary_button",onClick:s.save},{default:$(()=>[b("span",null,O(e.$t("Save Settings")),1)]),_:1},8,["onClick"])),[[S,r.saving]])]),default:$(()=>[b("div",k8e,[r.loading?(C(),T("div",S8e,[k(l,{rows:5,animated:!0})])):r.email_settings?(C(),T("div",$8e,[k(v,{onSubmit:t[12]||(t[12]=Je(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",E8e,[b("h3",x8e,O(e.$t("Mailing Settings")),1),b("p",T8e,O(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",O8e,[b("p",null,O(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",I8e,[b("p",null,O(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",A8e,[b("p",null,O(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",N8e,[b("p",null,O(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",P8e,[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",L8e,[b("p",null,O(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,R8e)])]),_:1},8,["label"]),e.has_pro?(C(),K(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(O(e.$t("Disable powered by FluentCommunity in the email footer")),1)]),_:1},8,["modelValue"])]),_:1})):j("",!0)]),D8e,b("div",V8e,[b("h3",F8e,O(e.$t("Email Notification Settings")),1),b("p",B8e,O(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),z8e,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(O(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(),T("div",j8e,[b("p",null,O(e.$t("You should enable this. Currently disabled.")),1)])):j("",!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(O(e.$t("Email authors when someone reply to their comments")),1)]),_:1},8,["modelValue"]),r.email_settings.reply_my_com_mail!="yes"?(C(),T("div",H8e,[b("p",null,O(e.$t("You should enable this. Currently disabled.")),1)])):j("",!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(O(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(),T("div",U8e,[b("p",null,O(e.$t("You should enable this. Currently disabled.")),1)])):j("",!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(O(e.$t("Enable Weekly Digest Email for community members")),1)]),_:1},8,["modelValue"]),b("div",W8e,[b("p",null,O(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(),T("div",K8e,[b("p",null,O(e.$t("Email will be sent if there has any unread notifications for the user from the last email sent")),1)])):j("",!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",q8e,O(e.$t("Approximate time when the digest emails will start sending for the members")),1)]),_:1},8,["label"])]),_:1})]),_:1})]),G8e,b("div",Y8e,[Fe((C(),K(i,{onClick:s.save,disabled:r.saving,class:"fcom_primary_button"},{default:$(()=>[ne(O(e.$t("Save Settings")),1)]),_:1},8,["onClick","disabled"])),[[S,r.saving]])])]),_:1},8,["modelValue"])])):(C(),T("div",Z8e,[b("p",null,O(e.$t("Settings could not be loaded")),1)]))])]),_:1},8,["title"])]),_:1})}const X8e=We(C8e,[["render",J8e]]),Q8e={name:"CustomizationSettings",components:{Layout:$s,AppLayout:Es},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"))}},eSe={class:"settings_router"},tSe={key:0,class:"white_loaded"},nSe={key:1,class:"fhr_content_layout_body"},oSe={class:"setting_body"},rSe={class:"fcom_input_wrap"},sSe={class:"fcom_input_wrap"},iSe={class:"fcom_input_wrap"},lSe={key:0,class:"fcom_input_wrap"},aSe=["innerHTML"],uSe={key:1,style:{cursor:"pointer","font-weight":"bold"}},cSe={class:"fcom_input_wrap"},dSe={style:{"font-weight":"bold"}},fSe={class:"fcom_help_text"},pSe={target:"_blank",rel:"noopener",href:"https://wpmanageninja.com/affiliate/"},hSe={class:"fcom_input_wrap"},mSe={class:"fcom_input_wrap"},gSe={class:"fcom_input_wrap"},vSe={key:0},ySe={class:"fcom_help_text"},_Se={class:"fcom_input_wrap"},bSe={class:"fcom_help_text"},wSe={style:{"margin-top":"50px"},class:"fcom_input_wrap"},CSe={key:2};function kSe(e,t,n,o,r,s){const i=ct,l=Jn,a=sO,u=In,c=Tt,d=bo,f=mh,p=ea,h=Bn,m=Fn,y=oe("layout"),v=oe("app-layout"),w=Dt("loading");return C(),K(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:$(()=>[Fe((C(),K(i,{class:"fcom_primary_button",onClick:s.save},{default:$(()=>[b("span",null,O(e.$t("Save Settings")),1)]),_:1},8,["onClick"])),[[w,r.saving]])]),default:$(()=>[b("div",eSe,[r.loading?(C(),T("div",tSe,[k(l,{rows:5,animated:!0})])):r.settings?(C(),T("div",nSe,[b("div",oSe,[b("p",null,O(e.$t("Customize the UI features of the portal.")),1),k(a),k(m,{onSubmit:t[10]||(t[10]=Je(_=>e.doNothing(),["prevent"])),modelValue:r.settings,"onUpdate:modelValue":t[11]||(t[11]=_=>r.settings=_),"label-position":"top"},{default:$(()=>[b("div",rSe,[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(O(e.$t("Enable Dark Mode")),1)]),_:1},8,["modelValue"]),b("p",null,O(e.$t("Enables switching between dark and light interface themes, accommodating different lighting conditions and user preferences.")),1)]),b("div",sSe,[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(O(e.$t("Enable Sticky Page headers across portal")),1)]),_:1},8,["modelValue"]),b("p",null,O(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",iSe,[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(O(e.$t("Show Default Feed link on left sidebar")),1)]),_:1},8,["modelValue"]),b("p",null,O(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(),T("div",lSe,[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(O(e.$t("Show powered by text")),1)]),_:1},8,["modelValue"]),b("p",null,[ne(O(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(),T("span",uSe,O(e.$t("Affiliate ID: %s",r.settings.affiliate_id)),1)):(C(),T("span",{key:0,style:{cursor:"pointer"},innerHTML:e.$t("%1sClick here%2s to add affiliate ID","<b>","</b>")},null,8,aSe))]),default:$(()=>[b("div",cSe,[b("label",dSe,O(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"]),Fe((C(),K(i,{onClick:s.save,disabled:r.saving,class:"fcom_primary_button"},{default:$(()=>[ne(O(e.$t("Save")),1)]),_:1},8,["onClick","disabled"])),[[w,r.saving]])]),b("div",fSe,[b("p",null,[ne(O(e.$t("Don't have an affiliate account?"))+" ",1),b("a",pSe,O(e.$t("Click here"))+".",1)])])]),_:1})])])):j("",!0),b("div",hSe,[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(O(e.$t("Show icon on header menu items")),1)]),_:1},8,["modelValue"]),b("p",null,O(e.$t("Adds icons next to text in header menu items, enhancing visual appeal and improving navigation clarity.")),1)]),j("",!0),b("div",mSe,[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(O(e.$t("Use Enhanced Color Contrast for Accessibility (a11y)")),1)]),_:1},8,["modelValue"]),b("p",null,O(e.$t("If you enable this, FluentCommunity will use enhanced color contrasts for different UI")),1)]),b("div",gSe,[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(O(e.$t("Classic")),1)]),_:1}),k(f,{disabled:!e.has_pro,value:"modern"},{default:$(()=>[ne(O(e.$t("Modern"))+" ",1),e.has_pro?j("",!0):(C(),T("span",vSe,"("+O(e.$t("Available on pro"))+")",1))]),_:1},8,["disabled"])]),_:1},8,["modelValue"]),b("div",ySe,[b("p",null,O(e.$t("Classic: Image/Video after the content. Modern: Image/Video at first")),1)])]),_:1},8,["label"])]),b("div",_Se,[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(O(e.$t("Optional")),1)]),_:1}),k(f,{value:"required"},{default:$(()=>[ne(O(e.$t("Required")),1)]),_:1}),k(f,{value:"disabled"},{default:$(()=>[ne(O(e.$t("Disabled")),1)]),_:1})]),_:1},8,["modelValue"]),b("div",bSe,[b("p",null,O(e.$t("When creating a new post, check if the post title is required or not")),1)])]),_:1},8,["label"])]),b("div",wSe,[Fe((C(),K(i,{onClick:s.save,disabled:r.saving,class:"fcom_primary_button"},{default:$(()=>[ne(O(e.$t("Save Settings")),1)]),_:1},8,["onClick","disabled"])),[[w,r.saving]])])]),_:1},8,["modelValue"])])])):(C(),T("div",CSe,[b("p",null,O(e.$t("Settings could not be loaded")),1)]))])]),_:1},8,["title"])]),_:1})}const SSe=We(Q8e,[["render",kSe]]),$Se={name:"PrivacySettings",components:{Layout:$s,AppLayout:Es},data(){return{loading:!1,saving:!1,settings:null}},methods:{getSettings(){this.loading=!0,this.$get("settings/privacy-settings").then(e=>{this.settings=e.settings}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})},save(){this.saving=!0,this.$post("settings/privacy-settings",{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("Privacy Settings"))}},ESe={class:"settings_router"},xSe={key:0,class:"white_loaded"},TSe={key:1,class:"fhr_content_layout_body"},MSe={class:"setting_body"},OSe={style:{"margin-top":"10px"},class:"fcom_help_text"},ISe={style:{"margin-top":"10px"},class:"fcom_help_text"},ASe={class:"fcom_input_wrap"},NSe={key:0},PSe={style:{"margin-top":"50px"},class:"fcom_input_wrap"},LSe={key:2};function RSe(e,t,n,o,r,s){const i=ct,l=Jn,a=sO,u=mh,c=ea,d=Bn,f=In,p=Fn,h=oe("layout"),m=oe("app-layout"),y=Dt("loading");return C(),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("Privacy Settings")},{actions:$(()=>[Fe((C(),K(i,{class:"fcom_primary_button",onClick:s.save},{default:$(()=>[b("span",null,O(e.$t("Save Settings")),1)]),_:1},8,["onClick"])),[[y,r.saving]])]),default:$(()=>[b("div",ESe,[r.loading?(C(),T("div",xSe,[k(l,{rows:5,animated:!0})])):r.settings?(C(),T("div",TSe,[b("div",MSe,[b("p",null,O(e.$t("Customize the privacy and compliance settings as per your need")),1),k(a),k(p,{onSubmit:t[4]||(t[4]=Je(v=>e.doNothing(),["prevent"])),modelValue:r.settings,"onUpdate:modelValue":t[5]||(t[5]=v=>r.settings=v),"label-position":"top"},{default:$(()=>[k(d,{label:e.$t("Who can view all members page")},{default:$(()=>[k(c,{modelValue:r.settings.members_page_status,"onUpdate:modelValue":t[0]||(t[0]=v=>r.settings.members_page_status=v)},{default:$(()=>[k(u,{border:"",value:"everybody"},{default:$(()=>[ne(O(e.$t("Everybody")),1)]),_:1}),k(u,{border:"",value:"logged_in"},{default:$(()=>[ne(O(e.$t("Only logged-in members")),1)]),_:1}),k(u,{border:"",value:"admin_only"},{default:$(()=>[ne(O(e.$t("Only Admin/Moderators")),1)]),_:1})]),_:1},8,["modelValue"]),b("div",OSe,[b("p",null,O(e.$t("Choose whether the all members page should be public or private or admin/moderator only")),1)])]),_:1},8,["label"]),k(d,{label:e.$t("Who can view membership spaces in user profile page")},{default:$(()=>[k(c,{modelValue:r.settings.user_space_visibility,"onUpdate:modelValue":t[1]||(t[1]=v=>r.settings.user_space_visibility=v)},{default:$(()=>[k(u,{border:"",value:"everybody"},{default:$(()=>[ne(O(e.$t("Everybody")),1)]),_:1}),k(u,{border:"",value:"logged_in"},{default:$(()=>[ne(O(e.$t("Only logged-in members")),1)]),_:1}),k(u,{border:"",value:"admin_only"},{default:$(()=>[ne(O(e.$t("Only Admin/Moderators")),1)]),_:1})]),_:1},8,["modelValue"]),b("div",ISe,[b("p",null,O(e.$t("Choose the privacy seetings for spaces page of a member profile.")),1)])]),_:1},8,["label"]),b("div",ASe,[k(f,{disabled:!e.has_pro,"true-value":"yes","false-value":"no",modelValue:r.settings.can_customize_username,"onUpdate:modelValue":t[2]||(t[2]=v=>r.settings.can_customize_username=v)},{default:$(()=>[ne(O(e.$t("Users can change their community username"))+" ",1),e.has_pro?j("",!0):(C(),T("span",NSe,"("+O(e.$t("This feature is available on the pro version of FluentCommunity"))+")",1))]),_:1},8,["disabled","modelValue"]),b("p",null,O(e.$t("When enabled, Members can change their username on their own. Otherwise, an admin/moderator can change the username")),1)]),j("",!0),b("div",PSe,[Fe((C(),K(i,{onClick:s.save,disabled:r.saving,class:"fcom_primary_button"},{default:$(()=>[ne(O(e.$t("Save Settings")),1)]),_:1},8,["onClick","disabled"])),[[y,r.saving]])])]),_:1},8,["modelValue"])])])):(C(),T("div",LSe,[b("p",null,O(e.$t("Settings could not be loaded")),1)]))])]),_:1},8,["title"])]),_:1})}const DSe=We($Se,[["render",RSe]]),VSe={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")}}},FSe={class:"fcom_upgrade_header"},BSe={class:"dialog_body"},zSe={class:"fcom_upgrade_banner"},jSe=["href"],HSe={class:"fcom_upgrade_content"},USe={class:"fcom_feature_image"},WSe=["src","alt"],KSe={class:"fcom_upgrade_body"},qSe={class:"fcom_upgrade_description"},GSe=["href"];function YSe(e,t,n,o,r,s){const i=ta;return C(),K(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",FSe,[b("h4",null,O(r.upgradeModule.headerTitle),1),b("p",null,O(r.upgradeModule.headerDescription),1)])]),default:$(()=>[b("div",BSe,[b("div",zSe,[b("p",null," 🎉 "+O(e.$t("Discover exciting new features now!")),1),b("a",{href:e.appVars.upgrade_url,target:"_blank"},O(e.$t("Upgrade Now")),9,jSe)]),b("div",HSe,[b("div",USe,[b("img",{src:e.appVars.assets_url+"images/upgrades/"+r.upgradeModule.featureImage,alt:r.upgradeModule.headerTitle},null,8,WSe)]),b("div",KSe,[b("h4",null,O(r.upgradeModule.bodyTitle),1),b("p",qSe,O(r.upgradeModule.bodyDescription),1),b("a",{class:"el-button fcom_primary_button",href:e.appVars.upgrade_url,target:"_blank"},O(e.$t("Upgrade to Pro")),9,GSe)])])])]),_:1},8,["modelValue"])}const Ev=We(VSe,[["render",YSe]]),ZSe={name:"StorageSettings",props:["features"],components:{UpgradeToProModal:Ev},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()}},JSe={class:"fcom_storage_settings"},XSe={class:"dialog_header"},QSe={class:"dialog_left"},e9e={key:0,class:"white_loaded"},t9e={key:1,class:"dialog_body"},n9e={key:0},o9e=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),r9e=b("hr",null,null,-1),s9e={class:"fcom_cloudflare_settings"},i9e=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),l9e=b("hr",null,null,-1),a9e={class:"fcom_s3_settings"},u9e={key:2},c9e={class:"dialog_footer"},d9e={key:2};function f9e(e,t,n,o,r,s){const i=ct,l=Jn,a=R3,u=ea,c=Bn,d=Tt,f=Ss,p=vr,h=Fn,m=_h,y=oe("UpgradeToProModal"),v=Dt("loading");return C(),T(fe,null,[b("div",JSe,[k(i,{class:"fcom_secondary_button",onClick:t[0]||(t[0]=w=>s.openSettings())},{default:$(()=>{var w;return[ne(O(e.$t("Configure"))+" ("+O((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",XSe,[b("div",QSe,[b("div",null,[b("h4",null,O(e.$t("Configure Media Storage")),1)])])])]),default:$(()=>[r.fetching?(C(),T("div",e9e,[k(l,{rows:5,animated:!0})])):r.storageConfig?(C(),T("div",t9e,[r.storageConfig.is_defined?(C(),T("p",n9e,O(e.$t("__CLOUD_STORAGE_CONFIGURED")),1)):(C(),T(fe,{key:1},[k(h,{onSubmit:t[14]||(t[14]=Je(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(O(e.$t("Server Storage")),1)]),_:1}),k(a,{value:"cloudflare_r2"},{default:$(()=>[ne(O(e.$t("Cloudflare R2 (Recommended)")),1)]),_:1}),k(a,{value:"amazon_s3"},{default:$(()=>[ne(O(e.$t("Amazon S3")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["label"]),r.storageConfig.driver==="cloudflare_r2"?(C(),T(fe,{key:0},[o9e,r9e,b("div",s9e,[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(),T(fe,{key:1},[i9e,l9e,b("div",a9e,[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),T(fe,null,nt(r.s3Locations,(w,_)=>(C(),K(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(),T("p",u9e,O(e.$t("Your files will be stored in the default Uploads folder")),1))]),_:1}),b("div",c9e,[Fe((C(),K(i,{class:"fcom_primary_button",disabled:r.saving,onClick:s.saveSettings},{default:$(()=>[ne(O(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])),[[v,r.saving]])])],64))])):(C(),T("div",d9e,[b("p",null,O(e.$t("Config could not be loaded")),1)]))]),_:1},8,["width","modelValue"]),r.openUpgradeModal?(C(),K(y,{key:0,showModal:r.openUpgradeModal,onCloseModal:t[16]||(t[16]=w=>r.openUpgradeModal=!1),upgrade_module:"media_module"},null,8,["showModal"])):j("",!0)],64)}const p9e=We(ZSe,[["render",f9e]]),h9e={name:"LeaderBoardConfig",props:["features"],emits:["saveSettings"],data(){return{levels:null,showSettings:!1,fetching:!1,saving:!1,openUpgradeModal:!1}},components:{UpgradeToProModal:Ev},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})}}},m9e={class:"fcom_storage_settings"},g9e={key:0,class:"white_loaded"},v9e={key:1,class:"dialog_body"},y9e={class:"fcom_level_table"},_9e={class:"fcom_level_table_row fcom_header_row"},b9e=b("div",{class:"fcom_lavel_num"}," # ",-1),w9e={class:"fcom_lavel_desc"},C9e={class:"fcom_lavel_actions"},k9e={class:"fcom_lavel_num"},S9e={class:"fcom_lavel_desc"},$9e={class:"fcom_lavel_actions"},E9e={class:"dialog_footer"},x9e={key:2};function T9e(e,t,n,o,r,s){const i=ct,l=Jn,a=In,u=Bn,c=Tt,d=Fn,f=ta,p=oe("UpgradeToProModal"),h=Dt("loading");return C(),T(fe,null,[b("div",m9e,[k(i,{class:"fcom_secondary_button",onClick:t[0]||(t[0]=m=>s.openSettings())},{default:$(()=>[ne(O(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,O(e.$t("Leaderboard / Gamification Settings")),1)]),default:$(()=>[r.fetching?(C(),T("div",g9e,[k(l,{rows:5,animated:!0})])):r.levels?(C(),T("div",v9e,[k(d,{onSubmit:t[2]||(t[2]=Je(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(),T(fe,{key:0},[b("h5",null,O(e.$t("Leaderboard Levels")),1),b("div",y9e,[b("div",_9e,[b9e,b("div",w9e,O(e.$t("Title & Description")),1),b("div",C9e,O(e.$t("Minimum Points")),1)]),(C(!0),T(fe,null,nt(r.levels,(m,y,v)=>(C(),T("div",{class:"fcom_level_table_row",key:y},[b("div",k9e,O(v+1),1),b("div",S9e,[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",$9e,[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)):j("",!0)]),_:1}),b("div",E9e,[Fe((C(),K(i,{class:"fcom_primary_button",disabled:r.saving,onClick:s.saveSettings},{default:$(()=>[ne(O(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])),[[h,r.saving]])])])):(C(),T("div",x9e,[b("p",null,O(e.$t("Config could not be loaded")),1)]))]),_:1},8,["size","modelValue"]),r.openUpgradeModal?(C(),K(p,{key:0,showModal:r.openUpgradeModal,onCloseModal:t[4]||(t[4]=m=>r.openUpgradeModal=!1),upgrade_module:"leader_board_module"},null,8,["showModal"])):j("",!0)],64)}const M9e=We(h9e,[["render",T9e]]),O9e={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 class="fcom_shape fcom_shape_circle" 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 class="fcom_shape fcom_shape_square" 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 class="fcom_shape fcom_shape_triangle" 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 class="fcom_shape fcom_shape_star" 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 class="fcom_shape fcom_shape_heart" 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 class="fcom_shape fcom_shape_diamond" 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])}}},I9e={class:"fcom_svg_generator"},A9e={class:"fcom_form_item"},N9e={class:"fcom_form_item"},P9e=["innerHTML"];function L9e(e,t,n,o,r,s){const i=D3,l=R3,a=ea;return C(),T("div",I9e,[b("div",A9e,[b("label",null,O(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",N9e,[b("label",null,O(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),T(fe,null,nt(s.svgShapes,(u,c)=>(C(),K(l,{key:c,value:c},{default:$(()=>[b("div",{innerHTML:u},null,8,P9e)]),_:2},1032,["value"]))),128))]),_:1},8,["modelValue"])])])}const R9e=We(O9e,[["render",L9e]]);var Nk="emoji-mart";const D9e=JSON;var oL=typeof window<"u"&&"localStorage"in window;let O2,I2;function V9e(e){e||(e={}),O2=e.getter,I2=e.setter}function F9e(e){Nk=e}function B9e(e){for(let t in e){let n=e[t];rL(t,n)}}function rL(e,t){if(I2)I2(e,t);else{if(!oL)return;try{window.localStorage[`${Nk}.${e}`]=D9e.stringify(t)}catch{}}}function z9e(e){if(O2)return O2(e);if(!oL)return;try{var t=window.localStorage[`${Nk}.${e}`]}catch{return}if(t)return JSON.parse(t)}const hd={update:B9e,set:rL,get:z9e,setNamespace:F9e,setHandlers:V9e},r_={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"},sL=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 iL(e){var t=Object.getOwnPropertyNames(e);for(let n of t){let o=e[n];e[n]=o&&typeof o=="object"?iL(o):o}return Object.freeze(e)}const j9e=e=>{if(!e.compressed)return e;e.compressed=!1;for(let t in e.emojis){let n=e.emojis[t];for(let o in r_)n[o]=n[r_[o]],delete n[r_[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=sL(n)}return e=iL(e),e},s_=["+1","grinning","kissing_heart","heart_eyes","laughing","stuck_out_tongue_winking_eye","sweat_smile","joy","scream","disappointed","unamused","weary","sob","sunglasses","heart","hankey"];let Tr,Pk,A2={};function lL(){Pk=!0,Tr=hd.get("frequently")}function H9e(e){Pk||lL();var{id:t}=e;Tr||(Tr=A2),Tr[t]||(Tr[t]=0),Tr[t]+=1,hd.set("last",t),hd.set("frequently",Tr)}function U9e(e){if(Pk||lL(),!Tr){A2={};const i=[];let l=Math.min(e,s_.length);for(let a=0;a<l;a++)A2[s_[a]]=parseInt((l-a)/4,10)+1,i.push(s_[a]);return i}const t=e,n=[];for(let i in Tr)Tr.hasOwnProperty(i)&&n.push(i);const r=n.sort((i,l)=>Tr[i]-Tr[l]).reverse().slice(0,t),s=hd.get("last");return s&&r.indexOf(s)==-1&&(r.pop(),r.push(s)),r}const N2={add:H9e,get:U9e},W9e={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>'},K9e={props:{i18n:{type:Object,required:!0},color:{type:String},categories:{type:Array,required:!0},activeCategory:{type:Object,default(){return{}}}},emits:["click"],created(){this.svgs=W9e}},q9e={role:"tablist",class:"emoji-mart-anchors"},G9e=["aria-label","aria-selected","data-title","onClick"],Y9e=["innerHTML"];function Z9e(e,t,n,o,r,s){return C(),T("div",q9e,[(C(!0),T(fe,null,nt(n.categories,i=>(C(),T("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:et({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,Y9e),b("span",{"aria-hidden":"true",class:"emoji-mart-anchor-bar",style:et({backgroundColor:n.color})},null,4)],14,G9e))),128))])}const J9e=We(K9e,[["render",Z9e]]),X9e=String,Q9e=X9e.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 e$e(e){var t=e.split("-"),n=t.map(o=>`0x${o}`);return Q9e.apply(null,n)}function X9(e){return e.reduce((t,n)=>(t.indexOf(n)===-1&&t.push(n),t),[])}function t$e(e,t){const n=X9(e),o=X9(t);return n.filter(r=>o.indexOf(r)>=0)}function aL(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=aL(r,s)),n[o]=s}return n}function n$e(){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 o$e=61,r$e=/^(?:\:([^\:]+)\:)(?:\:skin-tone-(\d)\:)?$/,Q9=["1F3FA","1F3FB","1F3FC","1F3FD","1F3FE","1F3FF"];class s$e{constructor(t,{emojisToShowFilter:n,include:o,exclude:r,custom:s,recent:i,recentLength:l=20}={}){this._data=j9e(t),this._emojisFilter=n||null,this._include=o||null,this._exclude=r||null,this._custom=s||[],this._recent=i||N2.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(r$e);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=t$e.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=sL(n));let o=new i0(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 i0(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 i0{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 i0(s))}}this._sanitized=i$e(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=o$e-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 uL{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 i$e(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:e$e(i)})}const l$e={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"}},a$e={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{}}}},u$e={props:{...l$e,data:{type:Object,required:!0}},emits:["click","mouseenter","mouseleave"],computed:{view(){return new uL(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 c$e(e,t,n,o,r,s){return s.view.canRender?(C(),K(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:et(s.view.cssStyle)},O(s.view.content),7)]),_:1},40,["title","aria-label","data-title","onMouseenter","onMouseleave","onClick"])):j("",!0)}const cL=We(u$e,[["render",c$e]]),d$e={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 uL(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:cL}},f$e=["aria-label"],p$e={class:"emoji-mart-category-label"},h$e={class:"emoji-mart-category-label"},m$e=["aria-label","data-title","title","onMouseenter","onMouseleave","onClick"],g$e={key:0},v$e={class:"emoji-mart-no-results-label"};function y$e(e,t,n,o,r,s){const i=oe("emoji");return s.isVisible&&(s.isSearch||s.hasResults)?(C(),T("section",{key:0,class:D({"emoji-mart-category":!0,"emoji-mart-no-results":!s.hasResults}),"aria-label":n.i18n.categories[n.id]},[b("div",p$e,[b("h3",h$e,O(n.i18n.categories[n.id]),1)]),(C(!0),T(fe,null,nt(s.emojiObjects,({emojiObject:l,emojiView:a})=>(C(),T(fe,null,[a.canRender?(C(),T("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:et(a.cssStyle)},O(a.content),7)],42,m$e)):j("",!0)],64))),256)),s.hasResults?j("",!0):(C(),T("div",g$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",v$e,O(n.i18n.notfound),1)]))],10,f$e)):j("",!0)}const _$e=We(d$e,[["render",y$e]]),b$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}}},w$e=["onClick"];function C$e(e,t,n,o,r,s){return C(),T("div",{class:D({"emoji-mart-skin-swatches":!0,"emoji-mart-skin-swatches-opened":r.opened})},[(C(),T(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,w$e)],2)),64))],2)}const k$e=We(b$e,[["render",C$e]]),S$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:cL,Skins:k$e}},$$e={class:"emoji-mart-preview"},E$e={class:"emoji-mart-preview-emoji"},x$e={class:"emoji-mart-preview-data"},T$e={class:"emoji-mart-preview-name"},M$e={class:"emoji-mart-preview-shortnames"},O$e={class:"emoji-mart-preview-emoticons"},I$e={class:"emoji-mart-preview-emoji"},A$e={class:"emoji-mart-preview-data"},N$e={class:"emoji-mart-title-label"},P$e={key:0,class:"emoji-mart-preview-skins"};function L$e(e,t,n,o,r,s){const i=oe("emoji"),l=oe("skins");return C(),T("div",$$e,[n.emoji?(C(),T(fe,{key:0},[b("div",E$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",x$e,[b("div",T$e,O(n.emoji.name),1),b("div",M$e,[(C(!0),T(fe,null,nt(s.emojiShortNames,a=>(C(),T("span",{key:a,class:"emoji-mart-preview-shortname"},":"+O(a)+":",1))),128))]),b("div",O$e,[(C(!0),T(fe,null,nt(s.emojiEmoticons,a=>(C(),T("span",{key:a,class:"emoji-mart-preview-emoticon"},O(a),1))),128))])])],64)):(C(),T(fe,{key:1},[b("div",I$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",A$e,[b("span",N$e,O(n.title),1)]),n.showSkinTones?(C(),T("div",P$e,[k(l,{skin:n.skinProps.skin,onChange:t[0]||(t[0]=a=>n.onSkinChange(a))},null,8,["skin"])])):j("",!0)],64))])}const R$e=We(S$e,[["render",L$e]]),D$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()}},V$e={class:"emoji-mart-search"},F$e=["placeholder"],B$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 z$e(e,t,n,o,r,s){return C(),T("div",V$e,[Fe(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,F$e),[[Bc,r.value]]),B$e])}const j$e=We(D$e,[["render",z$e]]);var H$e=typeof window<"u";H$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 U$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 W$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"}},K$e={props:{...a$e,data:{type:Object,required:!0}},emits:["select","skin-change"],data(){return{activeSkin:this.skin||hd.get("skin")||this.defaultSkin,view:new U$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+n$e()},filteredCategories(){return this.view.filteredCategories},mergedI18n(){return Object.freeze(aL(W$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),N2.add(this.view.previewEmoji))},onEmojiClick(e){this.$emit("select",e),N2.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:J9e,Category:_$e,Preview:R$e,Search:j$e}},q$e={key:0,class:"emoji-mart-bar emoji-mart-bar-anchors"},G$e={id:"emoji-mart-list",ref:"scrollContent",role:"listbox","aria-expanded":"true"},Y$e={key:0,class:"emoji-mart-bar emoji-mart-bar-preview"};function Z$e(e,t,n,o,r,s){const i=oe("anchors"),l=oe("search"),a=oe("category"),u=oe("preview");return C(),T("section",{class:"emoji-mart emoji-mart-static",style:et(s.customStyles)},[e.showCategories?(C(),T("div",q$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"])])):j("",!0),he(e.$slots,"searchTemplate",{data:n.data,i18n:e.i18n,autoFocus:e.autoFocus,onSearch:s.onSearch},()=>[e.showSearch?(C(),K(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"])):j("",!0)]),b("div",{role:"tabpanel",class:"emoji-mart-scroll",ref:"scroll",onScroll:t[0]||(t[0]=(...c)=>s.onScroll&&s.onScroll(...c))},[b("div",G$e,[he(e.$slots,"customCategory"),(C(!0),T(fe,null,nt(r.view.filteredCategories,(c,d)=>Fe((C(),K(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(),T("div",Y$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"])])):j("",!0)])],4)}const J$e=We(K$e,[["render",Z$e]]),X$e={name:"EmojiPicker",components:{Picker:J$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 s$e(t),this.emojiIndex=window.fcomEmojiIndex,this.imojiLoading=!1):this.errorMessage="Emoji loading failed"}).catch(t=>{this.errorMessage="Emoji loading failed"}).finally(()=>{this.isLoading=!1})}}},Q$e={style:{position:"relative"},ref:"container"},eEe=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),tEe={key:0,class:"emoji-mart emoji-mart-static",style:{width:"320px",padding:"10px 20px"}},nEe={key:0},oEe={style:{"text-align":"center","margin-bottom":"20px"}},rEe={key:1,class:"fcom_emoji_holder"};function sEe(e,t,n,o,r,s){const i=Ne,l=ct,a=Jn,u=oe("Picker"),c=bo;return C(),T("div",Q$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:$(()=>[eEe]),_:1})]),_:1})]),default:$(()=>[r.imojiLoading?(C(),T("div",tEe,[r.errorMessage?(C(),T("div",nEe,O(r.errorMessage),1)):(C(),T(fe,{key:1},[b("div",oEe,O(e.$t("Loading.....")),1),k(a,{animated:!0,rows:3})],64))])):r.emojiIndex?(C(),T("div",rEe,[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"])])):j("",!0)]),_:1},8,["onShow"])],512)}const dL=We(X$e,[["render",sEe]]),iEe={name:"LogoEmojiSelector",components:{EmojiPicker:dL,ImageUploader:Td,SvgShapeGenerator:R9e},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(){if(this.logo)this.selectedTab="logo";else if(this.emoji)this.selectedTab="emoji";else if(this.shape_svg){if(this.custom_svg&&!/fcom_shape/.test(this.shape_svg)){this.selectedTab="shape_svg";return}this.selectedTab="shape"}}},lEe=["innerHTML"];function aEe(e,t,n,o,r,s){const i=ct,l=oe("EmojiPicker"),a=Tt,u=NO,c=oe("SvgShapeGenerator"),d=Ed,f=oe("ImageUploader"),p=AO,h=bo;return C(),K(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,lEe)]),_: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(),K(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"])):j("",!0),k(u,{name:"logo",label:e.$t("Custom Image")},{default:$(()=>[r.logo?(C(),K(d,{key:0,alt:e.$t("Logo"),src:r.logo,style:{"max-width":"100px"}},null,8,["alt","src"])):j("",!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(O(e.$t("Close")),1)]),_:1})]),_:1},8,["visible"])}const xv=We(iEe,[["render",aEe]]),uEe={name:"UserBadgesConfig",components:{LogoEmojiSelector:xv,UpgradeToProModal:Ev},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()}}},fL=e=>(J$("data-v-45693b4b"),e=e(),X$(),e),cEe={class:"fcom_storage_settings"},dEe={key:0,class:"white_loaded"},fEe={key:1},pEe={class:"header_user_badge"},hEe={style:{"margin-bottom":"30px"},class:"fcom_user_badges fcom_manager_table"},mEe={class:"fcom_badge_preview"},gEe={class:"fcom_table_action_col",style:{display:"flex",gap:"10px"}},vEe=fL(()=>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)),yEe=["onClick"],_Ee=fL(()=>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)),bEe=[_Ee],wEe={key:2};function CEe(e,t,n,o,r,s){const i=ct,l=Jn,a=In,u=Bn,c=Z0,d=oe("UserBadge"),f=Y0,p=Fn,h=ta,m=oe("logo-emoji-selector"),y=Tt,v=D3,w=yh,_=vh,S=_h,x=oe("UpgradeToProModal"),E=Dt("loading");return C(),T(fe,null,[b("div",cEe,[k(i,{class:"fcom_secondary_button",onClick:t[0]||(t[0]=M=>s.openSettings())},{default:$(()=>[ne(O(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]=M=>r.showSettings=M),direction:"rtl"},{header:$(()=>[b("h4",null,O(e.$t("User Badge Settings")),1)]),default:$(()=>[r.fetching?(C(),T("div",dEe,[k(l,{rows:5,animated:!0})])):r.badges?(C(),T("div",fEe,[k(p,{onSubmit:t[3]||(t[3]=Je(M=>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]=M=>n.features.user_badge=M),label:e.$t("Enable User Badge Module"),size:"large"},null,8,["modelValue","label"])]),_:1}),n.features.user_badge==="yes"?(C(),T(fe,{key:0},[b("div",pEe,[b("h3",null,O(e.$t("User Badges")),1),k(i,{class:"fcom_secondary_button",onClick:t[2]||(t[2]=M=>s.initAddNew()),size:"small"},{default:$(()=>[ne(O(e.$t("Add New")),1)]),_:1})]),b("div",hEe,[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:$(M=>[b("div",mEe,[k(d,{is_preview:!0,badge:M.row},null,8,["badge"])])]),_:1},8,["label"]),k(c,{width:"150px",label:e.$t("Actions")},{default:$(M=>[b("div",gEe,[vEe,b("div",{onClick:A=>s.initEdit(M.row),class:"action_item clickable"},bEe,8,yEe)])]),_:1},8,["label"])]),_:1},8,["empty-text","data"])])],64)):j("",!0),k(u,null,{default:$(()=>[Fe((C(),K(i,{class:"fcom_primary_button",disabled:r.saving,onClick:s.saveSettings},{default:$(()=>[ne(O(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])),[[E,r.saving]])]),_:1})]),_:1})])):(C(),T("div",wEe,[b("p",null,O(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]=M=>r.showEditBagdeModal=M),title:e.$t("Edit Badge"),width:"30%"},{default:$(()=>[r.editingBadge?(C(),K(p,{key:0,onSubmit:t[13]||(t[13]=Je(M=>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]=M=>r.editingBadge.title=M),placeholder:e.$t("Badge Title")},{prepend:$(()=>{var M,A;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:((M=r.editingBadge.config)==null?void 0:M.emoji)||"",shape_svg:(A=r.editingBadge.config)==null?void 0:A.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]=M=>r.editingBadge.show_label=M),"true-value":"yes","false-value":"no"},{default:$(()=>[ne(O(e.$t("Show Label on Badge")),1)]),_:1},8,["modelValue"])]),_:1}),r.editingBadge.show_label=="yes"?(C(),T(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]=M=>{r.editingBadge.color=M}),modelValue:r.editingBadge.color,"onUpdate:modelValue":t[9]||(t[9]=M=>r.editingBadge.color=M)},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]=M=>{r.editingBadge.background_color=M}),modelValue:r.editingBadge.background_color,"onUpdate:modelValue":t[11]||(t[11]=M=>r.editingBadge.background_color=M)},null,8,["modelValue"])]),_:1},8,["label"])]),_:1})]),_:1}),b("p",null,O(e.$t("For best UI, keep the colors empty")),1)],64)):j("",!0),k(u,null,{default:$(()=>[k(i,{class:"fcom_primary_button",onClick:t[12]||(t[12]=M=>s.closeEdit())},{default:$(()=>[ne(O(e.$t("Save")),1)]),_:1})]),_:1})]),_:1})):j("",!0)]),_:1},8,["modelValue","title"]),r.openUpgradeModal?(C(),K(x,{key:0,showModal:r.openUpgradeModal,onCloseModal:t[15]||(t[15]=M=>r.openUpgradeModal=!1),upgrade_module:"user_badge_module"},null,8,["showModal"])):j("",!0)],64)}const kEe=We(uEe,[["render",CEe],["__scopeId","data-v-45693b4b"]]),SEe={name:"Features",components:{UserBadgesConfig:kEe,LeaderBoardConfig:M9e,StorageSettings:p9e,Layout:$s,AppLayout:Es,UpgradeToProModal:Ev},data(){return{features:null,addOns:{},loading:!1,installing:!1,openGiphyUpgradeModal:!1,openEmojiUpgradeModal:!1}},methods:{saveFeatures(e=!0){if(this.features.giphy_module==="yes"&&tI(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"))}},$Ee={class:"settings_router"},EEe={key:0,class:"white_loaded"},xEe=b("hr",null,null,-1),TEe={key:1,style:{"margin-bottom":"30px"}},MEe={class:"fhr_content_layout_body"},OEe={class:"setting_header"},IEe={class:"fcom_advancde_fetaures"},AEe={key:0,class:"setting_body"},NEe={class:"setting_item"},PEe={class:"setting_field_placeholder"},LEe={class:"title"},REe={class:"info"},DEe={class:"settings_field_data"},VEe={class:"align-right"},FEe={class:"setting_item"},BEe={class:"setting_field_placeholder"},zEe={class:"title"},jEe={class:"info"},HEe={class:"settings_field_data"},UEe={class:"align-right"},WEe={class:"setting_item"},KEe={class:"setting_field_placeholder"},qEe={class:"title"},GEe={class:"info"},YEe={class:"settings_field_data"},ZEe={class:"align-right"},JEe={class:"fcom_module_popover_content"},XEe={class:"setting_item"},QEe={class:"setting_field_placeholder"},e7e={class:"title"},t7e={class:"info"},n7e={class:"settings_field_data"},o7e={class:"align-right"},r7e={key:0,class:"fcom_giphy_api",style:{"margin-bottom":"5px"}},s7e={class:"fcom_module_popover_content"},i7e={class:"setting_item"},l7e={class:"setting_field_placeholder"},a7e={class:"title"},u7e={class:"info"},c7e={class:"settings_field_data"},d7e={class:"align-right"},f7e={class:"fcom_module_popover_content"},p7e={class:"setting_item"},h7e={class:"setting_field_placeholder"},m7e={class:"title"},g7e={class:"info"},v7e={class:"settings_field_data"},y7e={class:"align-right"},_7e={class:"fhr_content_layout_body"},b7e={class:"setting_header"},w7e={class:"fcom_advancde_fetaures"},C7e={key:0,class:"setting_body"},k7e={class:"setting_field_placeholder"},S7e={class:"title recommend_plugin",style:{display:"flex","align-items":"flex-start"}},$7e={class:"avatar",style:{"margin-right":"15px"}},E7e=["src"],x7e=["href"],T7e={class:"info"},M7e={class:"settings_field_data"},O7e={class:"align-right"},I7e=["href"];function A7e(e,t,n,o,r,s){const i=Jn,l=gh,a=oe("LeaderBoardConfig"),u=oe("UserBadgesConfig"),c=In,d=ct,f=bo,p=Tt,h=oe("UpgradeToProModal"),m=oe("storage-settings"),y=oe("layout"),v=oe("app-layout");return C(),K(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",$Ee,[r.loading?(C(),T("div",EEe,[k(i,{rows:5,animated:!0}),xEe,k(i,{rows:7,animated:!0})])):(C(),T("div",TEe,[b("div",MEe,[b("div",OEe,[b("h2",null,O(e.$t("Advanced Features")),1)]),b("div",IEe,[r.features?(C(),T("div",AEe,[b("div",NEe,[b("div",PEe,[b("div",LEe,[ne(O(e.$t("Leaderboards Module"))+" ",1),e.has_pro?(C(),T(fe,{key:0},[r.features.leader_board_module==="no"?(C(),K(l,{key:0,type:"info",size:"small"},{default:$(()=>[ne(O(e.$t("Disabled")),1)]),_:1})):r.features.leader_board_module==="yes"?(C(),K(l,{key:1,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(O(e.$t("Enabled")),1)]),_:1})):j("",!0)],64)):j("",!0)]),b("div",REe,O(e.$t("__LEADERBOARD_DESC")),1)]),b("div",DEe,[b("div",VEe,[k(a,{onSaveSettings:s.saveFeatures,features:r.features},null,8,["onSaveSettings","features"])])])]),b("div",FEe,[b("div",BEe,[b("div",zEe,[ne(O(e.$t("User Badges"))+" ",1),e.has_pro?(C(),T(fe,{key:0},[r.features.user_badge==="no"?(C(),K(l,{key:0,type:"info",size:"small"},{default:$(()=>[ne(O(e.$t("Disabled")),1)]),_:1})):r.features.user_badge==="yes"?(C(),K(l,{key:1,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(O(e.$t("Enabled")),1)]),_:1})):j("",!0)],64)):j("",!0)]),b("div",jEe,O(e.$t("__USER_BADGE_DESC")),1)]),b("div",HEe,[b("div",UEe,[k(u,{onSaveSettings:s.saveFeatures,features:r.features},null,8,["onSaveSettings","features"])])])]),b("div",WEe,[b("div",KEe,[b("div",qEe,[ne(O(e.$t("Course Module"))+" ",1),r.features.course_module==="no"?(C(),K(l,{key:0,type:"info",size:"small"},{default:$(()=>[ne(O(e.$t("Disabled")),1)]),_:1})):r.features.course_module==="yes"?(C(),K(l,{key:1,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(O(e.$t("Enabled")),1)]),_:1})):j("",!0)]),b("div",GEe,O(e.$t("__COURSE_STRUCTURED_LESSONS")),1)]),b("div",YEe,[b("div",ZEe,[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(O(e.$t("Settings")),1)]),_:1})]),default:$(()=>[b("div",JEe,[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(O(e.$t("Save")),1)]),_:1},8,["onClick"])])]),_:1},8,["title"])])])]),b("div",XEe,[b("div",QEe,[b("div",e7e,[ne(O(e.$t("Giphy Module"))+" ",1),e.has_pro?(C(),T(fe,{key:0},[r.features.giphy_module==="no"?(C(),K(l,{key:0,type:"info",size:"small",effect:"dark"},{default:$(()=>[ne(O(e.$t("Disabled")),1)]),_:1})):r.features.giphy_module==="yes"?(C(),K(l,{key:1,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(O(e.$t("Enabled")),1)]),_:1})):j("",!0)],64)):j("",!0)]),b("div",t7e,O(e.$t("Unlock potential by using giphy when creating a new article , post or comment")),1)]),b("div",n7e,[b("div",o7e,[r.openGiphyUpgradeModal?j("",!0):(C(),K(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(O(e.$t("Settings")),1)]),_:1})]),default:$(()=>[r.features.giphy_module==="yes"?(C(),T("div",r7e,[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"])])):j("",!0),b("div",s7e,[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(O(e.$t("Save")),1)]),_:1},8,["onClick"])])]),_:1},8,["title"])),r.openGiphyUpgradeModal?(C(),K(h,{key:1,showModal:r.openGiphyUpgradeModal,onCloseModal:t[4]||(t[4]=w=>r.openGiphyUpgradeModal=!1),upgrade_module:"giphy_module"},null,8,["showModal"])):j("",!0)])])]),b("div",i7e,[b("div",l7e,[b("div",a7e,[ne(O(e.$t("Emoji Module"))+" ",1),e.has_pro?(C(),T(fe,{key:0},[r.features.emoji_module==="no"?(C(),K(l,{key:0,type:"info",size:"small",effect:"dark"},{default:$(()=>[ne(O(e.$t("Disabled")),1)]),_:1})):r.features.emoji_module==="yes"?(C(),K(l,{key:1,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(O(e.$t("Enabled")),1)]),_:1})):j("",!0)],64)):j("",!0)]),b("div",u7e,O(e.$t("__EMOJIS_DESC")),1)]),b("div",c7e,[b("div",d7e,[r.openEmojiUpgradeModal?j("",!0):(C(),K(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(O(e.$t("Settings")),1)]),_:1})]),default:$(()=>[b("div",f7e,[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(O(e.$t("Save")),1)]),_:1},8,["onClick"])])]),_:1},8,["title"])),r.openEmojiUpgradeModal?(C(),K(h,{key:1,showModal:r.openEmojiUpgradeModal,onCloseModal:t[7]||(t[7]=w=>r.openEmojiUpgradeModal=!1),upgrade_module:"emoji_module"},null,8,["showModal"])):j("",!0)])])]),b("div",p7e,[b("div",h7e,[b("div",m7e,[ne(O(e.$t("Media Module"))+" ",1),r.features.cloud_storage==="yes"?(C(),K(l,{key:0,type:"success",size:"small",effect:"light"},{default:$(()=>[ne(O(e.$t("Enabled")),1)]),_:1})):r.features.cloud_storage==="no"?(C(),K(l,{key:1,type:"info",size:"small"},{default:$(()=>[ne(O(e.$t("Local")),1)]),_:1})):j("",!0)]),b("div",g7e,O(e.$t("__CLOUD_STORAGE_DESC")),1)]),b("div",v7e,[b("div",y7e,[k(m,{features:r.features},null,8,["features"])])])])])):j("",!0)])])])),b("div",_7e,[b("div",b7e,[b("h2",null,O(e.$t("Recommended Plugins and Addons")),1)]),b("div",w7e,[r.features?(C(),T("div",C7e,[(C(!0),T(fe,null,nt(r.addOns,(w,_)=>(C(),T("div",{key:_,class:"setting_item"},[b("div",k7e,[b("div",S7e,[b("div",$7e,[b("img",{alt:"",src:w.logo,style:{width:"60px"}},null,8,E7e)]),b("div",null,[b("a",{target:"_blank",href:w.learn_more_url},O(w.title),9,x7e),w.is_installed?(C(),K(l,{key:0,type:"success",size:"small",effect:"light",style:{"margin-left":"8px"}},{default:$(()=>[ne(O(e.$t("Installed")),1)]),_:1})):j("",!0),b("div",T7e,O(w.description),1)])])]),b("div",M7e,[b("div",O7e,[w.is_installed?(C(),T("a",{key:1,href:w.settings_url,class:"el-button el-button--default fcom_secondary_button"},O(e.$t("View Settings")),9,I7e)):(C(),K(d,{key:0,class:"fcom_secondary_button",onClick:S=>s.installPlugin(_)},{default:$(()=>[ne(O(w.action_text),1)]),_:2},1032,["onClick"]))])])]))),128))])):j("",!0)])])])]),_:1},8,["title"])]),_:1})}const N7e=We(SEe,[["render",A7e]]),P7e={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)}}},L7e={class:"drag-container"},R7e=["onDragstart","onDragover","onDrop"];function D7e(e,t,n,o,r,s){return C(),T("div",L7e,[k(k0,{name:"flip-list",tag:"div",class:"drag-group"},{default:$(()=>[(C(!0),T(fe,null,nt(n.items,(i,l)=>(C(),T("div",{key:i[n.rowKey],onDragstart:a=>s.dragStart(a,l),onDragend:t[0]||(t[0]=(...a)=>s.dragEnd&&s.dragEnd(...a)),onDragover:Je(a=>s.dragOver(a,l),["prevent"]),onDrop:Je(a=>s.dropEnd(a,l),["prevent"]),draggable:!0,class:D(["drag-item",`${n.itemClass} hello_${l}`,{dragging:r.draggingIndex===l}]),style:et(n.itemStyle)},[he(e.$slots,"item",{data:i,index:l},void 0,!0)],46,R7e))),128))]),_:3})])}const Tv=We(P7e,[["render",D7e],["__scopeId","data-v-51d9f44b"]]),V7e={name:"MenuGroupSettings",components:{FluentDnD:Tv,LogoEmojiSelector:xv},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()}}},F7e={key:0,class:"fcom_section_primary"},B7e={class:"fcom_section_primary_item"},z7e={class:"fcom_section_primary_item_title"},j7e={class:"fcom_heading_item"},H7e={class:"fcom_section_item_actions"},U7e={class:"fcom_section_items menu-items-container"},W7e={key:0,style:{padding:"1rem"}},K7e={class:"fcom_section_item_title"},q7e={class:"fcom_heading_item"},G7e=b("div",{class:"fcom_drag_handle"}," ⋮⋮ ",-1),Y7e={key:0,class:"community_avatar"},Z7e=["src"],J7e={key:1,class:"fcom_emoji"},X7e={key:2,class:"fcom_shape"},Q7e=["innerHTML"],exe={class:"fcom_section_item_actions"},txe={key:0},nxe={key:1},oxe={key:0};function rxe(e,t,n,o,r,s){const i=ct,l=Ne,a=gh,u=oe("FluentDnD"),c=oe("logo-emoji-selector"),d=Tt,f=Bn,p=In,h=Fn,m=ta;return C(),T(fe,null,[n.menuItems?(C(),T("div",F7e,[b("div",B7e,[b("div",z7e,[b("div",j7e,[he(e.$slots,"title",{},()=>[b("h4",null,O(n.title),1)])])]),b("div",H7e,[k(i,{class:"fcom_primary_button",onClick:t[0]||(t[0]=y=>s.initEditLink({enabled:"yes",new_tab:"yes"}))},{default:$(()=>[ne(O(e.$t("Add New Link")),1)]),_:1})])]),b("div",U7e,[n.menuItems.length?j("",!0):(C(),T("div",W7e,[b("p",null,O(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",K7e,[b("p",q7e,[n.use_icon_selector?(C(),T(fe,{key:0},[G7e,y.icon_image?(C(),T("div",Y7e,[k(l,null,{default:$(()=>[b("img",{alt:"",style:{"max-width":"16px","max-height":"16px"},src:y.icon_image},null,8,Z7e)]),_:2},1024)])):y.emoji?(C(),T("span",J7e,O(y.emoji),1)):y.shape_svg?(C(),T("span",X7e,[k(l,{innerHTML:y.shape_svg},null,8,["innerHTML"])])):j("",!0)],64)):y.icon_svg?(C(),K(l,{key:1},{default:$(()=>[b("span",{innerHTML:y.icon_svg},null,8,Q7e)]),_:2},1024)):j("",!0),b("span",null,O(y.title),1),y.is_unavailable=="yes"?(C(),K(a,{key:2,type:"danger"},{default:$(()=>[ne(O(e.$t("unavailable")),1)]),_:1})):y.enabled=="yes"?(C(),K(a,{key:3,type:"success"},{default:$(()=>[ne(O(e.$t("enabled")),1)]),_:1})):(C(),K(a,{key:4,type:"info"},{default:$(()=>[ne(O(e.$t("disabled")),1)]),_:1}))])]),b("div",exe,[b("div",null,[k(i,{onClick:w=>s.initEditLink(y),size:"small"},{default:$(()=>[ne(O(e.$t("Edit")),1)]),_:2},1032,["onClick"]),y.is_system!="yes"?(C(),K(i,{key:0,onClick:w=>s.removeLink(v),type:"danger",plain:"",size:"small"},{default:$(()=>[ne(O(e.$t("Delete")),1)]),_:2},1032,["onClick"])):j("",!0)])])]),_:1},8,["items","onDrop"])])])):j("",!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(),T("h4",txe,O(e.$t("Edit Link")),1)):(C(),T("h4",nxe,O(e.$t("Add Custom Link")),1))]),default:$(()=>[r.editingItem?(C(),T("div",oxe,[k(h,{onSubmit:t[8]||(t[8]=Je(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)},Bl({_: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(),K(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"])):j("",!0),n.has_enable_disable?(C(),K(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(O(e.$t("Enable this link")),1)]),_:1},8,["modelValue"])]),_:1})):j("",!0),r.editingItem.is_system?j("",!0):(C(),K(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(O(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(O(e.$t("Save")),1)]),_:1})]),_:1})]),_:1})])):j("",!0)]),_:1},8,["size","modelValue"])],64)}const pL=We(V7e,[["render",rxe]]),sxe={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(/ /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())}}},ixe=["data-ph"];function lxe(e,t,n,o,r,s){return C(),T("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,ixe)}const axe=We(sxe,[["render",lxe]]),uxe={name:"MenuSettings",components:{EditableContentInput:axe,MenuGroupSettings:pL,Layout:$s,AppLayout:Es},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()}},cxe={class:"settings_router"},dxe={key:0},fxe={class:"fcom_card_sections"},pxe={class:"fcom_card_sections"},hxe={class:"fcom_card_sections"},mxe={key:0,class:"fcom_card_sections"},gxe={class:"fcom_section_primary_item"},vxe={class:"fcom_section_primary_item_title"},yxe={class:"fcom_heading_item"},_xe={style:{"justify-content":"center"},class:"fcom_section_primary_item"},bxe={key:1,class:"white_loaded"};function wxe(e,t,n,o,r,s){const i=ct,l=oe("menu-group-settings"),a=Tt,u=Jn,c=oe("layout"),d=oe("app-layout");return C(),K(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,O(e.$t("Save Settings")),1)]),_:1},8,["disabled","onClick"])]),default:$(()=>[b("div",cxe,[r.menuSettings?(C(),T("div",dxe,[b("div",fxe,[r.menuSettings.mainMenuItems?(C(),K(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"])):j("",!0)]),b("div",pxe,[r.menuSettings.profileDropdownItems?(C(),K(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"])):j("",!0)]),b("div",hxe,[r.menuSettings.beforeCommunityMenuItems?(C(),K(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"])):j("",!0)]),r.menuSettings.afterCommunityLinkGroups?(C(),T("div",mxe,[b("div",gxe,[b("div",vxe,[b("div",yxe,[b("h4",null,O(e.$t("Sidebar Bottom Link Groups")),1)])])]),(C(!0),T(fe,null,nt(r.menuSettings.afterCommunityLinkGroups,f=>(C(),T("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(O(e.$t("save")),1)]),_:1},8,["onClick"])]),_:2},1032,["modelValue","onUpdate:modelValue","placeholder"])]),_:2},1032,["title","menuItems"])]))),256)),b("div",_xe,[k(i,{onClick:t[4]||(t[4]=f=>s.addFooterGroup())},{default:$(()=>[ne(O(e.$t("Add Another Group")),1)]),_:1})])])):j("",!0)])):(C(),T("div",bxe,[k(u,{animated:!0,rows:10})]))])]),_:1},8,["title"])]),_:1})}const Cxe=We(uxe,[["render",wxe]]),kxe={name:"SlugInput",emits:["update:modelValue"],props:{modelValue:{type:String,default:""},placeholder:{type:String,default:""},disabled:{type:Boolean,default:!1},is_inital_inactive:{type:Boolean,default:!1},edit_notice:{type:String,default:""},popMessage:{type:String,default:""},prefix:{type:String,default:""}},data(){return{model:this.modelValue,showEdit:this.is_inital_inactive}},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)},confirmEditInit(){this.$messageBox.confirm(this.popMessage,this.$t("Warning"),{confirmButtonText:this.$t("Yes"),cancelButtonText:this.$t("No"),type:"warning"}).then(()=>{this.showEdit=!1,this.$refs.input.focus()})}}},Sxe={key:0,class:"fcom_slug_input_info"},$xe=["innerHTML"];function Exe(e,t,n,o,r,s){const i=ct,l=Tt;return C(),T(fe,null,[k(l,{disabled:n.disabled,readonly:r.showEdit,modelValue:r.model,"onUpdate:modelValue":t[1]||(t[1]=a=>r.model=a),ref:"input",placeholder:n.placeholder,onInput:s.updateSlug},Bl({_:2},[n.prefix?{name:"prepend",fn:$(()=>[b("span",null,O(n.prefix),1)]),key:"0"}:void 0,r.showEdit?{name:"append",fn:$(()=>[k(i,{onClick:t[0]||(t[0]=a=>s.confirmEditInit()),text:"",type:"info"},{default:$(()=>[ne(O(e.$t("change")),1)]),_:1})]),key:"1"}:void 0]),1032,["disabled","readonly","modelValue","placeholder","onInput"]),!r.showEdit&&n.edit_notice?(C(),T("div",Sxe,[b("p",{innerHTML:n.edit_notice},null,8,$xe)])):j("",!0)],64)}const Bh=We(kxe,[["render",Exe]]),xxe={name:"TopicSelector",props:["modelValue","creatable"],emits:["update:modelValue"],components:{SlugInput:Bh},data(){return{topics:[],selected:this.modelValue,loading:!1,creatingTopic:!1,newTopic:{title:"OK"}}},methods:{initCreatetopic(){this.newTopic={title:"",description:"",slug:""}},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})},createTopic(){if(!this.newTopic.title||this.newTopic.title.length<2){this.$notify.error(this.$t("Title must be at least 2 characters long"));return}this.creatingTopic=!0;let e={title:this.newTopic.title,description:this.newTopic.description,slug:this.newTopic.slug,is_inline:!0};this.$post("admin/topics",e).then(t=>{this.$notify.success(t.message),this.fetchTopics(),this.selected.push(t.topic.id),this.$refs.creating_topic_ref.hide()}).catch(t=>{this.$handleError(t)}).finally(()=>{this.creatingTopic=!1})}},watch:{selected(){this.$emit("update:modelValue",this.selected)}},mounted(){this.fetchTopics()}},Txe={class:"fcom_topic_selector"};function Mxe(e,t,n,o,r,s){const i=Ss,l=vr,a=oe("Plus"),u=Ne,c=ct,d=Tt,f=Bn,p=oe("slug-input"),h=Fn,m=bo,y=Dt("loading");return C(),T("div",Txe,[Fe((C(),K(l,{style:{width:"100%"},"multiple-limit":20,modelValue:r.selected,"onUpdate:modelValue":t[0]||(t[0]=v=>r.selected=v),filterable:!0,multiple:!0,clearable:"",placeholder:e.$t("Choose up to 20 topics")},{default:$(()=>[(C(!0),T(fe,null,nt(r.topics,v=>(C(),K(i,{key:v.slug,label:v.title,value:v.id},{default:$(()=>[b("span",null,O(v.title),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])),[[y,r.loading]]),n.creatable?(C(),K(m,{key:0,ref:"creating_topic_ref",onShow:s.initCreatetopic,placement:"bottom",width:400,trigger:"click"},{reference:$(()=>[k(c,null,{default:$(()=>[k(u,null,{default:$(()=>[k(a)]),_:1}),b("span",null,O(e.$t("New")),1)]),_:1})]),default:$(()=>[k(h,{modelValue:r.newTopic,"onUpdate:modelValue":t[5]||(t[5]=v=>r.newTopic=v),"label-position":"top"},{default:$(()=>[k(f,{label:e.$t("Title")},{default:$(()=>[k(d,{modelValue:r.newTopic.title,"onUpdate:modelValue":t[1]||(t[1]=v=>r.newTopic.title=v),placeholder:e.$t("Title of the topic")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),k(f,{label:e.$t("Slug (optional)")},{default:$(()=>[k(p,{modelValue:r.newTopic.slug,"onUpdate:modelValue":t[2]||(t[2]=v=>r.newTopic.slug=v),placeholder:e.$t("Slug of the topic")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),k(f,{label:e.$t("Description (optional)")},{default:$(()=>[k(d,{modelValue:r.newTopic.description,"onUpdate:modelValue":t[3]||(t[3]=v=>r.newTopic.description=v),type:"textarea",rows:3,placeholder:e.$t("Description of the topic")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),k(f,null,{default:$(()=>[k(c,{type:"primary",onClick:t[4]||(t[4]=v=>s.createTopic()),loading:r.creatingTopic},{default:$(()=>[ne(O(e.$t("Create")),1)]),_:1},8,["loading"])]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["onShow"])):j("",!0)])}const hL=We(xxe,[["render",Mxe]]),Oxe={name:"CreateSpaceForm",emits:["completed"],components:{SlugInput:Bh,ImageUploader:Td,LogoEmojiSelector:xv,TopicSelector:hL},props:{community:{required:!1,default:null},parent_id:{required:!1,default:null},savingCount:{required:!1,default:0}},data(){return{saving:!1,privacies:R1e,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",members_page_status:"members_only"},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}},Ixe={key:0},Axe={style:{"font-weight":"bold"}},Nxe=["innerHTML"],Pxe={key:0},Lxe={class:"fcom_lined_checkboxes"},Rxe={class:"fcom_help_text"},Dxe={class:"fcom_help_text"},Vxe=["href"],Fxe={class:"fcom_help_text"},Bxe={class:"fcom_help_text"},zxe={key:0},jxe={key:1},Hxe={class:"fcom_space_form_bottom"};function Uxe(e,t,n,o,r,s){const i=oe("logo-emoji-selector"),l=Tt,a=Bn,u=oe("SlugInput"),c=Ss,d=vr,f=mh,p=ea,h=In,m=oe("topic-selector"),y=Ed,v=oe("ImageUploader"),w=ct,_=Fn,S=Dt("loading");return C(),K(_,{onSubmit:t[18]||(t[18]=Je(x=>e.doNothing(),["prevent"])),modelValue:r.form,"onUpdate:modelValue":t[19]||(t[19]=x=>r.form=x),"label-position":"top",class:"fcom_space_form"},{default:$(()=>[r.showingSections.indexOf("basic")!==-1?(C(),T(fe,{key:0},[r.form.id?j("",!0):(C(),T("h4",Ixe,O(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(),K(i,{key:0,custom_svg:!0,onUpdate:t[0]||(t[0]=M=>{r.form.settings.emoji=M.emoji,r.form.logo=M.logo,r.form.settings.shape_svg=M.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"])):j("",!0)]}),_:1},8,["placeholder","modelValue"])]),_:1},8,["label"]),r.dataLoaded?(C(),K(a,{key:1,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"])):j("",!0),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),T(fe,null,nt(r.privacies,(x,E)=>(C(),K(c,{key:E,label:x.label,value:E},{default:$(()=>[b("span",Axe,O(e.$labelize(x.label)),1),b("p",{innerHTML:x.description},null,8,Nxe)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),r.form.privacy=="private"?(C(),K(a,{key:2,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(O(e.$t("Custom Lock Screen")),1)]),_:1}),k(f,{value:"no"},{default:$(()=>[ne(O(e.$t("Default Lock Screen")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["label"])):j("",!0),r.form.settings.custom_lock_screen=="no"&&r.form.privacy!="secret"?(C(),K(a,{key:3},{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(O(e.$t("Allow users to request to join this Space")),1)]),_:1},8,["modelValue"])]),_:1})):j("",!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),T(fe,null,nt(e.appVars.space_groups,x=>(C(),K(c,{key:x.id,value:x.id.toString(),label:x.title},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])]),_:1},8,["label"]),r.form.privacy!="secret"?(C(),K(a,{key:4,label:e.$t("Who can view space members")},{default:$(()=>[k(d,{modelValue:r.form.settings.members_page_status,"onUpdate:modelValue":t[8]||(t[8]=x=>r.form.settings.members_page_status=x)},{default:$(()=>[k(c,{value:"members_only",label:e.$t("Members Only")},null,8,["label"]),k(c,{value:"admin_only",label:e.$t("Admin/Moderators Only")},null,8,["label"]),k(c,{value:"logged_in",label:e.$t("Any Logged in users")},null,8,["label"]),k(c,{value:"everybody",label:e.$t("Anyone")},null,8,["label"])]),_:1},8,["modelValue"])]),_:1},8,["label"])):j("",!0)],64)):j("",!0),r.showingSections.indexOf("customization")!==-1?(C(),T(fe,{key:1},[r.form.id?j("",!0):(C(),T("h4",Pxe,O(e.$t("Customization")),1)),r.form.settings?(C(),K(a,{key:1,label:e.$t("Features Customizations")},{default:$(()=>[b("div",Lxe,[k(h,{"true-value":"yes","false-value":"no",modelValue:r.form.settings.restricted_post_only,"onUpdate:modelValue":t[9]||(t[9]=x=>r.form.settings.restricted_post_only=x)},{default:$(()=>[ne(O(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[10]||(t[10]=x=>r.form.settings.show_sidebar=x)},{default:$(()=>[ne(O(e.$t("Show Right Sidebar on Space")),1)]),_:1},8,["modelValue"])])]),_:1},8,["label"])):j("",!0),k(a,{label:e.$t("Default layout styles")},{default:$(()=>[k(p,{modelValue:r.form.settings.layout_style,"onUpdate:modelValue":t[11]||(t[11]=x=>r.form.settings.layout_style=x)},{default:$(()=>[k(f,{value:"timeline"},{default:$(()=>[ne(O(e.$t("Timeline")),1)]),_:1}),k(f,{value:"list"},{default:$(()=>[ne(O(e.$t("List")),1)]),_:1})]),_:1},8,["modelValue"]),b("div",Rxe,[b("p",null,O(e.$t("User can change the layout style for their own preference")),1)])]),_:1},8,["label"]),e.has_pro&&r.form.id?(C(),K(a,{key:2,label:e.$t("Topic navigation")},{default:$(()=>[k(m,{creatable:!0,space_id:r.form.id,modelValue:r.form.topic_ids,"onUpdate:modelValue":t[12]||(t[12]=x=>r.form.topic_ids=x)},null,8,["space_id","modelValue"]),b("div",Dxe,[b("p",null,[ne(O(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")},O(e.$t("Manage all topics.")),9,Vxe)])])]),_:1},8,["label"])):j("",!0),e.appVars.has_chat?(C(),K(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[13]||(t[13]=x=>r.form.group_chat_support=x)},{default:$(()=>[ne(O(e.$t("Enable group chat for this space members")),1)]),_:1},8,["modelValue"])]),_:1},8,["label"])):j("",!0),k(a,{label:e.$t("Thumbnail / Open Graph Image (Recommended Size: 1200 x 630)")},{default:$(()=>[r.form.settings.og_image?(C(),K(y,{key:0,alt:e.$t("Thumbnail / Open Graph Image"),src:r.form.settings.og_image,style:{"max-width":"100px"}},null,8,["alt","src"])):j("",!0),k(v,{isTextBtn:!1,can_remove:!!r.form.settings.og_image,additionalData:{resize:!0,max_width:1200,max_height:630},onUploaded:t[14]||(t[14]=x=>{r.form.settings.og_image=x})},null,8,["can_remove"]),b("div",Fxe,[b("p",null,O(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(),K(y,{key:0,alt:e.$t("Featured Image Preview"),src:r.form.cover_photo,style:{"max-width":"100px"}},null,8,["alt","src"])):j("",!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",Bxe,[b("p",null,O(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(),K(w,{key:0,class:"plain_button",text:"",onClick:t[15]||(t[15]=()=>{r.showingSections=["basic"]})},{default:$(()=>[b("span",null,O(e.$t("Go Back")),1)]),_:1})):j("",!0),Fe((C(),K(w,{class:"fcom_primary_button",disabled:r.saving,onClick:t[16]||(t[16]=x=>s.submit())},{default:$(()=>[r.form.id?(C(),T("span",zxe,O(e.$t("Update Info")),1)):(C(),T("span",jxe,O(e.$t("Create")),1))]),_:1},8,["disabled"])),[[S,r.saving]])]),_:1})],64)):(C(),K(a,{key:2},{default:$(()=>[b("div",Hxe,[k(w,{onClick:t[17]||(t[17]=()=>{r.showingSections=["customization"]}),class:"fcom_primary_button"},{default:$(()=>[b("span",null,O(e.$t("Continue")),1)]),_:1})])]),_:1}))]),_:1},8,["modelValue"])}const Wxe=We(Oxe,[["render",Uxe]]),Kxe={name:"CreateGroupForm",emits:["completed"],components:{ImageUploader:Td},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"}}}},qxe=b("span",null,"#",-1),Gxe={key:0},Yxe={key:1};function Zxe(e,t,n,o,r,s){const i=Tt,l=Bn,a=In,u=ct,c=Fn,d=Dt("loading");return C(),K(c,{onSubmit:t[5]||(t[5]=Je(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:$(()=>[qxe]),_: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(),K(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(O(e.$t("Show Spaces even if the user is not a member of any space")),1)]),_:1},8,["modelValue"])]),_:1},8,["label"])):j("",!0),k(l,null,{default:$(()=>[Fe((C(),K(u,{class:"fcom_primary_button",disabled:r.saving,onClick:t[4]||(t[4]=f=>s.submit())},{default:$(()=>[r.form.id?(C(),T("span",Gxe,O(e.$t("Update Info")),1)):(C(),T("span",Yxe,O(e.$t("Create")),1))]),_:1},8,["disabled"])),[[d,r.saving]])]),_:1})]),_:1},8,["modelValue"])}const Jxe=We(Kxe,[["render",Zxe]]),Xxe={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 Qxe(e,t,n,o,r,s){const i=oe("MoreFilled"),l=Ne,a=ct,u=Ss,c=vr,d=Bn,f=Fn,p=bo,h=Dt("loading");return C(),K(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]=Je(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),T(fe,null,nt(s.filteredGroups,m=>(C(),K(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:$(()=>[Fe((C(),K(a,{disabled:!r.selectedGroupId||r.working,onClick:s.moveSpace,class:"fcom_primary_button"},{default:$(()=>[ne(O(e.$t("Move Space")),1)]),_:1},8,["disabled","onClick"])),[[h,r.working]])]),_:1})]),_:1})]),_:1},8,["visible"])}const eTe=We(Xxe,[["render",Qxe]]),tTe={name:"AllCommunities",components:{FluentDnD:Tv,CreateSpaceForm:Wxe,CreateGroupForm:Jxe,Layout:$s,AppLayout:Es,MoveGroupPopup:eTe},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={};du(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=[];du(o,(i,l)=>{s.push(i.id)}),this.resetSpaceIndexes(s),this.draggingIndexSpace=null}},mounted(){this.getGroups()}},nTe={class:"settings_router"},oTe={class:"fcom_communities"},rTe={class:"fcom_card_sections"},sTe={class:"fcom_card_section_heading"},iTe={class:"fcom_section_primary_item"},lTe={class:"fcom_section_primary_item_title"},aTe=b("div",{class:"fcom_drag_handle"}," ⋮⋮ ",-1),uTe={class:"fcom_heading_item"},cTe={class:"fcom_section_item_actions"},dTe={class:"fcom_section_items"},fTe={class:"fcom_section_item_title"},pTe=b("div",{class:"fcom_drag_handle"}," ⋮⋮ ",-1),hTe={class:"fcom_heading_item"},mTe={class:"fcom_section_item_actions"},gTe=["href"];function vTe(e,t,n,o,r,s){const i=ct,l=Jn,a=gh,u=oe("MoveGroupPopup"),c=oe("FluentDnD"),d=oe("layout"),f=oe("app-layout"),p=oe("create-group-form"),h=ta,m=Dt("loading");return C(),T(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(O(e.$t("Create New Group")),1)]),_:1})]),default:$(()=>[b("div",nTe,[Fe((C(),T("div",oTe,[b("div",rTe,[Fe((C(),T("div",sTe,[b("h3",null,O(e.$_n("%d Group","%d Groups",r.groups.length))+" • "+O(e.$_n("%d Space","%d Spaces",s.communityCounts)),1)])),[[m,r.loading]]),r.loading?(C(),K(l,{key:0,animated:!0,row:5})):j("",!0),k(c,{items:r.groups,onDrop:s.dropGroup},{item:$(({data:y})=>[b("div",iTe,[b("div",lTe,[aTe,b("div",uTe,[b("h4",null,O(e.$t("Group:"))+" "+O(y.title),1)])]),b("div",cTe,[k(i,{class:"fcom_secondary_button",onClick:v=>s.initEditGroup(y)},{default:$(()=>[ne(O(e.$t("Edit Info")),1)]),_:2},1032,["onClick"]),k(i,{onClick:v=>s.removeGroup(y),type:"danger",plain:""},{default:$(()=>[ne(O(e.$t("Delete")),1)]),_:2},1032,["onClick"])])]),b("div",dTe,[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",fTe,[pTe,b("p",hTe,[ne(O(v.title)+" ",1),v.status!="published"?(C(),K(a,{key:0,type:"info"},{default:$(()=>[ne(O(e.$labelize(v.status)),1)]),_:2},1024)):j("",!0),k(a,null,{default:$(()=>[ne(O(s.getTypeTitle(v.type)),1)]),_:2},1024)])]),b("div",mTe,[b("a",{class:"el-button el-button--small el-button--secondary",href:v.permalink},O(e.$t("View")),9,gTe),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,O(e.$t("Create a new Group")),1)]),default:$(()=>[r.createGroupModal?(C(),K(p,{key:0,group:r.editingGroup,onCompleted:t[2]||(t[2]=y=>{r.createGroupModal=!1,s.getGroups()})},null,8,["group"])):j("",!0)]),_:1},8,["size","modelValue"])],64)}const yTe=We(tTe,[["render",vTe]]),_Te={name:"CreateSpaceForm",components:{TopicSelector:hL,SlugInput:Bh,ImageUploader:Td,LogoEmojiSelector:xv},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:D1e,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:V1e,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}},bTe={style:{"font-weight":"bold"}},wTe={style:{"font-weight":"bold"}},CTe={class:"fcom_help_text"},kTe=["href"],STe={class:"fcom_help_text"},$Te={key:0},ETe={key:1},xTe={key:1},TTe=["href"];function MTe(e,t,n,o,r,s){const i=oe("logo-emoji-selector"),l=Tt,a=Bn,u=oe("SlugInput"),c=Ss,d=vr,f=mh,p=ea,h=oe("topic-selector"),m=Ed,y=oe("ImageUploader"),v=ct,w=Fn,_=Dt("loading");return e.hasFeature("has_course")?(C(),K(w,{key:0,onSubmit:t[11]||(t[11]=Je(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(),K(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"])):j("",!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,O(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),T(fe,null,nt(r.privacies,(S,x)=>(C(),K(c,{key:x,label:S.label,value:x},{default:$(()=>[b("span",bTe,O(S.label),1),b("p",null,O(S.description),1)]),_:2},1032,["label","value"]))),128))]),_:1},8,["modelValue","placeholder"])]),_:1},8,["label"]),r.form.privacy!="public"?(C(),K(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(O(e.$t("Custom")),1)]),_:1}),k(f,{value:"no"},{default:$(()=>[ne(O(e.$t("Default")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["label"])):j("",!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),T(fe,null,nt(e.appVars.space_groups,S=>(C(),K(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),T(fe,null,nt(r.courseTypes,(S,x)=>(C(),K(c,{key:x,label:S.label,value:x},{default:$(()=>[b("span",wTe,O(S.label),1),b("p",null,O(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(O(e.$t("Published")),1)]),_:1}),k(f,{value:"draft"},{default:$(()=>[ne(O(e.$t("Draft")),1)]),_:1})]),_:1},8,["modelValue"])]),_:1},8,["label"]),e.has_pro&&r.form.id?(C(),K(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",CTe,[b("p",null,[ne(O(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")},O(e.$t("Manage all topics.")),9,kTe)])])]),_:1},8,["label"])):j("",!0),k(a,{label:e.$t("Thumbnail / Open Graph Image (Recommended Size: 1200 x 630)")},{default:$(()=>[r.form.cover_photo?(C(),K(m,{key:0,alt:e.$t("Cover Photo"),src:r.form.cover_photo,style:{"max-width":"100px"}},null,8,["alt","src"])):j("",!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",STe,[b("p",null,O(e.$t("Will be used on course card preview and social sharing preview.")),1)])]),_:1},8,["label"]),k(a,null,{default:$(()=>[Fe((C(),K(v,{class:"fcom_primary_button",disabled:r.saving,onClick:t[10]||(t[10]=S=>s.submit())},{default:$(()=>[r.form.id?(C(),T("span",$Te,O(e.$t("Update Info")),1)):(C(),T("span",ETe,O(e.$t("Create")),1))]),_:1},8,["disabled"])),[[_,r.saving]])]),_:1})]),_:1},8,["modelValue"])):(C(),T("div",xTe,[b("p",null,O(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")},O(e.$t("Go to features settings")),9,TTe)]))}const mL=We(_Te,[["render",MTe]]),OTe={name:"GroupIcon"},ITe={width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},ATe=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),NTe=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),PTe=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),LTe=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),RTe=[ATe,NTe,PTe,LTe];function DTe(e,t,n,o,r,s){return C(),T("svg",ITe,RTe)}const VTe=We(OTe,[["render",DTe]]),FTe={name:"ManageCourses",components:{CreateCourseForm:mL,AppLayout:Es,Layout:$s,GroupIcon:VTe},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()}},BTe={class:"fcom_courses"},zTe={class:"fcom_box_card_list"},jTe=["onClick"],HTe=["src"],UTe={key:1,class:"fcom_no_image"},WTe={class:"fcom_box_card_info"},KTe={class:"fcom_box_card_name"},qTe={class:"fcom_box_card_by"},GTe={class:"fcom_box_card_details"},YTe={class:"inline_details"},ZTe=b("span",{class:"fcom_inline_separator"},null,-1),JTe={class:"inline_details"},XTe={key:0,class:"fcom_box_card_description"},QTe={class:"fcom_box_card_action"},eMe=["onClick"];function tMe(e,t,n,o,r,s){const i=ct,l=gh,a=oe("router-link"),u=oe("GroupIcon"),c=Ne,d=oe("layout"),f=oe("app-layout"),p=oe("create-course-form"),h=ta,m=Dt("loading");return C(),T(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(O(e.$t("Add Course")),1)]),_:1})]),default:$(()=>[Fe((C(),T("div",BTe,[b("div",zTe,[(C(!0),T(fe,null,nt(r.courses,y=>(C(),T("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(),T("img",{key:0,src:y.cover_photo,alt:""},null,8,HTe)):(C(),T("div",UTe))],8,jTe),b("div",WTe,[b("div",KTe,[k(a,{class:"course_route",to:{name:"edit_lessons",params:{course_id:y.id}}},{default:$(()=>[ne(O(s.getExcerpt(y.title,20))+" ",1),y.status=="draft"?(C(),K(l,{key:0,type:"info"},{default:$(()=>[ne(O(y.status),1)]),_:2},1024)):j("",!0)]),_:2},1032,["to"]),b("span",qTe,O(e.$t("by %s",y==null?void 0:y.owner.display_name)),1)]),b("div",GTe,[b("div",YTe,[b("span",null,O(e.$_n("%d Section","%d Sections",y.sectionsCount)),1),ZTe,b("span",null,O(e.$_n("%d Lesson","%d Lessons",y.lessonsCount)),1)]),b("div",JTe,[k(c,null,{default:$(()=>[k(u)]),_:1}),ne(" "+O(e.$_n("%d student","%d students",y.students_count||0)),1)])]),y.description?(C(),T("div",XTe,O(s.getExcerpt(y.description,40)),1)):j("",!0),b("div",QTe,[b("button",{class:"fcom_card_button",onClick:v=>s.navigateToEditLessons(y.id)},O(e.$t("Manage")),9,eMe)])])]))),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,O(e.$t("Create a new course")),1)]),default:$(()=>[r.newCourseModal?(C(),K(p,{key:0,onCompleted:t[1]||(t[1]=y=>{r.newCourseModal=!1})})):j("",!0)]),_:1},8,["size","modelValue"])],64)}const nMe=We(FTe,[["render",tMe]]),oMe={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 rMe(e,t,n,o,r,s){const i=Ed,l=ct,a=FO,u=oe("CloseBold"),c=Ne;return C(),T(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(),K(i,{key:0,alt:e.$t("Image Preview"),src:r.imageUrl},null,8,["alt","src"])):(C(),K(l,{key:1,class:"fcom_btn_upload",text:""},{default:$(()=>[ne(O(n.button_text),1)]),_:1}))])])]),_:3},8,["action","headers","multiple","data","on-success","on-error"]),r.imageUrl&&n.can_remove?(C(),K(l,{key:0,class:"fcom_bg_remove",text:"",size:"small",onClick:s.removeImage},{default:$(()=>[k(c,null,{default:$(()=>[k(u)]),_:1})]),_:1},8,["onClick"])):j("",!0)],64)}const sMe=We(oMe,[["render",rMe]]),iMe={name:"LockscreenMeta",components:{BgImageUpload:sMe},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}}},lMe={key:0,class:"fcom_lockscreen_meta"},aMe={class:"fcom_meta_section lockscreen_meta"},uMe={class:"fcom_description"},cMe={class:"fcom_meta_section lockscreen_meta"},dMe={class:"fcom_meta_label"},fMe={class:"fcom_meta_content"},pMe={class:"fcom_meta_block"},hMe={class:"fcom_block_label"},mMe={class:"fcom_meta_sorting"},gMe={class:"fcom_block_action"},vMe={key:1,class:"fcom_lockscreen_meta"},yMe={class:"fcom_edit_title"},_Me={class:"fcom_edit_content"},bMe={class:"fcom_color_input_wrap"},wMe={class:"fcom_color_input_wrap"},CMe={class:"fcom_color_input_wrap"},kMe={class:"fcom_color_input_wrap"},SMe={class:"fcom_color_input_wrap"},$Me={key:1,class:"fcom_description"};function EMe(e,t,n,o,r,s){const i=Ne,l=oe("Top"),a=oe("Bottom"),u=oe("EditPen"),c=oe("Hide"),d=oe("View"),f=oe("Back"),p=Tt,h=Bn,m=Fn,y=NO,v=oe("BgImageUpload"),w=D3,_=AO;return r.editing?(C(),T("div",vMe,[b("div",yMe,[k(i,{onClick:s.backToFields},{default:$(()=>[k(f)]),_:1},8,["onClick"]),b("p",null,O(r.editingField.label),1)]),b("div",_Me,[r.editingField.type=="image"?(C(),K(_,{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]=Je(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]=Je(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",bMe,[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",wMe,[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",CMe,[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",kMe,[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",SMe,[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(),T("div",$Me,O(e.$t("Edit the field from block editor ")),1)):j("",!0)])])):(C(),T("div",lMe,[b("div",aMe,[b("div",uMe,[b("p",null,O(e.$t("This page is only visible to non-members viewing a private space.")),1)])]),b("div",cMe,[b("div",dMe,O(e.$t("Page Blocks")),1),b("div",fMe,[b("ul",pMe,[(C(!0),T(fe,null,nt(s.lockscreenFields,(S,x)=>(C(),T("li",{class:D(["fcom_block_list",{block_hidden:S.hidden}])},[b("div",hMe,[k(i,{class:"fcom_el_icon"},{default:$(()=>[(C(),K(Lt(s.getFieldIcon(S))))]),_:2},1024),b("p",null,O(S.label),1)]),b("div",mMe,[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",gMe,[k(i,{onClick:E=>s.updateField(S)},{default:$(()=>[k(u)]),_:2},1032,["onClick"]),S.hidden?(C(),K(i,{key:0,onClick:E=>s.toggleHidden(S)},{default:$(()=>[k(c)]),_:2},1032,["onClick"])):(C(),K(i,{key:1,onClick:E=>s.toggleHidden(S)},{default:$(()=>[k(d)]),_:2},1032,["onClick"]))])],2))),256))])])])]))}const xMe=We(iMe,[["render",EMe]]),TMe={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)}},MMe={class:"fcom_block_editor"};function OMe(e,t,n,o,r,s){const i=Jn;return C(),T("div",MMe,[Fe(b("div",null,[b("textarea",{ref:"block_editor",id:"fcom_block_editor",name:"block_editor"},O(r.html),513)],512),[[en,r.all_loaded]]),r.all_loaded?j("",!0):(C(),K(i,{key:0,class:"white_loaded",rows:7,animated:!0}))])}const gL=We(TMe,[["render",OMe]]),IMe={name:"MediaPreview",components:{Postcard:KZ},props:["feed","media_item"],computed:{media(){return this.feed?this.feed.meta.media_preview:this.media_item}},data(){return{is_error:!1}},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 16/9},handleImageError(){this.is_error=!0}}},AMe={key:0},NMe=["innerHTML"],PMe=["href"],LMe={key:0,class:"feed_media_image"},RMe=b("span",null,null,-1),DMe={key:1,class:"feed_media_content"},VMe={class:"media_domain"},FMe={class:"feed_media_title"},BMe={key:0,class:"feed_media_description"},zMe={class:"feed_meta_desc"};function jMe(e,t,n,o,r,s){const i=Jn,l=Ed;return C(),T("div",{class:D(["feed_media","feed_media_"+s.media.type])},[s.media.type=="oembed"||s.media.type=="iframe_html"?(C(),T(fe,{key:0},[s.media.content_type=="video"?(C(),T("div",AMe,[b("div",{class:"feed_media_ext_video",innerHTML:s.media.html},null,8,NMe)])):j("",!0)],64)):s.media.type=="image"||s.media.is_uploaded?(C(),T("div",{key:1,class:D(["feed_media_provider_"+s.media.provider,"feed_media_image feed_custom_uploaded"])},[s.media.image&&!r.is_error?(C(),K(l,{key:0,alt:"",style:et({width:"100%",aspectRatio:s.getAspectRatio(s.media.width,s.media.height)}),src:s.media.image,lazy:!0,previewSrcList:[s.media.image],loading:"lazy",onError:s.handleImageError,"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","onError","class"])):j("",!0)],2)):(C(),T("a",{key:2,href:s.media.url,target:"_blank",rel:"noopener",class:"feed_media_link"},[s.media.image&&!r.is_error?(C(),T("div",LMe,[k(l,{onError:t[0]||(t[0]=a=>s.handleImageError()),style:{width:"100%"},src:s.media.image},{error:$(()=>[RMe]),_:1},8,["src"])])):j("",!0),s.media.title?(C(),T("div",DMe,[b("div",VMe,O(s.getDomainName(s.media.url)),1),b("div",FMe,O(e.getExcerpt(s.media.title,88)),1),s.media.description?(C(),T("div",BMe,[b("div",zMe,O(e.getExcerpt(s.media.description,160)),1)])):j("",!0)])):j("",!0)],8,PMe))],2)}const Mv=We(IMe,[["render",jMe]]),HMe={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()}},UMe={key:0},WMe={key:0,class:"fcom_media_editor_actions"},KMe={key:1,class:"fcom_media_editor fcom_media_embeder"},qMe={key:2,class:"fcom_course_media"};function GMe(e,t,n,o,r,s){const i=ct,l=R3,a=ea,u=Tt,c=oe("media-preview"),d=Dt("loading");return r.appReady?Fe((C(),T("div",UMe,[n.has_iframe?(C(),T("div",WMe,[s.showPreview?(C(),K(i,{key:0,onClick:t[0]||(t[0]=f=>r.showInput=!0),type:"danger",size:"small",text:""},{default:$(()=>[ne(O(e.$t("Edit media")),1)]),_:1})):(C(),K(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"]))])):j("",!0),s.showPreview?(C(),T("div",qMe,[k(c,{media_item:n.media},null,8,["media_item"])])):(C(),T("div",KMe,[n.media.type=="iframe_html"&&n.has_iframe?(C(),T(fe,{key:0},[b("h3",null,O(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(O(e.$t("Embed")),1)]),_:1})],64)):(C(),T(fe,{key:1},[b("h3",null,O(n.box_title||e.$t("Featured media")),1),b("p",null,O(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(O(e.$t("Embed")),1)]),_:1},8,["onClick"])]),_:1},8,["modelValue","placeholder"])],64))]))])),[[d,r.fetching]]):j("",!0)}const Lk=We(HMe,[["render",GMe]]),YMe={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)}}},ZMe={class:"fcom_course_sections"},JMe={class:"fcom_course_intro"},XMe={class:"fcom_course_labels"},QMe={class:"fcom_course_info"},eOe=b("span",null," • ",-1),tOe={class:"fcom_card_sections"},nOe={class:"fcom_section_items"},oOe={key:0,class:"fcom_section_primary_item"},rOe={class:"fcom_section_primary_item_title"},sOe={class:"fcom_section_primary_item_actions"},iOe={class:"fcom_meta_text"},lOe={class:"fcom_section_item_title"},aOe={class:"fcom_heading_item clickable"};function uOe(e,t,n,o,r,s){const i=oe("ArrowRight"),l=oe("ArrowDown"),a=Ne,u=oe("Lock");return C(),T("div",ZMe,[b("div",JMe,[b("div",XMe,[b("h3",null,O(e.$t("Course content")),1),b("p",QMe,[ne(O(e.$t("%s topics",s.sectionsCount))+" ",1),eOe,ne(" "+O(e.$t("%s lessons",s.lessonsCount)),1)])])]),b("div",tOe,[b("div",nOe,[(C(!0),T(fe,null,nt(n.sections,c=>(C(),T("div",{key:c.id,class:"fcom_section_primary"},[c.lessons.length?(C(),T("div",oOe,[b("div",rOe,[k(a,{class:"clickable",onClick:d=>c.is_closed=!c.is_closed},{default:$(()=>[c.is_closed?(C(),K(i,{key:0})):(C(),K(l,{key:1}))]),_:2},1032,["onClick"]),b("h4",null,O(c.title),1)]),b("div",sOe,[b("span",iOe,O(e.$t("%d lessons",c.lessons.length)),1)])])):j("",!0),c.is_closed?j("",!0):(C(!0),T(fe,{key:1},nt(c.lessons,d=>(C(),T("div",{key:d.id,class:"fcom_section_item"},[b("div",lOe,[b("p",aOe,[k(a,null,{default:$(()=>[k(u)]),_:1}),ne(" "+O(d.title),1)])])]))),128))]))),128))])])])}const cOe=We(YMe,[["render",uOe]]),dOe={name:"LockScreenEditor",props:["title","lockscreen","sections","saving","loading"],emits:["save","close"],components:{LessonEditor:cOe,MediaEmbeder:Lk,BlockEditor:gL,LockscreenMeta:xMe},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")}}},fOe={class:"fcom_editor_topbar"},pOe={class:"fcom_editor_content"},hOe={class:"fcom_item"},mOe={class:"fcom_content"},gOe=["onInput"],vOe=["onInput"],yOe=["onInput"],_Oe={key:1,class:"fcom_content_wrap"},bOe={key:0,id:"fcomBlockContent"},wOe=["onClick","innerHTML"],COe={key:2,class:"fcom_content_wrap"};function kOe(e,t,n,o,r,s){const i=oe("lockscreen-meta"),l=jM,a=oe("Lock"),u=Ne,c=oe("block-editor"),d=oe("lesson-editor"),f=Jn,p=ks,h=K0;return C(),T(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",fOe,[k(u,null,{default:$(()=>[k(a)]),_:1}),b("h3",null,O(n.title),1)]),b("div",pOe,[(C(!0),T(fe,null,nt(s.lockscreenFields,m=>{var y;return C(),T("div",hOe,[m.type=="image"?(C(),T("div",{key:0,class:"fcom_image_wrap",style:et(s.imageStyles(m))},[b("div",mOe,[b("h2",{style:et(s.headingStyles(m)),contenteditable:"true",onInput:v=>s.updateHeading(v,m)},O(m.heading),45,gOe),b("p",{style:et(s.descriptionStyles(m)),contenteditable:"true",onInput:v=>s.updateDescription(v,m)},O(m.description),45,vOe),b("button",{class:"fcom_btn",style:et(s.buttonStyles(m)),contenteditable:"true",onInput:v=>s.updateButtonLabel(v,m)},O(m.button_text),45,yOe)])],4)):j("",!0),m.type=="block"?(C(),T("div",_Oe,[((y=r.editingField)==null?void 0:y.type)=="block"?(C(),T("div",bOe,[k(c,{modelValue:m.content,"onUpdate:modelValue":v=>m.content=v},null,8,["modelValue","onUpdate:modelValue"])])):(C(),T("div",{key:1,onClick:v=>s.visibleBlock(m),innerHTML:m.content},null,8,wOe))])):j("",!0),m.type=="lesson"?(C(),T("div",COe,[n.loading?(C(),K(f,{key:1,rows:5,animated:!0})):(C(),K(d,{key:0,sections:n.sections},null,8,["sections"]))])):j("",!0)])}),256))])]),_:1})]),_:1})],64)}const SOe=We(dOe,[["render",kOe]]),$Oe={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()}},EOe={key:0,class:"fcom_lockscreen_meta"},xOe={class:"fcom_description"};function TOe(e,t,n,o,r,s){const i=oe("lock-screen-editor");return r.lockscreen?(C(),K(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(),T("div",EOe,[b("div",xOe,[b("p",null,O(e.$t("__LOCK_SCRREN_DESC")),1)])])):j("",!0)]),_:1},8,["title","lockscreen","sections","saving","loading","onSave"])):j("",!0)}const MOe=We($Oe,[["render",TOe]]),OOe={name:"ManageSpaceLinks",components:{MenuGroupSettings:pL},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})}}},IOe={style:{"max-width":"800px",padding:"20px",margin:"0 auto"}},AOe={class:"fcom_card_sections"};function NOe(e,t,n,o,r,s){const i=oe("menu-group-settings"),l=ks,a=K0;return C(),K(a,{class:"fcom_full_editor_main lockscreen_editor"},{default:$(()=>[k(l,null,{default:$(()=>[b("div",IOe,[b("div",AOe,[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 POe=We(OOe,[["render",NOe]]),LOe={name:"SpaceCustomizer",props:["course"],emits:["close","completed"],components:{ManageSpaceLinks:POe,CourseLockscreen:MOe,CreateCourseForm:mL},data(){return{saving:!1,currentTab:"general",savingCount:0}},methods:{saveChanges(){this.savingCount=this.savingCount+1}}},ROe={key:0,class:"fcom_full_editor"},DOe={class:"fcom_full_editor_header"},VOe={class:"fcom_editor_menu object_menu"},FOe={class:"fcom_space_menu_ul"},BOe={class:"full_editor_actions"},zOe={style:{"max-width":"600px",padding:"20px",margin:"0 auto"}};function jOe(e,t,n,o,r,s){const i=oe("ArrowLeft"),l=Ne,a=ct,u=HM,c=oe("create-course-form"),d=ks,f=K0,p=oe("course-lockscreen"),h=oe("manage-space-links"),m=zM,y=Dt("loading");return n.course.id?(C(),T("div",ROe,[k(m,null,{default:$(()=>[k(u,{class:"fcom_full_editor_header_wrap"},{default:$(()=>[b("div",DOe,[b("div",{onClick:t[0]||(t[0]=v=>e.$emit("completed")),class:"fcom_back_header"},[k(l,null,{default:$(()=>[k(i)]),_:1}),ne(" "+O(n.course.title),1)]),b("div",VOe,[b("ul",FOe,[b("li",{onClick:t[1]||(t[1]=v=>r.currentTab="general")},[b("a",{class:D({"router-link-exact-active":r.currentTab==="general"}),href:"#"},O(e.$t("General Settings")),3)]),n.course.privacy=="private"?(C(),T("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:"#"},O(e.$t("Lock Screen")),3)])):j("",!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:"#"},O(e.$t("Course Links")),3)])])]),b("div",BOe,[Fe((C(),K(a,{class:"fcom_primary_button",disabled:r.saving,onClick:s.saveChanges,bg:""},{default:$(()=>[ne(O(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(),K(f,{key:0,class:"fcom_full_editor_main lockscreen_editor"},{default:$(()=>[k(d,null,{default:$(()=>[b("div",zOe,[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(),K(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(),K(h,{key:2,savingCount:r.savingCount,onClose:t[6]||(t[6]=v=>e.$emit("close")),spaceProfile:n.course},null,8,["savingCount","spaceProfile"])):j("",!0)]),_:1})]),_:1})])):j("",!0)}const HOe=We(LOe,[["render",jOe]]),UOe={name:"EditCourseRoute",components:{CourseCustomizer:HOe,AppLayout:Es,Layout:$s},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()}},WOe={class:"object_menu"},KOe={class:"fcom_space_menu_ul"},qOe={class:"actions_items"},GOe={key:0,class:"white_loaded"},YOe={key:2},ZOe={key:0};function JOe(e,t,n,o,r,s){const i=dne,l=cne,a=oe("router-link"),u=oe("MoreFilled"),c=Ne,d=ct,f=bo,p=Jn,h=oe("router-view"),m=oe("layout"),y=oe("app-layout"),v=oe("course-customizer");return C(),T(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(O(e.$t("Courses")),1)]),_:1}),r.course.id?(C(),K(i,{key:0},{default:$(()=>[ne(O(r.course.title)+" ",1),b("span",{class:"fcom_edit_course fcom_secondary_button clickable",onClick:t[0]||(t[0]=w=>{r.customizeCourse=!0})},O(e.$t("Edit")),1)]),_:1})):j("",!0)]),_:1})]),actions:$(()=>[b("div",WOe,[b("ul",KOe,[(C(!0),T(fe,null,nt(r.menuItems,w=>(C(),T("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(O(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",qOe,[b("li",{onClick:t[1]||(t[1]=w=>s.toViewCourse())},O(e.$t("View Course")),1),b("li",{onClick:t[2]||(t[2]=()=>{e.$refs.course_actions.hide(),r.customizeCourse=!0})},O(e.$t("Edit Course")),1),b("li",{onClick:t[3]||(t[3]=(...w)=>s.initDeleteCourse&&s.initDeleteCourse(...w))},O(e.$t("Delete Course")),1)])]),_:1},512)])])])]),default:$(()=>[r.loading?(C(),T("div",GOe,[k(p,{loading:r.loading,animation:"pulse",row:"10"},null,8,["loading"])])):r.course.id?(C(),K(h,{key:1,course:r.course},null,8,["course"])):(C(),T("div",YOe,[b("h3",null,O(e.$t("Sorry, the course can not be loaded")),1)]))]),_:1},8,["title"])]),_:1}),r.customizeCourse&&r.course.id?(C(),T("div",ZOe,[(C(),K(_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"])]))])):j("",!0)],64)}const XOe=We(UOe,[["render",JOe]]),QOe={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||"")}},eIe={class:"fcom_length_input"};function tIe(e,t,n,o,r,s){const i=Tt;return C(),T("div",eIe,[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(O(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(O(e.$t("sec")),1)]),_:1},8,["modelValue","onChange"])])}const nIe=We(QOe,[["render",tIe]]),oIe={name:"CourseMeta",components:{LengthInput:nIe},props:["lesson"]},rIe={class:"fcom_course_meta"},sIe={class:"fcom_meta_section"},iIe={class:"fcom_meta_label"},lIe={class:"fcom_meta_content"},aIe={key:0,class:"fcom_meta_section"},uIe={class:"fcom_meta_label"},cIe={class:"fcom_meta_content"};function dIe(e,t,n,o,r,s){const i=In,l=oe("length-input");return C(),T("div",rIe,[b("div",sIe,[b("div",iIe,O(e.$t("Features Settings")),1),b("div",lIe,[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(O(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(O(e.$t("Enable Comments")),1)]),_:1},8,["modelValue"])])]),n.lesson.meta.enable_media=="yes"?(C(),T("div",aIe,[b("div",uIe,O(e.$t("Video length")),1),b("div",cIe,[k(l,{modelValue:n.lesson.meta.video_length,"onUpdate:modelValue":t[2]||(t[2]=a=>n.lesson.meta.video_length=a)},null,8,["modelValue"])])])):j("",!0)])}const fIe=We(oIe,[["render",dIe]]),pIe={name:"LessonEditor",props:["lesson","section","course","editingIndex"],emits:["saved","close","changeLesson"],components:{BlockEditor:gL,MediaEmbeder:Lk,LessonMeta:fIe},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")}},hIe={class:"fcom_full_editor"},mIe={class:"fcom_full_editor_header"},gIe={key:0},vIe={class:"full_editor_actions"},yIe={class:"fcom_editor_wrap"},_Ie={style:{"margin-bottom":"10px"},class:"fcom_lesson_camp"},bIe={class:"fcom_lesson_nav"},wIe={class:"fcom_lesson_title"},CIe={class:"fcom_lesson_content"};function kIe(e,t,n,o,r,s){const i=oe("ArrowLeft"),l=Ne,a=oe("arrow-down"),u=ct,c=wh,d=Ch,f=bh,p=HM,h=oe("lesson-meta"),m=jM,y=oe("ArrowRight"),v=Tt,w=oe("media-embeder"),_=oe("block-editor"),S=ks,x=K0,E=zM,M=Dt("loading");return C(),T("div",hIe,[k(E,null,{default:$(()=>[k(p,{class:"fcom_full_editor_header_wrap"},{default:$(()=>[b("div",mIe,[b("div",{onClick:t[0]||(t[0]=A=>e.$emit("close")),class:"fcom_back_header"},[k(l,null,{default:$(()=>[k(i)]),_:1}),ne(" "+O(e.$t("Back to Lessons"))+" ",1),n.course&&n.course.title?(C(),T("span",gIe,"("+O(n.course.title)+")",1)):j("",!0)]),b("div",vIe,[k(f,{onCommand:t[1]||(t[1]=A=>{n.lesson.status=A}),trigger:"click"},{dropdown:$(()=>[k(d,null,{default:$(()=>[k(c,{command:"draft"},{default:$(()=>[ne(O(e.$t("Draft")),1)]),_:1}),k(c,{command:"published"},{default:$(()=>[ne(O(e.$t("Published")),1)]),_:1})]),_:1})]),default:$(()=>[k(u,{type:n.lesson.status=="published"?"success":"info",bg:"",text:"",class:"el-dropdown-link"},{default:$(()=>[ne(O(e.$labelize(n.lesson.status))+" ",1),k(l,{class:"el-icon--right"},{default:$(()=>[k(a)]),_:1})]),_:1},8,["type"])]),_:1}),Fe((C(),K(u,{style:{"margin-left":"15px"},disabled:r.saving,onClick:s.saveData,class:"fcom_primary_button"},{default:$(()=>[ne(O(e.$t("Save")),1)]),_:1},8,["disabled","onClick"])),[[M,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",yIe,[b("div",_Ie,[b("div",null,O(e.$t("Lesson %1s of %2s - %3s",n.editingIndex+1,n.section.lessons.length,n.section.title)),1),b("div",bIe,[k(u,{onClick:t[2]||(t[2]=A=>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]=A=>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",wIe,[k(v,{ref:"create_status",type:"text",class:"fcom_input_h1",modelValue:n.lesson.title,"onUpdate:modelValue":t[4]||(t[4]=A=>n.lesson.title=A),size:"large",placeholder:e.$t("Lesson Title")},null,8,["modelValue","placeholder"])]),n.lesson.meta.enable_media=="yes"?(C(),K(w,{key:0,style:{margin:"30px 0"},media:n.lesson.meta.media},null,8,["media"])):j("",!0),b("div",CIe,[k(_,{modelValue:n.lesson.message,"onUpdate:modelValue":t[5]||(t[5]=A=>n.lesson.message=A)},null,8,["modelValue"])])])]),_:1})]),_:1})]),_:1})]),_:1})])}const vL=We(pIe,[["render",kIe]]),SIe={name:"LessonLine",emits:["showEditor","updated"],props:["lesson"],components:{LessonEditor:vL},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)}}},$Ie={key:0,class:"fcom_heading_item"},EIe={class:"fcom_section_item_actions"};function xIe(e,t,n,o,r,s){const i=ct,l=Tt,a=oe("arrow-down"),u=Ne,c=wh,d=Ch,f=bh,p=oe("MoreFilled");return C(),T(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(),K(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(O(e.$t("save")),1)]),_:1},8,["onClick"])]),_:1},8,["onKeyup","modelValue"])):(C(),T("p",$Ie,[b("span",{onClick:t[0]||(t[0]=h=>e.$emit("showEditor",n.lesson))},O(n.lesson.title),1)]))],2),b("div",EIe,[k(i,{onClick:t[3]||(t[3]=h=>e.$emit("showEditor",n.lesson)),class:"fcom_show_hover",text:""},{default:$(()=>[ne(O(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(O(e.$t("Draft")),1)]),_:1}),k(c,{command:"published"},{default:$(()=>[ne(O(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(O(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(O(e.$t("Edit Lesson Content")),1)]),_:1}),k(c,{command:"edit_title"},{default:$(()=>[ne(O(e.$t("Edit Title")),1)]),_:1}),k(c,{command:"delete"},{default:$(()=>[ne(O(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 TIe=We(SIe,[["render",xIe]]),MIe={name:"SectionScheduler",components:{CaretBottom:zY},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}}},OIe={style:{"padding-left":"10px"},class:"fcom_section_scheduler"},IIe={class:"fcom_scheduler_form"},AIe={class:"fcom_input_group"},NIe={class:"el_inline_date_picker"},PIe={class:"fcom_input_group"},LIe={class:"fcom_input_group"},RIe={class:"fcom_scheduler_form"},DIe={class:"fcom_input_group"},VIe={class:"fcom_label"},FIe={class:"fcom_input_group"};function BIe(e,t,n,o,r,s){const i=oe("CaretBottom"),l=Ne,a=cie,u=PO,c=ct,d=bo,f=hO,p=Dt("loading");return C(),T("div",OIe,[n.course.settings.course_type=="scheduled"?(C(),K(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,O(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",IIe,[b("div",AIe,[b("div",NIe,[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",PIe,[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",LIe,[Fe((C(),K(c,{disabled:r.saving,type:"success",onClick:s.saveSchedule},{default:$(()=>[ne(O(e.$t("Update Date")),1)]),_:1},8,["disabled","onClick"])),[[p,r.saving]])])])]),_:1},8,["visible"])):j("",!0),n.course.settings.course_type=="structured"?(C(),K(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,O(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",RIe,[b("div",DIe,[b("div",VIe,O(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(" "+O(e.$t("Days")),1)]),b("div",FIe,[Fe((C(),K(c,{disabled:r.saving,type:"success",onClick:s.saveUnlockDays},{default:$(()=>[ne(O(e.$t("Update")),1)]),_:1},8,["disabled","onClick"])),[[p,r.saving]])])])]),_:1},8,["visible"])):j("",!0)])}const zIe=We(MIe,[["render",BIe]]),jIe={name:"SectionPart",props:["section","course"],emits:["reload"],components:{LessonEditor:vL,LessonLine:TIe,SectionScheduler:zIe,FluentDnD:Tv},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){console.log(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={};du(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)})}}},HIe={class:"fcom_section_primary"},UIe={class:"fcom_section_primary_item"},WIe={key:0,class:"fcom_heading_item"},KIe={class:"fcom_section_config fcom_label_schedule"},qIe={class:"fcom_section_config fcom_label_email"},GIe={style:{"margin-left":"15px"}},YIe={class:"meta_line"},ZIe={class:"fcom_section_primary_item_actions fcom_label_actions"},JIe={key:0,class:"fcom_section_items"},XIe=b("div",{class:"fcom_drag_handle"}," ⋮⋮ ",-1),QIe={key:0};function eAe(e,t,n,o,r,s){const i=ct,l=Tt,a=oe("section-scheduler"),u=Bn,c=Fn,d=bo,f=oe("MoreFilled"),p=Ne,h=wh,m=Ch,y=bh,v=oe("lesson-line"),w=oe("FluentDnD"),_=oe("LessonEditor"),S=Dt("loading");return C(),T(fe,null,[Fe((C(),T("div",HIe,[b("div",UIe,[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(),K(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(O(e.$t("save")),1)]),_:1})]),_:1},8,["modelValue"])):(C(),T("h4",WIe,[b("span",{onClick:t[0]||(t[0]=x=>r.editing_title=!0)},O(n.section.title),1)]))],2),s.hasSchedule?(C(),T(fe,{key:0},[b("div",KIe,[k(a,{section:n.section,course:n.course},null,8,["section","course"])]),b("div",qIe,[b("div",GIe,[b("span",YIe,O(e.$t("n/a")),1)])])],64)):j("",!0),b("div",ZIe,[k(d,{persistent:!1,ref:"add_lesson",placement:"bottom",width:400,trigger:"click"},{reference:$(()=>[k(i,{class:"fcom_secondary_button"},{default:$(()=>[ne(O(e.$t("Add Lesson")),1)]),_:1})]),default:$(()=>[k(c,{onSubmit:[t[6]||(t[6]=Je(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:$(()=>[Fe((C(),K(i,{disabled:r.addingLesson,class:"fcom_secondary_button",onClick:s.addLesson},{default:$(()=>[ne(O(e.$t("Add")),1)]),_:1},8,["disabled","onClick"])),[[S,r.addingLesson]]),Fe((C(),K(i,{disabled:r.addingLesson,class:"fcom_primary_button",onClick:t[5]||(t[5]=()=>{s.addLesson(!1,!0)})},{default:$(()=>[ne(O(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(O(e.$t("Edit Title")),1)]),_:1}),k(h,{command:"delete"},{default:$(()=>[ne(O(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(),T("div",JIe,[k(w,{items:n.section.lessons,onDrop:s.dropLesson,"item-class":"fcom_section_item"},{item:$(({data:x,index:E})=>[(C(),K(v,{onDeleteLesson:s.handleDeleteLesson,onUpdated:s.handleLessonUpdated,key:x.id,onShowEditor:M=>s.initLessonEditor(x,E),lesson:x},{before_section_heading:$(()=>[XIe]),_:2},1032,["onDeleteLesson","onUpdated","onShowEditor","lesson"]))]),_:1},8,["items","onDrop"])])):j("",!0)])),[[S,r.working]]),r.editingLesson?(C(),T("div",QIe,[(C(),K(_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"])]))])):j("",!0)],64)}const tAe=We(jIe,[["render",eAe]]),nAe={name:"EditLessons",props:["course"],components:{SectionPart:tAe,FluentDnD:Tv},data(){return{sections:[],loading:!1,newSection:{title:""},addingSection:!1}},computed:{lessonsCount(){let e=0;return du(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={};du(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()}},oAe={class:"fcom_course_lessons"},rAe={class:"fcom_settings_header"},sAe={class:"fcom_settings_header_meta"},iAe={class:"fcom_settings_header_meta_item"},lAe={class:"fcom_card_section_heading"},aAe={class:"fcom_section_labels"},uAe={class:"fcom_lebel fcom_label_lesson"},cAe={class:"fcom_lebel fcom_label_schedule"},dAe={class:"fcom_lebel fcom_label_email"},fAe=b("div",{class:"fcom_lebel fcom_label_actions"},null,-1),pAe=b("div",{class:"fcom_drag_handle"}," ⋮⋮ ",-1);function hAe(e,t,n,o,r,s){const i=ct,l=Tt,a=Bn,u=Fn,c=bo,d=Jn,f=oe("section-part"),p=oe("FluentDnD"),h=Dt("loading");return C(),T("div",oAe,[b("div",rAe,[b("div",null,[b("h2",null,O(e.$t("Lessons")),1),b("div",sAe,[b("div",iAe,[b("b",null,O(e.$t("Type:")),1),ne(" "+O(e.$labelize(n.course.settings.course_type))+" • ",1),b("b",null,O(e.$t("Status:")),1),ne(" "+O(e.$labelize(n.course.status))+" • ",1),b("b",null,O(e.$t("Visibility:")),1),ne(" "+O(e.$labelize(n.course.privacy)),1)])])])]),b("div",{class:D(["fcom_card_sections","fcom_course_type_"+n.course.settings.course_type])},[Fe((C(),T("div",lAe,[b("h3",null,O(e.$_n("%d Section","%d Sections",r.sections.length))+" • "+O(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(O(e.$t("+ Add Section")),1)]),_:1})]),default:$(()=>[k(u,{onSubmit:t[1]||(t[1]=Je(m=>e.doNothing(),["prevent"])),"label-position":"top"},{default:$(()=>[k(a,{label:e.$t("Section Title")},{default:$(()=>[k(l,{onKeydown:Pt(Je(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:$(()=>[Fe((C(),K(i,{disabled:r.addingSection,class:"fcom_primary_button",onClick:s.addSection},{default:$(()=>[ne(O(e.$t("Save")),1)]),_:1},8,["disabled","onClick"])),[[h,r.addingSection]])]),_:1})]),_:1})]),_:1},512)])),[[h,r.loading]]),r.loading?(C(),K(d,{key:0,animated:!0,rows:10})):j("",!0),b("div",aAe,[b("div",uAe,O(e.$t("Lesson name")),1),b("div",cAe,O(e.$t("Schedule")),1),b("div",dAe,O(e.$t("E-mail")),1),fAe]),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:$(()=>[pAe]),_:2},1032,["onReload","course","section"])]),_:1},8,["items","onDrop"])],2)])}const mAe=We(nAe,[["render",hAe]]),gAe={name:"Pagination",emits:["fetch","per_page_change"],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]},pager_layout(){return this.isMobile?"total, sizes, jumper, prev, next":"total, sizes, jumper , prev, pager, next"}},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")}}},vAe={class:"fcom_pagination_wrap"};function yAe(e,t,n,o,r,s){const i=nue;return C(),T("div",vAe,[k(i,{background:!1,size:"small","pager-count":3,layout:s.pager_layout,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,["layout","onCurrentChange","onSizeChange","hide-on-single-page","current-page","page-sizes","page-size","total"])])}const yL=We(gAe,[["render",yAe]]),_Ae={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()}},bAe={style:{float:"left"}},wAe={style:{float:"right",color:"#8492a6","font-size":"13px"}};function CAe(e,t,n,o,r,s){const i=Ss,l=vr,a=Bn,u=ct,c=Fn,d=Dt("loading");return C(),K(c,{onSubmit:t[2]||(t[2]=Je(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),T(fe,null,nt(r.users,f=>(C(),K(i,{key:f.ID,label:f.display_name+" ("+f.ID+")",value:f.ID},{default:$(()=>[b("span",bAe,O(f.display_name),1),b("span",wAe,O(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:$(()=>[Fe((C(),K(u,{class:"fcom_primary_button",disabled:r.saving,onClick:t[1]||(t[1]=f=>s.addStudent())},{default:$(()=>[ne(O(e.$t("Add Student")),1)]),_:1},8,["disabled"])),[[d,r.saving]])]),_:1})])]),_:3})}const kAe=We(_Ae,[["render",CAe]]),SAe={name:"CourseMembers",props:["course","course_id"],components:{UserRouteLink:Q0,Pagination:yL,AddStudentForm:kAe},data(){return{students:[],search:"",loading:!0,working:!1,isAddStdOpen:!1,SearchIcon:Ii(tJ),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()}},$Ae={class:"fcom_course_members"},EAe={class:"fcom_course_member_header"},xAe={class:"fcom_course_member_actions"},TAe={class:"table_user_card"},MAe={class:"card_avatar"},OAe={class:"card_info"},IAe={class:"card_name"},AAe={class:"meta_line"},NAe={class:"progress_wrap"};function PAe(e,t,n,o,r,s){const i=ct,l=Tt,a=oe("UserAvatar"),u=oe("UserRouteLink"),c=Z0,d=yO,f=oe("MoreFilled"),p=Ne,h=wh,m=Ch,y=bh,v=Y0,w=oe("pagination"),_=oe("add-student-form"),S=ta,x=Dt("loading");return C(),T("div",$Ae,[b("div",EAe,[b("h3",null,O(e.$t("Course Students")),1),b("div",xAe,[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(O(e.$t("Add Student")),1)]),_:1})])]),Fe((C(),K(v,{data:r.students,style:{width:"100%"}},{default:$(()=>[k(c,{prop:"ID",label:e.$t("Name"),"min-width":"200"},{default:$(E=>[b("div",TAe,[b("div",MAe,[k(a,{xprofile:E.row},null,8,["xprofile"])]),b("div",OAe,[b("div",IAe,[k(u,{show_badge:!0,xprofile:E.row},null,8,["xprofile"])]),b("div",AAe,O(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",NAe,[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(O(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:M=>s.removeStudentPrompt(E.row)},{default:$(()=>[ne(O(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,O(e.$t("Add Student")),1)]),default:$(()=>[k(_,{onCompleted:s.studentAdded,course:n.course},null,8,["onCompleted","course"])]),_:1},8,["modelValue","size"])])}const LAe=We(SAe,[["render",PAe]]),RAe={name:"ChatIcon"},DAe={width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},VAe=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),FAe=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=[VAe,FAe];function zAe(e,t,n,o,r,s){return C(),T("svg",DAe,BAe)}const jAe=We(RAe,[["render",zAe]]),HAe={name:"HeartIcon",props:{filled:{default:!1}}},UAe={key:0,viewBox:"0 0 24 24","aria-hidden":"true"},WAe=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),KAe=[WAe],qAe={key:1,viewBox:"0 0 24 24","aria-hidden":"true"},GAe=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),YAe=[GAe];function ZAe(e,t,n,o,r,s){return n.filled?(C(),T("svg",UAe,KAe)):(C(),T("svg",qAe,YAe))}const _L=We(HAe,[["render",ZAe]]),JAe={name:"SurveyEditForm",props:["form"],emits:["cancel"],data(){return{}},methods:{addOption(){this.form.options.push({label:"",slug:""})},removeOption(e){this.form.options.splice(e,1)}}},XAe={class:"fcom_compose_app_form"},QAe={class:"fcom_app_header"},eNe={class:"fcom_app_options"},tNe={class:"fcom_app_pref"},nNe={class:"fcom_app_footer"};function oNe(e,t,n,o,r,s){const i=ct,l=Tt,a=oe("Plus"),u=Ne,c=In;return C(),T("div",XAe,[b("div",QAe,[b("h5",null,O(e.$t("Poll Options")),1),b("div",null,[k(i,{onClick:t[0]||(t[0]=d=>e.$emit("cancel")),size:"small",text:""},{default:$(()=>[ne(O(e.$t("cancel")),1)]),_:1})])]),b("div",eNe,[(C(!0),T(fe,null,nt(n.form.options,(d,f)=>(C(),T("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")},Bl({_: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",tNe,[k(i,{onClick:s.addOption,text:"",size:"small"},{default:$(()=>[k(u,null,{default:$(()=>[k(a)]),_:1}),b("span",null,O(e.$t("Add More")),1)]),_:1},8,["onClick"])])]),b("div",nNe,[b("h5",null,O(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(O(e.$t("Users can choose multiple options")),1)]),_:1},8,["modelValue"])])])}const rNe=We(JAe,[["render",oNe]]),sNe={name:"GiphyIcon"},iNe={width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},lNe=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),aNe=[lNe];function uNe(e,t,n,o,r,s){return C(),T("svg",iNe,aNe)}const cNe=We(sNe,[["render",uNe]]),dNe={name:"Giphy",components:{GiphyIcon:cNe},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:Cpe(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()}}},fNe={class:"fcom_giphy_composer"},pNe={class:"search-container"},hNe=["onLoad","src","alt","onClick"],mNe={key:0,class:"img_loading"},gNe={key:1,class:"no_result"},vNe=b("div",{class:"fcom_giphy_powered_by"},[b("span",{class:"powered_by"},"POWERED BY "),b("span",null,"GIPHY")],-1);function yNe(e,t,n,o,r,s){const i=Tt,l=yh,a=vh,u=oe("GiphyIcon"),c=Ne,d=ct,f=bo,p=Dt("loading");return C(),T("div",fNe,[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:$(()=>[Fe((C(),T("div",pNe,[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(),K(a,{key:0,gutter:5},{default:$(()=>[(C(!0),T(fe,null,nt(r.gifs,h=>(C(),K(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,hNe),h.loaded?j("",!0):(C(),T("p",mNe))]),_:2},1024))),128))]),_:1})):(C(),T("p",gNe,O(e.$t("No results")),1))],32),vNe])),[[p,r.loading]])]),_:1},512)])}const _Ne=We(dNe,[["render",yNe]]),bNe={name:"VideoIcon"},wNe={width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},CNe=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),kNe=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),SNe=[CNe,kNe];function $Ne(e,t,n,o,r,s){return C(),T("svg",wNe,SNe)}const ENe=We(bNe,[["render",$Ne]]),xNe={name:"VideoEmbeder",emits:["embeded"],components:{MediaEmbeder:Lk,VideoIcon:ENe},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"}}}},TNe={class:"fcom_video_embeder"};function MNe(e,t,n,o,r,s){const i=oe("VideoIcon"),l=Ne,a=ct,u=oe("media-embeder"),c=_h;return C(),T("div",TNe,[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(),K(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"])):j("",!0)])}const ONe=We(xNe,[["render",MNe]]),INe=window.fluentComAdmin.auth,ANe={name:"FeedTextComposer",components:{MediaPreview:Mv,Giphy:_Ne,ImageUploader:Td,SurveyEditForm:rNe,MarkdownEditor:nL,EmojiPicker:dL,VideoEmbeder:ONe},emits:["editorCreated"],props:{placeholder:{type:String,default(){return"What's happening, "+INe.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()})}},NNe={class:"fcom_text_composer"},PNe={class:"fcom_editor status_text_input"},LNe={key:0,style:{position:"relative","text-align":"center"}},RNe={key:1,class:"fcom_media_items"},DNe={key:0,class:"fcom_media_images"},VNe=["src","alt"],FNe={key:1},BNe={class:"fcom_media_images"},zNe=["src","alt"],jNe={key:2,class:"fcrom_media_images"},HNe=["src","alt"],UNe={key:3,class:"fcrom_media_images"},WNe={class:"fcrom_media_image"},KNe=["src","alt"],qNe={class:"fcom_composer_footer"},GNe={class:"fcom_composer_apps"},YNe=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),ZNe={key:0},JNe=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),XNe={class:"fcom_composer_actions"};function QNe(e,t,n,o,r,s){var y,v,w,_,S,x,E,M,A;const i=oe("MarkdownEditor"),l=oe("SurveyEditForm"),a=ct,u=oe("media-preview"),c=Ne,d=oe("image-uploader"),f=oe("video-embeder"),p=oe("EmojiPicker"),h=oe("Giphy"),m=Dt("loading");return C(),T(fe,null,[b("div",NNe,[b("div",PNe,[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(),K(l,{key:0,onCancel:t[2]||(t[2]=P=>n.content.survey=null),form:n.content.survey},null,8,["form"])):(C(),T(fe,{key:1},[(v=(y=n.content)==null?void 0:y.media)!=null&&v.type?(C(),T("div",LNe,[k(a,{onClick:t[3]||(t[3]=P=>{n.content.media=null}),text:"",type:"danger"},{default:$(()=>[ne(O(e.$t("Remove Media")),1)]),_:1}),k(u,{media_item:n.content.media},null,8,["media_item"])])):(w=n.content)!=null&&w.meta?(C(),T("div",RNe,[(S=(_=n.content.meta)==null?void 0:_.media_items)!=null&&S.length?(C(!0),T(fe,{key:0},nt(n.content.meta.media_items,(P,N)=>(C(),T("div",{key:N},[P.type=="image"?(C(),T("div",DNe,[b("img",{class:"fcom_media_image",src:P.url,alt:e.$t("Media image")},null,8,VNe),k(a,{class:"fcom_media_images_cross_button",link:"",onClick:V=>n.content.meta.media_items.splice(N,1)},{default:$(()=>[ne(" x ")]),_:2},1032,["onClick"])])):j("",!0)]))),128)):((E=(x=n.content.meta)==null?void 0:x.media_preview)==null?void 0:E.type)=="image"||(A=(M=n.content.meta)==null?void 0:M.media_preview)!=null&&A.image?(C(),T("div",FNe,[b("div",BNe,[b("img",{class:"fcom_media_image",src:n.content.meta.media_preview.image,alt:e.$t("Media Preview image")},null,8,zNe),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})])])):j("",!0)])):n.content.media_images&&n.content.media_images.length?(C(),T("div",jNe,[(C(!0),T(fe,null,nt(n.content.media_images,(P,N)=>(C(),T("div",{class:"fcrom_media_image",key:N},[b("img",{src:P.url,alt:e.$t("Media image")},null,8,HNe),k(a,{link:"",onClick:V=>n.content.media_images.splice(N,1)},{default:$(()=>[ne(" x ")]),_:2},1032,["onClick"])]))),128))])):s.checkHasImageForCommentsEdit(n.content)?(C(),T("div",UNe,[b("div",WNe,[b("img",{src:n.content.media.media_url,alt:e.$t("Media image")},null,8,KNe),k(a,{link:"",onClick:t[5]||(t[5]=P=>s.removeImageFromComments())},{default:$(()=>[ne(" x ")]),_:1})])])):j("",!0)],64))]),Fe((C(),T("div",qNe,[b("div",GNe,[s.hasActiveApp?j("",!0):(C(),T(fe,{key:0},[e.appVars.features.max_media_per_post?(C(),K(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:$(()=>[Fe((C(),K(a,{"aria-label":"Upload Media",text:""},{default:$(()=>[k(c,{class:"fcom_status_img_icon"},{default:$(()=>[YNe]),_:1}),r.uploading?(C(),T("span",ZNe,O(e.$t("Uploading...")),1)):j("",!0)]),_:1})),[[m,r.uploading]])]),_:1},8,["isMultiple","onUploaded"])):j("",!0),n.videoApp&&e.hasFeature("video_embeder")?(C(),K(f,{key:1,onEmbeded:s.handleVideoAttachment},null,8,["onEmbeded"])):j("",!0),n.surveyApp&&e.hasFeature("has_survey_poll")?(C(),K(a,{key:2,"aria-label":"Create Poll",onClick:s.initSurveyForm,text:""},{default:$(()=>[k(c,{class:"fcom_apps_icon"},{default:$(()=>[JNe]),_:1})]),_:1},8,["onClick"])):j("",!0),e.hasFeature("emoji_app")?(C(),K(p,{key:3,onEmojiSelected:s.insertEmoji},null,8,["onEmojiSelected"])):j("",!0),e.hasFeature("giphy_app")?(C(),K(h,{key:4,onSelectedGiphy:s.selectedGiphy},null,8,["onSelectedGiphy"])):j("",!0)],64))]),b("div",XNe,[he(e.$slots,"default")])])),[[m,r.uploading]])],64)}const bL=We(ANe,[["render",QNe]]),ePe={name:"CommentReacts",components:{UserRouteLink:Q0},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}))}}},tPe={style:{"margin-left":"5px"}},nPe={key:0},oPe={key:1},rPe={class:"fcom_user_lists"},sPe={key:2};function iPe(e,t,n,o,r,s){const i=Jn,l=oe("UserAvatar"),a=oe("UserRouteLink"),u=ks,c=bo;return C(),K(c,{persistent:!1,placement:"bottom",title:e.$t("Likes"),width:200,trigger:"click",onShow:s.getReactions},{reference:$(()=>[b("span",tPe,O(n.comment.reactions_count),1)]),default:$(()=>[r.loading?(C(),T("div",nPe,[k(i,{animated:!0,rows:1})])):r.reactions?(C(),T("div",oPe,[k(u,{"max-height":"300px"},{default:$(()=>[b("ul",rPe,[(C(!0),T(fe,null,nt(r.reactions,d=>(C(),T("li",null,[d.xprofile?(C(),T(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)):j("",!0)]))),256))])]),_:1})])):(C(),T("div",sPe,[b("p",null,O(e.$t("Failed to load the list")),1)]))]),_:1},8,["title","onShow"])}const lPe=We(ePe,[["render",iPe]]),aPe={name:"SingleComment",components:{FeedTextComposer:bL,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()}}},uPe={key:0,class:"person_avatar"},cPe={class:"comment_wrap"},dPe={key:0,class:"comment_text"},fPe={class:"comment_text_head"},pPe={class:"comment_text_head_name"},hPe=["title"],mPe={style:{"margin-left":"auto"},class:"comment_actions"},gPe={class:"actions_items"},vPe=["innerHTML"],yPe={key:0,class:"comment_text_media"},_Pe={key:1,class:"comment_text"};function bPe(e,t,n,o,r,s){const i=oe("UserAvatar"),l=oe("UserRouteLink"),a=oe("MoreFilled"),u=Ne,c=ct,d=bo,f=oe("MediaPreview"),p=oe("feed-text-composer"),h=Dt("loading");return C(),T(fe,null,[n.comment.xprofile?(C(),T("div",uPe,[k(i,{with_level:!1,xprofile:n.comment.xprofile,is_rounded:!0},null,8,["xprofile"])])):j("",!0),Fe((C(),T("div",cPe,[r.isEdit?(C(),T("div",_Pe,[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(O(e.$t("Cancel")),1)]),_:1}),k(c,{type:"primary",onClick:t[4]||(t[4]=m=>s.updateComment(n.comment))},{default:$(()=>[ne(O(e.$t("Update")),1)]),_:1})])]),_:1},8,["content"])])):(C(),T("div",dPe,[b("div",fPe,[b("div",pPe,[k(l,{show_badge:!0,xprofile:n.comment.xprofile},null,8,["xprofile"])]),b("div",{title:n.comment.created_at,class:"comment_text_head_time"},O(e.humanDateDiff(n.comment.created_at)),9,hPe),b("div",mPe,[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",gPe,[b("li",{onClick:t[0]||(t[0]=m=>s.copyCommentLink(n.comment))},O(e.$t("Copy Link")),1),e.canEditComment(n.comment)?(C(),T("li",{key:0,onClick:t[1]||(t[1]=m=>s.editComment())},O(e.$t("Edit")),1)):j("",!0),e.canDeleteComment(n.comment)?(C(),T("li",{key:1,onClick:t[2]||(t[2]=m=>s.deleteComment())},O(e.$t("Delete")),1)):j("",!0)])]),_:1},512)])]),b("div",{class:"comment_text_body feed_md_content",innerHTML:s.renderedComment(n.comment.message_rendered)},null,8,vPe),n.comment.meta.media_preview?(C(),T("div",yPe,[k(f,{media_item:n.comment.meta.media_preview},null,8,["media_item"])])):j("",!0)])),he(e.$slots,"after_comment_text")])),[[h,r.working]])],64)}const wPe=We(aPe,[["render",bPe]]),CPe={name:"IndividualCommentReply",components:{FeedTextComposer:bL,HeartIcon:_L,SingleComment:wPe,CommentReactions:lPe},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.replyingComment.comments||(this.replyingComment.comments=[]),this.replyingComment.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()}},kPe={class:"fcom_course_comment each_comment"},SPe={key:0,class:"person_avatar"},$Pe=["src","alt"],EPe={class:"comment_wrap"},xPe={class:"comment_text"},TPe={class:"comment_text_head"},MPe={class:"comment_text_head_name"},OPe={class:"comment_text_head_time"},IPe=["innerHTML"],APe={class:"reply_box"},NPe={class:"fcom_comments_react"},PPe={class:"child_comments"},LPe=["id"],RPe={class:"reply_box"},DPe=["onClick"],VPe={class:"fcom_comments_react fcom_reaction_list"},FPe={key:0,class:"child_reply_wrap"},BPe={class:"feed_commenting"},zPe={class:"person_avatar"},jPe=["src"],HPe={class:"feed_comment_input comment_text"};function UPe(e,t,n,o,r,s){const i=oe("UserRouteLink"),l=oe("HeartIcon"),a=Ne,u=oe("CommentReactions"),c=oe("single-comment"),d=ct,f=oe("FeedTextComposer"),p=Dt("loading");return C(),T("div",kPe,[r.replyingComment.xprofile?(C(),T("div",SPe,[b("img",{src:r.replyingComment.xprofile.avatar,alt:e.$t("avatar")},null,8,$Pe)])):j("",!0),b("div",EPe,[b("div",xPe,[b("div",TPe,[b("div",MPe,[k(i,{xprofile:r.replyingComment.xprofile},null,8,["xprofile"])]),b("div",OPe,O(e.humanDateDiff(r.replyingComment.created_at)),1)]),b("div",{class:"comment_text_body",innerHTML:r.replyingComment.message_rendered},null,8,IPe)]),b("div",APe,[b("span",{onClick:t[0]||(t[0]=(...h)=>s.toggleCommentBox&&s.toggleCommentBox(...h)),class:"reply_btn"},O(e.$t("Reply")),1),b("span",{style:{"margin-left":"14px"},class:D([{fcom_is_liked:r.replyingComment.liked},"reply_btn"])},[b("div",NPe,[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(),K(u,{key:0,comment:n.comment},null,8,["comment"])):j("",!0)])],2)]),b("div",PPe,[(C(!0),T(fe,null,nt(r.replyingComment.comments,(h,m)=>(C(),T("div",{id:"comment_"+h.id,class:"each_comment"},[k(c,{onDeleted:y=>e.handleCommentDelete(m),comment:h},{after_comment_text:$(()=>[b("div",RPe,[b("span",{onClick:y=>s.toggleCommentBox(h),class:"reply_btn"},O(e.$t("Reply")),9,DPe),b("span",{style:{"margin-left":"14px"},class:D([{fcom_is_liked:h.liked},"reply_btn"])},[b("div",VPe,[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(),K(u,{key:0,comment:h},null,8,["comment"])):j("",!0)])],2)])]),_:2},1032,["onDeleted","comment"])],8,LPe))),256))]),r.commenting?(C(),T("div",FPe,[b("div",BPe,[b("div",zPe,[b("img",{alt:"",src:e.auth.avatar},null,8,jPe)]),b("div",HPe,[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:$(()=>[Fe((C(),K(d,{disabled:r.saving,class:"fcom_primary_button",onClick:t[2]||(t[2]=h=>s.postComment())},{default:$(()=>[ne(O(e.$t("Reply")),1)]),_:1},8,["disabled"])),[[p,r.saving]])]),_:1},8,["mentionQuery","autofocus_changed","autofocus","disabled","placeholder","content"])])])])):j("",!0)])])}const WPe=We(CPe,[["render",UPe]]),KPe={name:"CourseComments",props:["course"],components:{IndividualCommentReply:WPe,Pagination:yL,ChatIcon:jAe,HeartIcon:_L},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()}},qPe={key:0,class:"white_loaded"},GPe={class:"fcom_course_comments_header"},YPe={key:0},ZPe={class:"course_comments feed_comments overview_comments"},JPe={key:0,class:"person_avatar"},XPe={class:"comment_wrap"},QPe={class:"comment_text"},eLe={class:"comment_text_head"},tLe={class:"comment_text_head_name"},nLe={class:"comment_text_head_time"},oLe={class:"comment_actions"},rLe={class:"actions_items"},sLe=["onClick"],iLe={class:"comment_text_details"},lLe=["href"],aLe=["innerHTML"],uLe={class:"comment_text_actions"},cLe={key:0},dLe={key:1};function fLe(e,t,n,o,r,s){const i=Jn,l=oe("UserAvatar"),a=oe("UserRouteLink"),u=oe("MoreFilled"),c=Ne,d=ct,f=bo,p=oe("ChatIcon"),h=oe("HeartIcon"),m=oe("pagination"),y=oe("IndividualCommentReply"),v=ta,w=Dt("loading");return r.loading?(C(),T("div",qPe,[k(i,{row:5})])):(C(),T(fe,{key:1},[b("div",GPe,[r.pagination.total?(C(),T("h5",YPe,O(e.$t("Comments (%s)",r.pagination.total)),1)):j("",!0)]),b("div",ZPe,[(C(!0),T(fe,null,nt(r.comments,(_,S)=>(C(),T("div",{key:_.id,class:"fcom_course_comment each_comment"},[_.xprofile?(C(),T("div",JPe,[k(l,{with_level:!1,xprofile:_.xprofile},null,8,["xprofile"])])):j("",!0),b("div",XPe,[b("div",QPe,[b("div",eLe,[b("div",tLe,[k(a,{xprofile:_.xprofile},null,8,["xprofile"])]),b("div",nLe,O(e.humanDateDiff(_.created_at)),1),Fe((C(),T("div",oLe,[e.canDeleteComment(_)?(C(),K(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",rLe,[b("li",{onClick:x=>s.deleteComment(_,S)},"Delete",8,sLe)])]),_:2},1024)):j("",!0)])),[[w,r.working]])]),b("div",iLe,[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(O(e.$t("Commented in"))+" ",1),b("b",null,O(e.getExcerpt(_.post.title,60)),1)],8,lLe)]),b("div",{class:"comment_text_body",innerHTML:_.message_rendered},null,8,aLe),b("div",uLe,[k(d,{onClick:x=>s.initCommentReply(_),text:""},{default:$(()=>[k(c,null,{default:$(()=>[k(p)]),_:1}),b("span",null,O(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,O(_.reactions_count||""),1)]),_:2},1024)])])])]))),128)),r.pagination.total?j("",!0):(C(),T("div",cLe,[b("h5",null,O(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(O(e.$t("Replying to"))+" ",1),b("b",null,O((_=r.replyingComemnt)==null?void 0:_.post.title),1)])]}),default:$(()=>[r.replyingComemnt?(C(),K(y,{key:0,comment:r.replyingComemnt,comments:r.comments,onToggleLike:s.toggleLike},null,8,["comment","comments","onToggleLike"])):(C(),T("h3",dLe,O(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 pLe=We(KPe,[["render",fLe]]),hLe={name:"CourseOverview",props:["course","course_id"],components:{CourseComments:pLe}},mLe={class:"fcom_cards fcom_cards_2"},gLe={class:"fcom_card"},vLe={class:"fcom_card_body"},yLe={class:"fcom_card"},_Le={class:"fcom_card_body"};function bLe(e,t,n,o,r,s){const i=oe("course-comments");return C(),T(fe,null,[b("div",mLe,[b("div",gLe,[b("div",vLe,[b("p",null,O(e.$t("Students")),1),b("h3",null,O(n.course.students_count),1)])]),b("div",yLe,[b("div",_Le,[b("p",null,O(e.$t("Average completion rate")),1),b("h3",null,O(n.course.overAllProgress)+"%",1)])])]),k(i,{course:n.course},null,8,["course"])],64)}const wLe=We(hLe,[["render",bLe]]),CLe={name:"SpaceIcon",props:["space_profile"]},kLe=["alt","src"],SLe={key:1,class:"fcom_emoji"},$Le={key:2,class:"fcom_shape"},ELe={key:3,class:"fcom_no_avatar"};function xLe(e,t,n,o,r,s){var l,a,u,c;const i=Ne;return n.space_profile.logo?(C(),T("img",{key:0,alt:e.$t("Space Logo"),src:n.space_profile.logo},null,8,kLe)):(l=n.space_profile.settings)!=null&&l.emoji?(C(),T("span",SLe,O((a=n.space_profile.settings)==null?void 0:a.emoji),1)):(u=n.space_profile.settings)!=null&&u.shape_svg?(C(),T("span",$Le,[k(i,{innerHTML:(c=n.space_profile.settings)==null?void 0:c.shape_svg},null,8,["innerHTML"])])):(C(),T("span",ELe))}const wL=We(CLe,[["render",xLe]]),TLe={name:"TopicsConfig",emits:["saved"],data(){return{config:this.appVars.topicsConfig,loading:!1}},methods:{update(){this.loading=!0,this.$post("admin/topics/config",{config:this.config}).then(e=>{this.$notify.success(e.message),this.appVars.topicsConfig=e.config,this.$emit("saved")}).catch(e=>{this.$handleError(e)}).finally(()=>{this.loading=!1})}}};function MLe(e,t,n,o,r,s){const i=hO,l=Bn,a=In,u=ct,c=Fn,d=Dt("loading");return C(),K(c,{onSubmit:t[4]||(t[4]=Je(f=>e.doNothing(),["prevent"])),"label-position":"top",modelValue:r.config,"onUpdate:modelValue":t[5]||(t[5]=f=>r.config=f)},{default:$(()=>[k(l,{label:e.$t("Maximum Number of Topics a user can select when creating a post")},{default:$(()=>[k(i,{modelValue:r.config.max_topics_per_post,"onUpdate:modelValue":t[0]||(t[0]=f=>r.config.max_topics_per_post=f),min:1,max:20,step:1},null,8,["modelValue"])]),_:1},8,["label"]),k(l,{label:e.$t("Maximum Number of Topics a space may have")},{default:$(()=>[k(i,{modelValue:r.config.max_topics_per_space,"onUpdate:modelValue":t[1]||(t[1]=f=>r.config.max_topics_per_space=f),min:1,max:40,step:1},null,8,["modelValue"])]),_:1},8,["label"]),k(l,{label:e.$t("Show/Hide Topics On post Card")},{default:$(()=>[k(a,{"true-value":"yes","false-value":"no",modelValue:r.config.show_on_post_card,"onUpdate:modelValue":t[2]||(t[2]=f=>r.config.show_on_post_card=f)},{default:$(()=>[ne(O(e.$t("Show Topics on Post Card")),1)]),_:1},8,["modelValue"])]),_:1},8,["label"]),k(l,null,{default:$(()=>[Fe((C(),K(u,{class:"fcom_primary_button",onClick:t[3]||(t[3]=f=>s.update())},{default:$(()=>[ne(O(e.$t("Update")),1)]),_:1})),[[d,r.loading]])]),_:1})]),_:1},8,["modelValue"])}const OLe=We(TLe,[["render",MLe]]),ILe={name:"TopicCreateForm",components:{SpaceIcon:wL,SlugInput:Bh},emits:["saved"],props:{space_id:{type:Number,required:!1},all_spaces:{type:Array,required:!1,default:()=>[]},topic:{type:Object,required:!1,default:{title:"",description:"",slug:"",space_ids:[],admin_only:"no"}}},data(){return{saving:!1,editing_topic:this.topic,formattedSpaceGroups:[]}},methods:{createOrupdateTopic(){this.saving=!0,this.space_id&&(this.editing_topic.space_ids=[this.space_id],this.editing_topic.inline="yes"),this.$post("admin/topics",this.editing_topic).then(e=>{this.$notify.success(e.message),this.$emit("saved",e.topic)}).catch(e=>{this.$handleError(e)}).finally(()=>{this.saving=!1})},formatSpaceGroups(){if(this.space_id||this.all_spaces.length==0)return;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}},mounted(){this.formatSpaceGroups()}},ALe={class:"fcom_help_text"},NLe={key:0,class:"fcom_space_title"},PLe={key:0},LLe={key:1},RLe={class:"fcom_help_text"};function DLe(e,t,n,o,r,s){const i=Tt,l=Bn,a=oe("slug-input"),u=oe("SpaceIcon"),c=Ss,d=Tae,f=vr,p=In,h=ct,m=Fn,y=Dt("loading");return C(),K(m,{onSubmit:t[5]||(t[5]=Je(v=>e.doNothing(),["prevent"])),modelValue:r.editing_topic,"onUpdate:modelValue":t[6]||(t[6]=v=>r.editing_topic=v),"label-position":"top"},{default:$(()=>[k(l,{label:e.$t("Topic Title")},{default:$(()=>[k(i,{placeholder:e.$t("Title of your topic"),modelValue:r.editing_topic.title,"onUpdate:modelValue":t[0]||(t[0]=v=>r.editing_topic.title=v),type:"text"},null,8,["placeholder","modelValue"])]),_:1},8,["label"]),k(l,{label:e.$t("Topic Slug")},{default:$(()=>[k(a,{disabled:!!r.editing_topic.id,modelValue:r.editing_topic.slug,"onUpdate:modelValue":t[1]||(t[1]=v=>r.editing_topic.slug=v),placeholder:e.$t("Slug of your topic")},null,8,["disabled","modelValue","placeholder"])]),_:1},8,["label"]),k(l,{label:e.$t("Topic sub-title")},{default:$(()=>[k(i,{placeholder:e.$t("Sub-title of your topic"),modelValue:r.editing_topic.description,"onUpdate:modelValue":t[2]||(t[2]=v=>r.editing_topic.description=v),type:"text"},null,8,["placeholder","modelValue"]),b("div",ALe,[b("p",null,O(e.$t("This will be displayed under the title in the topic when selecting in post creation form")),1)])]),_:1},8,["label"]),n.space_id?j("",!0):(C(),K(l,{key:0,label:e.$t("Space visibility")},{default:$(()=>[k(f,{modelValue:r.editing_topic.space_ids,"onUpdate:modelValue":t[3]||(t[3]=v=>r.editing_topic.space_ids=v),multiple:"",placeholder:e.$t("Select Spaces"),style:{width:"100%"}},{default:$(()=>[(C(!0),T(fe,null,nt(r.formattedSpaceGroups,v=>(C(),K(d,{key:v.label,label:v.label},{default:$(()=>[(C(!0),T(fe,null,nt(v.spaces,w=>(C(),K(c,{key:w.slug,label:w.title,value:w.id.toString()},{default:$(()=>[w.id?(C(),T("span",NLe,[k(u,{space_profile:w},null,8,["space_profile"]),b("span",null,[ne(O(e.getExcerpt(w.title,50))+" ",1),w.type=="course"?(C(),T("span",PLe," ("+O(e.$t("course"))+")",1)):j("",!0)])])):(C(),T("span",LLe,O(e.getExcerpt(w.title,50)),1))]),_:2},1032,["label","value"]))),128))]),_:2},1032,["label"]))),128))]),_:1},8,["modelValue","placeholder"]),b("div",RLe,[b("p",null,O(e.$t("Select spaces where this topic will be visible.")),1)])]),_:1},8,["label"])),k(l,null,{default:$(()=>[k(p,{modelValue:r.editing_topic.admin_only,"onUpdate:modelValue":t[4]||(t[4]=v=>r.editing_topic.admin_only=v),"true-value":"yes","false-value":"no"},{default:$(()=>[ne(O(e.$t("Only admins and moderators can select this topic")),1)]),_:1},8,["modelValue"])]),_:1}),k(l,null,{default:$(()=>[Fe((C(),K(h,{type:"primary",onClick:s.createOrupdateTopic,disabled:r.saving},{default:$(()=>[ne(O(e.$t("Save")),1)]),_:1},8,["onClick","disabled"])),[[y,r.saving]])]),_:1})]),_:1},8,["modelValue"])}const VLe=We(ILe,[["render",DLe]]),FLe={name:"AllTopics",components:{TopicCreateForm:VLe,SlugInput:Bh,SpaceIcon:wL,Layout:$s,AppLayout:Es,TopicsConfig:OLe},data(){return{topics:[],saving:!1,loading:!1,search:"",showModal:!1,editing_topic:{title:"",description:"",slug:"",space_ids:[],admin_only:"no"},all_spaces:[],showConfig:!1}},methods:{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}).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})})},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"))}},BLe=["href"],zLe={class:""},jLe={class:"fhr_content_layout_body"},HLe={key:0},ULe={style:{"margin-bottom":"10px"},class:"fcom_manager_actions"},WLe={class:"bulk_search"},KLe=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),qLe={style:{margin:"0",padding:"0"}},GLe={class:"fcom_meta_text"},YLe={class:"fcom_table_action_col"},ZLe={key:1,class:"setting_body",style:{"text-align":"center"}},JLe=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),XLe=["href"],QLe={class:"dialog_header"},eRe={class:"dialog_left"},tRe=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),nRe={key:0,class:"dialog_body"};function oRe(e,t,n,o,r,s){const i=oe("Plus"),l=Ne,a=ct,u=oe("Operation"),c=Tt,d=Z0,f=oe("DeleteFilled"),p=Y0,h=oe("layout"),m=oe("app-layout"),y=oe("TopicCreateForm"),v=_h,w=oe("TopicsConfig"),_=Dt("loading");return C(),T(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("Topics")},{actions:$(()=>[e.has_pro?(C(),T(fe,{key:0},[k(a,{class:"fcom_primary_button",onClick:t[0]||(t[0]=S=>s.showForm(null))},{default:$(()=>[k(l,null,{default:$(()=>[k(i)]),_:1}),b("span",null,O(e.$t("New Topic")),1)]),_:1}),k(a,{onClick:t[1]||(t[1]=S=>r.showConfig=!0)},{default:$(()=>[k(l,null,{default:$(()=>[k(u)]),_:1}),b("span",null,O(e.$t("Settings")),1)]),_:1})],64)):(C(),T("a",{key:1,target:"_blank",rel:"noopener",href:e.appVars.upgrade_url,class:"el-button el-button--danger"},O(e.$t("Upgrade to Pro")),9,BLe))]),default:$(()=>[b("div",zLe,[b("div",jLe,[e.has_pro?(C(),T("div",HLe,[b("p",null,O(e.$t("Categorize your content and allow members to filter posts with the topic navigation bar in spaces.")),1),b("div",ULe,[b("div",WLe,[k(c,{modelValue:r.search,"onUpdate:modelValue":t[2]||(t[2]=S=>r.search=S),onKeydown:Pt(s.fetch,["enter"]),placeholder:e.$t("Search"),class:"el-input-round"},{prefix:$(()=>[KLe]),_:1},8,["modelValue","onKeydown","placeholder"])])]),Fe((C(),K(p,{data:r.topics},{default:$(()=>[k(d,{label:e.$t("Title"),"min-width":"260"},{default:$(S=>[b("p",qLe,O(S.row.title),1),b("span",GLe,O(S.row.title),1)]),_:1},8,["label"]),k(d,{label:e.$t("Spaces"),"min-width":"140"},{default:$(S=>[b("span",null,O(s.formatTopics(S.row.space_ids)),1)]),_:1},8,["label"]),k(d,{label:e.$t("Admin Only?"),width:"120"},{default:$(S=>[b("span",null,O(S.row.admin_only=="yes"?e.$t("Yes"):e.$t("No")),1)]),_:1},8,["label"]),k(d,{label:e.$t("Actions"),width:"120"},{default:$(S=>[b("div",YLe,[k(a,{onClick:x=>s.showForm(S.row),size:"small"},{default:$(()=>[ne(O(e.$t("Edit")),1)]),_:2},1032,["onClick"]),k(a,{onClick:x=>s.removeTopic(S.row),type:"danger",plain:"",size:"small"},{default:$(()=>[k(l,null,{default:$(()=>[k(f)]),_:1})]),_:2},1032,["onClick"])])]),_:1},8,["label"])]),_:1},8,["data"])),[[_,r.loading]])])):(C(),T("div",ZLe,[JLe,b("a",{target:"_blank",rel:"noopener",href:e.appVars.upgrade_url,class:"el-button el-button--danger"},O(e.$t("Upgrade to Pro")),9,XLe)]))])])]),_: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]=S=>r.showModal=S),direction:"rtl"},{header:$(({close:S})=>[b("div",QLe,[b("div",eRe,[tRe,b("div",null,[b("h4",null,O(r.editing_topic.id?e.$t("Update Tipic"):e.$t("Add Topic")),1)])])])]),default:$(()=>[r.showModal?(C(),T("div",nRe,[r.showModal?(C(),K(y,{key:0,all_spaces:r.all_spaces,editing_topic:r.editing_topic,onSaved:t[3]||(t[3]=S=>{r.showModal=!1,s.fetch()})},null,8,["all_spaces","editing_topic"])):j("",!0)])):j("",!0)]),_:1},8,["width","modelValue"]),k(v,{"close-on-click-modal":!1,"append-to-body":!0,width:e.dialogWidth,title:e.$t("Topics Settings"),modelValue:r.showConfig,"onUpdate:modelValue":t[6]||(t[6]=S=>r.showConfig=S),direction:"rtl"},{default:$(()=>[r.showConfig?(C(),K(w,{key:0,onSaved:t[5]||(t[5]=S=>{r.showConfig=!1})})):j("",!0)]),_:1},8,["width","title","modelValue"])],64)}const rRe=We(FLe,[["render",oRe]]),sRe=[{path:"/settings",component:Sfe,meta:{active_menu:"settings"},children:[{name:"settings",path:"",component:fhe,meta:{active_menu:"settings"}},{name:"customization",path:"customization",component:SSe,meta:{active_menu:"settings"}},{name:"admin_moderators",path:"moderators",component:Y0e,meta:{active_menu:"settings"}},{name:"email_notifications",path:"email-notifications",component:X8e,meta:{active_menu:"settings"}},{name:"features",path:"features",component:N7e,meta:{active_menu:"settings"}},{name:"menu_settings",path:"menu-settings",component:Cxe,meta:{active_menu:"settings"}},{path:"space_groups",name:"space_groups",component:yTe,meta:{active_menu:"settings"}},{path:"topics-settings",name:"all_topics",component:rRe,meta:{active_menu:"settings"}},{path:"privacy-settings",name:"privacy_settings",component:DSe,meta:{active_menu:"settings"}}]},{path:"/manage-courses",component:nMe,name:"manage_courses",meta:{active_menu:"manage_courses"}},{path:"/manage-courses/edit/:course_id",component:XOe,props:!0,meta:{active_menu:"manage_courses"},children:[{name:"edit_lessons",path:"lessons",component:mAe,props:!0,meta:{active_menu:"manage_courses"}},{name:"course_students",path:"students",component:LAe,props:!0,meta:{active_menu:"manage_courses"}},{name:"course_overview",path:"overview",component:wLe,props:!0,meta:{active_menu:"manage_courses"}}]}],iRe={name:"VerifiedSign"},lRe={class:"fcom_verified"},aRe=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),uRe=[aRe];function cRe(e,t,n,o,r,s){return C(),T("span",lRe,uRe)}const dRe=We(iRe,[["render",cRe]]),fRe={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}}},pRe=["title"],hRe=["src"],mRe={key:1,class:"fcom_emoji"},gRe={key:2,class:"fcom_shape"},vRe={key:1};function yRe(e,t,n,o,r,s){const i=Ne;return s.renderingBadge?(C(),T("div",{key:0,class:D([{user_icon_only:s.renderingBadge.show_label!="yes"},"user_badge"])},[b("div",{style:et({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(),T(fe,{key:0},[s.renderingBadge.config.logo?(C(),T("img",{key:0,alt:"",src:s.renderingBadge.config.logo},null,8,hRe)):s.renderingBadge.config.emoji?(C(),T("span",mRe,O(s.renderingBadge.config.emoji),1)):s.renderingBadge.config.shape_svg?(C(),T("span",gRe,[k(i,{innerHTML:s.renderingBadge.config.shape_svg},null,8,["innerHTML"])])):j("",!0)],64)):j("",!0),s.renderingBadge.show_label=="yes"?(C(),T("span",vRe,O(s.renderingBadge.title),1)):j("",!0)],12,pRe)],2)):j("",!0)}const _Re=We(fRe,[["render",yRe]]),bRe={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)}}},wRe={key:0,class:"fcom_welcome_box"},CRe={key:2,class:"fcom_welcome_title"},kRe=["innerHTML"],SRe={key:4,class:"fcom_welcome_cta_buttons"},$Re=["href","target"];function ERe(e,t,n,o,r,s){const i=oe("media-preview"),l=Ed,a=oe("MoreFilled"),u=Ne,c=ct,d=wh,f=Ch,p=bh;return r.config&&s.showBanner?(C(),T("div",wRe,[s.showMedia?(C(),K(i,{key:0,media_item:r.config.bannerVideo},null,8,["media_item"])):r.config.bannerImage?(C(),K(l,{key:1,class:"feed_media",alt:e.$t("Image Preview"),src:r.config.bannerImage},null,8,["alt","src"])):j("",!0),r.config.title?(C(),T("h2",CRe,O(r.config.title),1)):j("",!0),r.config.description_rendered?(C(),T("div",{key:3,class:"fcom_welcome_sub",innerHTML:r.config.description_rendered},null,8,kRe)):j("",!0),s.showCtaButtons?(C(),T("div",SRe,[(C(!0),T(fe,null,nt(r.config.ctaButtons,h=>(C(),T(fe,null,[h.link&&h.label?(C(),T("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"})},O(h.label),11,$Re)):j("",!0)],64))),256))])):j("",!0),s.isRemovable?(C(),K(p,{key:5,trigger:"click",class:"fcom_welcome_close"},{dropdown:$(()=>[k(f,null,{default:$(()=>[k(d,{onClick:s.closeBanner},{default:$(()=>[ne(O(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})):j("",!0)])):j("",!0)}const xRe=We(bRe,[["render",ERe]]);Yd(()=>Promise.resolve().then(()=>QVe),void 0);const TRe=[HY,lZ,fZ,HZ,rJ,kZ,TZ,aJ,LY,FY,nT,eT,LZ,IY,OZ,L0,Qx,EZ,d3,Us,iJ,uu,$u,WY,Z_,cJ,hZ,bZ,GZ,MY,XY,FZ,c3,vZ,NY,tZ,DZ,Xx,tT,a3];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 qn=Cw(wfe);qn.use(Ide);qn.config.globalProperties.appVars=window.fluentComAdmin;qn.config.globalProperties.auth=window.fluentComAdmin.auth;qn.config.globalProperties.has_pro=!!window.fluentComAdmin.pro;let P2="40%",L2="60%";window.innerWidth<600?(L2="95%",P2="90%"):window.innerWidth<800&&(L2="80%",P2="80%");TRe.forEach(e=>{qn.component(e.name,e)});qn.component("VerifiedSign",dRe);qn.component("UserAvatar",nI);qn.component("UserRouteLink",Q0);qn.component("WelcomeBanner",xRe);qn.component("UserBadge",_Re);function e$(){qn.use(window.FluentCommunityUtil.eventBus);const e=window.FluentCommunityUtil.Rest;qn.mixin({data(){return{Storage:window.FluentCommunityUtil.Storage,is_rtl:!1,drawerWidth:P2,dialogWidth:L2,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:du,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 du(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"}}))}}),qn.config.globalProperties.$notify=ofe,qn.config.globalProperties.$confirm=py.confirm,qn.config.globalProperties.$promt=py.prompt,qn.config.globalProperties.$messageBox=py,qn.config.globalProperties.$gloablStorage={};const t=window.FluentCommunityUtil.hooks.applyFilters("fluent_com_portal_admin_routes",sRe);let n=null;window.fluentComAdmin.routing_system=="hash"?n=y6({routes:t,history:rj()}):n=y6({routes:t,history:ix(window.fluentComAdmin.portal_slug)});const o=window.FluentCommunityUtil.hooks.applyFilters("fluent_com_portal_admin_app",qn);window.fluentFrameworkApp=o.use(n).mount("#fluent_com_portal"),window.fluentFrameworkAppRouter=n}window.FluentCommunityUtil?e$():document.addEventListener("fluentCommunityUtilReady",function(){e$()});var Ba,Pc;class MRe{constructor(t){Ms(this,Ba,void 0);Ms(this,Pc,new Set);Lo(this,Ba,t)}get current(){return kt(this,Ba)}set current(t){kt(this,Ba)!=t&&(Lo(this,Ba,t),kt(this,Pc).forEach(n=>n(t)))}on(t){return kt(this,Pc).add(t),()=>kt(this,Pc).delete(t)}}Ba=new WeakMap,Pc=new WeakMap;const CL=e=>new MRe(e),R2=Symbol.for("atomico.hooks");globalThis[R2]=globalThis[R2]||{};let md=globalThis[R2];const ORe=Symbol.for("Atomico.suspense"),kL=Symbol.for("Atomico.effect"),IRe=Symbol.for("Atomico.layoutEffect"),SL=Symbol.for("Atomico.insertionEffect"),zh=(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=>zh((t=CL(e))=>t),$L=()=>zh((e=CL(md.c.host))=>e),EL=()=>md.c.update,ARe=(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!==ORe)throw d;r=!0}finally{md.c=null}return c},cleanEffects:u=>(i(SL,u),()=>(i(IRe,u),()=>{i(kL,u)})),isSuspense:s}},jh=Symbol.for;function xL(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:NRe}=Array,D2=(e,t)=>(t?e instanceof HTMLStyleElement:!0)&&"hydrate"in((e==null?void 0:e.dataset)||{});function TL(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 ML=(e,t,n)=>(e.addEventListener(t,n),()=>e.removeEventListener(t,n));let OL=class{constructor(t,n,o){this.message=n,this.target=t,this.value=o}};class PRe extends OL{}class LRe extends OL{}const l0="Custom",RRe=null,DRe={true:1,"":1,1:1};function VRe(e,t,n,o,r){const{type:s,reflect:i,event:l,value:a,attr:u=BRe(t)}=(n==null?void 0:n.name)!=l0&&up(n)&&n!=RRe?n:{type:n},c=(s==null?void 0:s.name)===l0&&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?HRe:URe)(s,f);if(h&&m!=null)throw new PRe(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&&FRe(this,l),this.updated.then(()=>{i&&(this._ignoreAttr=u,zRe(this,s,u,this[t]),this._ignoreAttr=null)}))},get(){return this._props[t]}}),d&&(r[t]=d()),o[u]={prop:t,type:s}}const FRe=(e,{type:t,base:n=CustomEvent,...o})=>e.dispatchEvent(new n(t,o)),BRe=e=>e.replace(/([A-Z])/g,"-$1").toLowerCase(),zRe=(e,t,n,o)=>o==null||t==Boolean&&!o?e.removeAttribute(n):e.setAttribute(n,(t==null?void 0:t.name)===l0&&(t!=null&&t.serialize)?t==null?void 0:t.serialize(o):up(o)?JSON.stringify(o):t==Boolean?"":o),jRe=(e,t)=>e==Boolean?!!DRe[t]:e==Number?Number(t):e==String?t:e==Array||e==Object?JSON.parse(t):e.name==l0?t:new e(t),HRe=({map:e},t)=>{try{return{value:e(t),error:!1}}catch{return{value:t,error:!0}}},URe=(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 WRe=0;const KRe=e=>{var n;const t=((n=(e==null?void 0:e.dataset)||{})==null?void 0:n.hydrate)||"";return t||"c"+WRe++},Hh=(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=ARe(()=>this.update(),this,KRe(this));let p,h=!0;const m=D2(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&&qRe(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]=jRe(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)VRe(this.prototype,d,i[d],n,o);return Object.keys(n).concat(c)}}return a};function qRe(e){const{styles:t}=e.constructor,{shadowRoot:n}=e;if(n&&t.length){const o=[];TL(t,r=>{r&&(r instanceof Element?n.appendChild(r.cloneNode(!0)):o.push(r))}),o.length&&(n.adoptedStyleSheets=o)}}const IL=e=>(t,n)=>{zh(([o,r]=[])=>((r||!r)&&(r&&xL(r,n)?o=o||!0:(Ci(o)&&o(),o=null)),[o,n]),([o,r],s)=>s?(Ci(o)&&o(),[]):[o||t(),r],e)},a0=IL(kL),GRe=IL(SL);class YRe 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 AL=e=>{const t=EL();return zh((n=new YRe(e,(o,r,s)=>{o=Ci(o)?o(r[0]):o,o!==r[0]&&(r[0]=o,s||t())}))=>n)},V2=(e,t)=>{const[n]=zh(([o,r,s=0]=[])=>((!r||r&&!xL(r,t))&&(o=e()),[o,t,s]));return n},Vu=(e,t)=>V2(()=>e,t),F2=jh("atomico/options");globalThis[F2]=globalThis[F2]||{sheet:!!document.adoptedStyleSheets};const NL=globalThis[F2];new Promise(e=>{NL.ssr||(document.readyState==="loading"?ML(document,"DOMContentLoaded",e):e())});const ZRe={checked:1,value:1,selected:1},JRe={list:1,type:1,size:1,form:1,width:1,height:1,src:1,href:1,slot:1},XRe={shadowDom:1,staticNode:1,cloneNode:1,children:1,key:1},U1={},B2=[];class z2 extends Text{}const QRe=jh("atomico/id"),cp=jh("atomico/type"),i_=jh("atomico/ref"),PL=jh("atomico/vnode"),eDe=()=>{};function tDe(e,t,n){return RL(this,e,t,n)}const LL=(e,t,...n)=>{const o=t||U1;let{children:r}=o;if(r=r??(n.length?n:B2),e===eDe)return r;const s=e?e instanceof Node?1:e.prototype instanceof HTMLElement&&2:0;if(s===!1&&e instanceof Function)return e(r!=B2?{children:r,...o}:o);const i=NL.render||tDe;return{[cp]:PL,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 RL(e,t,n=QRe,o,r){let s;if(t&&t[n]&&t[n].vnode==e||e[cp]!=PL)return t;(e||!t)&&(r=r||e.type=="svg",s=e.type!="host"&&(e.raw==1?(t&&e.clone?t[i_]:t)!=e.type:e.raw==2?!(t instanceof e.type):t?t[i_]||t.localName!=e.type:!t),s&&e.type!=null&&(e.raw==1&&e.clone?(o=!0,t=e.type.cloneNode(!0),t[i_]=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]:U1,{vnode:l=U1,cycle:a=0}=i;let{fragment:u,handlers:c}=i;const{children:d=B2,props:f=U1}=l;if(c=s?{}:c||{},e.static&&!s)return t;if(e.shadow&&!t.shadowRoot&&t.attachShadow({mode:"open",...e.shadow}),e.props!=f&&rDe(t,f,e.props,c,r),e.children!==d){const p=e.shadow?t.shadowRoot:t;u=oDe(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 nDe(e,t){const n=new z2(""),o=new z2("");let r;if(e[t?"prepend":"append"](n),t){let{lastElementChild:s}=e;for(;s;){const{previousElementSibling:i}=s;if(D2(s,!0)&&!D2(i,!0)){r=s;break}s=i}}return r?r.before(o):e.append(o),{markStart:n,markEnd:o}}function oDe(e,t,n,o,r,s){e=e==null?null:NRe(e)?e:[e];const i=t||nDe(n,r),{markStart:l,markEnd:a,keyes:u}=i;let c;const d=u&&new Set;let f=l;if(e&&TL(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=RL(p,y,o,r,s);else{const w=p+"";!(v instanceof Text)||v instanceof z2?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 rDe(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&&ZRe[t]&&(n=e[t]),!(o===n||XRe[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)))sDe(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&&!JRe[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 sDe(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 iDe=LL("host",{style:"display: contents"}),lDe="value",aDe=(e,t)=>{const n=$L(),o=Rk();GRe(()=>ML(n.current,"ConnectContext",r=>{r.composedPath().at(0)!==r.currentTarget&&e===r.detail.id&&(r.stopPropagation(),r.detail.connect(o))}),[e]),o.current=t},uDe=e=>{const t=Hh(({value:n})=>(aDe(t,n),iDe),{props:{value:{type:Object,value:()=>e}}});return t[lDe]=e,t};uDe({dispatch(e,t){}});const cDe=0,Fu=1,Nm=2,Pm=3,o$=4,Cf=5,j2=6,DL=0,dDe=2,VL=3,FL=4,BL=Cf,fDe=j2,zL=(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===VL?o[0]=l:i===FL?o[1]=Object.assign(o[1]||{},l):i===BL?(o[1]=o[1]||{})[t[++s]]=l:i===fDe?o[1][t[++s]]+=l+"":i?(r=e.apply(l,zL(e,l,n,["",null])),o.push(r),l[0]?t[0]|=2:(t[s-2]=DL,t[s]=r)):o.push(l)}return o},pDe=function(e){let t=Fu,n="",o="",r=[0],s,i;const l=a=>{t===Fu&&(a||(n=n.replace(/^\s*\n\s*|\s*\n\s*$/g,"")))?r.push(DL,a,n):t===Pm&&(a||n)?(r.push(VL,a,n),t=Nm):t===Nm&&n==="..."&&a?r.push(FL,a,0):t===Nm&&n&&!a?r.push(BL,0,!0,n):t>=Cf&&((n||!a&&t===Cf)&&(r.push(t,0,n,i),t=j2),a&&(r.push(t,a,0,i),t=j2)),n=""};for(let a=0;a<e.length;a++){a&&(t===Fu&&l(),l(a));for(let u=0;u<e[a].length;u++)s=e[a][u],t===Fu?s==="<"?(l(),r=[r],t=Pm):n+=s:t===o$?n==="--"&&s===">"?(t=Fu,n=""):n=s+n[0]:o?s===o?o="":n+=s:s==='"'||s==="'"?o=s:s===">"?(l(),t=Fu):t&&(s==="="?(t=Cf,i=n,n=""):s==="/"&&(t<Cf||e[a][u+1]===">")?(l(),t===Pm&&(r=r[0]),t=r,(r=r[0]).push(dDe,0,t),t=cDe):s===" "||s===" "||s===` |
| 127 |
`||s==="\r"?(l(),t=Nm):n+=s),t===Pm&&n==="!--"&&(t=o$,r=r[0])}return l(),r},hDe=new Map;function $t(e){let t=hDe;return t=zL(LL,t.get(e)||(t.set(e,t=pDe(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),mDe=(e,t,n)=>(Dk(e,t,"access private method"),n),W1,K1,kf,Sf,q1,H2,jL;let Vk=class{constructor(t){zu(this,H2),zu(this,W1,void 0),zu(this,K1,void 0),zu(this,kf,void 0),zu(this,Sf,void 0),zu(this,q1,void 0),ju(this,kf,!1),this.onShow=()=>{},this.onHide=()=>{},ju(this,q1,(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,K1).call(this,n,o)){this.hide();return}nb({getBoundingClientRect:()=>uv(n,c,d)},this.element,{placement:"top",middleware:[tb(),Q_(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)=>{$v(Bu(this,q1),Bu(this,W1))(n,o)},this.destroy=()=>{},this.show=n=>{this.element.dataset.show="true",n&&nb(n,this.element,{placement:"top",middleware:[tb(),Q_(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,W1,t.debounce??200),ju(this,K1,t.shouldShow??mDe(this,H2,jL)),ju(this,Sf,t.offset),this.element.dataset.show="false"}};W1=new WeakMap,K1=new WeakMap,kf=new WeakMap,Sf=new WeakMap,q1=new WeakMap,H2=new WeakSet,jL=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 Fk(e){const t=An({},`${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 HL(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=HL(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=HL(e))&&(o&&(o+=" "),o+=t);return o}var gDe=Object.defineProperty,r$=Object.getOwnPropertySymbols,vDe=Object.prototype.hasOwnProperty,yDe=Object.prototype.propertyIsEnumerable,s$=(e,t,n)=>t in e?gDe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_De=(e,t)=>{for(var n in t||(t={}))vDe.call(t,n)&&s$(e,n,t[n]);if(r$)for(var n of r$(t))yDe.call(t,n)&&s$(e,n,t[n]);return e};function Ou(e,t){return Object.assign(e,{meta:_De({package:"@milkdown/components"},t)}),e}var bDe=Object.defineProperty,i$=Object.getOwnPropertySymbols,wDe=Object.prototype.hasOwnProperty,CDe=Object.prototype.propertyIsEnumerable,l$=(e,t,n)=>t in e?bDe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Bk=(e,t)=>{for(var n in t||(t={}))wDe.call(t,n)&&l$(e,n,t[n]);if(i$)for(var n of i$(t))CDe.call(t,n)&&l$(e,n,t[n]);return e};const kDe={mode:"preview"},Ri=An(Bk({},kDe),"linkTooltipStateCtx");Ou(Ri,{displayName:"State<link-tooltip>",group:"LinkTooltip"});const SDe={addLink:()=>{},editLink:()=>{},removeLink:()=>{}},gd=An(Bk({},SDe),"linkTooltipAPICtx");Ou(Ri,{displayName:"API<link-tooltip>",group:"LinkTooltip"});const $De={linkIcon:()=>"🔗",editButton:()=>"✎",removeButton:()=>"⌫",confirmButton:()=>$t`Confirm ⏎`,onCopyLink:()=>{},inputPlaceholder:"Paste link..."},Ov=An(Bk({},$De),"linkTooltipConfigCtx");Ou(Ri,{displayName:"Config<link-tooltip>",group:"LinkTooltip"});const Uh=Fk("LINK_PREVIEW");Ou(Uh[0],{displayName:"PreviewTooltipSpec<link-tooltip>",group:"LinkTooltip"});Ou(Uh[1],{displayName:"PreviewTooltipPlugin<link-tooltip>",group:"LinkTooltip"});const Iv=Fk("LINK_EDIT");Ou(Iv[0],{displayName:"EditTooltipSpec<link-tooltip>",group:"LinkTooltip"});Ou(Iv[1],{displayName:"EditTooltipPlugin<link-tooltip>",group:"LinkTooltip"});function EDe(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 xDe(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||!Uh.pluginKey()))return{show:!0,pos:r,node:s,mark:i}}function UL(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 WL=({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 |
`};WL.props={config:Object,src:String,onEdit:Function,onRemove:Function};const KL=Hh(WL);var qL=e=>{throw TypeError(e)},GL=(e,t,n)=>t.has(e)||qL("Cannot "+n),rn=(e,t,n)=>(GL(e,t,"read from private field"),n?n.call(e):t.get(e)),Xi=(e,t,n)=>t.has(e)?qL("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Lm=(e,t,n,o)=>(GL(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),cl,es,$f,Ef,G1,Y1,Z1,xf;class TDe{constructor(t,n){this.ctx=t,Xi(this,cl,new KL),Xi(this,es),Xi(this,$f,this.ctx.use(Ri.key)),Xi(this,Ef,!1),Xi(this,G1,({mode:o})=>{o==="edit"&&rn(this,xf).call(this)}),Xi(this,Y1,()=>{Lm(this,Ef,!0)}),Xi(this,Z1,()=>{Lm(this,Ef,!1)}),Xi(this,xf,()=>{rn(this,es).hide(),rn(this,es).element.removeEventListener("mouseenter",rn(this,Y1)),rn(this,es).element.removeEventListener("mouseleave",rn(this,Z1))}),this.show=(o,r,s,i)=>{rn(this,cl).config=this.ctx.get(Ov.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,Y1)),rn(this,es).element.addEventListener("mouseleave",rn(this,Z1))},this.hide=()=>{rn(this,Ef)||rn(this,xf).call(this)},this.update=()=>{},this.destroy=()=>{rn(this,$f).off(rn(this,G1)),rn(this,es).destroy(),rn(this,cl).remove()},Lm(this,es,new Vk({debounce:0,content:rn(this,cl),shouldShow:()=>!1})),rn(this,es).update(n),Lm(this,$f,t.use(Ri.key)),rn(this,$f).on(rn(this,G1))}}cl=new WeakMap;es=new WeakMap;$f=new WeakMap;Ef=new WeakMap;G1=new WeakMap;Y1=new WeakMap;Z1=new WeakMap;xf=new WeakMap;UL("milkdown-link-preview",KL);function MDe(e){let t;const o=$v((s,i)=>{if(!t||!s.hasFocus()||e.get(Ri.key).mode==="edit")return;const a=xDe(e,s,i);if(a){const u=s.state.doc.resolve(a.pos),c=EDe(a.mark,a.node,s.state.doc,u.before(),u.after()),d=c.start,f=c.end;t.show(a.mark,d,f,uv(s,d,f));return}t.hide()},200),r=()=>{setTimeout(()=>{t==null||t.hide()},200)};e.set(Uh.key,{props:{handleDOMEvents:{mousemove:o,mouseleave:r}},view:s=>(t=new TDe(e,s),t)})}const YL=({src:e,onConfirm:t,onCancel:n,config:o})=>{const r=Rk(),[s,i]=AL(e);a0(()=>{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 |
`};YL.props={config:Object,src:String,onConfirm:Function,onCancel:Function};const ZL=Hh(YL);var ODe=Object.defineProperty,IDe=Object.defineProperties,ADe=Object.getOwnPropertyDescriptors,a$=Object.getOwnPropertySymbols,NDe=Object.prototype.hasOwnProperty,PDe=Object.prototype.propertyIsEnumerable,JL=e=>{throw TypeError(e)},u$=(e,t,n)=>t in e?ODe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Rm=(e,t)=>{for(var n in t||(t={}))NDe.call(t,n)&&u$(e,n,t[n]);if(a$)for(var n of a$(t))PDe.call(t,n)&&u$(e,n,t[n]);return e},c$=(e,t)=>IDe(e,ADe(t)),XL=(e,t,n)=>t.has(e)||JL("Cannot "+n),gn=(e,t,n)=>(XL(e,t,"read from private field"),n?n.call(e):t.get(e)),Hu=(e,t,n)=>t.has(e)?JL("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Dm=(e,t,n,o)=>(XL(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),Ps,dl,fl,Ea,U2,J1;const d$={from:-1,to:-1,mark:null};class LDe{constructor(t,n){this.ctx=t,Hu(this,Ps,new ZL),Hu(this,dl),Hu(this,fl,Rm({},d$)),Hu(this,Ea,()=>{gn(this,dl).hide(),this.ctx.update(Ri.key,o=>c$(Rm({},o),{mode:"preview"})),Dm(this,fl,Rm({},d$))}),Hu(this,U2,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,Ea).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,Ea).call(this)}),Hu(this,J1,(o,r,s)=>{const i=this.ctx.get(Ov.key);gn(this,Ps).config=i,gn(this,Ps).src=o,this.ctx.update(Ri.key,a=>c$(Rm({},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:()=>uv(l,r,s)}),requestAnimationFrame(()=>{var a;(a=gn(this,Ps).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,Ea).call(this)},this.destroy=()=>{gn(this,dl).destroy(),gn(this,Ps).remove()},this.addLink=(o,r)=>{Dm(this,fl,{from:o,to:r,mark:null}),gn(this,J1).call(this,"",o,r)},this.editLink=(o,r,s)=>{Dm(this,fl,{from:r,to:s,mark:o}),gn(this,J1).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,Ea).call(this)},Dm(this,dl,new Vk({content:gn(this,Ps),debounce:0,shouldShow:()=>!1})),gn(this,dl).onHide=()=>{gn(this,Ps).update().catch(o=>{throw o}),n.dom.focus({preventScroll:!0})},gn(this,dl).update(n),gn(this,Ps).onConfirm=gn(this,U2),gn(this,Ps).onCancel=gn(this,Ea)}}Ps=new WeakMap;dl=new WeakMap;fl=new WeakMap;Ea=new WeakMap;U2=new WeakMap;J1=new WeakMap;var RDe=Object.defineProperty,DDe=Object.defineProperties,VDe=Object.getOwnPropertyDescriptors,f$=Object.getOwnPropertySymbols,FDe=Object.prototype.hasOwnProperty,BDe=Object.prototype.propertyIsEnumerable,p$=(e,t,n)=>t in e?RDe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,zDe=(e,t)=>{for(var n in t||(t={}))FDe.call(t,n)&&p$(e,n,t[n]);if(f$)for(var n of f$(t))BDe.call(t,n)&&p$(e,n,t[n]);return e},jDe=(e,t)=>DDe(e,VDe(t));UL("milkdown-link-edit",ZL);function HDe(e){let t;e.update(gd.key,n=>jDe(zDe({},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(Iv.key,{view:n=>(t=new LDe(e,n),t)})}function UDe(e){MDe(e),HDe(e)}const WDe=[Ri,gd,Ov,Uh,Iv].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 KDe=$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 qDe=$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 QL=$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 |
`,GDe=$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 YDe=$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 ZDe=$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 |
`,JDe=$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 |
`,XDe=$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 QDe=$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 |
`,eR=$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 eVe=$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 tVe=$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 |
`,nVe=$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 oVe=$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 rVe=$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 sVe=(e,t)=>{e.config(UDe).config(n=>{n.update(Ov.key,o=>({...o,linkIcon:(t==null?void 0:t.linkIcon)??(()=>eR),editButton:(t==null?void 0:t.editButton)??(()=>YDe),removeButton:(t==null?void 0:t.removeButton)??(()=>nVe),confirmButton:(t==null?void 0:t.confirmButton)??(()=>GDe),inputPlaceholder:(t==null?void 0:t.inputPlaceholder)??"Paste link...",onCopyLink:(t==null?void 0:t.onCopyLink)??(()=>{})}))}).use(WDe)},iVe=Object.freeze(Object.defineProperty({__proto__:null,defineFeature:sVe},Symbol.toStringTag,{value:"Module"}));var tR="Expected a function",h$=0/0,lVe="[object Symbol]",aVe=/^\s+|\s+$/g,uVe=/^[-+]0x[0-9a-f]+$/i,cVe=/^0b[01]+$/i,dVe=/^0o[0-7]+$/i,fVe=parseInt,pVe=typeof On=="object"&&On&&On.Object===Object&&On,hVe=typeof self=="object"&&self&&self.Object===Object&&self,mVe=pVe||hVe||Function("return this")(),gVe=Object.prototype,vVe=gVe.toString,yVe=Math.max,_Ve=Math.min,l_=function(){return mVe.Date.now()};function bVe(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(tR);t=m$(t)||0,u0(n)&&(c=!!n.leading,d="maxWait"in n,s=d?yVe(m$(n.maxWait)||0,t):s,f="trailing"in n?!!n.trailing:f);function p(E){var M=o,A=r;return o=r=void 0,u=E,i=e.apply(A,M),i}function h(E){return u=E,l=setTimeout(v,t),c?p(E):i}function m(E){var M=E-a,A=E-u,P=t-M;return d?_Ve(P,s-A):P}function y(E){var M=E-a,A=E-u;return a===void 0||M>=t||M<0||d&&A>=s}function v(){var E=l_();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(l_())}function x(){var E=l_(),M=y(E);if(o=arguments,r=this,a=E,M){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 wVe(e,t,n){var o=!0,r=!0;if(typeof e!="function")throw new TypeError(tR);return u0(n)&&(o="leading"in n?!!n.leading:o,r="trailing"in n?!!n.trailing:r),bVe(e,t,{leading:o,maxWait:t,trailing:r})}function u0(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function CVe(e){return!!e&&typeof e=="object"}function kVe(e){return typeof e=="symbol"||CVe(e)&&vVe.call(e)==lVe}function m$(e){if(typeof e=="number")return e;if(kVe(e))return h$;if(u0(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=u0(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace(aVe,"");var n=cVe.test(e);return n||dVe.test(e)?fVe(e.slice(2),n?2:8):uVe.test(e)?h$:+e}var SVe=wVe;const $Ve=_o(SVe);var nR=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},Ht=(e,t,n)=>(nR(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)=>(nR(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n);function Av(e,t){return Object.assign(e,{meta:{package:"@milkdown/plugin-block",...t}}),e}const EVe=e=>!dC(t=>t.type.name==="table")(e),Wh=An({filterNodes:EVe},"blockConfig");Av(Wh,{displayName:"Ctx<blockConfig>"});function xVe(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 TVe(){return g$||(g$=document.implementation.createHTMLDocument("title"))}const MVe={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 OVe(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")||oa.fromSchema(e.state.schema),l=TVe(),a=l.createElement("div");a.appendChild(i.serializeFragment(s,{document:l}));let u=a.firstChild,c,d=0;for(;u&&u.nodeType===1&&(c=MVe[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$=Em.ie&&Em.ie_version<15||Em.ios&&Em.webkit_version<604,y$=20;var dp,X1,uc,Ls,Tf,Rs,W2,oR,cc,Mf,dc,fc,Q1,Of,If,Af,eg,pc;class IVe{constructor(){co(this,W2),co(this,cc),co(this,dp,void 0),co(this,X1,void 0),co(this,uc,void 0),co(this,Ls,void 0),co(this,Tf,void 0),co(this,Rs,void 0),co(this,dc,void 0),co(this,fc,void 0),co(this,Q1,void 0),co(this,Of,void 0),co(this,If,void 0),co(this,Af,void 0),co(this,eg,void 0),co(this,pc,void 0),sn(this,X1,()=>{if(!Ht(this,Ls))return null;const t=Ht(this,Ls),n=Ht(this,cc,Mf);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,Ls,null),sn(this,Tf,void 0),sn(this,Rs,!1),sn(this,fc,()=>{var t;(t=Ht(this,dc))==null||t.call(this,{type:"hide"}),sn(this,Ls,null)}),sn(this,Q1,t=>{var n;sn(this,Ls,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,Tf,(t=Ht(this,Ls))==null?void 0:t.el.getBoundingClientRect()),Ht(this,X1).call(this)}),sn(this,If,()=>{if(!Ht(this,Rs)){requestAnimationFrame(()=>{var t;Ht(this,Tf)&&((t=Ht(this,cc,Mf))==null||t.focus())});return}sn(this,Rs,!1),sn(this,uc,null)}),sn(this,Af,t=>{var n;sn(this,Rs,!0);const o=Ht(this,cc,Mf);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}=OVe(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,Ls))==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,Rs,!1),t.dom.dataset.dragging="false",!1),sn(this,eg,$Ve((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,W2,oR);if(!s)return;const i=xVe(t,{x:r,y:n.clientY},s);if(!i){Ht(this,fc).call(this);return}Ht(this,Q1).call(this,i)},200)),this.mousemoveCallback=(t,n)=>(t.composing||!t.editable||Ht(this,eg).call(this,t,n),!1),this.dragoverCallback=(t,n)=>{var o;if(Ht(this,Rs)){const r=(o=Ht(this,cc,Mf))==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,Rs,!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,Ls,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,Rs,!1),t.dom.dataset.dragging="false"})}}dp=new WeakMap,X1=new WeakMap,uc=new WeakMap,Ls=new WeakMap,Tf=new WeakMap,Rs=new WeakMap,W2=new WeakSet,oR=function(){var e;return(e=Ht(this,dp))==null?void 0:e.get(Wh.key).filterNodes},cc=new WeakSet,Mf=function(){var e;return(e=Ht(this,dp))==null?void 0:e.get(bn)},dc=new WeakMap,fc=new WeakMap,Q1=new WeakMap,Of=new WeakMap,If=new WeakMap,Af=new WeakMap,eg=new WeakMap,pc=new WeakMap;const rR=An(new IVe,"blockService");Av(Wh,{displayName:"Ctx<blockService>"});const zk=An({},"blockSpec");Av(Wh,{displayName:"Ctx<blockSpec>"});const jk=ao(e=>{const t=new wn("MILKDOWN_BLOCK"),n=e.get(rR.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)}}})});Av(jk,{displayName:"Prose<block>"});const Hk=[zk,Wh,rR,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)),ga=(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)},va=(e,t,n,o)=>(Uk(e,t,"write to private field"),o?o.call(e,n):t.set(e,n),n),AVe=(e,t,n)=>(Uk(e,t,"access private method"),n);function NVe(e){const t=An({},`${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,tg,hc,ng,og,rg,K2,sR;class PVe{constructor(t){ga(this,K2),ga(this,Nf,void 0),ga(this,tg,void 0),ga(this,hc,void 0),ga(this,ng,void 0),ga(this,og,void 0),ga(this,rg,void 0),va(this,Nf,!1),this.onShow=()=>{},this.onHide=()=>{},va(this,rg,(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),va(this,Nf,!0)),!(i||f)){if(!El(this,ng).call(this,n,o)){this.hide();return}nb({getBoundingClientRect:()=>uv(n,c,d)},this.element,{placement:"bottom-start",middleware:[tb(),Q_(El(this,og))]}).then(({x:p,y:h})=>{Object.assign(this.element.style,{left:`${p}px`,top:`${h}px`})}),this.show()}}),this.update=(n,o)=>{$v(El(this,rg),El(this,tg))(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=!awe(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,va(this,tg,t.debounce??200),va(this,ng,t.shouldShow??AVe(this,K2,sR)),va(this,hc,t.trigger??"/"),va(this,og,t.offset)}}Nf=new WeakMap,tg=new WeakMap,hc=new WeakMap,ng=new WeakMap,og=new WeakMap,rg=new WeakMap,K2=new WeakSet,sR=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 iR(e){return e.$from.parent.type.name==="code_block"}function lR(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 aR(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 LVe(e,t,n=null){const{from:o,to:r}=e.selection;return e.setBlockType(o,r,t,n)}function RVe(e,t,n=null){const{$from:o,$to:r}=e.selection,s=o.blockRange(r),i=s&&lC(s,t,n);return i?e.wrap(s,i):null}function DVe(e,t,n=null){const o=t.createAndFill(n);return o?e.replaceSelectionWith(o):null}function Vm(e,t=null){return(n,o)=>{if(o){const r=LVe(Wk(n.tr),e,t);o(r.scrollIntoView())}return!0}}function a_(e,t=null){return(n,o)=>{const r=RVe(Wk(n.tr),e,t);return r?(o&&o(r.scrollIntoView()),!0):!1}}function VVe(e,t=null){return(n,o)=>{const r=DVe(Wk(n.tr),e,t);return r?(o&&o(r.scrollIntoView()),!0):!1}}var xl,Lc;class FVe{constructor(){Ms(this,xl,void 0);Ms(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 Is(e){return window.fluentComAdmin.i18n[e]||e}function BVe(e,t){var s,i,l,a,u,c,d,f,p;const n=new FVe;n.addGroup("text",(t==null?void 0:t.slashMenuTextGroupLabel)??Is("Text")).addItem("text",{label:(t==null?void 0:t.slashMenuTextGroupLabel)??Is("Text"),icon:((s=t==null?void 0:t.slashMenuTextIcon)==null?void 0:s.call(t))??rVe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;Vm(ji.type(h))(v,y)}}).addItem("h2",{label:(t==null?void 0:t.slashMenuH2Label)??Is("Heading 2"),icon:((i=t==null?void 0:t.slashMenuH2Icon)==null?void 0:i.call(t))??ZDe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;Vm(qs.type(h),{level:2})(v,y)}}).addItem("h3",{label:(t==null?void 0:t.slashMenuH3Label)??Is("Heading 3"),icon:((l=t==null?void 0:t.slashMenuH3Icon)==null?void 0:l.call(t))??JDe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;Vm(qs.type(h),{level:3})(v,y)}}).addItem("h4",{label:(t==null?void 0:t.slashMenuH4Label)??Is("Heading 4"),icon:((a=t==null?void 0:t.slashMenuH4Icon)==null?void 0:a.call(t))??XDe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;Vm(qs.type(h),{level:4})(v,y)}}).addItem("quote",{label:(t==null?void 0:t.slashMenuQuoteLabel)??Is("Quote"),icon:((u=t==null?void 0:t.slashMenuQuoteIcon)==null?void 0:u.call(t))??tVe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;a_(Nd.type(h))(v,y)}}).addItem("code",{label:(t==null?void 0:t.slashMenuCodeBlockLabel)??Is("Code"),icon:((c=t==null?void 0:t.slashMenuCodeBlockIcon)==null?void 0:c.call(t))??QL,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;VVe(Pd.type(h))(v,y)}}),n.addGroup("list",(t==null?void 0:t.slashMenuListGroupLabel)??Is("List")).addItem("bullet-list",{label:(t==null?void 0:t.slashMenuBulletListLabel)??Is("Bullet List"),icon:((d=t==null?void 0:t.slashMenuBulletListIcon)==null?void 0:d.call(t))??qDe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;a_(Tu.type(h))(v,y)}}).addItem("ordered-list",{label:(t==null?void 0:t.slashMenuOrderedListLabel)??Is("Ordered List"),icon:((f=t==null?void 0:t.slashMenuOrderedListIcon)==null?void 0:f.call(t))??eVe,onRun:h=>{const m=h.get(bn),{dispatch:y,state:v}=m;a_(Mu.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 uR=({show:e,hide:t,ctx:n,filter:o,config:r})=>{const{groups:s,size:i}=V2(()=>BVe(o,r),[o]),l=$L(),[a,u]=AL(0),c=V2(()=>l.current.getRootNode(),[l]),d=Rk({x:-999,y:-999}),f=Vu(w=>{const _=d.current;if(!_)return;const{x:S,y:x}=w;_.x=S,_.y=x},[]);a0(()=>{i===0&&e&&(t==null||t())},[i,e]);const p=Vu((w,_)=>{u(S=>{const x=typeof w=="function"?w(S):w;return _==null||_(x),x})},[]),h=Vu(w=>{const _=l.current.querySelector(`[data-index="${w}"]`),S=l.current.querySelector(".menu-groups");!_||!S||(S.scrollTop=_.offsetTop-S.offsetTop)},[]),m=Vu(w=>{const _=s.flatMap(S=>S.items).at(w);_&&n&&_.onRun(n),t==null||t()},[s]),y=Vu(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=Vu(w=>_=>{const S=d.current;if(!S)return;const{x,y:E}=_;x===S.x&&E===S.y||p(w)},[]);return a0(()=>(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 |
`};uR.props={ctx:Object,config:Object,show:Boolean,filter:String,hide:Function};const cR=Hh(uR),dR=NVe("CREPE_MENU"),fR=An({show:()=>{},hide:()=>{}},"menuAPICtx");aR("milkdown-slash-menu",cR);function zVe(e,t){e.set(dR.key,{view:n=>new jVe(e,n,t)})}var sr,Bs,Tl;class jVe{constructor(t,n,o){Ms(this,sr,void 0);Ms(this,Bs,void 0);Ms(this,Tl,void 0);Lo(this,Tl,null),this.update=s=>{kt(this,Bs).update(s)},this.show=s=>{Lo(this,Tl,s),kt(this,sr).filter="",kt(this,Bs).show()},this.hide=()=>{Lo(this,Tl,null),kt(this,Bs).hide()},this.destroy=()=>{kt(this,Bs).destroy(),kt(this,sr).remove()},Lo(this,sr,new cR),kt(this,sr).hide=this.hide,kt(this,sr).ctx=t,kt(this,sr).config=o;const r=this;Lo(this,Bs,new PVe({content:kt(this,sr),debounce:20,shouldShow(s){if(iR(s.state.selection)||lR(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,Tl);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,Tl,null),!1):!0:!!i.startsWith("/")},offset:10})),kt(this,Bs).onShow=()=>{kt(this,sr).show=!0},kt(this,Bs).onHide=()=>{kt(this,sr).show=!1},this.update(n),t.set(fR.key,{show:s=>this.show(s),hide:()=>this.hide()})}}sr=new WeakMap,Bs=new WeakMap,Tl=new WeakMap;const HVe=(e,t)=>{e.config(n=>zVe(n,t)).use(fR).use(Hk).use(dR)},UVe=Object.freeze(Object.defineProperty({__proto__:null,defineFeature:HVe},Symbol.toStringTag,{value:"Module"}));function WVe(e){var t;return e.childCount<=1&&!((t=e.firstChild)!=null&&t.content.size)}function KVe(e,t){const{selection:n}=e;if(!n.empty)return null;const o=n.$anchor,r=o.parent;if(r.content.size>0||dC(l=>l.type.name==="table")(o))return null;const i=o.before();return Un.node(i,i+r.nodeSize,{class:"crepe-placeholder","data-placeholder":t})}const c0=An({text:"Please enter...",mode:"block"},"placeholderConfigCtx"),pR=ao(e=>new xn({key:new wn("CREPE_PLACEHOLDER"),props:{decorations:t=>{const n=e.get(c0.key);if(n.mode==="doc"&&!WVe(t.doc)||iR(t.selection)||lR(t.selection))return null;const o=n.text??"Please enter...",r=KVe(t,o);return r?an.create(t.doc,[r]):null}}})),qVe=(e,t)=>{e.config(n=>{t&&n.update(c0.key,o=>({...o,...t}))}).use(pR).use(c0)},GVe=Object.freeze(Object.defineProperty({__proto__:null,defineFeature:qVe,placeholderConfig:c0,placeholderPlugin:pR},Symbol.toStringTag,{value:"Module"})),hR=({ctx:e,hide:t,show:n,config:o})=>{var l,a,u,c,d;const r=EL();a0(()=>{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(Vt).call(yv.key)})} |
| 480 |
> |
| 481 |
${((l=o==null?void 0:o.boldIcon)==null?void 0:l.call(o))??KDe} |
| 482 |
</button> |
| 483 |
<button |
| 484 |
class=${ac("toolbar-item",e&&i(xu.type(e))&&"active")} |
| 485 |
onmousedown=${s(f=>{f.get(Vt).call(vv.key)})} |
| 486 |
> |
| 487 |
${((a=o==null?void 0:o.italicIcon)==null?void 0:a.call(o))??QDe} |
| 488 |
</button> |
| 489 |
<button |
| 490 |
class=${ac("toolbar-item",e&&i(Rd.type(e))&&"active")} |
| 491 |
onmousedown=${s(f=>{f.get(Vt).call(Cv.key)})} |
| 492 |
> |
| 493 |
${((u=o==null?void 0:o.strikethroughIcon)==null?void 0:u.call(o))??oVe} |
| 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(Vt).call(_v.key)})} |
| 499 |
> |
| 500 |
${((c=o==null?void 0:o.codeIcon)==null?void 0:c.call(o))??QL} |
| 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))??eR} |
| 507 |
</button> |
| 508 |
</host>`};hR.props={ctx:Object,hide:Function,show:Boolean,config:Object};const mR=Hh(hR),_$=Fk("CREPE_TOOLBAR");var _i,$o;class YVe{constructor(t,n,o){Ms(this,_i,void 0);Ms(this,$o,void 0);this.update=(s,i)=>{kt(this,_i).update(s,i)},this.destroy=()=>{kt(this,_i).destroy(),kt(this,$o).remove()},this.hide=()=>{kt(this,_i).hide()};const r=new mR;Lo(this,$o,r),kt(this,$o).ctx=t,kt(this,$o).hide=this.hide,kt(this,$o).config=o,Lo(this,_i,new Vk({content:kt(this,$o),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,$o).show=!0,setTimeout(()=>{let s=kt(this,$o).style.left;s=parseInt(s),console.log(s),s<0?(kt(this,$o).style.left=0,console.log(kt(this,$o))):s>350&&(kt(this,$o).style.left="350px")},0)},kt(this,_i).onHide=()=>{kt(this,$o).show=!1},this.update(n)}}_i=new WeakMap,$o=new WeakMap;aR("milkdown-toolbar",mR);const ZVe=(e,t)=>{e.config(n=>{n.set(_$.key,{view:o=>new YVe(n,o,t)})}).use(_$)},JVe=Object.freeze(Object.defineProperty({__proto__:null,defineFeature:ZVe},Symbol.toStringTag,{value:"Module"})),XVe="",QVe=Object.freeze(Object.defineProperty({__proto__:null,default:XVe},Symbol.toStringTag,{value:"Module"}))});export default eFe(); |
| 509 |
|