@visulima/ono 1.0.4 → 1.0.6
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/CHANGELOG.md +26 -0
- package/dist/error-inspector/page/create-request-context.js +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +107 -107
- package/dist/packem_shared/clipboard-BeHvxj0X.js +1 -0
- package/dist/server/open-in-editor.d.ts +2 -1
- package/dist/server/open-in-editor.js +3 -3
- package/package.json +33 -34
- package/dist/packem_shared/clipboard-CI3XgYla.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var f=Object.defineProperty;var m=(t,e)=>f(t,"name",{value:e,configurable:!0});import{createRequire as D}from"node:module";const v=D(import.meta.url),H=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process;const p=v("isomorphic-dompurify");var y=Object.defineProperty,i=m((t,e)=>y(t,"name",{value:e,configurable:!0}),"e");const w=["http://","https://","/","./","../"],u="#",b={'"':""","&":"&","'":"'","<":"<",">":">"},C=/^[\w+/-]+={0,2}$/,n=i(t=>String(t??"").trim(),"toString"),h=i(t=>t.replaceAll(/[&<>"']/g,e=>b[e]),"escapeHtml"),z=i(t=>{try{return p.sanitize(n(t))}catch{return h(n(t))}},"sanitizeHtml"),A=i(t=>{const e=n(t);if(!e)return"";try{return p.sanitize(e).replaceAll('"',""").replaceAll("'","'")}catch{return h(e)}},"sanitizeAttribute"),j=i(t=>{const e=n(t);if(!e)return u;try{const r=p.sanitize(e),s=r.toLowerCase();return w.some(a=>s.startsWith(a))?r:u}catch{return u}},"sanitizeUrlAttribute"),q=i(t=>{const e=n(t);if(!e)return"";try{return p.sanitize(e,{ADD_ATTR:["class","style"]})}catch{return z(e)}},"sanitizeCodeHtml"),F=i(t=>{const e=n(t);if(e)return C.test(e)?e:void 0},"sanitizeCspNonce"),N=i((t={})=>{if(!t||typeof t!="object")return{};try{return{...t,cspNonce:F(t.cspNonce),openInEditorUrl:t.openInEditorUrl?j(t.openInEditorUrl):void 0}}catch{return{...t,cspNonce:void 0,openInEditorUrl:void 0}}},"sanitizeOptions");var x=Object.defineProperty,o=m((t,e)=>x(t,"name",{value:e,configurable:!0}),"r");let c,l;const _=o(async(t=[])=>{try{const[e,r]=await Promise.all([import("shiki/core"),import("shiki/engine/javascript")]),{createHighlighterCore:s}=e,{createJavaScriptRegexEngine:a}=r,d=await s({themes:[import("@shikijs/themes/github-dark-default"),import("@shikijs/themes/github-light")],langs:[import("@shikijs/langs/javascript"),import("@shikijs/langs/typescript"),import("@shikijs/langs/jsx"),import("@shikijs/langs/tsx"),import("@shikijs/langs/json"),import("@shikijs/langs/jsonc"),import("@shikijs/langs/xml"),import("@shikijs/langs/sql"),import("@shikijs/langs/bash"),import("@shikijs/langs/shell"),import("@shikijs/langs/markdown"),import("@shikijs/langs/mdx"),import("@shikijs/langs/html"),import("@shikijs/langs/css"),import("@shikijs/langs/scss"),import("@shikijs/langs/less"),import("@shikijs/langs/sass"),import("@shikijs/langs/stylus"),import("@shikijs/langs/styl"),...t],engine:a()}),g=d;return l=o(()=>{try{d?.dispose?.()}catch{}c=void 0},"disposeFn"),g}catch{const{createHighlighter:e}=await import("shiki"),r=await e({langs:["javascript","typescript","jsx","tsx","json","jsonc","xml","sql","bash","shell","markdown","mdx"],themes:["github-dark-default","github-light"]});return l=o(()=>{try{r?.dispose?.()}catch{}c=void 0},"disposeFn"),r}},"createSingletonHighlighter"),T=o(async(t=[])=>(c||(c=_(t)),c),"getHighlighter");o(async()=>{try{l&&(l(),l=void 0)}catch{}},"disposeHighlighter");o((t=[])=>({name:"@shikijs/transformers:compact-line-options",line(e,r){const s=t.find(a=>a.line===r);return s?.classes&&this.addClassToHast(e,s.classes),e}}),"transformerCompactLineOptions");const U="data:image/svg+xml;charset=utf-8,%3Csvg%20class%3D%22lucide%20lucide-check%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22currentColor%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%20%3E%20%3Cpath%20d%3D%22M20%206%209%2017l-5-5%22%20%2F%3E%20%3C%2Fsvg%3E",$="data:image/svg+xml;charset=utf-8,%3Csvg%20class%3D%22lucide%20lucide-clipboard%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22currentColor%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%20%3E%20%3Crect%20width%3D%228%22%20height%3D%224%22%20x%3D%228%22%20y%3D%222%22%20rx%3D%221%22%20ry%3D%221%22%20%2F%3E%20%3Cpath%20d%3D%22M16%204h2a2%202%200%200%201%202%202v14a2%202%200%200%201-2%202H6a2%202%200%200%201-2-2V6a2%202%200%200%201%202-2h2%22%20%2F%3E%20%3C%2Fsvg%3E";export{A as a,F as b,T as c,j as d,U as e,N as f,q as g,$ as n,z as s};
|
|
@@ -15,4 +15,5 @@ declare const createOpenInEditorMiddleware: (options?: OpenInEditorOptions) => U
|
|
|
15
15
|
declare const createNodeHttpHandler: (options?: OpenInEditorOptions) => NodeHttpHandler;
|
|
16
16
|
declare const createExpressHandler: (options?: OpenInEditorOptions) => UniversalHandler;
|
|
17
17
|
|
|
18
|
-
export {
|
|
18
|
+
export { createExpressHandler, createNodeHttpHandler, createOpenInEditorMiddleware };
|
|
19
|
+
export type { OpenInEditorOptions };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
var Kt=Object.defineProperty;var v=(t,n)=>Kt(t,"name",{value:n,configurable:!0});import{realpathSync as Te}from"node:fs";import le from"path";import Xt from"fs";import er from"os";import Ye from"child_process";import tr from"url";import{a as _e}from"../packem_shared/process-B37didfB.js";var rr=Object.defineProperty,ye=v((t,n)=>rr(t,"name",{value:n,configurable:!0}),"I"),nr=Object.defineProperty,h=ye((t,n)=>nr(t,"name",{value:n,configurable:!0}),"__name$2");let qe=h(()=>{var t=(()=>{var n=Object.defineProperty,s=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,c=Object.prototype.hasOwnProperty,p=h((e,r)=>{for(var a in r)n(e,a,{get:r[a],enumerable:!0})},"J"),d=h((e,r,a,u)=>{if(r&&typeof r=="object"||typeof r=="function")for(let l of i(r))!c.call(e,l)&&l!==a&&n(e,l,{get:h(()=>r[l],"get"),enumerable:!(u=s(r,l))||u.enumerable});return e},"T"),b=h(e=>d(n({},"__esModule",{value:!0}),e),"W"),B={};p(B,{zeptomatch:h(()=>Vt,"zeptomatch")});var f=h(e=>Array.isArray(e),"k"),o=h(e=>typeof e=="function","x"),g=h(e=>e.length===0,"K"),w=(()=>{const{toString:e}=Function.prototype,r=/(?:^\(\s*(?:[^,.()]|\.(?!\.\.))*\s*\)\s*=>|^\s*[a-zA-Z$_][a-zA-Z0-9$_]*\s*=>)/;return a=>(a.length===0||a.length===1)&&r.test(e.call(a))})(),C=h(e=>typeof e=="number","Y"),R=h(e=>typeof e=="object"&&e!==null,"rr"),P=h(e=>e instanceof RegExp,"er"),T=(()=>{const e=/\\\(|\((?!\?(?::|=|!|<=|<!))/;return r=>e.test(r.source)})(),M=(()=>{const e=/^[a-zA-Z0-9_-]+$/;return r=>e.test(r.source)&&!r.flags.includes("i")})(),I=h(e=>typeof e=="string","M"),x=h(e=>e===void 0,"f"),L=h(e=>{const r=new Map;return a=>{const u=r.get(a);if(u!==void 0)return u;const l=e(a);return r.set(a,l),l}},"ar"),E=h((e,r,a={})=>{const u={cache:{},input:e,index:0,indexBacktrackMax:0,options:a,output:[]},l=N(r)(u),S=Math.max(u.index,u.indexBacktrackMax);if(l&&u.index===e.length)return u.output;throw new Error(`Failed to parse at index ${S}`)},"or"),m=h((e,r)=>f(e)?z(e,r):I(e)?y(e,r):_(e,r),"o"),z=h((e,r)=>{const a={};for(const u of e){if(u.length!==1)throw new Error(`Invalid character: "${u}"`);const l=u.charCodeAt(0);a[l]=!0}return u=>{const l=u.input;let S=u.index,A=S;for(;A<l.length&&l.charCodeAt(A)in a;)A+=1;if(A>S){if(!x(r)&&!u.options.silent){const j=l.slice(S,A),G=o(r)?r(j,l,`${S}`):r;x(G)||u.output.push(G)}u.index=A}return!0}},"ir"),_=h((e,r)=>{if(M(e))return y(e.source,r);{const a=e.source,u=e.flags.replace(/y|$/,"y"),l=new RegExp(a,u);return T(e)&&o(r)&&!w(r)?D(l,r):W(l,r)}},"ur"),D=h((e,r)=>a=>{const u=a.index,l=a.input;e.lastIndex=u;const S=e.exec(l);if(S){const A=e.lastIndex;if(!a.options.silent){const j=r(...S,l,`${u}`);x(j)||a.output.push(j)}return a.index=A,!0}else return!1},"sr"),W=h((e,r)=>a=>{const u=a.index,l=a.input;if(e.lastIndex=u,e.test(l)){const S=e.lastIndex;if(!x(r)&&!a.options.silent){const A=o(r)?r(l.slice(u,S),l,`${u}`):r;x(A)||a.output.push(A)}return a.index=S,!0}else return!1},"cr"),y=h((e,r)=>a=>{const u=a.index,l=a.input;if(l.startsWith(e,u)){if(!x(r)&&!a.options.silent){const S=o(r)?r(e,l,`${u}`):r;x(S)||a.output.push(S)}return a.index+=e.length,!0}else return!1},"R"),V=h((e,r,a,u)=>{const l=N(e),S=r>1;return X($(K(A=>{let j=0;for(;j<a;){const G=A.index;if(!l(A)||(j+=1,A.index===G))break}return j>=r},S),u))},"O"),re=h((e,r)=>V(e,0,1,r),"lr"),q=h((e,r)=>V(e,0,1/0,r),"m"),H=h((e,r)=>{const a=e.map(N);return X($(K(u=>{for(let l=0,S=a.length;l<S;l++)if(!a[l](u))return!1;return!0}),r))},"_"),O=h((e,r)=>{const a=e.map(N);return X($(u=>{for(let l=0,S=a.length;l<S;l++)if(a[l](u))return!0;return!1},r))},"p"),K=h((e,r=!0,a=!1)=>{const u=N(e);return r?l=>{const S=l.index,A=l.output.length,j=u(l);return!j&&!a&&(l.indexBacktrackMax=Math.max(l.indexBacktrackMax,l.index)),(!j||a)&&(l.index=S,l.output.length!==A&&(l.output.length=A)),j}:u},"P"),$=h((e,r)=>{const a=N(e);return r?u=>{if(u.options.silent)return a(u);const l=u.output.length;if(a(u)){const S=u.output.splice(l,1/0),A=r(S);return x(A)||u.output.push(A),!0}else return!1}:a},"C"),X=(()=>{let e=0;return r=>{const a=N(r),u=e+=1;return l=>{var S;if(l.options.memoization===!1)return a(l);const A=l.index,j=(S=l.cache)[u]||(S[u]={indexMax:-1,queue:[]}),G=j.queue;if(A<=j.indexMax){const ne=j.store||(j.store=new Map);if(G.length){for(let te=0,Ht=G.length;te<Ht;te+=2){const Jt=G[te*2],Yt=G[te*2+1];ne.set(Jt,Yt)}G.length=0}const Q=ne.get(A);if(Q===!1)return!1;if(C(Q))return l.index=Q,!0;if(Q)return l.index=Q.index,Q.output?.length&&l.output.push(...Q.output),!0}const je=l.output.length,Zt=a(l);if(j.indexMax=Math.max(j.indexMax,A),Zt){const ne=l.index,Q=l.output.length;if(Q>je){const te=l.output.slice(je,Q);G.push(A,{index:ne,output:te})}else G.push(A,ne);return!0}else return G.push(A,!1),!1}}})(),F=h(e=>{let r;return a=>(r||(r=N(e())),r(a))},"A"),N=L(e=>{if(o(e))return g(e)?F(e):e;if(I(e)||P(e))return m(e);if(f(e))return H(e);if(R(e))return O(Object.values(e));throw new Error("Invalid rule")}),U=h(e=>e,"v"),ee=h(e=>r=>E(r,e,{memoization:!1}).join(""),"z"),tt=h(e=>{const r={};return a=>r[a]??(r[a]=e(a))},"pr"),Ce="abcdefghijklmnopqrstuvwxyz",rt=h(e=>{let r="";for(;e>0;){const a=(e-1)%26;r=Ce[a]+r,e=Math.floor((e-1)/26)}return r},"vr"),Se=h(e=>{let r=0;for(let a=0,u=e.length;a<u;a++)r=r*26+Ce.indexOf(e[a])+1;return r},"N"),ue=h((e,r)=>{if(r<e)return ue(r,e);const a=[];for(;e<=r;)a.push(e++);return a},"$"),nt=h((e,r,a)=>ue(e,r).map(u=>String(u).padStart(a,"0")),"fr"),Ae=h((e,r)=>ue(Se(e),Se(r)).map(rt),"j"),pe=m(/\\./,U),ot=m(/[$.*+?^(){}[\]\|]/,e=>`\\${e}`),it=m(/./,U),at=m(/^(?:!!)*!(.*)$/,(e,r)=>`(?!^${Ie(r)}$).*?`),st=m(/^(!!)+/,""),ct=O([at,st]),lt=m(/\/(\*\*\/)+/,"(?:[\\\\/].+[\\\\/]|[\\\\/])"),ut=m(/^(\*\*\/)+/,"(?:^|.*[\\\\/])"),pt=m(/\/(\*\*)$/,"(?:[\\\\/].*|$)"),mt=m(/\*\*/,".*"),$e=O([lt,ut,pt,mt]),dt=m(/\*\/(?!\*\*\/|\*$)/,"[^\\\\/]*[\\\\/]"),ft=m(/\*/,"[^\\\\/]*"),we=O([dt,ft]),Me=m("?","[^\\\\/]"),ht=m("[",U),xt=m("]",U),gt=m(/[!^]/,"^\\\\/"),bt=m(/[a-z]-[a-z]|[0-9]-[0-9]/i,U),vt=m(/[$.*+?^(){}[\|]/,e=>`\\${e}`),Bt=m(/[^\]]/,U),Ot=O([pe,vt,bt,Bt]),Ee=H([ht,re(gt),q(Ot),xt]),yt=m("{","(?:"),Ct=m("}",")"),St=m(/(\d+)\.\.(\d+)/,(e,r,a)=>nt(+r,+a,Math.min(r.length,a.length)).join("|")),At=m(/([a-z]+)\.\.([a-z]+)/,(e,r,a)=>Ae(r,a).join("|")),$t=m(/([A-Z]+)\.\.([A-Z]+)/,(e,r,a)=>Ae(r.toLowerCase(),a.toLowerCase()).join("|").toUpperCase()),wt=O([St,At,$t]),Pe=H([yt,wt,Ct]),Mt=m("{","(?:"),Et=m("}",")"),Pt=m(",","|"),Rt=m(/[$.*+?^(){[\]\|]/,e=>`\\${e}`),It=m(/[^}]/,U),jt=F(()=>Re),Tt=O([$e,we,Me,Ee,Pe,jt,pe,Rt,Pt,It]),Re=H([Mt,q(Tt),Et]),_t=q(O([ct,$e,we,Me,Ee,Pe,Re,pe,ot,it])),qt=_t,Lt=ee(qt),Ie=Lt,Nt=m(/\\./,U),kt=m(/./,U),zt=m(/\*\*\*+/,"*"),Dt=m(/([^/{[(!])\*\*/,(e,r)=>`${r}*`),Wt=m(/(^|.)\*\*(?=[^*/)\]}])/,(e,r)=>`${r}*`),Ut=q(O([Nt,zt,Dt,Wt,kt])),Gt=Ut,Ft=ee(Gt),Qt=Ft,oe=h((e,r)=>Array.isArray(e)?e.map(oe.compile).some(a=>a.test(r)):oe.compile(e).test(r),"S");oe.compile=tt(e=>new RegExp(`^${Ie(Qt(e))}[\\\\/]?$`,"s"));var Vt=oe;return b(B)})();return t.default||t},"_lazyMatch"),me;const or=h((t,n)=>(me||(me=qe(),qe=null),me(t,n)),"default");var ir=Object.defineProperty,ar=ye((t,n)=>ir(t,"name",{value:n,configurable:!0}),"__name$1");const sr=/^[A-Z]:\//i,Y=ar((t="")=>t&&t.replaceAll("\\","/").replace(sr,n=>n.toUpperCase()),"normalizeWindowsPath");var cr=Object.defineProperty,k=ye((t,n)=>cr(t,"name",{value:n,configurable:!0}),"__name");const lr=/^[/\\]{2}/,ur=/^[/\\](?![/\\])|^[/\\]{2}(?!\.)|^[A-Z]:[/\\]/i,Ke=/^[A-Z]:$/i,Le=/^\/([A-Z]:)?$/i,pr=/.(\.[^./]+)$/,mr=/^[/\\]|^[a-z]:[/\\]/i,dr=k(()=>typeof process.cwd=="function"?process.cwd().replaceAll("\\","/"):"/","cwd"),Ne="/",Xe=k((t,n)=>{let s="",i=0,c=-1,p=0,d=null;for(let b=0;b<=t.length;++b){if(b<t.length)d=t[b];else{if(d==="/")break;d="/"}if(d==="/"){if(!(c===b-1||p===1))if(p===2){if(s.length<2||i!==2||!s.endsWith(".")||s.at(-2)!=="."){if(s.length>2){const B=s.lastIndexOf("/");B===-1?(s="",i=0):(s=s.slice(0,B),i=s.length-1-s.lastIndexOf("/")),c=b,p=0;continue}else if(s.length>0){s="",i=0,c=b,p=0;continue}}n&&(s+=s.length>0?"/..":"..",i=2)}else s.length>0?s+=`/${t.slice(c+1,b)}`:s=t.slice(c+1,b),i=b-c-1;c=b,p=0}else d==="."&&p!==-1?++p:p=-1}return s},"normalizeString"),J=k(t=>ur.test(t),"isAbsolute"),se=k(function(t){if(t.length===0)return".";t=Y(t);const n=lr.exec(t),s=J(t),i=t.at(-1)==="/";return t=Xe(t,!s),t.length===0?s?"/":i?"./":".":(i&&(t+="/"),Ke.test(t)&&(t+="/"),n?s?`//${t}`:`//./${t}`:s&&!J(t)?`/${t}`:t)},"normalize");k((...t)=>{let n="";for(const s of t)if(s)if(n.length>0){const i=n[n.length-1]==="/",c=s[0]==="/";i&&c?n+=s.slice(1):n+=i||c?s:`/${s}`}else n+=s;return se(n)},"join");const ce=k(function(...t){t=t.map(i=>Y(i));let n="",s=!1;for(let i=t.length-1;i>=-1&&!s;i--){const c=i>=0?t[i]:dr();!c||c.length===0||(n=`${c}/${n}`,s=J(c))}return n=Xe(n,!s),s&&!J(n)?`/${n}`:n.length>0?n:"."},"resolve");k(function(t){return Y(t)},"toNamespacedPath");const fr=k(function(t){return pr.exec(Y(t))?.[1]??""},"extname"),hr=k(function(t,n){const s=ce(t).replace(Le,"$1").split("/"),i=ce(n).replace(Le,"$1").split("/");if(i[0][1]===":"&&s[0][1]===":"&&s[0]!==i[0])return i.join("/");const c=[...s];for(const p of c){if(i[0]!==p)break;s.shift(),i.shift()}return[...s.map(()=>".."),...i].join("/")},"relative"),xr=k(t=>{const n=Y(t).replace(/\/$/,"").split("/").slice(0,-1);return n.length===1&&Ke.test(n[0])&&(n[0]+="/"),n.join("/")||(J(t)?"/":".")},"dirname");k(function(t){const n=[t.root,t.dir,t.base??t.name+t.ext].filter(Boolean);return Y(t.root?ce(...n):n.join("/"))},"format");const gr=k((t,n)=>{const s=Y(t).split("/").pop();return n&&s.endsWith(n)?s.slice(0,-n.length):s},"basename");k(function(t){const n=mr.exec(t)?.[0]?.replace(/\\/g,"/")??"",s=gr(t),i=fr(s);return{base:s,dir:xr(t),ext:i,name:s.slice(0,s.length-i.length),root:n}},"parse");k((t,n)=>or(n,se(t)),"matchesGlob");function br(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}v(br,"getDefaultExportFromCjs");var ie={exports:{}},ke;function vr(){if(ke)return ie.exports;ke=1;var t=Object.defineProperty,n=v((f,o)=>t(f,"name",{value:o,configurable:!0}),"t");let s=process||{},i=s.argv||[],c=s.env||{},p=!(c.NO_COLOR||i.includes("--no-color"))&&(!!c.FORCE_COLOR||i.includes("--color")||s.platform==="win32"||(s.stdout||{}).isTTY&&c.TERM!=="dumb"||!!c.CI),d=n((f,o,g=f)=>w=>{let C=""+w,R=C.indexOf(o,f.length);return~R?f+b(C,o,g,R)+o:f+C+o},"formatter"),b=n((f,o,g,w)=>{let C="",R=0;do C+=f.substring(R,w)+g,R=w+o.length,w=f.indexOf(o,R);while(~w);return C+f.substring(R)},"replaceClose"),B=n((f=p)=>{let o=f?d:()=>String;return{isColorSupported:f,reset:o("\x1B[0m","\x1B[0m"),bold:o("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:o("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:o("\x1B[3m","\x1B[23m"),underline:o("\x1B[4m","\x1B[24m"),inverse:o("\x1B[7m","\x1B[27m"),hidden:o("\x1B[8m","\x1B[28m"),strikethrough:o("\x1B[9m","\x1B[29m"),black:o("\x1B[30m","\x1B[39m"),red:o("\x1B[31m","\x1B[39m"),green:o("\x1B[32m","\x1B[39m"),yellow:o("\x1B[33m","\x1B[39m"),blue:o("\x1B[34m","\x1B[39m"),magenta:o("\x1B[35m","\x1B[39m"),cyan:o("\x1B[36m","\x1B[39m"),white:o("\x1B[37m","\x1B[39m"),gray:o("\x1B[90m","\x1B[39m"),bgBlack:o("\x1B[40m","\x1B[49m"),bgRed:o("\x1B[41m","\x1B[49m"),bgGreen:o("\x1B[42m","\x1B[49m"),bgYellow:o("\x1B[43m","\x1B[49m"),bgBlue:o("\x1B[44m","\x1B[49m"),bgMagenta:o("\x1B[45m","\x1B[49m"),bgCyan:o("\x1B[46m","\x1B[49m"),bgWhite:o("\x1B[47m","\x1B[49m"),blackBright:o("\x1B[90m","\x1B[39m"),redBright:o("\x1B[91m","\x1B[39m"),greenBright:o("\x1B[92m","\x1B[39m"),yellowBright:o("\x1B[93m","\x1B[39m"),blueBright:o("\x1B[94m","\x1B[39m"),magentaBright:o("\x1B[95m","\x1B[39m"),cyanBright:o("\x1B[96m","\x1B[39m"),whiteBright:o("\x1B[97m","\x1B[39m"),bgBlackBright:o("\x1B[100m","\x1B[49m"),bgRedBright:o("\x1B[101m","\x1B[49m"),bgGreenBright:o("\x1B[102m","\x1B[49m"),bgYellowBright:o("\x1B[103m","\x1B[49m"),bgBlueBright:o("\x1B[104m","\x1B[49m"),bgMagentaBright:o("\x1B[105m","\x1B[49m"),bgCyanBright:o("\x1B[106m","\x1B[49m"),bgWhiteBright:o("\x1B[107m","\x1B[49m")}},"createColors");return ie.exports=B(),ie.exports.createColors=B,ie.exports}v(vr,"requirePicocolors");var ae={},de,ze;function Br(){if(ze)return de;ze=1;var t=Object.defineProperty,n=v((s,i)=>t(s,"name",{value:i,configurable:!0}),"n");return de=n(function(s){return s.map(function(i){return i===""?"''":i&&typeof i=="object"?i.op.replace(/(.)/g,"\\$1"):/["\s\\]/.test(i)&&!/'/.test(i)?"'"+i.replace(/(['])/g,"\\$1")+"'":/["'\s]/.test(i)?'"'+i.replace(/(["\\$`!])/g,"\\$1")+'"':String(i).replace(/([A-Za-z]:)?([#!"$&'()*,:;<=>?@[\\\]^`{|}])/g,"$1\\$2")}).join(" ")},"quote"),de}v(Br,"requireQuote");var fe,De;function Or(){if(De)return fe;De=1;for(var t=Object.defineProperty,n=v((I,x)=>t(I,"name",{value:x,configurable:!0}),"c"),s="(?:"+["\\|\\|","\\&\\&",";;","\\|\\&","\\<\\(","\\<\\<\\<",">>",">\\&","<\\&","[&;()|<>]"].join("|")+")",i=new RegExp("^"+s+"$"),c="|&;()<> \\t",p='"((\\\\"|[^"])*?)"',d="'((\\\\'|[^'])*?)'",b=/^#$/,B="'",f='"',o="$",g="",w=4294967296,C=0;C<4;C++)g+=(w*Math.random()).toString(16);var R=new RegExp("^"+g);function P(I,x){for(var L=x.lastIndex,E=[],m;m=x.exec(I);)E.push(m),x.lastIndex===m.index&&(x.lastIndex+=1);return x.lastIndex=L,E}v(P,"matchAll"),n(P,"matchAll");function T(I,x,L){var E=typeof I=="function"?I(L):I[L];return typeof E>"u"&&L!=""?E="":typeof E>"u"&&(E="$"),typeof E=="object"?x+g+JSON.stringify(E)+g:x+E}v(T,"getVar"),n(T,"getVar");function M(I,x,L){L||(L={});var E=L.escape||"\\",m="(\\"+E+`['"`+c+`]|[^\\s'"`+c+"])+",z=new RegExp(["("+s+")","("+m+"|"+p+"|"+d+")+"].join("|"),"g"),_=P(I,z);if(_.length===0)return[];x||(x={});var D=!1;return _.map(function(W){var y=W[0];if(!y||D)return;if(i.test(y))return{op:y};var V=!1,re=!1,q="",H=!1,O;function K(){O+=1;var F,N,U=y.charAt(O);if(U==="{"){if(O+=1,y.charAt(O)==="}")throw new Error("Bad substitution: "+y.slice(O-2,O+1));if(F=y.indexOf("}",O),F<0)throw new Error("Bad substitution: "+y.slice(O));N=y.slice(O,F),O=F}else if(/[*@#?$!_-]/.test(U))N=U,O+=1;else{var ee=y.slice(O);F=ee.match(/[^\w\d_]/),F?(N=ee.slice(0,F.index),O+=F.index-1):(N=ee,O=y.length)}return T(x,"",N)}for(v(K,"R"),n(K,"parseEnvVar"),O=0;O<y.length;O++){var $=y.charAt(O);if(H=H||!V&&($==="*"||$==="?"),re)q+=$,re=!1;else if(V)$===V?V=!1:V==B?q+=$:$===E?(O+=1,$=y.charAt(O),$===f||$===E||$===o?q+=$:q+=E+$):$===o?q+=K():q+=$;else if($===f||$===B)V=$;else{if(i.test($))return{op:y};if(b.test($)){D=!0;var X={comment:I.slice(W.index+O+1)};return q.length?[q,X]:[X]}else $===E?re=!0:$===o?q+=K():q+=$}}return H?{op:"glob",pattern:q}:q}).reduce(function(W,y){return typeof y>"u"?W:W.concat(y)},[])}return v(M,"parseInternal"),n(M,"parseInternal"),fe=n(function(I,x,L){var E=M(I,x,L);return typeof x!="function"?E:E.reduce(function(m,z){if(typeof z=="object")return m.concat(z);var _=z.split(RegExp("("+g+".*?"+g+")","g"));return _.length===1?m.concat(_[0]):m.concat(_.filter(Boolean).map(function(D){return R.test(D)?JSON.parse(D.split(g)[1]):D}))},[])},"parse"),fe}v(Or,"requireParse");var We;function yr(){return We||(We=1,ae.quote=Br(),ae.parse=Or()),ae}v(yr,"requireShellQuote");var he,Ue;function Cr(){return Ue||(Ue=1,he={"/Applications/Atom.app/Contents/MacOS/Atom":"atom","/Applications/Atom Beta.app/Contents/MacOS/Atom Beta":"/Applications/Atom Beta.app/Contents/MacOS/Atom Beta","/Applications/Brackets.app/Contents/MacOS/Brackets":"brackets","/Applications/Sublime Text.app/Contents/MacOS/Sublime Text":"/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl","/Applications/Sublime Text.app/Contents/MacOS/sublime_text":"/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl","/Applications/Sublime Text 2.app/Contents/MacOS/Sublime Text 2":"/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/subl","/Applications/Sublime Text Dev.app/Contents/MacOS/Sublime Text":"/Applications/Sublime Text Dev.app/Contents/SharedSupport/bin/subl","/Applications/Visual Studio Code.app/Contents/MacOS/Electron":"code","/Applications/Visual Studio Code - Insiders.app/Contents/MacOS/Electron":"code-insiders","/Applications/VSCodium.app/Contents/MacOS/Electron":"codium","/Applications/Cursor.app/Contents/MacOS/Cursor":"cursor","/Applications/Trae.app/Contents/MacOS/Electron":"trae","/Applications/AppCode.app/Contents/MacOS/appcode":"/Applications/AppCode.app/Contents/MacOS/appcode","/Applications/CLion.app/Contents/MacOS/clion":"/Applications/CLion.app/Contents/MacOS/clion","/Applications/IntelliJ IDEA.app/Contents/MacOS/idea":"/Applications/IntelliJ IDEA.app/Contents/MacOS/idea","/Applications/IntelliJ IDEA Ultimate.app/Contents/MacOS/idea":"/Applications/IntelliJ IDEA Ultimate.app/Contents/MacOS/idea","/Applications/IntelliJ IDEA Community Edition.app/Contents/MacOS/idea":"/Applications/IntelliJ IDEA Community Edition.app/Contents/MacOS/idea","/Applications/PhpStorm.app/Contents/MacOS/phpstorm":"/Applications/PhpStorm.app/Contents/MacOS/phpstorm","/Applications/PyCharm.app/Contents/MacOS/pycharm":"/Applications/PyCharm.app/Contents/MacOS/pycharm","/Applications/PyCharm CE.app/Contents/MacOS/pycharm":"/Applications/PyCharm CE.app/Contents/MacOS/pycharm","/Applications/RubyMine.app/Contents/MacOS/rubymine":"/Applications/RubyMine.app/Contents/MacOS/rubymine","/Applications/WebStorm.app/Contents/MacOS/webstorm":"/Applications/WebStorm.app/Contents/MacOS/webstorm","/Applications/MacVim.app/Contents/MacOS/MacVim":"mvim","/Applications/GoLand.app/Contents/MacOS/goland":"/Applications/GoLand.app/Contents/MacOS/goland","/Applications/Rider.app/Contents/MacOS/rider":"/Applications/Rider.app/Contents/MacOS/rider","/Applications/Zed.app/Contents/MacOS/zed":"zed"}),he}v(Cr,"requireMacos");var xe,Ge;function Sr(){return Ge||(Ge=1,xe={atom:"atom",Brackets:"brackets","code-insiders":"code-insiders",code:"code",vscodium:"vscodium",codium:"codium",trae:"trae",emacs:"emacs",gvim:"gvim",idea:"idea","idea.sh":"idea",phpstorm:"phpstorm","phpstorm.sh":"phpstorm",pycharm:"pycharm","pycharm.sh":"pycharm",rubymine:"rubymine","rubymine.sh":"rubymine",sublime_text:"subl",vim:"vim",webstorm:"webstorm","webstorm.sh":"webstorm",goland:"goland","goland.sh":"goland",rider:"rider","rider.sh":"rider",zed:"zed"}),xe}v(Sr,"requireLinux");var ge,Fe;function Ar(){return Fe||(Fe=1,ge=["Brackets.exe","Code.exe","Code - Insiders.exe","VSCodium.exe","Cursor.exe","atom.exe","sublime_text.exe","notepad++.exe","clion.exe","clion64.exe","idea.exe","idea64.exe","phpstorm.exe","phpstorm64.exe","pycharm.exe","pycharm64.exe","rubymine.exe","rubymine64.exe","webstorm.exe","webstorm64.exe","goland.exe","goland64.exe","rider.exe","rider64.exe","trae.exe"]),ge}v(Ar,"requireWindows");var be,Qe;function $r(){if(Qe)return be;Qe=1;var t=Object.defineProperty,n=v((B,f)=>t(B,"name",{value:f,configurable:!0}),"u");const s=le,i=yr(),c=Ye,p=Cr(),d=Sr(),b=Ar();return be=n(function(B){if(B)return i.parse(B);if(process.env.LAUNCH_EDITOR)return[process.env.LAUNCH_EDITOR];if(process.versions.webcontainer)return[process.env.EDITOR||"code"];try{if(process.platform==="darwin"){const f=c.execSync("ps x -o comm=",{stdio:["pipe","pipe","ignore"]}).toString(),o=Object.keys(p),g=f.split(`
|
|
2
|
-
`);for(let w=0;w<o.length;w++){const C=o[w];if(g.includes(C))return[p[C]];const R=C.replace("/Applications","");if(f.indexOf(R)!==-1){if(C!==p[C])return[p[C]];const P=g.find(
|
|
3
|
-
`);for(let o=0;o<f.length;o++){const g=f[o].trim(),w=s.basename(g);if(b.indexOf(w)!==-1)return[g]}}else if(process.platform==="linux"){const f=c.execSync("ps x --no-heading -o comm --sort=comm",{stdio:["pipe","pipe","ignore"]}).toString(),o=Object.keys(
|
|
1
|
+
var tr=Object.defineProperty;var v=(t,n)=>tr(t,"name",{value:n,configurable:!0});import{createRequire as rr}from"node:module";import{a as Ne}from"../packem_shared/process-B37didfB.js";const nr=rr(import.meta.url),ie=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,re=v(t=>{if(typeof ie<"u"&&ie.versions&&ie.versions.node){const[n,s]=ie.versions.node.split(".").map(Number);if(n>22||n===22&&s>=3||n===20&&s>=16)return ie.getBuiltinModule(t)}return nr(t)},"__cjs_getBuiltinModule"),{realpathSync:qe}=re("node:fs"),pe=re("path"),or=re("fs"),ir=re("os"),Xe=re("child_process"),ar=re("url");var sr=Object.defineProperty,cr=v((t,n)=>sr(t,"name",{value:n,configurable:!0}),"ce"),lr=Object.defineProperty,Se=cr((t,n)=>lr(t,"name",{value:n,configurable:!0}),"C"),ur=Object.defineProperty,h=Se((t,n)=>ur(t,"name",{value:n,configurable:!0}),"u$1");let Le=h(()=>{var t=(()=>{var n=Object.defineProperty,s=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,c=Object.prototype.hasOwnProperty,p=h((e,r)=>{for(var a in r)n(e,a,{get:r[a],enumerable:!0})},"J"),m=h((e,r,a,u)=>{if(r&&typeof r=="object"||typeof r=="function")for(let l of i(r))!c.call(e,l)&&l!==a&&n(e,l,{get:h(()=>r[l],"get"),enumerable:!(u=s(r,l))||u.enumerable});return e},"T"),b=h(e=>m(n({},"__esModule",{value:!0}),e),"W"),B={};p(B,{zeptomatch:h(()=>Jt,"zeptomatch")});var f=h(e=>Array.isArray(e),"k"),o=h(e=>typeof e=="function","x"),g=h(e=>e.length===0,"K"),w=(()=>{const{toString:e}=Function.prototype,r=/(?:^\(\s*(?:[^,.()]|\.(?!\.\.))*\s*\)\s*=>|^\s*[a-zA-Z$_][a-zA-Z0-9$_]*\s*=>)/;return a=>(a.length===0||a.length===1)&&r.test(e.call(a))})(),C=h(e=>typeof e=="number","Y"),R=h(e=>typeof e=="object"&&e!==null,"rr"),P=h(e=>e instanceof RegExp,"er"),_=(()=>{const e=/\\\(|\((?!\?(?::|=|!|<=|<!))/;return r=>e.test(r.source)})(),M=(()=>{const e=/^[a-zA-Z0-9_-]+$/;return r=>e.test(r.source)&&!r.flags.includes("i")})(),j=h(e=>typeof e=="string","M"),x=h(e=>e===void 0,"f"),N=h(e=>{const r=new Map;return a=>{const u=r.get(a);if(u!==void 0)return u;const l=e(a);return r.set(a,l),l}},"ar"),E=h((e,r,a={})=>{const u={cache:{},input:e,index:0,indexBacktrackMax:0,options:a,output:[]},l=L(r)(u),S=Math.max(u.index,u.indexBacktrackMax);if(l&&u.index===e.length)return u.output;throw new Error(`Failed to parse at index ${S}`)},"or"),d=h((e,r)=>f(e)?z(e,r):j(e)?y(e,r):T(e,r),"o"),z=h((e,r)=>{const a={};for(const u of e){if(u.length!==1)throw new Error(`Invalid character: "${u}"`);const l=u.charCodeAt(0);a[l]=!0}return u=>{const l=u.input;let S=u.index,A=S;for(;A<l.length&&l.charCodeAt(A)in a;)A+=1;if(A>S){if(!x(r)&&!u.options.silent){const I=l.slice(S,A),G=o(r)?r(I,l,`${S}`):r;x(G)||u.output.push(G)}u.index=A}return!0}},"ir"),T=h((e,r)=>{if(M(e))return y(e.source,r);{const a=e.source,u=e.flags.replace(/y|$/,"y"),l=new RegExp(a,u);return _(e)&&o(r)&&!w(r)?D(l,r):W(l,r)}},"ur"),D=h((e,r)=>a=>{const u=a.index,l=a.input;e.lastIndex=u;const S=e.exec(l);if(S){const A=e.lastIndex;if(!a.options.silent){const I=r(...S,l,`${u}`);x(I)||a.output.push(I)}return a.index=A,!0}else return!1},"sr"),W=h((e,r)=>a=>{const u=a.index,l=a.input;if(e.lastIndex=u,e.test(l)){const S=e.lastIndex;if(!x(r)&&!a.options.silent){const A=o(r)?r(l.slice(u,S),l,`${u}`):r;x(A)||a.output.push(A)}return a.index=S,!0}else return!1},"cr"),y=h((e,r)=>a=>{const u=a.index,l=a.input;if(l.startsWith(e,u)){if(!x(r)&&!a.options.silent){const S=o(r)?r(e,l,`${u}`):r;x(S)||a.output.push(S)}return a.index+=e.length,!0}else return!1},"R"),V=h((e,r,a,u)=>{const l=L(e),S=r>1;return X($(K(A=>{let I=0;for(;I<a;){const G=A.index;if(!l(A)||(I+=1,A.index===G))break}return I>=r},S),u))},"O"),ne=h((e,r)=>V(e,0,1,r),"lr"),q=h((e,r)=>V(e,0,1/0,r),"m"),H=h((e,r)=>{const a=e.map(L);return X($(K(u=>{for(let l=0,S=a.length;l<S;l++)if(!a[l](u))return!1;return!0}),r))},"S"),O=h((e,r)=>{const a=e.map(L);return X($(u=>{for(let l=0,S=a.length;l<S;l++)if(a[l](u))return!0;return!1},r))},"p"),K=h((e,r=!0,a=!1)=>{const u=L(e);return r?l=>{const S=l.index,A=l.output.length,I=u(l);return!I&&!a&&(l.indexBacktrackMax=Math.max(l.indexBacktrackMax,l.index)),(!I||a)&&(l.index=S,l.output.length!==A&&(l.output.length=A)),I}:u},"P"),$=h((e,r)=>{const a=L(e);return r?u=>{if(u.options.silent)return a(u);const l=u.output.length;if(a(u)){const S=u.output.splice(l,1/0),A=r(S);return x(A)||u.output.push(A),!0}else return!1}:a},"C"),X=(()=>{let e=0;return r=>{const a=L(r),u=e+=1;return l=>{var S;if(l.options.memoization===!1)return a(l);const A=l.index,I=(S=l.cache)[u]||(S[u]={indexMax:-1,queue:[]}),G=I.queue;if(A<=I.indexMax){const oe=I.store||(I.store=new Map);if(G.length){for(let te=0,Kt=G.length;te<Kt;te+=2){const Xt=G[te*2],er=G[te*2+1];oe.set(Xt,er)}G.length=0}const Q=oe.get(A);if(Q===!1)return!1;if(C(Q))return l.index=Q,!0;if(Q)return l.index=Q.index,Q.output?.length&&l.output.push(...Q.output),!0}const Te=l.output.length,Yt=a(l);if(I.indexMax=Math.max(I.indexMax,A),Yt){const oe=l.index,Q=l.output.length;if(Q>Te){const te=l.output.slice(Te,Q);G.push(A,{index:oe,output:te})}else G.push(A,oe);return!0}else return G.push(A,!1),!1}}})(),F=h(e=>{let r;return a=>(r||(r=L(e())),r(a))},"A"),L=N(e=>{if(o(e))return g(e)?F(e):e;if(j(e)||P(e))return d(e);if(f(e))return H(e);if(R(e))return O(Object.values(e));throw new Error("Invalid rule")}),U=h(e=>e,"v"),ee=h(e=>r=>E(r,e,{memoization:!1}).join(""),"z"),nt=h(e=>{const r={};return a=>r[a]??(r[a]=e(a))},"pr"),Ae="abcdefghijklmnopqrstuvwxyz",ot=h(e=>{let r="";for(;e>0;){const a=(e-1)%26;r=Ae[a]+r,e=Math.floor((e-1)/26)}return r},"vr"),$e=h(e=>{let r=0;for(let a=0,u=e.length;a<u;a++)r=r*26+Ae.indexOf(e[a])+1;return r},"N"),de=h((e,r)=>{if(r<e)return de(r,e);const a=[];for(;e<=r;)a.push(e++);return a},"$"),it=h((e,r,a)=>de(e,r).map(u=>String(u).padStart(a,"0")),"fr"),we=h((e,r)=>de($e(e),$e(r)).map(ot),"j"),me=d(/\\./,U),at=d(/[$.*+?^(){}[\]\|]/,e=>`\\${e}`),st=d(/[\\/]/,"[\\\\/]"),ct=d(/./,U),lt=d(/^(?:!!)*!(.*)$/,(e,r)=>`(?!^${_e(r)}$).*?`),ut=d(/^(!!)+/,""),pt=O([lt,ut]),dt=d(/\/(\*\*\/)+/,"(?:[\\\\/].+[\\\\/]|[\\\\/])"),mt=d(/^(\*\*\/)+/,"(?:^|.*[\\\\/])"),ft=d(/\/(\*\*)$/,"(?:[\\\\/].*|$)"),ht=d(/\*\*/,".*"),Me=O([dt,mt,ft,ht]),xt=d(/\*\/(?!\*\*\/|\*$)/,"[^\\\\/]*[\\\\/]"),gt=d(/\*/,"[^\\\\/]*"),Ee=O([xt,gt]),Pe=d("?","[^\\\\/]"),bt=d("[",U),vt=d("]",U),Bt=d(/[!^]/,"^\\\\/"),Ot=d(/[a-z]-[a-z]|[0-9]-[0-9]/i,U),yt=d(/[$.*+?^(){}[\|]/,e=>`\\${e}`),Ct=d(/[^\]]/,U),St=O([me,yt,Ot,Ct]),Re=H([bt,ne(Bt),q(St),vt]),At=d("{","(?:"),$t=d("}",")"),wt=d(/(\d+)\.\.(\d+)/,(e,r,a)=>it(+r,+a,Math.min(r.length,a.length)).join("|")),Mt=d(/([a-z]+)\.\.([a-z]+)/,(e,r,a)=>we(r,a).join("|")),Et=d(/([A-Z]+)\.\.([A-Z]+)/,(e,r,a)=>we(r.toLowerCase(),a.toLowerCase()).join("|").toUpperCase()),Pt=O([wt,Mt,Et]),je=H([At,Pt,$t]),Rt=d("{","(?:"),jt=d("}",")"),It=d(",","|"),_t=d(/[$.*+?^(){[\]\|]/,e=>`\\${e}`),Tt=d(/[^}]/,U),qt=F(()=>Ie),Nt=O([Me,Ee,Pe,Re,je,qt,me,_t,It,Tt]),Ie=H([Rt,q(Nt),jt]),Lt=q(O([pt,Me,Ee,Pe,Re,je,Ie,me,at,st,ct])),kt=Lt,zt=ee(kt),_e=zt,Dt=d(/\\./,U),Wt=d(/./,U),Ut=d(/\*\*\*+/,"*"),Gt=d(/([^/{[(!])\*\*/,(e,r)=>`${r}*`),Ft=d(/(^|.)\*\*(?=[^*/)\]}])/,(e,r)=>`${r}*`),Qt=q(O([Dt,Ut,Gt,Ft,Wt])),Vt=Qt,Zt=ee(Vt),Ht=Zt,ae=h((e,r)=>Array.isArray(e)?e.map(ae.compile).some(a=>a.test(r)):ae.compile(e).test(r),"_");ae.compile=nt(e=>new RegExp(`^${_e(Ht(e))}[\\\\/]?$`,"s"));var Jt=ae;return b(B)})();return t.default||t},"_lazyMatch"),fe;const pr=h((t,n)=>(fe||(fe=Le(),Le=null),fe(t,n)),"default");var dr=Object.defineProperty,mr=Se((t,n)=>dr(t,"name",{value:n,configurable:!0}),"t");const fr=/^[A-Z]:\//i,Y=mr((t="")=>t&&t.replaceAll("\\","/").replace(fr,n=>n.toUpperCase()),"normalizeWindowsPath");var hr=Object.defineProperty,k=Se((t,n)=>hr(t,"name",{value:n,configurable:!0}),"r");const xr=/^[/\\]{2}/,gr=/^[/\\](?![/\\])|^[/\\]{2}(?!\.)|^[A-Z]:[/\\]/i,et=/^[A-Z]:$/i,ke=/^\/([A-Z]:)?$/i,br=/.(\.[^./]+)$/,vr=/^[/\\]|^[a-z]:[/\\]/i,Br=k(()=>typeof process.cwd=="function"?process.cwd().replaceAll("\\","/"):"/","cwd"),ze="/",tt=k((t,n)=>{let s="",i=0,c=-1,p=0,m;for(let b=0;b<=t.length;++b){if(b<t.length)m=t[b];else{if(m==="/")break;m="/"}if(m==="/"){if(!(c===b-1||p===1))if(p===2){if(s.length<2||i!==2||!s.endsWith(".")||s.at(-2)!=="."){if(s.length>2){const B=s.lastIndexOf("/");B===-1?(s="",i=0):(s=s.slice(0,B),i=s.length-1-s.lastIndexOf("/")),c=b,p=0;continue}else if(s.length>0){s="",i=0,c=b,p=0;continue}}n&&(s+=s.length>0?"/..":"..",i=2)}else s.length>0?s+=`/${t.slice(c+1,b)}`:s=t.slice(c+1,b),i=b-c-1;c=b,p=0}else m==="."&&p!==-1?++p:p=-1}return s},"normalizeString"),J=k(t=>gr.test(t),"isAbsolute"),le=k(function(t){if(t.length===0)return".";t=Y(t);const n=xr.exec(t),s=J(t),i=t.at(-1)==="/";return t=tt(t,!s),t.length===0?s?"/":i?"./":".":(i&&(t+="/"),et.test(t)&&(t+="/"),n?s?`//${t}`:`//./${t}`:s&&!J(t)?`/${t}`:t)},"normalize");k((...t)=>{let n="";for(const s of t)if(s)if(n.length>0){const i=n[n.length-1]==="/",c=s[0]==="/";i&&c?n+=s.slice(1):n+=i||c?s:`/${s}`}else n+=s;return le(n)},"join");const ue=k(function(...t){t=t.map(i=>Y(i));let n="",s=!1;for(let i=t.length-1;i>=-1&&!s;i--){const c=i>=0?t[i]:Br();!c||c.length===0||(n=`${c}/${n}`,s=J(c))}return n=tt(n,!s),s&&!J(n)?`/${n}`:n.length>0?n:"."},"resolve");k(function(t){return Y(t)},"toNamespacedPath");const Or=k(function(t){return br.exec(Y(t))?.[1]??""},"extname"),yr=k(function(t,n){const s=ue(t).replace(ke,"$1").split("/"),i=ue(n).replace(ke,"$1").split("/");if(i[0][1]===":"&&s[0][1]===":"&&s[0]!==i[0])return i.join("/");const c=[...s];for(const p of c){if(i[0]!==p)break;s.shift(),i.shift()}return[...s.map(()=>".."),...i].join("/")},"relative"),Cr=k(t=>{const n=Y(t).replace(/\/$/,"").split("/").slice(0,-1);return n.length===1&&et.test(n[0])&&(n[0]+="/"),n.join("/")||(J(t)?"/":".")},"dirname");k(function(t){const n=[t.root,t.dir,t.base??t.name+t.ext].filter(Boolean);return Y(t.root?ue(...n):n.join("/"))},"format");const Sr=k((t,n)=>{const s=Y(t).split("/").pop();return n&&s.endsWith(n)?s.slice(0,-n.length):s},"basename");k(function(t){const n=vr.exec(t)?.[0]?.replaceAll("\\","/")??"",s=Sr(t),i=Or(s);return{base:s,dir:Cr(t),ext:i,name:s.slice(0,s.length-i.length),root:n}},"parse");k((t,n)=>pr(n,le(t)),"matchesGlob");function Ar(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}v(Ar,"getDefaultExportFromCjs");var se={exports:{}},De;function $r(){if(De)return se.exports;De=1;var t=Object.defineProperty,n=v((f,o)=>t(f,"name",{value:o,configurable:!0}),"t");let s=process||{},i=s.argv||[],c=s.env||{},p=!(c.NO_COLOR||i.includes("--no-color"))&&(!!c.FORCE_COLOR||i.includes("--color")||s.platform==="win32"||(s.stdout||{}).isTTY&&c.TERM!=="dumb"||!!c.CI),m=n((f,o,g=f)=>w=>{let C=""+w,R=C.indexOf(o,f.length);return~R?f+b(C,o,g,R)+o:f+C+o},"formatter"),b=n((f,o,g,w)=>{let C="",R=0;do C+=f.substring(R,w)+g,R=w+o.length,w=f.indexOf(o,R);while(~w);return C+f.substring(R)},"replaceClose"),B=n((f=p)=>{let o=f?m:()=>String;return{isColorSupported:f,reset:o("\x1B[0m","\x1B[0m"),bold:o("\x1B[1m","\x1B[22m","\x1B[22m\x1B[1m"),dim:o("\x1B[2m","\x1B[22m","\x1B[22m\x1B[2m"),italic:o("\x1B[3m","\x1B[23m"),underline:o("\x1B[4m","\x1B[24m"),inverse:o("\x1B[7m","\x1B[27m"),hidden:o("\x1B[8m","\x1B[28m"),strikethrough:o("\x1B[9m","\x1B[29m"),black:o("\x1B[30m","\x1B[39m"),red:o("\x1B[31m","\x1B[39m"),green:o("\x1B[32m","\x1B[39m"),yellow:o("\x1B[33m","\x1B[39m"),blue:o("\x1B[34m","\x1B[39m"),magenta:o("\x1B[35m","\x1B[39m"),cyan:o("\x1B[36m","\x1B[39m"),white:o("\x1B[37m","\x1B[39m"),gray:o("\x1B[90m","\x1B[39m"),bgBlack:o("\x1B[40m","\x1B[49m"),bgRed:o("\x1B[41m","\x1B[49m"),bgGreen:o("\x1B[42m","\x1B[49m"),bgYellow:o("\x1B[43m","\x1B[49m"),bgBlue:o("\x1B[44m","\x1B[49m"),bgMagenta:o("\x1B[45m","\x1B[49m"),bgCyan:o("\x1B[46m","\x1B[49m"),bgWhite:o("\x1B[47m","\x1B[49m"),blackBright:o("\x1B[90m","\x1B[39m"),redBright:o("\x1B[91m","\x1B[39m"),greenBright:o("\x1B[92m","\x1B[39m"),yellowBright:o("\x1B[93m","\x1B[39m"),blueBright:o("\x1B[94m","\x1B[39m"),magentaBright:o("\x1B[95m","\x1B[39m"),cyanBright:o("\x1B[96m","\x1B[39m"),whiteBright:o("\x1B[97m","\x1B[39m"),bgBlackBright:o("\x1B[100m","\x1B[49m"),bgRedBright:o("\x1B[101m","\x1B[49m"),bgGreenBright:o("\x1B[102m","\x1B[49m"),bgYellowBright:o("\x1B[103m","\x1B[49m"),bgBlueBright:o("\x1B[104m","\x1B[49m"),bgMagentaBright:o("\x1B[105m","\x1B[49m"),bgCyanBright:o("\x1B[106m","\x1B[49m"),bgWhiteBright:o("\x1B[107m","\x1B[49m")}},"createColors");return se.exports=B(),se.exports.createColors=B,se.exports}v($r,"requirePicocolors");var ce={},he,We;function wr(){if(We)return he;We=1;var t=Object.defineProperty,n=v((s,i)=>t(s,"name",{value:i,configurable:!0}),"n");return he=n(function(s){return s.map(function(i){return i===""?"''":i&&typeof i=="object"?i.op.replace(/(.)/g,"\\$1"):/["\s\\]/.test(i)&&!/'/.test(i)?"'"+i.replace(/(['])/g,"\\$1")+"'":/["'\s]/.test(i)?'"'+i.replace(/(["\\$`!])/g,"\\$1")+'"':String(i).replace(/([A-Za-z]:)?([#!"$&'()*,:;<=>?@[\\\]^`{|}])/g,"$1\\$2")}).join(" ")},"quote"),he}v(wr,"requireQuote");var xe,Ue;function Mr(){if(Ue)return xe;Ue=1;for(var t=Object.defineProperty,n=v((j,x)=>t(j,"name",{value:x,configurable:!0}),"c"),s="(?:"+["\\|\\|","\\&\\&",";;","\\|\\&","\\<\\(","\\<\\<\\<",">>",">\\&","<\\&","[&;()|<>]"].join("|")+")",i=new RegExp("^"+s+"$"),c="|&;()<> \\t",p='"((\\\\"|[^"])*?)"',m="'((\\\\'|[^'])*?)'",b=/^#$/,B="'",f='"',o="$",g="",w=4294967296,C=0;C<4;C++)g+=(w*Math.random()).toString(16);var R=new RegExp("^"+g);function P(j,x){for(var N=x.lastIndex,E=[],d;d=x.exec(j);)E.push(d),x.lastIndex===d.index&&(x.lastIndex+=1);return x.lastIndex=N,E}v(P,"matchAll"),n(P,"matchAll");function _(j,x,N){var E=typeof j=="function"?j(N):j[N];return typeof E>"u"&&N!=""?E="":typeof E>"u"&&(E="$"),typeof E=="object"?x+g+JSON.stringify(E)+g:x+E}v(_,"getVar"),n(_,"getVar");function M(j,x,N){N||(N={});var E=N.escape||"\\",d="(\\"+E+`['"`+c+`]|[^\\s'"`+c+"])+",z=new RegExp(["("+s+")","("+d+"|"+p+"|"+m+")+"].join("|"),"g"),T=P(j,z);if(T.length===0)return[];x||(x={});var D=!1;return T.map(function(W){var y=W[0];if(!y||D)return;if(i.test(y))return{op:y};var V=!1,ne=!1,q="",H=!1,O;function K(){O+=1;var F,L,U=y.charAt(O);if(U==="{"){if(O+=1,y.charAt(O)==="}")throw new Error("Bad substitution: "+y.slice(O-2,O+1));if(F=y.indexOf("}",O),F<0)throw new Error("Bad substitution: "+y.slice(O));L=y.slice(O,F),O=F}else if(/[*@#?$!_-]/.test(U))L=U,O+=1;else{var ee=y.slice(O);F=ee.match(/[^\w\d_]/),F?(L=ee.slice(0,F.index),O+=F.index-1):(L=ee,O=y.length)}return _(x,"",L)}for(v(K,"R"),n(K,"parseEnvVar"),O=0;O<y.length;O++){var $=y.charAt(O);if(H=H||!V&&($==="*"||$==="?"),ne)q+=$,ne=!1;else if(V)$===V?V=!1:V==B?q+=$:$===E?(O+=1,$=y.charAt(O),$===f||$===E||$===o?q+=$:q+=E+$):$===o?q+=K():q+=$;else if($===f||$===B)V=$;else{if(i.test($))return{op:y};if(b.test($)){D=!0;var X={comment:j.slice(W.index+O+1)};return q.length?[q,X]:[X]}else $===E?ne=!0:$===o?q+=K():q+=$}}return H?{op:"glob",pattern:q}:q}).reduce(function(W,y){return typeof y>"u"?W:W.concat(y)},[])}return v(M,"parseInternal"),n(M,"parseInternal"),xe=n(function(j,x,N){var E=M(j,x,N);return typeof x!="function"?E:E.reduce(function(d,z){if(typeof z=="object")return d.concat(z);var T=z.split(RegExp("("+g+".*?"+g+")","g"));return T.length===1?d.concat(T[0]):d.concat(T.filter(Boolean).map(function(D){return R.test(D)?JSON.parse(D.split(g)[1]):D}))},[])},"parse"),xe}v(Mr,"requireParse");var Ge;function Er(){return Ge||(Ge=1,ce.quote=wr(),ce.parse=Mr()),ce}v(Er,"requireShellQuote");var ge,Fe;function Pr(){return Fe||(Fe=1,ge={"/Applications/Atom.app/Contents/MacOS/Atom":"atom","/Applications/Atom Beta.app/Contents/MacOS/Atom Beta":"/Applications/Atom Beta.app/Contents/MacOS/Atom Beta","/Applications/Brackets.app/Contents/MacOS/Brackets":"brackets","/Applications/Sublime Text.app/Contents/MacOS/Sublime Text":"/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl","/Applications/Sublime Text.app/Contents/MacOS/sublime_text":"/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl","/Applications/Sublime Text 2.app/Contents/MacOS/Sublime Text 2":"/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/subl","/Applications/Sublime Text Dev.app/Contents/MacOS/Sublime Text":"/Applications/Sublime Text Dev.app/Contents/SharedSupport/bin/subl","/Applications/Visual Studio Code.app/Contents/MacOS/Electron":"code","/Applications/Visual Studio Code - Insiders.app/Contents/MacOS/Electron":"code-insiders","/Applications/VSCodium.app/Contents/MacOS/Electron":"codium","/Applications/Cursor.app/Contents/MacOS/Cursor":"cursor","/Applications/Trae.app/Contents/MacOS/Electron":"trae","/Applications/AppCode.app/Contents/MacOS/appcode":"/Applications/AppCode.app/Contents/MacOS/appcode","/Applications/CLion.app/Contents/MacOS/clion":"/Applications/CLion.app/Contents/MacOS/clion","/Applications/IntelliJ IDEA.app/Contents/MacOS/idea":"/Applications/IntelliJ IDEA.app/Contents/MacOS/idea","/Applications/IntelliJ IDEA Ultimate.app/Contents/MacOS/idea":"/Applications/IntelliJ IDEA Ultimate.app/Contents/MacOS/idea","/Applications/IntelliJ IDEA Community Edition.app/Contents/MacOS/idea":"/Applications/IntelliJ IDEA Community Edition.app/Contents/MacOS/idea","/Applications/PhpStorm.app/Contents/MacOS/phpstorm":"/Applications/PhpStorm.app/Contents/MacOS/phpstorm","/Applications/PyCharm.app/Contents/MacOS/pycharm":"/Applications/PyCharm.app/Contents/MacOS/pycharm","/Applications/PyCharm CE.app/Contents/MacOS/pycharm":"/Applications/PyCharm CE.app/Contents/MacOS/pycharm","/Applications/RubyMine.app/Contents/MacOS/rubymine":"/Applications/RubyMine.app/Contents/MacOS/rubymine","/Applications/WebStorm.app/Contents/MacOS/webstorm":"/Applications/WebStorm.app/Contents/MacOS/webstorm","/Applications/MacVim.app/Contents/MacOS/MacVim":"mvim","/Applications/GoLand.app/Contents/MacOS/goland":"/Applications/GoLand.app/Contents/MacOS/goland","/Applications/Rider.app/Contents/MacOS/rider":"/Applications/Rider.app/Contents/MacOS/rider","/Applications/Zed.app/Contents/MacOS/zed":"zed"}),ge}v(Pr,"requireMacos");var be,Qe;function Rr(){return Qe||(Qe=1,be={atom:"atom",Brackets:"brackets","code-insiders":"code-insiders",code:"code",vscodium:"vscodium",codium:"codium",trae:"trae",emacs:"emacs",gvim:"gvim",idea:"idea","idea.sh":"idea",phpstorm:"phpstorm","phpstorm.sh":"phpstorm",pycharm:"pycharm","pycharm.sh":"pycharm",rubymine:"rubymine","rubymine.sh":"rubymine",sublime_text:"subl",vim:"vim",webstorm:"webstorm","webstorm.sh":"webstorm",goland:"goland","goland.sh":"goland",rider:"rider","rider.sh":"rider",zed:"zed"}),be}v(Rr,"requireLinux");var ve,Ve;function jr(){return Ve||(Ve=1,ve=["Brackets.exe","Code.exe","Code - Insiders.exe","VSCodium.exe","Cursor.exe","atom.exe","sublime_text.exe","notepad++.exe","clion.exe","clion64.exe","idea.exe","idea64.exe","phpstorm.exe","phpstorm64.exe","pycharm.exe","pycharm64.exe","rubymine.exe","rubymine64.exe","webstorm.exe","webstorm64.exe","goland.exe","goland64.exe","rider.exe","rider64.exe","trae.exe"]),ve}v(jr,"requireWindows");var Be,Ze;function Ir(){if(Ze)return Be;Ze=1;var t=Object.defineProperty,n=v((B,f)=>t(B,"name",{value:f,configurable:!0}),"u");const s=pe,i=Er(),c=Xe,p=Pr(),m=Rr(),b=jr();return Be=n(function(B){if(B)return i.parse(B);if(process.env.LAUNCH_EDITOR)return[process.env.LAUNCH_EDITOR];if(process.versions.webcontainer)return[process.env.EDITOR||"code"];try{if(process.platform==="darwin"){const f=c.execSync("ps x -o comm=",{stdio:["pipe","pipe","ignore"]}).toString(),o=Object.keys(p),g=f.split(`
|
|
2
|
+
`);for(let w=0;w<o.length;w++){const C=o[w];if(g.includes(C))return[p[C]];const R=C.replace("/Applications","");if(f.indexOf(R)!==-1){if(C!==p[C])return[p[C]];const P=g.find(_=>_.endsWith(R));if(P!==void 0)return[P]}}}else if(process.platform==="win32"){const f=c.execSync('powershell -NoProfile -Command "[Console]::OutputEncoding=[Text.Encoding]::UTF8;Get-CimInstance -Query \\"select executablepath from win32_process where executablepath is not null\\" | % { $_.ExecutablePath }"',{stdio:["pipe","pipe","ignore"]}).toString().split(`\r
|
|
3
|
+
`);for(let o=0;o<f.length;o++){const g=f[o].trim(),w=s.basename(g);if(b.indexOf(w)!==-1)return[g]}}else if(process.platform==="linux"){const f=c.execSync("ps x --no-heading -o comm --sort=comm",{stdio:["pipe","pipe","ignore"]}).toString(),o=Object.keys(m);for(let g=0;g<o.length;g++){const w=o[g];if(f.indexOf(w)!==-1)return[m[w]]}}}catch{}return process.env.VISUAL?[process.env.VISUAL]:process.env.EDITOR?[process.env.EDITOR]:[null]},"guessEditor"),Be}v(Ir,"requireGuess");var Oe,He;function _r(){if(He)return Oe;He=1;var t=Object.defineProperty,n=v((i,c)=>t(i,"name",{value:c,configurable:!0}),"r");const s=pe;return Oe=n(function(i,c,p,m=1){switch(s.basename(i).replace(/\.(exe|cmd|bat)$/i,"")){case"atom":case"Atom":case"Atom Beta":case"subl":case"sublime":case"sublime_text":case"wstorm":case"charm":case"zed":return[`${c}:${p}:${m}`];case"notepad++":return["-n"+p,"-c"+m,c];case"vim":case"mvim":return[`+call cursor(${p}, ${m})`,c];case"joe":case"gvim":return[`+${p}`,c];case"emacs":case"emacsclient":return[`+${p}:${m}`,c];case"rmate":case"mate":case"mine":return["--line",p,c];case"code":case"Code":case"code-insiders":case"Code - Insiders":case"codium":case"trae":case"cursor":case"vscodium":case"VSCodium":return["-r","-g",`${c}:${p}:${m}`];case"appcode":case"clion":case"clion64":case"idea":case"idea64":case"phpstorm":case"phpstorm64":case"pycharm":case"pycharm64":case"rubymine":case"rubymine64":case"webstorm":case"webstorm64":case"goland":case"goland64":case"rider":case"rider64":return["--line",p,"--column",m,c]}return process.env.LAUNCH_EDITOR?[c,p,m]:[c]},"getArgumentsForPosition"),Oe}v(_r,"requireGetArgs");var ye,Je;function Tr(){if(Je)return ye;Je=1;var t=Object.defineProperty,n=v((P,_)=>t(P,"name",{value:_,configurable:!0}),"c");const s=or,i=ir,c=pe,p=$r(),m=Xe,b=Ir(),B=_r();function f(P){return(_,M)=>{console.log(),console.log(p.red("Could not open "+c.basename(_)+" in the editor.")),M&&(M[M.length-1]!=="."&&(M+="."),console.log(p.red("The editor process exited with an error: "+M))),console.log(),P&&P(_,M)}}v(f,"wrapErrorCallback"),n(f,"wrapErrorCallback");function o(P){switch(P){case"vim":case"emacs":case"nano":return!0}return!1}v(o,"isTerminalEditor"),n(o,"isTerminalEditor");const g=/:(\d+)(:(\d+))?$/;function w(P){P.startsWith("file://")&&(P=ar.fileURLToPath(P));const _=P.replace(g,""),M=P.match(g),j=M&&M[1],x=M&&M[3];return{fileName:_,lineNumber:j,columnNumber:x}}v(w,"parseFile"),n(w,"parseFile");let C=null;function R(P,_,M){const j=w(P);let{fileName:x}=j;const{lineNumber:N,columnNumber:E}=j;if(!s.existsSync(x))return;typeof _=="function"&&(M=_,_=void 0),M=f(M);const[d,...z]=b(_);if(!d){M(x,null);return}if(process.platform==="linux"&&x.startsWith("/mnt/")&&/Microsoft/i.test(i.release())&&(x=c.relative("",x)),N){const T=B(d,x,N,E);z.push.apply(z,T)}else z.push(x);if(C&&o(d)&&C.kill("SIGKILL"),process.platform==="win32"){let T=v(function(y){return y.replace(/([&|<>,;=^])/g,"^$1")},"i"),D=v(function(y){return y.includes("^")?`^"${y}^"`:y.includes(" ")?`"${y}"`:y},"a");n(T,"escapeCmdArgs"),n(D,"doubleQuoteIfNeeded");const W=[d,...z.map(T)].map(D).join(" ");C=m.exec(W,{stdio:"inherit",shell:!0})}else C=m.spawn(d,z,{stdio:"inherit"});C.on("exit",function(T){C=null,T&&M(x,"(code "+T+")")}),C.on("error",function(T){let{code:D,message:W}=T;D==="ENOENT"&&(W=`${W} ('${d}' command does not exist in 'PATH')`),M(x,W)})}return v(R,"launchEditor"),n(R,"launchEditor"),ye=R,ye}v(Tr,"requireLaunchEditor");var Ce,Ye;function qr(){if(Ye)return Ce;Ye=1;var t=Object.defineProperty,n=v((c,p)=>t(c,"name",{value:p,configurable:!0}),"r");const s=pe,i=Tr();return Ce=v((c,p,m)=>(typeof c=="function"&&(m=c,c=void 0),typeof p=="function"&&(m=p,p=void 0),p=p||process.cwd(),n(function(b,B){let f;try{const g=b.url.startsWith("http")?b.url:`http://localhost${b.url}`;f=new URL(g)}catch{B.statusCode=500,B.end("launch-editor-middleware: invalid URL.");return}const o=f.searchParams.get("file");if(!o)B.statusCode=500,B.end('launch-editor-middleware: required query param "file" is missing.');else{const g=o.startsWith("file://")?o:s.resolve(p,o);i(g,c,m),B.end()}},"launchEditorMiddleware")),"launchEditorMiddleware"),Ce}v(qr,"requireLaunchEditorMiddleware");var Nr=qr();const Lr=Ar(Nr);var kr=Object.defineProperty,Z=v((t,n)=>kr(t,"name",{value:n,configurable:!0}),"i");const Ke=Z(t=>{if(typeof t.status=="function"){t.status(400).send("Failed to open editor");return}t.statusCode=400,t.end("Failed to open editor")},"respond400"),rt=Z((t={})=>{const n=Z(async i=>{if(String(i.method||"GET").toUpperCase()==="POST")return i.body&&typeof i.body=="object"?i.body:new Promise(p=>{try{let m="";const b=Z(f=>{m+=String(f)},"onData"),B=Z(()=>{try{p(m?JSON.parse(m):{})}catch{p({})}},"onEnd");i.on("data",b),i.on("end",B),i.on("error",()=>p({}))}catch{p({})}});const c=new URL(i.url||"","http://localhost");return{column:Number(c.searchParams.get("column")||1),editor:c.searchParams.get("editor")||void 0,file:c.searchParams.get("file")||void 0,line:Number(c.searchParams.get("line")||1)}},"parseRequestBody"),s=Z((i,c,p)=>{if(!i)return;const m=J(i)?i:ue(c,i);if(!p)try{const b=qe(c),B=qe(m),f=le(b),o=le(B),g=Ne()==="win32"||Ne()==="darwin",w=g?f.toLowerCase():f,C=g?o.toLowerCase():o,R=yr(f,o);if(R.startsWith("..")||J(R)||g&&!C.startsWith(w))return}catch{const b=c.endsWith(ze)?c:c+ze;if(!m.startsWith(b))return}return m},"validateFilePath");return Z(async function(i,c,p){try{const m=await n(i),b=t.projectRoot??process.cwd(),B=s(m.file,b,t.allowOutsideProject??!1);if(!B){Ke(c);return}const f=Lr(m.editor,b),o=new URLSearchParams({column:String(m.column??1),file:B,line:String(m.line??1)});if(m.editor&&o.set("editor",String(m.editor)),i.url=`/?${o.toString()}`,typeof p=="function"){f(i,c,p);return}await new Promise(g=>{f(i,c,()=>{g()})})}catch{Ke(c)}},"universalHandler")},"createOpenInEditorMiddleware"),Ur=Z((t={})=>{const n=rt(t);return async(s,i)=>n(s,i)},"createNodeHttpHandler"),Gr=Z((t={})=>rt(t),"createExpressHandler");export{Gr as createExpressHandler,Ur as createNodeHttpHandler,rt as createOpenInEditorMiddleware};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@visulima/ono",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.6",
|
|
4
4
|
"description": "Ono is an error-parsing library that pretty prints JavaScript errors on a web page or the terminal.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"visulima",
|
|
@@ -81,8 +81,8 @@
|
|
|
81
81
|
"dev:hono": "packem build --development --watch --onSuccess 'node ./examples/hono/index.js'",
|
|
82
82
|
"dev:node": "packem build --development --watch --onSuccess 'node ./examples/node/index.js'",
|
|
83
83
|
"lint:attw": "attw --pack",
|
|
84
|
-
"lint:eslint": "eslint .",
|
|
85
|
-
"lint:eslint:fix": "eslint . --fix",
|
|
84
|
+
"lint:eslint": "eslint . --cache --concurrency auto",
|
|
85
|
+
"lint:eslint:fix": "eslint . --cache --concurrency auto --fix",
|
|
86
86
|
"lint:package-json": "publint --strict",
|
|
87
87
|
"lint:prettier": "prettier --config=.prettierrc.cjs --check .",
|
|
88
88
|
"lint:prettier:fix": "prettier --config=.prettierrc.cjs --write .",
|
|
@@ -93,56 +93,55 @@
|
|
|
93
93
|
"test:watch": "vitest"
|
|
94
94
|
},
|
|
95
95
|
"dependencies": {
|
|
96
|
-
"@shikijs/langs": "^3.
|
|
97
|
-
"@shikijs/themes": "^3.
|
|
98
|
-
"@visulima/error": "
|
|
99
|
-
"isomorphic-dompurify": "^2.
|
|
100
|
-
"shiki": "^3.
|
|
96
|
+
"@shikijs/langs": "^3.13.0",
|
|
97
|
+
"@shikijs/themes": "^3.13.0",
|
|
98
|
+
"@visulima/error": "5.0.1",
|
|
99
|
+
"isomorphic-dompurify": "^2.29.0",
|
|
100
|
+
"shiki": "^3.13.0"
|
|
101
101
|
},
|
|
102
102
|
"devDependencies": {
|
|
103
|
-
"@anolilab/eslint-config": "^16.
|
|
104
|
-
"@anolilab/prettier-config": "^6.0.
|
|
105
|
-
"@anolilab/semantic-release-preset": "^11.0.
|
|
103
|
+
"@anolilab/eslint-config": "^16.4.2",
|
|
104
|
+
"@anolilab/prettier-config": "^6.0.7",
|
|
105
|
+
"@anolilab/semantic-release-preset": "^11.0.4",
|
|
106
106
|
"@arethetypeswrong/cli": "^0.18.2",
|
|
107
|
-
"@
|
|
108
|
-
"@eslint/css": "0.11.0",
|
|
107
|
+
"@eslint/css": "0.13.0",
|
|
109
108
|
"@tailwindcss/forms": "^0.5.10",
|
|
110
|
-
"@tailwindcss/node": "^4.1.
|
|
111
|
-
"@tailwindcss/oxide": "^4.1.
|
|
112
|
-
"@tailwindcss/typography": "^0.5.
|
|
109
|
+
"@tailwindcss/node": "^4.1.14",
|
|
110
|
+
"@tailwindcss/oxide": "^4.1.14",
|
|
111
|
+
"@tailwindcss/typography": "^0.5.19",
|
|
113
112
|
"@total-typescript/ts-reset": "^0.6.1",
|
|
114
113
|
"@types/http-errors": "^2.0.5",
|
|
115
|
-
"@types/node": "24.
|
|
116
|
-
"@visulima/packem": "2.0.0-alpha.
|
|
117
|
-
"@visulima/path": "
|
|
114
|
+
"@types/node": "24.8.1",
|
|
115
|
+
"@visulima/packem": "2.0.0-alpha.30",
|
|
116
|
+
"@visulima/path": "2.0.0",
|
|
118
117
|
"@vitest/coverage-v8": "^3.2.4",
|
|
119
118
|
"cssnano": "7.1.1",
|
|
120
|
-
"esbuild": "0.25.
|
|
121
|
-
"eslint": "^9.
|
|
119
|
+
"esbuild": "0.25.11",
|
|
120
|
+
"eslint": "^9.38.0",
|
|
122
121
|
"http-errors": "^2.0.0",
|
|
123
122
|
"launch-editor-middleware": "2.11.1",
|
|
124
|
-
"lucide-static": "^0.
|
|
125
|
-
"marked": "^16.
|
|
123
|
+
"lucide-static": "^0.546.0",
|
|
124
|
+
"marked": "^16.4.1",
|
|
126
125
|
"node-mocks-http": "^1.17.2",
|
|
127
|
-
"openai": "5.
|
|
126
|
+
"openai": "6.5.0",
|
|
128
127
|
"prettier": "^3.6.2",
|
|
129
|
-
"prettier-plugin-tailwindcss": "0.
|
|
130
|
-
"publint": "^0.3.
|
|
128
|
+
"prettier-plugin-tailwindcss": "0.7.1",
|
|
129
|
+
"publint": "^0.3.14",
|
|
131
130
|
"rimraf": "^6.0.1",
|
|
132
|
-
"semantic-release": "^
|
|
131
|
+
"semantic-release": "^25.0.1",
|
|
133
132
|
"sort-package-json": "^3.4.0",
|
|
134
133
|
"tailwind-csstree": "0.1.4",
|
|
135
|
-
"tailwindcss": "^4.1.
|
|
136
|
-
"typescript": "^5.9.
|
|
134
|
+
"tailwindcss": "^4.1.14",
|
|
135
|
+
"typescript": "^5.9.3",
|
|
137
136
|
"vitest": "^3.2.4"
|
|
138
137
|
},
|
|
139
138
|
"peerDependencies": {
|
|
140
|
-
"@ai-sdk/anthropic": "^1.0.
|
|
141
|
-
"@ai-sdk/azure": "^1.0.
|
|
142
|
-
"@ai-sdk/google": "^1.0.
|
|
143
|
-
"@ai-sdk/mistral": "^1.0.
|
|
139
|
+
"@ai-sdk/anthropic": "^1.0.9",
|
|
140
|
+
"@ai-sdk/azure": "^1.0.22",
|
|
141
|
+
"@ai-sdk/google": "^1.0.17",
|
|
142
|
+
"@ai-sdk/mistral": "^1.0.9",
|
|
144
143
|
"@ai-sdk/ollama": "^1.0.0",
|
|
145
|
-
"@ai-sdk/openai": "^1.0.
|
|
144
|
+
"@ai-sdk/openai": "^1.0.20",
|
|
146
145
|
"ai": "^4.0.0 || ^5.0.0"
|
|
147
146
|
},
|
|
148
147
|
"peerDependenciesMeta": {
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var D=Object.defineProperty;var m=(t,e)=>D(t,"name",{value:e,configurable:!0});import p from"isomorphic-dompurify";var v=Object.defineProperty,i=m((t,e)=>v(t,"name",{value:e,configurable:!0}),"e");const w=["http://","https://","/","./","../"],h="#",f={'"':""","&":"&","'":"'","<":"<",">":">"},y=/^[\w+/-]+={0,2}$/,n=i(t=>String(t??"").trim(),"toString"),u=i(t=>t.replaceAll(/[&<>"']/g,e=>f[e]),"escapeHtml"),C=i(t=>{try{return p.sanitize(n(t))}catch{return u(n(t))}},"sanitizeHtml"),H=i(t=>{const e=n(t);if(!e)return"";try{return p.sanitize(e).replaceAll('"',""").replaceAll("'","'")}catch{return u(e)}},"sanitizeAttribute"),z=i(t=>{const e=n(t);if(!e)return h;try{const r=p.sanitize(e),s=r.toLowerCase();return w.some(a=>s.startsWith(a))?r:h}catch{return h}},"sanitizeUrlAttribute"),A=i(t=>{const e=n(t);if(!e)return"";try{return p.sanitize(e,{ADD_ATTR:["class","style"]})}catch{return C(e)}},"sanitizeCodeHtml"),F=i(t=>{const e=n(t);if(e)return y.test(e)?e:void 0},"sanitizeCspNonce"),j=i((t={})=>{if(!t||typeof t!="object")return{};try{return{...t,cspNonce:F(t.cspNonce),openInEditorUrl:t.openInEditorUrl?z(t.openInEditorUrl):void 0}}catch{return{...t,cspNonce:void 0,openInEditorUrl:void 0}}},"sanitizeOptions");var b=Object.defineProperty,o=m((t,e)=>b(t,"name",{value:e,configurable:!0}),"r");let c,l;const x=o(async(t=[])=>{try{const[e,r]=await Promise.all([import("shiki/core"),import("shiki/engine/javascript")]),{createHighlighterCore:s}=e,{createJavaScriptRegexEngine:a}=r,d=await s({themes:[import("@shikijs/themes/github-dark-default"),import("@shikijs/themes/github-light")],langs:[import("@shikijs/langs/javascript"),import("@shikijs/langs/typescript"),import("@shikijs/langs/jsx"),import("@shikijs/langs/tsx"),import("@shikijs/langs/json"),import("@shikijs/langs/jsonc"),import("@shikijs/langs/xml"),import("@shikijs/langs/sql"),import("@shikijs/langs/bash"),import("@shikijs/langs/shell"),import("@shikijs/langs/markdown"),import("@shikijs/langs/mdx"),import("@shikijs/langs/html"),import("@shikijs/langs/css"),import("@shikijs/langs/scss"),import("@shikijs/langs/less"),import("@shikijs/langs/sass"),import("@shikijs/langs/stylus"),import("@shikijs/langs/styl"),...t],engine:a()}),g=d;return l=o(()=>{try{d?.dispose?.()}catch{}c=void 0},"disposeFn"),g}catch{const{createHighlighter:e}=await import("shiki"),r=await e({langs:["javascript","typescript","jsx","tsx","json","jsonc","xml","sql","bash","shell","markdown","mdx"],themes:["github-dark-default","github-light"]});return l=o(()=>{try{r?.dispose?.()}catch{}c=void 0},"disposeFn"),r}},"createSingletonHighlighter"),U=o(async(t=[])=>(c||(c=x(t)),c),"getHighlighter");o(async()=>{try{l&&(l(),l=void 0)}catch{}},"disposeHighlighter");o((t=[])=>({name:"@shikijs/transformers:compact-line-options",line(e,r){const s=t.find(a=>a.line===r);return s?.classes&&this.addClassToHast(e,s.classes),e}}),"transformerCompactLineOptions");const $="data:image/svg+xml;charset=utf-8,%3Csvg%20class%3D%22lucide%20lucide-check%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22currentColor%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%20%3E%20%3Cpath%20d%3D%22M20%206%209%2017l-5-5%22%20%2F%3E%20%3C%2Fsvg%3E",N="data:image/svg+xml;charset=utf-8,%3Csvg%20class%3D%22lucide%20lucide-clipboard%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22currentColor%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%20%3E%20%3Crect%20width%3D%228%22%20height%3D%224%22%20x%3D%228%22%20y%3D%222%22%20rx%3D%221%22%20ry%3D%221%22%20%2F%3E%20%3Cpath%20d%3D%22M16%204h2a2%202%200%200%201%202%202v14a2%202%200%200%201-2%202H6a2%202%200%200%201-2-2V6a2%202%200%200%201%202-2h2%22%20%2F%3E%20%3C%2Fsvg%3E";export{H as a,F as b,U as c,z as d,$ as e,j as f,A as g,N as n,C as s};
|