mirror of
https://github.com/Physton/sd-webui-prompt-all-in-one.git
synced 2026-01-26 19:29:56 +00:00
133 lines
614 KiB
JavaScript
133 lines
614 KiB
JavaScript
(function(tr){typeof define=="function"&&define.amd?define(tr):tr()})(function(){"use strict";var U3=Object.defineProperty;var W3=(tr,bt,nr)=>bt in tr?U3(tr,bt,{enumerable:!0,configurable:!0,writable:!0,value:nr}):tr[bt]=nr;var Gb=(tr,bt,nr)=>(W3(tr,typeof bt!="symbol"?bt+"":bt,nr),nr);function tr(e,t){const n=Object.create(null),r=e.split(",");for(let i=0;i<r.length;i++)n[r[i]]=!0;return t?i=>!!n[i.toLowerCase()]:i=>!!n[i]}const bt={},nr=[],vr=()=>{},Yb=()=>!1,Xb=/^on[^a-z]/,Wa=e=>Xb.test(e),qu=e=>e.startsWith("onUpdate:"),Yt=Object.assign,zu=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},Jb=Object.prototype.hasOwnProperty,Ct=(e,t)=>Jb.call(e,t),qe=Array.isArray,po=e=>ws(e)==="[object Map]",ho=e=>ws(e)==="[object Set]",Tp=e=>ws(e)==="[object Date]",ct=e=>typeof e=="function",Ht=e=>typeof e=="string",_s=e=>typeof e=="symbol",It=e=>e!==null&&typeof e=="object",kp=e=>It(e)&&ct(e.then)&&ct(e.catch),xp=Object.prototype.toString,ws=e=>xp.call(e),Zb=e=>ws(e).slice(8,-1),Sp=e=>ws(e)==="[object Object]",Gu=e=>Ht(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Ka=tr(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Va=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},Qb=/-(\w)/g,Ar=Va(e=>e.replace(Qb,(t,n)=>n?n.toUpperCase():"")),eC=/\B([A-Z])/g,go=Va(e=>e.replace(eC,"-$1").toLowerCase()),qa=Va(e=>e.charAt(0).toUpperCase()+e.slice(1)),Yu=Va(e=>e?`on${qa(e)}`:""),Ts=(e,t)=>!Object.is(e,t),za=(e,t)=>{for(let n=0;n<e.length;n++)e[n](t)},Ga=(e,t,n)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},Ya=e=>{const t=parseFloat(e);return isNaN(t)?e:t},tC=e=>{const t=Ht(e)?Number(e):NaN;return isNaN(t)?e:t};let Ap;const Xu=()=>Ap||(Ap=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function St(e){if(qe(e)){const t={};for(let n=0;n<e.length;n++){const r=e[n],i=Ht(r)?oC(r):St(r);if(i)for(const o in i)t[o]=i[o]}return t}else{if(Ht(e))return e;if(It(e))return e}}const nC=/;(?![^(]*\))/g,rC=/:([^]+)/,iC=/\/\*[^]*?\*\//g;function oC(e){const t={};return e.replace(iC,"").split(nC).forEach(n=>{if(n){const r=n.split(rC);r.length>1&&(t[r[0].trim()]=r[1].trim())}}),t}function Ge(e){let t="";if(Ht(e))t=e;else if(qe(e))for(let n=0;n<e.length;n++){const r=Ge(e[n]);r&&(t+=r+" ")}else if(It(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}const sC=tr("itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly");function Ep(e){return!!e||e===""}function aC(e,t){if(e.length!==t.length)return!1;let n=!0;for(let r=0;n&&r<e.length;r++)n=ks(e[r],t[r]);return n}function ks(e,t){if(e===t)return!0;let n=Tp(e),r=Tp(t);if(n||r)return n&&r?e.getTime()===t.getTime():!1;if(n=_s(e),r=_s(t),n||r)return e===t;if(n=qe(e),r=qe(t),n||r)return n&&r?aC(e,t):!1;if(n=It(e),r=It(t),n||r){if(!n||!r)return!1;const i=Object.keys(e).length,o=Object.keys(t).length;if(i!==o)return!1;for(const s in e){const l=e.hasOwnProperty(s),c=t.hasOwnProperty(s);if(l&&!c||!l&&c||!ks(e[s],t[s]))return!1}}return String(e)===String(t)}function Ju(e,t){return e.findIndex(n=>ks(n,t))}const ie=e=>Ht(e)?e:e==null?"":qe(e)||It(e)&&(e.toString===xp||!ct(e.toString))?JSON.stringify(e,Lp,2):String(e),Lp=(e,t)=>t&&t.__v_isRef?Lp(e,t.value):po(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[r,i])=>(n[`${r} =>`]=i,n),{})}:ho(t)?{[`Set(${t.size})`]:[...t.values()]}:It(t)&&!qe(t)&&!Sp(t)?String(t):t;let Kn;class lC{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this.parent=Kn,!t&&Kn&&(this.index=(Kn.scopes||(Kn.scopes=[])).push(this)-1)}get active(){return this._active}run(t){if(this._active){const n=Kn;try{return Kn=this,t()}finally{Kn=n}}}on(){Kn=this}off(){Kn=this.parent}stop(t){if(this._active){let n,r;for(n=0,r=this.effects.length;n<r;n++)this.effects[n].stop();for(n=0,r=this.cleanups.length;n<r;n++)this.cleanups[n]();if(this.scopes)for(n=0,r=this.scopes.length;n<r;n++)this.scopes[n].stop(!0);if(!this.detached&&this.parent&&!t){const i=this.parent.scopes.pop();i&&i!==this&&(this.parent.scopes[this.index]=i,i.index=this.index)}this.parent=void 0,this._active=!1}}}function uC(e,t=Kn){t&&t.active&&t.effects.push(e)}function Op(){return Kn}function cC(e){Kn&&Kn.cleanups.push(e)}const Zu=e=>{const t=new Set(e);return t.w=0,t.n=0,t},Ip=e=>(e.w&ui)>0,Pp=e=>(e.n&ui)>0,fC=({deps:e})=>{if(e.length)for(let t=0;t<e.length;t++)e[t].w|=ui},dC=e=>{const{deps:t}=e;if(t.length){let n=0;for(let r=0;r<t.length;r++){const i=t[r];Ip(i)&&!Pp(i)?i.delete(e):t[n++]=i,i.w&=~ui,i.n&=~ui}t.length=n}},Qu=new WeakMap;let xs=0,ui=1;const ec=30;let yr;const Di=Symbol(""),tc=Symbol("");class nc{constructor(t,n=null,r){this.fn=t,this.scheduler=n,this.active=!0,this.deps=[],this.parent=void 0,uC(this,r)}run(){if(!this.active)return this.fn();let t=yr,n=ci;for(;t;){if(t===this)return;t=t.parent}try{return this.parent=yr,yr=this,ci=!0,ui=1<<++xs,xs<=ec?fC(this):Dp(this),this.fn()}finally{xs<=ec&&dC(this),ui=1<<--xs,yr=this.parent,ci=n,this.parent=void 0,this.deferStop&&this.stop()}}stop(){yr===this?this.deferStop=!0:this.active&&(Dp(this),this.onStop&&this.onStop(),this.active=!1)}}function Dp(e){const{deps:t}=e;if(t.length){for(let n=0;n<t.length;n++)t[n].delete(e);t.length=0}}let ci=!0;const Rp=[];function mo(){Rp.push(ci),ci=!1}function vo(){const e=Rp.pop();ci=e===void 0?!0:e}function Pn(e,t,n){if(ci&&yr){let r=Qu.get(e);r||Qu.set(e,r=new Map);let i=r.get(n);i||r.set(n,i=Zu()),Np(i)}}function Np(e,t){let n=!1;xs<=ec?Pp(e)||(e.n|=ui,n=!Ip(e)):n=!e.has(yr),n&&(e.add(yr),yr.deps.push(e))}function qr(e,t,n,r,i,o){const s=Qu.get(e);if(!s)return;let l=[];if(t==="clear")l=[...s.values()];else if(n==="length"&&qe(e)){const c=Number(r);s.forEach((d,p)=>{(p==="length"||p>=c)&&l.push(d)})}else switch(n!==void 0&&l.push(s.get(n)),t){case"add":qe(e)?Gu(n)&&l.push(s.get("length")):(l.push(s.get(Di)),po(e)&&l.push(s.get(tc)));break;case"delete":qe(e)||(l.push(s.get(Di)),po(e)&&l.push(s.get(tc)));break;case"set":po(e)&&l.push(s.get(Di));break}if(l.length===1)l[0]&&rc(l[0]);else{const c=[];for(const d of l)d&&c.push(...d);rc(Zu(c))}}function rc(e,t){const n=qe(e)?e:[...e];for(const r of n)r.computed&&Mp(r);for(const r of n)r.computed||Mp(r)}function Mp(e,t){(e!==yr||e.allowRecurse)&&(e.scheduler?e.scheduler():e.run())}const pC=tr("__proto__,__v_isRef,__isVue"),Fp=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(_s)),hC=ic(),gC=ic(!1,!0),mC=ic(!0),Bp=vC();function vC(){const e={};return["includes","indexOf","lastIndexOf"].forEach(t=>{e[t]=function(...n){const r=xt(this);for(let o=0,s=this.length;o<s;o++)Pn(r,"get",o+"");const i=r[t](...n);return i===-1||i===!1?r[t](...n.map(xt)):i}}),["push","pop","shift","unshift","splice"].forEach(t=>{e[t]=function(...n){mo();const r=xt(this)[t].apply(this,n);return vo(),r}}),e}function yC(e){const t=xt(this);return Pn(t,"has",e),t.hasOwnProperty(e)}function ic(e=!1,t=!1){return function(r,i,o){if(i==="__v_isReactive")return!e;if(i==="__v_isReadonly")return e;if(i==="__v_isShallow")return t;if(i==="__v_raw"&&o===(e?t?RC:zp:t?qp:Vp).get(r))return r;const s=qe(r);if(!e){if(s&&Ct(Bp,i))return Reflect.get(Bp,i,o);if(i==="hasOwnProperty")return yC}const l=Reflect.get(r,i,o);return(_s(i)?Fp.has(i):pC(i))||(e||Pn(r,"get",i),t)?l:yn(l)?s&&Gu(i)?l:l.value:It(l)?e?ac(l):Dn(l):l}}const bC=$p(),CC=$p(!0);function $p(e=!1){return function(n,r,i,o){let s=n[r];if(bo(s)&&yn(s)&&!yn(i))return!1;if(!e&&(!nl(i)&&!bo(i)&&(s=xt(s),i=xt(i)),!qe(n)&&yn(s)&&!yn(i)))return s.value=i,!0;const l=qe(n)&&Gu(r)?Number(r)<n.length:Ct(n,r),c=Reflect.set(n,r,i,o);return n===xt(o)&&(l?Ts(i,s)&&qr(n,"set",r,i):qr(n,"add",r,i)),c}}function _C(e,t){const n=Ct(e,t);e[t];const r=Reflect.deleteProperty(e,t);return r&&n&&qr(e,"delete",t,void 0),r}function wC(e,t){const n=Reflect.has(e,t);return(!_s(t)||!Fp.has(t))&&Pn(e,"has",t),n}function TC(e){return Pn(e,"iterate",qe(e)?"length":Di),Reflect.ownKeys(e)}const Hp={get:hC,set:bC,deleteProperty:_C,has:wC,ownKeys:TC},kC={get:mC,set(e,t){return!0},deleteProperty(e,t){return!0}},xC=Yt({},Hp,{get:gC,set:CC}),oc=e=>e,Xa=e=>Reflect.getPrototypeOf(e);function Ja(e,t,n=!1,r=!1){e=e.__v_raw;const i=xt(e),o=xt(t);n||(t!==o&&Pn(i,"get",t),Pn(i,"get",o));const{has:s}=Xa(i),l=r?oc:n?uc:Ss;if(s.call(i,t))return l(e.get(t));if(s.call(i,o))return l(e.get(o));e!==i&&e.get(t)}function Za(e,t=!1){const n=this.__v_raw,r=xt(n),i=xt(e);return t||(e!==i&&Pn(r,"has",e),Pn(r,"has",i)),e===i?n.has(e):n.has(e)||n.has(i)}function Qa(e,t=!1){return e=e.__v_raw,!t&&Pn(xt(e),"iterate",Di),Reflect.get(e,"size",e)}function jp(e){e=xt(e);const t=xt(this);return Xa(t).has.call(t,e)||(t.add(e),qr(t,"add",e,e)),this}function Up(e,t){t=xt(t);const n=xt(this),{has:r,get:i}=Xa(n);let o=r.call(n,e);o||(e=xt(e),o=r.call(n,e));const s=i.call(n,e);return n.set(e,t),o?Ts(t,s)&&qr(n,"set",e,t):qr(n,"add",e,t),this}function Wp(e){const t=xt(this),{has:n,get:r}=Xa(t);let i=n.call(t,e);i||(e=xt(e),i=n.call(t,e)),r&&r.call(t,e);const o=t.delete(e);return i&&qr(t,"delete",e,void 0),o}function Kp(){const e=xt(this),t=e.size!==0,n=e.clear();return t&&qr(e,"clear",void 0,void 0),n}function el(e,t){return function(r,i){const o=this,s=o.__v_raw,l=xt(s),c=t?oc:e?uc:Ss;return!e&&Pn(l,"iterate",Di),s.forEach((d,p)=>r.call(i,c(d),c(p),o))}}function tl(e,t,n){return function(...r){const i=this.__v_raw,o=xt(i),s=po(o),l=e==="entries"||e===Symbol.iterator&&s,c=e==="keys"&&s,d=i[e](...r),p=n?oc:t?uc:Ss;return!t&&Pn(o,"iterate",c?tc:Di),{next(){const{value:y,done:m}=d.next();return m?{value:y,done:m}:{value:l?[p(y[0]),p(y[1])]:p(y),done:m}},[Symbol.iterator](){return this}}}}function fi(e){return function(...t){return e==="delete"?!1:this}}function SC(){const e={get(o){return Ja(this,o)},get size(){return Qa(this)},has:Za,add:jp,set:Up,delete:Wp,clear:Kp,forEach:el(!1,!1)},t={get(o){return Ja(this,o,!1,!0)},get size(){return Qa(this)},has:Za,add:jp,set:Up,delete:Wp,clear:Kp,forEach:el(!1,!0)},n={get(o){return Ja(this,o,!0)},get size(){return Qa(this,!0)},has(o){return Za.call(this,o,!0)},add:fi("add"),set:fi("set"),delete:fi("delete"),clear:fi("clear"),forEach:el(!0,!1)},r={get(o){return Ja(this,o,!0,!0)},get size(){return Qa(this,!0)},has(o){return Za.call(this,o,!0)},add:fi("add"),set:fi("set"),delete:fi("delete"),clear:fi("clear"),forEach:el(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(o=>{e[o]=tl(o,!1,!1),n[o]=tl(o,!0,!1),t[o]=tl(o,!1,!0),r[o]=tl(o,!0,!0)}),[e,n,t,r]}const[AC,EC,LC,OC]=SC();function sc(e,t){const n=t?e?OC:LC:e?EC:AC;return(r,i,o)=>i==="__v_isReactive"?!e:i==="__v_isReadonly"?e:i==="__v_raw"?r:Reflect.get(Ct(n,i)&&i in r?n:r,i,o)}const IC={get:sc(!1,!1)},PC={get:sc(!1,!0)},DC={get:sc(!0,!1)},Vp=new WeakMap,qp=new WeakMap,zp=new WeakMap,RC=new WeakMap;function NC(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function MC(e){return e.__v_skip||!Object.isExtensible(e)?0:NC(Zb(e))}function Dn(e){return bo(e)?e:lc(e,!1,Hp,IC,Vp)}function FC(e){return lc(e,!1,xC,PC,qp)}function ac(e){return lc(e,!0,kC,DC,zp)}function lc(e,t,n,r,i){if(!It(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const o=i.get(e);if(o)return o;const s=MC(e);if(s===0)return e;const l=new Proxy(e,s===2?r:n);return i.set(e,l),l}function yo(e){return bo(e)?yo(e.__v_raw):!!(e&&e.__v_isReactive)}function bo(e){return!!(e&&e.__v_isReadonly)}function nl(e){return!!(e&&e.__v_isShallow)}function Gp(e){return yo(e)||bo(e)}function xt(e){const t=e&&e.__v_raw;return t?xt(t):e}function Yp(e){return Ga(e,"__v_skip",!0),e}const Ss=e=>It(e)?Dn(e):e,uc=e=>It(e)?ac(e):e;function Xp(e){ci&&yr&&(e=xt(e),Np(e.dep||(e.dep=Zu())))}function Jp(e,t){e=xt(e);const n=e.dep;n&&rc(n)}function yn(e){return!!(e&&e.__v_isRef===!0)}function Lt(e){return Zp(e,!1)}function BC(e){return Zp(e,!0)}function Zp(e,t){return yn(e)?e:new $C(e,t)}class $C{constructor(t,n){this.__v_isShallow=n,this.dep=void 0,this.__v_isRef=!0,this._rawValue=n?t:xt(t),this._value=n?t:Ss(t)}get value(){return Xp(this),this._value}set value(t){const n=this.__v_isShallow||nl(t)||bo(t);t=n?t:xt(t),Ts(t,this._rawValue)&&(this._rawValue=t,this._value=n?t:Ss(t),Jp(this))}}function Qp(e){return yn(e)?e.value:e}const HC={get:(e,t,n)=>Qp(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const i=e[t];return yn(i)&&!yn(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function eh(e){return yo(e)?e:new Proxy(e,HC)}class jC{constructor(t,n,r,i){this._setter=n,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new nc(t,()=>{this._dirty||(this._dirty=!0,Jp(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!i,this.__v_isReadonly=r}get value(){const t=xt(this);return Xp(t),(t._dirty||!t._cacheable)&&(t._dirty=!1,t._value=t.effect.run()),t._value}set value(t){this._setter(t)}}function UC(e,t,n=!1){let r,i;const o=ct(e);return o?(r=e,i=vr):(r=e.get,i=e.set),new jC(r,i,o||!i,n)}function V3(e,...t){}function di(e,t,n,r){let i;try{i=r?e(...r):e()}catch(o){rl(o,t,n)}return i}function rr(e,t,n,r){if(ct(e)){const o=di(e,t,n,r);return o&&kp(o)&&o.catch(s=>{rl(s,t,n)}),o}const i=[];for(let o=0;o<e.length;o++)i.push(rr(e[o],t,n,r));return i}function rl(e,t,n,r=!0){const i=t?t.vnode:null;if(t){let o=t.parent;const s=t.proxy,l=n;for(;o;){const d=o.ec;if(d){for(let p=0;p<d.length;p++)if(d[p](e,s,l)===!1)return}o=o.parent}const c=t.appContext.config.errorHandler;if(c){di(c,null,10,[e,s,l]);return}}WC(e,n,i,r)}function WC(e,t,n,r=!0){console.error(e)}let As=!1,cc=!1;const bn=[];let Er=0;const Co=[];let zr=null,Ri=0;const th=Promise.resolve();let fc=null;function il(e){const t=fc||th;return e?t.then(this?e.bind(this):e):t}function KC(e){let t=Er+1,n=bn.length;for(;t<n;){const r=t+n>>>1;Es(bn[r])<e?t=r+1:n=r}return t}function dc(e){(!bn.length||!bn.includes(e,As&&e.allowRecurse?Er+1:Er))&&(e.id==null?bn.push(e):bn.splice(KC(e.id),0,e),nh())}function nh(){!As&&!cc&&(cc=!0,fc=th.then(oh))}function VC(e){const t=bn.indexOf(e);t>Er&&bn.splice(t,1)}function qC(e){qe(e)?Co.push(...e):(!zr||!zr.includes(e,e.allowRecurse?Ri+1:Ri))&&Co.push(e),nh()}function rh(e,t=As?Er+1:0){for(;t<bn.length;t++){const n=bn[t];n&&n.pre&&(bn.splice(t,1),t--,n())}}function ih(e){if(Co.length){const t=[...new Set(Co)];if(Co.length=0,zr){zr.push(...t);return}for(zr=t,zr.sort((n,r)=>Es(n)-Es(r)),Ri=0;Ri<zr.length;Ri++)zr[Ri]();zr=null,Ri=0}}const Es=e=>e.id==null?1/0:e.id,zC=(e,t)=>{const n=Es(e)-Es(t);if(n===0){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function oh(e){cc=!1,As=!0,bn.sort(zC);const t=vr;try{for(Er=0;Er<bn.length;Er++){const n=bn[Er];n&&n.active!==!1&&di(n,null,14)}}finally{Er=0,bn.length=0,ih(),As=!1,fc=null,(bn.length||Co.length)&&oh()}}function GC(e,t,...n){if(e.isUnmounted)return;const r=e.vnode.props||bt;let i=n;const o=t.startsWith("update:"),s=o&&t.slice(7);if(s&&s in r){const p=`${s==="modelValue"?"model":s}Modifiers`,{number:y,trim:m}=r[p]||bt;m&&(i=n.map(C=>Ht(C)?C.trim():C)),y&&(i=n.map(Ya))}let l,c=r[l=Yu(t)]||r[l=Yu(Ar(t))];!c&&o&&(c=r[l=Yu(go(t))]),c&&rr(c,e,6,i);const d=r[l+"Once"];if(d){if(!e.emitted)e.emitted={};else if(e.emitted[l])return;e.emitted[l]=!0,rr(d,e,6,i)}}function sh(e,t,n=!1){const r=t.emitsCache,i=r.get(e);if(i!==void 0)return i;const o=e.emits;let s={},l=!1;if(!ct(e)){const c=d=>{const p=sh(d,t,!0);p&&(l=!0,Yt(s,p))};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}return!o&&!l?(It(e)&&r.set(e,null),null):(qe(o)?o.forEach(c=>s[c]=null):Yt(s,o),It(e)&&r.set(e,s),s)}function ol(e,t){return!e||!Wa(t)?!1:(t=t.slice(2).replace(/Once$/,""),Ct(e,t[0].toLowerCase()+t.slice(1))||Ct(e,go(t))||Ct(e,t))}let dn=null,sl=null;function al(e){const t=dn;return dn=e,sl=e&&e.type.__scopeId||null,t}function _o(e){sl=e}function wo(){sl=null}function tn(e,t=dn,n){if(!t||e._n)return e;const r=(...i)=>{r._d&&$h(-1);const o=al(t);let s;try{s=e(...i)}finally{al(o),r._d&&$h(1)}return s};return r._n=!0,r._c=!0,r._d=!0,r}function q3(){}function pc(e){const{type:t,vnode:n,proxy:r,withProxy:i,props:o,propsOptions:[s],slots:l,attrs:c,emit:d,render:p,renderCache:y,data:m,setupState:C,ctx:b,inheritAttrs:k}=e;let L,O;const $=al(e);try{if(n.shapeFlag&4){const x=i||r;L=Lr(p.call(x,x,y,o,C,m,b)),O=c}else{const x=t;L=Lr(x.length>1?x(o,{attrs:c,slots:l,emit:d}):x(o,null)),O=t.props?c:YC(c)}}catch(x){Ds.length=0,rl(x,e,1),L=ye(sr)}let X=L;if(O&&k!==!1){const x=Object.keys(O),{shapeFlag:z}=X;x.length&&z&7&&(s&&x.some(qu)&&(O=XC(O,s)),X=pi(X,O))}return n.dirs&&(X=pi(X),X.dirs=X.dirs?X.dirs.concat(n.dirs):n.dirs),n.transition&&(X.transition=n.transition),L=X,al($),L}const YC=e=>{let t;for(const n in e)(n==="class"||n==="style"||Wa(n))&&((t||(t={}))[n]=e[n]);return t},XC=(e,t)=>{const n={};for(const r in e)(!qu(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function JC(e,t,n){const{props:r,children:i,component:o}=e,{props:s,children:l,patchFlag:c}=t,d=o.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return r?ah(r,s,d):!!s;if(c&8){const p=t.dynamicProps;for(let y=0;y<p.length;y++){const m=p[y];if(s[m]!==r[m]&&!ol(d,m))return!0}}}else return(i||l)&&(!l||!l.$stable)?!0:r===s?!1:r?s?ah(r,s,d):!0:!!s;return!1}function ah(e,t,n){const r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let i=0;i<r.length;i++){const o=r[i];if(t[o]!==e[o]&&!ol(n,o))return!0}return!1}function ZC({vnode:e,parent:t},n){for(;t&&t.subTree===e;)(e=t.vnode).el=n,t=t.parent}const QC=e=>e.__isSuspense;function e_(e,t){t&&t.pendingBranch?qe(e)?t.effects.push(...e):t.effects.push(e):qC(e)}const ll={};function ir(e,t,n){return lh(e,t,n)}function lh(e,t,{immediate:n,deep:r,flush:i,onTrack:o,onTrigger:s}=bt){var l;const c=Op()===((l=ln)==null?void 0:l.scope)?ln:null;let d,p=!1,y=!1;if(yn(e)?(d=()=>e.value,p=nl(e)):yo(e)?(d=()=>e,r=!0):qe(e)?(y=!0,p=e.some(x=>yo(x)||nl(x)),d=()=>e.map(x=>{if(yn(x))return x.value;if(yo(x))return Ni(x);if(ct(x))return di(x,c,2)})):ct(e)?t?d=()=>di(e,c,2):d=()=>{if(!(c&&c.isUnmounted))return m&&m(),rr(e,c,3,[C])}:d=vr,t&&r){const x=d;d=()=>Ni(x())}let m,C=x=>{m=$.onStop=()=>{di(x,c,4)}},b;if(Ns)if(C=vr,t?n&&rr(t,c,3,[d(),y?[]:void 0,C]):d(),i==="sync"){const x=X_();b=x.__watcherHandles||(x.__watcherHandles=[])}else return vr;let k=y?new Array(e.length).fill(ll):ll;const L=()=>{if($.active)if(t){const x=$.run();(r||p||(y?x.some((z,Q)=>Ts(z,k[Q])):Ts(x,k)))&&(m&&m(),rr(t,c,3,[x,k===ll?void 0:y&&k[0]===ll?[]:k,C]),k=x)}else $.run()};L.allowRecurse=!!t;let O;i==="sync"?O=L:i==="post"?O=()=>Nn(L,c&&c.suspense):(L.pre=!0,c&&(L.id=c.uid),O=()=>dc(L));const $=new nc(d,O);t?n?L():k=$.run():i==="post"?Nn($.run.bind($),c&&c.suspense):$.run();const X=()=>{$.stop(),c&&c.scope&&zu(c.scope.effects,$)};return b&&b.push(X),X}function t_(e,t,n){const r=this.proxy,i=Ht(e)?e.includes(".")?uh(r,e):()=>r[e]:e.bind(r,r);let o;ct(t)?o=t:(o=t.handler,n=t);const s=ln;So(this);const l=lh(i,o.bind(r),n);return s?So(s):$i(),l}function uh(e,t){const n=t.split(".");return()=>{let r=e;for(let i=0;i<n.length&&r;i++)r=r[n[i]];return r}}function Ni(e,t){if(!It(e)||e.__v_skip||(t=t||new Set,t.has(e)))return e;if(t.add(e),yn(e))Ni(e.value,t);else if(qe(e))for(let n=0;n<e.length;n++)Ni(e[n],t);else if(ho(e)||po(e))e.forEach(n=>{Ni(n,t)});else if(Sp(e))for(const n in e)Ni(e[n],t);return e}function ge(e,t){const n=dn;if(n===null)return e;const r=Cl(n)||n.proxy,i=e.dirs||(e.dirs=[]);for(let o=0;o<t.length;o++){let[s,l,c,d=bt]=t[o];s&&(ct(s)&&(s={mounted:s,updated:s}),s.deep&&Ni(l),i.push({dir:s,instance:r,value:l,oldValue:void 0,arg:c,modifiers:d}))}return e}function Mi(e,t,n,r){const i=e.dirs,o=t&&t.dirs;for(let s=0;s<i.length;s++){const l=i[s];o&&(l.oldValue=o[s].value);let c=l.dir[r];c&&(mo(),rr(c,n,8,[e.el,l,e,t]),vo())}}function n_(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return fl(()=>{e.isMounted=!0}),gh(()=>{e.isUnmounting=!0}),e}const or=[Function,Array],ch={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:or,onEnter:or,onAfterEnter:or,onEnterCancelled:or,onBeforeLeave:or,onLeave:or,onAfterLeave:or,onLeaveCancelled:or,onBeforeAppear:or,onAppear:or,onAfterAppear:or,onAppearCancelled:or},r_={name:"BaseTransition",props:ch,setup(e,{slots:t}){const n=Ic(),r=n_();let i;return()=>{const o=t.default&&ph(t.default(),!0);if(!o||!o.length)return;let s=o[0];if(o.length>1){for(const k of o)if(k.type!==sr){s=k;break}}const l=xt(e),{mode:c}=l;if(r.isLeaving)return gc(s);const d=dh(s);if(!d)return gc(s);const p=hc(d,l,r,n);mc(d,p);const y=n.subTree,m=y&&dh(y);let C=!1;const{getTransitionKey:b}=d.type;if(b){const k=b();i===void 0?i=k:k!==i&&(i=k,C=!0)}if(m&&m.type!==sr&&(!Bi(d,m)||C)){const k=hc(m,l,r,n);if(mc(m,k),c==="out-in")return r.isLeaving=!0,k.afterLeave=()=>{r.isLeaving=!1,n.update.active!==!1&&n.update()},gc(s);c==="in-out"&&d.type!==sr&&(k.delayLeave=(L,O,$)=>{const X=fh(r,m);X[String(m.key)]=m,L._leaveCb=()=>{O(),L._leaveCb=void 0,delete p.delayedLeave},p.delayedLeave=$})}return s}}};function fh(e,t){const{leavingVNodes:n}=e;let r=n.get(t.type);return r||(r=Object.create(null),n.set(t.type,r)),r}function hc(e,t,n,r){const{appear:i,mode:o,persisted:s=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:d,onEnterCancelled:p,onBeforeLeave:y,onLeave:m,onAfterLeave:C,onLeaveCancelled:b,onBeforeAppear:k,onAppear:L,onAfterAppear:O,onAppearCancelled:$}=t,X=String(e.key),x=fh(n,e),z=(I,A)=>{I&&rr(I,r,9,A)},Q=(I,A)=>{const D=A[1];z(I,A),qe(I)?I.every(H=>H.length<=1)&&D():I.length<=1&&D()},g={mode:o,persisted:s,beforeEnter(I){let A=l;if(!n.isMounted)if(i)A=k||l;else return;I._leaveCb&&I._leaveCb(!0);const D=x[X];D&&Bi(e,D)&&D.el._leaveCb&&D.el._leaveCb(),z(A,[I])},enter(I){let A=c,D=d,H=p;if(!n.isMounted)if(i)A=L||c,D=O||d,H=$||p;else return;let K=!1;const U=I._enterCb=de=>{K||(K=!0,de?z(H,[I]):z(D,[I]),g.delayedLeave&&g.delayedLeave(),I._enterCb=void 0)};A?Q(A,[I,U]):U()},leave(I,A){const D=String(e.key);if(I._enterCb&&I._enterCb(!0),n.isUnmounting)return A();z(y,[I]);let H=!1;const K=I._leaveCb=U=>{H||(H=!0,A(),U?z(b,[I]):z(C,[I]),I._leaveCb=void 0,x[D]===e&&delete x[D])};x[D]=e,m?Q(m,[I,K]):K()},clone(I){return hc(I,t,n,r)}};return g}function gc(e){if(ul(e))return e=pi(e),e.children=null,e}function dh(e){return ul(e)?e.children?e.children[0]:void 0:e}function mc(e,t){e.shapeFlag&6&&e.component?mc(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 ph(e,t=!1,n){let r=[],i=0;for(let o=0;o<e.length;o++){let s=e[o];const l=n==null?s.key:String(n)+String(s.key!=null?s.key:o);s.type===De?(s.patchFlag&128&&i++,r=r.concat(ph(s.children,t,l))):(t||s.type!==sr)&&r.push(l!=null?pi(s,{key:l}):s)}if(i>1)for(let o=0;o<r.length;o++)r[o].patchFlag=-2;return r}function Rn(e,t){return ct(e)?(()=>Yt({name:e.name},t,{setup:e}))():e}const Ls=e=>!!e.type.__asyncLoader,ul=e=>e.type.__isKeepAlive;function i_(e,t){hh(e,"a",t)}function o_(e,t){hh(e,"da",t)}function hh(e,t,n=ln){const r=e.__wdc||(e.__wdc=()=>{let i=n;for(;i;){if(i.isDeactivated)return;i=i.parent}return e()});if(cl(t,r,n),n){let i=n.parent;for(;i&&i.parent;)ul(i.parent.vnode)&&s_(r,t,n,i),i=i.parent}}function s_(e,t,n,r){const i=cl(t,e,r,!0);mh(()=>{zu(r[t],i)},n)}function cl(e,t,n=ln,r=!1){if(n){const i=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...s)=>{if(n.isUnmounted)return;mo(),So(n);const l=rr(t,n,e,s);return $i(),vo(),l});return r?i.unshift(o):i.push(o),o}}const Gr=e=>(t,n=ln)=>(!Ns||e==="sp")&&cl(e,(...r)=>t(...r),n),a_=Gr("bm"),fl=Gr("m"),l_=Gr("bu"),u_=Gr("u"),gh=Gr("bum"),mh=Gr("um"),c_=Gr("sp"),f_=Gr("rtg"),d_=Gr("rtc");function p_(e,t=ln){cl("ec",e,t)}const vc="components",h_="directives";function Ye(e,t){return yc(vc,e,!0,t)||e}const vh=Symbol.for("v-ndc");function yh(e){return Ht(e)?yc(vc,e,!1)||e:e||vh}function To(e){return yc(h_,e)}function yc(e,t,n=!0,r=!1){const i=dn||ln;if(i){const o=i.type;if(e===vc){const l=q_(o,!1);if(l&&(l===t||l===Ar(t)||l===qa(Ar(t))))return o}const s=bh(i[e]||o[e],t)||bh(i.appContext[e],t);return!s&&r?o:s}}function bh(e,t){return e&&(e[t]||e[Ar(t)]||e[qa(Ar(t))])}function ot(e,t,n,r){let i;const o=n&&n[r];if(qe(e)||Ht(e)){i=new Array(e.length);for(let s=0,l=e.length;s<l;s++)i[s]=t(e[s],s,void 0,o&&o[s])}else if(typeof e=="number"){i=new Array(e);for(let s=0;s<e;s++)i[s]=t(s+1,s,void 0,o&&o[s])}else if(It(e))if(e[Symbol.iterator])i=Array.from(e,(s,l)=>t(s,l,void 0,o&&o[l]));else{const s=Object.keys(e);i=new Array(s.length);for(let l=0,c=s.length;l<c;l++){const d=s[l];i[l]=t(e[d],d,l,o&&o[l])}}else i=[];return n&&(n[r]=i),i}function g_(e,t,n={},r,i){if(dn.isCE||dn.parent&&Ls(dn.parent)&&dn.parent.isCE)return t!=="default"&&(n.name=t),ye("slot",n,r&&r());let o=e[t];o&&o._c&&(o._d=!1),E();const s=o&&Ch(o(n)),l=Ue(De,{key:n.key||s&&s.key||`_${t}`},s||(r?r():[]),s&&e._===1?64:-2);return!i&&l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),o&&o._c&&(o._d=!0),l}function Ch(e){return e.some(t=>ml(t)?!(t.type===sr||t.type===De&&!Ch(t.children)):!0)?e:null}const bc=e=>e?Wh(e)?Cl(e)||e.proxy:bc(e.parent):null,Os=Yt(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=>bc(e.parent),$root:e=>bc(e.root),$emit:e=>e.emit,$options:e=>wc(e),$forceUpdate:e=>e.f||(e.f=()=>dc(e.update)),$nextTick:e=>e.n||(e.n=il.bind(e.proxy)),$watch:e=>t_.bind(e)}),Cc=(e,t)=>e!==bt&&!e.__isScriptSetup&&Ct(e,t),m_={get({_:e},t){const{ctx:n,setupState:r,data:i,props:o,accessCache:s,type:l,appContext:c}=e;let d;if(t[0]!=="$"){const C=s[t];if(C!==void 0)switch(C){case 1:return r[t];case 2:return i[t];case 4:return n[t];case 3:return o[t]}else{if(Cc(r,t))return s[t]=1,r[t];if(i!==bt&&Ct(i,t))return s[t]=2,i[t];if((d=e.propsOptions[0])&&Ct(d,t))return s[t]=3,o[t];if(n!==bt&&Ct(n,t))return s[t]=4,n[t];_c&&(s[t]=0)}}const p=Os[t];let y,m;if(p)return t==="$attrs"&&Pn(e,"get",t),p(e);if((y=l.__cssModules)&&(y=y[t]))return y;if(n!==bt&&Ct(n,t))return s[t]=4,n[t];if(m=c.config.globalProperties,Ct(m,t))return m[t]},set({_:e},t,n){const{data:r,setupState:i,ctx:o}=e;return Cc(i,t)?(i[t]=n,!0):r!==bt&&Ct(r,t)?(r[t]=n,!0):Ct(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:i,propsOptions:o}},s){let l;return!!n[s]||e!==bt&&Ct(e,s)||Cc(t,s)||(l=o[0])&&Ct(l,s)||Ct(r,s)||Ct(Os,s)||Ct(i.config.globalProperties,s)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:Ct(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function _h(e){return qe(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}let _c=!0;function v_(e){const t=wc(e),n=e.proxy,r=e.ctx;_c=!1,t.beforeCreate&&wh(t.beforeCreate,e,"bc");const{data:i,computed:o,methods:s,watch:l,provide:c,inject:d,created:p,beforeMount:y,mounted:m,beforeUpdate:C,updated:b,activated:k,deactivated:L,beforeDestroy:O,beforeUnmount:$,destroyed:X,unmounted:x,render:z,renderTracked:Q,renderTriggered:g,errorCaptured:I,serverPrefetch:A,expose:D,inheritAttrs:H,components:K,directives:U,filters:de}=t;if(d&&y_(d,r,null),s)for(const V in s){const ae=s[V];ct(ae)&&(r[V]=ae.bind(n))}if(i){const V=i.call(n,n);It(V)&&(e.data=Dn(V))}if(_c=!0,o)for(const V in o){const ae=o[V],pe=ct(ae)?ae.bind(n,n):ct(ae.get)?ae.get.bind(n,n):vr,Qe=!ct(ae)&&ct(ae.set)?ae.set.bind(n):vr,et=nn({get:pe,set:Qe});Object.defineProperty(r,V,{enumerable:!0,configurable:!0,get:()=>et.value,set:se=>et.value=se})}if(l)for(const V in l)Th(l[V],r,n,V);if(c){const V=ct(c)?c.call(n):c;Reflect.ownKeys(V).forEach(ae=>{Ah(ae,V[ae])})}p&&wh(p,e,"c");function Pe(V,ae){qe(ae)?ae.forEach(pe=>V(pe.bind(n))):ae&&V(ae.bind(n))}if(Pe(a_,y),Pe(fl,m),Pe(l_,C),Pe(u_,b),Pe(i_,k),Pe(o_,L),Pe(p_,I),Pe(d_,Q),Pe(f_,g),Pe(gh,$),Pe(mh,x),Pe(c_,A),qe(D))if(D.length){const V=e.exposed||(e.exposed={});D.forEach(ae=>{Object.defineProperty(V,ae,{get:()=>n[ae],set:pe=>n[ae]=pe})})}else e.exposed||(e.exposed={});z&&e.render===vr&&(e.render=z),H!=null&&(e.inheritAttrs=H),K&&(e.components=K),U&&(e.directives=U)}function y_(e,t,n=vr){qe(e)&&(e=Tc(e));for(const r in e){const i=e[r];let o;It(i)?"default"in i?o=ko(i.from||r,i.default,!0):o=ko(i.from||r):o=ko(i),yn(o)?Object.defineProperty(t,r,{enumerable:!0,configurable:!0,get:()=>o.value,set:s=>o.value=s}):t[r]=o}}function wh(e,t,n){rr(qe(e)?e.map(r=>r.bind(t.proxy)):e.bind(t.proxy),t,n)}function Th(e,t,n,r){const i=r.includes(".")?uh(n,r):()=>n[r];if(Ht(e)){const o=t[e];ct(o)&&ir(i,o)}else if(ct(e))ir(i,e.bind(n));else if(It(e))if(qe(e))e.forEach(o=>Th(o,t,n,r));else{const o=ct(e.handler)?e.handler.bind(n):t[e.handler];ct(o)&&ir(i,o,e)}}function wc(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:o,config:{optionMergeStrategies:s}}=e.appContext,l=o.get(t);let c;return l?c=l:!i.length&&!n&&!r?c=t:(c={},i.length&&i.forEach(d=>dl(c,d,s,!0)),dl(c,t,s)),It(t)&&o.set(t,c),c}function dl(e,t,n,r=!1){const{mixins:i,extends:o}=t;o&&dl(e,o,n,!0),i&&i.forEach(s=>dl(e,s,n,!0));for(const s in t)if(!(r&&s==="expose")){const l=b_[s]||n&&n[s];e[s]=l?l(e[s],t[s]):t[s]}return e}const b_={data:kh,props:xh,emits:xh,methods:Is,computed:Is,beforeCreate:An,created:An,beforeMount:An,mounted:An,beforeUpdate:An,updated:An,beforeDestroy:An,beforeUnmount:An,destroyed:An,unmounted:An,activated:An,deactivated:An,errorCaptured:An,serverPrefetch:An,components:Is,directives:Is,watch:__,provide:kh,inject:C_};function kh(e,t){return t?e?function(){return Yt(ct(e)?e.call(this,this):e,ct(t)?t.call(this,this):t)}:t:e}function C_(e,t){return Is(Tc(e),Tc(t))}function Tc(e){if(qe(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function An(e,t){return e?[...new Set([].concat(e,t))]:t}function Is(e,t){return e?Yt(Object.create(null),e,t):t}function xh(e,t){return e?qe(e)&&qe(t)?[...new Set([...e,...t])]:Yt(Object.create(null),_h(e),_h(t??{})):t}function __(e,t){if(!e)return t;if(!t)return e;const n=Yt(Object.create(null),e);for(const r in t)n[r]=An(e[r],t[r]);return n}function Sh(){return{app:null,config:{isNativeTag:Yb,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 w_=0;function T_(e,t){return function(r,i=null){ct(r)||(r=Yt({},r)),i!=null&&!It(i)&&(i=null);const o=Sh(),s=new Set;let l=!1;const c=o.app={_uid:w_++,_component:r,_props:i,_container:null,_context:o,_instance:null,version:J_,get config(){return o.config},set config(d){},use(d,...p){return s.has(d)||(d&&ct(d.install)?(s.add(d),d.install(c,...p)):ct(d)&&(s.add(d),d(c,...p))),c},mixin(d){return o.mixins.includes(d)||o.mixins.push(d),c},component(d,p){return p?(o.components[d]=p,c):o.components[d]},directive(d,p){return p?(o.directives[d]=p,c):o.directives[d]},mount(d,p,y){if(!l){const m=ye(r,i);return m.appContext=o,p&&t?t(m,d):e(m,d,y),l=!0,c._container=d,d.__vue_app__=c,Cl(m.component)||m.component.proxy}},unmount(){l&&(e(null,c._container),delete c._container.__vue_app__)},provide(d,p){return o.provides[d]=p,c},runWithContext(d){pl=c;try{return d()}finally{pl=null}}};return c}}let pl=null;function Ah(e,t){if(ln){let n=ln.provides;const r=ln.parent&&ln.parent.provides;r===n&&(n=ln.provides=Object.create(r)),n[e]=t}}function ko(e,t,n=!1){const r=ln||dn;if(r||pl){const i=r?r.parent==null?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:pl._context.provides;if(i&&e in i)return i[e];if(arguments.length>1)return n&&ct(t)?t.call(r&&r.proxy):t}}function k_(e,t,n,r=!1){const i={},o={};Ga(o,vl,1),e.propsDefaults=Object.create(null),Eh(e,t,i,o);for(const s in e.propsOptions[0])s in i||(i[s]=void 0);n?e.props=r?i:FC(i):e.type.props?e.props=i:e.props=o,e.attrs=o}function x_(e,t,n,r){const{props:i,attrs:o,vnode:{patchFlag:s}}=e,l=xt(i),[c]=e.propsOptions;let d=!1;if((r||s>0)&&!(s&16)){if(s&8){const p=e.vnode.dynamicProps;for(let y=0;y<p.length;y++){let m=p[y];if(ol(e.emitsOptions,m))continue;const C=t[m];if(c)if(Ct(o,m))C!==o[m]&&(o[m]=C,d=!0);else{const b=Ar(m);i[b]=kc(c,l,b,C,e,!1)}else C!==o[m]&&(o[m]=C,d=!0)}}}else{Eh(e,t,i,o)&&(d=!0);let p;for(const y in l)(!t||!Ct(t,y)&&((p=go(y))===y||!Ct(t,p)))&&(c?n&&(n[y]!==void 0||n[p]!==void 0)&&(i[y]=kc(c,l,y,void 0,e,!0)):delete i[y]);if(o!==l)for(const y in o)(!t||!Ct(t,y))&&(delete o[y],d=!0)}d&&qr(e,"set","$attrs")}function Eh(e,t,n,r){const[i,o]=e.propsOptions;let s=!1,l;if(t)for(let c in t){if(Ka(c))continue;const d=t[c];let p;i&&Ct(i,p=Ar(c))?!o||!o.includes(p)?n[p]=d:(l||(l={}))[p]=d:ol(e.emitsOptions,c)||(!(c in r)||d!==r[c])&&(r[c]=d,s=!0)}if(o){const c=xt(n),d=l||bt;for(let p=0;p<o.length;p++){const y=o[p];n[y]=kc(i,c,y,d[y],e,!Ct(d,y))}}return s}function kc(e,t,n,r,i,o){const s=e[n];if(s!=null){const l=Ct(s,"default");if(l&&r===void 0){const c=s.default;if(s.type!==Function&&!s.skipFactory&&ct(c)){const{propsDefaults:d}=i;n in d?r=d[n]:(So(i),r=d[n]=c.call(null,t),$i())}else r=c}s[0]&&(o&&!l?r=!1:s[1]&&(r===""||r===go(n))&&(r=!0))}return r}function Lh(e,t,n=!1){const r=t.propsCache,i=r.get(e);if(i)return i;const o=e.props,s={},l=[];let c=!1;if(!ct(e)){const p=y=>{c=!0;const[m,C]=Lh(y,t,!0);Yt(s,m),C&&l.push(...C)};!n&&t.mixins.length&&t.mixins.forEach(p),e.extends&&p(e.extends),e.mixins&&e.mixins.forEach(p)}if(!o&&!c)return It(e)&&r.set(e,nr),nr;if(qe(o))for(let p=0;p<o.length;p++){const y=Ar(o[p]);Oh(y)&&(s[y]=bt)}else if(o)for(const p in o){const y=Ar(p);if(Oh(y)){const m=o[p],C=s[y]=qe(m)||ct(m)?{type:m}:Yt({},m);if(C){const b=Dh(Boolean,C.type),k=Dh(String,C.type);C[0]=b>-1,C[1]=k<0||b<k,(b>-1||Ct(C,"default"))&&l.push(y)}}}const d=[s,l];return It(e)&&r.set(e,d),d}function Oh(e){return e[0]!=="$"}function Ih(e){const t=e&&e.toString().match(/^\s*(function|class) (\w+)/);return t?t[2]:e===null?"null":""}function Ph(e,t){return Ih(e)===Ih(t)}function Dh(e,t){return qe(t)?t.findIndex(n=>Ph(n,e)):ct(t)&&Ph(t,e)?0:-1}const Rh=e=>e[0]==="_"||e==="$stable",xc=e=>qe(e)?e.map(Lr):[Lr(e)],S_=(e,t,n)=>{if(t._n)return t;const r=tn((...i)=>xc(t(...i)),n);return r._c=!1,r},Nh=(e,t,n)=>{const r=e._ctx;for(const i in e){if(Rh(i))continue;const o=e[i];if(ct(o))t[i]=S_(i,o,r);else if(o!=null){const s=xc(o);t[i]=()=>s}}},Mh=(e,t)=>{const n=xc(t);e.slots.default=()=>n},A_=(e,t)=>{if(e.vnode.shapeFlag&32){const n=t._;n?(e.slots=xt(t),Ga(t,"_",n)):Nh(t,e.slots={})}else e.slots={},t&&Mh(e,t);Ga(e.slots,vl,1)},E_=(e,t,n)=>{const{vnode:r,slots:i}=e;let o=!0,s=bt;if(r.shapeFlag&32){const l=t._;l?n&&l===1?o=!1:(Yt(i,t),!n&&l===1&&delete i._):(o=!t.$stable,Nh(t,i)),s=t}else t&&(Mh(e,t),s={default:1});if(o)for(const l in i)!Rh(l)&&!(l in s)&&delete i[l]};function Sc(e,t,n,r,i=!1){if(qe(e)){e.forEach((m,C)=>Sc(m,t&&(qe(t)?t[C]:t),n,r,i));return}if(Ls(r)&&!i)return;const o=r.shapeFlag&4?Cl(r.component)||r.component.proxy:r.el,s=i?null:o,{i:l,r:c}=e,d=t&&t.r,p=l.refs===bt?l.refs={}:l.refs,y=l.setupState;if(d!=null&&d!==c&&(Ht(d)?(p[d]=null,Ct(y,d)&&(y[d]=null)):yn(d)&&(d.value=null)),ct(c))di(c,l,12,[s,p]);else{const m=Ht(c),C=yn(c);if(m||C){const b=()=>{if(e.f){const k=m?Ct(y,c)?y[c]:p[c]:c.value;i?qe(k)&&zu(k,o):qe(k)?k.includes(o)||k.push(o):m?(p[c]=[o],Ct(y,c)&&(y[c]=p[c])):(c.value=[o],e.k&&(p[e.k]=c.value))}else m?(p[c]=s,Ct(y,c)&&(y[c]=s)):C&&(c.value=s,e.k&&(p[e.k]=s))};s?(b.id=-1,Nn(b,n)):b()}}}const Nn=e_;function L_(e){return O_(e)}function O_(e,t){const n=Xu();n.__VUE__=!0;const{insert:r,remove:i,patchProp:o,createElement:s,createText:l,createComment:c,setText:d,setElementText:p,parentNode:y,nextSibling:m,setScopeId:C=vr,insertStaticContent:b}=e,k=(R,B,Y,oe=null,ee=null,te=null,ve=!1,me=null,be=!!B.dynamicChildren)=>{if(R===B)return;R&&!Bi(R,B)&&(oe=Be(R),se(R,ee,te,!0),R=null),B.patchFlag===-2&&(be=!1,B.dynamicChildren=null);const{type:ce,ref:Te,shapeFlag:_e}=B;switch(ce){case gl:L(R,B,Y,oe);break;case sr:O(R,B,Y,oe);break;case Lc:R==null&&$(B,Y,oe,ve);break;case De:K(R,B,Y,oe,ee,te,ve,me,be);break;default:_e&1?z(R,B,Y,oe,ee,te,ve,me,be):_e&6?U(R,B,Y,oe,ee,te,ve,me,be):(_e&64||_e&128)&&ce.process(R,B,Y,oe,ee,te,ve,me,be,Re)}Te!=null&&ee&&Sc(Te,R&&R.ref,te,B||R,!B)},L=(R,B,Y,oe)=>{if(R==null)r(B.el=l(B.children),Y,oe);else{const ee=B.el=R.el;B.children!==R.children&&d(ee,B.children)}},O=(R,B,Y,oe)=>{R==null?r(B.el=c(B.children||""),Y,oe):B.el=R.el},$=(R,B,Y,oe)=>{[R.el,R.anchor]=b(R.children,B,Y,oe,R.el,R.anchor)},X=({el:R,anchor:B},Y,oe)=>{let ee;for(;R&&R!==B;)ee=m(R),r(R,Y,oe),R=ee;r(B,Y,oe)},x=({el:R,anchor:B})=>{let Y;for(;R&&R!==B;)Y=m(R),i(R),R=Y;i(B)},z=(R,B,Y,oe,ee,te,ve,me,be)=>{ve=ve||B.type==="svg",R==null?Q(B,Y,oe,ee,te,ve,me,be):A(R,B,ee,te,ve,me,be)},Q=(R,B,Y,oe,ee,te,ve,me)=>{let be,ce;const{type:Te,props:_e,shapeFlag:Ne,transition:ne,dirs:$e}=R;if(be=R.el=s(R.type,te,_e&&_e.is,_e),Ne&8?p(be,R.children):Ne&16&&I(R.children,be,null,oe,ee,te&&Te!=="foreignObject",ve,me),$e&&Mi(R,null,oe,"created"),g(be,R,R.scopeId,ve,oe),_e){for(const lt in _e)lt!=="value"&&!Ka(lt)&&o(be,lt,null,_e[lt],te,R.children,oe,ee,Oe);"value"in _e&&o(be,"value",null,_e.value),(ce=_e.onVnodeBeforeMount)&&Or(ce,oe,R)}$e&&Mi(R,null,oe,"beforeMount");const at=(!ee||ee&&!ee.pendingBranch)&&ne&&!ne.persisted;at&&ne.beforeEnter(be),r(be,B,Y),((ce=_e&&_e.onVnodeMounted)||at||$e)&&Nn(()=>{ce&&Or(ce,oe,R),at&&ne.enter(be),$e&&Mi(R,null,oe,"mounted")},ee)},g=(R,B,Y,oe,ee)=>{if(Y&&C(R,Y),oe)for(let te=0;te<oe.length;te++)C(R,oe[te]);if(ee){let te=ee.subTree;if(B===te){const ve=ee.vnode;g(R,ve,ve.scopeId,ve.slotScopeIds,ee.parent)}}},I=(R,B,Y,oe,ee,te,ve,me,be=0)=>{for(let ce=be;ce<R.length;ce++){const Te=R[ce]=me?hi(R[ce]):Lr(R[ce]);k(null,Te,B,Y,oe,ee,te,ve,me)}},A=(R,B,Y,oe,ee,te,ve)=>{const me=B.el=R.el;let{patchFlag:be,dynamicChildren:ce,dirs:Te}=B;be|=R.patchFlag&16;const _e=R.props||bt,Ne=B.props||bt;let ne;Y&&Fi(Y,!1),(ne=Ne.onVnodeBeforeUpdate)&&Or(ne,Y,B,R),Te&&Mi(B,R,Y,"beforeUpdate"),Y&&Fi(Y,!0);const $e=ee&&B.type!=="foreignObject";if(ce?D(R.dynamicChildren,ce,me,Y,oe,$e,te):ve||ae(R,B,me,null,Y,oe,$e,te,!1),be>0){if(be&16)H(me,B,_e,Ne,Y,oe,ee);else if(be&2&&_e.class!==Ne.class&&o(me,"class",null,Ne.class,ee),be&4&&o(me,"style",_e.style,Ne.style,ee),be&8){const at=B.dynamicProps;for(let lt=0;lt<at.length;lt++){const Tt=at[lt],Nt=_e[Tt],en=Ne[Tt];(en!==Nt||Tt==="value")&&o(me,Tt,Nt,en,ee,R.children,Y,oe,Oe)}}be&1&&R.children!==B.children&&p(me,B.children)}else!ve&&ce==null&&H(me,B,_e,Ne,Y,oe,ee);((ne=Ne.onVnodeUpdated)||Te)&&Nn(()=>{ne&&Or(ne,Y,B,R),Te&&Mi(B,R,Y,"updated")},oe)},D=(R,B,Y,oe,ee,te,ve)=>{for(let me=0;me<B.length;me++){const be=R[me],ce=B[me],Te=be.el&&(be.type===De||!Bi(be,ce)||be.shapeFlag&70)?y(be.el):Y;k(be,ce,Te,null,oe,ee,te,ve,!0)}},H=(R,B,Y,oe,ee,te,ve)=>{if(Y!==oe){if(Y!==bt)for(const me in Y)!Ka(me)&&!(me in oe)&&o(R,me,Y[me],null,ve,B.children,ee,te,Oe);for(const me in oe){if(Ka(me))continue;const be=oe[me],ce=Y[me];be!==ce&&me!=="value"&&o(R,me,ce,be,ve,B.children,ee,te,Oe)}"value"in oe&&o(R,"value",Y.value,oe.value)}},K=(R,B,Y,oe,ee,te,ve,me,be)=>{const ce=B.el=R?R.el:l(""),Te=B.anchor=R?R.anchor:l("");let{patchFlag:_e,dynamicChildren:Ne,slotScopeIds:ne}=B;ne&&(me=me?me.concat(ne):ne),R==null?(r(ce,Y,oe),r(Te,Y,oe),I(B.children,Y,Te,ee,te,ve,me,be)):_e>0&&_e&64&&Ne&&R.dynamicChildren?(D(R.dynamicChildren,Ne,Y,ee,te,ve,me),(B.key!=null||ee&&B===ee.subTree)&&Ac(R,B,!0)):ae(R,B,Y,Te,ee,te,ve,me,be)},U=(R,B,Y,oe,ee,te,ve,me,be)=>{B.slotScopeIds=me,R==null?B.shapeFlag&512?ee.ctx.activate(B,Y,oe,ve,be):de(B,Y,oe,ee,te,ve,be):je(R,B,be)},de=(R,B,Y,oe,ee,te,ve)=>{const me=R.component=j_(R,oe,ee);if(ul(R)&&(me.ctx.renderer=Re),U_(me),me.asyncDep){if(ee&&ee.registerDep(me,Pe),!R.el){const be=me.subTree=ye(sr);O(null,be,B,Y)}return}Pe(me,R,B,Y,ee,te,ve)},je=(R,B,Y)=>{const oe=B.component=R.component;if(JC(R,B,Y))if(oe.asyncDep&&!oe.asyncResolved){V(oe,B,Y);return}else oe.next=B,VC(oe.update),oe.update();else B.el=R.el,oe.vnode=B},Pe=(R,B,Y,oe,ee,te,ve)=>{const me=()=>{if(R.isMounted){let{next:Te,bu:_e,u:Ne,parent:ne,vnode:$e}=R,at=Te,lt;Fi(R,!1),Te?(Te.el=$e.el,V(R,Te,ve)):Te=$e,_e&&za(_e),(lt=Te.props&&Te.props.onVnodeBeforeUpdate)&&Or(lt,ne,Te,$e),Fi(R,!0);const Tt=pc(R),Nt=R.subTree;R.subTree=Tt,k(Nt,Tt,y(Nt.el),Be(Nt),R,ee,te),Te.el=Tt.el,at===null&&ZC(R,Tt.el),Ne&&Nn(Ne,ee),(lt=Te.props&&Te.props.onVnodeUpdated)&&Nn(()=>Or(lt,ne,Te,$e),ee)}else{let Te;const{el:_e,props:Ne}=B,{bm:ne,m:$e,parent:at}=R,lt=Ls(B);if(Fi(R,!1),ne&&za(ne),!lt&&(Te=Ne&&Ne.onVnodeBeforeMount)&&Or(Te,at,B),Fi(R,!0),_e&&dt){const Tt=()=>{R.subTree=pc(R),dt(_e,R.subTree,R,ee,null)};lt?B.type.__asyncLoader().then(()=>!R.isUnmounted&&Tt()):Tt()}else{const Tt=R.subTree=pc(R);k(null,Tt,Y,oe,R,ee,te),B.el=Tt.el}if($e&&Nn($e,ee),!lt&&(Te=Ne&&Ne.onVnodeMounted)){const Tt=B;Nn(()=>Or(Te,at,Tt),ee)}(B.shapeFlag&256||at&&Ls(at.vnode)&&at.vnode.shapeFlag&256)&&R.a&&Nn(R.a,ee),R.isMounted=!0,B=Y=oe=null}},be=R.effect=new nc(me,()=>dc(ce),R.scope),ce=R.update=()=>be.run();ce.id=R.uid,Fi(R,!0),ce()},V=(R,B,Y)=>{B.component=R;const oe=R.vnode.props;R.vnode=B,R.next=null,x_(R,B.props,oe,Y),E_(R,B.children,Y),mo(),rh(),vo()},ae=(R,B,Y,oe,ee,te,ve,me,be=!1)=>{const ce=R&&R.children,Te=R?R.shapeFlag:0,_e=B.children,{patchFlag:Ne,shapeFlag:ne}=B;if(Ne>0){if(Ne&128){Qe(ce,_e,Y,oe,ee,te,ve,me,be);return}else if(Ne&256){pe(ce,_e,Y,oe,ee,te,ve,me,be);return}}ne&8?(Te&16&&Oe(ce,ee,te),_e!==ce&&p(Y,_e)):Te&16?ne&16?Qe(ce,_e,Y,oe,ee,te,ve,me,be):Oe(ce,ee,te,!0):(Te&8&&p(Y,""),ne&16&&I(_e,Y,oe,ee,te,ve,me,be))},pe=(R,B,Y,oe,ee,te,ve,me,be)=>{R=R||nr,B=B||nr;const ce=R.length,Te=B.length,_e=Math.min(ce,Te);let Ne;for(Ne=0;Ne<_e;Ne++){const ne=B[Ne]=be?hi(B[Ne]):Lr(B[Ne]);k(R[Ne],ne,Y,null,ee,te,ve,me,be)}ce>Te?Oe(R,ee,te,!0,!1,_e):I(B,Y,oe,ee,te,ve,me,be,_e)},Qe=(R,B,Y,oe,ee,te,ve,me,be)=>{let ce=0;const Te=B.length;let _e=R.length-1,Ne=Te-1;for(;ce<=_e&&ce<=Ne;){const ne=R[ce],$e=B[ce]=be?hi(B[ce]):Lr(B[ce]);if(Bi(ne,$e))k(ne,$e,Y,null,ee,te,ve,me,be);else break;ce++}for(;ce<=_e&&ce<=Ne;){const ne=R[_e],$e=B[Ne]=be?hi(B[Ne]):Lr(B[Ne]);if(Bi(ne,$e))k(ne,$e,Y,null,ee,te,ve,me,be);else break;_e--,Ne--}if(ce>_e){if(ce<=Ne){const ne=Ne+1,$e=ne<Te?B[ne].el:oe;for(;ce<=Ne;)k(null,B[ce]=be?hi(B[ce]):Lr(B[ce]),Y,$e,ee,te,ve,me,be),ce++}}else if(ce>Ne)for(;ce<=_e;)se(R[ce],ee,te,!0),ce++;else{const ne=ce,$e=ce,at=new Map;for(ce=$e;ce<=Ne;ce++){const Se=B[ce]=be?hi(B[ce]):Lr(B[ce]);Se.key!=null&&at.set(Se.key,ce)}let lt,Tt=0;const Nt=Ne-$e+1;let en=!1,$t=0;const Vt=new Array(Nt);for(ce=0;ce<Nt;ce++)Vt[ce]=0;for(ce=ne;ce<=_e;ce++){const Se=R[ce];if(Tt>=Nt){se(Se,ee,te,!0);continue}let He;if(Se.key!=null)He=at.get(Se.key);else for(lt=$e;lt<=Ne;lt++)if(Vt[lt-$e]===0&&Bi(Se,B[lt])){He=lt;break}He===void 0?se(Se,ee,te,!0):(Vt[He-$e]=ce+1,He>=$t?$t=He:en=!0,k(Se,B[He],Y,null,ee,te,ve,me,be),Tt++)}const J=en?I_(Vt):nr;for(lt=J.length-1,ce=Nt-1;ce>=0;ce--){const Se=$e+ce,He=B[Se],pt=Se+1<Te?B[Se+1].el:oe;Vt[ce]===0?k(null,He,Y,pt,ee,te,ve,me,be):en&&(lt<0||ce!==J[lt]?et(He,Y,pt,2):lt--)}}},et=(R,B,Y,oe,ee=null)=>{const{el:te,type:ve,transition:me,children:be,shapeFlag:ce}=R;if(ce&6){et(R.component.subTree,B,Y,oe);return}if(ce&128){R.suspense.move(B,Y,oe);return}if(ce&64){ve.move(R,B,Y,Re);return}if(ve===De){r(te,B,Y);for(let _e=0;_e<be.length;_e++)et(be[_e],B,Y,oe);r(R.anchor,B,Y);return}if(ve===Lc){X(R,B,Y);return}if(oe!==2&&ce&1&&me)if(oe===0)me.beforeEnter(te),r(te,B,Y),Nn(()=>me.enter(te),ee);else{const{leave:_e,delayLeave:Ne,afterLeave:ne}=me,$e=()=>r(te,B,Y),at=()=>{_e(te,()=>{$e(),ne&&ne()})};Ne?Ne(te,$e,at):at()}else r(te,B,Y)},se=(R,B,Y,oe=!1,ee=!1)=>{const{type:te,props:ve,ref:me,children:be,dynamicChildren:ce,shapeFlag:Te,patchFlag:_e,dirs:Ne}=R;if(me!=null&&Sc(me,null,Y,R,!0),Te&256){B.ctx.deactivate(R);return}const ne=Te&1&&Ne,$e=!Ls(R);let at;if($e&&(at=ve&&ve.onVnodeBeforeUnmount)&&Or(at,B,R),Te&6)Ae(R.component,Y,oe);else{if(Te&128){R.suspense.unmount(Y,oe);return}ne&&Mi(R,null,B,"beforeUnmount"),Te&64?R.type.remove(R,B,Y,ee,Re,oe):ce&&(te!==De||_e>0&&_e&64)?Oe(ce,B,Y,!1,!0):(te===De&&_e&384||!ee&&Te&16)&&Oe(be,B,Y),oe&&Ce(R)}($e&&(at=ve&&ve.onVnodeUnmounted)||ne)&&Nn(()=>{at&&Or(at,B,R),ne&&Mi(R,null,B,"unmounted")},Y)},Ce=R=>{const{type:B,el:Y,anchor:oe,transition:ee}=R;if(B===De){xe(Y,oe);return}if(B===Lc){x(R);return}const te=()=>{i(Y),ee&&!ee.persisted&&ee.afterLeave&&ee.afterLeave()};if(R.shapeFlag&1&&ee&&!ee.persisted){const{leave:ve,delayLeave:me}=ee,be=()=>ve(Y,te);me?me(R.el,te,be):be()}else te()},xe=(R,B)=>{let Y;for(;R!==B;)Y=m(R),i(R),R=Y;i(B)},Ae=(R,B,Y)=>{const{bum:oe,scope:ee,update:te,subTree:ve,um:me}=R;oe&&za(oe),ee.stop(),te&&(te.active=!1,se(ve,R,B,Y)),me&&Nn(me,B),Nn(()=>{R.isUnmounted=!0},B),B&&B.pendingBranch&&!B.isUnmounted&&R.asyncDep&&!R.asyncResolved&&R.suspenseId===B.pendingId&&(B.deps--,B.deps===0&&B.resolve())},Oe=(R,B,Y,oe=!1,ee=!1,te=0)=>{for(let ve=te;ve<R.length;ve++)se(R[ve],B,Y,oe,ee)},Be=R=>R.shapeFlag&6?Be(R.component.subTree):R.shapeFlag&128?R.suspense.next():m(R.anchor||R.el),tt=(R,B,Y)=>{R==null?B._vnode&&se(B._vnode,null,null,!0):k(B._vnode||null,R,B,null,null,null,Y),rh(),ih(),B._vnode=R},Re={p:k,um:se,m:et,r:Ce,mt:de,mc:I,pc:ae,pbc:D,n:Be,o:e};let Ve,dt;return t&&([Ve,dt]=t(Re)),{render:tt,hydrate:Ve,createApp:T_(tt,Ve)}}function Fi({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function Ac(e,t,n=!1){const r=e.children,i=t.children;if(qe(r)&&qe(i))for(let o=0;o<r.length;o++){const s=r[o];let l=i[o];l.shapeFlag&1&&!l.dynamicChildren&&((l.patchFlag<=0||l.patchFlag===32)&&(l=i[o]=hi(i[o]),l.el=s.el),n||Ac(s,l)),l.type===gl&&(l.el=s.el)}}function I_(e){const t=e.slice(),n=[0];let r,i,o,s,l;const c=e.length;for(r=0;r<c;r++){const d=e[r];if(d!==0){if(i=n[n.length-1],e[i]<d){t[r]=i,n.push(r);continue}for(o=0,s=n.length-1;o<s;)l=o+s>>1,e[n[l]]<d?o=l+1:s=l;d<e[n[o]]&&(o>0&&(t[r]=n[o-1]),n[o]=r)}}for(o=n.length,s=n[o-1];o-- >0;)n[o]=s,s=t[s];return n}const P_=e=>e.__isTeleport,Ps=e=>e&&(e.disabled||e.disabled===""),Fh=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Ec=(e,t)=>{const n=e&&e.to;return Ht(n)?t?t(n):null:n},D_={__isTeleport:!0,process(e,t,n,r,i,o,s,l,c,d){const{mc:p,pc:y,pbc:m,o:{insert:C,querySelector:b,createText:k,createComment:L}}=d,O=Ps(t.props);let{shapeFlag:$,children:X,dynamicChildren:x}=t;if(e==null){const z=t.el=k(""),Q=t.anchor=k("");C(z,n,r),C(Q,n,r);const g=t.target=Ec(t.props,b),I=t.targetAnchor=k("");g&&(C(I,g),s=s||Fh(g));const A=(D,H)=>{$&16&&p(X,D,H,i,o,s,l,c)};O?A(n,Q):g&&A(g,I)}else{t.el=e.el;const z=t.anchor=e.anchor,Q=t.target=e.target,g=t.targetAnchor=e.targetAnchor,I=Ps(e.props),A=I?n:Q,D=I?z:g;if(s=s||Fh(Q),x?(m(e.dynamicChildren,x,A,i,o,s,l),Ac(e,t,!0)):c||y(e,t,A,D,i,o,s,l,!1),O)I||hl(t,n,z,d,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const H=t.target=Ec(t.props,b);H&&hl(t,H,null,d,0)}else I&&hl(t,Q,g,d,1)}Bh(t)},remove(e,t,n,r,{um:i,o:{remove:o}},s){const{shapeFlag:l,children:c,anchor:d,targetAnchor:p,target:y,props:m}=e;if(y&&o(p),(s||!Ps(m))&&(o(d),l&16))for(let C=0;C<c.length;C++){const b=c[C];i(b,t,n,!0,!!b.dynamicChildren)}},move:hl,hydrate:R_};function hl(e,t,n,{o:{insert:r},m:i},o=2){o===0&&r(e.targetAnchor,t,n);const{el:s,anchor:l,shapeFlag:c,children:d,props:p}=e,y=o===2;if(y&&r(s,t,n),(!y||Ps(p))&&c&16)for(let m=0;m<d.length;m++)i(d[m],t,n,2);y&&r(l,t,n)}function R_(e,t,n,r,i,o,{o:{nextSibling:s,parentNode:l,querySelector:c}},d){const p=t.target=Ec(t.props,c);if(p){const y=p._lpa||p.firstChild;if(t.shapeFlag&16)if(Ps(t.props))t.anchor=d(s(e),t,l(e),n,r,i,o),t.targetAnchor=y;else{t.anchor=s(e);let m=y;for(;m;)if(m=s(m),m&&m.nodeType===8&&m.data==="teleport anchor"){t.targetAnchor=m,p._lpa=t.targetAnchor&&s(t.targetAnchor);break}d(y,t,p,n,r,i,o)}Bh(t)}return t.anchor&&s(t.anchor)}const N_=D_;function Bh(e){const t=e.ctx;if(t&&t.ut){let n=e.children[0].el;for(;n!==e.targetAnchor;)n.nodeType===1&&n.setAttribute("data-v-owner",t.uid),n=n.nextSibling;t.ut()}}const De=Symbol.for("v-fgt"),gl=Symbol.for("v-txt"),sr=Symbol.for("v-cmt"),Lc=Symbol.for("v-stc"),Ds=[];let br=null;function E(e=!1){Ds.push(br=e?null:[])}function M_(){Ds.pop(),br=Ds[Ds.length-1]||null}let Rs=1;function $h(e){Rs+=e}function Hh(e){return e.dynamicChildren=Rs>0?br||nr:null,M_(),Rs>0&&br&&br.push(e),e}function M(e,t,n,r,i,o){return Hh(T(e,t,n,r,i,o,!0))}function Ue(e,t,n,r,i){return Hh(ye(e,t,n,r,i,!0))}function ml(e){return e?e.__v_isVNode===!0:!1}function Bi(e,t){return e.type===t.type&&e.key===t.key}const vl="__vInternal",jh=({key:e})=>e??null,yl=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?Ht(e)||yn(e)||ct(e)?{i:dn,r:e,k:t,f:!!n}:e:null);function T(e,t=null,n=null,r=0,i=null,o=e===De?0:1,s=!1,l=!1){const c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&jh(t),ref:t&&yl(t),scopeId:sl,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:o,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:dn};return l?(Oc(c,n),o&128&&e.normalize(c)):n&&(c.shapeFlag|=Ht(n)?8:16),Rs>0&&!s&&br&&(c.patchFlag>0||o&6)&&c.patchFlag!==32&&br.push(c),c}const ye=F_;function F_(e,t=null,n=null,r=0,i=null,o=!1){if((!e||e===vh)&&(e=sr),ml(e)){const l=pi(e,t,!0);return n&&Oc(l,n),Rs>0&&!o&&br&&(l.shapeFlag&6?br[br.indexOf(e)]=l:br.push(l)),l.patchFlag|=-2,l}if(z_(e)&&(e=e.__vccOpts),t){t=B_(t);let{class:l,style:c}=t;l&&!Ht(l)&&(t.class=Ge(l)),It(c)&&(Gp(c)&&!qe(c)&&(c=Yt({},c)),t.style=St(c))}const s=Ht(e)?1:QC(e)?128:P_(e)?64:It(e)?4:ct(e)?2:0;return T(e,t,n,r,i,s,o,!0)}function B_(e){return e?Gp(e)||vl in e?Yt({},e):e:null}function pi(e,t,n=!1){const{props:r,ref:i,patchFlag:o,children:s}=e,l=t?bl(r||{},t):r;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&jh(l),ref:t&&t.ref?n&&i?qe(i)?i.concat(yl(t)):[i,yl(t)]:yl(t):i,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==De?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&pi(e.ssContent),ssFallback:e.ssFallback&&pi(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce}}function jt(e=" ",t=0){return ye(gl,null,e,t)}function ke(e="",t=!1){return t?(E(),Ue(sr,null,e)):ye(sr,null,e)}function Lr(e){return e==null||typeof e=="boolean"?ye(sr):qe(e)?ye(De,null,e.slice()):typeof e=="object"?hi(e):ye(gl,null,String(e))}function hi(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:pi(e)}function Oc(e,t){let n=0;const{shapeFlag:r}=e;if(t==null)t=null;else if(qe(t))n=16;else if(typeof t=="object")if(r&65){const i=t.default;i&&(i._c&&(i._d=!1),Oc(e,i()),i._c&&(i._d=!0));return}else{n=32;const i=t._;!i&&!(vl in t)?t._ctx=dn:i===3&&dn&&(dn.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else ct(t)?(t={default:t,_ctx:dn},n=32):(t=String(t),r&64?(n=16,t=[jt(t)]):n=8);e.children=t,e.shapeFlag|=n}function bl(...e){const t={};for(let n=0;n<e.length;n++){const r=e[n];for(const i in r)if(i==="class")t.class!==r.class&&(t.class=Ge([t.class,r.class]));else if(i==="style")t.style=St([t.style,r.style]);else if(Wa(i)){const o=t[i],s=r[i];s&&o!==s&&!(qe(o)&&o.includes(s))&&(t[i]=o?[].concat(o,s):s)}else i!==""&&(t[i]=r[i])}return t}function Or(e,t,n,r=null){rr(e,t,7,[n,r])}const $_=Sh();let H_=0;function j_(e,t,n){const r=e.type,i=(t?t.appContext:e.appContext)||$_,o={uid:H_++,vnode:e,type:r,parent:t,appContext:i,root:null,next:null,subTree:null,effect:null,update:null,scope:new lC(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(i.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Lh(r,i),emitsOptions:sh(r,i),emit:null,emitted:null,propsDefaults:bt,inheritAttrs:r.inheritAttrs,ctx:bt,data:bt,props:bt,attrs:bt,slots:bt,refs:bt,setupState:bt,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 o.ctx={_:o},o.root=t?t.root:o,o.emit=GC.bind(null,o),e.ce&&e.ce(o),o}let ln=null;const Ic=()=>ln||dn;let Pc,xo,Uh="__VUE_INSTANCE_SETTERS__";(xo=Xu()[Uh])||(xo=Xu()[Uh]=[]),xo.push(e=>ln=e),Pc=e=>{xo.length>1?xo.forEach(t=>t(e)):xo[0](e)};const So=e=>{Pc(e),e.scope.on()},$i=()=>{ln&&ln.scope.off(),Pc(null)};function Wh(e){return e.vnode.shapeFlag&4}let Ns=!1;function U_(e,t=!1){Ns=t;const{props:n,children:r}=e.vnode,i=Wh(e);k_(e,n,i,t),A_(e,r);const o=i?W_(e,t):void 0;return Ns=!1,o}function W_(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=Yp(new Proxy(e.ctx,m_));const{setup:r}=n;if(r){const i=e.setupContext=r.length>1?V_(e):null;So(e),mo();const o=di(r,e,0,[e.props,i]);if(vo(),$i(),kp(o)){if(o.then($i,$i),t)return o.then(s=>{Kh(e,s,t)}).catch(s=>{rl(s,e,0)});e.asyncDep=o}else Kh(e,o,t)}else qh(e,t)}function Kh(e,t,n){ct(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:It(t)&&(e.setupState=eh(t)),qh(e,n)}let Vh;function qh(e,t,n){const r=e.type;if(!e.render){if(!t&&Vh&&!r.render){const i=r.template||wc(e).template;if(i){const{isCustomElement:o,compilerOptions:s}=e.appContext.config,{delimiters:l,compilerOptions:c}=r,d=Yt(Yt({isCustomElement:o,delimiters:l},s),c);r.render=Vh(i,d)}}e.render=r.render||vr}So(e),mo(),v_(e),vo(),$i()}function K_(e){return e.attrsProxy||(e.attrsProxy=new Proxy(e.attrs,{get(t,n){return Pn(e,"get","$attrs"),t[n]}}))}function V_(e){const t=n=>{e.exposed=n||{}};return{get attrs(){return K_(e)},slots:e.slots,emit:e.emit,expose:t}}function Cl(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(eh(Yp(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Os)return Os[n](e)},has(t,n){return n in t||n in Os}}))}function q_(e,t=!0){return ct(e)?e.displayName||e.name:e.name||t&&e.__name}function z_(e){return ct(e)&&"__vccOpts"in e}const nn=(e,t)=>UC(e,t,Ns);function G_(e,t,n){const r=arguments.length;return r===2?It(t)&&!qe(t)?ml(t)?ye(e,null,[t]):ye(e,t):ye(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):r===3&&ml(n)&&(n=[n]),ye(e,t,n))}const Y_=Symbol.for("v-scx"),X_=()=>ko(Y_),J_="3.3.4",Z_="http://www.w3.org/2000/svg",Hi=typeof document<"u"?document:null,zh=Hi&&Hi.createElement("template"),Q_={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{const i=t?Hi.createElementNS(Z_,e):Hi.createElement(e,n?{is:n}:void 0);return e==="select"&&r&&r.multiple!=null&&i.setAttribute("multiple",r.multiple),i},createText:e=>Hi.createTextNode(e),createComment:e=>Hi.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Hi.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,r,i,o){const s=n?n.previousSibling:t.lastChild;if(i&&(i===o||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),!(i===o||!(i=i.nextSibling)););else{zh.innerHTML=r?`<svg>${e}</svg>`:e;const l=zh.content;if(r){const c=l.firstChild;for(;c.firstChild;)l.appendChild(c.firstChild);l.removeChild(c)}t.insertBefore(l,n)}return[s?s.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}};function e1(e,t,n){const r=e._vtc;r&&(t=(t?[t,...r]:[...r]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}function t1(e,t,n){const r=e.style,i=Ht(n);if(n&&!i){if(t&&!Ht(t))for(const o in t)n[o]==null&&Dc(r,o,"");for(const o in n)Dc(r,o,n[o])}else{const o=r.display;i?t!==n&&(r.cssText=n):t&&e.removeAttribute("style"),"_vod"in e&&(r.display=o)}}const Gh=/\s*!important$/;function Dc(e,t,n){if(qe(n))n.forEach(r=>Dc(e,t,r));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const r=n1(e,t);Gh.test(n)?e.setProperty(go(r),n.replace(Gh,""),"important"):e[r]=n}}const Yh=["Webkit","Moz","ms"],Rc={};function n1(e,t){const n=Rc[t];if(n)return n;let r=Ar(t);if(r!=="filter"&&r in e)return Rc[t]=r;r=qa(r);for(let i=0;i<Yh.length;i++){const o=Yh[i]+r;if(o in e)return Rc[t]=o}return t}const Xh="http://www.w3.org/1999/xlink";function r1(e,t,n,r,i){if(r&&t.startsWith("xlink:"))n==null?e.removeAttributeNS(Xh,t.slice(6,t.length)):e.setAttributeNS(Xh,t,n);else{const o=sC(t);n==null||o&&!Ep(n)?e.removeAttribute(t):e.setAttribute(t,o?"":n)}}function i1(e,t,n,r,i,o,s){if(t==="innerHTML"||t==="textContent"){r&&s(r,i,o),e[t]=n??"";return}const l=e.tagName;if(t==="value"&&l!=="PROGRESS"&&!l.includes("-")){e._value=n;const d=l==="OPTION"?e.getAttribute("value"):e.value,p=n??"";d!==p&&(e.value=p),n==null&&e.removeAttribute(t);return}let c=!1;if(n===""||n==null){const d=typeof e[t];d==="boolean"?n=Ep(n):n==null&&d==="string"?(n="",c=!0):d==="number"&&(n=0,c=!0)}try{e[t]=n}catch{}c&&e.removeAttribute(t)}function gi(e,t,n,r){e.addEventListener(t,n,r)}function o1(e,t,n,r){e.removeEventListener(t,n,r)}function s1(e,t,n,r,i=null){const o=e._vei||(e._vei={}),s=o[t];if(r&&s)s.value=r;else{const[l,c]=a1(t);if(r){const d=o[t]=c1(r,i);gi(e,l,d,c)}else s&&(o1(e,l,s,c),o[t]=void 0)}}const Jh=/(?:Once|Passive|Capture)$/;function a1(e){let t;if(Jh.test(e)){t={};let r;for(;r=e.match(Jh);)e=e.slice(0,e.length-r[0].length),t[r[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):go(e.slice(2)),t]}let Nc=0;const l1=Promise.resolve(),u1=()=>Nc||(l1.then(()=>Nc=0),Nc=Date.now());function c1(e,t){const n=r=>{if(!r._vts)r._vts=Date.now();else if(r._vts<=n.attached)return;rr(f1(r,n.value),t,5,[r])};return n.value=e,n.attached=u1(),n}function f1(e,t){if(qe(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(r=>i=>!i._stopped&&r&&r(i))}else return t}const Zh=/^on[a-z]/,d1=(e,t,n,r,i=!1,o,s,l,c)=>{t==="class"?e1(e,r,i):t==="style"?t1(e,n,r):Wa(t)?qu(t)||s1(e,t,n,r,s):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):p1(e,t,r,i))?i1(e,t,r,o,s,l,c):(t==="true-value"?e._trueValue=r:t==="false-value"&&(e._falseValue=r),r1(e,t,r,i))};function p1(e,t,n,r){return r?!!(t==="innerHTML"||t==="textContent"||t in e&&Zh.test(t)&&ct(n)):t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA"||Zh.test(t)&&Ht(n)?!1:t in e}const mi="transition",Ms="animation",un=(e,{slots:t})=>G_(r_,h1(e),t);un.displayName="Transition";const Qh={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};un.props=Yt({},ch,Qh);const ji=(e,t=[])=>{qe(e)?e.forEach(n=>n(...t)):e&&e(...t)},eg=e=>e?qe(e)?e.some(t=>t.length>1):e.length>1:!1;function h1(e){const t={};for(const K in e)K in Qh||(t[K]=e[K]);if(e.css===!1)return t;const{name:n="v",type:r,duration:i,enterFromClass:o=`${n}-enter-from`,enterActiveClass:s=`${n}-enter-active`,enterToClass:l=`${n}-enter-to`,appearFromClass:c=o,appearActiveClass:d=s,appearToClass:p=l,leaveFromClass:y=`${n}-leave-from`,leaveActiveClass:m=`${n}-leave-active`,leaveToClass:C=`${n}-leave-to`}=e,b=g1(i),k=b&&b[0],L=b&&b[1],{onBeforeEnter:O,onEnter:$,onEnterCancelled:X,onLeave:x,onLeaveCancelled:z,onBeforeAppear:Q=O,onAppear:g=$,onAppearCancelled:I=X}=t,A=(K,U,de)=>{Ui(K,U?p:l),Ui(K,U?d:s),de&&de()},D=(K,U)=>{K._isLeaving=!1,Ui(K,y),Ui(K,C),Ui(K,m),U&&U()},H=K=>(U,de)=>{const je=K?g:$,Pe=()=>A(U,K,de);ji(je,[U,Pe]),tg(()=>{Ui(U,K?c:o),vi(U,K?p:l),eg(je)||ng(U,r,k,Pe)})};return Yt(t,{onBeforeEnter(K){ji(O,[K]),vi(K,o),vi(K,s)},onBeforeAppear(K){ji(Q,[K]),vi(K,c),vi(K,d)},onEnter:H(!1),onAppear:H(!0),onLeave(K,U){K._isLeaving=!0;const de=()=>D(K,U);vi(K,y),y1(),vi(K,m),tg(()=>{K._isLeaving&&(Ui(K,y),vi(K,C),eg(x)||ng(K,r,L,de))}),ji(x,[K,de])},onEnterCancelled(K){A(K,!1),ji(X,[K])},onAppearCancelled(K){A(K,!0),ji(I,[K])},onLeaveCancelled(K){D(K),ji(z,[K])}})}function g1(e){if(e==null)return null;if(It(e))return[Mc(e.enter),Mc(e.leave)];{const t=Mc(e);return[t,t]}}function Mc(e){return tC(e)}function vi(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e._vtc||(e._vtc=new Set)).add(t)}function Ui(e,t){t.split(/\s+/).forEach(r=>r&&e.classList.remove(r));const{_vtc:n}=e;n&&(n.delete(t),n.size||(e._vtc=void 0))}function tg(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let m1=0;function ng(e,t,n,r){const i=e._endId=++m1,o=()=>{i===e._endId&&r()};if(n)return setTimeout(o,n);const{type:s,timeout:l,propCount:c}=v1(e,t);if(!s)return r();const d=s+"end";let p=0;const y=()=>{e.removeEventListener(d,m),o()},m=C=>{C.target===e&&++p>=c&&y()};setTimeout(()=>{p<c&&y()},l+1),e.addEventListener(d,m)}function v1(e,t){const n=window.getComputedStyle(e),r=b=>(n[b]||"").split(", "),i=r(`${mi}Delay`),o=r(`${mi}Duration`),s=rg(i,o),l=r(`${Ms}Delay`),c=r(`${Ms}Duration`),d=rg(l,c);let p=null,y=0,m=0;t===mi?s>0&&(p=mi,y=s,m=o.length):t===Ms?d>0&&(p=Ms,y=d,m=c.length):(y=Math.max(s,d),p=y>0?s>d?mi:Ms:null,m=p?p===mi?o.length:c.length:0);const C=p===mi&&/\b(transform|all)(,|$)/.test(r(`${mi}Property`).toString());return{type:p,timeout:y,propCount:m,hasTransform:C}}function rg(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,r)=>ig(n)+ig(e[r])))}function ig(e){return Number(e.slice(0,-1).replace(",","."))*1e3}function y1(){return document.body.offsetHeight}const Ao=e=>{const t=e.props["onUpdate:modelValue"]||!1;return qe(t)?n=>za(t,n):t};function b1(e){e.target.composing=!0}function og(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Vn={created(e,{modifiers:{lazy:t,trim:n,number:r}},i){e._assign=Ao(i);const o=r||i.props&&i.props.type==="number";gi(e,t?"change":"input",s=>{if(s.target.composing)return;let l=e.value;n&&(l=l.trim()),o&&(l=Ya(l)),e._assign(l)}),n&&gi(e,"change",()=>{e.value=e.value.trim()}),t||(gi(e,"compositionstart",b1),gi(e,"compositionend",og),gi(e,"change",og))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,modifiers:{lazy:n,trim:r,number:i}},o){if(e._assign=Ao(o),e.composing||document.activeElement===e&&e.type!=="range"&&(n||r&&e.value.trim()===t||(i||e.type==="number")&&Ya(e.value)===t))return;const s=t??"";e.value!==s&&(e.value=s)}},Fc={deep:!0,created(e,t,n){e._assign=Ao(n),gi(e,"change",()=>{const r=e._modelValue,i=Fs(e),o=e.checked,s=e._assign;if(qe(r)){const l=Ju(r,i),c=l!==-1;if(o&&!c)s(r.concat(i));else if(!o&&c){const d=[...r];d.splice(l,1),s(d)}}else if(ho(r)){const l=new Set(r);o?l.add(i):l.delete(i),s(l)}else s(lg(e,o))})},mounted:sg,beforeUpdate(e,t,n){e._assign=Ao(n),sg(e,t,n)}};function sg(e,{value:t,oldValue:n},r){e._modelValue=t,qe(t)?e.checked=Ju(t,r.props.value)>-1:ho(t)?e.checked=t.has(r.props.value):t!==n&&(e.checked=ks(t,lg(e,!0)))}const Eo={deep:!0,created(e,{value:t,modifiers:{number:n}},r){const i=ho(t);gi(e,"change",()=>{const o=Array.prototype.filter.call(e.options,s=>s.selected).map(s=>n?Ya(Fs(s)):Fs(s));e._assign(e.multiple?i?new Set(o):o:o[0])}),e._assign=Ao(r)},mounted(e,{value:t}){ag(e,t)},beforeUpdate(e,t,n){e._assign=Ao(n)},updated(e,{value:t}){ag(e,t)}};function ag(e,t){const n=e.multiple;if(!(n&&!qe(t)&&!ho(t))){for(let r=0,i=e.options.length;r<i;r++){const o=e.options[r],s=Fs(o);if(n)qe(t)?o.selected=Ju(t,s)>-1:o.selected=t.has(s);else if(ks(Fs(o),t)){e.selectedIndex!==r&&(e.selectedIndex=r);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Fs(e){return"_value"in e?e._value:e.value}function lg(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const C1=["ctrl","shift","alt","meta"],_1={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)=>C1.some(n=>e[`${n}Key`]&&!t.includes(n))},nt=(e,t)=>(n,...r)=>{for(let i=0;i<t.length;i++){const o=_1[t[i]];if(o&&o(n,t))return}return e(n,...r)},Ot={beforeMount(e,{value:t},{transition:n}){e._vod=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):Bs(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),Bs(e,!0),r.enter(e)):r.leave(e,()=>{Bs(e,!1)}):Bs(e,t))},beforeUnmount(e,{value:t}){Bs(e,t)}};function Bs(e,t){e.style.display=t?e._vod:"none"}const w1=Yt({patchProp:d1},Q_);let ug;function T1(){return ug||(ug=L_(w1))}const k1=(...e)=>{const t=T1().createApp(...e),{mount:n}=t;return t.mount=r=>{const i=x1(r);if(!i)return;const o=t._component;!ct(o)&&!o.render&&!o.template&&(o.template=i.innerHTML),i.innerHTML="";const s=n(i,!1,i instanceof SVGElement);return i instanceof Element&&(i.removeAttribute("v-cloak"),i.setAttribute("data-v-app","")),s},t};function x1(e){return Ht(e)?document.querySelector(e):e}/**!
|
||
* Sortable 1.15.0
|
||
* @author RubaXa <trash@rubaxa.org>
|
||
* @author owenm <owen23355@gmail.com>
|
||
* @license MIT
|
||
*/function cg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ir(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?cg(Object(n),!0).forEach(function(r){S1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cg(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function _l(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?_l=function(t){return typeof t}:_l=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_l(e)}function S1(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Yr(){return Yr=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Yr.apply(this,arguments)}function A1(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function E1(e,t){if(e==null)return{};var n=A1(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}var L1="1.15.0";function Xr(e){if(typeof window<"u"&&window.navigator)return!!navigator.userAgent.match(e)}var Jr=Xr(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),$s=Xr(/Edge/i),fg=Xr(/firefox/i),Hs=Xr(/safari/i)&&!Xr(/chrome/i)&&!Xr(/android/i),dg=Xr(/iP(ad|od|hone)/i),pg=Xr(/chrome/i)&&Xr(/android/i),hg={capture:!1,passive:!1};function At(e,t,n){e.addEventListener(t,n,!Jr&&hg)}function _t(e,t,n){e.removeEventListener(t,n,!Jr&&hg)}function wl(e,t){if(t){if(t[0]===">"&&(t=t.substring(1)),e)try{if(e.matches)return e.matches(t);if(e.msMatchesSelector)return e.msMatchesSelector(t);if(e.webkitMatchesSelector)return e.webkitMatchesSelector(t)}catch{return!1}return!1}}function O1(e){return e.host&&e!==document&&e.host.nodeType?e.host:e.parentNode}function Pr(e,t,n,r){if(e){n=n||document;do{if(t!=null&&(t[0]===">"?e.parentNode===n&&wl(e,t):wl(e,t))||r&&e===n)return e;if(e===n)break}while(e=O1(e))}return null}var gg=/\s+/g;function qn(e,t,n){if(e&&t)if(e.classList)e.classList[n?"add":"remove"](t);else{var r=(" "+e.className+" ").replace(gg," ").replace(" "+t+" "," ");e.className=(r+(n?" "+t:"")).replace(gg," ")}}function Xe(e,t,n){var r=e&&e.style;if(r){if(n===void 0)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(e,""):e.currentStyle&&(n=e.currentStyle),t===void 0?n:n[t];!(t in r)&&t.indexOf("webkit")===-1&&(t="-webkit-"+t),r[t]=n+(typeof n=="string"?"":"px")}}function Lo(e,t){var n="";if(typeof e=="string")n=e;else do{var r=Xe(e,"transform");r&&r!=="none"&&(n=r+" "+n)}while(!t&&(e=e.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(n)}function mg(e,t,n){if(e){var r=e.getElementsByTagName(t),i=0,o=r.length;if(n)for(;i<o;i++)n(r[i],i);return r}return[]}function Dr(){var e=document.scrollingElement;return e||document.documentElement}function rn(e,t,n,r,i){if(!(!e.getBoundingClientRect&&e!==window)){var o,s,l,c,d,p,y;if(e!==window&&e.parentNode&&e!==Dr()?(o=e.getBoundingClientRect(),s=o.top,l=o.left,c=o.bottom,d=o.right,p=o.height,y=o.width):(s=0,l=0,c=window.innerHeight,d=window.innerWidth,p=window.innerHeight,y=window.innerWidth),(t||n)&&e!==window&&(i=i||e.parentNode,!Jr))do if(i&&i.getBoundingClientRect&&(Xe(i,"transform")!=="none"||n&&Xe(i,"position")!=="static")){var m=i.getBoundingClientRect();s-=m.top+parseInt(Xe(i,"border-top-width")),l-=m.left+parseInt(Xe(i,"border-left-width")),c=s+o.height,d=l+o.width;break}while(i=i.parentNode);if(r&&e!==window){var C=Lo(i||e),b=C&&C.a,k=C&&C.d;C&&(s/=k,l/=b,y/=b,p/=k,c=s+p,d=l+y)}return{top:s,left:l,bottom:c,right:d,width:y,height:p}}}function vg(e,t,n){for(var r=yi(e,!0),i=rn(e)[t];r;){var o=rn(r)[n],s=void 0;if(n==="top"||n==="left"?s=i>=o:s=i<=o,!s)return r;if(r===Dr())break;r=yi(r,!1)}return!1}function Oo(e,t,n,r){for(var i=0,o=0,s=e.children;o<s.length;){if(s[o].style.display!=="none"&&s[o]!==Je.ghost&&(r||s[o]!==Je.dragged)&&Pr(s[o],n.draggable,e,!1)){if(i===t)return s[o];i++}o++}return null}function Bc(e,t){for(var n=e.lastElementChild;n&&(n===Je.ghost||Xe(n,"display")==="none"||t&&!wl(n,t));)n=n.previousElementSibling;return n||null}function ar(e,t){var n=0;if(!e||!e.parentNode)return-1;for(;e=e.previousElementSibling;)e.nodeName.toUpperCase()!=="TEMPLATE"&&e!==Je.clone&&(!t||wl(e,t))&&n++;return n}function yg(e){var t=0,n=0,r=Dr();if(e)do{var i=Lo(e),o=i.a,s=i.d;t+=e.scrollLeft*o,n+=e.scrollTop*s}while(e!==r&&(e=e.parentNode));return[t,n]}function I1(e,t){for(var n in e)if(e.hasOwnProperty(n)){for(var r in t)if(t.hasOwnProperty(r)&&t[r]===e[n][r])return Number(n)}return-1}function yi(e,t){if(!e||!e.getBoundingClientRect)return Dr();var n=e,r=!1;do if(n.clientWidth<n.scrollWidth||n.clientHeight<n.scrollHeight){var i=Xe(n);if(n.clientWidth<n.scrollWidth&&(i.overflowX=="auto"||i.overflowX=="scroll")||n.clientHeight<n.scrollHeight&&(i.overflowY=="auto"||i.overflowY=="scroll")){if(!n.getBoundingClientRect||n===document.body)return Dr();if(r||t)return n;r=!0}}while(n=n.parentNode);return Dr()}function P1(e,t){if(e&&t)for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e}function $c(e,t){return Math.round(e.top)===Math.round(t.top)&&Math.round(e.left)===Math.round(t.left)&&Math.round(e.height)===Math.round(t.height)&&Math.round(e.width)===Math.round(t.width)}var js;function bg(e,t){return function(){if(!js){var n=arguments,r=this;n.length===1?e.call(r,n[0]):e.apply(r,n),js=setTimeout(function(){js=void 0},t)}}}function D1(){clearTimeout(js),js=void 0}function Cg(e,t,n){e.scrollLeft+=t,e.scrollTop+=n}function _g(e){var t=window.Polymer,n=window.jQuery||window.Zepto;return t&&t.dom?t.dom(e).cloneNode(!0):n?n(e).clone(!0)[0]:e.cloneNode(!0)}var zn="Sortable"+new Date().getTime();function R1(){var e=[],t;return{captureAnimationState:function(){if(e=[],!!this.options.animation){var r=[].slice.call(this.el.children);r.forEach(function(i){if(!(Xe(i,"display")==="none"||i===Je.ghost)){e.push({target:i,rect:rn(i)});var o=Ir({},e[e.length-1].rect);if(i.thisAnimationDuration){var s=Lo(i,!0);s&&(o.top-=s.f,o.left-=s.e)}i.fromRect=o}})}},addAnimationState:function(r){e.push(r)},removeAnimationState:function(r){e.splice(I1(e,{target:r}),1)},animateAll:function(r){var i=this;if(!this.options.animation){clearTimeout(t),typeof r=="function"&&r();return}var o=!1,s=0;e.forEach(function(l){var c=0,d=l.target,p=d.fromRect,y=rn(d),m=d.prevFromRect,C=d.prevToRect,b=l.rect,k=Lo(d,!0);k&&(y.top-=k.f,y.left-=k.e),d.toRect=y,d.thisAnimationDuration&&$c(m,y)&&!$c(p,y)&&(b.top-y.top)/(b.left-y.left)===(p.top-y.top)/(p.left-y.left)&&(c=M1(b,m,C,i.options)),$c(y,p)||(d.prevFromRect=p,d.prevToRect=y,c||(c=i.options.animation),i.animate(d,b,y,c)),c&&(o=!0,s=Math.max(s,c),clearTimeout(d.animationResetTimer),d.animationResetTimer=setTimeout(function(){d.animationTime=0,d.prevFromRect=null,d.fromRect=null,d.prevToRect=null,d.thisAnimationDuration=null},c),d.thisAnimationDuration=c)}),clearTimeout(t),o?t=setTimeout(function(){typeof r=="function"&&r()},s):typeof r=="function"&&r(),e=[]},animate:function(r,i,o,s){if(s){Xe(r,"transition",""),Xe(r,"transform","");var l=Lo(this.el),c=l&&l.a,d=l&&l.d,p=(i.left-o.left)/(c||1),y=(i.top-o.top)/(d||1);r.animatingX=!!p,r.animatingY=!!y,Xe(r,"transform","translate3d("+p+"px,"+y+"px,0)"),this.forRepaintDummy=N1(r),Xe(r,"transition","transform "+s+"ms"+(this.options.easing?" "+this.options.easing:"")),Xe(r,"transform","translate3d(0,0,0)"),typeof r.animated=="number"&&clearTimeout(r.animated),r.animated=setTimeout(function(){Xe(r,"transition",""),Xe(r,"transform",""),r.animated=!1,r.animatingX=!1,r.animatingY=!1},s)}}}}function N1(e){return e.offsetWidth}function M1(e,t,n,r){return Math.sqrt(Math.pow(t.top-e.top,2)+Math.pow(t.left-e.left,2))/Math.sqrt(Math.pow(t.top-n.top,2)+Math.pow(t.left-n.left,2))*r.animation}var Io=[],Hc={initializeByDefault:!0},Us={mount:function(t){for(var n in Hc)Hc.hasOwnProperty(n)&&!(n in t)&&(t[n]=Hc[n]);Io.forEach(function(r){if(r.pluginName===t.pluginName)throw"Sortable: Cannot mount plugin ".concat(t.pluginName," more than once")}),Io.push(t)},pluginEvent:function(t,n,r){var i=this;this.eventCanceled=!1,r.cancel=function(){i.eventCanceled=!0};var o=t+"Global";Io.forEach(function(s){n[s.pluginName]&&(n[s.pluginName][o]&&n[s.pluginName][o](Ir({sortable:n},r)),n.options[s.pluginName]&&n[s.pluginName][t]&&n[s.pluginName][t](Ir({sortable:n},r)))})},initializePlugins:function(t,n,r,i){Io.forEach(function(l){var c=l.pluginName;if(!(!t.options[c]&&!l.initializeByDefault)){var d=new l(t,n,t.options);d.sortable=t,d.options=t.options,t[c]=d,Yr(r,d.defaults)}});for(var o in t.options)if(t.options.hasOwnProperty(o)){var s=this.modifyOption(t,o,t.options[o]);typeof s<"u"&&(t.options[o]=s)}},getEventProperties:function(t,n){var r={};return Io.forEach(function(i){typeof i.eventProperties=="function"&&Yr(r,i.eventProperties.call(n[i.pluginName],t))}),r},modifyOption:function(t,n,r){var i;return Io.forEach(function(o){t[o.pluginName]&&o.optionListeners&&typeof o.optionListeners[n]=="function"&&(i=o.optionListeners[n].call(t[o.pluginName],r))}),i}};function F1(e){var t=e.sortable,n=e.rootEl,r=e.name,i=e.targetEl,o=e.cloneEl,s=e.toEl,l=e.fromEl,c=e.oldIndex,d=e.newIndex,p=e.oldDraggableIndex,y=e.newDraggableIndex,m=e.originalEvent,C=e.putSortable,b=e.extraEventProperties;if(t=t||n&&n[zn],!!t){var k,L=t.options,O="on"+r.charAt(0).toUpperCase()+r.substr(1);window.CustomEvent&&!Jr&&!$s?k=new CustomEvent(r,{bubbles:!0,cancelable:!0}):(k=document.createEvent("Event"),k.initEvent(r,!0,!0)),k.to=s||n,k.from=l||n,k.item=i||n,k.clone=o,k.oldIndex=c,k.newIndex=d,k.oldDraggableIndex=p,k.newDraggableIndex=y,k.originalEvent=m,k.pullMode=C?C.lastPutMode:void 0;var $=Ir(Ir({},b),Us.getEventProperties(r,t));for(var X in $)k[X]=$[X];n&&n.dispatchEvent(k),L[O]&&L[O].call(t,k)}}var B1=["evt"],Mn=function(t,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=r.evt,o=E1(r,B1);Us.pluginEvent.bind(Je)(t,n,Ir({dragEl:Le,parentEl:Ut,ghostEl:ut,rootEl:Mt,nextEl:Wi,lastDownEl:Tl,cloneEl:Bt,cloneHidden:bi,dragStarted:Ks,putSortable:pn,activeSortable:Je.active,originalEvent:i,oldIndex:Po,oldDraggableIndex:Ws,newIndex:Gn,newDraggableIndex:Ci,hideGhostForTarget:Eg,unhideGhostForTarget:Lg,cloneNowHidden:function(){bi=!0},cloneNowShown:function(){bi=!1},dispatchSortableEvent:function(l){En({sortable:n,name:l,originalEvent:i})}},o))};function En(e){F1(Ir({putSortable:pn,cloneEl:Bt,targetEl:Le,rootEl:Mt,oldIndex:Po,oldDraggableIndex:Ws,newIndex:Gn,newDraggableIndex:Ci},e))}var Le,Ut,ut,Mt,Wi,Tl,Bt,bi,Po,Gn,Ws,Ci,kl,pn,Do=!1,xl=!1,Sl=[],Ki,Cr,jc,Uc,wg,Tg,Ks,Ro,Vs,qs=!1,Al=!1,El,Cn,Wc=[],Kc=!1,Ll=[],Ol=typeof document<"u",Il=dg,kg=$s||Jr?"cssFloat":"float",$1=Ol&&!pg&&!dg&&"draggable"in document.createElement("div"),xg=function(){if(Ol){if(Jr)return!1;var e=document.createElement("x");return e.style.cssText="pointer-events:auto",e.style.pointerEvents==="auto"}}(),Sg=function(t,n){var r=Xe(t),i=parseInt(r.width)-parseInt(r.paddingLeft)-parseInt(r.paddingRight)-parseInt(r.borderLeftWidth)-parseInt(r.borderRightWidth),o=Oo(t,0,n),s=Oo(t,1,n),l=o&&Xe(o),c=s&&Xe(s),d=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+rn(o).width,p=c&&parseInt(c.marginLeft)+parseInt(c.marginRight)+rn(s).width;if(r.display==="flex")return r.flexDirection==="column"||r.flexDirection==="column-reverse"?"vertical":"horizontal";if(r.display==="grid")return r.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(o&&l.float&&l.float!=="none"){var y=l.float==="left"?"left":"right";return s&&(c.clear==="both"||c.clear===y)?"vertical":"horizontal"}return o&&(l.display==="block"||l.display==="flex"||l.display==="table"||l.display==="grid"||d>=i&&r[kg]==="none"||s&&r[kg]==="none"&&d+p>i)?"vertical":"horizontal"},H1=function(t,n,r){var i=r?t.left:t.top,o=r?t.right:t.bottom,s=r?t.width:t.height,l=r?n.left:n.top,c=r?n.right:n.bottom,d=r?n.width:n.height;return i===l||o===c||i+s/2===l+d/2},j1=function(t,n){var r;return Sl.some(function(i){var o=i[zn].options.emptyInsertThreshold;if(!(!o||Bc(i))){var s=rn(i),l=t>=s.left-o&&t<=s.right+o,c=n>=s.top-o&&n<=s.bottom+o;if(l&&c)return r=i}}),r},Ag=function(t){function n(o,s){return function(l,c,d,p){var y=l.options.group.name&&c.options.group.name&&l.options.group.name===c.options.group.name;if(o==null&&(s||y))return!0;if(o==null||o===!1)return!1;if(s&&o==="clone")return o;if(typeof o=="function")return n(o(l,c,d,p),s)(l,c,d,p);var m=(s?l:c).options.group.name;return o===!0||typeof o=="string"&&o===m||o.join&&o.indexOf(m)>-1}}var r={},i=t.group;(!i||_l(i)!="object")&&(i={name:i}),r.name=i.name,r.checkPull=n(i.pull,!0),r.checkPut=n(i.put),r.revertClone=i.revertClone,t.group=r},Eg=function(){!xg&&ut&&Xe(ut,"display","none")},Lg=function(){!xg&&ut&&Xe(ut,"display","")};Ol&&!pg&&document.addEventListener("click",function(e){if(xl)return e.preventDefault(),e.stopPropagation&&e.stopPropagation(),e.stopImmediatePropagation&&e.stopImmediatePropagation(),xl=!1,!1},!0);var Vi=function(t){if(Le){t=t.touches?t.touches[0]:t;var n=j1(t.clientX,t.clientY);if(n){var r={};for(var i in t)t.hasOwnProperty(i)&&(r[i]=t[i]);r.target=r.rootEl=n,r.preventDefault=void 0,r.stopPropagation=void 0,n[zn]._onDragOver(r)}}},U1=function(t){Le&&Le.parentNode[zn]._isOutsideThisEl(t.target)};function Je(e,t){if(!(e&&e.nodeType&&e.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(e));this.el=e,this.options=t=Yr({},t),e[zn]=this;var n={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(e.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return Sg(e,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(s,l){s.setData("Text",l.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:Je.supportPointer!==!1&&"PointerEvent"in window&&!Hs,emptyInsertThreshold:5};Us.initializePlugins(this,e,n);for(var r in n)!(r in t)&&(t[r]=n[r]);Ag(t);for(var i in this)i.charAt(0)==="_"&&typeof this[i]=="function"&&(this[i]=this[i].bind(this));this.nativeDraggable=t.forceFallback?!1:$1,this.nativeDraggable&&(this.options.touchStartThreshold=1),t.supportPointer?At(e,"pointerdown",this._onTapStart):(At(e,"mousedown",this._onTapStart),At(e,"touchstart",this._onTapStart)),this.nativeDraggable&&(At(e,"dragover",this),At(e,"dragenter",this)),Sl.push(this.el),t.store&&t.store.get&&this.sort(t.store.get(this)||[]),Yr(this,R1())}Je.prototype={constructor:Je,_isOutsideThisEl:function(t){!this.el.contains(t)&&t!==this.el&&(Ro=null)},_getDirection:function(t,n){return typeof this.options.direction=="function"?this.options.direction.call(this,t,n,Le):this.options.direction},_onTapStart:function(t){if(t.cancelable){var n=this,r=this.el,i=this.options,o=i.preventOnFilter,s=t.type,l=t.touches&&t.touches[0]||t.pointerType&&t.pointerType==="touch"&&t,c=(l||t).target,d=t.target.shadowRoot&&(t.path&&t.path[0]||t.composedPath&&t.composedPath()[0])||c,p=i.filter;if(X1(r),!Le&&!(/mousedown|pointerdown/.test(s)&&t.button!==0||i.disabled)&&!d.isContentEditable&&!(!this.nativeDraggable&&Hs&&c&&c.tagName.toUpperCase()==="SELECT")&&(c=Pr(c,i.draggable,r,!1),!(c&&c.animated)&&Tl!==c)){if(Po=ar(c),Ws=ar(c,i.draggable),typeof p=="function"){if(p.call(this,t,c,this)){En({sortable:n,rootEl:d,name:"filter",targetEl:c,toEl:r,fromEl:r}),Mn("filter",n,{evt:t}),o&&t.cancelable&&t.preventDefault();return}}else if(p&&(p=p.split(",").some(function(y){if(y=Pr(d,y.trim(),r,!1),y)return En({sortable:n,rootEl:y,name:"filter",targetEl:c,fromEl:r,toEl:r}),Mn("filter",n,{evt:t}),!0}),p)){o&&t.cancelable&&t.preventDefault();return}i.handle&&!Pr(d,i.handle,r,!1)||this._prepareDragStart(t,l,c)}}},_prepareDragStart:function(t,n,r){var i=this,o=i.el,s=i.options,l=o.ownerDocument,c;if(r&&!Le&&r.parentNode===o){var d=rn(r);if(Mt=o,Le=r,Ut=Le.parentNode,Wi=Le.nextSibling,Tl=r,kl=s.group,Je.dragged=Le,Ki={target:Le,clientX:(n||t).clientX,clientY:(n||t).clientY},wg=Ki.clientX-d.left,Tg=Ki.clientY-d.top,this._lastX=(n||t).clientX,this._lastY=(n||t).clientY,Le.style["will-change"]="all",c=function(){if(Mn("delayEnded",i,{evt:t}),Je.eventCanceled){i._onDrop();return}i._disableDelayedDragEvents(),!fg&&i.nativeDraggable&&(Le.draggable=!0),i._triggerDragStart(t,n),En({sortable:i,name:"choose",originalEvent:t}),qn(Le,s.chosenClass,!0)},s.ignore.split(",").forEach(function(p){mg(Le,p.trim(),Vc)}),At(l,"dragover",Vi),At(l,"mousemove",Vi),At(l,"touchmove",Vi),At(l,"mouseup",i._onDrop),At(l,"touchend",i._onDrop),At(l,"touchcancel",i._onDrop),fg&&this.nativeDraggable&&(this.options.touchStartThreshold=4,Le.draggable=!0),Mn("delayStart",this,{evt:t}),s.delay&&(!s.delayOnTouchOnly||n)&&(!this.nativeDraggable||!($s||Jr))){if(Je.eventCanceled){this._onDrop();return}At(l,"mouseup",i._disableDelayedDrag),At(l,"touchend",i._disableDelayedDrag),At(l,"touchcancel",i._disableDelayedDrag),At(l,"mousemove",i._delayedDragTouchMoveHandler),At(l,"touchmove",i._delayedDragTouchMoveHandler),s.supportPointer&&At(l,"pointermove",i._delayedDragTouchMoveHandler),i._dragStartTimer=setTimeout(c,s.delay)}else c()}},_delayedDragTouchMoveHandler:function(t){var n=t.touches?t.touches[0]:t;Math.max(Math.abs(n.clientX-this._lastX),Math.abs(n.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){Le&&Vc(Le),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var t=this.el.ownerDocument;_t(t,"mouseup",this._disableDelayedDrag),_t(t,"touchend",this._disableDelayedDrag),_t(t,"touchcancel",this._disableDelayedDrag),_t(t,"mousemove",this._delayedDragTouchMoveHandler),_t(t,"touchmove",this._delayedDragTouchMoveHandler),_t(t,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(t,n){n=n||t.pointerType=="touch"&&t,!this.nativeDraggable||n?this.options.supportPointer?At(document,"pointermove",this._onTouchMove):n?At(document,"touchmove",this._onTouchMove):At(document,"mousemove",this._onTouchMove):(At(Le,"dragend",this),At(Mt,"dragstart",this._onDragStart));try{document.selection?Dl(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(t,n){if(Do=!1,Mt&&Le){Mn("dragStarted",this,{evt:n}),this.nativeDraggable&&At(document,"dragover",U1);var r=this.options;!t&&qn(Le,r.dragClass,!1),qn(Le,r.ghostClass,!0),Je.active=this,t&&this._appendGhost(),En({sortable:this,name:"start",originalEvent:n})}else this._nulling()},_emulateDragOver:function(){if(Cr){this._lastX=Cr.clientX,this._lastY=Cr.clientY,Eg();for(var t=document.elementFromPoint(Cr.clientX,Cr.clientY),n=t;t&&t.shadowRoot&&(t=t.shadowRoot.elementFromPoint(Cr.clientX,Cr.clientY),t!==n);)n=t;if(Le.parentNode[zn]._isOutsideThisEl(t),n)do{if(n[zn]){var r=void 0;if(r=n[zn]._onDragOver({clientX:Cr.clientX,clientY:Cr.clientY,target:t,rootEl:n}),r&&!this.options.dragoverBubble)break}t=n}while(n=n.parentNode);Lg()}},_onTouchMove:function(t){if(Ki){var n=this.options,r=n.fallbackTolerance,i=n.fallbackOffset,o=t.touches?t.touches[0]:t,s=ut&&Lo(ut,!0),l=ut&&s&&s.a,c=ut&&s&&s.d,d=Il&&Cn&&yg(Cn),p=(o.clientX-Ki.clientX+i.x)/(l||1)+(d?d[0]-Wc[0]:0)/(l||1),y=(o.clientY-Ki.clientY+i.y)/(c||1)+(d?d[1]-Wc[1]:0)/(c||1);if(!Je.active&&!Do){if(r&&Math.max(Math.abs(o.clientX-this._lastX),Math.abs(o.clientY-this._lastY))<r)return;this._onDragStart(t,!0)}if(ut){s?(s.e+=p-(jc||0),s.f+=y-(Uc||0)):s={a:1,b:0,c:0,d:1,e:p,f:y};var m="matrix(".concat(s.a,",").concat(s.b,",").concat(s.c,",").concat(s.d,",").concat(s.e,",").concat(s.f,")");Xe(ut,"webkitTransform",m),Xe(ut,"mozTransform",m),Xe(ut,"msTransform",m),Xe(ut,"transform",m),jc=p,Uc=y,Cr=o}t.cancelable&&t.preventDefault()}},_appendGhost:function(){if(!ut){var t=this.options.fallbackOnBody?document.body:Mt,n=rn(Le,!0,Il,!0,t),r=this.options;if(Il){for(Cn=t;Xe(Cn,"position")==="static"&&Xe(Cn,"transform")==="none"&&Cn!==document;)Cn=Cn.parentNode;Cn!==document.body&&Cn!==document.documentElement?(Cn===document&&(Cn=Dr()),n.top+=Cn.scrollTop,n.left+=Cn.scrollLeft):Cn=Dr(),Wc=yg(Cn)}ut=Le.cloneNode(!0),qn(ut,r.ghostClass,!1),qn(ut,r.fallbackClass,!0),qn(ut,r.dragClass,!0),Xe(ut,"transition",""),Xe(ut,"transform",""),Xe(ut,"box-sizing","border-box"),Xe(ut,"margin",0),Xe(ut,"top",n.top),Xe(ut,"left",n.left),Xe(ut,"width",n.width),Xe(ut,"height",n.height),Xe(ut,"opacity","0.8"),Xe(ut,"position",Il?"absolute":"fixed"),Xe(ut,"zIndex","100000"),Xe(ut,"pointerEvents","none"),Je.ghost=ut,t.appendChild(ut),Xe(ut,"transform-origin",wg/parseInt(ut.style.width)*100+"% "+Tg/parseInt(ut.style.height)*100+"%")}},_onDragStart:function(t,n){var r=this,i=t.dataTransfer,o=r.options;if(Mn("dragStart",this,{evt:t}),Je.eventCanceled){this._onDrop();return}Mn("setupClone",this),Je.eventCanceled||(Bt=_g(Le),Bt.removeAttribute("id"),Bt.draggable=!1,Bt.style["will-change"]="",this._hideClone(),qn(Bt,this.options.chosenClass,!1),Je.clone=Bt),r.cloneId=Dl(function(){Mn("clone",r),!Je.eventCanceled&&(r.options.removeCloneOnHide||Mt.insertBefore(Bt,Le),r._hideClone(),En({sortable:r,name:"clone"}))}),!n&&qn(Le,o.dragClass,!0),n?(xl=!0,r._loopId=setInterval(r._emulateDragOver,50)):(_t(document,"mouseup",r._onDrop),_t(document,"touchend",r._onDrop),_t(document,"touchcancel",r._onDrop),i&&(i.effectAllowed="move",o.setData&&o.setData.call(r,i,Le)),At(document,"drop",r),Xe(Le,"transform","translateZ(0)")),Do=!0,r._dragStartId=Dl(r._dragStarted.bind(r,n,t)),At(document,"selectstart",r),Ks=!0,Hs&&Xe(document.body,"user-select","none")},_onDragOver:function(t){var n=this.el,r=t.target,i,o,s,l=this.options,c=l.group,d=Je.active,p=kl===c,y=l.sort,m=pn||d,C,b=this,k=!1;if(Kc)return;function L(ae,pe){Mn(ae,b,Ir({evt:t,isOwner:p,axis:C?"vertical":"horizontal",revert:s,dragRect:i,targetRect:o,canSort:y,fromSortable:m,target:r,completed:$,onMove:function(et,se){return Pl(Mt,n,Le,i,et,rn(et),t,se)},changed:X},pe))}function O(){L("dragOverAnimationCapture"),b.captureAnimationState(),b!==m&&m.captureAnimationState()}function $(ae){return L("dragOverCompleted",{insertion:ae}),ae&&(p?d._hideClone():d._showClone(b),b!==m&&(qn(Le,pn?pn.options.ghostClass:d.options.ghostClass,!1),qn(Le,l.ghostClass,!0)),pn!==b&&b!==Je.active?pn=b:b===Je.active&&pn&&(pn=null),m===b&&(b._ignoreWhileAnimating=r),b.animateAll(function(){L("dragOverAnimationComplete"),b._ignoreWhileAnimating=null}),b!==m&&(m.animateAll(),m._ignoreWhileAnimating=null)),(r===Le&&!Le.animated||r===n&&!r.animated)&&(Ro=null),!l.dragoverBubble&&!t.rootEl&&r!==document&&(Le.parentNode[zn]._isOutsideThisEl(t.target),!ae&&Vi(t)),!l.dragoverBubble&&t.stopPropagation&&t.stopPropagation(),k=!0}function X(){Gn=ar(Le),Ci=ar(Le,l.draggable),En({sortable:b,name:"change",toEl:n,newIndex:Gn,newDraggableIndex:Ci,originalEvent:t})}if(t.preventDefault!==void 0&&t.cancelable&&t.preventDefault(),r=Pr(r,l.draggable,n,!0),L("dragOver"),Je.eventCanceled)return k;if(Le.contains(t.target)||r.animated&&r.animatingX&&r.animatingY||b._ignoreWhileAnimating===r)return $(!1);if(xl=!1,d&&!l.disabled&&(p?y||(s=Ut!==Mt):pn===this||(this.lastPutMode=kl.checkPull(this,d,Le,t))&&c.checkPut(this,d,Le,t))){if(C=this._getDirection(t,r)==="vertical",i=rn(Le),L("dragOverValid"),Je.eventCanceled)return k;if(s)return Ut=Mt,O(),this._hideClone(),L("revert"),Je.eventCanceled||(Wi?Mt.insertBefore(Le,Wi):Mt.appendChild(Le)),$(!0);var x=Bc(n,l.draggable);if(!x||q1(t,C,this)&&!x.animated){if(x===Le)return $(!1);if(x&&n===t.target&&(r=x),r&&(o=rn(r)),Pl(Mt,n,Le,i,r,o,t,!!r)!==!1)return O(),x&&x.nextSibling?n.insertBefore(Le,x.nextSibling):n.appendChild(Le),Ut=n,X(),$(!0)}else if(x&&V1(t,C,this)){var z=Oo(n,0,l,!0);if(z===Le)return $(!1);if(r=z,o=rn(r),Pl(Mt,n,Le,i,r,o,t,!1)!==!1)return O(),n.insertBefore(Le,z),Ut=n,X(),$(!0)}else if(r.parentNode===n){o=rn(r);var Q=0,g,I=Le.parentNode!==n,A=!H1(Le.animated&&Le.toRect||i,r.animated&&r.toRect||o,C),D=C?"top":"left",H=vg(r,"top","top")||vg(Le,"top","top"),K=H?H.scrollTop:void 0;Ro!==r&&(g=o[D],qs=!1,Al=!A&&l.invertSwap||I),Q=z1(t,r,o,C,A?1:l.swapThreshold,l.invertedSwapThreshold==null?l.swapThreshold:l.invertedSwapThreshold,Al,Ro===r);var U;if(Q!==0){var de=ar(Le);do de-=Q,U=Ut.children[de];while(U&&(Xe(U,"display")==="none"||U===ut))}if(Q===0||U===r)return $(!1);Ro=r,Vs=Q;var je=r.nextElementSibling,Pe=!1;Pe=Q===1;var V=Pl(Mt,n,Le,i,r,o,t,Pe);if(V!==!1)return(V===1||V===-1)&&(Pe=V===1),Kc=!0,setTimeout(K1,30),O(),Pe&&!je?n.appendChild(Le):r.parentNode.insertBefore(Le,Pe?je:r),H&&Cg(H,0,K-H.scrollTop),Ut=Le.parentNode,g!==void 0&&!Al&&(El=Math.abs(g-rn(r)[D])),X(),$(!0)}if(n.contains(Le))return $(!1)}return!1},_ignoreWhileAnimating:null,_offMoveEvents:function(){_t(document,"mousemove",this._onTouchMove),_t(document,"touchmove",this._onTouchMove),_t(document,"pointermove",this._onTouchMove),_t(document,"dragover",Vi),_t(document,"mousemove",Vi),_t(document,"touchmove",Vi)},_offUpEvents:function(){var t=this.el.ownerDocument;_t(t,"mouseup",this._onDrop),_t(t,"touchend",this._onDrop),_t(t,"pointerup",this._onDrop),_t(t,"touchcancel",this._onDrop),_t(document,"selectstart",this)},_onDrop:function(t){var n=this.el,r=this.options;if(Gn=ar(Le),Ci=ar(Le,r.draggable),Mn("drop",this,{evt:t}),Ut=Le&&Le.parentNode,Gn=ar(Le),Ci=ar(Le,r.draggable),Je.eventCanceled){this._nulling();return}Do=!1,Al=!1,qs=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),qc(this.cloneId),qc(this._dragStartId),this.nativeDraggable&&(_t(document,"drop",this),_t(n,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),Hs&&Xe(document.body,"user-select",""),Xe(Le,"transform",""),t&&(Ks&&(t.cancelable&&t.preventDefault(),!r.dropBubble&&t.stopPropagation()),ut&&ut.parentNode&&ut.parentNode.removeChild(ut),(Mt===Ut||pn&&pn.lastPutMode!=="clone")&&Bt&&Bt.parentNode&&Bt.parentNode.removeChild(Bt),Le&&(this.nativeDraggable&&_t(Le,"dragend",this),Vc(Le),Le.style["will-change"]="",Ks&&!Do&&qn(Le,pn?pn.options.ghostClass:this.options.ghostClass,!1),qn(Le,this.options.chosenClass,!1),En({sortable:this,name:"unchoose",toEl:Ut,newIndex:null,newDraggableIndex:null,originalEvent:t}),Mt!==Ut?(Gn>=0&&(En({rootEl:Ut,name:"add",toEl:Ut,fromEl:Mt,originalEvent:t}),En({sortable:this,name:"remove",toEl:Ut,originalEvent:t}),En({rootEl:Ut,name:"sort",toEl:Ut,fromEl:Mt,originalEvent:t}),En({sortable:this,name:"sort",toEl:Ut,originalEvent:t})),pn&&pn.save()):Gn!==Po&&Gn>=0&&(En({sortable:this,name:"update",toEl:Ut,originalEvent:t}),En({sortable:this,name:"sort",toEl:Ut,originalEvent:t})),Je.active&&((Gn==null||Gn===-1)&&(Gn=Po,Ci=Ws),En({sortable:this,name:"end",toEl:Ut,originalEvent:t}),this.save()))),this._nulling()},_nulling:function(){Mn("nulling",this),Mt=Le=Ut=ut=Wi=Bt=Tl=bi=Ki=Cr=Ks=Gn=Ci=Po=Ws=Ro=Vs=pn=kl=Je.dragged=Je.ghost=Je.clone=Je.active=null,Ll.forEach(function(t){t.checked=!0}),Ll.length=jc=Uc=0},handleEvent:function(t){switch(t.type){case"drop":case"dragend":this._onDrop(t);break;case"dragenter":case"dragover":Le&&(this._onDragOver(t),W1(t));break;case"selectstart":t.preventDefault();break}},toArray:function(){for(var t=[],n,r=this.el.children,i=0,o=r.length,s=this.options;i<o;i++)n=r[i],Pr(n,s.draggable,this.el,!1)&&t.push(n.getAttribute(s.dataIdAttr)||Y1(n));return t},sort:function(t,n){var r={},i=this.el;this.toArray().forEach(function(o,s){var l=i.children[s];Pr(l,this.options.draggable,i,!1)&&(r[o]=l)},this),n&&this.captureAnimationState(),t.forEach(function(o){r[o]&&(i.removeChild(r[o]),i.appendChild(r[o]))}),n&&this.animateAll()},save:function(){var t=this.options.store;t&&t.set&&t.set(this)},closest:function(t,n){return Pr(t,n||this.options.draggable,this.el,!1)},option:function(t,n){var r=this.options;if(n===void 0)return r[t];var i=Us.modifyOption(this,t,n);typeof i<"u"?r[t]=i:r[t]=n,t==="group"&&Ag(r)},destroy:function(){Mn("destroy",this);var t=this.el;t[zn]=null,_t(t,"mousedown",this._onTapStart),_t(t,"touchstart",this._onTapStart),_t(t,"pointerdown",this._onTapStart),this.nativeDraggable&&(_t(t,"dragover",this),_t(t,"dragenter",this)),Array.prototype.forEach.call(t.querySelectorAll("[draggable]"),function(n){n.removeAttribute("draggable")}),this._onDrop(),this._disableDelayedDragEvents(),Sl.splice(Sl.indexOf(this.el),1),this.el=t=null},_hideClone:function(){if(!bi){if(Mn("hideClone",this),Je.eventCanceled)return;Xe(Bt,"display","none"),this.options.removeCloneOnHide&&Bt.parentNode&&Bt.parentNode.removeChild(Bt),bi=!0}},_showClone:function(t){if(t.lastPutMode!=="clone"){this._hideClone();return}if(bi){if(Mn("showClone",this),Je.eventCanceled)return;Le.parentNode==Mt&&!this.options.group.revertClone?Mt.insertBefore(Bt,Le):Wi?Mt.insertBefore(Bt,Wi):Mt.appendChild(Bt),this.options.group.revertClone&&this.animate(Le,Bt),Xe(Bt,"display",""),bi=!1}}};function W1(e){e.dataTransfer&&(e.dataTransfer.dropEffect="move"),e.cancelable&&e.preventDefault()}function Pl(e,t,n,r,i,o,s,l){var c,d=e[zn],p=d.options.onMove,y;return window.CustomEvent&&!Jr&&!$s?c=new CustomEvent("move",{bubbles:!0,cancelable:!0}):(c=document.createEvent("Event"),c.initEvent("move",!0,!0)),c.to=t,c.from=e,c.dragged=n,c.draggedRect=r,c.related=i||t,c.relatedRect=o||rn(t),c.willInsertAfter=l,c.originalEvent=s,e.dispatchEvent(c),p&&(y=p.call(d,c,s)),y}function Vc(e){e.draggable=!1}function K1(){Kc=!1}function V1(e,t,n){var r=rn(Oo(n.el,0,n.options,!0)),i=10;return t?e.clientX<r.left-i||e.clientY<r.top&&e.clientX<r.right:e.clientY<r.top-i||e.clientY<r.bottom&&e.clientX<r.left}function q1(e,t,n){var r=rn(Bc(n.el,n.options.draggable)),i=10;return t?e.clientX>r.right+i||e.clientX<=r.right&&e.clientY>r.bottom&&e.clientX>=r.left:e.clientX>r.right&&e.clientY>r.top||e.clientX<=r.right&&e.clientY>r.bottom+i}function z1(e,t,n,r,i,o,s,l){var c=r?e.clientY:e.clientX,d=r?n.height:n.width,p=r?n.top:n.left,y=r?n.bottom:n.right,m=!1;if(!s){if(l&&El<d*i){if(!qs&&(Vs===1?c>p+d*o/2:c<y-d*o/2)&&(qs=!0),qs)m=!0;else if(Vs===1?c<p+El:c>y-El)return-Vs}else if(c>p+d*(1-i)/2&&c<y-d*(1-i)/2)return G1(t)}return m=m||s,m&&(c<p+d*o/2||c>y-d*o/2)?c>p+d/2?1:-1:0}function G1(e){return ar(Le)<ar(e)?1:-1}function Y1(e){for(var t=e.tagName+e.className+e.src+e.href+e.textContent,n=t.length,r=0;n--;)r+=t.charCodeAt(n);return r.toString(36)}function X1(e){Ll.length=0;for(var t=e.getElementsByTagName("input"),n=t.length;n--;){var r=t[n];r.checked&&Ll.push(r)}}function Dl(e){return setTimeout(e,0)}function qc(e){return clearTimeout(e)}Ol&&At(document,"touchmove",function(e){(Je.active||Do)&&e.cancelable&&e.preventDefault()}),Je.utils={on:At,off:_t,css:Xe,find:mg,is:function(t,n){return!!Pr(t,n,t,!1)},extend:P1,throttle:bg,closest:Pr,toggleClass:qn,clone:_g,index:ar,nextTick:Dl,cancelNextTick:qc,detectDirection:Sg,getChild:Oo},Je.get=function(e){return e[zn]},Je.mount=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];t[0].constructor===Array&&(t=t[0]),t.forEach(function(r){if(!r.prototype||!r.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(r));r.utils&&(Je.utils=Ir(Ir({},Je.utils),r.utils)),Us.mount(r)})},Je.create=function(e,t){return new Je(e,t)},Je.version=L1;var Xt=[],zs,zc,Gc=!1,Yc,Xc,Rl,Gs;function J1(){function e(){this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0};for(var t in this)t.charAt(0)==="_"&&typeof this[t]=="function"&&(this[t]=this[t].bind(this))}return e.prototype={dragStarted:function(n){var r=n.originalEvent;this.sortable.nativeDraggable?At(document,"dragover",this._handleAutoScroll):this.options.supportPointer?At(document,"pointermove",this._handleFallbackAutoScroll):r.touches?At(document,"touchmove",this._handleFallbackAutoScroll):At(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(n){var r=n.originalEvent;!this.options.dragOverBubble&&!r.rootEl&&this._handleAutoScroll(r)},drop:function(){this.sortable.nativeDraggable?_t(document,"dragover",this._handleAutoScroll):(_t(document,"pointermove",this._handleFallbackAutoScroll),_t(document,"touchmove",this._handleFallbackAutoScroll),_t(document,"mousemove",this._handleFallbackAutoScroll)),Og(),Nl(),D1()},nulling:function(){Rl=zc=zs=Gc=Gs=Yc=Xc=null,Xt.length=0},_handleFallbackAutoScroll:function(n){this._handleAutoScroll(n,!0)},_handleAutoScroll:function(n,r){var i=this,o=(n.touches?n.touches[0]:n).clientX,s=(n.touches?n.touches[0]:n).clientY,l=document.elementFromPoint(o,s);if(Rl=n,r||this.options.forceAutoScrollFallback||$s||Jr||Hs){Jc(n,this.options,l,r);var c=yi(l,!0);Gc&&(!Gs||o!==Yc||s!==Xc)&&(Gs&&Og(),Gs=setInterval(function(){var d=yi(document.elementFromPoint(o,s),!0);d!==c&&(c=d,Nl()),Jc(n,i.options,d,r)},10),Yc=o,Xc=s)}else{if(!this.options.bubbleScroll||yi(l,!0)===Dr()){Nl();return}Jc(n,this.options,yi(l,!1),!1)}}},Yr(e,{pluginName:"scroll",initializeByDefault:!0})}function Nl(){Xt.forEach(function(e){clearInterval(e.pid)}),Xt=[]}function Og(){clearInterval(Gs)}var Jc=bg(function(e,t,n,r){if(t.scroll){var i=(e.touches?e.touches[0]:e).clientX,o=(e.touches?e.touches[0]:e).clientY,s=t.scrollSensitivity,l=t.scrollSpeed,c=Dr(),d=!1,p;zc!==n&&(zc=n,Nl(),zs=t.scroll,p=t.scrollFn,zs===!0&&(zs=yi(n,!0)));var y=0,m=zs;do{var C=m,b=rn(C),k=b.top,L=b.bottom,O=b.left,$=b.right,X=b.width,x=b.height,z=void 0,Q=void 0,g=C.scrollWidth,I=C.scrollHeight,A=Xe(C),D=C.scrollLeft,H=C.scrollTop;C===c?(z=X<g&&(A.overflowX==="auto"||A.overflowX==="scroll"||A.overflowX==="visible"),Q=x<I&&(A.overflowY==="auto"||A.overflowY==="scroll"||A.overflowY==="visible")):(z=X<g&&(A.overflowX==="auto"||A.overflowX==="scroll"),Q=x<I&&(A.overflowY==="auto"||A.overflowY==="scroll"));var K=z&&(Math.abs($-i)<=s&&D+X<g)-(Math.abs(O-i)<=s&&!!D),U=Q&&(Math.abs(L-o)<=s&&H+x<I)-(Math.abs(k-o)<=s&&!!H);if(!Xt[y])for(var de=0;de<=y;de++)Xt[de]||(Xt[de]={});(Xt[y].vx!=K||Xt[y].vy!=U||Xt[y].el!==C)&&(Xt[y].el=C,Xt[y].vx=K,Xt[y].vy=U,clearInterval(Xt[y].pid),(K!=0||U!=0)&&(d=!0,Xt[y].pid=setInterval((function(){r&&this.layer===0&&Je.active._onTouchMove(Rl);var je=Xt[this.layer].vy?Xt[this.layer].vy*l:0,Pe=Xt[this.layer].vx?Xt[this.layer].vx*l:0;typeof p=="function"&&p.call(Je.dragged.parentNode[zn],Pe,je,e,Rl,Xt[this.layer].el)!=="continue"||Cg(Xt[this.layer].el,Pe,je)}).bind({layer:y}),24))),y++}while(t.bubbleScroll&&m!==c&&(m=yi(m,!1)));Gc=d}},30),Ig=function(t){var n=t.originalEvent,r=t.putSortable,i=t.dragEl,o=t.activeSortable,s=t.dispatchSortableEvent,l=t.hideGhostForTarget,c=t.unhideGhostForTarget;if(n){var d=r||o;l();var p=n.changedTouches&&n.changedTouches.length?n.changedTouches[0]:n,y=document.elementFromPoint(p.clientX,p.clientY);c(),d&&!d.el.contains(y)&&(s("spill"),this.onSpill({dragEl:i,putSortable:r}))}};function Zc(){}Zc.prototype={startIndex:null,dragStart:function(t){var n=t.oldDraggableIndex;this.startIndex=n},onSpill:function(t){var n=t.dragEl,r=t.putSortable;this.sortable.captureAnimationState(),r&&r.captureAnimationState();var i=Oo(this.sortable.el,this.startIndex,this.options);i?this.sortable.el.insertBefore(n,i):this.sortable.el.appendChild(n),this.sortable.animateAll(),r&&r.animateAll()},drop:Ig},Yr(Zc,{pluginName:"revertOnSpill"});function Qc(){}Qc.prototype={onSpill:function(t){var n=t.dragEl,r=t.putSortable,i=r||this.sortable;i.captureAnimationState(),n.parentNode&&n.parentNode.removeChild(n),i.animateAll()},drop:Ig},Yr(Qc,{pluginName:"removeOnSpill"}),Je.mount(new J1),Je.mount(Qc,Zc);const Z1=(e,t=!1,n=!1)=>{if(e==null||e===!1||e===""||e.trim()==="")return[];e=e.replace(/,/g,","),e=e.replace(/。/g,","),e=e.replace(/、/g,","),e=e.replace(/;/g,","),e=e.replace(/./g,","),e=e.replace(/\t/g,`
|
||
`),e=e.replace(/\r/g,`
|
||
`),e=e.replace(/\n+/g,`
|
||
`),e=e.replace(/\>_\</g,"|||EXPRESSION1|||");const r={"(":")","[":"]","<":">","{":"}"},i=Object.keys(r);let o=e.length,s="",l="",c="",d=0,p=[];for(let m=0;m<o;m++){const C=e[m];C===`
|
||
`?l===""?(s.trim()!==""&&p.push(s.trim()),p.push(`
|
||
`),d=0,l="",c="",s=""):s+=" ":C===","?l===""?(p.push(s.trim()),d=0,l="",c="",s=""):s+=C:l===""?i.includes(C)?(d=1,l=C,c=r[C],s+=C):C===" "&&s.trim()==="BREAK"?(p.push(s.trim()),d=0,l="",c="",s=""):(s+=C,s.endsWith(" BREAK")&&(s=s.substring(0,s.length-6),p.push(s.trim()),p.push("BREAK"),d=0,l="",c="",s="")):C===c?(d--,d===0&&(l="",c=""),s+=C):(C===l&&d++,s+=C)}s!==""&&p.push(s.trim());let y=[];for(let m of p){if(m===`
|
||
`){y.push(m);continue}let C=m[0],b=m[m.length-1];if(C==="["&&b==="]"){y.push(m);continue}if(C==="("&&b===")"){y.push(m);continue}let k=/\<lora:[^\>]+\>/,L=null,O=[];for(;L=k.exec(m);){let $=L.index,X=$+L[0].length,x=m.substring(0,$),z=m.substring(X),Q=L[0];O.push(x),O.push(Q),m=z}O.push(m);for(let $ of O)$===""||$.trim()===""||($=$.replace(/\|\|\|EXPRESSION1\|\|\|/g,">_<"),y.push($))}return p=y,p},Ys={name:"Physton/sd-webui-prompt-all-in-one",shortName:"sd-webui-prompt-all-in-one",github:"https://github.com/Physton/sd-webui-prompt-all-in-one",nameAssets:"Physton/sd-webui-prompt-all-in-one-assets",shortNameAssets:"sd-webui-prompt-all-in-one-assets",githubAssets:"https://github.com/Physton/sd-webui-prompt-all-in-one-assets",gitee:"https://gitee.com/Physton/sd-webui-prompt-all-in-one",docs:"https://aiodoc.physton.com",nameTagComplete:"DominikDoom/a1111-sd-webui-tagcomplete",shortNameTagComplete:"a1111-sd-webui-tagcomplete",githubTagComplete:"https://github.com/DominikDoom/a1111-sd-webui-tagcomplete",civitaiUrl:"https://civitai.com"};function Ml(e){"@babel/helpers - typeof";return Ml=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ml(e)}var Q1=/^\s+/,ew=/\s+$/;function Ie(e,t){if(e=e||"",t=t||{},e instanceof Ie)return e;if(!(this instanceof Ie))return new Ie(e,t);var n=tw(e);this._originalInput=e,this._r=n.r,this._g=n.g,this._b=n.b,this._a=n.a,this._roundA=Math.round(100*this._a)/100,this._format=t.format||n.format,this._gradientType=t.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._ok=n.ok}Ie.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var t=this.toRgb();return(t.r*299+t.g*587+t.b*114)/1e3},getLuminance:function(){var t=this.toRgb(),n,r,i,o,s,l;return n=t.r/255,r=t.g/255,i=t.b/255,n<=.03928?o=n/12.92:o=Math.pow((n+.055)/1.055,2.4),r<=.03928?s=r/12.92:s=Math.pow((r+.055)/1.055,2.4),i<=.03928?l=i/12.92:l=Math.pow((i+.055)/1.055,2.4),.2126*o+.7152*s+.0722*l},setAlpha:function(t){return this._a=Fg(t),this._roundA=Math.round(100*this._a)/100,this},toHsv:function(){var t=Dg(this._r,this._g,this._b);return{h:t.h*360,s:t.s,v:t.v,a:this._a}},toHsvString:function(){var t=Dg(this._r,this._g,this._b),n=Math.round(t.h*360),r=Math.round(t.s*100),i=Math.round(t.v*100);return this._a==1?"hsv("+n+", "+r+"%, "+i+"%)":"hsva("+n+", "+r+"%, "+i+"%, "+this._roundA+")"},toHsl:function(){var t=Pg(this._r,this._g,this._b);return{h:t.h*360,s:t.s,l:t.l,a:this._a}},toHslString:function(){var t=Pg(this._r,this._g,this._b),n=Math.round(t.h*360),r=Math.round(t.s*100),i=Math.round(t.l*100);return this._a==1?"hsl("+n+", "+r+"%, "+i+"%)":"hsla("+n+", "+r+"%, "+i+"%, "+this._roundA+")"},toHex:function(t){return Rg(this._r,this._g,this._b,t)},toHexString:function(t){return"#"+this.toHex(t)},toHex8:function(t){return ow(this._r,this._g,this._b,this._a,t)},toHex8String:function(t){return"#"+this.toHex8(t)},toRgb:function(){return{r:Math.round(this._r),g:Math.round(this._g),b:Math.round(this._b),a:this._a}},toRgbString:function(){return this._a==1?"rgb("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+")":"rgba("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:Math.round(Ft(this._r,255)*100)+"%",g:Math.round(Ft(this._g,255)*100)+"%",b:Math.round(Ft(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+Math.round(Ft(this._r,255)*100)+"%, "+Math.round(Ft(this._g,255)*100)+"%, "+Math.round(Ft(this._b,255)*100)+"%)":"rgba("+Math.round(Ft(this._r,255)*100)+"%, "+Math.round(Ft(this._g,255)*100)+"%, "+Math.round(Ft(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){return this._a===0?"transparent":this._a<1?!1:vw[Rg(this._r,this._g,this._b,!0)]||!1},toFilter:function(t){var n="#"+Ng(this._r,this._g,this._b,this._a),r=n,i=this._gradientType?"GradientType = 1, ":"";if(t){var o=Ie(t);r="#"+Ng(o._r,o._g,o._b,o._a)}return"progid:DXImageTransform.Microsoft.gradient("+i+"startColorstr="+n+",endColorstr="+r+")"},toString:function(t){var n=!!t;t=t||this._format;var r=!1,i=this._a<1&&this._a>=0,o=!n&&i&&(t==="hex"||t==="hex6"||t==="hex3"||t==="hex4"||t==="hex8"||t==="name");return o?t==="name"&&this._a===0?this.toName():this.toRgbString():(t==="rgb"&&(r=this.toRgbString()),t==="prgb"&&(r=this.toPercentageRgbString()),(t==="hex"||t==="hex6")&&(r=this.toHexString()),t==="hex3"&&(r=this.toHexString(!0)),t==="hex4"&&(r=this.toHex8String(!0)),t==="hex8"&&(r=this.toHex8String()),t==="name"&&(r=this.toName()),t==="hsl"&&(r=this.toHslString()),t==="hsv"&&(r=this.toHsvString()),r||this.toHexString())},clone:function(){return Ie(this.toString())},_applyModification:function(t,n){var r=t.apply(null,[this].concat([].slice.call(n)));return this._r=r._r,this._g=r._g,this._b=r._b,this.setAlpha(r._a),this},lighten:function(){return this._applyModification(uw,arguments)},brighten:function(){return this._applyModification(cw,arguments)},darken:function(){return this._applyModification(fw,arguments)},desaturate:function(){return this._applyModification(sw,arguments)},saturate:function(){return this._applyModification(aw,arguments)},greyscale:function(){return this._applyModification(lw,arguments)},spin:function(){return this._applyModification(dw,arguments)},_applyCombination:function(t,n){return t.apply(null,[this].concat([].slice.call(n)))},analogous:function(){return this._applyCombination(gw,arguments)},complement:function(){return this._applyCombination(pw,arguments)},monochromatic:function(){return this._applyCombination(mw,arguments)},splitcomplement:function(){return this._applyCombination(hw,arguments)},triad:function(){return this._applyCombination(Mg,[3])},tetrad:function(){return this._applyCombination(Mg,[4])}},Ie.fromRatio=function(e,t){if(Ml(e)=="object"){var n={};for(var r in e)e.hasOwnProperty(r)&&(r==="a"?n[r]=e[r]:n[r]=Xs(e[r]));e=n}return Ie(e,t)};function tw(e){var t={r:0,g:0,b:0},n=1,r=null,i=null,o=null,s=!1,l=!1;return typeof e=="string"&&(e=_w(e)),Ml(e)=="object"&&(Zr(e.r)&&Zr(e.g)&&Zr(e.b)?(t=nw(e.r,e.g,e.b),s=!0,l=String(e.r).substr(-1)==="%"?"prgb":"rgb"):Zr(e.h)&&Zr(e.s)&&Zr(e.v)?(r=Xs(e.s),i=Xs(e.v),t=iw(e.h,r,i),s=!0,l="hsv"):Zr(e.h)&&Zr(e.s)&&Zr(e.l)&&(r=Xs(e.s),o=Xs(e.l),t=rw(e.h,r,o),s=!0,l="hsl"),e.hasOwnProperty("a")&&(n=e.a)),n=Fg(n),{ok:s,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}}function nw(e,t,n){return{r:Ft(e,255)*255,g:Ft(t,255)*255,b:Ft(n,255)*255}}function Pg(e,t,n){e=Ft(e,255),t=Ft(t,255),n=Ft(n,255);var r=Math.max(e,t,n),i=Math.min(e,t,n),o,s,l=(r+i)/2;if(r==i)o=s=0;else{var c=r-i;switch(s=l>.5?c/(2-r-i):c/(r+i),r){case e:o=(t-n)/c+(t<n?6:0);break;case t:o=(n-e)/c+2;break;case n:o=(e-t)/c+4;break}o/=6}return{h:o,s,l}}function rw(e,t,n){var r,i,o;e=Ft(e,360),t=Ft(t,100),n=Ft(n,100);function s(d,p,y){return y<0&&(y+=1),y>1&&(y-=1),y<1/6?d+(p-d)*6*y:y<1/2?p:y<2/3?d+(p-d)*(2/3-y)*6:d}if(t===0)r=i=o=n;else{var l=n<.5?n*(1+t):n+t-n*t,c=2*n-l;r=s(c,l,e+1/3),i=s(c,l,e),o=s(c,l,e-1/3)}return{r:r*255,g:i*255,b:o*255}}function Dg(e,t,n){e=Ft(e,255),t=Ft(t,255),n=Ft(n,255);var r=Math.max(e,t,n),i=Math.min(e,t,n),o,s,l=r,c=r-i;if(s=r===0?0:c/r,r==i)o=0;else{switch(r){case e:o=(t-n)/c+(t<n?6:0);break;case t:o=(n-e)/c+2;break;case n:o=(e-t)/c+4;break}o/=6}return{h:o,s,v:l}}function iw(e,t,n){e=Ft(e,360)*6,t=Ft(t,100),n=Ft(n,100);var r=Math.floor(e),i=e-r,o=n*(1-t),s=n*(1-i*t),l=n*(1-(1-i)*t),c=r%6,d=[n,s,o,o,l,n][c],p=[l,n,n,s,o,o][c],y=[o,o,l,n,n,s][c];return{r:d*255,g:p*255,b:y*255}}function Rg(e,t,n,r){var i=[_r(Math.round(e).toString(16)),_r(Math.round(t).toString(16)),_r(Math.round(n).toString(16))];return r&&i[0].charAt(0)==i[0].charAt(1)&&i[1].charAt(0)==i[1].charAt(1)&&i[2].charAt(0)==i[2].charAt(1)?i[0].charAt(0)+i[1].charAt(0)+i[2].charAt(0):i.join("")}function ow(e,t,n,r,i){var o=[_r(Math.round(e).toString(16)),_r(Math.round(t).toString(16)),_r(Math.round(n).toString(16)),_r(Bg(r))];return i&&o[0].charAt(0)==o[0].charAt(1)&&o[1].charAt(0)==o[1].charAt(1)&&o[2].charAt(0)==o[2].charAt(1)&&o[3].charAt(0)==o[3].charAt(1)?o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0)+o[3].charAt(0):o.join("")}function Ng(e,t,n,r){var i=[_r(Bg(r)),_r(Math.round(e).toString(16)),_r(Math.round(t).toString(16)),_r(Math.round(n).toString(16))];return i.join("")}Ie.equals=function(e,t){return!e||!t?!1:Ie(e).toRgbString()==Ie(t).toRgbString()},Ie.random=function(){return Ie.fromRatio({r:Math.random(),g:Math.random(),b:Math.random()})};function sw(e,t){t=t===0?0:t||10;var n=Ie(e).toHsl();return n.s-=t/100,n.s=Fl(n.s),Ie(n)}function aw(e,t){t=t===0?0:t||10;var n=Ie(e).toHsl();return n.s+=t/100,n.s=Fl(n.s),Ie(n)}function lw(e){return Ie(e).desaturate(100)}function uw(e,t){t=t===0?0:t||10;var n=Ie(e).toHsl();return n.l+=t/100,n.l=Fl(n.l),Ie(n)}function cw(e,t){t=t===0?0:t||10;var n=Ie(e).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)))),Ie(n)}function fw(e,t){t=t===0?0:t||10;var n=Ie(e).toHsl();return n.l-=t/100,n.l=Fl(n.l),Ie(n)}function dw(e,t){var n=Ie(e).toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,Ie(n)}function pw(e){var t=Ie(e).toHsl();return t.h=(t.h+180)%360,Ie(t)}function Mg(e,t){if(isNaN(t)||t<=0)throw new Error("Argument to polyad must be a positive number");for(var n=Ie(e).toHsl(),r=[Ie(e)],i=360/t,o=1;o<t;o++)r.push(Ie({h:(n.h+o*i)%360,s:n.s,l:n.l}));return r}function hw(e){var t=Ie(e).toHsl(),n=t.h;return[Ie(e),Ie({h:(n+72)%360,s:t.s,l:t.l}),Ie({h:(n+216)%360,s:t.s,l:t.l})]}function gw(e,t,n){t=t||6,n=n||30;var r=Ie(e).toHsl(),i=360/n,o=[Ie(e)];for(r.h=(r.h-(i*t>>1)+720)%360;--t;)r.h=(r.h+i)%360,o.push(Ie(r));return o}function mw(e,t){t=t||6;for(var n=Ie(e).toHsv(),r=n.h,i=n.s,o=n.v,s=[],l=1/t;t--;)s.push(Ie({h:r,s:i,v:o})),o=(o+l)%1;return s}Ie.mix=function(e,t,n){n=n===0?0:n||50;var r=Ie(e).toRgb(),i=Ie(t).toRgb(),o=n/100,s={r:(i.r-r.r)*o+r.r,g:(i.g-r.g)*o+r.g,b:(i.b-r.b)*o+r.b,a:(i.a-r.a)*o+r.a};return Ie(s)},Ie.readability=function(e,t){var n=Ie(e),r=Ie(t);return(Math.max(n.getLuminance(),r.getLuminance())+.05)/(Math.min(n.getLuminance(),r.getLuminance())+.05)},Ie.isReadable=function(e,t,n){var r=Ie.readability(e,t),i,o;switch(o=!1,i=ww(n),i.level+i.size){case"AAsmall":case"AAAlarge":o=r>=4.5;break;case"AAlarge":o=r>=3;break;case"AAAsmall":o=r>=7;break}return o},Ie.mostReadable=function(e,t,n){var r=null,i=0,o,s,l,c;n=n||{},s=n.includeFallbackColors,l=n.level,c=n.size;for(var d=0;d<t.length;d++)o=Ie.readability(e,t[d]),o>i&&(i=o,r=Ie(t[d]));return Ie.isReadable(e,r,{level:l,size:c})||!s?r:(n.includeFallbackColors=!1,Ie.mostReadable(e,["#fff","#000"],n))};var ef=Ie.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",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:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",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:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",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:"f00",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:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},vw=Ie.hexNames=yw(ef);function yw(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[e[n]]=n);return t}function Fg(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function Ft(e,t){bw(e)&&(e="100%");var n=Cw(e);return e=Math.min(t,Math.max(0,parseFloat(e))),n&&(e=parseInt(e*t,10)/100),Math.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function Fl(e){return Math.min(1,Math.max(0,e))}function Yn(e){return parseInt(e,16)}function bw(e){return typeof e=="string"&&e.indexOf(".")!=-1&&parseFloat(e)===1}function Cw(e){return typeof e=="string"&&e.indexOf("%")!=-1}function _r(e){return e.length==1?"0"+e:""+e}function Xs(e){return e<=1&&(e=e*100+"%"),e}function Bg(e){return Math.round(parseFloat(e)*255).toString(16)}function $g(e){return Yn(e)/255}var wr=function(){var e="[-\\+]?\\d+%?",t="[-\\+]?\\d*\\.\\d+%?",n="(?:"+t+")|(?:"+e+")",r="[\\s|\\(]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")\\s*\\)?",i="[\\s|\\(]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")\\s*\\)?";return{CSS_UNIT:new RegExp(n),rgb:new RegExp("rgb"+r),rgba:new RegExp("rgba"+i),hsl:new RegExp("hsl"+r),hsla:new RegExp("hsla"+i),hsv:new RegExp("hsv"+r),hsva:new RegExp("hsva"+i),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 Zr(e){return!!wr.CSS_UNIT.exec(e)}function _w(e){e=e.replace(Q1,"").replace(ew,"").toLowerCase();var t=!1;if(ef[e])e=ef[e],t=!0;else if(e=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var n;return(n=wr.rgb.exec(e))?{r:n[1],g:n[2],b:n[3]}:(n=wr.rgba.exec(e))?{r:n[1],g:n[2],b:n[3],a:n[4]}:(n=wr.hsl.exec(e))?{h:n[1],s:n[2],l:n[3]}:(n=wr.hsla.exec(e))?{h:n[1],s:n[2],l:n[3],a:n[4]}:(n=wr.hsv.exec(e))?{h:n[1],s:n[2],v:n[3]}:(n=wr.hsva.exec(e))?{h:n[1],s:n[2],v:n[3],a:n[4]}:(n=wr.hex8.exec(e))?{r:Yn(n[1]),g:Yn(n[2]),b:Yn(n[3]),a:$g(n[4]),format:t?"name":"hex8"}:(n=wr.hex6.exec(e))?{r:Yn(n[1]),g:Yn(n[2]),b:Yn(n[3]),format:t?"name":"hex"}:(n=wr.hex4.exec(e))?{r:Yn(n[1]+""+n[1]),g:Yn(n[2]+""+n[2]),b:Yn(n[3]+""+n[3]),a:$g(n[4]+""+n[4]),format:t?"name":"hex8"}:(n=wr.hex3.exec(e))?{r:Yn(n[1]+""+n[1]),g:Yn(n[2]+""+n[2]),b:Yn(n[3]+""+n[3]),format:t?"name":"hex"}:!1}function ww(e){var t,n;return e=e||{level:"AA",size:"small"},t=(e.level||"AA").toUpperCase(),n=(e.size||"small").toLowerCase(),t!=="AA"&&t!=="AAA"&&(t="AA"),n!=="small"&&n!=="large"&&(n="small"),{level:t,size:n}}const he={loraRegex:/^\<lora:\s*([^\:]+)\s*(:)?\s*(\-?[0-9\.]+)?\>$/,lycoRegex:/^\<lyco:\s*([^\:]+)\s*(:)?\s*(\-?[0-9\.]+)?\>$/,weightNumRegex:/(.*):(\-?[0-9\.]+)/,weightNumRegexEN:/(.*):\s*(\-?[0-9\.]+)/,weightNumRegexCN:/(.*):\s*(\-?[0-9\.]+)/,bracketsEN:[{"(":"(",")":")"},{"[":"[","]":"]"},{"{":"{","}":"}"},{"<":"<",">":">"}],bracketsCN:[{"(":"(",")":")"},{"【":"[","】":"]"},{"《":"<","》":">"},{"「":"{","」":"}"},{"『":"{","』":"}"},{"〈":"<","〉":">"},{"﹝":"(","﹞":")"},{"﹛":"{","﹜":"}"},{"﹙":"(","﹚":")"}],replaceTag(e){return typeof e!="string"||e===""||(e=this.replaceBrackets(e),this.weightNumRegexEN.test(e)&&(e=e.replace(this.weightNumRegexEN,"$1:$2")),this.weightNumRegexCN.test(e)&&(e=e.replace(this.weightNumRegexCN,"$1:$2"))),e},replaceBrackets(e){const t=e.length;if(t===0)return e;let n={};this.bracketsCN.forEach(o=>{for(const s in o)n[s]=o[s]});let r=e[0],i=e[t-1];return typeof n[r]<"u"&&(e=n[r]+e.substring(1)),typeof n[i]<"u"&&(e=e.substring(0,t-1)+n[i]),e},hasBrackets(e){const t=e.length;if(t===0)return!1;let n=[];this.bracketsEN.forEach(o=>{let s=[];for(const l in o)s.push(l);n.push(s)}),this.bracketsCN.forEach(o=>{let s=[];for(const l in o)s.push(l);n.push(s)});let r=e[0],i=e[t-1];for(const o of n)if(o[0]===r&&o[1]===i)return o;return!1},splitTag(e){let t={left:"",value:"",right:""},n=e.match(/^([\(\<\{\[]+)(.*)$/);return!n||(t.left=n[1],e=n[2],n=e.match(/((\:[0-9\.]+)?[\)\>\}\]]+)$/),!n)?(t.value=e,t):(t.right=n[1],e=e.substring(0,e.length-t.right.length),t.value=e,t)},splitTags(e,t=!1,n=!1){return Z1(e,t,n)},canTranslate(e){return!(e.trim()===""||e[0]==="<"&&e[e.length-1]===">"||/^[0-9`~!@#$%^&*()_+\-=\[\]{}\\|;:'",.\/<>?]+$/.test(e)||/^[a-zA-Z]$/.test(e))},isEnglish(e){const t=e.length;if(e[0]==="<"&&e[t-1]===">")return!0;for(let n=0;n<t;n++)if(e.charCodeAt(n)>127)return!1;return!0},canOneTranslate(e){const t=["zh_CN","zh_HK","zh_TW","ar_SA","ja_JP","ko_KR","ru_RU"];return t.push("am_ET","hy_AM","as_IN","bn_BD","ba_RU","bg_BG","prs_AF","dv_MV","el_GR","gu_IN","he_IL","hi_IN","iu_CA","kn_IN","kk_KZ","km_KH","ku_Arab_IQ","ky_KG","lo_LA","mk_MK","ml_IN","mr_IN","mn_Cyrl_MN","mn_Mong_CN","my_MM","ne_NP","or_IN","ps_AF","fa_IR","pa_Guru_IN","sr_Cyrl_RS","ta_IN","tt_Latn_RU","te_IN","th_TH","bo_CN","ti_ET","uk_UA","ur_PK","ug_Arab_CN","vi_VN"),!!t.includes(e)},isEnglishByLangCode(e,t){if(!this.canOneTranslate(t))return-1;const n=e.length;for(let r=0;r<n;r++)if(e.charCodeAt(r)>127)return 0;return 1},isSameLang(e,t){if(e===t)return!0;let n=e.toLowerCase(),r=t.toLowerCase();return n===r||(e=e.replace("-","_"),t=t.replace("-","_"),e===t)||(e=e.split("_")[0],t=t.split("_")[0],e===t)},getLang(e,t,n){return n[t]&&n[t].lang&&n[t].lang[e]?this.replaceGlobals(n[t].lang[e],t):n.en_US&&n.en_US.lang&&n.en_US.lang[e]?this.replaceGlobals(n.en_US.lang[e],"en_US"):this.replaceGlobals(e,t)},replaceGlobals(e,t){for(let n in Ys){let r=Ys[n];if(n==="docs")switch(t){case"zh_CN":r+="/zh-CN";break;case"zh_HK":case"zh_TW":r+="/zh-TW";break;case"ru_RU":r+="/ru";break}e=e.replace(new RegExp(`{{${n}}}`,"g"),r)}return e},escapeHtml(e){return e.replace(/[&<>'"]/g,t=>({"&":"&","<":"<",">":">","'":"'",'"':"""})[t]||t)},unescapeHtml(e){return e.replace(/&|<|>|'|"/g,t=>({"&":"&","<":"<",">":">","'":"'",""":'"'})[t]||t)},getTagWeightNum(e){const t=e.match(this.weightNumRegex);return t?parseFloat(t[2]):1},getTagIncWeight(e){return this.countLayers(e,"(",")")},getTagDecWeight(e){return this.countLayers(e,"[","]")},countLayers(e,t="(",n=")"){let r=0;if(e.length<2)return r;for(;;){let i=e[0],o=e[e.length-1];if(i===t&&o===n)r++,e=e.slice(1,e.length-1);else break}return r},setLayers(e,t=0,n="(",r=")",i=""){for(;;){let o=e[0],s=e[e.length-1];if(o===n&&s===r)e=e.slice(1,e.length-1);else break}return t===0?e:n.repeat(t)+e+i+r.repeat(t)},getTranslateApiInfo(e,t){let n=!1;for(const r in t)for(const i in r.children)if(i.key===e){n=i;break}return n},isEqualTags(e,t,n=[]){if(t.length!==e.length)return!1;for(let r=0;r<e.length;r++){for(let i in e[r])if(!n.includes(i)&&t[r][i]!==e[r][i])return!1;for(let i in t[r])if(!n.includes(i)&&t[r][i]!==e[r][i])return!1}return!0},getTranslateApiItem(e,t){if(!e||e.length<=0)return{};for(let n of e)for(let r of n.children)if(r.key===t)return r;return e[0].children[0]},hideCompleteResults(e){typeof hideResults=="function"&&[100,200,300,500,1e3].forEach(n=>{setTimeout(()=>{hideResults(e)},n)})},formatTime(e,t=!0){let n=new Date(e),r=n.getFullYear(),i=n.getMonth()+1;i<10&&(i="0"+i);let o=n.getDate();o<10&&(o="0"+o);let s=n.getHours();s<10&&(s="0"+s);let l=n.getMinutes();l<10&&(l="0"+l);let c=n.getSeconds();return c<10&&(c="0"+c),t?`${r}/${i}/${o} ${s}:${l}:${c}`:`${i}/${o} ${s}:${l}:${c}`},apiUrl(){let e;return e=window.location.origin+window.location.pathname,e+=e.endsWith("/")?"":"/",e+="physton_prompt/",e},removeCSS(e,t=!0){if(!e)return;let n=null;t?n=this.gradioApp().querySelector("#"+e):n=document.querySelector("#"+e),n&&n.remove()},loadCSS(e,t="",n=!0,r=!1,i=!0){n&&this.removeCSS(t,i);let o=this.apiUrl()+"styles?file="+encodeURIComponent(e);r||(o+="&t="+new Date().getTime());let s=document.createElement("link");s.id=t,s.rel="stylesheet",s.href=o,i?this.gradioApp().appendChild(s):document.body.appendChild(s)},swapElement(e,t){let n=e.parentNode,r=t.parentNode,i=e.nextSibling,o=t.nextSibling;n.insertBefore(t,i),r.insertBefore(e,o)},insertBefore(e,t){t.parentNode.insertBefore(e,t)},insertAfter(e,t){t.nextSibling?t.parentNode.insertBefore(e,t.nextSibling):t.parentNode.appendChild(e)},gradioContainer:null,gradioApp(){if(this.gradioContainer)return this.gradioContainer;const e=document.getElementsByTagName("gradio-app"),t=e.length==0?null:e[0].shadowRoot;if(t){const n=t.querySelectorAll(".gradio-container");for(let r=0;r<n.length;r++){const i=n[r];if(i.querySelectorAll("#tabs").length)return i.classList.add("physton-gradio-container"),this.gradioContainer=i,i}}else return document.body.classList.add("physton-gradio-container"),this.gradioContainer=document.body,document.body},fitterInputColor(e,t="rgba(0,0,0,0)"){let n="fitterInputColor:"+e+":"+t;return localStorage[n]?localStorage[n]:!e||e===""||e==="default"||e==="none"||e==="null"||e==="undefined"||e==="false"||e==="true"||!Ie(e).isValid()?(localStorage[n]=t,t):(localStorage[n]=e,e)},isColorTransparent(e){let t="isColorTransparent:"+e;if(localStorage[t])return localStorage[t]==="true";let n=Ie(e).getAlpha()===0;return localStorage[t]=n,n},getTagsColorKey(e,t){return e+"||"+t}};var tf=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Bl(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Hg={exports:{}};/* @license
|
||
Papa Parse
|
||
v5.4.1
|
||
https://github.com/mholt/PapaParse
|
||
License: MIT
|
||
*/(function(e,t){(function(n,r){e.exports=r()})(tf,function n(){var r=typeof self<"u"?self:typeof window<"u"?window:r!==void 0?r:{},i=!r.document&&!!r.postMessage,o=r.IS_PAPA_WORKER||!1,s={},l=0,c={parse:function(I,A){var D=(A=A||{}).dynamicTyping||!1;if(g(D)&&(A.dynamicTypingFunction=D,D={}),A.dynamicTyping=D,A.transform=!!g(A.transform)&&A.transform,A.worker&&c.WORKERS_SUPPORTED){var H=function(){if(!c.WORKERS_SUPPORTED)return!1;var U=(je=r.URL||r.webkitURL||null,Pe=n.toString(),c.BLOB_URL||(c.BLOB_URL=je.createObjectURL(new Blob(["var global = (function() { if (typeof self !== 'undefined') { return self; } if (typeof window !== 'undefined') { return window; } if (typeof global !== 'undefined') { return global; } return {}; })(); global.IS_PAPA_WORKER=true; ","(",Pe,")();"],{type:"text/javascript"})))),de=new r.Worker(U),je,Pe;return de.onmessage=$,de.id=l++,s[de.id]=de}();return H.userStep=A.step,H.userChunk=A.chunk,H.userComplete=A.complete,H.userError=A.error,A.step=g(A.step),A.chunk=g(A.chunk),A.complete=g(A.complete),A.error=g(A.error),delete A.worker,void H.postMessage({input:I,config:A,workerId:H.id})}var K=null;return c.NODE_STREAM_INPUT,typeof I=="string"?(I=function(U){return U.charCodeAt(0)===65279?U.slice(1):U}(I),K=A.download?new y(A):new C(A)):I.readable===!0&&g(I.read)&&g(I.on)?K=new b(A):(r.File&&I instanceof File||I instanceof Object)&&(K=new m(A)),K.stream(I)},unparse:function(I,A){var D=!1,H=!0,K=",",U=`\r
|
||
`,de='"',je=de+de,Pe=!1,V=null,ae=!1;(function(){if(typeof A=="object"){if(typeof A.delimiter!="string"||c.BAD_DELIMITERS.filter(function(se){return A.delimiter.indexOf(se)!==-1}).length||(K=A.delimiter),(typeof A.quotes=="boolean"||typeof A.quotes=="function"||Array.isArray(A.quotes))&&(D=A.quotes),typeof A.skipEmptyLines!="boolean"&&typeof A.skipEmptyLines!="string"||(Pe=A.skipEmptyLines),typeof A.newline=="string"&&(U=A.newline),typeof A.quoteChar=="string"&&(de=A.quoteChar),typeof A.header=="boolean"&&(H=A.header),Array.isArray(A.columns)){if(A.columns.length===0)throw new Error("Option columns is empty");V=A.columns}A.escapeChar!==void 0&&(je=A.escapeChar+de),(typeof A.escapeFormulae=="boolean"||A.escapeFormulae instanceof RegExp)&&(ae=A.escapeFormulae instanceof RegExp?A.escapeFormulae:/^[=+\-@\t\r].*$/)}})();var pe=new RegExp(L(de),"g");if(typeof I=="string"&&(I=JSON.parse(I)),Array.isArray(I)){if(!I.length||Array.isArray(I[0]))return Qe(null,I,Pe);if(typeof I[0]=="object")return Qe(V||Object.keys(I[0]),I,Pe)}else if(typeof I=="object")return typeof I.data=="string"&&(I.data=JSON.parse(I.data)),Array.isArray(I.data)&&(I.fields||(I.fields=I.meta&&I.meta.fields||V),I.fields||(I.fields=Array.isArray(I.data[0])?I.fields:typeof I.data[0]=="object"?Object.keys(I.data[0]):[]),Array.isArray(I.data[0])||typeof I.data[0]=="object"||(I.data=[I.data])),Qe(I.fields||[],I.data||[],Pe);throw new Error("Unable to serialize unrecognized input");function Qe(se,Ce,xe){var Ae="";typeof se=="string"&&(se=JSON.parse(se)),typeof Ce=="string"&&(Ce=JSON.parse(Ce));var Oe=Array.isArray(se)&&0<se.length,Be=!Array.isArray(Ce[0]);if(Oe&&H){for(var tt=0;tt<se.length;tt++)0<tt&&(Ae+=K),Ae+=et(se[tt],tt);0<Ce.length&&(Ae+=U)}for(var Re=0;Re<Ce.length;Re++){var Ve=Oe?se.length:Ce[Re].length,dt=!1,R=Oe?Object.keys(Ce[Re]).length===0:Ce[Re].length===0;if(xe&&!Oe&&(dt=xe==="greedy"?Ce[Re].join("").trim()==="":Ce[Re].length===1&&Ce[Re][0].length===0),xe==="greedy"&&Oe){for(var B=[],Y=0;Y<Ve;Y++){var oe=Be?se[Y]:Y;B.push(Ce[Re][oe])}dt=B.join("").trim()===""}if(!dt){for(var ee=0;ee<Ve;ee++){0<ee&&!R&&(Ae+=K);var te=Oe&&Be?se[ee]:ee;Ae+=et(Ce[Re][te],ee)}Re<Ce.length-1&&(!xe||0<Ve&&!R)&&(Ae+=U)}}return Ae}function et(se,Ce){if(se==null)return"";if(se.constructor===Date)return JSON.stringify(se).slice(1,25);var xe=!1;ae&&typeof se=="string"&&ae.test(se)&&(se="'"+se,xe=!0);var Ae=se.toString().replace(pe,je);return(xe=xe||D===!0||typeof D=="function"&&D(se,Ce)||Array.isArray(D)&&D[Ce]||function(Oe,Be){for(var tt=0;tt<Be.length;tt++)if(-1<Oe.indexOf(Be[tt]))return!0;return!1}(Ae,c.BAD_DELIMITERS)||-1<Ae.indexOf(K)||Ae.charAt(0)===" "||Ae.charAt(Ae.length-1)===" ")?de+Ae+de:Ae}}};if(c.RECORD_SEP=String.fromCharCode(30),c.UNIT_SEP=String.fromCharCode(31),c.BYTE_ORDER_MARK="\uFEFF",c.BAD_DELIMITERS=["\r",`
|
||
`,'"',c.BYTE_ORDER_MARK],c.WORKERS_SUPPORTED=!i&&!!r.Worker,c.NODE_STREAM_INPUT=1,c.LocalChunkSize=10485760,c.RemoteChunkSize=5242880,c.DefaultDelimiter=",",c.Parser=O,c.ParserHandle=k,c.NetworkStreamer=y,c.FileStreamer=m,c.StringStreamer=C,c.ReadableStreamStreamer=b,r.jQuery){var d=r.jQuery;d.fn.parse=function(I){var A=I.config||{},D=[];return this.each(function(U){if(!(d(this).prop("tagName").toUpperCase()==="INPUT"&&d(this).attr("type").toLowerCase()==="file"&&r.FileReader)||!this.files||this.files.length===0)return!0;for(var de=0;de<this.files.length;de++)D.push({file:this.files[de],inputElem:this,instanceConfig:d.extend({},A)})}),H(),this;function H(){if(D.length!==0){var U,de,je,Pe,V=D[0];if(g(I.before)){var ae=I.before(V.file,V.inputElem);if(typeof ae=="object"){if(ae.action==="abort")return U="AbortError",de=V.file,je=V.inputElem,Pe=ae.reason,void(g(I.error)&&I.error({name:U},de,je,Pe));if(ae.action==="skip")return void K();typeof ae.config=="object"&&(V.instanceConfig=d.extend(V.instanceConfig,ae.config))}else if(ae==="skip")return void K()}var pe=V.instanceConfig.complete;V.instanceConfig.complete=function(Qe){g(pe)&&pe(Qe,V.file,V.inputElem),K()},c.parse(V.file,V.instanceConfig)}else g(I.complete)&&I.complete()}function K(){D.splice(0,1),H()}}}function p(I){this._handle=null,this._finished=!1,this._completed=!1,this._halted=!1,this._input=null,this._baseIndex=0,this._partialLine="",this._rowCount=0,this._start=0,this._nextChunk=null,this.isFirstChunk=!0,this._completeResults={data:[],errors:[],meta:{}},(function(A){var D=z(A);D.chunkSize=parseInt(D.chunkSize),A.step||A.chunk||(D.chunkSize=null),this._handle=new k(D),(this._handle.streamer=this)._config=D}).call(this,I),this.parseChunk=function(A,D){if(this.isFirstChunk&&g(this._config.beforeFirstChunk)){var H=this._config.beforeFirstChunk(A);H!==void 0&&(A=H)}this.isFirstChunk=!1,this._halted=!1;var K=this._partialLine+A;this._partialLine="";var U=this._handle.parse(K,this._baseIndex,!this._finished);if(!this._handle.paused()&&!this._handle.aborted()){var de=U.meta.cursor;this._finished||(this._partialLine=K.substring(de-this._baseIndex),this._baseIndex=de),U&&U.data&&(this._rowCount+=U.data.length);var je=this._finished||this._config.preview&&this._rowCount>=this._config.preview;if(o)r.postMessage({results:U,workerId:c.WORKER_ID,finished:je});else if(g(this._config.chunk)&&!D){if(this._config.chunk(U,this._handle),this._handle.paused()||this._handle.aborted())return void(this._halted=!0);U=void 0,this._completeResults=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(U.data),this._completeResults.errors=this._completeResults.errors.concat(U.errors),this._completeResults.meta=U.meta),this._completed||!je||!g(this._config.complete)||U&&U.meta.aborted||(this._config.complete(this._completeResults,this._input),this._completed=!0),je||U&&U.meta.paused||this._nextChunk(),U}this._halted=!0},this._sendError=function(A){g(this._config.error)?this._config.error(A):o&&this._config.error&&r.postMessage({workerId:c.WORKER_ID,error:A,finished:!1})}}function y(I){var A;(I=I||{}).chunkSize||(I.chunkSize=c.RemoteChunkSize),p.call(this,I),this._nextChunk=i?function(){this._readChunk(),this._chunkLoaded()}:function(){this._readChunk()},this.stream=function(D){this._input=D,this._nextChunk()},this._readChunk=function(){if(this._finished)this._chunkLoaded();else{if(A=new XMLHttpRequest,this._config.withCredentials&&(A.withCredentials=this._config.withCredentials),i||(A.onload=Q(this._chunkLoaded,this),A.onerror=Q(this._chunkError,this)),A.open(this._config.downloadRequestBody?"POST":"GET",this._input,!i),this._config.downloadRequestHeaders){var D=this._config.downloadRequestHeaders;for(var H in D)A.setRequestHeader(H,D[H])}if(this._config.chunkSize){var K=this._start+this._config.chunkSize-1;A.setRequestHeader("Range","bytes="+this._start+"-"+K)}try{A.send(this._config.downloadRequestBody)}catch(U){this._chunkError(U.message)}i&&A.status===0&&this._chunkError()}},this._chunkLoaded=function(){A.readyState===4&&(A.status<200||400<=A.status?this._chunkError():(this._start+=this._config.chunkSize?this._config.chunkSize:A.responseText.length,this._finished=!this._config.chunkSize||this._start>=function(D){var H=D.getResponseHeader("Content-Range");return H===null?-1:parseInt(H.substring(H.lastIndexOf("/")+1))}(A),this.parseChunk(A.responseText)))},this._chunkError=function(D){var H=A.statusText||D;this._sendError(new Error(H))}}function m(I){var A,D;(I=I||{}).chunkSize||(I.chunkSize=c.LocalChunkSize),p.call(this,I);var H=typeof FileReader<"u";this.stream=function(K){this._input=K,D=K.slice||K.webkitSlice||K.mozSlice,H?((A=new FileReader).onload=Q(this._chunkLoaded,this),A.onerror=Q(this._chunkError,this)):A=new FileReaderSync,this._nextChunk()},this._nextChunk=function(){this._finished||this._config.preview&&!(this._rowCount<this._config.preview)||this._readChunk()},this._readChunk=function(){var K=this._input;if(this._config.chunkSize){var U=Math.min(this._start+this._config.chunkSize,this._input.size);K=D.call(K,this._start,U)}var de=A.readAsText(K,this._config.encoding);H||this._chunkLoaded({target:{result:de}})},this._chunkLoaded=function(K){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(K.target.result)},this._chunkError=function(){this._sendError(A.error)}}function C(I){var A;p.call(this,I=I||{}),this.stream=function(D){return A=D,this._nextChunk()},this._nextChunk=function(){if(!this._finished){var D,H=this._config.chunkSize;return H?(D=A.substring(0,H),A=A.substring(H)):(D=A,A=""),this._finished=!A,this.parseChunk(D)}}}function b(I){p.call(this,I=I||{});var A=[],D=!0,H=!1;this.pause=function(){p.prototype.pause.apply(this,arguments),this._input.pause()},this.resume=function(){p.prototype.resume.apply(this,arguments),this._input.resume()},this.stream=function(K){this._input=K,this._input.on("data",this._streamData),this._input.on("end",this._streamEnd),this._input.on("error",this._streamError)},this._checkIsFinished=function(){H&&A.length===1&&(this._finished=!0)},this._nextChunk=function(){this._checkIsFinished(),A.length?this.parseChunk(A.shift()):D=!0},this._streamData=Q(function(K){try{A.push(typeof K=="string"?K:K.toString(this._config.encoding)),D&&(D=!1,this._checkIsFinished(),this.parseChunk(A.shift()))}catch(U){this._streamError(U)}},this),this._streamError=Q(function(K){this._streamCleanUp(),this._sendError(K)},this),this._streamEnd=Q(function(){this._streamCleanUp(),H=!0,this._streamData("")},this),this._streamCleanUp=Q(function(){this._input.removeListener("data",this._streamData),this._input.removeListener("end",this._streamEnd),this._input.removeListener("error",this._streamError)},this)}function k(I){var A,D,H,K=Math.pow(2,53),U=-K,de=/^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/,je=/^((\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z)))$/,Pe=this,V=0,ae=0,pe=!1,Qe=!1,et=[],se={data:[],errors:[],meta:{}};if(g(I.step)){var Ce=I.step;I.step=function(Re){if(se=Re,Oe())Ae();else{if(Ae(),se.data.length===0)return;V+=Re.data.length,I.preview&&V>I.preview?D.abort():(se.data=se.data[0],Ce(se,Pe))}}}function xe(Re){return I.skipEmptyLines==="greedy"?Re.join("").trim()==="":Re.length===1&&Re[0].length===0}function Ae(){return se&&H&&(tt("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+c.DefaultDelimiter+"'"),H=!1),I.skipEmptyLines&&(se.data=se.data.filter(function(Re){return!xe(Re)})),Oe()&&function(){if(!se)return;function Re(dt,R){g(I.transformHeader)&&(dt=I.transformHeader(dt,R)),et.push(dt)}if(Array.isArray(se.data[0])){for(var Ve=0;Oe()&&Ve<se.data.length;Ve++)se.data[Ve].forEach(Re);se.data.splice(0,1)}else se.data.forEach(Re)}(),function(){if(!se||!I.header&&!I.dynamicTyping&&!I.transform)return se;function Re(dt,R){var B,Y=I.header?{}:[];for(B=0;B<dt.length;B++){var oe=B,ee=dt[B];I.header&&(oe=B>=et.length?"__parsed_extra":et[B]),I.transform&&(ee=I.transform(ee,oe)),ee=Be(oe,ee),oe==="__parsed_extra"?(Y[oe]=Y[oe]||[],Y[oe].push(ee)):Y[oe]=ee}return I.header&&(B>et.length?tt("FieldMismatch","TooManyFields","Too many fields: expected "+et.length+" fields but parsed "+B,ae+R):B<et.length&&tt("FieldMismatch","TooFewFields","Too few fields: expected "+et.length+" fields but parsed "+B,ae+R)),Y}var Ve=1;return!se.data.length||Array.isArray(se.data[0])?(se.data=se.data.map(Re),Ve=se.data.length):se.data=Re(se.data,0),I.header&&se.meta&&(se.meta.fields=et),ae+=Ve,se}()}function Oe(){return I.header&&et.length===0}function Be(Re,Ve){return dt=Re,I.dynamicTypingFunction&&I.dynamicTyping[dt]===void 0&&(I.dynamicTyping[dt]=I.dynamicTypingFunction(dt)),(I.dynamicTyping[dt]||I.dynamicTyping)===!0?Ve==="true"||Ve==="TRUE"||Ve!=="false"&&Ve!=="FALSE"&&(function(R){if(de.test(R)){var B=parseFloat(R);if(U<B&&B<K)return!0}return!1}(Ve)?parseFloat(Ve):je.test(Ve)?new Date(Ve):Ve===""?null:Ve):Ve;var dt}function tt(Re,Ve,dt,R){var B={type:Re,code:Ve,message:dt};R!==void 0&&(B.row=R),se.errors.push(B)}this.parse=function(Re,Ve,dt){var R=I.quoteChar||'"';if(I.newline||(I.newline=function(oe,ee){oe=oe.substring(0,1048576);var te=new RegExp(L(ee)+"([^]*?)"+L(ee),"gm"),ve=(oe=oe.replace(te,"")).split("\r"),me=oe.split(`
|
||
`),be=1<me.length&&me[0].length<ve[0].length;if(ve.length===1||be)return`
|
||
`;for(var ce=0,Te=0;Te<ve.length;Te++)ve[Te][0]===`
|
||
`&&ce++;return ce>=ve.length/2?`\r
|
||
`:"\r"}(Re,R)),H=!1,I.delimiter)g(I.delimiter)&&(I.delimiter=I.delimiter(Re),se.meta.delimiter=I.delimiter);else{var B=function(oe,ee,te,ve,me){var be,ce,Te,_e;me=me||[","," ","|",";",c.RECORD_SEP,c.UNIT_SEP];for(var Ne=0;Ne<me.length;Ne++){var ne=me[Ne],$e=0,at=0,lt=0;Te=void 0;for(var Tt=new O({comments:ve,delimiter:ne,newline:ee,preview:10}).parse(oe),Nt=0;Nt<Tt.data.length;Nt++)if(te&&xe(Tt.data[Nt]))lt++;else{var en=Tt.data[Nt].length;at+=en,Te!==void 0?0<en&&($e+=Math.abs(en-Te),Te=en):Te=en}0<Tt.data.length&&(at/=Tt.data.length-lt),(ce===void 0||$e<=ce)&&(_e===void 0||_e<at)&&1.99<at&&(ce=$e,be=ne,_e=at)}return{successful:!!(I.delimiter=be),bestDelimiter:be}}(Re,I.newline,I.skipEmptyLines,I.comments,I.delimitersToGuess);B.successful?I.delimiter=B.bestDelimiter:(H=!0,I.delimiter=c.DefaultDelimiter),se.meta.delimiter=I.delimiter}var Y=z(I);return I.preview&&I.header&&Y.preview++,A=Re,D=new O(Y),se=D.parse(A,Ve,dt),Ae(),pe?{meta:{paused:!0}}:se||{meta:{paused:!1}}},this.paused=function(){return pe},this.pause=function(){pe=!0,D.abort(),A=g(I.chunk)?"":A.substring(D.getCharIndex())},this.resume=function(){Pe.streamer._halted?(pe=!1,Pe.streamer.parseChunk(A,!0)):setTimeout(Pe.resume,3)},this.aborted=function(){return Qe},this.abort=function(){Qe=!0,D.abort(),se.meta.aborted=!0,g(I.complete)&&I.complete(se),A=""}}function L(I){return I.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function O(I){var A,D=(I=I||{}).delimiter,H=I.newline,K=I.comments,U=I.step,de=I.preview,je=I.fastMode,Pe=A=I.quoteChar===void 0||I.quoteChar===null?'"':I.quoteChar;if(I.escapeChar!==void 0&&(Pe=I.escapeChar),(typeof D!="string"||-1<c.BAD_DELIMITERS.indexOf(D))&&(D=","),K===D)throw new Error("Comment character same as delimiter");K===!0?K="#":(typeof K!="string"||-1<c.BAD_DELIMITERS.indexOf(K))&&(K=!1),H!==`
|
||
`&&H!=="\r"&&H!==`\r
|
||
`&&(H=`
|
||
`);var V=0,ae=!1;this.parse=function(pe,Qe,et){if(typeof pe!="string")throw new Error("Input must be a string");var se=pe.length,Ce=D.length,xe=H.length,Ae=K.length,Oe=g(U),Be=[],tt=[],Re=[],Ve=V=0;if(!pe)return $t();if(I.header&&!Qe){var dt=pe.split(H)[0].split(D),R=[],B={},Y=!1;for(var oe in dt){var ee=dt[oe];g(I.transformHeader)&&(ee=I.transformHeader(ee,oe));var te=ee,ve=B[ee]||0;for(0<ve&&(Y=!0,te=ee+"_"+ve),B[ee]=ve+1;R.includes(te);)te=te+"_"+ve;R.push(te)}if(Y){var me=pe.split(H);me[0]=R.join(D),pe=me.join(H)}}if(je||je!==!1&&pe.indexOf(A)===-1){for(var be=pe.split(H),ce=0;ce<be.length;ce++){if(Re=be[ce],V+=Re.length,ce!==be.length-1)V+=H.length;else if(et)return $t();if(!K||Re.substring(0,Ae)!==K){if(Oe){if(Be=[],lt(Re.split(D)),Vt(),ae)return $t()}else lt(Re.split(D));if(de&&de<=ce)return Be=Be.slice(0,de),$t(!0)}}return $t()}for(var Te=pe.indexOf(D,V),_e=pe.indexOf(H,V),Ne=new RegExp(L(Pe)+L(A),"g"),ne=pe.indexOf(A,V);;)if(pe[V]!==A)if(K&&Re.length===0&&pe.substring(V,V+Ae)===K){if(_e===-1)return $t();V=_e+xe,_e=pe.indexOf(H,V),Te=pe.indexOf(D,V)}else if(Te!==-1&&(Te<_e||_e===-1))Re.push(pe.substring(V,Te)),V=Te+Ce,Te=pe.indexOf(D,V);else{if(_e===-1)break;if(Re.push(pe.substring(V,_e)),en(_e+xe),Oe&&(Vt(),ae))return $t();if(de&&Be.length>=de)return $t(!0)}else for(ne=V,V++;;){if((ne=pe.indexOf(A,ne+1))===-1)return et||tt.push({type:"Quotes",code:"MissingQuotes",message:"Quoted field unterminated",row:Be.length,index:V}),Nt();if(ne===se-1)return Nt(pe.substring(V,ne).replace(Ne,A));if(A!==Pe||pe[ne+1]!==Pe){if(A===Pe||ne===0||pe[ne-1]!==Pe){Te!==-1&&Te<ne+1&&(Te=pe.indexOf(D,ne+1)),_e!==-1&&_e<ne+1&&(_e=pe.indexOf(H,ne+1));var $e=Tt(_e===-1?Te:Math.min(Te,_e));if(pe.substr(ne+1+$e,Ce)===D){Re.push(pe.substring(V,ne).replace(Ne,A)),pe[V=ne+1+$e+Ce]!==A&&(ne=pe.indexOf(A,V)),Te=pe.indexOf(D,V),_e=pe.indexOf(H,V);break}var at=Tt(_e);if(pe.substring(ne+1+at,ne+1+at+xe)===H){if(Re.push(pe.substring(V,ne).replace(Ne,A)),en(ne+1+at+xe),Te=pe.indexOf(D,V),ne=pe.indexOf(A,V),Oe&&(Vt(),ae))return $t();if(de&&Be.length>=de)return $t(!0);break}tt.push({type:"Quotes",code:"InvalidQuotes",message:"Trailing quote on quoted field is malformed",row:Be.length,index:V}),ne++}}else ne++}return Nt();function lt(J){Be.push(J),Ve=V}function Tt(J){var Se=0;if(J!==-1){var He=pe.substring(ne+1,J);He&&He.trim()===""&&(Se=He.length)}return Se}function Nt(J){return et||(J===void 0&&(J=pe.substring(V)),Re.push(J),V=se,lt(Re),Oe&&Vt()),$t()}function en(J){V=J,lt(Re),Re=[],_e=pe.indexOf(H,V)}function $t(J){return{data:Be,errors:tt,meta:{delimiter:D,linebreak:H,aborted:ae,truncated:!!J,cursor:Ve+(Qe||0)}}}function Vt(){U($t()),Be=[],tt=[]}},this.abort=function(){ae=!0},this.getCharIndex=function(){return V}}function $(I){var A=I.data,D=s[A.workerId],H=!1;if(A.error)D.userError(A.error,A.file);else if(A.results&&A.results.data){var K={abort:function(){H=!0,X(A.workerId,{data:[],errors:[],meta:{aborted:!0}})},pause:x,resume:x};if(g(D.userStep)){for(var U=0;U<A.results.data.length&&(D.userStep({data:A.results.data[U],errors:A.results.errors,meta:A.results.meta},K),!H);U++);delete A.results}else g(D.userChunk)&&(D.userChunk(A.results,K,A.file),delete A.results)}A.finished&&!H&&X(A.workerId,A.results)}function X(I,A){var D=s[I];g(D.userComplete)&&D.userComplete(A),D.terminate(),delete s[I]}function x(){throw new Error("Not implemented.")}function z(I){if(typeof I!="object"||I===null)return I;var A=Array.isArray(I)?[]:{};for(var D in I)A[D]=z(I[D]);return A}function Q(I,A){return function(){I.apply(A,arguments)}}function g(I){return typeof I=="function"}return o&&(r.onmessage=function(I){var A=I.data;if(c.WORKER_ID===void 0&&A&&(c.WORKER_ID=A.workerId),typeof A.input=="string")r.postMessage({workerId:c.WORKER_ID,results:c.parse(A.input,A.config),finished:!0});else if(r.File&&A.input instanceof File||A.input instanceof Object){var D=c.parse(A.input,A.config);D&&r.postMessage({workerId:c.WORKER_ID,results:D,finished:!0})}}),(y.prototype=Object.create(p.prototype)).constructor=y,(m.prototype=Object.create(p.prototype)).constructor=m,(C.prototype=Object.create(C.prototype)).constructor=C,(b.prototype=Object.create(p.prototype)).constructor=b,c})})(Hg);var Tw=Hg.exports;const kw=Bl(Tw),Xn={props:{languageCode:{type:String,default:"en_US"},languages:{type:Object,default:()=>{}},translateApis:{type:Array,default:()=>[]},translateApi:{type:String,default:""},translateApiConfig:{type:Object},tagCompleteFile:{type:String,default:""},onlyCsvOnAuto:{type:Boolean,default:!1},groupTagsTranslate:{type:Boolean,default:!0},groupTagsTranslateCache:{type:Object,default:()=>({toEn:new Map,toLocal:new Map})}},data(){return{cancelMultiTranslate:!1,globals:Ys}},computed:{langName(){for(const e in this.languages){const t=this.languages[e];if(t.code===this.languageCode)return t.name}return item.name}},methods:{getLang(e){return he.getLang(e,this.languageCode,this.languages)},replaceGlobals(e){return he.replaceGlobals(e,this.languageCode)},getCSV(e=null,t=!1){return window.tagCompleteFileCache=window.tagCompleteFileCache||{},window.tagCompleteFileLoading=window.tagCompleteFileLoading||{},new Promise((n,r)=>{if(e=e||this.tagCompleteFile,!t&&window.tagCompleteFileCache[e]){n(window.tagCompleteFileCache[e]);return}if(window.tagCompleteFileLoading[e]){const s=setInterval(()=>{window.tagCompleteFileLoading[e]||(clearInterval(s),n(window.tagCompleteFileCache[e]))},100);return}window.tagCompleteFileLoading[e]=!0;let i={toEn:new Map,toLocal:new Map},o=(s,l)=>{[s,s.replace(/\_/g," "),s.replace(/\-/g," ")].forEach(d=>i.toLocal.set(d,l)),i.toEn.set(l,s)};if(!e&&typeof translations=="object"&&translations instanceof Map){translations.forEach((s,l)=>{o(l,s)}),window.tagCompleteFileLoading[e]=!1,window.tagCompleteFileCache[e]=i,n(i);return}if(!e){window.tagCompleteFileLoading[e]=!1,window.tagCompleteFileCache[e]=i,r(this.getLang("not_found_csv_file"));return}this.gradioAPI.getCSV(e).then(s=>{s=kw.parse(s,{header:!1,skipEmptyLines:!0}),s.data.forEach(l=>{if(l.length<2)return;let c=l[0].trim(),d=l[1].trim();c===""||d===""||o(c,d)}),window.tagCompleteFileLoading[e]=!1,window.tagCompleteFileCache[e]=i,n(i)}).catch(s=>{window.tagCompleteFileLoading[e]=!1,window.tagCompleteFileCache[e]=i,s.response&&s.response.status===404?r(this.getLang("not_found_csv_file")):r(s.message)})})},_translateToLocalBy(e,t,n=!1){e=e.trim().toLowerCase();let r=i=>{var o;return((o=i.join)==null?void 0:o.call(i," / "))??i};if(t.has(e))return r(t.get(e));{const i=e.split(",").map(l=>l.trim());let o=[],s=[];if(i.forEach(l=>{t.has(l)?o.push(r(t.get(l))):n&&l.length&&s.push(l)}),o.length>0&&!s.length)return o.join(", ")}return""},async translateToLocalByCSV(e,t=null,n=!1,r=!1){let i=await this.getCSV(t,n);return this._translateToLocalBy(e,i.toLocal,r)},async translateToEnByCSV(e,t=null,n=!1){let r=await this.getCSV(t,n);return this._toEn(e,r.toEn)},async translateToLocalByGroupTags(e,t=!1){return console.log("translateToLocalByGroupTags",e),this._translateToLocalBy(e,this.groupTagsTranslateCache.toLocal,t)},async translateToEnByGroupTags(e){return this._toEn(e,this.groupTagsTranslateCache.toEn)},_toEn(e,t){return e=e.trim().toLowerCase(),t.has(e)?t.get(e):""}}},qi=Number.isNaN||window.isNaN,xw=/^-?(?:\d+|\d+\.\d+|\.\d+)(?:[eE][-+]?\d+)?$/,Sw=/\.\d*(?:0|9){10}\d*$/,jg=(e,t=1e11)=>Sw.test(String(e))?Math.round(e*t)/t:e,Aw=Rn({name:"VueNumberInput",props:{attrs:{type:Object,default:void 0},center:Boolean,controls:Boolean,disabled:Boolean,inputtable:{type:Boolean,default:!0},inline:Boolean,max:{type:Number,default:1/0},min:{type:Number,default:-1/0},name:{type:String,default:void 0},placeholder:{type:String,default:void 0},readonly:Boolean,rounded:Boolean,size:{type:String,default:void 0},step:{type:Number,default:1},modelValue:{type:Number,default:NaN}},emits:["update:modelValue"],data(){return{value:NaN}},computed:{increasable(){return qi(this.value)||this.value<this.max},decreasable(){return qi(this.value)||this.value>this.min}},watch:{modelValue:{immediate:!0,handler(e,t){!(qi(e)&&typeof t>"u")&&e!==this.value&&this.setValue(e)}}},methods:{isNaN:qi,change(e){this.setValue(e.target.value)},paste(e){const t=e.clipboardData||window.clipboardData;t&&!xw.test(t.getData("text"))&&e.preventDefault()},decrease(){if(this.decreasable){let{value:e}=this;qi(e)&&(e=0),this.setValue(jg(e-this.step))}},increase(){if(this.increasable){let{value:e}=this;qi(e)&&(e=0),this.setValue(jg(e+this.step))}},setValue(e){const t=this.value;let n=typeof e!="number"?parseFloat(e):e;qi(n)||(this.min<=this.max&&(n=Math.min(this.max,Math.max(this.min,n))),this.rounded&&(n=Math.round(n))),this.value=n,n===t&&(this.$refs.input.value=String(n)),this.$emit("update:modelValue",n,t)}}}),hn=(e,t)=>{const n=e.__vccOpts||e;for(const[r,i]of t)n[r]=i;return n},Ew=["disabled"],Lw=["name","value","min","max","step","readonly","disabled","placeholder"],Ow=["disabled"];function Iw(e,t,n,r,i,o){return E(),M("div",{class:Ge(["vue-number-input",{"vue-number-input--inline":e.inline,"vue-number-input--center":e.center,"vue-number-input--controls":e.controls,[`vue-number-input--${e.size}`]:e.size}])},[e.controls?(E(),M("button",{key:0,class:"vue-number-input__button vue-number-input__button--minus",type:"button",tabindex:"-1",disabled:e.disabled||e.readonly||!e.decreasable,onClick:t[0]||(t[0]=nt((...s)=>e.decrease&&e.decrease(...s),["prevent"]))},null,8,Ew)):ke("",!0),T("input",bl({ref:"input",class:"vue-number-input__input"},e.attrs,{type:"number",name:e.name,value:isNaN(e.value)?"":e.value,min:e.min,max:e.max,step:e.step,readonly:e.readonly||!e.inputtable,disabled:e.disabled||!e.decreasable&&!e.increasable,placeholder:e.placeholder,autocomplete:"off",onChange:t[1]||(t[1]=(...s)=>e.change&&e.change(...s)),onPaste:t[2]||(t[2]=(...s)=>e.paste&&e.paste(...s))}),null,16,Lw),e.controls?(E(),M("button",{key:1,class:"vue-number-input__button vue-number-input__button--plus",type:"button",tabindex:"-1",disabled:e.disabled||e.readonly||!e.increasable,onClick:t[3]||(t[3]=nt((...s)=>e.increase&&e.increase(...s),["prevent"]))},null,8,Ow)):ke("",!0)],2)}const Pw=hn(Aw,[["render",Iw]]),Dw={data(){return{autocompleteResults:null,autocompleteResultsParent:null,showAppendList:!1,appendListStyle:{top:0,left:0},appendListSelected:null,appendListChildSelected:null,appendList:[{type:"wrap",name:"line_break_character",icon:"wrap",children:[]}],favorites:[],autoInputPrompt:"disabled",autoInputPromptKey:""}},computed:{appendListChildItemTags(){return this.appendListSelected===null?[]:this.appendListChildSelected===null?[]:this.appendList[this.appendListSelected].type!=="favorite"&&this.appendList[this.appendListSelected].type!=="history"?[]:this.appendList[this.appendListSelected].children[this.appendListChildSelected].tags}},mounted(){this.initAutoInputPrompt(),[{name:"txt2img",type:"prompt",key:"txt2img",neg:!1},{name:"txt2img",type:"negative_prompt",key:"txt2img_neg",neg:!0},{name:"img2img",type:"prompt",key:"img2img",neg:!1},{name:"img2img",type:"negative_prompt",key:"img2img_neg",neg:!0}].forEach(t=>{t.neg===this.neg&&this.appendList.push({type:"favorite",name:["favorite",t.name],icon:"favorite",key:t.key,dataKey:"favorite."+t.key,children:[]})})},methods:{onUnfoldClick(){this.hidePanel&&this.$nextTick(()=>{this.onResize()}),this.$emit("update:hidePanel",!this.hidePanel)},onTranslatesToLocalClick(){if(this.tags.length===0)return;if(this.loading.all_local){this.cancelMultiTranslate=!0,this.loading.all_local=!1;return}this.loading.all_local=!0;let e=[];for(const t in this.tags)this.tags[t].type&&this.tags[t].type!=="text"||e.push(t);return this.translates(e,!0,!0).finally(()=>{this.loading.all_local=!1,this.updateTags()})},onTranslatesToEnglishClick(){if(this.tags.length===0)return;if(this.loading.all_en){this.cancelMultiTranslate=!0,this.loading.all_en=!1;return}this.loading.all_en=!0;let e=[];for(const t in this.tags)this.tags[t].type&&this.tags[t].type!=="text"||e.push(t);this.translates(e,!1,!0).finally(()=>{this.loading.all_en=!1,this.updateTags()})},onCopyAllTagsClick(){this.copy(this.prompt)},onDeleteAllTagsClick(){confirm(this.getLang("delete_all_keywords_confirm"))&&(this.tags=[],this.updateTags())},appendListItemName(e){let t=[];if(typeof e.name=="object")for(let n of e.name)t.push(this.getLang(n));else t=[this.getLang(e.name)];return t.join(" / ")},onAppendTagFocus(e){if(this.$refs.promptTagAppend.value===""||this.$refs.promptTagAppend.value.trim()===""){this.appendListStyle={top:e.target.offsetTop+e.target.offsetHeight+"px",left:e.target.offsetLeft+"px"},this.appendListSelected=null,this.appendListChildSelected=null,this.showAppendList=!0;let t=[];this.appendList.forEach(n=>{typeof n.dataKey=="string"&&t.push(n.dataKey)}),this.gradioAPI.getDatas(t).then(n=>{this.appendList.forEach(r=>{typeof r.dataKey=="string"&&(r.children=n[r.dataKey]||[],r.children.reverse())})})}this._setTextareaFocus()},onAppendTagBlur(e){setTimeout(()=>{this.showAppendList=!1},300)},selectAppendList(e=!0){this.appendList.length!==0&&(this.appendListSelected===null?this.appendListSelected=0:e?(this.appendListSelected++,this.appendListSelected>=this.appendList.length&&(this.appendListSelected=0)):(this.appendListSelected--,this.appendListSelected<0&&(this.appendListSelected=this.appendList.length-1)),this.appendListChildSelected=null)},selectAppendListChild(e=!0){this.appendList.length!==0&&this.appendListSelected!==null&&this.appendList[this.appendListSelected].children.length!==0&&(this.appendListChildSelected===null?this.appendListChildSelected=0:e?(this.appendListChildSelected++,this.appendListChildSelected>=this.appendList[this.appendListSelected].children.length&&(this.appendListChildSelected=0)):(this.appendListChildSelected--,this.appendListChildSelected<0&&(this.appendListChildSelected=this.appendList[this.appendListSelected].children.length-1)),this.scrollAppendListChild())},scrollAppendListChild(){this.appendListSelected!==null&&(this.appendListChildSelected===0||this.appendListChildSelected===null?this.$refs.promptAppendListChildren[this.appendListSelected].scrollTop=0:this.$refs.promptAppendListChild[this.appendListChildSelected].scrollIntoView({behavior:"smooth",block:"center"}))},onAppendTagKeyDown(e,t=null){if(!(e.keyCode===38||e.keyCode===40))if(e.keyCode===13){if(this.getAutocompleteResults()&&(this.autocompleteResultsParent&&this.autocompleteResultsParent.style.display==="flex"||this.autocompleteResults.style.display==="none")&&this.getAutocompleteResultsSelected()){let r=this.getAutocompleteResultsSelectedText();setTimeout(()=>{t=this.$refs.promptTagAppend.value,r?t=r:(r=this.getAutocompleteResultsSelectedText(),r&&(t=r)),this.onAppendTagKeyDown(e,t)},300);return}let n=this.$refs.promptTagAppend.value;if(this.$refs.promptTagAppend.value="",this.showAppendList=!0,console.log(n,t),t)n=n.replace(/\s*,\s*$/,"").trim(),he.hasBrackets(n)&&(n=he.replaceBrackets(n)),this._appendTag(n,t),this.updateTags();else{he.hasBrackets(n)?(n=he.replaceBrackets(n),n=[n]):n=he.splitTags(n,this.autoBreakBeforeWrap,this.autoBreakAfterWrap);let r=[];n.forEach(i=>{let o=-1;i===`
|
||
`?o=this._appendTag(`
|
||
`,`
|
||
`,!1,-1,"wrap"):o=this._appendTag(i),o!==-1&&r.push(o)}),this.autoTranslateByIndexes(r)}}else this.removeAutocompleteResultsSelected()},autoTranslateByIndexes(e){this.updatePrompt(),this.autoTranslateToEnglish||this.autoTranslateToLocal?this.$nextTick(()=>{let t=!(this.tagCompleteFile&&this.onlyCsvOnAuto);this.autoTranslateToEnglish?this.translates(e,!1,t).finally(()=>{this.updateTags()}):this.autoTranslateToLocal&&this.translates(e,!0,t).finally(()=>{this.updateTags()})}):this.updateTags()},onAppendTagKeyUp(e){this.$refs.promptTagAppend.value===""||this.$refs.promptTagAppend.value.trim()===""?(this.$refs.promptTagAppend.value="",this.showAppendList=!0,e.keyCode===38||e.keyCode===40?this.appendListChildSelected===null?this.selectAppendList(e.keyCode===40):this.selectAppendListChild(e.keyCode===40):e.keyCode===37||e.keyCode===39?this.appendListSelected!==null&&(e.keyCode===37?(this.appendListChildSelected=null,this.scrollAppendListChild()):this.appendList[this.appendListSelected].children.length===0?this.appendListChildSelected=null:(this.appendListChildSelected=0,this.scrollAppendListChild())):e.keyCode===13&&(this._appendTagByList(),this.scrollAppendListChild(),this.appendListSelected=null,this.appendListChildSelected=null)):this.showAppendList=!1},onAppendGroupClick(e,t,n){if(e!==null){if(this.appendListSelected=e,t===null){if(this.appendList[this.appendListSelected].children.length>0)return}else this.appendListChildSelected=t;this._appendTagByList()}},onAppendListChildMouseLeave(e,t,n){this.appendListSelected=null,this.appendListChildSelected=null},onAppendListChildMouseEnter(e,t,n){this.appendListSelected=e,this.appendListChildSelected=t},_appendTagByList(){if(this.appendListSelected===null)return;const e=this.appendList[this.appendListSelected];let t=null;e.children.length>0&&this.appendListChildSelected!==null&&(t=e.children[this.appendListChildSelected]);let n=[];switch(e.type){case"wrap":n.push({value:`
|
||
`,localValue:`
|
||
`,disabled:!1,type:"wrap"});break;case"lora":break;case"favorite":case"history":t&&t.tags.forEach(r=>{n.push({value:r.value,localValue:r.localValue,disabled:r.disabled,type:r.type||"text"})});break}n.length<=0||(n.forEach(r=>{this._appendTag(r.value,r.localValue,r.disabled,-1,r.type)}),this.updateTags())},getAutocompleteResults(){if(!this.autocompleteResults){const e=this.$refs.promptTagAppend.parentElement.querySelector(".autocompleteResults");if(e){this.autocompleteResults=e,this.autocompleteResults.getAttribute("data-mousemove")!=="true"&&(this.autocompleteResults.setAttribute("data-mousemove","true"),this.autocompleteResults.addEventListener("mousemove",n=>{this.bindAutocompleteResultsClick()}));const t=this.$refs.promptTagAppend.parentElement.querySelector(".autocompleteParent");t&&(this.autocompleteResultsParent=t)}}return this.autocompleteResults},removeAutocompleteResultsSelected(){const e=this.getAutocompleteResults();return e?(e.querySelectorAll("li").forEach(t=>{t.classList.remove("selected")}),!0):!1},getAutocompleteResultsSelected(){const e=this.getAutocompleteResults();if(!e)return null;const t=e.querySelector("li.selected");return t||null},getAutocompleteResultsSelectedText(e=null){if(!e&&(e=this.getAutocompleteResultsSelected(),!e))return null;const r=e.querySelector(".acListItem").innerText.match(/\[(.+?)\]/);return r?r[1]:null},bindAutocompleteResultsClick(){if(this.getAutocompleteResults(),!this.autocompleteResults)return;this.autocompleteResults.querySelectorAll("li").forEach(t=>{t.getAttribute("physton-on-clicked")!=="true"&&(t.setAttribute("physton-on-clicked","true"),t.addEventListener("click",()=>{this.onAutocompleteResultsClicked(t)}))})},onAutocompleteResultsClicked(e){const t=this.getAutocompleteResultsSelectedText(e);setTimeout(()=>{let n=this.$refs.promptTagAppend.value.replace(/,\s*$/,"");this.$refs.promptTagAppend.value="",n=n.replace(/\s*,\s*$/,"").trim(),he.hasBrackets(n)&&(n=he.replaceBrackets(n)),this._appendTag(n,t),this.updateTags()},300)},onSettingBoxMouseEnter(){this.favorites=typeof window.phystonPromptfavorites=="object"?window.phystonPromptfavorites:[]},getCurrentTypeFavorites(){this.favorites=typeof window.phystonPromptfavorites=="object"?window.phystonPromptfavorites:[];let e=[];return this.favorites.forEach(t=>{if(this.neg){if(t.type!=="negative_prompt")return}else if(t.type!=="prompt")return;e.push(t)}),e},onAutoInputPromptChange(){this.gradioAPI.setData(this.autoInputPromptKey,this.autoInputPrompt).then(()=>{this.$toastr.success(this.getLang("success"))}).catch(()=>{this.$toastr.error(this.getLang("failed"))})},initAutoInputPrompt(){this.autoInputPromptKey="autoInputPrompt-"+this.name,this.gradioAPI.getData(this.autoInputPromptKey).then(e=>{if(e!==null)if(this.autoInputPrompt=e,this.autoInputPrompt==="last")this.gradioAPI.getLatestHistory(this.historyKey).then(t=>{this.useHistory(t)});else{const t=()=>{if(typeof window.phystonPromptfavorites=="object"&&window.phystonPromptfavorites.length>0){for(let n of window.phystonPromptfavorites)for(let r of n.list)if(r.id===this.autoInputPrompt){this.useFavorite(r);return}return}setTimeout(t,100)};setTimeout(t,100)}})}}},Rw={data(){return{dropStartX:0,dropStartY:0,dropEndX:0,dropEndY:0,dropOffsetX:0,dropOffsetY:0,dropIsSelecting:!1,dropIsStart:!1,dropIsEnd:!1,dropArea:{top:0,left:0,width:0,height:0},dropTags:[],dropTimeId:0}},methods:{_dropOver(){this.dropIsSelecting=!1,this.dropIsStart=!1,this.dropIsEnd=!1,this.dropTags=[];for(let e=0;e<this.$refs.promptTagsList.children.length;e++){let t=this.$refs.promptTagsList.children[e];t.style.display==="none"&&(t.style.display=""),t.classList.remove("drop-selected")}},onDropMouseDown(e){this.droping||(this._dropOver(),this.dropOffsetX=e.clientX-e.layerX,this.dropOffsetY=e.clientY-e.layerY,this.dropStartX=e.clientX-this.dropOffsetX,this.dropStartY=e.clientY-this.dropOffsetY,this.dropEndX=e.clientX-this.dropOffsetX,this.dropEndY=e.clientY-this.dropOffsetY,this.dropIsStart=!0)},onDropMouseMove(e){if(this.dropIsStart){this.dropIsSelecting=!0,this.dropEndX=e.clientX-this.dropOffsetX,this.dropEndY=e.clientY-this.dropOffsetY;let t=Math.min(this.dropStartX,this.dropEndX),n=Math.min(this.dropStartY,this.dropEndY),r=Math.abs(this.dropStartX-this.dropEndX),i=Math.abs(this.dropStartY-this.dropEndY);t=Math.max(t,0),n=Math.max(n,0),r=Math.min(r,this.$refs.promptTags.clientWidth-t),i=Math.min(i,this.$refs.promptTags.clientHeight-n),this.dropArea.top=n,this.dropArea.left=t,this.dropArea.width=r,this.dropArea.height=i,this.dropTimeId&&clearTimeout(this.dropTimeId),this.dropTimeId=setTimeout(this.dropSelectItems,10)}this.$emit("hideExtraNetworks")},dropSelectItems(){this.dropTimeId&&clearTimeout(this.dropTimeId);let e=[];for(let t=0;t<this.$refs.promptTagsList.children.length;t++){let n=this.$refs.promptTagsList.children[t];if(!n.classList.contains("prompt-tag"))continue;let r=n.offsetLeft,i=n.offsetTop,o=n.clientWidth,s=n.clientHeight,l=r+o,c=i+s;!(l<this.dropArea.left||c<this.dropArea.top||r>this.dropArea.left+this.dropArea.width||i>this.dropArea.top+this.dropArea.height)?(e.push(n.getAttribute("data-id")),n.classList.add("drop-selected")):n.classList.remove("drop-selected"),this.dropTags=e}},onDropMouseUp(e){this.dropIsSelecting=!1,this.dropIsStart=!1,this.dropIsEnd=!0,this.$refs.dropSelectBtns.style.left=this.$refs.dropSelectBox.style.left,this.$refs.dropSelectBtns.style.top=this.$refs.dropSelectBox.style.top},_getDropTags(){let e=[];return this.dropTags.forEach(t=>{let n=this.tags.find(r=>r.id===t);n&&e.push(n)}),e},_getDropIndexes(){let e=[];return this.dropTags.forEach(t=>{let n=this.tags.findIndex(r=>r.id===t);n!==-1&&e.push(n)}),e},_getDropTagsEle(){let e=[];return this.dropTags.forEach(t=>{let n=this.$refs.promptTagsList.querySelector(`.prompt-tag[data-id="${t}"]`);n&&e.push(n)}),e},onDropCopy(){let e=this._getDropTags();this._dropOver();let t=this.genPrompt(e,!0);this.copy(t)},onDropFavorite(){let e=this._getDropTags();this._dropOver();let t=this.genPrompt(e,!0);this.gradioAPI.pushFavorite(this.favoriteKey,e,t,"").then(n=>{n?(this.$toastr.success(this.getLang("success")),this.$emit("refreshFavorites",this.favoriteKey)):this.$toastr.error(this.getLang("failed"))}).catch(n=>{this.$toastr.error(this.getLang("failed"))})},onDropDisable(){let e=this._getDropTags();this._dropOver(),e.forEach(t=>{t.disabled=!0}),this.updateTags()},onDropEnable(){let e=this._getDropTags();this._dropOver(),e.forEach(t=>{t.disabled=!1}),this.updateTags()},onDropDelete(){let e=this._getDropIndexes();this._dropOver(),e.sort((t,n)=>n-t),e.forEach(t=>{this.tags.splice(t,1)}),this.updateTags()}}};var nf="__autosizeInputGhost",Nw={" ":"nbsp","<":"lt",">":"gt"};function Mw(e){return"&"+Nw[e]+";"}function Fw(e){return e.replace(/\s|<|>/g,Mw)}function Bw(){var e=document.createElement("div");return e.id=nf,e.style.cssText="display:inline-block;height:0;overflow:hidden;position:absolute;top:0;visibility:hidden;white-space:nowrap;",document.body.appendChild(e),e}var $w=function(e,t){var n=window.getComputedStyle(e),r="box-sizing:"+n.boxSizing+";border-left:"+n.borderLeftWidth+" solid red;border-right:"+n.borderRightWidth+" solid red;font-family:"+n.fontFamily+";font-feature-settings:"+n.fontFeatureSettings+";font-kerning:"+n.fontKerning+";font-size:"+n.fontSize+";font-stretch:"+n.fontStretch+";font-style:"+n.fontStyle+";font-variant:"+n.fontVariant+";font-variant-caps:"+n.fontVariantCaps+";font-variant-ligatures:"+n.fontVariantLigatures+";font-variant-numeric:"+n.fontVariantNumeric+";font-weight:"+n.fontWeight+";letter-spacing:"+n.letterSpacing+";margin-left:"+n.marginLeft+";margin-right:"+n.marginRight+";padding-left:"+n.paddingLeft+";padding-right:"+n.paddingRight+";text-indent:"+n.textIndent+";text-transform:"+n.textTransform;function i(){var s=e.value||e.getAttribute("placeholder")||"",l=document.getElementById(nf)||Bw();l.style.cssText+=r,l.innerHTML=Fw(s);var c=window.getComputedStyle(l).width;return e.style.width=c,c}e.addEventListener("input",i);var o=i();return t&&t.minWidth&&o!=="0px"&&(e.style.minWidth=o),function(){e.removeEventListener("input",i);var s=document.getElementById(nf);s&&s.parentNode.removeChild(s)}};const Hw=Bl($w),jw={data(){return{tagClickTimeId:0,showExtendId:""}},mounted(){he.gradioApp().addEventListener("mousemove",()=>{this.$refs.highlightPrompt.hide()})},methods:{_setTag(e){if(typeof e.type=="string"&&e.type==="wrap")e.weightNum=1,e.incWeight=0,e.decWeight=0;else if(e.weightNum=he.getTagWeightNum(e.value),e.incWeight=he.getTagIncWeight(e.value),e.decWeight=he.getTagDecWeight(e.value),e.originalValue=e.value,!e.value.match(he.loraRegex)&&!e.value.match(he.lycoRegex)){let t=e.value;const n=he.hasBrackets(t);(n[0]==="("&&n[1]===")"||n[0]==="["&&n[1]==="]")&&(t=he.setLayers(t,0,n[0],n[1]),e.originalValue=t.replace(he.weightNumRegex,"$1"))}this._setTagClass(e),this.$nextTick(()=>{this._setTagHeight(e)})},_setTagHeight(e){let t=10,n=setInterval(()=>{if(t--,t<=0&&clearInterval(n),!this.$refs["promptTagValue-"+e.id]||!this.$refs["promptTagValue-"+e.id][0])return!1;clearInterval(n);let r=this.$refs["promptTagValue-"+e.id][0],i=r.offsetHeight;r.parentNode.style.height=i+"px",this.$refs["promptTagEdit-"+e.id]&&(this.$refs["promptTagEdit-"+e.id][0].style.height=i+"px"),this.$refs["promptTagDelete-"+e.id]&&(this.$refs["promptTagDelete-"+e.id][0].style.height=i+"px")},50)},_getTagType(e){},_setTagClass(e){if(e.isLora=!1,e.loraExists=!1,e.isLyco=!1,e.lycoExists=!1,e.isEmbedding=!1,!(typeof e.type=="string"&&e.type==="wrap")){const n=e.value.match(he.loraRegex);if(n&&(e.isLora=!0,e.loraName=n[1],this.loraExists(n[1])!==!1&&(e.loraExists=!0)),!e.isLora){const r=e.value.match(he.lycoRegex);r&&(e.isLyco=!0,e.lycoName=r[1],this.lycoExists(r[1])!==!1&&(e.lycoExists=!0))}if(!e.isLora&&!e.isLyco){const r=this.embeddingExists(e.value);if(r!==!1)e.isEmbedding=!0,e.value=r,e.embeddingName=r;else{const i=this.embeddingExists(e.originalValue);i!==!1&&(e.isEmbedding=!0,e.embeddingName=i)}}}let t=["prompt-tag-value"];return e.isLora?(t.push("lora-tag"),e.loraExists||t.push("lora-not-exists")):e.isLyco?(t.push("lyco-tag"),e.lycoExists||t.push("lyco-not-exists")):e.isEmbedding?t.push("embedding-tag"):this.neg&&t.push("neg-tag"),e.classes=t,t},_setTagById(e,t=null,n=null){let r=this.tags.find(i=>i.id===e);return r?(t!==null&&(r.value=t),n!==null&&(r.localValue=n),r):!1},_isTagBlacklist(e){var t,n,r,i,o;if(typeof e.type=="string"&&e.type==="wrap")return!1;if(e.isLora){if((t=this.blacklist.lora)!=null&&t.includes(e.loraName.toLowerCase()))return!0}else if(e.isLyco){if((n=this.blacklist.lycoris)!=null&&n.includes(e.lycoName.toLowerCase()))return!0}else if(e.isEmbedding){if((r=this.blacklist.embedding)!=null&&r.includes(e.embeddingName.toLowerCase()))return!0}else if(this.neg){if((i=this.blacklist.negative_prompt)!=null&&i.includes(e.originalValue.toLowerCase()))return!0}else if((o=this.blacklist.prompt)!=null&&o.includes(e.originalValue.toLowerCase()))return!0;return!1},_appendTag(e,t="",n=!1,r=-1,i="text"){if(e==="")return-1;const o=Date.now()+(Math.random()*1e6).toFixed(0);let s={id:o,value:e==null||e===!1?"":e,localValue:t==null||t===!1?"":t,disabled:n,type:i};return this._setTag(s),this._isTagBlacklist(s)?-1:(r>=0?this.tags.splice(r,0,s):r=this.tags.push(s),this.$nextTick(()=>{this.$refs["promptTagEdit-"+o]&&Hw(this.$refs["promptTagEdit-"+o][0])}),r-1)},renderTag(e){let t=this.tags.find(r=>r.id===e);if(!t)return"";let n=t.value;if(n==="BREAK"&&(this.autoBreakBeforeWrap||this.autoBreakAfterWrap))n='<div class="break-character">---------------------</div> <div class="character">BREAK</div> <div class="break-character">---------------------</div>';else if(n=he.escapeHtml(n),t.incWeight>0){n=he.setLayers(n,0,"(",")"),n='<div class="character">'+n+"</div>";let r='<div class="weight-character">'+"(".repeat(t.incWeight)+"</div>",i='<div class="weight-character">'+")".repeat(t.incWeight)+"</div>";n=r+n+i}else if(t.decWeight>0){n=he.setLayers(n,0,"[","]"),n='<div class="character">'+n+"</div>";let r='<div class="weight-character">'+"[".repeat(t.decWeight)+"</div>",i='<div class="weight-character">'+"]".repeat(t.decWeight)+"</div>";n=r+n+i}else n='<div class="character">'+n+"</div>";return n},isFavorite(e){let t=this.tags.find(n=>n.id===e);if(!t)return!1;if(typeof window.phystonPromptfavorites=="object"){for(const n of window.phystonPromptfavorites)if(n.key===this.favoriteKey){for(const r of n.list)if(r.tags.length===1&&r.tags[0].value===t.value)return r.id}}return!1},onLoraPopupUseKeywords(e){let t=[];for(let n of e){let r=n.toLowerCase();if(!this.tags.find(o=>o.value.toLowerCase()===r)){let o=this._appendTag(n,"",!1,-1,"text");o!==-1&&t.push(o)}}t.length&&this.autoTranslateByIndexes(t)},onTagMouseEnter(e){let t=this.tags.find(n=>n.id===e);if(!t)return!1;if(t.isFavorite=this.isFavorite(t.id),this.hotkey.hover==="extend"&&(this.showExtendId=e),t.isLora||t.isLyco||t.isEmbedding){let n=t.isLora?t.loraName:t.isLyco?t.lycoName:t.embeddingName;this.$emit("showExtraNetworks",this.$refs["promptTagValue-"+t.id][0],n,this.onLoraPopupUseKeywords)}},onTagMouseMove(e){let t=this.tags.find(n=>n.id===e);if(!t)return!1;this.$refs.highlightPrompt.show(t)},onTagMouseLeave(e){if(!this.tags.find(n=>n.id===e))return!1;this.hotkey.hover==="extend"&&(this.showExtendId=""),this.$emit("hideExtraNetworks")},onTagClick(e){this.tagClickTimeId&&clearTimeout(this.tagClickTimeId),this.tagClickTimeId=setTimeout(()=>{switch(this.hotkey.click){case"edit":this._handleEditTag(e);break;case"disable":this._handleDisableTag(e);break;case"extend":this._handleHoverTag(e);break}clearTimeout(this.tagClickTimeId)},250)},onTagDblclick(e){switch(clearTimeout(this.tagClickTimeId),this.hotkey.dblClick){case"edit":this._handleEditTag(e);break;case"disable":this._handleDisableTag(e);break;case"extend":this._handleHoverTag(e);break}},onTagRightClick(e,t){switch(this.hotkey.rightClick){case"edit":this._handleEditTag(e);break;case"disable":this._handleDisableTag(e);break;case"extend":this._handleHoverTag(e);break}},_handleEditTag(e){let t=this.tags.find(n=>n.id===e);if(!t)return!1;this.editing={},this.editing[t.id]=!0,this.$forceUpdate(),this.$nextTick(()=>{const n=this.$refs["promptTagEdit-"+t.id][0];n.focus(),n.dispatchEvent(new Event("input"))})},_handleDisableTag(e){let t=this.tags.find(n=>n.id===e);if(!t)return!1;this.onDisabledTagClick(t.id)},_handleHoverTag(e){if(!this.tags.find(n=>n.id===e))return!1;this.showExtendId=e},onTagInputBlur(e){let t=this.tags.find(n=>n.id===e);if(!t)return!1;this.editing[t.id]=!1},onTagInputKeyDown(e,t){if(t.keyCode===13){let n=this.tags.find(r=>r.id===e);if(!n)return!1;this.editing[n.id]=!1,n.value!==t.target.value&&(n.value=t.target.value,this._setTag(n),this.updateTags())}},onTagInputChange(e,t){let n=this.tags.find(r=>r.id===e);if(!n)return!1;n.value!==t.target.value&&(n.value=t.target.value,this._setTag(n),this.updateTags())},onTagWeightNumChange(e,t){let n=this.tags.find(s=>s.id===e);if(!n)return!1;if(t=typeof t=="number"||typeof a=="string"?t:t.target.value,n.weightNum==t)return;let r=t,i=n.value,o=n.localValue;if(r!==0){if(r===1&&!this.autoKeepWeightOne){const s=he.hasBrackets(i);s[0]==="("&&s[1]===")"&&(i=he.setLayers(i,0,s[0],s[1]),o!==""&&(o=he.setLayers(o,0,s[0],s[1]))),i=i.replace(he.weightNumRegex,"$1"),o!==""&&(o=o.replace(he.weightNumRegex,"$1"))}else{if(!he.weightNumRegex.test(i)){let s=he.hasBrackets(i);s?(i=he.setLayers(i,1,s[0],s[1],":"+r),o!==""&&(o=he.setLayers(o,1,s[0],s[1],":"+r))):(i=i+":"+r,o!==""&&(o=o+":"+r))}he.hasBrackets(i)||(i=he.setLayers(i,1,"(",")"),o!==""&&(o=he.setLayers(o,1,"(",")")))}i!==n.value&&(n.value=i,o!==""&&(n.localValue=o),this._setTag(n))}else this.autoKeepWeightZero?(n.value=i.replace(he.weightNumRegex,"$1:0"),o!==""&&(n.localValue=n.localValue.replace(he.weightNumRegex,"$1:0"))):(n.value=i.replace(he.weightNumRegex,"$1"),o!==""&&(n.localValue=n.localValue.replace(he.weightNumRegex,"$1")));n.weightNum=r,this.updateTags()},onDeleteTagClick(e){let t=this.tags.find(r=>r.id===e);if(!t)return!1;let n=this.tags.indexOf(t);this.tags.splice(n,1),this.updateTags()},onFavoriteTagClick(e){let t=this.tags.find(r=>r.id===e);if(!t)return!1;let n=this.isFavorite(t.id);n?this.gradioAPI.unFavorite(this.favoriteKey,n).then(r=>{r&&(t.isFavorite=!1,this.$emit("refreshFavorites",this.favoriteKey))}):this.gradioAPI.pushFavorite(this.favoriteKey,[t],t.value,t.localValue===""?t.value:t.localValue).then(r=>{r&&(t.isFavorite=!0,this.$emit("refreshFavorites",this.favoriteKey))})},onDisabledTagClick(e){let t=this.tags.find(n=>n.id===e);t&&(t.disabled=!t.disabled,this.updateTags())},onIncWeightClick(e,t){let n=this.tags.find(s=>s.id===e);if(!n)return;let r=n.value,i=n.localValue;r=he.setLayers(r,0,"[","]"),i!==""&&(i=he.setLayers(i,0,"[","]"));let o=n.incWeight;o+=t,o<0&&(o=0),n.incWeight=o,n.decWeight=0,r=he.setLayers(r,o,"(",")"),i!==""&&(i=he.setLayers(i,o,"(",")")),n.value=r,i!==""&&(n.localValue=i),this.updateTags()},onDecWeightClick(e,t){let n=this.tags.find(s=>s.id===e);if(!n)return;let r=n.value,i=n.localValue;r=he.setLayers(r,0,"(",")"),i!==""&&(i=he.setLayers(i,0,"(",")"));let o=n.decWeight;o+=t,o<0&&(o=0),n.incWeight=0,n.decWeight=o,r=he.setLayers(r,o,"[","]"),i!==""&&(i=he.setLayers(i,o,"[","]")),n.value=r,i!==""&&(n.localValue=i),this.updateTags()},onWrapTagClick(e){let t=this.tags.find(o=>o.id===e);if(!t)return;let n=this.tags.indexOf(t),r=this._appendTag(`
|
||
`,`
|
||
`,!1,-1,"wrap"),i=this.tags[r];this.tags.splice(r,1),this.tags.splice(n+1,0,i),this.updateTags()},onTranslateToLocalClick(e){let t=this.tags.find(r=>r.id===e);if(!t)return;let n=this.tags.indexOf(t);this.loading[t.id+"_local"]||this.translates([n],!0,!0).finally(()=>{this.updateTags()})},onTranslateToEnglishClick(e){let t=this.tags.find(r=>r.id===e);if(!t)return;let n=this.tags.indexOf(t);this.loading[t.id+"_en"]||this.translates([n],!1,!0).finally(()=>{this.updateTags()})},onBlacklistClick(e){let t=this.tags.find(r=>r.id===e);if(!t)return;if(!this.cancelBlacklistConfirm){let r=this.getLang("confirm_add_blacklist").replace("{0}",t.value)+`
|
||
`+this.getLang("blacklist_desc");if(!confirm(r))return}let n=JSON.parse(JSON.stringify(this.blacklist));t.isLora?n.lora.push(t.loraName):t.isLyco?n.lycoris.push(t.lycoName):t.isEmbedding?n.embedding.push(t.embeddingName):this.neg?n.negative_prompt.push(t.originalValue):n.prompt.push(t.originalValue),this.gradioAPI.setData("blacklist",n),this.$emit("update:blacklist",n,this.cancelBlacklistConfirm),this.tags.forEach(r=>{r.value===t.value&&this.onDeleteTagClick(r.id)})}}},Uw={data(){return{groupTagsActive:"",subGroupTagsActive:""}},watch:{groupTags:{handler(){(!this.groupTagsActive||!this.subGroupTagsActive)&&(this.groupTagsActive="favorite",this.subGroupTagsActive="favorite-"+this.favoriteKey),this._setGroupTagItemWidth()},deep:!0,immediate:!0},favorites:{handler(){},deep:!0,immediate:!0}},mounted(){this.gradioAPI.getData("groupTagsActive-"+this.name).then(e=>{e!==null&&typeof e=="object"&&(this.groupTagsActive=e.groupTagsActive,this.subGroupTagsActive=e.subGroupTagsActive)})},methods:{saveGroupActive(){this.gradioAPI.setData("groupTagsActive-"+this.name,{groupTagsActive:this.groupTagsActive,subGroupTagsActive:this.subGroupTagsActive})},activeGroupTab(e){e==="favorite"?(this.groupTagsActive="favorite",this.subGroupTagsActive="favorite-"+this.favoriteKey,e=0):(this.groupTagsActive=this.groupTags[e].tabKey,this.subGroupTagsActive=this.groupTags[e].groups[0].tabKey,e+=1),this.saveGroupActive();let t=this.$refs.groupTabsHeader.children[e].offsetLeft-this.$refs.groupTabsHeader.offsetWidth/2+this.$refs.groupTabsHeader.children[e].offsetWidth/2;this.$refs.groupTabsHeader.scrollTo({left:t,behavior:"smooth"}),this._setGroupTagItemWidth()},activeSubGroupTab(e,t){e==="favorite"?this.subGroupTagsActive="favorite-"+t:this.subGroupTagsActive=this.groupTags[e].groups[t].tabKey,this.saveGroupActive(),this._setGroupTagItemWidth()},_setGroupTagItemWidth(){this.$nextTick(()=>{if(!this.$refs.groupTagItem)return;this.$refs.groupTagItem.forEach((t,n)=>{t.style.width="auto"});let e=0;this.$refs.groupTagItem.forEach((t,n)=>{e=Math.max(e,t.offsetWidth)}),e>0&&this.$refs.groupTagItem.forEach((t,n)=>{t.style.width=e+"px"})})},onClickHideGroupTags(){this.$emit("update:hideGroupTags",!this.hideGroupTags)},onClickGroupTag(e,t){let n=[];this.tags.forEach((r,i)=>{r.originalValue===t&&n.push(i)}),n.length?n.reverse().forEach(r=>{this.tags.splice(r,1)}):this._appendTag(t,e,!1,-1,"text"),this.updateTags()},onClickGroupTagFavorite(e){e.tags.forEach(t=>{this._appendTag(t.value,t.localValue,t.disabled,-1,t.type)}),this.updateTags()},getGroupTagTooltip(e,t){let n="";return e&&e!==t&&(n+=e+"<br/>"),n+=t,n},getGroupTagStyle(e,t,n){let r={},i=he.getTagsColorKey(e,t),o="";this.groupTagsColor[i]&&(o=this.groupTagsColor[i],he.isColorTransparent(o)&&(o="")),o&&(r={background:o});for(let s of this.tags)if(s.originalValue===n){r.filter="grayscale(1)";break}return r},getTagsColorKey(e,t){return he.getTagsColorKey(e,t)},onTagsColorChange(e){this.$emit("update:groupTagsColor",this.groupTagsColor)},onClickResetTagsColor(e){for(let t of this.groupTags)for(let n of t.groups){if(n.type&&n.typ=="wrap")continue;let r=he.getTagsColorKey(t.name,n.name);e===r&&(this.groupTagsColor[e]=Lt(he.fitterInputColor(n.color)))}this.onTagsColorChange(e)},onClickClearTagsColor(e){this.groupTagsColor[e]=Lt("rgba(0,0,0,0)"),this.onTagsColorChange(e)},getTagColorStyle(e){if(e.isLora||e.isLyco||e.isEmbedding)return{};if(!this.groupTagsColorKeyCache[e.value])return{};let t=this.groupTagsColorKeyCache[e.value];if(!this.groupTagsColor[t])return{};let n=this.groupTagsColor[t];return he.isColorTransparent(n)?{}:{background:n}}}},Ww={name:"IconSvg",props:{name:{type:String,required:!0},svgName:{type:String,default:""}},data(){return{svgCode:""}},watch:{name:{handler:function(e,t){this.getSvg()},immediate:!1}},mounted(){this.getSvg()},methods:{getSvg(){if(!this.name)return;let e=this.svgName||this.name;if(window.loadingSvg=window.loadingSvg||{},window.isLoadSvg=window.isLoadSvg||{},window.isLoadSvg[e]){this.svgCode=localStorage.getItem("iconSVG-"+e);return}if(localStorage.getItem("iconSVG-"+e)&&(this.svgCode=localStorage.getItem("iconSVG-"+e)),window.loadingSvg[e]){const t=setInterval(()=>{window.loadingSvg[e]||(clearInterval(t),this.svgCode=localStorage.getItem("iconSVG-"+e))},10);return}window.loadingSvg[e]=!0,window.iconSvgHash||(window.iconSvgHash=new Date().getTime()),this.gradioAPI.styles("icons/"+e+".svg",window.iconSvgHash).then(t=>{this.svgCode=t,localStorage.setItem("iconSVG-"+e,t),window.isLoadSvg[e]=!0,window.loadingSvg[e]=!1}).catch(t=>{window.loadingSvg[e]=!1})}}},Kw=["innerHTML"];function Vw(e,t,n,r,i,o){return ge((E(),M("div",{class:Ge(["icon-svg","icon-svg-"+n.name]),"data-name":"name",innerHTML:i.svgCode},null,10,Kw)),[[Ot,i.svgCode]])}const Fn=hn(Ww,[["render",Vw]]),qw={name:"HighlightPrompt",props:{textarea:{type:Object,required:!0},hideDefaultInput:{type:Boolean,default:!1}},data(){return{scrollTop:0,showTimeId:0,hideTimeId:0,lastHighLightTag:null}},watch:{},mounted(){},methods:{show(e){this.lastHighLightTag&&this.lastHighLightTag.value===e.value||(this.lastHighLightTag=e,this.showTimeId&&clearTimeout(this.showTimeId),this.showTimeId=setTimeout(()=>{this._show(e),this.showTimeId=0},10))},_show(e){if(this.hideDefaultInput)return this._hide();if(typeof e.type=="string"&&e.type==="wrap")return this._hide();let t=e.value,n=this.textarea.value;if(t===""||t.trim()==="")return this._hide();if(n===""||n.trim()==="")return this._hide();if(t=he.escapeHtml(t),n=he.escapeHtml(this.textarea.value),n.indexOf(t)===-1)return this._hide();this.textarea.parentNode.insertBefore(this.$refs.highlightPrompt,this.textarea.nextSibling);const i=window.getComputedStyle(this.textarea);for(const l of i)this.$refs.highlightPrompt.style[l]=i[l];this.$refs.highlightPrompt.style.display="block",this.textarea.style.display="none";let o="",s=n;for(;;){const l=s.indexOf(t);if(l===-1){o+=s;break}const c=l+t.length;o+=s.substring(0,l),o+='<span class="physton-highlight-prompt">',o+=s.substring(l,c),o+="</span>",s=s.substring(c)}this.$refs.highlightPrompt.innerHTML=o,this.$refs.highlightPrompt.scrollTop=this.scrollTop},hide(){this.lastHighLightTag=null,this.showTimeId&&clearTimeout(this.showTimeId),this.hideTimeId&&clearTimeout(this.hideTimeId),this.hideTimeId=setTimeout(()=>{this._hide(),this.hideTimeId=0},10)},_hide(){this.textarea.style.display="block",this.$refs.highlightPrompt.style.display="none",this.scrollTop=this.textarea.scrollTop}}};function zw(e,t,n,r,i,o){return E(),M("div",{class:"physton-highlight-prompt",ref:"highlightPrompt",onClick:t[0]||(t[0]=(...s)=>o.hide&&o.hide(...s))},null,512)}const Gw=hn(qw,[["render",zw]]);function Yw(e){return Op()?(cC(e),!0):!1}function Js(e){return typeof e=="function"?e():Qp(e)}const Ug=typeof window<"u"&&typeof document<"u",Xw=Object.prototype.toString,Jw=e=>Xw.call(e)==="[object Object]",Zs=()=>{},Zw=Qw();function Qw(){var e;return Ug&&((e=window==null?void 0:window.navigator)==null?void 0:e.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent)}function Wg(e,t){function n(...r){return new Promise((i,o)=>{Promise.resolve(e(()=>t.apply(this,r),{fn:t,thisArg:this,args:r})).then(i).catch(o)})}return n}const Kg=e=>e();function eT(e,t={}){let n,r,i=Zs;const o=l=>{clearTimeout(l),i(),i=Zs};return l=>{const c=Js(e),d=Js(t.maxWait);return n&&o(n),c<=0||d!==void 0&&d<=0?(r&&(o(r),r=null),Promise.resolve(l())):new Promise((p,y)=>{i=t.rejectOnCancel?y:p,d&&!r&&(r=setTimeout(()=>{n&&o(n),r=null,p(l())},d)),n=setTimeout(()=>{r&&o(r),r=null,p(l())},c)})}}function tT(e=Kg){const t=Lt(!0);function n(){t.value=!1}function r(){t.value=!0}const i=(...o)=>{t.value&&e(...o)};return{isActive:ac(t),pause:n,resume:r,eventFilter:i}}function zi(e,t=200,n={}){return Wg(eT(t,n),e)}function nT(e,t,n={}){const{eventFilter:r=Kg,...i}=n;return ir(e,Wg(r,t),i)}function rT(e,t,n={}){const{eventFilter:r,...i}=n,{eventFilter:o,pause:s,resume:l,isActive:c}=tT(r);return{stop:nT(e,t,{...i,eventFilter:o}),pause:s,resume:l,isActive:c}}function No(e,t=!0){Ic()?fl(e):t?e():il(e)}function _n(e,t,n){return ir(e,(r,i,o)=>{r&&t(r,i,o)},n)}function Qs(e){var t;const n=Js(e);return(t=n==null?void 0:n.$el)!=null?t:n}const ea=Ug?window:void 0;function ta(...e){let t,n,r,i;if(typeof e[0]=="string"||Array.isArray(e[0])?([n,r,i]=e,t=ea):[t,n,r,i]=e,!t)return Zs;Array.isArray(n)||(n=[n]),Array.isArray(r)||(r=[r]);const o=[],s=()=>{o.forEach(p=>p()),o.length=0},l=(p,y,m,C)=>(p.addEventListener(y,m,C),()=>p.removeEventListener(y,m,C)),c=ir(()=>[Qs(t),Js(i)],([p,y])=>{if(s(),!p)return;const m=Jw(y)?{...y}:y;o.push(...n.flatMap(C=>r.map(b=>l(p,C,b,m))))},{immediate:!0,flush:"post"}),d=()=>{c(),s()};return Yw(d),d}let Vg=!1;function iT(e,t,n={}){const{window:r=ea,ignore:i=[],capture:o=!0,detectIframe:s=!1}=n;if(!r)return;Zw&&!Vg&&(Vg=!0,Array.from(r.document.body.children).forEach(m=>m.addEventListener("click",Zs)),r.document.documentElement.addEventListener("click",Zs));let l=!0;const c=m=>i.some(C=>{if(typeof C=="string")return Array.from(r.document.querySelectorAll(C)).some(b=>b===m.target||m.composedPath().includes(b));{const b=Qs(C);return b&&(m.target===b||m.composedPath().includes(b))}}),p=[ta(r,"click",m=>{const C=Qs(e);if(!(!C||C===m.target||m.composedPath().includes(C))){if(m.detail===0&&(l=!c(m)),!l){l=!0;return}t(m)}},{passive:!0,capture:o}),ta(r,"pointerdown",m=>{const C=Qs(e);C&&(l=!m.composedPath().includes(C)&&!c(m))},{passive:!0}),s&&ta(r,"blur",m=>{setTimeout(()=>{var C;const b=Qs(e);((C=r.document.activeElement)==null?void 0:C.tagName)==="IFRAME"&&!(b!=null&&b.contains(r.document.activeElement))&&t(m)},0)})].filter(Boolean);return()=>p.forEach(m=>m())}const $l=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},Hl="__vueuse_ssr_handlers__",oT=sT();function sT(){return Hl in $l||($l[Hl]=$l[Hl]||{}),$l[Hl]}function aT(e,t){return oT[e]||t}function lT(e){return e==null?"any":e instanceof Set?"set":e instanceof Map?"map":e instanceof Date?"date":typeof e=="boolean"?"boolean":typeof e=="string"?"string":typeof e=="object"?"object":Number.isNaN(e)?"any":"number"}const uT={boolean:{read:e=>e==="true",write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},qg="vueuse-storage";function cT(e,t,n,r={}){var i;const{flush:o="pre",deep:s=!0,listenToStorageChanges:l=!0,writeDefaults:c=!0,mergeDefaults:d=!1,shallow:p,window:y=ea,eventFilter:m,onError:C=I=>{console.error(I)}}=r,b=(p?BC:Lt)(t);if(!n)try{n=aT("getDefaultStorage",()=>{var I;return(I=ea)==null?void 0:I.localStorage})()}catch(I){C(I)}if(!n)return b;const k=Js(t),L=lT(k),O=(i=r.serializer)!=null?i:uT[L],{pause:$,resume:X}=rT(b,()=>x(b.value),{flush:o,deep:s,eventFilter:m});return y&&l&&(ta(y,"storage",g),ta(y,qg,Q)),g(),b;function x(I){try{if(I==null)n.removeItem(e);else{const A=O.write(I),D=n.getItem(e);D!==A&&(n.setItem(e,A),y&&y.dispatchEvent(new CustomEvent(qg,{detail:{key:e,oldValue:D,newValue:A,storageArea:n}})))}}catch(A){C(A)}}function z(I){const A=I?I.newValue:n.getItem(e);if(A==null)return c&&k!==null&&n.setItem(e,O.write(k)),k;if(!I&&d){const D=O.read(A);return typeof d=="function"?d(D,k):L==="object"&&!Array.isArray(D)?{...k,...D}:D}else return typeof A!="string"?A:O.read(A)}function Q(I){g(I.detail)}function g(I){if(!(I&&I.storageArea!==n)){if(I&&I.key==null){b.value=k;return}if(!(I&&I.key!==e)){$();try{(I==null?void 0:I.newValue)!==O.write(b.value)&&(b.value=z(I))}catch(A){C(A)}finally{I?il(X):X()}}}}}function rf(e,t,n={}){const{window:r=ea}=n;return cT(e,t,r==null?void 0:r.localStorage,n)}var Gi=Gi||{};Gi.stringify=function(){var e={"visit_linear-gradient":function(t){return e.visit_gradient(t)},"visit_repeating-linear-gradient":function(t){return e.visit_gradient(t)},"visit_radial-gradient":function(t){return e.visit_gradient(t)},"visit_repeating-radial-gradient":function(t){return e.visit_gradient(t)},visit_gradient:function(t){var n=e.visit(t.orientation);return n&&(n+=", "),t.type+"("+n+e.visit(t.colorStops)+")"},visit_shape:function(t){var n=t.value,r=e.visit(t.at),i=e.visit(t.style);return i&&(n+=" "+i),r&&(n+=" at "+r),n},"visit_default-radial":function(t){var n="",r=e.visit(t.at);return r&&(n+=r),n},"visit_extent-keyword":function(t){var n=t.value,r=e.visit(t.at);return r&&(n+=" at "+r),n},"visit_position-keyword":function(t){return t.value},visit_position:function(t){return e.visit(t.value.x)+" "+e.visit(t.value.y)},"visit_%":function(t){return t.value+"%"},visit_em:function(t){return t.value+"em"},visit_px:function(t){return t.value+"px"},visit_literal:function(t){return e.visit_color(t.value,t)},visit_hex:function(t){return e.visit_color("#"+t.value,t)},visit_rgb:function(t){return e.visit_color("rgb("+t.value.join(", ")+")",t)},visit_rgba:function(t){return e.visit_color("rgba("+t.value.join(", ")+")",t)},visit_color:function(t,n){var r=t,i=e.visit(n.length);return i&&(r+=" "+i),r},visit_angular:function(t){return t.value+"deg"},visit_directional:function(t){return"to "+t.value},visit_array:function(t){var n="",r=t.length;return t.forEach(function(i,o){n+=e.visit(i),o<r-1&&(n+=", ")}),n},visit:function(t){if(!t)return"";var n="";if(t instanceof Array)return e.visit_array(t,n);if(t.type){var r=e["visit_"+t.type];if(r)return r(t);throw Error("Missing visitor visit_"+t.type)}else throw Error("Invalid node.")}};return function(t){return e.visit(t)}}();var Gi=Gi||{};Gi.parse=function(){var e={linearGradient:/^(\-(webkit|o|ms|moz)\-)?(linear\-gradient)/i,repeatingLinearGradient:/^(\-(webkit|o|ms|moz)\-)?(repeating\-linear\-gradient)/i,radialGradient:/^(\-(webkit|o|ms|moz)\-)?(radial\-gradient)/i,repeatingRadialGradient:/^(\-(webkit|o|ms|moz)\-)?(repeating\-radial\-gradient)/i,sideOrCorner:/^to (left (top|bottom)|right (top|bottom)|left|right|top|bottom)/i,extentKeywords:/^(closest\-side|closest\-corner|farthest\-side|farthest\-corner|contain|cover)/,positionKeywords:/^(left|center|right|top|bottom)/i,pixelValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))px/,percentageValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))\%/,emValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))em/,angleValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))deg/,startCall:/^\(/,endCall:/^\)/,comma:/^,/,hexColor:/^\#([0-9a-fA-F]+)/,literalColor:/^([a-zA-Z]+)/,rgbColor:/^rgb/i,rgbaColor:/^rgba/i,number:/^(([0-9]*\.[0-9]+)|([0-9]+\.?))/},t="";function n(V){var ae=new Error(t+": "+V);throw ae.source=t,ae}function r(){var V=i();return t.length>0&&n("Invalid input not EOF"),V}function i(){return X(o)}function o(){return s("linear-gradient",e.linearGradient,c)||s("repeating-linear-gradient",e.repeatingLinearGradient,c)||s("radial-gradient",e.radialGradient,y)||s("repeating-radial-gradient",e.repeatingRadialGradient,y)}function s(V,ae,pe){return l(ae,function(Qe){var et=pe();return et&&(je(e.comma)||n("Missing comma before color stops")),{type:V,orientation:et,colorStops:X(x)}})}function l(V,ae){var pe=je(V);if(pe){je(e.startCall)||n("Missing (");var Qe=ae(pe);return je(e.endCall)||n("Missing )"),Qe}}function c(){return d()||p()}function d(){return de("directional",e.sideOrCorner,1)}function p(){return de("angular",e.angleValue,1)}function y(){var V,ae=m(),pe;return ae&&(V=[],V.push(ae),pe=t,je(e.comma)&&(ae=m(),ae?V.push(ae):t=pe)),V}function m(){var V=C()||b();if(V)V.at=L();else{var ae=k();if(ae){V=ae;var pe=L();pe&&(V.at=pe)}else{var Qe=O();Qe&&(V={type:"default-radial",at:Qe})}}return V}function C(){var V=de("shape",/^(circle)/i,0);return V&&(V.style=U()||k()),V}function b(){var V=de("shape",/^(ellipse)/i,0);return V&&(V.style=H()||k()),V}function k(){return de("extent-keyword",e.extentKeywords,1)}function L(){if(de("position",/^at/,0)){var V=O();return V||n("Missing positioning value"),V}}function O(){var V=$();if(V.x||V.y)return{type:"position",value:V}}function $(){return{x:H(),y:H()}}function X(V){var ae=V(),pe=[];if(ae)for(pe.push(ae);je(e.comma);)ae=V(),ae?pe.push(ae):n("One extra comma");return pe}function x(){var V=z();return V||n("Expected color definition"),V.length=H(),V}function z(){return g()||A()||I()||Q()}function Q(){return de("literal",e.literalColor,0)}function g(){return de("hex",e.hexColor,1)}function I(){return l(e.rgbColor,function(){return{type:"rgb",value:X(D)}})}function A(){return l(e.rgbaColor,function(){return{type:"rgba",value:X(D)}})}function D(){return je(e.number)[1]}function H(){return de("%",e.percentageValue,1)||K()||U()}function K(){return de("position-keyword",e.positionKeywords,1)}function U(){return de("px",e.pixelValue,1)||de("em",e.emValue,1)}function de(V,ae,pe){var Qe=je(ae);if(Qe)return{type:V,value:Qe[pe]}}function je(V){var ae,pe;return pe=/^[\n\r\t\s]+/.exec(t),pe&&Pe(pe[0].length),ae=V.exec(t),ae&&Pe(ae[0].length),ae}function Pe(V){t=t.substr(V)}return function(V){return t=V.toString(),r()}}();var fT=Gi.parse,dT=Gi.stringify,Bn="top",lr="bottom",ur="right",$n="left",of="auto",na=[Bn,lr,ur,$n],Mo="start",ra="end",pT="clippingParents",zg="viewport",ia="popper",hT="reference",Gg=na.reduce(function(e,t){return e.concat([t+"-"+Mo,t+"-"+ra])},[]),Yg=[].concat(na,[of]).reduce(function(e,t){return e.concat([t,t+"-"+Mo,t+"-"+ra])},[]),gT="beforeRead",mT="read",vT="afterRead",yT="beforeMain",bT="main",CT="afterMain",_T="beforeWrite",wT="write",TT="afterWrite",kT=[gT,mT,vT,yT,bT,CT,_T,wT,TT];function Rr(e){return e?(e.nodeName||"").toLowerCase():null}function Jn(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Yi(e){var t=Jn(e).Element;return e instanceof t||e instanceof Element}function cr(e){var t=Jn(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function sf(e){if(typeof ShadowRoot>"u")return!1;var t=Jn(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function xT(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},i=t.attributes[n]||{},o=t.elements[n];!cr(o)||!Rr(o)||(Object.assign(o.style,r),Object.keys(i).forEach(function(s){var l=i[s];l===!1?o.removeAttribute(s):o.setAttribute(s,l===!0?"":l)}))})}function ST(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(r){var i=t.elements[r],o=t.attributes[r]||{},s=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),l=s.reduce(function(c,d){return c[d]="",c},{});!cr(i)||!Rr(i)||(Object.assign(i.style,l),Object.keys(o).forEach(function(c){i.removeAttribute(c)}))})}}const Xg={name:"applyStyles",enabled:!0,phase:"write",fn:xT,effect:ST,requires:["computeStyles"]};function Nr(e){return e.split("-")[0]}var Xi=Math.max,jl=Math.min,Fo=Math.round;function af(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Jg(){return!/^((?!chrome|android).)*safari/i.test(af())}function Bo(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),i=1,o=1;t&&cr(e)&&(i=e.offsetWidth>0&&Fo(r.width)/e.offsetWidth||1,o=e.offsetHeight>0&&Fo(r.height)/e.offsetHeight||1);var s=Yi(e)?Jn(e):window,l=s.visualViewport,c=!Jg()&&n,d=(r.left+(c&&l?l.offsetLeft:0))/i,p=(r.top+(c&&l?l.offsetTop:0))/o,y=r.width/i,m=r.height/o;return{width:y,height:m,top:p,right:d+y,bottom:p+m,left:d,x:d,y:p}}function lf(e){var t=Bo(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function Zg(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&sf(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function Qr(e){return Jn(e).getComputedStyle(e)}function AT(e){return["table","td","th"].indexOf(Rr(e))>=0}function _i(e){return((Yi(e)?e.ownerDocument:e.document)||window.document).documentElement}function Ul(e){return Rr(e)==="html"?e:e.assignedSlot||e.parentNode||(sf(e)?e.host:null)||_i(e)}function Qg(e){return!cr(e)||Qr(e).position==="fixed"?null:e.offsetParent}function ET(e){var t=/firefox/i.test(af()),n=/Trident/i.test(af());if(n&&cr(e)){var r=Qr(e);if(r.position==="fixed")return null}var i=Ul(e);for(sf(i)&&(i=i.host);cr(i)&&["html","body"].indexOf(Rr(i))<0;){var o=Qr(i);if(o.transform!=="none"||o.perspective!=="none"||o.contain==="paint"||["transform","perspective"].indexOf(o.willChange)!==-1||t&&o.willChange==="filter"||t&&o.filter&&o.filter!=="none")return i;i=i.parentNode}return null}function oa(e){for(var t=Jn(e),n=Qg(e);n&&AT(n)&&Qr(n).position==="static";)n=Qg(n);return n&&(Rr(n)==="html"||Rr(n)==="body"&&Qr(n).position==="static")?t:n||ET(e)||t}function uf(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function sa(e,t,n){return Xi(e,jl(t,n))}function LT(e,t,n){var r=sa(e,t,n);return r>n?n:r}function em(){return{top:0,right:0,bottom:0,left:0}}function tm(e){return Object.assign({},em(),e)}function nm(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var OT=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,tm(typeof t!="number"?t:nm(t,na))};function IT(e){var t,n=e.state,r=e.name,i=e.options,o=n.elements.arrow,s=n.modifiersData.popperOffsets,l=Nr(n.placement),c=uf(l),d=[$n,ur].indexOf(l)>=0,p=d?"height":"width";if(!(!o||!s)){var y=OT(i.padding,n),m=lf(o),C=c==="y"?Bn:$n,b=c==="y"?lr:ur,k=n.rects.reference[p]+n.rects.reference[c]-s[c]-n.rects.popper[p],L=s[c]-n.rects.reference[c],O=oa(o),$=O?c==="y"?O.clientHeight||0:O.clientWidth||0:0,X=k/2-L/2,x=y[C],z=$-m[p]-y[b],Q=$/2-m[p]/2+X,g=sa(x,Q,z),I=c;n.modifiersData[r]=(t={},t[I]=g,t.centerOffset=g-Q,t)}}function PT(e){var t=e.state,n=e.options,r=n.element,i=r===void 0?"[data-popper-arrow]":r;i!=null&&(typeof i=="string"&&(i=t.elements.popper.querySelector(i),!i)||Zg(t.elements.popper,i)&&(t.elements.arrow=i))}const DT={name:"arrow",enabled:!0,phase:"main",fn:IT,effect:PT,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function $o(e){return e.split("-")[1]}var RT={top:"auto",right:"auto",bottom:"auto",left:"auto"};function NT(e,t){var n=e.x,r=e.y,i=t.devicePixelRatio||1;return{x:Fo(n*i)/i||0,y:Fo(r*i)/i||0}}function rm(e){var t,n=e.popper,r=e.popperRect,i=e.placement,o=e.variation,s=e.offsets,l=e.position,c=e.gpuAcceleration,d=e.adaptive,p=e.roundOffsets,y=e.isFixed,m=s.x,C=m===void 0?0:m,b=s.y,k=b===void 0?0:b,L=typeof p=="function"?p({x:C,y:k}):{x:C,y:k};C=L.x,k=L.y;var O=s.hasOwnProperty("x"),$=s.hasOwnProperty("y"),X=$n,x=Bn,z=window;if(d){var Q=oa(n),g="clientHeight",I="clientWidth";if(Q===Jn(n)&&(Q=_i(n),Qr(Q).position!=="static"&&l==="absolute"&&(g="scrollHeight",I="scrollWidth")),Q=Q,i===Bn||(i===$n||i===ur)&&o===ra){x=lr;var A=y&&Q===z&&z.visualViewport?z.visualViewport.height:Q[g];k-=A-r.height,k*=c?1:-1}if(i===$n||(i===Bn||i===lr)&&o===ra){X=ur;var D=y&&Q===z&&z.visualViewport?z.visualViewport.width:Q[I];C-=D-r.width,C*=c?1:-1}}var H=Object.assign({position:l},d&&RT),K=p===!0?NT({x:C,y:k},Jn(n)):{x:C,y:k};if(C=K.x,k=K.y,c){var U;return Object.assign({},H,(U={},U[x]=$?"0":"",U[X]=O?"0":"",U.transform=(z.devicePixelRatio||1)<=1?"translate("+C+"px, "+k+"px)":"translate3d("+C+"px, "+k+"px, 0)",U))}return Object.assign({},H,(t={},t[x]=$?k+"px":"",t[X]=O?C+"px":"",t.transform="",t))}function MT(e){var t=e.state,n=e.options,r=n.gpuAcceleration,i=r===void 0?!0:r,o=n.adaptive,s=o===void 0?!0:o,l=n.roundOffsets,c=l===void 0?!0:l,d={placement:Nr(t.placement),variation:$o(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,rm(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:s,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,rm(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const FT={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:MT,data:{}};var Wl={passive:!0};function BT(e){var t=e.state,n=e.instance,r=e.options,i=r.scroll,o=i===void 0?!0:i,s=r.resize,l=s===void 0?!0:s,c=Jn(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&d.forEach(function(p){p.addEventListener("scroll",n.update,Wl)}),l&&c.addEventListener("resize",n.update,Wl),function(){o&&d.forEach(function(p){p.removeEventListener("scroll",n.update,Wl)}),l&&c.removeEventListener("resize",n.update,Wl)}}const $T={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:BT,data:{}};var HT={left:"right",right:"left",bottom:"top",top:"bottom"};function Kl(e){return e.replace(/left|right|bottom|top/g,function(t){return HT[t]})}var jT={start:"end",end:"start"};function im(e){return e.replace(/start|end/g,function(t){return jT[t]})}function cf(e){var t=Jn(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function ff(e){return Bo(_i(e)).left+cf(e).scrollLeft}function UT(e,t){var n=Jn(e),r=_i(e),i=n.visualViewport,o=r.clientWidth,s=r.clientHeight,l=0,c=0;if(i){o=i.width,s=i.height;var d=Jg();(d||!d&&t==="fixed")&&(l=i.offsetLeft,c=i.offsetTop)}return{width:o,height:s,x:l+ff(e),y:c}}function WT(e){var t,n=_i(e),r=cf(e),i=(t=e.ownerDocument)==null?void 0:t.body,o=Xi(n.scrollWidth,n.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),s=Xi(n.scrollHeight,n.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),l=-r.scrollLeft+ff(e),c=-r.scrollTop;return Qr(i||n).direction==="rtl"&&(l+=Xi(n.clientWidth,i?i.clientWidth:0)-o),{width:o,height:s,x:l,y:c}}function df(e){var t=Qr(e),n=t.overflow,r=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+r)}function om(e){return["html","body","#document"].indexOf(Rr(e))>=0?e.ownerDocument.body:cr(e)&&df(e)?e:om(Ul(e))}function aa(e,t){var n;t===void 0&&(t=[]);var r=om(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),o=Jn(r),s=i?[o].concat(o.visualViewport||[],df(r)?r:[]):r,l=t.concat(s);return i?l:l.concat(aa(Ul(s)))}function pf(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function KT(e,t){var n=Bo(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function sm(e,t,n){return t===zg?pf(UT(e,n)):Yi(t)?KT(t,n):pf(WT(_i(e)))}function VT(e){var t=aa(Ul(e)),n=["absolute","fixed"].indexOf(Qr(e).position)>=0,r=n&&cr(e)?oa(e):e;return Yi(r)?t.filter(function(i){return Yi(i)&&Zg(i,r)&&Rr(i)!=="body"}):[]}function qT(e,t,n,r){var i=t==="clippingParents"?VT(e):[].concat(t),o=[].concat(i,[n]),s=o[0],l=o.reduce(function(c,d){var p=sm(e,d,r);return c.top=Xi(p.top,c.top),c.right=jl(p.right,c.right),c.bottom=jl(p.bottom,c.bottom),c.left=Xi(p.left,c.left),c},sm(e,s,r));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function am(e){var t=e.reference,n=e.element,r=e.placement,i=r?Nr(r):null,o=r?$o(r):null,s=t.x+t.width/2-n.width/2,l=t.y+t.height/2-n.height/2,c;switch(i){case Bn:c={x:s,y:t.y-n.height};break;case lr:c={x:s,y:t.y+t.height};break;case ur:c={x:t.x+t.width,y:l};break;case $n:c={x:t.x-n.width,y:l};break;default:c={x:t.x,y:t.y}}var d=i?uf(i):null;if(d!=null){var p=d==="y"?"height":"width";switch(o){case Mo:c[d]=c[d]-(t[p]/2-n[p]/2);break;case ra:c[d]=c[d]+(t[p]/2-n[p]/2);break}}return c}function la(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=r===void 0?e.placement:r,o=n.strategy,s=o===void 0?e.strategy:o,l=n.boundary,c=l===void 0?pT:l,d=n.rootBoundary,p=d===void 0?zg:d,y=n.elementContext,m=y===void 0?ia:y,C=n.altBoundary,b=C===void 0?!1:C,k=n.padding,L=k===void 0?0:k,O=tm(typeof L!="number"?L:nm(L,na)),$=m===ia?hT:ia,X=e.rects.popper,x=e.elements[b?$:m],z=qT(Yi(x)?x:x.contextElement||_i(e.elements.popper),c,p,s),Q=Bo(e.elements.reference),g=am({reference:Q,element:X,strategy:"absolute",placement:i}),I=pf(Object.assign({},X,g)),A=m===ia?I:Q,D={top:z.top-A.top+O.top,bottom:A.bottom-z.bottom+O.bottom,left:z.left-A.left+O.left,right:A.right-z.right+O.right},H=e.modifiersData.offset;if(m===ia&&H){var K=H[i];Object.keys(D).forEach(function(U){var de=[ur,lr].indexOf(U)>=0?1:-1,je=[Bn,lr].indexOf(U)>=0?"y":"x";D[U]+=K[je]*de})}return D}function zT(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=n.boundary,o=n.rootBoundary,s=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,d=c===void 0?Yg:c,p=$o(r),y=p?l?Gg:Gg.filter(function(b){return $o(b)===p}):na,m=y.filter(function(b){return d.indexOf(b)>=0});m.length===0&&(m=y);var C=m.reduce(function(b,k){return b[k]=la(e,{placement:k,boundary:i,rootBoundary:o,padding:s})[Nr(k)],b},{});return Object.keys(C).sort(function(b,k){return C[b]-C[k]})}function GT(e){if(Nr(e)===of)return[];var t=Kl(e);return[im(e),t,im(t)]}function YT(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var i=n.mainAxis,o=i===void 0?!0:i,s=n.altAxis,l=s===void 0?!0:s,c=n.fallbackPlacements,d=n.padding,p=n.boundary,y=n.rootBoundary,m=n.altBoundary,C=n.flipVariations,b=C===void 0?!0:C,k=n.allowedAutoPlacements,L=t.options.placement,O=Nr(L),$=O===L,X=c||($||!b?[Kl(L)]:GT(L)),x=[L].concat(X).reduce(function(xe,Ae){return xe.concat(Nr(Ae)===of?zT(t,{placement:Ae,boundary:p,rootBoundary:y,padding:d,flipVariations:b,allowedAutoPlacements:k}):Ae)},[]),z=t.rects.reference,Q=t.rects.popper,g=new Map,I=!0,A=x[0],D=0;D<x.length;D++){var H=x[D],K=Nr(H),U=$o(H)===Mo,de=[Bn,lr].indexOf(K)>=0,je=de?"width":"height",Pe=la(t,{placement:H,boundary:p,rootBoundary:y,altBoundary:m,padding:d}),V=de?U?ur:$n:U?lr:Bn;z[je]>Q[je]&&(V=Kl(V));var ae=Kl(V),pe=[];if(o&&pe.push(Pe[K]<=0),l&&pe.push(Pe[V]<=0,Pe[ae]<=0),pe.every(function(xe){return xe})){A=H,I=!1;break}g.set(H,pe)}if(I)for(var Qe=b?3:1,et=function(Ae){var Oe=x.find(function(Be){var tt=g.get(Be);if(tt)return tt.slice(0,Ae).every(function(Re){return Re})});if(Oe)return A=Oe,"break"},se=Qe;se>0;se--){var Ce=et(se);if(Ce==="break")break}t.placement!==A&&(t.modifiersData[r]._skip=!0,t.placement=A,t.reset=!0)}}const XT={name:"flip",enabled:!0,phase:"main",fn:YT,requiresIfExists:["offset"],data:{_skip:!1}};function lm(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 um(e){return[Bn,ur,lr,$n].some(function(t){return e[t]>=0})}function JT(e){var t=e.state,n=e.name,r=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,s=la(t,{elementContext:"reference"}),l=la(t,{altBoundary:!0}),c=lm(s,r),d=lm(l,i,o),p=um(c),y=um(d);t.modifiersData[n]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:p,hasPopperEscaped:y},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":p,"data-popper-escaped":y})}const ZT={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:JT};function QT(e,t,n){var r=Nr(e),i=[$n,Bn].indexOf(r)>=0?-1:1,o=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,s=o[0],l=o[1];return s=s||0,l=(l||0)*i,[$n,ur].indexOf(r)>=0?{x:l,y:s}:{x:s,y:l}}function ek(e){var t=e.state,n=e.options,r=e.name,i=n.offset,o=i===void 0?[0,0]:i,s=Yg.reduce(function(p,y){return p[y]=QT(y,t.rects,o),p},{}),l=s[t.placement],c=l.x,d=l.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[r]=s}const tk={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:ek};function nk(e){var t=e.state,n=e.name;t.modifiersData[n]=am({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const rk={name:"popperOffsets",enabled:!0,phase:"read",fn:nk,data:{}};function ik(e){return e==="x"?"y":"x"}function ok(e){var t=e.state,n=e.options,r=e.name,i=n.mainAxis,o=i===void 0?!0:i,s=n.altAxis,l=s===void 0?!1:s,c=n.boundary,d=n.rootBoundary,p=n.altBoundary,y=n.padding,m=n.tether,C=m===void 0?!0:m,b=n.tetherOffset,k=b===void 0?0:b,L=la(t,{boundary:c,rootBoundary:d,padding:y,altBoundary:p}),O=Nr(t.placement),$=$o(t.placement),X=!$,x=uf(O),z=ik(x),Q=t.modifiersData.popperOffsets,g=t.rects.reference,I=t.rects.popper,A=typeof k=="function"?k(Object.assign({},t.rects,{placement:t.placement})):k,D=typeof A=="number"?{mainAxis:A,altAxis:A}:Object.assign({mainAxis:0,altAxis:0},A),H=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,K={x:0,y:0};if(Q){if(o){var U,de=x==="y"?Bn:$n,je=x==="y"?lr:ur,Pe=x==="y"?"height":"width",V=Q[x],ae=V+L[de],pe=V-L[je],Qe=C?-I[Pe]/2:0,et=$===Mo?g[Pe]:I[Pe],se=$===Mo?-I[Pe]:-g[Pe],Ce=t.elements.arrow,xe=C&&Ce?lf(Ce):{width:0,height:0},Ae=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:em(),Oe=Ae[de],Be=Ae[je],tt=sa(0,g[Pe],xe[Pe]),Re=X?g[Pe]/2-Qe-tt-Oe-D.mainAxis:et-tt-Oe-D.mainAxis,Ve=X?-g[Pe]/2+Qe+tt+Be+D.mainAxis:se+tt+Be+D.mainAxis,dt=t.elements.arrow&&oa(t.elements.arrow),R=dt?x==="y"?dt.clientTop||0:dt.clientLeft||0:0,B=(U=H==null?void 0:H[x])!=null?U:0,Y=V+Re-B-R,oe=V+Ve-B,ee=sa(C?jl(ae,Y):ae,V,C?Xi(pe,oe):pe);Q[x]=ee,K[x]=ee-V}if(l){var te,ve=x==="x"?Bn:$n,me=x==="x"?lr:ur,be=Q[z],ce=z==="y"?"height":"width",Te=be+L[ve],_e=be-L[me],Ne=[Bn,$n].indexOf(O)!==-1,ne=(te=H==null?void 0:H[z])!=null?te:0,$e=Ne?Te:be-g[ce]-I[ce]-ne+D.altAxis,at=Ne?be+g[ce]+I[ce]-ne-D.altAxis:_e,lt=C&&Ne?LT($e,be,at):sa(C?$e:Te,be,C?at:_e);Q[z]=lt,K[z]=lt-be}t.modifiersData[r]=K}}const sk={name:"preventOverflow",enabled:!0,phase:"main",fn:ok,requiresIfExists:["offset"]};function ak(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function lk(e){return e===Jn(e)||!cr(e)?cf(e):ak(e)}function uk(e){var t=e.getBoundingClientRect(),n=Fo(t.width)/e.offsetWidth||1,r=Fo(t.height)/e.offsetHeight||1;return n!==1||r!==1}function ck(e,t,n){n===void 0&&(n=!1);var r=cr(t),i=cr(t)&&uk(t),o=_i(t),s=Bo(e,i,n),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(r||!r&&!n)&&((Rr(t)!=="body"||df(o))&&(l=lk(t)),cr(t)?(c=Bo(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):o&&(c.x=ff(o))),{x:s.left+l.scrollLeft-c.x,y:s.top+l.scrollTop-c.y,width:s.width,height:s.height}}function fk(e){var t=new Map,n=new Set,r=[];e.forEach(function(o){t.set(o.name,o)});function i(o){n.add(o.name);var s=[].concat(o.requires||[],o.requiresIfExists||[]);s.forEach(function(l){if(!n.has(l)){var c=t.get(l);c&&i(c)}}),r.push(o)}return e.forEach(function(o){n.has(o.name)||i(o)}),r}function dk(e){var t=fk(e);return kT.reduce(function(n,r){return n.concat(t.filter(function(i){return i.phase===r}))},[])}function pk(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function hk(e){var t=e.reduce(function(n,r){var i=n[r.name];return n[r.name]=i?Object.assign({},i,r,{options:Object.assign({},i.options,r.options),data:Object.assign({},i.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var cm={placement:"bottom",modifiers:[],strategy:"absolute"};function fm(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(r){return!(r&&typeof r.getBoundingClientRect=="function")})}function gk(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,r=n===void 0?[]:n,i=t.defaultOptions,o=i===void 0?cm:i;return function(l,c,d){d===void 0&&(d=o);var p={placement:"bottom",orderedModifiers:[],options:Object.assign({},cm,o),modifiersData:{},elements:{reference:l,popper:c},attributes:{},styles:{}},y=[],m=!1,C={state:p,setOptions:function(O){var $=typeof O=="function"?O(p.options):O;k(),p.options=Object.assign({},o,p.options,$),p.scrollParents={reference:Yi(l)?aa(l):l.contextElement?aa(l.contextElement):[],popper:aa(c)};var X=dk(hk([].concat(r,p.options.modifiers)));return p.orderedModifiers=X.filter(function(x){return x.enabled}),b(),C.update()},forceUpdate:function(){if(!m){var O=p.elements,$=O.reference,X=O.popper;if(fm($,X)){p.rects={reference:ck($,oa(X),p.options.strategy==="fixed"),popper:lf(X)},p.reset=!1,p.placement=p.options.placement,p.orderedModifiers.forEach(function(D){return p.modifiersData[D.name]=Object.assign({},D.data)});for(var x=0;x<p.orderedModifiers.length;x++){if(p.reset===!0){p.reset=!1,x=-1;continue}var z=p.orderedModifiers[x],Q=z.fn,g=z.options,I=g===void 0?{}:g,A=z.name;typeof Q=="function"&&(p=Q({state:p,options:I,name:A,instance:C})||p)}}}},update:pk(function(){return new Promise(function(L){C.forceUpdate(),L(p)})}),destroy:function(){k(),m=!0}};if(!fm(l,c))return C;C.setOptions(d).then(function(L){!m&&d.onFirstUpdate&&d.onFirstUpdate(L)});function b(){p.orderedModifiers.forEach(function(L){var O=L.name,$=L.options,X=$===void 0?{}:$,x=L.effect;if(typeof x=="function"){var z=x({state:p,name:O,instance:C,options:X}),Q=function(){};y.push(z||Q)}})}function k(){y.forEach(function(L){return L()}),y=[]}return C}}var mk=[$T,rk,FT,Xg,tk,XT,sk,DT,ZT],dm=gk({defaultModifiers:mk});/*!
|
||
* is-plain-object <https://github.com/jonschlinkert/is-plain-object>
|
||
*
|
||
* Copyright (c) 2014-2017, Jon Schlinkert.
|
||
* Released under the MIT License.
|
||
*/function pm(e){return Object.prototype.toString.call(e)==="[object Object]"}function vk(e){var t,n;return pm(e)===!1?!1:(t=e.constructor,t===void 0?!0:(n=t.prototype,!(pm(n)===!1||n.hasOwnProperty("isPrototypeOf")===!1)))}function ua(){return ua=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ua.apply(this,arguments)}function hm(e,t){if(e==null)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)t.indexOf(n=o[r])>=0||(i[n]=e[n]);return i}const yk={silent:!1,logLevel:"warn"},bk=["validator"],gm=Object.prototype,mm=gm.toString,Ck=gm.hasOwnProperty,vm=/^\s*function (\w+)/;function ym(e){var t;const n=(t=e==null?void 0:e.type)!==null&&t!==void 0?t:e;if(n){const r=n.toString().match(vm);return r?r[1]:""}return""}const Ji=vk;let wn=e=>e;const Ho=(e,t)=>Ck.call(e,t),_k=Number.isInteger||function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e},jo=Array.isArray||function(e){return mm.call(e)==="[object Array]"},Uo=e=>mm.call(e)==="[object Function]",Vl=e=>Ji(e)&&Ho(e,"_vueTypes_name"),bm=e=>Ji(e)&&(Ho(e,"type")||["_vueTypes_name","validator","default","required"].some(t=>Ho(e,t)));function hf(e,t){return Object.defineProperty(e.bind(t),"__original",{value:e})}function Zi(e,t,n=!1){let r,i=!0,o="";r=Ji(e)?e:{type:e};const s=Vl(r)?r._vueTypes_name+" - ":"";if(bm(r)&&r.type!==null){if(r.type===void 0||r.type===!0||!r.required&&t===void 0)return i;jo(r.type)?(i=r.type.some(l=>Zi(l,t,!0)===!0),o=r.type.map(l=>ym(l)).join(" or ")):(o=ym(r),i=o==="Array"?jo(t):o==="Object"?Ji(t):o==="String"||o==="Number"||o==="Boolean"||o==="Function"?function(l){if(l==null)return"";const c=l.constructor.toString().match(vm);return c?c[1]:""}(t)===o:t instanceof r.type)}if(!i){const l=`${s}value "${t}" should be of type "${o}"`;return n===!1?(wn(l),!1):l}if(Ho(r,"validator")&&Uo(r.validator)){const l=wn,c=[];if(wn=d=>{c.push(d)},i=r.validator(t),wn=l,!i){const d=(c.length>1?"* ":"")+c.join(`
|
||
* `);return c.length=0,n===!1?(wn(d),i):d}}return i}function Zn(e,t){const n=Object.defineProperties(t,{_vueTypes_name:{value:e,writable:!0},isRequired:{get(){return this.required=!0,this}},def:{value(i){return i===void 0?(Ho(this,"default")&&delete this.default,this):Uo(i)||Zi(this,i,!0)===!0?(this.default=jo(i)?()=>[...i]:Ji(i)?()=>Object.assign({},i):i,this):(wn(`${this._vueTypes_name} - invalid default value: "${i}"`),this)}}}),{validator:r}=n;return Uo(r)&&(n.validator=hf(r,n)),n}function Mr(e,t){const n=Zn(e,t);return Object.defineProperty(n,"validate",{value(r){return Uo(this.validator)&&wn(`${this._vueTypes_name} - calling .validate() will overwrite the current custom validator function. Validator info:
|
||
${JSON.stringify(this)}`),this.validator=hf(r,this),this}})}function Cm(e,t,n){const r=function(c){const d={};return Object.getOwnPropertyNames(c).forEach(p=>{d[p]=Object.getOwnPropertyDescriptor(c,p)}),Object.defineProperties({},d)}(t);if(r._vueTypes_name=e,!Ji(n))return r;const{validator:i}=n,o=hm(n,bk);if(Uo(i)){let{validator:c}=r;c&&(c=(l=(s=c).__original)!==null&&l!==void 0?l:s),r.validator=hf(c?function(d){return c.call(this,d)&&i.call(this,d)}:i,r)}var s,l;return Object.assign(r,o)}function ql(e){return e.replace(/^(?!\s*$)/gm," ")}const wk=()=>Mr("any",{}),Tk=()=>Mr("function",{type:Function}),kk=()=>Mr("boolean",{type:Boolean}),xk=()=>Mr("string",{type:String}),Sk=()=>Mr("number",{type:Number}),Ak=()=>Mr("array",{type:Array}),Ek=()=>Mr("object",{type:Object}),Lk=()=>Zn("integer",{type:Number,validator:e=>_k(e)}),Ok=()=>Zn("symbol",{validator:e=>typeof e=="symbol"});function Ik(e,t="custom validation failed"){if(typeof e!="function")throw new TypeError("[VueTypes error]: You must provide a function as argument");return Zn(e.name||"<<anonymous function>>",{type:null,validator(n){const r=e(n);return r||wn(`${this._vueTypes_name} - ${t}`),r}})}function Pk(e){if(!jo(e))throw new TypeError("[VueTypes error]: You must provide an array as argument.");const t=`oneOf - value should be one of "${e.join('", "')}".`,n=e.reduce((r,i)=>{if(i!=null){const o=i.constructor;r.indexOf(o)===-1&&r.push(o)}return r},[]);return Zn("oneOf",{type:n.length>0?n:void 0,validator(r){const i=e.indexOf(r)!==-1;return i||wn(t),i}})}function Dk(e){if(!jo(e))throw new TypeError("[VueTypes error]: You must provide an array as argument");let t=!1,n=[];for(let i=0;i<e.length;i+=1){const o=e[i];if(bm(o)){if(Vl(o)&&o._vueTypes_name==="oneOf"&&o.type){n=n.concat(o.type);continue}if(Uo(o.validator)&&(t=!0),o.type===!0||!o.type){wn('oneOfType - invalid usage of "true" or "null" as types.');continue}n=n.concat(o.type)}else n.push(o)}n=n.filter((i,o)=>n.indexOf(i)===o);const r=n.length>0?n:null;return Zn("oneOfType",t?{type:r,validator(i){const o=[],s=e.some(l=>{const c=Zi(Vl(l)&&l._vueTypes_name==="oneOf"?l.type||null:l,i,!0);return typeof c=="string"&&o.push(c),c===!0});return s||wn(`oneOfType - provided value does not match any of the ${o.length} passed-in validators:
|
||
${ql(o.join(`
|
||
`))}`),s}}:{type:r})}function Rk(e){return Zn("arrayOf",{type:Array,validator(t){let n="";const r=t.every(i=>(n=Zi(e,i,!0),n===!0));return r||wn(`arrayOf - value validation error:
|
||
${ql(n)}`),r}})}function Nk(e){return Zn("instanceOf",{type:e})}function Mk(e){return Zn("objectOf",{type:Object,validator(t){let n="";const r=Object.keys(t).every(i=>(n=Zi(e,t[i],!0),n===!0));return r||wn(`objectOf - value validation error:
|
||
${ql(n)}`),r}})}function Fk(e){const t=Object.keys(e),n=t.filter(i=>{var o;return!((o=e[i])===null||o===void 0||!o.required)}),r=Zn("shape",{type:Object,validator(i){if(!Ji(i))return!1;const o=Object.keys(i);if(n.length>0&&n.some(s=>o.indexOf(s)===-1)){const s=n.filter(l=>o.indexOf(l)===-1);return wn(s.length===1?`shape - required property "${s[0]}" is not defined.`:`shape - required properties "${s.join('", "')}" are not defined.`),!1}return o.every(s=>{if(t.indexOf(s)===-1)return this._vueTypes_isLoose===!0||(wn(`shape - shape definition does not include a "${s}" property. Allowed keys: "${t.join('", "')}".`),!1);const l=Zi(e[s],i[s],!0);return typeof l=="string"&&wn(`shape - "${s}" property validation error:
|
||
${ql(l)}`),l===!0})}});return Object.defineProperty(r,"_vueTypes_isLoose",{writable:!0,value:!1}),Object.defineProperty(r,"loose",{get(){return this._vueTypes_isLoose=!0,this}}),r}const Bk=["name","validate","getter"],$k=(()=>{var e;return(e=class{static get any(){return wk()}static get func(){return Tk().def(this.defaults.func)}static get bool(){return kk().def(this.defaults.bool)}static get string(){return xk().def(this.defaults.string)}static get number(){return Sk().def(this.defaults.number)}static get array(){return Ak().def(this.defaults.array)}static get object(){return Ek().def(this.defaults.object)}static get integer(){return Lk().def(this.defaults.integer)}static get symbol(){return Ok()}static get nullable(){return{type:null}}static extend(t){if(jo(t))return t.forEach(c=>this.extend(c)),this;const{name:n,validate:r=!1,getter:i=!1}=t,o=hm(t,Bk);if(Ho(this,n))throw new TypeError(`[VueTypes error]: Type "${n}" already defined`);const{type:s}=o;if(Vl(s))return delete o.type,Object.defineProperty(this,n,i?{get:()=>Cm(n,s,o)}:{value(...c){const d=Cm(n,s,o);return d.validator&&(d.validator=d.validator.bind(d,...c)),d}});let l;return l=i?{get(){const c=Object.assign({},o);return r?Mr(n,c):Zn(n,c)},enumerable:!0}:{value(...c){const d=Object.assign({},o);let p;return p=r?Mr(n,d):Zn(n,d),d.validator&&(p.validator=d.validator.bind(p,...c)),p},enumerable:!0},Object.defineProperty(this,n,l)}}).defaults={},e.sensibleDefaults=void 0,e.config=yk,e.custom=Ik,e.oneOf=Pk,e.instanceOf=Nk,e.oneOfType=Dk,e.arrayOf=Rk,e.objectOf=Mk,e.shape=Fk,e.utils={validate:(t,n)=>Zi(n,t,!0)===!0,toType:(t,n,r=!1)=>r?Mr(t,n):Zn(t,n)},e})();function Hk(e={func:()=>{},bool:!0,string:"",number:0,array:()=>[],object:()=>({}),integer:0}){var t;return(t=class extends $k{static get sensibleDefaults(){return ua({},this.defaults)}static set sensibleDefaults(n){this.defaults=n!==!1?ua({},n!==!0?n:e):{}}}).defaults=ua({},e),t}let rt=class extends Hk(){};var _m=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function gf(e){var t={exports:{}};return e(t,t.exports),t.exports}var zl=function(e){return e&&e.Math==Math&&e},on=zl(typeof globalThis=="object"&&globalThis)||zl(typeof window=="object"&&window)||zl(typeof self=="object"&&self)||zl(typeof _m=="object"&&_m)||function(){return this}()||Function("return this")(),Dt=function(e){try{return!!e()}catch{return!0}},fr=!Dt(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7}),wm={}.propertyIsEnumerable,Tm=Object.getOwnPropertyDescriptor,jk={f:Tm&&!wm.call({1:2},1)?function(e){var t=Tm(this,e);return!!t&&t.enumerable}:wm},Gl=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}},Uk={}.toString,ei=function(e){return Uk.call(e).slice(8,-1)},Wk="".split,Yl=Dt(function(){return!Object("z").propertyIsEnumerable(0)})?function(e){return ei(e)=="String"?Wk.call(e,""):Object(e)}:Object,wi=function(e){if(e==null)throw TypeError("Can't call method on "+e);return e},Wo=function(e){return Yl(wi(e))},cn=function(e){return typeof e=="object"?e!==null:typeof e=="function"},mf=function(e,t){if(!cn(e))return e;var n,r;if(t&&typeof(n=e.toString)=="function"&&!cn(r=n.call(e))||typeof(n=e.valueOf)=="function"&&!cn(r=n.call(e))||!t&&typeof(n=e.toString)=="function"&&!cn(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")},Kk={}.hasOwnProperty,Jt=function(e,t){return Kk.call(e,t)},vf=on.document,Vk=cn(vf)&&cn(vf.createElement),km=function(e){return Vk?vf.createElement(e):{}},xm=!fr&&!Dt(function(){return Object.defineProperty(km("div"),"a",{get:function(){return 7}}).a!=7}),Sm=Object.getOwnPropertyDescriptor,yf={f:fr?Sm:function(e,t){if(e=Wo(e),t=mf(t,!0),xm)try{return Sm(e,t)}catch{}if(Jt(e,t))return Gl(!jk.f.call(e,t),e[t])}},Ln=function(e){if(!cn(e))throw TypeError(String(e)+" is not an object");return e},Am=Object.defineProperty,ti={f:fr?Am:function(e,t,n){if(Ln(e),t=mf(t,!0),Ln(n),xm)try{return Am(e,t,n)}catch{}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},dr=fr?function(e,t,n){return ti.f(e,t,Gl(1,n))}:function(e,t,n){return e[t]=n,e},bf=function(e,t){try{dr(on,e,t)}catch{on[e]=t}return t},Qi=on["__core-js_shared__"]||bf("__core-js_shared__",{}),qk=Function.toString;typeof Qi.inspectSource!="function"&&(Qi.inspectSource=function(e){return qk.call(e)});var Xl,ca,Jl,Em=Qi.inspectSource,Lm=on.WeakMap,zk=typeof Lm=="function"&&/native code/.test(Em(Lm)),Om=gf(function(e){(e.exports=function(t,n){return Qi[t]||(Qi[t]=n!==void 0?n:{})})("versions",[]).push({version:"3.8.3",mode:"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"})}),Gk=0,Yk=Math.random(),Cf=function(e){return"Symbol("+String(e===void 0?"":e)+")_"+(++Gk+Yk).toString(36)},Im=Om("keys"),_f=function(e){return Im[e]||(Im[e]=Cf(e))},Zl={},Xk=on.WeakMap;if(zk){var Ko=Qi.state||(Qi.state=new Xk),Jk=Ko.get,Zk=Ko.has,Qk=Ko.set;Xl=function(e,t){return t.facade=e,Qk.call(Ko,e,t),t},ca=function(e){return Jk.call(Ko,e)||{}},Jl=function(e){return Zk.call(Ko,e)}}else{var fa=_f("state");Zl[fa]=!0,Xl=function(e,t){return t.facade=e,dr(e,fa,t),t},ca=function(e){return Jt(e,fa)?e[fa]:{}},Jl=function(e){return Jt(e,fa)}}var Ti={set:Xl,get:ca,has:Jl,enforce:function(e){return Jl(e)?ca(e):Xl(e,{})},getterFor:function(e){return function(t){var n;if(!cn(t)||(n=ca(t)).type!==e)throw TypeError("Incompatible receiver, "+e+" required");return n}}},ki=gf(function(e){var t=Ti.get,n=Ti.enforce,r=String(String).split("String");(e.exports=function(i,o,s,l){var c,d=!!l&&!!l.unsafe,p=!!l&&!!l.enumerable,y=!!l&&!!l.noTargetGet;typeof s=="function"&&(typeof o!="string"||Jt(s,"name")||dr(s,"name",o),(c=n(s)).source||(c.source=r.join(typeof o=="string"?o:""))),i!==on?(d?!y&&i[o]&&(p=!0):delete i[o],p?i[o]=s:dr(i,o,s)):p?i[o]=s:bf(o,s)})(Function.prototype,"toString",function(){return typeof this=="function"&&t(this).source||Em(this)})}),wf=on,Pm=function(e){return typeof e=="function"?e:void 0},Ql=function(e,t){return arguments.length<2?Pm(wf[e])||Pm(on[e]):wf[e]&&wf[e][t]||on[e]&&on[e][t]},ex=Math.ceil,tx=Math.floor,Vo=function(e){return isNaN(e=+e)?0:(e>0?tx:ex)(e)},nx=Math.min,Qn=function(e){return e>0?nx(Vo(e),9007199254740991):0},rx=Math.max,ix=Math.min,eu=function(e,t){var n=Vo(e);return n<0?rx(n+t,0):ix(n,t)},Dm=function(e){return function(t,n,r){var i,o=Wo(t),s=Qn(o.length),l=eu(r,s);if(e&&n!=n){for(;s>l;)if((i=o[l++])!=i)return!0}else for(;s>l;l++)if((e||l in o)&&o[l]===n)return e||l||0;return!e&&-1}},Rm={includes:Dm(!0),indexOf:Dm(!1)},ox=Rm.indexOf,Nm=function(e,t){var n,r=Wo(e),i=0,o=[];for(n in r)!Jt(Zl,n)&&Jt(r,n)&&o.push(n);for(;t.length>i;)Jt(r,n=t[i++])&&(~ox(o,n)||o.push(n));return o},tu=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],sx=tu.concat("length","prototype"),ax={f:Object.getOwnPropertyNames||function(e){return Nm(e,sx)}},lx={f:Object.getOwnPropertySymbols},ux=Ql("Reflect","ownKeys")||function(e){var t=ax.f(Ln(e)),n=lx.f;return n?t.concat(n(e)):t},cx=function(e,t){for(var n=ux(t),r=ti.f,i=yf.f,o=0;o<n.length;o++){var s=n[o];Jt(e,s)||r(e,s,i(t,s))}},fx=/#|\.prototype\./,da=function(e,t){var n=px[dx(e)];return n==gx||n!=hx&&(typeof t=="function"?Dt(t):!!t)},dx=da.normalize=function(e){return String(e).replace(fx,".").toLowerCase()},px=da.data={},hx=da.NATIVE="N",gx=da.POLYFILL="P",Tf=da,mx=yf.f,Tn=function(e,t){var n,r,i,o,s,l=e.target,c=e.global,d=e.stat;if(n=c?on:d?on[l]||bf(l,{}):(on[l]||{}).prototype)for(r in t){if(o=t[r],i=e.noTargetGet?(s=mx(n,r))&&s.value:n[r],!Tf(c?r:l+(d?".":"#")+r,e.forced)&&i!==void 0){if(typeof o==typeof i)continue;cx(o,i)}(e.sham||i&&i.sham)&&dr(o,"sham",!0),ki(n,r,o,e)}},kf=function(e,t){var n=[][e];return!!n&&Dt(function(){n.call(null,t||function(){throw 1},1)})},vx=Object.defineProperty,xf={},Mm=function(e){throw e},qo=function(e,t){if(Jt(xf,e))return xf[e];t||(t={});var n=[][e],r=!!Jt(t,"ACCESSORS")&&t.ACCESSORS,i=Jt(t,0)?t[0]:Mm,o=Jt(t,1)?t[1]:void 0;return xf[e]=!!n&&!Dt(function(){if(r&&!fr)return!0;var s={length:-1};r?vx(s,1,{enumerable:!0,get:Mm}):s[1]=1,n.call(s,i,o)})},yx=Rm.indexOf,Fm=[].indexOf,Bm=!!Fm&&1/[1].indexOf(1,-0)<0,bx=kf("indexOf"),Cx=qo("indexOf",{ACCESSORS:!0,1:0});function eo(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $m(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function to(e,t,n){return t&&$m(e.prototype,t),n&&$m(e,n),e}Tn({target:"Array",proto:!0,forced:Bm||!bx||!Cx},{indexOf:function(e){return Bm?Fm.apply(this,arguments)||0:yx(this,e,arguments.length>1?arguments[1]:void 0)}}),function(){function e(){eo(this,e)}return to(e,null,[{key:"isInBrowser",value:function(){return typeof window<"u"}},{key:"isServer",value:function(){return typeof window>"u"}},{key:"getUA",value:function(){return e.isInBrowser()?window.navigator.userAgent.toLowerCase():""}},{key:"isMobile",value:function(){return/Mobile|mini|Fennec|Android|iP(ad|od|hone)/.test(navigator.appVersion)}},{key:"isOpera",value:function(){return navigator.userAgent.indexOf("Opera")!==-1}},{key:"isIE",value:function(){var t=e.getUA();return t!==""&&t.indexOf("msie")>0}},{key:"isIE9",value:function(){var t=e.getUA();return t!==""&&t.indexOf("msie 9.0")>0}},{key:"isEdge",value:function(){var t=e.getUA();return t!==""&&t.indexOf("edge/")>0}},{key:"isChrome",value:function(){var t=e.getUA();return t!==""&&/chrome\/\d+/.test(t)&&!e.isEdge()}},{key:"isPhantomJS",value:function(){var t=e.getUA();return t!==""&&/phantomjs/.test(t)}},{key:"isFirefox",value:function(){var t=e.getUA();return t!==""&&/firefox/.test(t)}}]),e}();var _x=[].join,wx=Yl!=Object,Tx=kf("join",",");Tn({target:"Array",proto:!0,forced:wx||!Tx},{join:function(e){return _x.call(Wo(this),e===void 0?",":e)}});var zo,nu,ni=function(e){return Object(wi(e))},Go=Array.isArray||function(e){return ei(e)=="Array"},Hm=!!Object.getOwnPropertySymbols&&!Dt(function(){return!String(Symbol())}),kx=Hm&&!Symbol.sham&&typeof Symbol.iterator=="symbol",ru=Om("wks"),pa=on.Symbol,xx=kx?pa:pa&&pa.withoutSetter||Cf,Wt=function(e){return Jt(ru,e)||(Hm&&Jt(pa,e)?ru[e]=pa[e]:ru[e]=xx("Symbol."+e)),ru[e]},Sx=Wt("species"),iu=function(e,t){var n;return Go(e)&&(typeof(n=e.constructor)!="function"||n!==Array&&!Go(n.prototype)?cn(n)&&(n=n[Sx])===null&&(n=void 0):n=void 0),new(n===void 0?Array:n)(t===0?0:t)},Yo=function(e,t,n){var r=mf(t);r in e?ti.f(e,r,Gl(0,n)):e[r]=n},Sf=Ql("navigator","userAgent")||"",jm=on.process,Um=jm&&jm.versions,Wm=Um&&Um.v8;Wm?nu=(zo=Wm.split("."))[0]+zo[1]:Sf&&(!(zo=Sf.match(/Edge\/(\d+)/))||zo[1]>=74)&&(zo=Sf.match(/Chrome\/(\d+)/))&&(nu=zo[1]);var ou=nu&&+nu,Ax=Wt("species"),Af=function(e){return ou>=51||!Dt(function(){var t=[];return(t.constructor={})[Ax]=function(){return{foo:1}},t[e](Boolean).foo!==1})},Ex=Af("splice"),Lx=qo("splice",{ACCESSORS:!0,0:0,1:2}),Ox=Math.max,Ix=Math.min;Tn({target:"Array",proto:!0,forced:!Ex||!Lx},{splice:function(e,t){var n,r,i,o,s,l,c=ni(this),d=Qn(c.length),p=eu(e,d),y=arguments.length;if(y===0?n=r=0:y===1?(n=0,r=d-p):(n=y-2,r=Ix(Ox(Vo(t),0),d-p)),d+n-r>9007199254740991)throw TypeError("Maximum allowed length exceeded");for(i=iu(c,r),o=0;o<r;o++)(s=p+o)in c&&Yo(i,o,c[s]);if(i.length=r,n<r){for(o=p;o<d-r;o++)l=o+n,(s=o+r)in c?c[l]=c[s]:delete c[l];for(o=d;o>d-r+n;o--)delete c[o-1]}else if(n>r)for(o=d-r;o>p;o--)l=o+n-1,(s=o+r-1)in c?c[l]=c[s]:delete c[l];for(o=0;o<n;o++)c[o+p]=arguments[o+2];return c.length=d-r+n,i}});var Km={};Km[Wt("toStringTag")]="z";var Ef=String(Km)==="[object z]",Px=Wt("toStringTag"),Dx=ei(function(){return arguments}())=="Arguments",Vm=Ef?ei:function(e){var t,n,r;return e===void 0?"Undefined":e===null?"Null":typeof(n=function(i,o){try{return i[o]}catch{}}(t=Object(e),Px))=="string"?n:Dx?ei(t):(r=ei(t))=="Object"&&typeof t.callee=="function"?"Arguments":r},Rx=Ef?{}.toString:function(){return"[object "+Vm(this)+"]"};Ef||ki(Object.prototype,"toString",Rx,{unsafe:!0});var qm=function(){var e=Ln(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t};function zm(e,t){return RegExp(e,t)}var Lf,Of,Gm={UNSUPPORTED_Y:Dt(function(){var e=zm("a","y");return e.lastIndex=2,e.exec("abcd")!=null}),BROKEN_CARET:Dt(function(){var e=zm("^r","gy");return e.lastIndex=2,e.exec("str")!=null})},su=RegExp.prototype.exec,Nx=String.prototype.replace,Ym=su,If=(Lf=/a/,Of=/b*/g,su.call(Lf,"a"),su.call(Of,"a"),Lf.lastIndex!==0||Of.lastIndex!==0),Xm=Gm.UNSUPPORTED_Y||Gm.BROKEN_CARET,Pf=/()??/.exec("")[1]!==void 0;(If||Pf||Xm)&&(Ym=function(e){var t,n,r,i,o=this,s=Xm&&o.sticky,l=qm.call(o),c=o.source,d=0,p=e;return s&&((l=l.replace("y","")).indexOf("g")===-1&&(l+="g"),p=String(e).slice(o.lastIndex),o.lastIndex>0&&(!o.multiline||o.multiline&&e[o.lastIndex-1]!==`
|
||
`)&&(c="(?: "+c+")",p=" "+p,d++),n=new RegExp("^(?:"+c+")",l)),Pf&&(n=new RegExp("^"+c+"$(?!\\s)",l)),If&&(t=o.lastIndex),r=su.call(s?n:o,p),s?r?(r.input=r.input.slice(d),r[0]=r[0].slice(d),r.index=o.lastIndex,o.lastIndex+=r[0].length):o.lastIndex=0:If&&r&&(o.lastIndex=o.global?r.index+r[0].length:t),Pf&&r&&r.length>1&&Nx.call(r[0],n,function(){for(i=1;i<arguments.length-2;i++)arguments[i]===void 0&&(r[i]=void 0)}),r});var ha=Ym;Tn({target:"RegExp",proto:!0,forced:/./.exec!==ha},{exec:ha});var Jm=RegExp.prototype,Zm=Jm.toString,Mx=Dt(function(){return Zm.call({source:"a",flags:"b"})!="/a/b"}),Fx=Zm.name!="toString";(Mx||Fx)&&ki(RegExp.prototype,"toString",function(){var e=Ln(this),t=String(e.source),n=e.flags;return"/"+t+"/"+String(n===void 0&&e instanceof RegExp&&!("flags"in Jm)?qm.call(e):n)},{unsafe:!0});var Bx=Wt("species"),$x=!Dt(function(){var e=/./;return e.exec=function(){var t=[];return t.groups={a:"7"},t},"".replace(e,"$<a>")!=="7"}),Qm="a".replace(/./,"$0")==="$0",ev=Wt("replace"),tv=!!/./[ev]&&/./[ev]("a","$0")==="",Hx=!Dt(function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var n="ab".split(e);return n.length!==2||n[0]!=="a"||n[1]!=="b"}),nv=function(e,t,n,r){var i=Wt(e),o=!Dt(function(){var y={};return y[i]=function(){return 7},""[e](y)!=7}),s=o&&!Dt(function(){var y=!1,m=/a/;return e==="split"&&((m={}).constructor={},m.constructor[Bx]=function(){return m},m.flags="",m[i]=/./[i]),m.exec=function(){return y=!0,null},m[i](""),!y});if(!o||!s||e==="replace"&&(!$x||!Qm||tv)||e==="split"&&!Hx){var l=/./[i],c=n(i,""[e],function(y,m,C,b,k){return m.exec===ha?o&&!k?{done:!0,value:l.call(m,C,b)}:{done:!0,value:y.call(C,m,b)}:{done:!1}},{REPLACE_KEEPS_$0:Qm,REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE:tv}),d=c[0],p=c[1];ki(String.prototype,e,d),ki(RegExp.prototype,i,t==2?function(y,m){return p.call(y,this,m)}:function(y){return p.call(y,this)})}r&&dr(RegExp.prototype[i],"sham",!0)},jx=Wt("match"),rv=function(e){var t;return cn(e)&&((t=e[jx])!==void 0?!!t:ei(e)=="RegExp")},Df=function(e){if(typeof e!="function")throw TypeError(String(e)+" is not a function");return e},Ux=Wt("species"),iv=function(e){return function(t,n){var r,i,o=String(wi(t)),s=Vo(n),l=o.length;return s<0||s>=l?e?"":void 0:(r=o.charCodeAt(s))<55296||r>56319||s+1===l||(i=o.charCodeAt(s+1))<56320||i>57343?e?o.charAt(s):r:e?o.slice(s,s+2):i-56320+(r-55296<<10)+65536}},ov={codeAt:iv(!1),charAt:iv(!0)},Wx=ov.charAt,sv=function(e,t,n){return t+(n?Wx(e,t).length:1)},Rf=function(e,t){var n=e.exec;if(typeof n=="function"){var r=n.call(e,t);if(typeof r!="object")throw TypeError("RegExp exec method returned something other than an Object or null");return r}if(ei(e)!=="RegExp")throw TypeError("RegExp#exec called on incompatible receiver");return ha.call(e,t)},Kx=[].push,Vx=Math.min,Xo=!Dt(function(){return!RegExp(4294967295,"y")});nv("split",2,function(e,t,n){var r;return r="abbc".split(/(b)*/)[1]=="c"||"test".split(/(?:)/,-1).length!=4||"ab".split(/(?:ab)*/).length!=2||".".split(/(.?)(.?)/).length!=4||".".split(/()()/).length>1||"".split(/.?/).length?function(i,o){var s=String(wi(this)),l=o===void 0?4294967295:o>>>0;if(l===0)return[];if(i===void 0)return[s];if(!rv(i))return t.call(s,i,l);for(var c,d,p,y=[],m=(i.ignoreCase?"i":"")+(i.multiline?"m":"")+(i.unicode?"u":"")+(i.sticky?"y":""),C=0,b=new RegExp(i.source,m+"g");(c=ha.call(b,s))&&!((d=b.lastIndex)>C&&(y.push(s.slice(C,c.index)),c.length>1&&c.index<s.length&&Kx.apply(y,c.slice(1)),p=c[0].length,C=d,y.length>=l));)b.lastIndex===c.index&&b.lastIndex++;return C===s.length?!p&&b.test("")||y.push(""):y.push(s.slice(C)),y.length>l?y.slice(0,l):y}:"0".split(void 0,0).length?function(i,o){return i===void 0&&o===0?[]:t.call(this,i,o)}:t,[function(i,o){var s=wi(this),l=i==null?void 0:i[e];return l!==void 0?l.call(i,s,o):r.call(String(s),i,o)},function(i,o){var s=n(r,i,this,o,r!==t);if(s.done)return s.value;var l=Ln(i),c=String(this),d=function(x,z){var Q,g=Ln(x).constructor;return g===void 0||(Q=Ln(g)[Ux])==null?z:Df(Q)}(l,RegExp),p=l.unicode,y=(l.ignoreCase?"i":"")+(l.multiline?"m":"")+(l.unicode?"u":"")+(Xo?"y":"g"),m=new d(Xo?l:"^(?:"+l.source+")",y),C=o===void 0?4294967295:o>>>0;if(C===0)return[];if(c.length===0)return Rf(m,c)===null?[c]:[];for(var b=0,k=0,L=[];k<c.length;){m.lastIndex=Xo?k:0;var O,$=Rf(m,Xo?c:c.slice(k));if($===null||(O=Vx(Qn(m.lastIndex+(Xo?0:k)),c.length))===b)k=sv(c,k,p);else{if(L.push(c.slice(b,k)),L.length===C)return L;for(var X=1;X<=$.length-1;X++)if(L.push($[X]),L.length===C)return L;k=b=O}}return L.push(c.slice(b)),L}]},!Xo);var Nf=`
|
||
\v\f\r \u2028\u2029\uFEFF`,au="["+Nf+"]",qx=RegExp("^"+au+au+"*"),zx=RegExp(au+au+"*$"),Mf=function(e){return function(t){var n=String(wi(t));return 1&e&&(n=n.replace(qx,"")),2&e&&(n=n.replace(zx,"")),n}},Gx={start:Mf(1),end:Mf(2),trim:Mf(3)},Yx=Gx.trim;Tn({target:"String",proto:!0,forced:function(e){return Dt(function(){return!!Nf[e]()||"
"[e]()!="
"||Nf[e].name!==e})}("trim")},{trim:function(){return Yx(this)}});var Xx=Af("slice"),Jx=qo("slice",{ACCESSORS:!0,0:0,1:2}),Zx=Wt("species"),Qx=[].slice,eS=Math.max;Tn({target:"Array",proto:!0,forced:!Xx||!Jx},{slice:function(e,t){var n,r,i,o=Wo(this),s=Qn(o.length),l=eu(e,s),c=eu(t===void 0?s:t,s);if(Go(o)&&(typeof(n=o.constructor)!="function"||n!==Array&&!Go(n.prototype)?cn(n)&&(n=n[Zx])===null&&(n=void 0):n=void 0,n===Array||n===void 0))return Qx.call(o,l,c);for(r=new(n===void 0?Array:n)(eS(c-l,0)),i=0;l<c;l++,i++)l in o&&Yo(r,i,o[l]);return r.length=i,r}});var Ff=Object.keys||function(e){return Nm(e,tu)},tS=Dt(function(){Ff(1)});Tn({target:"Object",stat:!0,forced:tS},{keys:function(e){return Ff(ni(e))}});var Bf,nS=function(e){if(rv(e))throw TypeError("The method doesn't accept regular expressions");return e},rS=Wt("match"),iS=yf.f,av="".startsWith,oS=Math.min,lv=function(e){var t=/./;try{"/./"[e](t)}catch{try{return t[rS]=!1,"/./"[e](t)}catch{}}return!1}("startsWith"),sS=!(lv||(Bf=iS(String.prototype,"startsWith"),!Bf||Bf.writable));function uv(e){return(uv=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(e)}Tn({target:"String",proto:!0,forced:!sS&&!lv},{startsWith:function(e){var t=String(wi(this));nS(e);var n=Qn(oS(arguments.length>1?arguments[1]:void 0,t.length)),r=String(e);return av?av.call(t,r,n):t.slice(n,n+r.length)===r}});var Jo=function(e){return typeof e=="string"},Zo=function(e){return e!==null&&uv(e)==="object"},Qo=function(){function e(){eo(this,e)}return to(e,null,[{key:"isWindow",value:function(t){return t===window}},{key:"addEventListener",value:function(t,n,r){var i=arguments.length>3&&arguments[3]!==void 0&&arguments[3];t&&n&&r&&t.addEventListener(n,r,i)}},{key:"removeEventListener",value:function(t,n,r){var i=arguments.length>3&&arguments[3]!==void 0&&arguments[3];t&&n&&r&&t.removeEventListener(n,r,i)}},{key:"triggerDragEvent",value:function(t,n){var r=!1,i=function(s){var l;(l=n.drag)===null||l===void 0||l.call(n,s)},o=function s(l){var c;e.removeEventListener(document,"mousemove",i),e.removeEventListener(document,"mouseup",s),document.onselectstart=null,document.ondragstart=null,r=!1,(c=n.end)===null||c===void 0||c.call(n,l)};e.addEventListener(t,"mousedown",function(s){var l;r||(document.onselectstart=function(){return!1},document.ondragstart=function(){return!1},e.addEventListener(document,"mousemove",i),e.addEventListener(document,"mouseup",o),r=!0,(l=n.start)===null||l===void 0||l.call(n,s))})}},{key:"getBoundingClientRect",value:function(t){return t&&Zo(t)&&t.nodeType===1?t.getBoundingClientRect():null}},{key:"hasClass",value:function(t,n){return!!(t&&Zo(t)&&Jo(n)&&t.nodeType===1)&&t.classList.contains(n.trim())}},{key:"addClass",value:function(t,n){if(t&&Zo(t)&&Jo(n)&&t.nodeType===1&&(n=n.trim(),!e.hasClass(t,n))){var r=t.className;t.className=r?r+" "+n:n}}},{key:"removeClass",value:function(t,n){if(t&&Zo(t)&&Jo(n)&&t.nodeType===1&&typeof t.className=="string"){n=n.trim();for(var r=t.className.trim().split(" "),i=r.length-1;i>=0;i--)r[i]=r[i].trim(),r[i]&&r[i]!==n||r.splice(i,1);t.className=r.join(" ")}}},{key:"toggleClass",value:function(t,n,r){t&&Zo(t)&&Jo(n)&&t.nodeType===1&&t.classList.toggle(n,r)}},{key:"replaceClass",value:function(t,n,r){t&&Zo(t)&&Jo(n)&&Jo(r)&&t.nodeType===1&&(n=n.trim(),r=r.trim(),e.removeClass(t,n),e.addClass(t,r))}},{key:"getScrollTop",value:function(t){var n="scrollTop"in t?t.scrollTop:t.pageYOffset;return Math.max(n,0)}},{key:"setScrollTop",value:function(t,n){"scrollTop"in t?t.scrollTop=n:t.scrollTo(t.scrollX,n)}},{key:"getRootScrollTop",value:function(){return window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0}},{key:"setRootScrollTop",value:function(t){e.setScrollTop(window,t),e.setScrollTop(document.body,t)}},{key:"getElementTop",value:function(t,n){if(e.isWindow(t))return 0;var r=n?e.getScrollTop(n):e.getRootScrollTop();return t.getBoundingClientRect().top+r}},{key:"getVisibleHeight",value:function(t){return e.isWindow(t)?t.innerHeight:t.getBoundingClientRect().height}},{key:"isHidden",value:function(t){if(!t)return!1;var n=window.getComputedStyle(t),r=n.display==="none",i=t.offsetParent===null&&n.position!=="fixed";return r||i}},{key:"triggerEvent",value:function(t,n){if("createEvent"in document){var r=document.createEvent("HTMLEvents");r.initEvent(n,!1,!0),t.dispatchEvent(r)}}},{key:"calcAngle",value:function(t,n){var r=t.getBoundingClientRect(),i=r.left+r.width/2,o=r.top+r.height/2,s=Math.abs(i-n.clientX),l=Math.abs(o-n.clientY),c=l/Math.sqrt(Math.pow(s,2)+Math.pow(l,2)),d=Math.acos(c),p=Math.floor(180/(Math.PI/d));return n.clientX>i&&n.clientY>o&&(p=180-p),n.clientX==i&&n.clientY>o&&(p=180),n.clientX>i&&n.clientY==o&&(p=90),n.clientX<i&&n.clientY>o&&(p=180+p),n.clientX<i&&n.clientY==o&&(p=270),n.clientX<i&&n.clientY<o&&(p=360-p),p}},{key:"querySelector",value:function(t,n){return n?n.querySelector(t):document.querySelector(t)}},{key:"createElement",value:function(t){for(var n=document.createElement(t),r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];for(var s=0;s<i.length;s++)i[s]&&n.classList.add(i[s]);return n}},{key:"appendChild",value:function(t){for(var n=0;n<(arguments.length<=1?0:arguments.length-1);n++)t.appendChild(n+1<1||arguments.length<=n+1?void 0:arguments[n+1])}},{key:"getWindow",value:function(t){if(t.toString()!=="[object Window]"){var n=t.ownerDocument;return n&&n.defaultView||window}return t}},{key:"isElement",value:function(t){return t instanceof this.getWindow(t).Element||t instanceof Element}},{key:"isHTMLElement",value:function(t){return t instanceof this.getWindow(t).HTMLElement||t instanceof HTMLElement}},{key:"isShadowRoot",value:function(t){return typeof ShadowRoot<"u"&&(t instanceof this.getWindow(t).ShadowRoot||t instanceof ShadowRoot)}},{key:"getWindowScroll",value:function(t){var n=this.getWindow(t);return{scrollLeft:n.pageXOffset||0,scrollTop:n.pageYOffset||0}}}]),e}(),aS=Math.floor,lS="".replace,uS=/\$([$&'`]|\d\d?|<[^>]*>)/g,cS=/\$([$&'`]|\d\d?)/g,fS=function(e,t,n,r,i,o){var s=n+e.length,l=r.length,c=cS;return i!==void 0&&(i=ni(i),c=uS),lS.call(o,c,function(d,p){var y;switch(p.charAt(0)){case"$":return"$";case"&":return e;case"`":return t.slice(0,n);case"'":return t.slice(s);case"<":y=i[p.slice(1,-1)];break;default:var m=+p;if(m===0)return d;if(m>l){var C=aS(m/10);return C===0?d:C<=l?r[C-1]===void 0?p.charAt(1):r[C-1]+p.charAt(1):d}y=r[m-1]}return y===void 0?"":y})},dS=Math.max,pS=Math.min;nv("replace",2,function(e,t,n,r){var i=r.REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE,o=r.REPLACE_KEEPS_$0,s=i?"$":"$0";return[function(l,c){var d=wi(this),p=l==null?void 0:l[e];return p!==void 0?p.call(l,d,c):t.call(String(d),l,c)},function(l,c){if(!i&&o||typeof c=="string"&&c.indexOf(s)===-1){var d=n(t,l,this,c);if(d.done)return d.value}var p=Ln(l),y=String(this),m=typeof c=="function";m||(c=String(c));var C=p.global;if(C){var b=p.unicode;p.lastIndex=0}for(var k=[];;){var L=Rf(p,y);if(L===null||(k.push(L),!C))break;String(L[0])===""&&(p.lastIndex=sv(y,Qn(p.lastIndex),b))}for(var O,$="",X=0,x=0;x<k.length;x++){L=k[x];for(var z=String(L[0]),Q=dS(pS(Vo(L.index),y.length),0),g=[],I=1;I<L.length;I++)g.push((O=L[I])===void 0?O:String(O));var A=L.groups;if(m){var D=[z].concat(g,Q,y);A!==void 0&&D.push(A);var H=String(c.apply(void 0,D))}else H=fS(z,y,Q,g,A,c);Q>=X&&($+=y.slice(X,Q)+H,X=Q+z.length)}return $+y.slice(X)}]}),function(){function e(){eo(this,e)}return to(e,null,[{key:"camelize",value:function(t){return t.replace(/-(\w)/g,function(n,r){return r?r.toUpperCase():""})}},{key:"capitalize",value:function(t){return t.charAt(0).toUpperCase()+t.slice(1)}}]),e}(),function(){function e(){eo(this,e)}return to(e,null,[{key:"_clone",value:function(){}}]),e}();var cv=Wt("isConcatSpreadable"),hS=ou>=51||!Dt(function(){var e=[];return e[cv]=!1,e.concat()[0]!==e}),gS=Af("concat"),mS=function(e){if(!cn(e))return!1;var t=e[cv];return t!==void 0?!!t:Go(e)};Tn({target:"Array",proto:!0,forced:!hS||!gS},{concat:function(e){var t,n,r,i,o,s=ni(this),l=iu(s,0),c=0;for(t=-1,r=arguments.length;t<r;t++)if(mS(o=t===-1?s:arguments[t])){if(c+(i=Qn(o.length))>9007199254740991)throw TypeError("Maximum allowed index exceeded");for(n=0;n<i;n++,c++)n in o&&Yo(l,c,o[n])}else{if(c>=9007199254740991)throw TypeError("Maximum allowed index exceeded");Yo(l,c++,o)}return l.length=c,l}});var $f,ga=function(e,t,n){if(Df(e),t===void 0)return e;switch(n){case 0:return function(){return e.call(t)};case 1:return function(r){return e.call(t,r)};case 2:return function(r,i){return e.call(t,r,i)};case 3:return function(r,i,o){return e.call(t,r,i,o)}}return function(){return e.apply(t,arguments)}},fv=[].push,xi=function(e){var t=e==1,n=e==2,r=e==3,i=e==4,o=e==6,s=e==7,l=e==5||o;return function(c,d,p,y){for(var m,C,b=ni(c),k=Yl(b),L=ga(d,p,3),O=Qn(k.length),$=0,X=y||iu,x=t?X(c,O):n||s?X(c,0):void 0;O>$;$++)if((l||$ in k)&&(C=L(m=k[$],$,b),e))if(t)x[$]=C;else if(C)switch(e){case 3:return!0;case 5:return m;case 6:return $;case 2:fv.call(x,m)}else switch(e){case 4:return!1;case 7:fv.call(x,m)}return o?-1:r||i?i:x}},dv={forEach:xi(0),map:xi(1),filter:xi(2),some:xi(3),every:xi(4),find:xi(5),findIndex:xi(6),filterOut:xi(7)},vS=fr?Object.defineProperties:function(e,t){Ln(e);for(var n,r=Ff(t),i=r.length,o=0;i>o;)ti.f(e,n=r[o++],t[n]);return e},yS=Ql("document","documentElement"),pv=_f("IE_PROTO"),Hf=function(){},hv=function(e){return"<script>"+e+"<\/script>"},lu=function(){try{$f=document.domain&&new ActiveXObject("htmlfile")}catch{}var e,t;lu=$f?function(r){r.write(hv("")),r.close();var i=r.parentWindow.Object;return r=null,i}($f):((t=km("iframe")).style.display="none",yS.appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write(hv("document.F=Object")),e.close(),e.F);for(var n=tu.length;n--;)delete lu.prototype[tu[n]];return lu()};Zl[pv]=!0;var jf=Object.create||function(e,t){var n;return e!==null?(Hf.prototype=Ln(e),n=new Hf,Hf.prototype=null,n[pv]=e):n=lu(),t===void 0?n:vS(n,t)},Uf=Wt("unscopables"),Wf=Array.prototype;Wf[Uf]==null&&ti.f(Wf,Uf,{configurable:!0,value:jf(null)});var es=function(e){Wf[Uf][e]=!0},bS=dv.find,gv=!0,CS=qo("find");"find"in[]&&Array(1).find(function(){gv=!1}),Tn({target:"Array",proto:!0,forced:gv||!CS},{find:function(e){return bS(this,e,arguments.length>1?arguments[1]:void 0)}}),es("find");var _S=dv.findIndex,mv=!0,wS=qo("findIndex");"findIndex"in[]&&Array(1).findIndex(function(){mv=!1}),Tn({target:"Array",proto:!0,forced:mv||!wS},{findIndex:function(e){return _S(this,e,arguments.length>1?arguments[1]:void 0)}}),es("findIndex");var vv=function(e,t,n,r,i,o,s,l){for(var c,d=i,p=0,y=!!s&&ga(s,l,3);p<r;){if(p in n){if(c=y?y(n[p],p,t):n[p],o>0&&Go(c))d=vv(e,t,c,Qn(c.length),d,o-1)-1;else{if(d>=9007199254740991)throw TypeError("Exceed the acceptable array length");e[d]=c}d++}p++}return d},TS=vv;Tn({target:"Array",proto:!0},{flat:function(){var e=arguments.length?arguments[0]:void 0,t=ni(this),n=Qn(t.length),r=iu(t,0);return r.length=TS(r,t,t,n,0,e===void 0?1:Vo(e)),r}});var Kf=function(e){var t=e.return;if(t!==void 0)return Ln(t.call(e)).value},kS=function(e,t,n,r){try{return r?t(Ln(n)[0],n[1]):t(n)}catch(i){throw Kf(e),i}},ts={},xS=Wt("iterator"),SS=Array.prototype,yv=function(e){return e!==void 0&&(ts.Array===e||SS[xS]===e)},AS=Wt("iterator"),bv=function(e){if(e!=null)return e[AS]||e["@@iterator"]||ts[Vm(e)]},Cv=Wt("iterator"),_v=!1;try{var ES=0,wv={next:function(){return{done:!!ES++}},return:function(){_v=!0}};wv[Cv]=function(){return this},Array.from(wv,function(){throw 2})}catch{}var Tv=function(e,t){if(!t&&!_v)return!1;var n=!1;try{var r={};r[Cv]=function(){return{next:function(){return{done:n=!0}}}},e(r)}catch{}return n},LS=!Tv(function(e){Array.from(e)});Tn({target:"Array",stat:!0,forced:LS},{from:function(e){var t,n,r,i,o,s,l=ni(e),c=typeof this=="function"?this:Array,d=arguments.length,p=d>1?arguments[1]:void 0,y=p!==void 0,m=bv(l),C=0;if(y&&(p=ga(p,d>2?arguments[2]:void 0,2)),m==null||c==Array&&yv(m))for(n=new c(t=Qn(l.length));t>C;C++)s=y?p(l[C],C):l[C],Yo(n,C,s);else for(o=(i=m.call(l)).next,n=new c;!(r=o.call(i)).done;C++)s=y?kS(i,p,[r.value,C],!0):r.value,Yo(n,C,s);return n.length=C,n}});var kv=function(e){return function(t,n,r,i){Df(n);var o=ni(t),s=Yl(o),l=Qn(o.length),c=e?l-1:0,d=e?-1:1;if(r<2)for(;;){if(c in s){i=s[c],c+=d;break}if(c+=d,e?c<0:l<=c)throw TypeError("Reduce of empty array with no initial value")}for(;e?c>=0:l>c;c+=d)c in s&&(i=n(i,s[c],c,o));return i}},OS={left:kv(!1),right:kv(!0)},IS=ei(on.process)=="process",PS=OS.left,DS=kf("reduce"),RS=qo("reduce",{1:0});Tn({target:"Array",proto:!0,forced:!DS||!RS||!IS&&ou>79&&ou<83},{reduce:function(e){return PS(this,e,arguments.length,arguments.length>1?arguments[1]:void 0)}}),es("flat");var no,xv,Sv,NS=!Dt(function(){return Object.isExtensible(Object.preventExtensions({}))}),Av=gf(function(e){var t=ti.f,n=Cf("meta"),r=0,i=Object.isExtensible||function(){return!0},o=function(l){t(l,n,{value:{objectID:"O"+ ++r,weakData:{}}})},s=e.exports={REQUIRED:!1,fastKey:function(l,c){if(!cn(l))return typeof l=="symbol"?l:(typeof l=="string"?"S":"P")+l;if(!Jt(l,n)){if(!i(l))return"F";if(!c)return"E";o(l)}return l[n].objectID},getWeakData:function(l,c){if(!Jt(l,n)){if(!i(l))return!0;if(!c)return!1;o(l)}return l[n].weakData},onFreeze:function(l){return NS&&s.REQUIRED&&i(l)&&!Jt(l,n)&&o(l),l}};Zl[n]=!0}),ma=function(e,t){this.stopped=e,this.result=t},Ev=function(e,t,n){var r,i,o,s,l,c,d,p=n&&n.that,y=!(!n||!n.AS_ENTRIES),m=!(!n||!n.IS_ITERATOR),C=!(!n||!n.INTERRUPTED),b=ga(t,p,1+y+C),k=function(O){return r&&Kf(r),new ma(!0,O)},L=function(O){return y?(Ln(O),C?b(O[0],O[1],k):b(O[0],O[1])):C?b(O,k):b(O)};if(m)r=e;else{if(typeof(i=bv(e))!="function")throw TypeError("Target is not iterable");if(yv(i)){for(o=0,s=Qn(e.length);s>o;o++)if((l=L(e[o]))&&l instanceof ma)return l;return new ma(!1)}r=i.call(e)}for(c=r.next;!(d=c.call(r)).done;){try{l=L(d.value)}catch(O){throw Kf(r),O}if(typeof l=="object"&&l&&l instanceof ma)return l}return new ma(!1)},Lv=function(e,t,n){if(!(e instanceof t))throw TypeError("Incorrect "+(n?n+" ":"")+"invocation");return e},MS=ti.f,Ov=Wt("toStringTag"),Vf=function(e,t,n){e&&!Jt(e=n?e:e.prototype,Ov)&&MS(e,Ov,{configurable:!0,value:t})},uu=Object.setPrototypeOf||("__proto__"in{}?function(){var e,t=!1,n={};try{(e=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(n,[]),t=n instanceof Array}catch{}return function(r,i){return Ln(r),function(o){if(!cn(o)&&o!==null)throw TypeError("Can't set "+String(o)+" as a prototype")}(i),t?e.call(r,i):r.__proto__=i,r}}():void 0),Iv=function(e,t,n){for(var r in t)ki(e,r,t[r],n);return e},FS=!Dt(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}),Pv=_f("IE_PROTO"),BS=Object.prototype,cu=FS?Object.getPrototypeOf:function(e){return e=ni(e),Jt(e,Pv)?e[Pv]:typeof e.constructor=="function"&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?BS:null},qf=Wt("iterator"),Dv=!1;[].keys&&("next"in(Sv=[].keys())?(xv=cu(cu(Sv)))!==Object.prototype&&(no=xv):Dv=!0),(no==null||Dt(function(){var e={};return no[qf].call(e)!==e}))&&(no={}),Jt(no,qf)||dr(no,qf,function(){return this});var zf={IteratorPrototype:no,BUGGY_SAFARI_ITERATORS:Dv},$S=zf.IteratorPrototype,HS=function(){return this},Gf=zf.IteratorPrototype,fu=zf.BUGGY_SAFARI_ITERATORS,va=Wt("iterator"),jS=function(){return this},Yf=function(e,t,n,r,i,o,s){(function(O,$,X){var x=$+" Iterator";O.prototype=jf($S,{next:Gl(1,X)}),Vf(O,x,!1),ts[x]=HS})(n,t,r);var l,c,d,p=function(O){if(O===i&&k)return k;if(!fu&&O in C)return C[O];switch(O){case"keys":case"values":case"entries":return function(){return new n(this,O)}}return function(){return new n(this)}},y=t+" Iterator",m=!1,C=e.prototype,b=C[va]||C["@@iterator"]||i&&C[i],k=!fu&&b||p(i),L=t=="Array"&&C.entries||b;if(L&&(l=cu(L.call(new e)),Gf!==Object.prototype&&l.next&&(cu(l)!==Gf&&(uu?uu(l,Gf):typeof l[va]!="function"&&dr(l,va,jS)),Vf(l,y,!0))),i=="values"&&b&&b.name!=="values"&&(m=!0,k=function(){return b.call(this)}),C[va]!==k&&dr(C,va,k),ts[t]=k,i)if(c={values:p("values"),keys:o?k:p("keys"),entries:p("entries")},s)for(d in c)(fu||m||!(d in C))&&ki(C,d,c[d]);else Tn({target:t,proto:!0,forced:fu||m},c);return c},Rv=Wt("species"),US=ti.f,Nv=Av.fastKey,Mv=Ti.set,Xf=Ti.getterFor;(function(e,t,n){var r=e.indexOf("Map")!==-1,i=e.indexOf("Weak")!==-1,o=r?"set":"add",s=on[e],l=s&&s.prototype,c=s,d={},p=function(L){var O=l[L];ki(l,L,L=="add"?function($){return O.call(this,$===0?0:$),this}:L=="delete"?function($){return!(i&&!cn($))&&O.call(this,$===0?0:$)}:L=="get"?function($){return i&&!cn($)?void 0:O.call(this,$===0?0:$)}:L=="has"?function($){return!(i&&!cn($))&&O.call(this,$===0?0:$)}:function($,X){return O.call(this,$===0?0:$,X),this})};if(Tf(e,typeof s!="function"||!(i||l.forEach&&!Dt(function(){new s().entries().next()}))))c=n.getConstructor(t,e,r,o),Av.REQUIRED=!0;else if(Tf(e,!0)){var y=new c,m=y[o](i?{}:-0,1)!=y,C=Dt(function(){y.has(1)}),b=Tv(function(L){new s(L)}),k=!i&&Dt(function(){for(var L=new s,O=5;O--;)L[o](O,O);return!L.has(-0)});b||((c=t(function(L,O){Lv(L,c,e);var $=function(X,x,z){var Q,g;return uu&&typeof(Q=x.constructor)=="function"&&Q!==z&&cn(g=Q.prototype)&&g!==z.prototype&&uu(X,g),X}(new s,L,c);return O!=null&&Ev(O,$[o],{that:$,AS_ENTRIES:r}),$})).prototype=l,l.constructor=c),(C||k)&&(p("delete"),p("has"),r&&p("get")),(k||m)&&p(o),i&&l.clear&&delete l.clear}d[e]=c,Tn({global:!0,forced:c!=s},d),Vf(c,e),i||n.setStrong(c,e,r)})("Set",function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}},{getConstructor:function(e,t,n,r){var i=e(function(c,d){Lv(c,i,t),Mv(c,{type:t,index:jf(null),first:void 0,last:void 0,size:0}),fr||(c.size=0),d!=null&&Ev(d,c[r],{that:c,AS_ENTRIES:n})}),o=Xf(t),s=function(c,d,p){var y,m,C=o(c),b=l(c,d);return b?b.value=p:(C.last=b={index:m=Nv(d,!0),key:d,value:p,previous:y=C.last,next:void 0,removed:!1},C.first||(C.first=b),y&&(y.next=b),fr?C.size++:c.size++,m!=="F"&&(C.index[m]=b)),c},l=function(c,d){var p,y=o(c),m=Nv(d);if(m!=="F")return y.index[m];for(p=y.first;p;p=p.next)if(p.key==d)return p};return Iv(i.prototype,{clear:function(){for(var c=o(this),d=c.index,p=c.first;p;)p.removed=!0,p.previous&&(p.previous=p.previous.next=void 0),delete d[p.index],p=p.next;c.first=c.last=void 0,fr?c.size=0:this.size=0},delete:function(c){var d=this,p=o(d),y=l(d,c);if(y){var m=y.next,C=y.previous;delete p.index[y.index],y.removed=!0,C&&(C.next=m),m&&(m.previous=C),p.first==y&&(p.first=m),p.last==y&&(p.last=C),fr?p.size--:d.size--}return!!y},forEach:function(c){for(var d,p=o(this),y=ga(c,arguments.length>1?arguments[1]:void 0,3);d=d?d.next:p.first;)for(y(d.value,d.key,this);d&&d.removed;)d=d.previous},has:function(c){return!!l(this,c)}}),Iv(i.prototype,n?{get:function(c){var d=l(this,c);return d&&d.value},set:function(c,d){return s(this,c===0?0:c,d)}}:{add:function(c){return s(this,c=c===0?0:c,c)}}),fr&&US(i.prototype,"size",{get:function(){return o(this).size}}),i},setStrong:function(e,t,n){var r=t+" Iterator",i=Xf(t),o=Xf(r);Yf(e,t,function(s,l){Mv(this,{type:r,target:s,state:i(s),kind:l,last:void 0})},function(){for(var s=o(this),l=s.kind,c=s.last;c&&c.removed;)c=c.previous;return s.target&&(s.last=c=c?c.next:s.state.first)?l=="keys"?{value:c.key,done:!1}:l=="values"?{value:c.value,done:!1}:{value:[c.key,c.value],done:!1}:(s.target=void 0,{value:void 0,done:!0})},n?"entries":"values",!n,!0),function(s){var l=Ql(s),c=ti.f;fr&&l&&!l[Rv]&&c(l,Rv,{configurable:!0,get:function(){return this}})}(t)}});var WS=ov.charAt,KS=Ti.set,VS=Ti.getterFor("String Iterator");Yf(String,"String",function(e){KS(this,{type:"String Iterator",string:String(e),index:0})},function(){var e,t=VS(this),n=t.string,r=t.index;return r>=n.length?{value:void 0,done:!0}:(e=WS(n,r),t.index+=e.length,{value:e,done:!1})});var Fv={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0},qS=Ti.set,zS=Ti.getterFor("Array Iterator"),ya=Yf(Array,"Array",function(e,t){qS(this,{type:"Array Iterator",target:Wo(e),index:0,kind:t})},function(){var e=zS(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?(e.target=void 0,{value:void 0,done:!0}):n=="keys"?{value:r,done:!1}:n=="values"?{value:t[r],done:!1}:{value:[r,t[r]],done:!1}},"values");ts.Arguments=ts.Array,es("keys"),es("values"),es("entries");var Jf=Wt("iterator"),Bv=Wt("toStringTag"),Zf=ya.values;for(var Qf in Fv){var $v=on[Qf],ri=$v&&$v.prototype;if(ri){if(ri[Jf]!==Zf)try{dr(ri,Jf,Zf)}catch{ri[Jf]=Zf}if(ri[Bv]||dr(ri,Bv,Qf),Fv[Qf]){for(var ns in ya)if(ri[ns]!==ya[ns])try{dr(ri,ns,ya[ns])}catch{ri[ns]=ya[ns]}}}}(function(){function e(){eo(this,e)}return to(e,null,[{key:"deduplicate",value:function(t){return Array.from(new Set(t))}},{key:"flat",value:function(t){return t.reduce(function(n,r){var i=Array.isArray(r)?e.flat(r):r;return n.concat(i)},[])}},{key:"find",value:function(t,n){return t.find(n)}},{key:"findIndex",value:function(t,n){return t.findIndex(n)}}]),e})(),function(){function e(){eo(this,e)}return to(e,null,[{key:"today",value:function(){return new Date}}]),e}(),function(){function e(){eo(this,e)}return to(e,null,[{key:"range",value:function(t,n,r){return Math.min(Math.max(t,n),r)}},{key:"clamp",value:function(t,n,r){return n<r?t<n?n:t>r?r:t:t<r?r:t>n?n:t}}]),e}();var GS=typeof global=="object"&&global&&global.Object===Object&&global;const Hv=GS;var YS=typeof self=="object"&&self&&self.Object===Object&&self,XS=Hv||YS||Function("return this")();const rs=XS;var JS=rs.Symbol;const du=JS;var jv=Object.prototype,ZS=jv.hasOwnProperty,QS=jv.toString,ba=du?du.toStringTag:void 0;function eA(e){var t=ZS.call(e,ba),n=e[ba];try{e[ba]=void 0;var r=!0}catch{}var i=QS.call(e);return r&&(t?e[ba]=n:delete e[ba]),i}var tA=Object.prototype,nA=tA.toString;function rA(e){return nA.call(e)}var iA="[object Null]",oA="[object Undefined]",Uv=du?du.toStringTag:void 0;function pu(e){return e==null?e===void 0?oA:iA:Uv&&Uv in Object(e)?eA(e):rA(e)}function Ca(e){return e!=null&&typeof e=="object"}var sA=Array.isArray;const ed=sA;function ro(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}function Wv(e){return e}var aA="[object AsyncFunction]",lA="[object Function]",uA="[object GeneratorFunction]",cA="[object Proxy]";function td(e){if(!ro(e))return!1;var t=pu(e);return t==lA||t==uA||t==aA||t==cA}var fA=rs["__core-js_shared__"];const nd=fA;var Kv=function(){var e=/[^.]+$/.exec(nd&&nd.keys&&nd.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function dA(e){return!!Kv&&Kv in e}var pA=Function.prototype,hA=pA.toString;function gA(e){if(e!=null){try{return hA.call(e)}catch{}try{return e+""}catch{}}return""}var mA=/[\\^$.*+?()[\]{}|]/g,vA=/^\[object .+?Constructor\]$/,yA=Function.prototype,bA=Object.prototype,CA=yA.toString,_A=bA.hasOwnProperty,wA=RegExp("^"+CA.call(_A).replace(mA,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function TA(e){if(!ro(e)||dA(e))return!1;var t=td(e)?wA:vA;return t.test(gA(e))}function kA(e,t){return e==null?void 0:e[t]}function rd(e,t){var n=kA(e,t);return TA(n)?n:void 0}var Vv=Object.create,xA=function(){function e(){}return function(t){if(!ro(t))return{};if(Vv)return Vv(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();const SA=xA;function AA(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 EA(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}var LA=800,OA=16,IA=Date.now;function PA(e){var t=0,n=0;return function(){var r=IA(),i=OA-(r-n);if(n=r,i>0){if(++t>=LA)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function DA(e){return function(){return e}}var RA=function(){try{var e=rd(Object,"defineProperty");return e({},"",{}),e}catch{}}();const hu=RA;var NA=hu?function(e,t){return hu(e,"toString",{configurable:!0,enumerable:!1,value:DA(t),writable:!0})}:Wv,MA=PA(NA);const FA=MA;var BA=9007199254740991,$A=/^(?:0|[1-9]\d*)$/;function qv(e,t){var n=typeof e;return t=t??BA,!!t&&(n=="number"||n!="symbol"&&$A.test(e))&&e>-1&&e%1==0&&e<t}function id(e,t,n){t=="__proto__"&&hu?hu(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function gu(e,t){return e===t||e!==e&&t!==t}var HA=Object.prototype,jA=HA.hasOwnProperty;function UA(e,t,n){var r=e[t];(!(jA.call(e,t)&&gu(r,n))||n===void 0&&!(t in e))&&id(e,t,n)}function WA(e,t,n,r){var i=!n;n||(n={});for(var o=-1,s=t.length;++o<s;){var l=t[o],c=r?r(n[l],e[l],l,n,e):void 0;c===void 0&&(c=e[l]),i?id(n,l,c):UA(n,l,c)}return n}var zv=Math.max;function KA(e,t,n){return t=zv(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,o=zv(r.length-t,0),s=Array(o);++i<o;)s[i]=r[t+i];i=-1;for(var l=Array(t+1);++i<t;)l[i]=r[i];return l[t]=n(s),AA(e,this,l)}}function VA(e,t){return FA(KA(e,t,Wv),e+"")}var qA=9007199254740991;function Gv(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=qA}function od(e){return e!=null&&Gv(e.length)&&!td(e)}function zA(e,t,n){if(!ro(n))return!1;var r=typeof t;return(r=="number"?od(n)&&qv(t,n.length):r=="string"&&t in n)?gu(n[t],e):!1}function GA(e){return VA(function(t,n){var r=-1,i=n.length,o=i>1?n[i-1]:void 0,s=i>2?n[2]:void 0;for(o=e.length>3&&typeof o=="function"?(i--,o):void 0,s&&zA(n[0],n[1],s)&&(o=i<3?void 0:o,i=1),t=Object(t);++r<i;){var l=n[r];l&&e(t,l,r,o)}return t})}var YA=Object.prototype;function Yv(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||YA;return e===n}function XA(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var JA="[object Arguments]";function Xv(e){return Ca(e)&&pu(e)==JA}var Jv=Object.prototype,ZA=Jv.hasOwnProperty,QA=Jv.propertyIsEnumerable,eE=Xv(function(){return arguments}())?Xv:function(e){return Ca(e)&&ZA.call(e,"callee")&&!QA.call(e,"callee")};const sd=eE;function tE(){return!1}var Zv=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Qv=Zv&&typeof module=="object"&&module&&!module.nodeType&&module,nE=Qv&&Qv.exports===Zv,ey=nE?rs.Buffer:void 0,rE=ey?ey.isBuffer:void 0,iE=rE||tE;const ty=iE;var oE="[object Arguments]",sE="[object Array]",aE="[object Boolean]",lE="[object Date]",uE="[object Error]",cE="[object Function]",fE="[object Map]",dE="[object Number]",pE="[object Object]",hE="[object RegExp]",gE="[object Set]",mE="[object String]",vE="[object WeakMap]",yE="[object ArrayBuffer]",bE="[object DataView]",CE="[object Float32Array]",_E="[object Float64Array]",wE="[object Int8Array]",TE="[object Int16Array]",kE="[object Int32Array]",xE="[object Uint8Array]",SE="[object Uint8ClampedArray]",AE="[object Uint16Array]",EE="[object Uint32Array]",Rt={};Rt[CE]=Rt[_E]=Rt[wE]=Rt[TE]=Rt[kE]=Rt[xE]=Rt[SE]=Rt[AE]=Rt[EE]=!0,Rt[oE]=Rt[sE]=Rt[yE]=Rt[aE]=Rt[bE]=Rt[lE]=Rt[uE]=Rt[cE]=Rt[fE]=Rt[dE]=Rt[pE]=Rt[hE]=Rt[gE]=Rt[mE]=Rt[vE]=!1;function LE(e){return Ca(e)&&Gv(e.length)&&!!Rt[pu(e)]}function OE(e){return function(t){return e(t)}}var ny=typeof exports=="object"&&exports&&!exports.nodeType&&exports,_a=ny&&typeof module=="object"&&module&&!module.nodeType&&module,IE=_a&&_a.exports===ny,ad=IE&&Hv.process,PE=function(){try{var e=_a&&_a.require&&_a.require("util").types;return e||ad&&ad.binding&&ad.binding("util")}catch{}}();const ry=PE;var iy=ry&&ry.isTypedArray,DE=iy?OE(iy):LE;const oy=DE;var RE=Object.prototype,NE=RE.hasOwnProperty;function ME(e,t){var n=ed(e),r=!n&&sd(e),i=!n&&!r&&ty(e),o=!n&&!r&&!i&&oy(e),s=n||r||i||o,l=s?XA(e.length,String):[],c=l.length;for(var d in e)(t||NE.call(e,d))&&!(s&&(d=="length"||i&&(d=="offset"||d=="parent")||o&&(d=="buffer"||d=="byteLength"||d=="byteOffset")||qv(d,c)))&&l.push(d);return l}function FE(e,t){return function(n){return e(t(n))}}function BE(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var $E=Object.prototype,HE=$E.hasOwnProperty;function jE(e){if(!ro(e))return BE(e);var t=Yv(e),n=[];for(var r in e)r=="constructor"&&(t||!HE.call(e,r))||n.push(r);return n}function sy(e){return od(e)?ME(e,!0):jE(e)}var UE=rd(Object,"create");const wa=UE;function WE(){this.__data__=wa?wa(null):{},this.size=0}function KE(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var VE="__lodash_hash_undefined__",qE=Object.prototype,zE=qE.hasOwnProperty;function GE(e){var t=this.__data__;if(wa){var n=t[e];return n===VE?void 0:n}return zE.call(t,e)?t[e]:void 0}var YE=Object.prototype,XE=YE.hasOwnProperty;function JE(e){var t=this.__data__;return wa?t[e]!==void 0:XE.call(t,e)}var ZE="__lodash_hash_undefined__";function QE(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=wa&&t===void 0?ZE:t,this}function io(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}io.prototype.clear=WE,io.prototype.delete=KE,io.prototype.get=GE,io.prototype.has=JE,io.prototype.set=QE;function eL(){this.__data__=[],this.size=0}function mu(e,t){for(var n=e.length;n--;)if(gu(e[n][0],t))return n;return-1}var tL=Array.prototype,nL=tL.splice;function rL(e){var t=this.__data__,n=mu(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():nL.call(t,n,1),--this.size,!0}function iL(e){var t=this.__data__,n=mu(t,e);return n<0?void 0:t[n][1]}function oL(e){return mu(this.__data__,e)>-1}function sL(e,t){var n=this.__data__,r=mu(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function ii(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}ii.prototype.clear=eL,ii.prototype.delete=rL,ii.prototype.get=iL,ii.prototype.has=oL,ii.prototype.set=sL;var aL=rd(rs,"Map");const ay=aL;function lL(){this.size=0,this.__data__={hash:new io,map:new(ay||ii),string:new io}}function uL(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function vu(e,t){var n=e.__data__;return uL(t)?n[typeof t=="string"?"string":"hash"]:n.map}function cL(e){var t=vu(this,e).delete(e);return this.size-=t?1:0,t}function fL(e){return vu(this,e).get(e)}function dL(e){return vu(this,e).has(e)}function pL(e,t){var n=vu(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function is(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}is.prototype.clear=lL,is.prototype.delete=cL,is.prototype.get=fL,is.prototype.has=dL,is.prototype.set=pL;var hL=FE(Object.getPrototypeOf,Object);const ly=hL;var gL="[object Object]",mL=Function.prototype,vL=Object.prototype,uy=mL.toString,yL=vL.hasOwnProperty,bL=uy.call(Object);function CL(e){if(!Ca(e)||pu(e)!=gL)return!1;var t=ly(e);if(t===null)return!0;var n=yL.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&uy.call(n)==bL}function _L(){this.__data__=new ii,this.size=0}function wL(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function TL(e){return this.__data__.get(e)}function kL(e){return this.__data__.has(e)}var xL=200;function SL(e,t){var n=this.__data__;if(n instanceof ii){var r=n.__data__;if(!ay||r.length<xL-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new is(r)}return n.set(e,t),this.size=n.size,this}function os(e){var t=this.__data__=new ii(e);this.size=t.size}os.prototype.clear=_L,os.prototype.delete=wL,os.prototype.get=TL,os.prototype.has=kL,os.prototype.set=SL;var cy=typeof exports=="object"&&exports&&!exports.nodeType&&exports,fy=cy&&typeof module=="object"&&module&&!module.nodeType&&module,AL=fy&&fy.exports===cy,dy=AL?rs.Buffer:void 0,py=dy?dy.allocUnsafe:void 0;function EL(e,t){if(t)return e.slice();var n=e.length,r=py?py(n):new e.constructor(n);return e.copy(r),r}var LL=rs.Uint8Array;const hy=LL;function OL(e){var t=new e.constructor(e.byteLength);return new hy(t).set(new hy(e)),t}function IL(e,t){var n=t?OL(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function PL(e){return typeof e.constructor=="function"&&!Yv(e)?SA(ly(e)):{}}function DL(e){return function(t,n,r){for(var i=-1,o=Object(t),s=r(t),l=s.length;l--;){var c=s[e?l:++i];if(n(o[c],c,o)===!1)break}return t}}var RL=DL();const NL=RL;function ld(e,t,n){(n!==void 0&&!gu(e[t],n)||n===void 0&&!(t in e))&&id(e,t,n)}function ML(e){return Ca(e)&&od(e)}function ud(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function FL(e){return WA(e,sy(e))}function BL(e,t,n,r,i,o,s){var l=ud(e,n),c=ud(t,n),d=s.get(c);if(d){ld(e,n,d);return}var p=o?o(l,c,n+"",e,t,s):void 0,y=p===void 0;if(y){var m=ed(c),C=!m&&ty(c),b=!m&&!C&&oy(c);p=c,m||C||b?ed(l)?p=l:ML(l)?p=EA(l):C?(y=!1,p=EL(c,!0)):b?(y=!1,p=IL(c,!0)):p=[]:CL(c)||sd(c)?(p=l,sd(l)?p=FL(l):(!ro(l)||td(l))&&(p=PL(c))):y=!1}y&&(s.set(c,p),i(p,c,r,o,s),s.delete(c)),ld(e,n,p)}function gy(e,t,n,r,i){e!==t&&NL(t,function(o,s){if(i||(i=new os),ro(o))BL(e,t,s,n,gy,r,i);else{var l=r?r(ud(e,s),o,s+"",e,t,i):void 0;l===void 0&&(l=o),ld(e,s,l)}},sy)}var $L=GA(function(e,t,n){gy(e,t,n)});const yu=$L;var HL=Object.defineProperty,jL=(e,t,n)=>t in e?HL(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kn=(e,t,n)=>(jL(e,typeof t!="symbol"?t+"":t,n),n);const zt=e=>Math.round(e*100)/100;class Kt{constructor(t){kn(this,"instance"),kn(this,"alphaValue",0),kn(this,"redValue",0),kn(this,"greenValue",0),kn(this,"blueValue",0),kn(this,"hueValue",0),kn(this,"saturationValue",0),kn(this,"brightnessValue",0),kn(this,"hslSaturationValue",0),kn(this,"lightnessValue",0),kn(this,"initAlpha",()=>{const n=this.instance.getAlpha();this.alphaValue=Math.min(1,n)*100}),kn(this,"initLightness",()=>{const{s:n,l:r}=this.instance.toHsl();this.hslSaturationValue=zt(n),this.lightnessValue=zt(r)}),kn(this,"initRgb",()=>{const{r:n,g:r,b:i}=this.instance.toRgb();this.redValue=zt(n),this.greenValue=zt(r),this.blueValue=zt(i)}),kn(this,"initHsb",()=>{const{h:n,s:r,v:i}=this.instance.toHsv();this.hueValue=Math.min(360,Math.ceil(n)),this.saturationValue=zt(r),this.brightnessValue=zt(i)}),kn(this,"toHexString",()=>this.instance.toHexString()),kn(this,"toRgbString",()=>this.instance.toRgbString()),this.instance=Ie(t),this.initRgb(),this.initHsb(),this.initLightness(),this.initAlpha()}toString(t){return this.instance.toString(t)}get hex(){return this.instance.toHex()}set hex(t){this.instance=Ie(t),this.initHsb(),this.initRgb(),this.initAlpha(),this.initLightness()}set hue(t){this.saturation===0&&this.brightness===0&&(this.saturationValue=1,this.brightnessValue=1),this.instance=Ie({h:zt(t),s:this.saturation,v:this.brightness,a:this.alphaValue/100}),this.initRgb(),this.initLightness(),this.hueValue=zt(t)}get hue(){return this.hueValue}set saturation(t){this.instance=Ie({h:this.hue,s:zt(t),v:this.brightness,a:this.alphaValue/100}),this.initRgb(),this.initLightness(),this.saturationValue=zt(t)}get saturation(){return this.saturationValue}set brightness(t){this.instance=Ie({h:this.hue,s:this.saturation,v:zt(t),a:this.alphaValue/100}),this.initRgb(),this.initLightness(),this.brightnessValue=zt(t)}get brightness(){return this.brightnessValue}set lightness(t){this.instance=Ie({h:this.hue,s:this.hslSaturationValue,l:zt(t),a:this.alphaValue/100}),this.initRgb(),this.initHsb(),this.lightnessValue=zt(t)}get lightness(){return this.lightnessValue}set red(t){const n=this.instance.toRgb();this.instance=Ie({...n,r:zt(t),a:this.alphaValue/100}),this.initHsb(),this.initLightness(),this.redValue=zt(t)}get red(){return this.redValue}set green(t){const n=this.instance.toRgb();this.instance=Ie({...n,g:zt(t),a:this.alphaValue/100}),this.initHsb(),this.initLightness(),this.greenValue=zt(t)}get green(){return this.greenValue}set blue(t){const n=this.instance.toRgb();this.instance=Ie({...n,b:zt(t),a:this.alphaValue/100}),this.initHsb(),this.initLightness(),this.blueValue=zt(t)}get blue(){return this.blueValue}set alpha(t){this.instance.setAlpha(t/100),this.alphaValue=t}get alpha(){return this.alphaValue}get RGB(){return[this.red,this.green,this.blue,this.alpha/100]}get HSB(){return[this.hue,this.saturation,this.brightness,this.alpha/100]}get HSL(){return[this.hue,this.hslSaturationValue,this.lightness,this.alpha/100]}}function my(e,t,n,r){return`rgba(${[e,t,n,r/100].join(",")})`}const cd=(e,t,n)=>t<n?e<t?t:e>n?n:e:e<n?n:e>t?t:e,fd="color-history",dd=8,pr=(e,t)=>{const n=e.__vccOpts||e;for(const[r,i]of t)n[r]=i;return n},UL=Rn({name:"Alpha",props:{color:rt.instanceOf(Kt),size:rt.oneOf(["small","default"]).def("default")},emits:["change"],setup(e,{emit:t}){const n=Lt(null),r=Lt(null);let i=e.color||new Kt;const o=Dn({red:i.red,green:i.green,blue:i.blue,alpha:i.alpha});ir(()=>e.color,y=>{y&&(i=y,yu(o,{red:y.red,green:y.green,blue:y.blue,alpha:y.alpha}))},{deep:!0});const s=nn(()=>{const y=my(o.red,o.green,o.blue,0),m=my(o.red,o.green,o.blue,100);return{background:`linear-gradient(to right, ${y} , ${m})`}}),l=()=>{if(n.value&&r.value){const y=o.alpha/100,m=n.value.getBoundingClientRect(),C=r.value.offsetWidth;return Math.round(y*(m.width-C)+C/2)}return 0},c=nn(()=>({left:l()+"px",top:0})),d=y=>{y.target!==n.value&&p(y)},p=y=>{if(y.stopPropagation(),n.value&&r.value){const m=n.value.getBoundingClientRect(),C=r.value.offsetWidth;let b=y.clientX-m.left;b=Math.max(C/2,b),b=Math.min(b,m.width-C/2);const k=Math.round((b-C/2)/(m.width-C)*100);i.alpha=k,o.alpha=k,t("change",k)}};return No(()=>{const y={drag:m=>{p(m)},end:m=>{p(m)}};n.value&&r.value&&Qo.triggerDragEvent(n.value,y)}),{barElement:n,cursorElement:r,getCursorStyle:c,getBackgroundStyle:s,onClickSider:d}}}),WL=e=>(_o("data-v-18925ba6"),e=e(),wo(),e),KL=WL(()=>T("div",{class:"vc-alpha-slider__bar-handle"},null,-1)),VL=[KL];function qL(e,t,n,r,i,o){return E(),M("div",{class:Ge(["vc-alpha-slider","transparent",{"small-slider":e.size==="small"}])},[T("div",{ref:"barElement",class:"vc-alpha-slider__bar",style:St(e.getBackgroundStyle),onClick:t[0]||(t[0]=(...s)=>e.onClickSider&&e.onClickSider(...s))},[T("div",{class:Ge(["vc-alpha-slider__bar-pointer",{"small-bar":e.size==="small"}]),ref:"cursorElement",style:St(e.getCursorStyle)},VL,6)],4)],2)}const pd=pr(UL,[["render",qL],["__scopeId","data-v-18925ba6"]]),zL=[["#fcc02e","#f67c01","#e64a19","#d81b43","#8e24aa","#512da7","#1f87e8","#008781","#05a045"],["#fed835","#fb8c00","#f5511e","#eb1d4e","#9c28b1","#5d35b0","#2097f3","#029688","#4cb050"],["#ffeb3c","#ffa727","#fe5722","#eb4165","#aa47bc","#673bb7","#42a5f6","#26a59a","#83c683"],["#fff176","#ffb74e","#ff8a66","#f1627e","#b968c7","#7986cc","#64b5f6","#80cbc4","#a5d6a7"],["#fff59c","#ffcc80","#ffab91","#fb879e","#cf93d9","#9ea8db","#90caf8","#b2dfdc","#c8e6ca"],["transparent","#ffffff","#dedede","#a9a9a9","#4b4b4b","#353535","#212121","#000000","advance"]],GL=Rn({name:"Palette",emits:["change"],setup(e,{emit:t}){return{palettes:zL,computedBgStyle:n=>n==="transparent"?n:n==="advance"?{}:{background:Ie(n).toRgbString()},onColorChange:n=>{t("change",n)}}}}),YL={class:"vc-compact"},XL=["onClick"];function JL(e,t,n,r,i,o){return E(),M("div",YL,[(E(!0),M(De,null,ot(e.palettes,(s,l)=>(E(),M("div",{key:l,class:"vc-compact__row"},[(E(!0),M(De,null,ot(s,(c,d)=>(E(),M("div",{key:d,class:"vc-compact__color-cube--wrap",onClick:p=>e.onColorChange(c)},[T("div",{class:Ge(["vc-compact__color_cube",{advance:c==="advance",transparent:c==="transparent"}]),style:St(e.computedBgStyle(c))},null,6)],8,XL))),128))]))),128))])}const vy=pr(GL,[["render",JL],["__scopeId","data-v-b969fd48"]]),ZL=Rn({name:"Board",props:{color:rt.instanceOf(Kt),round:rt.bool.def(!1),hide:rt.bool.def(!0)},emits:["change"],setup(e,{emit:t}){var n,r,i;const o=Ic(),s={h:((n=e.color)==null?void 0:n.hue)||0,s:1,v:1},l=new Kt(s).toHexString(),c=Dn({hueColor:l,saturation:((r=e.color)==null?void 0:r.saturation)||0,brightness:((i=e.color)==null?void 0:i.brightness)||0}),d=Lt(0),p=Lt(0),y=Lt(),m=Lt(),C=nn(()=>({top:d.value+"px",left:p.value+"px"})),b=()=>{if(o){const O=o.vnode.el;p.value=c.saturation*(O==null?void 0:O.clientWidth),d.value=(1-c.brightness)*(O==null?void 0:O.clientHeight)}},k=O=>{O.target!==m.value&&L(O)},L=O=>{if(o){const $=o.vnode.el,X=$==null?void 0:$.getBoundingClientRect();let x=O.clientX-X.left,z=O.clientY-X.top;x=cd(x,0,X.width),z=cd(z,0,X.height);const Q=x/X.width,g=cd(-(z/X.height)+1,0,1);p.value=x,d.value=z,c.saturation=Q,c.brightness=g,t("change",Q,g)}};return No(()=>{o&&o.vnode.el&&y.value&&(Qo.triggerDragEvent(y.value,{drag:O=>{L(O)},end:O=>{L(O)}}),il(()=>{b()}))}),_n(()=>e.color,O=>{yu(c,{hueColor:new Kt({h:O.hue,s:1,v:1}).toHexString(),saturation:O.saturation,brightness:O.brightness}),b()},{deep:!0}),{state:c,cursorElement:y,getCursorStyle:C,onClickBoard:k}}}),hd=e=>(_o("data-v-058e5db2"),e=e(),wo(),e),QL=hd(()=>T("div",{class:"vc-saturation__white"},null,-1)),eO=hd(()=>T("div",{class:"vc-saturation__black"},null,-1)),tO=hd(()=>T("div",null,null,-1)),nO=[tO];function rO(e,t,n,r,i,o){return E(),M("div",{ref:"boardElement",class:Ge(["vc-saturation",{"vc-saturation__chrome":e.round,"vc-saturation__hidden":e.hide}]),style:St({backgroundColor:e.state.hueColor}),onClick:t[0]||(t[0]=(...s)=>e.onClickBoard&&e.onClickBoard(...s))},[QL,eO,T("div",{class:"vc-saturation__cursor",ref:"cursorElement",style:St(e.getCursorStyle)},nO,4)],6)}const gd=pr(ZL,[["render",rO],["__scopeId","data-v-058e5db2"]]),iO=Rn({name:"Hue",props:{color:rt.instanceOf(Kt),size:rt.oneOf(["small","default"]).def("default")},emits:["change"],setup(e,{emit:t}){const n=Lt(null),r=Lt(null);let i=e.color||new Kt;const o=Dn({hue:i.hue||0});ir(()=>e.color,p=>{p&&(i=p,yu(o,{hue:i.hue}))},{deep:!0});const s=()=>{if(n.value&&r.value){const p=n.value.getBoundingClientRect(),y=r.value.offsetWidth;return o.hue===360?p.width-y/2:o.hue%360*(p.width-y)/360+y/2}return 0},l=nn(()=>({left:s()+"px",top:0})),c=p=>{p.target!==n.value&&d(p)},d=p=>{if(p.stopPropagation(),n.value&&r.value){const y=n.value.getBoundingClientRect(),m=r.value.offsetWidth;let C=p.clientX-y.left;C=Math.min(C,y.width-m/2),C=Math.max(m/2,C);const b=Math.round((C-m/2)/(y.width-m)*360);i.hue=b,o.hue=b,t("change",b)}};return No(()=>{const p={drag:y=>{d(y)},end:y=>{d(y)}};n.value&&r.value&&Qo.triggerDragEvent(n.value,p)}),{barElement:n,cursorElement:r,getCursorStyle:l,onClickSider:c}}}),oO=e=>(_o("data-v-e1a08576"),e=e(),wo(),e),sO=oO(()=>T("div",{class:"vc-hue-slider__bar-handle"},null,-1)),aO=[sO];function lO(e,t,n,r,i,o){return E(),M("div",{class:Ge(["vc-hue-slider",{"small-slider":e.size==="small"}])},[T("div",{ref:"barElement",class:"vc-hue-slider__bar",onClick:t[0]||(t[0]=(...s)=>e.onClickSider&&e.onClickSider(...s))},[T("div",{class:Ge(["vc-hue-slider__bar-pointer",{"small-bar":e.size==="small"}]),ref:"cursorElement",style:St(e.getCursorStyle)},aO,6)],512)],2)}const md=pr(iO,[["render",lO],["__scopeId","data-v-e1a08576"]]),uO=Rn({name:"Lightness",props:{color:rt.instanceOf(Kt),size:rt.oneOf(["small","default"]).def("default")},emits:["change"],setup(e,{emit:t}){const n=Lt(null),r=Lt(null);let i=e.color||new Kt;const[o,s,l]=i.HSL,c=Dn({hue:o,saturation:s,lightness:l});ir(()=>e.color,b=>{if(b){i=b;const[k,L,O]=i.HSL;yu(c,{hue:k,saturation:L,lightness:O})}},{deep:!0});const d=nn(()=>{const b=Ie({h:c.hue,s:c.saturation,l:.8}).toPercentageRgbString(),k=Ie({h:c.hue,s:c.saturation,l:.6}).toPercentageRgbString(),L=Ie({h:c.hue,s:c.saturation,l:.4}).toPercentageRgbString(),O=Ie({h:c.hue,s:c.saturation,l:.2}).toPercentageRgbString();return{background:[`linear-gradient(to right, rgb(255, 255, 255), ${b}, ${k}, ${L}, ${O}, rgb(0, 0, 0))`,`-webkit-linear-gradient(left, rgb(255, 255, 255), ${b}, ${k}, ${L}, ${O}, rgb(0, 0, 0))`,`-moz-linear-gradient(left, rgb(255, 255, 255), ${b}, ${k}, ${L}, ${O}, rgb(0, 0, 0))`,`-ms-linear-gradient(left, rgb(255, 255, 255), ${b}, ${k}, ${L}, ${O}, rgb(0, 0, 0))`]}}),p=()=>{if(n.value&&r.value){const b=c.lightness,k=n.value.getBoundingClientRect(),L=r.value.offsetWidth;return(1-b)*(k.width-L)+L/2}return 0},y=nn(()=>({left:p()+"px",top:0})),m=b=>{b.target!==n.value&&C(b)},C=b=>{if(b.stopPropagation(),n.value&&r.value){const k=n.value.getBoundingClientRect(),L=r.value.offsetWidth;let O=b.clientX-k.left;O=Math.max(L/2,O),O=Math.min(O,k.width-L/2);const $=1-(O-L/2)/(k.width-L);i.lightness=$,t("change",$)}};return No(()=>{const b={drag:k=>{C(k)},end:k=>{C(k)}};n.value&&r.value&&Qo.triggerDragEvent(n.value,b)}),{barElement:n,cursorElement:r,getCursorStyle:y,getBackgroundStyle:d,onClickSider:m}}}),cO=e=>(_o("data-v-94a50a9e"),e=e(),wo(),e),fO=cO(()=>T("div",{class:"vc-lightness-slider__bar-handle"},null,-1)),dO=[fO];function pO(e,t,n,r,i,o){return E(),M("div",{class:Ge(["vc-lightness-slider",{"small-slider":e.size==="small"}])},[T("div",{ref:"barElement",class:"vc-lightness-slider__bar",style:St(e.getBackgroundStyle),onClick:t[0]||(t[0]=(...s)=>e.onClickSider&&e.onClickSider(...s))},[T("div",{class:Ge(["vc-lightness-slider__bar-pointer",{"small-bar":e.size==="small"}]),ref:"cursorElement",style:St(e.getCursorStyle)},dO,6)],4)],2)}const yy=pr(uO,[["render",pO],["__scopeId","data-v-94a50a9e"]]),hO=Rn({name:"History",props:{colors:rt.arrayOf(String).def(()=>[]),round:rt.bool.def(!1)},emits:["change"],setup(e,{emit:t}){return{onColorSelect:n=>{t("change",n)}}}}),gO={key:0,class:"vc-colorPicker__record"},mO={class:"color-list"},vO=["onClick"];function yO(e,t,n,r,i,o){return e.colors&&e.colors.length>0?(E(),M("div",gO,[T("div",mO,[(E(!0),M(De,null,ot(e.colors,(s,l)=>(E(),M("div",{key:l,class:Ge(["color-item","transparent",{"color-item__round":e.round}]),onClick:c=>e.onColorSelect(s)},[T("div",{class:"color-item__display",style:St({backgroundColor:s})},null,4)],10,vO))),128))])])):ke("",!0)}const vd=pr(hO,[["render",yO],["__scopeId","data-v-0f657238"]]),bO=Rn({name:"Display",props:{color:rt.instanceOf(Kt),disableAlpha:rt.bool.def(!1)},emits:["update:color","change"],setup(e,{emit:t}){var n,r,i,o;const s=Lt("hex"),l=Dn({color:e.color,hex:(n=e.color)==null?void 0:n.hex,alpha:((r=e.color)==null?void 0:r.alpha)+"%",rgba:(i=e.color)==null?void 0:i.RGB,previewBgColor:(o=e.color)==null?void 0:o.toRgbString()}),c=nn(()=>({background:l.previewBgColor})),d=()=>{s.value=s.value==="rgba"?"hex":"rgba"},p=zi(m=>{if(!m.target.value)return;let C=parseInt(m.target.value.replace("%",""));C>100&&(m.target.value="100%",C=100),C<0&&(m.target.value="0%",C=0),isNaN(C)&&(m.target.value="100%",C=100),!isNaN(C)&&l.color&&(l.color.alpha=C),t("update:color",l.color),t("change",l.color)},300),y=zi((m,C)=>{if(console.log(m.target.value),!!m.target.value){if(s.value==="hex"){const b=m.target.value.replace("#","");Ie(b).isValid()&&l.color&&(l.color.hex=b)}else if(C!==void 0&&l.rgba&&l.color){m.target.value<0&&(m.target.value=0),C===3&&m.target.value>1&&(m.target.value=1),C<3&&m.target.value>255&&(m.target.value=255),l.rgba[C]=Number(m.target.value);const[b,k,L,O]=l.rgba;l.color.hex=Ie({r:b,g:k,b:L}).toHex(),l.color.alpha=Math.floor(O*100)}t("update:color",l.color),t("change",l.color)}},300);return _n(()=>e.color,m=>{m&&(l.color=m,l.alpha=Math.floor(l.color.alpha)+"%",l.hex=l.color.hex,l.rgba=l.color.RGB)},{deep:!0}),_n(()=>l.color,()=>{l.color&&(l.previewBgColor=l.color.toRgbString())},{deep:!0}),{state:l,getBgColorStyle:c,inputType:s,onInputTypeChange:d,onAlphaBlur:p,onInputChange:y}}}),CO={class:"vc-display"},_O={class:"vc-current-color vc-transparent"},wO={key:0,style:{display:"flex",flex:"1",gap:"4px",height:"100%"}},TO={class:"vc-color-input"},kO=["value"],xO={key:0,class:"vc-alpha-input"},SO=["value"],AO={key:1,style:{display:"flex",flex:"1",gap:"4px",height:"100%"}},EO=["value","onInput"];function LO(e,t,n,r,i,o){return E(),M("div",CO,[T("div",_O,[T("div",{class:"color-cube",style:St(e.getBgColorStyle)},null,4)]),e.inputType==="hex"?(E(),M("div",wO,[T("div",TO,[T("input",{value:e.state.hex,onInput:t[0]||(t[0]=(...s)=>e.onInputChange&&e.onInputChange(...s))},null,40,kO)]),e.disableAlpha?ke("",!0):(E(),M("div",xO,[T("input",{class:"vc-alpha-input__inner",value:e.state.alpha,onInput:t[1]||(t[1]=(...s)=>e.onAlphaBlur&&e.onAlphaBlur(...s))},null,40,SO)]))])):e.state.rgba?(E(),M("div",AO,[(E(!0),M(De,null,ot(e.state.rgba,(s,l)=>(E(),M("div",{class:"vc-rgb-input",key:l},[T("div",null,[T("input",{value:s,onInput:c=>e.onInputChange(c,l)},null,40,EO)]),T("div",null,ie(["R","G","B","A"][l]),1)]))),128))])):ke("",!0),T("div",{class:"vc-input-toggle",onClick:t[2]||(t[2]=(...s)=>e.onInputTypeChange&&e.onInputTypeChange(...s))})])}const yd=pr(bO,[["render",LO],["__scopeId","data-v-f6f511ec"]]),OO=Rn({name:"FkColorPicker",components:{Display:yd,Alpha:pd,Palette:vy,Board:gd,Hue:md,Lightness:yy,History:vd},props:{color:rt.instanceOf(Kt),disableHistory:rt.bool.def(!1),roundHistory:rt.bool.def(!1),disableAlpha:rt.bool.def(!1)},emits:["update:color","change","advanceChange"],setup(e,{emit:t}){const n=e.color||new Kt,r=Dn({color:n,hex:n.toHexString(),rgb:n.toRgbString()}),i=Lt(!1),o=nn(()=>({background:r.rgb})),s=()=>{i.value=!1,t("advanceChange",!1)},l=rf(fd,[],{}),c=zi(()=>{if(e.disableHistory)return;const k=r.color.toRgbString();if(l.value=l.value.filter(L=>!Ie.equals(L,k)),!l.value.includes(k)){for(;l.value.length>dd;)l.value.pop();l.value.unshift(k)}},500),d=k=>{k==="advance"?(i.value=!0,t("advanceChange",!0)):(r.color.hex=k,t("advanceChange",!1))},p=k=>{r.color.alpha=k},y=k=>{r.color.hue=k},m=(k,L)=>{r.color.saturation=k,r.color.brightness=L},C=k=>{r.color.lightness=k},b=k=>{const L=k.target.value.replace("#","");Ie(L).isValid()&&(r.color.hex=L)};return _n(()=>e.color,k=>{k&&(r.color=k)},{deep:!0}),_n(()=>r.color,()=>{r.hex=r.color.hex,r.rgb=r.color.toRgbString(),c(),t("update:color",r.color),t("change",r.color)},{deep:!0}),{state:r,advancePanelShow:i,onBack:s,onCompactChange:d,onAlphaChange:p,onHueChange:y,onBoardChange:m,onLightChange:C,onInputChange:b,previewStyle:o,historyColors:l}}}),IO=e=>(_o("data-v-0d5bef46"),e=e(),wo(),e),PO={class:"vc-fk-colorPicker"},DO={class:"vc-fk-colorPicker__inner"},RO={class:"vc-fk-colorPicker__header"},NO=IO(()=>T("div",{class:"back"},null,-1)),MO=[NO];function FO(e,t,n,r,i,o){const s=Ye("Palette"),l=Ye("Board"),c=Ye("Hue"),d=Ye("Lightness"),p=Ye("Alpha"),y=Ye("Display"),m=Ye("History");return E(),M("div",PO,[T("div",DO,[T("div",RO,[e.advancePanelShow?(E(),M("span",{key:0,style:{cursor:"pointer"},onClick:t[0]||(t[0]=(...C)=>e.onBack&&e.onBack(...C))},MO)):ke("",!0)]),e.advancePanelShow?ke("",!0):(E(),Ue(s,{key:0,onChange:e.onCompactChange},null,8,["onChange"])),e.advancePanelShow?(E(),Ue(l,{key:1,color:e.state.color,onChange:e.onBoardChange},null,8,["color","onChange"])):ke("",!0),e.advancePanelShow?(E(),Ue(c,{key:2,color:e.state.color,onChange:e.onHueChange},null,8,["color","onChange"])):ke("",!0),e.advancePanelShow?ke("",!0):(E(),Ue(d,{key:3,color:e.state.color,onChange:e.onLightChange},null,8,["color","onChange"])),e.disableAlpha?ke("",!0):(E(),Ue(p,{key:4,color:e.state.color,onChange:e.onAlphaChange},null,8,["color","onChange"])),ye(y,{color:e.state.color,"disable-alpha":e.disableAlpha},null,8,["color","disable-alpha"]),e.disableHistory?ke("",!0):(E(),Ue(m,{key:5,round:e.roundHistory,colors:e.historyColors,onChange:e.onCompactChange},null,8,["round","colors","onChange"]))])])}const by=pr(OO,[["render",FO],["__scopeId","data-v-0d5bef46"]]),BO=Rn({name:"ChromeColorPicker",components:{Display:yd,Alpha:pd,Board:gd,Hue:md,History:vd},props:{color:rt.instanceOf(Kt),disableHistory:rt.bool.def(!1),roundHistory:rt.bool.def(!1),disableAlpha:rt.bool.def(!1)},emits:["update:color","change"],setup(e,{emit:t}){const n=e.color||new Kt,r=Dn({color:n,hex:n.toHexString(),rgb:n.toRgbString()}),i=nn(()=>({background:r.rgb})),o=rf(fd,[],{}),s=zi(()=>{if(e.disableHistory)return;const y=r.color.toRgbString();if(o.value=o.value.filter(m=>!Ie.equals(m,y)),!o.value.includes(y)){for(;o.value.length>dd;)o.value.pop();o.value.unshift(y)}},500),l=y=>{r.color.alpha=y},c=y=>{r.color.hue=y},d=(y,m)=>{r.color.saturation=y,r.color.brightness=m},p=y=>{y!=="advance"&&(r.color.hex=y)};return _n(()=>e.color,y=>{y&&(r.color=y)},{deep:!0}),_n(()=>r.color,()=>{r.hex=r.color.hex,r.rgb=r.color.toRgbString(),s(),t("update:color",r.color),t("change",r.color)},{deep:!0}),{state:r,previewStyle:i,historyColors:o,onAlphaChange:l,onHueChange:c,onBoardChange:d,onCompactChange:p}}}),$O={class:"vc-chrome-colorPicker"},HO={class:"vc-chrome-colorPicker-body"},jO={class:"chrome-controls"},UO={class:"chrome-sliders"};function WO(e,t,n,r,i,o){const s=Ye("Board"),l=Ye("Hue"),c=Ye("Alpha"),d=Ye("Display"),p=Ye("History");return E(),M("div",$O,[ye(s,{round:!0,hide:!1,color:e.state.color,onChange:e.onBoardChange},null,8,["color","onChange"]),T("div",HO,[T("div",jO,[T("div",UO,[ye(l,{size:"small",color:e.state.color,onChange:e.onHueChange},null,8,["color","onChange"]),e.disableAlpha?ke("",!0):(E(),Ue(c,{key:0,size:"small",color:e.state.color,onChange:e.onAlphaChange},null,8,["color","onChange"]))])]),ye(d,{color:e.state.color,"disable-alpha":e.disableAlpha},null,8,["color","disable-alpha"]),e.disableHistory?ke("",!0):(E(),Ue(p,{key:0,round:e.roundHistory,colors:e.historyColors,onChange:e.onCompactChange},null,8,["round","colors","onChange"]))])])}const Cy=pr(BO,[["render",WO],["__scopeId","data-v-33636434"]]),bd="Vue3ColorPickerProvider",KO=(e,t)=>{const n=e.getBoundingClientRect(),r=n.left+n.width/2,i=n.top+n.height/2,o=Math.abs(r-t.clientX),s=Math.abs(i-t.clientY),l=Math.sqrt(Math.pow(o,2)+Math.pow(s,2)),c=s/l,d=Math.acos(c);let p=Math.floor(180/(Math.PI/d));return t.clientX>r&&t.clientY>i&&(p=180-p),t.clientX==r&&t.clientY>i&&(p=180),t.clientX>r&&t.clientY==i&&(p=90),t.clientX<r&&t.clientY>i&&(p=180+p),t.clientX<r&&t.clientY==i&&(p=270),t.clientX<r&&t.clientY<i&&(p=360-p),p};let Cd=!1;const VO=(e,t)=>{const n=function(i){var o;(o=t.drag)==null||o.call(t,i)},r=function(i){var o;document.removeEventListener("mousemove",n,!1),document.removeEventListener("mouseup",r,!1),document.onselectstart=null,document.ondragstart=null,Cd=!1,(o=t.end)==null||o.call(t,i)};e&&e.addEventListener("mousedown",i=>{var o;Cd||(document.onselectstart=()=>!1,document.ondragstart=()=>!1,document.addEventListener("mousemove",n,!1),document.addEventListener("mouseup",r,!1),Cd=!0,(o=t.start)==null||o.call(t,i))})},qO={angle:{type:Number,default:0},size:{type:Number,default:16,validator:e=>e>=16},borderWidth:{type:Number,default:1,validator:e=>e>=1},borderColor:{type:String,default:"#666"}},zO=Rn({name:"Angle",props:qO,emits:["update:angle","change"],setup(e,{emit:t}){const n=Lt(null),r=Lt(0);ir(()=>e.angle,l=>{r.value=l});const i=()=>{let l=Number(r.value);isNaN(l)||(l=l>360||l<0?e.angle:l,r.value=l===360?0:l,t("update:angle",r.value),t("change",r.value))},o=nn(()=>({width:e.size+"px",height:e.size+"px",borderWidth:e.borderWidth+"px",borderColor:e.borderColor,transform:`rotate(${r.value}deg)`})),s=l=>{n.value&&(r.value=KO(n.value,l)%360,i())};return fl(()=>{const l={drag:c=>{s(c)},end:c=>{s(c)}};n.value&&VO(n.value,l)}),()=>ye("div",{class:"bee-angle"},[ye("div",{class:"bee-angle__round",ref:n,style:o.value},null)])}}),GO=Rn({name:"GradientColorPicker",components:{Angle:zO,Display:yd,Alpha:pd,Palette:vy,Board:gd,Hue:md,Lightness:yy,History:vd},props:{startColor:rt.instanceOf(Kt).isRequired,endColor:rt.instanceOf(Kt).isRequired,startColorStop:rt.number.def(0),endColorStop:rt.number.def(100),angle:rt.number.def(0),type:rt.oneOf(["linear","radial"]).def("linear"),disableHistory:rt.bool.def(!1),roundHistory:rt.bool.def(!1),disableAlpha:rt.bool.def(!1),pickerType:rt.oneOf(["fk","chrome"]).def("fk")},emits:["update:startColor","update:endColor","update:angle","update:startColorStop","update:endColorStop","startColorChange","endColorChange","advanceChange","angleChange","startColorStopChange","endColorStopChange","typeChange"],setup(e,{emit:t}){const n=Dn({startActive:!0,startColor:e.startColor,endColor:e.endColor,startColorStop:e.startColorStop,endColorStop:e.endColorStop,angle:e.angle,type:e.type,startColorRgba:e.startColor.toRgbString(),endColorRgba:e.endColor.toRgbString()}),r=ko(bd),i=Lt(e.pickerType==="chrome"),o=Lt(),s=Lt(),l=Lt();ir(()=>[e.startColor,e.endColor,e.angle],H=>{n.startColor=H[0],n.endColor=H[1],n.angle=H[2]}),ir(()=>e.type,H=>{n.type=H});const c=nn({get:()=>n.startActive?n.startColor:n.endColor,set:H=>{if(n.startActive){n.startColor=H;return}n.endColor=H}}),d=nn(()=>{if(l.value&&o.value){const H=n.startColorStop/100,K=l.value.getBoundingClientRect(),U=o.value.offsetWidth;return Math.round(H*(K.width-U)+U/2)}return 0}),p=nn(()=>{if(l.value&&s.value){const H=n.endColorStop/100,K=l.value.getBoundingClientRect(),U=s.value.offsetWidth;return Math.round(H*(K.width-U)+U/2)}return 0}),y=nn(()=>{let H=`background: linear-gradient(${n.angle}deg, ${n.startColorRgba} ${n.startColorStop}%, ${n.endColorRgba} ${n.endColorStop}%)`;return n.type==="radial"&&(H=`background: radial-gradient(circle, ${n.startColorRgba} ${n.startColorStop}%, ${n.endColorRgba} ${n.endColorStop}%)`),H}),m=H=>{var K;if(n.startActive=!0,l.value&&o.value){const U=(K=l.value)==null?void 0:K.getBoundingClientRect();let de=H.clientX-U.left;de=Math.max(o.value.offsetWidth/2,de),de=Math.min(de,U.width-o.value.offsetWidth/2),n.startColorStop=Math.round((de-o.value.offsetWidth/2)/(U.width-o.value.offsetWidth)*100),t("update:startColorStop",n.startColorStop),t("startColorStopChange",n.startColorStop)}},C=H=>{var K;if(n.startActive=!1,l.value&&s.value){const U=(K=l.value)==null?void 0:K.getBoundingClientRect();let de=H.clientX-U.left;de=Math.max(s.value.offsetWidth/2,de),de=Math.min(de,U.width-s.value.offsetWidth/2),n.endColorStop=Math.round((de-s.value.offsetWidth/2)/(U.width-s.value.offsetWidth)*100),t("update:endColorStop",n.endColorStop),t("endColorStopChange",n.endColorStop)}},b=H=>{const K=H.target,U=parseInt(K.value.replace("°",""));isNaN(U)||(n.angle=U%360),t("update:angle",n.angle),t("angleChange",n.angle)},k=H=>{n.angle=H,t("update:angle",n.angle),t("angleChange",n.angle)},L=H=>{H==="advance"?(i.value=!0,t("advanceChange",!0)):(c.value.hex=H,t("advanceChange",!1)),Q()},O=H=>{c.value.alpha=H,Q()},$=H=>{c.value.hue=H,Q()},X=(H,K)=>{c.value.saturation=H,c.value.brightness=K,Q()},x=H=>{c.value.lightness=H,Q()},z=()=>{Q()},Q=()=>{n.startActive?(t("update:startColor",n.startColor),t("startColorChange",n.startColor)):(t("update:endColor",n.endColor),t("endColorChange",n.endColor))},g=()=>{i.value=!1,t("advanceChange",!1)},I=()=>{n.type=n.type==="linear"?"radial":"linear",t("typeChange",n.type)},A=rf(fd,[],{}),D=zi(()=>{if(e.disableHistory)return;const H=c.value.toRgbString();if(A.value=A.value.filter(K=>!Ie.equals(K,H)),!A.value.includes(H)){for(;A.value.length>dd;)A.value.pop();A.value.unshift(H)}},500);return No(()=>{s.value&&o.value&&(Qo.triggerDragEvent(s.value,{drag:H=>{C(H)},end:H=>{C(H)}}),Qo.triggerDragEvent(o.value,{drag:H=>{m(H)},end:H=>{m(H)}}))}),_n(()=>n.startColor,H=>{n.startColorRgba=H.toRgbString()},{deep:!0}),_n(()=>n.endColor,H=>{n.endColorRgba=H.toRgbString()},{deep:!0}),_n(()=>c.value,()=>{D()},{deep:!0}),{startGradientRef:o,stopGradientRef:s,colorRangeRef:l,state:n,currentColor:c,getStartColorLeft:d,getEndColorLeft:p,gradientBg:y,advancePanelShow:i,onDegreeBlur:b,onCompactChange:L,onAlphaChange:O,onHueChange:$,onBoardChange:X,onLightChange:x,historyColors:A,onBack:g,onDegreeChange:k,onDisplayChange:z,onTypeChange:I,lang:r==null?void 0:r.lang}}}),_y=e=>(_o("data-v-1e7e32e5"),e=e(),wo(),e),YO={class:"vc-gradient-picker"},XO={class:"vc-gradient-picker__header"},JO={class:"vc-gradient__types"},ZO={class:"vc-gradient-picker__body"},QO={class:"vc-color-range",ref:"colorRangeRef"},eI={class:"vc-color-range__container"},tI={class:"vc-gradient__stop__container"},nI=["title"],rI=_y(()=>T("span",{class:"vc-gradient__stop--inner"},null,-1)),iI=[rI],oI=["title"],sI=_y(()=>T("span",{class:"vc-gradient__stop--inner"},null,-1)),aI=[sI],lI={class:"vc-picker-degree-input vc-degree-input"},uI={class:"vc-degree-input__control"},cI=["value"],fI={class:"vc-degree-input__panel"},dI={class:"vc-degree-input__disk"};function pI(e,t,n,r,i,o){var s,l;const c=Ye("Angle"),d=Ye("Board"),p=Ye("Hue"),y=Ye("Palette"),m=Ye("Lightness"),C=Ye("Alpha"),b=Ye("Display"),k=Ye("History");return E(),M("div",YO,[T("div",XO,[T("div",null,[ge(T("div",{class:"back",style:{cursor:"pointer"},onClick:t[0]||(t[0]=(...L)=>e.onBack&&e.onBack(...L))},null,512),[[Ot,e.pickerType==="fk"&&e.advancePanelShow]])]),T("div",JO,[(E(),M(De,null,ot(["linear","radial"],L=>T("div",{class:Ge(["vc-gradient__type",{active:e.state.type===L}]),key:L,onClick:t[1]||(t[1]=(...O)=>e.onTypeChange&&e.onTypeChange(...O))},ie(e.lang?e.lang[L]:L),3)),64))])]),T("div",ZO,[T("div",QO,[T("div",eI,[T("div",{class:"vc-background",style:St(e.gradientBg)},null,4),T("div",tI,[T("div",{class:Ge(["vc-gradient__stop",{"vc-gradient__stop--current":e.state.startActive}]),ref:"startGradientRef",title:(s=e.lang)==null?void 0:s.start,style:St({left:e.getStartColorLeft+"px"})},iI,14,nI),T("div",{class:Ge(["vc-gradient__stop",{"vc-gradient__stop--current":!e.state.startActive}]),ref:"stopGradientRef",title:(l=e.lang)==null?void 0:l.end,style:St({left:e.getEndColorLeft+"px"})},aI,14,oI)])])],512),T("div",lI,[T("div",uI,[T("input",{value:e.state.angle,onBlur:t[2]||(t[2]=(...L)=>e.onDegreeBlur&&e.onDegreeBlur(...L))},null,40,cI),jt("deg ")]),T("div",fI,[T("div",dI,[ye(c,{angle:e.state.angle,"onUpdate:angle":t[3]||(t[3]=L=>e.state.angle=L),size:40,onChange:e.onDegreeChange},null,8,["angle","onChange"])])])])]),e.advancePanelShow?(E(),Ue(d,{key:0,color:e.currentColor,onChange:e.onBoardChange},null,8,["color","onChange"])):ke("",!0),e.advancePanelShow?(E(),Ue(p,{key:1,color:e.currentColor,onChange:e.onHueChange},null,8,["color","onChange"])):ke("",!0),e.advancePanelShow?ke("",!0):(E(),Ue(y,{key:2,onChange:e.onCompactChange},null,8,["onChange"])),e.advancePanelShow?ke("",!0):(E(),Ue(m,{key:3,color:e.currentColor,onChange:e.onLightChange},null,8,["color","onChange"])),e.disableAlpha?ke("",!0):(E(),Ue(C,{key:4,color:e.currentColor,onChange:e.onAlphaChange},null,8,["color","onChange"])),ye(b,{color:e.currentColor,"disable-alpha":e.disableAlpha,onChange:e.onDisplayChange},null,8,["color","disable-alpha","onChange"]),e.disableHistory?ke("",!0):(E(),Ue(k,{key:5,round:e.roundHistory,colors:e.historyColors,onChange:e.onCompactChange},null,8,["round","colors","onChange"]))])}const wy=pr(GO,[["render",pI],["__scopeId","data-v-1e7e32e5"]]),hI=Rn({name:"WrapContainer",props:{theme:rt.oneOf(["white","black"]).def("white"),showTab:rt.bool.def(!1),activeKey:rt.oneOf(["pure","gradient"]).def("pure")},emits:["update:activeKey","change"],setup(e,{emit:t}){const n=Dn({activeKey:e.activeKey}),r=ko(bd),i=o=>{n.activeKey=o,t("update:activeKey",o),t("change",o)};return _n(()=>e.activeKey,o=>{n.activeKey=o}),{state:n,onActiveKeyChange:i,lang:r==null?void 0:r.lang}}}),gI={class:"vc-colorpicker--container"},mI={key:0,class:"vc-colorpicker--tabs"},vI={class:"vc-colorpicker--tabs__inner"},yI={class:"vc-btn__content"},bI={class:"vc-btn__content"};function CI(e,t,n,r,i,o){var s,l;return E(),M("div",{class:Ge(["vc-colorpicker",e.theme])},[T("div",gI,[e.showTab?(E(),M("div",mI,[T("div",vI,[T("div",{class:Ge(["vc-colorpicker--tabs__btn",{"vc-btn-active":e.state.activeKey==="pure"}]),onClick:t[0]||(t[0]=c=>e.onActiveKeyChange("pure"))},[T("button",null,[T("div",yI,ie((s=e.lang)==null?void 0:s.pure),1)])],2),T("div",{class:Ge(["vc-colorpicker--tabs__btn",{"vc-btn-active":e.state.activeKey==="gradient"}]),onClick:t[1]||(t[1]=c=>e.onActiveKeyChange("gradient"))},[T("button",null,[T("div",bI,ie((l=e.lang)==null?void 0:l.gradient),1)])],2),T("div",{class:"vc-colorpicker--tabs__bg",style:St({width:"50%",left:`calc(${e.state.activeKey==="gradient"?50:0}%)`})},null,4)])])):ke("",!0),g_(e.$slots,"default",{},void 0,!0)])],2)}const _I=pr(hI,[["render",CI],["__scopeId","data-v-0492277d"]]),wI={start:"Start",end:"End",pure:"Pure",gradient:"Gradient",linear:"linear",radial:"radial"},TI={start:"开始",end:"结束",pure:"纯色",gradient:"渐变",linear:"线性",radial:"径向"},kI={En:wI,"ZH-cn":TI},xI={isWidget:rt.bool.def(!1),pickerType:rt.oneOf(["fk","chrome"]).def("fk"),shape:rt.oneOf(["circle","square"]).def("square"),pureColor:{type:[String,Object],default:"#000000"},gradientColor:rt.string.def("linear-gradient(90deg, rgba(255, 255, 255, 1) 0%, rgba(0, 0, 0, 1) 100%)"),format:{type:String,default:"rgb"},disableAlpha:rt.bool.def(!1),disableHistory:rt.bool.def(!1),roundHistory:rt.bool.def(!1),useType:rt.oneOf(["pure","gradient","both"]).def("pure"),activeKey:rt.oneOf(["pure","gradient"]).def("pure"),lang:{type:String,default:"ZH-cn"},zIndex:rt.number.def(9999),pickerContainer:{type:String||HTMLElement,default:"body"},debounce:rt.number.def(100),theme:rt.oneOf(["white","black"]).def("white")},SI=Rn({name:"ColorPicker",components:{FkColorPicker:by,ChromeColorPicker:Cy,GradientColorPicker:wy,WrapContainer:_I},inheritAttrs:!1,props:xI,emits:["update:pureColor","pureColorChange","update:gradientColor","gradientColorChange","update:activeKey","activeKeyChange"],setup(e,{emit:t}){Ah(bd,{lang:nn(()=>kI[e.lang||"ZH-cn"])});const n=Dn({pureColor:e.pureColor||"",activeKey:e.useType==="gradient"?"gradient":e.activeKey,isAdvanceMode:!1}),r=new Kt("#000"),i=new Kt("#000"),o=new Kt(n.pureColor),s=Dn({startColor:r,endColor:i,startColorStop:0,endColorStop:100,angle:0,type:"linear",gradientColor:e.gradientColor}),l=Lt(o),c=Lt(!1),d=Lt(null),p=Lt(null);let y=null;const m=nn(()=>({background:n.activeKey!=="gradient"?Ie(n.pureColor).toRgbString():s.gradientColor})),C=nn(()=>n.activeKey==="gradient"?wy.name:e.pickerType==="fk"?by.name:Cy.name),b=A=>{n.isAdvanceMode=A},k=nn(()=>{const A={disableAlpha:e.disableAlpha,disableHistory:e.disableHistory,roundHistory:e.roundHistory,pickerType:e.pickerType};return n.activeKey==="gradient"?{...A,startColor:s.startColor,endColor:s.endColor,angle:s.angle,type:s.type,startColorStop:s.startColorStop,endColorStop:s.endColorStop,onStartColorChange:D=>{s.startColor=D,X()},onEndColorChange:D=>{s.endColor=D,X()},onStartColorStopChange:D=>{s.startColorStop=D,X()},onEndColorStopChange:D=>{s.endColorStop=D,X()},onAngleChange:D=>{s.angle=D,X()},onTypeChange:D=>{s.type=D,X()},onAdvanceChange:b}:{...A,disableAlpha:e.disableAlpha,disableHistory:e.disableHistory,roundHistory:e.roundHistory,color:l.value,onChange:Q,onAdvanceChange:b}}),L=()=>{c.value=!0,y?y.update():z()},O=()=>{c.value=!1},$=()=>{var A,D,H,K;try{const[U]=fT(s.gradientColor);if(U&&U.type.includes("gradient")&&U.colorStops.length>=2){const de=U.colorStops[0],je=U.colorStops[1];s.startColorStop=Number((A=de.length)==null?void 0:A.value)||0,s.endColorStop=Number((D=je.length)==null?void 0:D.value)||0,U.type==="linear-gradient"&&((H=U.orientation)==null?void 0:H.type)==="angular"&&(s.angle=Number((K=U.orientation)==null?void 0:K.value)||0),s.type=U.type.split("-")[0];const[Pe,V,ae,pe]=de.value,[Qe,et,se,Ce]=je.value;s.startColor=new Kt({r:Number(Pe),g:Number(V),b:Number(ae),a:Number(pe)}),s.endColor=new Kt({r:Number(Qe),g:Number(et),b:Number(se),a:Number(Ce)})}}catch(U){console.log(`[Parse Color]: ${U}`)}},X=zi(()=>{const A=x();try{s.gradientColor=dT(A),t("update:gradientColor",s.gradientColor),t("gradientColorChange",s.gradientColor)}catch(D){console.log(D)}},e.debounce),x=()=>{const A=[],D=s.startColor.RGB.map(U=>U.toString()),H=s.endColor.RGB.map(U=>U.toString()),K=[{type:"rgba",value:[D[0],D[1],D[2],D[3]],length:{value:s.startColorStop+"",type:"%"}},{type:"rgba",value:[H[0],H[1],H[2],H[3]],length:{value:s.endColorStop+"",type:"%"}}];return s.type==="linear"?A.push({type:"linear-gradient",orientation:{type:"angular",value:s.angle+""},colorStops:K}):s.type==="radial"&&A.push({type:"radial-gradient",orientation:[{type:"shape",value:"circle"}],colorStops:K}),A},z=()=>{d.value&&p.value&&(y=dm(d.value,p.value,{placement:"auto",modifiers:[{name:"offset",options:{offset:[0,8]}},{name:"flip",options:{allowedAutoPlacements:["top","bottom","left","right"],rootBoundary:"viewport"}}]}))},Q=A=>{l.value=A,n.pureColor=A.toString(e.format),g()},g=zi(()=>{t("update:pureColor",n.pureColor),t("pureColorChange",n.pureColor)},e.debounce);iT(p,()=>{O()});const I=A=>{n.activeKey=A,t("update:activeKey",A),t("activeKeyChange",A)};return No(()=>{$()}),_n(()=>e.gradientColor,A=>{A!=s.gradientColor&&(s.gradientColor=A)}),_n(()=>s.gradientColor,()=>{$()}),_n(()=>e.activeKey,A=>{n.activeKey=A}),_n(()=>e.useType,A=>{n.activeKey!=="gradient"&&A==="gradient"?n.activeKey="gradient":n.activeKey="pure"}),_n(()=>e.pureColor,A=>{Ie.equals(A,n.pureColor)||(n.pureColor=A,l.value=new Kt(A))},{deep:!0}),{colorCubeRef:d,pickerRef:p,showPicker:c,colorInstance:l,getBgColorStyle:m,onColorChange:Q,onShowPicker:L,onActiveKeyChange:I,getComponentName:C,getBindArgs:k,state:n}}});function AI(e,t,n,r,i,o){const s=Ye("WrapContainer");return E(),M(De,null,[e.isWidget?(E(),Ue(s,{key:0,"active-key":e.state.activeKey,"onUpdate:activeKey":t[0]||(t[0]=l=>e.state.activeKey=l),"show-tab":e.useType==="both",onChange:e.onActiveKeyChange,style:St({zIndex:e.zIndex}),theme:e.theme},{default:tn(()=>[(E(),Ue(yh(e.getComponentName),bl({key:e.getComponentName},e.getBindArgs),null,16))]),_:1},8,["active-key","show-tab","onChange","style","theme"])):ke("",!0),e.isWidget?ke("",!0):(E(),M(De,{key:1},[T("div",{class:Ge(["vc-color-wrap transparent",{round:e.shape==="circle"}]),ref:"colorCubeRef"},[T("div",{class:"current-color",style:St(e.getBgColorStyle),onClick:t[1]||(t[1]=(...l)=>e.onShowPicker&&e.onShowPicker(...l))},null,4)],2),(E(),Ue(N_,{to:e.pickerContainer},[ge(T("div",{ref:"pickerRef",style:St({zIndex:e.zIndex})},[e.showPicker?(E(),Ue(s,{key:0,"show-tab":e.useType==="both"&&!e.state.isAdvanceMode,"active-key":e.state.activeKey,"onUpdate:activeKey":t[2]||(t[2]=l=>e.state.activeKey=l),onChange:e.onActiveKeyChange,theme:e.theme},{default:tn(()=>[(E(),Ue(yh(e.getComponentName),bl({key:e.getComponentName},e.getBindArgs),null,16))]),_:1},8,["show-tab","active-key","onChange","theme"])):ke("",!0)],4),[[Ot,e.showPicker]])],8,["to"]))],64))],64)}const EI={name:"PhystonPrompt",components:{HighlightPrompt:Gw,VueNumberInput:Pw,IconSvg:Fn,ColorPicker:pr(SI,[["render",AI],["__scopeId","data-v-11de56b7"]])},mixins:[Xn,Dw,Rw,jw,Uw],props:{name:{type:String,required:!0},neg:{type:Boolean,default:!1},textarea:{type:Object,required:!0},steps:{type:Object,required:!0},canOneTranslate:{type:Boolean,default:!1},autoTranslate:{type:Boolean,default:!1},autoTranslateToEnglish:{type:Boolean,default:!1},autoTranslateToLocal:{type:Boolean,default:!1},autoRemoveSpace:{type:Boolean,default:!1},autoRemoveLastComma:{type:Boolean,default:!1},autoKeepWeightZero:{type:Boolean,default:!1},autoKeepWeightOne:{type:Boolean,default:!1},autoBreakBeforeWrap:{type:Boolean,default:!1},autoBreakAfterWrap:{type:Boolean,default:!1},hideDefaultInput:{type:Boolean,default:!1},hidePanel:{type:Boolean,default:!1},enableTooltip:{type:Boolean,default:!0},historyKey:{type:String,default:""},favoriteKey:{type:String,default:""},extraNetworks:{type:Array,default:()=>[]},loras:{type:Array,default:()=>[]},lycos:{type:Array,default:()=>[]},embeddings:{type:Array,default:()=>[]},version:{type:String,default:""},latestVersion:{type:String,default:""},isLatestVersion:{type:Boolean,default:!0},theme:{type:String,default:"dark"},groupTags:{type:Array,default:()=>[]},hideGroupTags:{type:Boolean,default:!1},groupTagsColor:{type:Object,default:()=>({})},groupTagsColorKeyCache:{type:Object,default:()=>({})},blacklist:{type:Object,default:()=>({})},cancelBlacklistConfirm:{type:Boolean,default:!1},hotkey:{type:Object,default:()=>({})}},emits:["update:languageCode","update:autoTranslate","update:autoTranslateToEnglish","update:autoTranslateToLocal","update:autoRemoveSpace","update:autoRemoveLastComma","update:autoKeepWeightZero","update:autoKeepWeightOne","update:hideDefaultInput","update:hidePanel","update:enableTooltip","update:translateApi","click:translateApi","click:promptFormat","click:blacklist","click:hotkey","click:selectTheme","click:switchTheme","click:showAbout","click:selectLanguage","click:showHistory","click:showFavorite","refreshFavorites","click:showChatgpt","update:hideGroupTags","update:groupTagsColor","update:blacklist","showExtraNetworks","hideExtraNetworks"],data(){return{prompt:"",counterText:"0/75",tags:[],sortable:null,droping:!1,loading:{},editing:{}}},computed:{isEnglish(){return this.languageCode==="en_US"},translateApiItem(){return he.getTranslateApiItem(this.translateApis,this.translateApi)}},watch:{loras:{handler(){this.tags.forEach(e=>{this._setTagClass(e)})},immediate:!1},lycos:{handler(){this.tags.forEach(e=>{this._setTagClass(e)})},immediate:!1},embeddings:{handler(){this.tags.forEach(e=>{this._setTagClass(e)})},immediate:!1}},mounted(){this.$nextTick(()=>{this.initSortable();let e=[1e3,3e3,5e3,1e4,2e4,3e4],t=!1;e.forEach(n=>{t||setTimeout(()=>{t||typeof addAutocompleteToArea=="function"&&typeof TAC_CFG=="object"&&TAC_CFG&&TAC_CFG.activeIn&&(t=!0,addAutocompleteToArea(this.$refs.promptTagAppend))},n)}),this.init()})},methods:{init(){this.tags=[],this.onTextareaChange();let e=this.textarea.value;setInterval(()=>{let t=this.textarea.value;e!==t&&document.activeElement!==this.textarea&&(e=t,this.onTextareaChange(!0))},500)},onTextareaChange(e){this.onTextareaChangeTimeId&&clearTimeout(this.onTextareaChangeTimeId),this.onTextareaChangeTimeId=setTimeout(()=>{this._onTextareaChange(e)},100)},_onTextareaChange(e){console.log("onTextareaChange",e);const t=this.textarea.parentElement.getElementsByClassName("autocompleteParent");if(t.length){if(t[0].style.display!=="none")return}else{const l=this.textarea.parentElement.getElementsByClassName("autocompleteResults");if(l.length>0&&l[0].style.display!=="none")return}let n=this.textarea.value.trim();if(n===this.prompt.trim())return;let r=he.splitTags(n,this.autoBreakBeforeWrap,this.autoBreakAfterWrap),i=[];this.tags.forEach((l,c)=>{l.disabled&&i.push({tag:l,index:c})}),i.forEach(({tag:l,index:c})=>{r.splice(c,0,l.value)});let o=[],s=this.tags;this.tags=[];for(let l in r){let c=r[l];if(c===`
|
||
`)this._appendTag(`
|
||
`,`
|
||
`,!1,-1,"wrap");else{let d=!1;for(let C of s)if(C.value===c){d=C;break}const p=d?d.localValue:"",y=d?d.disabled:!1,m=this._appendTag(c,p,y,-1,"text");!d&&m!==-1&&o.push(m)}}if(this.autoTranslateToLocal&&e){let l=!(this.tagCompleteFile&&this.onlyCsvOnAuto);l=!1,this.translates(o,!0,l).finally(()=>{this.updateTags()})}else this.updateTags()},_setTextareaFocus(){if(typeof get_uiCurrentTabContent!="function"||typeof activePromptTextarea!="object")return;const e=get_uiCurrentTabContent();if(!e)return;let t=e.id.replace("tab_","");t&&(activePromptTextarea[t]=this.textarea)},copy(e){this.$copyText(e).then(()=>{this.$toastr.success(this.getLang("success"))}).catch(()=>{this.$toastr.error(this.getLang("failed"))})},genPrompt(e=null,t=!1){e=e||this.tags;let n=[],r=e.length;return e.forEach((i,o)=>{let s="";if(typeof i.type=="string"&&i.type==="wrap")s=`
|
||
`;else{let l=he.replaceTag(i.value);l!==i.value&&(i.value=l,this._setTag(i));let c=he.replaceTag(i.localValue);if(c!==i.localValue&&(i.localValue=c),(i.weightNum>0||i.weightNum<0)&&(i.weightNum=Number(parseFloat(i.weightNum).toFixed(6)),i.value=i.value.replace(he.weightNumRegex,"$1:"+i.weightNum),i.localValue!==""&&(i.localValue=i.localValue.replace(he.weightNumRegex,"$1:"+i.weightNum))),i.disabled&&!t)return;let d=","+(this.autoRemoveSpace?"":" "),p=null,y=!1;if(o+1<r&&(p=e[o+1],typeof p.type=="string"&&p.type==="wrap"?y=!0:p.value),y){const m=[" BREAK"," ADDCOL"," ADDROW"," ADDCOMM"," ADDBASE"];for(const C of m)i.value.endsWith(C)&&(d="")}i.value==="BREAK"&&(y?d="":d=" "),this.autoRemoveLastComma&&o+1===r&&(d=""),s=i.value+d}s&&n.push(s)}),n.length<=0?"":n.join("")},updatePrompt(){let e=[],t=this.tags.length;for(let n=0;n<t;n++)if(this.tags[n].value==="BREAK"){if(this.autoBreakBeforeWrap&&n-1>=0){let i=this.tags[n-1];typeof i.type=="string"&&i.type==="wrap"||e.push(n)}if(this.autoBreakAfterWrap&&n+1<t){let i=this.tags[n+1];typeof i.type=="string"&&i.type==="wrap"||e.push(n+1)}}for(let n=0;n<e.length;n++){let r=e[n]+n;this._appendTag(`
|
||
`,`
|
||
`,!1,r,"wrap")}if(e.length){this.updateTags();return}this.prompt=this.genPrompt(),this.textarea.value=this.prompt,he.hideCompleteResults(this.textarea),typeof updateInput=="function"?updateInput(this.textarea):this.textarea.dispatchEvent(new Event("input"))},updateTags(){console.log("tags change",this.tags),this.updatePrompt();const e=this.steps.querySelector('input[type="number"]').value;this.gradioAPI.tokenCounter(this.textarea.value,e).then(t=>{const{token_count:n,max_length:r}=t;this.counterText=`${n}/${r}`}),this.tags.length&&this.gradioAPI.getLatestHistory(this.historyKey).then(t=>{t&&t.prompt===this.prompt?this.gradioAPI.setHistory(this.historyKey,t.id,this.tags,this.prompt,t.name).then(n=>{}).catch(n=>{}):this.gradioAPI.pushHistory(this.historyKey,this.tags,this.prompt).then(n=>{}).catch(n=>{})}).catch(t=>{}),this.$nextTick(()=>{for(let t=0;t<this.$refs.promptTagsList.children.length;t++){let n=this.$refs.promptTagsList.children[t];if(!n.classList.contains("prompt-tag"))continue;let r=n.getAttribute("data-id"),i=this.$refs.promptTagWrap.find(o=>o.getAttribute("data-id")===r);i&&n.parentNode.insertBefore(i,n.nextElementSibling)}})},onResize(){this.tags.forEach(e=>{this._setTagHeight(e)})},initSortable(){this.sortable=Je.create(this.$refs.promptTagsList,{animation:150,handle:".prompt-tag-value",draggable:".prompt-tag",onEnd:e=>{if(this.dropTags.length){let n=e.item,r=n.getAttribute("data-id"),i=this._getDropTagsEle(),o=i.findIndex(c=>c.getAttribute("data-id")===r),s=i.slice(0,o),l=i.slice(o+1).reverse();s.forEach(c=>{he.insertBefore(c,n)}),l.forEach(c=>{he.insertAfter(c,n)})}this._dropOver(),this.droping=!1;let t=[];for(let n=0;n<this.$refs.promptTagsList.children.length;n++){let r=this.$refs.promptTagsList.children[n];if(!r.classList.contains("prompt-tag"))continue;let i=r.getAttribute("data-id");t.push(i)}this.tags=this.tags.sort((n,r)=>t.indexOf(n.id)-t.indexOf(r.id)),this.$forceUpdate(),this.updateTags()},onChoose:e=>{if(console.log(e),this.dropTags.length){let n=e.item.getAttribute("data-id");this._getDropTagsEle().forEach(i=>{i.getAttribute("data-id")!==n&&(i.style.display="block",i.style.transition="transform 0.2s",i.style.transform="scale(0)",setTimeout(()=>{i.style.transition="",i.style.transform="",i.style.display="none"},300))})}this.editing={},this.droping=!0},onUnchoose:e=>{if(this.droping=null,this.dropTags.length){let n=e.item.getAttribute("data-id");this._getDropTagsEle().forEach(i=>{i.getAttribute("data-id")!==n&&(i.style.display="")})}}})},useHistory(e){this.tags=[],e.tags.forEach(t=>{this._appendTag(t.value,t.localValue,t.disabled,-1,t.type||"text")}),this.updateTags()},useFavorite(e){this.useHistory(e)},useChatgpt(e){let t=he.splitTags(e,this.autoBreakBeforeWrap,this.autoBreakAfterWrap);this.tags=[],t.forEach(n=>{this._appendTag(n,"",!1,-1,"text")}),this.updateTags()},onPromptMainClick(){this.onTextareaChange(!0),this._setTextareaFocus(),this.showExtendId=""},translates(e,t=!1,n=!0){return new Promise((r,i)=>{if(this.languageCode==="en_US"||this.languageCode==="en_GB"){r();return}let o=[],s=(C,b)=>{C.forEach(k=>{l(k,b)})},l=(C,b)=>{this.canOneTranslate?(this.loading[C.id+"_local"]=b,this.loading[C.id+"_en"]=b):C.toLocal?this.loading[C.id+"_local"]=b:this.loading[C.id+"_en"]=b},c=(C,b)=>{C.toLocal?C.localValue=b:(C.localValue=C.value,C.value=b),this._setTagById(C.id,C.value,C.localValue)},d=C=>C.isLora&&C.loraExists?this.getExtraNetworkFullName(C.loraName,"lora"):C.isLyco&&C.lycoExists?this.getExtraNetworkFullName(C.lycoName,"lycoris"):C.isEmbedding?this.getExtraNetworkFullName(C.value,"textual inversion"):C.value;e.forEach(C=>{var L,O,$,X;let b=this.tags[C],k=d(b);if(k!==b.value){b.localValue=k;return}if(he.canTranslate(b.value)){if(b.isLora){if((L=this.blacklist.translate)!=null&&L.includes(b.loraName.toLowerCase()))return}else if(b.isLyco){if((O=this.blacklist.translate)!=null&&O.includes(b.lycoName.toLowerCase()))return}else if(b.isEmbedding){if(($=this.blacklist.translate)!=null&&$.includes(b.embeddingName.toLowerCase()))return}else if((X=this.blacklist.translate)!=null&&X.includes(b.originalValue.toLowerCase()))return;if(b.isEnglish=he.isEnglishByLangCode(b.value,this.languageCode),b.isEnglish===-1)t?b.toLocal=!0:b.toLocal=!1;else if(b.isEnglish===0)if(t)if(b.localValue==="")b.localValue=b.value,b.toLocal=!1;else{const x=b.value;b.value=b.localValue,b.localValue=x}else b.toLocal=!1;else b.toLocal=!0;l(b,!0),o.push(b)}});const p=C=>{if(C.length<=0){s(C,!1),r();return}let b={};C.forEach((L,O)=>{let $=L.toLocal?"en_US":this.languageCode,X=L.toLocal?this.languageCode:"en_US",x=$+"."+X;b[x]||(b[x]={fromLang:$,toLang:X,tags:[]}),b[x].tags.push(L)});const k=()=>{let L=b[Object.keys(b)[0]];if(!L){r();return}let O=L.tags.map($=>d($));this.gradioAPI.translates(O,L.fromLang,L.toLang,this.translateApi,this.translateApiConfig).then($=>{$.success?($.translated_text.forEach((x,z)=>{x=x.replace(/\.$/,"").trim(),he.isEnglish(x)&&x!==x.toUpperCase()&&(x=x.toLowerCase());let Q=L.tags[z];x!==""&&c(Q,x),l(Q,!1)}),delete b[Object.keys(b)[0]],k()):(s(C,!1),this.$toastr.error($.message),i($.message))}).catch($=>{s(C,!1),this.$toastr.error($.message),i($.message)})};k()};let y=C=>{console.log("translateByCSV",C.map(k=>k.value),{useNetwork:n});let b=[];C.forEach(k=>{const L=he.splitTag(k.value);L.value!==k.value&&(k.value=L.value,k.splits=L),k.toLocal?b.push(this.translateToLocalByCSV(k.value,void 0,void 0,n)):b.push(this.translateToEnByCSV(k.value))}),Promise.all(b).then(k=>{let L=[];k.forEach((O,$)=>{let X=C[$];X.splits&&(X.value=X.splits.left+X.value+X.splits.right),O===""?L.push(X):(X.splits&&(O=X.splits.left+O+X.splits.right),l(X,!1),c(X,O))}),console.log("No translated keywords: ",L.map(O=>O.value)),n?p(L):(s(L,!1),r())}).catch(k=>{s(C,!1),this.$toastr.error(k),i(k)})},m=C=>{console.log("translateByGroupTags",C.map(k=>k.value),{useNetwork:n});let b=[];C.forEach(k=>{const L=he.splitTag(k.value);L.value!==k.value&&(k.value=L.value,k.splits=L),k.toLocal?b.push(this.translateToLocalByGroupTags(k.value,n)):b.push(this.translateToEnByGroupTags(k.value,n))}),Promise.allSettled(b).then(k=>{let L=[],O=[];if(k.forEach(($,X)=>{var z;let x=C[X];x.splits&&(x.value=x.splits.left+x.value+x.splits.right),$.status!=="fulfilled"&&L.push($.reason),!((z=$.value)!=null&&z.length)||$.status!=="fulfilled"?O.push(x):(x.splits&&($=x.splits.left+$.value+x.splits.right),l(x,!1),c(x,$.value))}),console.log("No translated keywords: ",O.map($=>$.value)),this.tagCompleteFile)y(O);else{if(L.length){s(C,!1),this.$toastr.error(L[0]),i(L[0]);return}n?p(O):(s(O,!1),r())}}).catch(k=>{s(C,!1),this.$toastr.error(k),i(k)})};this.groupTagsTranslate?m(o):this.tagCompleteFile?y(o):n?p(o):(s(o,!1),r())})}}},LI=["name"],OI={class:"prompt-header"},II={class:"prompt-header-title"},PI={class:"prompt-header-extend"},DI={class:"extend-content"},RI={class:"extend-btn-group"},NI={key:0,class:"gradio-checkbox hover-scale-120"},MI=["checked"],FI={class:"gradio-checkbox hover-scale-120"},BI=["checked"],$I={class:"gradio-checkbox hover-scale-120"},HI=["checked"],jI={class:"gradio-checkbox hover-scale-120"},UI=["checked"],WI={class:"gradio-checkbox"},KI={value:"disabled"},VI={value:"last"},qI=["label"],zI=["value"],GI={class:"prompt-header-extend"},YI={class:"extend-content"},XI={class:"extend-btn-group"},JI={key:0,class:"prompt-header-extend"},ZI={class:"extend-content"},QI={class:"extend-btn-group"},e2={class:"prompt-header-extend"},t2={class:"extend-content"},n2={class:"extend-btn-group"},r2={key:1,class:"prompt-header-extend"},i2={class:"extend-content"},o2={class:"extend-btn-group"},s2={class:"prompt-header-extend prompt-append"},a2={class:"extend-content"},l2={class:"gradio-checkbox hover-scale-120"},u2={key:0},c2=["checked"],f2={key:1},d2=["checked"],p2=["placeholder"],h2=["onClick"],g2={class:"arrow-right"},m2=["onMouseleave","onMouseenter","onClick"],v2={key:0,class:"tags-name"},y2={key:1,class:"tags-name"},b2={class:"tags-detail"},C2={class:"tags-list"},_2={key:0,class:"item-wrap"},w2={key:1,class:"tags-item"},T2={class:"item-tag-value"},k2={class:"item-tag-local-value"},x2={class:"prompt-tags-list",ref:"promptTagsList"},S2=["data-id"],A2=["onMouseenter","onMousemove","onMouseleave"],E2={class:"prompt-tag-edit"},L2=["onClick","onDblclick","onContextmenu","innerHTML"],O2=["placeholder","value","onBlur","onKeydown","onChange"],I2=["onClick"],P2=["onClick"],D2=["onClick"],R2=["onClick"],N2=["onClick"],M2=["onClick"],F2=["onClick"],B2=["onClick"],$2=["onClick"],H2=["onClick"],j2=["onClick"],U2={class:"prompt-local-language"},W2=["onClick"],K2={class:"local-language"},V2=["data-id"],q2={class:"btns-title"},z2={class:"group-tabs"},G2={class:"group-header",ref:"groupTabsHeader"},Y2=["onClick","data-name"],X2={class:"group-body"},J2={key:0,class:"sub-group-header"},Z2=["onClick","data-name"],Q2={key:1,class:"sub-group-body"},eP={key:0,class:"group-tags"},tP=["onClick"],nP={class:"tag-local"},rP={class:"tag-en"},iP={key:0,class:"sub-group-header"},oP=["onClick","data-name"],sP={key:1,class:"sub-group-body"},aP={key:0,class:"group-tags"},lP=["onClick"],uP={class:"tag-en"},cP={class:"tags-footer"},fP={class:"tags-color"},dP={class:"tags-color-picker hover-scale-120",unaffected:"true"},pP=["onClick"],hP=["onClick"],gP={class:"tags-copyright"};function mP(e,t,n,r,i,o){const s=Ye("icon-svg"),l=Ye("vue-number-input"),c=Ye("color-picker"),d=Ye("highlight-prompt"),p=To("tooltip"),y=To("animate");return E(),M("div",{class:"physton-prompt",name:n.name},[T("div",{class:Ge(["prompt-main",n.hidePanel?"fold":""]),onClick:t[59]||(t[59]=(...m)=>o.onPromptMainClick&&o.onPromptMainClick(...m))},[T("div",OI,[ge((E(),M("div",{class:"prompt-unfold",onClick:t[0]||(t[0]=(...m)=>e.onUnfoldClick&&e.onUnfoldClick(...m))},[ye(s,{class:"hover-scale-120",name:"unfold"})])),[[p,e.getLang(n.hidePanel?"show_panel":"hide_panel")]]),T("div",II,ie(n.neg?e.getLang("negative_prompt"):e.getLang("prompt")),1),ge(T("div",{class:"prompt-header-counter"},"("+ie(i.counterText)+")",513),[[Ot,i.counterText]]),T("div",PI,[T("div",DI,[T("div",RI,[ge((E(),M("div",{class:"extend-btn-item",onClick:t[1]||(t[1]=m=>e.$emit("click:selectLanguage",m))},[ye(s,{class:"hover-scale-120",name:"i18n"})])),[[p,"Language: "+e.langName]]),T("div",{class:Ge(["extend-btn-item",n.isLatestVersion?"":"red-dot"])},[ge(ye(s,{class:"hover-scale-120",name:"setting"},null,512),[[p,e.getLang("setting_desc")]]),ge((E(),M("div",{class:"setting-box",onMouseenter:t[15]||(t[15]=(...m)=>e.onSettingBoxMouseEnter&&e.onSettingBoxMouseEnter(...m))},[o.translateApiItem.name&&!o.isEnglish?ge((E(),M("div",{key:0,class:"extend-btn-item",onClick:t[2]||(t[2]=m=>e.$emit("click:translateApi",m))},[ye(s,{class:"hover-scale-120",name:"api"})])),[[p,e.getLang("translate_api")+": "+o.translateApiItem.name]]):ke("",!0),ge((E(),M("div",{class:"extend-btn-item",onClick:t[3]||(t[3]=m=>e.$emit("click:promptFormat",m))},[ye(s,{class:"hover-scale-120",name:"format"})])),[[p,e.getLang("prompt_format")]]),ge((E(),M("div",{class:"extend-btn-item",onClick:t[4]||(t[4]=m=>e.$emit("click:blacklist",m))},[ye(s,{class:"hover-scale-120",name:"blacklist"})])),[[p,e.getLang("keywords_blacklist")]]),ge((E(),M("div",{class:"extend-btn-item",onClick:t[5]||(t[5]=m=>e.$emit("click:hotkey",m))},[ye(s,{class:"hover-scale-120",name:"hotkey"})])),[[p,e.getLang("hotkey_setting")]]),ge((E(),M("div",{class:"extend-btn-item",onClick:t[6]||(t[6]=m=>e.$emit("click:selectTheme",m))},[ye(s,{class:"hover-scale-120",name:"theme"})])),[[p,e.getLang("theme_extension")]]),ge((E(),M("div",{class:"extend-btn-item",onClick:t[7]||(t[7]=m=>e.$emit("click:switchTheme",m))},[ye(s,{class:"hover-scale-120",name:n.theme==="dark"?"sun":"moon"},null,8,["name"])])),[[p,e.getLang(n.theme==="dark"?"switch_to_light_theme":"switch_to_dark_theme")]]),ge((E(),M("div",{class:Ge(["extend-btn-item",n.isLatestVersion?"":"red-dot"]),onClick:t[8]||(t[8]=m=>e.$emit("click:showAbout",m))},[ye(s,{class:"hover-scale-120",name:"about"})],2)),[[p,e.getLang("about_desc")]]),o.isEnglish?ke("",!0):(E(),M(De,{key:1},[n.canOneTranslate?(E(),M("div",NI,[ge((E(),M("label",null,[T("input",{type:"checkbox",name:"auto_translate",value:"1",checked:n.autoTranslate,onChange:t[9]||(t[9]=m=>e.$emit("update:autoTranslate",m.target.checked))},null,40,MI),ye(s,{name:"translate"})])),[[p,e.getLang("auto_translate")]])])):(E(),M(De,{key:1},[T("div",FI,[ge((E(),M("label",null,[T("input",{type:"checkbox",name:"auto_translate_to_local_language",value:"1",checked:n.autoTranslateToLocal,onChange:t[10]||(t[10]=m=>e.$emit("update:autoTranslateToLocal",m.target.checked))},null,40,BI),ye(s,{name:"translate"})])),[[p,e.getLang("auto_translate_to_local_language")]])]),T("div",$I,[ge((E(),M("label",null,[T("input",{type:"checkbox",name:"auto_translate_to_english",value:"1",checked:n.autoTranslateToEnglish,onChange:t[11]||(t[11]=m=>e.$emit("update:autoTranslateToEnglish",m.target.checked))},null,40,HI),ye(s,{name:"english"})])),[[p,e.getLang("auto_translate_to_english")]])])],64))],64)),T("div",jI,[ge((E(),M("label",null,[T("input",{type:"checkbox",name:"enable_tooltip",value:"1",checked:n.enableTooltip,onChange:t[12]||(t[12]=m=>e.$emit("update:enableTooltip",m.target.checked))},null,40,UI),ye(s,{name:"tooltip"})])),[[p,e.getLang("whether_to_enable_tooltip")]])]),T("div",WI,[ge((E(),M("label",null,[ge(T("select",{"onUpdate:modelValue":t[13]||(t[13]=m=>e.autoInputPrompt=m),onChange:t[14]||(t[14]=(...m)=>e.onAutoInputPromptChange&&e.onAutoInputPromptChange(...m))},[T("option",KI,ie(e.getLang("auto_input_prompt"))+": "+ie(e.getLang("disabled")),1),T("option",VI,ie(e.getLang("last_input_prompt")),1),(E(!0),M(De,null,ot(e.getCurrentTypeFavorites(),m=>(E(),M("optgroup",{key:m.key,label:e.getLang("favorite")+" / "+e.getLang(m.name)},[(E(!0),M(De,null,ot(m.list,C=>(E(),M("option",{value:C.id},ie(C.name||C.prompt.substring(0,40)),9,zI))),256))],8,qI))),128))],544),[[Eo,e.autoInputPrompt]])])),[[p,e.getLang("auto_input_prompt")]])])],32)),[[y,"fadeIn"]])],2)])])]),T("div",GI,[T("div",YI,[T("div",XI,[ge((E(),M("div",{class:"extend-btn-item",ref:"historyButton",onClick:t[16]||(t[16]=m=>e.$emit("click:showHistory",m))},[ye(s,{class:"hover-scale-120",name:"history"})])),[[p,e.getLang("history")]]),ge((E(),M("div",{class:"extend-btn-item",ref:"favoriteButton",onClick:t[17]||(t[17]=m=>e.$emit("click:showFavorite",m))},[ye(s,{class:"hover-scale-120",name:"favorite"})])),[[p,e.getLang("favorite")]])])])]),o.isEnglish?ke("",!0):(E(),M("div",JI,[T("div",ZI,[T("div",QI,[n.canOneTranslate?ge((E(),M("div",{key:0,class:"extend-btn-item",onClick:t[18]||(t[18]=(...m)=>e.onTranslatesToLocalClick&&e.onTranslatesToLocalClick(...m))},[i.loading.all_local?ke("",!0):(E(),Ue(s,{key:0,class:"hover-scale-120",name:"translate"})),i.loading.all_local?(E(),Ue(s,{key:1,class:"hover-scale-120",name:"loading"})):ke("",!0)])),[[p,e.getLang("one_translate_all_keywords")]]):(E(),M(De,{key:1},[ge((E(),M("div",{class:"extend-btn-item",onClick:t[19]||(t[19]=(...m)=>e.onTranslatesToLocalClick&&e.onTranslatesToLocalClick(...m))},[i.loading.all_local?ke("",!0):(E(),Ue(s,{key:0,class:"hover-scale-120",name:"translate"})),i.loading.all_local?(E(),Ue(s,{key:1,class:"hover-scale-120",name:"loading"})):ke("",!0)])),[[p,e.getLang("translate_keywords_to_local_language")]]),ge((E(),M("div",{class:"extend-btn-item",onClick:t[20]||(t[20]=(...m)=>e.onTranslatesToEnglishClick&&e.onTranslatesToEnglishClick(...m))},[i.loading.all_en?ke("",!0):(E(),Ue(s,{key:0,class:"hover-scale-120",name:"english"})),i.loading.all_en?(E(),Ue(s,{key:1,class:"hover-scale-120",name:"loading"})):ke("",!0)])),[[p,e.getLang("translate_all_keywords_to_english")]])],64))])])])),T("div",e2,[T("div",t2,[T("div",n2,[ge((E(),M("div",{class:"extend-btn-item",onClick:t[21]||(t[21]=(...m)=>e.onCopyAllTagsClick&&e.onCopyAllTagsClick(...m))},[ye(s,{class:"hover-scale-120",name:"copy"})])),[[p,e.getLang("copy_keywords_to_clipboard")]]),ge((E(),M("div",{class:"extend-btn-item",onClick:t[22]||(t[22]=(...m)=>e.onDeleteAllTagsClick&&e.onDeleteAllTagsClick(...m))},[ye(s,{class:"hover-scale-120",name:"remove"})])),[[p,e.getLang("delete_all_keywords")]])])])]),n.neg?ke("",!0):(E(),M("div",r2,[T("div",i2,[T("div",o2,[ge((E(),M("div",{class:"extend-btn-item",onClick:t[23]||(t[23]=m=>e.$emit("click:showChatgpt",m))},[ye(s,{class:"hover-scale-120",name:"chatgpt"})])),[[p,e.getLang("use_chatgpt_gen_prompts")]])])])])),T("div",s2,[T("div",a2,[T("div",l2,[n.hideDefaultInput?ge((E(),M("label",u2,[T("input",{type:"checkbox",name:"hide_default_input",value:"1",checked:!n.hideDefaultInput,onChange:t[24]||(t[24]=m=>e.$emit("update:hideDefaultInput",!m.target.checked))},null,40,c2),ye(s,{name:"input"})])),[[p,e.getLang("show_default_input_box")]]):ge((E(),M("label",f2,[T("input",{type:"checkbox",name:"hide_default_input",value:"1",checked:!n.hideDefaultInput,onChange:t[25]||(t[25]=m=>e.$emit("update:hideDefaultInput",!m.target.checked))},null,40,d2),ye(s,{name:"input"})])),[[p,e.getLang("hide_default_input_box")]])]),ge(T("textarea",{type:"text",class:"scroll-hide svelte-4xt1ch input-tag-append",ref:"promptTagAppend",placeholder:e.getLang("please_enter_new_keyword"),onFocus:t[26]||(t[26]=(...m)=>e.onAppendTagFocus&&e.onAppendTagFocus(...m)),onBlur:t[27]||(t[27]=(...m)=>e.onAppendTagBlur&&e.onAppendTagBlur(...m)),onKeyup:t[28]||(t[28]=(...m)=>e.onAppendTagKeyUp&&e.onAppendTagKeyUp(...m)),onKeydown:t[29]||(t[29]=(...m)=>e.onAppendTagKeyDown&&e.onAppendTagKeyDown(...m))},null,40,p2),[[p,e.getLang("enter_to_add")]]),ge(T("div",{class:"prompt-append-list",ref:"promptAppendList",style:St(e.appendListStyle)},[(E(!0),M(De,null,ot(e.appendList,(m,C)=>(E(),M("div",{key:m.type,class:Ge(["prompt-append-group",e.appendListSelected===C?"selected":""])},[T("div",{class:"append-group-name",onClick:b=>e.onAppendGroupClick(C,null,b)},[m.icon==="wrap"?(E(),Ue(s,{key:0,class:"name-icon",name:"wrap"})):m.icon==="history"?(E(),Ue(s,{key:1,class:"name-icon",name:"history"})):m.icon==="favorite"?(E(),Ue(s,{key:2,class:"name-icon",name:"favorite"})):ke("",!0),jt(" "+ie(e.appendListItemName(m))+" ",1),ge(T("span",g2,null,512),[[Ot,m.children.length>0]])],8,h2),ye(un,{name:"fade"},{default:tn(()=>[ge(T("div",{class:"append-group-list",ref_for:!0,ref:"promptAppendListChildren"},[(E(!0),M(De,null,ot(m.children,(b,k)=>(E(),M("div",{key:k,ref_for:!0,ref:"promptAppendListChild",class:Ge(["append-item",e.appendListChildSelected===k?"selected":""]),onMouseleave:L=>e.onAppendListChildMouseLeave(C,k,L),onMouseenter:L=>e.onAppendListChildMouseEnter(C,k,L),onClick:L=>e.onAppendGroupClick(C,k,L)},[m.type==="favorite"||m.type==="history"?(E(),M(De,{key:0},[b.name?(E(),M("div",v2,ie(b.name),1)):(E(),M("div",y2,ie(b.prompt),1))],64)):ke("",!0)],42,m2))),128))],512),[[Ot,m.children.length>0]])]),_:2},1024),ye(un,{name:"fade"},{default:tn(()=>[ge(T("div",b2,[T("div",C2,[(E(!0),M(De,null,ot(e.appendListChildItemTags,(b,k)=>(E(),M(De,{key:k},[b.type&&b.type==="wrap"?(E(),M("div",_2)):(E(),M("div",w2,[T("div",T2,ie(b.value),1),T("div",k2,ie(b.localValue),1)]))],64))),128))])],512),[[Ot,e.appendListSelected!==null&&e.appendListChildSelected!==null&&e.appendListSelected===C&&(m.type==="favorite"||m.type==="history")]])]),_:2},1024)],2))),128))],4),[[Ot,e.showAppendList]])])])]),T("div",{class:Ge(["prompt-tags",i.droping?"droping":"",e.dropIsSelecting||e.dropIsEnd&&e.dropTags.length?"selecting":""]),ref:"promptTags",onMousedown:t[54]||(t[54]=(...m)=>e.onDropMouseDown&&e.onDropMouseDown(...m)),onMousemove:t[55]||(t[55]=(...m)=>e.onDropMouseMove&&e.onDropMouseMove(...m)),onMouseup:t[56]||(t[56]=(...m)=>e.onDropMouseUp&&e.onDropMouseUp(...m))},[T("div",x2,[(E(!0),M(De,null,ot(i.tags,(m,C)=>(E(),M("div",{key:m.id,class:Ge(["prompt-tag",m.disabled?"disabled":"",m.type==="wrap"?"wrap-tag":""]),ref_for:!0,ref:"promptTag-"+m.id,"data-id":m.id},[T("div",{class:"prompt-tag-main",onMouseenter:b=>e.onTagMouseEnter(m.id),onMousemove:nt(b=>e.onTagMouseMove(m.id),["stop"]),onMouseleave:nt(b=>e.onTagMouseLeave(m.id),["stop"])},[T("div",E2,[m.type==="wrap"?ge((E(),M("div",{key:0,class:"prompt-tag-value",ref_for:!0,ref:"promptTagValue-"+m.id,style:{width:"100%"}},[ye(s,{name:"wrap"})])),[[p,e.getLang("line_break_character")+"<br/>"+e.getLang("drop_to_order")]]):(E(),M(De,{key:1},[ge(T("div",{class:Ge(m.classes),style:St(e.getTagColorStyle(m)),ref_for:!0,ref:"promptTagValue-"+m.id,onClick:b=>e.onTagClick(m.id,b),onDblclick:b=>e.onTagDblclick(m.id),onContextmenu:nt(b=>e.onTagRightClick(m.id,b),["right","prevent"]),innerHTML:e.renderTag(m.id)},null,46,L2),[[Ot,!i.editing[m.id]],[p,m.isLora||m.isLyco?"":e.getLang("click_to_edit")+"<br/>"+e.getLang("dblclick_to_disable")+"<br/>"+e.getLang("drop_to_order")]]),ge(T("textarea",{type:"text",class:"scroll-hide svelte-4xt1ch input-tag-edit",ref_for:!0,ref:"promptTagEdit-"+m.id,placeholder:e.getLang("enter_to_save"),value:m.value,onMousedown:t[30]||(t[30]=nt(()=>{},["stop"])),onMousemove:t[31]||(t[31]=nt(()=>{},["stop"])),onMouseup:t[32]||(t[32]=nt(()=>{},["stop"])),onBlur:b=>e.onTagInputBlur(m.id),onKeydown:b=>e.onTagInputKeyDown(m.id,b),onChange:b=>e.onTagInputChange(m.id,b)},null,40,O2),[[Ot,i.editing[m.id]]])],64)),T("div",{class:"btn-tag-delete",ref_for:!0,ref:"promptTagDelete-"+m.id,onClick:b=>e.onDeleteTagClick(m.id),onMousedown:t[33]||(t[33]=nt(()=>{},["stop"])),onMousemove:t[34]||(t[34]=nt(()=>{},["stop"])),onMouseup:t[35]||(t[35]=nt(()=>{},["stop"]))},[ye(s,{name:"close"})],40,I2)]),ge((E(),M("div",{class:"btn-tag-extend",style:St({display:(m.type==="text"||!m.type)&&e.showExtendId===m.id?"flex":"none"}),onClick:t[36]||(t[36]=nt(()=>{},["stop"])),onMousedown:t[37]||(t[37]=nt(()=>{},["stop"])),onMousemove:t[38]||(t[38]=nt(()=>{},["stop"])),onMouseup:t[39]||(t[39]=nt(()=>{},["stop"]))},[ye(l,{class:"input-number",name:"input-number","model-value":m.weightNum,center:"",controls:"",min:-100,step:.1,size:"small","onUpdate:modelValue":b=>e.onTagWeightNumChange(m.id,b)},null,8,["model-value","onUpdate:modelValue"]),ge((E(),M("button",{type:"button",name:"weight-parentheses-inc",onClick:b=>e.onIncWeightClick(m.id,1)},[ye(s,{name:"weight-parentheses-inc"})],8,P2)),[[p,e.getLang("increase_weight_add_parentheses")]]),ge((E(),M("button",{type:"button",name:"weight-parentheses-dec",onClick:b=>e.onIncWeightClick(m.id,-1)},[ye(s,{name:"weight-parentheses-dec"})],8,D2)),[[p,e.getLang("increase_weight_subtract_parentheses")]]),ge((E(),M("button",{type:"button",name:"weight-brackets-inc",onClick:b=>e.onDecWeightClick(m.id,1)},[ye(s,{name:"weight-brackets-inc"})],8,R2)),[[p,e.getLang("decrease_weight_add_brackets")]]),ge((E(),M("button",{type:"button",name:"weight-brackets-dec",onClick:b=>e.onDecWeightClick(m.id,-1)},[ye(s,{name:"weight-brackets-dec"})],8,N2)),[[p,e.getLang("decrease_weight_subtract_brackets")]]),ge((E(),M("button",{type:"button",name:"wrap",onClick:b=>e.onWrapTagClick(m.id)},[ye(s,{name:"wrap"})],8,M2)),[[p,e.getLang("line_break_character")]]),ge((E(),M("button",{type:"button",name:"translate",onClick:b=>e.onTranslateToEnglishClick(m.id)},[i.loading[m.id+"_en"]?ke("",!0):(E(),Ue(s,{key:0,name:"english"})),i.loading[m.id+"_en"]?(E(),Ue(s,{key:1,name:"loading"})):ke("",!0)],8,F2)),[[p,e.getLang("translate_keyword_to_english")],[Ot,!o.isEnglish]]),ge((E(),M("button",{type:"button",name:"copy",onClick:b=>o.copy(m.value)},[ye(s,{name:"copy"})],8,B2)),[[p,e.getLang("copy_to_clipboard")]]),ge((E(),M("button",{type:"button",name:"favorite",onClick:b=>e.onFavoriteTagClick(m.id)},[m.isFavorite?(E(),Ue(s,{key:0,name:"favorite-yes"})):ke("",!0),m.isFavorite?ke("",!0):(E(),Ue(s,{key:1,name:"favorite-no"}))],8,$2)),[[p,e.getLang(m.isFavorite?"remove_from_favorite":"add_to_favorite")]]),ge((E(),M("button",{type:"button",name:"blacklist",onClick:b=>e.onBlacklistClick(m.id)},[ye(s,{name:"blacklist"})],8,H2)),[[p,e.getLang("add_blacklist")]]),ge((E(),M("button",{type:"button",name:"enable",onClick:b=>e.onDisabledTagClick(m.id)},[m.disabled?ke("",!0):(E(),Ue(s,{key:0,name:"disabled"})),m.disabled?(E(),Ue(s,{key:1,name:"enable"})):ke("",!0)],8,j2)),[[p,e.getLang(m.disabled?"enable_keyword":"disable_keyword")]])],36)),[[y,"fadeIn"]])],40,A2),ge(T("div",U2,[ge((E(),M("div",{class:"translate-to-local hover-scale-120",onClick:b=>e.onTranslateToLocalClick(m.id),onMousedown:t[40]||(t[40]=nt(()=>{},["stop"])),onMousemove:t[41]||(t[41]=nt(()=>{},["stop"])),onMouseup:t[42]||(t[42]=nt(()=>{},["stop"]))},[i.loading[m.id+"_local"]?ke("",!0):(E(),Ue(s,{key:0,name:"translate"})),i.loading[m.id+"_local"]?(E(),Ue(s,{key:1,name:"loading"})):ke("",!0)],40,W2)),[[p,e.getLang("translate_keyword_to_local_language")]]),T("div",K2,ie(m.localValue),1)],512),[[Ot,!o.isEnglish&&(m.type==="text"||!m.type)]])],10,S2))),128)),(E(!0),M(De,null,ot(i.tags,(m,C)=>(E(),M("div",{key:m.id,class:Ge(["prompt-wrap",m.type==="wrap"?"wrap-tag":""]),"data-id":m.id,ref_for:!0,ref:"promptTagWrap",onMousedown:t[43]||(t[43]=nt(()=>{},["stop"])),onMousemove:t[44]||(t[44]=nt(()=>{},["stop"])),onMouseup:t[45]||(t[45]=nt(()=>{},["stop"]))},null,42,V2))),128))],512),T("div",{class:"drop-select-bg",ref:"dropSelectBg",style:St({display:e.dropIsStart?"block":"none"})},null,4),T("div",{class:"drop-select-box",ref:"dropSelectBox",style:St({display:e.dropIsSelecting?"block":"none",top:e.dropArea.top+"px",left:e.dropArea.left+"px",width:e.dropArea.width+"px",height:e.dropArea.height+"px"})},null,4),T("div",{class:"drop-select-btns",ref:"dropSelectBtns",style:St({display:e.dropIsEnd&&e.dropTags.length?"flex":"none",top:e.dropEndY-32+"px",left:e.dropEndX+"px"}),onMousedown:t[51]||(t[51]=nt(()=>{},["stop"])),onMousemove:t[52]||(t[52]=nt(()=>{},["stop"])),onMouseup:t[53]||(t[53]=nt(()=>{},["stop"]))},[T("div",q2,ie(e.getLang("batch_operation")),1),ge((E(),M("button",{type:"button",onClick:t[46]||(t[46]=(...m)=>e.onDropCopy&&e.onDropCopy(...m))},[ye(s,{name:"copy"})])),[[p,e.getLang("copy_to_clipboard")]]),ge((E(),M("button",{type:"button",onClick:t[47]||(t[47]=(...m)=>e.onDropFavorite&&e.onDropFavorite(...m))},[ye(s,{name:"favorite-no"})])),[[p,e.getLang("add_to_favorite")]]),ge((E(),M("button",{type:"button",onClick:t[48]||(t[48]=(...m)=>e.onDropDisable&&e.onDropDisable(...m))},[ye(s,{name:"disabled"})])),[[p,e.getLang("disable_keyword")]]),ge((E(),M("button",{type:"button",onClick:t[49]||(t[49]=(...m)=>e.onDropEnable&&e.onDropEnable(...m))},[ye(s,{name:"enable"})])),[[p,e.getLang("enable_keyword")]]),T("button",{type:"button",onClick:t[50]||(t[50]=(...m)=>e.onDropDelete&&e.onDropDelete(...m))},[ye(s,{name:"remove"})])],36)],34),n.groupTags.length?ge((E(),M("div",{key:0,class:Ge(["show-group-tags",n.hideGroupTags?"hided":""]),onClick:t[57]||(t[57]=(...m)=>e.onClickHideGroupTags&&e.onClickHideGroupTags(...m))},[ye(s,{class:"hover-scale-120",name:"unfold"})],2)),[[p,e.getLang(n.hideGroupTags?"show_group_tags":"hide_group_tags")]]):ke("",!0),ye(un,{name:"fade"},{default:tn(()=>[ge(T("div",z2,[T("div",G2,[T("div",{class:Ge(["group-tab",e.groupTagsActive=="favorite"?"active":""]),onClick:t[58]||(t[58]=m=>e.activeGroupTab("favorite")),"data-name":"favorite"},ie(e.getLang("favorite")),3),(E(!0),M(De,null,ot(n.groupTags,(m,C)=>(E(),M("div",{key:C,class:Ge(["group-tab",m.tabKey==e.groupTagsActive?"active":""]),onClick:b=>e.activeGroupTab(C),"data-name":m.name},ie(m.name),11,Y2))),128))],512),T("div",X2,[T("div",{class:Ge(["group-main",e.groupTagsActive=="favorite"?"active":""])},[e.groupTagsActive=="favorite"?(E(),M("div",J2,[(E(!0),M(De,null,ot(e.getCurrentTypeFavorites(),m=>(E(),M("div",{key:m.key,class:Ge(["sub-group-tab","favorite-"+m.key==e.subGroupTagsActive?"active":""]),onClick:C=>e.activeSubGroupTab("favorite",m.key),"data-name":m.name},ie(e.getLang(m.name)),11,Z2))),128))])):ke("",!0),e.groupTagsActive=="favorite"?(E(),M("div",Q2,[(E(!0),M(De,null,ot(e.getCurrentTypeFavorites(),m=>(E(),M("div",{key:m.key,class:Ge(["sub-group-main","favorite-"+m.key==e.subGroupTagsActive?"active":""])},[ye(un,{name:"fade"},{default:tn(()=>["favorite-"+m.key==e.subGroupTagsActive?(E(),M("div",eP,[(E(!0),M(De,null,ot(m.list,C=>ge((E(),M("div",{class:"tag-item",ref_for:!0,ref:"groupTagItem",onClick:b=>e.onClickGroupTagFavorite(C)},[T("div",nP,ie(C.name==""?C.prompt:C.name),1),T("div",rP,ie(C.prompt),1)],8,tP)),[[p,e.getGroupTagTooltip(C.name,C.prompt)]])),256))])):ke("",!0)]),_:2},1024)],2))),128))])):ke("",!0)],2),(E(!0),M(De,null,ot(n.groupTags,(m,C)=>(E(),M("div",{key:C,class:Ge(["group-main",m.tabKey==e.groupTagsActive?"active":""])},[m.tabKey==e.groupTagsActive?(E(),M("div",iP,[(E(!0),M(De,null,ot(m.groups,(b,k)=>(E(),M("div",{key:k,class:Ge([b.type&&b.type==="wrap"?"sub-group-tag-wrap":"sub-group-tab",b.tabKey==e.subGroupTagsActive?"active":""]),onClick:L=>e.activeSubGroupTab(C,k),"data-name":b.name},ie(b.name),11,oP))),128))])):ke("",!0),m.tabKey==e.groupTagsActive?(E(),M("div",sP,[(E(!0),M(De,null,ot(m.groups,(b,k)=>(E(),M("div",{key:k,class:Ge(["sub-group-main",b.tabKey==e.subGroupTagsActive?"active":""])},[ye(un,{name:"fade"},{default:tn(()=>[b.tabKey==e.subGroupTagsActive?(E(),M("div",aP,[(E(!0),M(De,null,ot(b.tags,(L,O)=>ge((E(),M("div",{class:"tag-item",ref_for:!0,ref:"groupTagItem",onClick:$=>e.onClickGroupTag(L,O)},[L&&L!=O?(E(),M(De,{key:0},[T("div",{class:"tag-local",style:St(e.getGroupTagStyle(m.name,b.name,O))},ie(L),5),T("div",uP,ie(O),1)],64)):(E(),M("div",{key:1,class:"tag-local",style:St(e.getGroupTagStyle(m.name,b.name,O))},ie(O),5))],8,lP)),[[p,e.getGroupTagTooltip(L,O)]])),256))])):ke("",!0)]),_:2},1024),T("div",cP,[T("div",fP,[T("div",null,ie(e.getLang("tags_color"))+":",1),ge((E(),M("div",dP,[ye(c,{theme:n.theme=="dark"?"black":"white",pureColor:n.groupTagsColor[e.getTagsColorKey(m.name,b.name)],"onUpdate:pureColor":L=>n.groupTagsColor[e.getTagsColorKey(m.name,b.name)]=L,onPureColorChange:L=>e.onTagsColorChange(e.getTagsColorKey(m.name,b.name))},null,8,["theme","pureColor","onUpdate:pureColor","onPureColorChange"])])),[[p,n.groupTagsColor[e.getTagsColorKey(m.name,b.name)]]]),ge((E(),M("div",{class:"tags-color-reset hover-scale-120",onClick:L=>e.onClickResetTagsColor(e.getTagsColorKey(m.name,b.name))},[ye(s,{name:"reset"})],8,pP)),[[p,e.getLang("reset_default_color")]]),ge((E(),M("div",{class:"tags-color-clear hover-scale-120",onClick:L=>e.onClickClearTagsColor(e.getTagsColorKey(m.name,b.name))},[ye(s,{name:"clear"})],8,hP)),[[p,e.getLang("clear_color")]])]),T("div",gP,ie(e.getLang("tags-copyright")),1)])],2))),128))])):ke("",!0)],2))),128))])],512),[[Ot,!n.hideGroupTags&&n.groupTags.length]])]),_:1})],2),ye(d,{ref:"highlightPrompt",textarea:n.textarea,"hide-default-input":n.hideDefaultInput},null,8,["textarea","hide-default-input"])],8,LI)}const vP=hn(EI,[["render",mP]]),yP={name:"TranslateSetting",components:{IconSvg:Fn},mixins:[Xn],props:{},data(){return{testText:"",translateSuccess:!1,errorMessage:"",translatedText:"",loading:!1,isOpen:!1,configs:[],apiKey:"",tagCompleteFiles:[],tagCompleteFilesLoading:!1,tagCompleteFileKey:"",tagCompleteResults:[],onlyCsvOnAutoValue:!1,groupTagsTranslateValue:!0,mbart50Loading:!1,mbart50Success:!1,mbart50Message:""}},computed:{apiItem(){return he.getTranslateApiItem(this.translateApis,this.apiKey)},supportApi(){if(!this.translateApis||this.translateApis.length<=0)return[];let e=JSON.parse(JSON.stringify(this.translateApis));return e.forEach(t=>{t.children.forEach(n=>{n.disabled=!n.support[this.languageCode]})}),e}},mounted(){this.translateSuccess=!1,this.errorMessage="",this.translatedText="",this.loading=!1},emits:["update:translateApi","forceUpdate:translateApi","update:tagCompleteFile","update:onlyCsvOnAuto","update:groupTagsTranslate"],watch:{apiKey:{handler:function(e,t){this.translateSuccess=!1,this.errorMessage="",this.translatedText="",this.loading=!1,this.configs=[],this.gradioAPI.getData("translate_api."+this.apiKey).then(n=>{const r=this.apiItem;if(r&&r.config){for(const i of this.apiItem.config)n?i.value=n[i.key]||i.default:i.value=i.default||"",this.configs.push(i);console.log(this.configs)}})},immediate:!1}},methods:{open(e){this.testText=`Hi, this extension is developed by Physton. Welcome to use it!
|
||
If you have any suggestions or opinions, please feel free to raise an issue or PR on Github.
|
||
If you find this extension helpful, please give me a star on Github!
|
||
|
||
Developed by: Physton
|
||
Github: {{name}}`,this.testText=he.replaceGlobals(this.testText),this.apiKey=e,this.isOpen=!0,this.errorMessage="",this.translatedText="",this.loading=!1,this.tagCompleteFileKey=this.tagCompleteFile,this.onlyCsvOnAutoValue=this.onlyCsvOnAuto,this.groupTagsTranslateValue=this.groupTagsTranslate,this.mbart50Success=!1,this.mbart50Message="",this.refreshCSVs()},getItemName(e){let t=e.name;return t=t.replace("[Free] ","["+this.getLang("free")+"] "),t=t.replace("[ApiKey] ","["+this.getLang("apply_for_free")+"] "),t},onChangeConfigValue(e){e.type==="input"&&e.value===""&&e.default&&(e.value=e.default)},refreshCSVs(){this.tagCompleteFilesLoading||(this.tagCompleteFilesLoading=!0,this.tagCompleteFiles=[],this.gradioAPI.getCSVs().then(e=>{if(this.tagCompleteFilesLoading=!1,!(!e||e.length<=0)){this.tagCompleteFiles.push({key:"",name:this.getLang("not_enable")});for(const t of e)this.tagCompleteFiles.push({key:t.key,name:t.key})}}).catch(e=>{this.tagCompleteFilesLoading=!1}))},onTestClick(){if(this.loading)return;this.translateSuccess=!1,this.errorMessage="",this.translatedText="",this.loading=!0;let e={};for(const t of this.configs)e[t.key]=t.value;this.translate(this.testText,"en_US",this.languageCode,this.apiKey,e).then(t=>{t.success?(this.translatedText=t.translated_text,this.translateSuccess=!0):this.errorMessage=t.message,this.loading=!1}).catch(t=>{this.errorMessage=t.message,this.loading=!1})},translate(e,t,n,r=null,i=null){return new Promise(async(o,s)=>{r=r||this.translateApi,i=i||this.translateApiConfig||{},this.gradioAPI.translate(e,t,n,r,i).then(l=>{l.success?o(l):s(l)}).catch(l=>{s(l)})})},onSaveClick(){this.isOpen=!1;let e={};for(const t of this.configs)e[t.key]=t.value;this.$emit("update:translateApi",this.apiKey),this.$emit("update:tagCompleteFile",this.tagCompleteFileKey),this.$emit("update:onlyCsvOnAuto",this.onlyCsvOnAutoValue),this.$emit("update:groupTagsTranslate",this.groupTagsTranslateValue),this.gradioAPI.setData("translate_api."+this.apiKey,e).then(t=>{this.apiKey===this.translateApi&&this.$emit("forceUpdate:translateApi")})},onCloseClick(){this.isOpen=!1},onTagCompleteTestClick(){this.tagCompleteResults=[],["1girl","Robot dog"].forEach(t=>{let n=this.getLang("translate_result");this.translateToLocalByCSV(t,this.tagCompleteFileKey,!0).then(r=>{this.tagCompleteResults.push(n.replace("{0}",t).replace("{1}",r))}).catch(r=>{this.$toastr.error(r)})})},onMbart50Initialize(){this.mbart50Loading=!0,this.mbart50Success=!1,this.mbart50Message="",this.gradioAPI.mbart50Initialize().then(e=>{this.mbart50Loading=!1,e.success?(this.mbart50Success=!0,this.mbart50Message=this.getLang("initialize_finished")):this.mbart50Message=this.getLang("initialize_failed")+": "+e.message}).catch(e=>{this.mbart50Loading=!1,this.mbart50Message=e.message})}}},bP={key:0,class:"physton-prompt-translate-setting"},CP={class:"translate-setting-main"},_P={class:"translate-setting-content"},wP={class:"setting-line"},TP={class:"line-title"},kP={class:"line-content"},xP=["label"],SP=["value","disabled"],AP={key:0,class:"setting-line"},EP=T("div",{class:"line-title"},null,-1),LP={class:"line-content"},OP={class:"common-red"},IP={key:1,class:"setting-line"},PP=T("div",{class:"line-title"},null,-1),DP={class:"line-content"},RP={class:"help-list"},NP={class:"help-item"},MP=["href"],FP={class:"setting-line"},BP={class:"line-title"},$P={class:"line-content"},HP=["onUpdate:modelValue","onChange"],jP=["onUpdate:modelValue"],UP=["value"],WP=["innerHTML"],KP={key:2,class:"setting-line"},VP={class:"line-title"},qP={class:"line-content"},zP=["innerHTML"],GP=["innerHTML"],YP={key:3,class:"setting-line"},XP=T("div",{class:"line-title"},null,-1),JP={class:"line-content"},ZP={class:"setting-line"},QP={class:"line-title"},eD={class:"line-content"},tD={class:"setting-line"},nD=T("div",{class:"line-title"},null,-1),rD={class:"line-content"},iD={class:"setting-line"},oD=T("div",{class:"line-title"},null,-1),sD={class:"line-content"},aD={key:0,class:"translate-error"},lD={class:"setting-line"},uD={class:"line-title"},cD={class:"line-content"},fD=["innerHTML"],dD={class:"onlyCsvOnAuto"},pD={class:"setting-line"},hD=T("div",{class:"line-title"},"TagComplete",-1),gD={class:"line-content"},mD={class:"help-list"},vD={class:"help-item"},yD=["href"],bD=["innerHTML"],CD=["innerHTML"],_D={class:"line-row"},wD=["value"],TD={class:"setting-line"},kD=T("div",{class:"line-title"},null,-1),xD={class:"line-content"},SD={ref:"tagCompleteResults"},AD={class:"setting-btns"};function ED(e,t,n,r,i,o){const s=Ye("icon-svg"),l=To("tooltip");return E(),Ue(un,{name:"fadeDown"},{default:tn(()=>[i.isOpen?(E(),M("div",bP,[T("div",CP,[T("div",_P,[T("div",wP,[T("div",TP,ie(e.getLang("translate_api")),1),T("div",kP,[ge(T("select",{"onUpdate:modelValue":t[0]||(t[0]=c=>i.apiKey=c)},[(E(!0),M(De,null,ot(o.supportApi,c=>(E(),M("optgroup",{key:c.type,label:e.getLang(c.type)},[(E(!0),M(De,null,ot(c.children,d=>(E(),M("option",{key:d.key,value:d.key,disabled:d.disabled},ie(o.getItemName(d)),9,SP))),128))],8,xP))),128))],512),[[Eo,i.apiKey]])])]),o.apiItem&&o.apiItem.type=="translators"?(E(),M("div",AP,[EP,T("div",LP,[T("span",OP,"*"+ie(e.getLang("not_api_key_desc")),1)])])):ke("",!0),o.apiItem.help?(E(),M("div",IP,[PP,T("div",DP,[(E(!0),M(De,null,ot(o.apiItem.help,c=>(E(),M("div",RP,[T("div",NP,[jt("[?] "),T("a",{href:c.url,target:"_blank"},ie(c.title),9,MP)])]))),256))])])):ke("",!0),(E(!0),M(De,null,ot(i.configs,c=>(E(),M("div",FP,[T("div",BP,ie(c.title),1),T("div",$P,[c.type=="input"?ge((E(),M("input",{key:0,type:"text","onUpdate:modelValue":d=>c.value=d,onChange:d=>o.onChangeConfigValue(c)},null,40,HP)),[[Vn,c.value]]):ke("",!0),c.type=="select"?ge((E(),M("select",{key:1,"onUpdate:modelValue":d=>c.value=d},[(E(!0),M(De,null,ot(c.options,d=>(E(),M("option",{value:d},ie(d),9,UP))),256))],8,jP)),[[Eo,c.value]]):ke("",!0),c.desc?(E(),M("div",{key:2,innerHTML:c.desc},null,8,WP)):ke("",!0)])]))),256)),o.apiItem.key==="mbart50"?(E(),M("div",KP,[T("div",VP,ie(e.getLang("initialize")),1),T("div",qP,[T("div",{class:"hover-scale-120 test-btn",onClick:t[1]||(t[1]=(...c)=>o.onMbart50Initialize&&o.onMbart50Initialize(...c))},[i.mbart50Loading?(E(),Ue(s,{key:0,name:"loading"})):(E(),M(De,{key:1},[jt(ie(e.getLang("initialize")),1)],64))]),T("p",{class:"common-red",innerHTML:e.getLang("download_model_desc")},null,8,zP),T("p",{class:"common-red",innerHTML:e.getLang("download_model_desc2")},null,8,GP)])])):ke("",!0),o.apiItem.key==="mbart50"&&i.mbart50Message?(E(),M("div",YP,[XP,T("div",JP,[T("div",{class:Ge([i.mbart50Success?"":"common-red"])},ie(i.mbart50Message),3)])])):ke("",!0),T("div",ZP,[T("div",QP,ie(e.getLang("translate_test")),1),T("div",eD,[ge(T("textarea",{class:"test-input","onUpdate:modelValue":t[2]||(t[2]=c=>i.testText=c)},null,512),[[Vn,i.testText]])])]),T("div",tD,[nD,T("div",rD,[T("div",{class:"hover-scale-120 test-btn",onClick:t[3]||(t[3]=(...c)=>o.onTestClick&&o.onTestClick(...c))},[i.loading?(E(),Ue(s,{key:0,name:"loading"})):(E(),M(De,{key:1},[jt(ie(e.getLang("test")),1)],64))])])]),T("div",iD,[oD,T("div",sD,[!i.translateSuccess&&i.errorMessage?(E(),M("div",aD,ie(i.errorMessage),1)):ke("",!0),i.translatedText?ge((E(),M("textarea",{key:1,class:"test-input","onUpdate:modelValue":t[4]||(t[4]=c=>i.translatedText=c)},null,512)),[[Vn,i.translatedText]]):ke("",!0)])]),T("div",lD,[T("div",uD,ie(e.getLang("Keyword_group")),1),T("div",cD,[T("div",{innerHTML:e.getLang("enhance_translation_use_Keyword_group_desc")},null,8,fD),T("label",dD,[ge(T("input",{class:"hover-scale-120",type:"checkbox",value:"1","onUpdate:modelValue":t[5]||(t[5]=c=>i.groupTagsTranslateValue=c)},null,512),[[Fc,i.groupTagsTranslateValue]]),T("span",null,ie(e.getLang("enhance_translation_use_keyword_group")),1)])])]),T("div",pD,[hD,T("div",gD,[T("div",mD,[T("div",vD,[jt("[?] "),T("a",{href:e.globals.docs+"/TranslationApiConfiguration.html#tagcomplete-translation-enhancement",target:"_blank"},"[Wiki] TagComplete Translation enhancement",8,yD)])]),T("div",{innerHTML:e.getLang("tagcomplete_translate_desc")},null,8,bD),T("div",{class:"common-red",innerHTML:e.getLang("tagcomplete_translate_desc2")},null,8,CD),T("div",_D,[ge(T("select",{"onUpdate:modelValue":t[6]||(t[6]=c=>i.tagCompleteFileKey=c),onChange:t[7]||(t[7]=c=>i.tagCompleteResults=[])},[(E(!0),M(De,null,ot(i.tagCompleteFiles,c=>(E(),M("option",{value:c.key},ie(c.name),9,wD))),256))],544),[[Eo,i.tagCompleteFileKey]]),ge((E(),M("div",{class:"refresh-btn hover-scale-120",onClick:t[8]||(t[8]=(...c)=>o.refreshCSVs&&o.refreshCSVs(...c))},[i.tagCompleteFilesLoading?(E(),Ue(s,{key:0,name:"loading"})):(E(),Ue(s,{key:1,name:"refresh"}))])),[[l,e.getLang("refresh")]])]),T("label",{class:"onlyCsvOnAuto",style:St({display:i.tagCompleteFileKey?"flex":"none"})},[ge(T("input",{class:"hover-scale-120",type:"checkbox",value:"1","onUpdate:modelValue":t[9]||(t[9]=c=>i.onlyCsvOnAutoValue=c)},null,512),[[Fc,i.onlyCsvOnAutoValue]]),T("span",null,ie(e.getLang("only_csv_on_auto")),1)],4)])]),ge(T("div",TD,[kD,T("div",xD,[T("div",{class:"hover-scale-120 test-btn",onClick:t[10]||(t[10]=(...c)=>o.onTagCompleteTestClick&&o.onTagCompleteTestClick(...c))},ie(e.getLang("test")),1),ge(T("div",SD,[(E(!0),M(De,null,ot(i.tagCompleteResults,c=>(E(),M("p",{key:c},ie(c),1))),128))],512),[[Ot,i.tagCompleteResults.length>0]])])],512),[[Ot,i.tagCompleteFileKey]])]),T("div",AD,[T("div",{class:"translate-save hover-scale-120",onClick:t[11]||(t[11]=(...c)=>o.onSaveClick&&o.onSaveClick(...c))},ie(e.getLang("save")),1),T("div",{class:"translate-close hover-scale-120",onClick:t[12]||(t[12]=(...c)=>o.onCloseClick&&o.onCloseClick(...c))},ie(e.getLang("close")),1)])])])):ke("",!0)]),_:1})}const LD=hn(yP,[["render",ED]]),OD={name:"SelectLanguage",components:{IconSvg:Fn},mixins:[Xn],props:{},data(){return{isOpen:!1}},computed:{},mounted(){},methods:{open(){this.isOpen=!0,this.$nextTick(()=>{this.scrollToSelectedItem()})},close(){this.isOpen=!1},onLanguageClick(e){this.$emit("update:languageCode",e.code),this.close()},scrollToSelectedItem(){const e=this.$refs.items;for(let t=0;t<e.length;t++)if(e[t].classList.contains("selected")){e[t].scrollIntoView({behavior:"smooth",block:"center"});break}}}},ID=["onClick"];function PD(e,t,n,r,i,o){const s=Ye("icon-svg");return E(),Ue(un,{name:"fadeDown"},{default:tn(()=>[i.isOpen?(E(),M("div",{key:0,class:"physton-prompt-select-language",onClick:t[3]||(t[3]=(...l)=>o.close&&o.close(...l))},[T("div",{class:"language-main",onClick:t[2]||(t[2]=nt(()=>{},["stop"]))},[T("div",{class:"language-close",onClick:t[0]||(t[0]=(...l)=>o.close&&o.close(...l))},[ye(s,{name:"close"})]),T("div",{class:"language-list",onClick:t[1]||(t[1]=nt(()=>{},["stop"]))},[(E(!0),M(De,null,ot(e.languages,l=>(E(),M("div",{key:l.code,class:Ge(["language-item",l.code==e.languageCode?"selected":""]),ref_for:!0,ref:"items",onClick:c=>o.onLanguageClick(l)},ie(l.code)+" - "+ie(l.name),11,ID))),128))])])])):ke("",!0)]),_:1})}const DD=hn(OD,[["render",PD]]),RD={components:{IconSvg:Fn},props:{},mixins:[Xn],data(){return{favoriteKey:"",favorites:[{name:"txt2img",type:"prompt",key:"txt2img",list:[]},{name:"txt2img",type:"negative_prompt",key:"txt2img_neg",list:[]},{name:"img2img",type:"prompt",key:"img2img",list:[]},{name:"img2img",type:"negative_prompt",key:"img2img_neg",list:[]}],isShow:!1,loading:!1,emptyMsg:"",mouseEnter:!1,currentItem:{}}},emits:["use"],mounted(){this.favorites.forEach(e=>{this.getFavorites(e.key)})},methods:{formatTime(e){return he.formatTime(e*1e3,!1)},getFavorites(e){if(!e)return;let t=this.favorites.find(n=>n.key===e);t&&(this.loading=!0,this.gradioAPI.getFavorites(e).then(n=>{n&&n.length>0&&(n.reverse(),n.forEach(r=>{r.is_favorite=!0}),t.list=n),window.phystonPromptfavorites=this.favorites,this.emptyMsg=this.getLang("no_favorite"),this.loading=!1}).catch(n=>{this.emptyMsg=this.getLang("get_favorite_error"),this.loading=!1}))},show(e,t){if(!(!e||!t)){if(this.favoriteKey=e,this.isShow){this.isShow=!1;return}this.mouseEnter=!1,this.loading=!0,this.isShow=!0,this.$refs.favorite.style.top=t.pageY+2+"px",this.$refs.favorite.style.left=t.pageX+2+"px",this.getFavorites(this.favoriteKey),this.$nextTick(()=>{let n=this.$refs.favorite.getBoundingClientRect();n.right>window.innerWidth&&(this.$refs.favorite.style.left=window.innerWidth-n.width-2+"px")}),setTimeout(()=>{this.mouseEnter||this.hide()},3e3)}},hide(){this.mouseEnter=!1,this.isShow=!1},onMouseEnter(){this.mouseEnter=!0},onMouseLeave(e){e.relatedTarget&&this.hide()},onTabClick(e){this.favoriteKey=e,this.getFavorites(this.favoriteKey)},onFavoriteClick(e){let t=this.favorites.find(r=>r.key===this.favoriteKey);if(!t)return;let n=t.list[e];n.is_favorite?this.gradioAPI.unFavorite(this.favoriteKey,n.id).then(r=>{r&&(n.is_favorite=!1,window.phystonPromptfavorites=this.favorites)}):this.gradioAPI.doFavorite(this.favoriteKey,n.id).then(r=>{r&&(n.is_favorite=!0,window.phystonPromptfavorites=this.favorites)})},onCopyClick(e){let t=this.favorites.find(r=>r.key===this.favoriteKey);if(!t)return;let n=t.list[e];this.$copyText(n.prompt).then(()=>{this.$toastr.success("success!")}).catch(()=>{this.$toastr.error("error!")})},onNameKeyDown(e,t){t.keyCode===13&&t.target.blur()},onNameChange(e,t){let n=this.favorites.find(o=>o.key===this.favoriteKey);if(!n)return;let r=n.list[e];const i=t.target.value;this.gradioAPI.setFavoriteName(this.favoriteKey,r.id,i).then(o=>{o?(r.name=i,window.phystonPromptfavorites=this.favorites):t.target.value=r.name}).catch(o=>{t.target.value=r.name})},onItemMouseEnter(e){let t=this.favorites.find(n=>n.key===this.favoriteKey);t&&(this.currentItem=t.list[e],this.$nextTick(()=>{let n=this.$refs.favoriteDetail.getBoundingClientRect();n.right>window.innerWidth&&(this.$refs.favoriteDetail.style.left=0-n.width-2+"px")}))},onItemMouseLeave(e){this.currentItem={}},onUseClick(e){let t=this.favorites.find(n=>n.key===this.favoriteKey);t&&(this.hide(),this.$emit("use",t.list[e]))}}},ND={class:"popup-tabs"},MD=["onClick"],FD={class:"tab-name"},BD={class:"tab-type"},$D={class:"tab-count"},HD={class:"popup-detail",ref:"favoriteDetail"},jD={class:"popup-item-tags"},UD={key:0,class:"item-wrap"},WD={key:1,class:"item-tag"},KD={class:"item-tag-value"},VD={class:"item-tag-local-value"},qD={class:"content-list"},zD=["onMouseenter","onMouseleave"],GD={class:"item-header"},YD={class:"item-header-left"},XD={class:"item-header-index"},JD={class:"item-header-time"},ZD={class:"item-header-name"},QD=["value","onKeydown","onChange","placeholder"],eR={class:"item-header-right"},tR=["onClick"],nR=["onClick"],rR=["onClick"],iR=["onClick"],oR={class:"item-prompt"},sR={class:"content-empty"},aR={key:1};function lR(e,t,n,r,i,o){const s=Ye("icon-svg"),l=To("tooltip");return E(),Ue(un,{name:"fade"},{default:tn(()=>[ge(T("div",{class:"physton-prompt-favorite",ref:"favorite",onMouseenter:t[0]||(t[0]=(...c)=>o.onMouseEnter&&o.onMouseEnter(...c)),onMouseleave:t[1]||(t[1]=(...c)=>o.onMouseLeave&&o.onMouseLeave(...c)),onClick:t[2]||(t[2]=nt(()=>{},["stop"]))},[T("div",ND,[(E(!0),M(De,null,ot(i.favorites,c=>(E(),M("div",{key:c.key,class:Ge(["popup-tab",c.key===i.favoriteKey?"active":""]),onClick:d=>o.onTabClick(c.key)},[T("div",FD,ie(e.getLang(c.name)),1),T("div",BD,ie(e.getLang(c.type)),1),T("div",$D,ie(c.list.length),1)],10,MD))),128))]),ge(T("div",HD,[T("div",jD,[(E(!0),M(De,null,ot(i.currentItem.tags,(c,d)=>(E(),M(De,{key:d},[c.type&&c.type==="wrap"?(E(),M("div",UD)):(E(),M("div",WD,[T("div",KD,ie(c.value),1),T("div",VD,ie(c.localValue),1)]))],64))),128))])],512),[[Ot,i.currentItem&&i.currentItem.tags]]),(E(!0),M(De,null,ot(i.favorites,c=>(E(),M("div",{key:c.key,class:Ge(["popup-tab-content",c.key===i.favoriteKey?"active":""])},[ge(T("div",qD,[(E(!0),M(De,null,ot(c.list,(d,p)=>(E(),M("div",{class:"content-item",key:d.id,onMouseenter:y=>o.onItemMouseEnter(p),onMouseleave:y=>o.onItemMouseLeave(p)},[T("div",GD,[T("div",YD,[T("div",XD,ie(c.list.length-p),1),T("div",JD,ie(o.formatTime(d.time)),1),T("div",ZD,[T("input",{class:"header-name-input",value:d.name,onKeydown:y=>o.onNameKeyDown(p,y),onChange:y=>o.onNameChange(p,y),placeholder:e.getLang("unset_name")},null,40,QD)])]),T("div",eR,[ge((E(),M("div",{class:"header-btn-favorite hover-scale-140",onClick:y=>o.onFavoriteClick(p)},[ye(s,{name:"favorite-yes"})],8,tR)),[[Ot,d.is_favorite],[l,e.getLang("remove_from_favorite")]]),ge((E(),M("div",{class:"header-btn-favorite hover-scale-140",onClick:y=>o.onFavoriteClick(p)},[ye(s,{name:"favorite-no"})],8,nR)),[[Ot,!d.is_favorite],[l,e.getLang("add_to_favorite")]]),ge((E(),M("div",{class:"header-btn-copy hover-scale-140",onClick:y=>o.onCopyClick(p)},[ye(s,{name:"copy"})],8,rR)),[[l,e.getLang("copy_to_clipboard")]]),ge((E(),M("div",{class:"header-btn-use hover-scale-140",onClick:y=>o.onUseClick(p)},[ye(s,{name:"use"})],8,iR)),[[l,e.getLang("use")]])])]),T("div",oR,ie(d.prompt),1)],40,zD))),128))],512),[[Ot,c.list.length>0]]),ge(T("div",sR,[i.loading?(E(),Ue(s,{key:0,name:"loading"})):(E(),M("span",aR,ie(i.emptyMsg),1))],512),[[Ot,c.list.length===0]])],2))),128))],544),[[Ot,i.isShow]])]),_:1})}const uR=hn(RD,[["render",lR]]),cR={components:{IconSvg:Fn},props:{},mixins:[Xn],data(){return{historyKey:"",histories:[{name:"txt2img",type:"prompt",key:"txt2img",list:[]},{name:"txt2img",type:"negative_prompt",key:"txt2img_neg",list:[]},{name:"img2img",type:"prompt",key:"img2img",list:[]},{name:"img2img",type:"negative_prompt",key:"img2img_neg",list:[]}],isShow:!1,loading:!1,emptyMsg:"",mouseEnter:!1,currentItem:{}}},emits:["use","refreshFavorites"],mounted(){},methods:{formatTime(e){return he.formatTime(e*1e3,!1)},getHistories(e){if(!e)return;let t=this.histories.find(n=>n.key===e);t&&(this.loading=!0,this.gradioAPI.getHistories(e).then(n=>{n&&n.length>0&&(n.reverse(),t.list=n),this.emptyMsg=this.getLang("no_history"),this.loading=!1}).catch(n=>{this.emptyMsg=this.getLang("get_history_error"),this.loading=!1}))},show(e,t){if(!(!e||!t)){if(this.historyKey=e,this.isShow){this.isShow=!1;return}this.mouseEnter=!1,this.loading=!0,this.isShow=!0,this.$refs.history.style.top=t.pageY+2+"px",this.$refs.history.style.left=t.pageX+2+"px",this.getHistories(this.historyKey),this.$nextTick(()=>{let n=this.$refs.history.getBoundingClientRect();n.right>window.innerWidth&&(this.$refs.history.style.left=window.innerWidth-n.width-2+"px")}),setTimeout(()=>{this.mouseEnter||this.hide()},3e3)}},hide(){this.mouseEnter=!1,this.isShow=!1},onMouseEnter(){this.mouseEnter=!0},onMouseLeave(e){e.relatedTarget&&this.hide()},onTabClick(e){this.historyKey=e,this.getHistories(this.historyKey)},onDeleteClick(e){let t=this.histories.find(r=>r.key===this.historyKey);if(!t)return;let n=t.list[e];this.gradioAPI.deleteHistory(this.historyKey,n.id).then(r=>{r&&t.list.splice(e,1)})},onFavoriteClick(e){let t=this.histories.find(r=>r.key===this.historyKey);if(!t)return;let n=t.list[e];n.is_favorite?this.gradioAPI.unFavorite(this.historyKey,n.id).then(r=>{r&&(n.is_favorite=!1,this.$emit("refreshFavorites",this.historyKey))}):this.gradioAPI.doFavorite(this.historyKey,n.id).then(r=>{r&&(n.is_favorite=!0,this.$emit("refreshFavorites",this.historyKey))})},onCopyClick(e){let t=this.histories.find(r=>r.key===this.historyKey);if(!t)return;let n=t.list[e];this.$copyText(n.prompt).then(()=>{this.$toastr.success("success!")}).catch(()=>{this.$toastr.error("error!")})},onNameKeyDown(e,t){t.keyCode===13&&t.target.blur()},onNameChange(e,t){let n=this.histories.find(o=>o.key===this.historyKey);if(!n)return;let r=n.list[e];const i=t.target.value;this.gradioAPI.setHistoryName(this.historyKey,r.id,i).then(o=>{o?(r.name=i,this.$emit("refreshFavorites",this.historyKey)):t.target.value=r.name}).catch(o=>{t.target.value=r.name})},onItemMouseEnter(e){let t=this.histories.find(n=>n.key===this.historyKey);t&&(this.currentItem=t.list[e],this.$nextTick(()=>{let n=this.$refs.historyDetail.getBoundingClientRect();n.right>window.innerWidth&&(this.$refs.historyDetail.style.left=0-n.width-2+"px")}))},onItemMouseLeave(e){this.currentItem={}},onUseClick(e){let t=this.histories.find(n=>n.key===this.historyKey);t&&(this.hide(),this.$emit("use",t.list[e]))},onDeleteAllHistoryClick(){let e=this.histories.find(t=>t.key===this.historyKey);e&&confirm(this.getLang("delete_all_history_confirm"))&&this.gradioAPI.deleteHistories(this.historyKey).then(t=>{e.list=[]}).catch(t=>{})}}},fR={class:"popup-tabs"},dR=["onClick"],pR={class:"tab-name"},hR={class:"tab-type"},gR={class:"tab-count"},mR={class:"popup-detail",ref:"historyDetail"},vR={class:"popup-item-tags"},yR={key:0,class:"item-wrap"},bR={key:1,class:"item-tag"},CR={class:"item-tag-value"},_R={class:"item-tag-local-value"},wR={class:"content-list"},TR=["onMouseenter","onMouseleave"],kR={class:"item-header"},xR={class:"item-header-left"},SR={class:"item-header-index"},AR={class:"item-header-time"},ER={class:"item-header-name"},LR=["value","onKeydown","onChange","placeholder"],OR={class:"item-header-right"},IR=["onClick"],PR=["onClick"],DR=["onClick"],RR=["onClick"],NR=["onClick"],MR={class:"item-prompt"},FR={class:"content-empty"},BR={key:1};function $R(e,t,n,r,i,o){const s=Ye("icon-svg"),l=To("tooltip");return E(),Ue(un,{name:"fade"},{default:tn(()=>[ge(T("div",{class:"physton-prompt-history",ref:"history",onMouseenter:t[1]||(t[1]=(...c)=>o.onMouseEnter&&o.onMouseEnter(...c)),onMouseleave:t[2]||(t[2]=(...c)=>o.onMouseLeave&&o.onMouseLeave(...c)),onClick:t[3]||(t[3]=nt(()=>{},["stop"]))},[T("div",fR,[(E(!0),M(De,null,ot(i.histories,c=>(E(),M("div",{key:c.key,class:Ge(["popup-tab",c.key===i.historyKey?"active":""]),onClick:d=>o.onTabClick(c.key)},[T("div",pR,ie(e.getLang(c.name)),1),T("div",hR,ie(e.getLang(c.type)),1),T("div",gR,ie(c.list.length),1)],10,dR))),128))]),ge(T("div",mR,[T("div",vR,[(E(!0),M(De,null,ot(i.currentItem.tags,(c,d)=>(E(),M(De,{key:d},[c.type&&c.type==="wrap"?(E(),M("div",yR)):(E(),M("div",bR,[T("div",CR,ie(c.value),1),T("div",_R,ie(c.localValue),1)]))],64))),128))])],512),[[Ot,i.currentItem&&i.currentItem.tags]]),(E(!0),M(De,null,ot(i.histories,c=>(E(),M("div",{key:c.key,class:Ge(["popup-tab-content",c.key===i.historyKey?"active":""])},[ge(T("div",wR,[T("div",{class:"clear-btn",onClick:t[0]||(t[0]=(...d)=>o.onDeleteAllHistoryClick&&o.onDeleteAllHistoryClick(...d))},[ye(s,{name:"remove"}),jt(" "+ie(e.getLang("delete_all_history")),1)]),(E(!0),M(De,null,ot(c.list,(d,p)=>(E(),M("div",{class:"content-item",key:d.id,onMouseenter:y=>o.onItemMouseEnter(p),onMouseleave:y=>o.onItemMouseLeave(p)},[T("div",kR,[T("div",xR,[T("div",SR,ie(c.list.length-p),1),T("div",AR,ie(o.formatTime(d.time)),1),T("div",ER,[T("input",{class:"header-name-input",value:d.name,onKeydown:y=>o.onNameKeyDown(p,y),onChange:y=>o.onNameChange(p,y),placeholder:e.getLang("unset_name")},null,40,LR)])]),T("div",OR,[T("div",{class:"header-btn-favorite hover-scale-140",onClick:y=>o.onDeleteClick(p)},[ye(s,{name:"remove"})],8,IR),ge((E(),M("div",{class:"header-btn-favorite hover-scale-140",onClick:y=>o.onFavoriteClick(p)},[ye(s,{name:"favorite-yes"})],8,PR)),[[Ot,d.is_favorite],[l,e.getLang("remove_from_favorite")]]),ge((E(),M("div",{class:"header-btn-favorite hover-scale-140",onClick:y=>o.onFavoriteClick(p)},[ye(s,{name:"favorite-no"})],8,DR)),[[Ot,!d.is_favorite],[l,e.getLang("add_to_favorite")]]),ge((E(),M("div",{class:"header-btn-copy hover-scale-140",onClick:y=>o.onCopyClick(p)},[ye(s,{name:"copy"})],8,RR)),[[l,e.getLang("copy_to_clipboard")]]),ge((E(),M("div",{class:"header-btn-use hover-scale-140",onClick:y=>o.onUseClick(p)},[ye(s,{name:"use"})],8,NR)),[[l,e.getLang("use")]])])]),T("div",MR,ie(d.prompt),1)],40,TR))),128))],512),[[Ot,c.list.length>0]]),ge(T("div",FR,[i.loading?(E(),Ue(s,{key:0,name:"loading"})):(E(),M("span",BR,ie(i.emptyMsg),1))],512),[[Ot,c.list.length===0]])],2))),128))],544),[[Ot,i.isShow]])]),_:1})}const HR=hn(cR,[["render",$R]]),jR={name:"ExtensionCss",components:{IconSvg:Fn},mixins:[Xn],props:{},data(){return{isOpen:!1,list:[]}},computed:{},mounted(){},methods:{init(){this.refresh(!0)},refresh(e=!1){this.gradioAPI.getExtensionCssList().then(t=>{let n=[];for(let r=0;r<t.length;r++)t[r].manifest=JSON.parse(t[r].manifest),t[r].manifest&&typeof t[r].manifest=="object"&&t[r].manifest.name&&(t[r].selected=t[r].selected||!1,t[r].id="physton-prompt-extension-"+t[r].dir,n.push(t[r]));n.forEach(r=>{r.sort=r.manifest.type+"."+r.dir}),n.sort((r,i)=>r.sort>i.sort?1:-1),this.list=n,e&&this.list.forEach(r=>{r.selected&&he.loadCSS(r.style,r.id,!0,!1)})})},getName(e){if(!e)return"";let t=e.manifest.name;return e.manifest.i18n&&e.manifest.i18n[this.languageCode]&&(t=e.manifest.i18n[this.languageCode]),t},onChangeSelect(e){let t=this.list.find(n=>n.id===e);t&&(t.selected=!t.selected,t.selected?he.loadCSS(t.style,t.id,!0,!1):he.removeCSS(t.id),this.gradioAPI.setData(t.dataName,t.selected))},open(){this.isOpen=!0,this.refresh(!1)},close(){this.isOpen=!1}}},UR={class:"extension-table"},WR=["checked","onChange"],KR={class:"extension-name"},VR={class:"extension-type"},qR={class:"extension-dir"},zR={class:"extension-author"};function GR(e,t,n,r,i,o){const s=Ye("icon-svg");return E(),Ue(un,{name:"slideRight"},{default:tn(()=>[i.isOpen?(E(),M("div",{key:0,class:"physton-prompt-extension-css",onClick:t[3]||(t[3]=(...l)=>o.close&&o.close(...l))},[T("div",{class:"extension-main",onClick:t[2]||(t[2]=nt(()=>{},["stop"]))},[T("div",{class:"extension-close",onClick:t[0]||(t[0]=(...l)=>o.close&&o.close(...l))},[ye(s,{name:"close"})]),T("div",{class:"extension-list",onClick:t[1]||(t[1]=nt(()=>{},["stop"]))},[T("table",UR,[(E(!0),M(De,null,ot(i.list,(l,c)=>(E(),M("tr",{key:l.dir,class:"extension-item",ref_for:!0,ref:"items"},[T("td",null,[T("input",{class:"extension-checkbox",type:"checkbox",name:"extension-item",checked:l.selected,onChange:d=>o.onChangeSelect(l.id)},null,40,WR)]),T("td",KR,ie(o.getName(l)),1),T("td",VR,ie(e.getLang(l.manifest.type)),1),T("td",qR,ie(l.dir),1),T("td",zR,[l.manifest.author?(E(),M(De,{key:0},[jt("By: "+ie(l.manifest.author),1)],64)):ke("",!0)])]))),128))])])])])):ke("",!0)]),_:1})}const YR=hn(jR,[["render",GR]]),XR={name:"PromptFormat",components:{IconSvg:Fn},mixins:[Xn],props:{autoRemoveSpace:{type:Boolean,default:!1},autoRemoveLastComma:{type:Boolean,default:!1},autoKeepWeightZero:{type:Boolean,default:!1},autoKeepWeightOne:{type:Boolean,default:!1},autoBreakBeforeWrap:{type:Boolean,default:!1},autoBreakAfterWrap:{type:Boolean,default:!1}},data(){return{isOpen:!1}},emits:["update:autoRemoveSpace","update:autoRemoveLastComma","update:autoKeepWeightZero","update:autoKeepWeightOne","update:autoBreakBeforeWrap","update:autoBreakAfterWrap"],computed:{},mounted(){},methods:{open(){this.isOpen=!0},close(){this.isOpen=!1}}},JR={class:"format-item"},ZR=["checked"],QR=["innerHTML"],eN={class:"format-item"},tN=["checked"],nN=["innerHTML"],rN={class:"format-item"},iN=["checked"],oN=["innerHTML"],sN={class:"format-item"},aN=["checked"],lN=["innerHTML"],uN={class:"format-item"},cN=["checked"],fN=["innerHTML"];function dN(e,t,n,r,i,o){const s=Ye("icon-svg");return E(),Ue(un,{name:"fadeDown"},{default:tn(()=>[i.isOpen?(E(),M("div",{key:0,class:"physton-prompt-format",onClick:t[8]||(t[8]=(...l)=>o.close&&o.close(...l))},[T("div",{class:"format-main",onClick:t[7]||(t[7]=nt(()=>{},["stop"]))},[T("div",{class:"format-close",onClick:t[0]||(t[0]=(...l)=>o.close&&o.close(...l))},[ye(s,{name:"close"})]),T("div",{class:"format-list",onClick:t[6]||(t[6]=nt(()=>{},["stop"]))},[T("div",JR,[T("input",{class:"format-checkbox",type:"checkbox",checked:n.autoRemoveSpace,onChange:t[1]||(t[1]=l=>e.$emit("update:autoRemoveSpace",l.target.checked))},null,40,ZR),T("div",{class:"format-desc",innerHTML:e.getLang("is_remove_space")},null,8,QR)]),T("div",eN,[T("input",{class:"format-checkbox",type:"checkbox",checked:n.autoRemoveLastComma,onChange:t[2]||(t[2]=l=>e.$emit("update:autoRemoveLastComma",l.target.checked))},null,40,tN),T("div",{class:"format-desc",innerHTML:e.getLang("is_remove_last_comma")},null,8,nN)]),T("div",rN,[T("input",{class:"format-checkbox",type:"checkbox",checked:n.autoKeepWeightZero,onChange:t[3]||(t[3]=l=>e.$emit("update:autoKeepWeightZero",l.target.checked))},null,40,iN),T("div",{class:"format-desc",innerHTML:e.getLang("is_keep_weight_zero")},null,8,oN)]),T("div",sN,[T("input",{class:"format-checkbox",type:"checkbox",checked:n.autoBreakBeforeWrap,onChange:t[4]||(t[4]=l=>e.$emit("update:autoBreakBeforeWrap",l.target.checked))},null,40,aN),T("div",{class:"format-desc",innerHTML:e.getLang("is_break_before_wrap")},null,8,lN)]),T("div",uN,[T("input",{class:"format-checkbox",type:"checkbox",checked:n.autoBreakAfterWrap,onChange:t[5]||(t[5]=l=>e.$emit("update:autoBreakAfterWrap",l.target.checked))},null,40,cN),T("div",{class:"format-desc",innerHTML:e.getLang("is_break_after_wrap")},null,8,fN)])])])])):ke("",!0)]),_:1})}const pN=hn(XR,[["render",dN]]),hN={name:"Blacklist",components:{IconSvg:Fn},mixins:[Xn],props:{},data(){return{isOpen:!1,data:{prompt:[],negative_prompt:[],lora:[],lycoris:[],embedding:[],translate:[]},cancelBlacklistConfirm:!1,textarea:{prompt:"",negative_prompt:"",lora:"",lycoris:"",embedding:"",translate:""}}},emits:["update:blacklist"],computed:{},mounted(){},methods:{open(){this.isOpen=!0,this.data={prompt:[],negative_prompt:[],lora:[],lycoris:[],embedding:[],translate:[]},this.textarea={prompt:"",negative_prompt:"",lora:"",lycoris:"",embedding:"",translate:""},this.gradioAPI.getDatas(["blacklist","cancelBlacklistConfirm"]).then(e=>{e.blacklist&&(this.data.prompt=e.blacklist.prompt||[],this.data.negative_prompt=e.blacklist.negative_prompt||[],this.data.lora=e.blacklist.lora||[],this.data.lycoris=e.blacklist.lycoris||[],this.data.embedding=e.blacklist.embedding||[],this.data.translate=e.blacklist.translate||[]),e.cancelBlacklistConfirm&&(this.cancelBlacklistConfirm=e.cancelBlacklistConfirm),this.textarea.prompt=this.data.prompt.join(`
|
||
`),this.textarea.negative_prompt=this.data.negative_prompt.join(`
|
||
`),this.textarea.lora=this.data.lora.join(`
|
||
`),this.textarea.lycoris=this.data.lycoris.join(`
|
||
`),this.textarea.embedding=this.data.embedding.join(`
|
||
`),this.textarea.translate=this.data.translate.join(`
|
||
`)})},close(){this.isOpen=!1},onCloseClick(){this.close()},onSaveClick(){this.data.prompt=this.textarea.prompt.split(/\s*\n\s*/).filter(e=>e==null?void 0:e.trim().length),this.data.negative_prompt=this.textarea.negative_prompt.split(/\s*\n\s*/).filter(e=>e==null?void 0:e.trim().length),this.data.lora=this.textarea.lora.split(/\s*\n\s*/).filter(e=>e==null?void 0:e.trim().length),this.data.lycoris=this.textarea.lycoris.split(/\s*\n\s*/).filter(e=>e==null?void 0:e.trim().length),this.data.embedding=this.textarea.embedding.split(/\s*\n\s*/).filter(e=>e==null?void 0:e.trim().length),this.data.translate=this.textarea.translate.split(/\s*\n\s*/).filter(e=>e==null?void 0:e.trim().length),this.gradioAPI.setData("blacklist",this.data),this.gradioAPI.setData("cancelBlacklistConfirm",this.cancelBlacklistConfirm),this.close(),this.$emit("update:blacklist",this.data,this.cancelBlacklistConfirm)}}},gN={class:"blacklist-desc"},mN={class:"blacklist-group"},vN={class:"group-title"},yN=["placeholder"],bN={class:"blacklist-group"},CN={class:"group-title"},_N=["placeholder"],wN=T("div",{class:"blacklist-wrap"},null,-1),TN={class:"blacklist-group"},kN={class:"group-title"},xN=["placeholder"],SN={class:"blacklist-group"},AN={class:"group-title"},EN=["placeholder"],LN={class:"blacklist-group"},ON={class:"group-title"},IN=["placeholder"],PN=T("div",{class:"blacklist-wrap"},null,-1),DN={class:"blacklist-group"},RN={class:"group-title"},NN=T("div",{class:"blacklist-wrap"},null,-1),MN={class:"blacklist-desc"},FN={class:"blacklist-group"},BN={class:"group-title"},$N=["placeholder"],HN=T("div",{class:"blacklist-wrap"},null,-1),jN={class:"setting-btns"};function UN(e,t,n,r,i,o){return E(),Ue(un,{name:"fadeDown"},{default:tn(()=>[i.isOpen?(E(),M("div",{key:0,class:"physton-prompt-blacklist",onClick:t[11]||(t[11]=()=>{})},[T("div",{class:"blacklist-main",onClick:t[10]||(t[10]=nt(()=>{},["stop"]))},[T("div",{class:"blacklist-body",onClick:t[9]||(t[9]=nt(()=>{},["stop"]))},[T("div",gN,"1. "+ie(e.getLang("blacklist_desc")),1),T("div",mN,[T("div",vN,ie(e.getLang("prompt_blacklist_list"))+":",1),ge(T("textarea",{class:"group-content",placeholder:e.getLang("one_keyword_per_line"),"onUpdate:modelValue":t[0]||(t[0]=s=>i.textarea.prompt=s)},null,8,yN),[[Vn,i.textarea.prompt]])]),T("div",bN,[T("div",CN,ie(e.getLang("negative_prompt_blacklist_list"))+":",1),ge(T("textarea",{class:"group-content",placeholder:e.getLang("one_keyword_per_line"),"onUpdate:modelValue":t[1]||(t[1]=s=>i.textarea.negative_prompt=s)},null,8,_N),[[Vn,i.textarea.negative_prompt]])]),wN,T("div",TN,[T("div",kN,ie(e.getLang("lora_blacklist_list"))+":",1),ge(T("textarea",{class:"group-content",placeholder:e.getLang("one_keyword_per_line"),"onUpdate:modelValue":t[2]||(t[2]=s=>i.textarea.lora=s)},null,8,xN),[[Vn,i.textarea.lora]])]),T("div",SN,[T("div",AN,ie(e.getLang("lycoris_blacklist_list"))+":",1),ge(T("textarea",{class:"group-content",placeholder:e.getLang("one_keyword_per_line"),"onUpdate:modelValue":t[3]||(t[3]=s=>i.textarea.lycoris=s)},null,8,EN),[[Vn,i.textarea.lycoris]])]),T("div",LN,[T("div",ON,ie(e.getLang("embedding_blacklist_list"))+":",1),ge(T("textarea",{class:"group-content",placeholder:e.getLang("one_keyword_per_line"),"onUpdate:modelValue":t[4]||(t[4]=s=>i.textarea.embedding=s)},null,8,IN),[[Vn,i.textarea.embedding]])]),PN,T("div",DN,[T("div",RN,[T("label",null,[ge(T("input",{type:"checkbox","onUpdate:modelValue":t[5]||(t[5]=s=>i.cancelBlacklistConfirm=s)},null,512),[[Fc,i.cancelBlacklistConfirm]]),jt(" "+ie(e.getLang("cancel_confirm_add_blacklist")),1)])])]),NN,T("div",MN,"2. "+ie(e.getLang("translate_blacklist_desc")),1),T("div",FN,[T("div",BN,ie(e.getLang("disable_translate_prompt_blacklist_list"))+":",1),ge(T("textarea",{class:"group-content",placeholder:e.getLang("one_keyword_per_line"),"onUpdate:modelValue":t[6]||(t[6]=s=>i.textarea.translate=s)},null,8,$N),[[Vn,i.textarea.translate]])]),HN,T("div",jN,[T("div",{class:"blacklist-save hover-scale-120",onClick:t[7]||(t[7]=(...s)=>o.onSaveClick&&o.onSaveClick(...s))},ie(e.getLang("save")),1),T("div",{class:"blacklist-close hover-scale-120",onClick:t[8]||(t[8]=(...s)=>o.onCloseClick&&o.onCloseClick(...s))},ie(e.getLang("close")),1)])])])])):ke("",!0)]),_:1})}const WN=hn(hN,[["render",UN]]),KN={name:"PackagesState",components:{IconSvg:Fn},mixins:[Xn],props:{python:{type:String,default:"./python"},packagesState:{type:Array,default:()=>[]}},data(){return{todayNotShow:!1,isOpen:!1,loading:!1,showResult:!1,result:`1112323
|
||
sfsdfsdf
|
||
2222
|
||
3333
|
||
1112323
|
||
sfsdfsdf
|
||
2222
|
||
3333
|
||
1112323
|
||
sfsdfsdf
|
||
2222
|
||
3333`}},emits:[],computed:{},watch:{packagesState:{handler(){this.isAllInstalled()||this.open()},deep:!0}},mounted(){},methods:{isInstalled(e){for(let t of this.packagesState)if(t.name===e)return t.state;return!1},isAllInstalled(){for(let e of this.packagesState)if(!e.state)return!1;return!0},getCommand(e){return`${this.python} -m pip install ${e.package}`},onInstallClick(){if(this.loading)return;this.loading=!0,this.showResult=!0,this.result="";let e=[];this.packagesState.forEach(r=>{r.state||e.push(r)});const t=(r=!1)=>{this.loading=!1,r&&(this.result+=`
|
||
complete!`,setTimeout(this.close,2e3)),this.scrollToBottom()},n=()=>{let r=e.shift();if(!r)return t(!0);this.gradioAPI.installPackage(r.name,r.package).then(i=>{this.result+=`${i.message}
|
||
`,i.state?(this.scrollToBottom(),n()):t(!1)}).catch(i=>{console.log(i),this.result+=`${r.name} install failed
|
||
${i.message}
|
||
`,t(!1)})};n()},scrollToBottom(){this.$nextTick(()=>{this.$refs.result.scrollTop=this.$refs.result.scrollHeight})},onTodayNotShowChange(){this.todayNotShow=!this.todayNotShow,this.gradioAPI.setData("packagesStateTodayNotShow",new Date().toLocaleDateString())},open(){this.gradioAPI.getData("packagesStateTodayNotShow").then(e=>{e&&e===new Date().toLocaleDateString()?this.close():(this.result="",this.loading=!1,this.showResult=!1,this.isOpen=!0)}).catch(e=>{})},close(){this.isOpen=!1}}},VN={class:"today-now-show"},qN=["value"],zN={class:"state-body-name"},GN=["innerHTML"],YN={class:"package-list"},XN={class:"package-name"},JN={class:"package-command"},ZN={key:0,class:"install-result"};function QN(e,t,n,r,i,o){const s=Ye("icon-svg");return E(),Ue(un,{name:"fadeDown"},{default:tn(()=>[i.isOpen?(E(),M("div",{key:0,class:"physton-packages-state",onClick:t[6]||(t[6]=(...l)=>o.close&&o.close(...l))},[T("div",{class:"state-main",onClick:t[5]||(t[5]=nt(()=>{},["stop"]))},[T("div",{class:"state-close",onClick:t[0]||(t[0]=(...l)=>o.close&&o.close(...l))},[ye(s,{name:"close"})]),T("div",{class:"state-body",onClick:t[4]||(t[4]=nt(()=>{},["stop"]))},[T("div",VN,[T("label",null,[T("input",{type:"checkbox",value:i.todayNotShow,onChange:t[1]||(t[1]=(...l)=>o.onTodayNotShowChange&&o.onTodayNotShowChange(...l))},null,40,qN),jt(" "+ie(e.getLang("today_not_show")),1)])]),T("div",zN,ie(e.globals.shortName),1),T("div",{class:"state-body-language",onClick:t[2]||(t[2]=l=>e.$emit("click:selectLanguage",l))},[ye(s,{name:"i18n"}),T("div",null,"Language: "+ie(e.langName),1)]),T("div",{class:"state-body-desc",innerHTML:e.getLang("packages_desc")},null,8,GN),T("div",YN,[(E(!0),M(De,null,ot(n.packagesState,l=>(E(),M("div",{key:l.name,class:"package-item"},[T("div",XN,ie(l.name),1),T("div",{class:Ge(["package-state",l.state?"installed":"not_install"])},ie(e.getLang(l.state?"installed":"not_install")),3),T("div",JN,ie(o.getCommand(l)),1)]))),128))]),T("div",{class:"btn-packages-install hover-scale-120",onClick:t[3]||(t[3]=(...l)=>o.onInstallClick&&o.onInstallClick(...l))},[i.loading?(E(),Ue(s,{key:0,name:"loading"})):(E(),M(De,{key:1},[jt(ie(e.getLang("install")),1)],64))]),i.showResult?(E(),M("div",ZN,[jt(ie(e.getLang("packages_installing"))+" ",1),i.result?(E(),M("div",{key:0,class:"result-content",ref:"result"},ie(i.result),513)):ke("",!0)])):ke("",!0)])])])):ke("",!0)]),_:1})}const eM=hn(KN,[["render",QN]]),tM={name:"ChatgptPrompt",components:{IconSvg:Fn},mixins:[Xn],props:{},data(){return{isOpen:!1,api:{},configs:[],chatPreset:"",hidePanels:{api:!0},imageDesc:"",promptResult:"",saveConfigIng:!1,genIng:!1}},emits:["use"],computed:{},mounted(){},methods:{open(){this.isOpen=!0,this.saveConfigIng=!1,this.genIng=!1,this.gradioAPI.getDatas(["chatgpt_prompts_preset","chatgpt_key","translate_api.openai"]).then(e=>{console.log(e),e.chatgpt_prompts_preset!==null?this.chatPreset=e.chatgpt_prompts_preset:this.chatPreset=this.getLang("chatgpt_prompts_preset"),this.configs=[];let t={},n=he.getTranslateApiItem(this.translateApis,"openai");if(n=JSON.parse(JSON.stringify(n)),e.chatgpt_key&&typeof e.chatgpt_key=="object")for(const r of n.config)t[r.key]=e.chatgpt_key[r.key]||r.default||"";else for(const r of n.config)t[r.key]=r.default||"";t.api_key||(this.hidePanels.api=!1);for(const r of n.config)r.value=t[r.key],this.configs.push(r)})},close(){this.isOpen=!1},onUnfoldClick(e){this.hidePanels[e]=!this.hidePanels[e]},onSaveConfigClick(){if(this.saveConfigIng)return;this.saveConfigIng=!0;let e={};this.configs.forEach(t=>{e[t.key]=t.value}),this.gradioAPI.setData("chatgpt_key",e).then(t=>{this.$toastr.success(this.getLang("success")),this.saveConfigIng=!1}).catch(t=>{this.$toastr.error(t.message||t),this.saveConfigIng=!1})},onPresetChange(e){this.chatPreset=e.target.value,this._saveChatPreset()},onRestoreClick(){this.chatPreset=this.getLang("chatgpt_prompts_preset"),this._saveChatPreset()},_saveChatPreset(){this.gradioAPI.setData("chatgpt_prompts_preset",this.chatPreset)},onGenClick(){if(this.genIng)return;if(!this.imageDesc)return this.$refs.imageDesc.focus();if(this.imageDesc=this.imageDesc.trim(),!this.imageDesc)return this.$refs.imageDesc.focus();this.genIng=!0;let e=[{role:"user",content:this.chatPreset},{role:"user",content:this.imageDesc}],t={};this.configs.forEach(n=>{t[n.key]=n.value}),this.gradioAPI.genOpenAI(e,t).then(n=>{n.success?this.promptResult=n.result:this.$toastr.error(n.message||"error"),this.genIng=!1}).catch(n=>{this.$toastr.error(n.message||n),this.genIng=!1})},onUseClick(){this.$emit("use",this.promptResult),this.close()}}},nM={class:"panel-header"},rM={class:"panel-title"},iM={class:"panel-content"},oM={class:"body-line"},sM={class:"line-title"},aM={class:"line-content"},lM=["onUpdate:modelValue"],uM=["onUpdate:modelValue"],cM=["value"],fM=["innerHTML"],dM={class:"body-line"},pM=T("div",{class:"line-title"},null,-1),hM={class:"line-content text-right"},gM={class:"panel-header"},mM={class:"panel-title"},vM={class:"panel-content"},yM={class:"body-line"},bM={class:"line-title"},CM={class:"line-subtitle"},_M={class:"line-content"},wM=["value"],TM={class:"body-line"},kM=T("div",{class:"line-title"},null,-1),xM={class:"line-content text-right"},SM={class:"body-line"},AM={class:"line-title"},EM={class:"line-subtitle"},LM={class:"line-content"},OM=["placeholder"],IM={class:"body-line"},PM=T("div",{class:"line-title"},null,-1),DM={class:"line-content text-right"},RM={class:"panel-header"},NM={class:"panel-title"},MM={class:"panel-content"},FM={class:"body-line"},BM={class:"line-title"},$M={class:"line-content"},HM={key:0,class:"body-line"},jM=T("div",{class:"line-title"},null,-1),UM={class:"line-content text-right"};function WM(e,t,n,r,i,o){const s=Ye("icon-svg");return E(),Ue(un,{name:"fadeDown"},{default:tn(()=>[i.isOpen?(E(),M("div",{key:0,class:"physton-chatgpt-prompt",onClick:t[13]||(t[13]=(...l)=>o.close&&o.close(...l))},[T("div",{class:"chatgpt-main",onClick:t[12]||(t[12]=nt(()=>{},["stop"]))},[T("div",{class:"chatgpt-close",onClick:t[0]||(t[0]=(...l)=>o.close&&o.close(...l))},[ye(s,{name:"close"})]),T("div",{class:"chatgpt-body",onClick:t[11]||(t[11]=nt(()=>{},["stop"]))},[T("div",{class:Ge(["body-panel",i.hidePanels.api?"fold":""])},[T("div",nM,[T("div",{class:"panel-unfold",onClick:t[1]||(t[1]=l=>o.onUnfoldClick("api"))},[ye(s,{class:"hover-scale-120",name:"unfold"})]),T("div",rM,ie(e.getLang("api_config")),1)]),T("div",iM,[(E(!0),M(De,null,ot(i.configs,l=>(E(),M("div",oM,[T("div",sM,ie(l.title),1),T("div",aM,[l.type=="input"?ge((E(),M("input",{key:0,type:"text","onUpdate:modelValue":c=>l.value=c},null,8,lM)),[[Vn,l.value]]):ke("",!0),l.type=="select"?ge((E(),M("select",{key:1,"onUpdate:modelValue":c=>l.value=c},[(E(!0),M(De,null,ot(l.options,c=>(E(),M("option",{value:c},ie(c),9,cM))),256))],8,uM)),[[Eo,l.value]]):ke("",!0),l.desc?(E(),M("div",{key:2,innerHTML:l.desc},null,8,fM)):ke("",!0)])]))),256)),T("div",dM,[pM,T("div",hM,[T("div",{class:"common-btn hover-scale-120",onClick:t[2]||(t[2]=(...l)=>o.onSaveConfigClick&&o.onSaveConfigClick(...l))},[i.saveConfigIng?(E(),Ue(s,{key:0,name:"loading"})):(E(),M(De,{key:1},[jt(ie(e.getLang("save")),1)],64))])])])])],2),T("div",{class:Ge(["body-panel",i.hidePanels.send?"fold":""])},[T("div",gM,[T("div",{class:"panel-unfold",onClick:t[3]||(t[3]=l=>o.onUnfoldClick("send"))},[ye(s,{class:"hover-scale-120",name:"unfold"})]),T("div",mM,ie(e.getLang("image_desc")),1)]),T("div",vM,[T("div",yM,[T("div",bM,[jt(ie(e.getLang("preset"))+" ",1),T("div",CM,ie(e.getLang("ai_one")),1)]),T("div",_M,[T("textarea",{value:i.chatPreset,onChange:t[4]||(t[4]=(...l)=>o.onPresetChange&&o.onPresetChange(...l)),style:{height:"100px"}},null,40,wM)])]),T("div",TM,[kM,T("div",xM,[T("a",{href:"javascript:",onClick:t[5]||(t[5]=(...l)=>o.onRestoreClick&&o.onRestoreClick(...l))},ie(e.getLang("restore_to_default")),1)])]),T("div",SM,[T("div",AM,[jt(ie(e.getLang("image_desc"))+" ",1),T("div",EM,ie(e.getLang("ai_two")),1)]),T("div",LM,[ge(T("textarea",{style:{height:"100px"},ref:"imageDesc","onUpdate:modelValue":t[6]||(t[6]=l=>i.imageDesc=l),placeholder:e.getLang("input_image_desc")},null,8,OM),[[Vn,i.imageDesc]])])]),T("div",IM,[PM,T("div",DM,[T("div",{class:"common-btn hover-scale-120",onClick:t[7]||(t[7]=(...l)=>o.onGenClick&&o.onGenClick(...l))},[i.genIng?(E(),Ue(s,{key:0,name:"loading"})):(E(),M(De,{key:1},[jt(ie(e.getLang("generate")),1)],64))])])])])],2),T("div",{class:Ge(["body-panel",i.hidePanels.result?"fold":""])},[T("div",RM,[T("div",{class:"panel-unfold",onClick:t[8]||(t[8]=l=>o.onUnfoldClick("result"))},[ye(s,{class:"hover-scale-120",name:"unfold"})]),T("div",NM,ie(e.getLang("generate_result")),1)]),T("div",MM,[T("div",FM,[T("div",BM,ie(e.getLang("generate_result")),1),T("div",$M,[ge(T("textarea",{style:{height:"100px"},"onUpdate:modelValue":t[9]||(t[9]=l=>i.promptResult=l)},null,512),[[Vn,i.promptResult]])])]),i.promptResult?(E(),M("div",HM,[jM,T("div",UM,[T("div",{class:"common-btn hover-scale-120",onClick:t[10]||(t[10]=(...l)=>o.onUseClick&&o.onUseClick(...l))},ie(e.getLang("use")),1)])])):ke("",!0)])],2)])])])):ke("",!0)]),_:1})}const KM=hn(tM,[["render",WM]]),VM={name:"About",components:{IconSvg:Fn},mixins:[Xn],data(){return{version:"",latestVersion:"",isLatestVersion:!0,isOpen:!1,loading:!1,versions:[],icons:[]}},emits:["use"],computed:{},mounted(){this.icons=[{title:"GitHub stars",url:this.globals.github+"/stargazers",image:"https://img.shields.io/github/stars/"+this.globals.name+"?style=flat-square"},{title:"GitHub forks",url:this.globals.github+"/network/members",image:"https://img.shields.io/github/forks/"+this.globals.name+"?style=flat-square"},{title:"GitHub issues",url:this.globals.github+"/issues",image:"https://img.shields.io/github/issues/"+this.globals.name+"?style=flat-square"},{title:"GitHub issues closed",url:this.globals.github+"/issues?q=is%3Aissue+is%3Aclosed",image:"https://img.shields.io/github/issues-closed/"+this.globals.name+"?style=flat-square"},{title:"GitHub license",url:this.globals.github+"/blob/master/LICENSE.md",image:"https://img.shields.io/github/license/"+this.globals.name+"?style=flat-square"},{title:"GitHub commits",url:this.globals.github+"/commits/main",image:"https://img.shields.io/github/last-commit/"+this.globals.name+"?style=flat-square"}]},methods:{open(){this.isOpen=!0,this.version="",this.latestVersion="",this.isLatestVersion=!0,this.versions=[],this.loading=!0,this.gradioAPI.getVersion().then(e=>{this.version=e.version,this.latestVersion=e.latest_version,this.isLatestVersion=e.version===e.latest_version}),this.gradioAPI.getRemoteVersions().then(e=>{this.loading=!1;let t=[];e.forEach((n,r)=>{n.is_update_readme||(n.date=he.formatTime(n.date),t.push(n))}),this.versions=t}).catch(e=>{this.loading=!1})},close(){this.isOpen=!1},commitUrl(e){return this.globals.github+"/commit/"+e},formatVersion(e){return e?e.slice(0,7):this.getLang("unknown_version")},message(e){return e=he.escapeHtml(e),e=e.replace(/Former-commit-id: [a-z0-9]{40}/g,""),e=e.trim(),e=e.replace(`
|
||
`,"<br/>"),e=e.replace(/#(\d+)/g,'<a href="'+this.globals.github+'/issues/$1" target="_blank">#$1</a>'),e}}},qM={class:"body-title"},zM=["href"],GM=["href"],YM=["src","alt"],XM={key:0},JM=["href"],ZM={key:0,class:"has-new-version"},QM=["href"],eF=["href"],tF={class:"version-list"},nF={class:"item-header"},rF={class:"version-sha"},iF=["href"],oF={class:"version-date"},sF=["innerHTML"];function aF(e,t,n,r,i,o){const s=Ye("icon-svg");return E(),Ue(un,{name:"fadeDown"},{default:tn(()=>[i.isOpen?(E(),M("div",{key:0,class:"physton-about-prompt",onClick:t[3]||(t[3]=(...l)=>o.close&&o.close(...l))},[T("div",{class:"about-main",onClick:t[2]||(t[2]=nt(()=>{},["stop"]))},[T("div",{class:"about-close",onClick:t[0]||(t[0]=(...l)=>o.close&&o.close(...l))},[ye(s,{name:"close"})]),T("div",{class:"about-body",onClick:t[1]||(t[1]=nt(()=>{},["stop"]))},[T("p",qM,[T("a",{href:e.globals.github,target:"_blank"},ie(e.globals.name),9,zM)]),T("p",null,[(E(!0),M(De,null,ot(i.icons,l=>(E(),M("a",{key:l.title,href:l.url,target:"_blank"},[T("img",{src:l.image,alt:l.title},null,8,YM)],8,GM))),128))]),i.loading?ke("",!0):(E(),M("p",XM,[T("span",null,[jt(ie(e.getLang("version"))+": ",1),T("a",{href:o.commitUrl(i.version),target:"_blank"},ie(o.formatVersion(i.version)),9,JM)]),!i.isLatestVersion&&i.latestVersion?(E(),M("span",ZM,[jt(" ("+ie(e.getLang("has_new_version"))+": ",1),T("a",{href:o.commitUrl(i.latestVersion),target:"_blank"},ie(o.formatVersion(i.latestVersion)),9,QM),jt(")")])):ke("",!0)])),T("p",null,[jt(ie(e.getLang("wiki_desc"))+" ",1),T("a",{href:e.replaceGlobals("{{docs}}"),target:"_blank"},"Wiki",8,eF)]),T("div",tF,[i.loading?(E(),Ue(s,{key:0,name:"loading"})):ke("",!0),(E(!0),M(De,null,ot(i.versions,l=>(E(),M("div",{class:"version-item",key:l.version},[T("div",nF,[T("div",rF,[T("a",{href:o.commitUrl(l.version),target:"_blank"},ie(o.formatVersion(l.version)),9,iF)]),T("div",oF,ie(l.date),1)]),T("div",{class:"version-msg",innerHTML:o.message(l.message)},null,8,sF)]))),128))])])])])):ke("",!0)]),_:1})}const lF=hn(VM,[["render",aF]]);/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */function Ty(e){return typeof e>"u"||e===null}function uF(e){return typeof e=="object"&&e!==null}function cF(e){return Array.isArray(e)?e:Ty(e)?[]:[e]}function fF(e,t){var n,r,i,o;if(t)for(o=Object.keys(t),n=0,r=o.length;n<r;n+=1)i=o[n],e[i]=t[i];return e}function dF(e,t){var n="",r;for(r=0;r<t;r+=1)n+=e;return n}function pF(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}var hF=Ty,gF=uF,mF=cF,vF=dF,yF=pF,bF=fF,sn={isNothing:hF,isObject:gF,toArray:mF,repeat:vF,isNegativeZero:yF,extend:bF};function ky(e,t){var n="",r=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(n+='in "'+e.mark.name+'" '),n+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!t&&e.mark.snippet&&(n+=`
|
||
|
||
`+e.mark.snippet),r+" "+n):r}function Ta(e,t){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=t,this.message=ky(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}Ta.prototype=Object.create(Error.prototype),Ta.prototype.constructor=Ta,Ta.prototype.toString=function(t){return this.name+": "+ky(this,t)};var On=Ta;function _d(e,t,n,r,i){var o="",s="",l=Math.floor(i/2)-1;return r-t>l&&(o=" ... ",t=r-l+o.length),n-r>l&&(s=" ...",n=r+l-s.length),{str:o+e.slice(t,n).replace(/\t/g,"→")+s,pos:r-t+o.length}}function wd(e,t){return sn.repeat(" ",t-e.length)+e}function CF(e,t){if(t=Object.create(t||null),!e.buffer)return null;t.maxLength||(t.maxLength=79),typeof t.indent!="number"&&(t.indent=1),typeof t.linesBefore!="number"&&(t.linesBefore=3),typeof t.linesAfter!="number"&&(t.linesAfter=2);for(var n=/\r?\n|\r|\0/g,r=[0],i=[],o,s=-1;o=n.exec(e.buffer);)i.push(o.index),r.push(o.index+o[0].length),e.position<=o.index&&s<0&&(s=r.length-2);s<0&&(s=r.length-1);var l="",c,d,p=Math.min(e.line+t.linesAfter,i.length).toString().length,y=t.maxLength-(t.indent+p+3);for(c=1;c<=t.linesBefore&&!(s-c<0);c++)d=_d(e.buffer,r[s-c],i[s-c],e.position-(r[s]-r[s-c]),y),l=sn.repeat(" ",t.indent)+wd((e.line-c+1).toString(),p)+" | "+d.str+`
|
||
`+l;for(d=_d(e.buffer,r[s],i[s],e.position,y),l+=sn.repeat(" ",t.indent)+wd((e.line+1).toString(),p)+" | "+d.str+`
|
||
`,l+=sn.repeat("-",t.indent+p+3+d.pos)+`^
|
||
`,c=1;c<=t.linesAfter&&!(s+c>=i.length);c++)d=_d(e.buffer,r[s+c],i[s+c],e.position-(r[s]-r[s+c]),y),l+=sn.repeat(" ",t.indent)+wd((e.line+c+1).toString(),p)+" | "+d.str+`
|
||
`;return l.replace(/\n$/,"")}var _F=CF,wF=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],TF=["scalar","sequence","mapping"];function kF(e){var t={};return e!==null&&Object.keys(e).forEach(function(n){e[n].forEach(function(r){t[String(r)]=n})}),t}function xF(e,t){if(t=t||{},Object.keys(t).forEach(function(n){if(wF.indexOf(n)===-1)throw new On('Unknown option "'+n+'" is met in definition of "'+e+'" YAML type.')}),this.options=t,this.tag=e,this.kind=t.kind||null,this.resolve=t.resolve||function(){return!0},this.construct=t.construct||function(n){return n},this.instanceOf=t.instanceOf||null,this.predicate=t.predicate||null,this.represent=t.represent||null,this.representName=t.representName||null,this.defaultStyle=t.defaultStyle||null,this.multi=t.multi||!1,this.styleAliases=kF(t.styleAliases||null),TF.indexOf(this.kind)===-1)throw new On('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')}var gn=xF;function xy(e,t){var n=[];return e[t].forEach(function(r){var i=n.length;n.forEach(function(o,s){o.tag===r.tag&&o.kind===r.kind&&o.multi===r.multi&&(i=s)}),n[i]=r}),n}function SF(){var e={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},t,n;function r(i){i.multi?(e.multi[i.kind].push(i),e.multi.fallback.push(i)):e[i.kind][i.tag]=e.fallback[i.tag]=i}for(t=0,n=arguments.length;t<n;t+=1)arguments[t].forEach(r);return e}function Td(e){return this.extend(e)}Td.prototype.extend=function(t){var n=[],r=[];if(t instanceof gn)r.push(t);else if(Array.isArray(t))r=r.concat(t);else if(t&&(Array.isArray(t.implicit)||Array.isArray(t.explicit)))t.implicit&&(n=n.concat(t.implicit)),t.explicit&&(r=r.concat(t.explicit));else throw new On("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");n.forEach(function(o){if(!(o instanceof gn))throw new On("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(o.loadKind&&o.loadKind!=="scalar")throw new On("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(o.multi)throw new On("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),r.forEach(function(o){if(!(o instanceof gn))throw new On("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var i=Object.create(Td.prototype);return i.implicit=(this.implicit||[]).concat(n),i.explicit=(this.explicit||[]).concat(r),i.compiledImplicit=xy(i,"implicit"),i.compiledExplicit=xy(i,"explicit"),i.compiledTypeMap=SF(i.compiledImplicit,i.compiledExplicit),i};var Sy=Td,Ay=new gn("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return e!==null?e:""}}),Ey=new gn("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return e!==null?e:[]}}),Ly=new gn("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return e!==null?e:{}}}),Oy=new Sy({explicit:[Ay,Ey,Ly]});function AF(e){if(e===null)return!0;var t=e.length;return t===1&&e==="~"||t===4&&(e==="null"||e==="Null"||e==="NULL")}function EF(){return null}function LF(e){return e===null}var Iy=new gn("tag:yaml.org,2002:null",{kind:"scalar",resolve:AF,construct:EF,predicate:LF,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"});function OF(e){if(e===null)return!1;var t=e.length;return t===4&&(e==="true"||e==="True"||e==="TRUE")||t===5&&(e==="false"||e==="False"||e==="FALSE")}function IF(e){return e==="true"||e==="True"||e==="TRUE"}function PF(e){return Object.prototype.toString.call(e)==="[object Boolean]"}var Py=new gn("tag:yaml.org,2002:bool",{kind:"scalar",resolve:OF,construct:IF,predicate:PF,represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"});function DF(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function RF(e){return 48<=e&&e<=55}function NF(e){return 48<=e&&e<=57}function MF(e){if(e===null)return!1;var t=e.length,n=0,r=!1,i;if(!t)return!1;if(i=e[n],(i==="-"||i==="+")&&(i=e[++n]),i==="0"){if(n+1===t)return!0;if(i=e[++n],i==="b"){for(n++;n<t;n++)if(i=e[n],i!=="_"){if(i!=="0"&&i!=="1")return!1;r=!0}return r&&i!=="_"}if(i==="x"){for(n++;n<t;n++)if(i=e[n],i!=="_"){if(!DF(e.charCodeAt(n)))return!1;r=!0}return r&&i!=="_"}if(i==="o"){for(n++;n<t;n++)if(i=e[n],i!=="_"){if(!RF(e.charCodeAt(n)))return!1;r=!0}return r&&i!=="_"}}if(i==="_")return!1;for(;n<t;n++)if(i=e[n],i!=="_"){if(!NF(e.charCodeAt(n)))return!1;r=!0}return!(!r||i==="_")}function FF(e){var t=e,n=1,r;if(t.indexOf("_")!==-1&&(t=t.replace(/_/g,"")),r=t[0],(r==="-"||r==="+")&&(r==="-"&&(n=-1),t=t.slice(1),r=t[0]),t==="0")return 0;if(r==="0"){if(t[1]==="b")return n*parseInt(t.slice(2),2);if(t[1]==="x")return n*parseInt(t.slice(2),16);if(t[1]==="o")return n*parseInt(t.slice(2),8)}return n*parseInt(t,10)}function BF(e){return Object.prototype.toString.call(e)==="[object Number]"&&e%1===0&&!sn.isNegativeZero(e)}var Dy=new gn("tag:yaml.org,2002:int",{kind:"scalar",resolve:MF,construct:FF,predicate:BF,represent:{binary:function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},octal:function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),$F=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function HF(e){return!(e===null||!$F.test(e)||e[e.length-1]==="_")}function jF(e){var t,n;return t=e.replace(/_/g,"").toLowerCase(),n=t[0]==="-"?-1:1,"+-".indexOf(t[0])>=0&&(t=t.slice(1)),t===".inf"?n===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:t===".nan"?NaN:n*parseFloat(t,10)}var UF=/^[-+]?[0-9]+e/;function WF(e,t){var n;if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(sn.isNegativeZero(e))return"-0.0";return n=e.toString(10),UF.test(n)?n.replace("e",".e"):n}function KF(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1!==0||sn.isNegativeZero(e))}var Ry=new gn("tag:yaml.org,2002:float",{kind:"scalar",resolve:HF,construct:jF,predicate:KF,represent:WF,defaultStyle:"lowercase"}),Ny=Oy.extend({implicit:[Iy,Py,Dy,Ry]}),My=Ny,Fy=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),By=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function VF(e){return e===null?!1:Fy.exec(e)!==null||By.exec(e)!==null}function qF(e){var t,n,r,i,o,s,l,c=0,d=null,p,y,m;if(t=Fy.exec(e),t===null&&(t=By.exec(e)),t===null)throw new Error("Date resolve error");if(n=+t[1],r=+t[2]-1,i=+t[3],!t[4])return new Date(Date.UTC(n,r,i));if(o=+t[4],s=+t[5],l=+t[6],t[7]){for(c=t[7].slice(0,3);c.length<3;)c+="0";c=+c}return t[9]&&(p=+t[10],y=+(t[11]||0),d=(p*60+y)*6e4,t[9]==="-"&&(d=-d)),m=new Date(Date.UTC(n,r,i,o,s,l,c)),d&&m.setTime(m.getTime()-d),m}function zF(e){return e.toISOString()}var $y=new gn("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:VF,construct:qF,instanceOf:Date,represent:zF});function GF(e){return e==="<<"||e===null}var Hy=new gn("tag:yaml.org,2002:merge",{kind:"scalar",resolve:GF}),kd=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
||
\r`;function YF(e){if(e===null)return!1;var t,n,r=0,i=e.length,o=kd;for(n=0;n<i;n++)if(t=o.indexOf(e.charAt(n)),!(t>64)){if(t<0)return!1;r+=6}return r%8===0}function XF(e){var t,n,r=e.replace(/[\r\n=]/g,""),i=r.length,o=kd,s=0,l=[];for(t=0;t<i;t++)t%4===0&&t&&(l.push(s>>16&255),l.push(s>>8&255),l.push(s&255)),s=s<<6|o.indexOf(r.charAt(t));return n=i%4*6,n===0?(l.push(s>>16&255),l.push(s>>8&255),l.push(s&255)):n===18?(l.push(s>>10&255),l.push(s>>2&255)):n===12&&l.push(s>>4&255),new Uint8Array(l)}function JF(e){var t="",n=0,r,i,o=e.length,s=kd;for(r=0;r<o;r++)r%3===0&&r&&(t+=s[n>>18&63],t+=s[n>>12&63],t+=s[n>>6&63],t+=s[n&63]),n=(n<<8)+e[r];return i=o%3,i===0?(t+=s[n>>18&63],t+=s[n>>12&63],t+=s[n>>6&63],t+=s[n&63]):i===2?(t+=s[n>>10&63],t+=s[n>>4&63],t+=s[n<<2&63],t+=s[64]):i===1&&(t+=s[n>>2&63],t+=s[n<<4&63],t+=s[64],t+=s[64]),t}function ZF(e){return Object.prototype.toString.call(e)==="[object Uint8Array]"}var jy=new gn("tag:yaml.org,2002:binary",{kind:"scalar",resolve:YF,construct:XF,predicate:ZF,represent:JF}),QF=Object.prototype.hasOwnProperty,eB=Object.prototype.toString;function tB(e){if(e===null)return!0;var t=[],n,r,i,o,s,l=e;for(n=0,r=l.length;n<r;n+=1){if(i=l[n],s=!1,eB.call(i)!=="[object Object]")return!1;for(o in i)if(QF.call(i,o))if(!s)s=!0;else return!1;if(!s)return!1;if(t.indexOf(o)===-1)t.push(o);else return!1}return!0}function nB(e){return e!==null?e:[]}var Uy=new gn("tag:yaml.org,2002:omap",{kind:"sequence",resolve:tB,construct:nB}),rB=Object.prototype.toString;function iB(e){if(e===null)return!0;var t,n,r,i,o,s=e;for(o=new Array(s.length),t=0,n=s.length;t<n;t+=1){if(r=s[t],rB.call(r)!=="[object Object]"||(i=Object.keys(r),i.length!==1))return!1;o[t]=[i[0],r[i[0]]]}return!0}function oB(e){if(e===null)return[];var t,n,r,i,o,s=e;for(o=new Array(s.length),t=0,n=s.length;t<n;t+=1)r=s[t],i=Object.keys(r),o[t]=[i[0],r[i[0]]];return o}var Wy=new gn("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:iB,construct:oB}),sB=Object.prototype.hasOwnProperty;function aB(e){if(e===null)return!0;var t,n=e;for(t in n)if(sB.call(n,t)&&n[t]!==null)return!1;return!0}function lB(e){return e!==null?e:{}}var Ky=new gn("tag:yaml.org,2002:set",{kind:"mapping",resolve:aB,construct:lB}),xd=My.extend({implicit:[$y,Hy],explicit:[jy,Uy,Wy,Ky]}),Si=Object.prototype.hasOwnProperty,bu=1,Vy=2,qy=3,Cu=4,Sd=1,uB=2,zy=3,cB=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,fB=/[\x85\u2028\u2029]/,dB=/[,\[\]\{\}]/,Gy=/^(?:!|!!|![a-z\-]+!)$/i,Yy=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function Xy(e){return Object.prototype.toString.call(e)}function Fr(e){return e===10||e===13}function oo(e){return e===9||e===32}function Hn(e){return e===9||e===32||e===10||e===13}function ss(e){return e===44||e===91||e===93||e===123||e===125}function pB(e){var t;return 48<=e&&e<=57?e-48:(t=e|32,97<=t&&t<=102?t-97+10:-1)}function hB(e){return e===120?2:e===117?4:e===85?8:0}function gB(e){return 48<=e&&e<=57?e-48:-1}function Jy(e){return e===48?"\0":e===97?"\x07":e===98?"\b":e===116||e===9?" ":e===110?`
|
||
`:e===118?"\v":e===102?"\f":e===114?"\r":e===101?"\x1B":e===32?" ":e===34?'"':e===47?"/":e===92?"\\":e===78?"
":e===95?" ":e===76?"\u2028":e===80?"\u2029":""}function mB(e){return e<=65535?String.fromCharCode(e):String.fromCharCode((e-65536>>10)+55296,(e-65536&1023)+56320)}for(var Zy=new Array(256),Qy=new Array(256),as=0;as<256;as++)Zy[as]=Jy(as)?1:0,Qy[as]=Jy(as);function vB(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||xd,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function e0(e,t){var n={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return n.snippet=_F(n),new On(t,n)}function Ke(e,t){throw e0(e,t)}function _u(e,t){e.onWarning&&e.onWarning.call(null,e0(e,t))}var t0={YAML:function(t,n,r){var i,o,s;t.version!==null&&Ke(t,"duplication of %YAML directive"),r.length!==1&&Ke(t,"YAML directive accepts exactly one argument"),i=/^([0-9]+)\.([0-9]+)$/.exec(r[0]),i===null&&Ke(t,"ill-formed argument of the YAML directive"),o=parseInt(i[1],10),s=parseInt(i[2],10),o!==1&&Ke(t,"unacceptable YAML version of the document"),t.version=r[0],t.checkLineBreaks=s<2,s!==1&&s!==2&&_u(t,"unsupported YAML version of the document")},TAG:function(t,n,r){var i,o;r.length!==2&&Ke(t,"TAG directive accepts exactly two arguments"),i=r[0],o=r[1],Gy.test(i)||Ke(t,"ill-formed tag handle (first argument) of the TAG directive"),Si.call(t.tagMap,i)&&Ke(t,'there is a previously declared suffix for "'+i+'" tag handle'),Yy.test(o)||Ke(t,"ill-formed tag prefix (second argument) of the TAG directive");try{o=decodeURIComponent(o)}catch{Ke(t,"tag prefix is malformed: "+o)}t.tagMap[i]=o}};function Ai(e,t,n,r){var i,o,s,l;if(t<n){if(l=e.input.slice(t,n),r)for(i=0,o=l.length;i<o;i+=1)s=l.charCodeAt(i),s===9||32<=s&&s<=1114111||Ke(e,"expected valid JSON character");else cB.test(l)&&Ke(e,"the stream contains non-printable characters");e.result+=l}}function n0(e,t,n,r){var i,o,s,l;for(sn.isObject(n)||Ke(e,"cannot merge mappings; the provided source object is unacceptable"),i=Object.keys(n),s=0,l=i.length;s<l;s+=1)o=i[s],Si.call(t,o)||(t[o]=n[o],r[o]=!0)}function ls(e,t,n,r,i,o,s,l,c){var d,p;if(Array.isArray(i))for(i=Array.prototype.slice.call(i),d=0,p=i.length;d<p;d+=1)Array.isArray(i[d])&&Ke(e,"nested arrays are not supported inside keys"),typeof i=="object"&&Xy(i[d])==="[object Object]"&&(i[d]="[object Object]");if(typeof i=="object"&&Xy(i)==="[object Object]"&&(i="[object Object]"),i=String(i),t===null&&(t={}),r==="tag:yaml.org,2002:merge")if(Array.isArray(o))for(d=0,p=o.length;d<p;d+=1)n0(e,t,o[d],n);else n0(e,t,o,n);else!e.json&&!Si.call(n,i)&&Si.call(t,i)&&(e.line=s||e.line,e.lineStart=l||e.lineStart,e.position=c||e.position,Ke(e,"duplicated mapping key")),i==="__proto__"?Object.defineProperty(t,i,{configurable:!0,enumerable:!0,writable:!0,value:o}):t[i]=o,delete n[i];return t}function Ad(e){var t;t=e.input.charCodeAt(e.position),t===10?e.position++:t===13?(e.position++,e.input.charCodeAt(e.position)===10&&e.position++):Ke(e,"a line break is expected"),e.line+=1,e.lineStart=e.position,e.firstTabInLine=-1}function Zt(e,t,n){for(var r=0,i=e.input.charCodeAt(e.position);i!==0;){for(;oo(i);)i===9&&e.firstTabInLine===-1&&(e.firstTabInLine=e.position),i=e.input.charCodeAt(++e.position);if(t&&i===35)do i=e.input.charCodeAt(++e.position);while(i!==10&&i!==13&&i!==0);if(Fr(i))for(Ad(e),i=e.input.charCodeAt(e.position),r++,e.lineIndent=0;i===32;)e.lineIndent++,i=e.input.charCodeAt(++e.position);else break}return n!==-1&&r!==0&&e.lineIndent<n&&_u(e,"deficient indentation"),r}function wu(e){var t=e.position,n;return n=e.input.charCodeAt(t),!!((n===45||n===46)&&n===e.input.charCodeAt(t+1)&&n===e.input.charCodeAt(t+2)&&(t+=3,n=e.input.charCodeAt(t),n===0||Hn(n)))}function Ed(e,t){t===1?e.result+=" ":t>1&&(e.result+=sn.repeat(`
|
||
`,t-1))}function yB(e,t,n){var r,i,o,s,l,c,d,p,y=e.kind,m=e.result,C;if(C=e.input.charCodeAt(e.position),Hn(C)||ss(C)||C===35||C===38||C===42||C===33||C===124||C===62||C===39||C===34||C===37||C===64||C===96||(C===63||C===45)&&(i=e.input.charCodeAt(e.position+1),Hn(i)||n&&ss(i)))return!1;for(e.kind="scalar",e.result="",o=s=e.position,l=!1;C!==0;){if(C===58){if(i=e.input.charCodeAt(e.position+1),Hn(i)||n&&ss(i))break}else if(C===35){if(r=e.input.charCodeAt(e.position-1),Hn(r))break}else{if(e.position===e.lineStart&&wu(e)||n&&ss(C))break;if(Fr(C))if(c=e.line,d=e.lineStart,p=e.lineIndent,Zt(e,!1,-1),e.lineIndent>=t){l=!0,C=e.input.charCodeAt(e.position);continue}else{e.position=s,e.line=c,e.lineStart=d,e.lineIndent=p;break}}l&&(Ai(e,o,s,!1),Ed(e,e.line-c),o=s=e.position,l=!1),oo(C)||(s=e.position+1),C=e.input.charCodeAt(++e.position)}return Ai(e,o,s,!1),e.result?!0:(e.kind=y,e.result=m,!1)}function bB(e,t){var n,r,i;if(n=e.input.charCodeAt(e.position),n!==39)return!1;for(e.kind="scalar",e.result="",e.position++,r=i=e.position;(n=e.input.charCodeAt(e.position))!==0;)if(n===39)if(Ai(e,r,e.position,!0),n=e.input.charCodeAt(++e.position),n===39)r=e.position,e.position++,i=e.position;else return!0;else Fr(n)?(Ai(e,r,i,!0),Ed(e,Zt(e,!1,t)),r=i=e.position):e.position===e.lineStart&&wu(e)?Ke(e,"unexpected end of the document within a single quoted scalar"):(e.position++,i=e.position);Ke(e,"unexpected end of the stream within a single quoted scalar")}function CB(e,t){var n,r,i,o,s,l;if(l=e.input.charCodeAt(e.position),l!==34)return!1;for(e.kind="scalar",e.result="",e.position++,n=r=e.position;(l=e.input.charCodeAt(e.position))!==0;){if(l===34)return Ai(e,n,e.position,!0),e.position++,!0;if(l===92){if(Ai(e,n,e.position,!0),l=e.input.charCodeAt(++e.position),Fr(l))Zt(e,!1,t);else if(l<256&&Zy[l])e.result+=Qy[l],e.position++;else if((s=hB(l))>0){for(i=s,o=0;i>0;i--)l=e.input.charCodeAt(++e.position),(s=pB(l))>=0?o=(o<<4)+s:Ke(e,"expected hexadecimal character");e.result+=mB(o),e.position++}else Ke(e,"unknown escape sequence");n=r=e.position}else Fr(l)?(Ai(e,n,r,!0),Ed(e,Zt(e,!1,t)),n=r=e.position):e.position===e.lineStart&&wu(e)?Ke(e,"unexpected end of the document within a double quoted scalar"):(e.position++,r=e.position)}Ke(e,"unexpected end of the stream within a double quoted scalar")}function _B(e,t){var n=!0,r,i,o,s=e.tag,l,c=e.anchor,d,p,y,m,C,b=Object.create(null),k,L,O,$;if($=e.input.charCodeAt(e.position),$===91)p=93,C=!1,l=[];else if($===123)p=125,C=!0,l={};else return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=l),$=e.input.charCodeAt(++e.position);$!==0;){if(Zt(e,!0,t),$=e.input.charCodeAt(e.position),$===p)return e.position++,e.tag=s,e.anchor=c,e.kind=C?"mapping":"sequence",e.result=l,!0;n?$===44&&Ke(e,"expected the node content, but found ','"):Ke(e,"missed comma between flow collection entries"),L=k=O=null,y=m=!1,$===63&&(d=e.input.charCodeAt(e.position+1),Hn(d)&&(y=m=!0,e.position++,Zt(e,!0,t))),r=e.line,i=e.lineStart,o=e.position,us(e,t,bu,!1,!0),L=e.tag,k=e.result,Zt(e,!0,t),$=e.input.charCodeAt(e.position),(m||e.line===r)&&$===58&&(y=!0,$=e.input.charCodeAt(++e.position),Zt(e,!0,t),us(e,t,bu,!1,!0),O=e.result),C?ls(e,l,b,L,k,O,r,i,o):y?l.push(ls(e,null,b,L,k,O,r,i,o)):l.push(k),Zt(e,!0,t),$=e.input.charCodeAt(e.position),$===44?(n=!0,$=e.input.charCodeAt(++e.position)):n=!1}Ke(e,"unexpected end of the stream within a flow collection")}function wB(e,t){var n,r,i=Sd,o=!1,s=!1,l=t,c=0,d=!1,p,y;if(y=e.input.charCodeAt(e.position),y===124)r=!1;else if(y===62)r=!0;else return!1;for(e.kind="scalar",e.result="";y!==0;)if(y=e.input.charCodeAt(++e.position),y===43||y===45)Sd===i?i=y===43?zy:uB:Ke(e,"repeat of a chomping mode identifier");else if((p=gB(y))>=0)p===0?Ke(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):s?Ke(e,"repeat of an indentation width identifier"):(l=t+p-1,s=!0);else break;if(oo(y)){do y=e.input.charCodeAt(++e.position);while(oo(y));if(y===35)do y=e.input.charCodeAt(++e.position);while(!Fr(y)&&y!==0)}for(;y!==0;){for(Ad(e),e.lineIndent=0,y=e.input.charCodeAt(e.position);(!s||e.lineIndent<l)&&y===32;)e.lineIndent++,y=e.input.charCodeAt(++e.position);if(!s&&e.lineIndent>l&&(l=e.lineIndent),Fr(y)){c++;continue}if(e.lineIndent<l){i===zy?e.result+=sn.repeat(`
|
||
`,o?1+c:c):i===Sd&&o&&(e.result+=`
|
||
`);break}for(r?oo(y)?(d=!0,e.result+=sn.repeat(`
|
||
`,o?1+c:c)):d?(d=!1,e.result+=sn.repeat(`
|
||
`,c+1)):c===0?o&&(e.result+=" "):e.result+=sn.repeat(`
|
||
`,c):e.result+=sn.repeat(`
|
||
`,o?1+c:c),o=!0,s=!0,c=0,n=e.position;!Fr(y)&&y!==0;)y=e.input.charCodeAt(++e.position);Ai(e,n,e.position,!1)}return!0}function r0(e,t){var n,r=e.tag,i=e.anchor,o=[],s,l=!1,c;if(e.firstTabInLine!==-1)return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=o),c=e.input.charCodeAt(e.position);c!==0&&(e.firstTabInLine!==-1&&(e.position=e.firstTabInLine,Ke(e,"tab characters must not be used in indentation")),!(c!==45||(s=e.input.charCodeAt(e.position+1),!Hn(s))));){if(l=!0,e.position++,Zt(e,!0,-1)&&e.lineIndent<=t){o.push(null),c=e.input.charCodeAt(e.position);continue}if(n=e.line,us(e,t,qy,!1,!0),o.push(e.result),Zt(e,!0,-1),c=e.input.charCodeAt(e.position),(e.line===n||e.lineIndent>t)&&c!==0)Ke(e,"bad indentation of a sequence entry");else if(e.lineIndent<t)break}return l?(e.tag=r,e.anchor=i,e.kind="sequence",e.result=o,!0):!1}function TB(e,t,n){var r,i,o,s,l,c,d=e.tag,p=e.anchor,y={},m=Object.create(null),C=null,b=null,k=null,L=!1,O=!1,$;if(e.firstTabInLine!==-1)return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=y),$=e.input.charCodeAt(e.position);$!==0;){if(!L&&e.firstTabInLine!==-1&&(e.position=e.firstTabInLine,Ke(e,"tab characters must not be used in indentation")),r=e.input.charCodeAt(e.position+1),o=e.line,($===63||$===58)&&Hn(r))$===63?(L&&(ls(e,y,m,C,b,null,s,l,c),C=b=k=null),O=!0,L=!0,i=!0):L?(L=!1,i=!0):Ke(e,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),e.position+=1,$=r;else{if(s=e.line,l=e.lineStart,c=e.position,!us(e,n,Vy,!1,!0))break;if(e.line===o){for($=e.input.charCodeAt(e.position);oo($);)$=e.input.charCodeAt(++e.position);if($===58)$=e.input.charCodeAt(++e.position),Hn($)||Ke(e,"a whitespace character is expected after the key-value separator within a block mapping"),L&&(ls(e,y,m,C,b,null,s,l,c),C=b=k=null),O=!0,L=!1,i=!1,C=e.tag,b=e.result;else if(O)Ke(e,"can not read an implicit mapping pair; a colon is missed");else return e.tag=d,e.anchor=p,!0}else if(O)Ke(e,"can not read a block mapping entry; a multiline key may not be an implicit key");else return e.tag=d,e.anchor=p,!0}if((e.line===o||e.lineIndent>t)&&(L&&(s=e.line,l=e.lineStart,c=e.position),us(e,t,Cu,!0,i)&&(L?b=e.result:k=e.result),L||(ls(e,y,m,C,b,k,s,l,c),C=b=k=null),Zt(e,!0,-1),$=e.input.charCodeAt(e.position)),(e.line===o||e.lineIndent>t)&&$!==0)Ke(e,"bad indentation of a mapping entry");else if(e.lineIndent<t)break}return L&&ls(e,y,m,C,b,null,s,l,c),O&&(e.tag=d,e.anchor=p,e.kind="mapping",e.result=y),O}function kB(e){var t,n=!1,r=!1,i,o,s;if(s=e.input.charCodeAt(e.position),s!==33)return!1;if(e.tag!==null&&Ke(e,"duplication of a tag property"),s=e.input.charCodeAt(++e.position),s===60?(n=!0,s=e.input.charCodeAt(++e.position)):s===33?(r=!0,i="!!",s=e.input.charCodeAt(++e.position)):i="!",t=e.position,n){do s=e.input.charCodeAt(++e.position);while(s!==0&&s!==62);e.position<e.length?(o=e.input.slice(t,e.position),s=e.input.charCodeAt(++e.position)):Ke(e,"unexpected end of the stream within a verbatim tag")}else{for(;s!==0&&!Hn(s);)s===33&&(r?Ke(e,"tag suffix cannot contain exclamation marks"):(i=e.input.slice(t-1,e.position+1),Gy.test(i)||Ke(e,"named tag handle cannot contain such characters"),r=!0,t=e.position+1)),s=e.input.charCodeAt(++e.position);o=e.input.slice(t,e.position),dB.test(o)&&Ke(e,"tag suffix cannot contain flow indicator characters")}o&&!Yy.test(o)&&Ke(e,"tag name cannot contain such characters: "+o);try{o=decodeURIComponent(o)}catch{Ke(e,"tag name is malformed: "+o)}return n?e.tag=o:Si.call(e.tagMap,i)?e.tag=e.tagMap[i]+o:i==="!"?e.tag="!"+o:i==="!!"?e.tag="tag:yaml.org,2002:"+o:Ke(e,'undeclared tag handle "'+i+'"'),!0}function xB(e){var t,n;if(n=e.input.charCodeAt(e.position),n!==38)return!1;for(e.anchor!==null&&Ke(e,"duplication of an anchor property"),n=e.input.charCodeAt(++e.position),t=e.position;n!==0&&!Hn(n)&&!ss(n);)n=e.input.charCodeAt(++e.position);return e.position===t&&Ke(e,"name of an anchor node must contain at least one character"),e.anchor=e.input.slice(t,e.position),!0}function SB(e){var t,n,r;if(r=e.input.charCodeAt(e.position),r!==42)return!1;for(r=e.input.charCodeAt(++e.position),t=e.position;r!==0&&!Hn(r)&&!ss(r);)r=e.input.charCodeAt(++e.position);return e.position===t&&Ke(e,"name of an alias node must contain at least one character"),n=e.input.slice(t,e.position),Si.call(e.anchorMap,n)||Ke(e,'unidentified alias "'+n+'"'),e.result=e.anchorMap[n],Zt(e,!0,-1),!0}function us(e,t,n,r,i){var o,s,l,c=1,d=!1,p=!1,y,m,C,b,k,L;if(e.listener!==null&&e.listener("open",e),e.tag=null,e.anchor=null,e.kind=null,e.result=null,o=s=l=Cu===n||qy===n,r&&Zt(e,!0,-1)&&(d=!0,e.lineIndent>t?c=1:e.lineIndent===t?c=0:e.lineIndent<t&&(c=-1)),c===1)for(;kB(e)||xB(e);)Zt(e,!0,-1)?(d=!0,l=o,e.lineIndent>t?c=1:e.lineIndent===t?c=0:e.lineIndent<t&&(c=-1)):l=!1;if(l&&(l=d||i),(c===1||Cu===n)&&(bu===n||Vy===n?k=t:k=t+1,L=e.position-e.lineStart,c===1?l&&(r0(e,L)||TB(e,L,k))||_B(e,k)?p=!0:(s&&wB(e,k)||bB(e,k)||CB(e,k)?p=!0:SB(e)?(p=!0,(e.tag!==null||e.anchor!==null)&&Ke(e,"alias node should not have any properties")):yB(e,k,bu===n)&&(p=!0,e.tag===null&&(e.tag="?")),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result)):c===0&&(p=l&&r0(e,L))),e.tag===null)e.anchor!==null&&(e.anchorMap[e.anchor]=e.result);else if(e.tag==="?"){for(e.result!==null&&e.kind!=="scalar"&&Ke(e,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+e.kind+'"'),y=0,m=e.implicitTypes.length;y<m;y+=1)if(b=e.implicitTypes[y],b.resolve(e.result)){e.result=b.construct(e.result),e.tag=b.tag,e.anchor!==null&&(e.anchorMap[e.anchor]=e.result);break}}else if(e.tag!=="!"){if(Si.call(e.typeMap[e.kind||"fallback"],e.tag))b=e.typeMap[e.kind||"fallback"][e.tag];else for(b=null,C=e.typeMap.multi[e.kind||"fallback"],y=0,m=C.length;y<m;y+=1)if(e.tag.slice(0,C[y].tag.length)===C[y].tag){b=C[y];break}b||Ke(e,"unknown tag !<"+e.tag+">"),e.result!==null&&b.kind!==e.kind&&Ke(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+b.kind+'", not "'+e.kind+'"'),b.resolve(e.result,e.tag)?(e.result=b.construct(e.result,e.tag),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result)):Ke(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")}return e.listener!==null&&e.listener("close",e),e.tag!==null||e.anchor!==null||p}function AB(e){var t=e.position,n,r,i,o=!1,s;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);(s=e.input.charCodeAt(e.position))!==0&&(Zt(e,!0,-1),s=e.input.charCodeAt(e.position),!(e.lineIndent>0||s!==37));){for(o=!0,s=e.input.charCodeAt(++e.position),n=e.position;s!==0&&!Hn(s);)s=e.input.charCodeAt(++e.position);for(r=e.input.slice(n,e.position),i=[],r.length<1&&Ke(e,"directive name must not be less than one character in length");s!==0;){for(;oo(s);)s=e.input.charCodeAt(++e.position);if(s===35){do s=e.input.charCodeAt(++e.position);while(s!==0&&!Fr(s));break}if(Fr(s))break;for(n=e.position;s!==0&&!Hn(s);)s=e.input.charCodeAt(++e.position);i.push(e.input.slice(n,e.position))}s!==0&&Ad(e),Si.call(t0,r)?t0[r](e,r,i):_u(e,'unknown document directive "'+r+'"')}if(Zt(e,!0,-1),e.lineIndent===0&&e.input.charCodeAt(e.position)===45&&e.input.charCodeAt(e.position+1)===45&&e.input.charCodeAt(e.position+2)===45?(e.position+=3,Zt(e,!0,-1)):o&&Ke(e,"directives end mark is expected"),us(e,e.lineIndent-1,Cu,!1,!0),Zt(e,!0,-1),e.checkLineBreaks&&fB.test(e.input.slice(t,e.position))&&_u(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&wu(e)){e.input.charCodeAt(e.position)===46&&(e.position+=3,Zt(e,!0,-1));return}if(e.position<e.length-1)Ke(e,"end of the stream or a document separator is expected");else return}function i0(e,t){e=String(e),t=t||{},e.length!==0&&(e.charCodeAt(e.length-1)!==10&&e.charCodeAt(e.length-1)!==13&&(e+=`
|
||
`),e.charCodeAt(0)===65279&&(e=e.slice(1)));var n=new vB(e,t),r=e.indexOf("\0");for(r!==-1&&(n.position=r,Ke(n,"null byte is not allowed in input")),n.input+="\0";n.input.charCodeAt(n.position)===32;)n.lineIndent+=1,n.position+=1;for(;n.position<n.length-1;)AB(n);return n.documents}function EB(e,t,n){t!==null&&typeof t=="object"&&typeof n>"u"&&(n=t,t=null);var r=i0(e,n);if(typeof t!="function")return r;for(var i=0,o=r.length;i<o;i+=1)t(r[i])}function LB(e,t){var n=i0(e,t);if(n.length!==0){if(n.length===1)return n[0];throw new On("expected a single document in the stream, but found more")}}var OB=EB,IB=LB,o0={loadAll:OB,load:IB},s0=Object.prototype.toString,a0=Object.prototype.hasOwnProperty,Ld=65279,PB=9,ka=10,DB=13,RB=32,NB=33,MB=34,Od=35,FB=37,BB=38,$B=39,HB=42,l0=44,jB=45,Tu=58,UB=61,WB=62,KB=63,VB=64,u0=91,c0=93,qB=96,f0=123,zB=124,d0=125,xn={};xn[0]="\\0",xn[7]="\\a",xn[8]="\\b",xn[9]="\\t",xn[10]="\\n",xn[11]="\\v",xn[12]="\\f",xn[13]="\\r",xn[27]="\\e",xn[34]='\\"',xn[92]="\\\\",xn[133]="\\N",xn[160]="\\_",xn[8232]="\\L",xn[8233]="\\P";var GB=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],YB=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function XB(e,t){var n,r,i,o,s,l,c;if(t===null)return{};for(n={},r=Object.keys(t),i=0,o=r.length;i<o;i+=1)s=r[i],l=String(t[s]),s.slice(0,2)==="!!"&&(s="tag:yaml.org,2002:"+s.slice(2)),c=e.compiledTypeMap.fallback[s],c&&a0.call(c.styleAliases,l)&&(l=c.styleAliases[l]),n[s]=l;return n}function JB(e){var t,n,r;if(t=e.toString(16).toUpperCase(),e<=255)n="x",r=2;else if(e<=65535)n="u",r=4;else if(e<=4294967295)n="U",r=8;else throw new On("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+n+sn.repeat("0",r-t.length)+t}var ZB=1,xa=2;function QB(e){this.schema=e.schema||xd,this.indent=Math.max(1,e.indent||2),this.noArrayIndent=e.noArrayIndent||!1,this.skipInvalid=e.skipInvalid||!1,this.flowLevel=sn.isNothing(e.flowLevel)?-1:e.flowLevel,this.styleMap=XB(this.schema,e.styles||null),this.sortKeys=e.sortKeys||!1,this.lineWidth=e.lineWidth||80,this.noRefs=e.noRefs||!1,this.noCompatMode=e.noCompatMode||!1,this.condenseFlow=e.condenseFlow||!1,this.quotingType=e.quotingType==='"'?xa:ZB,this.forceQuotes=e.forceQuotes||!1,this.replacer=typeof e.replacer=="function"?e.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}function p0(e,t){for(var n=sn.repeat(" ",t),r=0,i=-1,o="",s,l=e.length;r<l;)i=e.indexOf(`
|
||
`,r),i===-1?(s=e.slice(r),r=l):(s=e.slice(r,i+1),r=i+1),s.length&&s!==`
|
||
`&&(o+=n),o+=s;return o}function Id(e,t){return`
|
||
`+sn.repeat(" ",e.indent*t)}function e$(e,t){var n,r,i;for(n=0,r=e.implicitTypes.length;n<r;n+=1)if(i=e.implicitTypes[n],i.resolve(t))return!0;return!1}function ku(e){return e===RB||e===PB}function Sa(e){return 32<=e&&e<=126||161<=e&&e<=55295&&e!==8232&&e!==8233||57344<=e&&e<=65533&&e!==Ld||65536<=e&&e<=1114111}function h0(e){return Sa(e)&&e!==Ld&&e!==DB&&e!==ka}function g0(e,t,n){var r=h0(e),i=r&&!ku(e);return(n?r:r&&e!==l0&&e!==u0&&e!==c0&&e!==f0&&e!==d0)&&e!==Od&&!(t===Tu&&!i)||h0(t)&&!ku(t)&&e===Od||t===Tu&&i}function t$(e){return Sa(e)&&e!==Ld&&!ku(e)&&e!==jB&&e!==KB&&e!==Tu&&e!==l0&&e!==u0&&e!==c0&&e!==f0&&e!==d0&&e!==Od&&e!==BB&&e!==HB&&e!==NB&&e!==zB&&e!==UB&&e!==WB&&e!==$B&&e!==MB&&e!==FB&&e!==VB&&e!==qB}function n$(e){return!ku(e)&&e!==Tu}function Aa(e,t){var n=e.charCodeAt(t),r;return n>=55296&&n<=56319&&t+1<e.length&&(r=e.charCodeAt(t+1),r>=56320&&r<=57343)?(n-55296)*1024+r-56320+65536:n}function m0(e){var t=/^\n* /;return t.test(e)}var v0=1,Pd=2,y0=3,b0=4,cs=5;function r$(e,t,n,r,i,o,s,l){var c,d=0,p=null,y=!1,m=!1,C=r!==-1,b=-1,k=t$(Aa(e,0))&&n$(Aa(e,e.length-1));if(t||s)for(c=0;c<e.length;d>=65536?c+=2:c++){if(d=Aa(e,c),!Sa(d))return cs;k=k&&g0(d,p,l),p=d}else{for(c=0;c<e.length;d>=65536?c+=2:c++){if(d=Aa(e,c),d===ka)y=!0,C&&(m=m||c-b-1>r&&e[b+1]!==" ",b=c);else if(!Sa(d))return cs;k=k&&g0(d,p,l),p=d}m=m||C&&c-b-1>r&&e[b+1]!==" "}return!y&&!m?k&&!s&&!i(e)?v0:o===xa?cs:Pd:n>9&&m0(e)?cs:s?o===xa?cs:Pd:m?b0:y0}function i$(e,t,n,r,i){e.dump=function(){if(t.length===0)return e.quotingType===xa?'""':"''";if(!e.noCompatMode&&(GB.indexOf(t)!==-1||YB.test(t)))return e.quotingType===xa?'"'+t+'"':"'"+t+"'";var o=e.indent*Math.max(1,n),s=e.lineWidth===-1?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-o),l=r||e.flowLevel>-1&&n>=e.flowLevel;function c(d){return e$(e,d)}switch(r$(t,l,e.indent,s,c,e.quotingType,e.forceQuotes&&!r,i)){case v0:return t;case Pd:return"'"+t.replace(/'/g,"''")+"'";case y0:return"|"+C0(t,e.indent)+_0(p0(t,o));case b0:return">"+C0(t,e.indent)+_0(p0(o$(t,s),o));case cs:return'"'+s$(t)+'"';default:throw new On("impossible error: invalid scalar style")}}()}function C0(e,t){var n=m0(e)?String(t):"",r=e[e.length-1]===`
|
||
`,i=r&&(e[e.length-2]===`
|
||
`||e===`
|
||
`),o=i?"+":r?"":"-";return n+o+`
|
||
`}function _0(e){return e[e.length-1]===`
|
||
`?e.slice(0,-1):e}function o$(e,t){for(var n=/(\n+)([^\n]*)/g,r=function(){var d=e.indexOf(`
|
||
`);return d=d!==-1?d:e.length,n.lastIndex=d,w0(e.slice(0,d),t)}(),i=e[0]===`
|
||
`||e[0]===" ",o,s;s=n.exec(e);){var l=s[1],c=s[2];o=c[0]===" ",r+=l+(!i&&!o&&c!==""?`
|
||
`:"")+w0(c,t),i=o}return r}function w0(e,t){if(e===""||e[0]===" ")return e;for(var n=/ [^ ]/g,r,i=0,o,s=0,l=0,c="";r=n.exec(e);)l=r.index,l-i>t&&(o=s>i?s:l,c+=`
|
||
`+e.slice(i,o),i=o+1),s=l;return c+=`
|
||
`,e.length-i>t&&s>i?c+=e.slice(i,s)+`
|
||
`+e.slice(s+1):c+=e.slice(i),c.slice(1)}function s$(e){for(var t="",n=0,r,i=0;i<e.length;n>=65536?i+=2:i++)n=Aa(e,i),r=xn[n],!r&&Sa(n)?(t+=e[i],n>=65536&&(t+=e[i+1])):t+=r||JB(n);return t}function a$(e,t,n){var r="",i=e.tag,o,s,l;for(o=0,s=n.length;o<s;o+=1)l=n[o],e.replacer&&(l=e.replacer.call(n,String(o),l)),(oi(e,t,l,!1,!1)||typeof l>"u"&&oi(e,t,null,!1,!1))&&(r!==""&&(r+=","+(e.condenseFlow?"":" ")),r+=e.dump);e.tag=i,e.dump="["+r+"]"}function T0(e,t,n,r){var i="",o=e.tag,s,l,c;for(s=0,l=n.length;s<l;s+=1)c=n[s],e.replacer&&(c=e.replacer.call(n,String(s),c)),(oi(e,t+1,c,!0,!0,!1,!0)||typeof c>"u"&&oi(e,t+1,null,!0,!0,!1,!0))&&((!r||i!=="")&&(i+=Id(e,t)),e.dump&&ka===e.dump.charCodeAt(0)?i+="-":i+="- ",i+=e.dump);e.tag=o,e.dump=i||"[]"}function l$(e,t,n){var r="",i=e.tag,o=Object.keys(n),s,l,c,d,p;for(s=0,l=o.length;s<l;s+=1)p="",r!==""&&(p+=", "),e.condenseFlow&&(p+='"'),c=o[s],d=n[c],e.replacer&&(d=e.replacer.call(n,c,d)),oi(e,t,c,!1,!1)&&(e.dump.length>1024&&(p+="? "),p+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" "),oi(e,t,d,!1,!1)&&(p+=e.dump,r+=p));e.tag=i,e.dump="{"+r+"}"}function u$(e,t,n,r){var i="",o=e.tag,s=Object.keys(n),l,c,d,p,y,m;if(e.sortKeys===!0)s.sort();else if(typeof e.sortKeys=="function")s.sort(e.sortKeys);else if(e.sortKeys)throw new On("sortKeys must be a boolean or a function");for(l=0,c=s.length;l<c;l+=1)m="",(!r||i!=="")&&(m+=Id(e,t)),d=s[l],p=n[d],e.replacer&&(p=e.replacer.call(n,d,p)),oi(e,t+1,d,!0,!0,!0)&&(y=e.tag!==null&&e.tag!=="?"||e.dump&&e.dump.length>1024,y&&(e.dump&&ka===e.dump.charCodeAt(0)?m+="?":m+="? "),m+=e.dump,y&&(m+=Id(e,t)),oi(e,t+1,p,!0,y)&&(e.dump&&ka===e.dump.charCodeAt(0)?m+=":":m+=": ",m+=e.dump,i+=m));e.tag=o,e.dump=i||"{}"}function k0(e,t,n){var r,i,o,s,l,c;for(i=n?e.explicitTypes:e.implicitTypes,o=0,s=i.length;o<s;o+=1)if(l=i[o],(l.instanceOf||l.predicate)&&(!l.instanceOf||typeof t=="object"&&t instanceof l.instanceOf)&&(!l.predicate||l.predicate(t))){if(n?l.multi&&l.representName?e.tag=l.representName(t):e.tag=l.tag:e.tag="?",l.represent){if(c=e.styleMap[l.tag]||l.defaultStyle,s0.call(l.represent)==="[object Function]")r=l.represent(t,c);else if(a0.call(l.represent,c))r=l.represent[c](t,c);else throw new On("!<"+l.tag+'> tag resolver accepts not "'+c+'" style');e.dump=r}return!0}return!1}function oi(e,t,n,r,i,o,s){e.tag=null,e.dump=n,k0(e,n,!1)||k0(e,n,!0);var l=s0.call(e.dump),c=r,d;r&&(r=e.flowLevel<0||e.flowLevel>t);var p=l==="[object Object]"||l==="[object Array]",y,m;if(p&&(y=e.duplicates.indexOf(n),m=y!==-1),(e.tag!==null&&e.tag!=="?"||m||e.indent!==2&&t>0)&&(i=!1),m&&e.usedDuplicates[y])e.dump="*ref_"+y;else{if(p&&m&&!e.usedDuplicates[y]&&(e.usedDuplicates[y]=!0),l==="[object Object]")r&&Object.keys(e.dump).length!==0?(u$(e,t,e.dump,i),m&&(e.dump="&ref_"+y+e.dump)):(l$(e,t,e.dump),m&&(e.dump="&ref_"+y+" "+e.dump));else if(l==="[object Array]")r&&e.dump.length!==0?(e.noArrayIndent&&!s&&t>0?T0(e,t-1,e.dump,i):T0(e,t,e.dump,i),m&&(e.dump="&ref_"+y+e.dump)):(a$(e,t,e.dump),m&&(e.dump="&ref_"+y+" "+e.dump));else if(l==="[object String]")e.tag!=="?"&&i$(e,e.dump,t,o,c);else{if(l==="[object Undefined]")return!1;if(e.skipInvalid)return!1;throw new On("unacceptable kind of an object to dump "+l)}e.tag!==null&&e.tag!=="?"&&(d=encodeURI(e.tag[0]==="!"?e.tag.slice(1):e.tag).replace(/!/g,"%21"),e.tag[0]==="!"?d="!"+d:d.slice(0,18)==="tag:yaml.org,2002:"?d="!!"+d.slice(18):d="!<"+d+">",e.dump=d+" "+e.dump)}return!0}function c$(e,t){var n=[],r=[],i,o;for(Dd(e,n,r),i=0,o=r.length;i<o;i+=1)t.duplicates.push(n[r[i]]);t.usedDuplicates=new Array(o)}function Dd(e,t,n){var r,i,o;if(e!==null&&typeof e=="object")if(i=t.indexOf(e),i!==-1)n.indexOf(i)===-1&&n.push(i);else if(t.push(e),Array.isArray(e))for(i=0,o=e.length;i<o;i+=1)Dd(e[i],t,n);else for(r=Object.keys(e),i=0,o=r.length;i<o;i+=1)Dd(e[r[i]],t,n)}function f$(e,t){t=t||{};var n=new QB(t);n.noRefs||c$(e,n);var r=e;return n.replacer&&(r=n.replacer.call({"":r},"",r)),oi(n,0,r,!0,!0)?n.dump+`
|
||
`:""}var d$=f$,p$={dump:d$};function Rd(e,t){return function(){throw new Error("Function yaml."+e+" is removed in js-yaml 4. Use yaml."+t+" instead, which is now safe by default.")}}var h$=gn,g$=Sy,m$=Oy,v$=Ny,y$=My,b$=xd,C$=o0.load,_$=o0.loadAll,w$=p$.dump,T$=On,k$={binary:jy,float:Ry,map:Ly,null:Iy,pairs:Wy,set:Ky,timestamp:$y,bool:Py,int:Dy,merge:Hy,omap:Uy,seq:Ey,str:Ay},x$=Rd("safeLoad","load"),S$=Rd("safeLoadAll","loadAll"),A$=Rd("safeDump","dump"),E$={Type:h$,Schema:g$,FAILSAFE_SCHEMA:m$,JSON_SCHEMA:v$,CORE_SCHEMA:y$,DEFAULT_SCHEMA:b$,load:C$,loadAll:_$,dump:w$,YAMLException:T$,types:k$,safeLoad:x$,safeLoadAll:S$,safeDump:A$};const L$={name:"Hotkey",components:{IconSvg:Fn},mixins:[Xn],props:{defaultHotkey:{type:Object,default:()=>({})}},data(){return{isOpen:!1,hotkeys:[{name:"click",title:"left_click_keyword_tag",value:"",options:[{name:"",title:"none"},{name:"edit",title:"edit_keyword"},{name:"disable",title:"disable_enable_keyword"},{name:"extend",title:"show_keyword_extend_panel"}]},{name:"rightClick",title:"right_click_keyword_tag",value:"",options:[{name:"",title:"none"},{name:"edit",title:"edit_keyword"},{name:"disable",title:"disable_enable_keyword"},{name:"extend",title:"show_keyword_extend_panel"}]},{name:"dblClick",title:"dblclick_keyword_tag",value:"",options:[{name:"",title:"none"},{name:"edit",title:"edit_keyword"},{name:"disable",title:"disable_enable_keyword"},{name:"extend",title:"show_keyword_extend_panel"}]},{name:"hover",title:"hover_keyword_tag",value:"",options:[{name:"",title:"none"},{name:"extend",title:"show_keyword_extend_panel"}]}]}},emits:["update:hotkey"],computed:{},mounted(){},methods:{open(){this.isOpen=!0,this.hotkeys.forEach(e=>{this.defaultHotkey[e.name]?e.value=this.defaultHotkey[e.name]:e.value=""})},close(){this.isOpen=!1},onCloseClick(){this.close()},onSaveClick(){let e={};this.hotkeys.forEach(t=>{e[t.name]=t.value}),this.gradioAPI.setData("hotkey",e),this.close(),this.$emit("update:hotkey",e)}}},O$={class:"hotkey-list"},I$={class:"hotkey-title"},P$=["onUpdate:modelValue"],D$=["value"],R$={class:"setting-btns"};function N$(e,t,n,r,i,o){return E(),Ue(un,{name:"fadeDown"},{default:tn(()=>[i.isOpen?(E(),M("div",{key:0,class:"physton-prompt-hotkey",onClick:t[4]||(t[4]=()=>{})},[T("div",{class:"hotkey-main",onClick:t[3]||(t[3]=nt(()=>{},["stop"]))},[T("div",{class:"hotkey-body",onClick:t[2]||(t[2]=nt(()=>{},["stop"]))},[T("div",O$,[(E(!0),M(De,null,ot(i.hotkeys,s=>(E(),M("div",{class:"hotkey-item",key:s.name},[T("div",I$,ie(e.getLang(s.title)),1),ge(T("select",{class:"hotkey-select","onUpdate:modelValue":l=>s.value=l},[(E(!0),M(De,null,ot(s.options,l=>(E(),M("option",{key:l.name,value:l.name},ie(e.getLang(l.title)),9,D$))),128))],8,P$),[[Eo,s.value]])]))),128))]),T("div",R$,[T("div",{class:"hotkey-save hover-scale-120",onClick:t[0]||(t[0]=(...s)=>o.onSaveClick&&o.onSaveClick(...s))},ie(e.getLang("save")),1),T("div",{class:"hotkey-close hover-scale-120",onClick:t[1]||(t[1]=(...s)=>o.onCloseClick&&o.onCloseClick(...s))},ie(e.getLang("close")),1)])])])])):ke("",!0)]),_:1})}const M$=hn(L$,[["render",N$]]),F$="lora",B$="lyco",$$="embedding",H$={name:"ExtraNetworksPopup",components:{IconSvg:Fn},mixins:[Xn],props:{extraNetworks:{type:Array,default:()=>[]}},data(){return{isShow:!1,e:null,name:"",useCallback:null,type:"",data:{},style:{},previewStyle:{},mouseIn:!1,eMouseIn:!1}},computed:{},mounted(){},methods:{show(e,t,n){this.mouseIn=!1,this.eMouseIn=!0,this.e=e,this.name=t,this.useCallback=n,this.type="",this.data={},this.style={},this.previewStyle={};let r;t=t.toLowerCase();for(let i of this.extraNetworks)if(i.name==="textual inversion"){for(let o of i.items)if(o.name.toLowerCase()===t){this.type=$$,r=o;break}}else if(i.name==="lora"||i.name==="lycoris"){for(let o of i.items)if(o.name.toLowerCase()===t||o.output_name&&o.output_name.toLowerCase()===t){this.type=i.name==="lora"?F$:B$,r=o;break}}if(!this.type)return this.isShow=!1;this.isShow=!0,this.data.name=r.civitai_info&&r.civitai_info.model&&r.civitai_info.model.name?r.civitai_info.model.name:r.name,this.data.output_name=r.output_name&&r.output_name!==this.data.name?r.output_name:"",this.data.basename=r.basename||"",this.data.dirname=r.dirname||"",this.data.description=r.civitai_info&&r.civitai_info.description?r.civitai_info.description:r.description||"",this.data.description=this.data.description.replace(/<[^>]+>/g,""),this.data.trainedWords=r.civitai_info&&r.civitai_info.trainedWords?r.civitai_info.trainedWords:[],this.data.preview=r.preview||(r.civitai_info&&r.civitai_info.images&&r.civitai_info.images.length?r.civitai_info.images[0]:""),this.data.modelId=r.civitai_info&&r.civitai_info.modelId?r.civitai_info.modelId:"",this.$nextTick(()=>{const i=e.getBoundingClientRect();this.style.top=i.top+e.offsetHeight+4+"px",this.style.left=i.left+"px",this.data.preview&&(this.previewStyle={width:"auto",height:this.$refs.extraNetworks.offsetHeight+"px"}),this.$nextTick(()=>{this.onPreviewLoad()})})},onPreviewLoad(){const e=this.$refs.extraNetworks.getBoundingClientRect();e.right>window.innerWidth&&(this.style.left=window.innerWidth-e.width-10+"px")},_hide(){this.isShow&&(this.hideTimer&&clearTimeout(this.hideTimer),this.hideTimer=setTimeout(()=>{this.hideTimer=null,!this.mouseIn&&!this.eMouseIn&&(this.isShow=!1)},10))},hide(){this.eMouseIn=!1,this._hide()},onMouseEnter(){this.mouseIn=!0},onMouseMove(){this.mouseIn=!0},onMouseLeave(){this.mouseIn=!1,this._hide()},copy(e){this.$copyText(e).then(()=>{this.$toastr.success(this.getLang("success"))}).catch(()=>{this.$toastr.error(this.getLang("failed"))})},onOpenCivitaiClick(){if(!this.data.modelId)return;let e=Ys.civitaiUrl+"/models/"+this.data.modelId;window.open(e)},onUseKeywordsClick(){!this.data.trainedWords||!this.data.trainedWords.length||this.useCallback&&typeof this.useCallback=="function"&&(this.useCallback(this.data.trainedWords),this.$toastr.success(this.getLang("success")))}}},j$={class:"popup-main"},U$=["src"],W$={class:"info-raws"},K$={class:"info-raw"},V$={class:"raw-name"},q$={key:0,class:"info-raw"},z$={class:"raw-name"},G$={key:1,class:"info-raw"},Y$={class:"raw-name"},X$={key:2,class:"info-raw"},J$={class:"raw-name"},Z$={key:3,class:"info-raw"},Q$={class:"raw-name"},eH={key:4,class:"info-raw"},tH={class:"raw-name"},nH={class:"info-btns"};function rH(e,t,n,r,i,o){const s=To("tooltip");return ge((E(),M("div",{class:"physton-prompt-extra-networks-popup",ref:"extraNetworks",onMouseenter:t[9]||(t[9]=nt((...l)=>o.onMouseEnter&&o.onMouseEnter(...l),["stop"])),onMousemove:t[10]||(t[10]=nt((...l)=>o.onMouseMove&&o.onMouseMove(...l),["stop"])),onMouseleave:t[11]||(t[11]=nt((...l)=>o.onMouseLeave&&o.onMouseLeave(...l),["stop"])),style:St(i.style)},[T("div",j$,[i.data.preview?(E(),M("img",{key:0,class:"info-preview",src:i.data.preview,style:St(i.previewStyle),onLoad:t[0]||(t[0]=(...l)=>o.onPreviewLoad&&o.onPreviewLoad(...l))},null,44,U$)):ke("",!0),T("div",W$,[T("div",K$,[T("div",V$,ie(e.getLang("model_name")),1),T("div",{class:"raw-value",onClick:t[1]||(t[1]=l=>o.copy(i.data.name))},ie(i.data.name),1)]),i.data.output_name?(E(),M("div",q$,[T("div",z$,ie(e.getLang("output_name")),1),T("div",{class:"raw-value",onClick:t[2]||(t[2]=l=>o.copy(i.data.output_name))},ie(i.data.output_name),1)])):ke("",!0),i.data.basename?(E(),M("div",G$,[T("div",Y$,ie(e.getLang("filename")),1),T("div",{class:"raw-value",onClick:t[3]||(t[3]=l=>o.copy(i.data.basename))},ie(i.data.basename),1)])):ke("",!0),i.data.dirname?(E(),M("div",X$,[T("div",J$,ie(e.getLang("filepath")),1),T("div",{class:"raw-value",onClick:t[4]||(t[4]=l=>o.copy(i.data.dirname))},ie(i.data.dirname),1)])):ke("",!0),i.data.trainedWords&&i.data.trainedWords.length?(E(),M("div",Z$,[T("div",Q$,ie(e.getLang("trained_words")),1),T("div",{class:"raw-value",onClick:t[5]||(t[5]=l=>o.copy(i.data.trainedWords.join(", ")))},ie(i.data.trainedWords.join(", ")),1)])):ke("",!0),i.data.description?(E(),M("div",eH,[T("div",tH,ie(e.getLang("description")),1),ge((E(),M("div",{class:"raw-value description",onClick:t[6]||(t[6]=l=>o.copy(i.data.description))},[jt(ie(i.data.description),1)])),[[s,i.data.description]])])):ke("",!0),T("div",nH,[i.data.modelId?(E(),M("div",{key:0,class:"info-btn hover-scale-120",onClick:t[7]||(t[7]=(...l)=>o.onOpenCivitaiClick&&o.onOpenCivitaiClick(...l))},ie(e.getLang("open_civitai")),1)):ke("",!0),i.data.trainedWords&&i.data.trainedWords.length?(E(),M("div",{key:1,class:"info-btn hover-scale-120",onClick:t[8]||(t[8]=(...l)=>o.onUseKeywordsClick&&o.onUseKeywordsClick(...l))},ie(e.getLang("use_keywords")),1)):ke("",!0)])])])],36)),[[Ot,i.isShow]])}const iH={name:"App",components:{Hotkey:M$,About:lF,ChatgptPrompt:KM,PackagesState:eM,PromptFormat:pN,Blacklist:WN,ExtensionCss:YR,IconSvg:Fn,History:HR,Favorite:uR,SelectLanguage:DD,TranslateSetting:LD,PhystonPrompt:vP,ExtraNetworksPopup:hn(H$,[["render",rH]])},mixins:[],data(){return{prompts:[{tab:"tab_txt2img",prompt:"txt2img_prompt",counter:"txt2img_token_counter",button:"txt2img_token_button",steps:"txt2img_steps",historyKey:"txt2img",favoriteKey:"txt2img",$prompt:null,$textarea:null,$steps:null,name:"txt2img_prompt",neg:!1,hideDefaultInputKey:"txt2ImgHideDefaultInput",hideDefaultInput:!1,hidePanelKey:"txt2ImgHidePanel",hidePanel:!1,hideGroupTagsKey:"txt2ImgHideGroupTags",hideGroupTags:!1,id:"phystonPrompt_txt2img_prompt"},{tab:"tab_txt2img",prompt:"txt2img_neg_prompt",counter:"txt2img_negative_token_counter",button:"txt2img_negative_token_button",steps:"txt2img_steps",historyKey:"txt2img_neg",favoriteKey:"txt2img_neg",$prompt:null,$textarea:null,$steps:null,name:"txt2img_neg_prompt",neg:!0,hideDefaultInputKey:"txt2ImgNegHideDefaultInput",hideDefaultInput:!1,hidePanelKey:"txt2ImgNegHidePanel",hidePanel:!1,hideGroupTagsKey:"txt2ImgNegHideGroupTags",hideGroupTags:!1,id:"phystonPrompt_txt2img_neg_prompt"},{tab:"tab_img2img",prompt:"img2img_prompt",counter:"img2img_token_counter",button:"img2img_token_button",steps:"img2img_steps",historyKey:"img2img",favoriteKey:"img2img",$prompt:null,$textarea:null,$steps:null,name:"img2img_prompt",neg:!1,hideDefaultInputKey:"img2ImgHideDefaultInput",hideDefaultInput:!1,hidePanelKey:"img2ImgHidePanel",hidePanel:!1,hideGroupTagsKey:"img2ImgHideGroupTags",hideGroupTags:!1,id:"phystonPrompt_img2img_prompt"},{tab:"tab_img2img",prompt:"img2img_neg_prompt",counter:"img2img_negative_token_counter",button:"img2img_negative_token_button",steps:"img2img_steps",historyKey:"img2img_neg",favoriteKey:"img2img_neg",$prompt:null,$textarea:null,$steps:null,name:"img2img_neg_prompt",neg:!0,hideDefaultInputKey:"img2ImgNegHideDefaultInput",hideDefaultInput:!1,hidePanelKey:"img2ImgNegHidePanel",hidePanel:!1,hideGroupTagsKey:"img2ImgNegHideGroupTags",hideGroupTags:!1,id:"phystonPrompt_img2img_neg_prompt"}],languageCode:"",languages:{},translateApis:[],translateApi:"",translateApiConfig:{},canOneTranslate:!1,autoTranslate:!1,autoTranslateToEnglish:!1,autoTranslateToLocal:!1,autoRemoveSpace:!0,autoRemoveLastComma:!1,autoKeepWeightZero:!1,autoKeepWeightOne:!1,autoBreakBeforeWrap:!1,autoBreakAfterWrap:!1,enableTooltip:!0,tagCompleteFile:"",onlyCsvOnAuto:!1,startWatchSave:!1,pasteBtn:null,showPastePopup:!1,pasteTitle:"",pasteContent:"",pasteLoading:!1,historyCurrentPrompt:"",favoriteCurrentPrompt:"",chatgptCurrentPrompt:"",extraNetworks:[],loras:[],lycos:[],embeddings:[],python:"",packagesState:[],version:"",latestVersion:"",isLatestVersion:!0,theme:"dark",groupTags:[],groupTagsColor:{},groupTagsColorKeyCache:{},groupTagsTranslate:!0,groupTagsTranslateCache:{toEn:new Map,toLocal:new Map},blacklist:{},cancelBlacklistConfirm:!1,hotkey:{click:"edit",dblClick:"disable",rightClick:"",hover:"extend"}}},watch:{languageCode:{handler:function(e,t){this.startWatchSave&&(console.log("onLanguageCodeChange",e),this.canOneTranslate=he.canOneTranslate(this.languageCode),this.gradioAPI.setData("languageCode",e).then(n=>{}).catch(n=>{}),this.loadGroupTags())},immediate:!1},autoTranslateToEnglish:{handler:function(e,t){this.startWatchSave&&(console.log("onAutoTranslateToEnglishChange",e),this.gradioAPI.setData("autoTranslateToEnglish",e).then(n=>{}).catch(n=>{}))},immediate:!1},autoTranslateToLocal:{handler:function(e,t){this.startWatchSave&&(console.log("onAutoTranslateToLocalChange",e),this.gradioAPI.setData("autoTranslateToLocal",e).then(n=>{}).catch(n=>{}))},immediate:!1},autoTranslate:{handler:function(e,t){this.startWatchSave&&(this.autoTranslateToEnglish=this.autoTranslate,this.autoTranslateToLocal=this.autoTranslate,console.log("onAutoTranslateChange",e),this.gradioAPI.setData("autoTranslate",e).then(n=>{}).catch(n=>{}))},immediate:!1},autoRemoveSpace:{handler:function(e,t){this.startWatchSave&&(console.log("onAutoRemoveSpaceChange",e),this.gradioAPI.setData("autoRemoveSpace",e).then(n=>{this.prompts.forEach(r=>{this.$refs[r.id][0].updatePrompt()})}).catch(n=>{}))},immediate:!1},autoRemoveLastComma:{handler:function(e,t){this.startWatchSave&&(console.log("onAutoRemoveLastCommaChange",e),this.gradioAPI.setData("autoRemoveLastComma",e).then(n=>{this.prompts.forEach(r=>{this.$refs[r.id][0].updatePrompt()})}).catch(n=>{}))},immediate:!1},autoKeepWeightZero:{handler:function(e,t){this.startWatchSave&&(console.log("onAutoKeepWeightZeroChange",e),this.gradioAPI.setData("autoKeepWeightZero",e).then(n=>{}).catch(n=>{}))},immediate:!1},autoKeepWeightOne:{handler:function(e,t){this.startWatchSave&&(console.log("onAutoKeepWeightOneChange",e),this.gradioAPI.setData("autoKeepWeightOne",e).then(n=>{}).catch(n=>{}))},immediate:!1},autoBreakBeforeWrap:{handler:function(e,t){this.startWatchSave&&(console.log("onAutoBreakBeforeWrap",e),this.gradioAPI.setData("autoBreakBeforeWrap",e).then(n=>{this.prompts.forEach(r=>{this.$refs[r.id][0].updatePrompt()})}).catch(n=>{}))},immediate:!1},autoBreakAfterWrap:{handler:function(e,t){this.startWatchSave&&(console.log("onAutoBreakAfterWrap",e),this.gradioAPI.setData("autoBreakAfterWrap",e).then(n=>{this.prompts.forEach(r=>{this.$refs[r.id][0].updatePrompt()})}).catch(n=>{}))},immediate:!1},enableTooltip:{handler:function(e,t){this.startWatchSave&&(localStorage.setItem("phystonPromptEnableTooltip",e?"true":"false"),this.updateTippyState(),this.gradioAPI.setData("enableTooltip",e).then(n=>{}).catch(n=>{}))},immediate:!1},translateApi:{handler:function(e,t){this.startWatchSave&&(console.log("onTranslateApiChange",e,t),this.updateTranslateApiConfig(),this.gradioAPI.setData("translateApi",e).then(n=>{}).catch(n=>{}))},immediate:!1},tagCompleteFile:{handler:function(e,t){this.startWatchSave&&(console.log("onTagCompleteFileChange",e,t),this.gradioAPI.setData("tagCompleteFile",e).then(n=>{}).catch(n=>{}))},immediate:!1},groupTagsColor:{handler:function(e,t){this.startWatchSave&&(console.log("onGroupTagsColorChange",e,t),this.gradioAPI.setData("groupTagsColor",e).then(n=>{}).catch(n=>{}))},deep:!0,immediate:!1},groupTagsTranslate:{handler:function(e,t){this.startWatchSave&&(console.log("onGroupTagsTranslateChange",e,t),this.gradioAPI.setData("groupTagsTranslate",e).then(n=>{}).catch(n=>{}))},immediate:!1},onlyCsvOnAuto(){this.startWatchSave&&(console.log("onOnlyCsvOnAutoChange",this.onlyCsvOnAuto),this.gradioAPI.setData("onlyCsvOnAuto",this.onlyCsvOnAuto).then(e=>{}).catch(e=>{}))}},mounted(){he.loadCSS("toastr.min.css","physton-prompt-toastr",!0,!0,!1),he.loadCSS("tippy.css","physton-prompt-tippy",!0,!0,!1),he.loadCSS("vue3-colorpicker.css","physton-prompt-vue3-colorpicker",!0,!0,!1),he.loadCSS("animate.min.css","physton-prompt-animate",!0,!0,!1),he.loadCSS("main.min.css","physton-prompt-main",!0);let t=new URLSearchParams(window.location.search).get("__theme");["dark","light"].includes(t)&&(this.theme=t,he.gradioApp().classList.contains(this.theme)||he.gradioApp().classList.add(this.theme)),setTimeout(()=>{var i,o,s;let n=!1,r=!1;if(localStorage.getItem("SD-LOBE-SETTING")||localStorage.getItem("SD-KITCHEN-SETTING")||(s=(o=(i=document.querySelector('head > meta[name="application-name"]'))==null?void 0:i.content)==null?void 0:o.includes)!=null&&s.call(o,"Lobe")){let l=document.getElementsByTagName("link");for(let c=0;c<l.length;c++){let d=l[c];if(d.href.includes("lobehub/")){n=!0;break}else d.href.includes("kitchen-theme")&&(r=!0)}}n?he.gradioApp().classList.add("physton-prompt-lobehub"):r&&he.gradioApp().classList.add("physton-prompt-kitchen")},3e3),this.gradioAPI.getConfig().then(n=>{console.log("config:",n),this.languageCode=n.i18n.default,this.translateApi=n.translate_apis.default,this.translateApis=n.translate_apis.apis,this.python=n.python,this.packagesState=n.packages_state;let r={};n.i18n.languages.forEach(i=>{r[i.code]=i}),this.languages=r,this.init()}).catch(n=>{this.$toastr.error("Connection to backend API service failed. Please manually refresh the webpage. If it still doesn't work, please restart the WebUI.<br/>连接到后台接口服务失败,请手动再刷新一次网页。如果还是不行,请重启WebUI。<br/><br/>"+n.message,Ys.shortName,{timeOut:2e4}),console.log(n)})},methods:{getLang(e){return he.getLang(e,this.languageCode,this.languages)},init(){this.loadExtraNetworks();let e=["languageCode","autoTranslate","autoTranslateToEnglish","autoTranslateToLocal","autoRemoveSpace","autoRemoveLastComma","autoKeepWeightZero","autoKeepWeightOne","autoBreakBeforeWrap","autoBreakAfterWrap","translateApi","enableTooltip","tagCompleteFile","onlyCsvOnAuto","extensionSelect.minimalist","groupTagsColor","groupTagsTranslate","blacklist","cancelBlacklistConfirm","hotkey"];this.prompts.forEach(t=>{e.push(t.hideDefaultInputKey),e.push(t.hidePanelKey),e.push(t.hideGroupTagsKey)}),this.gradioAPI.getDatas(e).then(t=>{if(t.languageCode!==null){let n=!1;for(let r in this.languages)if(this.languages[r].code===t.languageCode){n=!0;break}n&&(this.languageCode=t.languageCode,this.$forceUpdate(),this.gradioAPI.setData("languageCode",this.languageCode))}else{let n=navigator.language||navigator.userLanguage||"";if(n){for(let r in this.languages)if(he.isSameLang(this.languages[r].code,n)){this.languageCode=this.languages[r].code,this.$forceUpdate(),this.gradioAPI.setData("languageCode",this.languageCode);break}}}if(this.canOneTranslate=he.canOneTranslate(this.languageCode),t.autoTranslateToEnglish!==null&&(this.autoTranslateToEnglish=t.autoTranslateToEnglish),t.autoTranslateToLocal!==null&&(this.autoTranslateToLocal=t.autoTranslateToLocal),t.autoTranslate!==null?this.canOneTranslate?(this.autoTranslate=t.autoTranslate,this.autoTranslateToEnglish=this.autoTranslate,this.autoTranslateToLocal=this.autoTranslate):this.autoTranslate=!1:this.canOneTranslate?(this.autoTranslate=this.autoTranslateToEnglish||this.autoTranslateToLocal,this.autoTranslateToEnglish=!0,this.autoTranslateToLocal=!0):this.autoTranslate=!1,t.autoRemoveSpace!==null&&(this.autoRemoveSpace=t.autoRemoveSpace),t.autoRemoveLastComma!==null&&(this.autoRemoveLastComma=t.autoRemoveLastComma),t.autoKeepWeightZero!==null&&(this.autoKeepWeightZero=t.autoKeepWeightZero),t.autoKeepWeightOne!==null&&(this.autoKeepWeightOne=t.autoKeepWeightOne),t.autoBreakBeforeWrap!==null&&(this.autoBreakBeforeWrap=t.autoBreakBeforeWrap),t.autoBreakAfterWrap!==null&&(this.autoBreakAfterWrap=t.autoBreakAfterWrap),t.enableTooltip!==null&&(this.enableTooltip=t.enableTooltip),localStorage.setItem("phystonPromptEnableTooltip",this.enableTooltip?"true":"false"),this.updateTippyState(),t.translateApi!==null&&(this.translateApi=t.translateApi),t.tagCompleteFile!==null&&(this.tagCompleteFile=t.tagCompleteFile,this.$nextTick(()=>{this.$refs.translateSetting.getCSV(this.tagCompleteFile)})),t.onlyCsvOnAuto!==null&&(this.onlyCsvOnAuto=t.onlyCsvOnAuto),t["extensionSelect.minimalist"]===null&&this.gradioAPI.setData("extensionSelect.minimalist",!0),t.groupTagsColor!==null&&typeof t.groupTagsColor=="object"){this.groupTagsColor={};for(let n in t.groupTagsColor){let r=t.groupTagsColor[n];this.groupTagsColor[n]=Lt(he.fitterInputColor(r))}}t.groupTagsTranslate!==null&&(this.groupTagsTranslate=t.groupTagsTranslate),t.blacklist!==null&&(this.blacklist=this._handleBlacklist(t.blacklist)),t.cancelBlacklistConfirm!==null&&(this.cancelBlacklistConfirm=t.cancelBlacklistConfirm),t.hotkey!==null&&(this.hotkey=t.hotkey),this.updateTranslateApiConfig(),this.$refs.extensionCss.init(),this.prompts.forEach(n=>{t[n.hideDefaultInputKey]!==null&&(n.hideDefaultInput=t[n.hideDefaultInputKey]),t[n.hidePanelKey]!==null&&(n.hidePanel=t[n.hidePanelKey]),t[n.hideGroupTagsKey]!==null&&(n.hideGroupTags=t[n.hideGroupTagsKey]),n.$prompt=he.gradioApp().querySelector("#"+n.prompt),n.$textarea=n.$prompt.getElementsByTagName("textarea")[0],n.$steps=he.gradioApp().querySelector("#"+n.steps)}),this.$nextTick(()=>{this.prompts.forEach(n=>{const r=he.gradioApp().querySelector("#"+n.id);n.$prompt.parentElement.parentElement.parentElement.appendChild(r),n.$prompt.parentElement.parentElement.style.display=n.hideDefaultInput?"none":"flex"}),this.startWatchSave=!0}),this.handlePaste(),this.loadGroupTags()})},loadGroupTags(){this.gradioAPI.getGroupTags(this.languageCode).then(e=>{if(!e||e==="")this.groupTags=[];else try{this.groupTags=E$.load(e),Array.isArray(this.groupTags)||(this.groupTags=[])}catch(t){console.log(t),this.groupTags=[]}this._handleGroupTags()})},_handleGroupTags(){let e={toEn:new Map,toLocal:new Map},t=(n,r)=>{[n,n.replace(/\_/g," "),n.replace(/\-/g," ")].forEach(o=>{if(e.toLocal.has(o)){let s=e.toLocal.get(o);s.includes(r)||s.push(r)}else e.toLocal.set(o,[r])}),e.toEn.set(r,n)};this.groupTags.forEach((n,r)=>{n.tabKey="groupTags-"+r,n.groups.forEach((i,o)=>{if(i.tabKey="subGroupTags-"+r+"-"+o,i.type&&i.type=="wrap")return;let s=he.getTagsColorKey(n.name,i.name);this.groupTagsColor[s]||(this.groupTagsColor[s]=Lt(he.fitterInputColor(i.color)));for(let l in i.tags){if(!l)continue;this.groupTagsColorKeyCache[l]=s;let c=i.tags[l];!c||l==c||t(l,c)}})}),this.groupTagsTranslateCache=e},updateTippyState(){for(const e of this.$tippyList)this.enableTooltip?e.enable():e.disable()},updateTranslateApiConfig(){this.gradioAPI.getData("translate_api."+this.translateApi).then(e=>{let t={};const n=he.getTranslateApiItem(this.translateApis,this.translateApi);if(n.config){for(const r of n.config)n.type==="translators"&&r.key==="region"&&!e.region?t[r.key]=this.languageCode==="zh_CN"||this.languageCode==="zh_HK"||this.languageCode==="zh_TW"?"China":"EN":e?t[r.key]=e[r.key]:t[r.key]=r.default||"";t.concurrent=n.concurrent||0}this.translateApiConfig=t})},onPromptFormatClick(e){this.$refs.promptFormat.open(e)},onBlacklistClick(e){this.$refs.blacklist.open(e)},onHotkeyClick(e){this.$refs.hotkey.open(e)},onSelectLanguageClick(e){this.$refs.selectLanguage.open(e)},onTranslateApiClick(){this.$refs.translateSetting.open(this.translateApi)},onSelectThemeClick(){this.$refs.extensionCss.open()},handlePaste(){if(typeof gradioApp!="function")return;const e=gradioApp().querySelectorAll("#paste");!e||e.length<=0||e.forEach((t,n)=>{const r=t.cloneNode(!0);r.id="paste-new-"+n,r.innerHTML="🗒",t.parentNode.insertBefore(r,t.nextSibling),r.addEventListener("click",()=>{this.pasteBtn=t,this.openPastePopup()}),this.pasteTitle=t.title})},openPastePopup(){this.pasteContent="",this.pasteLoading=!1,this.showPastePopup=!0},closePastePopup(){this.showPastePopup=!1},onClickPasteSubmit(){this.pasteLoading=!0;const e=get_uiCurrentTabContent();let t=null,n=null,r=null,i=null,o=[];for(const s of this.prompts)s.tab==e.id&&(console.log(s),o.push(s.id),s.neg?(n=s.$textarea,i=s.$prompt):(t=s.$textarea,r=s.$prompt));if(!t||!r||!i){this.pasteLoading=!1;return}t.value=this.pasteContent,t.dispatchEvent(new Event("input")),this.pasteBtn.dispatchEvent(new Event("click")),setTimeout(()=>{let s=0,l=0;s=setInterval(()=>{if(l++,l>100){this.pasteLoading=!1,clearInterval(s);return}r.getElementsByClassName("hide").length>0&&i.getElementsByClassName("hide").length>0&&(this.pasteLoading=!1,this.closePastePopup(),clearInterval(s),he.hideCompleteResults(t),he.hideCompleteResults(n),o.forEach((c,d)=>{setTimeout(()=>{this.$refs[c][0].onTextareaChange(!0)},1e3)}))},100)},1e3)},onUpdateHideDefaultInput(e,t){const n=this.prompts.find(r=>r.id==e);n&&(n.hideDefaultInput=t,this.gradioAPI.setData(n.hideDefaultInputKey,n.hideDefaultInput),n.$prompt.parentElement.parentElement.style.display=n.hideDefaultInput?"none":"flex")},onUpdateHidePanel(e,t){const n=this.prompts.find(r=>r.id==e);n&&(n.hidePanel=t,this.gradioAPI.setData(n.hidePanelKey,n.hidePanel))},onUpdateHideGroupTags(e,t){const n=this.prompts.find(r=>r.id==e);n&&(n.hideGroupTags=t,this.gradioAPI.setData(n.hideGroupTagsKey,n.hideGroupTags))},onShowHistory(e,t){this.$refs.favorite.hide(),this.historyCurrentPrompt=e;const n=this.prompts.find(r=>r.id==e);n&&this.$refs.history.show(n.historyKey,t)},onUseHistory(e){if(!this.historyCurrentPrompt)return;const t=this.prompts.find(n=>n.id==this.historyCurrentPrompt);t&&this.$refs[t.id][0].useFavorite(e)},onShowFavorite(e,t){this.$refs.history.hide(),this.favoriteCurrentPrompt=e;const n=this.prompts.find(r=>r.id==e);n&&this.$refs.favorite.show(n.favoriteKey,t)},onUseFavorite(e){if(!this.favoriteCurrentPrompt)return;const t=this.prompts.find(n=>n.id==this.favoriteCurrentPrompt);t&&this.$refs[t.id][0].useFavorite(e)},onRefreshFavorites(e){this.$refs.favorite.getFavorites(e)},onShowChatgpt(e,t){this.chatgptCurrentPrompt=e,this.prompts.find(r=>r.id==e)&&this.$refs.chatgptPrompt.open()},onUseChatgpt(e){if(!this.chatgptCurrentPrompt)return;const t=this.prompts.find(n=>n.id==this.chatgptCurrentPrompt);t&&this.$refs[t.id][0].useChatgpt(e)},onShowAbout(){this.$refs.about.open()},onSwitchTheme(){this.theme=this.theme==="dark"?"light":"dark";let e=window.location.href,t=new URL(e),n=new URLSearchParams(t.search);n.has("__theme")?n.set("__theme",this.theme):n.append("__theme",this.theme);let r=t.origin+t.pathname+"?"+n.toString();window.location.href=r},_handleBlacklist(e){var t,n,r,i,o,s;return e={...e},e.prompt=(t=e.prompt)==null?void 0:t.slice().map(l=>l.toLowerCase()),e.negative_prompt=(n=e.negative_prompt)==null?void 0:n.slice().map(l=>l.toLowerCase()),e.lora=(r=e.lora)==null?void 0:r.slice().map(l=>l.toLowerCase()),e.lycoris=(i=e.lycoris)==null?void 0:i.slice().map(l=>l.toLowerCase()),e.embedding=(o=e.embedding)==null?void 0:o.slice().map(l=>l.toLowerCase()),e.translate=(s=e.translate)==null?void 0:s.slice().map(l=>l.toLowerCase()),e},onUpdateBlacklist(e,t){this.blacklist=this._handleBlacklist(e),typeof t=="boolean"&&(this.cancelBlacklistConfirm=t)},onUpdateHotkey(e){this.hotkey=e},onShowExtraNetworks(e,t,n){this.$refs.extraNetworksPopup.show(e,t,n)},onHideExtraNetworks(){this.$refs.extraNetworksPopup.hide()}}},oH={class:"paste-popup-title"},sH={class:"paste-popup-body"},aH=["placeholder"],lH={key:1,class:"paste-submit"};function uH(e,t,n,r,i,o){const s=Ye("physton-prompt"),l=Ye("translate-setting"),c=Ye("select-language"),d=Ye("prompt-format"),p=Ye("blacklist"),y=Ye("hotkey"),m=Ye("history"),C=Ye("favorite"),b=Ye("extension-css"),k=Ye("packages-state"),L=Ye("chatgpt-prompt"),O=Ye("about"),$=Ye("extra-networks-popup"),X=Ye("icon-svg");return E(),M("div",null,[(E(!0),M(De,null,ot(i.prompts,x=>(E(),M(De,{key:x.name},[x.$textarea?(E(),Ue(s,{key:0,id:x.id,ref_for:!0,ref:x.id,name:x.name,neg:x.neg,textarea:x.$textarea,steps:x.$steps,"language-code":i.languageCode,"onUpdate:languageCode":t[0]||(t[0]=z=>i.languageCode=z),"translate-apis":i.translateApis,languages:i.languages,"history-key":x.historyKey,"onClick:showHistory":z=>o.onShowHistory(x.id,z),"favorite-key":x.favoriteKey,onRefreshFavorites:o.onRefreshFavorites,"onClick:showFavorite":z=>o.onShowFavorite(x.id,z),"can-one-translate":i.canOneTranslate,"onUpdate:canOneTranslate":t[1]||(t[1]=z=>i.canOneTranslate=z),"auto-translate":i.autoTranslate,"onUpdate:autoTranslate":t[2]||(t[2]=z=>i.autoTranslate=z),"auto-translate-to-english":i.autoTranslateToEnglish,"onUpdate:autoTranslateToEnglish":t[3]||(t[3]=z=>i.autoTranslateToEnglish=z),"auto-translate-to-local":i.autoTranslateToLocal,"onUpdate:autoTranslateToLocal":t[4]||(t[4]=z=>i.autoTranslateToLocal=z),"auto-remove-space":i.autoRemoveSpace,"onUpdate:autoRemoveSpace":t[5]||(t[5]=z=>i.autoRemoveSpace=z),"auto-remove-last-comma":i.autoRemoveLastComma,"onUpdate:autoRemoveLastComma":t[6]||(t[6]=z=>i.autoRemoveLastComma=z),"auto-keep-weight-zero":i.autoKeepWeightZero,"onUpdate:autoKeepWeightZero":t[7]||(t[7]=z=>i.autoKeepWeightZero=z),"auto-keep-weight-one":i.autoKeepWeightOne,"onUpdate:autoKeepWeightOne":t[8]||(t[8]=z=>i.autoKeepWeightOne=z),"auto-break-before-wrap":i.autoBreakBeforeWrap,"onUpdate:autoBreakBeforeWrap":t[9]||(t[9]=z=>i.autoBreakBeforeWrap=z),"auto-break-after-wrap":i.autoBreakAfterWrap,"onUpdate:autoBreakAfterWrap":t[10]||(t[10]=z=>i.autoBreakAfterWrap=z),"hide-default-input":x.hideDefaultInput,"onUpdate:hideDefaultInput":z=>o.onUpdateHideDefaultInput(x.id,z),"hide-panel":x.hidePanel,"onUpdate:hidePanel":z=>o.onUpdateHidePanel(x.id,z),"enable-tooltip":i.enableTooltip,"onUpdate:enableTooltip":t[11]||(t[11]=z=>i.enableTooltip=z),"translate-api":i.translateApi,"onUpdate:translateApi":t[12]||(t[12]=z=>i.translateApi=z),"translate-api-config":i.translateApiConfig,"onClick:translateApi":o.onTranslateApiClick,"onClick:promptFormat":o.onPromptFormatClick,"onClick:blacklist":o.onBlacklistClick,"onClick:hotkey":o.onHotkeyClick,"tag-complete-file":i.tagCompleteFile,"onUpdate:tagCompleteFile":t[13]||(t[13]=z=>i.tagCompleteFile=z),"only-csv-on-auto":i.onlyCsvOnAuto,"onUpdate:onlyCsvOnAuto":t[14]||(t[14]=z=>i.onlyCsvOnAuto=z),"group-tags-translate":i.groupTagsTranslate,"onUpdate:groupTagsTranslate":t[15]||(t[15]=z=>i.groupTagsTranslate=z),"onClick:selectLanguage":o.onSelectLanguageClick,"onClick:selectTheme":o.onSelectThemeClick,"onClick:showChatgpt":z=>o.onShowChatgpt(x.id,z),"extra-networks":i.extraNetworks,loras:i.loras,lycos:i.lycos,embeddings:i.embeddings,version:i.version,"latest-version":i.latestVersion,"is-latest-version":i.isLatestVersion,"onClick:showAbout":o.onShowAbout,theme:i.theme,"onClick:switchTheme":o.onSwitchTheme,"group-tags":i.groupTags,"hide-group-tags":x.hideGroupTags,"group-tags-color":i.groupTagsColor,"onUpdate:groupTagsColor":t[16]||(t[16]=z=>i.groupTagsColor=z),"group-tags-color-key-cache":i.groupTagsColorKeyCache,"onUpdate:hideGroupTags":z=>o.onUpdateHideGroupTags(x.id,z),"group-tags-translate-cache":i.groupTagsTranslateCache,blacklist:i.blacklist,"cancel-blacklist-confirm":i.cancelBlacklistConfirm,"onUpdate:blacklist":o.onUpdateBlacklist,hotkey:i.hotkey,onShowExtraNetworks:o.onShowExtraNetworks,onHideExtraNetworks:o.onHideExtraNetworks},null,8,["id","name","neg","textarea","steps","language-code","translate-apis","languages","history-key","onClick:showHistory","favorite-key","onRefreshFavorites","onClick:showFavorite","can-one-translate","auto-translate","auto-translate-to-english","auto-translate-to-local","auto-remove-space","auto-remove-last-comma","auto-keep-weight-zero","auto-keep-weight-one","auto-break-before-wrap","auto-break-after-wrap","hide-default-input","onUpdate:hideDefaultInput","hide-panel","onUpdate:hidePanel","enable-tooltip","translate-api","translate-api-config","onClick:translateApi","onClick:promptFormat","onClick:blacklist","onClick:hotkey","tag-complete-file","only-csv-on-auto","group-tags-translate","onClick:selectLanguage","onClick:selectTheme","onClick:showChatgpt","extra-networks","loras","lycos","embeddings","version","latest-version","is-latest-version","onClick:showAbout","theme","onClick:switchTheme","group-tags","hide-group-tags","group-tags-color","group-tags-color-key-cache","onUpdate:hideGroupTags","group-tags-translate-cache","blacklist","cancel-blacklist-confirm","onUpdate:blacklist","hotkey","onShowExtraNetworks","onHideExtraNetworks"])):ke("",!0)],64))),128)),ye(l,{ref:"translateSetting","language-code":i.languageCode,"onUpdate:languageCode":t[17]||(t[17]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages,"onForceUpdate:translateApi":o.updateTranslateApiConfig,"tag-complete-file":i.tagCompleteFile,"onUpdate:tagCompleteFile":t[18]||(t[18]=x=>i.tagCompleteFile=x),"only-csv-on-auto":i.onlyCsvOnAuto,"onUpdate:onlyCsvOnAuto":t[19]||(t[19]=x=>i.onlyCsvOnAuto=x),"group-tags-translate":i.groupTagsTranslate,"onUpdate:groupTagsTranslate":t[20]||(t[20]=x=>i.groupTagsTranslate=x),"translate-api":i.translateApi,"onUpdate:translateApi":t[21]||(t[21]=x=>i.translateApi=x)},null,8,["language-code","translate-apis","languages","onForceUpdate:translateApi","tag-complete-file","only-csv-on-auto","group-tags-translate","translate-api"]),ye(c,{ref:"selectLanguage","language-code":i.languageCode,"onUpdate:languageCode":t[22]||(t[22]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages,"translate-api":i.translateApi,"onUpdate:translateApi":t[23]||(t[23]=x=>i.translateApi=x),"tag-complete-file":i.tagCompleteFile,"onUpdate:tagCompleteFile":t[24]||(t[24]=x=>i.tagCompleteFile=x),"only-csv-on-auto":i.onlyCsvOnAuto,"onUpdate:onlyCsvOnAuto":t[25]||(t[25]=x=>i.onlyCsvOnAuto=x)},null,8,["language-code","translate-apis","languages","translate-api","tag-complete-file","only-csv-on-auto"]),ye(d,{ref:"promptFormat","language-code":i.languageCode,"onUpdate:languageCode":t[26]||(t[26]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages,"auto-remove-space":i.autoRemoveSpace,"onUpdate:autoRemoveSpace":t[27]||(t[27]=x=>i.autoRemoveSpace=x),"auto-remove-last-comma":i.autoRemoveLastComma,"onUpdate:autoRemoveLastComma":t[28]||(t[28]=x=>i.autoRemoveLastComma=x),"auto-keep-weight-zero":i.autoKeepWeightZero,"onUpdate:autoKeepWeightZero":t[29]||(t[29]=x=>i.autoKeepWeightZero=x),"auto-keep-weight-one":i.autoKeepWeightOne,"onUpdate:autoKeepWeightOne":t[30]||(t[30]=x=>i.autoKeepWeightOne=x),"auto-break-before-wrap":i.autoBreakBeforeWrap,"onUpdate:autoBreakBeforeWrap":t[31]||(t[31]=x=>i.autoBreakBeforeWrap=x),"auto-break-after-wrap":i.autoBreakAfterWrap,"onUpdate:autoBreakAfterWrap":t[32]||(t[32]=x=>i.autoBreakAfterWrap=x)},null,8,["language-code","translate-apis","languages","auto-remove-space","auto-remove-last-comma","auto-keep-weight-zero","auto-keep-weight-one","auto-break-before-wrap","auto-break-after-wrap"]),ye(p,{ref:"blacklist","language-code":i.languageCode,"onUpdate:languageCode":t[33]||(t[33]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages,"onUpdate:blacklist":o.onUpdateBlacklist},null,8,["language-code","translate-apis","languages","onUpdate:blacklist"]),ye(y,{ref:"hotkey","language-code":i.languageCode,"onUpdate:languageCode":t[34]||(t[34]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages,"default-hotkey":i.hotkey,"onUpdate:hotkey":o.onUpdateHotkey},null,8,["language-code","translate-apis","languages","default-hotkey","onUpdate:hotkey"]),ye(m,{ref:"history","language-code":i.languageCode,"onUpdate:languageCode":t[35]||(t[35]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages,"tag-complete-file":i.tagCompleteFile,"onUpdate:tagCompleteFile":t[36]||(t[36]=x=>i.tagCompleteFile=x),"only-csv-on-auto":i.onlyCsvOnAuto,"onUpdate:onlyCsvOnAuto":t[37]||(t[37]=x=>i.onlyCsvOnAuto=x),onRefreshFavorites:o.onRefreshFavorites,onUse:o.onUseHistory},null,8,["language-code","translate-apis","languages","tag-complete-file","only-csv-on-auto","onRefreshFavorites","onUse"]),ye(C,{ref:"favorite","language-code":i.languageCode,"onUpdate:languageCode":t[38]||(t[38]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages,"tag-complete-file":i.tagCompleteFile,"onUpdate:tagCompleteFile":t[39]||(t[39]=x=>i.tagCompleteFile=x),"only-csv-on-auto":i.onlyCsvOnAuto,"onUpdate:onlyCsvOnAuto":t[40]||(t[40]=x=>i.onlyCsvOnAuto=x),onUse:o.onUseFavorite},null,8,["language-code","translate-apis","languages","tag-complete-file","only-csv-on-auto","onUse"]),ye(b,{ref:"extensionCss","language-code":i.languageCode,"onUpdate:languageCode":t[41]||(t[41]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages},null,8,["language-code","translate-apis","languages"]),ye(k,{ref:"packagesState","language-code":i.languageCode,"onUpdate:languageCode":t[42]||(t[42]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages,"onClick:selectLanguage":o.onSelectLanguageClick,"packages-state":i.packagesState,python:i.python},null,8,["language-code","translate-apis","languages","onClick:selectLanguage","packages-state","python"]),ye(L,{ref:"chatgptPrompt","language-code":i.languageCode,"onUpdate:languageCode":t[43]||(t[43]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages,onUse:o.onUseChatgpt},null,8,["language-code","translate-apis","languages","onUse"]),ye(O,{ref:"about","language-code":i.languageCode,"onUpdate:languageCode":t[44]||(t[44]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages},null,8,["language-code","translate-apis","languages"]),ye($,{ref:"extraNetworksPopup","language-code":i.languageCode,"onUpdate:languageCode":t[45]||(t[45]=x=>i.languageCode=x),"translate-apis":i.translateApis,languages:i.languages,"extra-networks":i.extraNetworks},null,8,["language-code","translate-apis","languages","extra-networks"]),i.showPastePopup?(E(),M("div",{key:0,class:"physton-paste-popup",onClick:t[50]||(t[50]=(...x)=>o.closePastePopup&&o.closePastePopup(...x))},[T("div",{class:"paste-popup-main",onClick:t[49]||(t[49]=nt(()=>{},["stop"]))},[T("div",{class:"paste-popup-close",onClick:t[46]||(t[46]=(...x)=>o.closePastePopup&&o.closePastePopup(...x))},[ye(X,{name:"close"})]),T("div",oH,ie(i.pasteTitle),1),T("div",sH,[ge(T("textarea",{class:"paste-content","onUpdate:modelValue":t[47]||(t[47]=x=>i.pasteContent=x),placeholder:o.getLang("please_enter_the_content_here")},null,8,aH),[[Vn,i.pasteContent]]),i.pasteLoading?(E(),M("div",lH,[ye(X,{name:"loading"})])):(E(),M("div",{key:0,class:"paste-submit",onClick:t[48]||(t[48]=(...x)=>o.onClickPasteSubmit&&o.onClickPasteSubmit(...x))},"Submit"))])])])):ke("",!0)])}const cH=hn(iH,[["render",uH]]);var x0={exports:{}},Nd={exports:{}};/*!
|
||
* jQuery JavaScript Library v3.7.1
|
||
* https://jquery.com/
|
||
*
|
||
* Copyright OpenJS Foundation and other contributors
|
||
* Released under the MIT license
|
||
* https://jquery.org/license
|
||
*
|
||
* Date: 2023-08-28T13:37Z
|
||
*/var S0;function fH(){return S0||(S0=1,function(e){(function(t,n){e.exports=t.document?n(t,!0):function(r){if(!r.document)throw new Error("jQuery requires a window with a document");return n(r)}})(typeof window<"u"?window:tf,function(t,n){var r=[],i=Object.getPrototypeOf,o=r.slice,s=r.flat?function(u){return r.flat.call(u)}:function(u){return r.concat.apply([],u)},l=r.push,c=r.indexOf,d={},p=d.toString,y=d.hasOwnProperty,m=y.toString,C=m.call(Object),b={},k=function(f){return typeof f=="function"&&typeof f.nodeType!="number"&&typeof f.item!="function"},L=function(f){return f!=null&&f===f.window},O=t.document,$={type:!0,src:!0,nonce:!0,noModule:!0};function X(u,f,h){h=h||O;var v,_,w=h.createElement("script");if(w.text=u,f)for(v in $)_=f[v]||f.getAttribute&&f.getAttribute(v),_&&w.setAttribute(v,_);h.head.appendChild(w).parentNode.removeChild(w)}function x(u){return u==null?u+"":typeof u=="object"||typeof u=="function"?d[p.call(u)]||"object":typeof u}var z="3.7.1",Q=/HTML$/i,g=function(u,f){return new g.fn.init(u,f)};g.fn=g.prototype={jquery:z,constructor:g,length:0,toArray:function(){return o.call(this)},get:function(u){return u==null?o.call(this):u<0?this[u+this.length]:this[u]},pushStack:function(u){var f=g.merge(this.constructor(),u);return f.prevObject=this,f},each:function(u){return g.each(this,u)},map:function(u){return this.pushStack(g.map(this,function(f,h){return u.call(f,h,f)}))},slice:function(){return this.pushStack(o.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(g.grep(this,function(u,f){return(f+1)%2}))},odd:function(){return this.pushStack(g.grep(this,function(u,f){return f%2}))},eq:function(u){var f=this.length,h=+u+(u<0?f:0);return this.pushStack(h>=0&&h<f?[this[h]]:[])},end:function(){return this.prevObject||this.constructor()},push:l,sort:r.sort,splice:r.splice},g.extend=g.fn.extend=function(){var u,f,h,v,_,w,S=arguments[0]||{},F=1,N=arguments.length,W=!1;for(typeof S=="boolean"&&(W=S,S=arguments[F]||{},F++),typeof S!="object"&&!k(S)&&(S={}),F===N&&(S=this,F--);F<N;F++)if((u=arguments[F])!=null)for(f in u)v=u[f],!(f==="__proto__"||S===v)&&(W&&v&&(g.isPlainObject(v)||(_=Array.isArray(v)))?(h=S[f],_&&!Array.isArray(h)?w=[]:!_&&!g.isPlainObject(h)?w={}:w=h,_=!1,S[f]=g.extend(W,w,v)):v!==void 0&&(S[f]=v));return S},g.extend({expando:"jQuery"+(z+Math.random()).replace(/\D/g,""),isReady:!0,error:function(u){throw new Error(u)},noop:function(){},isPlainObject:function(u){var f,h;return!u||p.call(u)!=="[object Object]"?!1:(f=i(u),f?(h=y.call(f,"constructor")&&f.constructor,typeof h=="function"&&m.call(h)===C):!0)},isEmptyObject:function(u){var f;for(f in u)return!1;return!0},globalEval:function(u,f,h){X(u,{nonce:f&&f.nonce},h)},each:function(u,f){var h,v=0;if(I(u))for(h=u.length;v<h&&f.call(u[v],v,u[v])!==!1;v++);else for(v in u)if(f.call(u[v],v,u[v])===!1)break;return u},text:function(u){var f,h="",v=0,_=u.nodeType;if(!_)for(;f=u[v++];)h+=g.text(f);return _===1||_===11?u.textContent:_===9?u.documentElement.textContent:_===3||_===4?u.nodeValue:h},makeArray:function(u,f){var h=f||[];return u!=null&&(I(Object(u))?g.merge(h,typeof u=="string"?[u]:u):l.call(h,u)),h},inArray:function(u,f,h){return f==null?-1:c.call(f,u,h)},isXMLDoc:function(u){var f=u&&u.namespaceURI,h=u&&(u.ownerDocument||u).documentElement;return!Q.test(f||h&&h.nodeName||"HTML")},merge:function(u,f){for(var h=+f.length,v=0,_=u.length;v<h;v++)u[_++]=f[v];return u.length=_,u},grep:function(u,f,h){for(var v,_=[],w=0,S=u.length,F=!h;w<S;w++)v=!f(u[w],w),v!==F&&_.push(u[w]);return _},map:function(u,f,h){var v,_,w=0,S=[];if(I(u))for(v=u.length;w<v;w++)_=f(u[w],w,h),_!=null&&S.push(_);else for(w in u)_=f(u[w],w,h),_!=null&&S.push(_);return s(S)},guid:1,support:b}),typeof Symbol=="function"&&(g.fn[Symbol.iterator]=r[Symbol.iterator]),g.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(u,f){d["[object "+f+"]"]=f.toLowerCase()});function I(u){var f=!!u&&"length"in u&&u.length,h=x(u);return k(u)||L(u)?!1:h==="array"||f===0||typeof f=="number"&&f>0&&f-1 in u}function A(u,f){return u.nodeName&&u.nodeName.toLowerCase()===f.toLowerCase()}var D=r.pop,H=r.sort,K=r.splice,U="[\\x20\\t\\r\\n\\f]",de=new RegExp("^"+U+"+|((?:^|[^\\\\])(?:\\\\.)*)"+U+"+$","g");g.contains=function(u,f){var h=f&&f.parentNode;return u===h||!!(h&&h.nodeType===1&&(u.contains?u.contains(h):u.compareDocumentPosition&&u.compareDocumentPosition(h)&16))};var je=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\x80-\uFFFF\w-]/g;function Pe(u,f){return f?u==="\0"?"<22>":u.slice(0,-1)+"\\"+u.charCodeAt(u.length-1).toString(16)+" ":"\\"+u}g.escapeSelector=function(u){return(u+"").replace(je,Pe)};var V=O,ae=l;(function(){var u,f,h,v,_,w=ae,S,F,N,W,re,ue=g.expando,G=0,we=0,it=Uu(),yt=Uu(),ft=Uu(),vn=Uu(),an=function(P,j){return P===j&&(_=!0),0},jr="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",Ur="(?:\\\\[\\da-fA-F]{1,6}"+U+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",vt="\\["+U+"*("+Ur+")(?:"+U+"*([*^$|!~]?=)"+U+`*(?:'((?:\\\\.|[^\\\\'])*)'|"((?:\\\\.|[^\\\\"])*)"|(`+Ur+"))|)"+U+"*\\]",co=":("+Ur+`)(?:\\((('((?:\\\\.|[^\\\\'])*)'|"((?:\\\\.|[^\\\\"])*)")|((?:\\\\.|[^\\\\()[\\]]|`+vt+")*)|.*)\\)|)",kt=new RegExp(U+"+","g"),qt=new RegExp("^"+U+"*,"+U+"*"),Ha=new RegExp("^"+U+"*([>+~]|"+U+")"+U+"*"),mp=new RegExp(U+"|>"),Wr=new RegExp(co),ja=new RegExp("^"+Ur+"$"),Kr={ID:new RegExp("^#("+Ur+")"),CLASS:new RegExp("^\\.("+Ur+")"),TAG:new RegExp("^("+Ur+"|[*])"),ATTR:new RegExp("^"+vt),PSEUDO:new RegExp("^"+co),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+U+"*(even|odd|(([+-]|)(\\d*)n|)"+U+"*(?:([+-]|)"+U+"*(\\d+)|))"+U+"*\\)|)","i"),bool:new RegExp("^(?:"+jr+")$","i"),needsContext:new RegExp("^"+U+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+U+"*((?:-\\d)?\\d*)"+U+"*\\)|)(?=[^-]|$)","i")},Oi=/^(?:input|select|textarea|button)$/i,Ii=/^h\d$/i,gr=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,vp=/[+~]/,ai=new RegExp("\\\\[\\da-fA-F]{1,6}"+U+"?|\\\\([^\\r\\n\\f])","g"),li=function(P,j){var q="0x"+P.slice(1)-65536;return j||(q<0?String.fromCharCode(q+65536):String.fromCharCode(q>>10|55296,q&1023|56320))},N3=function(){Pi()},M3=Ku(function(P){return P.disabled===!0&&A(P,"fieldset")},{dir:"parentNode",next:"legend"});function F3(){try{return S.activeElement}catch{}}try{w.apply(r=o.call(V.childNodes),V.childNodes),r[V.childNodes.length].nodeType}catch{w={apply:function(j,q){ae.apply(j,o.call(q))},call:function(j){ae.apply(j,o.call(arguments,1))}}}function Et(P,j,q,Z){var le,Ee,Me,We,Fe,ht,Ze,st=j&&j.ownerDocument,gt=j?j.nodeType:9;if(q=q||[],typeof P!="string"||!P||gt!==1&>!==9&>!==11)return q;if(!Z&&(Pi(j),j=j||S,N)){if(gt!==11&&(Fe=gr.exec(P)))if(le=Fe[1]){if(gt===9)if(Me=j.getElementById(le)){if(Me.id===le)return w.call(q,Me),q}else return q;else if(st&&(Me=st.getElementById(le))&&Et.contains(j,Me)&&Me.id===le)return w.call(q,Me),q}else{if(Fe[2])return w.apply(q,j.getElementsByTagName(P)),q;if((le=Fe[3])&&j.getElementsByClassName)return w.apply(q,j.getElementsByClassName(le)),q}if(!vn[P+" "]&&(!W||!W.test(P))){if(Ze=P,st=j,gt===1&&(mp.test(P)||Ha.test(P))){for(st=vp.test(P)&&yp(j.parentNode)||j,(st!=j||!b.scope)&&((We=j.getAttribute("id"))?We=g.escapeSelector(We):j.setAttribute("id",We=ue)),ht=Ua(P),Ee=ht.length;Ee--;)ht[Ee]=(We?"#"+We:":scope")+" "+Wu(ht[Ee]);Ze=ht.join(",")}try{return w.apply(q,st.querySelectorAll(Ze)),q}catch{vn(P,!0)}finally{We===ue&&j.removeAttribute("id")}}}return zb(P.replace(de,"$1"),j,q,Z)}function Uu(){var P=[];function j(q,Z){return P.push(q+" ")>f.cacheLength&&delete j[P.shift()],j[q+" "]=Z}return j}function Sr(P){return P[ue]=!0,P}function bs(P){var j=S.createElement("fieldset");try{return!!P(j)}catch{return!1}finally{j.parentNode&&j.parentNode.removeChild(j),j=null}}function B3(P){return function(j){return A(j,"input")&&j.type===P}}function $3(P){return function(j){return(A(j,"input")||A(j,"button"))&&j.type===P}}function Vb(P){return function(j){return"form"in j?j.parentNode&&j.disabled===!1?"label"in j?"label"in j.parentNode?j.parentNode.disabled===P:j.disabled===P:j.isDisabled===P||j.isDisabled!==!P&&M3(j)===P:j.disabled===P:"label"in j?j.disabled===P:!1}}function fo(P){return Sr(function(j){return j=+j,Sr(function(q,Z){for(var le,Ee=P([],q.length,j),Me=Ee.length;Me--;)q[le=Ee[Me]]&&(q[le]=!(Z[le]=q[le]))})})}function yp(P){return P&&typeof P.getElementsByTagName<"u"&&P}function Pi(P){var j,q=P?P.ownerDocument||P:V;return q==S||q.nodeType!==9||!q.documentElement||(S=q,F=S.documentElement,N=!g.isXMLDoc(S),re=F.matches||F.webkitMatchesSelector||F.msMatchesSelector,F.msMatchesSelector&&V!=S&&(j=S.defaultView)&&j.top!==j&&j.addEventListener("unload",N3),b.getById=bs(function(Z){return F.appendChild(Z).id=g.expando,!S.getElementsByName||!S.getElementsByName(g.expando).length}),b.disconnectedMatch=bs(function(Z){return re.call(Z,"*")}),b.scope=bs(function(){return S.querySelectorAll(":scope")}),b.cssHas=bs(function(){try{return S.querySelector(":has(*,:jqfake)"),!1}catch{return!0}}),b.getById?(f.filter.ID=function(Z){var le=Z.replace(ai,li);return function(Ee){return Ee.getAttribute("id")===le}},f.find.ID=function(Z,le){if(typeof le.getElementById<"u"&&N){var Ee=le.getElementById(Z);return Ee?[Ee]:[]}}):(f.filter.ID=function(Z){var le=Z.replace(ai,li);return function(Ee){var Me=typeof Ee.getAttributeNode<"u"&&Ee.getAttributeNode("id");return Me&&Me.value===le}},f.find.ID=function(Z,le){if(typeof le.getElementById<"u"&&N){var Ee,Me,We,Fe=le.getElementById(Z);if(Fe){if(Ee=Fe.getAttributeNode("id"),Ee&&Ee.value===Z)return[Fe];for(We=le.getElementsByName(Z),Me=0;Fe=We[Me++];)if(Ee=Fe.getAttributeNode("id"),Ee&&Ee.value===Z)return[Fe]}return[]}}),f.find.TAG=function(Z,le){return typeof le.getElementsByTagName<"u"?le.getElementsByTagName(Z):le.querySelectorAll(Z)},f.find.CLASS=function(Z,le){if(typeof le.getElementsByClassName<"u"&&N)return le.getElementsByClassName(Z)},W=[],bs(function(Z){var le;F.appendChild(Z).innerHTML="<a id='"+ue+"' href='' disabled='disabled'></a><select id='"+ue+"-\r\\' disabled='disabled'><option selected=''></option></select>",Z.querySelectorAll("[selected]").length||W.push("\\["+U+"*(?:value|"+jr+")"),Z.querySelectorAll("[id~="+ue+"-]").length||W.push("~="),Z.querySelectorAll("a#"+ue+"+*").length||W.push(".#.+[+~]"),Z.querySelectorAll(":checked").length||W.push(":checked"),le=S.createElement("input"),le.setAttribute("type","hidden"),Z.appendChild(le).setAttribute("name","D"),F.appendChild(Z).disabled=!0,Z.querySelectorAll(":disabled").length!==2&&W.push(":enabled",":disabled"),le=S.createElement("input"),le.setAttribute("name",""),Z.appendChild(le),Z.querySelectorAll("[name='']").length||W.push("\\["+U+"*name"+U+"*="+U+`*(?:''|"")`)}),b.cssHas||W.push(":has"),W=W.length&&new RegExp(W.join("|")),an=function(Z,le){if(Z===le)return _=!0,0;var Ee=!Z.compareDocumentPosition-!le.compareDocumentPosition;return Ee||(Ee=(Z.ownerDocument||Z)==(le.ownerDocument||le)?Z.compareDocumentPosition(le):1,Ee&1||!b.sortDetached&&le.compareDocumentPosition(Z)===Ee?Z===S||Z.ownerDocument==V&&Et.contains(V,Z)?-1:le===S||le.ownerDocument==V&&Et.contains(V,le)?1:v?c.call(v,Z)-c.call(v,le):0:Ee&4?-1:1)}),S}Et.matches=function(P,j){return Et(P,null,null,j)},Et.matchesSelector=function(P,j){if(Pi(P),N&&!vn[j+" "]&&(!W||!W.test(j)))try{var q=re.call(P,j);if(q||b.disconnectedMatch||P.document&&P.document.nodeType!==11)return q}catch{vn(j,!0)}return Et(j,S,null,[P]).length>0},Et.contains=function(P,j){return(P.ownerDocument||P)!=S&&Pi(P),g.contains(P,j)},Et.attr=function(P,j){(P.ownerDocument||P)!=S&&Pi(P);var q=f.attrHandle[j.toLowerCase()],Z=q&&y.call(f.attrHandle,j.toLowerCase())?q(P,j,!N):void 0;return Z!==void 0?Z:P.getAttribute(j)},Et.error=function(P){throw new Error("Syntax error, unrecognized expression: "+P)},g.uniqueSort=function(P){var j,q=[],Z=0,le=0;if(_=!b.sortStable,v=!b.sortStable&&o.call(P,0),H.call(P,an),_){for(;j=P[le++];)j===P[le]&&(Z=q.push(le));for(;Z--;)K.call(P,q[Z],1)}return v=null,P},g.fn.uniqueSort=function(){return this.pushStack(g.uniqueSort(o.apply(this)))},f=g.expr={cacheLength:50,createPseudo:Sr,match:Kr,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(P){return P[1]=P[1].replace(ai,li),P[3]=(P[3]||P[4]||P[5]||"").replace(ai,li),P[2]==="~="&&(P[3]=" "+P[3]+" "),P.slice(0,4)},CHILD:function(P){return P[1]=P[1].toLowerCase(),P[1].slice(0,3)==="nth"?(P[3]||Et.error(P[0]),P[4]=+(P[4]?P[5]+(P[6]||1):2*(P[3]==="even"||P[3]==="odd")),P[5]=+(P[7]+P[8]||P[3]==="odd")):P[3]&&Et.error(P[0]),P},PSEUDO:function(P){var j,q=!P[6]&&P[2];return Kr.CHILD.test(P[0])?null:(P[3]?P[2]=P[4]||P[5]||"":q&&Wr.test(q)&&(j=Ua(q,!0))&&(j=q.indexOf(")",q.length-j)-q.length)&&(P[0]=P[0].slice(0,j),P[2]=q.slice(0,j)),P.slice(0,3))}},filter:{TAG:function(P){var j=P.replace(ai,li).toLowerCase();return P==="*"?function(){return!0}:function(q){return A(q,j)}},CLASS:function(P){var j=it[P+" "];return j||(j=new RegExp("(^|"+U+")"+P+"("+U+"|$)"))&&it(P,function(q){return j.test(typeof q.className=="string"&&q.className||typeof q.getAttribute<"u"&&q.getAttribute("class")||"")})},ATTR:function(P,j,q){return function(Z){var le=Et.attr(Z,P);return le==null?j==="!=":j?(le+="",j==="="?le===q:j==="!="?le!==q:j==="^="?q&&le.indexOf(q)===0:j==="*="?q&&le.indexOf(q)>-1:j==="$="?q&&le.slice(-q.length)===q:j==="~="?(" "+le.replace(kt," ")+" ").indexOf(q)>-1:j==="|="?le===q||le.slice(0,q.length+1)===q+"-":!1):!0}},CHILD:function(P,j,q,Z,le){var Ee=P.slice(0,3)!=="nth",Me=P.slice(-4)!=="last",We=j==="of-type";return Z===1&&le===0?function(Fe){return!!Fe.parentNode}:function(Fe,ht,Ze){var st,gt,ze,Pt,Wn,Sn=Ee!==Me?"nextSibling":"previousSibling",mr=Fe.parentNode,Vr=We&&Fe.nodeName.toLowerCase(),Cs=!Ze&&!We,In=!1;if(mr){if(Ee){for(;Sn;){for(ze=Fe;ze=ze[Sn];)if(We?A(ze,Vr):ze.nodeType===1)return!1;Wn=Sn=P==="only"&&!Wn&&"nextSibling"}return!0}if(Wn=[Me?mr.firstChild:mr.lastChild],Me&&Cs){for(gt=mr[ue]||(mr[ue]={}),st=gt[P]||[],Pt=st[0]===G&&st[1],In=Pt&&st[2],ze=Pt&&mr.childNodes[Pt];ze=++Pt&&ze&&ze[Sn]||(In=Pt=0)||Wn.pop();)if(ze.nodeType===1&&++In&&ze===Fe){gt[P]=[G,Pt,In];break}}else if(Cs&&(gt=Fe[ue]||(Fe[ue]={}),st=gt[P]||[],Pt=st[0]===G&&st[1],In=Pt),In===!1)for(;(ze=++Pt&&ze&&ze[Sn]||(In=Pt=0)||Wn.pop())&&!((We?A(ze,Vr):ze.nodeType===1)&&++In&&(Cs&&(gt=ze[ue]||(ze[ue]={}),gt[P]=[G,In]),ze===Fe)););return In-=le,In===Z||In%Z===0&&In/Z>=0}}},PSEUDO:function(P,j){var q,Z=f.pseudos[P]||f.setFilters[P.toLowerCase()]||Et.error("unsupported pseudo: "+P);return Z[ue]?Z(j):Z.length>1?(q=[P,P,"",j],f.setFilters.hasOwnProperty(P.toLowerCase())?Sr(function(le,Ee){for(var Me,We=Z(le,j),Fe=We.length;Fe--;)Me=c.call(le,We[Fe]),le[Me]=!(Ee[Me]=We[Fe])}):function(le){return Z(le,0,q)}):Z}},pseudos:{not:Sr(function(P){var j=[],q=[],Z=wp(P.replace(de,"$1"));return Z[ue]?Sr(function(le,Ee,Me,We){for(var Fe,ht=Z(le,null,We,[]),Ze=le.length;Ze--;)(Fe=ht[Ze])&&(le[Ze]=!(Ee[Ze]=Fe))}):function(le,Ee,Me){return j[0]=le,Z(j,null,Me,q),j[0]=null,!q.pop()}}),has:Sr(function(P){return function(j){return Et(P,j).length>0}}),contains:Sr(function(P){return P=P.replace(ai,li),function(j){return(j.textContent||g.text(j)).indexOf(P)>-1}}),lang:Sr(function(P){return ja.test(P||"")||Et.error("unsupported lang: "+P),P=P.replace(ai,li).toLowerCase(),function(j){var q;do if(q=N?j.lang:j.getAttribute("xml:lang")||j.getAttribute("lang"))return q=q.toLowerCase(),q===P||q.indexOf(P+"-")===0;while((j=j.parentNode)&&j.nodeType===1);return!1}}),target:function(P){var j=t.location&&t.location.hash;return j&&j.slice(1)===P.id},root:function(P){return P===F},focus:function(P){return P===F3()&&S.hasFocus()&&!!(P.type||P.href||~P.tabIndex)},enabled:Vb(!1),disabled:Vb(!0),checked:function(P){return A(P,"input")&&!!P.checked||A(P,"option")&&!!P.selected},selected:function(P){return P.parentNode&&P.parentNode.selectedIndex,P.selected===!0},empty:function(P){for(P=P.firstChild;P;P=P.nextSibling)if(P.nodeType<6)return!1;return!0},parent:function(P){return!f.pseudos.empty(P)},header:function(P){return Ii.test(P.nodeName)},input:function(P){return Oi.test(P.nodeName)},button:function(P){return A(P,"input")&&P.type==="button"||A(P,"button")},text:function(P){var j;return A(P,"input")&&P.type==="text"&&((j=P.getAttribute("type"))==null||j.toLowerCase()==="text")},first:fo(function(){return[0]}),last:fo(function(P,j){return[j-1]}),eq:fo(function(P,j,q){return[q<0?q+j:q]}),even:fo(function(P,j){for(var q=0;q<j;q+=2)P.push(q);return P}),odd:fo(function(P,j){for(var q=1;q<j;q+=2)P.push(q);return P}),lt:fo(function(P,j,q){var Z;for(q<0?Z=q+j:q>j?Z=j:Z=q;--Z>=0;)P.push(Z);return P}),gt:fo(function(P,j,q){for(var Z=q<0?q+j:q;++Z<j;)P.push(Z);return P})}},f.pseudos.nth=f.pseudos.eq;for(u in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})f.pseudos[u]=B3(u);for(u in{submit:!0,reset:!0})f.pseudos[u]=$3(u);function qb(){}qb.prototype=f.filters=f.pseudos,f.setFilters=new qb;function Ua(P,j){var q,Z,le,Ee,Me,We,Fe,ht=yt[P+" "];if(ht)return j?0:ht.slice(0);for(Me=P,We=[],Fe=f.preFilter;Me;){(!q||(Z=qt.exec(Me)))&&(Z&&(Me=Me.slice(Z[0].length)||Me),We.push(le=[])),q=!1,(Z=Ha.exec(Me))&&(q=Z.shift(),le.push({value:q,type:Z[0].replace(de," ")}),Me=Me.slice(q.length));for(Ee in f.filter)(Z=Kr[Ee].exec(Me))&&(!Fe[Ee]||(Z=Fe[Ee](Z)))&&(q=Z.shift(),le.push({value:q,type:Ee,matches:Z}),Me=Me.slice(q.length));if(!q)break}return j?Me.length:Me?Et.error(P):yt(P,We).slice(0)}function Wu(P){for(var j=0,q=P.length,Z="";j<q;j++)Z+=P[j].value;return Z}function Ku(P,j,q){var Z=j.dir,le=j.next,Ee=le||Z,Me=q&&Ee==="parentNode",We=we++;return j.first?function(Fe,ht,Ze){for(;Fe=Fe[Z];)if(Fe.nodeType===1||Me)return P(Fe,ht,Ze);return!1}:function(Fe,ht,Ze){var st,gt,ze=[G,We];if(Ze){for(;Fe=Fe[Z];)if((Fe.nodeType===1||Me)&&P(Fe,ht,Ze))return!0}else for(;Fe=Fe[Z];)if(Fe.nodeType===1||Me)if(gt=Fe[ue]||(Fe[ue]={}),le&&A(Fe,le))Fe=Fe[Z]||Fe;else{if((st=gt[Ee])&&st[0]===G&&st[1]===We)return ze[2]=st[2];if(gt[Ee]=ze,ze[2]=P(Fe,ht,Ze))return!0}return!1}}function bp(P){return P.length>1?function(j,q,Z){for(var le=P.length;le--;)if(!P[le](j,q,Z))return!1;return!0}:P[0]}function H3(P,j,q){for(var Z=0,le=j.length;Z<le;Z++)Et(P,j[Z],q);return q}function Vu(P,j,q,Z,le){for(var Ee,Me=[],We=0,Fe=P.length,ht=j!=null;We<Fe;We++)(Ee=P[We])&&(!q||q(Ee,Z,le))&&(Me.push(Ee),ht&&j.push(We));return Me}function Cp(P,j,q,Z,le,Ee){return Z&&!Z[ue]&&(Z=Cp(Z)),le&&!le[ue]&&(le=Cp(le,Ee)),Sr(function(Me,We,Fe,ht){var Ze,st,gt,ze,Pt=[],Wn=[],Sn=We.length,mr=Me||H3(j||"*",Fe.nodeType?[Fe]:Fe,[]),Vr=P&&(Me||!j)?Vu(mr,Pt,P,Fe,ht):mr;if(q?(ze=le||(Me?P:Sn||Z)?[]:We,q(Vr,ze,Fe,ht)):ze=Vr,Z)for(Ze=Vu(ze,Wn),Z(Ze,[],Fe,ht),st=Ze.length;st--;)(gt=Ze[st])&&(ze[Wn[st]]=!(Vr[Wn[st]]=gt));if(Me){if(le||P){if(le){for(Ze=[],st=ze.length;st--;)(gt=ze[st])&&Ze.push(Vr[st]=gt);le(null,ze=[],Ze,ht)}for(st=ze.length;st--;)(gt=ze[st])&&(Ze=le?c.call(Me,gt):Pt[st])>-1&&(Me[Ze]=!(We[Ze]=gt))}}else ze=Vu(ze===We?ze.splice(Sn,ze.length):ze),le?le(null,We,ze,ht):w.apply(We,ze)})}function _p(P){for(var j,q,Z,le=P.length,Ee=f.relative[P[0].type],Me=Ee||f.relative[" "],We=Ee?1:0,Fe=Ku(function(st){return st===j},Me,!0),ht=Ku(function(st){return c.call(j,st)>-1},Me,!0),Ze=[function(st,gt,ze){var Pt=!Ee&&(ze||gt!=h)||((j=gt).nodeType?Fe(st,gt,ze):ht(st,gt,ze));return j=null,Pt}];We<le;We++)if(q=f.relative[P[We].type])Ze=[Ku(bp(Ze),q)];else{if(q=f.filter[P[We].type].apply(null,P[We].matches),q[ue]){for(Z=++We;Z<le&&!f.relative[P[Z].type];Z++);return Cp(We>1&&bp(Ze),We>1&&Wu(P.slice(0,We-1).concat({value:P[We-2].type===" "?"*":""})).replace(de,"$1"),q,We<Z&&_p(P.slice(We,Z)),Z<le&&_p(P=P.slice(Z)),Z<le&&Wu(P))}Ze.push(q)}return bp(Ze)}function j3(P,j){var q=j.length>0,Z=P.length>0,le=function(Ee,Me,We,Fe,ht){var Ze,st,gt,ze=0,Pt="0",Wn=Ee&&[],Sn=[],mr=h,Vr=Ee||Z&&f.find.TAG("*",ht),Cs=G+=mr==null?1:Math.random()||.1,In=Vr.length;for(ht&&(h=Me==S||Me||ht);Pt!==In&&(Ze=Vr[Pt])!=null;Pt++){if(Z&&Ze){for(st=0,!Me&&Ze.ownerDocument!=S&&(Pi(Ze),We=!N);gt=P[st++];)if(gt(Ze,Me||S,We)){w.call(Fe,Ze);break}ht&&(G=Cs)}q&&((Ze=!gt&&Ze)&&ze--,Ee&&Wn.push(Ze))}if(ze+=Pt,q&&Pt!==ze){for(st=0;gt=j[st++];)gt(Wn,Sn,Me,We);if(Ee){if(ze>0)for(;Pt--;)Wn[Pt]||Sn[Pt]||(Sn[Pt]=D.call(Fe));Sn=Vu(Sn)}w.apply(Fe,Sn),ht&&!Ee&&Sn.length>0&&ze+j.length>1&&g.uniqueSort(Fe)}return ht&&(G=Cs,h=mr),Wn};return q?Sr(le):le}function wp(P,j){var q,Z=[],le=[],Ee=ft[P+" "];if(!Ee){for(j||(j=Ua(P)),q=j.length;q--;)Ee=_p(j[q]),Ee[ue]?Z.push(Ee):le.push(Ee);Ee=ft(P,j3(le,Z)),Ee.selector=P}return Ee}function zb(P,j,q,Z){var le,Ee,Me,We,Fe,ht=typeof P=="function"&&P,Ze=!Z&&Ua(P=ht.selector||P);if(q=q||[],Ze.length===1){if(Ee=Ze[0]=Ze[0].slice(0),Ee.length>2&&(Me=Ee[0]).type==="ID"&&j.nodeType===9&&N&&f.relative[Ee[1].type]){if(j=(f.find.ID(Me.matches[0].replace(ai,li),j)||[])[0],j)ht&&(j=j.parentNode);else return q;P=P.slice(Ee.shift().value.length)}for(le=Kr.needsContext.test(P)?0:Ee.length;le--&&(Me=Ee[le],!f.relative[We=Me.type]);)if((Fe=f.find[We])&&(Z=Fe(Me.matches[0].replace(ai,li),vp.test(Ee[0].type)&&yp(j.parentNode)||j))){if(Ee.splice(le,1),P=Z.length&&Wu(Ee),!P)return w.apply(q,Z),q;break}}return(ht||wp(P,Ze))(Z,j,!N,q,!j||vp.test(P)&&yp(j.parentNode)||j),q}b.sortStable=ue.split("").sort(an).join("")===ue,Pi(),b.sortDetached=bs(function(P){return P.compareDocumentPosition(S.createElement("fieldset"))&1}),g.find=Et,g.expr[":"]=g.expr.pseudos,g.unique=g.uniqueSort,Et.compile=wp,Et.select=zb,Et.setDocument=Pi,Et.tokenize=Ua,Et.escape=g.escapeSelector,Et.getText=g.text,Et.isXML=g.isXMLDoc,Et.selectors=g.expr,Et.support=g.support,Et.uniqueSort=g.uniqueSort})();var pe=function(u,f,h){for(var v=[],_=h!==void 0;(u=u[f])&&u.nodeType!==9;)if(u.nodeType===1){if(_&&g(u).is(h))break;v.push(u)}return v},Qe=function(u,f){for(var h=[];u;u=u.nextSibling)u.nodeType===1&&u!==f&&h.push(u);return h},et=g.expr.match.needsContext,se=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function Ce(u,f,h){return k(f)?g.grep(u,function(v,_){return!!f.call(v,_,v)!==h}):f.nodeType?g.grep(u,function(v){return v===f!==h}):typeof f!="string"?g.grep(u,function(v){return c.call(f,v)>-1!==h}):g.filter(f,u,h)}g.filter=function(u,f,h){var v=f[0];return h&&(u=":not("+u+")"),f.length===1&&v.nodeType===1?g.find.matchesSelector(v,u)?[v]:[]:g.find.matches(u,g.grep(f,function(_){return _.nodeType===1}))},g.fn.extend({find:function(u){var f,h,v=this.length,_=this;if(typeof u!="string")return this.pushStack(g(u).filter(function(){for(f=0;f<v;f++)if(g.contains(_[f],this))return!0}));for(h=this.pushStack([]),f=0;f<v;f++)g.find(u,_[f],h);return v>1?g.uniqueSort(h):h},filter:function(u){return this.pushStack(Ce(this,u||[],!1))},not:function(u){return this.pushStack(Ce(this,u||[],!0))},is:function(u){return!!Ce(this,typeof u=="string"&&et.test(u)?g(u):u||[],!1).length}});var xe,Ae=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/,Oe=g.fn.init=function(u,f,h){var v,_;if(!u)return this;if(h=h||xe,typeof u=="string")if(u[0]==="<"&&u[u.length-1]===">"&&u.length>=3?v=[null,u,null]:v=Ae.exec(u),v&&(v[1]||!f))if(v[1]){if(f=f instanceof g?f[0]:f,g.merge(this,g.parseHTML(v[1],f&&f.nodeType?f.ownerDocument||f:O,!0)),se.test(v[1])&&g.isPlainObject(f))for(v in f)k(this[v])?this[v](f[v]):this.attr(v,f[v]);return this}else return _=O.getElementById(v[2]),_&&(this[0]=_,this.length=1),this;else return!f||f.jquery?(f||h).find(u):this.constructor(f).find(u);else{if(u.nodeType)return this[0]=u,this.length=1,this;if(k(u))return h.ready!==void 0?h.ready(u):u(g)}return g.makeArray(u,this)};Oe.prototype=g.fn,xe=g(O);var Be=/^(?:parents|prev(?:Until|All))/,tt={children:!0,contents:!0,next:!0,prev:!0};g.fn.extend({has:function(u){var f=g(u,this),h=f.length;return this.filter(function(){for(var v=0;v<h;v++)if(g.contains(this,f[v]))return!0})},closest:function(u,f){var h,v=0,_=this.length,w=[],S=typeof u!="string"&&g(u);if(!et.test(u)){for(;v<_;v++)for(h=this[v];h&&h!==f;h=h.parentNode)if(h.nodeType<11&&(S?S.index(h)>-1:h.nodeType===1&&g.find.matchesSelector(h,u))){w.push(h);break}}return this.pushStack(w.length>1?g.uniqueSort(w):w)},index:function(u){return u?typeof u=="string"?c.call(g(u),this[0]):c.call(this,u.jquery?u[0]:u):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(u,f){return this.pushStack(g.uniqueSort(g.merge(this.get(),g(u,f))))},addBack:function(u){return this.add(u==null?this.prevObject:this.prevObject.filter(u))}});function Re(u,f){for(;(u=u[f])&&u.nodeType!==1;);return u}g.each({parent:function(u){var f=u.parentNode;return f&&f.nodeType!==11?f:null},parents:function(u){return pe(u,"parentNode")},parentsUntil:function(u,f,h){return pe(u,"parentNode",h)},next:function(u){return Re(u,"nextSibling")},prev:function(u){return Re(u,"previousSibling")},nextAll:function(u){return pe(u,"nextSibling")},prevAll:function(u){return pe(u,"previousSibling")},nextUntil:function(u,f,h){return pe(u,"nextSibling",h)},prevUntil:function(u,f,h){return pe(u,"previousSibling",h)},siblings:function(u){return Qe((u.parentNode||{}).firstChild,u)},children:function(u){return Qe(u.firstChild)},contents:function(u){return u.contentDocument!=null&&i(u.contentDocument)?u.contentDocument:(A(u,"template")&&(u=u.content||u),g.merge([],u.childNodes))}},function(u,f){g.fn[u]=function(h,v){var _=g.map(this,f,h);return u.slice(-5)!=="Until"&&(v=h),v&&typeof v=="string"&&(_=g.filter(v,_)),this.length>1&&(tt[u]||g.uniqueSort(_),Be.test(u)&&_.reverse()),this.pushStack(_)}});var Ve=/[^\x20\t\r\n\f]+/g;function dt(u){var f={};return g.each(u.match(Ve)||[],function(h,v){f[v]=!0}),f}g.Callbacks=function(u){u=typeof u=="string"?dt(u):g.extend({},u);var f,h,v,_,w=[],S=[],F=-1,N=function(){for(_=_||u.once,v=f=!0;S.length;F=-1)for(h=S.shift();++F<w.length;)w[F].apply(h[0],h[1])===!1&&u.stopOnFalse&&(F=w.length,h=!1);u.memory||(h=!1),f=!1,_&&(h?w=[]:w="")},W={add:function(){return w&&(h&&!f&&(F=w.length-1,S.push(h)),function re(ue){g.each(ue,function(G,we){k(we)?(!u.unique||!W.has(we))&&w.push(we):we&&we.length&&x(we)!=="string"&&re(we)})}(arguments),h&&!f&&N()),this},remove:function(){return g.each(arguments,function(re,ue){for(var G;(G=g.inArray(ue,w,G))>-1;)w.splice(G,1),G<=F&&F--}),this},has:function(re){return re?g.inArray(re,w)>-1:w.length>0},empty:function(){return w&&(w=[]),this},disable:function(){return _=S=[],w=h="",this},disabled:function(){return!w},lock:function(){return _=S=[],!h&&!f&&(w=h=""),this},locked:function(){return!!_},fireWith:function(re,ue){return _||(ue=ue||[],ue=[re,ue.slice?ue.slice():ue],S.push(ue),f||N()),this},fire:function(){return W.fireWith(this,arguments),this},fired:function(){return!!v}};return W};function R(u){return u}function B(u){throw u}function Y(u,f,h,v){var _;try{u&&k(_=u.promise)?_.call(u).done(f).fail(h):u&&k(_=u.then)?_.call(u,f,h):f.apply(void 0,[u].slice(v))}catch(w){h.apply(void 0,[w])}}g.extend({Deferred:function(u){var f=[["notify","progress",g.Callbacks("memory"),g.Callbacks("memory"),2],["resolve","done",g.Callbacks("once memory"),g.Callbacks("once memory"),0,"resolved"],["reject","fail",g.Callbacks("once memory"),g.Callbacks("once memory"),1,"rejected"]],h="pending",v={state:function(){return h},always:function(){return _.done(arguments).fail(arguments),this},catch:function(w){return v.then(null,w)},pipe:function(){var w=arguments;return g.Deferred(function(S){g.each(f,function(F,N){var W=k(w[N[4]])&&w[N[4]];_[N[1]](function(){var re=W&&W.apply(this,arguments);re&&k(re.promise)?re.promise().progress(S.notify).done(S.resolve).fail(S.reject):S[N[0]+"With"](this,W?[re]:arguments)})}),w=null}).promise()},then:function(w,S,F){var N=0;function W(re,ue,G,we){return function(){var it=this,yt=arguments,ft=function(){var an,jr;if(!(re<N)){if(an=G.apply(it,yt),an===ue.promise())throw new TypeError("Thenable self-resolution");jr=an&&(typeof an=="object"||typeof an=="function")&&an.then,k(jr)?we?jr.call(an,W(N,ue,R,we),W(N,ue,B,we)):(N++,jr.call(an,W(N,ue,R,we),W(N,ue,B,we),W(N,ue,R,ue.notifyWith))):(G!==R&&(it=void 0,yt=[an]),(we||ue.resolveWith)(it,yt))}},vn=we?ft:function(){try{ft()}catch(an){g.Deferred.exceptionHook&&g.Deferred.exceptionHook(an,vn.error),re+1>=N&&(G!==B&&(it=void 0,yt=[an]),ue.rejectWith(it,yt))}};re?vn():(g.Deferred.getErrorHook?vn.error=g.Deferred.getErrorHook():g.Deferred.getStackHook&&(vn.error=g.Deferred.getStackHook()),t.setTimeout(vn))}}return g.Deferred(function(re){f[0][3].add(W(0,re,k(F)?F:R,re.notifyWith)),f[1][3].add(W(0,re,k(w)?w:R)),f[2][3].add(W(0,re,k(S)?S:B))}).promise()},promise:function(w){return w!=null?g.extend(w,v):v}},_={};return g.each(f,function(w,S){var F=S[2],N=S[5];v[S[1]]=F.add,N&&F.add(function(){h=N},f[3-w][2].disable,f[3-w][3].disable,f[0][2].lock,f[0][3].lock),F.add(S[3].fire),_[S[0]]=function(){return _[S[0]+"With"](this===_?void 0:this,arguments),this},_[S[0]+"With"]=F.fireWith}),v.promise(_),u&&u.call(_,_),_},when:function(u){var f=arguments.length,h=f,v=Array(h),_=o.call(arguments),w=g.Deferred(),S=function(F){return function(N){v[F]=this,_[F]=arguments.length>1?o.call(arguments):N,--f||w.resolveWith(v,_)}};if(f<=1&&(Y(u,w.done(S(h)).resolve,w.reject,!f),w.state()==="pending"||k(_[h]&&_[h].then)))return w.then();for(;h--;)Y(_[h],S(h),w.reject);return w.promise()}});var oe=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;g.Deferred.exceptionHook=function(u,f){t.console&&t.console.warn&&u&&oe.test(u.name)&&t.console.warn("jQuery.Deferred exception: "+u.message,u.stack,f)},g.readyException=function(u){t.setTimeout(function(){throw u})};var ee=g.Deferred();g.fn.ready=function(u){return ee.then(u).catch(function(f){g.readyException(f)}),this},g.extend({isReady:!1,readyWait:1,ready:function(u){(u===!0?--g.readyWait:g.isReady)||(g.isReady=!0,!(u!==!0&&--g.readyWait>0)&&ee.resolveWith(O,[g]))}}),g.ready.then=ee.then;function te(){O.removeEventListener("DOMContentLoaded",te),t.removeEventListener("load",te),g.ready()}O.readyState==="complete"||O.readyState!=="loading"&&!O.documentElement.doScroll?t.setTimeout(g.ready):(O.addEventListener("DOMContentLoaded",te),t.addEventListener("load",te));var ve=function(u,f,h,v,_,w,S){var F=0,N=u.length,W=h==null;if(x(h)==="object"){_=!0;for(F in h)ve(u,f,F,h[F],!0,w,S)}else if(v!==void 0&&(_=!0,k(v)||(S=!0),W&&(S?(f.call(u,v),f=null):(W=f,f=function(re,ue,G){return W.call(g(re),G)})),f))for(;F<N;F++)f(u[F],h,S?v:v.call(u[F],F,f(u[F],h)));return _?u:W?f.call(u):N?f(u[0],h):w},me=/^-ms-/,be=/-([a-z])/g;function ce(u,f){return f.toUpperCase()}function Te(u){return u.replace(me,"ms-").replace(be,ce)}var _e=function(u){return u.nodeType===1||u.nodeType===9||!+u.nodeType};function Ne(){this.expando=g.expando+Ne.uid++}Ne.uid=1,Ne.prototype={cache:function(u){var f=u[this.expando];return f||(f={},_e(u)&&(u.nodeType?u[this.expando]=f:Object.defineProperty(u,this.expando,{value:f,configurable:!0}))),f},set:function(u,f,h){var v,_=this.cache(u);if(typeof f=="string")_[Te(f)]=h;else for(v in f)_[Te(v)]=f[v];return _},get:function(u,f){return f===void 0?this.cache(u):u[this.expando]&&u[this.expando][Te(f)]},access:function(u,f,h){return f===void 0||f&&typeof f=="string"&&h===void 0?this.get(u,f):(this.set(u,f,h),h!==void 0?h:f)},remove:function(u,f){var h,v=u[this.expando];if(v!==void 0){if(f!==void 0)for(Array.isArray(f)?f=f.map(Te):(f=Te(f),f=f in v?[f]:f.match(Ve)||[]),h=f.length;h--;)delete v[f[h]];(f===void 0||g.isEmptyObject(v))&&(u.nodeType?u[this.expando]=void 0:delete u[this.expando])}},hasData:function(u){var f=u[this.expando];return f!==void 0&&!g.isEmptyObject(f)}};var ne=new Ne,$e=new Ne,at=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,lt=/[A-Z]/g;function Tt(u){return u==="true"?!0:u==="false"?!1:u==="null"?null:u===+u+""?+u:at.test(u)?JSON.parse(u):u}function Nt(u,f,h){var v;if(h===void 0&&u.nodeType===1)if(v="data-"+f.replace(lt,"-$&").toLowerCase(),h=u.getAttribute(v),typeof h=="string"){try{h=Tt(h)}catch{}$e.set(u,f,h)}else h=void 0;return h}g.extend({hasData:function(u){return $e.hasData(u)||ne.hasData(u)},data:function(u,f,h){return $e.access(u,f,h)},removeData:function(u,f){$e.remove(u,f)},_data:function(u,f,h){return ne.access(u,f,h)},_removeData:function(u,f){ne.remove(u,f)}}),g.fn.extend({data:function(u,f){var h,v,_,w=this[0],S=w&&w.attributes;if(u===void 0){if(this.length&&(_=$e.get(w),w.nodeType===1&&!ne.get(w,"hasDataAttrs"))){for(h=S.length;h--;)S[h]&&(v=S[h].name,v.indexOf("data-")===0&&(v=Te(v.slice(5)),Nt(w,v,_[v])));ne.set(w,"hasDataAttrs",!0)}return _}return typeof u=="object"?this.each(function(){$e.set(this,u)}):ve(this,function(F){var N;if(w&&F===void 0)return N=$e.get(w,u),N!==void 0||(N=Nt(w,u),N!==void 0)?N:void 0;this.each(function(){$e.set(this,u,F)})},null,f,arguments.length>1,null,!0)},removeData:function(u){return this.each(function(){$e.remove(this,u)})}}),g.extend({queue:function(u,f,h){var v;if(u)return f=(f||"fx")+"queue",v=ne.get(u,f),h&&(!v||Array.isArray(h)?v=ne.access(u,f,g.makeArray(h)):v.push(h)),v||[]},dequeue:function(u,f){f=f||"fx";var h=g.queue(u,f),v=h.length,_=h.shift(),w=g._queueHooks(u,f),S=function(){g.dequeue(u,f)};_==="inprogress"&&(_=h.shift(),v--),_&&(f==="fx"&&h.unshift("inprogress"),delete w.stop,_.call(u,S,w)),!v&&w&&w.empty.fire()},_queueHooks:function(u,f){var h=f+"queueHooks";return ne.get(u,h)||ne.access(u,h,{empty:g.Callbacks("once memory").add(function(){ne.remove(u,[f+"queue",h])})})}}),g.fn.extend({queue:function(u,f){var h=2;return typeof u!="string"&&(f=u,u="fx",h--),arguments.length<h?g.queue(this[0],u):f===void 0?this:this.each(function(){var v=g.queue(this,u,f);g._queueHooks(this,u),u==="fx"&&v[0]!=="inprogress"&&g.dequeue(this,u)})},dequeue:function(u){return this.each(function(){g.dequeue(this,u)})},clearQueue:function(u){return this.queue(u||"fx",[])},promise:function(u,f){var h,v=1,_=g.Deferred(),w=this,S=this.length,F=function(){--v||_.resolveWith(w,[w])};for(typeof u!="string"&&(f=u,u=void 0),u=u||"fx";S--;)h=ne.get(w[S],u+"queueHooks"),h&&h.empty&&(v++,h.empty.add(F));return F(),_.promise(f)}});var en=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,$t=new RegExp("^(?:([+-])=|)("+en+")([a-z%]*)$","i"),Vt=["Top","Right","Bottom","Left"],J=O.documentElement,Se=function(u){return g.contains(u.ownerDocument,u)},He={composed:!0};J.getRootNode&&(Se=function(u){return g.contains(u.ownerDocument,u)||u.getRootNode(He)===u.ownerDocument});var pt=function(u,f){return u=f||u,u.style.display==="none"||u.style.display===""&&Se(u)&&g.css(u,"display")==="none"};function mt(u,f,h,v){var _,w,S=20,F=v?function(){return v.cur()}:function(){return g.css(u,f,"")},N=F(),W=h&&h[3]||(g.cssNumber[f]?"":"px"),re=u.nodeType&&(g.cssNumber[f]||W!=="px"&&+N)&&$t.exec(g.css(u,f));if(re&&re[3]!==W){for(N=N/2,W=W||re[3],re=+N||1;S--;)g.style(u,f,re+W),(1-w)*(1-(w=F()/N||.5))<=0&&(S=0),re=re/w;re=re*2,g.style(u,f,re+W),h=h||[]}return h&&(re=+re||+N||0,_=h[1]?re+(h[1]+1)*h[2]:+h[2],v&&(v.unit=W,v.start=re,v.end=_)),_}var fn={};function jn(u){var f,h=u.ownerDocument,v=u.nodeName,_=fn[v];return _||(f=h.body.appendChild(h.createElement(v)),_=g.css(f,"display"),f.parentNode.removeChild(f),_==="none"&&(_="block"),fn[v]=_,_)}function er(u,f){for(var h,v,_=[],w=0,S=u.length;w<S;w++)v=u[w],v.style&&(h=v.style.display,f?(h==="none"&&(_[w]=ne.get(v,"display")||null,_[w]||(v.style.display="")),v.style.display===""&&pt(v)&&(_[w]=jn(v))):h!=="none"&&(_[w]="none",ne.set(v,"display",h)));for(w=0;w<S;w++)_[w]!=null&&(u[w].style.display=_[w]);return u}g.fn.extend({show:function(){return er(this,!0)},hide:function(){return er(this)},toggle:function(u){return typeof u=="boolean"?u?this.show():this.hide():this.each(function(){pt(this)?g(this).show():g(this).hide()})}});var Li=/^(?:checkbox|radio)$/i,Hr=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,hs=/^$|^module$|\/(?:java|ecma)script/i;(function(){var u=O.createDocumentFragment(),f=u.appendChild(O.createElement("div")),h=O.createElement("input");h.setAttribute("type","radio"),h.setAttribute("checked","checked"),h.setAttribute("name","t"),f.appendChild(h),b.checkClone=f.cloneNode(!0).cloneNode(!0).lastChild.checked,f.innerHTML="<textarea>x</textarea>",b.noCloneChecked=!!f.cloneNode(!0).lastChild.defaultValue,f.innerHTML="<option></option>",b.option=!!f.lastChild})();var mn={thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};mn.tbody=mn.tfoot=mn.colgroup=mn.caption=mn.thead,mn.th=mn.td,b.option||(mn.optgroup=mn.option=[1,"<select multiple='multiple'>","</select>"]);function Gt(u,f){var h;return typeof u.getElementsByTagName<"u"?h=u.getElementsByTagName(f||"*"):typeof u.querySelectorAll<"u"?h=u.querySelectorAll(f||"*"):h=[],f===void 0||f&&A(u,f)?g.merge([u],h):h}function Ra(u,f){for(var h=0,v=u.length;h<v;h++)ne.set(u[h],"globalEval",!f||ne.get(f[h],"globalEval"))}var Na=/<|&#?\w+;/;function ao(u,f,h,v,_){for(var w,S,F,N,W,re,ue=f.createDocumentFragment(),G=[],we=0,it=u.length;we<it;we++)if(w=u[we],w||w===0)if(x(w)==="object")g.merge(G,w.nodeType?[w]:w);else if(!Na.test(w))G.push(f.createTextNode(w));else{for(S=S||ue.appendChild(f.createElement("div")),F=(Hr.exec(w)||["",""])[1].toLowerCase(),N=mn[F]||mn._default,S.innerHTML=N[1]+g.htmlPrefilter(w)+N[2],re=N[0];re--;)S=S.lastChild;g.merge(G,S.childNodes),S=ue.firstChild,S.textContent=""}for(ue.textContent="",we=0;w=G[we++];){if(v&&g.inArray(w,v)>-1){_&&_.push(w);continue}if(W=Se(w),S=Gt(ue.appendChild(w),"script"),W&&Ra(S),h)for(re=0;w=S[re++];)hs.test(w.type||"")&&h.push(w)}return ue}var _b=/^([^.]*)(?:\.(.+)|)/;function gs(){return!0}function ms(){return!1}function rp(u,f,h,v,_,w){var S,F;if(typeof f=="object"){typeof h!="string"&&(v=v||h,h=void 0);for(F in f)rp(u,F,h,v,f[F],w);return u}if(v==null&&_==null?(_=h,v=h=void 0):_==null&&(typeof h=="string"?(_=v,v=void 0):(_=v,v=h,h=void 0)),_===!1)_=ms;else if(!_)return u;return w===1&&(S=_,_=function(N){return g().off(N),S.apply(this,arguments)},_.guid=S.guid||(S.guid=g.guid++)),u.each(function(){g.event.add(this,f,_,v,h)})}g.event={global:{},add:function(u,f,h,v,_){var w,S,F,N,W,re,ue,G,we,it,yt,ft=ne.get(u);if(_e(u))for(h.handler&&(w=h,h=w.handler,_=w.selector),_&&g.find.matchesSelector(J,_),h.guid||(h.guid=g.guid++),(N=ft.events)||(N=ft.events=Object.create(null)),(S=ft.handle)||(S=ft.handle=function(vn){return typeof g<"u"&&g.event.triggered!==vn.type?g.event.dispatch.apply(u,arguments):void 0}),f=(f||"").match(Ve)||[""],W=f.length;W--;)F=_b.exec(f[W])||[],we=yt=F[1],it=(F[2]||"").split(".").sort(),we&&(ue=g.event.special[we]||{},we=(_?ue.delegateType:ue.bindType)||we,ue=g.event.special[we]||{},re=g.extend({type:we,origType:yt,data:v,handler:h,guid:h.guid,selector:_,needsContext:_&&g.expr.match.needsContext.test(_),namespace:it.join(".")},w),(G=N[we])||(G=N[we]=[],G.delegateCount=0,(!ue.setup||ue.setup.call(u,v,it,S)===!1)&&u.addEventListener&&u.addEventListener(we,S)),ue.add&&(ue.add.call(u,re),re.handler.guid||(re.handler.guid=h.guid)),_?G.splice(G.delegateCount++,0,re):G.push(re),g.event.global[we]=!0)},remove:function(u,f,h,v,_){var w,S,F,N,W,re,ue,G,we,it,yt,ft=ne.hasData(u)&&ne.get(u);if(!(!ft||!(N=ft.events))){for(f=(f||"").match(Ve)||[""],W=f.length;W--;){if(F=_b.exec(f[W])||[],we=yt=F[1],it=(F[2]||"").split(".").sort(),!we){for(we in N)g.event.remove(u,we+f[W],h,v,!0);continue}for(ue=g.event.special[we]||{},we=(v?ue.delegateType:ue.bindType)||we,G=N[we]||[],F=F[2]&&new RegExp("(^|\\.)"+it.join("\\.(?:.*\\.|)")+"(\\.|$)"),S=w=G.length;w--;)re=G[w],(_||yt===re.origType)&&(!h||h.guid===re.guid)&&(!F||F.test(re.namespace))&&(!v||v===re.selector||v==="**"&&re.selector)&&(G.splice(w,1),re.selector&&G.delegateCount--,ue.remove&&ue.remove.call(u,re));S&&!G.length&&((!ue.teardown||ue.teardown.call(u,it,ft.handle)===!1)&&g.removeEvent(u,we,ft.handle),delete N[we])}g.isEmptyObject(N)&&ne.remove(u,"handle events")}},dispatch:function(u){var f,h,v,_,w,S,F=new Array(arguments.length),N=g.event.fix(u),W=(ne.get(this,"events")||Object.create(null))[N.type]||[],re=g.event.special[N.type]||{};for(F[0]=N,f=1;f<arguments.length;f++)F[f]=arguments[f];if(N.delegateTarget=this,!(re.preDispatch&&re.preDispatch.call(this,N)===!1)){for(S=g.event.handlers.call(this,N,W),f=0;(_=S[f++])&&!N.isPropagationStopped();)for(N.currentTarget=_.elem,h=0;(w=_.handlers[h++])&&!N.isImmediatePropagationStopped();)(!N.rnamespace||w.namespace===!1||N.rnamespace.test(w.namespace))&&(N.handleObj=w,N.data=w.data,v=((g.event.special[w.origType]||{}).handle||w.handler).apply(_.elem,F),v!==void 0&&(N.result=v)===!1&&(N.preventDefault(),N.stopPropagation()));return re.postDispatch&&re.postDispatch.call(this,N),N.result}},handlers:function(u,f){var h,v,_,w,S,F=[],N=f.delegateCount,W=u.target;if(N&&W.nodeType&&!(u.type==="click"&&u.button>=1)){for(;W!==this;W=W.parentNode||this)if(W.nodeType===1&&!(u.type==="click"&&W.disabled===!0)){for(w=[],S={},h=0;h<N;h++)v=f[h],_=v.selector+" ",S[_]===void 0&&(S[_]=v.needsContext?g(_,this).index(W)>-1:g.find(_,this,null,[W]).length),S[_]&&w.push(v);w.length&&F.push({elem:W,handlers:w})}}return W=this,N<f.length&&F.push({elem:W,handlers:f.slice(N)}),F},addProp:function(u,f){Object.defineProperty(g.Event.prototype,u,{enumerable:!0,configurable:!0,get:k(f)?function(){if(this.originalEvent)return f(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[u]},set:function(h){Object.defineProperty(this,u,{enumerable:!0,configurable:!0,writable:!0,value:h})}})},fix:function(u){return u[g.expando]?u:new g.Event(u)},special:{load:{noBubble:!0},click:{setup:function(u){var f=this||u;return Li.test(f.type)&&f.click&&A(f,"input")&&Bu(f,"click",!0),!1},trigger:function(u){var f=this||u;return Li.test(f.type)&&f.click&&A(f,"input")&&Bu(f,"click"),!0},_default:function(u){var f=u.target;return Li.test(f.type)&&f.click&&A(f,"input")&&ne.get(f,"click")||A(f,"a")}},beforeunload:{postDispatch:function(u){u.result!==void 0&&u.originalEvent&&(u.originalEvent.returnValue=u.result)}}}};function Bu(u,f,h){if(!h){ne.get(u,f)===void 0&&g.event.add(u,f,gs);return}ne.set(u,f,!1),g.event.add(u,f,{namespace:!1,handler:function(v){var _,w=ne.get(this,f);if(v.isTrigger&1&&this[f]){if(w)(g.event.special[f]||{}).delegateType&&v.stopPropagation();else if(w=o.call(arguments),ne.set(this,f,w),this[f](),_=ne.get(this,f),ne.set(this,f,!1),w!==_)return v.stopImmediatePropagation(),v.preventDefault(),_}else w&&(ne.set(this,f,g.event.trigger(w[0],w.slice(1),this)),v.stopPropagation(),v.isImmediatePropagationStopped=gs)}})}g.removeEvent=function(u,f,h){u.removeEventListener&&u.removeEventListener(f,h)},g.Event=function(u,f){if(!(this instanceof g.Event))return new g.Event(u,f);u&&u.type?(this.originalEvent=u,this.type=u.type,this.isDefaultPrevented=u.defaultPrevented||u.defaultPrevented===void 0&&u.returnValue===!1?gs:ms,this.target=u.target&&u.target.nodeType===3?u.target.parentNode:u.target,this.currentTarget=u.currentTarget,this.relatedTarget=u.relatedTarget):this.type=u,f&&g.extend(this,f),this.timeStamp=u&&u.timeStamp||Date.now(),this[g.expando]=!0},g.Event.prototype={constructor:g.Event,isDefaultPrevented:ms,isPropagationStopped:ms,isImmediatePropagationStopped:ms,isSimulated:!1,preventDefault:function(){var u=this.originalEvent;this.isDefaultPrevented=gs,u&&!this.isSimulated&&u.preventDefault()},stopPropagation:function(){var u=this.originalEvent;this.isPropagationStopped=gs,u&&!this.isSimulated&&u.stopPropagation()},stopImmediatePropagation:function(){var u=this.originalEvent;this.isImmediatePropagationStopped=gs,u&&!this.isSimulated&&u.stopImmediatePropagation(),this.stopPropagation()}},g.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,char:!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:!0},g.event.addProp),g.each({focus:"focusin",blur:"focusout"},function(u,f){function h(v){if(O.documentMode){var _=ne.get(this,"handle"),w=g.event.fix(v);w.type=v.type==="focusin"?"focus":"blur",w.isSimulated=!0,_(v),w.target===w.currentTarget&&_(w)}else g.event.simulate(f,v.target,g.event.fix(v))}g.event.special[u]={setup:function(){var v;if(Bu(this,u,!0),O.documentMode)v=ne.get(this,f),v||this.addEventListener(f,h),ne.set(this,f,(v||0)+1);else return!1},trigger:function(){return Bu(this,u),!0},teardown:function(){var v;if(O.documentMode)v=ne.get(this,f)-1,v?ne.set(this,f,v):(this.removeEventListener(f,h),ne.remove(this,f));else return!1},_default:function(v){return ne.get(v.target,u)},delegateType:f},g.event.special[f]={setup:function(){var v=this.ownerDocument||this.document||this,_=O.documentMode?this:v,w=ne.get(_,f);w||(O.documentMode?this.addEventListener(f,h):v.addEventListener(u,h,!0)),ne.set(_,f,(w||0)+1)},teardown:function(){var v=this.ownerDocument||this.document||this,_=O.documentMode?this:v,w=ne.get(_,f)-1;w?ne.set(_,f,w):(O.documentMode?this.removeEventListener(f,h):v.removeEventListener(u,h,!0),ne.remove(_,f))}}}),g.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(u,f){g.event.special[u]={delegateType:f,bindType:f,handle:function(h){var v,_=this,w=h.relatedTarget,S=h.handleObj;return(!w||w!==_&&!g.contains(_,w))&&(h.type=S.origType,v=S.handler.apply(this,arguments),h.type=f),v}}}),g.fn.extend({on:function(u,f,h,v){return rp(this,u,f,h,v)},one:function(u,f,h,v){return rp(this,u,f,h,v,1)},off:function(u,f,h){var v,_;if(u&&u.preventDefault&&u.handleObj)return v=u.handleObj,g(u.delegateTarget).off(v.namespace?v.origType+"."+v.namespace:v.origType,v.selector,v.handler),this;if(typeof u=="object"){for(_ in u)this.off(_,f,u[_]);return this}return(f===!1||typeof f=="function")&&(h=f,f=void 0),h===!1&&(h=ms),this.each(function(){g.event.remove(this,u,h,f)})}});var n3=/<script|<style|<link/i,r3=/checked\s*(?:[^=]|=\s*.checked.)/i,i3=/^\s*<!\[CDATA\[|\]\]>\s*$/g;function wb(u,f){return A(u,"table")&&A(f.nodeType!==11?f:f.firstChild,"tr")&&g(u).children("tbody")[0]||u}function o3(u){return u.type=(u.getAttribute("type")!==null)+"/"+u.type,u}function s3(u){return(u.type||"").slice(0,5)==="true/"?u.type=u.type.slice(5):u.removeAttribute("type"),u}function Tb(u,f){var h,v,_,w,S,F,N;if(f.nodeType===1){if(ne.hasData(u)&&(w=ne.get(u),N=w.events,N)){ne.remove(f,"handle events");for(_ in N)for(h=0,v=N[_].length;h<v;h++)g.event.add(f,_,N[_][h])}$e.hasData(u)&&(S=$e.access(u),F=g.extend({},S),$e.set(f,F))}}function a3(u,f){var h=f.nodeName.toLowerCase();h==="input"&&Li.test(u.type)?f.checked=u.checked:(h==="input"||h==="textarea")&&(f.defaultValue=u.defaultValue)}function vs(u,f,h,v){f=s(f);var _,w,S,F,N,W,re=0,ue=u.length,G=ue-1,we=f[0],it=k(we);if(it||ue>1&&typeof we=="string"&&!b.checkClone&&r3.test(we))return u.each(function(yt){var ft=u.eq(yt);it&&(f[0]=we.call(this,yt,ft.html())),vs(ft,f,h,v)});if(ue&&(_=ao(f,u[0].ownerDocument,!1,u,v),w=_.firstChild,_.childNodes.length===1&&(_=w),w||v)){for(S=g.map(Gt(_,"script"),o3),F=S.length;re<ue;re++)N=_,re!==G&&(N=g.clone(N,!0,!0),F&&g.merge(S,Gt(N,"script"))),h.call(u[re],N,re);if(F)for(W=S[S.length-1].ownerDocument,g.map(S,s3),re=0;re<F;re++)N=S[re],hs.test(N.type||"")&&!ne.access(N,"globalEval")&&g.contains(W,N)&&(N.src&&(N.type||"").toLowerCase()!=="module"?g._evalUrl&&!N.noModule&&g._evalUrl(N.src,{nonce:N.nonce||N.getAttribute("nonce")},W):X(N.textContent.replace(i3,""),N,W))}return u}function kb(u,f,h){for(var v,_=f?g.filter(f,u):u,w=0;(v=_[w])!=null;w++)!h&&v.nodeType===1&&g.cleanData(Gt(v)),v.parentNode&&(h&&Se(v)&&Ra(Gt(v,"script")),v.parentNode.removeChild(v));return u}g.extend({htmlPrefilter:function(u){return u},clone:function(u,f,h){var v,_,w,S,F=u.cloneNode(!0),N=Se(u);if(!b.noCloneChecked&&(u.nodeType===1||u.nodeType===11)&&!g.isXMLDoc(u))for(S=Gt(F),w=Gt(u),v=0,_=w.length;v<_;v++)a3(w[v],S[v]);if(f)if(h)for(w=w||Gt(u),S=S||Gt(F),v=0,_=w.length;v<_;v++)Tb(w[v],S[v]);else Tb(u,F);return S=Gt(F,"script"),S.length>0&&Ra(S,!N&&Gt(u,"script")),F},cleanData:function(u){for(var f,h,v,_=g.event.special,w=0;(h=u[w])!==void 0;w++)if(_e(h)){if(f=h[ne.expando]){if(f.events)for(v in f.events)_[v]?g.event.remove(h,v):g.removeEvent(h,v,f.handle);h[ne.expando]=void 0}h[$e.expando]&&(h[$e.expando]=void 0)}}}),g.fn.extend({detach:function(u){return kb(this,u,!0)},remove:function(u){return kb(this,u)},text:function(u){return ve(this,function(f){return f===void 0?g.text(this):this.empty().each(function(){(this.nodeType===1||this.nodeType===11||this.nodeType===9)&&(this.textContent=f)})},null,u,arguments.length)},append:function(){return vs(this,arguments,function(u){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var f=wb(this,u);f.appendChild(u)}})},prepend:function(){return vs(this,arguments,function(u){if(this.nodeType===1||this.nodeType===11||this.nodeType===9){var f=wb(this,u);f.insertBefore(u,f.firstChild)}})},before:function(){return vs(this,arguments,function(u){this.parentNode&&this.parentNode.insertBefore(u,this)})},after:function(){return vs(this,arguments,function(u){this.parentNode&&this.parentNode.insertBefore(u,this.nextSibling)})},empty:function(){for(var u,f=0;(u=this[f])!=null;f++)u.nodeType===1&&(g.cleanData(Gt(u,!1)),u.textContent="");return this},clone:function(u,f){return u=u??!1,f=f??u,this.map(function(){return g.clone(this,u,f)})},html:function(u){return ve(this,function(f){var h=this[0]||{},v=0,_=this.length;if(f===void 0&&h.nodeType===1)return h.innerHTML;if(typeof f=="string"&&!n3.test(f)&&!mn[(Hr.exec(f)||["",""])[1].toLowerCase()]){f=g.htmlPrefilter(f);try{for(;v<_;v++)h=this[v]||{},h.nodeType===1&&(g.cleanData(Gt(h,!1)),h.innerHTML=f);h=0}catch{}}h&&this.empty().append(f)},null,u,arguments.length)},replaceWith:function(){var u=[];return vs(this,arguments,function(f){var h=this.parentNode;g.inArray(this,u)<0&&(g.cleanData(Gt(this)),h&&h.replaceChild(f,this))},u)}}),g.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(u,f){g.fn[u]=function(h){for(var v,_=[],w=g(h),S=w.length-1,F=0;F<=S;F++)v=F===S?this:this.clone(!0),g(w[F])[f](v),l.apply(_,v.get());return this.pushStack(_)}});var ip=new RegExp("^("+en+")(?!px)[a-z%]+$","i"),op=/^--/,$u=function(u){var f=u.ownerDocument.defaultView;return(!f||!f.opener)&&(f=t),f.getComputedStyle(u)},xb=function(u,f,h){var v,_,w={};for(_ in f)w[_]=u.style[_],u.style[_]=f[_];v=h.call(u);for(_ in f)u.style[_]=w[_];return v},l3=new RegExp(Vt.join("|"),"i");(function(){function u(){if(W){N.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",W.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",J.appendChild(N).appendChild(W);var re=t.getComputedStyle(W);h=re.top!=="1%",F=f(re.marginLeft)===12,W.style.right="60%",w=f(re.right)===36,v=f(re.width)===36,W.style.position="absolute",_=f(W.offsetWidth/3)===12,J.removeChild(N),W=null}}function f(re){return Math.round(parseFloat(re))}var h,v,_,w,S,F,N=O.createElement("div"),W=O.createElement("div");W.style&&(W.style.backgroundClip="content-box",W.cloneNode(!0).style.backgroundClip="",b.clearCloneStyle=W.style.backgroundClip==="content-box",g.extend(b,{boxSizingReliable:function(){return u(),v},pixelBoxStyles:function(){return u(),w},pixelPosition:function(){return u(),h},reliableMarginLeft:function(){return u(),F},scrollboxSize:function(){return u(),_},reliableTrDimensions:function(){var re,ue,G,we;return S==null&&(re=O.createElement("table"),ue=O.createElement("tr"),G=O.createElement("div"),re.style.cssText="position:absolute;left:-11111px;border-collapse:separate",ue.style.cssText="box-sizing:content-box;border:1px solid",ue.style.height="1px",G.style.height="9px",G.style.display="block",J.appendChild(re).appendChild(ue).appendChild(G),we=t.getComputedStyle(ue),S=parseInt(we.height,10)+parseInt(we.borderTopWidth,10)+parseInt(we.borderBottomWidth,10)===ue.offsetHeight,J.removeChild(re)),S}}))})();function Ma(u,f,h){var v,_,w,S,F=op.test(f),N=u.style;return h=h||$u(u),h&&(S=h.getPropertyValue(f)||h[f],F&&S&&(S=S.replace(de,"$1")||void 0),S===""&&!Se(u)&&(S=g.style(u,f)),!b.pixelBoxStyles()&&ip.test(S)&&l3.test(f)&&(v=N.width,_=N.minWidth,w=N.maxWidth,N.minWidth=N.maxWidth=N.width=S,S=h.width,N.width=v,N.minWidth=_,N.maxWidth=w)),S!==void 0?S+"":S}function Sb(u,f){return{get:function(){if(u()){delete this.get;return}return(this.get=f).apply(this,arguments)}}}var Ab=["Webkit","Moz","ms"],Eb=O.createElement("div").style,Lb={};function u3(u){for(var f=u[0].toUpperCase()+u.slice(1),h=Ab.length;h--;)if(u=Ab[h]+f,u in Eb)return u}function sp(u){var f=g.cssProps[u]||Lb[u];return f||(u in Eb?u:Lb[u]=u3(u)||u)}var c3=/^(none|table(?!-c[ea]).+)/,f3={position:"absolute",visibility:"hidden",display:"block"},Ob={letterSpacing:"0",fontWeight:"400"};function Ib(u,f,h){var v=$t.exec(f);return v?Math.max(0,v[2]-(h||0))+(v[3]||"px"):f}function ap(u,f,h,v,_,w){var S=f==="width"?1:0,F=0,N=0,W=0;if(h===(v?"border":"content"))return 0;for(;S<4;S+=2)h==="margin"&&(W+=g.css(u,h+Vt[S],!0,_)),v?(h==="content"&&(N-=g.css(u,"padding"+Vt[S],!0,_)),h!=="margin"&&(N-=g.css(u,"border"+Vt[S]+"Width",!0,_))):(N+=g.css(u,"padding"+Vt[S],!0,_),h!=="padding"?N+=g.css(u,"border"+Vt[S]+"Width",!0,_):F+=g.css(u,"border"+Vt[S]+"Width",!0,_));return!v&&w>=0&&(N+=Math.max(0,Math.ceil(u["offset"+f[0].toUpperCase()+f.slice(1)]-w-N-F-.5))||0),N+W}function Pb(u,f,h){var v=$u(u),_=!b.boxSizingReliable()||h,w=_&&g.css(u,"boxSizing",!1,v)==="border-box",S=w,F=Ma(u,f,v),N="offset"+f[0].toUpperCase()+f.slice(1);if(ip.test(F)){if(!h)return F;F="auto"}return(!b.boxSizingReliable()&&w||!b.reliableTrDimensions()&&A(u,"tr")||F==="auto"||!parseFloat(F)&&g.css(u,"display",!1,v)==="inline")&&u.getClientRects().length&&(w=g.css(u,"boxSizing",!1,v)==="border-box",S=N in u,S&&(F=u[N])),F=parseFloat(F)||0,F+ap(u,f,h||(w?"border":"content"),S,v,F)+"px"}g.extend({cssHooks:{opacity:{get:function(u,f){if(f){var h=Ma(u,"opacity");return h===""?"1":h}}}},cssNumber:{animationIterationCount:!0,aspectRatio:!0,borderImageSlice:!0,columnCount:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,scale:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeMiterlimit:!0,strokeOpacity:!0},cssProps:{},style:function(u,f,h,v){if(!(!u||u.nodeType===3||u.nodeType===8||!u.style)){var _,w,S,F=Te(f),N=op.test(f),W=u.style;if(N||(f=sp(F)),S=g.cssHooks[f]||g.cssHooks[F],h!==void 0){if(w=typeof h,w==="string"&&(_=$t.exec(h))&&_[1]&&(h=mt(u,f,_),w="number"),h==null||h!==h)return;w==="number"&&!N&&(h+=_&&_[3]||(g.cssNumber[F]?"":"px")),!b.clearCloneStyle&&h===""&&f.indexOf("background")===0&&(W[f]="inherit"),(!S||!("set"in S)||(h=S.set(u,h,v))!==void 0)&&(N?W.setProperty(f,h):W[f]=h)}else return S&&"get"in S&&(_=S.get(u,!1,v))!==void 0?_:W[f]}},css:function(u,f,h,v){var _,w,S,F=Te(f),N=op.test(f);return N||(f=sp(F)),S=g.cssHooks[f]||g.cssHooks[F],S&&"get"in S&&(_=S.get(u,!0,h)),_===void 0&&(_=Ma(u,f,v)),_==="normal"&&f in Ob&&(_=Ob[f]),h===""||h?(w=parseFloat(_),h===!0||isFinite(w)?w||0:_):_}}),g.each(["height","width"],function(u,f){g.cssHooks[f]={get:function(h,v,_){if(v)return c3.test(g.css(h,"display"))&&(!h.getClientRects().length||!h.getBoundingClientRect().width)?xb(h,f3,function(){return Pb(h,f,_)}):Pb(h,f,_)},set:function(h,v,_){var w,S=$u(h),F=!b.scrollboxSize()&&S.position==="absolute",N=F||_,W=N&&g.css(h,"boxSizing",!1,S)==="border-box",re=_?ap(h,f,_,W,S):0;return W&&F&&(re-=Math.ceil(h["offset"+f[0].toUpperCase()+f.slice(1)]-parseFloat(S[f])-ap(h,f,"border",!1,S)-.5)),re&&(w=$t.exec(v))&&(w[3]||"px")!=="px"&&(h.style[f]=v,v=g.css(h,f)),Ib(h,v,re)}}}),g.cssHooks.marginLeft=Sb(b.reliableMarginLeft,function(u,f){if(f)return(parseFloat(Ma(u,"marginLeft"))||u.getBoundingClientRect().left-xb(u,{marginLeft:0},function(){return u.getBoundingClientRect().left}))+"px"}),g.each({margin:"",padding:"",border:"Width"},function(u,f){g.cssHooks[u+f]={expand:function(h){for(var v=0,_={},w=typeof h=="string"?h.split(" "):[h];v<4;v++)_[u+Vt[v]+f]=w[v]||w[v-2]||w[0];return _}},u!=="margin"&&(g.cssHooks[u+f].set=Ib)}),g.fn.extend({css:function(u,f){return ve(this,function(h,v,_){var w,S,F={},N=0;if(Array.isArray(v)){for(w=$u(h),S=v.length;N<S;N++)F[v[N]]=g.css(h,v[N],!1,w);return F}return _!==void 0?g.style(h,v,_):g.css(h,v)},u,f,arguments.length>1)}});function Un(u,f,h,v,_){return new Un.prototype.init(u,f,h,v,_)}g.Tween=Un,Un.prototype={constructor:Un,init:function(u,f,h,v,_,w){this.elem=u,this.prop=h,this.easing=_||g.easing._default,this.options=f,this.start=this.now=this.cur(),this.end=v,this.unit=w||(g.cssNumber[h]?"":"px")},cur:function(){var u=Un.propHooks[this.prop];return u&&u.get?u.get(this):Un.propHooks._default.get(this)},run:function(u){var f,h=Un.propHooks[this.prop];return this.options.duration?this.pos=f=g.easing[this.easing](u,this.options.duration*u,0,1,this.options.duration):this.pos=f=u,this.now=(this.end-this.start)*f+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),h&&h.set?h.set(this):Un.propHooks._default.set(this),this}},Un.prototype.init.prototype=Un.prototype,Un.propHooks={_default:{get:function(u){var f;return u.elem.nodeType!==1||u.elem[u.prop]!=null&&u.elem.style[u.prop]==null?u.elem[u.prop]:(f=g.css(u.elem,u.prop,""),!f||f==="auto"?0:f)},set:function(u){g.fx.step[u.prop]?g.fx.step[u.prop](u):u.elem.nodeType===1&&(g.cssHooks[u.prop]||u.elem.style[sp(u.prop)]!=null)?g.style(u.elem,u.prop,u.now+u.unit):u.elem[u.prop]=u.now}}},Un.propHooks.scrollTop=Un.propHooks.scrollLeft={set:function(u){u.elem.nodeType&&u.elem.parentNode&&(u.elem[u.prop]=u.now)}},g.easing={linear:function(u){return u},swing:function(u){return .5-Math.cos(u*Math.PI)/2},_default:"swing"},g.fx=Un.prototype.init,g.fx.step={};var ys,Hu,d3=/^(?:toggle|show|hide)$/,p3=/queueHooks$/;function lp(){Hu&&(O.hidden===!1&&t.requestAnimationFrame?t.requestAnimationFrame(lp):t.setTimeout(lp,g.fx.interval),g.fx.tick())}function Db(){return t.setTimeout(function(){ys=void 0}),ys=Date.now()}function ju(u,f){var h,v=0,_={height:u};for(f=f?1:0;v<4;v+=2-f)h=Vt[v],_["margin"+h]=_["padding"+h]=u;return f&&(_.opacity=_.width=u),_}function Rb(u,f,h){for(var v,_=(xr.tweeners[f]||[]).concat(xr.tweeners["*"]),w=0,S=_.length;w<S;w++)if(v=_[w].call(h,f,u))return v}function h3(u,f,h){var v,_,w,S,F,N,W,re,ue="width"in f||"height"in f,G=this,we={},it=u.style,yt=u.nodeType&&pt(u),ft=ne.get(u,"fxshow");h.queue||(S=g._queueHooks(u,"fx"),S.unqueued==null&&(S.unqueued=0,F=S.empty.fire,S.empty.fire=function(){S.unqueued||F()}),S.unqueued++,G.always(function(){G.always(function(){S.unqueued--,g.queue(u,"fx").length||S.empty.fire()})}));for(v in f)if(_=f[v],d3.test(_)){if(delete f[v],w=w||_==="toggle",_===(yt?"hide":"show"))if(_==="show"&&ft&&ft[v]!==void 0)yt=!0;else continue;we[v]=ft&&ft[v]||g.style(u,v)}if(N=!g.isEmptyObject(f),!(!N&&g.isEmptyObject(we))){ue&&u.nodeType===1&&(h.overflow=[it.overflow,it.overflowX,it.overflowY],W=ft&&ft.display,W==null&&(W=ne.get(u,"display")),re=g.css(u,"display"),re==="none"&&(W?re=W:(er([u],!0),W=u.style.display||W,re=g.css(u,"display"),er([u]))),(re==="inline"||re==="inline-block"&&W!=null)&&g.css(u,"float")==="none"&&(N||(G.done(function(){it.display=W}),W==null&&(re=it.display,W=re==="none"?"":re)),it.display="inline-block")),h.overflow&&(it.overflow="hidden",G.always(function(){it.overflow=h.overflow[0],it.overflowX=h.overflow[1],it.overflowY=h.overflow[2]})),N=!1;for(v in we)N||(ft?"hidden"in ft&&(yt=ft.hidden):ft=ne.access(u,"fxshow",{display:W}),w&&(ft.hidden=!yt),yt&&er([u],!0),G.done(function(){yt||er([u]),ne.remove(u,"fxshow");for(v in we)g.style(u,v,we[v])})),N=Rb(yt?ft[v]:0,v,G),v in ft||(ft[v]=N.start,yt&&(N.end=N.start,N.start=0))}}function g3(u,f){var h,v,_,w,S;for(h in u)if(v=Te(h),_=f[v],w=u[h],Array.isArray(w)&&(_=w[1],w=u[h]=w[0]),h!==v&&(u[v]=w,delete u[h]),S=g.cssHooks[v],S&&"expand"in S){w=S.expand(w),delete u[v];for(h in w)h in u||(u[h]=w[h],f[h]=_)}else f[v]=_}function xr(u,f,h){var v,_,w=0,S=xr.prefilters.length,F=g.Deferred().always(function(){delete N.elem}),N=function(){if(_)return!1;for(var ue=ys||Db(),G=Math.max(0,W.startTime+W.duration-ue),we=G/W.duration||0,it=1-we,yt=0,ft=W.tweens.length;yt<ft;yt++)W.tweens[yt].run(it);return F.notifyWith(u,[W,it,G]),it<1&&ft?G:(ft||F.notifyWith(u,[W,1,0]),F.resolveWith(u,[W]),!1)},W=F.promise({elem:u,props:g.extend({},f),opts:g.extend(!0,{specialEasing:{},easing:g.easing._default},h),originalProperties:f,originalOptions:h,startTime:ys||Db(),duration:h.duration,tweens:[],createTween:function(ue,G){var we=g.Tween(u,W.opts,ue,G,W.opts.specialEasing[ue]||W.opts.easing);return W.tweens.push(we),we},stop:function(ue){var G=0,we=ue?W.tweens.length:0;if(_)return this;for(_=!0;G<we;G++)W.tweens[G].run(1);return ue?(F.notifyWith(u,[W,1,0]),F.resolveWith(u,[W,ue])):F.rejectWith(u,[W,ue]),this}}),re=W.props;for(g3(re,W.opts.specialEasing);w<S;w++)if(v=xr.prefilters[w].call(W,u,re,W.opts),v)return k(v.stop)&&(g._queueHooks(W.elem,W.opts.queue).stop=v.stop.bind(v)),v;return g.map(re,Rb,W),k(W.opts.start)&&W.opts.start.call(u,W),W.progress(W.opts.progress).done(W.opts.done,W.opts.complete).fail(W.opts.fail).always(W.opts.always),g.fx.timer(g.extend(N,{elem:u,anim:W,queue:W.opts.queue})),W}g.Animation=g.extend(xr,{tweeners:{"*":[function(u,f){var h=this.createTween(u,f);return mt(h.elem,u,$t.exec(f),h),h}]},tweener:function(u,f){k(u)?(f=u,u=["*"]):u=u.match(Ve);for(var h,v=0,_=u.length;v<_;v++)h=u[v],xr.tweeners[h]=xr.tweeners[h]||[],xr.tweeners[h].unshift(f)},prefilters:[h3],prefilter:function(u,f){f?xr.prefilters.unshift(u):xr.prefilters.push(u)}}),g.speed=function(u,f,h){var v=u&&typeof u=="object"?g.extend({},u):{complete:h||!h&&f||k(u)&&u,duration:u,easing:h&&f||f&&!k(f)&&f};return g.fx.off?v.duration=0:typeof v.duration!="number"&&(v.duration in g.fx.speeds?v.duration=g.fx.speeds[v.duration]:v.duration=g.fx.speeds._default),(v.queue==null||v.queue===!0)&&(v.queue="fx"),v.old=v.complete,v.complete=function(){k(v.old)&&v.old.call(this),v.queue&&g.dequeue(this,v.queue)},v},g.fn.extend({fadeTo:function(u,f,h,v){return this.filter(pt).css("opacity",0).show().end().animate({opacity:f},u,h,v)},animate:function(u,f,h,v){var _=g.isEmptyObject(u),w=g.speed(f,h,v),S=function(){var F=xr(this,g.extend({},u),w);(_||ne.get(this,"finish"))&&F.stop(!0)};return S.finish=S,_||w.queue===!1?this.each(S):this.queue(w.queue,S)},stop:function(u,f,h){var v=function(_){var w=_.stop;delete _.stop,w(h)};return typeof u!="string"&&(h=f,f=u,u=void 0),f&&this.queue(u||"fx",[]),this.each(function(){var _=!0,w=u!=null&&u+"queueHooks",S=g.timers,F=ne.get(this);if(w)F[w]&&F[w].stop&&v(F[w]);else for(w in F)F[w]&&F[w].stop&&p3.test(w)&&v(F[w]);for(w=S.length;w--;)S[w].elem===this&&(u==null||S[w].queue===u)&&(S[w].anim.stop(h),_=!1,S.splice(w,1));(_||!h)&&g.dequeue(this,u)})},finish:function(u){return u!==!1&&(u=u||"fx"),this.each(function(){var f,h=ne.get(this),v=h[u+"queue"],_=h[u+"queueHooks"],w=g.timers,S=v?v.length:0;for(h.finish=!0,g.queue(this,u,[]),_&&_.stop&&_.stop.call(this,!0),f=w.length;f--;)w[f].elem===this&&w[f].queue===u&&(w[f].anim.stop(!0),w.splice(f,1));for(f=0;f<S;f++)v[f]&&v[f].finish&&v[f].finish.call(this);delete h.finish})}}),g.each(["toggle","show","hide"],function(u,f){var h=g.fn[f];g.fn[f]=function(v,_,w){return v==null||typeof v=="boolean"?h.apply(this,arguments):this.animate(ju(f,!0),v,_,w)}}),g.each({slideDown:ju("show"),slideUp:ju("hide"),slideToggle:ju("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(u,f){g.fn[u]=function(h,v,_){return this.animate(f,h,v,_)}}),g.timers=[],g.fx.tick=function(){var u,f=0,h=g.timers;for(ys=Date.now();f<h.length;f++)u=h[f],!u()&&h[f]===u&&h.splice(f--,1);h.length||g.fx.stop(),ys=void 0},g.fx.timer=function(u){g.timers.push(u),g.fx.start()},g.fx.interval=13,g.fx.start=function(){Hu||(Hu=!0,lp())},g.fx.stop=function(){Hu=null},g.fx.speeds={slow:600,fast:200,_default:400},g.fn.delay=function(u,f){return u=g.fx&&g.fx.speeds[u]||u,f=f||"fx",this.queue(f,function(h,v){var _=t.setTimeout(h,u);v.stop=function(){t.clearTimeout(_)}})},function(){var u=O.createElement("input"),f=O.createElement("select"),h=f.appendChild(O.createElement("option"));u.type="checkbox",b.checkOn=u.value!=="",b.optSelected=h.selected,u=O.createElement("input"),u.value="t",u.type="radio",b.radioValue=u.value==="t"}();var Nb,Fa=g.expr.attrHandle;g.fn.extend({attr:function(u,f){return ve(this,g.attr,u,f,arguments.length>1)},removeAttr:function(u){return this.each(function(){g.removeAttr(this,u)})}}),g.extend({attr:function(u,f,h){var v,_,w=u.nodeType;if(!(w===3||w===8||w===2)){if(typeof u.getAttribute>"u")return g.prop(u,f,h);if((w!==1||!g.isXMLDoc(u))&&(_=g.attrHooks[f.toLowerCase()]||(g.expr.match.bool.test(f)?Nb:void 0)),h!==void 0){if(h===null){g.removeAttr(u,f);return}return _&&"set"in _&&(v=_.set(u,h,f))!==void 0?v:(u.setAttribute(f,h+""),h)}return _&&"get"in _&&(v=_.get(u,f))!==null?v:(v=g.find.attr(u,f),v??void 0)}},attrHooks:{type:{set:function(u,f){if(!b.radioValue&&f==="radio"&&A(u,"input")){var h=u.value;return u.setAttribute("type",f),h&&(u.value=h),f}}}},removeAttr:function(u,f){var h,v=0,_=f&&f.match(Ve);if(_&&u.nodeType===1)for(;h=_[v++];)u.removeAttribute(h)}}),Nb={set:function(u,f,h){return f===!1?g.removeAttr(u,h):u.setAttribute(h,h),h}},g.each(g.expr.match.bool.source.match(/\w+/g),function(u,f){var h=Fa[f]||g.find.attr;Fa[f]=function(v,_,w){var S,F,N=_.toLowerCase();return w||(F=Fa[N],Fa[N]=S,S=h(v,_,w)!=null?N:null,Fa[N]=F),S}});var m3=/^(?:input|select|textarea|button)$/i,v3=/^(?:a|area)$/i;g.fn.extend({prop:function(u,f){return ve(this,g.prop,u,f,arguments.length>1)},removeProp:function(u){return this.each(function(){delete this[g.propFix[u]||u]})}}),g.extend({prop:function(u,f,h){var v,_,w=u.nodeType;if(!(w===3||w===8||w===2))return(w!==1||!g.isXMLDoc(u))&&(f=g.propFix[f]||f,_=g.propHooks[f]),h!==void 0?_&&"set"in _&&(v=_.set(u,h,f))!==void 0?v:u[f]=h:_&&"get"in _&&(v=_.get(u,f))!==null?v:u[f]},propHooks:{tabIndex:{get:function(u){var f=g.find.attr(u,"tabindex");return f?parseInt(f,10):m3.test(u.nodeName)||v3.test(u.nodeName)&&u.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),b.optSelected||(g.propHooks.selected={get:function(u){var f=u.parentNode;return f&&f.parentNode&&f.parentNode.selectedIndex,null},set:function(u){var f=u.parentNode;f&&(f.selectedIndex,f.parentNode&&f.parentNode.selectedIndex)}}),g.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){g.propFix[this.toLowerCase()]=this});function lo(u){var f=u.match(Ve)||[];return f.join(" ")}function uo(u){return u.getAttribute&&u.getAttribute("class")||""}function up(u){return Array.isArray(u)?u:typeof u=="string"?u.match(Ve)||[]:[]}g.fn.extend({addClass:function(u){var f,h,v,_,w,S;return k(u)?this.each(function(F){g(this).addClass(u.call(this,F,uo(this)))}):(f=up(u),f.length?this.each(function(){if(v=uo(this),h=this.nodeType===1&&" "+lo(v)+" ",h){for(w=0;w<f.length;w++)_=f[w],h.indexOf(" "+_+" ")<0&&(h+=_+" ");S=lo(h),v!==S&&this.setAttribute("class",S)}}):this)},removeClass:function(u){var f,h,v,_,w,S;return k(u)?this.each(function(F){g(this).removeClass(u.call(this,F,uo(this)))}):arguments.length?(f=up(u),f.length?this.each(function(){if(v=uo(this),h=this.nodeType===1&&" "+lo(v)+" ",h){for(w=0;w<f.length;w++)for(_=f[w];h.indexOf(" "+_+" ")>-1;)h=h.replace(" "+_+" "," ");S=lo(h),v!==S&&this.setAttribute("class",S)}}):this):this.attr("class","")},toggleClass:function(u,f){var h,v,_,w,S=typeof u,F=S==="string"||Array.isArray(u);return k(u)?this.each(function(N){g(this).toggleClass(u.call(this,N,uo(this),f),f)}):typeof f=="boolean"&&F?f?this.addClass(u):this.removeClass(u):(h=up(u),this.each(function(){if(F)for(w=g(this),_=0;_<h.length;_++)v=h[_],w.hasClass(v)?w.removeClass(v):w.addClass(v);else(u===void 0||S==="boolean")&&(v=uo(this),v&&ne.set(this,"__className__",v),this.setAttribute&&this.setAttribute("class",v||u===!1?"":ne.get(this,"__className__")||""))}))},hasClass:function(u){var f,h,v=0;for(f=" "+u+" ";h=this[v++];)if(h.nodeType===1&&(" "+lo(uo(h))+" ").indexOf(f)>-1)return!0;return!1}});var y3=/\r/g;g.fn.extend({val:function(u){var f,h,v,_=this[0];return arguments.length?(v=k(u),this.each(function(w){var S;this.nodeType===1&&(v?S=u.call(this,w,g(this).val()):S=u,S==null?S="":typeof S=="number"?S+="":Array.isArray(S)&&(S=g.map(S,function(F){return F==null?"":F+""})),f=g.valHooks[this.type]||g.valHooks[this.nodeName.toLowerCase()],(!f||!("set"in f)||f.set(this,S,"value")===void 0)&&(this.value=S))})):_?(f=g.valHooks[_.type]||g.valHooks[_.nodeName.toLowerCase()],f&&"get"in f&&(h=f.get(_,"value"))!==void 0?h:(h=_.value,typeof h=="string"?h.replace(y3,""):h??"")):void 0}}),g.extend({valHooks:{option:{get:function(u){var f=g.find.attr(u,"value");return f??lo(g.text(u))}},select:{get:function(u){var f,h,v,_=u.options,w=u.selectedIndex,S=u.type==="select-one",F=S?null:[],N=S?w+1:_.length;for(w<0?v=N:v=S?w:0;v<N;v++)if(h=_[v],(h.selected||v===w)&&!h.disabled&&(!h.parentNode.disabled||!A(h.parentNode,"optgroup"))){if(f=g(h).val(),S)return f;F.push(f)}return F},set:function(u,f){for(var h,v,_=u.options,w=g.makeArray(f),S=_.length;S--;)v=_[S],(v.selected=g.inArray(g.valHooks.option.get(v),w)>-1)&&(h=!0);return h||(u.selectedIndex=-1),w}}}}),g.each(["radio","checkbox"],function(){g.valHooks[this]={set:function(u,f){if(Array.isArray(f))return u.checked=g.inArray(g(u).val(),f)>-1}},b.checkOn||(g.valHooks[this].get=function(u){return u.getAttribute("value")===null?"on":u.value})});var Ba=t.location,Mb={guid:Date.now()},cp=/\?/;g.parseXML=function(u){var f,h;if(!u||typeof u!="string")return null;try{f=new t.DOMParser().parseFromString(u,"text/xml")}catch{}return h=f&&f.getElementsByTagName("parsererror")[0],(!f||h)&&g.error("Invalid XML: "+(h?g.map(h.childNodes,function(v){return v.textContent}).join(`
|
||
`):u)),f};var Fb=/^(?:focusinfocus|focusoutblur)$/,Bb=function(u){u.stopPropagation()};g.extend(g.event,{trigger:function(u,f,h,v){var _,w,S,F,N,W,re,ue,G=[h||O],we=y.call(u,"type")?u.type:u,it=y.call(u,"namespace")?u.namespace.split("."):[];if(w=ue=S=h=h||O,!(h.nodeType===3||h.nodeType===8)&&!Fb.test(we+g.event.triggered)&&(we.indexOf(".")>-1&&(it=we.split("."),we=it.shift(),it.sort()),N=we.indexOf(":")<0&&"on"+we,u=u[g.expando]?u:new g.Event(we,typeof u=="object"&&u),u.isTrigger=v?2:3,u.namespace=it.join("."),u.rnamespace=u.namespace?new RegExp("(^|\\.)"+it.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,u.result=void 0,u.target||(u.target=h),f=f==null?[u]:g.makeArray(f,[u]),re=g.event.special[we]||{},!(!v&&re.trigger&&re.trigger.apply(h,f)===!1))){if(!v&&!re.noBubble&&!L(h)){for(F=re.delegateType||we,Fb.test(F+we)||(w=w.parentNode);w;w=w.parentNode)G.push(w),S=w;S===(h.ownerDocument||O)&&G.push(S.defaultView||S.parentWindow||t)}for(_=0;(w=G[_++])&&!u.isPropagationStopped();)ue=w,u.type=_>1?F:re.bindType||we,W=(ne.get(w,"events")||Object.create(null))[u.type]&&ne.get(w,"handle"),W&&W.apply(w,f),W=N&&w[N],W&&W.apply&&_e(w)&&(u.result=W.apply(w,f),u.result===!1&&u.preventDefault());return u.type=we,!v&&!u.isDefaultPrevented()&&(!re._default||re._default.apply(G.pop(),f)===!1)&&_e(h)&&N&&k(h[we])&&!L(h)&&(S=h[N],S&&(h[N]=null),g.event.triggered=we,u.isPropagationStopped()&&ue.addEventListener(we,Bb),h[we](),u.isPropagationStopped()&&ue.removeEventListener(we,Bb),g.event.triggered=void 0,S&&(h[N]=S)),u.result}},simulate:function(u,f,h){var v=g.extend(new g.Event,h,{type:u,isSimulated:!0});g.event.trigger(v,null,f)}}),g.fn.extend({trigger:function(u,f){return this.each(function(){g.event.trigger(u,f,this)})},triggerHandler:function(u,f){var h=this[0];if(h)return g.event.trigger(u,f,h,!0)}});var b3=/\[\]$/,$b=/\r?\n/g,C3=/^(?:submit|button|image|reset|file)$/i,_3=/^(?:input|select|textarea|keygen)/i;function fp(u,f,h,v){var _;if(Array.isArray(f))g.each(f,function(w,S){h||b3.test(u)?v(u,S):fp(u+"["+(typeof S=="object"&&S!=null?w:"")+"]",S,h,v)});else if(!h&&x(f)==="object")for(_ in f)fp(u+"["+_+"]",f[_],h,v);else v(u,f)}g.param=function(u,f){var h,v=[],_=function(w,S){var F=k(S)?S():S;v[v.length]=encodeURIComponent(w)+"="+encodeURIComponent(F??"")};if(u==null)return"";if(Array.isArray(u)||u.jquery&&!g.isPlainObject(u))g.each(u,function(){_(this.name,this.value)});else for(h in u)fp(h,u[h],f,_);return v.join("&")},g.fn.extend({serialize:function(){return g.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var u=g.prop(this,"elements");return u?g.makeArray(u):this}).filter(function(){var u=this.type;return this.name&&!g(this).is(":disabled")&&_3.test(this.nodeName)&&!C3.test(u)&&(this.checked||!Li.test(u))}).map(function(u,f){var h=g(this).val();return h==null?null:Array.isArray(h)?g.map(h,function(v){return{name:f.name,value:v.replace($b,`\r
|
||
`)}}):{name:f.name,value:h.replace($b,`\r
|
||
`)}}).get()}});var w3=/%20/g,T3=/#.*$/,k3=/([?&])_=[^&]*/,x3=/^(.*?):[ \t]*([^\r\n]*)$/mg,S3=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,A3=/^(?:GET|HEAD)$/,E3=/^\/\//,Hb={},dp={},jb="*/".concat("*"),pp=O.createElement("a");pp.href=Ba.href;function Ub(u){return function(f,h){typeof f!="string"&&(h=f,f="*");var v,_=0,w=f.toLowerCase().match(Ve)||[];if(k(h))for(;v=w[_++];)v[0]==="+"?(v=v.slice(1)||"*",(u[v]=u[v]||[]).unshift(h)):(u[v]=u[v]||[]).push(h)}}function Wb(u,f,h,v){var _={},w=u===dp;function S(F){var N;return _[F]=!0,g.each(u[F]||[],function(W,re){var ue=re(f,h,v);if(typeof ue=="string"&&!w&&!_[ue])return f.dataTypes.unshift(ue),S(ue),!1;if(w)return!(N=ue)}),N}return S(f.dataTypes[0])||!_["*"]&&S("*")}function hp(u,f){var h,v,_=g.ajaxSettings.flatOptions||{};for(h in f)f[h]!==void 0&&((_[h]?u:v||(v={}))[h]=f[h]);return v&&g.extend(!0,u,v),u}function L3(u,f,h){for(var v,_,w,S,F=u.contents,N=u.dataTypes;N[0]==="*";)N.shift(),v===void 0&&(v=u.mimeType||f.getResponseHeader("Content-Type"));if(v){for(_ in F)if(F[_]&&F[_].test(v)){N.unshift(_);break}}if(N[0]in h)w=N[0];else{for(_ in h){if(!N[0]||u.converters[_+" "+N[0]]){w=_;break}S||(S=_)}w=w||S}if(w)return w!==N[0]&&N.unshift(w),h[w]}function O3(u,f,h,v){var _,w,S,F,N,W={},re=u.dataTypes.slice();if(re[1])for(S in u.converters)W[S.toLowerCase()]=u.converters[S];for(w=re.shift();w;)if(u.responseFields[w]&&(h[u.responseFields[w]]=f),!N&&v&&u.dataFilter&&(f=u.dataFilter(f,u.dataType)),N=w,w=re.shift(),w){if(w==="*")w=N;else if(N!=="*"&&N!==w){if(S=W[N+" "+w]||W["* "+w],!S){for(_ in W)if(F=_.split(" "),F[1]===w&&(S=W[N+" "+F[0]]||W["* "+F[0]],S)){S===!0?S=W[_]:W[_]!==!0&&(w=F[0],re.unshift(F[1]));break}}if(S!==!0)if(S&&u.throws)f=S(f);else try{f=S(f)}catch(ue){return{state:"parsererror",error:S?ue:"No conversion from "+N+" to "+w}}}}return{state:"success",data:f}}g.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Ba.href,type:"GET",isLocal:S3.test(Ba.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":jb,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":g.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(u,f){return f?hp(hp(u,g.ajaxSettings),f):hp(g.ajaxSettings,u)},ajaxPrefilter:Ub(Hb),ajaxTransport:Ub(dp),ajax:function(u,f){typeof u=="object"&&(f=u,u=void 0),f=f||{};var h,v,_,w,S,F,N,W,re,ue,G=g.ajaxSetup({},f),we=G.context||G,it=G.context&&(we.nodeType||we.jquery)?g(we):g.event,yt=g.Deferred(),ft=g.Callbacks("once memory"),vn=G.statusCode||{},an={},jr={},Ur="canceled",vt={readyState:0,getResponseHeader:function(kt){var qt;if(N){if(!w)for(w={};qt=x3.exec(_);)w[qt[1].toLowerCase()+" "]=(w[qt[1].toLowerCase()+" "]||[]).concat(qt[2]);qt=w[kt.toLowerCase()+" "]}return qt==null?null:qt.join(", ")},getAllResponseHeaders:function(){return N?_:null},setRequestHeader:function(kt,qt){return N==null&&(kt=jr[kt.toLowerCase()]=jr[kt.toLowerCase()]||kt,an[kt]=qt),this},overrideMimeType:function(kt){return N==null&&(G.mimeType=kt),this},statusCode:function(kt){var qt;if(kt)if(N)vt.always(kt[vt.status]);else for(qt in kt)vn[qt]=[vn[qt],kt[qt]];return this},abort:function(kt){var qt=kt||Ur;return h&&h.abort(qt),co(0,qt),this}};if(yt.promise(vt),G.url=((u||G.url||Ba.href)+"").replace(E3,Ba.protocol+"//"),G.type=f.method||f.type||G.method||G.type,G.dataTypes=(G.dataType||"*").toLowerCase().match(Ve)||[""],G.crossDomain==null){F=O.createElement("a");try{F.href=G.url,F.href=F.href,G.crossDomain=pp.protocol+"//"+pp.host!=F.protocol+"//"+F.host}catch{G.crossDomain=!0}}if(G.data&&G.processData&&typeof G.data!="string"&&(G.data=g.param(G.data,G.traditional)),Wb(Hb,G,f,vt),N)return vt;W=g.event&&G.global,W&&g.active++===0&&g.event.trigger("ajaxStart"),G.type=G.type.toUpperCase(),G.hasContent=!A3.test(G.type),v=G.url.replace(T3,""),G.hasContent?G.data&&G.processData&&(G.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&(G.data=G.data.replace(w3,"+")):(ue=G.url.slice(v.length),G.data&&(G.processData||typeof G.data=="string")&&(v+=(cp.test(v)?"&":"?")+G.data,delete G.data),G.cache===!1&&(v=v.replace(k3,"$1"),ue=(cp.test(v)?"&":"?")+"_="+Mb.guid+++ue),G.url=v+ue),G.ifModified&&(g.lastModified[v]&&vt.setRequestHeader("If-Modified-Since",g.lastModified[v]),g.etag[v]&&vt.setRequestHeader("If-None-Match",g.etag[v])),(G.data&&G.hasContent&&G.contentType!==!1||f.contentType)&&vt.setRequestHeader("Content-Type",G.contentType),vt.setRequestHeader("Accept",G.dataTypes[0]&&G.accepts[G.dataTypes[0]]?G.accepts[G.dataTypes[0]]+(G.dataTypes[0]!=="*"?", "+jb+"; q=0.01":""):G.accepts["*"]);for(re in G.headers)vt.setRequestHeader(re,G.headers[re]);if(G.beforeSend&&(G.beforeSend.call(we,vt,G)===!1||N))return vt.abort();if(Ur="abort",ft.add(G.complete),vt.done(G.success),vt.fail(G.error),h=Wb(dp,G,f,vt),!h)co(-1,"No Transport");else{if(vt.readyState=1,W&&it.trigger("ajaxSend",[vt,G]),N)return vt;G.async&&G.timeout>0&&(S=t.setTimeout(function(){vt.abort("timeout")},G.timeout));try{N=!1,h.send(an,co)}catch(kt){if(N)throw kt;co(-1,kt)}}function co(kt,qt,Ha,mp){var Wr,ja,Kr,Oi,Ii,gr=qt;N||(N=!0,S&&t.clearTimeout(S),h=void 0,_=mp||"",vt.readyState=kt>0?4:0,Wr=kt>=200&&kt<300||kt===304,Ha&&(Oi=L3(G,vt,Ha)),!Wr&&g.inArray("script",G.dataTypes)>-1&&g.inArray("json",G.dataTypes)<0&&(G.converters["text script"]=function(){}),Oi=O3(G,Oi,vt,Wr),Wr?(G.ifModified&&(Ii=vt.getResponseHeader("Last-Modified"),Ii&&(g.lastModified[v]=Ii),Ii=vt.getResponseHeader("etag"),Ii&&(g.etag[v]=Ii)),kt===204||G.type==="HEAD"?gr="nocontent":kt===304?gr="notmodified":(gr=Oi.state,ja=Oi.data,Kr=Oi.error,Wr=!Kr)):(Kr=gr,(kt||!gr)&&(gr="error",kt<0&&(kt=0))),vt.status=kt,vt.statusText=(qt||gr)+"",Wr?yt.resolveWith(we,[ja,gr,vt]):yt.rejectWith(we,[vt,gr,Kr]),vt.statusCode(vn),vn=void 0,W&&it.trigger(Wr?"ajaxSuccess":"ajaxError",[vt,G,Wr?ja:Kr]),ft.fireWith(we,[vt,gr]),W&&(it.trigger("ajaxComplete",[vt,G]),--g.active||g.event.trigger("ajaxStop")))}return vt},getJSON:function(u,f,h){return g.get(u,f,h,"json")},getScript:function(u,f){return g.get(u,void 0,f,"script")}}),g.each(["get","post"],function(u,f){g[f]=function(h,v,_,w){return k(v)&&(w=w||_,_=v,v=void 0),g.ajax(g.extend({url:h,type:f,dataType:w,data:v,success:_},g.isPlainObject(h)&&h))}}),g.ajaxPrefilter(function(u){var f;for(f in u.headers)f.toLowerCase()==="content-type"&&(u.contentType=u.headers[f]||"")}),g._evalUrl=function(u,f,h){return g.ajax({url:u,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(v){g.globalEval(v,f,h)}})},g.fn.extend({wrapAll:function(u){var f;return this[0]&&(k(u)&&(u=u.call(this[0])),f=g(u,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&f.insertBefore(this[0]),f.map(function(){for(var h=this;h.firstElementChild;)h=h.firstElementChild;return h}).append(this)),this},wrapInner:function(u){return k(u)?this.each(function(f){g(this).wrapInner(u.call(this,f))}):this.each(function(){var f=g(this),h=f.contents();h.length?h.wrapAll(u):f.append(u)})},wrap:function(u){var f=k(u);return this.each(function(h){g(this).wrapAll(f?u.call(this,h):u)})},unwrap:function(u){return this.parent(u).not("body").each(function(){g(this).replaceWith(this.childNodes)}),this}}),g.expr.pseudos.hidden=function(u){return!g.expr.pseudos.visible(u)},g.expr.pseudos.visible=function(u){return!!(u.offsetWidth||u.offsetHeight||u.getClientRects().length)},g.ajaxSettings.xhr=function(){try{return new t.XMLHttpRequest}catch{}};var I3={0:200,1223:204},$a=g.ajaxSettings.xhr();b.cors=!!$a&&"withCredentials"in $a,b.ajax=$a=!!$a,g.ajaxTransport(function(u){var f,h;if(b.cors||$a&&!u.crossDomain)return{send:function(v,_){var w,S=u.xhr();if(S.open(u.type,u.url,u.async,u.username,u.password),u.xhrFields)for(w in u.xhrFields)S[w]=u.xhrFields[w];u.mimeType&&S.overrideMimeType&&S.overrideMimeType(u.mimeType),!u.crossDomain&&!v["X-Requested-With"]&&(v["X-Requested-With"]="XMLHttpRequest");for(w in v)S.setRequestHeader(w,v[w]);f=function(F){return function(){f&&(f=h=S.onload=S.onerror=S.onabort=S.ontimeout=S.onreadystatechange=null,F==="abort"?S.abort():F==="error"?typeof S.status!="number"?_(0,"error"):_(S.status,S.statusText):_(I3[S.status]||S.status,S.statusText,(S.responseType||"text")!=="text"||typeof S.responseText!="string"?{binary:S.response}:{text:S.responseText},S.getAllResponseHeaders()))}},S.onload=f(),h=S.onerror=S.ontimeout=f("error"),S.onabort!==void 0?S.onabort=h:S.onreadystatechange=function(){S.readyState===4&&t.setTimeout(function(){f&&h()})},f=f("abort");try{S.send(u.hasContent&&u.data||null)}catch(F){if(f)throw F}},abort:function(){f&&f()}}}),g.ajaxPrefilter(function(u){u.crossDomain&&(u.contents.script=!1)}),g.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(u){return g.globalEval(u),u}}}),g.ajaxPrefilter("script",function(u){u.cache===void 0&&(u.cache=!1),u.crossDomain&&(u.type="GET")}),g.ajaxTransport("script",function(u){if(u.crossDomain||u.scriptAttrs){var f,h;return{send:function(v,_){f=g("<script>").attr(u.scriptAttrs||{}).prop({charset:u.scriptCharset,src:u.url}).on("load error",h=function(w){f.remove(),h=null,w&&_(w.type==="error"?404:200,w.type)}),O.head.appendChild(f[0])},abort:function(){h&&h()}}}});var Kb=[],gp=/(=)\?(?=&|$)|\?\?/;g.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var u=Kb.pop()||g.expando+"_"+Mb.guid++;return this[u]=!0,u}}),g.ajaxPrefilter("json jsonp",function(u,f,h){var v,_,w,S=u.jsonp!==!1&&(gp.test(u.url)?"url":typeof u.data=="string"&&(u.contentType||"").indexOf("application/x-www-form-urlencoded")===0&&gp.test(u.data)&&"data");if(S||u.dataTypes[0]==="jsonp")return v=u.jsonpCallback=k(u.jsonpCallback)?u.jsonpCallback():u.jsonpCallback,S?u[S]=u[S].replace(gp,"$1"+v):u.jsonp!==!1&&(u.url+=(cp.test(u.url)?"&":"?")+u.jsonp+"="+v),u.converters["script json"]=function(){return w||g.error(v+" was not called"),w[0]},u.dataTypes[0]="json",_=t[v],t[v]=function(){w=arguments},h.always(function(){_===void 0?g(t).removeProp(v):t[v]=_,u[v]&&(u.jsonpCallback=f.jsonpCallback,Kb.push(v)),w&&k(_)&&_(w[0]),w=_=void 0}),"script"}),b.createHTMLDocument=function(){var u=O.implementation.createHTMLDocument("").body;return u.innerHTML="<form></form><form></form>",u.childNodes.length===2}(),g.parseHTML=function(u,f,h){if(typeof u!="string")return[];typeof f=="boolean"&&(h=f,f=!1);var v,_,w;return f||(b.createHTMLDocument?(f=O.implementation.createHTMLDocument(""),v=f.createElement("base"),v.href=O.location.href,f.head.appendChild(v)):f=O),_=se.exec(u),w=!h&&[],_?[f.createElement(_[1])]:(_=ao([u],f,w),w&&w.length&&g(w).remove(),g.merge([],_.childNodes))},g.fn.load=function(u,f,h){var v,_,w,S=this,F=u.indexOf(" ");return F>-1&&(v=lo(u.slice(F)),u=u.slice(0,F)),k(f)?(h=f,f=void 0):f&&typeof f=="object"&&(_="POST"),S.length>0&&g.ajax({url:u,type:_||"GET",dataType:"html",data:f}).done(function(N){w=arguments,S.html(v?g("<div>").append(g.parseHTML(N)).find(v):N)}).always(h&&function(N,W){S.each(function(){h.apply(this,w||[N.responseText,W,N])})}),this},g.expr.pseudos.animated=function(u){return g.grep(g.timers,function(f){return u===f.elem}).length},g.offset={setOffset:function(u,f,h){var v,_,w,S,F,N,W,re=g.css(u,"position"),ue=g(u),G={};re==="static"&&(u.style.position="relative"),F=ue.offset(),w=g.css(u,"top"),N=g.css(u,"left"),W=(re==="absolute"||re==="fixed")&&(w+N).indexOf("auto")>-1,W?(v=ue.position(),S=v.top,_=v.left):(S=parseFloat(w)||0,_=parseFloat(N)||0),k(f)&&(f=f.call(u,h,g.extend({},F))),f.top!=null&&(G.top=f.top-F.top+S),f.left!=null&&(G.left=f.left-F.left+_),"using"in f?f.using.call(u,G):ue.css(G)}},g.fn.extend({offset:function(u){if(arguments.length)return u===void 0?this:this.each(function(_){g.offset.setOffset(this,u,_)});var f,h,v=this[0];if(v)return v.getClientRects().length?(f=v.getBoundingClientRect(),h=v.ownerDocument.defaultView,{top:f.top+h.pageYOffset,left:f.left+h.pageXOffset}):{top:0,left:0}},position:function(){if(this[0]){var u,f,h,v=this[0],_={top:0,left:0};if(g.css(v,"position")==="fixed")f=v.getBoundingClientRect();else{for(f=this.offset(),h=v.ownerDocument,u=v.offsetParent||h.documentElement;u&&(u===h.body||u===h.documentElement)&&g.css(u,"position")==="static";)u=u.parentNode;u&&u!==v&&u.nodeType===1&&(_=g(u).offset(),_.top+=g.css(u,"borderTopWidth",!0),_.left+=g.css(u,"borderLeftWidth",!0))}return{top:f.top-_.top-g.css(v,"marginTop",!0),left:f.left-_.left-g.css(v,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var u=this.offsetParent;u&&g.css(u,"position")==="static";)u=u.offsetParent;return u||J})}}),g.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(u,f){var h=f==="pageYOffset";g.fn[u]=function(v){return ve(this,function(_,w,S){var F;if(L(_)?F=_:_.nodeType===9&&(F=_.defaultView),S===void 0)return F?F[f]:_[w];F?F.scrollTo(h?F.pageXOffset:S,h?S:F.pageYOffset):_[w]=S},u,v,arguments.length)}}),g.each(["top","left"],function(u,f){g.cssHooks[f]=Sb(b.pixelPosition,function(h,v){if(v)return v=Ma(h,f),ip.test(v)?g(h).position()[f]+"px":v})}),g.each({Height:"height",Width:"width"},function(u,f){g.each({padding:"inner"+u,content:f,"":"outer"+u},function(h,v){g.fn[v]=function(_,w){var S=arguments.length&&(h||typeof _!="boolean"),F=h||(_===!0||w===!0?"margin":"border");return ve(this,function(N,W,re){var ue;return L(N)?v.indexOf("outer")===0?N["inner"+u]:N.document.documentElement["client"+u]:N.nodeType===9?(ue=N.documentElement,Math.max(N.body["scroll"+u],ue["scroll"+u],N.body["offset"+u],ue["offset"+u],ue["client"+u])):re===void 0?g.css(N,W,F):g.style(N,W,re,F)},f,S?_:void 0,S)}})}),g.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(u,f){g.fn[f]=function(h){return this.on(f,h)}}),g.fn.extend({bind:function(u,f,h){return this.on(u,null,f,h)},unbind:function(u,f){return this.off(u,null,f)},delegate:function(u,f,h,v){return this.on(f,u,h,v)},undelegate:function(u,f,h){return arguments.length===1?this.off(u,"**"):this.off(f,u||"**",h)},hover:function(u,f){return this.on("mouseenter",u).on("mouseleave",f||u)}}),g.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(u,f){g.fn[f]=function(h,v){return arguments.length>0?this.on(f,null,h,v):this.trigger(f)}});var P3=/^[\s\uFEFF\xA0]+|([^\s\uFEFF\xA0])[\s\uFEFF\xA0]+$/g;g.proxy=function(u,f){var h,v,_;if(typeof f=="string"&&(h=u[f],f=u,u=h),!!k(u))return v=o.call(arguments,2),_=function(){return u.apply(f||this,v.concat(o.call(arguments)))},_.guid=u.guid=u.guid||g.guid++,_},g.holdReady=function(u){u?g.readyWait++:g.ready(!0)},g.isArray=Array.isArray,g.parseJSON=JSON.parse,g.nodeName=A,g.isFunction=k,g.isWindow=L,g.camelCase=Te,g.type=x,g.now=Date.now,g.isNumeric=function(u){var f=g.type(u);return(f==="number"||f==="string")&&!isNaN(u-parseFloat(u))},g.trim=function(u){return u==null?"":(u+"").replace(P3,"$1")};var D3=t.jQuery,R3=t.$;return g.noConflict=function(u){return t.$===g&&(t.$=R3),u&&t.jQuery===g&&(t.jQuery=D3),g},typeof n>"u"&&(t.jQuery=t.$=g),g})}(Nd)),Nd.exports}(function(e){(function(t){t(["jquery"],function(n){return function(){var r,i,o=0,s={error:"error",info:"info",success:"success",warning:"warning"},l={clear:k,remove:L,error:d,getContainer:p,info:y,options:{},subscribe:m,success:C,version:"2.1.4",warning:b},c;return l;function d(A,D,H){return Q({type:s.error,iconClass:g().iconClasses.error,message:A,optionsOverride:H,title:D})}function p(A,D){return A||(A=g()),r=n("#"+A.containerId),r.length||D&&(r=X(A)),r}function y(A,D,H){return Q({type:s.info,iconClass:g().iconClasses.info,message:A,optionsOverride:H,title:D})}function m(A){i=A}function C(A,D,H){return Q({type:s.success,iconClass:g().iconClasses.success,message:A,optionsOverride:H,title:D})}function b(A,D,H){return Q({type:s.warning,iconClass:g().iconClasses.warning,message:A,optionsOverride:H,title:D})}function k(A,D){var H=g();r||p(H),$(A,H,D)||O(H)}function L(A){var D=g();if(r||p(D),A&&n(":focus",A).length===0){I(A);return}r.children().length&&r.remove()}function O(A){for(var D=r.children(),H=D.length-1;H>=0;H--)$(n(D[H]),A)}function $(A,D,H){var K=H&&H.force?H.force:!1;return A&&(K||n(":focus",A).length===0)?(A[D.hideMethod]({duration:D.hideDuration,easing:D.hideEasing,complete:function(){I(A)}}),!0):!1}function X(A){return r=n("<div/>").attr("id",A.containerId).addClass(A.positionClass),r.appendTo(n(A.target)),r}function x(){return{tapToDismiss:!0,toastClass:"toast",containerId:"toast-container",debug:!1,showMethod:"fadeIn",showDuration:300,showEasing:"swing",onShown:void 0,hideMethod:"fadeOut",hideDuration:1e3,hideEasing:"swing",onHidden:void 0,closeMethod:!1,closeDuration:!1,closeEasing:!1,closeOnHover:!0,extendedTimeOut:1e3,iconClasses:{error:"toast-error",info:"toast-info",success:"toast-success",warning:"toast-warning"},iconClass:"toast-info",positionClass:"toast-top-right",timeOut:5e3,titleClass:"toast-title",messageClass:"toast-message",escapeHtml:!1,target:"body",closeHtml:'<button type="button">×</button>',closeClass:"toast-close-button",newestOnTop:!0,preventDuplicates:!1,progressBar:!1,progressClass:"toast-progress",rtl:!1}}function z(A){i&&i(A)}function Q(A){var D=g(),H=A.iconClass||D.iconClass;if(typeof A.optionsOverride<"u"&&(D=n.extend(D,A.optionsOverride),H=A.optionsOverride.iconClass||H),R(D,A))return;o++,r=p(D,!0);var K=null,U=n("<div/>"),de=n("<div/>"),je=n("<div/>"),Pe=n("<div/>"),V=n(D.closeHtml),ae={intervalId:null,hideEta:null,maxHideTime:null},pe={toastId:o,state:"visible",startTime:new Date,options:D,map:A};return et(),xe(),Ce(),z(pe),D.debug&&console&&console.log(pe),U;function Qe(te){return te==null&&(te=""),te.replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">")}function et(){Ae(),Be(),tt(),Re(),Ve(),dt(),Oe(),se()}function se(){var te="";switch(A.iconClass){case"toast-success":case"toast-info":te="polite";break;default:te="assertive"}U.attr("aria-live",te)}function Ce(){D.closeOnHover&&U.hover(oe,Y),!D.onclick&&D.tapToDismiss&&U.click(B),D.closeButton&&V&&V.click(function(te){te.stopPropagation?te.stopPropagation():te.cancelBubble!==void 0&&te.cancelBubble!==!0&&(te.cancelBubble=!0),D.onCloseClick&&D.onCloseClick(te),B(!0)}),D.onclick&&U.click(function(te){D.onclick(te),B()})}function xe(){U.hide(),U[D.showMethod]({duration:D.showDuration,easing:D.showEasing,complete:D.onShown}),D.timeOut>0&&(K=setTimeout(B,D.timeOut),ae.maxHideTime=parseFloat(D.timeOut),ae.hideEta=new Date().getTime()+ae.maxHideTime,D.progressBar&&(ae.intervalId=setInterval(ee,10)))}function Ae(){A.iconClass&&U.addClass(D.toastClass).addClass(H)}function Oe(){D.newestOnTop?r.prepend(U):r.append(U)}function Be(){if(A.title){var te=A.title;D.escapeHtml&&(te=Qe(A.title)),de.append(te).addClass(D.titleClass),U.append(de)}}function tt(){if(A.message){var te=A.message;D.escapeHtml&&(te=Qe(A.message)),je.append(te).addClass(D.messageClass),U.append(je)}}function Re(){D.closeButton&&(V.addClass(D.closeClass).attr("role","button"),U.prepend(V))}function Ve(){D.progressBar&&(Pe.addClass(D.progressClass),U.prepend(Pe))}function dt(){D.rtl&&U.addClass("rtl")}function R(te,ve){if(te.preventDuplicates){if(ve.message===c)return!0;c=ve.message}return!1}function B(te){var ve=te&&D.closeMethod!==!1?D.closeMethod:D.hideMethod,me=te&&D.closeDuration!==!1?D.closeDuration:D.hideDuration,be=te&&D.closeEasing!==!1?D.closeEasing:D.hideEasing;if(!(n(":focus",U).length&&!te))return clearTimeout(ae.intervalId),U[ve]({duration:me,easing:be,complete:function(){I(U),clearTimeout(K),D.onHidden&&pe.state!=="hidden"&&D.onHidden(),pe.state="hidden",pe.endTime=new Date,z(pe)}})}function Y(){(D.timeOut>0||D.extendedTimeOut>0)&&(K=setTimeout(B,D.extendedTimeOut),ae.maxHideTime=parseFloat(D.extendedTimeOut),ae.hideEta=new Date().getTime()+ae.maxHideTime)}function oe(){clearTimeout(K),ae.hideEta=0,U.stop(!0,!0)[D.showMethod]({duration:D.showDuration,easing:D.showEasing})}function ee(){var te=(ae.hideEta-new Date().getTime())/ae.maxHideTime*100;Pe.width(te+"%")}}function g(){return n.extend({},x(),l.options)}function I(A){r||(r=p()),!A.is(":visible")&&(A.remove(),A=null,r.children().length===0&&(r.remove(),c=void 0))}}()})})(function(t,n){e.exports?e.exports=n(fH()):window.toastr=n(window.jQuery)})})(x0);var dH=x0.exports;const pH=Bl(dH);var A0={exports:{}};/*!
|
||
* clipboard.js v2.0.11
|
||
* https://clipboardjs.com/
|
||
*
|
||
* Licensed MIT © Zeno Rocha
|
||
*/(function(e,t){(function(r,i){e.exports=i()})(tf,function(){return function(){var n={686:function(o,s,l){l.d(s,{default:function(){return et}});var c=l(279),d=l.n(c),p=l(370),y=l.n(p),m=l(817),C=l.n(m);function b(se){try{return document.execCommand(se)}catch{return!1}}var k=function(Ce){var xe=C()(Ce);return b("cut"),xe},L=k;function O(se){var Ce=document.documentElement.getAttribute("dir")==="rtl",xe=document.createElement("textarea");xe.style.fontSize="12pt",xe.style.border="0",xe.style.padding="0",xe.style.margin="0",xe.style.position="absolute",xe.style[Ce?"right":"left"]="-9999px";var Ae=window.pageYOffset||document.documentElement.scrollTop;return xe.style.top="".concat(Ae,"px"),xe.setAttribute("readonly",""),xe.value=se,xe}var $=function(Ce,xe){var Ae=O(Ce);xe.container.appendChild(Ae);var Oe=C()(Ae);return b("copy"),Ae.remove(),Oe},X=function(Ce){var xe=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body},Ae="";return typeof Ce=="string"?Ae=$(Ce,xe):Ce instanceof HTMLInputElement&&!["text","search","url","tel","password"].includes(Ce==null?void 0:Ce.type)?Ae=$(Ce.value,xe):(Ae=C()(Ce),b("copy")),Ae},x=X;function z(se){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?z=function(xe){return typeof xe}:z=function(xe){return xe&&typeof Symbol=="function"&&xe.constructor===Symbol&&xe!==Symbol.prototype?"symbol":typeof xe},z(se)}var Q=function(){var Ce=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},xe=Ce.action,Ae=xe===void 0?"copy":xe,Oe=Ce.container,Be=Ce.target,tt=Ce.text;if(Ae!=="copy"&&Ae!=="cut")throw new Error('Invalid "action" value, use either "copy" or "cut"');if(Be!==void 0)if(Be&&z(Be)==="object"&&Be.nodeType===1){if(Ae==="copy"&&Be.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if(Ae==="cut"&&(Be.hasAttribute("readonly")||Be.hasAttribute("disabled")))throw new Error(`Invalid "target" attribute. You can't cut text from elements with "readonly" or "disabled" attributes`)}else throw new Error('Invalid "target" value, use a valid Element');if(tt)return x(tt,{container:Oe});if(Be)return Ae==="cut"?L(Be):x(Be,{container:Oe})},g=Q;function I(se){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?I=function(xe){return typeof xe}:I=function(xe){return xe&&typeof Symbol=="function"&&xe.constructor===Symbol&&xe!==Symbol.prototype?"symbol":typeof xe},I(se)}function A(se,Ce){if(!(se instanceof Ce))throw new TypeError("Cannot call a class as a function")}function D(se,Ce){for(var xe=0;xe<Ce.length;xe++){var Ae=Ce[xe];Ae.enumerable=Ae.enumerable||!1,Ae.configurable=!0,"value"in Ae&&(Ae.writable=!0),Object.defineProperty(se,Ae.key,Ae)}}function H(se,Ce,xe){return Ce&&D(se.prototype,Ce),xe&&D(se,xe),se}function K(se,Ce){if(typeof Ce!="function"&&Ce!==null)throw new TypeError("Super expression must either be null or a function");se.prototype=Object.create(Ce&&Ce.prototype,{constructor:{value:se,writable:!0,configurable:!0}}),Ce&&U(se,Ce)}function U(se,Ce){return U=Object.setPrototypeOf||function(Ae,Oe){return Ae.__proto__=Oe,Ae},U(se,Ce)}function de(se){var Ce=V();return function(){var Ae=ae(se),Oe;if(Ce){var Be=ae(this).constructor;Oe=Reflect.construct(Ae,arguments,Be)}else Oe=Ae.apply(this,arguments);return je(this,Oe)}}function je(se,Ce){return Ce&&(I(Ce)==="object"||typeof Ce=="function")?Ce:Pe(se)}function Pe(se){if(se===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return se}function V(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}function ae(se){return ae=Object.setPrototypeOf?Object.getPrototypeOf:function(xe){return xe.__proto__||Object.getPrototypeOf(xe)},ae(se)}function pe(se,Ce){var xe="data-clipboard-".concat(se);if(Ce.hasAttribute(xe))return Ce.getAttribute(xe)}var Qe=function(se){K(xe,se);var Ce=de(xe);function xe(Ae,Oe){var Be;return A(this,xe),Be=Ce.call(this),Be.resolveOptions(Oe),Be.listenClick(Ae),Be}return H(xe,[{key:"resolveOptions",value:function(){var Oe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.action=typeof Oe.action=="function"?Oe.action:this.defaultAction,this.target=typeof Oe.target=="function"?Oe.target:this.defaultTarget,this.text=typeof Oe.text=="function"?Oe.text:this.defaultText,this.container=I(Oe.container)==="object"?Oe.container:document.body}},{key:"listenClick",value:function(Oe){var Be=this;this.listener=y()(Oe,"click",function(tt){return Be.onClick(tt)})}},{key:"onClick",value:function(Oe){var Be=Oe.delegateTarget||Oe.currentTarget,tt=this.action(Be)||"copy",Re=g({action:tt,container:this.container,target:this.target(Be),text:this.text(Be)});this.emit(Re?"success":"error",{action:tt,text:Re,trigger:Be,clearSelection:function(){Be&&Be.focus(),window.getSelection().removeAllRanges()}})}},{key:"defaultAction",value:function(Oe){return pe("action",Oe)}},{key:"defaultTarget",value:function(Oe){var Be=pe("target",Oe);if(Be)return document.querySelector(Be)}},{key:"defaultText",value:function(Oe){return pe("text",Oe)}},{key:"destroy",value:function(){this.listener.destroy()}}],[{key:"copy",value:function(Oe){var Be=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body};return x(Oe,Be)}},{key:"cut",value:function(Oe){return L(Oe)}},{key:"isSupported",value:function(){var Oe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:["copy","cut"],Be=typeof Oe=="string"?[Oe]:Oe,tt=!!document.queryCommandSupported;return Be.forEach(function(Re){tt=tt&&!!document.queryCommandSupported(Re)}),tt}}]),xe}(d()),et=Qe},828:function(o){var s=9;if(typeof Element<"u"&&!Element.prototype.matches){var l=Element.prototype;l.matches=l.matchesSelector||l.mozMatchesSelector||l.msMatchesSelector||l.oMatchesSelector||l.webkitMatchesSelector}function c(d,p){for(;d&&d.nodeType!==s;){if(typeof d.matches=="function"&&d.matches(p))return d;d=d.parentNode}}o.exports=c},438:function(o,s,l){var c=l(828);function d(m,C,b,k,L){var O=y.apply(this,arguments);return m.addEventListener(b,O,L),{destroy:function(){m.removeEventListener(b,O,L)}}}function p(m,C,b,k,L){return typeof m.addEventListener=="function"?d.apply(null,arguments):typeof b=="function"?d.bind(null,document).apply(null,arguments):(typeof m=="string"&&(m=document.querySelectorAll(m)),Array.prototype.map.call(m,function(O){return d(O,C,b,k,L)}))}function y(m,C,b,k){return function(L){L.delegateTarget=c(L.target,C),L.delegateTarget&&k.call(m,L)}}o.exports=p},879:function(o,s){s.node=function(l){return l!==void 0&&l instanceof HTMLElement&&l.nodeType===1},s.nodeList=function(l){var c=Object.prototype.toString.call(l);return l!==void 0&&(c==="[object NodeList]"||c==="[object HTMLCollection]")&&"length"in l&&(l.length===0||s.node(l[0]))},s.string=function(l){return typeof l=="string"||l instanceof String},s.fn=function(l){var c=Object.prototype.toString.call(l);return c==="[object Function]"}},370:function(o,s,l){var c=l(879),d=l(438);function p(b,k,L){if(!b&&!k&&!L)throw new Error("Missing required arguments");if(!c.string(k))throw new TypeError("Second argument must be a String");if(!c.fn(L))throw new TypeError("Third argument must be a Function");if(c.node(b))return y(b,k,L);if(c.nodeList(b))return m(b,k,L);if(c.string(b))return C(b,k,L);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}function y(b,k,L){return b.addEventListener(k,L),{destroy:function(){b.removeEventListener(k,L)}}}function m(b,k,L){return Array.prototype.forEach.call(b,function(O){O.addEventListener(k,L)}),{destroy:function(){Array.prototype.forEach.call(b,function(O){O.removeEventListener(k,L)})}}}function C(b,k,L){return d(document.body,b,k,L)}o.exports=p},817:function(o){function s(l){var c;if(l.nodeName==="SELECT")l.focus(),c=l.value;else if(l.nodeName==="INPUT"||l.nodeName==="TEXTAREA"){var d=l.hasAttribute("readonly");d||l.setAttribute("readonly",""),l.select(),l.setSelectionRange(0,l.value.length),d||l.removeAttribute("readonly"),c=l.value}else{l.hasAttribute("contenteditable")&&l.focus();var p=window.getSelection(),y=document.createRange();y.selectNodeContents(l),p.removeAllRanges(),p.addRange(y),c=p.toString()}return c}o.exports=s},279:function(o){function s(){}s.prototype={on:function(l,c,d){var p=this.e||(this.e={});return(p[l]||(p[l]=[])).push({fn:c,ctx:d}),this},once:function(l,c,d){var p=this;function y(){p.off(l,y),c.apply(d,arguments)}return y._=c,this.on(l,y,d)},emit:function(l){var c=[].slice.call(arguments,1),d=((this.e||(this.e={}))[l]||[]).slice(),p=0,y=d.length;for(p;p<y;p++)d[p].fn.apply(d[p].ctx,c);return this},off:function(l,c){var d=this.e||(this.e={}),p=d[l],y=[];if(p&&c)for(var m=0,C=p.length;m<C;m++)p[m].fn!==c&&p[m].fn._!==c&&y.push(p[m]);return y.length?d[l]=y:delete d[l],this}},o.exports=s,o.exports.TinyEmitter=s}},r={};function i(o){if(r[o])return r[o].exports;var s=r[o]={exports:{}};return n[o](s,s.exports,i),s.exports}return function(){i.n=function(o){var s=o&&o.__esModule?function(){return o.default}:function(){return o};return i.d(s,{a:s}),s}}(),function(){i.d=function(o,s){for(var l in s)i.o(s,l)&&!i.o(o,l)&&Object.defineProperty(o,l,{enumerable:!0,get:s[l]})}}(),function(){i.o=function(o,s){return Object.prototype.hasOwnProperty.call(o,s)}}(),i(686)}().default})})(A0);var hH=A0.exports;const gH=Bl(hH),mH=e=>{const t=(e==null?void 0:e.appendToBody)===void 0?!0:e.appendToBody;return{toClipboard(n,r){return new Promise((i,o)=>{const s=document.createElement("button"),l=new gH(s,{text:()=>n,action:()=>"copy",container:r!==void 0?r:document.body});l.on("success",c=>{l.destroy(),i(c)}),l.on("error",c=>{l.destroy(),o(c)}),t&&document.body.appendChild(s),s.click(),t&&document.body.removeChild(s)})}}};function E0(e,t){return function(){return e.apply(t,arguments)}}const{toString:vH}=Object.prototype,{getPrototypeOf:Md}=Object,xu=(e=>t=>{const n=vH.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Br=e=>(e=e.toLowerCase(),t=>xu(t)===e),Su=e=>t=>typeof t===e,{isArray:fs}=Array,Ea=Su("undefined");function yH(e){return e!==null&&!Ea(e)&&e.constructor!==null&&!Ea(e.constructor)&&hr(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const L0=Br("ArrayBuffer");function bH(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&L0(e.buffer),t}const CH=Su("string"),hr=Su("function"),O0=Su("number"),Au=e=>e!==null&&typeof e=="object",_H=e=>e===!0||e===!1,Eu=e=>{if(xu(e)!=="object")return!1;const t=Md(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},wH=Br("Date"),TH=Br("File"),kH=Br("Blob"),xH=Br("FileList"),SH=e=>Au(e)&&hr(e.pipe),AH=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||hr(e.append)&&((t=xu(e))==="formdata"||t==="object"&&hr(e.toString)&&e.toString()==="[object FormData]"))},EH=Br("URLSearchParams"),LH=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function La(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,i;if(typeof e!="object"&&(e=[e]),fs(e))for(r=0,i=e.length;r<i;r++)t.call(null,e[r],r,e);else{const o=n?Object.getOwnPropertyNames(e):Object.keys(e),s=o.length;let l;for(r=0;r<s;r++)l=o[r],t.call(null,e[l],l,e)}}function I0(e,t){t=t.toLowerCase();const n=Object.keys(e);let r=n.length,i;for(;r-- >0;)if(i=n[r],t===i.toLowerCase())return i;return null}const P0=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),D0=e=>!Ea(e)&&e!==P0;function Fd(){const{caseless:e}=D0(this)&&this||{},t={},n=(r,i)=>{const o=e&&I0(t,i)||i;Eu(t[o])&&Eu(r)?t[o]=Fd(t[o],r):Eu(r)?t[o]=Fd({},r):fs(r)?t[o]=r.slice():t[o]=r};for(let r=0,i=arguments.length;r<i;r++)arguments[r]&&La(arguments[r],n);return t}const OH=(e,t,n,{allOwnKeys:r}={})=>(La(t,(i,o)=>{n&&hr(i)?e[o]=E0(i,n):e[o]=i},{allOwnKeys:r}),e),IH=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),PH=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},DH=(e,t,n,r)=>{let i,o,s;const l={};if(t=t||{},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),o=i.length;o-- >0;)s=i[o],(!r||r(s,e,t))&&!l[s]&&(t[s]=e[s],l[s]=!0);e=n!==!1&&Md(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},RH=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},NH=e=>{if(!e)return null;if(fs(e))return e;let t=e.length;if(!O0(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},MH=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Md(Uint8Array)),FH=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let i;for(;(i=r.next())&&!i.done;){const o=i.value;t.call(e,o[0],o[1])}},BH=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},$H=Br("HTMLFormElement"),HH=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,i){return r.toUpperCase()+i}),R0=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),jH=Br("RegExp"),N0=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};La(n,(i,o)=>{let s;(s=t(i,o,e))!==!1&&(r[o]=s||i)}),Object.defineProperties(e,r)},UH=e=>{N0(e,(t,n)=>{if(hr(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(hr(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},WH=(e,t)=>{const n={},r=i=>{i.forEach(o=>{n[o]=!0})};return fs(e)?r(e):r(String(e).split(t)),n},KH=()=>{},VH=(e,t)=>(e=+e,Number.isFinite(e)?e:t),Bd="abcdefghijklmnopqrstuvwxyz",M0="0123456789",F0={DIGIT:M0,ALPHA:Bd,ALPHA_DIGIT:Bd+Bd.toUpperCase()+M0},qH=(e=16,t=F0.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n};function zH(e){return!!(e&&hr(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const GH=e=>{const t=new Array(10),n=(r,i)=>{if(Au(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[i]=r;const o=fs(r)?[]:{};return La(r,(s,l)=>{const c=n(s,i+1);!Ea(c)&&(o[l]=c)}),t[i]=void 0,o}}return r};return n(e,0)},YH=Br("AsyncFunction"),fe={isArray:fs,isArrayBuffer:L0,isBuffer:yH,isFormData:AH,isArrayBufferView:bH,isString:CH,isNumber:O0,isBoolean:_H,isObject:Au,isPlainObject:Eu,isUndefined:Ea,isDate:wH,isFile:TH,isBlob:kH,isRegExp:jH,isFunction:hr,isStream:SH,isURLSearchParams:EH,isTypedArray:MH,isFileList:xH,forEach:La,merge:Fd,extend:OH,trim:LH,stripBOM:IH,inherits:PH,toFlatObject:DH,kindOf:xu,kindOfTest:Br,endsWith:RH,toArray:NH,forEachEntry:FH,matchAll:BH,isHTMLForm:$H,hasOwnProperty:R0,hasOwnProp:R0,reduceDescriptors:N0,freezeMethods:UH,toObjectSet:WH,toCamelCase:HH,noop:KH,toFiniteNumber:VH,findKey:I0,global:P0,isContextDefined:D0,ALPHABET:F0,generateString:qH,isSpecCompliantForm:zH,toJSONObject:GH,isAsyncFn:YH,isThenable:e=>e&&(Au(e)||hr(e))&&hr(e.then)&&hr(e.catch)};function wt(e,t,n,r,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i)}fe.inherits(wt,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:fe.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const B0=wt.prototype,$0={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{$0[e]={value:e}}),Object.defineProperties(wt,$0),Object.defineProperty(B0,"isAxiosError",{value:!0}),wt.from=(e,t,n,r,i,o)=>{const s=Object.create(B0);return fe.toFlatObject(e,s,function(c){return c!==Error.prototype},l=>l!=="isAxiosError"),wt.call(s,e.message,t,n,r,i),s.cause=e,s.name=e.name,o&&Object.assign(s,o),s};const XH=null;function $d(e){return fe.isPlainObject(e)||fe.isArray(e)}function H0(e){return fe.endsWith(e,"[]")?e.slice(0,-2):e}function j0(e,t,n){return e?e.concat(t).map(function(i,o){return i=H0(i),!n&&o?"["+i+"]":i}).join(n?".":""):t}function JH(e){return fe.isArray(e)&&!e.some($d)}const ZH=fe.toFlatObject(fe,{},null,function(t){return/^is[A-Z]/.test(t)});function Lu(e,t,n){if(!fe.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=fe.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(k,L){return!fe.isUndefined(L[k])});const r=n.metaTokens,i=n.visitor||p,o=n.dots,s=n.indexes,c=(n.Blob||typeof Blob<"u"&&Blob)&&fe.isSpecCompliantForm(t);if(!fe.isFunction(i))throw new TypeError("visitor must be a function");function d(b){if(b===null)return"";if(fe.isDate(b))return b.toISOString();if(!c&&fe.isBlob(b))throw new wt("Blob is not supported. Use a Buffer instead.");return fe.isArrayBuffer(b)||fe.isTypedArray(b)?c&&typeof Blob=="function"?new Blob([b]):Buffer.from(b):b}function p(b,k,L){let O=b;if(b&&!L&&typeof b=="object"){if(fe.endsWith(k,"{}"))k=r?k:k.slice(0,-2),b=JSON.stringify(b);else if(fe.isArray(b)&&JH(b)||(fe.isFileList(b)||fe.endsWith(k,"[]"))&&(O=fe.toArray(b)))return k=H0(k),O.forEach(function(X,x){!(fe.isUndefined(X)||X===null)&&t.append(s===!0?j0([k],x,o):s===null?k:k+"[]",d(X))}),!1}return $d(b)?!0:(t.append(j0(L,k,o),d(b)),!1)}const y=[],m=Object.assign(ZH,{defaultVisitor:p,convertValue:d,isVisitable:$d});function C(b,k){if(!fe.isUndefined(b)){if(y.indexOf(b)!==-1)throw Error("Circular reference detected in "+k.join("."));y.push(b),fe.forEach(b,function(O,$){(!(fe.isUndefined(O)||O===null)&&i.call(t,O,fe.isString($)?$.trim():$,k,m))===!0&&C(O,k?k.concat($):[$])}),y.pop()}}if(!fe.isObject(e))throw new TypeError("data must be an object");return C(e),t}function U0(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Hd(e,t){this._pairs=[],e&&Lu(e,this,t)}const W0=Hd.prototype;W0.append=function(t,n){this._pairs.push([t,n])},W0.toString=function(t){const n=t?function(r){return t.call(this,r,U0)}:U0;return this._pairs.map(function(i){return n(i[0])+"="+n(i[1])},"").join("&")};function QH(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function K0(e,t,n){if(!t)return e;const r=n&&n.encode||QH,i=n&&n.serialize;let o;if(i?o=i(t,n):o=fe.isURLSearchParams(t)?t.toString():new Hd(t,n).toString(r),o){const s=e.indexOf("#");s!==-1&&(e=e.slice(0,s)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class ej{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){fe.forEach(this.handlers,function(r){r!==null&&t(r)})}}const V0=ej,q0={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},tj=typeof URLSearchParams<"u"?URLSearchParams:Hd,nj=typeof FormData<"u"?FormData:null,rj=typeof Blob<"u"?Blob:null,ij=(()=>{let e;return typeof navigator<"u"&&((e=navigator.product)==="ReactNative"||e==="NativeScript"||e==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),oj=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),Tr={isBrowser:!0,classes:{URLSearchParams:tj,FormData:nj,Blob:rj},isStandardBrowserEnv:ij,isStandardBrowserWebWorkerEnv:oj,protocols:["http","https","file","blob","url","data"]};function sj(e,t){return Lu(e,new Tr.classes.URLSearchParams,Object.assign({visitor:function(n,r,i,o){return Tr.isNode&&fe.isBuffer(n)?(this.append(r,n.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)}},t))}function aj(e){return fe.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function lj(e){const t={},n=Object.keys(e);let r;const i=n.length;let o;for(r=0;r<i;r++)o=n[r],t[o]=e[o];return t}function z0(e){function t(n,r,i,o){let s=n[o++];const l=Number.isFinite(+s),c=o>=n.length;return s=!s&&fe.isArray(i)?i.length:s,c?(fe.hasOwnProp(i,s)?i[s]=[i[s],r]:i[s]=r,!l):((!i[s]||!fe.isObject(i[s]))&&(i[s]=[]),t(n,r,i[s],o)&&fe.isArray(i[s])&&(i[s]=lj(i[s])),!l)}if(fe.isFormData(e)&&fe.isFunction(e.entries)){const n={};return fe.forEachEntry(e,(r,i)=>{t(aj(r),i,n,0)}),n}return null}function uj(e,t,n){if(fe.isString(e))try{return(t||JSON.parse)(e),fe.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const jd={transitional:q0,adapter:Tr.isNode?"http":"xhr",transformRequest:[function(t,n){const r=n.getContentType()||"",i=r.indexOf("application/json")>-1,o=fe.isObject(t);if(o&&fe.isHTMLForm(t)&&(t=new FormData(t)),fe.isFormData(t))return i&&i?JSON.stringify(z0(t)):t;if(fe.isArrayBuffer(t)||fe.isBuffer(t)||fe.isStream(t)||fe.isFile(t)||fe.isBlob(t))return t;if(fe.isArrayBufferView(t))return t.buffer;if(fe.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let l;if(o){if(r.indexOf("application/x-www-form-urlencoded")>-1)return sj(t,this.formSerializer).toString();if((l=fe.isFileList(t))||r.indexOf("multipart/form-data")>-1){const c=this.env&&this.env.FormData;return Lu(l?{"files[]":t}:t,c&&new c,this.formSerializer)}}return o||i?(n.setContentType("application/json",!1),uj(t)):t}],transformResponse:[function(t){const n=this.transitional||jd.transitional,r=n&&n.forcedJSONParsing,i=this.responseType==="json";if(t&&fe.isString(t)&&(r&&!this.responseType||i)){const s=!(n&&n.silentJSONParsing)&&i;try{return JSON.parse(t)}catch(l){if(s)throw l.name==="SyntaxError"?wt.from(l,wt.ERR_BAD_RESPONSE,this,null,this.response):l}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Tr.classes.FormData,Blob:Tr.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};fe.forEach(["delete","get","head","post","put","patch"],e=>{jd.headers[e]={}});const Ud=jd,cj=fe.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),fj=e=>{const t={};let n,r,i;return e&&e.split(`
|
||
`).forEach(function(s){i=s.indexOf(":"),n=s.substring(0,i).trim().toLowerCase(),r=s.substring(i+1).trim(),!(!n||t[n]&&cj[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},G0=Symbol("internals");function Oa(e){return e&&String(e).trim().toLowerCase()}function Ou(e){return e===!1||e==null?e:fe.isArray(e)?e.map(Ou):String(e)}function dj(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const pj=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Wd(e,t,n,r,i){if(fe.isFunction(r))return r.call(this,t,n);if(i&&(t=n),!!fe.isString(t)){if(fe.isString(r))return t.indexOf(r)!==-1;if(fe.isRegExp(r))return r.test(t)}}function hj(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function gj(e,t){const n=fe.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(i,o,s){return this[r].call(this,t,i,o,s)},configurable:!0})})}class Iu{constructor(t){t&&this.set(t)}set(t,n,r){const i=this;function o(l,c,d){const p=Oa(c);if(!p)throw new Error("header name must be a non-empty string");const y=fe.findKey(i,p);(!y||i[y]===void 0||d===!0||d===void 0&&i[y]!==!1)&&(i[y||c]=Ou(l))}const s=(l,c)=>fe.forEach(l,(d,p)=>o(d,p,c));return fe.isPlainObject(t)||t instanceof this.constructor?s(t,n):fe.isString(t)&&(t=t.trim())&&!pj(t)?s(fj(t),n):t!=null&&o(n,t,r),this}get(t,n){if(t=Oa(t),t){const r=fe.findKey(this,t);if(r){const i=this[r];if(!n)return i;if(n===!0)return dj(i);if(fe.isFunction(n))return n.call(this,i,r);if(fe.isRegExp(n))return n.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Oa(t),t){const r=fe.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Wd(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let i=!1;function o(s){if(s=Oa(s),s){const l=fe.findKey(r,s);l&&(!n||Wd(r,r[l],l,n))&&(delete r[l],i=!0)}}return fe.isArray(t)?t.forEach(o):o(t),i}clear(t){const n=Object.keys(this);let r=n.length,i=!1;for(;r--;){const o=n[r];(!t||Wd(this,this[o],o,t,!0))&&(delete this[o],i=!0)}return i}normalize(t){const n=this,r={};return fe.forEach(this,(i,o)=>{const s=fe.findKey(r,o);if(s){n[s]=Ou(i),delete n[o];return}const l=t?hj(o):String(o).trim();l!==o&&delete n[o],n[l]=Ou(i),r[l]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return fe.forEach(this,(r,i)=>{r!=null&&r!==!1&&(n[i]=t&&fe.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
|
||
`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(i=>r.set(i)),r}static accessor(t){const r=(this[G0]=this[G0]={accessors:{}}).accessors,i=this.prototype;function o(s){const l=Oa(s);r[l]||(gj(i,s),r[l]=!0)}return fe.isArray(t)?t.forEach(o):o(t),this}}Iu.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),fe.reduceDescriptors(Iu.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),fe.freezeMethods(Iu);const si=Iu;function Kd(e,t){const n=this||Ud,r=t||n,i=si.from(r.headers);let o=r.data;return fe.forEach(e,function(l){o=l.call(n,o,i.normalize(),t?t.status:void 0)}),i.normalize(),o}function Y0(e){return!!(e&&e.__CANCEL__)}function Ia(e,t,n){wt.call(this,e??"canceled",wt.ERR_CANCELED,t,n),this.name="CanceledError"}fe.inherits(Ia,wt,{__CANCEL__:!0});function mj(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new wt("Request failed with status code "+n.status,[wt.ERR_BAD_REQUEST,wt.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}const vj=Tr.isStandardBrowserEnv?function(){return{write:function(n,r,i,o,s,l){const c=[];c.push(n+"="+encodeURIComponent(r)),fe.isNumber(i)&&c.push("expires="+new Date(i).toGMTString()),fe.isString(o)&&c.push("path="+o),fe.isString(s)&&c.push("domain="+s),l===!0&&c.push("secure"),document.cookie=c.join("; ")},read:function(n){const r=document.cookie.match(new RegExp("(^|;\\s*)("+n+")=([^;]*)"));return r?decodeURIComponent(r[3]):null},remove:function(n){this.write(n,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function yj(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function bj(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}function X0(e,t){return e&&!yj(t)?bj(e,t):t}const Cj=Tr.isStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let r;function i(o){let s=o;return t&&(n.setAttribute("href",s),s=n.href),n.setAttribute("href",s),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=i(window.location.href),function(s){const l=fe.isString(s)?i(s):s;return l.protocol===r.protocol&&l.host===r.host}}():function(){return function(){return!0}}();function _j(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function wj(e,t){e=e||10;const n=new Array(e),r=new Array(e);let i=0,o=0,s;return t=t!==void 0?t:1e3,function(c){const d=Date.now(),p=r[o];s||(s=d),n[i]=c,r[i]=d;let y=o,m=0;for(;y!==i;)m+=n[y++],y=y%e;if(i=(i+1)%e,i===o&&(o=(o+1)%e),d-s<t)return;const C=p&&d-p;return C?Math.round(m*1e3/C):void 0}}function J0(e,t){let n=0;const r=wj(50,250);return i=>{const o=i.loaded,s=i.lengthComputable?i.total:void 0,l=o-n,c=r(l),d=o<=s;n=o;const p={loaded:o,total:s,progress:s?o/s:void 0,bytes:l,rate:c||void 0,estimated:c&&s&&d?(s-o)/c:void 0,event:i};p[t?"download":"upload"]=!0,e(p)}}const Pu={http:XH,xhr:typeof XMLHttpRequest<"u"&&function(e){return new Promise(function(n,r){let i=e.data;const o=si.from(e.headers).normalize(),s=e.responseType;let l;function c(){e.cancelToken&&e.cancelToken.unsubscribe(l),e.signal&&e.signal.removeEventListener("abort",l)}fe.isFormData(i)&&(Tr.isStandardBrowserEnv||Tr.isStandardBrowserWebWorkerEnv?o.setContentType(!1):o.setContentType("multipart/form-data;",!1));let d=new XMLHttpRequest;if(e.auth){const C=e.auth.username||"",b=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";o.set("Authorization","Basic "+btoa(C+":"+b))}const p=X0(e.baseURL,e.url);d.open(e.method.toUpperCase(),K0(p,e.params,e.paramsSerializer),!0),d.timeout=e.timeout;function y(){if(!d)return;const C=si.from("getAllResponseHeaders"in d&&d.getAllResponseHeaders()),k={data:!s||s==="text"||s==="json"?d.responseText:d.response,status:d.status,statusText:d.statusText,headers:C,config:e,request:d};mj(function(O){n(O),c()},function(O){r(O),c()},k),d=null}if("onloadend"in d?d.onloadend=y:d.onreadystatechange=function(){!d||d.readyState!==4||d.status===0&&!(d.responseURL&&d.responseURL.indexOf("file:")===0)||setTimeout(y)},d.onabort=function(){d&&(r(new wt("Request aborted",wt.ECONNABORTED,e,d)),d=null)},d.onerror=function(){r(new wt("Network Error",wt.ERR_NETWORK,e,d)),d=null},d.ontimeout=function(){let b=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const k=e.transitional||q0;e.timeoutErrorMessage&&(b=e.timeoutErrorMessage),r(new wt(b,k.clarifyTimeoutError?wt.ETIMEDOUT:wt.ECONNABORTED,e,d)),d=null},Tr.isStandardBrowserEnv){const C=(e.withCredentials||Cj(p))&&e.xsrfCookieName&&vj.read(e.xsrfCookieName);C&&o.set(e.xsrfHeaderName,C)}i===void 0&&o.setContentType(null),"setRequestHeader"in d&&fe.forEach(o.toJSON(),function(b,k){d.setRequestHeader(k,b)}),fe.isUndefined(e.withCredentials)||(d.withCredentials=!!e.withCredentials),s&&s!=="json"&&(d.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&d.addEventListener("progress",J0(e.onDownloadProgress,!0)),typeof e.onUploadProgress=="function"&&d.upload&&d.upload.addEventListener("progress",J0(e.onUploadProgress)),(e.cancelToken||e.signal)&&(l=C=>{d&&(r(!C||C.type?new Ia(null,e,d):C),d.abort(),d=null)},e.cancelToken&&e.cancelToken.subscribe(l),e.signal&&(e.signal.aborted?l():e.signal.addEventListener("abort",l)));const m=_j(p);if(m&&Tr.protocols.indexOf(m)===-1){r(new wt("Unsupported protocol "+m+":",wt.ERR_BAD_REQUEST,e));return}d.send(i||null)})}};fe.forEach(Pu,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Z0={getAdapter:e=>{e=fe.isArray(e)?e:[e];const{length:t}=e;let n,r;for(let i=0;i<t&&(n=e[i],!(r=fe.isString(n)?Pu[n.toLowerCase()]:n));i++);if(!r)throw r===!1?new wt(`Adapter ${n} is not supported by the environment`,"ERR_NOT_SUPPORT"):new Error(fe.hasOwnProp(Pu,n)?`Adapter '${n}' is not available in the build`:`Unknown adapter '${n}'`);if(!fe.isFunction(r))throw new TypeError("adapter is not a function");return r},adapters:Pu};function Vd(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ia(null,e)}function Q0(e){return Vd(e),e.headers=si.from(e.headers),e.data=Kd.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Z0.getAdapter(e.adapter||Ud.adapter)(e).then(function(r){return Vd(e),r.data=Kd.call(e,e.transformResponse,r),r.headers=si.from(r.headers),r},function(r){return Y0(r)||(Vd(e),r&&r.response&&(r.response.data=Kd.call(e,e.transformResponse,r.response),r.response.headers=si.from(r.response.headers))),Promise.reject(r)})}const eb=e=>e instanceof si?e.toJSON():e;function ds(e,t){t=t||{};const n={};function r(d,p,y){return fe.isPlainObject(d)&&fe.isPlainObject(p)?fe.merge.call({caseless:y},d,p):fe.isPlainObject(p)?fe.merge({},p):fe.isArray(p)?p.slice():p}function i(d,p,y){if(fe.isUndefined(p)){if(!fe.isUndefined(d))return r(void 0,d,y)}else return r(d,p,y)}function o(d,p){if(!fe.isUndefined(p))return r(void 0,p)}function s(d,p){if(fe.isUndefined(p)){if(!fe.isUndefined(d))return r(void 0,d)}else return r(void 0,p)}function l(d,p,y){if(y in t)return r(d,p);if(y in e)return r(void 0,d)}const c={url:o,method:o,data:o,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:l,headers:(d,p)=>i(eb(d),eb(p),!0)};return fe.forEach(Object.keys(Object.assign({},e,t)),function(p){const y=c[p]||i,m=y(e[p],t[p],p);fe.isUndefined(m)&&y!==l||(n[p]=m)}),n}const tb="1.5.0",qd={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{qd[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const nb={};qd.transitional=function(t,n,r){function i(o,s){return"[Axios v"+tb+"] Transitional option '"+o+"'"+s+(r?". "+r:"")}return(o,s,l)=>{if(t===!1)throw new wt(i(s," has been removed"+(n?" in "+n:"")),wt.ERR_DEPRECATED);return n&&!nb[s]&&(nb[s]=!0,console.warn(i(s," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(o,s,l):!0}};function Tj(e,t,n){if(typeof e!="object")throw new wt("options must be an object",wt.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let i=r.length;for(;i-- >0;){const o=r[i],s=t[o];if(s){const l=e[o],c=l===void 0||s(l,o,e);if(c!==!0)throw new wt("option "+o+" must be "+c,wt.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new wt("Unknown option "+o,wt.ERR_BAD_OPTION)}}const zd={assertOptions:Tj,validators:qd},Ei=zd.validators;class Du{constructor(t){this.defaults=t,this.interceptors={request:new V0,response:new V0}}request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=ds(this.defaults,n);const{transitional:r,paramsSerializer:i,headers:o}=n;r!==void 0&&zd.assertOptions(r,{silentJSONParsing:Ei.transitional(Ei.boolean),forcedJSONParsing:Ei.transitional(Ei.boolean),clarifyTimeoutError:Ei.transitional(Ei.boolean)},!1),i!=null&&(fe.isFunction(i)?n.paramsSerializer={serialize:i}:zd.assertOptions(i,{encode:Ei.function,serialize:Ei.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let s=o&&fe.merge(o.common,o[n.method]);o&&fe.forEach(["delete","get","head","post","put","patch","common"],b=>{delete o[b]}),n.headers=si.concat(s,o);const l=[];let c=!0;this.interceptors.request.forEach(function(k){typeof k.runWhen=="function"&&k.runWhen(n)===!1||(c=c&&k.synchronous,l.unshift(k.fulfilled,k.rejected))});const d=[];this.interceptors.response.forEach(function(k){d.push(k.fulfilled,k.rejected)});let p,y=0,m;if(!c){const b=[Q0.bind(this),void 0];for(b.unshift.apply(b,l),b.push.apply(b,d),m=b.length,p=Promise.resolve(n);y<m;)p=p.then(b[y++],b[y++]);return p}m=l.length;let C=n;for(y=0;y<m;){const b=l[y++],k=l[y++];try{C=b(C)}catch(L){k.call(this,L);break}}try{p=Q0.call(this,C)}catch(b){return Promise.reject(b)}for(y=0,m=d.length;y<m;)p=p.then(d[y++],d[y++]);return p}getUri(t){t=ds(this.defaults,t);const n=X0(t.baseURL,t.url);return K0(n,t.params,t.paramsSerializer)}}fe.forEach(["delete","get","head","options"],function(t){Du.prototype[t]=function(n,r){return this.request(ds(r||{},{method:t,url:n,data:(r||{}).data}))}}),fe.forEach(["post","put","patch"],function(t){function n(r){return function(o,s,l){return this.request(ds(l||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:o,data:s}))}}Du.prototype[t]=n(),Du.prototype[t+"Form"]=n(!0)});const Ru=Du;class Gd{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(o){n=o});const r=this;this.promise.then(i=>{if(!r._listeners)return;let o=r._listeners.length;for(;o-- >0;)r._listeners[o](i);r._listeners=null}),this.promise.then=i=>{let o;const s=new Promise(l=>{r.subscribe(l),o=l}).then(i);return s.cancel=function(){r.unsubscribe(o)},s},t(function(o,s,l){r.reason||(r.reason=new Ia(o,s,l),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}static source(){let t;return{token:new Gd(function(i){t=i}),cancel:t}}}const kj=Gd;function xj(e){return function(n){return e.apply(null,n)}}function Sj(e){return fe.isObject(e)&&e.isAxiosError===!0}const Yd={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Yd).forEach(([e,t])=>{Yd[t]=e});const Aj=Yd;function rb(e){const t=new Ru(e),n=E0(Ru.prototype.request,t);return fe.extend(n,Ru.prototype,t,{allOwnKeys:!0}),fe.extend(n,t,null,{allOwnKeys:!0}),n.create=function(i){return rb(ds(e,i))},n}const Qt=rb(Ud);Qt.Axios=Ru,Qt.CanceledError=Ia,Qt.CancelToken=kj,Qt.isCancel=Y0,Qt.VERSION=tb,Qt.toFormData=Lu,Qt.AxiosError=wt,Qt.Cancel=Qt.CanceledError,Qt.all=function(t){return Promise.all(t)},Qt.spread=xj,Qt.isAxiosError=Sj,Qt.mergeConfig=ds,Qt.AxiosHeaders=si,Qt.formToJSON=e=>z0(fe.isHTMLForm(e)?new FormData(e):e),Qt.getAdapter=Z0.getAdapter,Qt.HttpStatusCode=Aj,Qt.default=Qt;const Ej=Qt;class Lj{constructor(){Gb(this,"apiBaseURL","");this.apiBaseURL=he.apiUrl(),this.api=Ej.create({baseURL:this.apiBaseURL,timeout:6e4,headers:{"Content-Type":"application/json"}})}async getVersion(){return(await this.api.get("/get_version")).data}async getRemoteVersions(t=1,n=100){return(await this.api.get("/get_remote_versions",{params:{page:t,per_page:n}})).data.versions}async getConfig(){return(await this.api.get("/get_config")).data}async installPackage(t,n){const r={timeout:1e7};return(await this.api.post("/install_package",{name:t,package:n},r)).data.result}async getExtensions(){return(await this.api.get("/get_extensions")).data.extensions}async tokenCounter(t,n){return(await this.api.post("/token_counter",{text:t,steps:n})).data}async getData(t){return(await this.api.get("/get_data",{params:{key:t}})).data.data}async getDatas(t){return typeof t=="object"&&(t=t.join(",")),(await this.api.get("/get_datas",{params:{keys:t}})).data.datas}async setData(t,n){return(await this.api.post("/set_data",{key:t,data:n})).data.success}async setDatas(t){return(await this.api.post("/set_datas",{datas:t})).data.success}async getDataListItem(t,n){return(await this.api.get("/get_data_list_item",{params:{key:t,index:n}})).data.item}async pushDataList(t,n){return(await this.api.post("/push_data_list",{key:t,item:n})).data.success}async popDataList(t){return(await this.api.post("/pop_data_list",{key:t})).data.item}async shiftDataList(t){return(await this.api.post("/shift_data_list",{key:t})).data.item}async removeDataList(t,n){return(await this.api.post("/remove_data_list",{key:t,index:n})).data.success}async clearDataList(t){return(await this.api.post("/clear_data_list",{key:t})).data.success}async getHistories(t){return(await this.api.get("/get_histories",{params:{type:t}})).data.histories}async getFavorites(t){return(await this.api.get("/get_favorites",{params:{type:t}})).data.favorites}async pushHistory(t,n,r,i=""){return(await this.api.post("/push_history",{type:t,tags:n,prompt:r,name:i})).data.success}async pushFavorite(t,n,r,i=""){return(await this.api.post("/push_favorite",{type:t,tags:n,prompt:r,name:i})).data.success}async getLatestHistory(t){return(await this.api.get("/get_latest_history",{params:{type:t}})).data.history}async setHistory(t,n,r,i,o){return(await this.api.post("/set_history",{type:t,id:n,tags:r,prompt:i,name:o})).data.success}async setHistoryName(t,n,r){return(await this.api.post("/set_history_name",{type:t,id:n,name:r})).data.success}async setFavoriteName(t,n,r){return(await this.api.post("/set_favorite_name",{type:t,id:n,name:r})).data.success}async doFavorite(t,n){return(await this.api.post("/dofavorite",{type:t,id:n})).data.success}async unFavorite(t,n){return(await this.api.post("/unfavorite",{type:t,id:n})).data.success}async deleteHistory(t,n){return(await this.api.post("/delete_history",{type:t,id:n})).data.success}async deleteHistories(t){return(await this.api.post("/delete_histories",{type:t})).data.success}async translate(t,n,r,i,o={}){let s=(await this.api.post("/translate",{text:t,from_lang:n,to_lang:r,api:i,api_config:o})).data;return s.translated_text&&(s.translated_text=he.unescapeHtml(s.translated_text)),s}async translates(t,n,r,i,o={}){let s=(await this.api.post("/translates",{texts:t,from_lang:n,to_lang:r,api:i,api_config:o})).data;return s.translated_text&&s.translated_text.forEach((l,c)=>{s.translated_text[c]=he.unescapeHtml(l)}),s}async getCSVs(){return(await this.api.get("/get_csvs")).data.csvs}async getCSV(t){return(await this.api.get("/get_csv",{params:{key:t}})).data}async styles(t,n=""){return(await this.api.get("/styles",{params:{file:t,hash:n}})).data}async getExtensionCssList(){return(await this.api.get("/get_extension_css_list")).data.css_list}async getExtraNetworks(){return(await this.api.get("/get_extra_networks")).data.extra_networks}async genOpenAI(t,n){return(await this.api.post("/gen_openai",{messages:t,api_config:n})).data}async mbart50Initialize(){const t={timeout:1e11};return(await this.api.post("/mbart50_initialize",{},t)).data}async getGroupTags(t){return(await this.api.get("/get_group_tags",{params:{lang:t}})).data.tags}}const Oj={data(){return{gradioAPI:null}},beforeMount(){this.gradioAPI=new Lj},methods:{loadExtraNetworks(){this.gradioAPI.getExtraNetworks().then(e=>{e&&(this.extraNetworks=e,e.forEach(t=>{if(t.name==="textual inversion"){let n={};t.items.forEach(r=>{n[r.name.toLowerCase()]=r.name}),this.embeddings=n}else if(t.name==="lora"||t.name==="lycoris"){let n={};t.items.forEach(r=>{n[r.name.toLowerCase()]=r.name,r.output_name&&(n[r.output_name.toLowerCase()]=r.name)}),t.name==="lora"?this.loras=n:this.lycos=n}}))})},getExtraNetworkFullName(e,t="lora"){var n,r,i;if(typeof this.extraNetworks!="object")return e;for(let o of this.extraNetworks){if(o.name!==t)continue;const s=e.toLowerCase();for(let l of o.items)if(l.name.toLowerCase()===s||((n=l.output_name)==null?void 0:n.toLowerCase())===s)return(r=l.civitai_info)!=null&&r.name?(i=l.civitai_info.model)!=null&&i.name&&l.civitai_info.model.name!==l.civitai_info.name?"["+l.civitai_info.name+"] "+l.civitai_info.model.name:l.civitai_info.name:e}return e},loraExists(e){return typeof this.loras!="object"?e:this.loras[e.toLowerCase()]??!1},lycoExists(e){return typeof this.lycos!="object"?e:this.lycos[e.toLowerCase()]??!1},embeddingExists(e){return typeof this.embeddings!="object"?e:this.embeddings[e.toLowerCase()]??!1}}};var Ij="tippy-box",ib="tippy-content",Pj="tippy-backdrop",ob="tippy-arrow",sb="tippy-svg-arrow",so={passive:!0,capture:!0},ab=function(){return document.body};function Xd(e,t,n){if(Array.isArray(e)){var r=e[t];return r??(Array.isArray(n)?n[t]:n)}return e}function Jd(e,t){var n={}.toString.call(e);return n.indexOf("[object")===0&&n.indexOf(t+"]")>-1}function lb(e,t){return typeof e=="function"?e.apply(void 0,t):e}function ub(e,t){if(t===0)return e;var n;return function(r){clearTimeout(n),n=setTimeout(function(){e(r)},t)}}function Dj(e){return e.split(/\s+/).filter(Boolean)}function ps(e){return[].concat(e)}function cb(e,t){e.indexOf(t)===-1&&e.push(t)}function Rj(e){return e.filter(function(t,n){return e.indexOf(t)===n})}function Nj(e){return e.split("-")[0]}function Nu(e){return[].slice.call(e)}function fb(e){return Object.keys(e).reduce(function(t,n){return e[n]!==void 0&&(t[n]=e[n]),t},{})}function Pa(){return document.createElement("div")}function Mu(e){return["Element","Fragment"].some(function(t){return Jd(e,t)})}function Mj(e){return Jd(e,"NodeList")}function Fj(e){return Jd(e,"MouseEvent")}function Bj(e){return!!(e&&e._tippy&&e._tippy.reference===e)}function $j(e){return Mu(e)?[e]:Mj(e)?Nu(e):Array.isArray(e)?e:Nu(document.querySelectorAll(e))}function Zd(e,t){e.forEach(function(n){n&&(n.style.transitionDuration=t+"ms")})}function db(e,t){e.forEach(function(n){n&&n.setAttribute("data-state",t)})}function Hj(e){var t,n=ps(e),r=n[0];return r!=null&&(t=r.ownerDocument)!=null&&t.body?r.ownerDocument:document}function jj(e,t){var n=t.clientX,r=t.clientY;return e.every(function(i){var o=i.popperRect,s=i.popperState,l=i.props,c=l.interactiveBorder,d=Nj(s.placement),p=s.modifiersData.offset;if(!p)return!0;var y=d==="bottom"?p.top.y:0,m=d==="top"?p.bottom.y:0,C=d==="right"?p.left.x:0,b=d==="left"?p.right.x:0,k=o.top-r+y>c,L=r-o.bottom-m>c,O=o.left-n+C>c,$=n-o.right-b>c;return k||L||O||$})}function Qd(e,t,n){var r=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(i){e[r](i,n)})}function pb(e,t){for(var n=t;n;){var r;if(e.contains(n))return!0;n=n.getRootNode==null||(r=n.getRootNode())==null?void 0:r.host}return!1}var $r={isTouch:!1},hb=0;function Uj(){$r.isTouch||($r.isTouch=!0,window.performance&&document.addEventListener("mousemove",gb))}function gb(){var e=performance.now();e-hb<20&&($r.isTouch=!1,document.removeEventListener("mousemove",gb)),hb=e}function Wj(){var e=document.activeElement;if(Bj(e)){var t=e._tippy;e.blur&&!t.state.isVisible&&e.blur()}}function Kj(){document.addEventListener("touchstart",Uj,so),window.addEventListener("blur",Wj)}var Vj=typeof window<"u"&&typeof document<"u",qj=Vj?!!window.msCrypto:!1,zj={animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},Gj={allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999},kr=Object.assign({appendTo:ab,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},zj,Gj),Yj=Object.keys(kr),Xj=function(t){var n=Object.keys(t);n.forEach(function(r){kr[r]=t[r]})};function mb(e){var t=e.plugins||[],n=t.reduce(function(r,i){var o=i.name,s=i.defaultValue;if(o){var l;r[o]=e[o]!==void 0?e[o]:(l=kr[o])!=null?l:s}return r},{});return Object.assign({},e,n)}function Jj(e,t){var n=t?Object.keys(mb(Object.assign({},kr,{plugins:t}))):Yj,r=n.reduce(function(i,o){var s=(e.getAttribute("data-tippy-"+o)||"").trim();if(!s)return i;if(o==="content")i[o]=s;else try{i[o]=JSON.parse(s)}catch{i[o]=s}return i},{});return r}function vb(e,t){var n=Object.assign({},t,{content:lb(t.content,[e])},t.ignoreAttributes?{}:Jj(e,t.plugins));return n.aria=Object.assign({},kr.aria,n.aria),n.aria={expanded:n.aria.expanded==="auto"?t.interactive:n.aria.expanded,content:n.aria.content==="auto"?t.interactive?null:"describedby":n.aria.content},n}var Zj=function(){return"innerHTML"};function ep(e,t){e[Zj()]=t}function yb(e){var t=Pa();return e===!0?t.className=ob:(t.className=sb,Mu(e)?t.appendChild(e):ep(t,e)),t}function bb(e,t){Mu(t.content)?(ep(e,""),e.appendChild(t.content)):typeof t.content!="function"&&(t.allowHTML?ep(e,t.content):e.textContent=t.content)}function tp(e){var t=e.firstElementChild,n=Nu(t.children);return{box:t,content:n.find(function(r){return r.classList.contains(ib)}),arrow:n.find(function(r){return r.classList.contains(ob)||r.classList.contains(sb)}),backdrop:n.find(function(r){return r.classList.contains(Pj)})}}function Cb(e){var t=Pa(),n=Pa();n.className=Ij,n.setAttribute("data-state","hidden"),n.setAttribute("tabindex","-1");var r=Pa();r.className=ib,r.setAttribute("data-state","hidden"),bb(r,e.props),t.appendChild(n),n.appendChild(r),i(e.props,e.props);function i(o,s){var l=tp(t),c=l.box,d=l.content,p=l.arrow;s.theme?c.setAttribute("data-theme",s.theme):c.removeAttribute("data-theme"),typeof s.animation=="string"?c.setAttribute("data-animation",s.animation):c.removeAttribute("data-animation"),s.inertia?c.setAttribute("data-inertia",""):c.removeAttribute("data-inertia"),c.style.maxWidth=typeof s.maxWidth=="number"?s.maxWidth+"px":s.maxWidth,s.role?c.setAttribute("role",s.role):c.removeAttribute("role"),(o.content!==s.content||o.allowHTML!==s.allowHTML)&&bb(d,e.props),s.arrow?p?o.arrow!==s.arrow&&(c.removeChild(p),c.appendChild(yb(s.arrow))):c.appendChild(yb(s.arrow)):p&&c.removeChild(p)}return{popper:t,onUpdate:i}}Cb.$$tippy=!0;var Qj=1,Fu=[],np=[];function e3(e,t){var n=vb(e,Object.assign({},kr,mb(fb(t)))),r,i,o,s=!1,l=!1,c=!1,d=!1,p,y,m,C=[],b=ub(Y,n.interactiveDebounce),k,L=Qj++,O=null,$=Rj(n.plugins),X={isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},x={id:L,reference:e,popper:Pa(),popperInstance:O,props:n,state:X,plugins:$,clearDelayTimeouts:$e,setProps:at,setContent:lt,show:Tt,hide:Nt,hideWithInteractivity:en,enable:Ne,disable:ne,unmount:$t,destroy:Vt};if(!n.render)return x;var z=n.render(x),Q=z.popper,g=z.onUpdate;Q.setAttribute("data-tippy-root",""),Q.id="tippy-"+x.id,x.popper=Q,e._tippy=x,Q._tippy=x;var I=$.map(function(J){return J.fn(x)}),A=e.hasAttribute("aria-expanded");return dt(),Qe(),V(),ae("onCreate",[x]),n.showOnCreate&&Te(),Q.addEventListener("mouseenter",function(){x.props.interactive&&x.state.isVisible&&x.clearDelayTimeouts()}),Q.addEventListener("mouseleave",function(){x.props.interactive&&x.props.trigger.indexOf("mouseenter")>=0&&de().addEventListener("mousemove",b)}),x;function D(){var J=x.props.touch;return Array.isArray(J)?J:[J,0]}function H(){return D()[0]==="hold"}function K(){var J;return!!((J=x.props.render)!=null&&J.$$tippy)}function U(){return k||e}function de(){var J=U().parentNode;return J?Hj(J):document}function je(){return tp(Q)}function Pe(J){return x.state.isMounted&&!x.state.isVisible||$r.isTouch||p&&p.type==="focus"?0:Xd(x.props.delay,J?0:1,kr.delay)}function V(J){J===void 0&&(J=!1),Q.style.pointerEvents=x.props.interactive&&!J?"":"none",Q.style.zIndex=""+x.props.zIndex}function ae(J,Se,He){if(He===void 0&&(He=!0),I.forEach(function(mt){mt[J]&&mt[J].apply(mt,Se)}),He){var pt;(pt=x.props)[J].apply(pt,Se)}}function pe(){var J=x.props.aria;if(J.content){var Se="aria-"+J.content,He=Q.id,pt=ps(x.props.triggerTarget||e);pt.forEach(function(mt){var fn=mt.getAttribute(Se);if(x.state.isVisible)mt.setAttribute(Se,fn?fn+" "+He:He);else{var jn=fn&&fn.replace(He,"").trim();jn?mt.setAttribute(Se,jn):mt.removeAttribute(Se)}})}}function Qe(){if(!(A||!x.props.aria.expanded)){var J=ps(x.props.triggerTarget||e);J.forEach(function(Se){x.props.interactive?Se.setAttribute("aria-expanded",x.state.isVisible&&Se===U()?"true":"false"):Se.removeAttribute("aria-expanded")})}}function et(){de().removeEventListener("mousemove",b),Fu=Fu.filter(function(J){return J!==b})}function se(J){if(!($r.isTouch&&(c||J.type==="mousedown"))){var Se=J.composedPath&&J.composedPath()[0]||J.target;if(!(x.props.interactive&&pb(Q,Se))){if(ps(x.props.triggerTarget||e).some(function(He){return pb(He,Se)})){if($r.isTouch||x.state.isVisible&&x.props.trigger.indexOf("click")>=0)return}else ae("onClickOutside",[x,J]);x.props.hideOnClick===!0&&(x.clearDelayTimeouts(),x.hide(),l=!0,setTimeout(function(){l=!1}),x.state.isMounted||Oe())}}}function Ce(){c=!0}function xe(){c=!1}function Ae(){var J=de();J.addEventListener("mousedown",se,!0),J.addEventListener("touchend",se,so),J.addEventListener("touchstart",xe,so),J.addEventListener("touchmove",Ce,so)}function Oe(){var J=de();J.removeEventListener("mousedown",se,!0),J.removeEventListener("touchend",se,so),J.removeEventListener("touchstart",xe,so),J.removeEventListener("touchmove",Ce,so)}function Be(J,Se){Re(J,function(){!x.state.isVisible&&Q.parentNode&&Q.parentNode.contains(Q)&&Se()})}function tt(J,Se){Re(J,Se)}function Re(J,Se){var He=je().box;function pt(mt){mt.target===He&&(Qd(He,"remove",pt),Se())}if(J===0)return Se();Qd(He,"remove",y),Qd(He,"add",pt),y=pt}function Ve(J,Se,He){He===void 0&&(He=!1);var pt=ps(x.props.triggerTarget||e);pt.forEach(function(mt){mt.addEventListener(J,Se,He),C.push({node:mt,eventType:J,handler:Se,options:He})})}function dt(){H()&&(Ve("touchstart",B,{passive:!0}),Ve("touchend",oe,{passive:!0})),Dj(x.props.trigger).forEach(function(J){if(J!=="manual")switch(Ve(J,B),J){case"mouseenter":Ve("mouseleave",oe);break;case"focus":Ve(qj?"focusout":"blur",ee);break;case"focusin":Ve("focusout",ee);break}})}function R(){C.forEach(function(J){var Se=J.node,He=J.eventType,pt=J.handler,mt=J.options;Se.removeEventListener(He,pt,mt)}),C=[]}function B(J){var Se,He=!1;if(!(!x.state.isEnabled||te(J)||l)){var pt=((Se=p)==null?void 0:Se.type)==="focus";p=J,k=J.currentTarget,Qe(),!x.state.isVisible&&Fj(J)&&Fu.forEach(function(mt){return mt(J)}),J.type==="click"&&(x.props.trigger.indexOf("mouseenter")<0||s)&&x.props.hideOnClick!==!1&&x.state.isVisible?He=!0:Te(J),J.type==="click"&&(s=!He),He&&!pt&&_e(J)}}function Y(J){var Se=J.target,He=U().contains(Se)||Q.contains(Se);if(!(J.type==="mousemove"&&He)){var pt=ce().concat(Q).map(function(mt){var fn,jn=mt._tippy,er=(fn=jn.popperInstance)==null?void 0:fn.state;return er?{popperRect:mt.getBoundingClientRect(),popperState:er,props:n}:null}).filter(Boolean);jj(pt,J)&&(et(),_e(J))}}function oe(J){var Se=te(J)||x.props.trigger.indexOf("click")>=0&&s;if(!Se){if(x.props.interactive){x.hideWithInteractivity(J);return}_e(J)}}function ee(J){x.props.trigger.indexOf("focusin")<0&&J.target!==U()||x.props.interactive&&J.relatedTarget&&Q.contains(J.relatedTarget)||_e(J)}function te(J){return $r.isTouch?H()!==J.type.indexOf("touch")>=0:!1}function ve(){me();var J=x.props,Se=J.popperOptions,He=J.placement,pt=J.offset,mt=J.getReferenceClientRect,fn=J.moveTransition,jn=K()?tp(Q).arrow:null,er=mt?{getBoundingClientRect:mt,contextElement:mt.contextElement||U()}:e,Li={name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(mn){var Gt=mn.state;if(K()){var Ra=je(),Na=Ra.box;["placement","reference-hidden","escaped"].forEach(function(ao){ao==="placement"?Na.setAttribute("data-placement",Gt.placement):Gt.attributes.popper["data-popper-"+ao]?Na.setAttribute("data-"+ao,""):Na.removeAttribute("data-"+ao)}),Gt.attributes.popper={}}}},Hr=[{name:"offset",options:{offset:pt}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!fn}},Li];K()&&jn&&Hr.push({name:"arrow",options:{element:jn,padding:3}}),Hr.push.apply(Hr,(Se==null?void 0:Se.modifiers)||[]),x.popperInstance=dm(er,Q,Object.assign({},Se,{placement:He,onFirstUpdate:m,modifiers:Hr}))}function me(){x.popperInstance&&(x.popperInstance.destroy(),x.popperInstance=null)}function be(){var J=x.props.appendTo,Se,He=U();x.props.interactive&&J===ab||J==="parent"?Se=He.parentNode:Se=lb(J,[He]),Se.contains(Q)||Se.appendChild(Q),x.state.isMounted=!0,ve()}function ce(){return Nu(Q.querySelectorAll("[data-tippy-root]"))}function Te(J){x.clearDelayTimeouts(),J&&ae("onTrigger",[x,J]),Ae();var Se=Pe(!0),He=D(),pt=He[0],mt=He[1];$r.isTouch&&pt==="hold"&&mt&&(Se=mt),Se?r=setTimeout(function(){x.show()},Se):x.show()}function _e(J){if(x.clearDelayTimeouts(),ae("onUntrigger",[x,J]),!x.state.isVisible){Oe();return}if(!(x.props.trigger.indexOf("mouseenter")>=0&&x.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(J.type)>=0&&s)){var Se=Pe(!1);Se?i=setTimeout(function(){x.state.isVisible&&x.hide()},Se):o=requestAnimationFrame(function(){x.hide()})}}function Ne(){x.state.isEnabled=!0}function ne(){x.hide(),x.state.isEnabled=!1}function $e(){clearTimeout(r),clearTimeout(i),cancelAnimationFrame(o)}function at(J){if(!x.state.isDestroyed){ae("onBeforeUpdate",[x,J]),R();var Se=x.props,He=vb(e,Object.assign({},Se,fb(J),{ignoreAttributes:!0}));x.props=He,dt(),Se.interactiveDebounce!==He.interactiveDebounce&&(et(),b=ub(Y,He.interactiveDebounce)),Se.triggerTarget&&!He.triggerTarget?ps(Se.triggerTarget).forEach(function(pt){pt.removeAttribute("aria-expanded")}):He.triggerTarget&&e.removeAttribute("aria-expanded"),Qe(),V(),g&&g(Se,He),x.popperInstance&&(ve(),ce().forEach(function(pt){requestAnimationFrame(pt._tippy.popperInstance.forceUpdate)})),ae("onAfterUpdate",[x,J])}}function lt(J){x.setProps({content:J})}function Tt(){var J=x.state.isVisible,Se=x.state.isDestroyed,He=!x.state.isEnabled,pt=$r.isTouch&&!x.props.touch,mt=Xd(x.props.duration,0,kr.duration);if(!(J||Se||He||pt)&&!U().hasAttribute("disabled")&&(ae("onShow",[x],!1),x.props.onShow(x)!==!1)){if(x.state.isVisible=!0,K()&&(Q.style.visibility="visible"),V(),Ae(),x.state.isMounted||(Q.style.transition="none"),K()){var fn=je(),jn=fn.box,er=fn.content;Zd([jn,er],0)}m=function(){var Hr;if(!(!x.state.isVisible||d)){if(d=!0,Q.offsetHeight,Q.style.transition=x.props.moveTransition,K()&&x.props.animation){var hs=je(),mn=hs.box,Gt=hs.content;Zd([mn,Gt],mt),db([mn,Gt],"visible")}pe(),Qe(),cb(np,x),(Hr=x.popperInstance)==null||Hr.forceUpdate(),ae("onMount",[x]),x.props.animation&&K()&&tt(mt,function(){x.state.isShown=!0,ae("onShown",[x])})}},be()}}function Nt(){var J=!x.state.isVisible,Se=x.state.isDestroyed,He=!x.state.isEnabled,pt=Xd(x.props.duration,1,kr.duration);if(!(J||Se||He)&&(ae("onHide",[x],!1),x.props.onHide(x)!==!1)){if(x.state.isVisible=!1,x.state.isShown=!1,d=!1,s=!1,K()&&(Q.style.visibility="hidden"),et(),Oe(),V(!0),K()){var mt=je(),fn=mt.box,jn=mt.content;x.props.animation&&(Zd([fn,jn],pt),db([fn,jn],"hidden"))}pe(),Qe(),x.props.animation?K()&&Be(pt,x.unmount):x.unmount()}}function en(J){de().addEventListener("mousemove",b),cb(Fu,b),b(J)}function $t(){x.state.isVisible&&x.hide(),x.state.isMounted&&(me(),ce().forEach(function(J){J._tippy.unmount()}),Q.parentNode&&Q.parentNode.removeChild(Q),np=np.filter(function(J){return J!==x}),x.state.isMounted=!1,ae("onHidden",[x]))}function Vt(){x.state.isDestroyed||(x.clearDelayTimeouts(),x.unmount(),R(),delete e._tippy,x.state.isDestroyed=!0,ae("onDestroy",[x]))}}function Da(e,t){t===void 0&&(t={});var n=kr.plugins.concat(t.plugins||[]);Kj();var r=Object.assign({},t,{plugins:n}),i=$j(e),o=i.reduce(function(s,l){var c=l&&e3(l,r);return c&&s.push(c),s},[]);return Mu(e)?o[0]:o}Da.defaultProps=kr,Da.setDefaultProps=Xj,Da.currentInput=$r,Object.assign({},Xg,{effect:function(t){var n=t.state,r={popper:{position:n.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(n.elements.popper.style,r.popper),n.styles=r,n.elements.arrow&&Object.assign(n.elements.arrow.style,r.arrow)}}),Da.setDefaultProps({render:Cb});const{toClipboard:t3}=mH();onUiLoaded(()=>{const e=document.createElement("div");e.id="physton-prompt-all-in-one",he.gradioApp().appendChild(e);const t=k1(cH);t.config.globalProperties.$toastr=pH,t.config.globalProperties.$copyText=t3,t.config.globalProperties.$tippyList=[],t.mixin(Oj),t.directive("animate",{mounted(n,r){n.classList.add("animate__animated",`animate__${r.value}`,"animate__faster")},updated(n,r){n.classList.remove(`animate__${r.oldValue}`),n.classList.add(`animate__${r.value}`)}}),t.directive("tooltip",{mounted(n,r){n.setAttribute("data-tippy-content",r.value);let i=n.getAttribute("unaffected");i=i===null?!1:i==="true";const o=Da(n,{placement:"bottom",theme:"light",allowHTML:!0,onCreate(s,l){if(!r.value||i)return;s.enable(),localStorage.getItem("phystonPromptEnableTooltip")==="true"||s.disable()}});n.$tippyInstance=o,i||t.config.globalProperties.$tippyList.push(o)},updated(n,r){r.value?(n.setAttribute("data-tippy-content",r.value),n.$tippyInstance.setContent(r.value)):n.$tippyInstance.disable()}}),t.mount(e)})});
|
||
//# sourceMappingURL=main.entry.js.map
|