valaxy 0.19.2 → 0.19.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/client/App.vue +1 -99
- package/client/components/ValaxyApp.vue +106 -0
- package/client/components/ValaxyDecrypt.vue +2 -1
- package/client/composables/outline/headers.ts +8 -111
- package/client/index.ts +3 -0
- package/client/main.ts +1 -0
- package/client/styles/mixins/variable.scss +0 -4
- package/client/styles/palette.scss +6 -3
- package/dist/{chunk-I6UPHJXQ.cjs → chunk-AFNVTV2C.cjs} +1 -1
- package/dist/chunk-K5UQMKIT.mjs +157 -0
- package/dist/chunk-VJHFBXMR.cjs +156 -0
- package/dist/node/cli/index.cjs +1 -1
- package/dist/node/cli/index.mjs +1 -1
- package/dist/node/index.cjs +1 -1
- package/dist/node/index.d.cts +17 -1
- package/dist/node/index.d.ts +17 -1
- package/dist/node/index.mjs +1 -1
- package/dist/types/index.cjs +1 -1
- package/dist/types/index.d.cts +2 -29
- package/dist/types/index.d.ts +2 -29
- package/dist/types/index.mjs +1 -1
- package/package.json +13 -13
- package/shims.d.ts +1 -1
- package/types/data.ts +1 -28
- package/dist/chunk-PTYUKZAG.mjs +0 -157
- package/dist/chunk-RVKKZQ6C.cjs +0 -156
- /package/dist/{chunk-7VTZAWDO.mjs → chunk-GYSOLAXM.mjs} +0 -0
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
import {createRequire as __createRequire} from 'module';var require=__createRequire(import.meta.url);
|
|
2
|
+
import{a as B,b as R,c as ee,d as l}from"./chunk-GYSOLAXM.mjs";var le=R((f_,ln)=>{"use strict";l();var Ni=process.argv||[],tr=process.env,Cf=!("NO_COLOR"in tr||Ni.includes("--no-color"))&&("FORCE_COLOR"in tr||Ni.includes("--color")||process.platform==="win32"||B!=null&&B("tty").isatty(1)&&tr.TERM!=="dumb"||"CI"in tr),Ef=(e,t,r=e)=>n=>{let o=""+n,i=o.indexOf(t,e.length);return~i?e+kf(o,t,r,i)+t:e+o+t},kf=(e,t,r,n)=>{let o="",i=0;do o+=e.substring(i,n)+r,i=n+t.length,n=e.indexOf(t,i);while(~n);return o+e.substring(i)},Mi=(e=Cf)=>{let t=e?Ef:()=>String;return{isColorSupported:e,reset:t("\x1B[0m","\x1B[0m"),bold:t("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:t("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:t("\x1B[3m","\x1B[23m"),underline:t("\x1B[4m","\x1B[24m"),inverse:t("\x1B[7m","\x1B[27m"),hidden:t("\x1B[8m","\x1B[28m"),strikethrough:t("\x1B[9m","\x1B[29m"),black:t("\x1B[30m","\x1B[39m"),red:t("\x1B[31m","\x1B[39m"),green:t("\x1B[32m","\x1B[39m"),yellow:t("\x1B[33m","\x1B[39m"),blue:t("\x1B[34m","\x1B[39m"),magenta:t("\x1B[35m","\x1B[39m"),cyan:t("\x1B[36m","\x1B[39m"),white:t("\x1B[37m","\x1B[39m"),gray:t("\x1B[90m","\x1B[39m"),bgBlack:t("\x1B[40m","\x1B[49m"),bgRed:t("\x1B[41m","\x1B[49m"),bgGreen:t("\x1B[42m","\x1B[49m"),bgYellow:t("\x1B[43m","\x1B[49m"),bgBlue:t("\x1B[44m","\x1B[49m"),bgMagenta:t("\x1B[45m","\x1B[49m"),bgCyan:t("\x1B[46m","\x1B[49m"),bgWhite:t("\x1B[47m","\x1B[49m")}};ln.exports=Mi();ln.exports.createColors=Mi});var Ii=R(pt=>{"use strict";l();Object.defineProperty(pt,"__esModule",{value:!0});pt.splitWhen=pt.flatten=void 0;function Pf(e){return e.reduce((t,r)=>[].concat(t,r),[])}pt.flatten=Pf;function Af(e,t){let r=[[]],n=0;for(let o of e)t(o)?(n++,r[n]=[]):r[n].push(o);return r}pt.splitWhen=Af});var Li=R(rr=>{"use strict";l();Object.defineProperty(rr,"__esModule",{value:!0});rr.isEnoentCodeError=void 0;function Of(e){return e.code==="ENOENT"}rr.isEnoentCodeError=Of});var Fi=R(nr=>{"use strict";l();Object.defineProperty(nr,"__esModule",{value:!0});nr.createDirentFromStats=void 0;var cn=class{constructor(t,r){this.name=t,this.isBlockDevice=r.isBlockDevice.bind(r),this.isCharacterDevice=r.isCharacterDevice.bind(r),this.isDirectory=r.isDirectory.bind(r),this.isFIFO=r.isFIFO.bind(r),this.isFile=r.isFile.bind(r),this.isSocket=r.isSocket.bind(r),this.isSymbolicLink=r.isSymbolicLink.bind(r)}};function Tf(e,t){return new cn(e,t)}nr.createDirentFromStats=Tf});var Hi=R(te=>{"use strict";l();Object.defineProperty(te,"__esModule",{value:!0});te.convertPosixPathToPattern=te.convertWindowsPathToPattern=te.convertPathToPattern=te.escapePosixPath=te.escapeWindowsPath=te.escape=te.removeLeadingDotSegment=te.makeAbsolute=te.unixify=void 0;var $f=B("os"),Nf=B("path"),Di=$f.platform()==="win32",Mf=2,If=/(\\?)([()*?[\]{|}]|^!|[!+@](?=\()|\\(?![!()*+?@[\]{|}]))/g,Lf=/(\\?)([()[\]{}]|^!|[!+@](?=\())/g,Ff=/^\\\\([.?])/,Df=/\\(?![!()+@[\]{}])/g;function Vf(e){return e.replace(/\\/g,"/")}te.unixify=Vf;function jf(e,t){return Nf.resolve(e,t)}te.makeAbsolute=jf;function Hf(e){if(e.charAt(0)==="."){let t=e.charAt(1);if(t==="/"||t==="\\")return e.slice(Mf)}return e}te.removeLeadingDotSegment=Hf;te.escape=Di?un:fn;function un(e){return e.replace(Lf,"\\$2")}te.escapeWindowsPath=un;function fn(e){return e.replace(If,"\\$2")}te.escapePosixPath=fn;te.convertPathToPattern=Di?Vi:ji;function Vi(e){return un(e).replace(Ff,"//$1").replace(Df,"/")}te.convertWindowsPathToPattern=Vi;function ji(e){return fn(e)}te.convertPosixPathToPattern=ji});var Bi=R((R_,qi)=>{"use strict";l();qi.exports=function(t){if(typeof t!="string"||t==="")return!1;for(var r;r=/(\\).|([@?!+*]\(.*\))/g.exec(t);){if(r[2])return!0;t=t.slice(r.index+r[0].length)}return!1}});var Gi=R((w_,Wi)=>{"use strict";l();var qf=Bi(),Ui={"{":"}","(":")","[":"]"},Bf=function(e){if(e[0]==="!")return!0;for(var t=0,r=-2,n=-2,o=-2,i=-2,s=-2;t<e.length;){if(e[t]==="*"||e[t+1]==="?"&&/[\].+)]/.test(e[t])||n!==-1&&e[t]==="["&&e[t+1]!=="]"&&(n<t&&(n=e.indexOf("]",t)),n>t&&(s===-1||s>n||(s=e.indexOf("\\",t),s===-1||s>n)))||o!==-1&&e[t]==="{"&&e[t+1]!=="}"&&(o=e.indexOf("}",t),o>t&&(s=e.indexOf("\\",t),s===-1||s>o))||i!==-1&&e[t]==="("&&e[t+1]==="?"&&/[:!=]/.test(e[t+2])&&e[t+3]!==")"&&(i=e.indexOf(")",t),i>t&&(s=e.indexOf("\\",t),s===-1||s>i))||r!==-1&&e[t]==="("&&e[t+1]!=="|"&&(r<t&&(r=e.indexOf("|",t)),r!==-1&&e[r+1]!==")"&&(i=e.indexOf(")",r),i>r&&(s=e.indexOf("\\",r),s===-1||s>i))))return!0;if(e[t]==="\\"){var a=e[t+1];t+=2;var c=Ui[a];if(c){var u=e.indexOf(c,t);u!==-1&&(t=u+1)}if(e[t]==="!")return!0}else t++}return!1},Uf=function(e){if(e[0]==="!")return!0;for(var t=0;t<e.length;){if(/[*?{}()[\]]/.test(e[t]))return!0;if(e[t]==="\\"){var r=e[t+1];t+=2;var n=Ui[r];if(n){var o=e.indexOf(n,t);o!==-1&&(t=o+1)}if(e[t]==="!")return!0}else t++}return!1};Wi.exports=function(t,r){if(typeof t!="string"||t==="")return!1;if(qf(t))return!0;var n=Bf;return r&&r.strict===!1&&(n=Uf),n(t)}});var zi=R((E_,Ki)=>{"use strict";l();var Wf=Gi(),Gf=B("path").posix.dirname,Kf=B("os").platform()==="win32",pn="/",zf=/\\/g,Yf=/[\{\[].*[\}\]]$/,Xf=/(^|[^\\])([\{\[]|\([^\)]+$)/,Qf=/\\([\!\*\?\|\[\]\(\)\{\}])/g;Ki.exports=function(t,r){var n=Object.assign({flipBackslashes:!0},r);n.flipBackslashes&&Kf&&t.indexOf(pn)<0&&(t=t.replace(zf,pn)),Yf.test(t)&&(t+=pn),t+="a";do t=Gf(t);while(Wf(t)||Xf.test(t));return t.replace(Qf,"$1")}});var or=R(ve=>{"use strict";l();ve.isInteger=e=>typeof e=="number"?Number.isInteger(e):typeof e=="string"&&e.trim()!==""?Number.isInteger(Number(e)):!1;ve.find=(e,t)=>e.nodes.find(r=>r.type===t);ve.exceedsLimit=(e,t,r=1,n)=>n===!1||!ve.isInteger(e)||!ve.isInteger(t)?!1:(Number(t)-Number(e))/Number(r)>=n;ve.escapeNode=(e,t=0,r)=>{let n=e.nodes[t];n&&(r&&n.type===r||n.type==="open"||n.type==="close")&&n.escaped!==!0&&(n.value="\\"+n.value,n.escaped=!0)};ve.encloseBrace=e=>e.type!=="brace"||e.commas>>0+e.ranges>>0?!1:(e.invalid=!0,!0);ve.isInvalidBrace=e=>e.type!=="brace"?!1:e.invalid===!0||e.dollar?!0:!(e.commas>>0+e.ranges>>0)||e.open!==!0||e.close!==!0?(e.invalid=!0,!0):!1;ve.isOpenOrClose=e=>e.type==="open"||e.type==="close"?!0:e.open===!0||e.close===!0;ve.reduce=e=>e.reduce((t,r)=>(r.type==="text"&&t.push(r.value),r.type==="range"&&(r.type="text"),t),[]);ve.flatten=(...e)=>{let t=[],r=n=>{for(let o=0;o<n.length;o++){let i=n[o];if(Array.isArray(i)){r(i);continue}i!==void 0&&t.push(i)}return t};return r(e),t}});var ir=R((O_,Xi)=>{"use strict";l();var Yi=or();Xi.exports=(e,t={})=>{let r=(n,o={})=>{let i=t.escapeInvalid&&Yi.isInvalidBrace(o),s=n.invalid===!0&&t.escapeInvalid===!0,a="";if(n.value)return(i||s)&&Yi.isOpenOrClose(n)?"\\"+n.value:n.value;if(n.value)return n.value;if(n.nodes)for(let c of n.nodes)a+=r(c);return a};return r(e)}});var Ji=R(($_,Qi)=>{"use strict";l();Qi.exports=function(e){return typeof e=="number"?e-e===0:typeof e=="string"&&e.trim()!==""?Number.isFinite?Number.isFinite(+e):isFinite(+e):!1}});var as=R((M_,ss)=>{"use strict";l();var Zi=Ji(),et=(e,t,r)=>{if(Zi(e)===!1)throw new TypeError("toRegexRange: expected the first argument to be a number");if(t===void 0||e===t)return String(e);if(Zi(t)===!1)throw new TypeError("toRegexRange: expected the second argument to be a number.");let n={relaxZeros:!0,...r};typeof n.strictZeros=="boolean"&&(n.relaxZeros=n.strictZeros===!1);let o=String(n.relaxZeros),i=String(n.shorthand),s=String(n.capture),a=String(n.wrap),c=e+":"+t+"="+o+i+s+a;if(et.cache.hasOwnProperty(c))return et.cache[c].result;let u=Math.min(e,t),f=Math.max(e,t);if(Math.abs(u-f)===1){let b=e+"|"+t;return n.capture?`(${b})`:n.wrap===!1?b:`(?:${b})`}let d=is(e)||is(t),p={min:e,max:t,a:u,b:f},y=[],v=[];if(d&&(p.isPadded=d,p.maxLen=String(p.max).length),u<0){let b=f<0?Math.abs(f):1;v=es(b,Math.abs(u),p,n),u=p.a=0}return f>=0&&(y=es(u,f,p,n)),p.negatives=v,p.positives=y,p.result=Jf(v,y,n),n.capture===!0?p.result=`(${p.result})`:n.wrap!==!1&&y.length+v.length>1&&(p.result=`(?:${p.result})`),et.cache[c]=p,p.result};function Jf(e,t,r){let n=dn(e,t,"-",!1,r)||[],o=dn(t,e,"",!1,r)||[],i=dn(e,t,"-?",!0,r)||[];return n.concat(i).concat(o).join("|")}function Zf(e,t){let r=1,n=1,o=rs(e,r),i=new Set([t]);for(;e<=o&&o<=t;)i.add(o),r+=1,o=rs(e,r);for(o=ns(t+1,n)-1;e<o&&o<=t;)i.add(o),n+=1,o=ns(t+1,n)-1;return i=[...i],i.sort(rp),i}function ep(e,t,r){if(e===t)return{pattern:e,count:[],digits:0};let n=tp(e,t),o=n.length,i="",s=0;for(let a=0;a<o;a++){let[c,u]=n[a];c===u?i+=c:c!=="0"||u!=="9"?i+=np(c,u,r):s++}return s&&(i+=r.shorthand===!0?"\\d":"[0-9]"),{pattern:i,count:[s],digits:o}}function es(e,t,r,n){let o=Zf(e,t),i=[],s=e,a;for(let c=0;c<o.length;c++){let u=o[c],f=ep(String(s),String(u),n),d="";if(!r.isPadded&&a&&a.pattern===f.pattern){a.count.length>1&&a.count.pop(),a.count.push(f.count[0]),a.string=a.pattern+os(a.count),s=u+1;continue}r.isPadded&&(d=op(u,r,n)),f.string=d+f.pattern+os(f.count),i.push(f),s=u+1,a=f}return i}function dn(e,t,r,n,o){let i=[];for(let s of e){let{string:a}=s;!n&&!ts(t,"string",a)&&i.push(r+a),n&&ts(t,"string",a)&&i.push(r+a)}return i}function tp(e,t){let r=[];for(let n=0;n<e.length;n++)r.push([e[n],t[n]]);return r}function rp(e,t){return e>t?1:t>e?-1:0}function ts(e,t,r){return e.some(n=>n[t]===r)}function rs(e,t){return Number(String(e).slice(0,-t)+"9".repeat(t))}function ns(e,t){return e-e%Math.pow(10,t)}function os(e){let[t=0,r=""]=e;return r||t>1?`{${t+(r?","+r:"")}}`:""}function np(e,t,r){return`[${e}${t-e===1?"":"-"}${t}]`}function is(e){return/^-?(0+)\d/.test(e)}function op(e,t,r){if(!t.isPadded)return e;let n=Math.abs(t.maxLen-String(e).length),o=r.relaxZeros!==!1;switch(n){case 0:return"";case 1:return o?"0?":"0";case 2:return o?"0{0,2}":"00";default:return o?`0{0,${n}}`:`0{${n}}`}}et.cache={};et.clearCache=()=>et.cache={};ss.exports=et});var hn=R((L_,ms)=>{"use strict";l();var ip=B("util"),cs=as(),ls=e=>e!==null&&typeof e=="object"&&!Array.isArray(e),sp=e=>t=>e===!0?Number(t):String(t),mn=e=>typeof e=="number"||typeof e=="string"&&e!=="",Ot=e=>Number.isInteger(+e),gn=e=>{let t=`${e}`,r=-1;if(t[0]==="-"&&(t=t.slice(1)),t==="0")return!1;for(;t[++r]==="0";);return r>0},ap=(e,t,r)=>typeof e=="string"||typeof t=="string"?!0:r.stringify===!0,lp=(e,t,r)=>{if(t>0){let n=e[0]==="-"?"-":"";n&&(e=e.slice(1)),e=n+e.padStart(n?t-1:t,"0")}return r===!1?String(e):e},ar=(e,t)=>{let r=e[0]==="-"?"-":"";for(r&&(e=e.slice(1),t--);e.length<t;)e="0"+e;return r?"-"+e:e},cp=(e,t,r)=>{e.negatives.sort((a,c)=>a<c?-1:a>c?1:0),e.positives.sort((a,c)=>a<c?-1:a>c?1:0);let n=t.capture?"":"?:",o="",i="",s;return e.positives.length&&(o=e.positives.map(a=>ar(String(a),r)).join("|")),e.negatives.length&&(i=`-(${n}${e.negatives.map(a=>ar(String(a),r)).join("|")})`),o&&i?s=`${o}|${i}`:s=o||i,t.wrap?`(${n}${s})`:s},us=(e,t,r,n)=>{if(r)return cs(e,t,{wrap:!1,...n});let o=String.fromCharCode(e);if(e===t)return o;let i=String.fromCharCode(t);return`[${o}-${i}]`},fs=(e,t,r)=>{if(Array.isArray(e)){let n=r.wrap===!0,o=r.capture?"":"?:";return n?`(${o}${e.join("|")})`:e.join("|")}return cs(e,t,r)},ps=(...e)=>new RangeError("Invalid range arguments: "+ip.inspect(...e)),ds=(e,t,r)=>{if(r.strictRanges===!0)throw ps([e,t]);return[]},up=(e,t)=>{if(t.strictRanges===!0)throw new TypeError(`Expected step "${e}" to be a number`);return[]},fp=(e,t,r=1,n={})=>{let o=Number(e),i=Number(t);if(!Number.isInteger(o)||!Number.isInteger(i)){if(n.strictRanges===!0)throw ps([e,t]);return[]}o===0&&(o=0),i===0&&(i=0);let s=o>i,a=String(e),c=String(t),u=String(r);r=Math.max(Math.abs(r),1);let f=gn(a)||gn(c)||gn(u),d=f?Math.max(a.length,c.length,u.length):0,p=f===!1&&ap(e,t,n)===!1,y=n.transform||sp(p);if(n.toRegex&&r===1)return us(ar(e,d),ar(t,d),!0,n);let v={negatives:[],positives:[]},b=I=>v[I<0?"negatives":"positives"].push(Math.abs(I)),$=[],E=0;for(;s?o>=i:o<=i;)n.toRegex===!0&&r>1?b(o):$.push(lp(y(o,E),d,p)),o=s?o-r:o+r,E++;return n.toRegex===!0?r>1?cp(v,n,d):fs($,null,{wrap:!1,...n}):$},pp=(e,t,r=1,n={})=>{if(!Ot(e)&&e.length>1||!Ot(t)&&t.length>1)return ds(e,t,n);let o=n.transform||(p=>String.fromCharCode(p)),i=`${e}`.charCodeAt(0),s=`${t}`.charCodeAt(0),a=i>s,c=Math.min(i,s),u=Math.max(i,s);if(n.toRegex&&r===1)return us(c,u,!1,n);let f=[],d=0;for(;a?i>=s:i<=s;)f.push(o(i,d)),i=a?i-r:i+r,d++;return n.toRegex===!0?fs(f,null,{wrap:!1,options:n}):f},sr=(e,t,r,n={})=>{if(t==null&&mn(e))return[e];if(!mn(e)||!mn(t))return ds(e,t,n);if(typeof r=="function")return sr(e,t,1,{transform:r});if(ls(r))return sr(e,t,0,r);let o={...n};return o.capture===!0&&(o.wrap=!0),r=r||o.step||1,Ot(r)?Ot(e)&&Ot(t)?fp(e,t,r,o):pp(e,t,Math.max(Math.abs(r),1),o):r!=null&&!ls(r)?up(r,o):sr(e,t,1,r)};ms.exports=sr});var ys=R((D_,hs)=>{"use strict";l();var dp=hn(),gs=or(),mp=(e,t={})=>{let r=(n,o={})=>{let i=gs.isInvalidBrace(o),s=n.invalid===!0&&t.escapeInvalid===!0,a=i===!0||s===!0,c=t.escapeInvalid===!0?"\\":"",u="";if(n.isOpen===!0)return c+n.value;if(n.isClose===!0)return console.log("node.isClose",c,n.value),c+n.value;if(n.type==="open")return a?c+n.value:"(";if(n.type==="close")return a?c+n.value:")";if(n.type==="comma")return n.prev.type==="comma"?"":a?n.value:"|";if(n.value)return n.value;if(n.nodes&&n.ranges>0){let f=gs.reduce(n.nodes),d=dp(...f,{...t,wrap:!1,toRegex:!0,strictZeros:!0});if(d.length!==0)return f.length>1&&d.length>1?`(${d})`:d}if(n.nodes)for(let f of n.nodes)u+=r(f,n);return u};return r(e)};hs.exports=mp});var _s=R((j_,xs)=>{"use strict";l();var gp=hn(),vs=ir(),dt=or(),tt=(e="",t="",r=!1)=>{let n=[];if(e=[].concat(e),t=[].concat(t),!t.length)return e;if(!e.length)return r?dt.flatten(t).map(o=>`{${o}}`):t;for(let o of e)if(Array.isArray(o))for(let i of o)n.push(tt(i,t,r));else for(let i of t)r===!0&&typeof i=="string"&&(i=`{${i}}`),n.push(Array.isArray(i)?tt(o,i,r):o+i);return dt.flatten(n)},hp=(e,t={})=>{let r=t.rangeLimit===void 0?1e3:t.rangeLimit,n=(o,i={})=>{o.queue=[];let s=i,a=i.queue;for(;s.type!=="brace"&&s.type!=="root"&&s.parent;)s=s.parent,a=s.queue;if(o.invalid||o.dollar){a.push(tt(a.pop(),vs(o,t)));return}if(o.type==="brace"&&o.invalid!==!0&&o.nodes.length===2){a.push(tt(a.pop(),["{}"]));return}if(o.nodes&&o.ranges>0){let d=dt.reduce(o.nodes);if(dt.exceedsLimit(...d,t.step,r))throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.");let p=gp(...d,t);p.length===0&&(p=vs(o,t)),a.push(tt(a.pop(),p)),o.nodes=[];return}let c=dt.encloseBrace(o),u=o.queue,f=o;for(;f.type!=="brace"&&f.type!=="root"&&f.parent;)f=f.parent,u=f.queue;for(let d=0;d<o.nodes.length;d++){let p=o.nodes[d];if(p.type==="comma"&&o.type==="brace"){d===1&&u.push(""),u.push("");continue}if(p.type==="close"){a.push(tt(a.pop(),u,c));continue}if(p.value&&p.type!=="open"){u.push(tt(u.pop(),p.value));continue}p.nodes&&n(p,o)}return u};return dt.flatten(n(e))};xs.exports=hp});var Rs=R((q_,bs)=>{"use strict";l();bs.exports={MAX_LENGTH:1e4,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:`
|
|
3
|
+
`,CHAR_NO_BREAK_SPACE:"\xA0",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:" ",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\uFEFF"}});var ks=R((U_,Es)=>{"use strict";l();var yp=ir(),{MAX_LENGTH:Ss,CHAR_BACKSLASH:yn,CHAR_BACKTICK:vp,CHAR_COMMA:xp,CHAR_DOT:_p,CHAR_LEFT_PARENTHESES:bp,CHAR_RIGHT_PARENTHESES:Rp,CHAR_LEFT_CURLY_BRACE:Sp,CHAR_RIGHT_CURLY_BRACE:wp,CHAR_LEFT_SQUARE_BRACKET:ws,CHAR_RIGHT_SQUARE_BRACKET:Cs,CHAR_DOUBLE_QUOTE:Cp,CHAR_SINGLE_QUOTE:Ep,CHAR_NO_BREAK_SPACE:kp,CHAR_ZERO_WIDTH_NOBREAK_SPACE:Pp}=Rs(),Ap=(e,t={})=>{if(typeof e!="string")throw new TypeError("Expected a string");let r=t||{},n=typeof r.maxLength=="number"?Math.min(Ss,r.maxLength):Ss;if(e.length>n)throw new SyntaxError(`Input length (${e.length}), exceeds max characters (${n})`);let o={type:"root",input:e,nodes:[]},i=[o],s=o,a=o,c=0,u=e.length,f=0,d=0,p,y=()=>e[f++],v=b=>{if(b.type==="text"&&a.type==="dot"&&(a.type="text"),a&&a.type==="text"&&b.type==="text"){a.value+=b.value;return}return s.nodes.push(b),b.parent=s,b.prev=a,a=b,b};for(v({type:"bos"});f<u;)if(s=i[i.length-1],p=y(),!(p===Pp||p===kp)){if(p===yn){v({type:"text",value:(t.keepEscaping?p:"")+y()});continue}if(p===Cs){v({type:"text",value:"\\"+p});continue}if(p===ws){c++;let b;for(;f<u&&(b=y());){if(p+=b,b===ws){c++;continue}if(b===yn){p+=y();continue}if(b===Cs&&(c--,c===0))break}v({type:"text",value:p});continue}if(p===bp){s=v({type:"paren",nodes:[]}),i.push(s),v({type:"text",value:p});continue}if(p===Rp){if(s.type!=="paren"){v({type:"text",value:p});continue}s=i.pop(),v({type:"text",value:p}),s=i[i.length-1];continue}if(p===Cp||p===Ep||p===vp){let b=p,$;for(t.keepQuotes!==!0&&(p="");f<u&&($=y());){if($===yn){p+=$+y();continue}if($===b){t.keepQuotes===!0&&(p+=$);break}p+=$}v({type:"text",value:p});continue}if(p===Sp){d++;let $={type:"brace",open:!0,close:!1,dollar:a.value&&a.value.slice(-1)==="$"||s.dollar===!0,depth:d,commas:0,ranges:0,nodes:[]};s=v($),i.push(s),v({type:"open",value:p});continue}if(p===wp){if(s.type!=="brace"){v({type:"text",value:p});continue}let b="close";s=i.pop(),s.close=!0,v({type:b,value:p}),d--,s=i[i.length-1];continue}if(p===xp&&d>0){if(s.ranges>0){s.ranges=0;let b=s.nodes.shift();s.nodes=[b,{type:"text",value:yp(s)}]}v({type:"comma",value:p}),s.commas++;continue}if(p===_p&&d>0&&s.commas===0){let b=s.nodes;if(d===0||b.length===0){v({type:"text",value:p});continue}if(a.type==="dot"){if(s.range=[],a.value+=p,a.type="range",s.nodes.length!==3&&s.nodes.length!==5){s.invalid=!0,s.ranges=0,a.type="text";continue}s.ranges++,s.args=[];continue}if(a.type==="range"){b.pop();let $=b[b.length-1];$.value+=a.value+p,a=$,s.ranges--;continue}v({type:"dot",value:p});continue}v({type:"text",value:p})}do if(s=i.pop(),s.type!=="root"){s.nodes.forEach(E=>{E.nodes||(E.type==="open"&&(E.isOpen=!0),E.type==="close"&&(E.isClose=!0),E.nodes||(E.type="text"),E.invalid=!0)});let b=i[i.length-1],$=b.nodes.indexOf(s);b.nodes.splice($,1,...s.nodes)}while(i.length>0);return v({type:"eos"}),o};Es.exports=Ap});var Os=R((G_,As)=>{"use strict";l();var Ps=ir(),Op=ys(),Tp=_s(),$p=ks(),he=(e,t={})=>{let r=[];if(Array.isArray(e))for(let n of e){let o=he.create(n,t);Array.isArray(o)?r.push(...o):r.push(o)}else r=[].concat(he.create(e,t));return t&&t.expand===!0&&t.nodupes===!0&&(r=[...new Set(r)]),r};he.parse=(e,t={})=>$p(e,t);he.stringify=(e,t={})=>Ps(typeof e=="string"?he.parse(e,t):e,t);he.compile=(e,t={})=>(typeof e=="string"&&(e=he.parse(e,t)),Op(e,t));he.expand=(e,t={})=>{typeof e=="string"&&(e=he.parse(e,t));let r=Tp(e,t);return t.noempty===!0&&(r=r.filter(Boolean)),t.nodupes===!0&&(r=[...new Set(r)]),r};he.create=(e,t={})=>e===""||e.length<3?[e]:t.expand!==!0?he.compile(e,t):he.expand(e,t);As.exports=he});var Tt=R((z_,Is)=>{"use strict";l();var Np=B("path"),Ce="\\\\/",Ts=`[^${Ce}]`,Me="\\.",Mp="\\+",Ip="\\?",lr="\\/",Lp="(?=.)",$s="[^/]",vn=`(?:${lr}|$)`,Ns=`(?:^|${lr})`,xn=`${Me}{1,2}${vn}`,Fp=`(?!${Me})`,Dp=`(?!${Ns}${xn})`,Vp=`(?!${Me}{0,1}${vn})`,jp=`(?!${xn})`,Hp=`[^.${lr}]`,qp=`${$s}*?`,Ms={DOT_LITERAL:Me,PLUS_LITERAL:Mp,QMARK_LITERAL:Ip,SLASH_LITERAL:lr,ONE_CHAR:Lp,QMARK:$s,END_ANCHOR:vn,DOTS_SLASH:xn,NO_DOT:Fp,NO_DOTS:Dp,NO_DOT_SLASH:Vp,NO_DOTS_SLASH:jp,QMARK_NO_DOT:Hp,STAR:qp,START_ANCHOR:Ns},Bp={...Ms,SLASH_LITERAL:`[${Ce}]`,QMARK:Ts,STAR:`${Ts}*?`,DOTS_SLASH:`${Me}{1,2}(?:[${Ce}]|$)`,NO_DOT:`(?!${Me})`,NO_DOTS:`(?!(?:^|[${Ce}])${Me}{1,2}(?:[${Ce}]|$))`,NO_DOT_SLASH:`(?!${Me}{0,1}(?:[${Ce}]|$))`,NO_DOTS_SLASH:`(?!${Me}{1,2}(?:[${Ce}]|$))`,QMARK_NO_DOT:`[^.${Ce}]`,START_ANCHOR:`(?:^|[${Ce}])`,END_ANCHOR:`(?:[${Ce}]|$)`},Up={alnum:"a-zA-Z0-9",alpha:"a-zA-Z",ascii:"\\x00-\\x7F",blank:" \\t",cntrl:"\\x00-\\x1F\\x7F",digit:"0-9",graph:"\\x21-\\x7E",lower:"a-z",print:"\\x20-\\x7E ",punct:"\\-!\"#$%&'()\\*+,./:;<=>?@[\\]^_`{|}~",space:" \\t\\r\\n\\v\\f",upper:"A-Z",word:"A-Za-z0-9_",xdigit:"A-Fa-f0-9"};Is.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:Up,REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{"***":"*","**/**":"**","**/**/**":"**"},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,SEP:Np.sep,extglobChars(e){return{"!":{type:"negate",open:"(?:(?!(?:",close:`))${e.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars(e){return e===!0?Bp:Ms}}});var $t=R(ge=>{"use strict";l();var Wp=B("path"),Gp=process.platform==="win32",{REGEX_BACKSLASH:Kp,REGEX_REMOVE_BACKSLASH:zp,REGEX_SPECIAL_CHARS:Yp,REGEX_SPECIAL_CHARS_GLOBAL:Xp}=Tt();ge.isObject=e=>e!==null&&typeof e=="object"&&!Array.isArray(e);ge.hasRegexChars=e=>Yp.test(e);ge.isRegexChar=e=>e.length===1&&ge.hasRegexChars(e);ge.escapeRegex=e=>e.replace(Xp,"\\$1");ge.toPosixSlashes=e=>e.replace(Kp,"/");ge.removeBackslashes=e=>e.replace(zp,t=>t==="\\"?"":t);ge.supportsLookbehinds=()=>{let e=process.version.slice(1).split(".").map(Number);return e.length===3&&e[0]>=9||e[0]===8&&e[1]>=10};ge.isWindows=e=>e&&typeof e.windows=="boolean"?e.windows:Gp===!0||Wp.sep==="\\";ge.escapeLast=(e,t,r)=>{let n=e.lastIndexOf(t,r);return n===-1?e:e[n-1]==="\\"?ge.escapeLast(e,t,n-1):`${e.slice(0,n)}\\${e.slice(n)}`};ge.removePrefix=(e,t={})=>{let r=e;return r.startsWith("./")&&(r=r.slice(2),t.prefix="./"),r};ge.wrapOutput=(e,t={},r={})=>{let n=r.contains?"":"^",o=r.contains?"":"$",i=`${n}(?:${e})${o}`;return t.negated===!0&&(i=`(?:^(?!${i}).*$)`),i}});var Bs=R((J_,qs)=>{"use strict";l();var Ls=$t(),{CHAR_ASTERISK:_n,CHAR_AT:Qp,CHAR_BACKWARD_SLASH:Nt,CHAR_COMMA:Jp,CHAR_DOT:bn,CHAR_EXCLAMATION_MARK:Rn,CHAR_FORWARD_SLASH:Hs,CHAR_LEFT_CURLY_BRACE:Sn,CHAR_LEFT_PARENTHESES:wn,CHAR_LEFT_SQUARE_BRACKET:Zp,CHAR_PLUS:ed,CHAR_QUESTION_MARK:Fs,CHAR_RIGHT_CURLY_BRACE:td,CHAR_RIGHT_PARENTHESES:Ds,CHAR_RIGHT_SQUARE_BRACKET:rd}=Tt(),Vs=e=>e===Hs||e===Nt,js=e=>{e.isPrefix!==!0&&(e.depth=e.isGlobstar?1/0:1)},nd=(e,t)=>{let r=t||{},n=e.length-1,o=r.parts===!0||r.scanToEnd===!0,i=[],s=[],a=[],c=e,u=-1,f=0,d=0,p=!1,y=!1,v=!1,b=!1,$=!1,E=!1,I=!1,P=!1,D=!1,A=!1,M=0,C,w,T={value:"",depth:0,isGlob:!1},G=()=>u>=n,h=()=>c.charCodeAt(u+1),O=()=>(C=w,c.charCodeAt(++u));for(;u<n;){w=O();let q;if(w===Nt){I=T.backslashes=!0,w=O(),w===Sn&&(E=!0);continue}if(E===!0||w===Sn){for(M++;G()!==!0&&(w=O());){if(w===Nt){I=T.backslashes=!0,O();continue}if(w===Sn){M++;continue}if(E!==!0&&w===bn&&(w=O())===bn){if(p=T.isBrace=!0,v=T.isGlob=!0,A=!0,o===!0)continue;break}if(E!==!0&&w===Jp){if(p=T.isBrace=!0,v=T.isGlob=!0,A=!0,o===!0)continue;break}if(w===td&&(M--,M===0)){E=!1,p=T.isBrace=!0,A=!0;break}}if(o===!0)continue;break}if(w===Hs){if(i.push(u),s.push(T),T={value:"",depth:0,isGlob:!1},A===!0)continue;if(C===bn&&u===f+1){f+=2;continue}d=u+1;continue}if(r.noext!==!0&&(w===ed||w===Qp||w===_n||w===Fs||w===Rn)===!0&&h()===wn){if(v=T.isGlob=!0,b=T.isExtglob=!0,A=!0,w===Rn&&u===f&&(D=!0),o===!0){for(;G()!==!0&&(w=O());){if(w===Nt){I=T.backslashes=!0,w=O();continue}if(w===Ds){v=T.isGlob=!0,A=!0;break}}continue}break}if(w===_n){if(C===_n&&($=T.isGlobstar=!0),v=T.isGlob=!0,A=!0,o===!0)continue;break}if(w===Fs){if(v=T.isGlob=!0,A=!0,o===!0)continue;break}if(w===Zp){for(;G()!==!0&&(q=O());){if(q===Nt){I=T.backslashes=!0,O();continue}if(q===rd){y=T.isBracket=!0,v=T.isGlob=!0,A=!0;break}}if(o===!0)continue;break}if(r.nonegate!==!0&&w===Rn&&u===f){P=T.negated=!0,f++;continue}if(r.noparen!==!0&&w===wn){if(v=T.isGlob=!0,o===!0){for(;G()!==!0&&(w=O());){if(w===wn){I=T.backslashes=!0,w=O();continue}if(w===Ds){A=!0;break}}continue}break}if(v===!0){if(A=!0,o===!0)continue;break}}r.noext===!0&&(b=!1,v=!1);let L=c,j="",x="";f>0&&(j=c.slice(0,f),c=c.slice(f),d-=f),L&&v===!0&&d>0?(L=c.slice(0,d),x=c.slice(d)):v===!0?(L="",x=c):L=c,L&&L!==""&&L!=="/"&&L!==c&&Vs(L.charCodeAt(L.length-1))&&(L=L.slice(0,-1)),r.unescape===!0&&(x&&(x=Ls.removeBackslashes(x)),L&&I===!0&&(L=Ls.removeBackslashes(L)));let _={prefix:j,input:e,start:f,base:L,glob:x,isBrace:p,isBracket:y,isGlob:v,isExtglob:b,isGlobstar:$,negated:P,negatedExtglob:D};if(r.tokens===!0&&(_.maxDepth=0,Vs(w)||s.push(T),_.tokens=s),r.parts===!0||r.tokens===!0){let q;for(let N=0;N<i.length;N++){let K=q?q+1:f,Z=i[N],Q=e.slice(K,Z);r.tokens&&(N===0&&f!==0?(s[N].isPrefix=!0,s[N].value=j):s[N].value=Q,js(s[N]),_.maxDepth+=s[N].depth),(N!==0||Q!=="")&&a.push(Q),q=Z}if(q&&q+1<e.length){let N=e.slice(q+1);a.push(N),r.tokens&&(s[s.length-1].value=N,js(s[s.length-1]),_.maxDepth+=s[s.length-1].depth)}_.slashes=i,_.parts=a}return _};qs.exports=nd});var Gs=R((e1,Ws)=>{"use strict";l();var cr=Tt(),ye=$t(),{MAX_LENGTH:ur,POSIX_REGEX_SOURCE:od,REGEX_NON_SPECIAL_CHARS:id,REGEX_SPECIAL_CHARS_BACKREF:sd,REPLACEMENTS:Us}=cr,ad=(e,t)=>{if(typeof t.expandRange=="function")return t.expandRange(...e,t);e.sort();let r=`[${e.join("-")}]`;try{new RegExp(r)}catch{return e.map(o=>ye.escapeRegex(o)).join("..")}return r},mt=(e,t)=>`Missing ${e}: "${t}" - use "\\\\${t}" to match literal characters`,Cn=(e,t)=>{if(typeof e!="string")throw new TypeError("Expected a string");e=Us[e]||e;let r={...t},n=typeof r.maxLength=="number"?Math.min(ur,r.maxLength):ur,o=e.length;if(o>n)throw new SyntaxError(`Input length: ${o}, exceeds maximum allowed length: ${n}`);let i={type:"bos",value:"",output:r.prepend||""},s=[i],a=r.capture?"":"?:",c=ye.isWindows(t),u=cr.globChars(c),f=cr.extglobChars(u),{DOT_LITERAL:d,PLUS_LITERAL:p,SLASH_LITERAL:y,ONE_CHAR:v,DOTS_SLASH:b,NO_DOT:$,NO_DOT_SLASH:E,NO_DOTS_SLASH:I,QMARK:P,QMARK_NO_DOT:D,STAR:A,START_ANCHOR:M}=u,C=k=>`(${a}(?:(?!${M}${k.dot?b:d}).)*?)`,w=r.dot?"":$,T=r.dot?P:D,G=r.bash===!0?C(r):A;r.capture&&(G=`(${G})`),typeof r.noext=="boolean"&&(r.noextglob=r.noext);let h={input:e,index:-1,start:0,dot:r.dot===!0,consumed:"",output:"",prefix:"",backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens:s};e=ye.removePrefix(e,h),o=e.length;let O=[],L=[],j=[],x=i,_,q=()=>h.index===o-1,N=h.peek=(k=1)=>e[h.index+k],K=h.advance=()=>e[++h.index]||"",Z=()=>e.slice(h.index+1),Q=(k="",W=0)=>{h.consumed+=k,h.index+=W},pe=k=>{h.output+=k.output!=null?k.output:k.value,Q(k.value)},se=()=>{let k=1;for(;N()==="!"&&(N(2)!=="("||N(3)==="?");)K(),h.start++,k++;return k%2===0?!1:(h.negated=!0,h.start++,!0)},Ne=k=>{h[k]++,j.push(k)},ae=k=>{h[k]--,j.pop()},V=k=>{if(x.type==="globstar"){let W=h.braces>0&&(k.type==="comma"||k.type==="brace"),S=k.extglob===!0||O.length&&(k.type==="pipe"||k.type==="paren");k.type!=="slash"&&k.type!=="paren"&&!W&&!S&&(h.output=h.output.slice(0,-x.output.length),x.type="star",x.value="*",x.output=G,h.output+=x.output)}if(O.length&&k.type!=="paren"&&(O[O.length-1].inner+=k.value),(k.value||k.output)&&pe(k),x&&x.type==="text"&&k.type==="text"){x.value+=k.value,x.output=(x.output||"")+k.value;return}k.prev=x,s.push(k),x=k},me=(k,W)=>{let S={...f[W],conditions:1,inner:""};S.prev=x,S.parens=h.parens,S.output=h.output;let H=(r.capture?"(":"")+S.open;Ne("parens"),V({type:k,value:W,output:h.output?"":v}),V({type:"paren",extglob:!0,value:K(),output:H}),O.push(S)},ut=k=>{let W=k.close+(r.capture?")":""),S;if(k.type==="negate"){let H=G;if(k.inner&&k.inner.length>1&&k.inner.includes("/")&&(H=C(r)),(H!==G||q()||/^\)+$/.test(Z()))&&(W=k.close=`)$))${H}`),k.inner.includes("*")&&(S=Z())&&/^\.[^\\/.]+$/.test(S)){let Y=Cn(S,{...t,fastpaths:!1}).output;W=k.close=`)${Y})${H})`}k.prev.type==="bos"&&(h.negatedExtglob=!0)}V({type:"paren",extglob:!0,value:_,output:W}),ae("parens")};if(r.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(e)){let k=!1,W=e.replace(sd,(S,H,Y,de,ne,an)=>de==="\\"?(k=!0,S):de==="?"?H?H+de+(ne?P.repeat(ne.length):""):an===0?T+(ne?P.repeat(ne.length):""):P.repeat(Y.length):de==="."?d.repeat(Y.length):de==="*"?H?H+de+(ne?G:""):G:H?S:`\\${S}`);return k===!0&&(r.unescape===!0?W=W.replace(/\\/g,""):W=W.replace(/\\+/g,S=>S.length%2===0?"\\\\":S?"\\":"")),W===e&&r.contains===!0?(h.output=e,h):(h.output=ye.wrapOutput(W,h,t),h)}for(;!q();){if(_=K(),_==="\0")continue;if(_==="\\"){let S=N();if(S==="/"&&r.bash!==!0||S==="."||S===";")continue;if(!S){_+="\\",V({type:"text",value:_});continue}let H=/^\\+/.exec(Z()),Y=0;if(H&&H[0].length>2&&(Y=H[0].length,h.index+=Y,Y%2!==0&&(_+="\\")),r.unescape===!0?_=K():_+=K(),h.brackets===0){V({type:"text",value:_});continue}}if(h.brackets>0&&(_!=="]"||x.value==="["||x.value==="[^")){if(r.posix!==!1&&_===":"){let S=x.value.slice(1);if(S.includes("[")&&(x.posix=!0,S.includes(":"))){let H=x.value.lastIndexOf("["),Y=x.value.slice(0,H),de=x.value.slice(H+2),ne=od[de];if(ne){x.value=Y+ne,h.backtrack=!0,K(),!i.output&&s.indexOf(x)===1&&(i.output=v);continue}}}(_==="["&&N()!==":"||_==="-"&&N()==="]")&&(_=`\\${_}`),_==="]"&&(x.value==="["||x.value==="[^")&&(_=`\\${_}`),r.posix===!0&&_==="!"&&x.value==="["&&(_="^"),x.value+=_,pe({value:_});continue}if(h.quotes===1&&_!=='"'){_=ye.escapeRegex(_),x.value+=_,pe({value:_});continue}if(_==='"'){h.quotes=h.quotes===1?0:1,r.keepQuotes===!0&&V({type:"text",value:_});continue}if(_==="("){Ne("parens"),V({type:"paren",value:_});continue}if(_===")"){if(h.parens===0&&r.strictBrackets===!0)throw new SyntaxError(mt("opening","("));let S=O[O.length-1];if(S&&h.parens===S.parens+1){ut(O.pop());continue}V({type:"paren",value:_,output:h.parens?")":"\\)"}),ae("parens");continue}if(_==="["){if(r.nobracket===!0||!Z().includes("]")){if(r.nobracket!==!0&&r.strictBrackets===!0)throw new SyntaxError(mt("closing","]"));_=`\\${_}`}else Ne("brackets");V({type:"bracket",value:_});continue}if(_==="]"){if(r.nobracket===!0||x&&x.type==="bracket"&&x.value.length===1){V({type:"text",value:_,output:`\\${_}`});continue}if(h.brackets===0){if(r.strictBrackets===!0)throw new SyntaxError(mt("opening","["));V({type:"text",value:_,output:`\\${_}`});continue}ae("brackets");let S=x.value.slice(1);if(x.posix!==!0&&S[0]==="^"&&!S.includes("/")&&(_=`/${_}`),x.value+=_,pe({value:_}),r.literalBrackets===!1||ye.hasRegexChars(S))continue;let H=ye.escapeRegex(x.value);if(h.output=h.output.slice(0,-x.value.length),r.literalBrackets===!0){h.output+=H,x.value=H;continue}x.value=`(${a}${H}|${x.value})`,h.output+=x.value;continue}if(_==="{"&&r.nobrace!==!0){Ne("braces");let S={type:"brace",value:_,output:"(",outputIndex:h.output.length,tokensIndex:h.tokens.length};L.push(S),V(S);continue}if(_==="}"){let S=L[L.length-1];if(r.nobrace===!0||!S){V({type:"text",value:_,output:_});continue}let H=")";if(S.dots===!0){let Y=s.slice(),de=[];for(let ne=Y.length-1;ne>=0&&(s.pop(),Y[ne].type!=="brace");ne--)Y[ne].type!=="dots"&&de.unshift(Y[ne].value);H=ad(de,r),h.backtrack=!0}if(S.comma!==!0&&S.dots!==!0){let Y=h.output.slice(0,S.outputIndex),de=h.tokens.slice(S.tokensIndex);S.value=S.output="\\{",_=H="\\}",h.output=Y;for(let ne of de)h.output+=ne.output||ne.value}V({type:"brace",value:_,output:H}),ae("braces"),L.pop();continue}if(_==="|"){O.length>0&&O[O.length-1].conditions++,V({type:"text",value:_});continue}if(_===","){let S=_,H=L[L.length-1];H&&j[j.length-1]==="braces"&&(H.comma=!0,S="|"),V({type:"comma",value:_,output:S});continue}if(_==="/"){if(x.type==="dot"&&h.index===h.start+1){h.start=h.index+1,h.consumed="",h.output="",s.pop(),x=i;continue}V({type:"slash",value:_,output:y});continue}if(_==="."){if(h.braces>0&&x.type==="dot"){x.value==="."&&(x.output=d);let S=L[L.length-1];x.type="dots",x.output+=_,x.value+=_,S.dots=!0;continue}if(h.braces+h.parens===0&&x.type!=="bos"&&x.type!=="slash"){V({type:"text",value:_,output:d});continue}V({type:"dot",value:_,output:d});continue}if(_==="?"){if(!(x&&x.value==="(")&&r.noextglob!==!0&&N()==="("&&N(2)!=="?"){me("qmark",_);continue}if(x&&x.type==="paren"){let H=N(),Y=_;if(H==="<"&&!ye.supportsLookbehinds())throw new Error("Node.js v10 or higher is required for regex lookbehinds");(x.value==="("&&!/[!=<:]/.test(H)||H==="<"&&!/<([!=]|\w+>)/.test(Z()))&&(Y=`\\${_}`),V({type:"text",value:_,output:Y});continue}if(r.dot!==!0&&(x.type==="slash"||x.type==="bos")){V({type:"qmark",value:_,output:D});continue}V({type:"qmark",value:_,output:P});continue}if(_==="!"){if(r.noextglob!==!0&&N()==="("&&(N(2)!=="?"||!/[!=<:]/.test(N(3)))){me("negate",_);continue}if(r.nonegate!==!0&&h.index===0){se();continue}}if(_==="+"){if(r.noextglob!==!0&&N()==="("&&N(2)!=="?"){me("plus",_);continue}if(x&&x.value==="("||r.regex===!1){V({type:"plus",value:_,output:p});continue}if(x&&(x.type==="bracket"||x.type==="paren"||x.type==="brace")||h.parens>0){V({type:"plus",value:_});continue}V({type:"plus",value:p});continue}if(_==="@"){if(r.noextglob!==!0&&N()==="("&&N(2)!=="?"){V({type:"at",extglob:!0,value:_,output:""});continue}V({type:"text",value:_});continue}if(_!=="*"){(_==="$"||_==="^")&&(_=`\\${_}`);let S=id.exec(Z());S&&(_+=S[0],h.index+=S[0].length),V({type:"text",value:_});continue}if(x&&(x.type==="globstar"||x.star===!0)){x.type="star",x.star=!0,x.value+=_,x.output=G,h.backtrack=!0,h.globstar=!0,Q(_);continue}let k=Z();if(r.noextglob!==!0&&/^\([^?]/.test(k)){me("star",_);continue}if(x.type==="star"){if(r.noglobstar===!0){Q(_);continue}let S=x.prev,H=S.prev,Y=S.type==="slash"||S.type==="bos",de=H&&(H.type==="star"||H.type==="globstar");if(r.bash===!0&&(!Y||k[0]&&k[0]!=="/")){V({type:"star",value:_,output:""});continue}let ne=h.braces>0&&(S.type==="comma"||S.type==="brace"),an=O.length&&(S.type==="pipe"||S.type==="paren");if(!Y&&S.type!=="paren"&&!ne&&!an){V({type:"star",value:_,output:""});continue}for(;k.slice(0,3)==="/**";){let er=e[h.index+4];if(er&&er!=="/")break;k=k.slice(3),Q("/**",3)}if(S.type==="bos"&&q()){x.type="globstar",x.value+=_,x.output=C(r),h.output=x.output,h.globstar=!0,Q(_);continue}if(S.type==="slash"&&S.prev.type!=="bos"&&!de&&q()){h.output=h.output.slice(0,-(S.output+x.output).length),S.output=`(?:${S.output}`,x.type="globstar",x.output=C(r)+(r.strictSlashes?")":"|$)"),x.value+=_,h.globstar=!0,h.output+=S.output+x.output,Q(_);continue}if(S.type==="slash"&&S.prev.type!=="bos"&&k[0]==="/"){let er=k[1]!==void 0?"|$":"";h.output=h.output.slice(0,-(S.output+x.output).length),S.output=`(?:${S.output}`,x.type="globstar",x.output=`${C(r)}${y}|${y}${er})`,x.value+=_,h.output+=S.output+x.output,h.globstar=!0,Q(_+K()),V({type:"slash",value:"/",output:""});continue}if(S.type==="bos"&&k[0]==="/"){x.type="globstar",x.value+=_,x.output=`(?:^|${y}|${C(r)}${y})`,h.output=x.output,h.globstar=!0,Q(_+K()),V({type:"slash",value:"/",output:""});continue}h.output=h.output.slice(0,-x.output.length),x.type="globstar",x.output=C(r),x.value+=_,h.output+=x.output,h.globstar=!0,Q(_);continue}let W={type:"star",value:_,output:G};if(r.bash===!0){W.output=".*?",(x.type==="bos"||x.type==="slash")&&(W.output=w+W.output),V(W);continue}if(x&&(x.type==="bracket"||x.type==="paren")&&r.regex===!0){W.output=_,V(W);continue}(h.index===h.start||x.type==="slash"||x.type==="dot")&&(x.type==="dot"?(h.output+=E,x.output+=E):r.dot===!0?(h.output+=I,x.output+=I):(h.output+=w,x.output+=w),N()!=="*"&&(h.output+=v,x.output+=v)),V(W)}for(;h.brackets>0;){if(r.strictBrackets===!0)throw new SyntaxError(mt("closing","]"));h.output=ye.escapeLast(h.output,"["),ae("brackets")}for(;h.parens>0;){if(r.strictBrackets===!0)throw new SyntaxError(mt("closing",")"));h.output=ye.escapeLast(h.output,"("),ae("parens")}for(;h.braces>0;){if(r.strictBrackets===!0)throw new SyntaxError(mt("closing","}"));h.output=ye.escapeLast(h.output,"{"),ae("braces")}if(r.strictSlashes!==!0&&(x.type==="star"||x.type==="bracket")&&V({type:"maybe_slash",value:"",output:`${y}?`}),h.backtrack===!0){h.output="";for(let k of h.tokens)h.output+=k.output!=null?k.output:k.value,k.suffix&&(h.output+=k.suffix)}return h};Cn.fastpaths=(e,t)=>{let r={...t},n=typeof r.maxLength=="number"?Math.min(ur,r.maxLength):ur,o=e.length;if(o>n)throw new SyntaxError(`Input length: ${o}, exceeds maximum allowed length: ${n}`);e=Us[e]||e;let i=ye.isWindows(t),{DOT_LITERAL:s,SLASH_LITERAL:a,ONE_CHAR:c,DOTS_SLASH:u,NO_DOT:f,NO_DOTS:d,NO_DOTS_SLASH:p,STAR:y,START_ANCHOR:v}=cr.globChars(i),b=r.dot?d:f,$=r.dot?p:f,E=r.capture?"":"?:",I={negated:!1,prefix:""},P=r.bash===!0?".*?":y;r.capture&&(P=`(${P})`);let D=w=>w.noglobstar===!0?P:`(${E}(?:(?!${v}${w.dot?u:s}).)*?)`,A=w=>{switch(w){case"*":return`${b}${c}${P}`;case".*":return`${s}${c}${P}`;case"*.*":return`${b}${P}${s}${c}${P}`;case"*/*":return`${b}${P}${a}${c}${$}${P}`;case"**":return b+D(r);case"**/*":return`(?:${b}${D(r)}${a})?${$}${c}${P}`;case"**/*.*":return`(?:${b}${D(r)}${a})?${$}${P}${s}${c}${P}`;case"**/.*":return`(?:${b}${D(r)}${a})?${s}${c}${P}`;default:{let T=/^(.*?)\.(\w+)$/.exec(w);if(!T)return;let G=A(T[1]);return G?G+s+T[2]:void 0}}},M=ye.removePrefix(e,I),C=A(M);return C&&r.strictSlashes!==!0&&(C+=`${a}?`),C};Ws.exports=Cn});var zs=R((r1,Ks)=>{"use strict";l();var ld=B("path"),cd=Bs(),En=Gs(),kn=$t(),ud=Tt(),fd=e=>e&&typeof e=="object"&&!Array.isArray(e),J=(e,t,r=!1)=>{if(Array.isArray(e)){let f=e.map(p=>J(p,t,r));return p=>{for(let y of f){let v=y(p);if(v)return v}return!1}}let n=fd(e)&&e.tokens&&e.input;if(e===""||typeof e!="string"&&!n)throw new TypeError("Expected pattern to be a non-empty string");let o=t||{},i=kn.isWindows(t),s=n?J.compileRe(e,t):J.makeRe(e,t,!1,!0),a=s.state;delete s.state;let c=()=>!1;if(o.ignore){let f={...t,ignore:null,onMatch:null,onResult:null};c=J(o.ignore,f,r)}let u=(f,d=!1)=>{let{isMatch:p,match:y,output:v}=J.test(f,s,t,{glob:e,posix:i}),b={glob:e,state:a,regex:s,posix:i,input:f,output:v,match:y,isMatch:p};return typeof o.onResult=="function"&&o.onResult(b),p===!1?(b.isMatch=!1,d?b:!1):c(f)?(typeof o.onIgnore=="function"&&o.onIgnore(b),b.isMatch=!1,d?b:!1):(typeof o.onMatch=="function"&&o.onMatch(b),d?b:!0)};return r&&(u.state=a),u};J.test=(e,t,r,{glob:n,posix:o}={})=>{if(typeof e!="string")throw new TypeError("Expected input to be a string");if(e==="")return{isMatch:!1,output:""};let i=r||{},s=i.format||(o?kn.toPosixSlashes:null),a=e===n,c=a&&s?s(e):e;return a===!1&&(c=s?s(e):e,a=c===n),(a===!1||i.capture===!0)&&(i.matchBase===!0||i.basename===!0?a=J.matchBase(e,t,r,o):a=t.exec(c)),{isMatch:!!a,match:a,output:c}};J.matchBase=(e,t,r,n=kn.isWindows(r))=>(t instanceof RegExp?t:J.makeRe(t,r)).test(ld.basename(e));J.isMatch=(e,t,r)=>J(t,r)(e);J.parse=(e,t)=>Array.isArray(e)?e.map(r=>J.parse(r,t)):En(e,{...t,fastpaths:!1});J.scan=(e,t)=>cd(e,t);J.compileRe=(e,t,r=!1,n=!1)=>{if(r===!0)return e.output;let o=t||{},i=o.contains?"":"^",s=o.contains?"":"$",a=`${i}(?:${e.output})${s}`;e&&e.negated===!0&&(a=`^(?!${a}).*$`);let c=J.toRegex(a,t);return n===!0&&(c.state=e),c};J.makeRe=(e,t={},r=!1,n=!1)=>{if(!e||typeof e!="string")throw new TypeError("Expected a non-empty string");let o={negated:!1,fastpaths:!0};return t.fastpaths!==!1&&(e[0]==="."||e[0]==="*")&&(o.output=En.fastpaths(e,t)),o.output||(o=En(e,t)),J.compileRe(o,t,r,n)};J.toRegex=(e,t)=>{try{let r=t||{};return new RegExp(e,r.flags||(r.nocase?"i":""))}catch(r){if(t&&t.debug===!0)throw r;return/$^/}};J.constants=ud;Ks.exports=J});var Xs=R((o1,Ys)=>{"use strict";l();Ys.exports=zs()});var ta=R((s1,ea)=>{"use strict";l();var Js=B("util"),Zs=Os(),Ee=Xs(),Pn=$t(),Qs=e=>e===""||e==="./",z=(e,t,r)=>{t=[].concat(t),e=[].concat(e);let n=new Set,o=new Set,i=new Set,s=0,a=f=>{i.add(f.output),r&&r.onResult&&r.onResult(f)};for(let f=0;f<t.length;f++){let d=Ee(String(t[f]),{...r,onResult:a},!0),p=d.state.negated||d.state.negatedExtglob;p&&s++;for(let y of e){let v=d(y,!0);(p?!v.isMatch:v.isMatch)&&(p?n.add(v.output):(n.delete(v.output),o.add(v.output)))}}let u=(s===t.length?[...i]:[...o]).filter(f=>!n.has(f));if(r&&u.length===0){if(r.failglob===!0)throw new Error(`No matches found for "${t.join(", ")}"`);if(r.nonull===!0||r.nullglob===!0)return r.unescape?t.map(f=>f.replace(/\\/g,"")):t}return u};z.match=z;z.matcher=(e,t)=>Ee(e,t);z.isMatch=(e,t,r)=>Ee(t,r)(e);z.any=z.isMatch;z.not=(e,t,r={})=>{t=[].concat(t).map(String);let n=new Set,o=[],i=a=>{r.onResult&&r.onResult(a),o.push(a.output)},s=new Set(z(e,t,{...r,onResult:i}));for(let a of o)s.has(a)||n.add(a);return[...n]};z.contains=(e,t,r)=>{if(typeof e!="string")throw new TypeError(`Expected a string: "${Js.inspect(e)}"`);if(Array.isArray(t))return t.some(n=>z.contains(e,n,r));if(typeof t=="string"){if(Qs(e)||Qs(t))return!1;if(e.includes(t)||e.startsWith("./")&&e.slice(2).includes(t))return!0}return z.isMatch(e,t,{...r,contains:!0})};z.matchKeys=(e,t,r)=>{if(!Pn.isObject(e))throw new TypeError("Expected the first argument to be an object");let n=z(Object.keys(e),t,r),o={};for(let i of n)o[i]=e[i];return o};z.some=(e,t,r)=>{let n=[].concat(e);for(let o of[].concat(t)){let i=Ee(String(o),r);if(n.some(s=>i(s)))return!0}return!1};z.every=(e,t,r)=>{let n=[].concat(e);for(let o of[].concat(t)){let i=Ee(String(o),r);if(!n.every(s=>i(s)))return!1}return!0};z.all=(e,t,r)=>{if(typeof e!="string")throw new TypeError(`Expected a string: "${Js.inspect(e)}"`);return[].concat(t).every(n=>Ee(n,r)(e))};z.capture=(e,t,r)=>{let n=Pn.isWindows(r),i=Ee.makeRe(String(e),{...r,capture:!0}).exec(n?Pn.toPosixSlashes(t):t);if(i)return i.slice(1).map(s=>s===void 0?"":s)};z.makeRe=(...e)=>Ee.makeRe(...e);z.scan=(...e)=>Ee.scan(...e);z.parse=(e,t)=>{let r=[];for(let n of[].concat(e||[]))for(let o of Zs(String(n),t))r.push(Ee.parse(o,t));return r};z.braces=(e,t)=>{if(typeof e!="string")throw new TypeError("Expected a string");return t&&t.nobrace===!0||!/\{.*\}/.test(e)?[e]:Zs(e,t)};z.braceExpand=(e,t)=>{if(typeof e!="string")throw new TypeError("Expected a string");return z.braces(e,{...t,expand:!0})};ea.exports=z});var ca=R(F=>{"use strict";l();Object.defineProperty(F,"__esModule",{value:!0});F.removeDuplicateSlashes=F.matchAny=F.convertPatternsToRe=F.makeRe=F.getPatternParts=F.expandBraceExpansion=F.expandPatternsWithBraceExpansion=F.isAffectDepthOfReadingPattern=F.endsWithSlashGlobStar=F.hasGlobStar=F.getBaseDirectory=F.isPatternRelatedToParentDirectory=F.getPatternsOutsideCurrentDirectory=F.getPatternsInsideCurrentDirectory=F.getPositivePatterns=F.getNegativePatterns=F.isPositivePattern=F.isNegativePattern=F.convertToNegativePattern=F.convertToPositivePattern=F.isDynamicPattern=F.isStaticPattern=void 0;var pd=B("path"),dd=zi(),An=ta(),ra="**",md="\\",gd=/[*?]|^!/,hd=/\[[^[]*]/,yd=/(?:^|[^!*+?@])\([^(]*\|[^|]*\)/,vd=/[!*+?@]\([^(]*\)/,xd=/,|\.\./,_d=/(?!^)\/{2,}/g;function na(e,t={}){return!oa(e,t)}F.isStaticPattern=na;function oa(e,t={}){return e===""?!1:!!(t.caseSensitiveMatch===!1||e.includes(md)||gd.test(e)||hd.test(e)||yd.test(e)||t.extglob!==!1&&vd.test(e)||t.braceExpansion!==!1&&bd(e))}F.isDynamicPattern=oa;function bd(e){let t=e.indexOf("{");if(t===-1)return!1;let r=e.indexOf("}",t+1);if(r===-1)return!1;let n=e.slice(t,r);return xd.test(n)}function Rd(e){return fr(e)?e.slice(1):e}F.convertToPositivePattern=Rd;function Sd(e){return"!"+e}F.convertToNegativePattern=Sd;function fr(e){return e.startsWith("!")&&e[1]!=="("}F.isNegativePattern=fr;function ia(e){return!fr(e)}F.isPositivePattern=ia;function wd(e){return e.filter(fr)}F.getNegativePatterns=wd;function Cd(e){return e.filter(ia)}F.getPositivePatterns=Cd;function Ed(e){return e.filter(t=>!On(t))}F.getPatternsInsideCurrentDirectory=Ed;function kd(e){return e.filter(On)}F.getPatternsOutsideCurrentDirectory=kd;function On(e){return e.startsWith("..")||e.startsWith("./..")}F.isPatternRelatedToParentDirectory=On;function Pd(e){return dd(e,{flipBackslashes:!1})}F.getBaseDirectory=Pd;function Ad(e){return e.includes(ra)}F.hasGlobStar=Ad;function sa(e){return e.endsWith("/"+ra)}F.endsWithSlashGlobStar=sa;function Od(e){let t=pd.basename(e);return sa(e)||na(t)}F.isAffectDepthOfReadingPattern=Od;function Td(e){return e.reduce((t,r)=>t.concat(aa(r)),[])}F.expandPatternsWithBraceExpansion=Td;function aa(e){let t=An.braces(e,{expand:!0,nodupes:!0,keepEscaping:!0});return t.sort((r,n)=>r.length-n.length),t.filter(r=>r!=="")}F.expandBraceExpansion=aa;function $d(e,t){let{parts:r}=An.scan(e,Object.assign(Object.assign({},t),{parts:!0}));return r.length===0&&(r=[e]),r[0].startsWith("/")&&(r[0]=r[0].slice(1),r.unshift("")),r}F.getPatternParts=$d;function la(e,t){return An.makeRe(e,t)}F.makeRe=la;function Nd(e,t){return e.map(r=>la(r,t))}F.convertPatternsToRe=Nd;function Md(e,t){return t.some(r=>r.test(e))}F.matchAny=Md;function Id(e){return e.replace(_d,"/")}F.removeDuplicateSlashes=Id});var da=R((u1,pa)=>{"use strict";l();var Ld=B("stream"),ua=Ld.PassThrough,Fd=Array.prototype.slice;pa.exports=Dd;function Dd(){let e=[],t=Fd.call(arguments),r=!1,n=t[t.length-1];n&&!Array.isArray(n)&&n.pipe==null?t.pop():n={};let o=n.end!==!1,i=n.pipeError===!0;n.objectMode==null&&(n.objectMode=!0),n.highWaterMark==null&&(n.highWaterMark=64*1024);let s=ua(n);function a(){for(let f=0,d=arguments.length;f<d;f++)e.push(fa(arguments[f],n));return c(),this}function c(){if(r)return;r=!0;let f=e.shift();if(!f){process.nextTick(u);return}Array.isArray(f)||(f=[f]);let d=f.length+1;function p(){--d>0||(r=!1,c())}function y(v){function b(){v.removeListener("merge2UnpipeEnd",b),v.removeListener("end",b),i&&v.removeListener("error",$),p()}function $(E){s.emit("error",E)}if(v._readableState.endEmitted)return p();v.on("merge2UnpipeEnd",b),v.on("end",b),i&&v.on("error",$),v.pipe(s,{end:!1}),v.resume()}for(let v=0;v<f.length;v++)y(f[v]);p()}function u(){r=!1,s.emit("queueDrain"),o&&s.end()}return s.setMaxListeners(0),s.add=a,s.on("unpipe",function(f){f.emit("merge2UnpipeEnd")}),t.length&&a.apply(null,t),s}function fa(e,t){if(Array.isArray(e))for(let r=0,n=e.length;r<n;r++)e[r]=fa(e[r],t);else{if(!e._readableState&&e.pipe&&(e=e.pipe(ua(t))),!e._readableState||!e.pause||!e.pipe)throw new Error("Only readable stream can be merged.");e.pause()}return e}});var ga=R(pr=>{"use strict";l();Object.defineProperty(pr,"__esModule",{value:!0});pr.merge=void 0;var Vd=da();function jd(e){let t=Vd(e);return e.forEach(r=>{r.once("error",n=>t.emit("error",n))}),t.once("close",()=>ma(e)),t.once("end",()=>ma(e)),t}pr.merge=jd;function ma(e){e.forEach(t=>t.emit("close"))}});var ha=R(gt=>{"use strict";l();Object.defineProperty(gt,"__esModule",{value:!0});gt.isEmpty=gt.isString=void 0;function Hd(e){return typeof e=="string"}gt.isString=Hd;function qd(e){return e===""}gt.isEmpty=qd});var Ie=R(ce=>{"use strict";l();Object.defineProperty(ce,"__esModule",{value:!0});ce.string=ce.stream=ce.pattern=ce.path=ce.fs=ce.errno=ce.array=void 0;var Bd=Ii();ce.array=Bd;var Ud=Li();ce.errno=Ud;var Wd=Fi();ce.fs=Wd;var Gd=Hi();ce.path=Gd;var Kd=ca();ce.pattern=Kd;var zd=ga();ce.stream=zd;var Yd=ha();ce.string=Yd});var _a=R(ue=>{"use strict";l();Object.defineProperty(ue,"__esModule",{value:!0});ue.convertPatternGroupToTask=ue.convertPatternGroupsToTasks=ue.groupPatternsByBaseDirectory=ue.getNegativePatternsAsPositive=ue.getPositivePatterns=ue.convertPatternsToTasks=ue.generate=void 0;var Se=Ie();function Xd(e,t){let r=ya(e,t),n=ya(t.ignore,t),o=va(r),i=xa(r,n),s=o.filter(f=>Se.pattern.isStaticPattern(f,t)),a=o.filter(f=>Se.pattern.isDynamicPattern(f,t)),c=Tn(s,i,!1),u=Tn(a,i,!0);return c.concat(u)}ue.generate=Xd;function ya(e,t){let r=e;return t.braceExpansion&&(r=Se.pattern.expandPatternsWithBraceExpansion(r)),t.baseNameMatch&&(r=r.map(n=>n.includes("/")?n:`**/${n}`)),r.map(n=>Se.pattern.removeDuplicateSlashes(n))}function Tn(e,t,r){let n=[],o=Se.pattern.getPatternsOutsideCurrentDirectory(e),i=Se.pattern.getPatternsInsideCurrentDirectory(e),s=$n(o),a=$n(i);return n.push(...Nn(s,t,r)),"."in a?n.push(Mn(".",i,t,r)):n.push(...Nn(a,t,r)),n}ue.convertPatternsToTasks=Tn;function va(e){return Se.pattern.getPositivePatterns(e)}ue.getPositivePatterns=va;function xa(e,t){return Se.pattern.getNegativePatterns(e).concat(t).map(Se.pattern.convertToPositivePattern)}ue.getNegativePatternsAsPositive=xa;function $n(e){let t={};return e.reduce((r,n)=>{let o=Se.pattern.getBaseDirectory(n);return o in r?r[o].push(n):r[o]=[n],r},t)}ue.groupPatternsByBaseDirectory=$n;function Nn(e,t,r){return Object.keys(e).map(n=>Mn(n,e[n],t,r))}ue.convertPatternGroupsToTasks=Nn;function Mn(e,t,r,n){return{dynamic:n,positive:t,negative:r,base:e,patterns:[].concat(t,r.map(Se.pattern.convertToNegativePattern))}}ue.convertPatternGroupToTask=Mn});var Ra=R(dr=>{"use strict";l();Object.defineProperty(dr,"__esModule",{value:!0});dr.read=void 0;function Qd(e,t,r){t.fs.lstat(e,(n,o)=>{if(n!==null){ba(r,n);return}if(!o.isSymbolicLink()||!t.followSymbolicLink){In(r,o);return}t.fs.stat(e,(i,s)=>{if(i!==null){if(t.throwErrorOnBrokenSymbolicLink){ba(r,i);return}In(r,o);return}t.markSymbolicLink&&(s.isSymbolicLink=()=>!0),In(r,s)})})}dr.read=Qd;function ba(e,t){e(t)}function In(e,t){e(null,t)}});var Sa=R(mr=>{"use strict";l();Object.defineProperty(mr,"__esModule",{value:!0});mr.read=void 0;function Jd(e,t){let r=t.fs.lstatSync(e);if(!r.isSymbolicLink()||!t.followSymbolicLink)return r;try{let n=t.fs.statSync(e);return t.markSymbolicLink&&(n.isSymbolicLink=()=>!0),n}catch(n){if(!t.throwErrorOnBrokenSymbolicLink)return r;throw n}}mr.read=Jd});var wa=R(De=>{"use strict";l();Object.defineProperty(De,"__esModule",{value:!0});De.createFileSystemAdapter=De.FILE_SYSTEM_ADAPTER=void 0;var gr=B("fs");De.FILE_SYSTEM_ADAPTER={lstat:gr.lstat,stat:gr.stat,lstatSync:gr.lstatSync,statSync:gr.statSync};function Zd(e){return e===void 0?De.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},De.FILE_SYSTEM_ADAPTER),e)}De.createFileSystemAdapter=Zd});var Ca=R(Fn=>{"use strict";l();Object.defineProperty(Fn,"__esModule",{value:!0});var em=wa(),Ln=class{constructor(t={}){this._options=t,this.followSymbolicLink=this._getValue(this._options.followSymbolicLink,!0),this.fs=em.createFileSystemAdapter(this._options.fs),this.markSymbolicLink=this._getValue(this._options.markSymbolicLink,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0)}_getValue(t,r){return t??r}};Fn.default=Ln});var rt=R(Ve=>{"use strict";l();Object.defineProperty(Ve,"__esModule",{value:!0});Ve.statSync=Ve.stat=Ve.Settings=void 0;var Ea=Ra(),tm=Sa(),Dn=Ca();Ve.Settings=Dn.default;function rm(e,t,r){if(typeof t=="function"){Ea.read(e,Vn(),t);return}Ea.read(e,Vn(t),r)}Ve.stat=rm;function nm(e,t){let r=Vn(t);return tm.read(e,r)}Ve.statSync=nm;function Vn(e={}){return e instanceof Dn.default?e:new Dn.default(e)}});var Aa=R((O1,Pa)=>{"use strict";l();var ka;Pa.exports=typeof queueMicrotask=="function"?queueMicrotask.bind(typeof window<"u"?window:global):e=>(ka||(ka=Promise.resolve())).then(e).catch(t=>setTimeout(()=>{throw t},0))});var Ta=R(($1,Oa)=>{"use strict";l();Oa.exports=im;var om=Aa();function im(e,t){let r,n,o,i=!0;Array.isArray(e)?(r=[],n=e.length):(o=Object.keys(e),r={},n=o.length);function s(c){function u(){t&&t(c,r),t=null}i?om(u):u()}function a(c,u,f){r[c]=f,(--n===0||u)&&s(u)}n?o?o.forEach(function(c){e[c](function(u,f){a(c,u,f)})}):e.forEach(function(c,u){c(function(f,d){a(u,f,d)})}):s(null),i=!1}});var jn=R(yr=>{"use strict";l();Object.defineProperty(yr,"__esModule",{value:!0});yr.IS_SUPPORT_READDIR_WITH_FILE_TYPES=void 0;var hr=process.versions.node.split(".");if(hr[0]===void 0||hr[1]===void 0)throw new Error(`Unexpected behavior. The 'process.versions.node' variable has invalid value: ${process.versions.node}`);var $a=Number.parseInt(hr[0],10),sm=Number.parseInt(hr[1],10),Na=10,am=10,lm=$a>Na,cm=$a===Na&&sm>=am;yr.IS_SUPPORT_READDIR_WITH_FILE_TYPES=lm||cm});var Ma=R(vr=>{"use strict";l();Object.defineProperty(vr,"__esModule",{value:!0});vr.createDirentFromStats=void 0;var Hn=class{constructor(t,r){this.name=t,this.isBlockDevice=r.isBlockDevice.bind(r),this.isCharacterDevice=r.isCharacterDevice.bind(r),this.isDirectory=r.isDirectory.bind(r),this.isFIFO=r.isFIFO.bind(r),this.isFile=r.isFile.bind(r),this.isSocket=r.isSocket.bind(r),this.isSymbolicLink=r.isSymbolicLink.bind(r)}};function um(e,t){return new Hn(e,t)}vr.createDirentFromStats=um});var qn=R(xr=>{"use strict";l();Object.defineProperty(xr,"__esModule",{value:!0});xr.fs=void 0;var fm=Ma();xr.fs=fm});var Bn=R(_r=>{"use strict";l();Object.defineProperty(_r,"__esModule",{value:!0});_r.joinPathSegments=void 0;function pm(e,t,r){return e.endsWith(r)?e+t:e+r+t}_r.joinPathSegments=pm});var ja=R(je=>{"use strict";l();Object.defineProperty(je,"__esModule",{value:!0});je.readdir=je.readdirWithFileTypes=je.read=void 0;var dm=rt(),Ia=Ta(),mm=jn(),La=qn(),Fa=Bn();function gm(e,t,r){if(!t.stats&&mm.IS_SUPPORT_READDIR_WITH_FILE_TYPES){Da(e,t,r);return}Va(e,t,r)}je.read=gm;function Da(e,t,r){t.fs.readdir(e,{withFileTypes:!0},(n,o)=>{if(n!==null){br(r,n);return}let i=o.map(a=>({dirent:a,name:a.name,path:Fa.joinPathSegments(e,a.name,t.pathSegmentSeparator)}));if(!t.followSymbolicLinks){Un(r,i);return}let s=i.map(a=>hm(a,t));Ia(s,(a,c)=>{if(a!==null){br(r,a);return}Un(r,c)})})}je.readdirWithFileTypes=Da;function hm(e,t){return r=>{if(!e.dirent.isSymbolicLink()){r(null,e);return}t.fs.stat(e.path,(n,o)=>{if(n!==null){if(t.throwErrorOnBrokenSymbolicLink){r(n);return}r(null,e);return}e.dirent=La.fs.createDirentFromStats(e.name,o),r(null,e)})}}function Va(e,t,r){t.fs.readdir(e,(n,o)=>{if(n!==null){br(r,n);return}let i=o.map(s=>{let a=Fa.joinPathSegments(e,s,t.pathSegmentSeparator);return c=>{dm.stat(a,t.fsStatSettings,(u,f)=>{if(u!==null){c(u);return}let d={name:s,path:a,dirent:La.fs.createDirentFromStats(s,f)};t.stats&&(d.stats=f),c(null,d)})}});Ia(i,(s,a)=>{if(s!==null){br(r,s);return}Un(r,a)})})}je.readdir=Va;function br(e,t){e(t)}function Un(e,t){e(null,t)}});var Wa=R(He=>{"use strict";l();Object.defineProperty(He,"__esModule",{value:!0});He.readdir=He.readdirWithFileTypes=He.read=void 0;var ym=rt(),vm=jn(),Ha=qn(),qa=Bn();function xm(e,t){return!t.stats&&vm.IS_SUPPORT_READDIR_WITH_FILE_TYPES?Ba(e,t):Ua(e,t)}He.read=xm;function Ba(e,t){return t.fs.readdirSync(e,{withFileTypes:!0}).map(n=>{let o={dirent:n,name:n.name,path:qa.joinPathSegments(e,n.name,t.pathSegmentSeparator)};if(o.dirent.isSymbolicLink()&&t.followSymbolicLinks)try{let i=t.fs.statSync(o.path);o.dirent=Ha.fs.createDirentFromStats(o.name,i)}catch(i){if(t.throwErrorOnBrokenSymbolicLink)throw i}return o})}He.readdirWithFileTypes=Ba;function Ua(e,t){return t.fs.readdirSync(e).map(n=>{let o=qa.joinPathSegments(e,n,t.pathSegmentSeparator),i=ym.statSync(o,t.fsStatSettings),s={name:n,path:o,dirent:Ha.fs.createDirentFromStats(n,i)};return t.stats&&(s.stats=i),s})}He.readdir=Ua});var Ga=R(qe=>{"use strict";l();Object.defineProperty(qe,"__esModule",{value:!0});qe.createFileSystemAdapter=qe.FILE_SYSTEM_ADAPTER=void 0;var ht=B("fs");qe.FILE_SYSTEM_ADAPTER={lstat:ht.lstat,stat:ht.stat,lstatSync:ht.lstatSync,statSync:ht.statSync,readdir:ht.readdir,readdirSync:ht.readdirSync};function _m(e){return e===void 0?qe.FILE_SYSTEM_ADAPTER:Object.assign(Object.assign({},qe.FILE_SYSTEM_ADAPTER),e)}qe.createFileSystemAdapter=_m});var Ka=R(Gn=>{"use strict";l();Object.defineProperty(Gn,"__esModule",{value:!0});var bm=B("path"),Rm=rt(),Sm=Ga(),Wn=class{constructor(t={}){this._options=t,this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!1),this.fs=Sm.createFileSystemAdapter(this._options.fs),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,bm.sep),this.stats=this._getValue(this._options.stats,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!0),this.fsStatSettings=new Rm.Settings({followSymbolicLink:this.followSymbolicLinks,fs:this.fs,throwErrorOnBrokenSymbolicLink:this.throwErrorOnBrokenSymbolicLink})}_getValue(t,r){return t??r}};Gn.default=Wn});var Rr=R(Be=>{"use strict";l();Object.defineProperty(Be,"__esModule",{value:!0});Be.Settings=Be.scandirSync=Be.scandir=void 0;var za=ja(),wm=Wa(),Kn=Ka();Be.Settings=Kn.default;function Cm(e,t,r){if(typeof t=="function"){za.read(e,zn(),t);return}za.read(e,zn(t),r)}Be.scandir=Cm;function Em(e,t){let r=zn(t);return wm.read(e,r)}Be.scandirSync=Em;function zn(e={}){return e instanceof Kn.default?e:new Kn.default(e)}});var Xa=R((J1,Ya)=>{"use strict";l();function km(e){var t=new e,r=t;function n(){var i=t;return i.next?t=i.next:(t=new e,r=t),i.next=null,i}function o(i){r.next=i,r=i}return{get:n,release:o}}Ya.exports=km});var Ja=R((eb,Yn)=>{"use strict";l();var Pm=Xa();function Qa(e,t,r){if(typeof e=="function"&&(r=t,t=e,e=null),!(r>=1))throw new Error("fastqueue concurrency must be equal to or greater than 1");var n=Pm(Am),o=null,i=null,s=0,a=null,c={push:b,drain:xe,saturated:xe,pause:f,paused:!1,get concurrency(){return r},set concurrency(A){if(!(A>=1))throw new Error("fastqueue concurrency must be equal to or greater than 1");if(r=A,!c.paused)for(;o&&s<r;)s++,E()},running:u,resume:y,idle:v,length:d,getQueue:p,unshift:$,empty:xe,kill:I,killAndDrain:P,error:D};return c;function u(){return s}function f(){c.paused=!0}function d(){for(var A=o,M=0;A;)A=A.next,M++;return M}function p(){for(var A=o,M=[];A;)M.push(A.value),A=A.next;return M}function y(){if(c.paused){if(c.paused=!1,o===null){s++,E();return}for(;o&&s<r;)s++,E()}}function v(){return s===0&&c.length()===0}function b(A,M){var C=n.get();C.context=e,C.release=E,C.value=A,C.callback=M||xe,C.errorHandler=a,s>=r||c.paused?i?(i.next=C,i=C):(o=C,i=C,c.saturated()):(s++,t.call(e,C.value,C.worked))}function $(A,M){var C=n.get();C.context=e,C.release=E,C.value=A,C.callback=M||xe,C.errorHandler=a,s>=r||c.paused?o?(C.next=o,o=C):(o=C,i=C,c.saturated()):(s++,t.call(e,C.value,C.worked))}function E(A){A&&n.release(A);var M=o;M&&s<=r?c.paused?s--:(i===o&&(i=null),o=M.next,M.next=null,t.call(e,M.value,M.worked),i===null&&c.empty()):--s===0&&c.drain()}function I(){o=null,i=null,c.drain=xe}function P(){o=null,i=null,c.drain(),c.drain=xe}function D(A){a=A}}function xe(){}function Am(){this.value=null,this.callback=xe,this.next=null,this.release=xe,this.context=null,this.errorHandler=null;var e=this;this.worked=function(r,n){var o=e.callback,i=e.errorHandler,s=e.value;e.value=null,e.callback=xe,e.errorHandler&&i(r,s),o.call(e.context,r,n),e.release(e)}}function Om(e,t,r){typeof e=="function"&&(r=t,t=e,e=null);function n(f,d){t.call(this,f).then(function(p){d(null,p)},d)}var o=Qa(e,n,r),i=o.push,s=o.unshift;return o.push=a,o.unshift=c,o.drained=u,o;function a(f){var d=new Promise(function(p,y){i(f,function(v,b){if(v){y(v);return}p(b)})});return d.catch(xe),d}function c(f){var d=new Promise(function(p,y){s(f,function(v,b){if(v){y(v);return}p(b)})});return d.catch(xe),d}function u(){if(o.idle())return new Promise(function(p){p()});var f=o.drain,d=new Promise(function(p){o.drain=function(){f(),p()}});return d}}Yn.exports=Qa;Yn.exports.promise=Om});var Sr=R(ke=>{"use strict";l();Object.defineProperty(ke,"__esModule",{value:!0});ke.joinPathSegments=ke.replacePathSegmentSeparator=ke.isAppliedFilter=ke.isFatalError=void 0;function Tm(e,t){return e.errorFilter===null?!0:!e.errorFilter(t)}ke.isFatalError=Tm;function $m(e,t){return e===null||e(t)}ke.isAppliedFilter=$m;function Nm(e,t){return e.split(/[/\\]/).join(t)}ke.replacePathSegmentSeparator=Nm;function Mm(e,t,r){return e===""?t:e.endsWith(r)?e+t:e+r+t}ke.joinPathSegments=Mm});var Jn=R(Qn=>{"use strict";l();Object.defineProperty(Qn,"__esModule",{value:!0});var Im=Sr(),Xn=class{constructor(t,r){this._root=t,this._settings=r,this._root=Im.replacePathSegmentSeparator(t,r.pathSegmentSeparator)}};Qn.default=Xn});var to=R(eo=>{"use strict";l();Object.defineProperty(eo,"__esModule",{value:!0});var Lm=B("events"),Fm=Rr(),Dm=Ja(),wr=Sr(),Vm=Jn(),Zn=class extends Vm.default{constructor(t,r){super(t,r),this._settings=r,this._scandir=Fm.scandir,this._emitter=new Lm.EventEmitter,this._queue=Dm(this._worker.bind(this),this._settings.concurrency),this._isFatalError=!1,this._isDestroyed=!1,this._queue.drain=()=>{this._isFatalError||this._emitter.emit("end")}}read(){return this._isFatalError=!1,this._isDestroyed=!1,setImmediate(()=>{this._pushToQueue(this._root,this._settings.basePath)}),this._emitter}get isDestroyed(){return this._isDestroyed}destroy(){if(this._isDestroyed)throw new Error("The reader is already destroyed");this._isDestroyed=!0,this._queue.killAndDrain()}onEntry(t){this._emitter.on("entry",t)}onError(t){this._emitter.once("error",t)}onEnd(t){this._emitter.once("end",t)}_pushToQueue(t,r){let n={directory:t,base:r};this._queue.push(n,o=>{o!==null&&this._handleError(o)})}_worker(t,r){this._scandir(t.directory,this._settings.fsScandirSettings,(n,o)=>{if(n!==null){r(n,void 0);return}for(let i of o)this._handleEntry(i,t.base);r(null,void 0)})}_handleError(t){this._isDestroyed||!wr.isFatalError(this._settings,t)||(this._isFatalError=!0,this._isDestroyed=!0,this._emitter.emit("error",t))}_handleEntry(t,r){if(this._isDestroyed||this._isFatalError)return;let n=t.path;r!==void 0&&(t.path=wr.joinPathSegments(r,t.name,this._settings.pathSegmentSeparator)),wr.isAppliedFilter(this._settings.entryFilter,t)&&this._emitEntry(t),t.dirent.isDirectory()&&wr.isAppliedFilter(this._settings.deepFilter,t)&&this._pushToQueue(n,r===void 0?void 0:t.path)}_emitEntry(t){this._emitter.emit("entry",t)}};eo.default=Zn});var Za=R(no=>{"use strict";l();Object.defineProperty(no,"__esModule",{value:!0});var jm=to(),ro=class{constructor(t,r){this._root=t,this._settings=r,this._reader=new jm.default(this._root,this._settings),this._storage=[]}read(t){this._reader.onError(r=>{Hm(t,r)}),this._reader.onEntry(r=>{this._storage.push(r)}),this._reader.onEnd(()=>{qm(t,this._storage)}),this._reader.read()}};no.default=ro;function Hm(e,t){e(t)}function qm(e,t){e(null,t)}});var el=R(io=>{"use strict";l();Object.defineProperty(io,"__esModule",{value:!0});var Bm=B("stream"),Um=to(),oo=class{constructor(t,r){this._root=t,this._settings=r,this._reader=new Um.default(this._root,this._settings),this._stream=new Bm.Readable({objectMode:!0,read:()=>{},destroy:()=>{this._reader.isDestroyed||this._reader.destroy()}})}read(){return this._reader.onError(t=>{this._stream.emit("error",t)}),this._reader.onEntry(t=>{this._stream.push(t)}),this._reader.onEnd(()=>{this._stream.push(null)}),this._reader.read(),this._stream}};io.default=oo});var tl=R(ao=>{"use strict";l();Object.defineProperty(ao,"__esModule",{value:!0});var Wm=Rr(),Cr=Sr(),Gm=Jn(),so=class extends Gm.default{constructor(){super(...arguments),this._scandir=Wm.scandirSync,this._storage=[],this._queue=new Set}read(){return this._pushToQueue(this._root,this._settings.basePath),this._handleQueue(),this._storage}_pushToQueue(t,r){this._queue.add({directory:t,base:r})}_handleQueue(){for(let t of this._queue.values())this._handleDirectory(t.directory,t.base)}_handleDirectory(t,r){try{let n=this._scandir(t,this._settings.fsScandirSettings);for(let o of n)this._handleEntry(o,r)}catch(n){this._handleError(n)}}_handleError(t){if(Cr.isFatalError(this._settings,t))throw t}_handleEntry(t,r){let n=t.path;r!==void 0&&(t.path=Cr.joinPathSegments(r,t.name,this._settings.pathSegmentSeparator)),Cr.isAppliedFilter(this._settings.entryFilter,t)&&this._pushToStorage(t),t.dirent.isDirectory()&&Cr.isAppliedFilter(this._settings.deepFilter,t)&&this._pushToQueue(n,r===void 0?void 0:t.path)}_pushToStorage(t){this._storage.push(t)}};ao.default=so});var rl=R(co=>{"use strict";l();Object.defineProperty(co,"__esModule",{value:!0});var Km=tl(),lo=class{constructor(t,r){this._root=t,this._settings=r,this._reader=new Km.default(this._root,this._settings)}read(){return this._reader.read()}};co.default=lo});var nl=R(fo=>{"use strict";l();Object.defineProperty(fo,"__esModule",{value:!0});var zm=B("path"),Ym=Rr(),uo=class{constructor(t={}){this._options=t,this.basePath=this._getValue(this._options.basePath,void 0),this.concurrency=this._getValue(this._options.concurrency,Number.POSITIVE_INFINITY),this.deepFilter=this._getValue(this._options.deepFilter,null),this.entryFilter=this._getValue(this._options.entryFilter,null),this.errorFilter=this._getValue(this._options.errorFilter,null),this.pathSegmentSeparator=this._getValue(this._options.pathSegmentSeparator,zm.sep),this.fsScandirSettings=new Ym.Settings({followSymbolicLinks:this._options.followSymbolicLinks,fs:this._options.fs,pathSegmentSeparator:this._options.pathSegmentSeparator,stats:this._options.stats,throwErrorOnBrokenSymbolicLink:this._options.throwErrorOnBrokenSymbolicLink})}_getValue(t,r){return t??r}};fo.default=uo});var kr=R(Pe=>{"use strict";l();Object.defineProperty(Pe,"__esModule",{value:!0});Pe.Settings=Pe.walkStream=Pe.walkSync=Pe.walk=void 0;var ol=Za(),Xm=el(),Qm=rl(),po=nl();Pe.Settings=po.default;function Jm(e,t,r){if(typeof t=="function"){new ol.default(e,Er()).read(t);return}new ol.default(e,Er(t)).read(r)}Pe.walk=Jm;function Zm(e,t){let r=Er(t);return new Qm.default(e,r).read()}Pe.walkSync=Zm;function eg(e,t){let r=Er(t);return new Xm.default(e,r).read()}Pe.walkStream=eg;function Er(e={}){return e instanceof po.default?e:new po.default(e)}});var Pr=R(go=>{"use strict";l();Object.defineProperty(go,"__esModule",{value:!0});var tg=B("path"),rg=rt(),il=Ie(),mo=class{constructor(t){this._settings=t,this._fsStatSettings=new rg.Settings({followSymbolicLink:this._settings.followSymbolicLinks,fs:this._settings.fs,throwErrorOnBrokenSymbolicLink:this._settings.followSymbolicLinks})}_getFullEntryPath(t){return tg.resolve(this._settings.cwd,t)}_makeEntry(t,r){let n={name:r,path:r,dirent:il.fs.createDirentFromStats(r,t)};return this._settings.stats&&(n.stats=t),n}_isFatalError(t){return!il.errno.isEnoentCodeError(t)&&!this._settings.suppressErrors}};go.default=mo});var vo=R(yo=>{"use strict";l();Object.defineProperty(yo,"__esModule",{value:!0});var ng=B("stream"),og=rt(),ig=kr(),sg=Pr(),ho=class extends sg.default{constructor(){super(...arguments),this._walkStream=ig.walkStream,this._stat=og.stat}dynamic(t,r){return this._walkStream(t,r)}static(t,r){let n=t.map(this._getFullEntryPath,this),o=new ng.PassThrough({objectMode:!0});o._write=(i,s,a)=>this._getEntry(n[i],t[i],r).then(c=>{c!==null&&r.entryFilter(c)&&o.push(c),i===n.length-1&&o.end(),a()}).catch(a);for(let i=0;i<n.length;i++)o.write(i);return o}_getEntry(t,r,n){return this._getStat(t).then(o=>this._makeEntry(o,r)).catch(o=>{if(n.errorFilter(o))return null;throw o})}_getStat(t){return new Promise((r,n)=>{this._stat(t,this._fsStatSettings,(o,i)=>o===null?r(i):n(o))})}};yo.default=ho});var sl=R(_o=>{"use strict";l();Object.defineProperty(_o,"__esModule",{value:!0});var ag=kr(),lg=Pr(),cg=vo(),xo=class extends lg.default{constructor(){super(...arguments),this._walkAsync=ag.walk,this._readerStream=new cg.default(this._settings)}dynamic(t,r){return new Promise((n,o)=>{this._walkAsync(t,r,(i,s)=>{i===null?n(s):o(i)})})}async static(t,r){let n=[],o=this._readerStream.static(t,r);return new Promise((i,s)=>{o.once("error",s),o.on("data",a=>n.push(a)),o.once("end",()=>i(n))})}};_o.default=xo});var al=R(Ro=>{"use strict";l();Object.defineProperty(Ro,"__esModule",{value:!0});var Mt=Ie(),bo=class{constructor(t,r,n){this._patterns=t,this._settings=r,this._micromatchOptions=n,this._storage=[],this._fillStorage()}_fillStorage(){for(let t of this._patterns){let r=this._getPatternSegments(t),n=this._splitSegmentsIntoSections(r);this._storage.push({complete:n.length<=1,pattern:t,segments:r,sections:n})}}_getPatternSegments(t){return Mt.pattern.getPatternParts(t,this._micromatchOptions).map(n=>Mt.pattern.isDynamicPattern(n,this._settings)?{dynamic:!0,pattern:n,patternRe:Mt.pattern.makeRe(n,this._micromatchOptions)}:{dynamic:!1,pattern:n})}_splitSegmentsIntoSections(t){return Mt.array.splitWhen(t,r=>r.dynamic&&Mt.pattern.hasGlobStar(r.pattern))}};Ro.default=bo});var ll=R(wo=>{"use strict";l();Object.defineProperty(wo,"__esModule",{value:!0});var ug=al(),So=class extends ug.default{match(t){let r=t.split("/"),n=r.length,o=this._storage.filter(i=>!i.complete||i.segments.length>n);for(let i of o){let s=i.sections[0];if(!i.complete&&n>s.length||r.every((c,u)=>{let f=i.segments[u];return!!(f.dynamic&&f.patternRe.test(c)||!f.dynamic&&f.pattern===c)}))return!0}return!1}};wo.default=So});var cl=R(Eo=>{"use strict";l();Object.defineProperty(Eo,"__esModule",{value:!0});var Ar=Ie(),fg=ll(),Co=class{constructor(t,r){this._settings=t,this._micromatchOptions=r}getFilter(t,r,n){let o=this._getMatcher(r),i=this._getNegativePatternsRe(n);return s=>this._filter(t,s,o,i)}_getMatcher(t){return new fg.default(t,this._settings,this._micromatchOptions)}_getNegativePatternsRe(t){let r=t.filter(Ar.pattern.isAffectDepthOfReadingPattern);return Ar.pattern.convertPatternsToRe(r,this._micromatchOptions)}_filter(t,r,n,o){if(this._isSkippedByDeep(t,r.path)||this._isSkippedSymbolicLink(r))return!1;let i=Ar.path.removeLeadingDotSegment(r.path);return this._isSkippedByPositivePatterns(i,n)?!1:this._isSkippedByNegativePatterns(i,o)}_isSkippedByDeep(t,r){return this._settings.deep===1/0?!1:this._getEntryLevel(t,r)>=this._settings.deep}_getEntryLevel(t,r){let n=r.split("/").length;if(t==="")return n;let o=t.split("/").length;return n-o}_isSkippedSymbolicLink(t){return!this._settings.followSymbolicLinks&&t.dirent.isSymbolicLink()}_isSkippedByPositivePatterns(t,r){return!this._settings.baseNameMatch&&!r.match(t)}_isSkippedByNegativePatterns(t,r){return!Ar.pattern.matchAny(t,r)}};Eo.default=Co});var ul=R(Po=>{"use strict";l();Object.defineProperty(Po,"__esModule",{value:!0});var nt=Ie(),ko=class{constructor(t,r){this._settings=t,this._micromatchOptions=r,this.index=new Map}getFilter(t,r){let n=nt.pattern.convertPatternsToRe(t,this._micromatchOptions),o=nt.pattern.convertPatternsToRe(r,Object.assign(Object.assign({},this._micromatchOptions),{dot:!0}));return i=>this._filter(i,n,o)}_filter(t,r,n){let o=nt.path.removeLeadingDotSegment(t.path);if(this._settings.unique&&this._isDuplicateEntry(o)||this._onlyFileFilter(t)||this._onlyDirectoryFilter(t)||this._isSkippedByAbsoluteNegativePatterns(o,n))return!1;let i=t.dirent.isDirectory(),s=this._isMatchToPatterns(o,r,i)&&!this._isMatchToPatterns(o,n,i);return this._settings.unique&&s&&this._createIndexRecord(o),s}_isDuplicateEntry(t){return this.index.has(t)}_createIndexRecord(t){this.index.set(t,void 0)}_onlyFileFilter(t){return this._settings.onlyFiles&&!t.dirent.isFile()}_onlyDirectoryFilter(t){return this._settings.onlyDirectories&&!t.dirent.isDirectory()}_isSkippedByAbsoluteNegativePatterns(t,r){if(!this._settings.absolute)return!1;let n=nt.path.makeAbsolute(this._settings.cwd,t);return nt.pattern.matchAny(n,r)}_isMatchToPatterns(t,r,n){let o=nt.pattern.matchAny(t,r);return!o&&n?nt.pattern.matchAny(t+"/",r):o}};Po.default=ko});var fl=R(Oo=>{"use strict";l();Object.defineProperty(Oo,"__esModule",{value:!0});var pg=Ie(),Ao=class{constructor(t){this._settings=t}getFilter(){return t=>this._isNonFatalError(t)}_isNonFatalError(t){return pg.errno.isEnoentCodeError(t)||this._settings.suppressErrors}};Oo.default=Ao});var dl=R($o=>{"use strict";l();Object.defineProperty($o,"__esModule",{value:!0});var pl=Ie(),To=class{constructor(t){this._settings=t}getTransformer(){return t=>this._transform(t)}_transform(t){let r=t.path;return this._settings.absolute&&(r=pl.path.makeAbsolute(this._settings.cwd,r),r=pl.path.unixify(r)),this._settings.markDirectories&&t.dirent.isDirectory()&&(r+="/"),this._settings.objectMode?Object.assign(Object.assign({},t),{path:r}):r}};$o.default=To});var Or=R(Mo=>{"use strict";l();Object.defineProperty(Mo,"__esModule",{value:!0});var dg=B("path"),mg=cl(),gg=ul(),hg=fl(),yg=dl(),No=class{constructor(t){this._settings=t,this.errorFilter=new hg.default(this._settings),this.entryFilter=new gg.default(this._settings,this._getMicromatchOptions()),this.deepFilter=new mg.default(this._settings,this._getMicromatchOptions()),this.entryTransformer=new yg.default(this._settings)}_getRootDirectory(t){return dg.resolve(this._settings.cwd,t.base)}_getReaderOptions(t){let r=t.base==="."?"":t.base;return{basePath:r,pathSegmentSeparator:"/",concurrency:this._settings.concurrency,deepFilter:this.deepFilter.getFilter(r,t.positive,t.negative),entryFilter:this.entryFilter.getFilter(t.positive,t.negative),errorFilter:this.errorFilter.getFilter(),followSymbolicLinks:this._settings.followSymbolicLinks,fs:this._settings.fs,stats:this._settings.stats,throwErrorOnBrokenSymbolicLink:this._settings.throwErrorOnBrokenSymbolicLink,transform:this.entryTransformer.getTransformer()}}_getMicromatchOptions(){return{dot:this._settings.dot,matchBase:this._settings.baseNameMatch,nobrace:!this._settings.braceExpansion,nocase:!this._settings.caseSensitiveMatch,noext:!this._settings.extglob,noglobstar:!this._settings.globstar,posix:!0,strictSlashes:!1}}};Mo.default=No});var ml=R(Lo=>{"use strict";l();Object.defineProperty(Lo,"__esModule",{value:!0});var vg=sl(),xg=Or(),Io=class extends xg.default{constructor(){super(...arguments),this._reader=new vg.default(this._settings)}async read(t){let r=this._getRootDirectory(t),n=this._getReaderOptions(t);return(await this.api(r,t,n)).map(i=>n.transform(i))}api(t,r,n){return r.dynamic?this._reader.dynamic(t,n):this._reader.static(r.patterns,n)}};Lo.default=Io});var gl=R(Do=>{"use strict";l();Object.defineProperty(Do,"__esModule",{value:!0});var _g=B("stream"),bg=vo(),Rg=Or(),Fo=class extends Rg.default{constructor(){super(...arguments),this._reader=new bg.default(this._settings)}read(t){let r=this._getRootDirectory(t),n=this._getReaderOptions(t),o=this.api(r,t,n),i=new _g.Readable({objectMode:!0,read:()=>{}});return o.once("error",s=>i.emit("error",s)).on("data",s=>i.emit("data",n.transform(s))).once("end",()=>i.emit("end")),i.once("close",()=>o.destroy()),i}api(t,r,n){return r.dynamic?this._reader.dynamic(t,n):this._reader.static(r.patterns,n)}};Do.default=Fo});var hl=R(jo=>{"use strict";l();Object.defineProperty(jo,"__esModule",{value:!0});var Sg=rt(),wg=kr(),Cg=Pr(),Vo=class extends Cg.default{constructor(){super(...arguments),this._walkSync=wg.walkSync,this._statSync=Sg.statSync}dynamic(t,r){return this._walkSync(t,r)}static(t,r){let n=[];for(let o of t){let i=this._getFullEntryPath(o),s=this._getEntry(i,o,r);s===null||!r.entryFilter(s)||n.push(s)}return n}_getEntry(t,r,n){try{let o=this._getStat(t);return this._makeEntry(o,r)}catch(o){if(n.errorFilter(o))return null;throw o}}_getStat(t){return this._statSync(t,this._fsStatSettings)}};jo.default=Vo});var yl=R(qo=>{"use strict";l();Object.defineProperty(qo,"__esModule",{value:!0});var Eg=hl(),kg=Or(),Ho=class extends kg.default{constructor(){super(...arguments),this._reader=new Eg.default(this._settings)}read(t){let r=this._getRootDirectory(t),n=this._getReaderOptions(t);return this.api(r,t,n).map(n.transform)}api(t,r,n){return r.dynamic?this._reader.dynamic(t,n):this._reader.static(r.patterns,n)}};qo.default=Ho});var vl=R(vt=>{"use strict";l();Object.defineProperty(vt,"__esModule",{value:!0});vt.DEFAULT_FILE_SYSTEM_ADAPTER=void 0;var yt=B("fs"),Pg=B("os"),Ag=Math.max(Pg.cpus().length,1);vt.DEFAULT_FILE_SYSTEM_ADAPTER={lstat:yt.lstat,lstatSync:yt.lstatSync,stat:yt.stat,statSync:yt.statSync,readdir:yt.readdir,readdirSync:yt.readdirSync};var Bo=class{constructor(t={}){this._options=t,this.absolute=this._getValue(this._options.absolute,!1),this.baseNameMatch=this._getValue(this._options.baseNameMatch,!1),this.braceExpansion=this._getValue(this._options.braceExpansion,!0),this.caseSensitiveMatch=this._getValue(this._options.caseSensitiveMatch,!0),this.concurrency=this._getValue(this._options.concurrency,Ag),this.cwd=this._getValue(this._options.cwd,process.cwd()),this.deep=this._getValue(this._options.deep,1/0),this.dot=this._getValue(this._options.dot,!1),this.extglob=this._getValue(this._options.extglob,!0),this.followSymbolicLinks=this._getValue(this._options.followSymbolicLinks,!0),this.fs=this._getFileSystemMethods(this._options.fs),this.globstar=this._getValue(this._options.globstar,!0),this.ignore=this._getValue(this._options.ignore,[]),this.markDirectories=this._getValue(this._options.markDirectories,!1),this.objectMode=this._getValue(this._options.objectMode,!1),this.onlyDirectories=this._getValue(this._options.onlyDirectories,!1),this.onlyFiles=this._getValue(this._options.onlyFiles,!0),this.stats=this._getValue(this._options.stats,!1),this.suppressErrors=this._getValue(this._options.suppressErrors,!1),this.throwErrorOnBrokenSymbolicLink=this._getValue(this._options.throwErrorOnBrokenSymbolicLink,!1),this.unique=this._getValue(this._options.unique,!0),this.onlyDirectories&&(this.onlyFiles=!1),this.stats&&(this.objectMode=!0),this.ignore=[].concat(this.ignore)}_getValue(t,r){return t===void 0?r:t}_getFileSystemMethods(t={}){return Object.assign(Object.assign({},vt.DEFAULT_FILE_SYSTEM_ADAPTER),t)}};vt.default=Bo});var Tr=R((Xb,_l)=>{"use strict";l();var xl=_a(),Og=ml(),Tg=gl(),$g=yl(),Uo=vl(),_e=Ie();async function Wo(e,t){we(e);let r=Go(e,Og.default,t),n=await Promise.all(r);return _e.array.flatten(n)}(function(e){e.glob=e,e.globSync=t,e.globStream=r,e.async=e;function t(u,f){we(u);let d=Go(u,$g.default,f);return _e.array.flatten(d)}e.sync=t;function r(u,f){we(u);let d=Go(u,Tg.default,f);return _e.stream.merge(d)}e.stream=r;function n(u,f){we(u);let d=[].concat(u),p=new Uo.default(f);return xl.generate(d,p)}e.generateTasks=n;function o(u,f){we(u);let d=new Uo.default(f);return _e.pattern.isDynamicPattern(u,d)}e.isDynamicPattern=o;function i(u){return we(u),_e.path.escape(u)}e.escapePath=i;function s(u){return we(u),_e.path.convertPathToPattern(u)}e.convertPathToPattern=s;let a;(function(u){function f(p){return we(p),_e.path.escapePosixPath(p)}u.escapePath=f;function d(p){return we(p),_e.path.convertPosixPathToPattern(p)}u.convertPathToPattern=d})(a=e.posix||(e.posix={}));let c;(function(u){function f(p){return we(p),_e.path.escapeWindowsPath(p)}u.escapePath=f;function d(p){return we(p),_e.path.convertWindowsPathToPattern(p)}u.convertPathToPattern=d})(c=e.win32||(e.win32={}))})(Wo||(Wo={}));function Go(e,t,r){let n=[].concat(e),o=new Uo.default(r),i=xl.generate(n,o),s=new t(o);return i.map(s.read,s)}function we(e){if(![].concat(e).every(n=>_e.string.isString(n)&&!_e.string.isEmpty(n)))throw new TypeError("Patterns must be a string (non empty) or an array of strings")}_l.exports=Wo});var Tl=R((pR,Ol)=>{"use strict";l();var{hasOwnProperty:zo}=Object.prototype,Yo=(e,t={})=>{typeof t=="string"&&(t={section:t}),t.align=t.align===!0,t.newline=t.newline===!0,t.sort=t.sort===!0,t.whitespace=t.whitespace===!0||t.align===!0,t.platform=t.platform||typeof process<"u"&&process.platform,t.bracketedArray=t.bracketedArray!==!1;let r=t.platform==="win32"?`\r
|
|
4
|
+
`:`
|
|
5
|
+
`,n=t.whitespace?" = ":"=",o=[],i=t.sort?Object.keys(e).sort():Object.keys(e),s=0;t.align&&(s=Le(i.filter(u=>e[u]===null||Array.isArray(e[u])||typeof e[u]!="object").map(u=>Array.isArray(e[u])?`${u}[]`:u).concat([""]).reduce((u,f)=>Le(u).length>=Le(f).length?u:f)).length);let a="",c=t.bracketedArray?"[]":"";for(let u of i){let f=e[u];if(f&&Array.isArray(f))for(let d of f)a+=Le(`${u}${c}`).padEnd(s," ")+n+Le(d)+r;else f&&typeof f=="object"?o.push(u):a+=Le(u).padEnd(s," ")+n+Le(f)+r}t.section&&a.length&&(a="["+Le(t.section)+"]"+(t.newline?r+r:r)+a);for(let u of o){let f=Pl(u,".").join("\\."),d=(t.section?t.section+".":"")+f,p=Yo(e[u],{...t,section:d});a.length&&p.length&&(a+=r),a+=p}return a};function Pl(e,t){var r=0,n=0,o=0,i=[];do if(o=e.indexOf(t,r),o!==-1){if(r=o+t.length,o>0&&e[o-1]==="\\")continue;i.push(e.slice(n,o)),n=o+t.length}while(o!==-1);return i.push(e.slice(n)),i}var kl=(e,t={})=>{t.bracketedArray=t.bracketedArray!==!1;let r=Object.create(null),n=r,o=null,i=/^\[([^\]]*)\]\s*$|^([^=]+)(=(.*))?$/i,s=e.split(/[\r\n]+/g),a={};for(let u of s){if(!u||u.match(/^\s*[;#]/)||u.match(/^\s*$/))continue;let f=u.match(i);if(!f)continue;if(f[1]!==void 0){if(o=$r(f[1]),o==="__proto__"){n=Object.create(null);continue}n=r[o]=r[o]||Object.create(null);continue}let d=$r(f[2]),p;t.bracketedArray?p=d.length>2&&d.slice(-2)==="[]":(a[d]=(a?.[d]||0)+1,p=a[d]>1);let y=p?d.slice(0,-2):d;if(y==="__proto__")continue;let v=f[3]?$r(f[4]):!0,b=v==="true"||v==="false"||v==="null"?JSON.parse(v):v;p&&(zo.call(n,y)?Array.isArray(n[y])||(n[y]=[n[y]]):n[y]=[]),Array.isArray(n[y])?n[y].push(b):n[y]=b}let c=[];for(let u of Object.keys(r)){if(!zo.call(r,u)||typeof r[u]!="object"||Array.isArray(r[u]))continue;let f=Pl(u,".");n=r;let d=f.pop(),p=d.replace(/\\\./g,".");for(let y of f)y!=="__proto__"&&((!zo.call(n,y)||typeof n[y]!="object")&&(n[y]=Object.create(null)),n=n[y]);n===r&&p===d||(n[p]=r[u],c.push(u))}for(let u of c)delete r[u];return r},Al=e=>e.startsWith('"')&&e.endsWith('"')||e.startsWith("'")&&e.endsWith("'"),Le=e=>typeof e!="string"||e.match(/[=\r\n]/)||e.match(/^\[/)||e.length>1&&Al(e)||e!==e.trim()?JSON.stringify(e):e.split(";").join("\\;").split("#").join("\\#"),$r=(e,t)=>{if(e=(e||"").trim(),Al(e)){e.charAt(0)==="'"&&(e=e.slice(1,-1));try{e=JSON.parse(e)}catch{}}else{let r=!1,n="";for(let o=0,i=e.length;o<i;o++){let s=e.charAt(o);if(r)"\\;#".indexOf(s)!==-1?n+=s:n+="\\"+s,r=!1;else{if(";#".indexOf(s)!==-1)break;s==="\\"?r=!0:n+=s}}return r&&(n+="\\"),n.trim()}return e};Ol.exports={parse:kl,decode:kl,stringify:Yo,encode:Yo,safe:Le,unsafe:$r}});var Jo=R((_R,Ll)=>{"use strict";l();var jg=B("os");Ll.exports=jg.homedir||function(){var t=process.env.HOME,r=process.env.LOGNAME||process.env.USER||process.env.LNAME||process.env.USERNAME;return process.platform==="win32"?process.env.USERPROFILE||process.env.HOMEDRIVE+process.env.HOMEPATH||t||null:process.platform==="darwin"?t||(r?"/Users/"+r:null):process.platform==="linux"?t||(process.getuid()===0?"/root":r?"/home/"+r:null):t||null}});var Zo=R((RR,Fl)=>{"use strict";l();Fl.exports=function(){var e=Error.prepareStackTrace;Error.prepareStackTrace=function(r,n){return n};var t=new Error().stack;return Error.prepareStackTrace=e,t[2].getFileName()}});var Dl=R((wR,Dt)=>{"use strict";l();var Hg=process.platform==="win32",qg=/^(((?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?[\\\/]?)(?:[^\\\/]*[\\\/])*)((\.{1,2}|[^\\\/]+?|)(\.[^.\/\\]*|))[\\\/]*$/,ei={};function Bg(e){return qg.exec(e).slice(1)}ei.parse=function(e){if(typeof e!="string")throw new TypeError("Parameter 'pathString' must be a string, not "+typeof e);var t=Bg(e);if(!t||t.length!==5)throw new TypeError("Invalid path '"+e+"'");return{root:t[1],dir:t[0]===t[1]?t[0]:t[0].slice(0,-1),base:t[2],ext:t[4],name:t[3]}};var Ug=/^((\/?)(?:[^\/]*\/)*)((\.{1,2}|[^\/]+?|)(\.[^.\/]*|))[\/]*$/,ti={};function Wg(e){return Ug.exec(e).slice(1)}ti.parse=function(e){if(typeof e!="string")throw new TypeError("Parameter 'pathString' must be a string, not "+typeof e);var t=Wg(e);if(!t||t.length!==5)throw new TypeError("Invalid path '"+e+"'");return{root:t[1],dir:t[0].slice(0,-1),base:t[2],ext:t[4],name:t[3]}};Hg?Dt.exports=ei.parse:Dt.exports=ti.parse;Dt.exports.posix=ti.parse;Dt.exports.win32=ei.parse});var ri=R((ER,ql)=>{"use strict";l();var Hl=B("path"),Vl=Hl.parse||Dl(),jl=function(t,r){var n="/";/^([A-Za-z]:)/.test(t)?n="":/^\\\\/.test(t)&&(n="\\\\");for(var o=[t],i=Vl(t);i.dir!==o[o.length-1];)o.push(i.dir),i=Vl(i.dir);return o.reduce(function(s,a){return s.concat(r.map(function(c){return Hl.resolve(n,a,c)}))},[])};ql.exports=function(t,r,n){var o=r&&r.moduleDirectory?[].concat(r.moduleDirectory):["node_modules"];if(r&&typeof r.paths=="function")return r.paths(n,t,function(){return jl(t,o)},r);var i=jl(t,o);return r&&r.paths?i.concat(r.paths):i}});var ni=R((PR,Bl)=>{"use strict";l();Bl.exports=function(e,t){return t||{}}});var Gl=R((OR,Wl)=>{"use strict";l();var Gg="Function.prototype.bind called on incompatible ",Kg=Object.prototype.toString,zg=Math.max,Yg="[object Function]",Ul=function(t,r){for(var n=[],o=0;o<t.length;o+=1)n[o]=t[o];for(var i=0;i<r.length;i+=1)n[i+t.length]=r[i];return n},Xg=function(t,r){for(var n=[],o=r||0,i=0;o<t.length;o+=1,i+=1)n[i]=t[o];return n},Qg=function(e,t){for(var r="",n=0;n<e.length;n+=1)r+=e[n],n+1<e.length&&(r+=t);return r};Wl.exports=function(t){var r=this;if(typeof r!="function"||Kg.apply(r)!==Yg)throw new TypeError(Gg+r);for(var n=Xg(arguments,1),o,i=function(){if(this instanceof o){var f=r.apply(this,Ul(n,arguments));return Object(f)===f?f:this}return r.apply(t,Ul(n,arguments))},s=zg(0,r.length-n.length),a=[],c=0;c<s;c++)a[c]="$"+c;if(o=Function("binder","return function ("+Qg(a,",")+"){ return binder.apply(this,arguments); }")(i),r.prototype){var u=function(){};u.prototype=r.prototype,o.prototype=new u,u.prototype=null}return o}});var zl=R(($R,Kl)=>{"use strict";l();var Jg=Gl();Kl.exports=Function.prototype.bind||Jg});var Xl=R((MR,Yl)=>{"use strict";l();var Zg=Function.prototype.call,eh=Object.prototype.hasOwnProperty,th=zl();Yl.exports=th.call(Zg,eh)});var Ql=R((LR,rh)=>{rh.exports={assert:!0,"node:assert":[">= 14.18 && < 15",">= 16"],"assert/strict":">= 15","node:assert/strict":">= 16",async_hooks:">= 8","node:async_hooks":[">= 14.18 && < 15",">= 16"],buffer_ieee754:">= 0.5 && < 0.9.7",buffer:!0,"node:buffer":[">= 14.18 && < 15",">= 16"],child_process:!0,"node:child_process":[">= 14.18 && < 15",">= 16"],cluster:">= 0.5","node:cluster":[">= 14.18 && < 15",">= 16"],console:!0,"node:console":[">= 14.18 && < 15",">= 16"],constants:!0,"node:constants":[">= 14.18 && < 15",">= 16"],crypto:!0,"node:crypto":[">= 14.18 && < 15",">= 16"],_debug_agent:">= 1 && < 8",_debugger:"< 8",dgram:!0,"node:dgram":[">= 14.18 && < 15",">= 16"],diagnostics_channel:[">= 14.17 && < 15",">= 15.1"],"node:diagnostics_channel":[">= 14.18 && < 15",">= 16"],dns:!0,"node:dns":[">= 14.18 && < 15",">= 16"],"dns/promises":">= 15","node:dns/promises":">= 16",domain:">= 0.7.12","node:domain":[">= 14.18 && < 15",">= 16"],events:!0,"node:events":[">= 14.18 && < 15",">= 16"],freelist:"< 6",fs:!0,"node:fs":[">= 14.18 && < 15",">= 16"],"fs/promises":[">= 10 && < 10.1",">= 14"],"node:fs/promises":[">= 14.18 && < 15",">= 16"],_http_agent:">= 0.11.1","node:_http_agent":[">= 14.18 && < 15",">= 16"],_http_client:">= 0.11.1","node:_http_client":[">= 14.18 && < 15",">= 16"],_http_common:">= 0.11.1","node:_http_common":[">= 14.18 && < 15",">= 16"],_http_incoming:">= 0.11.1","node:_http_incoming":[">= 14.18 && < 15",">= 16"],_http_outgoing:">= 0.11.1","node:_http_outgoing":[">= 14.18 && < 15",">= 16"],_http_server:">= 0.11.1","node:_http_server":[">= 14.18 && < 15",">= 16"],http:!0,"node:http":[">= 14.18 && < 15",">= 16"],http2:">= 8.8","node:http2":[">= 14.18 && < 15",">= 16"],https:!0,"node:https":[">= 14.18 && < 15",">= 16"],inspector:">= 8","node:inspector":[">= 14.18 && < 15",">= 16"],"inspector/promises":[">= 19"],"node:inspector/promises":[">= 19"],_linklist:"< 8",module:!0,"node:module":[">= 14.18 && < 15",">= 16"],net:!0,"node:net":[">= 14.18 && < 15",">= 16"],"node-inspect/lib/_inspect":">= 7.6 && < 12","node-inspect/lib/internal/inspect_client":">= 7.6 && < 12","node-inspect/lib/internal/inspect_repl":">= 7.6 && < 12",os:!0,"node:os":[">= 14.18 && < 15",">= 16"],path:!0,"node:path":[">= 14.18 && < 15",">= 16"],"path/posix":">= 15.3","node:path/posix":">= 16","path/win32":">= 15.3","node:path/win32":">= 16",perf_hooks:">= 8.5","node:perf_hooks":[">= 14.18 && < 15",">= 16"],process:">= 1","node:process":[">= 14.18 && < 15",">= 16"],punycode:">= 0.5","node:punycode":[">= 14.18 && < 15",">= 16"],querystring:!0,"node:querystring":[">= 14.18 && < 15",">= 16"],readline:!0,"node:readline":[">= 14.18 && < 15",">= 16"],"readline/promises":">= 17","node:readline/promises":">= 17",repl:!0,"node:repl":[">= 14.18 && < 15",">= 16"],"node:sea":[">= 20.12 && < 21",">= 21.7"],smalloc:">= 0.11.5 && < 3",_stream_duplex:">= 0.9.4","node:_stream_duplex":[">= 14.18 && < 15",">= 16"],_stream_transform:">= 0.9.4","node:_stream_transform":[">= 14.18 && < 15",">= 16"],_stream_wrap:">= 1.4.1","node:_stream_wrap":[">= 14.18 && < 15",">= 16"],_stream_passthrough:">= 0.9.4","node:_stream_passthrough":[">= 14.18 && < 15",">= 16"],_stream_readable:">= 0.9.4","node:_stream_readable":[">= 14.18 && < 15",">= 16"],_stream_writable:">= 0.9.4","node:_stream_writable":[">= 14.18 && < 15",">= 16"],stream:!0,"node:stream":[">= 14.18 && < 15",">= 16"],"stream/consumers":">= 16.7","node:stream/consumers":">= 16.7","stream/promises":">= 15","node:stream/promises":">= 16","stream/web":">= 16.5","node:stream/web":">= 16.5",string_decoder:!0,"node:string_decoder":[">= 14.18 && < 15",">= 16"],sys:[">= 0.4 && < 0.7",">= 0.8"],"node:sys":[">= 14.18 && < 15",">= 16"],"test/reporters":">= 19.9 && < 20.2","node:test/reporters":[">= 18.17 && < 19",">= 19.9",">= 20"],"test/mock_loader":">= 22.3","node:test/mock_loader":">= 22.3","node:test":[">= 16.17 && < 17",">= 18"],timers:!0,"node:timers":[">= 14.18 && < 15",">= 16"],"timers/promises":">= 15","node:timers/promises":">= 16",_tls_common:">= 0.11.13","node:_tls_common":[">= 14.18 && < 15",">= 16"],_tls_legacy:">= 0.11.3 && < 10",_tls_wrap:">= 0.11.3","node:_tls_wrap":[">= 14.18 && < 15",">= 16"],tls:!0,"node:tls":[">= 14.18 && < 15",">= 16"],trace_events:">= 10","node:trace_events":[">= 14.18 && < 15",">= 16"],tty:!0,"node:tty":[">= 14.18 && < 15",">= 16"],url:!0,"node:url":[">= 14.18 && < 15",">= 16"],util:!0,"node:util":[">= 14.18 && < 15",">= 16"],"util/types":">= 15.3","node:util/types":">= 16","v8/tools/arguments":">= 10 && < 12","v8/tools/codemap":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/consarray":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/csvparser":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/logreader":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/profile_view":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/splaytree":[">= 4.4 && < 5",">= 5.2 && < 12"],v8:">= 1","node:v8":[">= 14.18 && < 15",">= 16"],vm:!0,"node:vm":[">= 14.18 && < 15",">= 16"],wasi:[">= 13.4 && < 13.5",">= 18.17 && < 19",">= 20"],"node:wasi":[">= 18.17 && < 19",">= 20"],worker_threads:">= 11.7","node:worker_threads":[">= 14.18 && < 15",">= 16"],zlib:">= 0.5","node:zlib":[">= 14.18 && < 15",">= 16"]}});var Vt=R((FR,ec)=>{"use strict";l();var nh=Xl();function oh(e,t){for(var r=e.split("."),n=t.split(" "),o=n.length>1?n[0]:"=",i=(n.length>1?n[1]:n[0]).split("."),s=0;s<3;++s){var a=parseInt(r[s]||0,10),c=parseInt(i[s]||0,10);if(a!==c)return o==="<"?a<c:o===">="?a>=c:!1}return o===">="}function Jl(e,t){var r=t.split(/ ?&& ?/);if(r.length===0)return!1;for(var n=0;n<r.length;++n)if(!oh(e,r[n]))return!1;return!0}function ih(e,t){if(typeof t=="boolean")return t;var r=typeof e>"u"?process.versions&&process.versions.node:e;if(typeof r!="string")throw new TypeError(typeof e>"u"?"Unable to determine current node version":"If provided, a valid node version is required");if(t&&typeof t=="object"){for(var n=0;n<t.length;++n)if(Jl(r,t[n]))return!0;return!1}return Jl(r,t)}var Zl=Ql();ec.exports=function(t,r){return nh(Zl,t)&&ih(r,Zl[t])}});var nc=R((VR,rc)=>{"use strict";l();var ot=B("fs"),sh=Jo(),re=B("path"),ah=Zo(),lh=ri(),ch=ni(),uh=Vt(),fh=process.platform!=="win32"&&ot.realpath&&typeof ot.realpath.native=="function"?ot.realpath.native:ot.realpath,tc=sh(),ph=function(){return[re.join(tc,".node_modules"),re.join(tc,".node_libraries")]},dh=function(t,r){ot.stat(t,function(n,o){return n?n.code==="ENOENT"||n.code==="ENOTDIR"?r(null,!1):r(n):r(null,o.isFile()||o.isFIFO())})},mh=function(t,r){ot.stat(t,function(n,o){return n?n.code==="ENOENT"||n.code==="ENOTDIR"?r(null,!1):r(n):r(null,o.isDirectory())})},gh=function(t,r){fh(t,function(n,o){n&&n.code!=="ENOENT"?r(n):r(null,n?t:o)})},jt=function(t,r,n,o){n&&n.preserveSymlinks===!1?t(r,o):o(null,r)},hh=function(t,r,n){t(r,function(o,i){if(o)n(o);else try{var s=JSON.parse(i);n(null,s)}catch{n(null)}})},yh=function(t,r,n){for(var o=lh(r,n,t),i=0;i<o.length;i++)o[i]=re.join(o[i],t);return o};rc.exports=function(t,r,n){var o=n,i=r;if(typeof r=="function"&&(o=i,i={}),typeof t!="string"){var s=new TypeError("Path must be a string.");return process.nextTick(function(){o(s)})}i=ch(t,i);var a=i.isFile||dh,c=i.isDirectory||mh,u=i.readFile||ot.readFile,f=i.realpath||gh,d=i.readPackage||hh;if(i.readFile&&i.readPackage){var p=new TypeError("`readFile` and `readPackage` are mutually exclusive.");return process.nextTick(function(){o(p)})}var y=i.packageIterator,v=i.extensions||[".js"],b=i.includeCoreModules!==!1,$=i.basedir||re.dirname(ah()),E=i.filename||$;i.paths=i.paths||ph();var I=re.resolve($);jt(f,I,i,function(h,O){h?o(h):D(O)});var P;function D(h){if(/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/.test(t))P=re.resolve(h,t),(t==="."||t===".."||t.slice(-1)==="/")&&(P+="/"),/\/$/.test(t)&&P===h?w(P,i.package,A):M(P,i.package,A);else{if(b&&uh(t))return o(null,t);G(t,h,function(O,L,j){if(O)o(O);else{if(L)return jt(f,L,i,function(_,q){_?o(_):o(null,q,j)});var x=new Error("Cannot find module '"+t+"' from '"+E+"'");x.code="MODULE_NOT_FOUND",o(x)}})}}function A(h,O,L){h?o(h):O?o(null,O,L):w(P,function(j,x,_){if(j)o(j);else if(x)jt(f,x,i,function(N,K){N?o(N):o(null,K,_)});else{var q=new Error("Cannot find module '"+t+"' from '"+E+"'");q.code="MODULE_NOT_FOUND",o(q)}})}function M(h,O,L){var j=O,x=L;typeof j=="function"&&(x=j,j=void 0);var _=[""].concat(v);q(_,h,j);function q(N,K,Z){if(N.length===0)return x(null,void 0,Z);var Q=K+N[0],pe=Z;pe?se(null,pe):C(re.dirname(Q),se);function se(ae,V,me){if(pe=V,ae)return x(ae);if(me&&pe&&i.pathFilter){var ut=re.relative(me,Q),k=ut.slice(0,ut.length-N[0].length),W=i.pathFilter(pe,K,k);if(W)return q([""].concat(v.slice()),re.resolve(me,W),pe)}a(Q,Ne)}function Ne(ae,V){if(ae)return x(ae);if(V)return x(null,Q,pe);q(N.slice(1),K,pe)}}}function C(h,O){if(h===""||h==="/"||process.platform==="win32"&&/^\w:[/\\]*$/.test(h)||/[/\\]node_modules[/\\]*$/.test(h))return O(null);jt(f,h,i,function(L,j){if(L)return C(re.dirname(h),O);var x=re.join(j,"package.json");a(x,function(_,q){if(!q)return C(re.dirname(h),O);d(u,x,function(N,K){N&&O(N);var Z=K;Z&&i.packageFilter&&(Z=i.packageFilter(Z,x)),O(null,Z,h)})})})}function w(h,O,L){var j=L,x=O;typeof x=="function"&&(j=x,x=i.package),jt(f,h,i,function(_,q){if(_)return j(_);var N=re.join(q,"package.json");a(N,function(K,Z){if(K)return j(K);if(!Z)return M(re.join(h,"index"),x,j);d(u,N,function(Q,pe){if(Q)return j(Q);var se=pe;if(se&&i.packageFilter&&(se=i.packageFilter(se,N)),se&&se.main){if(typeof se.main!="string"){var Ne=new TypeError("package \u201C"+se.name+"\u201D `main` must be a string");return Ne.code="INVALID_PACKAGE_MAIN",j(Ne)}(se.main==="."||se.main==="./")&&(se.main="index"),M(re.resolve(h,se.main),se,function(ae,V,me){if(ae)return j(ae);if(V)return j(null,V,me);if(!me)return M(re.join(h,"index"),me,j);var ut=re.resolve(h,me.main);w(ut,me,function(k,W,S){if(k)return j(k);if(W)return j(null,W,S);M(re.join(h,"index"),S,j)})});return}M(re.join(h,"/index"),se,j)})})})}function T(h,O){if(O.length===0)return h(null,void 0);var L=O[0];c(re.dirname(L),j);function j(q,N){if(q)return h(q);if(!N)return T(h,O.slice(1));M(L,i.package,x)}function x(q,N,K){if(q)return h(q);if(N)return h(null,N,K);w(L,i.package,_)}function _(q,N,K){if(q)return h(q);if(N)return h(null,N,K);T(h,O.slice(1))}}function G(h,O,L){var j=function(){return yh(h,O,i)};T(L,y?y(h,O,j,i):j())}}});var oc=R((HR,vh)=>{vh.exports={assert:!0,"node:assert":[">= 14.18 && < 15",">= 16"],"assert/strict":">= 15","node:assert/strict":">= 16",async_hooks:">= 8","node:async_hooks":[">= 14.18 && < 15",">= 16"],buffer_ieee754:">= 0.5 && < 0.9.7",buffer:!0,"node:buffer":[">= 14.18 && < 15",">= 16"],child_process:!0,"node:child_process":[">= 14.18 && < 15",">= 16"],cluster:">= 0.5","node:cluster":[">= 14.18 && < 15",">= 16"],console:!0,"node:console":[">= 14.18 && < 15",">= 16"],constants:!0,"node:constants":[">= 14.18 && < 15",">= 16"],crypto:!0,"node:crypto":[">= 14.18 && < 15",">= 16"],_debug_agent:">= 1 && < 8",_debugger:"< 8",dgram:!0,"node:dgram":[">= 14.18 && < 15",">= 16"],diagnostics_channel:[">= 14.17 && < 15",">= 15.1"],"node:diagnostics_channel":[">= 14.18 && < 15",">= 16"],dns:!0,"node:dns":[">= 14.18 && < 15",">= 16"],"dns/promises":">= 15","node:dns/promises":">= 16",domain:">= 0.7.12","node:domain":[">= 14.18 && < 15",">= 16"],events:!0,"node:events":[">= 14.18 && < 15",">= 16"],freelist:"< 6",fs:!0,"node:fs":[">= 14.18 && < 15",">= 16"],"fs/promises":[">= 10 && < 10.1",">= 14"],"node:fs/promises":[">= 14.18 && < 15",">= 16"],_http_agent:">= 0.11.1","node:_http_agent":[">= 14.18 && < 15",">= 16"],_http_client:">= 0.11.1","node:_http_client":[">= 14.18 && < 15",">= 16"],_http_common:">= 0.11.1","node:_http_common":[">= 14.18 && < 15",">= 16"],_http_incoming:">= 0.11.1","node:_http_incoming":[">= 14.18 && < 15",">= 16"],_http_outgoing:">= 0.11.1","node:_http_outgoing":[">= 14.18 && < 15",">= 16"],_http_server:">= 0.11.1","node:_http_server":[">= 14.18 && < 15",">= 16"],http:!0,"node:http":[">= 14.18 && < 15",">= 16"],http2:">= 8.8","node:http2":[">= 14.18 && < 15",">= 16"],https:!0,"node:https":[">= 14.18 && < 15",">= 16"],inspector:">= 8","node:inspector":[">= 14.18 && < 15",">= 16"],"inspector/promises":[">= 19"],"node:inspector/promises":[">= 19"],_linklist:"< 8",module:!0,"node:module":[">= 14.18 && < 15",">= 16"],net:!0,"node:net":[">= 14.18 && < 15",">= 16"],"node-inspect/lib/_inspect":">= 7.6 && < 12","node-inspect/lib/internal/inspect_client":">= 7.6 && < 12","node-inspect/lib/internal/inspect_repl":">= 7.6 && < 12",os:!0,"node:os":[">= 14.18 && < 15",">= 16"],path:!0,"node:path":[">= 14.18 && < 15",">= 16"],"path/posix":">= 15.3","node:path/posix":">= 16","path/win32":">= 15.3","node:path/win32":">= 16",perf_hooks:">= 8.5","node:perf_hooks":[">= 14.18 && < 15",">= 16"],process:">= 1","node:process":[">= 14.18 && < 15",">= 16"],punycode:">= 0.5","node:punycode":[">= 14.18 && < 15",">= 16"],querystring:!0,"node:querystring":[">= 14.18 && < 15",">= 16"],readline:!0,"node:readline":[">= 14.18 && < 15",">= 16"],"readline/promises":">= 17","node:readline/promises":">= 17",repl:!0,"node:repl":[">= 14.18 && < 15",">= 16"],smalloc:">= 0.11.5 && < 3",_stream_duplex:">= 0.9.4","node:_stream_duplex":[">= 14.18 && < 15",">= 16"],_stream_transform:">= 0.9.4","node:_stream_transform":[">= 14.18 && < 15",">= 16"],_stream_wrap:">= 1.4.1","node:_stream_wrap":[">= 14.18 && < 15",">= 16"],_stream_passthrough:">= 0.9.4","node:_stream_passthrough":[">= 14.18 && < 15",">= 16"],_stream_readable:">= 0.9.4","node:_stream_readable":[">= 14.18 && < 15",">= 16"],_stream_writable:">= 0.9.4","node:_stream_writable":[">= 14.18 && < 15",">= 16"],stream:!0,"node:stream":[">= 14.18 && < 15",">= 16"],"stream/consumers":">= 16.7","node:stream/consumers":">= 16.7","stream/promises":">= 15","node:stream/promises":">= 16","stream/web":">= 16.5","node:stream/web":">= 16.5",string_decoder:!0,"node:string_decoder":[">= 14.18 && < 15",">= 16"],sys:[">= 0.4 && < 0.7",">= 0.8"],"node:sys":[">= 14.18 && < 15",">= 16"],"test/reporters":">= 19.9 && < 20.2","node:test/reporters":[">= 18.17 && < 19",">= 19.9",">= 20"],"node:test":[">= 16.17 && < 17",">= 18"],timers:!0,"node:timers":[">= 14.18 && < 15",">= 16"],"timers/promises":">= 15","node:timers/promises":">= 16",_tls_common:">= 0.11.13","node:_tls_common":[">= 14.18 && < 15",">= 16"],_tls_legacy:">= 0.11.3 && < 10",_tls_wrap:">= 0.11.3","node:_tls_wrap":[">= 14.18 && < 15",">= 16"],tls:!0,"node:tls":[">= 14.18 && < 15",">= 16"],trace_events:">= 10","node:trace_events":[">= 14.18 && < 15",">= 16"],tty:!0,"node:tty":[">= 14.18 && < 15",">= 16"],url:!0,"node:url":[">= 14.18 && < 15",">= 16"],util:!0,"node:util":[">= 14.18 && < 15",">= 16"],"util/types":">= 15.3","node:util/types":">= 16","v8/tools/arguments":">= 10 && < 12","v8/tools/codemap":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/consarray":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/csvparser":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/logreader":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/profile_view":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/splaytree":[">= 4.4 && < 5",">= 5.2 && < 12"],v8:">= 1","node:v8":[">= 14.18 && < 15",">= 16"],vm:!0,"node:vm":[">= 14.18 && < 15",">= 16"],wasi:[">= 13.4 && < 13.5",">= 18.17 && < 19",">= 20"],"node:wasi":[">= 18.17 && < 19",">= 20"],worker_threads:">= 11.7","node:worker_threads":[">= 14.18 && < 15",">= 16"],zlib:">= 0.5","node:zlib":[">= 14.18 && < 15",">= 16"]}});var lc=R((qR,ac)=>{"use strict";l();var xh=Vt(),ic=oc(),sc={};for(Mr in ic)Object.prototype.hasOwnProperty.call(ic,Mr)&&(sc[Mr]=xh(Mr));var Mr;ac.exports=sc});var uc=R((UR,cc)=>{"use strict";l();var _h=Vt();cc.exports=function(t){return _h(t)}});var dc=R((GR,pc)=>{"use strict";l();var bh=Vt(),it=B("fs"),fe=B("path"),Rh=Jo(),Sh=Zo(),wh=ri(),Ch=ni(),Eh=process.platform!=="win32"&&it.realpathSync&&typeof it.realpathSync.native=="function"?it.realpathSync.native:it.realpathSync,fc=Rh(),kh=function(){return[fe.join(fc,".node_modules"),fe.join(fc,".node_libraries")]},Ph=function(t){try{var r=it.statSync(t,{throwIfNoEntry:!1})}catch(n){if(n&&(n.code==="ENOENT"||n.code==="ENOTDIR"))return!1;throw n}return!!r&&(r.isFile()||r.isFIFO())},Ah=function(t){try{var r=it.statSync(t,{throwIfNoEntry:!1})}catch(n){if(n&&(n.code==="ENOENT"||n.code==="ENOTDIR"))return!1;throw n}return!!r&&r.isDirectory()},Oh=function(t){try{return Eh(t)}catch(r){if(r.code!=="ENOENT")throw r}return t},Ht=function(t,r,n){return n&&n.preserveSymlinks===!1?t(r):r},Th=function(t,r){var n=t(r);try{var o=JSON.parse(n);return o}catch{}},$h=function(t,r,n){for(var o=wh(r,n,t),i=0;i<o.length;i++)o[i]=fe.join(o[i],t);return o};pc.exports=function(t,r){if(typeof t!="string")throw new TypeError("Path must be a string.");var n=Ch(t,r),o=n.isFile||Ph,i=n.readFileSync||it.readFileSync,s=n.isDirectory||Ah,a=n.realpathSync||Oh,c=n.readPackageSync||Th;if(n.readFileSync&&n.readPackageSync)throw new TypeError("`readFileSync` and `readPackageSync` are mutually exclusive.");var u=n.packageIterator,f=n.extensions||[".js"],d=n.includeCoreModules!==!1,p=n.basedir||fe.dirname(Sh()),y=n.filename||p;n.paths=n.paths||kh();var v=Ht(a,fe.resolve(p),n);if(/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/.test(t)){var b=fe.resolve(v,t);(t==="."||t===".."||t.slice(-1)==="/")&&(b+="/");var $=P(b)||A(b);if($)return Ht(a,$,n)}else{if(d&&bh(t))return t;var E=M(t,v);if(E)return Ht(a,E,n)}var I=new Error("Cannot find module '"+t+"' from '"+y+"'");throw I.code="MODULE_NOT_FOUND",I;function P(C){var w=D(fe.dirname(C));if(w&&w.dir&&w.pkg&&n.pathFilter){var T=fe.relative(w.dir,C),G=n.pathFilter(w.pkg,C,T);G&&(C=fe.resolve(w.dir,G))}if(o(C))return C;for(var h=0;h<f.length;h++){var O=C+f[h];if(o(O))return O}}function D(C){if(!(C===""||C==="/")&&!(process.platform==="win32"&&/^\w:[/\\]*$/.test(C))&&!/[/\\]node_modules[/\\]*$/.test(C)){var w=fe.join(Ht(a,C,n),"package.json");if(!o(w))return D(fe.dirname(C));var T=c(i,w);return T&&n.packageFilter&&(T=n.packageFilter(T,C)),{pkg:T,dir:C}}}function A(C){var w=fe.join(Ht(a,C,n),"/package.json");if(o(w)){try{var T=c(i,w)}catch{}if(T&&n.packageFilter&&(T=n.packageFilter(T,C)),T&&T.main){if(typeof T.main!="string"){var G=new TypeError("package \u201C"+T.name+"\u201D `main` must be a string");throw G.code="INVALID_PACKAGE_MAIN",G}(T.main==="."||T.main==="./")&&(T.main="index");try{var h=P(fe.resolve(C,T.main));if(h)return h;var O=A(fe.resolve(C,T.main));if(O)return O}catch{}}}return P(fe.join(C,"/index"))}function M(C,w){for(var T=function(){return $h(C,w,n)},G=u?u(C,w,T,n):T(),h=0;h<G.length;h++){var O=G[h];if(s(fe.dirname(O))){var L=P(O);if(L)return L;var j=A(O);if(j)return j}}}}});var gc=R((zR,mc)=>{"use strict";l();var Ir=nc();Ir.core=lc();Ir.isCore=uc();Ir.sync=dc();mc.exports=Ir});l();import s_ from"node:process";import a_ from"yargs";import{hideBin as l_}from"yargs/helpers";var ft="0.19.4";l();var Re=ee(le(),1),zc=ee(Tr(),1);import{dirname as my,join as gy,resolve as Ur}from"node:path";import{readFile as hy}from"node:fs/promises";import Wt from"fs-extra";import yy from"gray-matter";import vy from"markdown-it";import{Feed as xy}from"feed";import at from"consola";l();import bl from"fs-extra";l();import{spawn as Ng}from"cross-spawn";function It(e,t="updated"){return new Promise((r,n)=>{let o=["log"];t==="updated"&&o.push("-1"),o.push('--pretty="%ci"',e),t==="created"&&o.push("|","tail","-1");let i=Ng("git",o),s="";i.stdout.on("data",a=>s+=String(a)),i.on("close",()=>{r(+new Date(s))}),i.on("error",()=>{r(0)})})}async function Rl(e){return await It(e,"created")||(await bl.stat(e)).ctime}async function Sl(e){return await It(e,"created")||(await bl.stat(e)).mtime}l();import Ko from"js-yaml";l();var wl="<!-- more -->",xt=/^https?:/i,Cl=/^pathname:\/\//,iR="/:all(.*)*",El=new Set(["annotation","math","menclose","mfrac","mglyph","mi","mlabeledtr","mn","mo","mover","mpadded","mphantom","mroot","mrow","mspace","msqrt","mstyle","msub","msubsup","msup","mtable","mtd","mtext","mtr","munder","munderover","semantics"]);var Mg={yaml:{parse:e=>Ko.load(e,{schema:Ko.CORE_SCHEMA}),stringify:e=>Ko.dump(e)}},Ue={excerpt_separator:wl,engines:Mg};l();var Bc=ee(Tr(),1),Ge=ee(le(),1);import{dirname as ly}from"node:path";import jc from"node:process";import{resolve as Ut}from"pathe";import qc from"fs-extra";import cy from"debug";import{ensureSuffix as Hc,uniq as uy}from"@antfu/utils";import Uc from"defu";import Wc from"consola";l();l();import{join as hc}from"node:path";import Nh from"is-installed-globally";l();var Nl=ee(Tl(),1);import oe from"node:process";import ie from"node:path";import Xo from"node:os";import Nr from"node:fs";var Ft=oe.platform==="win32",$l=e=>{try{return Nl.default.parse(Nr.readFileSync(e,"utf8")).prefix}catch{}},Ig=()=>Object.keys(oe.env).reduce((e,t)=>/^npm_config_prefix$/i.test(t)?oe.env[t]:e,void 0),Lg=()=>{if(Ft&&oe.env.APPDATA)return ie.join(oe.env.APPDATA,"/npm/etc/npmrc");if(oe.execPath.includes("/Cellar/node")){let e=oe.execPath.slice(0,oe.execPath.indexOf("/Cellar/node"));return ie.join(e,"/lib/node_modules/npm/npmrc")}if(oe.execPath.endsWith("/bin/node")){let e=ie.dirname(ie.dirname(oe.execPath));return ie.join(e,"/etc/npmrc")}},Fg=()=>{if(Ft){let{APPDATA:e}=oe.env;return e?ie.join(e,"npm"):ie.dirname(oe.execPath)}return ie.dirname(ie.dirname(oe.execPath))},Dg=()=>{let e=Ig();if(e)return e;let t=$l(ie.join(Xo.homedir(),".npmrc"));if(t)return t;if(oe.env.PREFIX)return oe.env.PREFIX;let r=$l(Lg());return r||Fg()},Lt=ie.resolve(Dg()),Ml=()=>{if(Ft&&oe.env.LOCALAPPDATA){let e=ie.join(oe.env.LOCALAPPDATA,"Yarn");if(Nr.existsSync(e))return e}return!1},Vg=()=>{if(oe.env.PREFIX)return oe.env.PREFIX;let e=Ml();if(e)return e;let t=ie.join(Xo.homedir(),".config/yarn");if(Nr.existsSync(t))return t;let r=ie.join(Xo.homedir(),".yarn-config");return Nr.existsSync(r)?r:Lt},Ae={};Ae.npm={};Ae.npm.prefix=Lt;Ae.npm.packages=ie.join(Lt,Ft?"node_modules":"lib/node_modules");Ae.npm.binaries=Ft?Lt:ie.join(Lt,"bin");var Il=ie.resolve(Vg());Ae.yarn={};Ae.yarn.prefix=Il;Ae.yarn.packages=ie.join(Il,Ml()?"Data/global/node_modules":"global/node_modules");Ae.yarn.binaries=ie.join(Ae.yarn.packages,".bin");var Qo=Ae;var vc=ee(gc(),1);import yc from"consola";function Oe(e,t=!1,r={preserveSymlinks:!1}){try{return(0,vc.sync)(e,r)}catch(n){yc.log(n)}if(Nh){try{return B.resolve(hc(Qo.yarn.packages,e))}catch{}try{return B.resolve(hc(Qo.npm.packages,e))}catch{}}if(t)throw new Error(`Failed to resolve package ${e}`);yc.error(`Failed to resolve package ${e}`)}l();function xc(e){return xt.test(e)}function Mh(e){return e.replace(/\\/g,"/")}function oi(e,t){return t.startsWith(e)?t:e+t}function X(e){return`/@fs${oi("/",Mh(e))}`}function _c(e){return e.startsWith("/")||/^\.\.?[\/\\]/.test(e)}function bc(e){return`JSON.parse(${JSON.stringify(JSON.stringify(e))})`}l();l();import Ih from"node:process";import{fileURLToPath as Lh}from"node:url";import Fh from"fs-extra";import Dh from"jiti";import{resolve as Vh}from"pathe";import Rc from"consola";async function jh(e){let{name:t,cwd:r}=e,n=Vh(r,`${t}.config.ts`),o={};if(await Fh.exists(n))try{o=Dh(Lh(import.meta.url),{interopDefault:!0,requireCache:!1,esmResolve:!0})(n)}catch{Rc.error(`Failed to load config file: ${n}`)}else Rc.debug(`Config file not found: ${n}`);return{config:o,configFile:n}}async function _t(e,t={}){let{config:r,configFile:n}=await jh({name:e,cwd:t.cwd||Ih.cwd()}),o=r;return typeof r=="function"&&(o=await r(t.valaxyOptions||{})),{config:o,configFile:n}}l();var Rt=ee(le(),1);import Bh from"node:process";import{createDefu as Uh}from"defu";import{mergeConfig as Wh}from"vite";import{isFunction as wc}from"@antfu/utils";import Gh from"consola";l();function We(){let e=performance.now();return()=>{let r=performance.now()-e;return r>1e3?`${(r/1e3).toFixed(2)}s`:`${r.toFixed(2)}ms`}}l();var bt=ee(le(),1);import{webcrypto as Sc}from"node:crypto";import Hh from"consola";var Lr={mode:"auto",url:"/",lang:"en",languages:["en","zh-CN"],title:"Valaxy Blog",description:"A blog generated by Valaxy.",subtitle:"Next Generation Static Blog Framework.",author:{avatar:"https://valaxy.site/valaxy-logo.png",email:"i@valaxy.site",link:"https://valaxy.site",name:"VALAXY Developer",status:{emoji:"\u{1F30C}",message:"The moonlight is beautiful."}},favicon:"/favicon.svg",feed:{name:"",favicon:"/favicon.svg"},social:[],lastUpdated:!0,license:{enabled:!0,language:"",type:"by-nc-sa"},sponsor:{enable:!0,description:"\u8FD9\u662F\u5173\u4E8E\u8D5E\u52A9\u7684\u4E00\u4E9B\u63CF\u8FF0",methods:[]},search:{enable:!1,type:"fuse"},fuse:{dataPath:"valaxy-fuse-list.json",options:{keys:[]}},comment:{enable:!1},frontmatter:{time_warning:180*24*60*60*1e3},cdn:{prefix:"https://unpkg.com/"},mediumZoom:{enable:!1,selector:"",options:{}},vanillaLazyload:{enable:!1,options:{}},statistics:{enable:!1,readTime:{speed:{cn:300,en:100}}},pageSize:7,encrypt:{enable:!1,algorithm:"AES-CBC",salt:Sc.getRandomValues(new Uint8Array(16)),iv:Sc.getRandomValues(new Uint8Array(16))},redirects:{useVueRouter:!0,rules:[]}};function CS(e){return e}async function qh(e){return _t("site",{cwd:e})}async function Fr(e){let t=We(),{config:r,configFile:n}=await qh(e),o=t();return r&&n&&Hh.success(`Resolve ${(0,bt.cyan)("siteConfig")} from ${(0,bt.dim)(n)} ${(0,bt.yellow)(o)}`),{siteConfig:r,siteConfigFile:n}}var Cc={siteConfig:Lr,theme:"yun",themeConfig:{pkg:{name:"",version:""}},build:{ssgForPagination:!1},runtimeConfig:{addons:{},redirects:{useVueRouter:!0,redirectRoutes:[]}},modules:{rss:{enable:!0}},features:{katex:!0},vite:{build:{rollupOptions:{external:[]}}},devtools:!0};function Kh(e){return e}var LS=Kh;async function qt(e,t){return await _t("valaxy",{cwd:e,valaxyOptions:t})}var st=Uh((e,t,r)=>{if(wc(e[t])&&wc(r)&&(e[t]=function(...n){e[t].call(this,...n),r.call(this,...n)}),t==="vite")return e[t]=Wh(e[t],r),!0});async function Ec(e){let t=e.userRoot||Bh.cwd(),r=We(),{config:n,configFile:o}=await qt(t),i=r();o&&n&&Object.keys(n).length!==0&&Gh.success(`Resolve ${(0,Rt.cyan)("userValaxyConfig")} from ${(0,Rt.dim)(o)} ${(0,Rt.yellow)(i)}`);let s=e.theme||n?.theme||"yun";return{config:n,configFile:o,theme:s}}l();import zh from"node:path";import Yh from"fs-extra";function Xh(e){return e}var qS=Xh;async function kc(e,t){let r={};for(let n of e){if(!Yh.existsSync(zh.resolve(n.root,"valaxy.config.ts")))continue;let{config:o,configFile:i}=await qt(n.root,t);o&&(n.configFile=i,r=st(o,r))}return r}l();var jr=ee(le(),1);import ey from"defu";l();var Ac=ee(le(),1);import Zh from"consola";l();import Pc from"node:process";import Qh from"node:fs";import Jh from"node:path";function Bt(){return Pc.env.NODE_ENV==="production"}function ii(e="development"){Pc.env.NODE_ENV=e,Te.level=Bt()?2:3}function St(){return ii("production")}function Dr(e){let t=Qh.existsSync(Jh.resolve(e,"pages"));return t||Te.error(`No pages directory found in ${e}`),t}var Te=Zh.create({level:Bt()?2:3}),si=`${(0,Ac.magenta)("valaxy")}:`,wt={success:e=>Te.success(si,e),info:e=>Te.info(si,e),ready:e=>Te.ready(si,e)};async function Vr(e){return _t("theme",{cwd:e})}async function Oc(e){let{config:t,configFile:r}=await Vr(e.userRoot);if(t&&r&&Te.info(`Resolve ${(0,jr.cyan)("themeConfig")} from ${(0,jr.dim)(r)}`),e?.themeRoot){let{config:n}=await Vr(e.themeRoot);t=ey(t||{},n)}return{themeConfig:t,themeConfigFile:r}}function ty(e){return e}var ow=ty;function aw(e){return e}l();var $e=ee(le(),1);import Lc from"node:process";import{resolve as ny}from"pathe";import Nc from"fs-extra";import Mc from"defu";import oy from"ora";l();import{dirname as Tc}from"node:path";import{resolve as $c}from"pathe";import ry from"fs-extra";function Hr(e,t){if(!e)return"";if(_c(e))if(t){let r=ry.lstatSync(t).isFile();return $c(r?Tc(t):t,e)}else throw new Error(`entry is required when ${e} is path`);else return $c(Tc(Oe(`${e}/package.json`)||""))}async function Fc(e,t=Lc.cwd()){let r=oy(`Resolve ${(0,$e.cyan)("addons")} from ${(0,$e.dim)(t)}`).start(),n={},o=s=>{s&&(n[s.name]=Mc(n[s.name]||{},s))};if(Array.isArray(e))for(let s of e){if(typeof s=="string"){o(await Ic(s,{cwd:t}));continue}typeof s=="object"&&o(Mc(await Ic(s.name,{cwd:t}),s||{}))}r.succeed();let i=Object.values(n).filter(s=>s.enable);return i.forEach((s,a)=>{console.log(` ${a===i.length-1?"\u2514\u2500":"\u251C\u2500"} ${(0,$e.yellow)(s.name)} ${(0,$e.blue)(`v${s.pkg?.version}`)}${s.global?(0,$e.cyan)(" (global)"):""} ${(0,$e.dim)(s.pkg.homepage||s.pkg.repository?.url||s.pkg.repository||"")}`)}),i}async function Ic(e,t={}){let r=iy(e,t.cwd||Lc.cwd()),n=ny(r,"./package.json");if(!Nc.existsSync(n)){Te.error(`No addon named ${e} found`);return}let o=await Nc.readJSON(n);return{enable:!0,name:o.name,global:!!o.global,root:r,options:{},props:{},pkg:o}}function iy(e,t){let r=e.startsWith("valaxy-addon")||e.startsWith(".")?e:`valaxy-addon-${e}`;return Hr(r,t)}l();function Dc(e,t){let r=e.startsWith("valaxy-theme")||e.startsWith(".")?e:`valaxy-theme-${e}`;return Hr(r,t)}l();import{writeFile as sy}from"node:fs/promises";import{ensureFile as ay}from"fs-extra";function qr(e){return e==="/"?"/index":e.endsWith("/")?e.slice(0,-1):e}function Br(e){if(!e)return[];let t=[];for(let r of e)if(Array.isArray(r.from))for(let n of r.from)t.push({from:qr(n),to:qr(r.to)});else t.push({from:qr(r.from),to:qr(r.to)});return t}async function Vc(e,t){await ay(t),await sy(t,`
|
|
6
|
+
<!DOCTYPE html>
|
|
7
|
+
<html lang="en">
|
|
8
|
+
<head>
|
|
9
|
+
<meta charset="UTF-8">
|
|
10
|
+
<meta http-equiv="refresh" content="0; url=${e}">
|
|
11
|
+
<link rel="canonical" href="${e}">
|
|
12
|
+
</head>
|
|
13
|
+
<script>
|
|
14
|
+
window.location.href = '${e}' + window.location.search + window.location.hash
|
|
15
|
+
</script>
|
|
16
|
+
</html>
|
|
17
|
+
`)}var fy=cy("valaxy:options");async function py(e){let{config:t,themeRoot:r,theme:n}=e,o=t.siteConfig;o.url=Hc("/",o.url||""),o.cdn.prefix=Hc("/",o.cdn.prefix||"");let i=Ut(r,"package.json");try{t.themeConfig.pkg=await qc.readJson(i,"utf-8")}catch{console.error(`valaxy-theme-${n} doesn't have package.json`)}}async function ai(e,t){let{clientRoot:r,themeRoot:n,userRoot:o}=e,i=await Fc(t.addons||[],e.userRoot),s=await kc(i,e);t=st(t,s);let a=Uc(t,Cc);e.config={...a,runtimeConfig:{addons:{},redirects:{useVueRouter:!0,redirectRoutes:[]}}},e.addons=i,i.forEach(d=>{e.config.runtimeConfig.addons[d.name]=d});let c=i.map(({root:d})=>d),u=i.map(({name:d})=>d);e.addonRoots=c,e.roots=uy([r,n,...c,o]);let f=e.config.vite?.build?.rollupOptions?.external||[];return e.config.vite.build.rollupOptions.external=f.filter(d=>!u.includes(d)),await py(e),e}async function be(e={userRoot:jc.cwd()},t="dev"){let r=ly(Oe("valaxy/package.json",!0)),n=Ut(r,"client"),o=Ut(e.userRoot||jc.cwd());Wc.start(`Resolve ${(0,Ge.magenta)("valaxy")} config...`);let[i,s,a,c]=await Promise.all([Ec(e),Fr(e.userRoot),Vr(e.userRoot),(0,Bc.default)(["**.md"],{cwd:Ut(o,"pages"),ignore:["**/node_modules"]})]),{config:u,configFile:f,theme:d}=i,p=Dc(d,e.userRoot),{siteConfig:y,siteConfigFile:v}=s,{config:b,configFile:$}=a,E=Br(y.redirects?.rules);u=Uc({siteConfig:y},{themeConfig:b},u);let I={mode:t,pkgRoot:r,tempDir:Ut(o,".valaxy"),clientRoot:n,userRoot:o,themeRoot:p,addonRoots:[],roots:[],theme:d,config:{...u,runtimeConfig:{addons:{},redirects:{useVueRouter:!0,redirectRoutes:[]}}},configFile:f||"",siteConfigFile:v||"",themeConfigFile:$||"",pages:c.sort(),addons:[],redirects:E,env:{id:"",links:[]}};fy(I);let P=await li(I),D=st(u,P);return I=await ai(I,D),qc.ensureDirSync(I.tempDir),I}async function li(e){let t=We(),{config:r}=await qt(e.themeRoot,e),n=t();return r&&Wc.success(`Resolve ${(0,Ge.cyan)("valaxy.config.ts")} from ${(0,Ge.blue)(`theme(${e.theme})`)} ${(0,Ge.yellow)(n)}`),r}l();function Ke(e){return e.positional("root",{default:".",type:"string",describe:"root folder of your source files"})}l();function Gc(e,t){t.forEach(r=>{r.setup?.(e)})}var _y=vy({html:!0,breaks:!0,linkify:!0});async function Kc(e){at.info(`${(0,Re.yellow)("RSS Generating ...")}`);let{config:t}=e,r=t.siteConfig;if(!r.url||r.url==="/"){at.error("You must set `url` (like `https://example.com`) in `site.config.ts` to generate rss.");return}let n=r.url,o=r.url.slice(0,-1),i={name:r.author?.name,email:r.author?.email,link:r.author?.link};at.info(`RSS Site Url: ${(0,Re.cyan)(n)}`);let s=r.license?.type==="zero"?"1.0":"4.0",a={atom:r.feed?.name?`${r.feed?.name}.atom`:"atom.xml",json:`${r.feed?.name||"feed"}.json`,rss:`${r.feed?.name||"feed"}.xml`},c={title:r.title||"Valaxy Blog",description:r.description,id:n||"valaxy",link:n,copyright:`CC ${r.license?.type?.toUpperCase()} ${s} ${new Date().getFullYear()} \xA9 ${r.author?.name}`,feedLinks:{}};Object.keys(a).forEach(E=>{c.feedLinks[E]=`${n}${a[E]}`});let u=await(0,zc.default)(`${e.userRoot}/pages/posts/**/*.md`),f=e.config.siteConfig.lang||"en",d=[];for await(let E of u){let I=await hy(E,"utf-8"),{data:P,content:D,excerpt:A}=yy(I,Ue);if(P.password)continue;if(P.draft){at.warn(`Ignore draft post: ${(0,Re.dim)(E)}`);continue}if(P.hide)continue;let M=E;P.date||(P.date=await Rl(M)),r.lastUpdated&&(P.updated||(P.updated=await Sl(M)));let C=_y.render(A||D.slice(0,100)).replace('src="/',`src="${o}/`);P.image?.startsWith("/")&&(P.image=o+P.image);let w=(P.id||"").toString(),T=`<br/><p>${f==="zh-CN"?`\u8BBF\u95EE <a href="${w}" target="_blank">${w}</a> \u9605\u8BFB\u5168\u6587\u3002`:`Visit <a href="${w}" target="_blank">${w}</a> to read more.`}</p>`;d.push({title:"",...P,id:w,date:new Date(P.date),published:new Date(P.updated||P.date),content:C+T,author:[i],link:o+E.replace(`${e.userRoot}/pages`,"").replace(/\.md$/,"")})}d.sort((E,I)=>+new Date(I.published||I.date)-+new Date(E.published||E.date));let p=r.author?.avatar||"/favicon.svg";c.author=i,c.image=xc(p)?r.author?.avatar:`${o}${oi("/",p)}`,c.favicon=`${o}${r.feed?.favicon||r.favicon}`;let y=new xy(c);d.forEach(E=>y.addItem(E)),await Wt.ensureDir(my(`./dist/${a.atom}`));let v=Ur(e.userRoot,"./dist"),b=Ur(e.userRoot,"public");["rss","atom","json"].forEach(async E=>{let I="",P=`${v}/${a[E]}`;E==="rss"?I=y.rss2():E==="atom"?I=y.atom1():E==="json"&&(I=y.json1()),Wt.writeFileSync(P,I,"utf-8"),at.success(`[${(0,Re.cyan)(E)}] dist: ${(0,Re.dim)(P)}`);let D=Ur(b,a[E]),A=gy("public",a[E]);Wt.writeFileSync(D,I,"utf-8"),at.success(`[${(0,Re.cyan)(E)}] public: ${(0,Re.dim)(P)}`);try{let M=Ur(e.userRoot,".gitignore"),C=await Wt.readFile(M,"utf-8"),w=A.replace(/\\/g,"/");C.includes(w)||(await Wt.appendFile(M,`
|
|
18
|
+
# valaxy rss
|
|
19
|
+
${w}
|
|
20
|
+
`),at.success(`Add ${(0,Re.dim)(w)} to ${(0,Re.dim)(".gitignore")}`))}catch{}})}var Wr={extendCli(e){e.command("rss [root]","generate rss feed",t=>Ke(t).strict().help(),async({root:t})=>{St();let r=await be({userRoot:t},"build");await Kc(r)})},setup(e){e.hook("build:after",()=>{console.log(),Kc(e.options)})}};l();var Yc=ee(Tr(),1),Ye=ee(le(),1);import Ct from"node:path";import ze from"fs-extra";import Et from"consola";import by from"gray-matter";async function Ry(e){Et.start(`Generate List for Fuse Search by (${(0,Ye.cyan)("fuse.js")}) ...`);let t=await(0,Yc.default)(`${e.userRoot}/pages/posts/**/*.md`),r=[];for await(let n of t){let o=ze.readFileSync(n,"utf-8"),{data:i,excerpt:s,content:a}=by(o,Ue);if(i.draft){Et.warn(`Ignore draft post: ${(0,Ye.dim)(n)}`);continue}if(i.hide||i.password)continue;let c=e.config.siteConfig.fuse.options.keys||[],u=n.replace(`${e.userRoot}/pages`,""),f=n.endsWith("index.md")?u.replace(/\/index\.md$/,""):u.replace(/\.md$/,""),d={title:i.title||"",tags:(typeof i.tags=="string"?[i.tags]:i.tags)||[],categories:i.categories||[],author:e.config.siteConfig.author.name,excerpt:s||a.slice(0,100),link:encodeURI(f)};c.includes("content")&&(d.content=a||""),r.push(d)}return r}async function Xc(e){Et.info("Start generate fuse list...");let t=await Ry(e);await ze.ensureDir("./dist");let r=Ct.resolve(e.userRoot,"public"),n=Ct.resolve(r,e.config.siteConfig.fuse.dataPath),o=Ct.join("public",e.config.siteConfig.fuse.dataPath);await ze.ensureFile(n),ze.writeJSONSync(n,t),Et.success(`Generate fuse list in ${(0,Ye.dim)(r)}`);let i=Ct.resolve(e.userRoot,"dist"),s=Ct.resolve(i,e.config.siteConfig.fuse.dataPath);await ze.ensureDir(i),ze.writeJSONSync(s,t),Et.success(`Generate fuse list in ${(0,Ye.dim)(i)}`);try{let a=Ct.resolve(e.userRoot,".gitignore"),c=await ze.readFile(a,"utf-8"),u=o.replace(/\\/g,"/");c.includes(u)||(await ze.appendFile(a,`
|
|
21
|
+
# valaxy fuse
|
|
22
|
+
${u}
|
|
23
|
+
`),Et.success(`Add ${(0,Ye.dim)(u)} to ${(0,Ye.dim)(".gitignore")}`))}catch{}}function Sy(e){e.command("fuse [root]","generate fuse list for search",t=>Ke(t).strict().help(),async({root:t})=>{St();let r=await be({userRoot:t},"build");await Xc(r)})}var Gr={extendCli(e){Sy(e)},setup(e){e.hook("build:before",async()=>{await Xc(e.options)})}};l();l();var zr=ee(le(),1);import{join as Py,resolve as Zc}from"node:path";import{writeFile as Ay}from"node:fs/promises";import{render as Oy}from"ejs";import{ensureSuffix as Ty}from"@antfu/utils";import{consola as ci}from"consola";import{format as $y}from"date-fns";l();import{access as wy}from"node:fs/promises";async function Kr(e){try{return await wy(e),!0}catch{return!1}}l();import Ey from"node:path";import{readFile as ky}from"node:fs/promises";l();import Cy from"node:process";var Gt=Cy.cwd(),Qc=`---
|
|
24
|
+
layout: <%=layout%>
|
|
25
|
+
title: <%=title%>
|
|
26
|
+
date: <%=date%>
|
|
27
|
+
---
|
|
28
|
+
`;async function Jc(e){let{clientRoot:t,themeRoot:r}=await be({userRoot:Gt}),n=[Gt,r,t];for(let o of n){let i=Ey.resolve(o,"scaffolds",`${e}.md`);if(await Kr(i))return ky(i,"utf-8")}return!1}async function eu(e){let t=Zc(Gt,"pages"),{path:r,title:n}=e,o=r||Py("posts",n),i=0;for(;;){let s=Zc(t,o);if(i&&(s=`${s}-${i}`),s=Ty(".md",s),!await Kr(s)){let a=await Ny(e);try{await Ay(s,a,"utf-8"),ci.success(`[valaxy new]: successfully generated file ${(0,zr.magenta)(s)}`)}catch(c){console.log(c),ci.error(`[valaxy new]: failed to write file ${s}`),ci.warn(`You should run ${(0,zr.green)("valaxy new")} in your valaxy project root directory.`)}return s}i++}}async function Ny({date:e,title:t,layout:r="post"}){let n=await Jc(r);return n||(n=Qc),Oy(n,{title:t,layout:r,date:e?$y(new Date,"yyyy-MM-dd HH:mm:ss"):""})}function tu(e){e.command("new <title>","Draft a new post",t=>{t.usage("$0 <title> -p [path] -l [layout]").positional("title",{describe:"The title of the new post",required:!0}).option("path",{alias:"p",type:"string",describe:"the path to generate new post. Customize the path of post to generate"}).option("layout",{alias:"l",type:"string",default:"post"}).option("date",{alias:"d",type:"boolean",default:!0,describe:"Generate post with the current date"}).strict().help()},async({title:t,path:r,date:n,layout:o})=>{await eu({title:t,date:n,layout:o,path:r})})}l();var At=ee(le(),1);import Ti from"node:path";import Qx from"node:process";import Ze from"consola";import{mergeConfig as bf}from"vite";l();var df=ee(le(),1);import{join as uf,resolve as ff}from"node:path";import{mergeConfig as pf,build as Vx}from"vite";import{build as jx}from"vite-ssg/node";import Hx from"vite-ssg-sitemap";import tn from"fs-extra";import rn from"consola";l();import Nx from"@vitejs/plugin-vue";import Mx from"vite-plugin-vue-layouts";import Ix from"unplugin-vue-components/vite";import Lx from"@intlify/unplugin-vue-i18n/vite";import Fx from"@unhead/addons/vite";import{resolve as Dx}from"pathe";l();import{resolve as Vy}from"node:path";import{existsSync as jy}from"node:fs";import{fileURLToPath as Hy}from"node:url";import qy from"jiti";import ou from"defu";import{presetAttributify as By,presetIcons as Uy,presetTypography as Wy,presetUno as Gy,transformerDirectives as Ky,transformerVariantGroup as zy}from"unocss";l();import{resolve as My}from"node:path";import{fileURLToPath as Iy}from"node:url";import Ly from"fs-extra";import{isObject as Fy}from"@antfu/utils";import Dy from"jiti";function ru(e,t,r=""){return e={...e},Object.keys(t).forEach(n=>{Fy(e[n])?e[n]=ru(e[n],t[n],r?`${r}.${n}`:n):Array.isArray(e[n])?e[n]=[...e[n],...t[n]]:e[n]=t[n]}),e}async function nu(e,t,r,n,o=!0){let i=n;for(let s of e){let a=My(s,"setup",t);if(Ly.existsSync(a)){let{default:c}=Dy(Iy(import.meta.url),{esmResolve:!0})(a),u=await c(r);u!==null&&(i=o?ru(i,u):u)}}return i}async function Yy(e){let{config:t}=e,n=["animate-fade-in","m-auto","text-left","rotate-y-180",...["i-ri-clipboard-line","i-ri-archive-line","i-ri-folder-2-line","i-ri-price-tag-3-line","i-ri-cloud-line"],...e.config.unocss?.safelist??[]],o=t.siteConfig;if(t.markdown?.blocks){let s=t.markdown.blocks;Object.entries(s).forEach(([a,c])=>{c.icon&&n.push(c.icon)})}o.social?.length&&o.social.forEach(s=>n.push(s?.icon||""));let i=o.sponsor?.methods||[];return i.length&&i.forEach(s=>n.push(s?.icon||"")),n}async function Xy(e){let{config:t}=e;return{shortcuts:[["flex-center","flex items-center justify-center"],["inline-flex-center","inline-flex items-center justify-center"],["btn","px-4 py-1 rounded inline-block bg-$va-c-primary text-white cursor-pointer transition hover:bg-$va-c-primary-light disabled:cursor-default disabled:bg-gray-600 disabled:opacity-50"],["icon-btn","inline-flex justify-center items-center cursor-pointer select-none opacity-75 transition duration-200 ease-in-out hover:opacity-100 hover:text-sky-600"],["va-card","shadow hover:shadow-lg bg-$va-c-bg-light"]],presets:[Gy(t.unocssPresets?.uno),By(t.unocssPresets?.attributify),Uy({scale:1.2,...t.unocssPresets?.icons}),Wy(t.unocssPresets?.typography)],rules:[["font-serif",{"font-family":"var(--va-font-serif)"}],["font-sans",{"font-family":"var(--va-font-sans)"}],["font-mono",{"font-family":"var(--va-font-mono)"}]],transformers:[Ky(),zy()],safelist:await Yy(e)}}async function iu(e){let t=await import("unocss/vite").then(p=>p.default),{unocss:r}=e.config,n=await Xy(e),{themeRoot:o,clientRoot:i,roots:s}=e,a=["uno.config.ts","unocss.config.ts"],c=[];[o,i].forEach(p=>a.forEach(y=>c.push(Vy(p,y))));let f={},d=[];return c.forEach(p=>{if(jy(p)){let y=qy(Hy(import.meta.url),{esmResolve:!0})(p);"default"in y&&(y=y.default),f=ou(f,y),d.push(p)}}),f=await nu(s,"unocss.ts",{},f,!0),t({configDeps:d,configFile:!1,...ou(r||{},f,n)})}l();import{dirname as ev,join as pi,resolve as Fe}from"node:path";import{mergeConfig as tv,searchForWorkspaceRoot as di}from"vite";import rv from"is-installed-globally";import{uniq as au}from"@antfu/utils";l();import{join as ui}from"node:path";import fi from"fs-extra";import{uniq as Qy}from"@antfu/utils";import{loadConfigFromFile as Jy,mergeConfig as Zy}from"vite";async function Yr({userRoot:e,themeRoot:t},r){let n={mode:"development",command:r},o={},i=Qy([t,e]).map(s=>ui(s,"vite.config.ts"));for await(let s of i){if(!fi.existsSync(s))continue;let a=await Jy(n,s);a?.config&&(o=Zy(o,a.config))}return o}async function su({clientRoot:e,themeRoot:t,userRoot:r,config:n},o){let i=o,s="",a="";n.siteConfig.favicon&&(s+=`<link rel="icon" href="${n.siteConfig.favicon}">`);let c=[r,t];n.siteConfig.mode==="auto"&&(s+=`
|
|
29
|
+
<script>
|
|
30
|
+
;(function () {
|
|
31
|
+
const prefersDark =
|
|
32
|
+
window.matchMedia &&
|
|
33
|
+
window.matchMedia('(prefers-color-scheme: dark)').matches
|
|
34
|
+
const setting = localStorage.getItem('vueuse-color-scheme') || 'auto'
|
|
35
|
+
if (setting === 'dark' || (prefersDark && setting !== 'light'))
|
|
36
|
+
document.documentElement.classList.toggle('dark', true)
|
|
37
|
+
})()
|
|
38
|
+
</script>
|
|
39
|
+
`,s+=`<style type="text/css">
|
|
40
|
+
:root { --va-c-bg: #fff; }
|
|
41
|
+
html.dark { --va-c-bg: #1b1b1f; }
|
|
42
|
+
html { background-color: var(--va-c-bg); }
|
|
43
|
+
</style>`),n.siteConfig.lang&&(s+=`
|
|
44
|
+
<script>
|
|
45
|
+
const locale = localStorage.getItem('valaxy-locale') || '${n.siteConfig.lang}';
|
|
46
|
+
document.documentElement.setAttribute('lang', locale);
|
|
47
|
+
</script>
|
|
48
|
+
`);for(let u of c){let f=ui(u,"index.html");if(!fi.existsSync(f))continue;let d=await fi.readFile(f,"utf-8");s+=`
|
|
49
|
+
${(d.match(/<head>([\s\S]*?)<\/head>/im)?.[1]||"").trim()}`,a+=`
|
|
50
|
+
${(d.match(/<body>([\s\S]*?)<\/body>/im)?.[1]||"").trim()}`}return i=i.replace("__ENTRY__",X(ui(e,"main.ts"))).replace("<!-- head -->",s).replace("<!-- body -->",a),i}var nv=["@unhead/schema-org","@unhead/vue","@vueuse/integrations/useFuse","defu","katex","nprogress","unocss","vue","vue-router","vue-i18n","fuse.js","medium-zoom","vanilla-lazyload","@vue/devtools-api"],lu=["@docsearch/css","@vueuse/core","@vueuse/shared","@unocss/reset","unocss","vue","vue-router","vue-demi","@vue/devtools-api","meting","valaxy","/@valaxyjs/config","/@valaxyjs/context","/@valaxyjs/addons","/@valaxyjs/locales","/@valaxyjs/styles"];function cu(e){let t=Object.keys(e.config.themeConfig.pkg.dependencies||{}),r=e.addons.map(n=>Object.keys(n.pkg.dependencies||{})).flat();return{name:"valaxy:site",enforce:"pre",config(n){let o={root:e.clientRoot,cacheDir:pi(e.userRoot,"node_modules/.vite"),publicDir:pi(e.userRoot,"public"),define:mi(e),resolve:{alias:ov(e),dedupe:["vue"]},optimizeDeps:{entries:[Fe(e.clientRoot,"main.ts")],include:au([...nv,...t,...r]).filter(i=>!lu.includes(i)),exclude:lu},server:{fs:{allow:au([di(e.clientRoot),di(e.themeRoot),di(e.userRoot),ev(Oe("katex/package.json",!0))])}}};return rv&&(o.cacheDir=pi(e.pkgRoot,"node_modules/.vite"),o.resolve.alias.vue=`${Oe("vue/dist/vue.esm-browser.js",!0)}`),tv(n,o)},async transformIndexHtml(n){return n=await su(e,n),{html:n,tags:[]}}}}function mi(e){return{__VUE_PROD_DEVTOOLS__:!1,__INTLIFY_PROD_DEVTOOLS__:!1}}function ov(e){let t=[{find:"~/",replacement:`${X(e.userRoot)}/`},{find:"valaxy/client/",replacement:`${X(e.clientRoot)}/`},{find:"valaxy/package.json",replacement:X(Fe(e.clientRoot,"../package.json"))},{find:/^valaxy$/,replacement:X(Fe(e.clientRoot,"index.ts"))},{find:"@valaxyjs/client/",replacement:`${X(e.clientRoot)}/`},{find:"virtual:valaxy-theme",replacement:`${X(e.themeRoot)}/client/index.ts`},{find:`valaxy-theme-${e.theme}/`,replacement:`${X(Fe(e.themeRoot))}/`},{find:`valaxy-theme-${e.theme}`,replacement:`${X(Fe(e.themeRoot))}/client/index.ts`}];return e.config.siteConfig.encrypt.enable&&t.push({find:/^vue$/,replacement:Oe("vue/dist/vue.esm-bundler.js",!0)}),e.addons.forEach(r=>{t.push({find:`${r.name}/client/`,replacement:`${X(`${Fe(r.root)}`)}/client/`}),t.push({find:`${r.name}/App.vue`,replacement:`${X(Fe(r.root))}/App.vue`}),t.push({find:r.name,replacement:`${X(Fe(r.root))}/client/index.ts`})}),t.push({find:/^valaxy-addon-(.*)$/,replacement:X(Fe(e.clientRoot,"./addons/index.ts"))}),t}l();import{existsSync as iv}from"node:fs";import{join as sv,resolve as av}from"node:path";import{slash as lv,uniq as cv}from"@antfu/utils";function uu({clientRoot:e,themeRoot:t,userRoot:r}){let n=lv(av(e,"setup"));return{name:"valaxy:setup",enforce:"pre",async transform(o,i){if(i.startsWith(n)){let s=i.slice(n.length+1).replace(/\?.*$/,""),a=[],c=[];return cv([t,r]).map(f=>sv(f,"setup",s)).forEach((f,d)=>{if(!iv(f))return;a.push(`import __n${d} from '${X(f)}'`);let p=`__n${d}`;/\binjection_return\b/g.test(o)&&(p=`injection_return = ${p}`),/\binjection_arg\b/g.test(o)?p+="(injection_arg)":p+="()",c.push(`// ${f}`,p)}),o=o.replace("/* __imports__ */",a.join(`
|
|
51
|
+
`)),o=o.replace("/* __injections__ */",c.join(`
|
|
52
|
+
`)),o}return null}}}l();import{objectEntries as uv}from"@antfu/utils";function fu(e){let t=uv(mi(e));return[{name:"valaxy:flags",enforce:"pre",transform(r,n){if(n.match(/\.vue($|\?)/)){let o=r;if(t.forEach(([i,s])=>{r=r.replace(new RegExp(i,"g"),s)}),o!==r)return r}}}]}l();import ox from"unplugin-vue-router/vite";import Pi from"fs-extra";import{resolve as ix}from"pathe";import{isDate as Yu}from"@antfu/utils";import{convert as sx}from"html-to-text";import ax from"markdown-it";import lx from"gray-matter";l();import{existsSync as fv,readFileSync as pv}from"node:fs";function dv(e){let t=(e.match(/[\u4E00-\u9FA5]/g)||[]).length,r=(e.replace(/[\u4E00-\u9FA5]/g,"").match(/[a-zA-Z0-9_\u0392-\u03C9\u0400-\u04FF]+|[\u4E00-\u9FFF\u3400-\u4DBF\uF900-\uFAFF\u3040-\u309F\uAC00-\uD7AF\u0400-\u04FF]+|[\u00E4\u00C4\u00E5\u00C5\u00F6\u00D6]+|\w+/g)||[]).length;return{cn:t,en:r}}function mv({cn:e,en:t},r){let n=e/(r.speed.cn||300)+t/(r.speed.en||100);return n<1?1:Math.ceil(n)}function gv({cn:e,en:t}){let r=e+t;return r<1e3?r.toString():`${Math.round(r/100)/10}k`}function hv(e,t){let r=dv(e);return{countData:r,wordCount:gv(r),readingTime:mv(r,t.readTime)}}function pu({route:e,options:t}){let r=e.components.get("default")||"";if(fv(r)){let n=pv(r,"utf-8"),{wordCount:o,readingTime:i}=hv(n,{readTime:Object.assign({speed:{cn:300,en:100}},t.readTime)});e.meta.frontmatter&&(e.meta.frontmatter.wordCount||(e.meta.frontmatter.wordCount=o),e.meta.frontmatter.readingTime||(e.meta.frontmatter.readingTime=i))}}l();import DP from"markdown-it";l();l();import mu from"crypto";l();var du="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";var yv=128,Xe,Qe,gu=e=>{!Xe||Xe.length<e?(Xe=Buffer.allocUnsafe(e*yv),mu.randomFillSync(Xe),Qe=0):Qe+e>Xe.length&&(mu.randomFillSync(Xe),Qe=0),Qe+=e},vv=e=>(gu(e-=0),Xe.subarray(Qe-e,Qe)),xv=(e,t,r)=>{let n=(2<<31-Math.clz32(e.length-1|1))-1,o=Math.ceil(1.6*n*t/e.length);return(i=t)=>{let s="";for(;;){let a=r(o),c=o;for(;c--;)if(s+=e[a[c]&n]||"",s.length===i)return s}}},hu=(e,t=21)=>xv(e,t,vv),gi=(e=21)=>{gu(e-=0);let t="";for(let r=Qe-e;r<Qe;r++)t+=du[Xe[r]&63];return t};var Ru=ee(le(),1);l();function yu(e=[]){return{name:"@shikijs/transformers:compact-line-options",line(t,r){let n=e.find(o=>o.line===r);return n?.classes&&this.addClassToHast(t,n.classes),t}}}function _v(e,t,r,n=!1){return{name:e,code(o){let i=o.children.filter(a=>a.type==="element"),s=[];i.forEach((a,c)=>{let u;for(let f of a.children){if(f.type!=="element")continue;let d=f.children[0];if(d.type!=="text")continue;let p=!1;d.value=d.value.replace(t,(...y)=>r.call(this,y,a,f,i,c)?(p=!0,""):y[0]),p&&!d.value.trim()&&(u=f)}if(u&&(a.children.splice(a.children.indexOf(u),1),a.children.length===0&&(s.push(a),n))){let f=o.children[o.children.indexOf(a)+1];f&&f.type==="text"&&f.value===`
|
|
53
|
+
`&&s.push(f)}});for(let a of s)o.children.splice(o.children.indexOf(a),1)}}}function bv(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function Xr(e={},t="@shikijs/transformers:notation-map"){let{classMap:r={},classActivePre:n=void 0}=e;return _v(t,new RegExp(`\\s*(?://|/\\*|<!--|#|--)\\s+\\[!code (${Object.keys(r).map(bv).join("|")})(:\\d+)?\\]\\s*(?:\\*/|-->)?`),function([o,i,s=":1"],a,c,u,f){let d=Number.parseInt(s.slice(1),10);return u.slice(f,f+d).forEach(p=>{this.addClassToHast(p,r[i])}),n&&this.addClassToHast(this.pre,n),!0})}function vu(e={}){let{classActiveLine:t="focused",classActivePre:r="has-focused"}=e;return Xr({classMap:{focus:t},classActivePre:r},"@shikijs/transformers:notation-focus")}function xu(e={}){let{classActiveLine:t="highlighted",classActivePre:r="has-highlighted"}=e;return Xr({classMap:{highlight:t,hl:t},classActivePre:r},"@shikijs/transformers:notation-highlight")}function _u(e={}){let{classLineAdd:t="diff add",classLineRemove:r="diff remove",classActivePre:n="has-diff"}=e;return Xr({classMap:{"++":t,"--":r},classActivePre:n},"@shikijs/transformers:notation-diff")}function bu(e={}){let{classMap:t={error:["highlighted","error"],warning:["highlighted","warning"]},classActivePre:r="has-highlighted"}=e;return Xr({classMap:t,classActivePre:r},"@shikijs/transformers:notation-error-level")}var ek=Symbol("highlighted-lines");import{addClassToHast as Rv,bundledLanguages as Sv,getHighlighter as wv,isSpecialLang as Cv}from"shiki";var Ev=hu("abcdefghijklmnopqrstuvwxyz",10);function kv(e){e=e.replace(/^(?:\[.*?\])?.*?([\d,-]+).*/,"$1").trim();let t=[];return e?(e.split(",").map(r=>r.split("-").map(n=>Number.parseInt(n,10))).forEach(([r,n])=>{r&&n?t.push(...Array.from({length:n-r+1},(o,i)=>r+i)):t.push(r)}),t.map(r=>({line:r,classes:["highlighted"]}))):[]}async function hi(e,t,r=console){let{defaultHighlightLang:n="",codeTransformers:o=[]}=t,i=await wv({themes:typeof e=="object"&&"light"in e&&"dark"in e?[e.light,e.dark]:[e],langs:[...Object.keys(Sv),...t.languages||[]],langAlias:t.languageAlias});await t?.shikiSetup?.(i);let s=[_u(),vu({classActiveLine:"has-focus",classActivePre:"has-focused-lines"}),xu(),bu(),{name:"valaxy:add-class",pre(d){Rv(d,"vp-code")}},{name:"valaxy:clean-up",pre(d){delete d.properties.tabindex,delete d.properties.style}}],a=/-vue$/,c=/=(\d*)/,u=/:(no-)?line-numbers(=\d*)?$/,f=/\{\{.*?\}\}/g;return(d,p,y)=>{let v=a.test(p)?"":"v-pre";p=p.replace(c,"").replace(u,"").replace(a,"").toLowerCase()||n,p&&!i.getLoadedLanguages().includes(p)&&!Cv(p)&&(r.warn(Ru.default.yellow(`
|
|
54
|
+
The language '${p}' is not loaded, falling back to '${n||"txt"}' for syntax highlighting.`)),p=n);let b=kv(y),$=new Map,E=D=>v?D:D.replace(f,A=>{let M=$.get(A);return M||(M=Ev(),$.set(A,M)),M}),I=D=>($.forEach((A,M)=>{D=D.replaceAll(A,M)}),D);d=E(d).trimEnd();let P=i.codeToHtml(d,{lang:p,transformers:[...s,yu(b),{name:"valaxy:v-pre",pre(D){v&&(D.properties["v-pre"]="")}},{name:"valaxy:empty-line",code(D){D.children.forEach(A=>{A.type==="element"&&A.tagName==="span"&&Array.isArray(A.properties.class)&&A.properties.class.includes("line")&&A.children.length===0&&A.children.push({type:"element",tagName:"wbr",properties:{},children:[]})})}},...o],meta:{__raw:y},...typeof e=="object"&&"light"in e&&"dark"in e?{themes:e,defaultColor:!1}:{theme:e}});return I(P)}}l();import qu from"markdown-it-anchor";import zv from"markdown-it-attrs";import{full as Yv}from"markdown-it-emoji";import Xv from"markdown-it-footnote";import Qv from"markdown-it-task-lists";import Jv from"markdown-it-image-figures";l();l();var Pv={"&":"&","<":"<",">":">","'":"'",'"':"""},Av=/[&<>'"]/g,lt=e=>e.replace(Av,t=>Pv[t]);var yi=(e,{shouldAllowHtml:t,shouldEscapeText:r})=>{let n=e.children??[],o=["text","emoji","code_inline"];return t&&o.push("html_inline"),n.filter(s=>o.includes(s.type)&&!s.meta?.isPermalinkSymbol).reduce((s,a)=>r&&(a.type==="code_inline"||a.type==="text")?`${s}${lt(a.content)}`:`${s}${a.content}`,"").trim()},Qr=(e,{level:t,shouldAllowHtml:r,shouldAllowNested:n,shouldEscapeText:o,slugify:i,format:s})=>{let a=[],c=[],u=f=>{for(;c.length!==0&&f.level<=c[0].level;)c.shift();c.length===0?(a.push(f),c.push(f)):(c[0].children.push(f),c.unshift(f))};for(let f=0;f<e.length;f+=1){let d=e[f];if(d.type!=="heading_open"||d.level!==0&&!n)continue;let p=Number.parseInt(d.tag.slice(1),10);if(!t.includes(p))continue;let y=e[f+1];if(!y)continue;let v=yi(y,{shouldAllowHtml:r,shouldEscapeText:o}),b=d.attrGet("id")??i(v);u({level:p,title:s?.(v)??v,slug:b,link:`#${b}`,children:[]})}return a},Ov=/[\u0000-\u001f]/g,Tv=/[\s~`!@#$%^&*()\-_+=[\]{}|\\;:"'“”‘’<>,.?/]+/g,$v=/[\u0300-\u036F]/g,ct=e=>e.normalize("NFKD").replace($v,"").replace(Ov,"").replace(Tv,"-").replace(/-{2,}/g,"-").replace(/^-+|-+$/g,"").replace(/^(\d)/,"_$1").toLowerCase();var Su=(e,{level:t=[2,3],shouldAllowNested:r=!1,slugify:n=ct,format:o}={})=>{let i=e.renderer.render.bind(e.renderer);e.renderer.render=(s,a,c)=>(c.headers=Qr(s,{level:t,shouldAllowHtml:!1,shouldAllowNested:r,shouldEscapeText:!1,slugify:n,format:o}),i(s,a,c))};l();var wu="script",Cu="style",Kt="template",Nv=/^<script\s+.*?\bsetup\b.*?>$/is,Mv=({customBlocks:e})=>{let t=Array.from(new Set([wu,Cu,...e])).join("|");return new RegExp(`^\\s*(?<content>(?<tagOpen><(?<type>${t})\\s?.*?>)(?<contentStripped>.*)(?<tagClose><\\/\\k<type>\\s*>))\\s*$`,"is")},Eu=(e,{customBlocks:t=[]}={})=>{let r=Mv({customBlocks:t}),n=e.render.bind(e);e.render=(i,s={})=>{s.sfcBlocks={template:null,script:null,scriptSetup:null,scripts:[],styles:[],customBlocks:[]};let a=n(i,s);return s.sfcBlocks.template={type:Kt,content:`<${Kt}>${a}</${Kt}>`,contentStripped:a,tagOpen:`<${Kt}>`,tagClose:`</${Kt}>`},a};let o=e.renderer.rules.html_block;e.renderer.rules.html_block=(i,s,a,c,u)=>{if(!c.sfcBlocks)return o(i,s,a,c,u);let p=i[s].content.match(r);if(!p)return o(i,s,a,c,u);let y=p.groups;return y.type===wu?(c.sfcBlocks.scripts.push(y),Nv.test(y.tagOpen)?c.sfcBlocks.scriptSetup=y:c.sfcBlocks.script=y):y.type===Cu?c.sfcBlocks.styles.push(y):c.sfcBlocks.customBlocks.push(y),""}};l();var ku=e=>{let t=e.renderer.render.bind(e.renderer);e.renderer.render=(r,n,o)=>{let i=r.findIndex(s=>s.tag==="h1");return o.title=i>-1?yi(r[i+1],{shouldAllowHtml:!1,shouldEscapeText:!1}):"",t(r,n,o)}};l();var Iv=({listTag:e,listClass:t,itemClass:r,linkTag:n,linkClass:o})=>{let i=lt(e),s=t?` class="${lt(t)}"`:"",a="li",c=r?` class="${lt(r)}"`:"",u=lt(n),f=o?` class="${lt(o)}"`:"",d=y=>n==="router-link"?` to="${y}"`:` href="${y}"`,p=y=>`<${i}${s}>${y.map(v=>`<${a}${c}><${u}${f}${d(v.link)}>${v.title}</${u}>${v.children.length>0?p(v.children):""}</${a}>`).join("")}</${i}>`;return p},Lv=({pattern:e,containerTag:t,containerClass:r})=>(n,o,i,s)=>{if(n.sCount[o]-n.blkIndent>=4)return!1;let a=n.bMarks[o]+n.tShift[o],c=n.eMarks[o],u=n.src.slice(a,c).split(" ")[0];if(!e.test(u))return!1;if(s)return!0;n.line=o+1;let f=n.push("toc_open",t,1);f.markup="",f.map=[o,n.line],r&&f.attrSet("class",r);let d=n.push("toc_body","",0);d.markup=u,d.map=[o,n.line],d.hidden=!0;let p=n.push("toc_close",t,-1);return p.markup="",d.map=[o,n.line],!0},Pu=(e,{pattern:t=/^\[\[toc\]\]$/i,slugify:r=ct,format:n,level:o=[2,3],shouldAllowNested:i=!1,containerTag:s="nav",containerClass:a="table-of-contents",listTag:c="ul",listClass:u="",itemClass:f="",linkTag:d="a",linkClass:p=""}={})=>{e.block.ruler.before("heading","toc",Lv({pattern:t,containerTag:s,containerClass:a}),{alt:["paragraph","reference","blockquote"]});let y=Iv({listTag:c,listClass:u,itemClass:f,linkTag:d,linkClass:p});e.renderer.rules.toc_body=v=>y(Qr(v,{level:o,shouldAllowHtml:!0,shouldAllowNested:i,shouldEscapeText:!0,slugify:r,format:n}))};import{cssI18nContainer as Zv}from"css-i18n";l();import Au from"katex";function Ou(e,t){let r=e.posMax,n=!0,o=!0,i=t>0?e.src.charCodeAt(t-1):-1,s=t+1<=r?e.src.charCodeAt(t+1):-1;return(i===32||i===9||s>=48&&s<=57)&&(o=!1),(s===32||s===9)&&(n=!1),{can_open:n,can_close:o}}function Fv(e,t){let r,n,o,i;if(e.src[e.pos]!=="$")return!1;if(o=Ou(e,e.pos),!o.can_open)return t||(e.pending+="$"),e.pos+=1,!0;let s=e.pos+1;for(r=s;(r=e.src.indexOf("$",r))!==-1;){for(i=r-1;e.src[i]==="\\";)i-=1;if((r-i)%2===1)break;r+=1}return r===-1?(t||(e.pending+="$"),e.pos=s,!0):r-s===0?(t||(e.pending+="$$"),e.pos=s+1,!0):(o=Ou(e,r),o.can_close?(t||(n=e.push("math_inline","math",0),n.markup="$",n.content=e.src.slice(s,r)),e.pos=r+1,!0):(t||(e.pending+="$"),e.pos=s,!0))}function Dv(e,t,r,n){let o,i,s,a,c=!1,u=e.bMarks[t]+e.tShift[t],f=e.eMarks[t];if(u+2>f||e.src.slice(u,u+2)!=="$$")return!1;if(u+=2,o=e.src.slice(u,f),n)return!0;for(o.trim().slice(-2)==="$$"&&(o=o.trim().slice(0,-2),c=!0),s=t;!c&&(s++,!(s>=r||(u=e.bMarks[s]+e.tShift[s],f=e.eMarks[s],u<f&&e.tShift[s]<e.blkIndent)));)e.src.slice(u,f).trim().slice(-2)==="$$"&&(a=e.src.slice(0,f).lastIndexOf("$$"),i=e.src.slice(u,a),c=!0);e.line=s+1;let d=e.push("math_block","math",0);return d.block=!0,d.content=(o&&o.trim()?`${o}
|
|
55
|
+
`:"")+e.getLines(t+1,s,e.tShift[t],!0)+(i&&i.trim()?i:""),d.map=[t,e.line],d.markup="$$",!0}function vi(e,t){t=t||{};let r=function(s){t.displayMode=!1;try{return Au.renderToString(s,t)}catch(a){return t.throwOnError&&console.warn(a),s}},n=function(s,a){return r(s[a].content)},o=function(s){t.displayMode=!0;try{return`<p>${Au.renderToString(s,t)}</p>`}catch(a){return t.throwOnError&&console.warn(a),s}},i=function(s,a){return`${o(s[a].content)}
|
|
56
|
+
`};e.inline.ruler.after("escape","math_inline",Fv),e.block.ruler.after("blockquote","math_block",Dv,{alt:["paragraph","reference","blockquote","list"]}),e.renderer.rules.math_inline=n,e.renderer.rules.math_block=i}l();import _i from"markdown-it-container";l();function Tu(e){return e.trim().replace(/=(\d*)/,"").replace(/:(no-)?line-numbers({| |$|=\d*).*/,"").replace(/(-vue|{| ).*$/,"").replace(/^vue-html$/,"template").replace(/^ansi$/,"")}function xi(e){return e.hasSingleTheme?"":" vp-adaptive-theme"}function $u(e,t=!1){return t?e.replace(/<!--[^]*?-->/g,"").match(/data-title="(.*?)"/)?.[1]||"":e.match(/\[(.*)\]/)?.[1]||Tu(e)||"txt"}function Vv(e,t){let r=t.frontmatter?.codeHeightLimit||e?.siteConfig?.codeHeightLimit;return r===void 0||r<=0?"":`style="max-height: ${r}px;"`}function Nu(e,t){let r=e.renderer.rules.fence;e.renderer.rules.fence=(...n)=>{let[o,i,s,a]=n,c=o[i];c.info=c.info.replace(/\[.*\]/,"");let u=Tu(c.info),f=r(...n);return`
|
|
57
|
+
<div ${Vv(t,a)} class="language-${u}${xi(t)}${/ active( |$)/.test(c.info)?" active":""}">
|
|
58
|
+
<button title="Copy Code" class="copy"></button><span class="lang">${u}</span>${f}<button class="collapse"></button>
|
|
59
|
+
</div>`}}function jv(e,{icon:t,color:r,text:n,langs:o}={}){return[_i,e,{render(i,s){let a=i[s],c=a.info.trim().slice(e.length).trim();if(a.nesting===1){if(e==="details")return`<details class="${e} custom-block">${`<summary>${c}</summary>`}
|
|
60
|
+
`;let u="";t&&(u=`<i class="icon ${t}" ${r?`style="color: ${r}"`:""}></i>`);let f=`<span lang="en">${c||n}</span>`;return o&&Object.keys(o).forEach(d=>{f+=`<span lang="${d}">${c||o[d]}</span>`}),`<div class="${e} custom-block"><p class="custom-block-title">${u}${f}</p>
|
|
61
|
+
`}else return e==="details"?`</details>
|
|
62
|
+
`:`</div>
|
|
63
|
+
`}}]}var Mu={tip:{text:"TIP",langs:{"zh-CN":"\u63D0\u793A"}},warning:{text:"WARNING",langs:{"zh-CN":"\u6CE8\u610F"}},danger:{text:"DANGER",langs:{"zh-CN":"\u8B66\u544A"}},info:{text:"INFO",langs:{"zh-CN":"\u4FE1\u606F"}},details:{text:"Details",langs:{"zh-CN":"\u8BE6\u60C5"}}};function Iu(e,t,r={}){Object.keys(Mu).forEach(o=>{let i={...Mu[o],...r[o]||{}};e.use(...jv(o,i))}),e.use(...Hv(t)),["zh-CN","en"].forEach(o=>{e.use(_i,o,{render:(i,s)=>i[s].nesting===1?`<div lang="${o}">
|
|
64
|
+
`:`</div>
|
|
65
|
+
`})})}function Hv(e){return[_i,"code-group",{render(t,r){if(t[r].nesting===1){let n=gi(5),o="",i='checked="checked"';for(let s=r+1;!(t[s].nesting===-1&&t[s].type==="container_code-group_close");++s){let a=t[s].type==="html_block";if(t[s].type==="fence"&&t[s].tag==="code"||a){let c=$u(a?t[s].content:t[s].info,a);if(c){let u=gi(7);o+=`<input type="radio" name="group-${n}" id="tab-${u}" ${i}><label for="tab-${u}">${c}</label>`,i&&!a&&(t[s].info+=" active"),i=""}}}return`<div class="vp-code-group${xi(e)}"><div class="tabs">${o}</div><div class="blocks">
|
|
66
|
+
`}return`</div></div>
|
|
67
|
+
`}}]}l();var bi=/{([\d,-]+)}/;function Lu(e){let t=e.renderer.rules.fence;e.renderer.rules.fence=(...r)=>{let[n,o]=r,i=n[o],s=i.attrs&&i.attrs[0],a=null;if(!s){let c=i.info;if(!c||!bi.test(c))return t(...r);let u=c.replace(bi,"").trim();i.info=u,a=bi.exec(c)[1]}return!a&&(a=s[0],!a||!/[\d,-]+/.test(a))?t(...r):(i.info+=` ${a}`,t(...r))}}l();import{URL as qv}from"node:url";var Bv=/(^|.*\/)index.md(#?.*)$/i;function Fu(e,t,r){e.renderer.rules.link_open=(i,s,a,c,u)=>{let f=i[s],d=f.attrIndex("href");if(d>=0){let p=f.attrs[d],y=p[1];xt.test(y)?(Object.entries(t).forEach(([b,$])=>{f.attrSet(b,$)}),p[1]=y.replace(Cl,"")):!y.startsWith("#")&&!y.startsWith("mailto:")&&!/\.(?!html|md)\w+($|\?)/i.test(y)&&n(p,c),p[1]=p[1].replace(/\bimport\.meta/g,"import%2Emeta").replace(/\bprocess\.env/g,"process%2Eenv")}return u.renderToken(i,s,a)};function n(i,s){let a=i[1],c=a.match(Bv);if(c){let[,u,f]=c;a=u+f}else{let u=a.replace(/[?#].*$/,"");u.endsWith(".md")&&(u=u.replace(/\.md$/,s.cleanUrls==="disabled"?".html":"")),s.cleanUrls==="disabled"&&!u.endsWith(".html")&&!u.endsWith("/")&&(u+=".html");let f=new qv(a,"http://a.com");a=u+f.search+f.hash}!a.startsWith("/")&&!/^\.\//.test(a)&&(a=`./${a}`),o(a.replace(/\.html$/,""),s),a.startsWith("/")&&(a=`${r}${a}`.replace(/\/+/g,"/")),i[1]=decodeURI(a)}function o(i,s){(s.links||(s.links=[])).push(i)}}l();function Du(e,t=!1){let r=e.renderer.rules.fence;e.renderer.rules.fence=(...n)=>{let o=r(...n),[i,s]=n,a=i[s].info;if(!t&&!/:line-numbers($| |=)/.test(a)||t&&/:no-line-numbers($| )/.test(a))return o;let c=1,u=a.match(/=(\d*)/);u&&u[1]&&(c=Number.parseInt(u[1]));let d=o.slice(o.indexOf("<code>"),o.indexOf("</code>")).split(`
|
|
68
|
+
`),y=`<div class="line-numbers-wrapper" aria-hidden="true">${[...Array(d.length)].map((b,$)=>`<span class="line-number">${$+c}</span><br>`).join("")}</div>`;return o.replace(/<\/div>$/,`${y}</div>`).replace(/"(language-[^"]*?)"/,'"$1 line-numbers-mode"')}}l();import Vu from"pathe";import Ri from"fs-extra";var Uv=/^(.+?(?:(?:\.([a-z0-9]+))?))(?:(#[\w-]+))?(?: ?(?:{(\d+(?:[,-]\d+)*)? ?(\S+)?}))? ?(?:\[(.+)\])?$/;function Wv(e){let[t="",r="",n="",o="",i="",s=""]=(Uv.exec(e)||[]).slice(1),a=s||t.split("/").pop()||"";return{filepath:t,extension:r,region:n,lines:o,lang:i,title:a}}function Gv(e){let t=e.split(`
|
|
69
|
+
`),r=t.reduce((n,o)=>{for(let i=0;i<o.length;i++)if(o[i]!==" "&&o[i]!==" ")return Math.min(i,n);return n},Number.POSITIVE_INFINITY);return r<Number.POSITIVE_INFINITY?t.map(n=>n.slice(r)).join(`
|
|
70
|
+
`):e}function ju(e,t,r,n=!1){let[o,i,s]=t.exec(e.trim())||[];return o&&i&&s===r&&i.match(n?/^[Ee]nd ?[rR]egion$/:/^[rR]egion$/)}function Kv(e,t){let r=[/^\/\/ ?#?((?:end)?region) ([\w*-]+)$/,/^\/\* ?#((?:end)?region) ([\w*-]+) ?\*\/$/,/^#pragma ((?:end)?region) ([\w*-]+)$/,/^<!-- #?((?:end)?region) ([\w*-]+) -->$/,/^#((?:End )Region) ([\w*-]+)$/,/^::#((?:end)region) ([\w*-]+)$/,/^# ?((?:end)?region) ([\w*-]+)$/],n=null,o=-1;for(let[i,s]of e.entries())if(n===null){for(let a of r)if(ju(s,a,t)){o=i+1,n=a;break}}else if(ju(s,n,t,!0))return{start:o,end:i,regexp:n};return null}function Hu(e,t){let r=(o,i,s,a)=>{let u=o.bMarks[i]+o.tShift[i],f=o.eMarks[i];if(o.sCount[i]-o.blkIndent>=4)return!1;for(let w=0;w<3;++w)if(o.src.charCodeAt(u+w)!==60||u+w>=f)return!1;if(a)return!0;let d=u+3,p=o.skipSpacesBack(f,u),y=o.src.slice(d,p).trim().replace(/^@/,t).trim(),{filepath:v,extension:b,region:$,lines:E,lang:I,title:P}=Wv(y);o.line=i+1;let D=o.push("fence","code",0);D.info=`${I||b}${E?`{${E}}`:""}${P?`[${P}]`:""}`;let{realPath:A,path:M}=o.env,C=Vu.resolve(Vu.dirname(A??M),v);return D.src=[C,$.slice(1)],D.markup="```",D.map=[i,i+1],!0},n=e.renderer.rules.fence;e.renderer.rules.fence=(...o)=>{let[i,s,,{includes:a}]=o,c=i[s],[u,f]=c.src??[];if(!u)return n(...o);a&&a.push(u);let d=Ri.statSync(u).isFile();if(!Ri.existsSync(u)||!d)return c.content=d?`Code snippet path not found: ${u}`:"Invalid code snippet option",c.info="",n(...o);let p=Ri.readFileSync(u,"utf8");if(f){let y=p.split(/\r?\n/),v=Kv(y,f);v&&(p=Gv(y.slice(v.start,v.end).filter(b=>!v.regexp.test(b.trim())).join(`
|
|
71
|
+
`)))}return c.content=p,n(...o)},e.block.ruler.before("fence","snippet",r)}var Jr={light:"github-light",dark:"github-dark"};async function zt(e,t,r="/"){let n=t?.config.markdown||{},o=n.theme??Jr,i=typeof o=="string"||"name"in o,s=t?.config.siteConfig||{};n.preConfig&&n.preConfig(e),e.use(Lu).use(Nu,{theme:o,siteConfig:s}).use(Hu,t?.userRoot).use(Iu,{hasSingleTheme:i},{...n.blocks,...n?.container}).use(Zv,{languages:t?.config.siteConfig.languages}).use(Fu,{target:"_blank",rel:"noreferrer",...n.externalLinks},r),e.use(Du,n.lineNumbers),n.attrs?.disable||e.use(zv,n.attrs),e.use(Yv).use(Xv),e.use(qu,{slugify:ct,permalink:qu.permalink.linkInsideHeader({symbol:"​",renderAttrs:(c,u)=>{let f=u.tokens.findIndex(p=>{let v=p.attrs?.find(b=>b[0]==="id");return v&&c===v[1]});return{"aria-label":`Permalink to "${u.tokens[f+1].content}"`}}}),...n.anchor}),e.use(Su,{slugify:ct,...typeof n.headers=="boolean"?void 0:n.headers}).use(Eu,{...n.sfc}).use(ku).use(Pu,{...n.toc}),e.use(vi,n.katex);let a=t?.config.siteConfig.vanillaLazyload||{enable:!1};return e.use(Jv,{figcaption:!0,lazy:!0,async:!0,...a.enable?{lazy:!0,async:!0,classes:"lazy"}:{},...n.imageFigures}),e.use(Qv),n.config&&n.config(e),e}l();l();import nx from"unplugin-vue-markdown/vite";l();import ki from"pathe";import{slash as tx}from"@antfu/utils";l();l();import Si from"node:process";var wi=new Set;function Bu(e){if(wi.size===0){let r=typeof Si=="object"&&Si.env.VITE_EXTRA_EXTENSIONS||Si.env?.VITE_EXTRA_EXTENSIONS||"";`3g2,3gp,aac,ai,apng,au,avif,bin,bmp,cer,class,conf,crl,css,csv,dll,doc,eps,epub,exe,gif,gz,ics,ief,jar,jpe,jpeg,jpg,js,json,jsonld,m4a,man,mid,midi,mjs,mov,mp2,mp3,mp4,mpe,mpeg,mpg,mpp,oga,ogg,ogv,ogx,opus,otf,p10,p7c,p7m,p7s,pdf,png,ps,qt,roff,rtf,rtx,ser,svg,t,tif,tiff,tr,ts,tsv,ttf,txt,vtt,wav,weba,webm,webp,woff,woff2,xhtml,xml,yaml,yml,zip${r&&typeof r=="string"?`,${r}`:""}`.split(",").forEach(n=>wi.add(n))}let t=e.split(".").pop();return t==null||!wi.has(t.toLowerCase())}l();import Ci from"node:path";import ex from"fs-extra";function Ei(e,t,r){let n=/<!--\s*@include:\s*(.*?)\s*-->/g,o=/\{(\d*),(\d*)\}$/;return t.replace(n,(i,s)=>{if(!s.length)return i;let a=s.match(o);a&&(s=s.slice(0,-a[0].length));let c=s[0]==="@";try{let u=c?Ci.join(e,s.slice(s[1]==="/"?2:1)):Ci.join(Ci.dirname(r),s),f=ex.readFileSync(u,"utf-8");if(a){let[,d,p]=a;f=f.split(/\r?\n/).slice(d?Number.parseInt(d,10)-1:void 0,p?Number.parseInt(p,10):void 0).join(`
|
|
72
|
+
`)}return f=`<!-- @included: ${s} -->
|
|
73
|
+
${f}`,Ei(e,f,u)}catch{return i}})}var rx=/<!--\s*@included:\s*(.*?)\s*-->/g;function Uu(e){let t=e.userRoot;return(r,n)=>Ei(t,r,n)}function Wu(e,t,r){let n=[],o=ki.dirname(t);return e=e.replace(rx,(i,s)=>{let c=s.startsWith("@")?ki.resolve(r.userRoot,s.slice(s[1]==="/"?2:1)):ki.join(o,s);return n.push(tx(c)),""}),{code:e,includes:n}}l();import*as Gu from"js-base64";function Ku(e){return e=e.replace(/^````txt\n```mermaid/mg,"````txt\n\\`\\`\\`mermaid"),e=e.replace(/^```mermaid\s*?({.*?})?\n([\s\S]+?)\n```/mg,(t,r="",n="")=>(n=n.trim(),r=r.trim()||"{}",`<ValaxyMermaid :code="'${Gu.encode(n,!0)}'" v-bind="${r}" />`)),e=e.replace(/^````txt\n\\`\\`\\`mermaid/mg,"````txt\n```mermaid"),e}async function zu(e){let t=e?.config.markdown||{},r=t.theme??Jr,n=Uu(e);return nx({include:[/\.md$/],wrapperClasses:"",frontmatter:!0,exportFrontmatter:!1,frontmatterOptions:{grayMatterOptions:Ue},frontmatterPreprocess(o,i,s,a){let c=o;return c.date&&(c.date=new Date(c.date)),c.updated&&(c.updated=new Date(c.updated)),{head:a(o,i),frontmatter:o}},escapeCodeTagInterpolation:!0,markdownItOptions:{quotes:`""''`,html:!0,xhtmlOut:!0,linkify:!0,highlight:await hi(r,t),...t?.markdownItOptions},async markdownItSetup(o){o.linkify.set({fuzzyLink:!1}),await zt(o,e),e?.config.markdown?.markdownItSetup?.(o);function i(s){s.core.ruler.push("valaxy_md_env",a=>{e.env=a.env})}o.use(i)},transforms:{before(o,i){return o=Ku(o),o=n(o,i),o}},...t})}function cx(e="",t="html",r){switch(t){case"ai":case"md":return e;case"html":return r.render(e);case"text":return sx(r.render(e));default:return e}}async function Xu(e){let{options:t}=e,{roots:r,config:n}=t,o=new ax({html:!0});return await zt(o,t),ox({extensions:[".vue",".md"],routesFolder:r.map(i=>`${i}/pages`),dts:ix(t.tempDir,"typed-router.d.ts"),...n.router,async extendRoute(i){let s=JSON.parse(JSON.stringify(n.siteConfig.frontmatter))||{};if(i.meta&&i.meta.frontmatter){let{frontmatter:c,otherMeta:u}=i.meta;i.meta=u}i.addToMeta({frontmatter:s}),(i.fullPath==="/"||i.fullPath==="/page")&&i.addToMeta({layout:"home"}),i.fullPath==="/posts"?i.addToMeta({layout:!1}):i.fullPath.startsWith("/posts/")&&i.children.length===0&&i.addToMeta({layout:"post"});let a=i.components.get("default")||"";if(a.endsWith(".md")){let c=Pi.readFileSync(a,"utf-8"),{data:u,excerpt:f,content:d}=lx(c,Ue),p=u,y=t.config.siteConfig.lastUpdated;if(delete p.password,p.gallery_password&&(delete p.gallery_password,delete p.photos),p.date||(p.date=Pi.statSync(a).mtime),y&&(p.updated||(p.updated=Pi.statSync(a).ctime)),Yu(p.date)||(p.date=new Date(p.date)),Yu(p.updated)||(p.updated=new Date(p.updated)),p.from&&(Array.isArray(p.from)?p.from.forEach(b=>{t.redirects.push({from:b,to:i.fullPath})}):t.redirects.push({from:p.from,to:i.fullPath})),i.addToMeta({frontmatter:p,excerpt:f?cx(f,p.excerpt_type,o):""}),u.layout&&i.addToMeta({layout:u.layout}),i.meta.frontmatter?.updated||(i.meta.frontmatter.updated=i.meta.frontmatter.date),i.meta.frontmatter.tags){let b=i.meta.frontmatter.tags;typeof b=="string"&&(i.meta.frontmatter.tags=[b])}n.siteConfig.statistics.enable&&pu({options:n.siteConfig.statistics,route:i});let v={route:i,data:u,excerpt:f,content:d,path:a};n.extendMd?.(v)}return await e.hooks.callHook("vue-router:extendRoute",i),n.router?.extendRoute?.(i)}})}l();var en=ee(le(),1);import{join as Yt,relative as wx,resolve as Cx}from"pathe";import Xt from"fs-extra";import{defu as Ex}from"defu";import kx from"pascalcase";import lf from"consola";l();import{LRUCache as _x}from"lru-cache";import bx from"debug";import Rx from"pathe";l();import kt from"pathe";import{slash as ux}from"@antfu/utils";import fx from"fs-extra";function Qu(e){let t=kt.resolve(e.userRoot,"pages"),{ignoreDeadLinks:r}=e.config,n=e.config.vite?.publicDir||"public";return(o,i)=>{let{links:s=[]}=e.env,a=i,c=i,u=[],f=p=>{u.push({url:p,file:kt.relative(t,a)})};function d(p){return r?r===!0?!0:r==="localhostLinks"?p.replace(xt,"").startsWith("//localhost"):r.some(y=>typeof y=="string"?p===y:y instanceof RegExp?y.test(p):typeof y=="function"?y(p):!1):!1}if(s){let p=kt.dirname(c);for(let y of s){let{pathname:v}=new URL(y,"http://a.com");if(!Bu(v))continue;y=y.replace(/[?#].*$/,"").replace(/\.(html|md)$/,""),y.endsWith("/")&&(y+="index");let b=decodeURIComponent(ux(y.startsWith("/")?y.slice(1):kt.relative(t,kt.resolve(p,y)))).replace(/\/index$/,"");!e.pages.includes(b)&&!fx.existsSync(kt.resolve(p,n,`${b}.html`))&&!d(y)&&f(y)}}return u}}l();function px(e){return["import { provide } from 'vue'","import { useRoute } from 'vue-router'",`
|
|
74
|
+
const data = ${bc(e)}
|
|
75
|
+
const route = useRoute()`,`const $frontmatter = data.frontmatter || {}
|
|
76
|
+
route.meta.frontmatter = Object.assign(route.meta.frontmatter || {}, data.frontmatter || {})
|
|
77
|
+
provide('pageData', data)
|
|
78
|
+
provide('valaxy:frontmatter', $frontmatter)
|
|
79
|
+
`]}function Ju(e){return(t,r,n)=>{let o=px(n),i=e.mode==="dev",s=[...o,i?`
|
|
80
|
+
window.$pageData = data
|
|
81
|
+
window.$frontmatter = $frontmatter
|
|
82
|
+
`:"","globalThis.$frontmatter = $frontmatter"],a=t.indexOf("<script setup>");a!==-1?t=t.slice(0,a+14)+s.join(`
|
|
83
|
+
`)+t.slice(a+14):t=`<script setup>
|
|
84
|
+
${s.join(`
|
|
85
|
+
`)}
|
|
86
|
+
</script>
|
|
87
|
+
${t}`;let c=t.indexOf("<template>")+10,u=t.lastIndexOf("</template>"),f=t.slice(c,u).trim();return f.startsWith("<div>")&&f.endsWith("</div>")&&(f=f.slice(5,-6)),t=`${t.slice(0,c)}
|
|
88
|
+
${Zu(f)}
|
|
89
|
+
${t.slice(u)}`,t}}l();import dx from"pathe";function mx(e,t){if(!e||!e.length)return;let r=e.find(([n,o={}])=>n==="meta"&&o.name===t&&o.content);return r&&r[1].content}function gx(e){let{description:t,head:r}=e;return t!==void 0?t:r&&mx(r,"description")||""}async function ef(e,t,r){let{frontmatter:n={}}=r.env,o=dx.relative(r.userRoot,t),i=JSON.parse(JSON.stringify(n)),s={title:i.title||r.env.title||"",titleTemplate:i.titleTemplate,description:gx(i),frontmatter:i,headers:r.env.headers||[],relativePath:o,path:t};return s.lastUpdated=await It(t),s}l();function hx(e,t,r){if(typeof r!="number"||r<=0)return e;let n=t.config.siteConfig.codeHeightLimit;return e=e.replaceAll(/<div.+class="language-\w+">/g,o=>(n!==void 0&&n>0?o=o.replace(/\d+/,r.toString()):o=`${o.slice(0,5)}style="max-height: ${r}px;"${o.slice(5)}`,o)),e}function tf(e){return t=>{let{frontmatter:r={}}=e.env;return hx(t,e,r.codeHeightLimit)}}l();l();import{webcrypto as Ai}from"node:crypto";function yx(e){let t=new TextEncoder;return Ai.subtle.importKey("raw",t.encode(e),"PBKDF2",!1,["deriveBits","deriveKey"])}function vx(e,t){return Ai.subtle.deriveKey({name:"PBKDF2",salt:t,iterations:1e5,hash:"SHA-256"},e,{name:"AES-CBC",length:256},!0,["encrypt","decrypt"])}async function Zr(e,t){let{password:r,iv:n,salt:o}=t,i=await yx(r),s=await vx(i,o),a=new TextEncoder,c=await Ai.subtle.encrypt({name:"AES-CBC",iv:n},s,a.encode(e));return String.fromCharCode(...new Uint8Array(c))}function rf(e){let{config:{siteConfig:{encrypt:t}}}=e;return async(r,n,o)=>{let{frontmatter:i={}}=o;if(t.enable){let s=/<!-- valaxy-encrypt-start:(?<password>\w+) -->(?<content>.*?)<!-- valaxy-encrypt-end -->/gs,a=/((<!-- valaxy-encrypt-start:\w+ -->)|(<!-- valaxy-encrypt-end -->))/g;if(i.password)r=r.replaceAll(a,"");else{let c=[];for(let f of r.matchAll(s))c.push(await Zr(f.groups.content,{password:f.groups.password,iv:t.iv,salt:t.salt}));let u=0;c.length&&(i.partiallyEncryptedContents=c,r=r.replaceAll(s,()=>`<ClientOnly><ValaxyDecrypt :encrypted-content="${`$frontmatter.partiallyEncryptedContents[${u++}]`}" /></ClientOnly>`))}if(i.password){let c=r.indexOf("<template>"),u=r.lastIndexOf("</template>"),f=r.slice(c+10,u),d=await Zr(f,{password:i.password,iv:t.iv,salt:t.salt});i.encryptedContent=d,i.encrypt=!0,delete i.password,r=r.replace(f,'<ClientOnly><ValaxyDecrypt :encrypted-content="$frontmatter.encryptedContent" /></ClientOnly>');let y=r.lastIndexOf("<script setup>"),v=r.lastIndexOf("</script>"),b=r.slice(y+14,v);r=r.replace(b,"")}if(i.gallery_password){let c=await Zr(JSON.stringify(i.photos),{password:i.gallery_password,iv:t.iv,salt:t.salt});i.encryptedPhotos=c,delete i.gallery_password,delete i.photos}}return r}}l();var Pt=ee(le(),1);import xx from"consola";function nf(e,t){return e.includes("{%")&&e.includes("%}")&&xx.error(`${`${t}
|
|
90
|
+
`} Please ${(0,Pt.red)("remove")} ${(0,Pt.cyan)("{% %}")}, because it conflicts with ${(0,Pt.yellow)("markdown-it-attrs")}.`),e.replace("{%","{%"),e.replace("%}","%}"),e}var of=bx("valaxy:md"),sf=new _x({max:128});function Sx(){return["main-header","main-header-after","main-nav","main-content","main-content-after","main-nav-before","main-nav-after","comment","footer","aside","aside-custom"].map(r=>`<template #${r}><slot name="${r}" /></template>`).join("")}function Zu(e){let t="ValaxyMain";return`
|
|
91
|
+
<${t} :frontmatter="$frontmatter">
|
|
92
|
+
<template #main-content-md>${e}</template>
|
|
93
|
+
${Sx()}
|
|
94
|
+
<slot />
|
|
95
|
+
</${t}>
|
|
96
|
+
`}async function af(e,t){e.pages=e.pages.map(c=>c.replace(/\.md$/,"").replace(/\/index$/,""));let r=tf(e),n=Ju(e),o=rf(e),i=Qu(e),s=e.userRoot,a=e.mode==="build";return async(c,u)=>{let f=u,d=Rx.relative(s,f),p=i(c,u),y=JSON.stringify({code:c,id:u});if(a){let P=JSON.stringify({code:c,id:u}),D=sf.get(P);if(D)return of(`[cache hit] ${d}`),D}let v=Date.now(),b=await ef(c,u,e);c=nf(c,u);let $=Wu(c,u,e),E=$.includes;c=$.code,c=r(c),c=await o(c,u,b),c=n(c,u,b),of(`[render] ${f} in ${Date.now()-v}ms.`);let I={code:c,pageData:b,deadLinks:p,includes:E};return a&&sf.set(y,I),I}}function Px(e){let t=e.redirects.map(r=>({path:r.from,redirect:r.to}));return e.config.runtimeConfig.redirects={useVueRouter:Bt()?e.config.siteConfig.redirects.useVueRouter:!0,redirectRoutes:t},`export default ${JSON.stringify(JSON.stringify(e.config))}`}function Ax(e,t){let r=[];t.config.features?.katex&&(r.push(`import "${X(Oe("katex/dist/katex.min.css",!0))}"`),r.push(`import "${X(Yt(t.clientRoot,"styles/third/katex.scss"))}"`));for(let n of e){let o=[];["css-vars","index"].forEach(s=>{o.push(Yt(n,"styles",`${s}.css`)),o.push(Yt(n,"styles",`${s}.scss`))});for(let s of o)Xt.existsSync(s)&&r.push(`import "${X(s)}"`)}return r.join(`
|
|
97
|
+
`)}function Ox(e){let t=['import { defu } from "defu"','const messages = { "zh-CN": {}, en: {} }'],r=["zh-CN","en"];return e.forEach((n,o)=>{r.forEach(i=>{let s=`${n}/locales/${i}.yml`;if(Xt.existsSync(s)&&Xt.readFileSync(s,"utf-8")){let a=i.replace("-","")+o;t.unshift(`import ${a} from "${X(s)}"`),t.push(`messages['${i}'] = defu(${a}, messages['${i}'])`)}})}),t.push("export default messages"),t.join(`
|
|
98
|
+
`)}function Tx(e){let t=e.addons.filter(i=>i.global).filter(i=>Xt.existsSync(Yt(i.root,"./App.vue"))),r=i=>`Addon${kx(i)}App`,n=t.map(i=>`import ${r(i.name)} from "${i.name}/App.vue"`).join(`
|
|
99
|
+
`),o=t.map(i=>`{ component: ${r(i.name)}, props: ${JSON.stringify(i.props)} }`).join(",");return`${n}
|
|
100
|
+
export default [${o}]`}var $x='import { defineComponent } from "vue"; export default defineComponent({ render: () => null });';function Oi(e){let t=Yt(e,"App.vue");return Xt.existsSync(t)?[`import AppVue from "${X(t)}"`,"export default AppVue"].join(`
|
|
101
|
+
`):$x}async function cf(e,t={}){let{config:r}=e,n="/@valaxy",o=e.roots,i=!1,s,a;return[{name:"valaxy:loader",enforce:"pre",async configResolved(c){a=c,s=await af(e,a)},configureServer(c){c.watcher.add([e.configFile,e.clientRoot,e.themeRoot,e.userRoot])},resolveId(c){return c.startsWith(n)?c:null},load(c){if(c==="/@valaxyjs/config")return Px(e);if(c==="/@valaxyjs/context")return`export default ${JSON.stringify(JSON.stringify({userRoot:e.userRoot}))}`;if(c==="/@valaxyjs/styles")return Ax(o,e);if(c==="/@valaxyjs/locales")return Ox(o);if(c==="/@valaxyjs/addons")return Tx(e);if(c==="/@valaxyjs/AppVue")return Oi(e.clientRoot);if(c==="/@valaxyjs/UserAppVue")return Oi(e.userRoot);if(c==="/@valaxyjs/ThemeAppVue")return Oi(e.themeRoot);if(c.startsWith(n))return{code:"",map:{mappings:""}}},async transform(c,u){if(u.endsWith(".md")){let{code:f,deadLinks:d,includes:p}=await s(c,u);return d.length&&(i=!0,lf.error(`Dead links found in ${u}`),lf.error(d)),p.length&&p.forEach(y=>{this.addWatchFile(y)}),f}},renderStart(){if(i&&!(r.ignoreDeadLinks||r.build.ignoreDeadLinks))throw new Error("One or more pages contain dead links.")},async handleHotUpdate(c){let{file:u,server:f,read:d}=c,p=v=>{t.onConfigReload?.(v,e.config),Object.assign(e.config,v),r=v;let b=["/@valaxyjs/config","/@valaxyjs/context"];return[...Array.from(b).map(E=>f.moduleGraph.getModuleById(E))].filter(E=>!!E)};if([e.configFile].includes(u)){let{config:v}=await be({userRoot:e.userRoot});return p(v)}if(u===e.siteConfigFile){let{siteConfig:v}=await Fr(e.userRoot);return r.siteConfig=Ex(v,Lr),p(r)}if(u===e.themeConfigFile){let{themeConfig:v}=await Oc(e),b=r.themeConfig.pkg;return v.pkg=b,r.themeConfig=v,p(r)}if(u===Cx(e.themeRoot,"valaxy.config.ts")){let v=await li(e),b=st(e.config,v),{config:$}=await ai(e,b);return p($)}if(u.endsWith(".md")){let v=We(),b=await d(),{code:$,pageData:E}=await s(b,u),P={path:`/${wx(`${e.userRoot}/pages`,u)}`,pageData:E};f.hot.send({type:"custom",event:"valaxy:pageData",data:P}),wt.success(`${(0,en.yellow)("[HMR]")} ${u} ${(0,en.dim)(`updated in ${v()}`)}`),c.read=()=>$}}}]}async function Qt(e,t={}){let{options:r}=e,{roots:n,config:o}=r,i=await zu(r),s=await cf(r,t);return[i,cu(r),uu(r),Nx({include:[/\.vue$/,/\.md$/],exclude:[],template:{compilerOptions:{isCustomElement:a=>{let c=El.has(a);return o.vue?.isCustomElement?.forEach(u=>{c=c||u(a)}),c}}},...o.vue}),s,Fx(),await Xu(e),Mx({layoutsDirs:n.map(a=>`${a}/layouts`),...o.layouts}),Ix({extensions:["vue","md"],include:[/\.vue$/,/\.vue\?vue/,/\.md$/],exclude:[],allowOverrides:!0,dirs:n.map(a=>`${a}/components`).concat(["src/components","components"]),dts:Dx(r.tempDir,"components.d.ts"),...o.components}),await iu(r),Lx({runtimeOnly:!0,compositionOnly:!0,include:n.map(a=>`${a}/locales/**`),jitCompilation:!1}),fu(r)]}async function mf(e,t={}){let r=pf(t,{plugins:await Qt(e)});await Vx(r)}async function gf(e,t={}){let{options:r}=e,n={plugins:await Qt(e),ssr:{noExternal:["workbox-window",/vue-i18n/,"@vue/devtools-api"]}};n.ssgOptions={script:"async",formatting:"minify",crittersOptions:{reduceInlineStyles:!1},onFinished(){Hx({hostname:r.config.siteConfig.url})}},r.config.build.ssgForPagination&&(n.ssgOptions.includedRoutes=(i,s)=>{let a=i,c=i.filter(f=>f.startsWith("/posts/")),u=Math.ceil(c.length/r.config.siteConfig.pageSize);rn.info(`Generate ${df.default.yellow(u)} pages for pagination.`);for(let f=1;f<=u;f++)a.push(`/page/${f}`);return r.config.vite?.ssgOptions?.includeAllRoutes?a:a.filter(f=>!f.split("/").some(d=>d.startsWith(":")))});let o=pf(n,t);await jx({},o)}async function hf(e){let{userRoot:t}=e,r=ff(t,"dist/index.html");if(tn.existsSync(r)){rn.info("post process for ssg...");let n=await tn.readFile(r,"utf-8"),o="</html>";if(!n.endsWith(o)){rn.warn("fix incomplete index.html...");let i=n.lastIndexOf(o);await tn.writeFile(r,n.slice(0,i+o.length),"utf-8")}}e.config.siteConfig.redirects?.useVueRouter||await qx(e)}async function qx(e){rn.info("generate client redirects...");let t=ff(e.userRoot,"dist"),n=Br(e.redirects).map(async o=>{let i=uf(t,`${o.from}.html`),s=uf(t,`${o.to}.html`);if(!await tn.pathExists(s))throw new Error(`the route of '${o.to}' not exists`);await Vc(o.to,i)});await Promise.all(n)}l();l();l();l();import yf from"node:process";import{createServer as Bx,mergeConfig as Ux}from"vite";async function vf(e,t={},r={}){yf.env.EDITOR=yf.env.EDITOR||"code";let{options:n}=e,o=await Qt(e,r),i=n.mode==="dev"&&n.config.devtools,s=[...o];i&&s.push((await import("vite-plugin-vue-devtools")).default(),(await import("@valaxyjs/devtools")).default());let a=Ux(t,{plugins:s});return await Bx(a)}l();l();import{createHooks as Wx}from"hookable";var Gx=["build:before","build:after"];function nn(e){let t=Wx();typeof e.config.hooks=="object"&&Object.keys(e.config.hooks).forEach(n=>{let o=n,i=e.config.hooks[o];typeof i=="function"&&(Gx.includes(o)?e.mode==="build"&&t.hook(o,i):t.hook(o,i))});let r={version:ft,hooks:t,hook:t.hook,options:e};return e.addons.forEach(n=>{typeof n.setup=="function"&&n.setup(r)}),r}l();var U=ee(le(),1);import*as xf from"node:readline";import Kx from"node:path";import zx from"node:os";import Je from"node:process";import Yx from"consola";import{mergeConfig as Xx}from"vite";var on;function sn(e,t,r){if(console.log(),console.log(` ${(0,U.bold)("\u{1F30C} Valaxy")} ${(0,U.blue)(`v${ft}`)}`),console.log(),console.log(`${(0,U.dim)(" \u{1FA90} theme ")} > ${e.theme?(0,U.green)(e.theme):(0,U.gray)("none")}`),console.log(` ${(0,U.dim)("\u{1F4C1}")} ${(0,U.dim)(Kx.resolve(e.userRoot))}`),t){console.log(),console.log(`${(0,U.dim)(" Preview ")} > ${(0,U.cyan)(`http://localhost:${(0,U.bold)(t)}/`)}`),r&&Object.values(zx.networkInterfaces()).forEach(c=>(c||[]).filter(u=>u.family==="IPv4"&&!u.address.includes("127.0.0.1")).forEach(({address:u})=>{console.log(`${(0,U.dim)(" Network ")} > ${(0,U.blue)(`http://${u}:${(0,U.bold)(t)}/`)}`)})),console.log();let n=`${(0,U.underline)("r")}${(0,U.dim)("estart")}`,o=`${(0,U.underline)("e")}${(0,U.dim)("dit")}`,i=`${(0,U.underline)("o")}${(0,U.dim)("pen")}`,s=`${(0,U.underline)("q")}${(0,U.dim)("r")}`,a=`${(0,U.dim)(" | ")}`;console.log(`${(0,U.dim)(" shortcuts ")} > ${n}${a}${i}${a}${s}${a}${o}`)}console.log()}async function Jt(e,t){on&&(wt.info("close server..."),await on.close());let{options:r}=e,n=Xx(await Yr(r,"serve"),t);try{on=await vf(e,n,{async onConfigReload(o,i,s=!1){s&&(wt.info(`${(0,U.yellow)("force")} reload the server`),Jt(e,t));let a=!1;o.theme!==i.theme&&(a=!0),a&&Jt(e,t)}}),await on.listen(),wt.ready("server ready")}catch(o){Yx.error(`failed to start server. error:
|
|
102
|
+
`),console.error(o),Je.exit(1)}}function _f(e){Je.stdin.resume(),Je.stdin.setEncoding("utf8"),xf.emitKeypressEvents(Je.stdin),Je.stdin.isTTY&&Je.stdin.setRawMode(!0),Je.stdin.on("keypress",(t,r)=>{if(r.ctrl&&r.name==="c")Je.exit();else{let[n]=e.filter(o=>o.name===t);if(n)try{n.action()}catch(o){console.error(`Failed to execute shortcut ${n.fullName}`,o)}}})}function Rf(e){e.command("build [root]","build your blog to static content",t=>Ke(t).option("ssg",{alias:"s",type:"boolean",default:!1,describe:"static site generate"}).option("output",{alias:"o",type:"string",default:"dist",describe:"output dir"}).option("log",{default:"warn",type:"string",choices:["error","warn","info","silent"],describe:"log level"}).strict().help(),async({ssg:t,root:r,output:n,log:o})=>{St(),Dr(r)||Qx.exit(0);let i=Ti.resolve(r),s=await be({userRoot:i},"build");sn(s);let a=nn(s);Ze.start(`Run ${(0,At.yellow)("options:resolved")} hooks`),await a.hooks.callHook("options:resolved");let c=[];s.config.siteConfig.search.type==="fuse"&&c.push(Gr),s.config.modules.rss.enable&&c.push(Wr),Gc(a,c);let u=bf(await Yr(s,"build"),s.config.vite||{}),f=bf(u,{configFile:Ti.resolve(s.clientRoot,"vite.config.ts"),build:{emptyOutDir:!0,outDir:Ti.resolve(s.userRoot,n)},logLevel:o});Ze.start(`Run ${(0,At.yellow)("config:init")} hooks`),await a.hooks.callHook("config:init"),Ze.start(`Run ${(0,At.yellow)("build:before")} hooks`),await a.hooks.callHook("build:before"),Ze.box("\u{1F320} Start building...");try{if(t){Ze.info(`use ${(0,At.yellow)("vite-ssg")} to do ssg build...`);try{await gf(a,f),await hf(s)}catch(d){Ze.error("[vite-ssg] An internal error occurred."),console.log(d)}}else Ze.info("use vite do spa build..."),await mf(a,f)}catch(d){console.log(d)}finally{Ze.start(`Run ${(0,At.yellow)("build:after")} hooks`),await a.hooks.callHook("build:after")}})}l();import e_ from"node:path";import{exec as t_}from"node:child_process";import r_ from"node:process";import n_ from"node:os";import{mergeConfig as o_}from"vite";import i_ from"qrcode";l();import Jx from"node:net";async function $i(e){return await Zx(e)?e:await $i(e+1)}function Zx(e){return new Promise(t=>{let r=Jx.createServer(n=>{n.write(`Echo server\r
|
|
103
|
+
`),n.pipe(n)});r.listen(e,"0.0.0.0"),r.on("error",()=>{t(!1)}),r.on("listening",()=>{r.close(),t(!0)})})}function Sf(e){e.command("* [root]","Start a local server for Valaxy",t=>Ke(t).option("port",{alias:"p",type:"number",describe:"port"}).option("open",{alias:"o",default:!1,type:"boolean",describe:"open in browser"}).option("remote",{default:!0,type:"boolean",describe:"listen public host and enable remote control"}).option("log",{default:"info",type:"string",choices:["error","warn","info","silent"],describe:"log level"}).strict().help(),async({root:t,port:r,open:n,remote:o,log:i})=>{ii(),Dr(t)||r_.exit(0);let s=r||await $i(4859),a=await be({userRoot:t}),c=nn(a),u=o_({configFile:e_.resolve(a.clientRoot,"vite.config.ts"),server:{watch:{ignored:[`!${a.themeRoot}/**`,`${a.userRoot}/**.md`]},port:s,strictPort:!0,open:n,host:o?"0.0.0.0":"localhost"},logLevel:i},a.config.vite||{});await Jt(c,u),sn(a,s,o),_f([{name:"r",fullName:"restart",action(){Jt(c,u)}},{name:"o",fullName:"open",async action(){let{default:d}=await import("open");d(`http://localhost:${s}`)}},{name:"q",fullName:"qr",action(){let p=`http://${Object.values(n_.networkInterfaces()).flat().filter(y=>y?.family==="IPv4"&&!y.address.includes("127.0.0.1"))[0]?.address||"localhost"}:${s}`;i_.toString(p,{type:"terminal"},(y,v)=>{if(y)throw y;console.log(v)})}},{name:"e",fullName:"edit",action(){t_(`code "${t}"`)}}])})}var Zt=a_(l_(s_.argv)).scriptName("valaxy").usage("$0 [args]").version(ft).showHelpOnFail(!1).alias("h","help").alias("v","version");Sf(Zt);Rf(Zt);tu(Zt);var c_=[Gr,Wr];c_.forEach(e=>{e.extendCli?.(Zt)});function eT(){Zt.help().parse()}export{It as a,wl as b,xt as c,Cl as d,iR as e,El as f,Oe as g,xc as h,Mh as i,oi as j,X as k,_c as l,bc as m,jh as n,_t as o,Lr as p,CS as q,qh as r,Fr as s,Cc as t,Kh as u,LS as v,qt as w,st as x,Ec as y,Xh as z,qS as A,kc as B,Vr as C,Oc as D,ty as E,ow as F,aw as G,ai as H,be as I,li as J,Yr as K,su as L,cf as M,Qt as N,mf as O,gf as P,hf as Q,qx as R,vf as S,Zt as T,eT as U};
|
|
104
|
+
/*! Bundled license information:
|
|
105
|
+
|
|
106
|
+
is-extglob/index.js:
|
|
107
|
+
(*!
|
|
108
|
+
* is-extglob <https://github.com/jonschlinkert/is-extglob>
|
|
109
|
+
*
|
|
110
|
+
* Copyright (c) 2014-2016, Jon Schlinkert.
|
|
111
|
+
* Licensed under the MIT License.
|
|
112
|
+
*)
|
|
113
|
+
|
|
114
|
+
is-glob/index.js:
|
|
115
|
+
(*!
|
|
116
|
+
* is-glob <https://github.com/jonschlinkert/is-glob>
|
|
117
|
+
*
|
|
118
|
+
* Copyright (c) 2014-2017, Jon Schlinkert.
|
|
119
|
+
* Released under the MIT License.
|
|
120
|
+
*)
|
|
121
|
+
|
|
122
|
+
is-number/index.js:
|
|
123
|
+
(*!
|
|
124
|
+
* is-number <https://github.com/jonschlinkert/is-number>
|
|
125
|
+
*
|
|
126
|
+
* Copyright (c) 2014-present, Jon Schlinkert.
|
|
127
|
+
* Released under the MIT License.
|
|
128
|
+
*)
|
|
129
|
+
|
|
130
|
+
to-regex-range/index.js:
|
|
131
|
+
(*!
|
|
132
|
+
* to-regex-range <https://github.com/micromatch/to-regex-range>
|
|
133
|
+
*
|
|
134
|
+
* Copyright (c) 2015-present, Jon Schlinkert.
|
|
135
|
+
* Released under the MIT License.
|
|
136
|
+
*)
|
|
137
|
+
|
|
138
|
+
fill-range/index.js:
|
|
139
|
+
(*!
|
|
140
|
+
* fill-range <https://github.com/jonschlinkert/fill-range>
|
|
141
|
+
*
|
|
142
|
+
* Copyright (c) 2014-present, Jon Schlinkert.
|
|
143
|
+
* Licensed under the MIT License.
|
|
144
|
+
*)
|
|
145
|
+
|
|
146
|
+
queue-microtask/index.js:
|
|
147
|
+
(*! queue-microtask. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> *)
|
|
148
|
+
|
|
149
|
+
run-parallel/index.js:
|
|
150
|
+
(*! run-parallel. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> *)
|
|
151
|
+
|
|
152
|
+
@mdit-vue/shared/dist/index.mjs:
|
|
153
|
+
(* istanbul ignore if -- @preserve *)
|
|
154
|
+
|
|
155
|
+
@mdit-vue/plugin-sfc/dist/index.mjs:
|
|
156
|
+
(* istanbul ignore if -- @preserve *)
|
|
157
|
+
*/
|