@dtsx/dtsx 0.11.37 → 0.11.38

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.
Files changed (179) hide show
  1. package/dist/bin/cli.js +3 -3
  2. package/dist/{chunk-wrnz0e76.js → chunk-082w7zvy.js} +3 -3
  3. package/dist/{chunk-psrgw9f8.js → chunk-0k0fhq13.js} +7 -7
  4. package/dist/{chunk-69dbf6de.js → chunk-0rmbc5zp.js} +2 -2
  5. package/dist/{chunk-nn9tpxx3.js → chunk-0yg5mcrf.js} +2 -2
  6. package/dist/chunk-0zfzhn19.js +31 -0
  7. package/dist/chunk-189nn4fc.js +3 -0
  8. package/dist/{chunk-cen2t56g.js → chunk-1qtghb2x.js} +2 -2
  9. package/dist/{chunk-r4zkf9ag.js → chunk-2436cnmb.js} +2 -2
  10. package/dist/{chunk-py7pj8aj.js → chunk-2qd3axyx.js} +4 -4
  11. package/dist/{chunk-n2nyd0ck.js → chunk-32qexm3w.js} +2 -2
  12. package/dist/{chunk-1pz7zxhc.js → chunk-3fbt79hx.js} +2 -2
  13. package/dist/{chunk-gpq2kggq.js → chunk-3t57mzvf.js} +2 -2
  14. package/dist/{chunk-2kwjbk55.js → chunk-42j9cfte.js} +2 -2
  15. package/dist/{chunk-vtskg4r2.js → chunk-4fygcxtb.js} +2 -2
  16. package/dist/{chunk-437g8zz6.js → chunk-50h54rax.js} +3 -3
  17. package/dist/{chunk-aw48mk3t.js → chunk-6yvk3q1e.js} +2 -2
  18. package/dist/chunk-73dzve1s.js +3 -0
  19. package/dist/chunk-7tremqhs.js +14 -0
  20. package/dist/{chunk-mt9219xc.js → chunk-83qnrx0m.js} +5 -5
  21. package/dist/{chunk-ckq8g1ck.js → chunk-88gwzbew.js} +3 -3
  22. package/dist/{chunk-90aptjh6.js → chunk-8d3sdkv4.js} +19 -19
  23. package/dist/{chunk-srg5qhch.js → chunk-8tzd98q8.js} +4 -4
  24. package/dist/{chunk-fy97syc2.js → chunk-96atbsd3.js} +2 -2
  25. package/dist/{chunk-h7k9wamx.js → chunk-9gts9ymh.js} +2 -2
  26. package/dist/{chunk-sq34kkhy.js → chunk-9menejdz.js} +2 -2
  27. package/dist/{chunk-1h6ycqza.js → chunk-a7nvyxpg.js} +4 -4
  28. package/dist/{chunk-j6pfxvy8.js → chunk-ag1b6d30.js} +2 -2
  29. package/dist/{chunk-0ke9xh7t.js → chunk-bnry23ve.js} +3 -3
  30. package/dist/{chunk-wzcwctba.js → chunk-bxc2herz.js} +3 -3
  31. package/dist/{chunk-pzedkn7z.js → chunk-cpmqa8kd.js} +2 -2
  32. package/dist/{chunk-rdzfdjkb.js → chunk-cv29b4zb.js} +3 -3
  33. package/dist/{chunk-xr1h3tv2.js → chunk-cyr45de1.js} +2 -2
  34. package/dist/{chunk-m1khpcqb.js → chunk-d0bazr3p.js} +1 -1
  35. package/dist/{chunk-vae5wxar.js → chunk-danfamyx.js} +2 -2
  36. package/dist/{chunk-853ftm92.js → chunk-davy89dj.js} +5 -5
  37. package/dist/{chunk-n6nw7sn2.js → chunk-e29rp5xj.js} +5 -5
  38. package/dist/{chunk-p7w9ydhe.js → chunk-eba562w8.js} +2 -2
  39. package/dist/{chunk-v44crx69.js → chunk-ebjafajx.js} +11 -11
  40. package/dist/{chunk-g9d5r6a8.js → chunk-ft2zk7jx.js} +2 -2
  41. package/dist/chunk-g2120ysy.js +3 -0
  42. package/dist/chunk-ghfd34r7.js +3 -0
  43. package/dist/{chunk-sjneg7p7.js → chunk-gspsxc9d.js} +8 -8
  44. package/dist/{chunk-n3p7wedp.js → chunk-h3n6256r.js} +2 -2
  45. package/dist/{chunk-4f2mwn7p.js → chunk-hnqm1zb3.js} +4 -4
  46. package/dist/{chunk-gs7wfk8b.js → chunk-htgy94y3.js} +1 -1
  47. package/dist/{chunk-knrtwppp.js → chunk-hv8bx8xx.js} +6 -6
  48. package/dist/chunk-hzn9kmq7.js +3 -0
  49. package/dist/{chunk-nchp0pqa.js → chunk-ja7bp731.js} +2 -2
  50. package/dist/chunk-jcckwgb9.js +3 -0
  51. package/dist/{chunk-s0mvstt0.js → chunk-kfk554fj.js} +2 -2
  52. package/dist/{chunk-1e10w914.js → chunk-kkshxyex.js} +3 -3
  53. package/dist/{chunk-bdxq6500.js → chunk-kpbz61yy.js} +3 -3
  54. package/dist/{chunk-w9av39jy.js → chunk-mkakbjvs.js} +2 -2
  55. package/dist/{chunk-xsf941gw.js → chunk-mwyjxjqa.js} +2 -2
  56. package/dist/{chunk-n37yj3xv.js → chunk-p023fhce.js} +3 -3
  57. package/dist/chunk-p9vfxn8g.js +3 -0
  58. package/dist/{chunk-q0hn0ymb.js → chunk-pjqzkgzk.js} +4 -4
  59. package/dist/chunk-qzjzw9p2.js +3 -0
  60. package/dist/{chunk-acyj1dev.js → chunk-rbx6q1r0.js} +2 -2
  61. package/dist/{chunk-fgbdm1y6.js → chunk-rkstz4w1.js} +4 -4
  62. package/dist/{chunk-gsv5yc32.js → chunk-rz060wxt.js} +4 -4
  63. package/dist/{chunk-z4mvkazp.js → chunk-sd8bywh9.js} +11 -11
  64. package/dist/{chunk-dv5hhg1a.js → chunk-sv8h007a.js} +2 -2
  65. package/dist/{chunk-1bpv3tck.js → chunk-t4va49p3.js} +4 -4
  66. package/dist/{chunk-bqabznps.js → chunk-tka2m4af.js} +2 -2
  67. package/dist/{chunk-7610h2tf.js → chunk-v93389xm.js} +1 -1
  68. package/dist/{chunk-wnk9yjw2.js → chunk-vf3ybe5r.js} +2 -2
  69. package/dist/{chunk-ezbp8tss.js → chunk-vkahj2ab.js} +8 -8
  70. package/dist/chunk-wnqg6hem.js +27 -0
  71. package/dist/chunk-xa6rsd4b.js +29 -0
  72. package/dist/{chunk-gsb3ty07.js → chunk-xfjfhe9d.js} +2 -2
  73. package/dist/{chunk-5n0tfrpc.js → chunk-xwpn40p0.js} +3 -3
  74. package/dist/chunk-y1g6v96c.js +10 -0
  75. package/dist/{chunk-r4s18nn5.js → chunk-y5k0szq6.js} +2 -2
  76. package/dist/{chunk-km8t8gqg.js → chunk-yay68832.js} +2 -2
  77. package/dist/{chunk-strqhcqs.js → chunk-yrv6z221.js} +2 -2
  78. package/dist/chunk-yx1jy7fx.js +37 -0
  79. package/dist/{chunk-ggbahdr2.js → chunk-zgcdx773.js} +3 -3
  80. package/dist/{chunk-60ssvwc8.js → chunk-zk3w5sqv.js} +2 -2
  81. package/dist/src/augmentation-graph.js +1 -1
  82. package/dist/src/binding-patterns.js +1 -1
  83. package/dist/src/branded-types.js +1 -1
  84. package/dist/src/bundle-linker.js +1 -1
  85. package/dist/src/bundler.js +1 -1
  86. package/dist/src/cache.js +1 -1
  87. package/dist/src/call-signatures.js +1 -1
  88. package/dist/src/circular.js +1 -1
  89. package/dist/src/compat.js +1 -1
  90. package/dist/src/computed-keys.js +1 -1
  91. package/dist/src/config.js +1 -1
  92. package/dist/src/dangling-refs.js +1 -1
  93. package/dist/src/declaration-project.js +1 -1
  94. package/dist/src/declaration-publication.js +1 -1
  95. package/dist/src/declaration-references.js +1 -1
  96. package/dist/src/diff.js +1 -1
  97. package/dist/src/docs.js +1 -1
  98. package/dist/src/enum-declarations.js +1 -1
  99. package/dist/src/errors.js +1 -1
  100. package/dist/src/extractor/directives.js +1 -1
  101. package/dist/src/extractor/extract.js +1 -1
  102. package/dist/src/extractor/scanner.js +1 -1
  103. package/dist/src/extractor.js +1 -1
  104. package/dist/src/formats.js +1 -1
  105. package/dist/src/formatter.js +1 -1
  106. package/dist/src/function-properties.js +1 -1
  107. package/dist/src/generator.js +1 -1
  108. package/dist/src/global-types.js +1 -1
  109. package/dist/src/import-sorter.js +1 -1
  110. package/dist/src/incremental.js +1 -1
  111. package/dist/src/index.js +1 -1
  112. package/dist/src/inferred-imports.js +1 -1
  113. package/dist/src/json-config.js +1 -1
  114. package/dist/src/logger.js +1 -1
  115. package/dist/src/lsp.js +1 -1
  116. package/dist/src/memory.js +1 -1
  117. package/dist/src/merger.js +1 -1
  118. package/dist/src/module-graph.js +1 -1
  119. package/dist/src/native-checker.js +1 -1
  120. package/dist/src/native-engine.js +1 -1
  121. package/dist/src/native-extractor.js +1 -1
  122. package/dist/src/native-generation.js +1 -1
  123. package/dist/src/native-project.js +1 -1
  124. package/dist/src/optimizer.js +1 -1
  125. package/dist/src/output-normalizer.js +1 -1
  126. package/dist/src/parallel-processor.js +1 -1
  127. package/dist/src/parameters.js +1 -1
  128. package/dist/src/parser.js +1 -1
  129. package/dist/src/plugins/bun.js +1 -1
  130. package/dist/src/plugins/esbuild.js +1 -1
  131. package/dist/src/plugins/index.js +1 -1
  132. package/dist/src/plugins/tsdown.js +1 -1
  133. package/dist/src/plugins/tsup.js +1 -1
  134. package/dist/src/plugins/vite.js +1 -1
  135. package/dist/src/plugins/webpack.js +1 -1
  136. package/dist/src/plugins.js +1 -1
  137. package/dist/src/process-source.js +1 -1
  138. package/dist/src/processor/cache.js +1 -1
  139. package/dist/src/processor/comments.js +1 -1
  140. package/dist/src/processor/declarations.js +1 -1
  141. package/dist/src/processor/import-usage.js +1 -1
  142. package/dist/src/processor/imports.js +1 -1
  143. package/dist/src/processor/index.js +1 -1
  144. package/dist/src/processor/type-inference.js +1 -1
  145. package/dist/src/processor.js +1 -1
  146. package/dist/src/profiling.js +1 -1
  147. package/dist/src/return-type-scope.js +1 -1
  148. package/dist/src/security.js +1 -1
  149. package/dist/src/source-cache.js +1 -1
  150. package/dist/src/sourcemap.js +1 -1
  151. package/dist/src/stx.js +1 -1
  152. package/dist/src/syntax-validator.js +1 -1
  153. package/dist/src/tracking.js +1 -1
  154. package/dist/src/transformers.js +1 -1
  155. package/dist/src/tree-shaker.js +1 -1
  156. package/dist/src/tsconfig.js +1 -1
  157. package/dist/src/type-mappings.js +1 -1
  158. package/dist/src/utils.js +1 -1
  159. package/dist/src/value-inference.js +1 -1
  160. package/dist/src/vue.js +1 -1
  161. package/dist/src/watcher.js +1 -1
  162. package/dist/src/worker-thread.js +1 -1
  163. package/dist/src/worker.js +1 -1
  164. package/dist/src/workspace.js +1 -1
  165. package/package.json +1 -1
  166. package/dist/chunk-0azm93j9.js +0 -31
  167. package/dist/chunk-25vyhfzh.js +0 -3
  168. package/dist/chunk-79nv7twc.js +0 -14
  169. package/dist/chunk-cs4gwz1k.js +0 -27
  170. package/dist/chunk-d43bpfk6.js +0 -3
  171. package/dist/chunk-dfye109x.js +0 -3
  172. package/dist/chunk-n94729d9.js +0 -3
  173. package/dist/chunk-p2qz2nk2.js +0 -3
  174. package/dist/chunk-qnf4byak.js +0 -3
  175. package/dist/chunk-rmdwvzgn.js +0 -3
  176. package/dist/chunk-s6c98nad.js +0 -29
  177. package/dist/chunk-t1jtn2r0.js +0 -10
  178. package/dist/chunk-ttc5pr8y.js +0 -37
  179. package/dist/chunk-xb92nrsm.js +0 -3
@@ -1,3 +1,3 @@
1
1
  // @bun
2
- import{s}from"./chunk-0azm93j9.js";function ue(a={}){let{onStart:d=!1,onEnd:l=!0,onGenerated:u,onError:i,...n}=a,e=async()=>{try{let r=await s(n);u?.(r)}catch(r){let t=r instanceof Error?r:Error(String(r));if(i?.(t),!i)console.error("[dtsx] Generation failed:",t.message)}};return{name:"dtsx",setup(r){let t=r.initialOptions;if(!n.entrypoints&&t.entryPoints)if(Array.isArray(t.entryPoints))n.entrypoints=t.entryPoints;else n.entrypoints=Object.values(t.entryPoints);if(!n.outdir){if(t.outdir)n.outdir=t.outdir;else if(t.outfile){let o=t.outfile.lastIndexOf("/");if(o!==-1)n.outdir=t.outfile.substring(0,o)}}if(d)r.onStart(async()=>{await e()});if(l)r.onEnd(async(o)=>{if(o.errors.length===0)await e()})}}}var wa=ue,Zn=ue,xa=ue;
2
+ import{s}from"./chunk-0zfzhn19.js";function ue(a={}){let{onStart:d=!1,onEnd:l=!0,onGenerated:u,onError:i,...n}=a,e=async()=>{try{let r=await s(n);u?.(r)}catch(r){let t=r instanceof Error?r:Error(String(r));if(i?.(t),!i)console.error("[dtsx] Generation failed:",t.message)}};return{name:"dtsx",setup(r){let t=r.initialOptions;if(!n.entrypoints&&t.entryPoints)if(Array.isArray(t.entryPoints))n.entrypoints=t.entryPoints;else n.entrypoints=Object.values(t.entryPoints);if(!n.outdir){if(t.outdir)n.outdir=t.outdir;else if(t.outfile){let o=t.outfile.lastIndexOf("/");if(o!==-1)n.outdir=t.outfile.substring(0,o)}}if(d)r.onStart(async()=>{await e()});if(l)r.onEnd(async(o)=>{if(o.errors.length===0)await e()})}}}var wa=ue,Zn=ue,xa=ue;
3
3
  export{ue,wa,Zn,xa};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
- function d(n,c){let o=1,l=1;for(let i=0;i<c;i++)if(n.charCodeAt(i)===10)o++,l=1;else l++;return{line:o,column:l}}function be(n){let c=[],o=[],l=[],i={")":"(","]":"[","}":"{"},r=0,m=0,f=-1;for(let e=0;e<n.length;e++){let t=n.charCodeAt(e),s=n.charCodeAt(e+1);if(f!==-1){if(t===42&&s===47)o.push({start:f,end:e+2}),f=-1,e++;continue}if(r){if(t===92)e++;else if(t===r)o.push({start:m,end:e+1}),r=0;continue}if(t===47&&s===42){f=e,e++;continue}if(t===47&&s===47){let u=e;while(e<n.length&&n.charCodeAt(e)!==10)e++;o.push({start:u,end:e});continue}if(t===39||t===34||t===96){r=t,m=e;continue}let a=n[e];if(a==="("||a==="["||a==="{")l.push({char:a,offset:e});else if(i[a]){let u=l.pop();if(!u||u.char!==i[a])c.push({...d(n,e),message:`Unexpected closing delimiter ${a}`,code:"DTSX1004"})}}if(r)c.push({...d(n,m),message:"Unterminated string literal",code:"DTSX1002"});if(f!==-1)c.push({...d(n,f),message:"Unterminated block comment",code:"DTSX1003"});for(let e of l)c.push({...d(n,e.offset),message:`Unclosed delimiter ${e.char}`,code:"DTSX1001"});let p=[[/\b(?:interface|class|enum)\s*(?=[{=])/g,"Declaration name expected"],[/\bfunction\s*(?=\()/g,"Function name expected"],[/\(\s*:/g,"Parameter name expected"]];for(let[e,t]of p)for(let s of n.matchAll(e)){if(o.some((a)=>s.index>=a.start&&s.index<a.end))continue;c.push({...d(n,s.index),message:t,code:"DTSX1005"})}for(let e of n.matchAll(/\btype\s*(?=[{=])/g)){if(o.some((s)=>e.index>=s.start&&e.index<s.end))continue;let t=n.slice(0,e.index).trimEnd();if(t.endsWith("import")||t.endsWith("export"))continue;c.push({...d(n,e.index),message:"Declaration name expected",code:"DTSX1005"})}return c.push(...g(n,o)),c.sort((e,t)=>e.line-t.line||e.column-t.column)}var h=String.raw`(?:[\p{ID_Start}$_][\p{ID_Continue}$\u200C\u200D]*|'[^']*'|"[^"]*")`,x=new RegExp(`^(?:type\\s+)?${h}(?:\\s+as\\s+${h})?$`,"u");function g(n,c){let o=[],l=(i)=>c.some((r)=>i>=r.start&&i<r.end);for(let i of n.matchAll(/\b(import|export)\s+(?:type\s+)?\{/g)){let r=i.index;if(l(r))continue;let m=r+i[0].length-1,f=-1;for(let t=m+1;t<n.length;t++){if(l(t))continue;let s=n[t];if(s==="{"){f=-2;break}if(s==="}"){f=t;break}}if(f<0)continue;let p=n.slice(m+1,f);if(!p.trim())continue;let e=m+1;for(let t of p.split(",")){let s=t.trim();if(s){let a=e+t.indexOf(s);if(s.includes(";"))o.push({...d(n,a),message:`Unexpected ';' in ${i[1]} clause \u2014 specifiers are separated by ','`,code:"DTSX1006"});else if(!x.test(s))o.push({...d(n,a),message:`Invalid ${i[1]} specifier '${s}'`,code:"DTSX1006"})}e+=t.length+1}}return o}
3
- export{be};
2
+ function d(n,c){let o=1,l=1;for(let i=0;i<c;i++)if(n.charCodeAt(i)===10)o++,l=1;else l++;return{line:o,column:l}}function me(n){let c=[],o=[],l=[],i={")":"(","]":"[","}":"{"},r=0,m=0,f=-1;for(let e=0;e<n.length;e++){let t=n.charCodeAt(e),s=n.charCodeAt(e+1);if(f!==-1){if(t===42&&s===47)o.push({start:f,end:e+2}),f=-1,e++;continue}if(r){if(t===92)e++;else if(t===r)o.push({start:m,end:e+1}),r=0;continue}if(t===47&&s===42){f=e,e++;continue}if(t===47&&s===47){let u=e;while(e<n.length&&n.charCodeAt(e)!==10)e++;o.push({start:u,end:e});continue}if(t===39||t===34||t===96){r=t,m=e;continue}let a=n[e];if(a==="("||a==="["||a==="{")l.push({char:a,offset:e});else if(i[a]){let u=l.pop();if(!u||u.char!==i[a])c.push({...d(n,e),message:`Unexpected closing delimiter ${a}`,code:"DTSX1004"})}}if(r)c.push({...d(n,m),message:"Unterminated string literal",code:"DTSX1002"});if(f!==-1)c.push({...d(n,f),message:"Unterminated block comment",code:"DTSX1003"});for(let e of l)c.push({...d(n,e.offset),message:`Unclosed delimiter ${e.char}`,code:"DTSX1001"});let p=[[/\b(?:interface|class|enum)\s*(?=[{=])/g,"Declaration name expected"],[/\bfunction\s*(?=\()/g,"Function name expected"],[/\(\s*:/g,"Parameter name expected"]];for(let[e,t]of p)for(let s of n.matchAll(e)){if(o.some((a)=>s.index>=a.start&&s.index<a.end))continue;c.push({...d(n,s.index),message:t,code:"DTSX1005"})}for(let e of n.matchAll(/\btype\s*(?=[{=])/g)){if(o.some((s)=>e.index>=s.start&&e.index<s.end))continue;let t=n.slice(0,e.index).trimEnd();if(t.endsWith("import")||t.endsWith("export"))continue;c.push({...d(n,e.index),message:"Declaration name expected",code:"DTSX1005"})}return c.push(...g(n,o)),c.sort((e,t)=>e.line-t.line||e.column-t.column)}var h=String.raw`(?:[\p{ID_Start}$_][\p{ID_Continue}$\u200C\u200D]*|'[^']*'|"[^"]*")`,x=new RegExp(`^(?:type\\s+)?${h}(?:\\s+as\\s+${h})?$`,"u");function g(n,c){let o=[],l=(i)=>c.some((r)=>i>=r.start&&i<r.end);for(let i of n.matchAll(/\b(import|export)\s+(?:type\s+)?\{/g)){let r=i.index;if(l(r))continue;let m=r+i[0].length-1,f=-1;for(let t=m+1;t<n.length;t++){if(l(t))continue;let s=n[t];if(s==="{"){f=-2;break}if(s==="}"){f=t;break}}if(f<0)continue;let p=n.slice(m+1,f);if(!p.trim())continue;let e=m+1;for(let t of p.split(",")){let s=t.trim();if(s){let a=e+t.indexOf(s);if(s.includes(";"))o.push({...d(n,a),message:`Unexpected ';' in ${i[1]} clause \u2014 specifiers are separated by ','`,code:"DTSX1006"});else if(!x.test(s))o.push({...d(n,a),message:`Invalid ${i[1]} specifier '${s}'`,code:"DTSX1006"})}e+=t.length+1}}return o}
3
+ export{me};
@@ -1,8 +1,8 @@
1
1
  // @bun
2
- import{he}from"./chunk-xb92nrsm.js";import{e}from"./chunk-km8t8gqg.js";import{De,V}from"./chunk-d43bpfk6.js";import{existsSync as S}from"fs";import{basename as D,dirname as M,extname as R,isAbsolute as b,relative as p,resolve as m}from"path";var{Glob:j}=globalThis.Bun;async function me(r,o){let s=await N(r);F(r,s);let n=s.slice(),a=await(o?o():De(r)),t=null;if(r.autoIncludeReExports!==!1&&n.length>0){t=await V(n,{includeImports:!0,resolveSpecifier:a});let l=m(r.cwd,r.root),u=r.exclude||[],f=[];for(let c of t.reachable){if(n.includes(c))continue;if(!x(c))continue;if(c.endsWith(".d.ts"))continue;if(c.includes("node_modules"))continue;let E=r.outputStructure==="flat"&&s.some((O)=>a.isPackageLocal?.(O,c));if(!v(c,l)&&!E){e.warn(`Skipping auto-included source outside root: ${p(r.cwd,c)}`);continue}if(J(c,u,l))continue;f.push(c)}if(f.length>0)n=[...n,...f],e.debug(`Auto-included ${f.length} file(s) reached via relative re-exports`)}let i=A(n,r),d=t??await V(n,{includeImports:!0,resolveSpecifier:a}),g=await he([...d.sources.keys()],a,r.isolatedDeclarations??!1,d.sources),h=new Set(n);for(let[l,u]of g){if(!h.has(l))continue;for(let f of u){let c=a(f,l).resolved;if(c&&!h.has(c))throw Error(`Module augmentation import ${JSON.stringify(f)} from ${l} requires a source not emitted by this package build: ${c}`)}}let y=[...g].map(([l,u])=>[l,[...u].sort()]).sort(([l],[u])=>l.localeCompare(u));return Object.freeze({entryFiles:Object.freeze(s),files:Object.freeze(n),outputBySource:i,resolver:a,reachability:t,augmentationImports:g,getResolutionFingerprint:()=>JSON.stringify({resolution:a.cacheKey?.(n),augmentations:y})})}var P=50,w=new Map;function k(r){let o=w.get(r);if(!o){if(o=new j(r),w.set(r,o),w.size>P){let s=w.keys().next().value;if(s!==void 0)w.delete(s)}}return o}function J(r,o,s){if(!o||o.length===0)return!1;let n=p(s,r);for(let a of o){let t=k(a);if(t.match(n)||t.match(r))return!0}return!1}var C=/[*?[\]{}!]/;function F(r,o){let s=m(r.cwd,r.root),n=` root: ${s}
2
+ import{we}from"./chunk-g2120ysy.js";import{e}from"./chunk-yay68832.js";import{Ce,V}from"./chunk-p9vfxn8g.js";import{existsSync as x}from"fs";import{basename as D,dirname as M,extname as R,isAbsolute as v,relative as p,resolve as m}from"path";var{Glob:j}=globalThis.Bun;async function ye(r,o){let s=await N(r);F(r,s);let n=s.slice(),a=await(o?o():Ce(r)),t=null;if(r.autoIncludeReExports!==!1&&n.length>0){t=await V(n,{includeImports:!0,resolveSpecifier:a});let l=m(r.cwd,r.root),u=r.exclude||[],f=[];for(let c of t.reachable){if(n.includes(c))continue;if(!b(c))continue;if(c.endsWith(".d.ts"))continue;if(c.includes("node_modules"))continue;let E=r.outputStructure==="flat"&&s.some((O)=>a.isPackageLocal?.(O,c));if(!S(c,l)&&!E){e.warn(`Skipping auto-included source outside root: ${p(r.cwd,c)}`);continue}if(J(c,u,l))continue;f.push(c)}if(f.length>0)n=[...n,...f],e.debug(`Auto-included ${f.length} file(s) reached via relative re-exports`)}let i=A(n,r),d=t??await V(n,{includeImports:!0,resolveSpecifier:a}),g=await we([...d.sources.keys()],a,r.isolatedDeclarations??!1,d.sources),h=new Set(n);for(let[l,u]of g){if(!h.has(l))continue;for(let f of u){let c=a(f,l).resolved;if(c&&!h.has(c))throw Error(`Module augmentation import ${JSON.stringify(f)} from ${l} requires a source not emitted by this package build: ${c}`)}}let y=[...g].map(([l,u])=>[l,[...u].sort()]).sort(([l],[u])=>l.localeCompare(u));return Object.freeze({entryFiles:Object.freeze(s),files:Object.freeze(n),outputBySource:i,resolver:a,reachability:t,augmentationImports:g,getResolutionFingerprint:()=>JSON.stringify({resolution:a.cacheKey?.(n),augmentations:y})})}var P=50,w=new Map;function k(r){let o=w.get(r);if(!o){if(o=new j(r),w.set(r,o),w.size>P){let s=w.keys().next().value;if(s!==void 0)w.delete(s)}}return o}function J(r,o,s){if(!o||o.length===0)return!1;let n=p(s,r);for(let a of o){let t=k(a);if(t.match(n)||t.match(r))return!0}return!1}var C=/[*?[\]{}!]/;function F(r,o){let s=m(r.cwd,r.root),n=` root: ${s}
3
3
  entrypoints: ${r.entrypoints.map((t)=>JSON.stringify(t)).join(", ")||"(none)"}
4
4
  `+(r.exclude?.length?` exclude: ${r.exclude.map((t)=>JSON.stringify(t)).join(", ")}
5
- `:"")+"Entrypoints are resolved relative to --root. Pass several by repeating --entrypoints or separating them with commas.";if(o.length===0){if(r.entrypoints.filter((i)=>b(i)&&S(i)&&!v(i,s)).length===r.entrypoints.length)return;throw Error(`No source files matched. Nothing was generated.
6
- ${n}`)}let a=r.entrypoints.filter((t)=>{if(C.test(t))return!1;return!S(b(t)?t:m(s,t))});if(a.length>0)throw Error(`Entrypoint${a.length>1?"s":""} not found: ${a.map((t)=>JSON.stringify(t)).join(", ")}
7
- ${n}`)}async function N(r){let o=[],s=m(r.cwd,r.root),n=r.exclude||[],a=[...r.entrypoints,...r.include??[]];for(let t of a)if(b(t)&&x(t)){if(!t.includes("node_modules")){if(!v(t,s)&&r.outputStructure!=="flat")e.warn(`Skipping entrypoint outside root: ${p(r.cwd,t)}`);else if(!J(t,n,s))o.push(t)}}else{let i=new j(t);for await(let d of i.scan({cwd:s,absolute:!0,onlyFiles:!0}))if(x(d)&&!d.includes("node_modules")){if(!J(d,n,s))o.push(d)}}return[...new Set(o.map((t)=>m(t)))].sort()}function v(r,o){let s=p(o,r);return s!==".."&&!s.startsWith(`..${process.platform==="win32"?"\\":"/"}`)&&!b(s)}function A(r,o){let s=new Map,n=new Map;for(let a of r){let t=G(a,o),i=s.get(t);if(i&&i!==a)throw Error(`Output path collision: ${p(o.cwd,i)} and ${p(o.cwd,a)} both emit ${p(o.cwd,t)}`);s.set(t,a),n.set(a,t)}return n}function x(r){return/\.(m?tsx?|cts|jsx?|mjs|cjs|vue|stx)$/.test(r)&&!/\.d\.(?:ts|mts|cts)$/.test(r)}function G(r,o){let s=m(o.cwd,o.root),n=p(s,r),a=/\.d\.(?:ts|mts|cts)$/.test(n)?n:n.replace(/\.(m?tsx?|cts|jsx?|mjs|cjs|vue|stx)$/,(t)=>{if(t===".mts"||t===".mjs")return".d.mts";if(t===".cts"||t===".cjs")return".d.cts";return".d.ts"});if(o.outputStructure==="mirror")return m(o.cwd,o.outdir,a);else{let t=D(a);return m(o.cwd,o.outdir,t)}}function Eo(r,o,s=""){let n=p(M(r),o).replace(/\\/g,"/");if(n=n.replace(/\.d\.mts$/,"").replace(/\.d\.cts$/,"").replace(/\.d\.ts$/,""),s)n+=s;if(!n.startsWith("."))n=`./${n}`;return n}function ge(r,o,s,n){let a=G(r,o);return(t)=>{let i=s(t,r);if(!i.isRelative||!i.resolved)return{kind:"unchanged",reason:i.isRelative?"unresolved":"external",specifier:t,emittedSpecifier:t};if(/\.d\.(?:ts|mts|cts)$/.test(i.resolved)){if(o.moduleSpecifierMode!=="node")return{kind:"unchanged",reason:"preserved-declaration",specifier:t,emittedSpecifier:t};if(n&&!n.has(i.resolved))throw Error(`Local declaration ${JSON.stringify(t)} from ${r} targets an authored declaration not emitted by this package build: ${i.resolved}. Declaration-only dependencies must be delivered with the package before this importer can be emitted.`)}if(i.isAlias&&n&&!n.has(i.resolved))throw Error(`Local alias ${JSON.stringify(t)} from ${r} targets a declaration excluded from this package build: ${i.resolved}`);if(n&&!n.has(i.resolved)&&J(i.resolved,o.exclude??[],m(o.cwd,o.root)))throw Error(`Local reference ${JSON.stringify(t)} from ${r} targets a source excluded from this package build: ${i.resolved}`);let d=i.isAlias?i.suffix??"":t.match(/[?#].*$/)?.[0]??"",g=d?t.slice(0,-d.length):t,h=R(g),y=/^(?:\.js|\.jsx|\.mjs|\.cjs)$/.test(h)?h:"";if(!y&&o.moduleSpecifierMode==="node"){let u=R(i.resolved);y=u===".mts"||u===".mjs"?".mjs":u===".cts"||u===".cjs"?".cjs":".js"}let l=G(i.resolved,o);return{kind:"local",specifier:t,resolvedSource:i.resolved,declarationOutput:l,emittedSpecifier:Eo(a,l,y)+d}}}
8
- export{me,J,v,G,Eo,ge};
5
+ `:"")+"Entrypoints are resolved relative to --root. Pass several by repeating --entrypoints or separating them with commas.";if(o.length===0){if(r.entrypoints.filter((i)=>v(i)&&x(i)&&!S(i,s)).length===r.entrypoints.length)return;throw Error(`No source files matched. Nothing was generated.
6
+ ${n}`)}let a=r.entrypoints.filter((t)=>{if(C.test(t))return!1;return!x(v(t)?t:m(s,t))});if(a.length>0)throw Error(`Entrypoint${a.length>1?"s":""} not found: ${a.map((t)=>JSON.stringify(t)).join(", ")}
7
+ ${n}`)}async function N(r){let o=[],s=m(r.cwd,r.root),n=r.exclude||[],a=[...r.entrypoints,...r.include??[]];for(let t of a)if(v(t)&&b(t)){if(!t.includes("node_modules")){if(!S(t,s)&&r.outputStructure!=="flat")e.warn(`Skipping entrypoint outside root: ${p(r.cwd,t)}`);else if(!J(t,n,s))o.push(t)}}else{let i=new j(t);for await(let d of i.scan({cwd:s,absolute:!0,onlyFiles:!0}))if(b(d)&&!d.includes("node_modules")){if(!J(d,n,s))o.push(d)}}return[...new Set(o.map((t)=>m(t)))].sort()}function S(r,o){let s=p(o,r);return s!==".."&&!s.startsWith(`..${process.platform==="win32"?"\\":"/"}`)&&!v(s)}function A(r,o){let s=new Map,n=new Map;for(let a of r){let t=G(a,o),i=s.get(t);if(i&&i!==a)throw Error(`Output path collision: ${p(o.cwd,i)} and ${p(o.cwd,a)} both emit ${p(o.cwd,t)}`);s.set(t,a),n.set(a,t)}return n}function b(r){return/\.(m?tsx?|cts|jsx?|mjs|cjs|vue|stx)$/.test(r)&&!/\.d\.(?:ts|mts|cts)$/.test(r)}function G(r,o){let s=m(o.cwd,o.root),n=p(s,r),a=/\.d\.(?:ts|mts|cts)$/.test(n)?n:n.replace(/\.(m?tsx?|cts|jsx?|mjs|cjs|vue|stx)$/,(t)=>{if(t===".mts"||t===".mjs")return".d.mts";if(t===".cts"||t===".cjs")return".d.cts";return".d.ts"});if(o.outputStructure==="mirror")return m(o.cwd,o.outdir,a);else{let t=D(a);return m(o.cwd,o.outdir,t)}}function Vo(r,o,s=""){let n=p(M(r),o).replace(/\\/g,"/");if(n=n.replace(/\.d\.mts$/,"").replace(/\.d\.cts$/,"").replace(/\.d\.ts$/,""),s)n+=s;if(!n.startsWith("."))n=`./${n}`;return n}function be(r,o,s,n){let a=G(r,o);return(t)=>{let i=s(t,r);if(!i.isRelative||!i.resolved)return{kind:"unchanged",reason:i.isRelative?"unresolved":"external",specifier:t,emittedSpecifier:t};if(/\.d\.(?:ts|mts|cts)$/.test(i.resolved)){if(o.moduleSpecifierMode!=="node")return{kind:"unchanged",reason:"preserved-declaration",specifier:t,emittedSpecifier:t};if(n&&!n.has(i.resolved))throw Error(`Local declaration ${JSON.stringify(t)} from ${r} targets an authored declaration not emitted by this package build: ${i.resolved}. Declaration-only dependencies must be delivered with the package before this importer can be emitted.`)}if(i.isAlias&&n&&!n.has(i.resolved))throw Error(`Local alias ${JSON.stringify(t)} from ${r} targets a declaration excluded from this package build: ${i.resolved}`);if(n&&!n.has(i.resolved)&&J(i.resolved,o.exclude??[],m(o.cwd,o.root)))throw Error(`Local reference ${JSON.stringify(t)} from ${r} targets a source excluded from this package build: ${i.resolved}`);let d=i.isAlias?i.suffix??"":t.match(/[?#].*$/)?.[0]??"",g=d?t.slice(0,-d.length):t,h=R(g),y=/^(?:\.js|\.jsx|\.mjs|\.cjs)$/.test(h)?h:"";if(!y&&o.moduleSpecifierMode==="node"){let u=R(i.resolved);y=u===".mts"||u===".mjs"?".mjs":u===".cts"||u===".cjs"?".cjs":".js"}let l=G(i.resolved,o);return{kind:"local",specifier:t,resolvedSource:i.resolved,declarationOutput:l,emittedSpecifier:Vo(a,l,y)+d}}}
8
+ export{ye,J,S,G,Vo,be};
@@ -1,7 +1,7 @@
1
1
  // @bun
2
- import{ae}from"./chunk-dfye109x.js";function M(n,t){let e=n.length,i=t.length,o=Array.from({length:e+1},()=>Array(i+1).fill(0));for(let s=1;s<=e;s++)for(let r=1;r<=i;r++)if(n[s-1]===t[r-1])o[s][r]=o[s-1][r-1]+1;else o[s][r]=Math.max(o[s-1][r],o[s][r-1]);return o}function S(n,t,e,i,o){let s=[];while(i>0||o>0)if(i>0&&o>0&&t[i-1]===e[o-1])s.unshift({op:"equal",oldIdx:i-1,newIdx:o-1,line:t[i-1]}),i--,o--;else if(o>0&&(i===0||n[i][o-1]>=n[i-1][o]))s.unshift({op:"add",newIdx:o-1,line:e[o-1]}),o--;else if(i>0)s.unshift({op:"remove",oldIdx:i-1,line:t[i-1]}),i--;return s}function k(n,t){let e=n;if(t.ignoreWhitespace)e=e.replace(/\s+/g," ").trim();return e}function ut(n,t,e,i={}){let{context:o=3,ignoreWhitespace:s=!1,ignoreBlankLines:r=!1}=i,f=n.split(`
2
+ import{Z}from"./chunk-73dzve1s.js";function M(n,t){let e=n.length,i=t.length,o=Array.from({length:e+1},()=>Array(i+1).fill(0));for(let s=1;s<=e;s++)for(let r=1;r<=i;r++)if(n[s-1]===t[r-1])o[s][r]=o[s-1][r-1]+1;else o[s][r]=Math.max(o[s-1][r],o[s][r-1]);return o}function S(n,t,e,i,o){let s=[];while(i>0||o>0)if(i>0&&o>0&&t[i-1]===e[o-1])s.unshift({op:"equal",oldIdx:i-1,newIdx:o-1,line:t[i-1]}),i--,o--;else if(o>0&&(i===0||n[i][o-1]>=n[i-1][o]))s.unshift({op:"add",newIdx:o-1,line:e[o-1]}),o--;else if(i>0)s.unshift({op:"remove",oldIdx:i-1,line:t[i-1]}),i--;return s}function k(n,t){let e=n;if(t.ignoreWhitespace)e=e.replace(/\s+/g," ").trim();return e}function ot(n,t,e,i={}){let{context:o=3,ignoreWhitespace:s=!1,ignoreBlankLines:r=!1}=i,f=n.split(`
3
3
  `),p=t.split(`
4
- `);if(f[f.length-1]==="")f.pop();if(p[p.length-1]==="")p.pop();let d=f.map((l)=>k(l,{ignoreWhitespace:s})),a=p.map((l)=>k(l,{ignoreWhitespace:s})),c=d,g=a,w=f.map((l,x)=>x),m=p.map((l,x)=>x);if(r)c=[],g=[],w=[],m=[],d.forEach((l,x)=>{if(l.trim())c.push(l),w.push(x)}),a.forEach((l,x)=>{if(l.trim())g.push(l),m.push(x)});let F=M(c,g),b=S(F,c,g,c.length,g.length),B=b.every((l)=>l.op==="equal"),D=0,u=0,h=0;for(let l of b)if(l.op==="add")D++;else if(l.op==="remove")u++;else h++;let y=C(b,f,p,w,m,o);return{filePath:e,identical:B,hunks:y,stats:{additions:D,deletions:u,unchanged:h},oldContent:n,newContent:t}}function C(n,t,e,i,o,s){let r=[],f=[];if(n.forEach((a,c)=>{if(a.op!=="equal")f.push(c)}),f.length===0)return r;let p=[],d=[f[0]];for(let a=1;a<f.length;a++)if(f[a]-f[a-1]<=s*2+1)d.push(f[a]);else p.push(d),d=[f[a]];p.push(d);for(let a of p){let c=Math.max(0,a[0]-s),g=Math.min(n.length-1,a[a.length-1]+s),w=n.slice(c,g+1),m=[],F=1,b=1,B=0,D=0;for(let u=0;u<c;u++){let h=n[u];if(h.op==="equal"||h.op==="remove")F++;if(h.op==="equal"||h.op==="add")b++}for(let u of w)if(u.op==="equal")m.push(` ${u.line}`),B++,D++;else if(u.op==="remove")m.push(`-${u.line}`),B++;else if(u.op==="add")m.push(`+${u.line}`),D++;r.push({operation:"equal",lines:m,oldStart:F,oldCount:B,newStart:b,newCount:D})}return r}function Ps(n){if(n.identical)return"";let t=[];t.push(`--- a/${n.filePath}`),t.push(`+++ b/${n.filePath}`);for(let e of n.hunks)t.push(`@@ -${e.oldStart},${e.oldCount} +${e.newStart},${e.newCount} @@`),t.push(...e.lines);return t.join(`
5
- `)}function Mr(n){if(n.identical)return`\x1B[32m\u2713 ${n.filePath} (unchanged)\x1B[0m`;let t=[],e=`+${n.stats.additions} -${n.stats.deletions}`;t.push(`\x1B[1m${n.filePath}\x1B[0m \x1B[90m(${e})\x1B[0m`),t.push("");for(let i of n.hunks){t.push(`\x1B[36m@@ -${i.oldStart},${i.oldCount} +${i.newStart},${i.newCount} @@\x1B[0m`);for(let o of i.lines)if(o.startsWith("+"))t.push(`\x1B[32m${o}\x1B[0m`);else if(o.startsWith("-"))t.push(`\x1B[31m${o}\x1B[0m`);else t.push(`\x1B[90m${o}\x1B[0m`);t.push("")}return t.join(`
6
- `)}function Ds(n){if(n.identical)return`${n.filePath}: unchanged`;return`${n.filePath}: +${n.stats.additions} -${n.stats.deletions} lines`}async function Or(n,t,e={}){let i="";try{let o=ae(n);if(await o.exists())i=await o.text();else if(!e.treatMissingAsEmpty)return ut("",t,n,e)}catch{if(!e.treatMissingAsEmpty)return ut("",t,n,e)}return ut(i,t,n,e)}async function Rs(n,t={}){let e=new Map;for(let[i,o]of n){let s=await Or(i,o,t);e.set(i,s)}return e}function Ir(n){let t=0,e=0,i=0,o=0,s=0;for(let r of n.values())if(r.identical)e++;else if(t++,i+=r.stats.additions,o+=r.stats.deletions,!r.oldContent)s++;return{totalFiles:n.size,changedFiles:t,unchangedFiles:e,totalAdditions:i,totalDeletions:o,newFiles:s}}function Fr(n){console.log(Mr(n))}function Ms(n,t=!1){for(let i of n.values()){if(i.identical&&!t)continue;Fr(i)}let e=Ir(n);if(console.log(""),console.log(`\x1B[1mSummary:\x1B[0m ${e.totalFiles} files, ${e.changedFiles} changed, ${e.unchangedFiles} unchanged`),e.changedFiles>0)console.log(` \x1B[32m+${e.totalAdditions}\x1B[0m \x1B[31m-${e.totalDeletions}\x1B[0m lines`);if(e.newFiles>0)console.log(` ${e.newFiles} new files`)}
7
- export{ut,Ps,Mr,Ds,Or,Rs,Ir,Fr,Ms};
4
+ `);if(f[f.length-1]==="")f.pop();if(p[p.length-1]==="")p.pop();let d=f.map((l)=>k(l,{ignoreWhitespace:s})),a=p.map((l)=>k(l,{ignoreWhitespace:s})),c=d,g=a,w=f.map((l,x)=>x),m=p.map((l,x)=>x);if(r)c=[],g=[],w=[],m=[],d.forEach((l,x)=>{if(l.trim())c.push(l),w.push(x)}),a.forEach((l,x)=>{if(l.trim())g.push(l),m.push(x)});let F=M(c,g),b=S(F,c,g,c.length,g.length),B=b.every((l)=>l.op==="equal"),D=0,u=0,h=0;for(let l of b)if(l.op==="add")D++;else if(l.op==="remove")u++;else h++;let y=C(b,f,p,w,m,o);return{filePath:e,identical:B,hunks:y,stats:{additions:D,deletions:u,unchanged:h},oldContent:n,newContent:t}}function C(n,t,e,i,o,s){let r=[],f=[];if(n.forEach((a,c)=>{if(a.op!=="equal")f.push(c)}),f.length===0)return r;let p=[],d=[f[0]];for(let a=1;a<f.length;a++)if(f[a]-f[a-1]<=s*2+1)d.push(f[a]);else p.push(d),d=[f[a]];p.push(d);for(let a of p){let c=Math.max(0,a[0]-s),g=Math.min(n.length-1,a[a.length-1]+s),w=n.slice(c,g+1),m=[],F=1,b=1,B=0,D=0;for(let u=0;u<c;u++){let h=n[u];if(h.op==="equal"||h.op==="remove")F++;if(h.op==="equal"||h.op==="add")b++}for(let u of w)if(u.op==="equal")m.push(` ${u.line}`),B++,D++;else if(u.op==="remove")m.push(`-${u.line}`),B++;else if(u.op==="add")m.push(`+${u.line}`),D++;r.push({operation:"equal",lines:m,oldStart:F,oldCount:B,newStart:b,newCount:D})}return r}function _i(n){if(n.identical)return"";let t=[];t.push(`--- a/${n.filePath}`),t.push(`+++ b/${n.filePath}`);for(let e of n.hunks)t.push(`@@ -${e.oldStart},${e.oldCount} +${e.newStart},${e.newCount} @@`),t.push(...e.lines);return t.join(`
5
+ `)}function ir(n){if(n.identical)return`\x1B[32m\u2713 ${n.filePath} (unchanged)\x1B[0m`;let t=[],e=`+${n.stats.additions} -${n.stats.deletions}`;t.push(`\x1B[1m${n.filePath}\x1B[0m \x1B[90m(${e})\x1B[0m`),t.push("");for(let i of n.hunks){t.push(`\x1B[36m@@ -${i.oldStart},${i.oldCount} +${i.newStart},${i.newCount} @@\x1B[0m`);for(let o of i.lines)if(o.startsWith("+"))t.push(`\x1B[32m${o}\x1B[0m`);else if(o.startsWith("-"))t.push(`\x1B[31m${o}\x1B[0m`);else t.push(`\x1B[90m${o}\x1B[0m`);t.push("")}return t.join(`
6
+ `)}function Gi(n){if(n.identical)return`${n.filePath}: unchanged`;return`${n.filePath}: +${n.stats.additions} -${n.stats.deletions} lines`}async function sr(n,t,e={}){let i="";try{let o=Z(n);if(await o.exists())i=await o.text();else if(!e.treatMissingAsEmpty)return ot("",t,n,e)}catch{if(!e.treatMissingAsEmpty)return ot("",t,n,e)}return ot(i,t,n,e)}async function Vi(n,t={}){let e=new Map;for(let[i,o]of n){let s=await sr(i,o,t);e.set(i,s)}return e}function or(n){let t=0,e=0,i=0,o=0,s=0;for(let r of n.values())if(r.identical)e++;else if(t++,i+=r.stats.additions,o+=r.stats.deletions,!r.oldContent)s++;return{totalFiles:n.size,changedFiles:t,unchangedFiles:e,totalAdditions:i,totalDeletions:o,newFiles:s}}function ar(n){console.log(ir(n))}function Ui(n,t=!1){for(let i of n.values()){if(i.identical&&!t)continue;ar(i)}let e=or(n);if(console.log(""),console.log(`\x1B[1mSummary:\x1B[0m ${e.totalFiles} files, ${e.changedFiles} changed, ${e.unchangedFiles} unchanged`),e.changedFiles>0)console.log(` \x1B[32m+${e.totalAdditions}\x1B[0m \x1B[31m-${e.totalDeletions}\x1B[0m lines`);if(e.newFiles>0)console.log(` ${e.newFiles} new files`)}
7
+ export{ot,_i,ir,Gi,sr,Vi,or,ar,Ui};
@@ -5,5 +5,5 @@ function rt(e,r={}){let{entryPoints:n,keepExported:s=!0,keep:t=[],remove:l=[],sh
5
5
  `)}),t=null}}if(s.length===0)return{content:e,removed:[]};let l=s.map((i)=>({name:i.name,kind:i.kind,isExported:i.isExported,text:i.text})),c=rt(l,r),m=new Set(c.declarations.map((i)=>i.name)),p=new Set;for(let i of s)if(!m.has(i.name))for(let o=i.start;o<=i.end;o++)p.add(o);return{content:n.filter((i,o)=>!p.has(o)).join(`
6
6
  `).replace(/\n{3,}/g,`
7
7
 
8
- `),removed:c.removed}}function nr(e,r={}){return rt(e,{...r,debug:!1}).removed}function rr(e,r){let n=it(r),s=n.get(e)||new Set,t=T(new Set([e]),n);t.delete(e);let l=[];for(let[c,m]of n)if(c!==e&&m.has(e))l.push(c);return{directDependencies:Array.from(s),transitiveDependencies:Array.from(t),dependents:l}}function Ai(e={}){return{shake:(r)=>rt(r,e),shakeContent:(r)=>tr(r,e),findUnused:(r)=>nr(r,e),analyzeDependencies:(r,n)=>rr(r,n),buildGraph:it,extractRefs:st}}
9
- export{rt,it,st,tr,nr,rr,Ai};
8
+ `),removed:c.removed}}function nr(e,r={}){return rt(e,{...r,debug:!1}).removed}function rr(e,r){let n=it(r),s=n.get(e)||new Set,t=T(new Set([e]),n);t.delete(e);let l=[];for(let[c,m]of n)if(c!==e&&m.has(e))l.push(c);return{directDependencies:Array.from(s),transitiveDependencies:Array.from(t),dependents:l}}function ji(e={}){return{shake:(r)=>rt(r,e),shakeContent:(r)=>tr(r,e),findUnused:(r)=>nr(r,e),analyzeDependencies:(r,n)=>rr(r,n),buildGraph:it,extractRefs:st}}
9
+ export{rt,it,st,tr,nr,rr,ji};