@visulima/vis 1.0.0-alpha.45 → 1.0.0-alpha.46

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 (113) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/bin.js +1 -1
  3. package/dist/binx.js +1 -1
  4. package/dist/packem_chunks/CONFIG_FILES.js +3 -3
  5. package/dist/packem_chunks/agent-instructions.js +11 -0
  6. package/dist/packem_chunks/bloom-status.js +1 -1
  7. package/dist/packem_chunks/bloom-sync.js +1 -1
  8. package/dist/packem_chunks/catalog.js +1 -1
  9. package/dist/packem_chunks/cli-exec.js +1 -1
  10. package/dist/packem_chunks/cli-main.js +23 -23
  11. package/dist/packem_chunks/defineReleasePlugin.js +3 -0
  12. package/dist/packem_chunks/fix.js +1 -1
  13. package/dist/packem_chunks/group-tags.js +1 -0
  14. package/dist/packem_chunks/handler10.js +1 -1
  15. package/dist/packem_chunks/handler12.js +1 -1
  16. package/dist/packem_chunks/handler13.js +1 -1
  17. package/dist/packem_chunks/handler14.js +1 -1
  18. package/dist/packem_chunks/handler15.js +1 -1
  19. package/dist/packem_chunks/handler19.js +1 -1
  20. package/dist/packem_chunks/handler20.js +1 -1
  21. package/dist/packem_chunks/handler21.js +1 -1
  22. package/dist/packem_chunks/handler24.js +1 -1
  23. package/dist/packem_chunks/handler26.js +1 -1
  24. package/dist/packem_chunks/handler28.js +1 -1
  25. package/dist/packem_chunks/handler32.js +1 -1
  26. package/dist/packem_chunks/handler4.js +1 -1
  27. package/dist/packem_chunks/handler40.js +19 -19
  28. package/dist/packem_chunks/handler5.js +1 -1
  29. package/dist/packem_chunks/handler50.js +1 -1
  30. package/dist/packem_chunks/handler51.js +1 -1
  31. package/dist/packem_chunks/handler54.js +1 -1
  32. package/dist/packem_chunks/handler57.js +11 -5
  33. package/dist/packem_chunks/handler58.js +5 -11
  34. package/dist/packem_chunks/handler59.js +11 -3
  35. package/dist/packem_chunks/handler6.js +1 -1
  36. package/dist/packem_chunks/handler60.js +3 -22
  37. package/dist/packem_chunks/handler61.js +21 -60
  38. package/dist/packem_chunks/handler62.js +61 -3
  39. package/dist/packem_chunks/handler63.js +3 -6
  40. package/dist/packem_chunks/handler64.js +6 -9
  41. package/dist/packem_chunks/handler65.js +9 -2
  42. package/dist/packem_chunks/handler66.js +2 -24
  43. package/dist/packem_chunks/handler67.js +24 -25
  44. package/dist/packem_chunks/handler68.js +25 -153
  45. package/dist/packem_chunks/handler69.js +153 -10
  46. package/dist/packem_chunks/handler7.js +1 -1
  47. package/dist/packem_chunks/handler70.js +10 -23
  48. package/dist/packem_chunks/handler71.js +23 -322
  49. package/dist/packem_chunks/handler72.js +273 -659
  50. package/dist/packem_chunks/handler73.js +708 -48
  51. package/dist/packem_chunks/handler74.js +48 -27
  52. package/dist/packem_chunks/handler75.js +27 -3
  53. package/dist/packem_chunks/handler76.js +3 -190
  54. package/dist/packem_chunks/handler77.js +189 -37
  55. package/dist/packem_chunks/handler78.js +38 -0
  56. package/dist/packem_chunks/heal.js +1 -1
  57. package/dist/packem_chunks/help-command.js +1 -1
  58. package/dist/packem_chunks/index3.js +1 -1
  59. package/dist/packem_chunks/keys-refresh.js +1 -1
  60. package/dist/packem_chunks/list.js +1 -1
  61. package/dist/packem_chunks/orchestrator.js +26 -23
  62. package/dist/packem_chunks/prune.js +1 -1
  63. package/dist/packem_chunks/state.js +3 -3
  64. package/dist/packem_chunks/status.js +1 -1
  65. package/dist/packem_chunks/sync.js +1 -1
  66. package/dist/packem_chunks/sync2.js +1 -1
  67. package/dist/packem_chunks/tripwire.js +1 -1
  68. package/dist/packem_chunks/verify-lockfile.js +1 -1
  69. package/dist/packem_shared/ReleaseClient-BY4OZNCK.js +1 -0
  70. package/dist/packem_shared/{Table-BGIHvenQ-D2oJtNQj.js → Table-CcVkyULl-DLWu6XHL.js} +1 -1
  71. package/dist/packem_shared/{advisories-CefYKEPe.js → advisories-B76fBVL-.js} +1 -1
  72. package/dist/packem_shared/{ai-analysis-rC48NLfB.js → ai-analysis-DF_AfeS3.js} +1 -1
  73. package/dist/packem_shared/{ai-fix-D_ijV3Rn.js → ai-fix-D1bFLkfk.js} +1 -1
  74. package/dist/packem_shared/{bin-CPMo34SM.js → bin-BlGVEhl8.js} +1 -1
  75. package/dist/packem_shared/{build-scripts-MTSK6TNr.js → build-scripts-q__dKE2y.js} +1 -1
  76. package/dist/packem_shared/{cyclonedx-BeUmPgfO.js → cyclonedx-CmrYQ0vx.js} +1 -1
  77. package/dist/packem_shared/{docker-CViFYtmM.js → docker-BYqiD711.js} +1 -1
  78. package/dist/packem_shared/{env-Ct3hMEYB.js → env-DJlbJiFh.js} +1 -1
  79. package/dist/packem_shared/{failure-log-Dy2G-rKi.js → failure-log-Bt7sW4p7.js} +1 -1
  80. package/dist/packem_shared/{index-XAb0QGqA.js → index-C6tpgeIV.js} +2 -2
  81. package/dist/packem_shared/{index-Cntyu-w8.js → index-D6fJJDli.js} +1 -1
  82. package/dist/packem_shared/{lifecycle-CHcFuWf_.js → lifecycle-XeMei1ED.js} +1 -1
  83. package/dist/packem_shared/{manifests-WBnsV_Eb.js → manifests-DSBr3-dw.js} +1 -1
  84. package/dist/packem_shared/{native-config-sync-BFDVK9LH.js → native-config-sync-D-z2Uwqu.js} +1 -1
  85. package/dist/packem_shared/{osv-bloom-DVMlkcAO.js → osv-bloom-DMhXP184.js} +1 -1
  86. package/dist/packem_shared/{packument-C-A3Uhhx.js → packument-CY2QDFml.js} +1 -1
  87. package/dist/packem_shared/plugins.d-ND23R9I3.d.ts +4 -0
  88. package/dist/packem_shared/{provenance-R2csDSNg.js → provenance-DVHiWZrW.js} +1 -1
  89. package/dist/packem_shared/{registry-keys-CMnS_Qt_.js → registry-keys-BKEq72qX.js} +1 -1
  90. package/dist/packem_shared/{resolve-explicit-C4oQMyoB.js → resolve-explicit-UtkNrGKq.js} +1 -1
  91. package/dist/packem_shared/{runtime-check-BXehSP06.js → runtime-check-qnrPTlma.js} +1 -1
  92. package/dist/packem_shared/{s1ngularity-BCDt28u0.js → s1ngularity-DUZtU95L.js} +1 -1
  93. package/dist/packem_shared/{scan-progress-YRpDs90j.js → scan-progress-BgtHexnt.js} +1 -1
  94. package/dist/packem_shared/{signatures-B3srzCEv.js → signatures-QoCuUv9E.js} +1 -1
  95. package/dist/packem_shared/target-merge-Dg25Izl5.js +11 -0
  96. package/dist/packem_shared/{toolchain-C44mPKPu.js → toolchain-Zb3VzZb4.js} +1 -1
  97. package/dist/packem_shared/{typosquats-CQz-1Y6K.js → typosquats-C12CP_2G.js} +1 -1
  98. package/dist/packem_shared/{use-measured-height-DHi0xOPO.js → use-measured-height-BpKmrlkw.js} +1 -1
  99. package/dist/packem_shared/{vis-update-app-B3I14Vfy.js → vis-update-app-BoCQ4ute.js} +1 -1
  100. package/dist/packem_shared/{watch-loop-JfGKIgKB.js → watch-loop-BZudYfcl.js} +1 -1
  101. package/dist/release/index.d.ts +39 -2
  102. package/dist/release/index.js +1 -1
  103. package/dist/release/plugin-sdk.d.ts +2 -1
  104. package/dist/release/plugin-sdk.js +1 -1
  105. package/dist/release/types.d.ts +117 -1
  106. package/dist/release/types.js +1 -1
  107. package/index.js +52 -52
  108. package/package.json +9 -9
  109. package/schemas/vis-config.schema.json +33 -0
  110. package/schemas/vis-release-config.schema.json +33 -0
  111. package/dist/packem_shared/ReleaseClient-YHzBIxYS.js +0 -1
  112. package/dist/packem_shared/target-merge-DOm6h6tW.js +0 -11
  113. /package/dist/packem_shared/{readJsonSync-CvkZyKmL-ihoybKvs.js → readJsonSync-DuMMeB3s-ihoybKvs.js} +0 -0
@@ -1,9 +1,9 @@
1
- import{createRequire as FC}from"node:module";import{d as WC,c as Lr,V as IC,h as _C,e as zC,r as KC}from"../packem_shared/index-XAb0QGqA.js";import{T as ui,F as Gf,m as L,e as Jl,H as no,B as Ha,A as Ff,y as ws,f as Z,a as vo,v as z,o as qC,O as UC}from"../packem_shared/index-CE6MsgcV.js";import{N as VC,a as Qe}from"../packem_shared/readJsonSync-CvkZyKmL-ihoybKvs.js";import{L as dY}from"../packem_shared/public-api-WqUCiyIe.js";import{r as gY,a as hY,s as Tl}from"../packem_shared/index-Cg0IHaFI.js";import{a as _g}from"../packem_shared/_commonjsHelpers-B5Y90VFO.js";import{getMainWorktreeRoot as pY,Cache as Yr,readLastRunSummary as Uf,getLastRunSummaryPath as Dl,parseCacheSize as vY,digestFile as Vf}from"@visulima/task-runner";import{L as em,g as yY,d as fo,M as Bl,N as fY,_ as Pa,c as _t,O as im,f as mo,i as wp,V as mY}from"../packem_shared/env-Ct3hMEYB.js";import{e as Wr,V as sd,j as pn,s as Rt,q as eo,E as Ca,Q as YY,I as $Y}from"../packem_shared/index.server-J83sowC4.js";import{B as Xl,D as Hl,J as ZY,K as JY,r as D,M as xY,P as jp,Q as nm,S as TY,X as kp,a0 as Un,Y as om,m as Y,n as _,i as B,a1 as DY,v as En,b as BY,a2 as XY,W as Sp,e as HY,l as MY,a as Ml,U as Lp,$ as PY,d as NY,c as EY,f as RY}from"./catalog.js";import{e as OY}from"../packem_shared/index-DjTWo3sH.js";import{I as ao}from"../packem_shared/index-B0EsgdzO.js";import{findVisConfigFile as Uo,loadVisConfig as Cp}from"./CONFIG_FILES.js";import{u as Ro,m as AY}from"./ts-loader.js";import{s as GY}from"../packem_shared/bin-CPMo34SM.js";import{A as Yp}from"../packem_shared/pm-runner-CQcraCcu.js";const QC=FC(import.meta.url),yt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,Di=e=>{if(typeof yt<"u"&&yt.versions&&yt.versions.node){const[i,n]=yt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return yt.getBuiltinModule(e)}return QC(e)},Qf=Di("node:module"),{createRequire:wn}=Qf,{readFile:Wf,readdir:js,stat:Qa,realpath:fp,rm:Ig,mkdtemp:eY,mkdir:iY}=Di("node:fs/promises"),{resolve:Cr,dirname:If,delimiter:mp}=Di("node:path"),{rmSync:Ma,writeFileSync:He,renameSync:_f,unlinkSync:yo,readdirSync:Fi,statSync:Eo,readFileSync:nY,watch:oY,existsSync:bp,copyFileSync:aY,mkdirSync:tY,cpSync:sY}=Di("node:fs"),{execFileSync:rY,execFile:uY,spawnSync:La,execSync:zf}=Di("node:child_process"),{Readable:xl}=Di("node:stream"),{createInterface:Kf}=Di("node:readline"),qf=Di("node:url"),{fileURLToPath:lY}=qf,cY=Di("util"),{createServer:bY,STATUS_CODES:wY}=Di("node:http"),{Http2ServerRequest:zt,constants:jY}=Di("node:http2"),{tmpdir:kY,homedir:SY,platform:LY}=Di("node:os"),{randomUUID:CY}=Di("node:crypto"),le=(e,i)=>async()=>({default:(await e())[i]});function am(e,i,n,o){let a,t,s;t=n,s=o;const r=dY(i,t,s??a);ui(e,r,a)}let zg=class extends WC{troubleshooting;constructor(i,n,o=[]){super(i,n,{troubleshooting:o}),this.name="CompletionError",this.troubleshooting=o,o.length>0&&(this.hint=o.join(`
1
+ import{createRequire as FC}from"node:module";import{d as WC,c as Lr,V as IC,h as _C,e as zC,r as KC}from"../packem_shared/index-C6tpgeIV.js";import{T as ui,F as Gf,m as L,e as Jl,H as no,B as Ha,A as Ff,y as ws,f as Z,a as vo,v as z,o as qC,O as UC}from"../packem_shared/index-CE6MsgcV.js";import{N as VC,a as Qe}from"../packem_shared/readJsonSync-DuMMeB3s-ihoybKvs.js";import{L as dY}from"../packem_shared/public-api-WqUCiyIe.js";import{r as gY,a as hY,s as Tl}from"../packem_shared/index-Cg0IHaFI.js";import{a as _g}from"../packem_shared/_commonjsHelpers-B5Y90VFO.js";import{getMainWorktreeRoot as pY,Cache as Yr,readLastRunSummary as Uf,getLastRunSummaryPath as Dl,parseCacheSize as vY,digestFile as Vf}from"@visulima/task-runner";import{L as em,g as yY,d as fo,M as Bl,N as fY,_ as Pa,c as _t,O as im,f as mo,i as wp,V as mY}from"../packem_shared/env-DJlbJiFh.js";import{e as Wr,V as sd,j as pn,s as Rt,q as eo,E as Ca,Q as YY,I as $Y}from"../packem_shared/index.server-J83sowC4.js";import{B as Xl,D as Hl,J as ZY,K as JY,r as D,M as xY,P as jp,Q as nm,S as TY,X as kp,a0 as Un,Y as om,m as Y,n as _,i as B,a1 as DY,v as En,b as BY,a2 as XY,W as Sp,e as HY,l as MY,a as Ml,U as Lp,$ as PY,d as NY,c as EY,f as RY}from"./catalog.js";import{e as OY}from"../packem_shared/index-DjTWo3sH.js";import{I as ao}from"../packem_shared/index-B0EsgdzO.js";import{findVisConfigFile as Uo,loadVisConfig as Cp}from"./CONFIG_FILES.js";import{u as Ro,m as AY}from"./ts-loader.js";import{s as GY}from"../packem_shared/bin-BlGVEhl8.js";import{A as Yp}from"../packem_shared/pm-runner-CQcraCcu.js";const QC=FC(import.meta.url),yt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,Di=e=>{if(typeof yt<"u"&&yt.versions&&yt.versions.node){const[i,n]=yt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return yt.getBuiltinModule(e)}return QC(e)},Qf=Di("node:module"),{createRequire:wn}=Qf,{readFile:Wf,readdir:js,stat:Qa,realpath:fp,rm:Ig,mkdtemp:eY,mkdir:iY}=Di("node:fs/promises"),{resolve:Cr,dirname:If,delimiter:mp}=Di("node:path"),{rmSync:Ma,writeFileSync:He,renameSync:_f,unlinkSync:yo,readdirSync:Fi,statSync:Eo,readFileSync:nY,watch:oY,existsSync:bp,copyFileSync:aY,mkdirSync:tY,cpSync:sY}=Di("node:fs"),{execFileSync:rY,execFile:uY,spawnSync:La,execSync:zf}=Di("node:child_process"),{Readable:xl}=Di("node:stream"),{createInterface:Kf}=Di("node:readline"),qf=Di("node:url"),{fileURLToPath:lY}=qf,cY=Di("util"),{createServer:bY,STATUS_CODES:wY}=Di("node:http"),{Http2ServerRequest:zt,constants:jY}=Di("node:http2"),{tmpdir:kY,homedir:SY,platform:LY}=Di("node:os"),{randomUUID:CY}=Di("node:crypto"),le=(e,i)=>async()=>({default:(await e())[i]});function am(e,i,n,o){let a,t,s;t=n,s=o;const r=dY(i,t,s??a);ui(e,r,a)}let zg=class extends WC{troubleshooting;constructor(i,n,o=[]){super(i,n,{troubleshooting:o}),this.name="CompletionError",this.troubleshooting=o,o.length>0&&(this.hint=o.join(`
2
2
  `))}};const Pl=["bash","zsh","fish","powershell"],Nl=["node","bun","deno"],FY=e=>"Deno"in e,QY=e=>"Bun"in e,$p=()=>FY(globalThis)?"deno":QY(globalThis)?"bun":"node",Zp=e=>{const i=e?.starshipShell??e?.shell;if(i){const a=i.toLowerCase();if(a.includes("zsh"))return"zsh";if(a.includes("bash"))return"bash";if(a.includes("fish"))return"fish"}const n=e?.psModulePath,o=e?.prompt;if(n||o?.includes("PS"))return"powershell";if(e?.comSpec?.toLowerCase().includes("cmd.exe"))return"bash"},WY=async()=>(await import("./index2.js")).default,IY=(e,i)=>{for(const n of i)n.hidden||(n.name&&e.option(n.name,n.description??""),n.alias&&e.option(n.alias,n.description??""))},_Y=(e,i)=>{for(const[n,o]of i){if(o.name!==n||o.hidden)continue;const a=e.command(o.name,o.description??"");o.options&&IY(a,o.options)}},zY=e=>{if(!Pl.includes(e))throw new zg(`Invalid shell type: ${e}`,"INVALID_SHELL",[`Valid shells are: ${Pl.join(", ")}`,"Shell will be auto-detected if not specified"])},KY=e=>{if(e&&!Nl.includes(e))throw new zg(`Invalid runtime: ${e}`,"INVALID_RUNTIME",[`Valid runtimes are: ${Nl.join(", ")}`,"Runtime will be auto-detected if not specified"])},qY=(e,i)=>{e.error("Could not detect current shell");const n=[`Usage: ${i} completion --shell=<bash|zsh|fish|powershell> [--runtime=<node|bun|deno>]`,"","Examples:"," # Install completions for zsh:",` ${i} completion --shell=zsh > ~/.${i}-completion.zsh`,` echo 'source ~/.${i}-completion.zsh' >> ~/.zshrc`,""," # Install completions for bash with custom runtime:",` ${i} completion --shell=bash --runtime=bun > ~/.${i}-completion.bash`,` echo 'source ~/.${i}-completion.bash' >> ~/.bashrc`,""," # Install completions for fish:",` ${i} completion --shell=fish > ~/.config/fish/completions/${i}.fish`].join(`
3
3
  `);e.info(n)},UY={description:"Generate shell completion scripts",env:[{description:"Shell path (Unix-like systems). Used for shell detection.",name:"SHELL",type:String},{description:"Starship shell configuration. Takes precedence over SHELL for detection.",name:"STARSHIP_SHELL",type:String},{description:"PowerShell module path (Windows). Used for PowerShell detection.",name:"PSModulePath",type:String},{description:"Command prompt variable (Windows). Used for PowerShell detection.",name:"PROMPT",type:String},{description:"Command processor (Windows). Used for Windows Command Prompt detection.",name:"ComSpec",type:String}],execute:async({env:e,logger:i,options:n,runtime:o})=>{const a=o.getCliName(),t=n.shell??Zp(e);if(!t){qY(i,a);return}try{zY(t),KY(n.runtime);const s=await WY();_Y(s,o.getCommands());const r=`${n.runtime??$p()} ${a}`;s.setup(a,r,t)}catch(s){if(s instanceof zg){const r=[`Failed to generate completion script: ${s.message}`,`Error code: ${s.code}`];throw s.troubleshooting.length>0&&r.push("","Troubleshooting:",...s.troubleshooting.map(u=>` • ${u}`)),i.error(r.join(`
4
4
  `)),s}else{const r=["Failed to generate completion script",`Error: ${s instanceof Error?s.message:String(s)}`,"","Troubleshooting:"," • Ensure @bomb.sh/tab is installed: pnpm add @bomb.sh/tab",` • Verify shell is supported: ${Pl.join(", ")}`,` • Verify runtime is supported: ${Nl.join(", ")}`," • Check that your CLI name is correct"];i.error(r.join(`
5
- `))}}},name:"completion",options:[{defaultOption:!0,defaultValue:Zp(),description:"Shell type (bash, zsh, fish, powershell). Defaults to current shell if detected.",name:"shell",type:String,typeLabel:"{underline shell}"},{defaultValue:$p(),description:"JavaScript runtime (node, bun, deno). Defaults to current runtime if detected.",name:"runtime",type:String,typeLabel:"{underline runtime}"}]},VY={alias:["v","V"],description:"Output the version number",execute:({logger:e,runtime:i})=>{const n=i.getPackageVersion();n===void 0?(e.warn("Unknown version"),e.debug("The version number was not provided by the cli constructor.")):e.info(n)},name:"version",options:[],usage:[]},e$=wn(import.meta.url),ft=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,tm=e=>{if(typeof ft<"u"&&ft.versions&&ft.versions.node){const[i,n]=ft.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return ft.getBuiltinModule(e)}return e$(e)},{execFileSync:i$}=tm("node:child_process"),{existsSync:Jp,readFileSync:n$}=tm("node:fs"),o$=["yarn.lock","package-lock.json","pnpm-lock.yaml","npm-shrinkwrap.json","bun.lock","bun.lockb"],xp=new Set(["bun","npm","pnpm","yarn"]),sm=e=>{const i=VC(n$(e,"utf8"));return typeof i?.packageManager=="string"?i.packageManager:void 0},a$=e=>{let i;if(o$.forEach(o=>{!i&&Jp(L(e,o))&&(i=L(e,o))}),i)return i;const n=L(e,"package.json");if(Jp(n)&&sm(n)!==void 0)return n},t$=e=>{if(!e)throw new Jl("Could not find a package manager");if(e.endsWith("package.json")){const i=sm(e);if(i){const n=["npm","yarn","pnpm","bun"].find(o=>i.startsWith(o));if(n)return{packageManager:n,path:no(e)}}}if(e.endsWith("yarn.lock"))return{packageManager:"yarn",path:no(e)};if(e.endsWith("package-lock.json")||e.endsWith("npm-shrinkwrap.json"))return{packageManager:"npm",path:no(e)};if(e.endsWith("pnpm-lock.yaml"))return{packageManager:"pnpm",path:no(e)};if(e.endsWith("bun.lock")||e.endsWith("bun.lockb"))return{packageManager:"bun",path:no(e)};throw new Jl("Could not find a package manager")},s$=e=>{const i=Gf(a$,{...e&&{cwd:e}});return t$(i)},$1e=e=>{if(!xp.has(e))throw new Error(`Unsupported package manager "${e}". Expected one of: ${[...xp].join(", ")}.`);return i$(e,["--version"]).toString("utf8").trim()},r$=wn(import.meta.url),mt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,rm=e=>{if(typeof mt<"u"&&mt.versions&&mt.versions.node){const[i,n]=mt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return mt.getBuiltinModule(e)}return r$(e)};rm("node:fs");rm("node:fs/promises");const u$={sha256:"sha256",sha384:"sha384",sha512:"sha512"},d$=1024,l$=/^[A-Z0-9+/]+={0,2}$/i,Tp="node_modules/",as=/^['"]/,ts=/['"]$/,g$=/^[a-z][a-zA-Z0-9]*:\s*$/m,h$=/resolution:\s*\{[^}]*integrity:\s*([^,}\s]+)/,c$=/^["']?((?:@[^/@"']+\/)?[^@"'\n]+)@[^\n]+\n((?:[\t ][^\n]*(?:\n|$))+)/gm,p$=/^\s+version:?\s+"?([^"\n]+)"?/m,v$=/^\s+integrity[\s:]+"?([^"\s]+)"?/m,Ir=e=>{if(e.length>d$)return;const i=e.indexOf("-");if(i<=0)return;const n=u$[e.slice(0,i).toLowerCase()];if(!n)return;const o=e.slice(i+1);if(l$.test(o))try{const a=Buffer.from(o,"base64");return a.length===0?void 0:{algorithm:n,hex:a.toString("hex")}}catch{return}},_r=(e,i,n)=>{const o=`${n.name}@${n.version}`;i.has(o)||(i.add(o),e.push(n))},Ei=(e,i,n)=>{n&&Object.keys(n).length>0&&(e[i]={...n})},Ya=e=>{if(!e)return;const i={};for(const[n,o]of Object.entries(e))i[n]=[o];return Object.keys(i).length>0?i:void 0},y$=e=>{const i=[],n=new Set;let o;try{o=JSON.parse(e)}catch{return i}if(!o.packages)return i;for(const[a,t]of Object.entries(o.packages)){if(!a||!t.version)continue;const s=a.lastIndexOf(Tp);if(s===-1)continue;const r=a.slice(s+Tp.length);if(r.length===0)continue;const u=r.split("/"),d=r.startsWith("@")?2:1;if(u.length!==d||u.some(h=>h.length===0))continue;const l=t.name??r;if(l.startsWith("."))continue;const g={name:l,version:t.version};if(t.integrity){const h=Ir(t.integrity);h&&(g.integrity=h)}Ei(g,"dependencies",Ya(t.dependencies)),Ei(g,"peerDependencies",Ya(t.peerDependencies)),Ei(g,"optionalDependencies",Ya(t.optionalDependencies)),_r(i,n,g)}return i},um=e=>{let i=e.trim();i.startsWith("/")&&(i=i.slice(1)),i=i.replace(as,"").replace(ts,"");const n=i.indexOf("(");n>0&&(i=i.slice(0,n));const o=i.lastIndexOf("@");if(o<=0)return;const a=i.slice(0,o),t=i.slice(o+1);if(!(!a||!t||t.startsWith("link:")||t.startsWith("workspace:")||t.startsWith("file:")))return{name:a,version:t}},dm=(e,i)=>{const n=new RegExp(String.raw`^${i}:\s*$`,"m").exec(e);if(!n)return;const o=n.index+n[0].length,a=g$.exec(e.slice(o));return e.slice(o,a?o+a.index:e.length)},f$=e=>{const i=new Map,n=dm(e,"snapshots");if(!n)return i;const o=/^ {2}(['"]?[^\s:][^:\n]*?['"]?):\s*\n((?: {4}[^\n]*\n?)+)/gm;let a;for(;(a=o.exec(n)??void 0)!==void 0;){const t=um(a[1]);if(!t)continue;const s=`${t.name}@${t.version}`,r=a[2],u=i.get(s)??{};for(const d of["dependencies","peerDependencies","optionalDependencies"]){const l=rr(r,d);if(!l)continue;const g=u[d]??{};for(const[h,c]of Object.entries(l)){const p=g[h]??[];for(const f of c)p.includes(f)||p.push(f);g[h]=p}u[d]=g}i.set(s,u)}return i},m$=e=>{const i=[],n=new Set,o=dm(e,"packages");if(!o)return i;const a=f$(e),t=/^ {2}(['"]?[^\s:][^:\n]*?['"]?):\s*\n((?: {4}[^\n]*\n?)+)/gm;let s;for(;(s=t.exec(o)??void 0)!==void 0;){const r=um(s[1]);if(!r)continue;const u=s[2],d=h$.exec(u),l={name:r.name,version:r.version};if(d?.[1]){const h=Ir(d[1]);h&&(l.integrity=h)}const g=a.get(`${r.name}@${r.version}`);Ei(l,"dependencies",g?.dependencies??rr(u,"dependencies")),Ei(l,"peerDependencies",g?.peerDependencies??rr(u,"peerDependencies")),Ei(l,"optionalDependencies",g?.optionalDependencies??rr(u,"optionalDependencies")),_r(i,n,l)}return i},rr=(e,i)=>{const n=new RegExp(String.raw`^ {4}${i}:\s*\n((?: {6,}[^\n]*\n?)+)`,"m").exec(e);if(!n?.[1])return;const o={},a=/^ {6}([^\s:]+):\s*([^\n]+)/gm;let t;for(;(t=a.exec(n[1])??void 0)!==void 0;){const s=t[1].replace(as,"").replace(ts,"");let r=t[2].trim();r=r.replace(as,"").replace(ts,"");const u=r.indexOf("(");if(u>0&&(r=r.slice(0,u).trim()),!s||!r)continue;const d=o[s]??[];d.includes(r)||d.push(r),o[s]=d}return Object.keys(o).length>0?o:void 0},b$=e=>{const i=[],n=new Set,o=c$;o.lastIndex=0;let a;for(;(a=o.exec(e)??void 0)!==void 0;){const t=a[1].replace(as,"").replace(ts,"");if(!t)continue;const s=a[2],r=p$.exec(s);if(!r?.[1])continue;const u={name:t,version:r[1].trim()},d=v$.exec(s);if(d?.[1]){const l=Ir(d[1]);l&&(u.integrity=l)}Ei(u,"dependencies",rd(s,"dependencies")),Ei(u,"peerDependencies",rd(s,"peerDependencies")),Ei(u,"optionalDependencies",rd(s,"optionalDependencies")),_r(i,n,u)}return i},rd=(e,i)=>{const n=new RegExp(String.raw`^ {2}${i}:\s*\n((?: {4,}[^\n]*\n?)+)`,"m").exec(e);if(!n?.[1])return;const o={},a=/^ {4}(['"]?[^\s:'"]+['"]?)\s*(?::\s*)?['"]([^'"\n]+)['"]/gm;let t;for(;(t=a.exec(n[1])??void 0)!==void 0;){const s=t[1].replace(as,"").replace(ts,""),r=t[2];if(s&&r){const u=o[s]??[];u.includes(r)||u.push(r),o[s]=u}}return Object.keys(o).length>0?o:void 0},w$=/,(?=\s*[}\]])/g,j$=e=>{const i=[],n=new Set;let o;try{o=JSON.parse(e.replaceAll(w$,""))}catch{return i}if(!o.packages)return i;for(const a of Object.values(o.packages)){const t=a[0];if(typeof t!="string")continue;const s=t.indexOf("@",1);if(s<=0)continue;const r=t.slice(0,s),u=t.slice(s+1);if(!r||!u||u.startsWith("workspace:")||u.startsWith("link:")||u.startsWith("file:"))continue;const d={name:r,version:u},l=a[3];if(typeof l=="string"&&l.length>0){const h=Ir(l);h&&(d.integrity=h)}const g=a[2];if(g&&typeof g=="object"&&!Array.isArray(g)){const h=g;Ei(d,"dependencies",Ya(h.dependencies)),Ei(d,"peerDependencies",Ya(h.peerDependencies)),Ei(d,"optionalDependencies",Ya(h.optionalDependencies))}_r(i,n,d)}return i},Z1e=(e,i)=>{switch(i){case"bun":return j$(e);case"npm":return y$(e);case"pnpm":return m$(e);case"yarn":return b$(e);default:return[]}},k$=wn(import.meta.url),bt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,S$=e=>{if(typeof bt<"u"&&bt.versions&&bt.versions.node){const[i,n]=bt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return bt.getBuiltinModule(e)}return k$(e)},{existsSync:Dp,readFileSync:L$}=S$("node:fs"),lm=e=>{const i=Gf(["lerna.json","turbo.json"],{type:"file",...e&&{cwd:e}});if(i?.endsWith("lerna.json")){const o=Qe(i);if(o.useWorkspaces||o.packages)return{path:no(i),strategy:"lerna"}}const n=i?.endsWith("turbo.json");try{const{packageManager:o,path:a}=s$(e);if(["npm","yarn"].includes(o)){const t=L(a,"package.json");if(Dp(t)&&L$(L(a,"package.json"),"utf8").includes("workspaces"))return{path:a,strategy:n?"turbo":o}}else if(o==="pnpm"){const t=L(a,"pnpm-workspace.yaml");if(Dp(t))return{path:a,strategy:n?"turbo":"pnpm"}}}catch(o){if(!(o instanceof Jl))throw o}throw new Error(`No monorepo root could be found upwards from the directory ${String(e??process.cwd())} using lerna, yarn, pnpm, or npm as indicators.`)},C$=wn(import.meta.url),wt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,Y$=e=>{if(typeof wt<"u"&&wt.versions&&wt.versions.node){const[i,n]=wt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return wt.getBuiltinModule(e)}return C$(e)};Y$("node:fs");var ud,Bp;function gm(){return Bp||(Bp=1,ud=["0BSD","3D-Slicer-1.0","AAL","ADSL","AFL-1.1","AFL-1.2","AFL-2.0","AFL-2.1","AFL-3.0","AGPL-1.0-only","AGPL-1.0-or-later","AGPL-3.0-only","AGPL-3.0-or-later","ALGLIB-Documentation","AMD-newlib","AMDPLPA","AML","AML-glslang","AMPAS","ANTLR-PD","ANTLR-PD-fallback","APAFML","APL-1.0","APSL-1.0","APSL-1.1","APSL-1.2","APSL-2.0","ASWF-Digital-Assets-1.0","ASWF-Digital-Assets-1.1","Abstyles","AdaCore-doc","Adobe-2006","Adobe-Display-PostScript","Adobe-Glyph","Adobe-Utopia","Advanced-Cryptics-Dictionary","Afmparse","Aladdin","Apache-1.0","Apache-1.1","Apache-2.0","App-s2p","Arphic-1999","Artistic-1.0","Artistic-1.0-Perl","Artistic-1.0-cl8","Artistic-2.0","Artistic-dist","Aspell-RU","BOLA-1.1","BSD-1-Clause","BSD-2-Clause","BSD-2-Clause-Darwin","BSD-2-Clause-Patent","BSD-2-Clause-Views","BSD-2-Clause-first-lines","BSD-2-Clause-pkgconf-disclaimer","BSD-3-Clause","BSD-3-Clause-Attribution","BSD-3-Clause-Clear","BSD-3-Clause-HP","BSD-3-Clause-LBNL","BSD-3-Clause-Modification","BSD-3-Clause-No-Military-License","BSD-3-Clause-No-Nuclear-License","BSD-3-Clause-No-Nuclear-License-2014","BSD-3-Clause-No-Nuclear-Warranty","BSD-3-Clause-Open-MPI","BSD-3-Clause-Sun","BSD-3-Clause-Tso","BSD-3-Clause-acpica","BSD-3-Clause-flex","BSD-4-Clause","BSD-4-Clause-Shortened","BSD-4-Clause-UC","BSD-4.3RENO","BSD-4.3TAHOE","BSD-Advertising-Acknowledgement","BSD-Attribution-HPND-disclaimer","BSD-Inferno-Nettverk","BSD-Mark-Modifications","BSD-Protection","BSD-Source-Code","BSD-Source-beginning-file","BSD-Systemics","BSD-Systemics-W3Works","BSL-1.0","BUSL-1.1","Baekmuk","Bahyph","Barr","Beerware","BitTorrent-1.0","BitTorrent-1.1","Bitstream-Charter","Bitstream-Vera","BlueOak-1.0.0","Boehm-GC","Boehm-GC-without-fee","Borceux","Brian-Gladman-2-Clause","Brian-Gladman-3-Clause","Buddy","C-UDA-1.0","CAL-1.0","CAL-1.0-Combined-Work-Exception","CAPEC-tou","CATOSL-1.1","CC-BY-1.0","CC-BY-2.0","CC-BY-2.5","CC-BY-2.5-AU","CC-BY-3.0","CC-BY-3.0-AT","CC-BY-3.0-AU","CC-BY-3.0-DE","CC-BY-3.0-IGO","CC-BY-3.0-NL","CC-BY-3.0-US","CC-BY-4.0","CC-BY-NC-1.0","CC-BY-NC-2.0","CC-BY-NC-2.5","CC-BY-NC-3.0","CC-BY-NC-3.0-DE","CC-BY-NC-4.0","CC-BY-NC-ND-1.0","CC-BY-NC-ND-2.0","CC-BY-NC-ND-2.5","CC-BY-NC-ND-3.0","CC-BY-NC-ND-3.0-DE","CC-BY-NC-ND-3.0-IGO","CC-BY-NC-ND-4.0","CC-BY-NC-SA-1.0","CC-BY-NC-SA-2.0","CC-BY-NC-SA-2.0-DE","CC-BY-NC-SA-2.0-FR","CC-BY-NC-SA-2.0-UK","CC-BY-NC-SA-2.5","CC-BY-NC-SA-3.0","CC-BY-NC-SA-3.0-DE","CC-BY-NC-SA-3.0-IGO","CC-BY-NC-SA-4.0","CC-BY-ND-1.0","CC-BY-ND-2.0","CC-BY-ND-2.5","CC-BY-ND-3.0","CC-BY-ND-3.0-DE","CC-BY-ND-4.0","CC-BY-SA-1.0","CC-BY-SA-2.0","CC-BY-SA-2.0-UK","CC-BY-SA-2.1-JP","CC-BY-SA-2.5","CC-BY-SA-3.0","CC-BY-SA-3.0-AT","CC-BY-SA-3.0-DE","CC-BY-SA-3.0-IGO","CC-BY-SA-4.0","CC-PDDC","CC-PDM-1.0","CC-SA-1.0","CC0-1.0","CDDL-1.0","CDDL-1.1","CDL-1.0","CDLA-Permissive-1.0","CDLA-Permissive-2.0","CDLA-Sharing-1.0","CECILL-1.0","CECILL-1.1","CECILL-2.0","CECILL-2.1","CECILL-B","CECILL-C","CERN-OHL-1.1","CERN-OHL-1.2","CERN-OHL-P-2.0","CERN-OHL-S-2.0","CERN-OHL-W-2.0","CFITSIO","CMU-Mach","CMU-Mach-nodoc","CNRI-Jython","CNRI-Python","CNRI-Python-GPL-Compatible","COIL-1.0","CPAL-1.0","CPL-1.0","CPOL-1.02","CUA-OPL-1.0","Caldera","Caldera-no-preamble","Catharon","ClArtistic","Clips","Community-Spec-1.0","Condor-1.1","Cornell-Lossless-JPEG","Cronyx","Crossword","CryptoSwift","CrystalStacker","Cube","D-FSL-1.0","DEC-3-Clause","DL-DE-BY-2.0","DL-DE-ZERO-2.0","DOC","DRL-1.0","DRL-1.1","DSDP","DocBook-DTD","DocBook-Schema","DocBook-Stylesheet","DocBook-XML","Dotseqn","ECL-1.0","ECL-2.0","EFL-1.0","EFL-2.0","EPICS","EPL-1.0","EPL-2.0","ESA-PL-permissive-2.4","ESA-PL-strong-copyleft-2.4","ESA-PL-weak-copyleft-2.4","EUDatagrid","EUPL-1.0","EUPL-1.1","EUPL-1.2","Elastic-2.0","Entessa","ErlPL-1.1","Eurosym","FBM","FDK-AAC","FSFAP","FSFAP-no-warranty-disclaimer","FSFUL","FSFULLR","FSFULLRSD","FSFULLRWD","FSL-1.1-ALv2","FSL-1.1-MIT","FTL","Fair","Ferguson-Twofish","Frameworx-1.0","FreeBSD-DOC","FreeImage","Furuseth","GCR-docs","GD","GFDL-1.1-invariants-only","GFDL-1.1-invariants-or-later","GFDL-1.1-no-invariants-only","GFDL-1.1-no-invariants-or-later","GFDL-1.1-only","GFDL-1.1-or-later","GFDL-1.2-invariants-only","GFDL-1.2-invariants-or-later","GFDL-1.2-no-invariants-only","GFDL-1.2-no-invariants-or-later","GFDL-1.2-only","GFDL-1.2-or-later","GFDL-1.3-invariants-only","GFDL-1.3-invariants-or-later","GFDL-1.3-no-invariants-only","GFDL-1.3-no-invariants-or-later","GFDL-1.3-only","GFDL-1.3-or-later","GL2PS","GLWTPL","GPL-1.0-only","GPL-1.0-or-later","GPL-2.0-only","GPL-2.0-or-later","GPL-3.0-only","GPL-3.0-or-later","Game-Programming-Gems","Giftware","Glide","Glulxe","Graphics-Gems","Gutmann","HDF5","HIDAPI","HP-1986","HP-1989","HPND","HPND-DEC","HPND-Fenneberg-Livingston","HPND-INRIA-IMAG","HPND-Intel","HPND-Kevlin-Henney","HPND-MIT-disclaimer","HPND-Markus-Kuhn","HPND-Netrek","HPND-Pbmplus","HPND-SMC","HPND-UC","HPND-UC-export-US","HPND-doc","HPND-doc-sell","HPND-export-US","HPND-export-US-acknowledgement","HPND-export-US-modify","HPND-export2-US","HPND-merchantability-variant","HPND-sell-MIT-disclaimer-xserver","HPND-sell-regexpr","HPND-sell-variant","HPND-sell-variant-MIT-disclaimer","HPND-sell-variant-MIT-disclaimer-rev","HPND-sell-variant-critical-systems","HTMLTIDY","HaskellReport","Hippocratic-2.1","IBM-pibs","ICU","IEC-Code-Components-EULA","IJG","IJG-short","IPA","IPL-1.0","ISC","ISC-Veillard","ISO-permission","ImageMagick","Imlib2","Info-ZIP","Inner-Net-2.0","InnoSetup","Intel","Intel-ACPI","Interbase-1.0","JPL-image","JPNIC","JSON","Jam","JasPer-2.0","Kastrup","Kazlib","Knuth-CTAN","LAL-1.2","LAL-1.3","LGPL-2.0-only","LGPL-2.0-or-later","LGPL-2.1-only","LGPL-2.1-or-later","LGPL-3.0-only","LGPL-3.0-or-later","LGPLLR","LOOP","LPD-document","LPL-1.0","LPL-1.02","LPPL-1.0","LPPL-1.1","LPPL-1.2","LPPL-1.3a","LPPL-1.3c","LZMA-SDK-9.11-to-9.20","LZMA-SDK-9.22","Latex2e","Latex2e-translated-notice","Leptonica","LiLiQ-P-1.1","LiLiQ-R-1.1","LiLiQ-Rplus-1.1","Libpng","Linux-OpenIB","Linux-man-pages-1-para","Linux-man-pages-copyleft","Linux-man-pages-copyleft-2-para","Linux-man-pages-copyleft-var","Lucida-Bitmap-Fonts","MIPS","MIT","MIT-0","MIT-CMU","MIT-Click","MIT-Festival","MIT-Khronos-old","MIT-Modern-Variant","MIT-STK","MIT-Wu","MIT-advertising","MIT-enna","MIT-feh","MIT-open-group","MIT-testregex","MITNFA","MMIXware","MMPL-1.0.1","MPEG-SSG","MPL-1.0","MPL-1.1","MPL-2.0","MPL-2.0-no-copyleft-exception","MS-LPL","MS-PL","MS-RL","MTLL","Mackerras-3-Clause","Mackerras-3-Clause-acknowledgment","MakeIndex","Martin-Birgmeier","McPhee-slideshow","Minpack","MirOS","Motosoto","MulanPSL-1.0","MulanPSL-2.0","Multics","Mup","NAIST-2003","NASA-1.3","NBPL-1.0","NCBI-PD","NCGL-UK-2.0","NCL","NCSA","NGPL","NICTA-1.0","NIST-PD","NIST-PD-TNT","NIST-PD-fallback","NIST-Software","NLOD-1.0","NLOD-2.0","NLPL","NOSL","NPL-1.0","NPL-1.1","NPOSL-3.0","NRL","NTIA-PD","NTP","NTP-0","Naumen","NetCDF","Newsletr","Nokia","Noweb","O-UDA-1.0","OAR","OCCT-PL","OCLC-2.0","ODC-By-1.0","ODbL-1.0","OFFIS","OFL-1.0","OFL-1.0-RFN","OFL-1.0-no-RFN","OFL-1.1","OFL-1.1-RFN","OFL-1.1-no-RFN","OGC-1.0","OGDL-Taiwan-1.0","OGL-Canada-2.0","OGL-UK-1.0","OGL-UK-2.0","OGL-UK-3.0","OGTSL","OLDAP-1.1","OLDAP-1.2","OLDAP-1.3","OLDAP-1.4","OLDAP-2.0","OLDAP-2.0.1","OLDAP-2.1","OLDAP-2.2","OLDAP-2.2.1","OLDAP-2.2.2","OLDAP-2.3","OLDAP-2.4","OLDAP-2.5","OLDAP-2.6","OLDAP-2.7","OLDAP-2.8","OLFL-1.3","OML","OPL-1.0","OPL-UK-3.0","OPUBL-1.0","OSC-1.0","OSET-PL-2.1","OSL-1.0","OSL-1.1","OSL-2.0","OSL-2.1","OSL-3.0","OSSP","OpenMDW-1.0","OpenPBS-2.3","OpenSSL","OpenSSL-standalone","OpenVision","PADL","PDDL-1.0","PHP-3.0","PHP-3.01","PPL","PSF-2.0","ParaType-Free-Font-1.3","Parity-6.0.0","Parity-7.0.0","Pixar","Plexus","PolyForm-Noncommercial-1.0.0","PolyForm-Small-Business-1.0.0","PostgreSQL","Python-2.0","Python-2.0.1","QPL-1.0","QPL-1.0-INRIA-2004","Qhull","RHeCos-1.1","RPL-1.1","RPL-1.5","RPSL-1.0","RSA-MD","RSCPL","Rdisc","Ruby","Ruby-pty","SAX-PD","SAX-PD-2.0","SCEA","SGI-B-1.0","SGI-B-1.1","SGI-B-2.0","SGI-OpenGL","SGMLUG-PM","SGP4","SHL-0.5","SHL-0.51","SISSL","SISSL-1.2","SL","SMAIL-GPL","SMLNJ","SMPPL","SNIA","SOFA","SPL-1.0","SSH-OpenSSH","SSH-short","SSLeay-standalone","SSPL-1.0","SUL-1.0","SWL","Saxpath","SchemeReport","Sendmail","Sendmail-8.23","Sendmail-Open-Source-1.1","SimPL-2.0","Sleepycat","Soundex","Spencer-86","Spencer-94","Spencer-99","SugarCRM-1.1.3","Sun-PPP","Sun-PPP-2000","SunPro","Symlinks","TAPR-OHL-1.0","TCL","TCP-wrappers","TGPPL-1.0","TMate","TORQUE-1.1","TOSL","TPDL","TPL-1.0","TTWL","TTYP0","TU-Berlin-1.0","TU-Berlin-2.0","TekHVC","TermReadKey","ThirdEye","TrustedQSL","UCAR","UCL-1.0","UMich-Merit","UPL-1.0","URT-RLE","Ubuntu-font-1.0","UnRAR","Unicode-3.0","Unicode-DFS-2015","Unicode-DFS-2016","Unicode-TOU","UnixCrypt","Unlicense","Unlicense-libtelnet","Unlicense-libwhirlpool","VOSTROM","VSL-1.0","Vim","Vixie-Cron","W3C","W3C-19980720","W3C-20150513","WTFNMFPL","WTFPL","Watcom-1.0","Widget-Workshop","WordNet","Wsuipa","X11","X11-distribute-modifications-variant","X11-no-permit-persons","X11-swapped","XFree86-1.1","XSkat","Xdebug-1.03","Xerox","Xfig","Xnet","YPL-1.0","YPL-1.1","ZPL-1.1","ZPL-2.0","ZPL-2.1","Zed","Zeeff","Zend-2.0","Zimbra-1.3","Zimbra-1.4","Zlib","any-OSI","any-OSI-perl-modules","bcrypt-Solar-Designer","blessing","bzip2-1.0.6","check-cvs","checkmk","copyleft-next-0.3.0","copyleft-next-0.3.1","curl","cve-tou","diffmark","dtoa","dvipdfm","eGenix","etalab-2.0","fwlw","gSOAP-1.3b","generic-xts","gnuplot","gtkbook","hdparm","hyphen-bulgarian","iMatix","jove","libpng-1.6.35","libpng-2.0","libselinux-1.0","libtiff","libutil-David-Nugent","lsof","magaz","mailprio","man2html","metamail","mpi-permissive","mpich2","mplus","ngrep","pkgconf","pnmstitch","psfrag","psutils","python-ldap","radvd","snprintf","softSurfer","ssh-keyscan","swrule","threeparttable","ulem","w3m","wwl","xinetd","xkeyboard-config-Zinoviev","xlock","xpp","xzoom","zlib-acknowledgement"]),ud}var dd,Xp;function $$(){return Xp||(Xp=1,dd=["AGPL-1.0","AGPL-3.0","BSD-2-Clause-FreeBSD","BSD-2-Clause-NetBSD","GFDL-1.1","GFDL-1.2","GFDL-1.3","GPL-1.0","GPL-2.0","GPL-2.0-with-GCC-exception","GPL-2.0-with-autoconf-exception","GPL-2.0-with-bison-exception","GPL-2.0-with-classpath-exception","GPL-2.0-with-font-exception","GPL-3.0","GPL-3.0-with-GCC-exception","GPL-3.0-with-autoconf-exception","LGPL-2.0","LGPL-2.1","LGPL-3.0","Net-SNMP","Nunit","StandardML-NJ","bzip2-1.0.5","eCos-2.0","wxWindows"]),dd}var ld,Hp;function Z$(){return Hp||(Hp=1,ld=["389-exception","Asterisk-exception","Autoconf-exception-2.0","Autoconf-exception-3.0","Autoconf-exception-generic","Autoconf-exception-generic-3.0","Autoconf-exception-macro","Bison-exception-1.24","Bison-exception-2.2","Bootloader-exception","Classpath-exception-2.0","CLISP-exception-2.0","cryptsetup-OpenSSL-exception","DigiRule-FOSS-exception","eCos-exception-2.0","Fawkes-Runtime-exception","FLTK-exception","fmt-exception","Font-exception-2.0","freertos-exception-2.0","GCC-exception-2.0","GCC-exception-2.0-note","GCC-exception-3.1","Gmsh-exception","GNAT-exception","GNOME-examples-exception","GNU-compiler-exception","gnu-javamail-exception","GPL-3.0-interface-exception","GPL-3.0-linking-exception","GPL-3.0-linking-source-exception","GPL-CC-1.0","GStreamer-exception-2005","GStreamer-exception-2008","i2p-gpl-java-exception","KiCad-libraries-exception","LGPL-3.0-linking-exception","libpri-OpenH323-exception","Libtool-exception","Linux-syscall-note","LLGPL","LLVM-exception","LZMA-exception","mif-exception","OCaml-LGPL-linking-exception","OCCT-exception-1.0","OpenJDK-assembly-exception-1.0","openvpn-openssl-exception","PS-or-PDF-font-exception-20170817","QPL-1.0-INRIA-2004-exception","Qt-GPL-exception-1.0","Qt-LGPL-exception-1.1","Qwt-exception-1.0","SANE-exception","SHL-2.0","SHL-2.1","stunnel-exception","SWI-exception","Swift-exception","Texinfo-exception","u-boot-exception-2.0","UBDL-exception","Universal-FOSS-exception-1.0","vsftpd-openssl-exception","WxWindows-exception-3.1","x11vnc-openssl-exception"]),ld}var gd,Mp;function J$(){if(Mp)return gd;Mp=1;var e=[].concat(gm()).concat($$()),i=Z$();return gd=function(n){var o=0;function a(){return o<n.length}function t(w){if(w instanceof RegExp){var v=n.slice(o),j=v.match(w);if(j)return o+=j[0].length,j[0]}else if(n.indexOf(w,o)===o)return o+=w.length,w}function s(){t(/[ ]*/)}function r(){for(var w,v=["WITH","AND","OR","(",")",":","+"],j=0;j<v.length&&(w=t(v[j]),!w);j++);if(w==="+"&&o>1&&n[o-2]===" ")throw new Error("Space before `+`");return w&&{type:"OPERATOR",string:w}}function u(){return t(/[A-Za-z0-9-.]+/)}function d(){var w=u();if(!w)throw new Error("Expected idstring at offset "+o);return w}function l(){if(t("DocumentRef-")){var w=d();return{type:"DOCUMENTREF",string:w}}}function g(){if(t("LicenseRef-")){var w=d();return{type:"LICENSEREF",string:w}}}function h(){var w=o,v=u();if(e.indexOf(v)!==-1)return{type:"LICENSE",string:v};if(i.indexOf(v)!==-1)return{type:"EXCEPTION",string:v};o=w}function c(){return r()||l()||g()||h()}for(var p=[];a()&&(s(),!!a());){var f=c();if(!f)throw new Error("Unexpected `"+n[o]+"` at offset "+o);p.push(f)}return p},gd}var hd,Pp;function x$(){return Pp||(Pp=1,hd=function(e){var i=0;function n(){return i<e.length}function o(){return n()?e[i]:null}function a(){if(!n())throw new Error;i++}function t(f){var w=o();if(w&&w.type==="OPERATOR"&&f===w.string)return a(),w.string}function s(){if(t("WITH")){var f=o();if(f&&f.type==="EXCEPTION")return a(),f.string;throw new Error("Expected exception after `WITH`")}}function r(){var f=i,w="",v=o();if(v.type==="DOCUMENTREF"&&(a(),w+="DocumentRef-"+v.string+":",!t(":")))throw new Error("Expected `:` after `DocumentRef-...`");if(v=o(),v.type==="LICENSEREF")return a(),w+="LicenseRef-"+v.string,{license:w};i=f}function u(){var f=o();if(f&&f.type==="LICENSE"){a();var w={license:f.string};t("+")&&(w.plus=!0);var v=s();return v&&(w.exception=v),w}}function d(){var f=t("(");if(f){var w=c();if(!t(")"))throw new Error("Expected `)`");return w}}function l(){return d()||r()||u()}function g(f,w){return function v(){var j=w();if(j){if(!t(f))return j;var C=v();if(!C)throw new Error("Expected expression");return{left:j,conjunction:f.toLowerCase(),right:C}}}}var h=g("AND",l),c=g("OR",h),p=c();if(!p||n())throw new Error("Syntax error");return p}),hd}var cd,Np;function hm(){if(Np)return cd;Np=1;var e=J$(),i=x$();return cd=function(n){return i(e(n))},cd}var pd,Ep;function T$(){if(Ep)return pd;Ep=1;var e=hm(),i=gm();function n(v){try{return e(v),!0}catch{return!1}}function o(v,j){var C=j[0].length-v[0].length;return C!==0?C:v[0].toUpperCase().localeCompare(j[0].toUpperCase())}var a=[["APGL","AGPL"],["Gpl","GPL"],["GLP","GPL"],["APL","Apache"],["ISD","ISC"],["GLP","GPL"],["IST","ISC"],["Claude","Clause"],[" or later","+"],[" International",""],["GNU","GPL"],["GUN","GPL"],["+",""],["GNU GPL","GPL"],["GNU LGPL","LGPL"],["GNU/GPL","GPL"],["GNU GLP","GPL"],["GNU LESSER GENERAL PUBLIC LICENSE","LGPL"],["GNU Lesser General Public License","LGPL"],["GNU LESSER GENERAL PUBLIC LICENSE","LGPL-2.1"],["GNU Lesser General Public License","LGPL-2.1"],["LESSER GENERAL PUBLIC LICENSE","LGPL"],["Lesser General Public License","LGPL"],["LESSER GENERAL PUBLIC LICENSE","LGPL-2.1"],["Lesser General Public License","LGPL-2.1"],["GNU General Public License","GPL"],["Gnu public license","GPL"],["GNU Public License","GPL"],["GNU GENERAL PUBLIC LICENSE","GPL"],["MTI","MIT"],["Mozilla Public License","MPL"],["Universal Permissive License","UPL"],["WTH","WTF"],["WTFGPL","WTFPL"],["-License",""]].sort(o),t=0,s=1,r=[function(v){return v.toUpperCase()},function(v){return v.trim()},function(v){return v.replace(/\./g,"")},function(v){return v.replace(/\s+/g,"")},function(v){return v.replace(/\s+/g,"-")},function(v){return v.replace("v","-")},function(v){return v.replace(/,?\s*(\d)/,"-$1")},function(v){return v.replace(/,?\s*(\d)/,"-$1.0")},function(v){return v.replace(/,?\s*(V\.|v\.|V|v|Version|version)\s*(\d)/,"-$2")},function(v){return v.replace(/,?\s*(V\.|v\.|V|v|Version|version)\s*(\d)/,"-$2.0")},function(v){return v[0].toUpperCase()+v.slice(1)},function(v){return v.replace("/","-")},function(v){return v.replace(/\s*V\s*(\d)/,"-$1").replace(/(\d)$/,"$1.0")},function(v){return v.indexOf("3.0")!==-1?v+"-or-later":v+"-only"},function(v){return v+"only"},function(v){return v.replace(/(\d)$/,"-$1.0")},function(v){return v.replace(/(-| )?(\d)$/,"-$2-Clause")},function(v){return v.replace(/(-| )clause(-| )(\d)/,"-$3-Clause")},function(v){return v.replace(/\b(Modified|New|Revised)(-| )?BSD((-| )License)?/i,"BSD-3-Clause")},function(v){return v.replace(/\bSimplified(-| )?BSD((-| )License)?/i,"BSD-2-Clause")},function(v){return v.replace(/\b(Free|Net)(-| )?BSD((-| )License)?/i,"BSD-2-Clause-$1BSD")},function(v){return v.replace(/\bClear(-| )?BSD((-| )License)?/i,"BSD-3-Clause-Clear")},function(v){return v.replace(/\b(Old|Original)(-| )?BSD((-| )License)?/i,"BSD-4-Clause")},function(v){return"CC-"+v},function(v){return"CC-"+v+"-4.0"},function(v){return v.replace("Attribution","BY").replace("NonCommercial","NC").replace("NoDerivatives","ND").replace(/ (\d)/,"-$1").replace(/ ?International/,"")},function(v){return"CC-"+v.replace("Attribution","BY").replace("NonCommercial","NC").replace("NoDerivatives","ND").replace(/ (\d)/,"-$1").replace(/ ?International/,"")+"-4.0"}],u=i.map(function(v){var j=/^(.*)-\d+\.\d+$/.exec(v);return j?[j[0],j[1]]:[v,null]}).reduce(function(v,j){var C=j[1];return v[C]=v[C]||[],v[C].push(j[0]),v},{}),d=Object.keys(u).map(function(v){return[v,u[v]]}).filter(function(v){return v[1].length===1&&v[0]!==null&&v[0]!=="APL"}).map(function(v){return[v[0],v[1][0]]});u=void 0;var l=[["UNLI","Unlicense"],["WTF","WTFPL"],["2 CLAUSE","BSD-2-Clause"],["2-CLAUSE","BSD-2-Clause"],["3 CLAUSE","BSD-3-Clause"],["3-CLAUSE","BSD-3-Clause"],["AFFERO","AGPL-3.0-or-later"],["AGPL","AGPL-3.0-or-later"],["APACHE","Apache-2.0"],["ARTISTIC","Artistic-2.0"],["Affero","AGPL-3.0-or-later"],["BEER","Beerware"],["BOOST","BSL-1.0"],["BSD","BSD-2-Clause"],["CDDL","CDDL-1.1"],["ECLIPSE","EPL-1.0"],["FUCK","WTFPL"],["GNU","GPL-3.0-or-later"],["LGPL","LGPL-3.0-or-later"],["GPLV1","GPL-1.0-only"],["GPL-1","GPL-1.0-only"],["GPLV2","GPL-2.0-only"],["GPL-2","GPL-2.0-only"],["GPL","GPL-3.0-or-later"],["MIT +NO-FALSE-ATTRIBS","MITNFA"],["MIT","MIT"],["MPL","MPL-2.0"],["X11","X11"],["ZLIB","Zlib"]].concat(d).sort(o),g=0,h=1,c=function(v){for(var j=0;j<r.length;j++){var C=r[j](v).trim();if(C!==v&&n(C))return C}return null},p=function(v){for(var j=v.toUpperCase(),C=0;C<l.length;C++){var y=l[C];if(j.indexOf(y[g])>-1)return y[h]}return null},f=function(v,j){for(var C=0;C<a.length;C++){var y=a[C],k=y[t];if(v.indexOf(k)>-1){var S=v.replace(k,y[s]),J=j(S);if(J!==null)return J}}return null};pd=function(v,j){j=j||{};var C=j.upgrade===void 0?!0:!!j.upgrade;function y(T){return C?w(T):T}var k=typeof v=="string"&&v.trim().length!==0;if(!k)throw Error("Invalid argument. Expected non-empty string.");if(v=v.trim(),n(v))return y(v);var S=v.replace(/\+$/,"").trim();if(n(S))return y(S);var J=c(v);return J!==null||(J=f(v,function(T){return n(T)?T:c(T)}),J!==null)||(J=p(v),J!==null)||(J=f(v,p),J!==null)?y(J):null};function w(v){return["GPL-1.0","LGPL-1.0","AGPL-1.0","GPL-2.0","LGPL-2.0","AGPL-2.0","LGPL-2.1"].indexOf(v)!==-1?v+"-only":["GPL-1.0+","GPL-2.0+","GPL-3.0+","LGPL-2.0+","LGPL-2.1+","LGPL-3.0+","AGPL-1.0+","AGPL-3.0+"].indexOf(v)!==-1?v.replace(/\+$/,"-or-later"):["GPL-3.0","LGPL-3.0","AGPL-3.0"].indexOf(v)!==-1?v+"-or-later":v}return pd}var vd,Rp;function D$(){if(Rp)return vd;Rp=1;var e=hm(),i=T$(),n='license should be a valid SPDX license expression (without "LicenseRef"), "UNLICENSED", or "SEE LICENSE IN <filename>"',o=/^SEE LICEN[CS]E IN (.+)$/;function a(s,r){return r.slice(0,s.length)===s}function t(s){if(s.hasOwnProperty("license")){var r=s.license;return a("LicenseRef",r)||a("DocumentRef",r)}else return t(s.left)||t(s.right)}return vd=function(s){var r;try{r=e(s)}catch{var u;if(s==="UNLICENSED"||s==="UNLICENCED")return{validForOldPackages:!0,validForNewPackages:!0,unlicensed:!0};if(u=o.exec(s))return{validForOldPackages:!0,validForNewPackages:!0,inFile:u[1]};var d={validForOldPackages:!1,validForNewPackages:!1,warnings:[n]};if(s.trim().length!==0){var l=i(s);l&&d.warnings.push('license is similar to the valid expression "'+l+'"')}return d}return t(r)?{validForNewPackages:!1,validForOldPackages:!1,spdx:!0,warnings:[n]}:{validForNewPackages:!0,validForOldPackages:!0,spdx:!0}},vd}var cm={hasSubscribers:!1},Ie=cm,ba=cm;import("node:diagnostics_channel").then(e=>{Ie=e.channel("lru-cache:metrics"),ba=e.tracingChannel("lru-cache")}).catch(()=>{});var B$=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,yd=()=>Ie.hasSubscribers||ba.hasSubscribers,pm=new Set,Op=process||{},X$=(e,i,n,o)=>{typeof Op.emitWarning=="function"?Op.emitWarning(e,i,n,o):console.error(`[${n}] ${i}: ${e}`)},H$=e=>!pm.has(e),Vn=e=>!!e&&e===Math.floor(e)&&e>0&&isFinite(e),vm=e=>Vn(e)?e<=Math.pow(2,8)?Uint8Array:e<=Math.pow(2,16)?Uint16Array:e<=Math.pow(2,32)?Uint32Array:e<=Number.MAX_SAFE_INTEGER?ur:null:null,ur=class extends Array{constructor(i){super(i),this.fill(0)}},M$=class Ot{heap;length;static#n=!1;static create(i){let n=vm(i);if(!n)return[];Ot.#n=!0;let o=new Ot(i,n);return Ot.#n=!1,o}constructor(i,n){if(!Ot.#n)throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new n(i),this.length=0}push(i){this.heap[this.length++]=i}pop(){return this.heap[--this.length]}},P$=class ym{#n;#i;#e;#t;#o;#a;#r;#g;get perf(){return this.#g}ttl;ttlResolution;ttlAutopurge;updateAgeOnGet;updateAgeOnHas;allowStale;noDisposeOnSet;noUpdateTTL;maxEntrySize;sizeCalculation;noDeleteOnFetchRejection;noDeleteOnStaleGet;allowStaleOnFetchAbort;allowStaleOnFetchRejection;ignoreFetchAbort;backgroundFetchSize;#u;#c;#h;#d;#s;#f;#b;#y;#p;#S;#v;#L;#C;#w;#j;#Y;#P;#m;#D;static unsafeExposeInternals(i){return{starts:i.#C,ttls:i.#w,autopurgeTimers:i.#j,sizes:i.#L,keyMap:i.#h,keyList:i.#d,valList:i.#s,next:i.#f,prev:i.#b,get head(){return i.#y},get tail(){return i.#p},free:i.#S,isBackgroundFetch:n=>i.#l(n),backgroundFetch:(n,o,a,t)=>i.#R(n,o,a,t),moveToTail:n=>i.#M(n),indexes:n=>i.#$(n),rindexes:n=>i.#Z(n),isStale:n=>i.#k(n)}}get max(){return this.#n}get maxSize(){return this.#i}get calculatedSize(){return this.#c}get size(){return this.#u}get fetchMethod(){return this.#a}get memoMethod(){return this.#r}get dispose(){return this.#e}get onInsert(){return this.#t}get disposeAfter(){return this.#o}constructor(i){let{max:n=0,ttl:o,ttlResolution:a=1,ttlAutopurge:t,updateAgeOnGet:s,updateAgeOnHas:r,allowStale:u,dispose:d,onInsert:l,disposeAfter:g,noDisposeOnSet:h,noUpdateTTL:c,maxSize:p=0,maxEntrySize:f=0,sizeCalculation:w,fetchMethod:v,memoMethod:j,noDeleteOnFetchRejection:C,noDeleteOnStaleGet:y,allowStaleOnFetchRejection:k,allowStaleOnFetchAbort:S,ignoreFetchAbort:J,backgroundFetchSize:T=1,perf:M}=i;if(this.backgroundFetchSize=T,M!==void 0&&typeof M?.now!="function")throw new TypeError("perf option must have a now() method if specified");if(this.#g=M??B$,n!==0&&!Vn(n))throw new TypeError("max option must be a nonnegative integer");let he=n?vm(n):Array;if(!he)throw new Error("invalid max value: "+n);if(this.#n=n,this.#i=p,this.maxEntrySize=f||this.#i,this.sizeCalculation=w,this.sizeCalculation){if(!this.#i&&!this.maxEntrySize)throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(j!==void 0&&typeof j!="function")throw new TypeError("memoMethod must be a function if defined");if(this.#r=j,v!==void 0&&typeof v!="function")throw new TypeError("fetchMethod must be a function if specified");if(this.#a=v,this.#P=!!v,this.#h=new Map,this.#d=Array.from({length:n}).fill(void 0),this.#s=Array.from({length:n}).fill(void 0),this.#f=new he(n),this.#b=new he(n),this.#y=0,this.#p=0,this.#S=M$.create(n),this.#u=0,this.#c=0,typeof d=="function"&&(this.#e=d),typeof l=="function"&&(this.#t=l),typeof g=="function"?(this.#o=g,this.#v=[]):(this.#o=void 0,this.#v=void 0),this.#Y=!!this.#e,this.#D=!!this.#t,this.#m=!!this.#o,this.noDisposeOnSet=!!h,this.noUpdateTTL=!!c,this.noDeleteOnFetchRejection=!!C,this.allowStaleOnFetchRejection=!!k,this.allowStaleOnFetchAbort=!!S,this.ignoreFetchAbort=!!J,this.maxEntrySize!==0){if(this.#i!==0&&!Vn(this.#i))throw new TypeError("maxSize must be a positive integer if specified");if(!Vn(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");this.#_()}if(this.allowStale=!!u,this.noDeleteOnStaleGet=!!y,this.updateAgeOnGet=!!s,this.updateAgeOnHas=!!r,this.ttlResolution=Vn(a)||a===0?a:1,this.ttlAutopurge=!!t,this.ttl=o||0,this.ttl){if(!Vn(this.ttl))throw new TypeError("ttl must be a positive integer if specified");this.#O()}if(this.#n===0&&this.ttl===0&&this.#i===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!this.#n&&!this.#i){let Je="LRU_CACHE_UNBOUNDED";H$(Je)&&(pm.add(Je),X$("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",Je,ym))}}getRemainingTTL(i){return this.#h.has(i)?1/0:0}#O(){let i=new ur(this.#n),n=new ur(this.#n);this.#w=i,this.#C=n;let o=this.ttlAutopurge?Array.from({length:this.#n}):void 0;this.#j=o,this.#A=(r,u,d=this.#g.now())=>{n[r]=u!==0?d:0,i[r]=u,a(r,u)},this.#B=r=>{n[r]=i[r]!==0?this.#g.now():0,a(r,i[r])};let a=this.ttlAutopurge?(r,u)=>{if(o?.[r]&&(clearTimeout(o[r]),o[r]=void 0),u&&u!==0&&o){let d=setTimeout(()=>{this.#k(r)&&this.#J(this.#d[r],"expire")},u+1);d.unref&&d.unref(),o[r]=d}}:()=>{};this.#x=(r,u)=>{if(i[u]){let d=i[u],l=n[u];if(!d||!l)return;r.ttl=d,r.start=l,r.now=t||s();let g=r.now-l;r.remainingTTL=d-g}};let t=0,s=()=>{let r=this.#g.now();if(this.ttlResolution>0){t=r;let u=setTimeout(()=>t=0,this.ttlResolution);u.unref&&u.unref()}return r};this.getRemainingTTL=r=>{let u=this.#h.get(r);if(u===void 0)return 0;let d=i[u],l=n[u];if(!d||!l)return 1/0;let g=(t||s())-l;return d-g},this.#k=r=>{let u=n[r],d=i[r];return!!d&&!!u&&(t||s())-u>d}}#B=()=>{};#x=()=>{};#A=()=>{};#k=()=>!1;#_(){let i=new ur(this.#n);this.#c=0,this.#L=i,this.#X=n=>{this.#c-=i[n],i[n]=0},this.#G=(n,o,a,t)=>{if(!Vn(a)){if(this.#l(o))return this.backgroundFetchSize;if(t){if(typeof t!="function")throw new TypeError("sizeCalculation must be a function");if(a=t(o,n),!Vn(a))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.")}return a},this.#N=(n,o,a)=>{if(i[n]=o,this.#i){let t=this.#i-i[n];for(;this.#c>t;)this.#E(!0)}this.#c+=i[n],a&&(a.entrySize=o,a.totalCalculatedSize=this.#c)}}#X=i=>{};#N=(i,n,o)=>{};#G=(i,n,o,a)=>{if(o||a)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0};*#$({allowStale:i=this.allowStale}={}){if(this.#u)for(let n=this.#p;this.#F(n)&&((i||!this.#k(n))&&(yield n),n!==this.#y);)n=this.#b[n]}*#Z({allowStale:i=this.allowStale}={}){if(this.#u)for(let n=this.#y;this.#F(n)&&((i||!this.#k(n))&&(yield n),n!==this.#p);)n=this.#f[n]}#F(i){return i!==void 0&&this.#h.get(this.#d[i])===i}*entries(){for(let i of this.#$())this.#s[i]!==void 0&&this.#d[i]!==void 0&&!this.#l(this.#s[i])&&(yield[this.#d[i],this.#s[i]])}*rentries(){for(let i of this.#Z())this.#s[i]!==void 0&&this.#d[i]!==void 0&&!this.#l(this.#s[i])&&(yield[this.#d[i],this.#s[i]])}*keys(){for(let i of this.#$()){let n=this.#d[i];n!==void 0&&!this.#l(this.#s[i])&&(yield n)}}*rkeys(){for(let i of this.#Z()){let n=this.#d[i];n!==void 0&&!this.#l(this.#s[i])&&(yield n)}}*values(){for(let i of this.#$())this.#s[i]!==void 0&&!this.#l(this.#s[i])&&(yield this.#s[i])}*rvalues(){for(let i of this.#Z())this.#s[i]!==void 0&&!this.#l(this.#s[i])&&(yield this.#s[i])}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="LRUCache";find(i,n={}){for(let o of this.#$()){let a=this.#s[o],t=this.#l(a)?a.__staleWhileFetching:a;if(t!==void 0&&i(t,this.#d[o],this))return this.#H(this.#d[o],n)}}forEach(i,n=this){for(let o of this.#$()){let a=this.#s[o],t=this.#l(a)?a.__staleWhileFetching:a;t!==void 0&&i.call(n,t,this.#d[o],this)}}rforEach(i,n=this){for(let o of this.#Z()){let a=this.#s[o],t=this.#l(a)?a.__staleWhileFetching:a;t!==void 0&&i.call(n,t,this.#d[o],this)}}purgeStale(){let i=!1;for(let n of this.#Z({allowStale:!0}))this.#k(n)&&(this.#J(this.#d[n],"expire"),i=!0);return i}info(i){let n=this.#h.get(i);if(n===void 0)return;let o=this.#s[n],a=this.#l(o)?o.__staleWhileFetching:o;if(a===void 0)return;let t={value:a};if(this.#w&&this.#C){let s=this.#w[n],r=this.#C[n];if(s&&r){let u=s-(this.#g.now()-r);t.ttl=u,t.start=Date.now()}}return this.#L&&(t.size=this.#L[n]),t}dump(){let i=[];for(let n of this.#$({allowStale:!0})){let o=this.#d[n],a=this.#s[n],t=this.#l(a)?a.__staleWhileFetching:a;if(t===void 0||o===void 0)continue;let s={value:t};if(this.#w&&this.#C){s.ttl=this.#w[n];let r=this.#g.now()-this.#C[n];s.start=Math.floor(Date.now()-r)}this.#L&&(s.size=this.#L[n]),i.unshift([o,s])}return i}load(i){this.clear();for(let[n,o]of i){if(o.start){let a=Date.now()-o.start;o.start=this.#g.now()-a}this.#T(n,o.value,o)}}set(i,n,o={}){let{status:a=Ie.hasSubscribers?{}:void 0}=o;o.status=a,a&&(a.op="set",a.key=i,n!==void 0&&(a.value=n),a.cache=this);let t=this.#T(i,n,o);return a&&Ie.hasSubscribers&&Ie.publish(a),t}#T(i,n,o,a){let{ttl:t=this.ttl,start:s,noDisposeOnSet:r=this.noDisposeOnSet,sizeCalculation:u=this.sizeCalculation,status:d}=o,l=this.#l(n);if(n===void 0)return d&&(d.set="deleted"),this.delete(i),this;let{noUpdateTTL:g=this.noUpdateTTL}=o;d&&!l&&(d.value=n);let h=this.#G(i,n,o.size||0,u,d);if(this.maxEntrySize&&h>this.maxEntrySize)return this.#J(i,"set"),d&&(d.set="miss",d.maxEntrySizeExceeded=!0),this;let c=this.#u===0?void 0:this.#h.get(i);if(c===void 0)c=this.#u===0?this.#p:this.#S.length!==0?this.#S.pop():this.#u===this.#n?this.#E(!1):this.#u,this.#d[c]=i,this.#s[c]=n,this.#h.set(i,c),this.#f[this.#p]=c,this.#b[c]=this.#p,this.#p=c,this.#u++,this.#N(c,h,d),d&&(d.set="add"),g=!1,this.#D&&!l&&this.#t?.(n,i,"add");else{this.#M(c);let p=this.#s[c];if(n!==p){if(!r)if(this.#l(p)){p!==a&&p.__abortController.abort(new Error("replaced"));let{__staleWhileFetching:f}=p;f!==void 0&&f!==n&&(this.#Y&&this.#e?.(f,i,"set"),this.#m&&this.#v?.push([f,i,"set"]))}else this.#Y&&this.#e?.(p,i,"set"),this.#m&&this.#v?.push([p,i,"set"]);if(this.#X(c),this.#N(c,h,d),this.#s[c]=n,!l){let f=p&&this.#l(p)?p.__staleWhileFetching:p,w=f===void 0?"add":n!==f?"replace":"update";d&&(d.set=w,f!==void 0&&(d.oldValue=f)),this.#D&&this.onInsert?.(n,i,w)}}else l||(d&&(d.set="update"),this.#D&&this.onInsert?.(n,i,"update"))}if(t!==0&&!this.#w&&this.#O(),this.#w&&(g||this.#A(c,t,s),d&&this.#x(d,c)),!r&&this.#m&&this.#v){let p=this.#v,f;for(;f=p?.shift();)this.#o?.(...f)}return this}pop(){try{for(;this.#u;){let i=this.#s[this.#y];if(this.#E(!0),this.#l(i)){if(i.__staleWhileFetching)return i.__staleWhileFetching}else if(i!==void 0)return i}}finally{if(this.#m&&this.#v){let i=this.#v,n;for(;n=i?.shift();)this.#o?.(...n)}}}#E(i){let n=this.#y,o=this.#d[n],a=this.#s[n],t=this.#l(a);t&&a.__abortController.abort(new Error("evicted"));let s=t?a.__staleWhileFetching:a;return(this.#Y||this.#m)&&s!==void 0&&(this.#Y&&this.#e?.(s,o,"evict"),this.#m&&this.#v?.push([s,o,"evict"])),this.#X(n),this.#j?.[n]&&(clearTimeout(this.#j[n]),this.#j[n]=void 0),i&&(this.#d[n]=void 0,this.#s[n]=void 0,this.#S.push(n)),this.#u===1?(this.#y=this.#p=0,this.#S.length=0):this.#y=this.#f[n],this.#h.delete(o),this.#u--,n}has(i,n={}){let{status:o=Ie.hasSubscribers?{}:void 0}=n;n.status=o,o&&(o.op="has",o.key=i,o.cache=this);let a=this.#z(i,n);return Ie.hasSubscribers&&Ie.publish(o),a}#z(i,n={}){let{updateAgeOnHas:o=this.updateAgeOnHas,status:a}=n,t=this.#h.get(i);if(t!==void 0){let s=this.#s[t];if(this.#l(s)&&s.__staleWhileFetching===void 0)return!1;if(this.#k(t))a&&(a.has="stale",this.#x(a,t));else return o&&this.#B(t),a&&(a.has="hit",this.#x(a,t)),!0}else a&&(a.has="miss");return!1}peek(i,n={}){let{status:o=yd()?{}:void 0}=n;o&&(o.op="peek",o.key=i,o.cache=this),n.status=o;let a=this.#K(i,n);return Ie.hasSubscribers&&Ie.publish(o),a}#K(i,n){let{status:o,allowStale:a=this.allowStale}=n,t=this.#h.get(i);if(t===void 0||!a&&this.#k(t)){o&&(o.peek=t===void 0?"miss":"stale");return}let s=this.#s[t],r=this.#l(s)?s.__staleWhileFetching:s;return o&&(r!==void 0?(o.peek="hit",o.value=r):o.peek="miss"),r}#R(i,n,o,a){let t=n===void 0?void 0:this.#s[n];if(this.#l(t))return t;let s=new AbortController,{signal:r}=o;r?.addEventListener("abort",()=>s.abort(r.reason),{signal:s.signal});let u={signal:s.signal,options:o,context:a},d=(f,w=!1)=>{let{aborted:v}=s.signal,j=o.ignoreFetchAbort&&f!==void 0,C=o.ignoreFetchAbort||!!(o.allowStaleOnFetchAbort&&f!==void 0);if(o.status&&(v&&!w?(o.status.fetchAborted=!0,o.status.fetchError=s.signal.reason,j&&(o.status.fetchAbortIgnored=!0)):o.status.fetchResolved=!0),v&&!j&&!w)return g(s.signal.reason,C);let y=c,k=this.#s[n];return(k===c||k===void 0&&j&&w)&&(f===void 0?y.__staleWhileFetching!==void 0?this.#s[n]=y.__staleWhileFetching:this.#J(i,"fetch"):(o.status&&(o.status.fetchUpdated=!0),this.#T(i,f,u.options,y))),f},l=f=>(o.status&&(o.status.fetchRejected=!0,o.status.fetchError=f),g(f,!1)),g=(f,w)=>{let{aborted:v}=s.signal,j=v&&o.allowStaleOnFetchAbort,C=j||o.allowStaleOnFetchRejection,y=C||o.noDeleteOnFetchRejection,k=c;if(this.#s[n]===c&&(!y||!w&&k.__staleWhileFetching===void 0?this.#J(i,"fetch"):j||(this.#s[n]=k.__staleWhileFetching)),C)return o.status&&k.__staleWhileFetching!==void 0&&(o.status.returnedStale=!0),k.__staleWhileFetching;if(k.__returned===k)throw f},h=(f,w)=>{let v=this.#a?.(i,t,u);s.signal.addEventListener("abort",()=>{(!o.ignoreFetchAbort||o.allowStaleOnFetchAbort)&&(f(void 0),o.allowStaleOnFetchAbort&&(f=j=>d(j,!0)))}),v&&v instanceof Promise?v.then(j=>f(j===void 0?void 0:j),w):v!==void 0&&f(v)};o.status&&(o.status.fetchDispatched=!0);let c=new Promise(h).then(d,l),p=Object.assign(c,{__abortController:s,__staleWhileFetching:t,__returned:void 0});return n===void 0?(this.#T(i,p,{...u.options,status:void 0}),n=this.#h.get(i)):this.#s[n]=p,p}#l(i){if(!this.#P)return!1;let n=i;return!!n&&n instanceof Promise&&n.hasOwnProperty("__staleWhileFetching")&&n.__abortController instanceof AbortController}fetch(i,n={}){let o=ba.hasSubscribers,{status:a=yd()?{}:void 0}=n;n.status=a,a&&n.context&&(a.context=n.context);let t=this.#Q(i,n);return a&&o&&(a.trace=!0,ba.tracePromise(()=>t,a).catch(()=>{})),t}async#Q(i,n={}){let{allowStale:o=this.allowStale,updateAgeOnGet:a=this.updateAgeOnGet,noDeleteOnStaleGet:t=this.noDeleteOnStaleGet,ttl:s=this.ttl,noDisposeOnSet:r=this.noDisposeOnSet,size:u=0,sizeCalculation:d=this.sizeCalculation,noUpdateTTL:l=this.noUpdateTTL,noDeleteOnFetchRejection:g=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:h=this.allowStaleOnFetchRejection,ignoreFetchAbort:c=this.ignoreFetchAbort,allowStaleOnFetchAbort:p=this.allowStaleOnFetchAbort,context:f,forceRefresh:w=!1,status:v,signal:j}=n;if(v&&(v.op="fetch",v.key=i,w&&(v.forceRefresh=!0),v.cache=this),!this.#P)return v&&(v.fetch="get"),this.#H(i,{allowStale:o,updateAgeOnGet:a,noDeleteOnStaleGet:t,status:v});let C={allowStale:o,updateAgeOnGet:a,noDeleteOnStaleGet:t,ttl:s,noDisposeOnSet:r,size:u,sizeCalculation:d,noUpdateTTL:l,noDeleteOnFetchRejection:g,allowStaleOnFetchRejection:h,allowStaleOnFetchAbort:p,ignoreFetchAbort:c,status:v,signal:j},y=this.#h.get(i);if(y===void 0){v&&(v.fetch="miss");let k=this.#R(i,y,C,f);return k.__returned=k}else{let k=this.#s[y];if(this.#l(k)){let M=o&&k.__staleWhileFetching!==void 0;return v&&(v.fetch="inflight",M&&(v.returnedStale=!0)),M?k.__staleWhileFetching:k.__returned=k}let S=this.#k(y);if(!w&&!S)return v&&(v.fetch="hit"),this.#M(y),a&&this.#B(y),v&&this.#x(v,y),k;let J=this.#R(i,y,C,f),T=J.__staleWhileFetching!==void 0&&o;return v&&(v.fetch=S?"stale":"refresh",T&&S&&(v.returnedStale=!0)),T?J.__staleWhileFetching:J.__returned=J}}forceFetch(i,n={}){let o=ba.hasSubscribers,{status:a=yd()?{}:void 0}=n;n.status=a,a&&n.context&&(a.context=n.context);let t=this.#q(i,n);return a&&o&&(a.trace=!0,ba.tracePromise(()=>t,a).catch(()=>{})),t}async#q(i,n={}){let o=await this.#Q(i,n);if(o===void 0)throw new Error("fetch() returned undefined");return o}memo(i,n={}){let{status:o=Ie.hasSubscribers?{}:void 0}=n;n.status=o,o&&(o.op="memo",o.key=i,n.context&&(o.context=n.context),o.cache=this);let a=this.#U(i,n);return o&&(o.value=a),Ie.hasSubscribers&&Ie.publish(o),a}#U(i,n={}){let o=this.#r;if(!o)throw new Error("no memoMethod provided to constructor");let{context:a,status:t,forceRefresh:s,...r}=n;t&&s&&(t.forceRefresh=!0);let u=this.#H(i,r),d=s||u===void 0;if(t&&(t.memo=d?"miss":"hit",d||(t.value=u)),!d)return u;let l=o(i,u,{options:r,context:a});return t&&(t.value=l),this.#T(i,l,r),l}get(i,n={}){let{status:o=Ie.hasSubscribers?{}:void 0}=n;n.status=o,o&&(o.op="get",o.key=i,o.cache=this);let a=this.#H(i,n);return o&&(a!==void 0&&(o.value=a),Ie.hasSubscribers&&Ie.publish(o)),a}#H(i,n={}){let{allowStale:o=this.allowStale,updateAgeOnGet:a=this.updateAgeOnGet,noDeleteOnStaleGet:t=this.noDeleteOnStaleGet,status:s}=n,r=this.#h.get(i);if(r===void 0){s&&(s.get="miss");return}let u=this.#s[r],d=this.#l(u);return s&&this.#x(s,r),this.#k(r)?d?(s&&(s.get="stale-fetching"),o&&u.__staleWhileFetching!==void 0?(s&&(s.returnedStale=!0),u.__staleWhileFetching):void 0):(t||this.#J(i,"expire"),s&&(s.get="stale"),o?(s&&(s.returnedStale=!0),u):void 0):(s&&(s.get=d?"fetching":"hit"),this.#M(r),a&&this.#B(r),d?u.__staleWhileFetching:u)}#W(i,n){this.#b[n]=i,this.#f[i]=n}#M(i){i!==this.#p&&(i===this.#y?this.#y=this.#f[i]:this.#W(this.#b[i],this.#f[i]),this.#W(this.#p,i),this.#p=i)}delete(i){return this.#J(i,"delete")}#J(i,n){Ie.hasSubscribers&&Ie.publish({op:"delete",delete:n,key:i,cache:this});let o=!1;if(this.#u!==0){let a=this.#h.get(i);if(a!==void 0)if(this.#j?.[a]&&(clearTimeout(this.#j?.[a]),this.#j[a]=void 0),o=!0,this.#u===1)this.#I(n);else{this.#X(a);let t=this.#s[a];if(this.#l(t)?t.__abortController.abort(new Error("deleted")):(this.#Y||this.#m)&&(this.#Y&&this.#e?.(t,i,n),this.#m&&this.#v?.push([t,i,n])),this.#h.delete(i),this.#d[a]=void 0,this.#s[a]=void 0,a===this.#p)this.#p=this.#b[a];else if(a===this.#y)this.#y=this.#f[a];else{let s=this.#b[a];this.#f[s]=this.#f[a];let r=this.#f[a];this.#b[r]=this.#b[a]}this.#u--,this.#S.push(a)}}if(this.#m&&this.#v?.length){let a=this.#v,t;for(;t=a?.shift();)this.#o?.(...t)}return o}clear(){return this.#I("delete")}#I(i){for(let n of this.#Z({allowStale:!0})){let o=this.#s[n];if(this.#l(o))o.__abortController.abort(new Error("deleted"));else{let a=this.#d[n];this.#Y&&this.#e?.(o,a,i),this.#m&&this.#v?.push([o,a,i])}}if(this.#h.clear(),this.#s.fill(void 0),this.#d.fill(void 0),this.#w&&this.#C){this.#w.fill(0),this.#C.fill(0);for(let n of this.#j??[])n!==void 0&&clearTimeout(n);this.#j?.fill(void 0)}if(this.#L&&this.#L.fill(0),this.#y=0,this.#p=0,this.#S.length=0,this.#c=0,this.#u=0,this.#m&&this.#v){let n=this.#v,o;for(;o=n?.shift();)this.#o?.(...o)}}};const N$=Object.defineProperty({__proto__:null,LRUCache:P$},Symbol.toStringTag,{value:"Module"}),E$=_g(N$);var fd,Ap;function R$(){if(Ap)return fd;Ap=1;const e=(...t)=>t.every(s=>s)?t.join(""):"",i=t=>t?encodeURIComponent(t):"",n=t=>t.toLowerCase().replace(/^\W+/g,"").replace(/(?<!\W)\W+$/,"").replace(/\//g,"").replace(/\W+/g,"-"),o={sshtemplate:({domain:t,user:s,project:r,committish:u})=>`git@${t}:${s}/${r}.git${e("#",u)}`,sshurltemplate:({domain:t,user:s,project:r,committish:u})=>`git+ssh://git@${t}/${s}/${r}.git${e("#",u)}`,edittemplate:({domain:t,user:s,project:r,committish:u,editpath:d,path:l})=>`https://${t}/${s}/${r}${e("/",d,"/",i(u||"HEAD"),"/",l)}`,browsetemplate:({domain:t,user:s,project:r,committish:u,treepath:d})=>`https://${t}/${s}/${r}${e("/",d,"/",i(u))}`,browsetreetemplate:({domain:t,user:s,project:r,committish:u,treepath:d,path:l,fragment:g,hashformat:h})=>`https://${t}/${s}/${r}/${d}/${i(u||"HEAD")}/${l}${e("#",h(g||""))}`,browseblobtemplate:({domain:t,user:s,project:r,committish:u,blobpath:d,path:l,fragment:g,hashformat:h})=>`https://${t}/${s}/${r}/${d}/${i(u||"HEAD")}/${l}${e("#",h(g||""))}`,docstemplate:({domain:t,user:s,project:r,treepath:u,committish:d})=>`https://${t}/${s}/${r}${e("/",u,"/",i(d))}#readme`,httpstemplate:({auth:t,domain:s,user:r,project:u,committish:d})=>`git+https://${e(t,"@")}${s}/${r}/${u}.git${e("#",d)}`,filetemplate:({domain:t,user:s,project:r,committish:u,path:d})=>`https://${t}/${s}/${r}/raw/${i(u||"HEAD")}/${d}`,shortcuttemplate:({type:t,user:s,project:r,committish:u})=>`${t}:${s}/${r}${e("#",u)}`,pathtemplate:({user:t,project:s,committish:r})=>`${t}/${s}${e("#",r)}`,bugstemplate:({domain:t,user:s,project:r})=>`https://${t}/${s}/${r}/issues`,hashformat:n},a={};a.github={protocols:["git:","http:","git+ssh:","git+https:","ssh:","https:"],domain:"github.com",treepath:"tree",blobpath:"blob",editpath:"edit",filetemplate:({auth:t,user:s,project:r,committish:u,path:d})=>`https://${e(t,"@")}raw.githubusercontent.com/${s}/${r}/${i(u||"HEAD")}/${d}`,gittemplate:({auth:t,domain:s,user:r,project:u,committish:d})=>`git://${e(t,"@")}${s}/${r}/${u}.git${e("#",d)}`,tarballtemplate:({domain:t,user:s,project:r,committish:u})=>`https://codeload.${t}/${s}/${r}/tar.gz/${i(u||"HEAD")}`,extract:t=>{let[,s,r,u,d]=t.pathname.split("/",5);if(!(u&&u!=="tree")&&(u||(d=t.hash.slice(1)),r&&r.endsWith(".git")&&(r=r.slice(0,-4)),!(!s||!r)))return{user:s,project:r,committish:d}}},a.bitbucket={protocols:["git+ssh:","git+https:","ssh:","https:"],domain:"bitbucket.org",treepath:"src",blobpath:"src",editpath:"?mode=edit",edittemplate:({domain:t,user:s,project:r,committish:u,treepath:d,path:l,editpath:g})=>`https://${t}/${s}/${r}${e("/",d,"/",i(u||"HEAD"),"/",l,g)}`,tarballtemplate:({domain:t,user:s,project:r,committish:u})=>`https://${t}/${s}/${r}/get/${i(u||"HEAD")}.tar.gz`,extract:t=>{let[,s,r,u]=t.pathname.split("/",4);if(!["get"].includes(u)&&(r&&r.endsWith(".git")&&(r=r.slice(0,-4)),!(!s||!r)))return{user:s,project:r,committish:t.hash.slice(1)}}},a.gitlab={protocols:["git+ssh:","git+https:","ssh:","https:"],domain:"gitlab.com",treepath:"tree",blobpath:"tree",editpath:"-/edit",tarballtemplate:({domain:t,user:s,project:r,committish:u})=>`https://${t}/api/v4/projects/${i(s+"/"+r)}/repository/archive.tar.gz?sha=${i(u||"HEAD")}`,extract:t=>{const s=t.pathname.slice(1);if(s.includes("/-/")||s.includes("/archive.tar.gz"))return;const r=s.split("/");let u=r.pop();u.endsWith(".git")&&(u=u.slice(0,-4));const d=r.join("/");if(!(!d||!u))return{user:d,project:u,committish:t.hash.slice(1)}}},a.gist={protocols:["git:","git+ssh:","git+https:","ssh:","https:"],domain:"gist.github.com",editpath:"edit",sshtemplate:({domain:t,project:s,committish:r})=>`git@${t}:${s}.git${e("#",r)}`,sshurltemplate:({domain:t,project:s,committish:r})=>`git+ssh://git@${t}/${s}.git${e("#",r)}`,edittemplate:({domain:t,user:s,project:r,committish:u,editpath:d})=>`https://${t}/${s}/${r}${e("/",i(u))}/${d}`,browsetemplate:({domain:t,project:s,committish:r})=>`https://${t}/${s}${e("/",i(r))}`,browsetreetemplate:({domain:t,project:s,committish:r,path:u,hashformat:d})=>`https://${t}/${s}${e("/",i(r))}${e("#",d(u))}`,browseblobtemplate:({domain:t,project:s,committish:r,path:u,hashformat:d})=>`https://${t}/${s}${e("/",i(r))}${e("#",d(u))}`,docstemplate:({domain:t,project:s,committish:r})=>`https://${t}/${s}${e("/",i(r))}`,httpstemplate:({domain:t,project:s,committish:r})=>`git+https://${t}/${s}.git${e("#",r)}`,filetemplate:({user:t,project:s,committish:r,path:u})=>`https://gist.githubusercontent.com/${t}/${s}/raw${e("/",i(r))}/${u}`,shortcuttemplate:({type:t,project:s,committish:r})=>`${t}:${s}${e("#",r)}`,pathtemplate:({project:t,committish:s})=>`${t}${e("#",s)}`,bugstemplate:({domain:t,project:s})=>`https://${t}/${s}`,gittemplate:({domain:t,project:s,committish:r})=>`git://${t}/${s}.git${e("#",r)}`,tarballtemplate:({project:t,committish:s})=>`https://codeload.github.com/gist/${t}/tar.gz/${i(s||"HEAD")}`,extract:t=>{let[,s,r,u]=t.pathname.split("/",4);if(u!=="raw"){if(!r){if(!s)return;r=s,s=null}return r.endsWith(".git")&&(r=r.slice(0,-4)),{user:s,project:r,committish:t.hash.slice(1)}}},hashformat:function(t){return t&&"file-"+n(t)}},a.sourcehut={protocols:["git+ssh:","https:"],domain:"git.sr.ht",treepath:"tree",blobpath:"tree",filetemplate:({domain:t,user:s,project:r,committish:u,path:d})=>`https://${t}/${s}/${r}/blob/${i(u)||"HEAD"}/${d}`,httpstemplate:({domain:t,user:s,project:r,committish:u})=>`https://${t}/${s}/${r}${e("#",u)}`,tarballtemplate:({domain:t,user:s,project:r,committish:u})=>`https://${t}/${s}/${r}/archive/${i(u)||"HEAD"}.tar.gz`,bugstemplate:()=>null,extract:t=>{let[,s,r,u]=t.pathname.split("/",4);if(!["archive"].includes(u)&&(r&&r.endsWith(".git")&&(r=r.slice(0,-4)),!(!s||!r)))return{user:s,project:r,committish:t.hash.slice(1)}}};for(const[t,s]of Object.entries(a))a[t]=Object.assign({},o,s);return fd=a,fd}var md,Gp;function fm(){if(Gp)return md;Gp=1;const e=(a,t,s)=>{const r=a.indexOf(s);return a.lastIndexOf(t,r>-1?r:1/0)},i=a=>{try{return new URL(a)}catch{}},n=(a,t)=>{const s=a.indexOf(":"),r=a.slice(0,s+1);if(Object.prototype.hasOwnProperty.call(t,r)||a.substr(s,3)==="://")return a;const u=a.indexOf("@");return u>-1?u>s?`git+ssh://${a}`:a:`${a.slice(0,s+1)}//${a.slice(s+1)}`},o=a=>{const t=e(a,"@","#"),s=e(a,":","#");return s>t&&(a=a.slice(0,s)+"/"+a.slice(s+1)),e(a,":","#")===-1&&a.indexOf("//")===-1&&(a=`git+ssh://${a}`),a};return md=(a,t)=>{const s=t?n(a,t):a;return i(s)||i(o(s))},md}var bd,Fp;function O$(){if(Fp)return bd;Fp=1;const e=fm(),i=n=>{const o=n.indexOf("#"),a=n.indexOf("/"),t=n.indexOf("/",a+1),s=n.indexOf(":"),r=/\s/.exec(n),u=n.indexOf("@"),d=!r||o>-1&&r.index>o,l=u===-1||o>-1&&u>o,g=s===-1||o>-1&&s>o,h=t===-1||o>-1&&t>o,c=a>0,p=o>-1?n[o-1]!=="/":!n.endsWith("/"),f=!n.startsWith(".");return d&&c&&p&&f&&l&&g&&h};return bd=(n,o,{gitHosts:a,protocols:t})=>{if(!n)return;const s=i(n)?`github:${n}`:n,r=e(s,t);if(!r)return;const u=a.byShortcut[r.protocol],d=a.byDomain[r.hostname.startsWith("www.")?r.hostname.slice(4):r.hostname],l=u||d;if(!l)return;const g=a[u||d];let h=null;t[r.protocol]?.auth&&(r.username||r.password)&&(h=`${r.username}${r.password?":"+r.password:""}`);let c=null,p=null,f=null,w=null;try{if(u){let v=r.pathname.startsWith("/")?r.pathname.slice(1):r.pathname;const j=v.indexOf("@");j>-1&&(v=v.slice(j+1));const C=v.lastIndexOf("/");C>-1?(p=decodeURIComponent(v.slice(0,C)),p||(p=null),f=decodeURIComponent(v.slice(C+1))):f=decodeURIComponent(v),f.endsWith(".git")&&(f=f.slice(0,-4)),r.hash&&(c=decodeURIComponent(r.hash.slice(1))),w="shortcut"}else{if(!g.protocols.includes(r.protocol))return;const v=g.extract(r);if(!v)return;p=v.user&&decodeURIComponent(v.user),f=decodeURIComponent(v.project),c=decodeURIComponent(v.committish),w=t[r.protocol]?.name||r.protocol.slice(0,-1)}}catch(v){if(v instanceof URIError)return;throw v}return[l,p,h,f,c,w,o]},bd}var wd,Qp;function A$(){if(Qp)return wd;Qp=1;const{LRUCache:e}=E$,i=R$(),n=O$(),o=fm(),a=new e({max:1e3});function t(r){try{const{protocol:u,hostname:d,pathname:l}=new URL(r);if(!d)return null;const g=/(?:git\+)http:$/.test(u)?"http:":"https:",h=l.replace(/\.git$/,"");return`${g}//${d}${h}`}catch{return null}}class s{constructor(u,d,l,g,h,c,p={}){Object.assign(this,s.#n[u],{type:u,user:d,auth:l,project:g,committish:h,default:c,opts:p})}static#n={byShortcut:{},byDomain:{}};static#i={"git+ssh:":{name:"sshurl"},"ssh:":{name:"sshurl"},"git+https:":{name:"https",auth:!0},"git:":{auth:!0},"http:":{auth:!0},"https:":{auth:!0},"git+http:":{auth:!0}};static addHost(u,d){s.#n[u]=d,s.#n.byDomain[d.domain]=u,s.#n.byShortcut[`${u}:`]=u,s.#i[`${u}:`]={name:u}}static fromUrl(u,d){if(typeof u!="string")return;const l=u+JSON.stringify(d||{});if(!a.has(l)){const g=n(u,d,{gitHosts:s.#n,protocols:s.#i});a.set(l,g?new s(...g):void 0)}return a.get(l)}static fromManifest(u,d={}){if(!u||typeof u!="object")return;const l=u.repository,g=l&&(typeof l=="string"?l:typeof l=="object"&&typeof l.url=="string"?l.url:null);if(!g)throw new Error("no repository");const h=g&&s.fromUrl(g.replace(/^git\+/,""),d)||null;if(h)return h;const c=t(g);return s.fromUrl(c,d)||c}static parseUrl(u){return o(u)}#e(u,d){if(typeof u!="function")return null;const l={...this,...this.opts,...d};l.path||(l.path=""),l.path.startsWith("/")&&(l.path=l.path.slice(1)),l.noCommittish&&(l.committish=null);const g=u(l);return l.noGitPlus&&g.startsWith("git+")?g.slice(4):g}hash(){return this.committish?`#${this.committish}`:""}ssh(u){return this.#e(this.sshtemplate,u)}sshurl(u){return this.#e(this.sshurltemplate,u)}browse(u,...d){return typeof u!="string"?this.#e(this.browsetemplate,u):typeof d[0]!="string"?this.#e(this.browsetreetemplate,{...d[0],path:u}):this.#e(this.browsetreetemplate,{...d[1],fragment:d[0],path:u})}browseFile(u,...d){return typeof d[0]!="string"?this.#e(this.browseblobtemplate,{...d[0],path:u}):this.#e(this.browseblobtemplate,{...d[1],fragment:d[0],path:u})}docs(u){return this.#e(this.docstemplate,u)}bugs(u){return this.#e(this.bugstemplate,u)}https(u){return this.#e(this.httpstemplate,u)}git(u){return this.#e(this.gittemplate,u)}shortcut(u){return this.#e(this.shortcuttemplate,u)}path(u){return this.#e(this.pathtemplate,u)}tarball(u){return this.#e(this.tarballtemplate,{...u,noCommittish:!1})}file(u,d){return this.#e(this.filetemplate,{...d,path:u})}edit(u,d){return this.#e(this.edittemplate,{...d,path:u})}getDefaultRepresentation(){return this.default}toString(u){return this.default&&typeof this[this.default]=="function"?this[this.default](u):this.sshurl(u)}}for(const[r,u]of Object.entries(i))s.addHost(r,u);return wd=s,wd}var jd,Wp;function G$(){if(Wp)return jd;Wp=1,jd=e;function e(i){if(!i||i==="ERROR: No README data found!")return;i=i.trim().split(`
6
- `);let n=0;for(;i[n]&&i[n].trim().match(/^(#|$)/);)n++;const o=i.length;let a=n+1;for(;a<o&&i[a].trim();)a++;return i.slice(n,a).join(" ").trim()}return jd}var mm={dependancies:"dependencies",dependecies:"dependencies",depdenencies:"dependencies",devEependencies:"devDependencies",depends:"dependencies","dev-dependencies":"devDependencies",devDependences:"devDependencies",devDepenencies:"devDependencies",devdependencies:"devDependencies",repostitory:"repository",repo:"repository",prefereGlobal:"preferGlobal",hompage:"homepage",hampage:"homepage",autohr:"author",autor:"author",contributers:"contributors",publicationConfig:"publishConfig",script:"scripts"},bm={web:"url",name:"url"},wm={server:"start",tests:"test"};const F$={topLevel:mm,bugs:bm,script:wm},Q$=Object.defineProperty({__proto__:null,bugs:bm,default:F$,script:wm,topLevel:mm},Symbol.toStringTag,{value:"Module"}),W$=_g(Q$);var kd,Ip;function I$(){if(Ip)return kd;Ip=1;var{URL:e}=qf,i=gY(),n=hY(),o=D$(),a=A$(),{isBuiltin:t}=Qf,s=["dependencies","devDependencies","optionalDependencies"],r=G$(),u=W$,d=y=>y.includes("@")&&y.indexOf("@")<y.lastIndexOf(".");kd={warn:function(){},fixRepositoryField:function(y){if(y.repositories&&(this.warn("repositories"),y.repository=y.repositories[0]),!y.repository)return this.warn("missingRepository");typeof y.repository=="string"&&(y.repository={type:"git",url:y.repository});var k=y.repository.url||"";if(k){var S=a.fromUrl(k);S&&(k=y.repository.url=S.getDefaultRepresentation()==="shortcut"?S.https():S.toString())}k.match(/github.com\/[^/]+\/[^/]+\.git\.git$/)&&this.warn("brokenGitUrl",k)},fixTypos:function(y){Object.keys(u.topLevel).forEach(function(k){Object.prototype.hasOwnProperty.call(y,k)&&this.warn("typo",k,u.topLevel[k])},this)},fixScriptsField:function(y){if(y.scripts){if(typeof y.scripts!="object"){this.warn("nonObjectScripts"),delete y.scripts;return}Object.keys(y.scripts).forEach(function(k){typeof y.scripts[k]!="string"?(this.warn("nonStringScript"),delete y.scripts[k]):u.script[k]&&!y.scripts[u.script[k]]&&this.warn("typo",k,u.script[k],"scripts")},this)}},fixFilesField:function(y){var k=y.files;k&&!Array.isArray(k)?(this.warn("nonArrayFiles"),delete y.files):y.files&&(y.files=y.files.filter(function(S){return!S||typeof S!="string"?(this.warn("invalidFilename",S),!1):!0},this))},fixBinField:function(y){if(y.bin&&typeof y.bin=="string"){var k={},S;(S=y.name.match(/^@[^/]+[/](.*)$/))?k[S[1]]=y.bin:k[y.name]=y.bin,y.bin=k}},fixManField:function(y){y.man&&typeof y.man=="string"&&(y.man=[y.man])},fixBundleDependenciesField:function(y){var k="bundledDependencies",S="bundleDependencies";y[k]&&!y[S]&&(y[S]=y[k],delete y[k]),y[S]&&!Array.isArray(y[S])?(this.warn("nonArrayBundleDependencies"),delete y[S]):y[S]&&(y[S]=y[S].filter(function(J){return!J||typeof J!="string"?(this.warn("nonStringBundleDependency",J),!1):(y.dependencies||(y.dependencies={}),Object.prototype.hasOwnProperty.call(y.dependencies,J)||(this.warn("nonDependencyBundleDependency",J),y.dependencies[J]="*"),!0)},this))},fixDependencies:function(y){j(y,this.warn),w(y),this.fixBundleDependenciesField(y),["dependencies","devDependencies"].forEach(function(k){if(k in y){if(!y[k]||typeof y[k]!="object"){this.warn("nonObjectDependencies",k),delete y[k];return}Object.keys(y[k]).forEach(function(S){var J=y[k][S];typeof J!="string"&&(this.warn("nonStringDependency",S,JSON.stringify(J)),delete y[k][S]);var T=a.fromUrl(y[k][S]);T&&(y[k][S]=T.toString())},this)}},this)},fixModulesField:function(y){y.modules&&(this.warn("deprecatedModules"),delete y.modules)},fixKeywordsField:function(y){typeof y.keywords=="string"&&(y.keywords=y.keywords.split(/,\s+/)),y.keywords&&!Array.isArray(y.keywords)?(delete y.keywords,this.warn("nonArrayKeywords")):y.keywords&&(y.keywords=y.keywords.filter(function(k){return typeof k!="string"||!k?(this.warn("nonStringKeyword"),!1):!0},this))},fixVersionField:function(y,k){var S=!k;if(!y.version)return y.version="",!0;if(!i(y.version,S))throw new Error('Invalid version: "'+y.version+'"');return y.version=n(y.version,S),!0},fixPeople:function(y){c(y,p),c(y,f)},fixNameField:function(y,k){typeof k=="boolean"?k={strict:k}:typeof k>"u"&&(k={});var S=k.strict;if(!y.name&&!S){y.name="";return}if(typeof y.name!="string")throw new Error("name field must be a string.");S||(y.name=y.name.trim()),h(y.name,S,k.allowLegacyCase),t(y.name)&&this.warn("conflictingName",y.name)},fixDescriptionField:function(y){y.description&&typeof y.description!="string"&&(this.warn("nonStringDescription"),delete y.description),y.readme&&!y.description&&(y.description=r(y.readme)),y.description===void 0&&delete y.description,y.description||this.warn("missingDescription")},fixReadmeField:function(y){y.readme||(this.warn("missingReadme"),y.readme="ERROR: No README data found!")},fixBugsField:function(y){if(!y.bugs&&y.repository&&y.repository.url){var k=a.fromUrl(y.repository.url);k&&k.bugs()&&(y.bugs={url:k.bugs()})}else if(y.bugs){if(typeof y.bugs=="string")d(y.bugs)?y.bugs={email:y.bugs}:e.canParse(y.bugs)?y.bugs={url:y.bugs}:this.warn("nonEmailUrlBugsString");else{C(y.bugs,this.warn);var S=y.bugs;y.bugs={},S.url&&(e.canParse(S.url)?y.bugs.url=S.url:this.warn("nonUrlBugsUrlField")),S.email&&(typeof S.email=="string"&&d(S.email)?y.bugs.email=S.email:this.warn("nonEmailBugsEmailField"))}!y.bugs.email&&!y.bugs.url&&(delete y.bugs,this.warn("emptyNormalizedBugs"))}},fixHomepageField:function(y){if(!y.homepage&&y.repository&&y.repository.url){var k=a.fromUrl(y.repository.url);k&&k.docs()&&(y.homepage=k.docs())}if(y.homepage){if(typeof y.homepage!="string")return this.warn("nonUrlHomepage"),delete y.homepage;e.canParse(y.homepage)||(y.homepage="http://"+y.homepage)}},fixLicenseField:function(y){const k=y.license||y.licence;if(!k)return this.warn("missingLicense");if(typeof k!="string"||k.length<1||k.trim()==="")return this.warn("invalidLicense");if(!o(k).validForNewPackages)return this.warn("invalidLicense")}};function l(y){if(y.charAt(0)!=="@")return!1;var k=y.slice(1).split("/");return k.length!==2?!1:k[0]&&k[1]&&k[0]===encodeURIComponent(k[0])&&k[1]===encodeURIComponent(k[1])}function g(y){return!y.match(/[/@\s+%:]/)&&y===encodeURIComponent(y)}function h(y,k,S){if(y.charAt(0)==="."||!(l(y)||g(y))||k&&!S&&y!==y.toLowerCase()||y.toLowerCase()==="node_modules"||y.toLowerCase()==="favicon.ico")throw new Error("Invalid name: "+JSON.stringify(y))}function c(y,k){return y.author&&(y.author=k(y.author)),["maintainers","contributors"].forEach(function(S){Array.isArray(y[S])&&(y[S]=y[S].map(k))}),y}function p(y){if(typeof y=="string")return y;var k=y.name||"",S=y.url||y.web,J=S?" ("+S+")":"",T=y.email||y.mail,M=T?" <"+T+">":"";return k+M+J}function f(y){if(typeof y!="string")return y;var k=y.match(/^([^(<]+)/),S=y.match(/\(([^()]+)\)/),J=y.match(/<([^<>]+)>/),T={};return k&&k[0].trim()&&(T.name=k[0].trim()),J&&(T.email=J[1]),S&&(T.url=S[1]),T}function w(y){var k=y.optionalDependencies;if(k){var S=y.dependencies||{};Object.keys(k).forEach(function(J){S[J]=k[J]}),y.dependencies=S}}function v(y,k,S){if(!y)return{};if(typeof y=="string"&&(y=y.trim().split(/[\n\r\s\t ,]+/)),!Array.isArray(y))return y;S("deprecatedArrayDependencies",k);var J={};return y.filter(function(T){return typeof T=="string"}).forEach(function(T){T=T.trim().split(/(:?[@\s><=])/);var M=T.shift(),he=T.join("");he=he.trim(),he=he.replace(/^@/,""),J[M]=he}),J}function j(y,k){s.forEach(function(S){y[S]&&(y[S]=v(y[S],S,k))})}function C(y,k){y&&Object.keys(y).forEach(function(S){u.bugs[S]&&(k("typo",S,u.bugs[S],"bugs"),y[u.bugs[S]]=y[S],delete y[S])})}return kd}var jm="'repositories' (plural) Not supported. Please pick one as the 'repository' field",km="No repository field.",Sm="Probably broken git url: %s",Lm="scripts must be an object",Cm="script values must be string commands",Ym="Invalid 'files' member",$m="Invalid filename in 'files' list: %s",Zm="Invalid 'bundleDependencies' list. Must be array of package names",Jm="Invalid bundleDependencies member: %s",xm="Non-dependency in bundleDependencies: %s",Tm="%s field must be an object",Dm="Invalid dependency: %s %s",Bm="specifying %s as array is deprecated",Xm="modules field is deprecated",Hm="keywords should be an array of strings",Mm="keywords should be an array of strings",Pm="%s is also the name of a node core module.",Nm="'description' field should be a string",Em="No description",Rm="No README data",Om="No license field.",Am="Bug string field must be url, email, or {email,url}",Gm="bugs.url field must be a string url. Deleted.",Fm="bugs.email field must be a string email. Deleted.",Qm="Normalized value of bugs field is an empty object. Deleted.",Wm="homepage field must be a string url. Deleted.",Im="license should be a valid SPDX license expression",_m="%s should probably be %s.";const _$={repositories:jm,missingRepository:km,brokenGitUrl:Sm,nonObjectScripts:Lm,nonStringScript:Cm,nonArrayFiles:Ym,invalidFilename:$m,nonArrayBundleDependencies:Zm,nonStringBundleDependency:Jm,nonDependencyBundleDependency:xm,nonObjectDependencies:Tm,nonStringDependency:Dm,deprecatedArrayDependencies:Bm,deprecatedModules:Xm,nonArrayKeywords:Hm,nonStringKeyword:Mm,conflictingName:Pm,nonStringDescription:Nm,missingDescription:Em,missingReadme:Rm,missingLicense:Om,nonEmailUrlBugsString:Am,nonUrlBugsUrlField:Gm,nonEmailBugsEmailField:Fm,emptyNormalizedBugs:Qm,nonUrlHomepage:Wm,invalidLicense:Im,typo:_m},z$=Object.defineProperty({__proto__:null,brokenGitUrl:Sm,conflictingName:Pm,default:_$,deprecatedArrayDependencies:Bm,deprecatedModules:Xm,emptyNormalizedBugs:Qm,invalidFilename:$m,invalidLicense:Im,missingDescription:Em,missingLicense:Om,missingReadme:Rm,missingRepository:km,nonArrayBundleDependencies:Zm,nonArrayFiles:Ym,nonArrayKeywords:Hm,nonDependencyBundleDependency:xm,nonEmailBugsEmailField:Fm,nonEmailUrlBugsString:Am,nonObjectDependencies:Tm,nonObjectScripts:Lm,nonStringBundleDependency:Jm,nonStringDependency:Dm,nonStringDescription:Nm,nonStringKeyword:Mm,nonStringScript:Cm,nonUrlBugsUrlField:Gm,nonUrlHomepage:Wm,repositories:jm,typo:_m},Symbol.toStringTag,{value:"Module"}),K$=_g(z$);var Sd,_p;function q$(){if(_p)return Sd;_p=1;var e=cY,i=K$;Sd=function(){var o=Array.prototype.slice.call(arguments,0),a=o.shift();if(a==="typo")return n.apply(null,o);var t=i[a]?i[a]:a+": '%s'";return o.unshift(t),e.format.apply(null,o)};function n(o,a,t){return t&&(o=t+"['"+o+"']",a=t+"['"+a+"']"),e.format(i.typo,o,a)}return Sd}var Ld,zp;function U$(){if(zp)return Ld;zp=1,Ld=t;var e=I$();t.fixer=e;var i=q$(),n=["name","version","description","repository","modules","scripts","files","bin","man","bugs","keywords","readme","homepage","license"],o=["dependencies","people","typos"],a=n.map(function(r){return s(r)+"Field"});a=a.concat(o);function t(r,u,d){u===!0&&(u=null,d=!0),d||(d=!1),(!u||r.private)&&(u=function(){}),r.scripts&&r.scripts.install==="node-gyp rebuild"&&!r.scripts.preinstall&&(r.gypfile=!0),e.warn=function(){u(i.apply(null,arguments))},a.forEach(function(l){e["fix"+s(l)](r,d)}),r._id=r.name+"@"+r.version}function s(r){return r.charAt(0).toUpperCase()+r.slice(1)}return Ld}U$();const V$=wn(import.meta.url),jt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,Kg=e=>{if(typeof jt<"u"&&jt.versions&&jt.versions.node){const[i,n]=jt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return jt.getBuiltinModule(e)}return V$(e)};Kg("node:fs");Kg("node:readline");Kg("node:util");const eZ={argument:{description:"Target selector (same syntax as `vis run`): `build`, `:build`, `~:test`, `#tag:lint`, …",name:"selector",type:String},description:"Show the execution plan for a target without running it",examples:[["vis action-graph build","Print the task plan for `build` on every project"],["vis action-graph :test","Moon-style selector"],["vis action-graph build --json","Emit a JSON description of the plan"],['vis action-graph lint --query "tag=frontend"',"Filter projects by query"]],group:"Workspace",loader:()=>import("./handler2.js"),name:"action-graph",options:[{defaultValue:!1,description:"Emit JSON instead of ASCII",name:"json",type:Boolean},{description:"Filter matched projects by a query",name:"query",type:String}]},iZ={argument:{description:"Packages to add (e.g., react react-dom)",name:"packages",type:String},description:"Add packages using the detected package manager",examples:[["vis add react react-dom","Add packages"],["vis add -D typescript @types/react","Add as dev dependencies"],["vis add react --filter app","Add to specific workspace package"],["vis add react --to web","Add to one package, auto-conforming the version to existing catalogs / sibling deps"],["vis add -g typescript","Add globally (uses npm)"],["vis add lodash -w","Add to workspace root"],["vis add lodash --no-socket-check","Add without Socket.dev check"],["vis add lodash --no-typosquat-check","Skip typosquat name check"],["vis add lodash --no-marshall-check","Skip the offline marshall pipeline (author, downloads, etc.)"],["vis add lodash --run-scripts","Run lifecycle scripts (opts out of vis's default block-by-default policy)"]],group:"Dependencies",loader:()=>import("./handler15.js"),name:"add",options:[{alias:"D",defaultValue:!1,description:"Add as dev dependency",name:"save-dev",type:Boolean},{alias:"E",defaultValue:!1,description:"Save exact version",name:"exact",type:Boolean},{alias:"P",defaultValue:!1,description:"Add as peer dependency",name:"save-peer",type:Boolean},{alias:"O",defaultValue:!1,description:"Add as optional dependency",name:"save-optional",type:Boolean},{alias:"g",defaultValue:!1,description:"Install globally (uses npm)",name:"global",type:Boolean},{alias:"w",defaultValue:!1,description:"Add to workspace root",name:"workspace-root",type:Boolean},{defaultValue:!1,description:"Use workspace protocol (pnpm)",name:"workspace",type:Boolean},{alias:"F",description:"Filter by workspace package name",multiple:!0,name:"filter",type:String},{description:"Target a single workspace package and auto-conform the version to existing catalogs / sibling deps (syncpack#285)",name:"to",type:String},{defaultValue:!1,description:"Skip typosquat name check before adding",name:"no-typosquat-check",type:Boolean},{defaultValue:!1,description:"Skip Socket.dev security check before adding",name:"no-socket-check",type:Boolean},{defaultValue:!1,description:"Skip the offline marshall pipeline (author, provenance, metadata, downloads, expired-domains, new-bin, signatures, archived-repo)",name:"no-marshall-check",type:Boolean},{defaultValue:!1,description:"Run lifecycle scripts during add (opts out of vis's default block-by-default policy; allowlisted packages run via security.policies.installScripts.allow)",name:"run-scripts",type:Boolean},{defaultValue:!1,description:"After adding, recursively install non-optional peer dependencies that aren't already in the workspace (matches nypm's installPeerDependencies)",name:"auto-install-peers",type:Boolean}]},qg={description:"Override the cache DB path (defaults to <cache>/vis/advisories/db.sqlite via @visulima/find-cache-dir).",name:"db",type:String},ks={description:"Output format: table (default) or json.",name:"format",type:String},nZ={commandPath:["advisories"],description:"Download and ingest one or more OSV ecosystem dumps into the local cache",examples:[["vis advisories sync","Sync the npm ecosystem (default)"],["vis advisories sync --ecosystem npm","Sync a single explicit ecosystem"],["vis advisories sync --ecosystem npm,PyPI","Sync several ecosystems in one pass"],["vis advisories sync --force","Re-download even when the ETag matches"],["vis advisories sync --source https://mirror.example.com","Use a corporate OSV mirror (must be in allowedHosts)"]],group:"Security & Health",loader:le(()=>import("./sync.js"),"advisoriesSyncExecute"),name:"sync",options:[{description:"Comma-separated list of ecosystems to sync (default: npm).",name:"ecosystem",type:String},{defaultValue:!1,description:"Re-download and re-ingest even if the upstream ETag is unchanged.",name:"force",type:Boolean},{description:"Override the advisory source URL. Must be https and resolve to an allowed host.",name:"source",type:String},qg,ks]},oZ={commandPath:["advisories"],description:"Print the local advisory DB summary: path, schema version, ecosystems, row counts, last sync, ETag",examples:[["vis advisories status","Human-readable summary"],["vis advisories status --format json","Machine-readable for CI freshness checks"]],group:"Security & Health",loader:le(()=>import("./status.js"),"advisoriesStatusExecute"),name:"status",options:[qg,ks]},aZ={commandPath:["advisories"],description:"Delete the local advisory DB. The next `vis audit --offline` will fail until you re-sync",examples:[["vis advisories prune","Confirm and delete the local DB"],["vis advisories prune --force","Delete without confirmation"]],group:"Security & Health",loader:le(()=>import("./prune.js"),"advisoriesPruneExecute"),name:"prune",options:[qg,{defaultValue:!1,description:"Skip the confirmation prompt.",name:"force",type:Boolean},ks]},zm={description:"Override the bloom cache directory (defaults to <cache>/vis/osv-bloom/).",name:"cache-dir",type:String},tZ={commandPath:["advisories","bloom"],description:"Fetch and verify the endevco/osv-bloom MAL-* prefilter into the local cache",examples:[["vis advisories bloom sync","Fetch the bloom filter from the default upstream"],["vis advisories bloom sync --force","Re-download even when the set digest matches"],["vis advisories bloom sync --source https://bloom.example.com","Use an internal mirror (must be in allowedHosts)"]],group:"Security & Health",loader:le(()=>import("./bloom-sync.js"),"advisoriesBloomSyncExecute"),name:"sync",options:[{defaultValue:!1,description:"Re-download and re-verify even when the upstream set digest is unchanged.",name:"force",type:Boolean},{description:"Override the bloom source URL. Must be https and resolve to an allowed host.",name:"source",type:String},zm,ks]},sZ={commandPath:["advisories","bloom"],description:"Print the local osv-bloom cache freshness: built-at, filter size, m/k parameters, set digest",examples:[["vis advisories bloom status","Human-readable summary"],["vis advisories bloom status --format json","Machine-readable for CI freshness checks"]],group:"Security & Health",loader:le(()=>import("./bloom-status.js"),"advisoriesBloomStatusExecute"),name:"status",options:[zm,ks]},rZ=[nZ,oZ,aZ,tZ,sZ],uZ={argument:{description:"The target to run (e.g., build, test, lint)",name:"target",type:String},description:"Run a target only on projects affected by recent changes",examples:[["vis affected build","Run build on affected projects"],["vis affected test --base=main","Run tests on projects changed since main"],["vis affected destroy --reverse","Tear down affected projects leaves-first"],["vis affected build --sparse-checkout","Print a git sparse-checkout cone set for the affected projects and exit"]],group:"Run & Execute",loader:()=>import("./handler3.js"),name:"affected",options:[{description:"Git base ref for comparison. When omitted, vis auto-resolves it from the active CI provider (GitHub/GitLab/Buildkite/CircleCI) or falls back to `git merge-base HEAD origin/<defaultBase>` locally. Default base branch comes from `vis.config.ts#defaultBase` (or `main`).",name:"base",type:String},{description:"Git head ref for comparison. When omitted, auto-resolves from CI env (e.g. `$GITHUB_SHA`) or defaults to `HEAD`.",name:"head",type:String},{defaultValue:"deep",description:'Downstream scope: "none", "direct", or "deep" — controls how far to include dependents of changed projects',name:"downstream",type:String},{defaultValue:"none",description:'Upstream scope: "none", "direct", or "deep" — controls how far to include dependencies of changed projects',name:"upstream",type:String},{defaultValue:3,description:"Maximum number of parallel tasks",name:"parallel",type:Number},{defaultValue:!0,description:"Enable caching (use --no-cache to disable)",name:"cache",type:Boolean},{defaultValue:!1,description:"Show what would run without executing",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Instead of running, print the affected project roots as a git sparse-checkout cone set (one path per line) and exit. Pipe into `git sparse-checkout set --stdin` to shrink huge-monorepo CI checkouts.",name:"sparse-checkout",type:Boolean},{description:'Partition tasks for distributed CI (e.g., "1/4" for first of four runners). Falls back to VIS_PARTITION env var.',name:"partition",type:String},{description:"Filter affected projects by a query (e.g. 'language=typescript && tag=lib')",name:"query",type:String},{defaultValue:!1,description:"Run the dependency graph in reverse (leaves first, then their dependents). Useful for teardown targets like `destroy`/`undeploy` where dependents must run before the things they depend on.",name:"reverse",type:Boolean},{description:"Comma-separated tags this runner advertises (e.g. 'gpu,slow'). Forwarded verbatim to the downstream `vis run` so capability-gated tasks resolve identically. Falls back to VIS_RUNNER_TAGS env var.",name:"runner-tags",type:String}]},Km={description:"Output format: table or json (default: table)",name:"format",type:String},dZ={commandPath:["ai"],description:"List detected AI providers and show which one is selected",examples:[["vis ai providers","List all AI providers and their status"],["vis ai providers --format json","Output as JSON"]],group:"System",loader:le(()=>import("./handler50.js"),"aiProvidersExecute"),name:"providers",options:[Km]},lZ={commandPath:["ai"],description:"Test the best available AI provider with a quick prompt",examples:[["vis ai test","Test the selected provider"]],group:"System",loader:le(()=>import("./handler50.js"),"aiTestExecute"),name:"test",options:[]},gZ={argument:{description:"Task ID to propose a fix for (e.g. @my/app:build)",name:"taskId",type:String},commandPath:["ai"],description:"Read a failed task's logs and propose a structured patch (Phase 1: local-only, no git)",examples:[["vis ai fix @myorg/app:build","Print proposed patch for the failed task"],["vis ai fix @myorg/app:build --apply","Apply the patch to disk after confirming"],["vis ai fix @myorg/app:build --format json","Machine-readable patch output"],["vis ai fix @myorg/app:build --run 2026-04-28T...","Inspect a specific historical run"]],group:"System",loader:le(()=>import("./handler50.js"),"aiFixExecute"),name:"fix",options:[Km,{description:"Use a specific run ID from .vis/runs/ instead of the latest run",name:"run",type:String},{defaultValue:!1,description:"Apply the proposed patch to disk after printing it",name:"apply",type:Boolean},{defaultValue:!1,description:"Bypass the AI response cache",name:"no-cache",type:Boolean},{defaultValue:!1,description:"Skip the confirmation prompt before applying",name:"yes",type:Boolean}]},hZ={description:"AI-assisted commands: provider detection and failure-fix proposals (cache management lives under `vis cache`)",examples:[["vis ai","List all AI subcommands"],["vis ai discover-help","Machine-readable subcommand catalogue (for AI agents)"]],group:"System",loader:le(()=>import("./handler50.js"),"aiRootExecute"),name:"ai",options:[]},cZ={commandPath:["ai"],description:"Print the machine-readable AI subcommand catalogue (JSON to stdout, designed for AI agents)",examples:[["vis ai discover-help","Emit the discovery payload as JSON"],["vis ai discover-help | jq '.subcommands[].path'","List all available paths"]],group:"System",loader:le(()=>import("./handler50.js"),"aiDiscoverHelpExecute"),name:"discover-help",options:[]},pZ={commandPath:["ai"],description:"Diagnose the most recent failed task and post a structured patch as a PR/MR comment (or Buildkite annotation)",examples:[["vis ai heal","Heal the most recent failure"],["vis ai heal --dry-run","Propose a patch but skip apply / validate / post"],["vis ai heal --run 2026-04-28T...","Heal a specific historical run"]],group:"System",loader:le(()=>import("./heal.js").then(e=>e.h),"aiHeal"),name:"heal",options:[{defaultValue:!1,description:"Show the proposal and exit without applying or posting it",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Bypass the AI response cache",name:"no-cache",type:Boolean},{description:"Use a specific run ID from .vis/runs/ instead of the latest run",name:"run",type:String},{description:"Per-task validation timeout in seconds (default: 1800)",name:"validation-timeout",type:Number}]},vZ={commandPath:["ai","heal"],description:"Re-run the proposed fix and commit it to the PR/MR branch when validation passes",examples:[["vis ai heal accept","Triggered automatically by a `/vis heal accept` PR comment (GitHub/GitLab) or a Buildkite block-step unblock"]],group:"System",loader:le(()=>import("./heal-accept.js"),"aiHealAccept"),name:"accept",options:[{description:"Use a specific run ID from .vis/runs/ instead of the latest run",name:"run",type:String},{description:"Per-task validation timeout in seconds (default: 1800)",name:"validation-timeout",type:Number}]},qm=[hZ,cZ,dZ,lZ,gZ,pZ,vZ],x1e=Object.defineProperty({__proto__:null,default:qm},Symbol.toStringTag,{value:"Module"}),yZ={argument:{description:"Package name to analyze (e.g., react)",name:"package",required:!0,type:String},description:"Analyze a single package update with AI",examples:[["vis analyze react","Analyze updating react to latest"],["vis analyze react 19.0.0","Analyze updating react to specific version"],["vis analyze react --ai-type security","Run security-focused analysis"],["vis analyze react --format json","Output as JSON"]],group:"System",loader:()=>import("./handler4.js"),name:"analyze",options:[{description:"AI analysis type: impact, security, compatibility, or recommend (default: impact)",name:"ai-type",type:String},{defaultValue:!1,description:"Check for known security vulnerabilities",name:"security",type:Boolean},{description:"Output format: table or json (default: table)",name:"format",type:String}]},fZ={description:"Review and approve dependencies with build scripts",examples:[["vis approve-builds","Scan and list unapproved build scripts"],["vis approve-builds --all","Approve all pending builds (pnpm)"],["vis approve-builds --write","Write unapproved entries into vis.config.ts security.policies.installScripts.allow"],["vis approve-builds --sync-native","Sync allowBuilds to native PM config"]],group:"Security & Health",loader:()=>import("./handler51.js"),name:"approve-builds",options:[{defaultValue:!1,description:"Approve all pending builds without prompting (pnpm only)",name:"all",type:Boolean},{defaultValue:!1,description:"Force vis scanning even for pnpm (instead of delegating)",name:"scan",type:Boolean},{defaultValue:!1,description:"Sync allowBuilds to native PM config (bun: trustedDependencies, npm: .npmrc, yarn: .yarnrc.yml)",name:"sync-native",type:Boolean},{defaultValue:!1,description:"Write unapproved entries directly into vis.config.ts security.policies.installScripts.allow (LavaMoat 'auto' parity)",name:"write",type:Boolean}]},Um={description:"Output format: table, json, or ndjson (default: table). json/ndjson go to stdout, logs to stderr.",name:"format",type:String},mZ={commandPath:["attest"],description:"Verify inbound provenance + registry signatures across the locked dependency graph and gate on regressions",examples:[["vis attest verify","Check every locked dep for provenance regressions and signature problems"],["vis attest verify --prod-only","Skip devDependencies"],["vis attest verify --format json","Machine-readable findings for CI (Axis A)"],["vis attest verify --fail-on error","Exit non-zero only on error-severity findings (default: any finding)"]],group:"Security & Health",loader:le(()=>import("./handler5.js"),"attestVerifyExecute"),name:"verify",options:[Um,{defaultValue:!1,description:"Skip devDependencies — verify the production graph only.",name:"prod-only",type:Boolean},{description:"Severity that triggers a non-zero exit: 'warning' (any finding, default) or 'error'.",name:"fail-on",type:String},{description:"Comma-separated package names to exclude from both marshalls.",name:"allowlist",type:String}]},bZ={argument:{description:"Path to the built artifact to attest (e.g. dist/app.tgz). Its sha256 becomes the in-toto subject digest.",name:"subject",type:String},description:"Build an in-toto SLSA v1 provenance statement for an artifact and keyless-sign it via Sigstore",examples:[["vis attest dist/app.tgz","Emit dist/app.tgz.sigstore (keyless-signed in CI)"],["vis attest dist/app.tgz --output attest.sigstore","Write the bundle to a specific path"],["vis attest dist/app.tgz --predicate slsaProvenance","Predicate type (default: slsaProvenance)"],["vis attest dist/app.tgz --require-signing","Fail instead of skip-with-warn when no ambient OIDC (outside CI)"],["vis attest dist/app.tgz --format json","Print the signed bundle summary as JSON (Axis A)"]],group:"Security & Health",loader:le(()=>import("./handler5.js"),"attestEmitExecute"),name:"attest",options:[Um,{description:"Write the serialized Sigstore bundle here (default: <subject>.sigstore).",name:"output",type:String},{description:"Predicate type: 'slsaProvenance' (default, https://slsa.dev/provenance/v1).",name:"predicate",type:String},{defaultValue:!1,description:"Error instead of skip-with-warn when no ambient OIDC token is available (i.e. outside CI).",name:"require-signing",type:Boolean}]},wZ=[bZ,mZ],jZ={description:"Audit installed packages for vulnerabilities and supply chain risks",examples:[["vis audit","Full audit of all installed packages"],["vis audit --severity high","Show only high/critical issues"],["vis audit --format json","Output as JSON for CI integration"],["vis audit --format sarif","Output SARIF 2.1.0 for code-scanning uploads"],["vis audit --format csaf","Output CSAF 2.0 csaf_vex for enterprise vuln pipelines"],["vis audit --format cyclonedx-vex","Output a CycloneDX 1.7 BOM with vulnerabilities[] (SBOM + VEX)"],["vis audit --format gitlab","Output a GitLab dependency-scanning report (gl-dependency-scanning.json)"],["vis audit --format junit","Output a Surefire-compatible JUnit XML report"],["vis audit --report report.html","Write a self-contained HTML report to ./report.html"],["vis audit --usage","Only report vulnerabilities in statically-imported packages"],["vis audit --offline","Query the local OSV cache only (no network)"],["vis audit --offline --db ./vendor.sqlite","Use a specific advisory DB"],["vis audit --ecosystem npm,pypi","Scan multiple OSV ecosystems (npm, pypi, crates.io, maven, go, rubygems)"],["vis audit --prod-only","Skip devDependencies"],["vis audit --fail-on high","Exit non-zero on any high or critical finding"],["vis audit --show-fixes","Print fix-suggestion lines (no apply, no rescan)"],["vis audit --fix","Apply direct-dep upgrades for vulnerable packages, then rescan (dry-run preview by default)"],["vis audit --fix --yes","Skip the confirmation prompt and run the upgrades immediately"],["vis audit --fix --allow-major","Permit major-version bumps when the lowest fix is outside the existing range"],["vis audit --fix-transitive","Write PM-specific overrides for vulnerable transitives (dry-run preview by default)"],["vis audit --exit-code","Exit with code 1 if issues found (for CI)"],["vis audit --show-accepted","Include acknowledged risks in output"],["vis audit --sync","Sync accepted risks to native PM config (pnpm-workspace.yaml / .yarnrc.yml)"],["vis audit --policies license,vulnerability","Run only the named policies (default: every configured policy)"],["vis audit --policies none","Skip the policy engine entirely"],["vis audit --explain","Add a plain-English AI explanation under every finding (auto-detects an installed AI CLI)"],["vis audit --explain CVE-2021-23337","Explain only the finding with this CVE/GHSA id"],["vis audit --explain 2","Explain only the 2nd finding"]],group:"Security & Health",loader:()=>import("./handler71.js"),name:"audit",options:[{description:"Minimum severity to report: low, medium, high, critical (default: low)",name:"severity",type:String},{description:"Output format: table, json, sarif, csaf, cyclonedx-vex, gitlab, or junit (default: table)",name:"format",type:String},{description:"Write a self-contained HTML report to this path. Auto-opens in a TTY when not in CI.",name:"report",type:String},{defaultValue:!1,description:"Only report vulnerabilities in statically-imported packages (reachability filter).",name:"usage",type:Boolean},{defaultValue:!1,description:"Disable the reachability filter even if enabled in config.",name:"no-usage",type:Boolean},{defaultValue:!1,description:"Query the local OSV advisory cache only — no network calls. Errors if the cache is missing.",name:"offline",type:Boolean},{description:"Override the offline advisory DB path (default: <cache>/vis/advisories/db.sqlite).",name:"db",type:String},{description:"Comma-separated list of OSV ecosystems to scan (default: npm). Supported: npm, pypi, crates.io (or 'cargo'), maven, go, rubygems. Non-npm ecosystems require --offline (online OSV path is npm-only).",name:"ecosystem",type:String},{defaultValue:!1,description:"Skip devDependencies — scan production graph only.",name:"prod-only",type:Boolean},{description:"Exit non-zero when any finding is at this severity or higher. One of: low, medium, high, critical.",name:"fail-on",type:String},{defaultValue:!1,description:"Print fix-suggestion lines for each finding (no apply, no rescan)",name:"show-fixes",type:Boolean},{defaultValue:!1,description:"Apply direct-dep fixes for vulnerable packages by running the active PM update command, then rescan",name:"fix",type:Boolean},{defaultValue:!1,description:"Apply transitive fixes by writing PM-specific overrides (pnpm-workspace.yaml / package.json overrides / resolutions)",name:"fix-transitive",type:Boolean},{defaultValue:!1,description:"Skip confirmation prompt for --fix / --fix-transitive (required in CI)",name:"yes",type:Boolean},{defaultValue:!1,description:"Allow --fix to bump a direct dep across a major version when the lowest fix is outside the existing range",name:"allow-major",type:Boolean},{defaultValue:!1,description:"Exit with code 1 if any issues found (for CI)",name:"exit-code",type:Boolean},{defaultValue:!1,description:"Include acknowledged (accepted risk) issues in output",name:"show-accepted",type:Boolean},{defaultValue:!1,description:"Sync vis accepted risks to native PM config (pnpm-workspace.yaml / .yarnrc.yml)",name:"sync",type:Boolean},{description:"Comma-separated list of supply-chain policies to evaluate (default: every configured policy). Use 'none' to skip the engine entirely, 'all' to force the full set. Known: malware, firstSeen, unexpectedDeps, publisherChange, installScripts, score, vulnerability, license.",name:"policies",type:String},{description:"Audit backend: 'auto' (default, delegates to 'aube audit' when aube is the installer), 'aube' (force delegate), or 'vis' (always use vis's OSV/Socket scanner).",name:"backend",type:String},{description:"Add a plain-English AI explanation to findings. Bare flag explains all findings at/above --severity; pass a finding index (e.g. 2) or a CVE/GHSA id to explain just one. Auto-detects an installed AI CLI; mutually exclusive with --offline.",name:"explain",type:String}]},Ss={description:"Cache directory (overrides config and default). Relative paths are resolved against the workspace root.",name:"cache-dir",type:String},zr={description:"Cache scope: 'shared' (default — main worktree's cache), 'worktree' (this checkout's local cache), or 'all' (both)",name:"scope",type:String},Vm={description:"Cache type: 'task' (workspace task cache), 'ai' (AI response cache), 'socket' (Socket.dev reports), 'deps-dev' (Google deps.dev reports), or 'all' (default)",name:"type",type:String},kZ={commandPath:["cache"],description:"List all cache entries",examples:[["vis cache list","List all cache entries"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheListExecute"),name:"list",options:[Ss,zr,{description:"Output format: table or json (default: table)",name:"format",type:String}]},SZ={commandPath:["cache"],description:"Remove cache entries (defaults to all stores: workspace task cache, AI responses, Socket.dev reports)",examples:[["vis cache clean","Remove all cache entries from every store"],["vis cache clean --type=ai","Clear only the AI response cache"],["vis cache clean --type=task","Clear only the workspace task cache"],["vis cache clean --dry-run","Preview what clean would remove"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheCleanExecute"),name:"clean",options:[Ss,Vm,{defaultValue:!1,description:"Preview without deleting",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Skip the confirmation prompt for out-of-workspace cache directories",name:"force",type:Boolean}]},LZ={commandPath:["cache"],description:"Remove old and oversized cache entries",examples:[["vis cache prune","Remove old and oversized entries"],["vis cache prune --max-age-days=3 --max-size=500MB","Prune with custom limits"],["vis cache prune --keep-last=30","Keep only the 30 most recent entries"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cachePruneExecute"),name:"prune",options:[Ss,zr,{description:"Remove entries older than N days",name:"max-age-days",type:Number},{description:"Evict oldest entries until cache is under this size (e.g. 500MB)",name:"max-size",type:String},{description:"Keep only the N most recent entries (sorted newest-first by mtime)",name:"keep-last",type:Number}]},CZ={commandPath:["cache"],description:"Print on-disk footprint and stats for one or more cache stores (task / ai / socket)",examples:[["vis cache size","Show stats for every cache store"],["vis cache size --type=ai","Show only the AI response cache (entries, size, oldest, newest)"],["vis cache size --type=task --format=json","Machine-readable task cache size"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheSizeExecute"),name:"size",options:[Ss,zr,Vm,{description:"Output format: table or json (default: table)",name:"format",type:String}]},Ug={description:"Output format: table or json (default: table)",name:"format",type:String},eb={description:"Use a specific run ID from .vis/runs/ instead of the latest run",name:"run",type:String},YZ={argument:{description:"Task ID to explain (e.g. @my/app:build)",name:"taskId",type:String},commandPath:["cache"],description:"Explain why a task missed the cache by diffing hash inputs against the previous run",examples:[["vis cache why @myorg/app:build","Show which inputs changed since the last run"],["vis cache why @myorg/app:build --json","Machine-readable output for CI"],["vis cache why @myorg/app:build --run 2026-04-28T...","Inspect a specific historical run"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheWhyExecute"),name:"why",options:[Ug,eb]},$Z={argument:{description:"Task ID to print the hash for (e.g. @my/app:build)",name:"taskId",type:String},commandPath:["cache"],description:"Print the recorded hash and per-input hash details for a task",examples:[["vis cache hash @myorg/app:build","Show the resolved hash + contributing inputs"],["vis cache hash @myorg/app:build --json","Machine-readable output"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheHashExecute"),name:"hash",options:[Ug,eb]},ZZ={argument:{description:"Task ID to verify (e.g. @my/app:build)",name:"taskId",type:String},commandPath:["cache"],description:"Verify cache restore fidelity: extract the cached entry into a tmp directory and diff each file's content, mode, and mtime against the live workspace. Exits 1 on any drift (changed content, mode, mtime) or if a cached output is missing from the workspace. With --scope=all, the first cache directory containing the task is used.",examples:[["vis cache verify @myorg/app:build","Diff cached outputs vs live workspace files"],["vis cache verify @myorg/app:build --format=json","Machine-readable diff (status: ok | drift)"],["vis cache verify @myorg/app:build --cache-dir=.alt-cache","Verify against a non-default cache directory"],["vis cache verify @myorg/app:build --scope=all","Search shared and worktree caches for the task"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheVerifyExecute"),name:"verify",options:[Ss,zr,Ug]},JZ={commandPath:["cache"],description:"Probe the configured remote cache (HTTP HEAD or REAPI Capabilities) and report reachability, latency, and negotiated capabilities",examples:[["vis cache doctor","Probe the remoteCache configured in vis.config.ts"],["vis cache doctor --url=grpcs://cache.example.com:443 --backend=reapi","Override URL/backend ad-hoc"],["vis cache doctor --json","Machine-readable output"]],group:"Workspace",loader:le(()=>import("./doctor-probe.js"),"cacheDoctorExecute"),name:"doctor",options:[{description:"Override remote cache URL (otherwise read from vis.config.ts remoteCache.url, or TURBO_API env var)",name:"url",type:String},{description:"Override backend selector: 'http' or 'reapi'",name:"backend",type:String},{description:"Output format: table or json (default: table)",name:"format",type:String},{defaultValue:5e3,description:"Probe timeout in milliseconds (default: 5000)",name:"timeout",type:Number}]},xZ=[kZ,SZ,LZ,CZ,YZ,$Z,ZZ,JZ],TZ={alias:["c","outdated"],argument:{description:"Specific packages to check (checks all if omitted)",name:"packages",type:String},description:"Check for outdated dependencies, security vulnerabilities, and supply chain settings",examples:[["vis check","Check all catalog dependencies"],["vis check react","Check specific packages"],["vis check --target minor","Only show minor/patch updates"],["vis check --exclude '@types/*'","Exclude packages by pattern"],["vis check --no-security","Skip vulnerability scanning"],["vis check --security-config","Audit supply chain security settings"],["vis check --security-config --sync","Sync security config to pnpm-workspace.yaml"]],group:"Security & Health",loader:()=>import("./handler6.js"),name:"check",options:[{alias:"t",description:"Update target: latest, minor, or patch (default: latest)",name:"target",type:String},{description:"Glob pattern to include packages (repeatable)",lazyMultiple:!0,name:"include",type:String},{description:"Glob pattern to exclude packages (repeatable)",lazyMultiple:!0,name:"exclude",type:String},{defaultValue:!1,description:"Include prerelease versions",name:"prerelease",type:Boolean},{defaultValue:!1,description:"Skip security vulnerability scanning",name:"no-security",type:Boolean},{defaultValue:!1,description:"Audit supply chain security settings",name:"security-config",type:Boolean},{defaultValue:!1,description:"Sync security settings to pnpm-workspace.yaml (pnpm only, requires --security-config)",name:"sync",type:Boolean},{description:"Output format: table, json, or minimal (default: table)",name:"format",type:String},{defaultValue:!1,description:"Exit with code 1 if outdated dependencies found (for CI)",name:"exit-code",type:Boolean},{defaultValue:!1,description:"Run AI analysis on outdated packages",name:"ai",type:Boolean},{description:"AI analysis type: impact, security, compatibility, or recommend",name:"ai-type",type:String},{alias:"D",conflicts:"prod",description:"Check only devDependencies (npm/yarn mode)",name:"dev",type:Boolean},{alias:"P",conflicts:"dev",description:"Check only dependencies (npm/yarn mode)",name:"prod",type:Boolean},{defaultValue:!1,description:"Include peerDependencies in outdated checks",name:"peer",type:Boolean},{defaultValue:!1,description:"Also check workspace-owned package names against the registry",name:"include-internal",type:Boolean}]},DZ={argument:{description:"Comma-separated list of targets to run (e.g., lint,test,build)",name:"targets",type:String},description:"Run affected targets in a CI-optimized pipeline",examples:[["vis ci lint,test,build","Run lint, test, and build on affected projects"],["vis ci test --base=origin/main","Override the base ref"],["vis ci build --no-install","Skip the install step (assume deps already present)"],["vis ci build --parallel=6","Increase concurrency"]],group:"Run & Execute",loader:()=>import("./handler7.js"),name:"ci",options:[{defaultValue:!0,description:"Install dependencies before running targets (use --no-install to skip)",name:"install",type:Boolean},{defaultValue:!1,description:"Skip the toolchain pre-flight (no auto-install for any pinned tool: node / pnpm / yarn / npm / bun / deno / go / python / ruby / rust)",name:"skip-toolchain",type:Boolean},{description:"Git base ref for affected detection (default: auto-detected from CI env)",name:"base",type:String},{description:"Git head ref for affected detection (default: HEAD)",name:"head",type:String},{defaultValue:"none",description:"Upstream scope: none | direct | deep",name:"upstream",type:String},{defaultValue:"deep",description:"Downstream scope: none | direct | deep",name:"downstream",type:String},{defaultValue:4,description:"Maximum number of parallel tasks per target",name:"parallel",type:Number},{description:'Partition tasks for distributed CI (e.g., "1/4")',name:"partition",type:String},{description:"Filter affected projects by a query (e.g. 'language=typescript && tag=lib')",name:"query",type:String}]},BZ={argument:{description:"Project name to check (required)",name:"project",type:String},commandPath:["ci"],description:'Exit with inverted codes for CI "Ignored Build Step" gating (Vercel/Netlify)',examples:[["vis ci ignore my-app","Check if my-app is affected and decide whether to build"],["vis ci ignore my-app --base $VERCEL_GIT_PREVIOUS_SHA","Explicit base ref"],["vis ci ignore my-app --json","Emit the decision as JSON instead of text"],["vis ci ignore my-app --verbose","Print debug info about the decision path"],["vis ci ignore my-app --exit-zero-on-build","Normal exit semantics (0=build, 0=skip)"]],group:"Run & Execute",loader:()=>import("./handler52.js"),name:"ignore",options:[{description:"Git base ref for comparison. Defaults to CI provider env vars, then HEAD~1.",name:"base",type:String},{defaultValue:"HEAD",description:"Git head ref for comparison",name:"head",type:String},{defaultValue:"deep",description:'Downstream scope: "none", "direct", or "deep"',name:"downstream",type:String},{defaultValue:"none",description:'Upstream scope: "none", "direct", or "deep"',name:"upstream",type:String},{defaultValue:!1,description:"Emit the decision as JSON on stdout instead of human text",name:"json",type:Boolean},{defaultValue:!1,description:"Exit 0 on build (normal semantics) instead of 1 (inverted Vercel/Netlify semantics)",name:"exit-zero-on-build",type:Boolean},{defaultValue:!1,description:"Enable verbose debug output",name:"verbose",type:Boolean}]},XZ={description:"Remove node_modules from all workspace projects",examples:[["vis clean","Remove all node_modules directories"],["vis clean --lockfile","Also remove lockfiles"],["vis clean --empty-packages","Also remove workspace directories that have no package.json"],["vis clean --dry-run","Preview what would be removed"]],group:"Workspace",loader:()=>import("./handler8.js"),name:"clean",options:[{alias:"l",defaultValue:!1,description:"Also remove lockfiles (pnpm-lock.yaml, package-lock.json, etc.)",name:"lockfile",type:Boolean},{alias:"e",defaultValue:!1,description:"Also remove stale workspace directories that match a workspace pattern but have no package.json",name:"empty-packages",type:Boolean},{defaultValue:!1,description:"Preview what would be removed without deleting",name:"dry-run",type:Boolean}]},HZ={argument:{description:"Template to use (e.g., vis:app, create-vite, user/repo) — omit for interactive mode",name:"template",type:String},description:"Create a new project from a template",examples:[["vis create","Interactive project scaffolding"],["vis create vis:monorepo my-workspace","Create a monorepo workspace"],["vis create vis:app my-app","Scaffold a Vite application"],["vis create vis:library my-lib","Create a TypeScript library"],["vis create vite my-app -- --template react-ts","Use create-vite with React TypeScript"],["vis create user/repo my-project","Clone a GitHub template"],["vis create --list","Show available templates"]],group:"Scaffold & Config",loader:()=>import("./handler68.js"),name:"create",options:[{defaultValue:!1,description:"Show available templates",name:"list",type:Boolean},{description:"Generate editor configs (vscode)",name:"editor",type:String},{defaultValue:!1,description:"Initialize a git repository",name:"git-init",type:Boolean},{defaultValue:!1,description:"Skip interactive prompts",name:"no-interactive",type:Boolean}]},ib=(e,i,n)=>{const o=t=>Ff(t)?t:Ha(e,t);if(i&&i.length>0)return o(i);if(n&&n.length>0)return o(n);const a=process.env.VIS_CACHE_DIRECTORY;return a&&a.length>0?o(a):Ha(e,em)},MZ=(e,i)=>i===!1?e:pY(e)??e,Kp=(e,i,n,o)=>{const a=i??n??process.env.VIS_CACHE_DIRECTORY;if(a&&a.length>0)return ib(e,i,n);const t=MZ(e,o);return Ha(t,em)},PZ=/[^\w.-]+/g,NZ=/^-+|-+$/g,EZ=e=>e.trim().replaceAll(PZ,"-").replaceAll(NZ,"").slice(0,64),RZ=e=>{try{const i=rY("git",["rev-parse","--abbrev-ref","HEAD"],{cwd:e,encoding:"utf8",stdio:["ignore","pipe","ignore"]}).trim();return!i||i==="HEAD"?void 0:i}catch{return}},T1e=(e,i,n)=>{if(n!==!0)return e;const o=RZ(i);if(!o)return e;const a=EZ(o);return a.length===0?e:Ha(e,"branches",a)},OZ=(e,i)=>{const n=ws(i,e);return n.length===0?!1:n!==".."&&!n.startsWith("../")&&!Ff(n)},AZ="x-hono-already-sent";var vn=class extends Error{constructor(i,n){super(i,n),this.name="RequestError"}};const GZ=/^\/[!#$&-;=?-\[\]_a-z~]*$/,FZ=/\/\.\.?(?:[/?#]|$)/,QZ=/^[a-z0-9._-]+(?::(?:[1-5]\d{3,4}|[6-9]\d{3}))?$/,WZ=(e,i,n)=>{const o=`${e}://${i}${n}`;if(QZ.test(i)){if(n.length===0)return o+"/";if(n.charCodeAt(0)!==47)throw new vn("Invalid URL");return!GZ.test(n)||FZ.test(n)?new URL(o).href:o}else{const a=new URL(o);if(a.hostname.length!==i.length&&a.hostname!==(i.includes(":")?i.replace(/:\d+$/,""):i).toLowerCase())throw new vn("Invalid host header");return a.href}},IZ=e=>e instanceof vn?e:new vn(e.message,{cause:e}),_Z=global.Request;var Na=class extends _Z{constructor(i,n){if(typeof i=="object"&&oo in i){const o=n!==void 0&&"body"in n&&n.body!=null;if(i[Mn]&&!o)throw new TypeError("Cannot construct a Request with a Request object that has already been used.");i=i[oo]()}typeof n?.body?.getReader<"u"&&(n.duplex??="half"),super(i,n)}};const nb=e=>{const i=[],n=e.rawHeaders;for(let o=0,a=n.length;o<a;o+=2){const t=n[o];t.charCodeAt(0)!==58&&i.push([t,n[o+1]])}return new Headers(i)},ob=Symbol("wrapBodyStream"),zZ=(e,i,n,o,a)=>{const t={method:e,headers:n,signal:a.signal};if(e==="TRACE"){t.method="GET";const s=new Na(i,t);return Object.defineProperty(s,"method",{get(){return"TRACE"}}),s}if(!(e==="GET"||e==="HEAD"))if("rawBody"in o&&o.rawBody instanceof Buffer)t.body=new ReadableStream({start(s){s.enqueue(o.rawBody),s.close()}});else if(o[ob]){let s;t.body=new ReadableStream({async pull(r){try{s||=xl.toWeb(o).getReader();const{done:u,value:d}=await s.read();u?r.close():r.enqueue(d)}catch(u){r.error(u)}}})}else t.body=xl.toWeb(o);return new Na(i,t)},oo=Symbol("getRequestCache"),Bn=Symbol("requestCache"),Ea=Symbol("incomingKey"),Kt=Symbol("urlKey"),ab=Symbol("methodKey"),tb=Symbol("headersKey"),kt=Symbol("abortControllerKey"),El=Symbol("getAbortController"),Rl=Symbol("abortRequest"),$a=Symbol("bodyBuffer"),Fs=Symbol("bodyReadPromise"),Mn=Symbol("bodyConsumedDirectly"),qp=Symbol("bodyLockReader"),At=Symbol("abortReason"),sb=()=>new TypeError("Body is unusable"),Ls=()=>Promise.reject(sb()),KZ=new TextDecoder,qZ=e=>{if(e[Mn])return Ls();e[Mn]=!0},UZ=e=>e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength),VZ=e=>(e[tb]||=nb(e[Ea])).get("content-type")||"",eJ=/^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/,iJ=e=>{if(typeof e!="string"||e.length===0)return"GET";switch(e){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"POST":case"PUT":return e}const i=e.toUpperCase();switch(i){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"POST":case"PUT":return i;default:return e}},nJ=e=>{if(!eJ.test(e))return new TypeError(`'${e}' is not a valid HTTP method.`);const i=e.toUpperCase();if(i==="CONNECT"||i==="TRACK"||i==="TRACE"&&e!=="TRACE")return new TypeError(`'${e}' HTTP method is unsupported.`)},Vg=(e,i,n)=>{if(e[Mn])return Ls();const o=e.method;if(o==="GET"||o==="HEAD")return e[oo]()[i]();const a=nJ(o);if(a)return Promise.reject(a);if(e[Bn]&&o!=="TRACE")return e[Bn][i]();const t=qZ(e);if(t)return t;const s=oJ(e);if(s){const r=Promise.resolve(n(s,e));return e[$a]=void 0,r}return aJ(e).then(r=>{const u=n(r,e);return e[$a]=void 0,u})},oJ=e=>{const i=e[Ea];if("rawBody"in i&&i.rawBody instanceof Buffer)return i.rawBody},aJ=e=>{if(e[$a])return Promise.resolve(e[$a]);if(e[Fs])return e[Fs];const i=e[Ea];if(xl.isDisturbed(i))return Ls();const n=new Promise((o,a)=>{const t=[];let s=!1;const r=c=>{s||(s=!0,h(),c())},u=c=>{t.push(Buffer.isBuffer(c)?c:Buffer.from(c))},d=()=>{r(()=>{const c=t.length===1?t[0]:Buffer.concat(t);e[$a]=c,o(c)})},l=c=>{r(()=>{a(c)})},g=()=>{if(i.readableEnded){d();return}r(()=>{if(i.errored){a(i.errored);return}const c=e[At];if(c!==void 0){a(c instanceof Error?c:new Error(String(c)));return}a(new Error("Client connection prematurely closed."))})},h=()=>{i.off("data",u),i.off("end",d),i.off("error",l),i.off("close",g),e[Fs]=void 0};i.on("data",u),i.on("end",d),i.on("error",l),i.on("close",g),queueMicrotask(()=>{s||(i.readableEnded?d():i.errored?l(i.errored):i.destroyed&&g())})});return e[Fs]=n,n},jn={get method(){return this[ab]},get url(){return this[Kt]},get headers(){return this[tb]||=nb(this[Ea])},[Rl](e){this[At]===void 0&&(this[At]=e);const i=this[kt];i&&!i.signal.aborted&&i.abort(e)},[El](){return this[kt]||=new AbortController,this[At]!==void 0&&!this[kt].signal.aborted&&this[kt].abort(this[At]),this[kt]},[oo](){const e=this[El]();if(this[Bn])return this[Bn];const i=this.method;if(this[Mn]&&!(i==="GET"||i==="HEAD")){this[$a]=void 0;const n={method:i==="TRACE"?"GET":i,headers:this.headers,signal:e.signal};i!=="TRACE"&&(n.body=new ReadableStream({start(a){a.close()}}),n.duplex="half");const o=new Na(this[Kt],n);return i==="TRACE"&&Object.defineProperty(o,"method",{get(){return"TRACE"}}),this[Bn]=o}return this[Bn]=zZ(this.method,this[Kt],this.headers,this[Ea],e)},get body(){if(!this[Mn])return this[oo]().body;const e=this[oo]();return!this[qp]&&e.body&&(this[qp]=e.body.getReader()),e.body},get bodyUsed(){return this[Mn]?!0:this[Bn]?this[Bn].bodyUsed:!1}};Object.defineProperty(jn,"signal",{get(){return this[El]().signal}});["cache","credentials","destination","integrity","mode","redirect","referrer","referrerPolicy","keepalive"].forEach(e=>{Object.defineProperty(jn,e,{get(){return this[oo]()[e]}})});["clone","formData"].forEach(e=>{Object.defineProperty(jn,e,{value:function(){if(this[Mn]){if(e==="clone")throw sb();return Ls()}return this[oo]()[e]()}})});Object.defineProperty(jn,"text",{value:function(){return Vg(this,"text",e=>KZ.decode(e))}});Object.defineProperty(jn,"arrayBuffer",{value:function(){return Vg(this,"arrayBuffer",e=>UZ(e))}});Object.defineProperty(jn,"blob",{value:function(){return Vg(this,"blob",(e,i)=>{const n=VZ(i),o=n?{headers:{"content-type":n}}:void 0;return new Response(e,o).blob()})}});Object.defineProperty(jn,"json",{value:function(){return this[Mn]?Ls():this.text().then(JSON.parse)}});Object.defineProperty(jn,Symbol.for("nodejs.util.inspect.custom"),{value:function(e,i,n){return`Request (lightweight) ${n({method:this.method,url:this.url,headers:this.headers,nativeRequest:this[Bn]},{...i,depth:e==null?null:e-1})}`}});Object.setPrototypeOf(jn,Na.prototype);const tJ=(e,i)=>{const n=Object.create(jn);n[Ea]=e,n[ab]=iJ(e.method);const o=e.url||"";if(o[0]!=="/"&&(o.startsWith("http://")||o.startsWith("https://"))){if(e instanceof zt)throw new vn("Absolute URL for :path is not allowed in HTTP/2");try{n[Kt]=new URL(o).href}catch(s){throw new vn("Invalid absolute URL",{cause:s})}return n}const a=(e instanceof zt?e.authority:e.headers.host)||i;if(!a)throw new vn("Missing host header");let t;if(e instanceof zt){if(t=e.scheme,!(t==="http"||t==="https"))throw new vn("Unsupported scheme")}else t=e.socket&&e.socket.encrypted?"https":"http";try{n[Kt]=WZ(t,a,o)}catch(s){throw s instanceof vn?s:new vn("Invalid URL",{cause:s})}return n},io="text/plain; charset=UTF-8",Ol=Symbol("responseCache"),wa=Symbol("getResponseCache"),Hn=Symbol("cache"),eh=global.Response;var fn=class rb{#n;#i;[wa](){const i=this[Hn],n=i&&i[2]instanceof Headers?i[2]:void 0;return delete this[Hn],this[Ol]||=new eh(this.#n,n?{...this.#i,headers:n}:this.#i)}constructor(i,n){let o;if(this.#n=i,n instanceof rb){const a=n[Ol];if(a){this.#i=a,this[wa]();return}else this.#i=n.#i,o=new Headers(n.headers)}else this.#i=n;(i==null||typeof i=="string"||typeof i?.getReader<"u"||i instanceof Blob||i instanceof Uint8Array)&&(this[Hn]=[n?.status||200,i??null,o||n?.headers])}get headers(){const i=this[Hn];return i?(i[2]instanceof Headers||(i[2]=new Headers(i[2]||(i[1]===null?void 0:{"content-type":io}))),i[2]):this[wa]().headers}get status(){return this[Hn]?.[0]??this[wa]().status}get ok(){const i=this.status;return i>=200&&i<300}};["body","bodyUsed","redirected","statusText","trailers","type","url"].forEach(e=>{Object.defineProperty(fn.prototype,e,{get(){return this[wa]()[e]}})});["arrayBuffer","blob","clone","formData","json","text"].forEach(e=>{Object.defineProperty(fn.prototype,e,{value:function(){return this[wa]()[e]()}})});Object.defineProperty(fn.prototype,Symbol.for("nodejs.util.inspect.custom"),{value:function(e,i,n){return`Response (lightweight) ${n({status:this.status,headers:this.headers,ok:this.ok,nativeResponse:this[Ol]},{...i,depth:e==null?null:e-1})}`}});Object.setPrototypeOf(fn,eh);Object.setPrototypeOf(fn.prototype,eh.prototype);const sJ=/^https?:\/\/[!#-;=?-[\]_a-z~A-Z]+$/,rJ=e=>e instanceof URL?e.href:sJ.test(e)?e:new URL(e).href,uJ=new Set([301,302,303,307,308]);Object.defineProperty(fn,"redirect",{value:function(e,i=302){if(!uJ.has(i))throw new RangeError("Invalid status code");return new fn(null,{status:i,headers:{location:rJ(e)}})},writable:!0,configurable:!0});Object.defineProperty(fn,"json",{value:function(e,i){const n=JSON.stringify(e);if(n===void 0)throw new TypeError("The data is not JSON serializable");const o=i?.headers;let a;return o?(a=new Headers(o),a.has("content-type")||a.set("content-type","application/json")):a={"content-type":"application/json"},new fn(n,{status:i?.status??200,statusText:i?.statusText,headers:a})},writable:!0,configurable:!0});async function dJ(e){return Promise.race([e,Promise.resolve().then(()=>Promise.resolve(void 0))])}function ub(e,i,n){const o=r=>{e.cancel(r).catch(()=>{})};return i.on("close",o),i.on("error",o),(n??e.read()).then(s,a),e.closed.finally(()=>{i.off("close",o),i.off("error",o)});function a(r){r&&i.destroy(r)}function t(){e.read().then(s,a)}function s({done:r,value:u}){try{if(r)i.end();else if(!i.write(u))i.once("drain",t);else return e.read().then(s,a)}catch(d){a(d)}}}function Up(e,i){if(e.locked)throw new TypeError("ReadableStream is locked.");return i.destroyed?void 0:ub(e.getReader(),i)}const Al=(e,i)=>{const n={};if(e instanceof Headers||(e=new Headers(e??void 0)),e.has("set-cookie")){const o=[];for(const[a,t]of e)a==="set-cookie"?o.push(t):n[a]=t;o.length>0&&(n["set-cookie"]=o)}else for(const[o,a]of e)n[o]=a;return i&&(n["content-type"]??=i),n},$r=Symbol("outgoingEnded"),Vp=Symbol("incomingDraining"),lJ=500,gJ=64*1024*1024,db=e=>{const i=e;if(e.destroyed||i[Vp])return;if(i[Vp]=!0,e instanceof zt){try{e.stream?.close?.(jY.NGHTTP2_NO_ERROR)}catch{}return}let n=0;const o=()=>{clearTimeout(t),e.off("data",s),e.off("end",o),e.off("error",o)},a=()=>{o();const r=e.socket;r&&!r.destroyed&&r.destroySoon()},t=setTimeout(a,lJ);t.unref?.();const s=r=>{n+=r.length,n>gJ&&a()};e.on("data",s),e.on("end",o),e.on("error",o),e.resume()},hJ=(e,i,n,o)=>()=>{i.errored?e[Rl](i.errored.toString()):n.writableFinished||e[Rl]("Client connection prematurely closed."),o&&!i.readableEnded&&setTimeout(()=>{i.readableEnded||setTimeout(()=>{db(i)})})},cJ=e=>{if(!(Hn in e))return!1;const i=e[Hn][1];return i===null||typeof i=="string"||i instanceof Uint8Array},pJ=()=>new Response(null,{status:400}),lb=e=>new Response(null,{status:e instanceof Error&&(e.name==="TimeoutError"||e.constructor.name==="TimeoutError")?504:500}),Zr=(e,i)=>{const n=e instanceof Error?e:new Error("unknown error",{cause:e});n.code==="ERR_STREAM_PREMATURE_CLOSE"?console.info("The user aborted a request."):(console.error(e),i.headersSent||i.writeHead(500,{"Content-Type":"text/plain"}),i.end(`Error: ${n.message}`),i.destroy(n))},Gl=e=>{"flushHeaders"in e&&e.writable&&e.flushHeaders()},gb=async(e,i)=>{let[n,o,a]=e[Hn];if(!a){o===null?(i.writeHead(n),i.end()):typeof o=="string"?(i.writeHead(n,{"Content-Type":io,"Content-Length":Buffer.byteLength(o)}),i.end(o)):o instanceof Uint8Array?(i.writeHead(n,{"Content-Type":io,"Content-Length":o.byteLength}),i.end(o)):o instanceof Blob?(i.writeHead(n,{"Content-Type":io,"Content-Length":o.size}),i.end(new Uint8Array(await o.arrayBuffer()))):(i.writeHead(n,{"Content-Type":io}),Gl(i),await Up(o,i)?.catch(s=>Zr(s,i))),i[$r]?.();return}let t=!1;if(a instanceof Headers)t=a.has("content-length"),a=Al(a,o===null?void 0:io);else if(Array.isArray(a)){const s=new Headers(a);t=s.has("content-length"),a=Al(s,o===null?void 0:io)}else for(const s in a)if(s.length===14&&s.toLowerCase()==="content-length"){t=!0;break}t||(typeof o=="string"?a["Content-Length"]=Buffer.byteLength(o):o instanceof Uint8Array?a["Content-Length"]=o.byteLength:o instanceof Blob&&(a["Content-Length"]=o.size)),i.writeHead(n,a),o==null?i.end():typeof o=="string"||o instanceof Uint8Array?i.end(o):o instanceof Blob?i.end(new Uint8Array(await o.arrayBuffer())):(Gl(i),await Up(o,i)?.catch(s=>Zr(s,i))),i[$r]?.()},hb=e=>typeof e.then=="function",vJ=async(e,i,n={})=>{if(hb(e))if(n.errorHandler)try{e=await e}catch(a){const t=await n.errorHandler(a);if(!t)return;e=t}else e=await e.catch(lb);if(Hn in e)return gb(e,i);const o=Al(e.headers,e.body===null?void 0:io);if(e.body){const a=e.body.getReader(),t=[];let s=!1,r;if(o["transfer-encoding"]!=="chunked"){let u=2;for(let d=0;d<u;d++){r||=a.read();const l=await dJ(r).catch(g=>{console.error(g),s=!0});if(!l){if(d===1){await new Promise(g=>setTimeout(g)),u=3;continue}break}if(r=void 0,l.value&&t.push(l.value),l.done){s=!0;break}}s&&!("content-length"in o)&&(o["content-length"]=t.reduce((d,l)=>d+l.length,0))}i.writeHead(e.status,o),t.forEach(u=>{i.write(u)}),s?i.end():(t.length===0&&Gl(i),await ub(a,i,r))}else o[AZ]||(i.writeHead(e.status,o),i.end());i[$r]?.()},yJ=(e,i={})=>{const n=i.autoCleanupIncoming??!0;return i.overrideGlobalObjects!==!1&&global.Request!==Na&&(Object.defineProperty(global,"Request",{value:Na}),Object.defineProperty(global,"Response",{value:fn})),async(o,a)=>{let t,s,r=!1,u=!1;const d=()=>{!s||u||(u=!0,a.on("close",hJ(s,o,a,r)))};try{if(s=tJ(o,i.hostname),r=n&&!(o.method==="GET"||o.method==="HEAD"),r&&(o[ob]=!0,o instanceof zt&&(a[$r]=()=>{o.readableEnded||setTimeout(()=>{o.readableEnded||setTimeout(()=>{o.destroy(),a.destroy()})})})),t=e(s,{incoming:o,outgoing:a}),!hb(t)&&cJ(t))return r&&!o.readableEnded&&a.once("finish",()=>{o.readableEnded||db(o)}),gb(t,a);d()}catch(l){if(t)return Zr(l,a);if(i.errorHandler){if(d(),t=await i.errorHandler(s?l:IZ(l)),!t)return}else s?t=lb(l):t=pJ()}try{return await vJ(t,a,i)}catch(l){return Zr(l,a)}}},fJ=Symbol("CONNECTION_SYMBOL_KEY"),mJ=Symbol("WAIT_FOR_WEBSOCKET_SYMBOL"),bJ=new Set(["connection","content-length","keep-alive","proxy-authenticate","proxy-authorization","te","trailer","transfer-encoding","upgrade","sec-websocket-accept","sec-websocket-extensions","sec-websocket-protocol"]),cb=(e,i)=>{i&&i.forEach((n,o)=>{bJ.has(o.toLowerCase())||e.push(`${o}: ${n}`)})},ev=(e,i,n)=>{const o=["Connection: close","Content-Length: 0"];cb(o,n),e.end(`HTTP/1.1 ${i.toString()} ${wY[i]??""}\r
5
+ `))}}},name:"completion",options:[{defaultOption:!0,defaultValue:Zp(),description:"Shell type (bash, zsh, fish, powershell). Defaults to current shell if detected.",name:"shell",type:String,typeLabel:"{underline shell}"},{defaultValue:$p(),description:"JavaScript runtime (node, bun, deno). Defaults to current runtime if detected.",name:"runtime",type:String,typeLabel:"{underline runtime}"}]},VY={alias:["v","V"],description:"Output the version number",execute:({logger:e,runtime:i})=>{const n=i.getPackageVersion();n===void 0?(e.warn("Unknown version"),e.debug("The version number was not provided by the cli constructor.")):e.info(n)},name:"version",options:[],usage:[]},e$=wn(import.meta.url),ft=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,tm=e=>{if(typeof ft<"u"&&ft.versions&&ft.versions.node){const[i,n]=ft.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return ft.getBuiltinModule(e)}return e$(e)},{execFileSync:i$}=tm("node:child_process"),{existsSync:Jp,readFileSync:n$}=tm("node:fs"),o$=["yarn.lock","package-lock.json","pnpm-lock.yaml","npm-shrinkwrap.json","bun.lock","bun.lockb"],xp=new Set(["bun","npm","pnpm","yarn"]),sm=e=>{const i=VC(n$(e,"utf8"));return typeof i?.packageManager=="string"?i.packageManager:void 0},a$=e=>{let i;if(o$.forEach(o=>{!i&&Jp(L(e,o))&&(i=L(e,o))}),i)return i;const n=L(e,"package.json");if(Jp(n)&&sm(n)!==void 0)return n},t$=e=>{if(!e)throw new Jl("Could not find a package manager");if(e.endsWith("package.json")){const i=sm(e);if(i){const n=["npm","yarn","pnpm","bun"].find(o=>i.startsWith(o));if(n)return{packageManager:n,path:no(e)}}}if(e.endsWith("yarn.lock"))return{packageManager:"yarn",path:no(e)};if(e.endsWith("package-lock.json")||e.endsWith("npm-shrinkwrap.json"))return{packageManager:"npm",path:no(e)};if(e.endsWith("pnpm-lock.yaml"))return{packageManager:"pnpm",path:no(e)};if(e.endsWith("bun.lock")||e.endsWith("bun.lockb"))return{packageManager:"bun",path:no(e)};throw new Jl("Could not find a package manager")},s$=e=>{const i=Gf(a$,{...e&&{cwd:e}});return t$(i)},ZSe=e=>{if(!xp.has(e))throw new Error(`Unsupported package manager "${e}". Expected one of: ${[...xp].join(", ")}.`);return i$(e,["--version"]).toString("utf8").trim()},r$=wn(import.meta.url),mt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,rm=e=>{if(typeof mt<"u"&&mt.versions&&mt.versions.node){const[i,n]=mt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return mt.getBuiltinModule(e)}return r$(e)};rm("node:fs");rm("node:fs/promises");const u$={sha256:"sha256",sha384:"sha384",sha512:"sha512"},d$=1024,l$=/^[A-Z0-9+/]+={0,2}$/i,Tp="node_modules/",as=/^['"]/,ts=/['"]$/,g$=/^[a-z][a-zA-Z0-9]*:\s*$/m,h$=/resolution:\s*\{[^}]*integrity:\s*([^,}\s]+)/,c$=/^["']?((?:@[^/@"']+\/)?[^@"'\n]+)@[^\n]+\n((?:[\t ][^\n]*(?:\n|$))+)/gm,p$=/^\s+version:?\s+"?([^"\n]+)"?/m,v$=/^\s+integrity[\s:]+"?([^"\s]+)"?/m,Ir=e=>{if(e.length>d$)return;const i=e.indexOf("-");if(i<=0)return;const n=u$[e.slice(0,i).toLowerCase()];if(!n)return;const o=e.slice(i+1);if(l$.test(o))try{const a=Buffer.from(o,"base64");return a.length===0?void 0:{algorithm:n,hex:a.toString("hex")}}catch{return}},_r=(e,i,n)=>{const o=`${n.name}@${n.version}`;i.has(o)||(i.add(o),e.push(n))},Ei=(e,i,n)=>{n&&Object.keys(n).length>0&&(e[i]={...n})},Ya=e=>{if(!e)return;const i={};for(const[n,o]of Object.entries(e))i[n]=[o];return Object.keys(i).length>0?i:void 0},y$=e=>{const i=[],n=new Set;let o;try{o=JSON.parse(e)}catch{return i}if(!o.packages)return i;for(const[a,t]of Object.entries(o.packages)){if(!a||!t.version)continue;const s=a.lastIndexOf(Tp);if(s===-1)continue;const r=a.slice(s+Tp.length);if(r.length===0)continue;const u=r.split("/"),d=r.startsWith("@")?2:1;if(u.length!==d||u.some(h=>h.length===0))continue;const l=t.name??r;if(l.startsWith("."))continue;const g={name:l,version:t.version};if(t.integrity){const h=Ir(t.integrity);h&&(g.integrity=h)}Ei(g,"dependencies",Ya(t.dependencies)),Ei(g,"peerDependencies",Ya(t.peerDependencies)),Ei(g,"optionalDependencies",Ya(t.optionalDependencies)),_r(i,n,g)}return i},um=e=>{let i=e.trim();i.startsWith("/")&&(i=i.slice(1)),i=i.replace(as,"").replace(ts,"");const n=i.indexOf("(");n>0&&(i=i.slice(0,n));const o=i.lastIndexOf("@");if(o<=0)return;const a=i.slice(0,o),t=i.slice(o+1);if(!(!a||!t||t.startsWith("link:")||t.startsWith("workspace:")||t.startsWith("file:")))return{name:a,version:t}},dm=(e,i)=>{const n=new RegExp(String.raw`^${i}:\s*$`,"m").exec(e);if(!n)return;const o=n.index+n[0].length,a=g$.exec(e.slice(o));return e.slice(o,a?o+a.index:e.length)},f$=e=>{const i=new Map,n=dm(e,"snapshots");if(!n)return i;const o=/^ {2}(['"]?[^\s:][^:\n]*?['"]?):\s*\n((?: {4}[^\n]*\n?)+)/gm;let a;for(;(a=o.exec(n)??void 0)!==void 0;){const t=um(a[1]);if(!t)continue;const s=`${t.name}@${t.version}`,r=a[2],u=i.get(s)??{};for(const d of["dependencies","peerDependencies","optionalDependencies"]){const l=rr(r,d);if(!l)continue;const g=u[d]??{};for(const[h,c]of Object.entries(l)){const p=g[h]??[];for(const f of c)p.includes(f)||p.push(f);g[h]=p}u[d]=g}i.set(s,u)}return i},m$=e=>{const i=[],n=new Set,o=dm(e,"packages");if(!o)return i;const a=f$(e),t=/^ {2}(['"]?[^\s:][^:\n]*?['"]?):\s*\n((?: {4}[^\n]*\n?)+)/gm;let s;for(;(s=t.exec(o)??void 0)!==void 0;){const r=um(s[1]);if(!r)continue;const u=s[2],d=h$.exec(u),l={name:r.name,version:r.version};if(d?.[1]){const h=Ir(d[1]);h&&(l.integrity=h)}const g=a.get(`${r.name}@${r.version}`);Ei(l,"dependencies",g?.dependencies??rr(u,"dependencies")),Ei(l,"peerDependencies",g?.peerDependencies??rr(u,"peerDependencies")),Ei(l,"optionalDependencies",g?.optionalDependencies??rr(u,"optionalDependencies")),_r(i,n,l)}return i},rr=(e,i)=>{const n=new RegExp(String.raw`^ {4}${i}:\s*\n((?: {6,}[^\n]*\n?)+)`,"m").exec(e);if(!n?.[1])return;const o={},a=/^ {6}([^\s:]+):\s*([^\n]+)/gm;let t;for(;(t=a.exec(n[1])??void 0)!==void 0;){const s=t[1].replace(as,"").replace(ts,"");let r=t[2].trim();r=r.replace(as,"").replace(ts,"");const u=r.indexOf("(");if(u>0&&(r=r.slice(0,u).trim()),!s||!r)continue;const d=o[s]??[];d.includes(r)||d.push(r),o[s]=d}return Object.keys(o).length>0?o:void 0},b$=e=>{const i=[],n=new Set,o=c$;o.lastIndex=0;let a;for(;(a=o.exec(e)??void 0)!==void 0;){const t=a[1].replace(as,"").replace(ts,"");if(!t)continue;const s=a[2],r=p$.exec(s);if(!r?.[1])continue;const u={name:t,version:r[1].trim()},d=v$.exec(s);if(d?.[1]){const l=Ir(d[1]);l&&(u.integrity=l)}Ei(u,"dependencies",rd(s,"dependencies")),Ei(u,"peerDependencies",rd(s,"peerDependencies")),Ei(u,"optionalDependencies",rd(s,"optionalDependencies")),_r(i,n,u)}return i},rd=(e,i)=>{const n=new RegExp(String.raw`^ {2}${i}:\s*\n((?: {4,}[^\n]*\n?)+)`,"m").exec(e);if(!n?.[1])return;const o={},a=/^ {4}(['"]?[^\s:'"]+['"]?)\s*(?::\s*)?['"]([^'"\n]+)['"]/gm;let t;for(;(t=a.exec(n[1])??void 0)!==void 0;){const s=t[1].replace(as,"").replace(ts,""),r=t[2];if(s&&r){const u=o[s]??[];u.includes(r)||u.push(r),o[s]=u}}return Object.keys(o).length>0?o:void 0},w$=/,(?=\s*[}\]])/g,j$=e=>{const i=[],n=new Set;let o;try{o=JSON.parse(e.replaceAll(w$,""))}catch{return i}if(!o.packages)return i;for(const a of Object.values(o.packages)){const t=a[0];if(typeof t!="string")continue;const s=t.indexOf("@",1);if(s<=0)continue;const r=t.slice(0,s),u=t.slice(s+1);if(!r||!u||u.startsWith("workspace:")||u.startsWith("link:")||u.startsWith("file:"))continue;const d={name:r,version:u},l=a[3];if(typeof l=="string"&&l.length>0){const h=Ir(l);h&&(d.integrity=h)}const g=a[2];if(g&&typeof g=="object"&&!Array.isArray(g)){const h=g;Ei(d,"dependencies",Ya(h.dependencies)),Ei(d,"peerDependencies",Ya(h.peerDependencies)),Ei(d,"optionalDependencies",Ya(h.optionalDependencies))}_r(i,n,d)}return i},JSe=(e,i)=>{switch(i){case"bun":return j$(e);case"npm":return y$(e);case"pnpm":return m$(e);case"yarn":return b$(e);default:return[]}},k$=wn(import.meta.url),bt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,S$=e=>{if(typeof bt<"u"&&bt.versions&&bt.versions.node){const[i,n]=bt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return bt.getBuiltinModule(e)}return k$(e)},{existsSync:Dp,readFileSync:L$}=S$("node:fs"),lm=e=>{const i=Gf(["lerna.json","turbo.json"],{type:"file",...e&&{cwd:e}});if(i?.endsWith("lerna.json")){const o=Qe(i);if(o.useWorkspaces||o.packages)return{path:no(i),strategy:"lerna"}}const n=i?.endsWith("turbo.json");try{const{packageManager:o,path:a}=s$(e);if(["npm","yarn"].includes(o)){const t=L(a,"package.json");if(Dp(t)&&L$(L(a,"package.json"),"utf8").includes("workspaces"))return{path:a,strategy:n?"turbo":o}}else if(o==="pnpm"){const t=L(a,"pnpm-workspace.yaml");if(Dp(t))return{path:a,strategy:n?"turbo":"pnpm"}}}catch(o){if(!(o instanceof Jl))throw o}throw new Error(`No monorepo root could be found upwards from the directory ${String(e??process.cwd())} using lerna, yarn, pnpm, or npm as indicators.`)},C$=wn(import.meta.url),wt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,Y$=e=>{if(typeof wt<"u"&&wt.versions&&wt.versions.node){const[i,n]=wt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return wt.getBuiltinModule(e)}return C$(e)};Y$("node:fs");var ud,Bp;function gm(){return Bp||(Bp=1,ud=["0BSD","3D-Slicer-1.0","AAL","ADSL","AFL-1.1","AFL-1.2","AFL-2.0","AFL-2.1","AFL-3.0","AGPL-1.0-only","AGPL-1.0-or-later","AGPL-3.0-only","AGPL-3.0-or-later","ALGLIB-Documentation","AMD-newlib","AMDPLPA","AML","AML-glslang","AMPAS","ANTLR-PD","ANTLR-PD-fallback","APAFML","APL-1.0","APSL-1.0","APSL-1.1","APSL-1.2","APSL-2.0","ASWF-Digital-Assets-1.0","ASWF-Digital-Assets-1.1","Abstyles","AdaCore-doc","Adobe-2006","Adobe-Display-PostScript","Adobe-Glyph","Adobe-Utopia","Advanced-Cryptics-Dictionary","Afmparse","Aladdin","Apache-1.0","Apache-1.1","Apache-2.0","App-s2p","Arphic-1999","Artistic-1.0","Artistic-1.0-Perl","Artistic-1.0-cl8","Artistic-2.0","Artistic-dist","Aspell-RU","BOLA-1.1","BSD-1-Clause","BSD-2-Clause","BSD-2-Clause-Darwin","BSD-2-Clause-Patent","BSD-2-Clause-Views","BSD-2-Clause-first-lines","BSD-2-Clause-pkgconf-disclaimer","BSD-3-Clause","BSD-3-Clause-Attribution","BSD-3-Clause-Clear","BSD-3-Clause-HP","BSD-3-Clause-LBNL","BSD-3-Clause-Modification","BSD-3-Clause-No-Military-License","BSD-3-Clause-No-Nuclear-License","BSD-3-Clause-No-Nuclear-License-2014","BSD-3-Clause-No-Nuclear-Warranty","BSD-3-Clause-Open-MPI","BSD-3-Clause-Sun","BSD-3-Clause-Tso","BSD-3-Clause-acpica","BSD-3-Clause-flex","BSD-4-Clause","BSD-4-Clause-Shortened","BSD-4-Clause-UC","BSD-4.3RENO","BSD-4.3TAHOE","BSD-Advertising-Acknowledgement","BSD-Attribution-HPND-disclaimer","BSD-Inferno-Nettverk","BSD-Mark-Modifications","BSD-Protection","BSD-Source-Code","BSD-Source-beginning-file","BSD-Systemics","BSD-Systemics-W3Works","BSL-1.0","BUSL-1.1","Baekmuk","Bahyph","Barr","Beerware","BitTorrent-1.0","BitTorrent-1.1","Bitstream-Charter","Bitstream-Vera","BlueOak-1.0.0","Boehm-GC","Boehm-GC-without-fee","Borceux","Brian-Gladman-2-Clause","Brian-Gladman-3-Clause","Buddy","C-UDA-1.0","CAL-1.0","CAL-1.0-Combined-Work-Exception","CAPEC-tou","CATOSL-1.1","CC-BY-1.0","CC-BY-2.0","CC-BY-2.5","CC-BY-2.5-AU","CC-BY-3.0","CC-BY-3.0-AT","CC-BY-3.0-AU","CC-BY-3.0-DE","CC-BY-3.0-IGO","CC-BY-3.0-NL","CC-BY-3.0-US","CC-BY-4.0","CC-BY-NC-1.0","CC-BY-NC-2.0","CC-BY-NC-2.5","CC-BY-NC-3.0","CC-BY-NC-3.0-DE","CC-BY-NC-4.0","CC-BY-NC-ND-1.0","CC-BY-NC-ND-2.0","CC-BY-NC-ND-2.5","CC-BY-NC-ND-3.0","CC-BY-NC-ND-3.0-DE","CC-BY-NC-ND-3.0-IGO","CC-BY-NC-ND-4.0","CC-BY-NC-SA-1.0","CC-BY-NC-SA-2.0","CC-BY-NC-SA-2.0-DE","CC-BY-NC-SA-2.0-FR","CC-BY-NC-SA-2.0-UK","CC-BY-NC-SA-2.5","CC-BY-NC-SA-3.0","CC-BY-NC-SA-3.0-DE","CC-BY-NC-SA-3.0-IGO","CC-BY-NC-SA-4.0","CC-BY-ND-1.0","CC-BY-ND-2.0","CC-BY-ND-2.5","CC-BY-ND-3.0","CC-BY-ND-3.0-DE","CC-BY-ND-4.0","CC-BY-SA-1.0","CC-BY-SA-2.0","CC-BY-SA-2.0-UK","CC-BY-SA-2.1-JP","CC-BY-SA-2.5","CC-BY-SA-3.0","CC-BY-SA-3.0-AT","CC-BY-SA-3.0-DE","CC-BY-SA-3.0-IGO","CC-BY-SA-4.0","CC-PDDC","CC-PDM-1.0","CC-SA-1.0","CC0-1.0","CDDL-1.0","CDDL-1.1","CDL-1.0","CDLA-Permissive-1.0","CDLA-Permissive-2.0","CDLA-Sharing-1.0","CECILL-1.0","CECILL-1.1","CECILL-2.0","CECILL-2.1","CECILL-B","CECILL-C","CERN-OHL-1.1","CERN-OHL-1.2","CERN-OHL-P-2.0","CERN-OHL-S-2.0","CERN-OHL-W-2.0","CFITSIO","CMU-Mach","CMU-Mach-nodoc","CNRI-Jython","CNRI-Python","CNRI-Python-GPL-Compatible","COIL-1.0","CPAL-1.0","CPL-1.0","CPOL-1.02","CUA-OPL-1.0","Caldera","Caldera-no-preamble","Catharon","ClArtistic","Clips","Community-Spec-1.0","Condor-1.1","Cornell-Lossless-JPEG","Cronyx","Crossword","CryptoSwift","CrystalStacker","Cube","D-FSL-1.0","DEC-3-Clause","DL-DE-BY-2.0","DL-DE-ZERO-2.0","DOC","DRL-1.0","DRL-1.1","DSDP","DocBook-DTD","DocBook-Schema","DocBook-Stylesheet","DocBook-XML","Dotseqn","ECL-1.0","ECL-2.0","EFL-1.0","EFL-2.0","EPICS","EPL-1.0","EPL-2.0","ESA-PL-permissive-2.4","ESA-PL-strong-copyleft-2.4","ESA-PL-weak-copyleft-2.4","EUDatagrid","EUPL-1.0","EUPL-1.1","EUPL-1.2","Elastic-2.0","Entessa","ErlPL-1.1","Eurosym","FBM","FDK-AAC","FSFAP","FSFAP-no-warranty-disclaimer","FSFUL","FSFULLR","FSFULLRSD","FSFULLRWD","FSL-1.1-ALv2","FSL-1.1-MIT","FTL","Fair","Ferguson-Twofish","Frameworx-1.0","FreeBSD-DOC","FreeImage","Furuseth","GCR-docs","GD","GFDL-1.1-invariants-only","GFDL-1.1-invariants-or-later","GFDL-1.1-no-invariants-only","GFDL-1.1-no-invariants-or-later","GFDL-1.1-only","GFDL-1.1-or-later","GFDL-1.2-invariants-only","GFDL-1.2-invariants-or-later","GFDL-1.2-no-invariants-only","GFDL-1.2-no-invariants-or-later","GFDL-1.2-only","GFDL-1.2-or-later","GFDL-1.3-invariants-only","GFDL-1.3-invariants-or-later","GFDL-1.3-no-invariants-only","GFDL-1.3-no-invariants-or-later","GFDL-1.3-only","GFDL-1.3-or-later","GL2PS","GLWTPL","GPL-1.0-only","GPL-1.0-or-later","GPL-2.0-only","GPL-2.0-or-later","GPL-3.0-only","GPL-3.0-or-later","Game-Programming-Gems","Giftware","Glide","Glulxe","Graphics-Gems","Gutmann","HDF5","HIDAPI","HP-1986","HP-1989","HPND","HPND-DEC","HPND-Fenneberg-Livingston","HPND-INRIA-IMAG","HPND-Intel","HPND-Kevlin-Henney","HPND-MIT-disclaimer","HPND-Markus-Kuhn","HPND-Netrek","HPND-Pbmplus","HPND-SMC","HPND-UC","HPND-UC-export-US","HPND-doc","HPND-doc-sell","HPND-export-US","HPND-export-US-acknowledgement","HPND-export-US-modify","HPND-export2-US","HPND-merchantability-variant","HPND-sell-MIT-disclaimer-xserver","HPND-sell-regexpr","HPND-sell-variant","HPND-sell-variant-MIT-disclaimer","HPND-sell-variant-MIT-disclaimer-rev","HPND-sell-variant-critical-systems","HTMLTIDY","HaskellReport","Hippocratic-2.1","IBM-pibs","ICU","IEC-Code-Components-EULA","IJG","IJG-short","IPA","IPL-1.0","ISC","ISC-Veillard","ISO-permission","ImageMagick","Imlib2","Info-ZIP","Inner-Net-2.0","InnoSetup","Intel","Intel-ACPI","Interbase-1.0","JPL-image","JPNIC","JSON","Jam","JasPer-2.0","Kastrup","Kazlib","Knuth-CTAN","LAL-1.2","LAL-1.3","LGPL-2.0-only","LGPL-2.0-or-later","LGPL-2.1-only","LGPL-2.1-or-later","LGPL-3.0-only","LGPL-3.0-or-later","LGPLLR","LOOP","LPD-document","LPL-1.0","LPL-1.02","LPPL-1.0","LPPL-1.1","LPPL-1.2","LPPL-1.3a","LPPL-1.3c","LZMA-SDK-9.11-to-9.20","LZMA-SDK-9.22","Latex2e","Latex2e-translated-notice","Leptonica","LiLiQ-P-1.1","LiLiQ-R-1.1","LiLiQ-Rplus-1.1","Libpng","Linux-OpenIB","Linux-man-pages-1-para","Linux-man-pages-copyleft","Linux-man-pages-copyleft-2-para","Linux-man-pages-copyleft-var","Lucida-Bitmap-Fonts","MIPS","MIT","MIT-0","MIT-CMU","MIT-Click","MIT-Festival","MIT-Khronos-old","MIT-Modern-Variant","MIT-STK","MIT-Wu","MIT-advertising","MIT-enna","MIT-feh","MIT-open-group","MIT-testregex","MITNFA","MMIXware","MMPL-1.0.1","MPEG-SSG","MPL-1.0","MPL-1.1","MPL-2.0","MPL-2.0-no-copyleft-exception","MS-LPL","MS-PL","MS-RL","MTLL","Mackerras-3-Clause","Mackerras-3-Clause-acknowledgment","MakeIndex","Martin-Birgmeier","McPhee-slideshow","Minpack","MirOS","Motosoto","MulanPSL-1.0","MulanPSL-2.0","Multics","Mup","NAIST-2003","NASA-1.3","NBPL-1.0","NCBI-PD","NCGL-UK-2.0","NCL","NCSA","NGPL","NICTA-1.0","NIST-PD","NIST-PD-TNT","NIST-PD-fallback","NIST-Software","NLOD-1.0","NLOD-2.0","NLPL","NOSL","NPL-1.0","NPL-1.1","NPOSL-3.0","NRL","NTIA-PD","NTP","NTP-0","Naumen","NetCDF","Newsletr","Nokia","Noweb","O-UDA-1.0","OAR","OCCT-PL","OCLC-2.0","ODC-By-1.0","ODbL-1.0","OFFIS","OFL-1.0","OFL-1.0-RFN","OFL-1.0-no-RFN","OFL-1.1","OFL-1.1-RFN","OFL-1.1-no-RFN","OGC-1.0","OGDL-Taiwan-1.0","OGL-Canada-2.0","OGL-UK-1.0","OGL-UK-2.0","OGL-UK-3.0","OGTSL","OLDAP-1.1","OLDAP-1.2","OLDAP-1.3","OLDAP-1.4","OLDAP-2.0","OLDAP-2.0.1","OLDAP-2.1","OLDAP-2.2","OLDAP-2.2.1","OLDAP-2.2.2","OLDAP-2.3","OLDAP-2.4","OLDAP-2.5","OLDAP-2.6","OLDAP-2.7","OLDAP-2.8","OLFL-1.3","OML","OPL-1.0","OPL-UK-3.0","OPUBL-1.0","OSC-1.0","OSET-PL-2.1","OSL-1.0","OSL-1.1","OSL-2.0","OSL-2.1","OSL-3.0","OSSP","OpenMDW-1.0","OpenPBS-2.3","OpenSSL","OpenSSL-standalone","OpenVision","PADL","PDDL-1.0","PHP-3.0","PHP-3.01","PPL","PSF-2.0","ParaType-Free-Font-1.3","Parity-6.0.0","Parity-7.0.0","Pixar","Plexus","PolyForm-Noncommercial-1.0.0","PolyForm-Small-Business-1.0.0","PostgreSQL","Python-2.0","Python-2.0.1","QPL-1.0","QPL-1.0-INRIA-2004","Qhull","RHeCos-1.1","RPL-1.1","RPL-1.5","RPSL-1.0","RSA-MD","RSCPL","Rdisc","Ruby","Ruby-pty","SAX-PD","SAX-PD-2.0","SCEA","SGI-B-1.0","SGI-B-1.1","SGI-B-2.0","SGI-OpenGL","SGMLUG-PM","SGP4","SHL-0.5","SHL-0.51","SISSL","SISSL-1.2","SL","SMAIL-GPL","SMLNJ","SMPPL","SNIA","SOFA","SPL-1.0","SSH-OpenSSH","SSH-short","SSLeay-standalone","SSPL-1.0","SUL-1.0","SWL","Saxpath","SchemeReport","Sendmail","Sendmail-8.23","Sendmail-Open-Source-1.1","SimPL-2.0","Sleepycat","Soundex","Spencer-86","Spencer-94","Spencer-99","SugarCRM-1.1.3","Sun-PPP","Sun-PPP-2000","SunPro","Symlinks","TAPR-OHL-1.0","TCL","TCP-wrappers","TGPPL-1.0","TMate","TORQUE-1.1","TOSL","TPDL","TPL-1.0","TTWL","TTYP0","TU-Berlin-1.0","TU-Berlin-2.0","TekHVC","TermReadKey","ThirdEye","TrustedQSL","UCAR","UCL-1.0","UMich-Merit","UPL-1.0","URT-RLE","Ubuntu-font-1.0","UnRAR","Unicode-3.0","Unicode-DFS-2015","Unicode-DFS-2016","Unicode-TOU","UnixCrypt","Unlicense","Unlicense-libtelnet","Unlicense-libwhirlpool","VOSTROM","VSL-1.0","Vim","Vixie-Cron","W3C","W3C-19980720","W3C-20150513","WTFNMFPL","WTFPL","Watcom-1.0","Widget-Workshop","WordNet","Wsuipa","X11","X11-distribute-modifications-variant","X11-no-permit-persons","X11-swapped","XFree86-1.1","XSkat","Xdebug-1.03","Xerox","Xfig","Xnet","YPL-1.0","YPL-1.1","ZPL-1.1","ZPL-2.0","ZPL-2.1","Zed","Zeeff","Zend-2.0","Zimbra-1.3","Zimbra-1.4","Zlib","any-OSI","any-OSI-perl-modules","bcrypt-Solar-Designer","blessing","bzip2-1.0.6","check-cvs","checkmk","copyleft-next-0.3.0","copyleft-next-0.3.1","curl","cve-tou","diffmark","dtoa","dvipdfm","eGenix","etalab-2.0","fwlw","gSOAP-1.3b","generic-xts","gnuplot","gtkbook","hdparm","hyphen-bulgarian","iMatix","jove","libpng-1.6.35","libpng-2.0","libselinux-1.0","libtiff","libutil-David-Nugent","lsof","magaz","mailprio","man2html","metamail","mpi-permissive","mpich2","mplus","ngrep","pkgconf","pnmstitch","psfrag","psutils","python-ldap","radvd","snprintf","softSurfer","ssh-keyscan","swrule","threeparttable","ulem","w3m","wwl","xinetd","xkeyboard-config-Zinoviev","xlock","xpp","xzoom","zlib-acknowledgement"]),ud}var dd,Xp;function $$(){return Xp||(Xp=1,dd=["AGPL-1.0","AGPL-3.0","BSD-2-Clause-FreeBSD","BSD-2-Clause-NetBSD","GFDL-1.1","GFDL-1.2","GFDL-1.3","GPL-1.0","GPL-2.0","GPL-2.0-with-GCC-exception","GPL-2.0-with-autoconf-exception","GPL-2.0-with-bison-exception","GPL-2.0-with-classpath-exception","GPL-2.0-with-font-exception","GPL-3.0","GPL-3.0-with-GCC-exception","GPL-3.0-with-autoconf-exception","LGPL-2.0","LGPL-2.1","LGPL-3.0","Net-SNMP","Nunit","StandardML-NJ","bzip2-1.0.5","eCos-2.0","wxWindows"]),dd}var ld,Hp;function Z$(){return Hp||(Hp=1,ld=["389-exception","Asterisk-exception","Autoconf-exception-2.0","Autoconf-exception-3.0","Autoconf-exception-generic","Autoconf-exception-generic-3.0","Autoconf-exception-macro","Bison-exception-1.24","Bison-exception-2.2","Bootloader-exception","Classpath-exception-2.0","CLISP-exception-2.0","cryptsetup-OpenSSL-exception","DigiRule-FOSS-exception","eCos-exception-2.0","Fawkes-Runtime-exception","FLTK-exception","fmt-exception","Font-exception-2.0","freertos-exception-2.0","GCC-exception-2.0","GCC-exception-2.0-note","GCC-exception-3.1","Gmsh-exception","GNAT-exception","GNOME-examples-exception","GNU-compiler-exception","gnu-javamail-exception","GPL-3.0-interface-exception","GPL-3.0-linking-exception","GPL-3.0-linking-source-exception","GPL-CC-1.0","GStreamer-exception-2005","GStreamer-exception-2008","i2p-gpl-java-exception","KiCad-libraries-exception","LGPL-3.0-linking-exception","libpri-OpenH323-exception","Libtool-exception","Linux-syscall-note","LLGPL","LLVM-exception","LZMA-exception","mif-exception","OCaml-LGPL-linking-exception","OCCT-exception-1.0","OpenJDK-assembly-exception-1.0","openvpn-openssl-exception","PS-or-PDF-font-exception-20170817","QPL-1.0-INRIA-2004-exception","Qt-GPL-exception-1.0","Qt-LGPL-exception-1.1","Qwt-exception-1.0","SANE-exception","SHL-2.0","SHL-2.1","stunnel-exception","SWI-exception","Swift-exception","Texinfo-exception","u-boot-exception-2.0","UBDL-exception","Universal-FOSS-exception-1.0","vsftpd-openssl-exception","WxWindows-exception-3.1","x11vnc-openssl-exception"]),ld}var gd,Mp;function J$(){if(Mp)return gd;Mp=1;var e=[].concat(gm()).concat($$()),i=Z$();return gd=function(n){var o=0;function a(){return o<n.length}function t(w){if(w instanceof RegExp){var v=n.slice(o),j=v.match(w);if(j)return o+=j[0].length,j[0]}else if(n.indexOf(w,o)===o)return o+=w.length,w}function s(){t(/[ ]*/)}function r(){for(var w,v=["WITH","AND","OR","(",")",":","+"],j=0;j<v.length&&(w=t(v[j]),!w);j++);if(w==="+"&&o>1&&n[o-2]===" ")throw new Error("Space before `+`");return w&&{type:"OPERATOR",string:w}}function u(){return t(/[A-Za-z0-9-.]+/)}function d(){var w=u();if(!w)throw new Error("Expected idstring at offset "+o);return w}function l(){if(t("DocumentRef-")){var w=d();return{type:"DOCUMENTREF",string:w}}}function g(){if(t("LicenseRef-")){var w=d();return{type:"LICENSEREF",string:w}}}function h(){var w=o,v=u();if(e.indexOf(v)!==-1)return{type:"LICENSE",string:v};if(i.indexOf(v)!==-1)return{type:"EXCEPTION",string:v};o=w}function c(){return r()||l()||g()||h()}for(var p=[];a()&&(s(),!!a());){var f=c();if(!f)throw new Error("Unexpected `"+n[o]+"` at offset "+o);p.push(f)}return p},gd}var hd,Pp;function x$(){return Pp||(Pp=1,hd=function(e){var i=0;function n(){return i<e.length}function o(){return n()?e[i]:null}function a(){if(!n())throw new Error;i++}function t(f){var w=o();if(w&&w.type==="OPERATOR"&&f===w.string)return a(),w.string}function s(){if(t("WITH")){var f=o();if(f&&f.type==="EXCEPTION")return a(),f.string;throw new Error("Expected exception after `WITH`")}}function r(){var f=i,w="",v=o();if(v.type==="DOCUMENTREF"&&(a(),w+="DocumentRef-"+v.string+":",!t(":")))throw new Error("Expected `:` after `DocumentRef-...`");if(v=o(),v.type==="LICENSEREF")return a(),w+="LicenseRef-"+v.string,{license:w};i=f}function u(){var f=o();if(f&&f.type==="LICENSE"){a();var w={license:f.string};t("+")&&(w.plus=!0);var v=s();return v&&(w.exception=v),w}}function d(){var f=t("(");if(f){var w=c();if(!t(")"))throw new Error("Expected `)`");return w}}function l(){return d()||r()||u()}function g(f,w){return function v(){var j=w();if(j){if(!t(f))return j;var C=v();if(!C)throw new Error("Expected expression");return{left:j,conjunction:f.toLowerCase(),right:C}}}}var h=g("AND",l),c=g("OR",h),p=c();if(!p||n())throw new Error("Syntax error");return p}),hd}var cd,Np;function hm(){if(Np)return cd;Np=1;var e=J$(),i=x$();return cd=function(n){return i(e(n))},cd}var pd,Ep;function T$(){if(Ep)return pd;Ep=1;var e=hm(),i=gm();function n(v){try{return e(v),!0}catch{return!1}}function o(v,j){var C=j[0].length-v[0].length;return C!==0?C:v[0].toUpperCase().localeCompare(j[0].toUpperCase())}var a=[["APGL","AGPL"],["Gpl","GPL"],["GLP","GPL"],["APL","Apache"],["ISD","ISC"],["GLP","GPL"],["IST","ISC"],["Claude","Clause"],[" or later","+"],[" International",""],["GNU","GPL"],["GUN","GPL"],["+",""],["GNU GPL","GPL"],["GNU LGPL","LGPL"],["GNU/GPL","GPL"],["GNU GLP","GPL"],["GNU LESSER GENERAL PUBLIC LICENSE","LGPL"],["GNU Lesser General Public License","LGPL"],["GNU LESSER GENERAL PUBLIC LICENSE","LGPL-2.1"],["GNU Lesser General Public License","LGPL-2.1"],["LESSER GENERAL PUBLIC LICENSE","LGPL"],["Lesser General Public License","LGPL"],["LESSER GENERAL PUBLIC LICENSE","LGPL-2.1"],["Lesser General Public License","LGPL-2.1"],["GNU General Public License","GPL"],["Gnu public license","GPL"],["GNU Public License","GPL"],["GNU GENERAL PUBLIC LICENSE","GPL"],["MTI","MIT"],["Mozilla Public License","MPL"],["Universal Permissive License","UPL"],["WTH","WTF"],["WTFGPL","WTFPL"],["-License",""]].sort(o),t=0,s=1,r=[function(v){return v.toUpperCase()},function(v){return v.trim()},function(v){return v.replace(/\./g,"")},function(v){return v.replace(/\s+/g,"")},function(v){return v.replace(/\s+/g,"-")},function(v){return v.replace("v","-")},function(v){return v.replace(/,?\s*(\d)/,"-$1")},function(v){return v.replace(/,?\s*(\d)/,"-$1.0")},function(v){return v.replace(/,?\s*(V\.|v\.|V|v|Version|version)\s*(\d)/,"-$2")},function(v){return v.replace(/,?\s*(V\.|v\.|V|v|Version|version)\s*(\d)/,"-$2.0")},function(v){return v[0].toUpperCase()+v.slice(1)},function(v){return v.replace("/","-")},function(v){return v.replace(/\s*V\s*(\d)/,"-$1").replace(/(\d)$/,"$1.0")},function(v){return v.indexOf("3.0")!==-1?v+"-or-later":v+"-only"},function(v){return v+"only"},function(v){return v.replace(/(\d)$/,"-$1.0")},function(v){return v.replace(/(-| )?(\d)$/,"-$2-Clause")},function(v){return v.replace(/(-| )clause(-| )(\d)/,"-$3-Clause")},function(v){return v.replace(/\b(Modified|New|Revised)(-| )?BSD((-| )License)?/i,"BSD-3-Clause")},function(v){return v.replace(/\bSimplified(-| )?BSD((-| )License)?/i,"BSD-2-Clause")},function(v){return v.replace(/\b(Free|Net)(-| )?BSD((-| )License)?/i,"BSD-2-Clause-$1BSD")},function(v){return v.replace(/\bClear(-| )?BSD((-| )License)?/i,"BSD-3-Clause-Clear")},function(v){return v.replace(/\b(Old|Original)(-| )?BSD((-| )License)?/i,"BSD-4-Clause")},function(v){return"CC-"+v},function(v){return"CC-"+v+"-4.0"},function(v){return v.replace("Attribution","BY").replace("NonCommercial","NC").replace("NoDerivatives","ND").replace(/ (\d)/,"-$1").replace(/ ?International/,"")},function(v){return"CC-"+v.replace("Attribution","BY").replace("NonCommercial","NC").replace("NoDerivatives","ND").replace(/ (\d)/,"-$1").replace(/ ?International/,"")+"-4.0"}],u=i.map(function(v){var j=/^(.*)-\d+\.\d+$/.exec(v);return j?[j[0],j[1]]:[v,null]}).reduce(function(v,j){var C=j[1];return v[C]=v[C]||[],v[C].push(j[0]),v},{}),d=Object.keys(u).map(function(v){return[v,u[v]]}).filter(function(v){return v[1].length===1&&v[0]!==null&&v[0]!=="APL"}).map(function(v){return[v[0],v[1][0]]});u=void 0;var l=[["UNLI","Unlicense"],["WTF","WTFPL"],["2 CLAUSE","BSD-2-Clause"],["2-CLAUSE","BSD-2-Clause"],["3 CLAUSE","BSD-3-Clause"],["3-CLAUSE","BSD-3-Clause"],["AFFERO","AGPL-3.0-or-later"],["AGPL","AGPL-3.0-or-later"],["APACHE","Apache-2.0"],["ARTISTIC","Artistic-2.0"],["Affero","AGPL-3.0-or-later"],["BEER","Beerware"],["BOOST","BSL-1.0"],["BSD","BSD-2-Clause"],["CDDL","CDDL-1.1"],["ECLIPSE","EPL-1.0"],["FUCK","WTFPL"],["GNU","GPL-3.0-or-later"],["LGPL","LGPL-3.0-or-later"],["GPLV1","GPL-1.0-only"],["GPL-1","GPL-1.0-only"],["GPLV2","GPL-2.0-only"],["GPL-2","GPL-2.0-only"],["GPL","GPL-3.0-or-later"],["MIT +NO-FALSE-ATTRIBS","MITNFA"],["MIT","MIT"],["MPL","MPL-2.0"],["X11","X11"],["ZLIB","Zlib"]].concat(d).sort(o),g=0,h=1,c=function(v){for(var j=0;j<r.length;j++){var C=r[j](v).trim();if(C!==v&&n(C))return C}return null},p=function(v){for(var j=v.toUpperCase(),C=0;C<l.length;C++){var y=l[C];if(j.indexOf(y[g])>-1)return y[h]}return null},f=function(v,j){for(var C=0;C<a.length;C++){var y=a[C],k=y[t];if(v.indexOf(k)>-1){var S=v.replace(k,y[s]),J=j(S);if(J!==null)return J}}return null};pd=function(v,j){j=j||{};var C=j.upgrade===void 0?!0:!!j.upgrade;function y(T){return C?w(T):T}var k=typeof v=="string"&&v.trim().length!==0;if(!k)throw Error("Invalid argument. Expected non-empty string.");if(v=v.trim(),n(v))return y(v);var S=v.replace(/\+$/,"").trim();if(n(S))return y(S);var J=c(v);return J!==null||(J=f(v,function(T){return n(T)?T:c(T)}),J!==null)||(J=p(v),J!==null)||(J=f(v,p),J!==null)?y(J):null};function w(v){return["GPL-1.0","LGPL-1.0","AGPL-1.0","GPL-2.0","LGPL-2.0","AGPL-2.0","LGPL-2.1"].indexOf(v)!==-1?v+"-only":["GPL-1.0+","GPL-2.0+","GPL-3.0+","LGPL-2.0+","LGPL-2.1+","LGPL-3.0+","AGPL-1.0+","AGPL-3.0+"].indexOf(v)!==-1?v.replace(/\+$/,"-or-later"):["GPL-3.0","LGPL-3.0","AGPL-3.0"].indexOf(v)!==-1?v+"-or-later":v}return pd}var vd,Rp;function D$(){if(Rp)return vd;Rp=1;var e=hm(),i=T$(),n='license should be a valid SPDX license expression (without "LicenseRef"), "UNLICENSED", or "SEE LICENSE IN <filename>"',o=/^SEE LICEN[CS]E IN (.+)$/;function a(s,r){return r.slice(0,s.length)===s}function t(s){if(s.hasOwnProperty("license")){var r=s.license;return a("LicenseRef",r)||a("DocumentRef",r)}else return t(s.left)||t(s.right)}return vd=function(s){var r;try{r=e(s)}catch{var u;if(s==="UNLICENSED"||s==="UNLICENCED")return{validForOldPackages:!0,validForNewPackages:!0,unlicensed:!0};if(u=o.exec(s))return{validForOldPackages:!0,validForNewPackages:!0,inFile:u[1]};var d={validForOldPackages:!1,validForNewPackages:!1,warnings:[n]};if(s.trim().length!==0){var l=i(s);l&&d.warnings.push('license is similar to the valid expression "'+l+'"')}return d}return t(r)?{validForNewPackages:!1,validForOldPackages:!1,spdx:!0,warnings:[n]}:{validForNewPackages:!0,validForOldPackages:!0,spdx:!0}},vd}var cm={hasSubscribers:!1},Ie=cm,ba=cm;import("node:diagnostics_channel").then(e=>{Ie=e.channel("lru-cache:metrics"),ba=e.tracingChannel("lru-cache")}).catch(()=>{});var B$=typeof performance=="object"&&performance&&typeof performance.now=="function"?performance:Date,yd=()=>Ie.hasSubscribers||ba.hasSubscribers,pm=new Set,Op=process||{},X$=(e,i,n,o)=>{typeof Op.emitWarning=="function"?Op.emitWarning(e,i,n,o):console.error(`[${n}] ${i}: ${e}`)},H$=e=>!pm.has(e),Vn=e=>!!e&&e===Math.floor(e)&&e>0&&isFinite(e),vm=e=>Vn(e)?e<=Math.pow(2,8)?Uint8Array:e<=Math.pow(2,16)?Uint16Array:e<=Math.pow(2,32)?Uint32Array:e<=Number.MAX_SAFE_INTEGER?ur:null:null,ur=class extends Array{constructor(i){super(i),this.fill(0)}},M$=class Ot{heap;length;static#n=!1;static create(i){let n=vm(i);if(!n)return[];Ot.#n=!0;let o=new Ot(i,n);return Ot.#n=!1,o}constructor(i,n){if(!Ot.#n)throw new TypeError("instantiate Stack using Stack.create(n)");this.heap=new n(i),this.length=0}push(i){this.heap[this.length++]=i}pop(){return this.heap[--this.length]}},P$=class ym{#n;#i;#e;#t;#o;#a;#r;#g;get perf(){return this.#g}ttl;ttlResolution;ttlAutopurge;updateAgeOnGet;updateAgeOnHas;allowStale;noDisposeOnSet;noUpdateTTL;maxEntrySize;sizeCalculation;noDeleteOnFetchRejection;noDeleteOnStaleGet;allowStaleOnFetchAbort;allowStaleOnFetchRejection;ignoreFetchAbort;backgroundFetchSize;#u;#c;#h;#d;#s;#f;#b;#y;#p;#S;#v;#L;#C;#w;#j;#Y;#P;#m;#D;static unsafeExposeInternals(i){return{starts:i.#C,ttls:i.#w,autopurgeTimers:i.#j,sizes:i.#L,keyMap:i.#h,keyList:i.#d,valList:i.#s,next:i.#f,prev:i.#b,get head(){return i.#y},get tail(){return i.#p},free:i.#S,isBackgroundFetch:n=>i.#l(n),backgroundFetch:(n,o,a,t)=>i.#R(n,o,a,t),moveToTail:n=>i.#M(n),indexes:n=>i.#$(n),rindexes:n=>i.#Z(n),isStale:n=>i.#k(n)}}get max(){return this.#n}get maxSize(){return this.#i}get calculatedSize(){return this.#c}get size(){return this.#u}get fetchMethod(){return this.#a}get memoMethod(){return this.#r}get dispose(){return this.#e}get onInsert(){return this.#t}get disposeAfter(){return this.#o}constructor(i){let{max:n=0,ttl:o,ttlResolution:a=1,ttlAutopurge:t,updateAgeOnGet:s,updateAgeOnHas:r,allowStale:u,dispose:d,onInsert:l,disposeAfter:g,noDisposeOnSet:h,noUpdateTTL:c,maxSize:p=0,maxEntrySize:f=0,sizeCalculation:w,fetchMethod:v,memoMethod:j,noDeleteOnFetchRejection:C,noDeleteOnStaleGet:y,allowStaleOnFetchRejection:k,allowStaleOnFetchAbort:S,ignoreFetchAbort:J,backgroundFetchSize:T=1,perf:M}=i;if(this.backgroundFetchSize=T,M!==void 0&&typeof M?.now!="function")throw new TypeError("perf option must have a now() method if specified");if(this.#g=M??B$,n!==0&&!Vn(n))throw new TypeError("max option must be a nonnegative integer");let he=n?vm(n):Array;if(!he)throw new Error("invalid max value: "+n);if(this.#n=n,this.#i=p,this.maxEntrySize=f||this.#i,this.sizeCalculation=w,this.sizeCalculation){if(!this.#i&&!this.maxEntrySize)throw new TypeError("cannot set sizeCalculation without setting maxSize or maxEntrySize");if(typeof this.sizeCalculation!="function")throw new TypeError("sizeCalculation set to non-function")}if(j!==void 0&&typeof j!="function")throw new TypeError("memoMethod must be a function if defined");if(this.#r=j,v!==void 0&&typeof v!="function")throw new TypeError("fetchMethod must be a function if specified");if(this.#a=v,this.#P=!!v,this.#h=new Map,this.#d=Array.from({length:n}).fill(void 0),this.#s=Array.from({length:n}).fill(void 0),this.#f=new he(n),this.#b=new he(n),this.#y=0,this.#p=0,this.#S=M$.create(n),this.#u=0,this.#c=0,typeof d=="function"&&(this.#e=d),typeof l=="function"&&(this.#t=l),typeof g=="function"?(this.#o=g,this.#v=[]):(this.#o=void 0,this.#v=void 0),this.#Y=!!this.#e,this.#D=!!this.#t,this.#m=!!this.#o,this.noDisposeOnSet=!!h,this.noUpdateTTL=!!c,this.noDeleteOnFetchRejection=!!C,this.allowStaleOnFetchRejection=!!k,this.allowStaleOnFetchAbort=!!S,this.ignoreFetchAbort=!!J,this.maxEntrySize!==0){if(this.#i!==0&&!Vn(this.#i))throw new TypeError("maxSize must be a positive integer if specified");if(!Vn(this.maxEntrySize))throw new TypeError("maxEntrySize must be a positive integer if specified");this.#_()}if(this.allowStale=!!u,this.noDeleteOnStaleGet=!!y,this.updateAgeOnGet=!!s,this.updateAgeOnHas=!!r,this.ttlResolution=Vn(a)||a===0?a:1,this.ttlAutopurge=!!t,this.ttl=o||0,this.ttl){if(!Vn(this.ttl))throw new TypeError("ttl must be a positive integer if specified");this.#O()}if(this.#n===0&&this.ttl===0&&this.#i===0)throw new TypeError("At least one of max, maxSize, or ttl is required");if(!this.ttlAutopurge&&!this.#n&&!this.#i){let Je="LRU_CACHE_UNBOUNDED";H$(Je)&&(pm.add(Je),X$("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.","UnboundedCacheWarning",Je,ym))}}getRemainingTTL(i){return this.#h.has(i)?1/0:0}#O(){let i=new ur(this.#n),n=new ur(this.#n);this.#w=i,this.#C=n;let o=this.ttlAutopurge?Array.from({length:this.#n}):void 0;this.#j=o,this.#A=(r,u,d=this.#g.now())=>{n[r]=u!==0?d:0,i[r]=u,a(r,u)},this.#B=r=>{n[r]=i[r]!==0?this.#g.now():0,a(r,i[r])};let a=this.ttlAutopurge?(r,u)=>{if(o?.[r]&&(clearTimeout(o[r]),o[r]=void 0),u&&u!==0&&o){let d=setTimeout(()=>{this.#k(r)&&this.#J(this.#d[r],"expire")},u+1);d.unref&&d.unref(),o[r]=d}}:()=>{};this.#x=(r,u)=>{if(i[u]){let d=i[u],l=n[u];if(!d||!l)return;r.ttl=d,r.start=l,r.now=t||s();let g=r.now-l;r.remainingTTL=d-g}};let t=0,s=()=>{let r=this.#g.now();if(this.ttlResolution>0){t=r;let u=setTimeout(()=>t=0,this.ttlResolution);u.unref&&u.unref()}return r};this.getRemainingTTL=r=>{let u=this.#h.get(r);if(u===void 0)return 0;let d=i[u],l=n[u];if(!d||!l)return 1/0;let g=(t||s())-l;return d-g},this.#k=r=>{let u=n[r],d=i[r];return!!d&&!!u&&(t||s())-u>d}}#B=()=>{};#x=()=>{};#A=()=>{};#k=()=>!1;#_(){let i=new ur(this.#n);this.#c=0,this.#L=i,this.#X=n=>{this.#c-=i[n],i[n]=0},this.#G=(n,o,a,t)=>{if(!Vn(a)){if(this.#l(o))return this.backgroundFetchSize;if(t){if(typeof t!="function")throw new TypeError("sizeCalculation must be a function");if(a=t(o,n),!Vn(a))throw new TypeError("sizeCalculation return invalid (expect positive integer)")}else throw new TypeError("invalid size value (must be positive integer). When maxSize or maxEntrySize is used, sizeCalculation or size must be set.")}return a},this.#N=(n,o,a)=>{if(i[n]=o,this.#i){let t=this.#i-i[n];for(;this.#c>t;)this.#E(!0)}this.#c+=i[n],a&&(a.entrySize=o,a.totalCalculatedSize=this.#c)}}#X=i=>{};#N=(i,n,o)=>{};#G=(i,n,o,a)=>{if(o||a)throw new TypeError("cannot set size without setting maxSize or maxEntrySize on cache");return 0};*#$({allowStale:i=this.allowStale}={}){if(this.#u)for(let n=this.#p;this.#F(n)&&((i||!this.#k(n))&&(yield n),n!==this.#y);)n=this.#b[n]}*#Z({allowStale:i=this.allowStale}={}){if(this.#u)for(let n=this.#y;this.#F(n)&&((i||!this.#k(n))&&(yield n),n!==this.#p);)n=this.#f[n]}#F(i){return i!==void 0&&this.#h.get(this.#d[i])===i}*entries(){for(let i of this.#$())this.#s[i]!==void 0&&this.#d[i]!==void 0&&!this.#l(this.#s[i])&&(yield[this.#d[i],this.#s[i]])}*rentries(){for(let i of this.#Z())this.#s[i]!==void 0&&this.#d[i]!==void 0&&!this.#l(this.#s[i])&&(yield[this.#d[i],this.#s[i]])}*keys(){for(let i of this.#$()){let n=this.#d[i];n!==void 0&&!this.#l(this.#s[i])&&(yield n)}}*rkeys(){for(let i of this.#Z()){let n=this.#d[i];n!==void 0&&!this.#l(this.#s[i])&&(yield n)}}*values(){for(let i of this.#$())this.#s[i]!==void 0&&!this.#l(this.#s[i])&&(yield this.#s[i])}*rvalues(){for(let i of this.#Z())this.#s[i]!==void 0&&!this.#l(this.#s[i])&&(yield this.#s[i])}[Symbol.iterator](){return this.entries()}[Symbol.toStringTag]="LRUCache";find(i,n={}){for(let o of this.#$()){let a=this.#s[o],t=this.#l(a)?a.__staleWhileFetching:a;if(t!==void 0&&i(t,this.#d[o],this))return this.#H(this.#d[o],n)}}forEach(i,n=this){for(let o of this.#$()){let a=this.#s[o],t=this.#l(a)?a.__staleWhileFetching:a;t!==void 0&&i.call(n,t,this.#d[o],this)}}rforEach(i,n=this){for(let o of this.#Z()){let a=this.#s[o],t=this.#l(a)?a.__staleWhileFetching:a;t!==void 0&&i.call(n,t,this.#d[o],this)}}purgeStale(){let i=!1;for(let n of this.#Z({allowStale:!0}))this.#k(n)&&(this.#J(this.#d[n],"expire"),i=!0);return i}info(i){let n=this.#h.get(i);if(n===void 0)return;let o=this.#s[n],a=this.#l(o)?o.__staleWhileFetching:o;if(a===void 0)return;let t={value:a};if(this.#w&&this.#C){let s=this.#w[n],r=this.#C[n];if(s&&r){let u=s-(this.#g.now()-r);t.ttl=u,t.start=Date.now()}}return this.#L&&(t.size=this.#L[n]),t}dump(){let i=[];for(let n of this.#$({allowStale:!0})){let o=this.#d[n],a=this.#s[n],t=this.#l(a)?a.__staleWhileFetching:a;if(t===void 0||o===void 0)continue;let s={value:t};if(this.#w&&this.#C){s.ttl=this.#w[n];let r=this.#g.now()-this.#C[n];s.start=Math.floor(Date.now()-r)}this.#L&&(s.size=this.#L[n]),i.unshift([o,s])}return i}load(i){this.clear();for(let[n,o]of i){if(o.start){let a=Date.now()-o.start;o.start=this.#g.now()-a}this.#T(n,o.value,o)}}set(i,n,o={}){let{status:a=Ie.hasSubscribers?{}:void 0}=o;o.status=a,a&&(a.op="set",a.key=i,n!==void 0&&(a.value=n),a.cache=this);let t=this.#T(i,n,o);return a&&Ie.hasSubscribers&&Ie.publish(a),t}#T(i,n,o,a){let{ttl:t=this.ttl,start:s,noDisposeOnSet:r=this.noDisposeOnSet,sizeCalculation:u=this.sizeCalculation,status:d}=o,l=this.#l(n);if(n===void 0)return d&&(d.set="deleted"),this.delete(i),this;let{noUpdateTTL:g=this.noUpdateTTL}=o;d&&!l&&(d.value=n);let h=this.#G(i,n,o.size||0,u,d);if(this.maxEntrySize&&h>this.maxEntrySize)return this.#J(i,"set"),d&&(d.set="miss",d.maxEntrySizeExceeded=!0),this;let c=this.#u===0?void 0:this.#h.get(i);if(c===void 0)c=this.#u===0?this.#p:this.#S.length!==0?this.#S.pop():this.#u===this.#n?this.#E(!1):this.#u,this.#d[c]=i,this.#s[c]=n,this.#h.set(i,c),this.#f[this.#p]=c,this.#b[c]=this.#p,this.#p=c,this.#u++,this.#N(c,h,d),d&&(d.set="add"),g=!1,this.#D&&!l&&this.#t?.(n,i,"add");else{this.#M(c);let p=this.#s[c];if(n!==p){if(!r)if(this.#l(p)){p!==a&&p.__abortController.abort(new Error("replaced"));let{__staleWhileFetching:f}=p;f!==void 0&&f!==n&&(this.#Y&&this.#e?.(f,i,"set"),this.#m&&this.#v?.push([f,i,"set"]))}else this.#Y&&this.#e?.(p,i,"set"),this.#m&&this.#v?.push([p,i,"set"]);if(this.#X(c),this.#N(c,h,d),this.#s[c]=n,!l){let f=p&&this.#l(p)?p.__staleWhileFetching:p,w=f===void 0?"add":n!==f?"replace":"update";d&&(d.set=w,f!==void 0&&(d.oldValue=f)),this.#D&&this.onInsert?.(n,i,w)}}else l||(d&&(d.set="update"),this.#D&&this.onInsert?.(n,i,"update"))}if(t!==0&&!this.#w&&this.#O(),this.#w&&(g||this.#A(c,t,s),d&&this.#x(d,c)),!r&&this.#m&&this.#v){let p=this.#v,f;for(;f=p?.shift();)this.#o?.(...f)}return this}pop(){try{for(;this.#u;){let i=this.#s[this.#y];if(this.#E(!0),this.#l(i)){if(i.__staleWhileFetching)return i.__staleWhileFetching}else if(i!==void 0)return i}}finally{if(this.#m&&this.#v){let i=this.#v,n;for(;n=i?.shift();)this.#o?.(...n)}}}#E(i){let n=this.#y,o=this.#d[n],a=this.#s[n],t=this.#l(a);t&&a.__abortController.abort(new Error("evicted"));let s=t?a.__staleWhileFetching:a;return(this.#Y||this.#m)&&s!==void 0&&(this.#Y&&this.#e?.(s,o,"evict"),this.#m&&this.#v?.push([s,o,"evict"])),this.#X(n),this.#j?.[n]&&(clearTimeout(this.#j[n]),this.#j[n]=void 0),i&&(this.#d[n]=void 0,this.#s[n]=void 0,this.#S.push(n)),this.#u===1?(this.#y=this.#p=0,this.#S.length=0):this.#y=this.#f[n],this.#h.delete(o),this.#u--,n}has(i,n={}){let{status:o=Ie.hasSubscribers?{}:void 0}=n;n.status=o,o&&(o.op="has",o.key=i,o.cache=this);let a=this.#z(i,n);return Ie.hasSubscribers&&Ie.publish(o),a}#z(i,n={}){let{updateAgeOnHas:o=this.updateAgeOnHas,status:a}=n,t=this.#h.get(i);if(t!==void 0){let s=this.#s[t];if(this.#l(s)&&s.__staleWhileFetching===void 0)return!1;if(this.#k(t))a&&(a.has="stale",this.#x(a,t));else return o&&this.#B(t),a&&(a.has="hit",this.#x(a,t)),!0}else a&&(a.has="miss");return!1}peek(i,n={}){let{status:o=yd()?{}:void 0}=n;o&&(o.op="peek",o.key=i,o.cache=this),n.status=o;let a=this.#K(i,n);return Ie.hasSubscribers&&Ie.publish(o),a}#K(i,n){let{status:o,allowStale:a=this.allowStale}=n,t=this.#h.get(i);if(t===void 0||!a&&this.#k(t)){o&&(o.peek=t===void 0?"miss":"stale");return}let s=this.#s[t],r=this.#l(s)?s.__staleWhileFetching:s;return o&&(r!==void 0?(o.peek="hit",o.value=r):o.peek="miss"),r}#R(i,n,o,a){let t=n===void 0?void 0:this.#s[n];if(this.#l(t))return t;let s=new AbortController,{signal:r}=o;r?.addEventListener("abort",()=>s.abort(r.reason),{signal:s.signal});let u={signal:s.signal,options:o,context:a},d=(f,w=!1)=>{let{aborted:v}=s.signal,j=o.ignoreFetchAbort&&f!==void 0,C=o.ignoreFetchAbort||!!(o.allowStaleOnFetchAbort&&f!==void 0);if(o.status&&(v&&!w?(o.status.fetchAborted=!0,o.status.fetchError=s.signal.reason,j&&(o.status.fetchAbortIgnored=!0)):o.status.fetchResolved=!0),v&&!j&&!w)return g(s.signal.reason,C);let y=c,k=this.#s[n];return(k===c||k===void 0&&j&&w)&&(f===void 0?y.__staleWhileFetching!==void 0?this.#s[n]=y.__staleWhileFetching:this.#J(i,"fetch"):(o.status&&(o.status.fetchUpdated=!0),this.#T(i,f,u.options,y))),f},l=f=>(o.status&&(o.status.fetchRejected=!0,o.status.fetchError=f),g(f,!1)),g=(f,w)=>{let{aborted:v}=s.signal,j=v&&o.allowStaleOnFetchAbort,C=j||o.allowStaleOnFetchRejection,y=C||o.noDeleteOnFetchRejection,k=c;if(this.#s[n]===c&&(!y||!w&&k.__staleWhileFetching===void 0?this.#J(i,"fetch"):j||(this.#s[n]=k.__staleWhileFetching)),C)return o.status&&k.__staleWhileFetching!==void 0&&(o.status.returnedStale=!0),k.__staleWhileFetching;if(k.__returned===k)throw f},h=(f,w)=>{let v=this.#a?.(i,t,u);s.signal.addEventListener("abort",()=>{(!o.ignoreFetchAbort||o.allowStaleOnFetchAbort)&&(f(void 0),o.allowStaleOnFetchAbort&&(f=j=>d(j,!0)))}),v&&v instanceof Promise?v.then(j=>f(j===void 0?void 0:j),w):v!==void 0&&f(v)};o.status&&(o.status.fetchDispatched=!0);let c=new Promise(h).then(d,l),p=Object.assign(c,{__abortController:s,__staleWhileFetching:t,__returned:void 0});return n===void 0?(this.#T(i,p,{...u.options,status:void 0}),n=this.#h.get(i)):this.#s[n]=p,p}#l(i){if(!this.#P)return!1;let n=i;return!!n&&n instanceof Promise&&n.hasOwnProperty("__staleWhileFetching")&&n.__abortController instanceof AbortController}fetch(i,n={}){let o=ba.hasSubscribers,{status:a=yd()?{}:void 0}=n;n.status=a,a&&n.context&&(a.context=n.context);let t=this.#Q(i,n);return a&&o&&(a.trace=!0,ba.tracePromise(()=>t,a).catch(()=>{})),t}async#Q(i,n={}){let{allowStale:o=this.allowStale,updateAgeOnGet:a=this.updateAgeOnGet,noDeleteOnStaleGet:t=this.noDeleteOnStaleGet,ttl:s=this.ttl,noDisposeOnSet:r=this.noDisposeOnSet,size:u=0,sizeCalculation:d=this.sizeCalculation,noUpdateTTL:l=this.noUpdateTTL,noDeleteOnFetchRejection:g=this.noDeleteOnFetchRejection,allowStaleOnFetchRejection:h=this.allowStaleOnFetchRejection,ignoreFetchAbort:c=this.ignoreFetchAbort,allowStaleOnFetchAbort:p=this.allowStaleOnFetchAbort,context:f,forceRefresh:w=!1,status:v,signal:j}=n;if(v&&(v.op="fetch",v.key=i,w&&(v.forceRefresh=!0),v.cache=this),!this.#P)return v&&(v.fetch="get"),this.#H(i,{allowStale:o,updateAgeOnGet:a,noDeleteOnStaleGet:t,status:v});let C={allowStale:o,updateAgeOnGet:a,noDeleteOnStaleGet:t,ttl:s,noDisposeOnSet:r,size:u,sizeCalculation:d,noUpdateTTL:l,noDeleteOnFetchRejection:g,allowStaleOnFetchRejection:h,allowStaleOnFetchAbort:p,ignoreFetchAbort:c,status:v,signal:j},y=this.#h.get(i);if(y===void 0){v&&(v.fetch="miss");let k=this.#R(i,y,C,f);return k.__returned=k}else{let k=this.#s[y];if(this.#l(k)){let M=o&&k.__staleWhileFetching!==void 0;return v&&(v.fetch="inflight",M&&(v.returnedStale=!0)),M?k.__staleWhileFetching:k.__returned=k}let S=this.#k(y);if(!w&&!S)return v&&(v.fetch="hit"),this.#M(y),a&&this.#B(y),v&&this.#x(v,y),k;let J=this.#R(i,y,C,f),T=J.__staleWhileFetching!==void 0&&o;return v&&(v.fetch=S?"stale":"refresh",T&&S&&(v.returnedStale=!0)),T?J.__staleWhileFetching:J.__returned=J}}forceFetch(i,n={}){let o=ba.hasSubscribers,{status:a=yd()?{}:void 0}=n;n.status=a,a&&n.context&&(a.context=n.context);let t=this.#q(i,n);return a&&o&&(a.trace=!0,ba.tracePromise(()=>t,a).catch(()=>{})),t}async#q(i,n={}){let o=await this.#Q(i,n);if(o===void 0)throw new Error("fetch() returned undefined");return o}memo(i,n={}){let{status:o=Ie.hasSubscribers?{}:void 0}=n;n.status=o,o&&(o.op="memo",o.key=i,n.context&&(o.context=n.context),o.cache=this);let a=this.#U(i,n);return o&&(o.value=a),Ie.hasSubscribers&&Ie.publish(o),a}#U(i,n={}){let o=this.#r;if(!o)throw new Error("no memoMethod provided to constructor");let{context:a,status:t,forceRefresh:s,...r}=n;t&&s&&(t.forceRefresh=!0);let u=this.#H(i,r),d=s||u===void 0;if(t&&(t.memo=d?"miss":"hit",d||(t.value=u)),!d)return u;let l=o(i,u,{options:r,context:a});return t&&(t.value=l),this.#T(i,l,r),l}get(i,n={}){let{status:o=Ie.hasSubscribers?{}:void 0}=n;n.status=o,o&&(o.op="get",o.key=i,o.cache=this);let a=this.#H(i,n);return o&&(a!==void 0&&(o.value=a),Ie.hasSubscribers&&Ie.publish(o)),a}#H(i,n={}){let{allowStale:o=this.allowStale,updateAgeOnGet:a=this.updateAgeOnGet,noDeleteOnStaleGet:t=this.noDeleteOnStaleGet,status:s}=n,r=this.#h.get(i);if(r===void 0){s&&(s.get="miss");return}let u=this.#s[r],d=this.#l(u);return s&&this.#x(s,r),this.#k(r)?d?(s&&(s.get="stale-fetching"),o&&u.__staleWhileFetching!==void 0?(s&&(s.returnedStale=!0),u.__staleWhileFetching):void 0):(t||this.#J(i,"expire"),s&&(s.get="stale"),o?(s&&(s.returnedStale=!0),u):void 0):(s&&(s.get=d?"fetching":"hit"),this.#M(r),a&&this.#B(r),d?u.__staleWhileFetching:u)}#W(i,n){this.#b[n]=i,this.#f[i]=n}#M(i){i!==this.#p&&(i===this.#y?this.#y=this.#f[i]:this.#W(this.#b[i],this.#f[i]),this.#W(this.#p,i),this.#p=i)}delete(i){return this.#J(i,"delete")}#J(i,n){Ie.hasSubscribers&&Ie.publish({op:"delete",delete:n,key:i,cache:this});let o=!1;if(this.#u!==0){let a=this.#h.get(i);if(a!==void 0)if(this.#j?.[a]&&(clearTimeout(this.#j?.[a]),this.#j[a]=void 0),o=!0,this.#u===1)this.#I(n);else{this.#X(a);let t=this.#s[a];if(this.#l(t)?t.__abortController.abort(new Error("deleted")):(this.#Y||this.#m)&&(this.#Y&&this.#e?.(t,i,n),this.#m&&this.#v?.push([t,i,n])),this.#h.delete(i),this.#d[a]=void 0,this.#s[a]=void 0,a===this.#p)this.#p=this.#b[a];else if(a===this.#y)this.#y=this.#f[a];else{let s=this.#b[a];this.#f[s]=this.#f[a];let r=this.#f[a];this.#b[r]=this.#b[a]}this.#u--,this.#S.push(a)}}if(this.#m&&this.#v?.length){let a=this.#v,t;for(;t=a?.shift();)this.#o?.(...t)}return o}clear(){return this.#I("delete")}#I(i){for(let n of this.#Z({allowStale:!0})){let o=this.#s[n];if(this.#l(o))o.__abortController.abort(new Error("deleted"));else{let a=this.#d[n];this.#Y&&this.#e?.(o,a,i),this.#m&&this.#v?.push([o,a,i])}}if(this.#h.clear(),this.#s.fill(void 0),this.#d.fill(void 0),this.#w&&this.#C){this.#w.fill(0),this.#C.fill(0);for(let n of this.#j??[])n!==void 0&&clearTimeout(n);this.#j?.fill(void 0)}if(this.#L&&this.#L.fill(0),this.#y=0,this.#p=0,this.#S.length=0,this.#c=0,this.#u=0,this.#m&&this.#v){let n=this.#v,o;for(;o=n?.shift();)this.#o?.(...o)}}};const N$=Object.defineProperty({__proto__:null,LRUCache:P$},Symbol.toStringTag,{value:"Module"}),E$=_g(N$);var fd,Ap;function R$(){if(Ap)return fd;Ap=1;const e=(...t)=>t.every(s=>s)?t.join(""):"",i=t=>t?encodeURIComponent(t):"",n=t=>t.toLowerCase().replace(/^\W+/g,"").replace(/(?<!\W)\W+$/,"").replace(/\//g,"").replace(/\W+/g,"-"),o={sshtemplate:({domain:t,user:s,project:r,committish:u})=>`git@${t}:${s}/${r}.git${e("#",u)}`,sshurltemplate:({domain:t,user:s,project:r,committish:u})=>`git+ssh://git@${t}/${s}/${r}.git${e("#",u)}`,edittemplate:({domain:t,user:s,project:r,committish:u,editpath:d,path:l})=>`https://${t}/${s}/${r}${e("/",d,"/",i(u||"HEAD"),"/",l)}`,browsetemplate:({domain:t,user:s,project:r,committish:u,treepath:d})=>`https://${t}/${s}/${r}${e("/",d,"/",i(u))}`,browsetreetemplate:({domain:t,user:s,project:r,committish:u,treepath:d,path:l,fragment:g,hashformat:h})=>`https://${t}/${s}/${r}/${d}/${i(u||"HEAD")}/${l}${e("#",h(g||""))}`,browseblobtemplate:({domain:t,user:s,project:r,committish:u,blobpath:d,path:l,fragment:g,hashformat:h})=>`https://${t}/${s}/${r}/${d}/${i(u||"HEAD")}/${l}${e("#",h(g||""))}`,docstemplate:({domain:t,user:s,project:r,treepath:u,committish:d})=>`https://${t}/${s}/${r}${e("/",u,"/",i(d))}#readme`,httpstemplate:({auth:t,domain:s,user:r,project:u,committish:d})=>`git+https://${e(t,"@")}${s}/${r}/${u}.git${e("#",d)}`,filetemplate:({domain:t,user:s,project:r,committish:u,path:d})=>`https://${t}/${s}/${r}/raw/${i(u||"HEAD")}/${d}`,shortcuttemplate:({type:t,user:s,project:r,committish:u})=>`${t}:${s}/${r}${e("#",u)}`,pathtemplate:({user:t,project:s,committish:r})=>`${t}/${s}${e("#",r)}`,bugstemplate:({domain:t,user:s,project:r})=>`https://${t}/${s}/${r}/issues`,hashformat:n},a={};a.github={protocols:["git:","http:","git+ssh:","git+https:","ssh:","https:"],domain:"github.com",treepath:"tree",blobpath:"blob",editpath:"edit",filetemplate:({auth:t,user:s,project:r,committish:u,path:d})=>`https://${e(t,"@")}raw.githubusercontent.com/${s}/${r}/${i(u||"HEAD")}/${d}`,gittemplate:({auth:t,domain:s,user:r,project:u,committish:d})=>`git://${e(t,"@")}${s}/${r}/${u}.git${e("#",d)}`,tarballtemplate:({domain:t,user:s,project:r,committish:u})=>`https://codeload.${t}/${s}/${r}/tar.gz/${i(u||"HEAD")}`,extract:t=>{let[,s,r,u,d]=t.pathname.split("/",5);if(!(u&&u!=="tree")&&(u||(d=t.hash.slice(1)),r&&r.endsWith(".git")&&(r=r.slice(0,-4)),!(!s||!r)))return{user:s,project:r,committish:d}}},a.bitbucket={protocols:["git+ssh:","git+https:","ssh:","https:"],domain:"bitbucket.org",treepath:"src",blobpath:"src",editpath:"?mode=edit",edittemplate:({domain:t,user:s,project:r,committish:u,treepath:d,path:l,editpath:g})=>`https://${t}/${s}/${r}${e("/",d,"/",i(u||"HEAD"),"/",l,g)}`,tarballtemplate:({domain:t,user:s,project:r,committish:u})=>`https://${t}/${s}/${r}/get/${i(u||"HEAD")}.tar.gz`,extract:t=>{let[,s,r,u]=t.pathname.split("/",4);if(!["get"].includes(u)&&(r&&r.endsWith(".git")&&(r=r.slice(0,-4)),!(!s||!r)))return{user:s,project:r,committish:t.hash.slice(1)}}},a.gitlab={protocols:["git+ssh:","git+https:","ssh:","https:"],domain:"gitlab.com",treepath:"tree",blobpath:"tree",editpath:"-/edit",tarballtemplate:({domain:t,user:s,project:r,committish:u})=>`https://${t}/api/v4/projects/${i(s+"/"+r)}/repository/archive.tar.gz?sha=${i(u||"HEAD")}`,extract:t=>{const s=t.pathname.slice(1);if(s.includes("/-/")||s.includes("/archive.tar.gz"))return;const r=s.split("/");let u=r.pop();u.endsWith(".git")&&(u=u.slice(0,-4));const d=r.join("/");if(!(!d||!u))return{user:d,project:u,committish:t.hash.slice(1)}}},a.gist={protocols:["git:","git+ssh:","git+https:","ssh:","https:"],domain:"gist.github.com",editpath:"edit",sshtemplate:({domain:t,project:s,committish:r})=>`git@${t}:${s}.git${e("#",r)}`,sshurltemplate:({domain:t,project:s,committish:r})=>`git+ssh://git@${t}/${s}.git${e("#",r)}`,edittemplate:({domain:t,user:s,project:r,committish:u,editpath:d})=>`https://${t}/${s}/${r}${e("/",i(u))}/${d}`,browsetemplate:({domain:t,project:s,committish:r})=>`https://${t}/${s}${e("/",i(r))}`,browsetreetemplate:({domain:t,project:s,committish:r,path:u,hashformat:d})=>`https://${t}/${s}${e("/",i(r))}${e("#",d(u))}`,browseblobtemplate:({domain:t,project:s,committish:r,path:u,hashformat:d})=>`https://${t}/${s}${e("/",i(r))}${e("#",d(u))}`,docstemplate:({domain:t,project:s,committish:r})=>`https://${t}/${s}${e("/",i(r))}`,httpstemplate:({domain:t,project:s,committish:r})=>`git+https://${t}/${s}.git${e("#",r)}`,filetemplate:({user:t,project:s,committish:r,path:u})=>`https://gist.githubusercontent.com/${t}/${s}/raw${e("/",i(r))}/${u}`,shortcuttemplate:({type:t,project:s,committish:r})=>`${t}:${s}${e("#",r)}`,pathtemplate:({project:t,committish:s})=>`${t}${e("#",s)}`,bugstemplate:({domain:t,project:s})=>`https://${t}/${s}`,gittemplate:({domain:t,project:s,committish:r})=>`git://${t}/${s}.git${e("#",r)}`,tarballtemplate:({project:t,committish:s})=>`https://codeload.github.com/gist/${t}/tar.gz/${i(s||"HEAD")}`,extract:t=>{let[,s,r,u]=t.pathname.split("/",4);if(u!=="raw"){if(!r){if(!s)return;r=s,s=null}return r.endsWith(".git")&&(r=r.slice(0,-4)),{user:s,project:r,committish:t.hash.slice(1)}}},hashformat:function(t){return t&&"file-"+n(t)}},a.sourcehut={protocols:["git+ssh:","https:"],domain:"git.sr.ht",treepath:"tree",blobpath:"tree",filetemplate:({domain:t,user:s,project:r,committish:u,path:d})=>`https://${t}/${s}/${r}/blob/${i(u)||"HEAD"}/${d}`,httpstemplate:({domain:t,user:s,project:r,committish:u})=>`https://${t}/${s}/${r}${e("#",u)}`,tarballtemplate:({domain:t,user:s,project:r,committish:u})=>`https://${t}/${s}/${r}/archive/${i(u)||"HEAD"}.tar.gz`,bugstemplate:()=>null,extract:t=>{let[,s,r,u]=t.pathname.split("/",4);if(!["archive"].includes(u)&&(r&&r.endsWith(".git")&&(r=r.slice(0,-4)),!(!s||!r)))return{user:s,project:r,committish:t.hash.slice(1)}}};for(const[t,s]of Object.entries(a))a[t]=Object.assign({},o,s);return fd=a,fd}var md,Gp;function fm(){if(Gp)return md;Gp=1;const e=(a,t,s)=>{const r=a.indexOf(s);return a.lastIndexOf(t,r>-1?r:1/0)},i=a=>{try{return new URL(a)}catch{}},n=(a,t)=>{const s=a.indexOf(":"),r=a.slice(0,s+1);if(Object.prototype.hasOwnProperty.call(t,r)||a.substr(s,3)==="://")return a;const u=a.indexOf("@");return u>-1?u>s?`git+ssh://${a}`:a:`${a.slice(0,s+1)}//${a.slice(s+1)}`},o=a=>{const t=e(a,"@","#"),s=e(a,":","#");return s>t&&(a=a.slice(0,s)+"/"+a.slice(s+1)),e(a,":","#")===-1&&a.indexOf("//")===-1&&(a=`git+ssh://${a}`),a};return md=(a,t)=>{const s=t?n(a,t):a;return i(s)||i(o(s))},md}var bd,Fp;function O$(){if(Fp)return bd;Fp=1;const e=fm(),i=n=>{const o=n.indexOf("#"),a=n.indexOf("/"),t=n.indexOf("/",a+1),s=n.indexOf(":"),r=/\s/.exec(n),u=n.indexOf("@"),d=!r||o>-1&&r.index>o,l=u===-1||o>-1&&u>o,g=s===-1||o>-1&&s>o,h=t===-1||o>-1&&t>o,c=a>0,p=o>-1?n[o-1]!=="/":!n.endsWith("/"),f=!n.startsWith(".");return d&&c&&p&&f&&l&&g&&h};return bd=(n,o,{gitHosts:a,protocols:t})=>{if(!n)return;const s=i(n)?`github:${n}`:n,r=e(s,t);if(!r)return;const u=a.byShortcut[r.protocol],d=a.byDomain[r.hostname.startsWith("www.")?r.hostname.slice(4):r.hostname],l=u||d;if(!l)return;const g=a[u||d];let h=null;t[r.protocol]?.auth&&(r.username||r.password)&&(h=`${r.username}${r.password?":"+r.password:""}`);let c=null,p=null,f=null,w=null;try{if(u){let v=r.pathname.startsWith("/")?r.pathname.slice(1):r.pathname;const j=v.indexOf("@");j>-1&&(v=v.slice(j+1));const C=v.lastIndexOf("/");C>-1?(p=decodeURIComponent(v.slice(0,C)),p||(p=null),f=decodeURIComponent(v.slice(C+1))):f=decodeURIComponent(v),f.endsWith(".git")&&(f=f.slice(0,-4)),r.hash&&(c=decodeURIComponent(r.hash.slice(1))),w="shortcut"}else{if(!g.protocols.includes(r.protocol))return;const v=g.extract(r);if(!v)return;p=v.user&&decodeURIComponent(v.user),f=decodeURIComponent(v.project),c=decodeURIComponent(v.committish),w=t[r.protocol]?.name||r.protocol.slice(0,-1)}}catch(v){if(v instanceof URIError)return;throw v}return[l,p,h,f,c,w,o]},bd}var wd,Qp;function A$(){if(Qp)return wd;Qp=1;const{LRUCache:e}=E$,i=R$(),n=O$(),o=fm(),a=new e({max:1e3});function t(r){try{const{protocol:u,hostname:d,pathname:l}=new URL(r);if(!d)return null;const g=/(?:git\+)http:$/.test(u)?"http:":"https:",h=l.replace(/\.git$/,"");return`${g}//${d}${h}`}catch{return null}}class s{constructor(u,d,l,g,h,c,p={}){Object.assign(this,s.#n[u],{type:u,user:d,auth:l,project:g,committish:h,default:c,opts:p})}static#n={byShortcut:{},byDomain:{}};static#i={"git+ssh:":{name:"sshurl"},"ssh:":{name:"sshurl"},"git+https:":{name:"https",auth:!0},"git:":{auth:!0},"http:":{auth:!0},"https:":{auth:!0},"git+http:":{auth:!0}};static addHost(u,d){s.#n[u]=d,s.#n.byDomain[d.domain]=u,s.#n.byShortcut[`${u}:`]=u,s.#i[`${u}:`]={name:u}}static fromUrl(u,d){if(typeof u!="string")return;const l=u+JSON.stringify(d||{});if(!a.has(l)){const g=n(u,d,{gitHosts:s.#n,protocols:s.#i});a.set(l,g?new s(...g):void 0)}return a.get(l)}static fromManifest(u,d={}){if(!u||typeof u!="object")return;const l=u.repository,g=l&&(typeof l=="string"?l:typeof l=="object"&&typeof l.url=="string"?l.url:null);if(!g)throw new Error("no repository");const h=g&&s.fromUrl(g.replace(/^git\+/,""),d)||null;if(h)return h;const c=t(g);return s.fromUrl(c,d)||c}static parseUrl(u){return o(u)}#e(u,d){if(typeof u!="function")return null;const l={...this,...this.opts,...d};l.path||(l.path=""),l.path.startsWith("/")&&(l.path=l.path.slice(1)),l.noCommittish&&(l.committish=null);const g=u(l);return l.noGitPlus&&g.startsWith("git+")?g.slice(4):g}hash(){return this.committish?`#${this.committish}`:""}ssh(u){return this.#e(this.sshtemplate,u)}sshurl(u){return this.#e(this.sshurltemplate,u)}browse(u,...d){return typeof u!="string"?this.#e(this.browsetemplate,u):typeof d[0]!="string"?this.#e(this.browsetreetemplate,{...d[0],path:u}):this.#e(this.browsetreetemplate,{...d[1],fragment:d[0],path:u})}browseFile(u,...d){return typeof d[0]!="string"?this.#e(this.browseblobtemplate,{...d[0],path:u}):this.#e(this.browseblobtemplate,{...d[1],fragment:d[0],path:u})}docs(u){return this.#e(this.docstemplate,u)}bugs(u){return this.#e(this.bugstemplate,u)}https(u){return this.#e(this.httpstemplate,u)}git(u){return this.#e(this.gittemplate,u)}shortcut(u){return this.#e(this.shortcuttemplate,u)}path(u){return this.#e(this.pathtemplate,u)}tarball(u){return this.#e(this.tarballtemplate,{...u,noCommittish:!1})}file(u,d){return this.#e(this.filetemplate,{...d,path:u})}edit(u,d){return this.#e(this.edittemplate,{...d,path:u})}getDefaultRepresentation(){return this.default}toString(u){return this.default&&typeof this[this.default]=="function"?this[this.default](u):this.sshurl(u)}}for(const[r,u]of Object.entries(i))s.addHost(r,u);return wd=s,wd}var jd,Wp;function G$(){if(Wp)return jd;Wp=1,jd=e;function e(i){if(!i||i==="ERROR: No README data found!")return;i=i.trim().split(`
6
+ `);let n=0;for(;i[n]&&i[n].trim().match(/^(#|$)/);)n++;const o=i.length;let a=n+1;for(;a<o&&i[a].trim();)a++;return i.slice(n,a).join(" ").trim()}return jd}var mm={dependancies:"dependencies",dependecies:"dependencies",depdenencies:"dependencies",devEependencies:"devDependencies",depends:"dependencies","dev-dependencies":"devDependencies",devDependences:"devDependencies",devDepenencies:"devDependencies",devdependencies:"devDependencies",repostitory:"repository",repo:"repository",prefereGlobal:"preferGlobal",hompage:"homepage",hampage:"homepage",autohr:"author",autor:"author",contributers:"contributors",publicationConfig:"publishConfig",script:"scripts"},bm={web:"url",name:"url"},wm={server:"start",tests:"test"};const F$={topLevel:mm,bugs:bm,script:wm},Q$=Object.defineProperty({__proto__:null,bugs:bm,default:F$,script:wm,topLevel:mm},Symbol.toStringTag,{value:"Module"}),W$=_g(Q$);var kd,Ip;function I$(){if(Ip)return kd;Ip=1;var{URL:e}=qf,i=gY(),n=hY(),o=D$(),a=A$(),{isBuiltin:t}=Qf,s=["dependencies","devDependencies","optionalDependencies"],r=G$(),u=W$,d=y=>y.includes("@")&&y.indexOf("@")<y.lastIndexOf(".");kd={warn:function(){},fixRepositoryField:function(y){if(y.repositories&&(this.warn("repositories"),y.repository=y.repositories[0]),!y.repository)return this.warn("missingRepository");typeof y.repository=="string"&&(y.repository={type:"git",url:y.repository});var k=y.repository.url||"";if(k){var S=a.fromUrl(k);S&&(k=y.repository.url=S.getDefaultRepresentation()==="shortcut"?S.https():S.toString())}k.match(/github.com\/[^/]+\/[^/]+\.git\.git$/)&&this.warn("brokenGitUrl",k)},fixTypos:function(y){Object.keys(u.topLevel).forEach(function(k){Object.prototype.hasOwnProperty.call(y,k)&&this.warn("typo",k,u.topLevel[k])},this)},fixScriptsField:function(y){if(y.scripts){if(typeof y.scripts!="object"){this.warn("nonObjectScripts"),delete y.scripts;return}Object.keys(y.scripts).forEach(function(k){typeof y.scripts[k]!="string"?(this.warn("nonStringScript"),delete y.scripts[k]):u.script[k]&&!y.scripts[u.script[k]]&&this.warn("typo",k,u.script[k],"scripts")},this)}},fixFilesField:function(y){var k=y.files;k&&!Array.isArray(k)?(this.warn("nonArrayFiles"),delete y.files):y.files&&(y.files=y.files.filter(function(S){return!S||typeof S!="string"?(this.warn("invalidFilename",S),!1):!0},this))},fixBinField:function(y){if(y.bin&&typeof y.bin=="string"){var k={},S;(S=y.name.match(/^@[^/]+[/](.*)$/))?k[S[1]]=y.bin:k[y.name]=y.bin,y.bin=k}},fixManField:function(y){y.man&&typeof y.man=="string"&&(y.man=[y.man])},fixBundleDependenciesField:function(y){var k="bundledDependencies",S="bundleDependencies";y[k]&&!y[S]&&(y[S]=y[k],delete y[k]),y[S]&&!Array.isArray(y[S])?(this.warn("nonArrayBundleDependencies"),delete y[S]):y[S]&&(y[S]=y[S].filter(function(J){return!J||typeof J!="string"?(this.warn("nonStringBundleDependency",J),!1):(y.dependencies||(y.dependencies={}),Object.prototype.hasOwnProperty.call(y.dependencies,J)||(this.warn("nonDependencyBundleDependency",J),y.dependencies[J]="*"),!0)},this))},fixDependencies:function(y){j(y,this.warn),w(y),this.fixBundleDependenciesField(y),["dependencies","devDependencies"].forEach(function(k){if(k in y){if(!y[k]||typeof y[k]!="object"){this.warn("nonObjectDependencies",k),delete y[k];return}Object.keys(y[k]).forEach(function(S){var J=y[k][S];typeof J!="string"&&(this.warn("nonStringDependency",S,JSON.stringify(J)),delete y[k][S]);var T=a.fromUrl(y[k][S]);T&&(y[k][S]=T.toString())},this)}},this)},fixModulesField:function(y){y.modules&&(this.warn("deprecatedModules"),delete y.modules)},fixKeywordsField:function(y){typeof y.keywords=="string"&&(y.keywords=y.keywords.split(/,\s+/)),y.keywords&&!Array.isArray(y.keywords)?(delete y.keywords,this.warn("nonArrayKeywords")):y.keywords&&(y.keywords=y.keywords.filter(function(k){return typeof k!="string"||!k?(this.warn("nonStringKeyword"),!1):!0},this))},fixVersionField:function(y,k){var S=!k;if(!y.version)return y.version="",!0;if(!i(y.version,S))throw new Error('Invalid version: "'+y.version+'"');return y.version=n(y.version,S),!0},fixPeople:function(y){c(y,p),c(y,f)},fixNameField:function(y,k){typeof k=="boolean"?k={strict:k}:typeof k>"u"&&(k={});var S=k.strict;if(!y.name&&!S){y.name="";return}if(typeof y.name!="string")throw new Error("name field must be a string.");S||(y.name=y.name.trim()),h(y.name,S,k.allowLegacyCase),t(y.name)&&this.warn("conflictingName",y.name)},fixDescriptionField:function(y){y.description&&typeof y.description!="string"&&(this.warn("nonStringDescription"),delete y.description),y.readme&&!y.description&&(y.description=r(y.readme)),y.description===void 0&&delete y.description,y.description||this.warn("missingDescription")},fixReadmeField:function(y){y.readme||(this.warn("missingReadme"),y.readme="ERROR: No README data found!")},fixBugsField:function(y){if(!y.bugs&&y.repository&&y.repository.url){var k=a.fromUrl(y.repository.url);k&&k.bugs()&&(y.bugs={url:k.bugs()})}else if(y.bugs){if(typeof y.bugs=="string")d(y.bugs)?y.bugs={email:y.bugs}:e.canParse(y.bugs)?y.bugs={url:y.bugs}:this.warn("nonEmailUrlBugsString");else{C(y.bugs,this.warn);var S=y.bugs;y.bugs={},S.url&&(e.canParse(S.url)?y.bugs.url=S.url:this.warn("nonUrlBugsUrlField")),S.email&&(typeof S.email=="string"&&d(S.email)?y.bugs.email=S.email:this.warn("nonEmailBugsEmailField"))}!y.bugs.email&&!y.bugs.url&&(delete y.bugs,this.warn("emptyNormalizedBugs"))}},fixHomepageField:function(y){if(!y.homepage&&y.repository&&y.repository.url){var k=a.fromUrl(y.repository.url);k&&k.docs()&&(y.homepage=k.docs())}if(y.homepage){if(typeof y.homepage!="string")return this.warn("nonUrlHomepage"),delete y.homepage;e.canParse(y.homepage)||(y.homepage="http://"+y.homepage)}},fixLicenseField:function(y){const k=y.license||y.licence;if(!k)return this.warn("missingLicense");if(typeof k!="string"||k.length<1||k.trim()==="")return this.warn("invalidLicense");if(!o(k).validForNewPackages)return this.warn("invalidLicense")}};function l(y){if(y.charAt(0)!=="@")return!1;var k=y.slice(1).split("/");return k.length!==2?!1:k[0]&&k[1]&&k[0]===encodeURIComponent(k[0])&&k[1]===encodeURIComponent(k[1])}function g(y){return!y.match(/[/@\s+%:]/)&&y===encodeURIComponent(y)}function h(y,k,S){if(y.charAt(0)==="."||!(l(y)||g(y))||k&&!S&&y!==y.toLowerCase()||y.toLowerCase()==="node_modules"||y.toLowerCase()==="favicon.ico")throw new Error("Invalid name: "+JSON.stringify(y))}function c(y,k){return y.author&&(y.author=k(y.author)),["maintainers","contributors"].forEach(function(S){Array.isArray(y[S])&&(y[S]=y[S].map(k))}),y}function p(y){if(typeof y=="string")return y;var k=y.name||"",S=y.url||y.web,J=S?" ("+S+")":"",T=y.email||y.mail,M=T?" <"+T+">":"";return k+M+J}function f(y){if(typeof y!="string")return y;var k=y.match(/^([^(<]+)/),S=y.match(/\(([^()]+)\)/),J=y.match(/<([^<>]+)>/),T={};return k&&k[0].trim()&&(T.name=k[0].trim()),J&&(T.email=J[1]),S&&(T.url=S[1]),T}function w(y){var k=y.optionalDependencies;if(k){var S=y.dependencies||{};Object.keys(k).forEach(function(J){S[J]=k[J]}),y.dependencies=S}}function v(y,k,S){if(!y)return{};if(typeof y=="string"&&(y=y.trim().split(/[\n\r\s\t ,]+/)),!Array.isArray(y))return y;S("deprecatedArrayDependencies",k);var J={};return y.filter(function(T){return typeof T=="string"}).forEach(function(T){T=T.trim().split(/(:?[@\s><=])/);var M=T.shift(),he=T.join("");he=he.trim(),he=he.replace(/^@/,""),J[M]=he}),J}function j(y,k){s.forEach(function(S){y[S]&&(y[S]=v(y[S],S,k))})}function C(y,k){y&&Object.keys(y).forEach(function(S){u.bugs[S]&&(k("typo",S,u.bugs[S],"bugs"),y[u.bugs[S]]=y[S],delete y[S])})}return kd}var jm="'repositories' (plural) Not supported. Please pick one as the 'repository' field",km="No repository field.",Sm="Probably broken git url: %s",Lm="scripts must be an object",Cm="script values must be string commands",Ym="Invalid 'files' member",$m="Invalid filename in 'files' list: %s",Zm="Invalid 'bundleDependencies' list. Must be array of package names",Jm="Invalid bundleDependencies member: %s",xm="Non-dependency in bundleDependencies: %s",Tm="%s field must be an object",Dm="Invalid dependency: %s %s",Bm="specifying %s as array is deprecated",Xm="modules field is deprecated",Hm="keywords should be an array of strings",Mm="keywords should be an array of strings",Pm="%s is also the name of a node core module.",Nm="'description' field should be a string",Em="No description",Rm="No README data",Om="No license field.",Am="Bug string field must be url, email, or {email,url}",Gm="bugs.url field must be a string url. Deleted.",Fm="bugs.email field must be a string email. Deleted.",Qm="Normalized value of bugs field is an empty object. Deleted.",Wm="homepage field must be a string url. Deleted.",Im="license should be a valid SPDX license expression",_m="%s should probably be %s.";const _$={repositories:jm,missingRepository:km,brokenGitUrl:Sm,nonObjectScripts:Lm,nonStringScript:Cm,nonArrayFiles:Ym,invalidFilename:$m,nonArrayBundleDependencies:Zm,nonStringBundleDependency:Jm,nonDependencyBundleDependency:xm,nonObjectDependencies:Tm,nonStringDependency:Dm,deprecatedArrayDependencies:Bm,deprecatedModules:Xm,nonArrayKeywords:Hm,nonStringKeyword:Mm,conflictingName:Pm,nonStringDescription:Nm,missingDescription:Em,missingReadme:Rm,missingLicense:Om,nonEmailUrlBugsString:Am,nonUrlBugsUrlField:Gm,nonEmailBugsEmailField:Fm,emptyNormalizedBugs:Qm,nonUrlHomepage:Wm,invalidLicense:Im,typo:_m},z$=Object.defineProperty({__proto__:null,brokenGitUrl:Sm,conflictingName:Pm,default:_$,deprecatedArrayDependencies:Bm,deprecatedModules:Xm,emptyNormalizedBugs:Qm,invalidFilename:$m,invalidLicense:Im,missingDescription:Em,missingLicense:Om,missingReadme:Rm,missingRepository:km,nonArrayBundleDependencies:Zm,nonArrayFiles:Ym,nonArrayKeywords:Hm,nonDependencyBundleDependency:xm,nonEmailBugsEmailField:Fm,nonEmailUrlBugsString:Am,nonObjectDependencies:Tm,nonObjectScripts:Lm,nonStringBundleDependency:Jm,nonStringDependency:Dm,nonStringDescription:Nm,nonStringKeyword:Mm,nonStringScript:Cm,nonUrlBugsUrlField:Gm,nonUrlHomepage:Wm,repositories:jm,typo:_m},Symbol.toStringTag,{value:"Module"}),K$=_g(z$);var Sd,_p;function q$(){if(_p)return Sd;_p=1;var e=cY,i=K$;Sd=function(){var o=Array.prototype.slice.call(arguments,0),a=o.shift();if(a==="typo")return n.apply(null,o);var t=i[a]?i[a]:a+": '%s'";return o.unshift(t),e.format.apply(null,o)};function n(o,a,t){return t&&(o=t+"['"+o+"']",a=t+"['"+a+"']"),e.format(i.typo,o,a)}return Sd}var Ld,zp;function U$(){if(zp)return Ld;zp=1,Ld=t;var e=I$();t.fixer=e;var i=q$(),n=["name","version","description","repository","modules","scripts","files","bin","man","bugs","keywords","readme","homepage","license"],o=["dependencies","people","typos"],a=n.map(function(r){return s(r)+"Field"});a=a.concat(o);function t(r,u,d){u===!0&&(u=null,d=!0),d||(d=!1),(!u||r.private)&&(u=function(){}),r.scripts&&r.scripts.install==="node-gyp rebuild"&&!r.scripts.preinstall&&(r.gypfile=!0),e.warn=function(){u(i.apply(null,arguments))},a.forEach(function(l){e["fix"+s(l)](r,d)}),r._id=r.name+"@"+r.version}function s(r){return r.charAt(0).toUpperCase()+r.slice(1)}return Ld}U$();const V$=wn(import.meta.url),jt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,Kg=e=>{if(typeof jt<"u"&&jt.versions&&jt.versions.node){const[i,n]=jt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return jt.getBuiltinModule(e)}return V$(e)};Kg("node:fs");Kg("node:readline");Kg("node:util");const eZ={argument:{description:"Target selector (same syntax as `vis run`): `build`, `:build`, `~:test`, `#tag:lint`, …",name:"selector",type:String},description:"Show the execution plan for a target without running it",examples:[["vis action-graph build","Print the task plan for `build` on every project"],["vis action-graph :test","Moon-style selector"],["vis action-graph build --json","Emit a JSON description of the plan"],['vis action-graph lint --query "tag=frontend"',"Filter projects by query"]],group:"Workspace",loader:()=>import("./handler2.js"),name:"action-graph",options:[{defaultValue:!1,description:"Emit JSON instead of ASCII",name:"json",type:Boolean},{description:"Filter matched projects by a query",name:"query",type:String}]},iZ={argument:{description:"Packages to add (e.g., react react-dom)",name:"packages",type:String},description:"Add packages using the detected package manager",examples:[["vis add react react-dom","Add packages"],["vis add -D typescript @types/react","Add as dev dependencies"],["vis add react --filter app","Add to specific workspace package"],["vis add react --to web","Add to one package, auto-conforming the version to existing catalogs / sibling deps"],["vis add -g typescript","Add globally (uses npm)"],["vis add lodash -w","Add to workspace root"],["vis add lodash --no-socket-check","Add without Socket.dev check"],["vis add lodash --no-typosquat-check","Skip typosquat name check"],["vis add lodash --no-marshall-check","Skip the offline marshall pipeline (author, downloads, etc.)"],["vis add lodash --run-scripts","Run lifecycle scripts (opts out of vis's default block-by-default policy)"]],group:"Dependencies",loader:()=>import("./handler15.js"),name:"add",options:[{alias:"D",defaultValue:!1,description:"Add as dev dependency",name:"save-dev",type:Boolean},{alias:"E",defaultValue:!1,description:"Save exact version",name:"exact",type:Boolean},{alias:"P",defaultValue:!1,description:"Add as peer dependency",name:"save-peer",type:Boolean},{alias:"O",defaultValue:!1,description:"Add as optional dependency",name:"save-optional",type:Boolean},{alias:"g",defaultValue:!1,description:"Install globally (uses npm)",name:"global",type:Boolean},{alias:"w",defaultValue:!1,description:"Add to workspace root",name:"workspace-root",type:Boolean},{defaultValue:!1,description:"Use workspace protocol (pnpm)",name:"workspace",type:Boolean},{alias:"F",description:"Filter by workspace package name",multiple:!0,name:"filter",type:String},{description:"Target a single workspace package and auto-conform the version to existing catalogs / sibling deps (syncpack#285)",name:"to",type:String},{defaultValue:!1,description:"Skip typosquat name check before adding",name:"no-typosquat-check",type:Boolean},{defaultValue:!1,description:"Skip Socket.dev security check before adding",name:"no-socket-check",type:Boolean},{defaultValue:!1,description:"Skip the offline marshall pipeline (author, provenance, metadata, downloads, expired-domains, new-bin, signatures, archived-repo)",name:"no-marshall-check",type:Boolean},{defaultValue:!1,description:"Run lifecycle scripts during add (opts out of vis's default block-by-default policy; allowlisted packages run via security.policies.installScripts.allow)",name:"run-scripts",type:Boolean},{defaultValue:!1,description:"After adding, recursively install non-optional peer dependencies that aren't already in the workspace (matches nypm's installPeerDependencies)",name:"auto-install-peers",type:Boolean}]},qg={description:"Override the cache DB path (defaults to <cache>/vis/advisories/db.sqlite via @visulima/find-cache-dir).",name:"db",type:String},ks={description:"Output format: table (default) or json.",name:"format",type:String},nZ={commandPath:["advisories"],description:"Download and ingest one or more OSV ecosystem dumps into the local cache",examples:[["vis advisories sync","Sync the npm ecosystem (default)"],["vis advisories sync --ecosystem npm","Sync a single explicit ecosystem"],["vis advisories sync --ecosystem npm,PyPI","Sync several ecosystems in one pass"],["vis advisories sync --force","Re-download even when the ETag matches"],["vis advisories sync --source https://mirror.example.com","Use a corporate OSV mirror (must be in allowedHosts)"]],group:"Security & Health",loader:le(()=>import("./sync.js"),"advisoriesSyncExecute"),name:"sync",options:[{description:"Comma-separated list of ecosystems to sync (default: npm).",name:"ecosystem",type:String},{defaultValue:!1,description:"Re-download and re-ingest even if the upstream ETag is unchanged.",name:"force",type:Boolean},{description:"Override the advisory source URL. Must be https and resolve to an allowed host.",name:"source",type:String},qg,ks]},oZ={commandPath:["advisories"],description:"Print the local advisory DB summary: path, schema version, ecosystems, row counts, last sync, ETag",examples:[["vis advisories status","Human-readable summary"],["vis advisories status --format json","Machine-readable for CI freshness checks"]],group:"Security & Health",loader:le(()=>import("./status.js"),"advisoriesStatusExecute"),name:"status",options:[qg,ks]},aZ={commandPath:["advisories"],description:"Delete the local advisory DB. The next `vis audit --offline` will fail until you re-sync",examples:[["vis advisories prune","Confirm and delete the local DB"],["vis advisories prune --force","Delete without confirmation"]],group:"Security & Health",loader:le(()=>import("./prune.js"),"advisoriesPruneExecute"),name:"prune",options:[qg,{defaultValue:!1,description:"Skip the confirmation prompt.",name:"force",type:Boolean},ks]},zm={description:"Override the bloom cache directory (defaults to <cache>/vis/osv-bloom/).",name:"cache-dir",type:String},tZ={commandPath:["advisories","bloom"],description:"Fetch and verify the endevco/osv-bloom MAL-* prefilter into the local cache",examples:[["vis advisories bloom sync","Fetch the bloom filter from the default upstream"],["vis advisories bloom sync --force","Re-download even when the set digest matches"],["vis advisories bloom sync --source https://bloom.example.com","Use an internal mirror (must be in allowedHosts)"]],group:"Security & Health",loader:le(()=>import("./bloom-sync.js"),"advisoriesBloomSyncExecute"),name:"sync",options:[{defaultValue:!1,description:"Re-download and re-verify even when the upstream set digest is unchanged.",name:"force",type:Boolean},{description:"Override the bloom source URL. Must be https and resolve to an allowed host.",name:"source",type:String},zm,ks]},sZ={commandPath:["advisories","bloom"],description:"Print the local osv-bloom cache freshness: built-at, filter size, m/k parameters, set digest",examples:[["vis advisories bloom status","Human-readable summary"],["vis advisories bloom status --format json","Machine-readable for CI freshness checks"]],group:"Security & Health",loader:le(()=>import("./bloom-status.js"),"advisoriesBloomStatusExecute"),name:"status",options:[zm,ks]},rZ=[nZ,oZ,aZ,tZ,sZ],uZ={argument:{description:"The target to run (e.g., build, test, lint)",name:"target",type:String},description:"Run a target only on projects affected by recent changes",examples:[["vis affected build","Run build on affected projects"],["vis affected test --base=main","Run tests on projects changed since main"],["vis affected destroy --reverse","Tear down affected projects leaves-first"],["vis affected build --sparse-checkout","Print a git sparse-checkout cone set for the affected projects and exit"]],group:"Run & Execute",loader:()=>import("./handler3.js"),name:"affected",options:[{description:"Git base ref for comparison. When omitted, vis auto-resolves it from the active CI provider (GitHub/GitLab/Buildkite/CircleCI) or falls back to `git merge-base HEAD origin/<defaultBase>` locally. Default base branch comes from `vis.config.ts#defaultBase` (or `main`).",name:"base",type:String},{description:"Git head ref for comparison. When omitted, auto-resolves from CI env (e.g. `$GITHUB_SHA`) or defaults to `HEAD`.",name:"head",type:String},{defaultValue:"deep",description:'Downstream scope: "none", "direct", or "deep" — controls how far to include dependents of changed projects',name:"downstream",type:String},{defaultValue:"none",description:'Upstream scope: "none", "direct", or "deep" — controls how far to include dependencies of changed projects',name:"upstream",type:String},{defaultValue:3,description:"Maximum number of parallel tasks",name:"parallel",type:Number},{defaultValue:!0,description:"Enable caching (use --no-cache to disable)",name:"cache",type:Boolean},{defaultValue:!1,description:"Show what would run without executing",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Instead of running, print the affected project roots as a git sparse-checkout cone set (one path per line) and exit. Pipe into `git sparse-checkout set --stdin` to shrink huge-monorepo CI checkouts.",name:"sparse-checkout",type:Boolean},{description:'Partition tasks for distributed CI (e.g., "1/4" for first of four runners). Falls back to VIS_PARTITION env var.',name:"partition",type:String},{description:"Filter affected projects by a query (e.g. 'language=typescript && tag=lib')",name:"query",type:String},{defaultValue:!1,description:"Run the dependency graph in reverse (leaves first, then their dependents). Useful for teardown targets like `destroy`/`undeploy` where dependents must run before the things they depend on.",name:"reverse",type:Boolean},{description:"Comma-separated tags this runner advertises (e.g. 'gpu,slow'). Forwarded verbatim to the downstream `vis run` so capability-gated tasks resolve identically. Falls back to VIS_RUNNER_TAGS env var.",name:"runner-tags",type:String}]},Km={description:"Output format: table or json (default: table)",name:"format",type:String},dZ={commandPath:["ai"],description:"List detected AI providers and show which one is selected",examples:[["vis ai providers","List all AI providers and their status"],["vis ai providers --format json","Output as JSON"]],group:"System",loader:le(()=>import("./handler50.js"),"aiProvidersExecute"),name:"providers",options:[Km]},lZ={commandPath:["ai"],description:"Test the best available AI provider with a quick prompt",examples:[["vis ai test","Test the selected provider"]],group:"System",loader:le(()=>import("./handler50.js"),"aiTestExecute"),name:"test",options:[]},gZ={argument:{description:"Task ID to propose a fix for (e.g. @my/app:build)",name:"taskId",type:String},commandPath:["ai"],description:"Read a failed task's logs and propose a structured patch (Phase 1: local-only, no git)",examples:[["vis ai fix @myorg/app:build","Print proposed patch for the failed task"],["vis ai fix @myorg/app:build --apply","Apply the patch to disk after confirming"],["vis ai fix @myorg/app:build --format json","Machine-readable patch output"],["vis ai fix @myorg/app:build --run 2026-04-28T...","Inspect a specific historical run"]],group:"System",loader:le(()=>import("./handler50.js"),"aiFixExecute"),name:"fix",options:[Km,{description:"Use a specific run ID from .vis/runs/ instead of the latest run",name:"run",type:String},{defaultValue:!1,description:"Apply the proposed patch to disk after printing it",name:"apply",type:Boolean},{defaultValue:!1,description:"Bypass the AI response cache",name:"no-cache",type:Boolean},{defaultValue:!1,description:"Skip the confirmation prompt before applying",name:"yes",type:Boolean}]},hZ={description:"AI-assisted commands: provider detection and failure-fix proposals (cache management lives under `vis cache`)",examples:[["vis ai","List all AI subcommands"],["vis ai discover-help","Machine-readable subcommand catalogue (for AI agents)"]],group:"System",loader:le(()=>import("./handler50.js"),"aiRootExecute"),name:"ai",options:[]},cZ={commandPath:["ai"],description:"Print the machine-readable AI subcommand catalogue (JSON to stdout, designed for AI agents)",examples:[["vis ai discover-help","Emit the discovery payload as JSON"],["vis ai discover-help | jq '.subcommands[].path'","List all available paths"]],group:"System",loader:le(()=>import("./handler50.js"),"aiDiscoverHelpExecute"),name:"discover-help",options:[]},pZ={commandPath:["ai"],description:"Diagnose the most recent failed task and post a structured patch as a PR/MR comment (or Buildkite annotation)",examples:[["vis ai heal","Heal the most recent failure"],["vis ai heal --dry-run","Propose a patch but skip apply / validate / post"],["vis ai heal --run 2026-04-28T...","Heal a specific historical run"]],group:"System",loader:le(()=>import("./heal.js").then(e=>e.h),"aiHeal"),name:"heal",options:[{defaultValue:!1,description:"Show the proposal and exit without applying or posting it",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Bypass the AI response cache",name:"no-cache",type:Boolean},{description:"Use a specific run ID from .vis/runs/ instead of the latest run",name:"run",type:String},{description:"Per-task validation timeout in seconds (default: 1800)",name:"validation-timeout",type:Number}]},vZ={commandPath:["ai","heal"],description:"Re-run the proposed fix and commit it to the PR/MR branch when validation passes",examples:[["vis ai heal accept","Triggered automatically by a `/vis heal accept` PR comment (GitHub/GitLab) or a Buildkite block-step unblock"]],group:"System",loader:le(()=>import("./heal-accept.js"),"aiHealAccept"),name:"accept",options:[{description:"Use a specific run ID from .vis/runs/ instead of the latest run",name:"run",type:String},{description:"Per-task validation timeout in seconds (default: 1800)",name:"validation-timeout",type:Number}]},qm=[hZ,cZ,dZ,lZ,gZ,pZ,vZ],TSe=Object.defineProperty({__proto__:null,default:qm},Symbol.toStringTag,{value:"Module"}),yZ={argument:{description:"Package name to analyze (e.g., react)",name:"package",required:!0,type:String},description:"Analyze a single package update with AI",examples:[["vis analyze react","Analyze updating react to latest"],["vis analyze react 19.0.0","Analyze updating react to specific version"],["vis analyze react --ai-type security","Run security-focused analysis"],["vis analyze react --format json","Output as JSON"]],group:"System",loader:()=>import("./handler4.js"),name:"analyze",options:[{description:"AI analysis type: impact, security, compatibility, or recommend (default: impact)",name:"ai-type",type:String},{defaultValue:!1,description:"Check for known security vulnerabilities",name:"security",type:Boolean},{description:"Output format: table or json (default: table)",name:"format",type:String}]},fZ={description:"Review and approve dependencies with build scripts",examples:[["vis approve-builds","Scan and list unapproved build scripts"],["vis approve-builds --all","Approve all pending builds (pnpm)"],["vis approve-builds --write","Write unapproved entries into vis.config.ts security.policies.installScripts.allow"],["vis approve-builds --sync-native","Sync allowBuilds to native PM config"]],group:"Security & Health",loader:()=>import("./handler51.js"),name:"approve-builds",options:[{defaultValue:!1,description:"Approve all pending builds without prompting (pnpm only)",name:"all",type:Boolean},{defaultValue:!1,description:"Force vis scanning even for pnpm (instead of delegating)",name:"scan",type:Boolean},{defaultValue:!1,description:"Sync allowBuilds to native PM config (bun: trustedDependencies, npm: .npmrc, yarn: .yarnrc.yml)",name:"sync-native",type:Boolean},{defaultValue:!1,description:"Write unapproved entries directly into vis.config.ts security.policies.installScripts.allow (LavaMoat 'auto' parity)",name:"write",type:Boolean}]},Um={description:"Output format: table, json, or ndjson (default: table). json/ndjson go to stdout, logs to stderr.",name:"format",type:String},mZ={commandPath:["attest"],description:"Verify inbound provenance + registry signatures across the locked dependency graph and gate on regressions",examples:[["vis attest verify","Check every locked dep for provenance regressions and signature problems"],["vis attest verify --prod-only","Skip devDependencies"],["vis attest verify --format json","Machine-readable findings for CI (Axis A)"],["vis attest verify --fail-on error","Exit non-zero only on error-severity findings (default: any finding)"]],group:"Security & Health",loader:le(()=>import("./handler5.js"),"attestVerifyExecute"),name:"verify",options:[Um,{defaultValue:!1,description:"Skip devDependencies — verify the production graph only.",name:"prod-only",type:Boolean},{description:"Severity that triggers a non-zero exit: 'warning' (any finding, default) or 'error'.",name:"fail-on",type:String},{description:"Comma-separated package names to exclude from both marshalls.",name:"allowlist",type:String}]},bZ={argument:{description:"Path to the built artifact to attest (e.g. dist/app.tgz). Its sha256 becomes the in-toto subject digest.",name:"subject",type:String},description:"Build an in-toto SLSA v1 provenance statement for an artifact and keyless-sign it via Sigstore",examples:[["vis attest dist/app.tgz","Emit dist/app.tgz.sigstore (keyless-signed in CI)"],["vis attest dist/app.tgz --output attest.sigstore","Write the bundle to a specific path"],["vis attest dist/app.tgz --predicate slsaProvenance","Predicate type (default: slsaProvenance)"],["vis attest dist/app.tgz --require-signing","Fail instead of skip-with-warn when no ambient OIDC (outside CI)"],["vis attest dist/app.tgz --format json","Print the signed bundle summary as JSON (Axis A)"]],group:"Security & Health",loader:le(()=>import("./handler5.js"),"attestEmitExecute"),name:"attest",options:[Um,{description:"Write the serialized Sigstore bundle here (default: <subject>.sigstore).",name:"output",type:String},{description:"Predicate type: 'slsaProvenance' (default, https://slsa.dev/provenance/v1).",name:"predicate",type:String},{defaultValue:!1,description:"Error instead of skip-with-warn when no ambient OIDC token is available (i.e. outside CI).",name:"require-signing",type:Boolean}]},wZ=[bZ,mZ],jZ={description:"Audit installed packages for vulnerabilities and supply chain risks",examples:[["vis audit","Full audit of all installed packages"],["vis audit --severity high","Show only high/critical issues"],["vis audit --format json","Output as JSON for CI integration"],["vis audit --format sarif","Output SARIF 2.1.0 for code-scanning uploads"],["vis audit --format csaf","Output CSAF 2.0 csaf_vex for enterprise vuln pipelines"],["vis audit --format cyclonedx-vex","Output a CycloneDX 1.7 BOM with vulnerabilities[] (SBOM + VEX)"],["vis audit --format gitlab","Output a GitLab dependency-scanning report (gl-dependency-scanning.json)"],["vis audit --format junit","Output a Surefire-compatible JUnit XML report"],["vis audit --report report.html","Write a self-contained HTML report to ./report.html"],["vis audit --usage","Only report vulnerabilities in statically-imported packages"],["vis audit --offline","Query the local OSV cache only (no network)"],["vis audit --offline --db ./vendor.sqlite","Use a specific advisory DB"],["vis audit --ecosystem npm,pypi","Scan multiple OSV ecosystems (npm, pypi, crates.io, maven, go, rubygems)"],["vis audit --prod-only","Skip devDependencies"],["vis audit --fail-on high","Exit non-zero on any high or critical finding"],["vis audit --show-fixes","Print fix-suggestion lines (no apply, no rescan)"],["vis audit --fix","Apply direct-dep upgrades for vulnerable packages, then rescan (dry-run preview by default)"],["vis audit --fix --yes","Skip the confirmation prompt and run the upgrades immediately"],["vis audit --fix --allow-major","Permit major-version bumps when the lowest fix is outside the existing range"],["vis audit --fix-transitive","Write PM-specific overrides for vulnerable transitives (dry-run preview by default)"],["vis audit --exit-code","Exit with code 1 if issues found (for CI)"],["vis audit --show-accepted","Include acknowledged risks in output"],["vis audit --sync","Sync accepted risks to native PM config (pnpm-workspace.yaml / .yarnrc.yml)"],["vis audit --policies license,vulnerability","Run only the named policies (default: every configured policy)"],["vis audit --policies none","Skip the policy engine entirely"],["vis audit --explain","Add a plain-English AI explanation under every finding (auto-detects an installed AI CLI)"],["vis audit --explain CVE-2021-23337","Explain only the finding with this CVE/GHSA id"],["vis audit --explain 2","Explain only the 2nd finding"]],group:"Security & Health",loader:()=>import("./handler72.js"),name:"audit",options:[{description:"Minimum severity to report: low, medium, high, critical (default: low)",name:"severity",type:String},{description:"Output format: table, json, sarif, csaf, cyclonedx-vex, gitlab, or junit (default: table)",name:"format",type:String},{description:"Write a self-contained HTML report to this path. Auto-opens in a TTY when not in CI.",name:"report",type:String},{defaultValue:!1,description:"Only report vulnerabilities in statically-imported packages (reachability filter).",name:"usage",type:Boolean},{defaultValue:!1,description:"Disable the reachability filter even if enabled in config.",name:"no-usage",type:Boolean},{defaultValue:!1,description:"Query the local OSV advisory cache only — no network calls. Errors if the cache is missing.",name:"offline",type:Boolean},{description:"Override the offline advisory DB path (default: <cache>/vis/advisories/db.sqlite).",name:"db",type:String},{description:"Comma-separated list of OSV ecosystems to scan (default: npm). Supported: npm, pypi, crates.io (or 'cargo'), maven, go, rubygems. Non-npm ecosystems require --offline (online OSV path is npm-only).",name:"ecosystem",type:String},{defaultValue:!1,description:"Skip devDependencies — scan production graph only.",name:"prod-only",type:Boolean},{description:"Exit non-zero when any finding is at this severity or higher. One of: low, medium, high, critical.",name:"fail-on",type:String},{defaultValue:!1,description:"Print fix-suggestion lines for each finding (no apply, no rescan)",name:"show-fixes",type:Boolean},{defaultValue:!1,description:"Apply direct-dep fixes for vulnerable packages by running the active PM update command, then rescan",name:"fix",type:Boolean},{defaultValue:!1,description:"Apply transitive fixes by writing PM-specific overrides (pnpm-workspace.yaml / package.json overrides / resolutions)",name:"fix-transitive",type:Boolean},{defaultValue:!1,description:"Skip confirmation prompt for --fix / --fix-transitive (required in CI)",name:"yes",type:Boolean},{defaultValue:!1,description:"Allow --fix to bump a direct dep across a major version when the lowest fix is outside the existing range",name:"allow-major",type:Boolean},{defaultValue:!1,description:"Exit with code 1 if any issues found (for CI)",name:"exit-code",type:Boolean},{defaultValue:!1,description:"Include acknowledged (accepted risk) issues in output",name:"show-accepted",type:Boolean},{defaultValue:!1,description:"Sync vis accepted risks to native PM config (pnpm-workspace.yaml / .yarnrc.yml)",name:"sync",type:Boolean},{description:"Comma-separated list of supply-chain policies to evaluate (default: every configured policy). Use 'none' to skip the engine entirely, 'all' to force the full set. Known: malware, firstSeen, unexpectedDeps, publisherChange, installScripts, score, vulnerability, license.",name:"policies",type:String},{description:"Audit backend: 'auto' (default, delegates to 'aube audit' when aube is the installer), 'aube' (force delegate), or 'vis' (always use vis's OSV/Socket scanner).",name:"backend",type:String},{description:"Add a plain-English AI explanation to findings. Bare flag explains all findings at/above --severity; pass a finding index (e.g. 2) or a CVE/GHSA id to explain just one. Auto-detects an installed AI CLI; mutually exclusive with --offline.",name:"explain",type:String}]},Ss={description:"Cache directory (overrides config and default). Relative paths are resolved against the workspace root.",name:"cache-dir",type:String},zr={description:"Cache scope: 'shared' (default — main worktree's cache), 'worktree' (this checkout's local cache), or 'all' (both)",name:"scope",type:String},Vm={description:"Cache type: 'task' (workspace task cache), 'ai' (AI response cache), 'socket' (Socket.dev reports), 'deps-dev' (Google deps.dev reports), or 'all' (default)",name:"type",type:String},kZ={commandPath:["cache"],description:"List all cache entries",examples:[["vis cache list","List all cache entries"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheListExecute"),name:"list",options:[Ss,zr,{description:"Output format: table or json (default: table)",name:"format",type:String}]},SZ={commandPath:["cache"],description:"Remove cache entries (defaults to all stores: workspace task cache, AI responses, Socket.dev reports)",examples:[["vis cache clean","Remove all cache entries from every store"],["vis cache clean --type=ai","Clear only the AI response cache"],["vis cache clean --type=task","Clear only the workspace task cache"],["vis cache clean --dry-run","Preview what clean would remove"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheCleanExecute"),name:"clean",options:[Ss,Vm,{defaultValue:!1,description:"Preview without deleting",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Skip the confirmation prompt for out-of-workspace cache directories",name:"force",type:Boolean}]},LZ={commandPath:["cache"],description:"Remove old and oversized cache entries",examples:[["vis cache prune","Remove old and oversized entries"],["vis cache prune --max-age-days=3 --max-size=500MB","Prune with custom limits"],["vis cache prune --keep-last=30","Keep only the 30 most recent entries"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cachePruneExecute"),name:"prune",options:[Ss,zr,{description:"Remove entries older than N days",name:"max-age-days",type:Number},{description:"Evict oldest entries until cache is under this size (e.g. 500MB)",name:"max-size",type:String},{description:"Keep only the N most recent entries (sorted newest-first by mtime)",name:"keep-last",type:Number}]},CZ={commandPath:["cache"],description:"Print on-disk footprint and stats for one or more cache stores (task / ai / socket)",examples:[["vis cache size","Show stats for every cache store"],["vis cache size --type=ai","Show only the AI response cache (entries, size, oldest, newest)"],["vis cache size --type=task --format=json","Machine-readable task cache size"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheSizeExecute"),name:"size",options:[Ss,zr,Vm,{description:"Output format: table or json (default: table)",name:"format",type:String}]},Ug={description:"Output format: table or json (default: table)",name:"format",type:String},eb={description:"Use a specific run ID from .vis/runs/ instead of the latest run",name:"run",type:String},YZ={argument:{description:"Task ID to explain (e.g. @my/app:build)",name:"taskId",type:String},commandPath:["cache"],description:"Explain why a task missed the cache by diffing hash inputs against the previous run",examples:[["vis cache why @myorg/app:build","Show which inputs changed since the last run"],["vis cache why @myorg/app:build --json","Machine-readable output for CI"],["vis cache why @myorg/app:build --run 2026-04-28T...","Inspect a specific historical run"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheWhyExecute"),name:"why",options:[Ug,eb]},$Z={argument:{description:"Task ID to print the hash for (e.g. @my/app:build)",name:"taskId",type:String},commandPath:["cache"],description:"Print the recorded hash and per-input hash details for a task",examples:[["vis cache hash @myorg/app:build","Show the resolved hash + contributing inputs"],["vis cache hash @myorg/app:build --json","Machine-readable output"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheHashExecute"),name:"hash",options:[Ug,eb]},ZZ={argument:{description:"Task ID to verify (e.g. @my/app:build)",name:"taskId",type:String},commandPath:["cache"],description:"Verify cache restore fidelity: extract the cached entry into a tmp directory and diff each file's content, mode, and mtime against the live workspace. Exits 1 on any drift (changed content, mode, mtime) or if a cached output is missing from the workspace. With --scope=all, the first cache directory containing the task is used.",examples:[["vis cache verify @myorg/app:build","Diff cached outputs vs live workspace files"],["vis cache verify @myorg/app:build --format=json","Machine-readable diff (status: ok | drift)"],["vis cache verify @myorg/app:build --cache-dir=.alt-cache","Verify against a non-default cache directory"],["vis cache verify @myorg/app:build --scope=all","Search shared and worktree caches for the task"]],group:"Workspace",loader:le(()=>Promise.resolve().then(()=>ua),"cacheVerifyExecute"),name:"verify",options:[Ss,zr,Ug]},JZ={commandPath:["cache"],description:"Probe the configured remote cache (HTTP HEAD or REAPI Capabilities) and report reachability, latency, and negotiated capabilities",examples:[["vis cache doctor","Probe the remoteCache configured in vis.config.ts"],["vis cache doctor --url=grpcs://cache.example.com:443 --backend=reapi","Override URL/backend ad-hoc"],["vis cache doctor --json","Machine-readable output"]],group:"Workspace",loader:le(()=>import("./doctor-probe.js"),"cacheDoctorExecute"),name:"doctor",options:[{description:"Override remote cache URL (otherwise read from vis.config.ts remoteCache.url, or TURBO_API env var)",name:"url",type:String},{description:"Override backend selector: 'http' or 'reapi'",name:"backend",type:String},{description:"Output format: table or json (default: table)",name:"format",type:String},{defaultValue:5e3,description:"Probe timeout in milliseconds (default: 5000)",name:"timeout",type:Number}]},xZ=[kZ,SZ,LZ,CZ,YZ,$Z,ZZ,JZ],TZ={alias:["c","outdated"],argument:{description:"Specific packages to check (checks all if omitted)",name:"packages",type:String},description:"Check for outdated dependencies, security vulnerabilities, and supply chain settings",examples:[["vis check","Check all catalog dependencies"],["vis check react","Check specific packages"],["vis check --target minor","Only show minor/patch updates"],["vis check --exclude '@types/*'","Exclude packages by pattern"],["vis check --no-security","Skip vulnerability scanning"],["vis check --security-config","Audit supply chain security settings"],["vis check --security-config --sync","Sync security config to pnpm-workspace.yaml"]],group:"Security & Health",loader:()=>import("./handler6.js"),name:"check",options:[{alias:"t",description:"Update target: latest, minor, or patch (default: latest)",name:"target",type:String},{description:"Glob pattern to include packages (repeatable)",lazyMultiple:!0,name:"include",type:String},{description:"Glob pattern to exclude packages (repeatable)",lazyMultiple:!0,name:"exclude",type:String},{defaultValue:!1,description:"Include prerelease versions",name:"prerelease",type:Boolean},{defaultValue:!1,description:"Skip security vulnerability scanning",name:"no-security",type:Boolean},{defaultValue:!1,description:"Audit supply chain security settings",name:"security-config",type:Boolean},{defaultValue:!1,description:"Sync security settings to pnpm-workspace.yaml (pnpm only, requires --security-config)",name:"sync",type:Boolean},{description:"Output format: table, json, or minimal (default: table)",name:"format",type:String},{defaultValue:!1,description:"Exit with code 1 if outdated dependencies found (for CI)",name:"exit-code",type:Boolean},{defaultValue:!1,description:"Run AI analysis on outdated packages",name:"ai",type:Boolean},{description:"AI analysis type: impact, security, compatibility, or recommend",name:"ai-type",type:String},{alias:"D",conflicts:"prod",description:"Check only devDependencies (npm/yarn mode)",name:"dev",type:Boolean},{alias:"P",conflicts:"dev",description:"Check only dependencies (npm/yarn mode)",name:"prod",type:Boolean},{defaultValue:!1,description:"Include peerDependencies in outdated checks",name:"peer",type:Boolean},{defaultValue:!1,description:"Also check workspace-owned package names against the registry",name:"include-internal",type:Boolean}]},DZ={argument:{description:"Comma-separated list of targets to run (e.g., lint,test,build)",name:"targets",type:String},description:"Run affected targets in a CI-optimized pipeline",examples:[["vis ci lint,test,build","Run lint, test, and build on affected projects"],["vis ci test --base=origin/main","Override the base ref"],["vis ci build --no-install","Skip the install step (assume deps already present)"],["vis ci build --parallel=6","Increase concurrency"]],group:"Run & Execute",loader:()=>import("./handler7.js"),name:"ci",options:[{defaultValue:!0,description:"Install dependencies before running targets (use --no-install to skip)",name:"install",type:Boolean},{defaultValue:!1,description:"Skip the toolchain pre-flight (no auto-install for any pinned tool: node / pnpm / yarn / npm / bun / deno / go / python / ruby / rust)",name:"skip-toolchain",type:Boolean},{description:"Git base ref for affected detection (default: auto-detected from CI env)",name:"base",type:String},{description:"Git head ref for affected detection (default: HEAD)",name:"head",type:String},{defaultValue:"none",description:"Upstream scope: none | direct | deep",name:"upstream",type:String},{defaultValue:"deep",description:"Downstream scope: none | direct | deep",name:"downstream",type:String},{defaultValue:4,description:"Maximum number of parallel tasks per target",name:"parallel",type:Number},{description:'Partition tasks for distributed CI (e.g., "1/4")',name:"partition",type:String},{description:"Filter affected projects by a query (e.g. 'language=typescript && tag=lib')",name:"query",type:String}]},BZ={argument:{description:"Project name to check (required)",name:"project",type:String},commandPath:["ci"],description:'Exit with inverted codes for CI "Ignored Build Step" gating (Vercel/Netlify)',examples:[["vis ci ignore my-app","Check if my-app is affected and decide whether to build"],["vis ci ignore my-app --base $VERCEL_GIT_PREVIOUS_SHA","Explicit base ref"],["vis ci ignore my-app --json","Emit the decision as JSON instead of text"],["vis ci ignore my-app --verbose","Print debug info about the decision path"],["vis ci ignore my-app --exit-zero-on-build","Normal exit semantics (0=build, 0=skip)"]],group:"Run & Execute",loader:()=>import("./handler52.js"),name:"ignore",options:[{description:"Git base ref for comparison. Defaults to CI provider env vars, then HEAD~1.",name:"base",type:String},{defaultValue:"HEAD",description:"Git head ref for comparison",name:"head",type:String},{defaultValue:"deep",description:'Downstream scope: "none", "direct", or "deep"',name:"downstream",type:String},{defaultValue:"none",description:'Upstream scope: "none", "direct", or "deep"',name:"upstream",type:String},{defaultValue:!1,description:"Emit the decision as JSON on stdout instead of human text",name:"json",type:Boolean},{defaultValue:!1,description:"Exit 0 on build (normal semantics) instead of 1 (inverted Vercel/Netlify semantics)",name:"exit-zero-on-build",type:Boolean},{defaultValue:!1,description:"Enable verbose debug output",name:"verbose",type:Boolean}]},XZ={description:"Remove node_modules from all workspace projects",examples:[["vis clean","Remove all node_modules directories"],["vis clean --lockfile","Also remove lockfiles"],["vis clean --empty-packages","Also remove workspace directories that have no package.json"],["vis clean --dry-run","Preview what would be removed"]],group:"Workspace",loader:()=>import("./handler8.js"),name:"clean",options:[{alias:"l",defaultValue:!1,description:"Also remove lockfiles (pnpm-lock.yaml, package-lock.json, etc.)",name:"lockfile",type:Boolean},{alias:"e",defaultValue:!1,description:"Also remove stale workspace directories that match a workspace pattern but have no package.json",name:"empty-packages",type:Boolean},{defaultValue:!1,description:"Preview what would be removed without deleting",name:"dry-run",type:Boolean}]},HZ={argument:{description:"Template to use (e.g., vis:app, create-vite, user/repo) — omit for interactive mode",name:"template",type:String},description:"Create a new project from a template",examples:[["vis create","Interactive project scaffolding"],["vis create vis:monorepo my-workspace","Create a monorepo workspace"],["vis create vis:app my-app","Scaffold a Vite application"],["vis create vis:library my-lib","Create a TypeScript library"],["vis create vite my-app -- --template react-ts","Use create-vite with React TypeScript"],["vis create user/repo my-project","Clone a GitHub template"],["vis create --list","Show available templates"]],group:"Scaffold & Config",loader:()=>import("./handler69.js"),name:"create",options:[{defaultValue:!1,description:"Show available templates",name:"list",type:Boolean},{description:"Generate editor configs (vscode)",name:"editor",type:String},{defaultValue:!1,description:"Initialize a git repository",name:"git-init",type:Boolean},{defaultValue:!1,description:"Skip interactive prompts",name:"no-interactive",type:Boolean}]},ib=(e,i,n)=>{const o=t=>Ff(t)?t:Ha(e,t);if(i&&i.length>0)return o(i);if(n&&n.length>0)return o(n);const a=process.env.VIS_CACHE_DIRECTORY;return a&&a.length>0?o(a):Ha(e,em)},MZ=(e,i)=>i===!1?e:pY(e)??e,Kp=(e,i,n,o)=>{const a=i??n??process.env.VIS_CACHE_DIRECTORY;if(a&&a.length>0)return ib(e,i,n);const t=MZ(e,o);return Ha(t,em)},PZ=/[^\w.-]+/g,NZ=/^-+|-+$/g,EZ=e=>e.trim().replaceAll(PZ,"-").replaceAll(NZ,"").slice(0,64),RZ=e=>{try{const i=rY("git",["rev-parse","--abbrev-ref","HEAD"],{cwd:e,encoding:"utf8",stdio:["ignore","pipe","ignore"]}).trim();return!i||i==="HEAD"?void 0:i}catch{return}},DSe=(e,i,n)=>{if(n!==!0)return e;const o=RZ(i);if(!o)return e;const a=EZ(o);return a.length===0?e:Ha(e,"branches",a)},OZ=(e,i)=>{const n=ws(i,e);return n.length===0?!1:n!==".."&&!n.startsWith("../")&&!Ff(n)},AZ="x-hono-already-sent";var vn=class extends Error{constructor(i,n){super(i,n),this.name="RequestError"}};const GZ=/^\/[!#$&-;=?-\[\]_a-z~]*$/,FZ=/\/\.\.?(?:[/?#]|$)/,QZ=/^[a-z0-9._-]+(?::(?:[1-5]\d{3,4}|[6-9]\d{3}))?$/,WZ=(e,i,n)=>{const o=`${e}://${i}${n}`;if(QZ.test(i)){if(n.length===0)return o+"/";if(n.charCodeAt(0)!==47)throw new vn("Invalid URL");return!GZ.test(n)||FZ.test(n)?new URL(o).href:o}else{const a=new URL(o);if(a.hostname.length!==i.length&&a.hostname!==(i.includes(":")?i.replace(/:\d+$/,""):i).toLowerCase())throw new vn("Invalid host header");return a.href}},IZ=e=>e instanceof vn?e:new vn(e.message,{cause:e}),_Z=global.Request;var Na=class extends _Z{constructor(i,n){if(typeof i=="object"&&oo in i){const o=n!==void 0&&"body"in n&&n.body!=null;if(i[Mn]&&!o)throw new TypeError("Cannot construct a Request with a Request object that has already been used.");i=i[oo]()}typeof n?.body?.getReader<"u"&&(n.duplex??="half"),super(i,n)}};const nb=e=>{const i=[],n=e.rawHeaders;for(let o=0,a=n.length;o<a;o+=2){const t=n[o];t.charCodeAt(0)!==58&&i.push([t,n[o+1]])}return new Headers(i)},ob=Symbol("wrapBodyStream"),zZ=(e,i,n,o,a)=>{const t={method:e,headers:n,signal:a.signal};if(e==="TRACE"){t.method="GET";const s=new Na(i,t);return Object.defineProperty(s,"method",{get(){return"TRACE"}}),s}if(!(e==="GET"||e==="HEAD"))if("rawBody"in o&&o.rawBody instanceof Buffer)t.body=new ReadableStream({start(s){s.enqueue(o.rawBody),s.close()}});else if(o[ob]){let s;t.body=new ReadableStream({async pull(r){try{s||=xl.toWeb(o).getReader();const{done:u,value:d}=await s.read();u?r.close():r.enqueue(d)}catch(u){r.error(u)}}})}else t.body=xl.toWeb(o);return new Na(i,t)},oo=Symbol("getRequestCache"),Bn=Symbol("requestCache"),Ea=Symbol("incomingKey"),Kt=Symbol("urlKey"),ab=Symbol("methodKey"),tb=Symbol("headersKey"),kt=Symbol("abortControllerKey"),El=Symbol("getAbortController"),Rl=Symbol("abortRequest"),$a=Symbol("bodyBuffer"),Fs=Symbol("bodyReadPromise"),Mn=Symbol("bodyConsumedDirectly"),qp=Symbol("bodyLockReader"),At=Symbol("abortReason"),sb=()=>new TypeError("Body is unusable"),Ls=()=>Promise.reject(sb()),KZ=new TextDecoder,qZ=e=>{if(e[Mn])return Ls();e[Mn]=!0},UZ=e=>e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength),VZ=e=>(e[tb]||=nb(e[Ea])).get("content-type")||"",eJ=/^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/,iJ=e=>{if(typeof e!="string"||e.length===0)return"GET";switch(e){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"POST":case"PUT":return e}const i=e.toUpperCase();switch(i){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"POST":case"PUT":return i;default:return e}},nJ=e=>{if(!eJ.test(e))return new TypeError(`'${e}' is not a valid HTTP method.`);const i=e.toUpperCase();if(i==="CONNECT"||i==="TRACK"||i==="TRACE"&&e!=="TRACE")return new TypeError(`'${e}' HTTP method is unsupported.`)},Vg=(e,i,n)=>{if(e[Mn])return Ls();const o=e.method;if(o==="GET"||o==="HEAD")return e[oo]()[i]();const a=nJ(o);if(a)return Promise.reject(a);if(e[Bn]&&o!=="TRACE")return e[Bn][i]();const t=qZ(e);if(t)return t;const s=oJ(e);if(s){const r=Promise.resolve(n(s,e));return e[$a]=void 0,r}return aJ(e).then(r=>{const u=n(r,e);return e[$a]=void 0,u})},oJ=e=>{const i=e[Ea];if("rawBody"in i&&i.rawBody instanceof Buffer)return i.rawBody},aJ=e=>{if(e[$a])return Promise.resolve(e[$a]);if(e[Fs])return e[Fs];const i=e[Ea];if(xl.isDisturbed(i))return Ls();const n=new Promise((o,a)=>{const t=[];let s=!1;const r=c=>{s||(s=!0,h(),c())},u=c=>{t.push(Buffer.isBuffer(c)?c:Buffer.from(c))},d=()=>{r(()=>{const c=t.length===1?t[0]:Buffer.concat(t);e[$a]=c,o(c)})},l=c=>{r(()=>{a(c)})},g=()=>{if(i.readableEnded){d();return}r(()=>{if(i.errored){a(i.errored);return}const c=e[At];if(c!==void 0){a(c instanceof Error?c:new Error(String(c)));return}a(new Error("Client connection prematurely closed."))})},h=()=>{i.off("data",u),i.off("end",d),i.off("error",l),i.off("close",g),e[Fs]=void 0};i.on("data",u),i.on("end",d),i.on("error",l),i.on("close",g),queueMicrotask(()=>{s||(i.readableEnded?d():i.errored?l(i.errored):i.destroyed&&g())})});return e[Fs]=n,n},jn={get method(){return this[ab]},get url(){return this[Kt]},get headers(){return this[tb]||=nb(this[Ea])},[Rl](e){this[At]===void 0&&(this[At]=e);const i=this[kt];i&&!i.signal.aborted&&i.abort(e)},[El](){return this[kt]||=new AbortController,this[At]!==void 0&&!this[kt].signal.aborted&&this[kt].abort(this[At]),this[kt]},[oo](){const e=this[El]();if(this[Bn])return this[Bn];const i=this.method;if(this[Mn]&&!(i==="GET"||i==="HEAD")){this[$a]=void 0;const n={method:i==="TRACE"?"GET":i,headers:this.headers,signal:e.signal};i!=="TRACE"&&(n.body=new ReadableStream({start(a){a.close()}}),n.duplex="half");const o=new Na(this[Kt],n);return i==="TRACE"&&Object.defineProperty(o,"method",{get(){return"TRACE"}}),this[Bn]=o}return this[Bn]=zZ(this.method,this[Kt],this.headers,this[Ea],e)},get body(){if(!this[Mn])return this[oo]().body;const e=this[oo]();return!this[qp]&&e.body&&(this[qp]=e.body.getReader()),e.body},get bodyUsed(){return this[Mn]?!0:this[Bn]?this[Bn].bodyUsed:!1}};Object.defineProperty(jn,"signal",{get(){return this[El]().signal}});["cache","credentials","destination","integrity","mode","redirect","referrer","referrerPolicy","keepalive"].forEach(e=>{Object.defineProperty(jn,e,{get(){return this[oo]()[e]}})});["clone","formData"].forEach(e=>{Object.defineProperty(jn,e,{value:function(){if(this[Mn]){if(e==="clone")throw sb();return Ls()}return this[oo]()[e]()}})});Object.defineProperty(jn,"text",{value:function(){return Vg(this,"text",e=>KZ.decode(e))}});Object.defineProperty(jn,"arrayBuffer",{value:function(){return Vg(this,"arrayBuffer",e=>UZ(e))}});Object.defineProperty(jn,"blob",{value:function(){return Vg(this,"blob",(e,i)=>{const n=VZ(i),o=n?{headers:{"content-type":n}}:void 0;return new Response(e,o).blob()})}});Object.defineProperty(jn,"json",{value:function(){return this[Mn]?Ls():this.text().then(JSON.parse)}});Object.defineProperty(jn,Symbol.for("nodejs.util.inspect.custom"),{value:function(e,i,n){return`Request (lightweight) ${n({method:this.method,url:this.url,headers:this.headers,nativeRequest:this[Bn]},{...i,depth:e==null?null:e-1})}`}});Object.setPrototypeOf(jn,Na.prototype);const tJ=(e,i)=>{const n=Object.create(jn);n[Ea]=e,n[ab]=iJ(e.method);const o=e.url||"";if(o[0]!=="/"&&(o.startsWith("http://")||o.startsWith("https://"))){if(e instanceof zt)throw new vn("Absolute URL for :path is not allowed in HTTP/2");try{n[Kt]=new URL(o).href}catch(s){throw new vn("Invalid absolute URL",{cause:s})}return n}const a=(e instanceof zt?e.authority:e.headers.host)||i;if(!a)throw new vn("Missing host header");let t;if(e instanceof zt){if(t=e.scheme,!(t==="http"||t==="https"))throw new vn("Unsupported scheme")}else t=e.socket&&e.socket.encrypted?"https":"http";try{n[Kt]=WZ(t,a,o)}catch(s){throw s instanceof vn?s:new vn("Invalid URL",{cause:s})}return n},io="text/plain; charset=UTF-8",Ol=Symbol("responseCache"),wa=Symbol("getResponseCache"),Hn=Symbol("cache"),eh=global.Response;var fn=class rb{#n;#i;[wa](){const i=this[Hn],n=i&&i[2]instanceof Headers?i[2]:void 0;return delete this[Hn],this[Ol]||=new eh(this.#n,n?{...this.#i,headers:n}:this.#i)}constructor(i,n){let o;if(this.#n=i,n instanceof rb){const a=n[Ol];if(a){this.#i=a,this[wa]();return}else this.#i=n.#i,o=new Headers(n.headers)}else this.#i=n;(i==null||typeof i=="string"||typeof i?.getReader<"u"||i instanceof Blob||i instanceof Uint8Array)&&(this[Hn]=[n?.status||200,i??null,o||n?.headers])}get headers(){const i=this[Hn];return i?(i[2]instanceof Headers||(i[2]=new Headers(i[2]||(i[1]===null?void 0:{"content-type":io}))),i[2]):this[wa]().headers}get status(){return this[Hn]?.[0]??this[wa]().status}get ok(){const i=this.status;return i>=200&&i<300}};["body","bodyUsed","redirected","statusText","trailers","type","url"].forEach(e=>{Object.defineProperty(fn.prototype,e,{get(){return this[wa]()[e]}})});["arrayBuffer","blob","clone","formData","json","text"].forEach(e=>{Object.defineProperty(fn.prototype,e,{value:function(){return this[wa]()[e]()}})});Object.defineProperty(fn.prototype,Symbol.for("nodejs.util.inspect.custom"),{value:function(e,i,n){return`Response (lightweight) ${n({status:this.status,headers:this.headers,ok:this.ok,nativeResponse:this[Ol]},{...i,depth:e==null?null:e-1})}`}});Object.setPrototypeOf(fn,eh);Object.setPrototypeOf(fn.prototype,eh.prototype);const sJ=/^https?:\/\/[!#-;=?-[\]_a-z~A-Z]+$/,rJ=e=>e instanceof URL?e.href:sJ.test(e)?e:new URL(e).href,uJ=new Set([301,302,303,307,308]);Object.defineProperty(fn,"redirect",{value:function(e,i=302){if(!uJ.has(i))throw new RangeError("Invalid status code");return new fn(null,{status:i,headers:{location:rJ(e)}})},writable:!0,configurable:!0});Object.defineProperty(fn,"json",{value:function(e,i){const n=JSON.stringify(e);if(n===void 0)throw new TypeError("The data is not JSON serializable");const o=i?.headers;let a;return o?(a=new Headers(o),a.has("content-type")||a.set("content-type","application/json")):a={"content-type":"application/json"},new fn(n,{status:i?.status??200,statusText:i?.statusText,headers:a})},writable:!0,configurable:!0});async function dJ(e){return Promise.race([e,Promise.resolve().then(()=>Promise.resolve(void 0))])}function ub(e,i,n){const o=r=>{e.cancel(r).catch(()=>{})};return i.on("close",o),i.on("error",o),(n??e.read()).then(s,a),e.closed.finally(()=>{i.off("close",o),i.off("error",o)});function a(r){r&&i.destroy(r)}function t(){e.read().then(s,a)}function s({done:r,value:u}){try{if(r)i.end();else if(!i.write(u))i.once("drain",t);else return e.read().then(s,a)}catch(d){a(d)}}}function Up(e,i){if(e.locked)throw new TypeError("ReadableStream is locked.");return i.destroyed?void 0:ub(e.getReader(),i)}const Al=(e,i)=>{const n={};if(e instanceof Headers||(e=new Headers(e??void 0)),e.has("set-cookie")){const o=[];for(const[a,t]of e)a==="set-cookie"?o.push(t):n[a]=t;o.length>0&&(n["set-cookie"]=o)}else for(const[o,a]of e)n[o]=a;return i&&(n["content-type"]??=i),n},$r=Symbol("outgoingEnded"),Vp=Symbol("incomingDraining"),lJ=500,gJ=64*1024*1024,db=e=>{const i=e;if(e.destroyed||i[Vp])return;if(i[Vp]=!0,e instanceof zt){try{e.stream?.close?.(jY.NGHTTP2_NO_ERROR)}catch{}return}let n=0;const o=()=>{clearTimeout(t),e.off("data",s),e.off("end",o),e.off("error",o)},a=()=>{o();const r=e.socket;r&&!r.destroyed&&r.destroySoon()},t=setTimeout(a,lJ);t.unref?.();const s=r=>{n+=r.length,n>gJ&&a()};e.on("data",s),e.on("end",o),e.on("error",o),e.resume()},hJ=(e,i,n,o)=>()=>{i.errored?e[Rl](i.errored.toString()):n.writableFinished||e[Rl]("Client connection prematurely closed."),o&&!i.readableEnded&&setTimeout(()=>{i.readableEnded||setTimeout(()=>{db(i)})})},cJ=e=>{if(!(Hn in e))return!1;const i=e[Hn][1];return i===null||typeof i=="string"||i instanceof Uint8Array},pJ=()=>new Response(null,{status:400}),lb=e=>new Response(null,{status:e instanceof Error&&(e.name==="TimeoutError"||e.constructor.name==="TimeoutError")?504:500}),Zr=(e,i)=>{const n=e instanceof Error?e:new Error("unknown error",{cause:e});n.code==="ERR_STREAM_PREMATURE_CLOSE"?console.info("The user aborted a request."):(console.error(e),i.headersSent||i.writeHead(500,{"Content-Type":"text/plain"}),i.end(`Error: ${n.message}`),i.destroy(n))},Gl=e=>{"flushHeaders"in e&&e.writable&&e.flushHeaders()},gb=async(e,i)=>{let[n,o,a]=e[Hn];if(!a){o===null?(i.writeHead(n),i.end()):typeof o=="string"?(i.writeHead(n,{"Content-Type":io,"Content-Length":Buffer.byteLength(o)}),i.end(o)):o instanceof Uint8Array?(i.writeHead(n,{"Content-Type":io,"Content-Length":o.byteLength}),i.end(o)):o instanceof Blob?(i.writeHead(n,{"Content-Type":io,"Content-Length":o.size}),i.end(new Uint8Array(await o.arrayBuffer()))):(i.writeHead(n,{"Content-Type":io}),Gl(i),await Up(o,i)?.catch(s=>Zr(s,i))),i[$r]?.();return}let t=!1;if(a instanceof Headers)t=a.has("content-length"),a=Al(a,o===null?void 0:io);else if(Array.isArray(a)){const s=new Headers(a);t=s.has("content-length"),a=Al(s,o===null?void 0:io)}else for(const s in a)if(s.length===14&&s.toLowerCase()==="content-length"){t=!0;break}t||(typeof o=="string"?a["Content-Length"]=Buffer.byteLength(o):o instanceof Uint8Array?a["Content-Length"]=o.byteLength:o instanceof Blob&&(a["Content-Length"]=o.size)),i.writeHead(n,a),o==null?i.end():typeof o=="string"||o instanceof Uint8Array?i.end(o):o instanceof Blob?i.end(new Uint8Array(await o.arrayBuffer())):(Gl(i),await Up(o,i)?.catch(s=>Zr(s,i))),i[$r]?.()},hb=e=>typeof e.then=="function",vJ=async(e,i,n={})=>{if(hb(e))if(n.errorHandler)try{e=await e}catch(a){const t=await n.errorHandler(a);if(!t)return;e=t}else e=await e.catch(lb);if(Hn in e)return gb(e,i);const o=Al(e.headers,e.body===null?void 0:io);if(e.body){const a=e.body.getReader(),t=[];let s=!1,r;if(o["transfer-encoding"]!=="chunked"){let u=2;for(let d=0;d<u;d++){r||=a.read();const l=await dJ(r).catch(g=>{console.error(g),s=!0});if(!l){if(d===1){await new Promise(g=>setTimeout(g)),u=3;continue}break}if(r=void 0,l.value&&t.push(l.value),l.done){s=!0;break}}s&&!("content-length"in o)&&(o["content-length"]=t.reduce((d,l)=>d+l.length,0))}i.writeHead(e.status,o),t.forEach(u=>{i.write(u)}),s?i.end():(t.length===0&&Gl(i),await ub(a,i,r))}else o[AZ]||(i.writeHead(e.status,o),i.end());i[$r]?.()},yJ=(e,i={})=>{const n=i.autoCleanupIncoming??!0;return i.overrideGlobalObjects!==!1&&global.Request!==Na&&(Object.defineProperty(global,"Request",{value:Na}),Object.defineProperty(global,"Response",{value:fn})),async(o,a)=>{let t,s,r=!1,u=!1;const d=()=>{!s||u||(u=!0,a.on("close",hJ(s,o,a,r)))};try{if(s=tJ(o,i.hostname),r=n&&!(o.method==="GET"||o.method==="HEAD"),r&&(o[ob]=!0,o instanceof zt&&(a[$r]=()=>{o.readableEnded||setTimeout(()=>{o.readableEnded||setTimeout(()=>{o.destroy(),a.destroy()})})})),t=e(s,{incoming:o,outgoing:a}),!hb(t)&&cJ(t))return r&&!o.readableEnded&&a.once("finish",()=>{o.readableEnded||db(o)}),gb(t,a);d()}catch(l){if(t)return Zr(l,a);if(i.errorHandler){if(d(),t=await i.errorHandler(s?l:IZ(l)),!t)return}else s?t=lb(l):t=pJ()}try{return await vJ(t,a,i)}catch(l){return Zr(l,a)}}},fJ=Symbol("CONNECTION_SYMBOL_KEY"),mJ=Symbol("WAIT_FOR_WEBSOCKET_SYMBOL"),bJ=new Set(["connection","content-length","keep-alive","proxy-authenticate","proxy-authorization","te","trailer","transfer-encoding","upgrade","sec-websocket-accept","sec-websocket-extensions","sec-websocket-protocol"]),cb=(e,i)=>{i&&i.forEach((n,o)=>{bJ.has(o.toLowerCase())||e.push(`${o}: ${n}`)})},ev=(e,i,n)=>{const o=["Connection: close","Content-Length: 0"];cb(o,n),e.end(`HTTP/1.1 ${i.toString()} ${wY[i]??""}\r
7
7
  ${o.join(`\r
8
8
  `)}\r
9
9
  \r
@@ -12,7 +12,7 @@ ${o.join(`\r
12
12
  `);for(const a of["event","id","retry"])if(i[a]&&/[\r\n]/.test(i[a]))throw new Error(`${a} must not contain "\\r" or "\\n"`);const o=[i.event&&`event: ${i.event}`,n,i.id&&`id: ${i.id}`,i.retry&&`retry: ${i.retry}`].filter(Boolean).join(`
13
13
  `)+`
14
14
 
15
- `;await this.write(o)}},ux=async(e,i,n)=>{try{await i(e)}catch(o){console.error(o)}finally{e.close()}},dx=new WeakMap,lx=(e,i,n)=>{const{readable:o,writable:a}=new TransformStream,t=new rx(a,o);return Zb()&&e.req.raw.signal.addEventListener("abort",()=>{t.closed||t.abort()}),dx.set(t.responseReadable,e),e.header("Transfer-Encoding","chunked"),e.header("Content-Type","text/event-stream"),e.header("Cache-Control","no-cache"),e.header("Connection","keep-alive"),ux(t,i),e.newResponse(t.responseReadable)};const Za=(1n<<128n)-1n,K=(1n<<64n)-1n,xr=(1n<<32n)-1n,Jb=0x9E3779B1n,xb=0x85EBCA77n,gx=0xC2B2AE3Dn,to=0x9E3779B185EBCA87n,Oo=0xC2B2AE3D27D4EB4Fn,Tb=0x165667B19E3779F9n,oh=0x85EBCA77C2B2AE63n,hx=0x27D4EB2F165667C5n,cx=0x165667919E3779F9n,px=0x9FB21C651E98DF25n,Xn=64,Db=Xn/8,vx=8,Pi=Buffer.from("b8fe6c3923a44bbe7c01812cf721ad1cded46de9839097db7240a4a4b7b3671fcb79e64eccc0e578825ad07dccff7221b8084674f743248ee03590e6813a264c3c2852bb91c300cb88d0658b1b532ea371644897a20df94e3819ef46a9deacd8a8fa763fe39c343ff9dcbbc7c70b4f1d8a51e04bcdb45931c89f7ec9d9787364eac5ac8334d3ebc3c581a0fffa1363eb170ddd51b7f0da49d316552629d4689e2b16be587d47a1fc8ff8b8d17ad031ce45cb3a8f95160428afd7fbcabb4b407e","hex"),Si=(e,i=0)=>Buffer.from(e.buffer,e.byteOffset+i,e.length-i),yx=e=>{let i=e&K;return i=(i&0x00000000FFFFFFFFn)<<32n|(i&0xFFFFFFFF00000000n)>>32n,i=(i&0x0000FFFF0000FFFFn)<<16n|(i&0xFFFF0000FFFF0000n)>>16n,i=(i&0x00FF00FF00FF00FFn)<<8n|(i&0xFF00FF00FF00FF00n)>>8n,i&K},fx=e=>{let i=e;return i=(i&0x0000FFFFn)<<16n|(i&0xFFFF0000n)>>16n,i=(i&0x00FF00FFn)<<8n|(i&0xFF00FF00n)>>8n,i},mx=(e,i)=>(e&xr)*(i&xr)&K,bx=(e,i)=>(e<<i|e>>32n-i)&xr,Ql=(e,i)=>e^e>>i,Wl=e=>~e+1n&K,Bb=(e,i)=>{const n=e*i&Za;return n&K^n>>64n},yn=e=>{let i=e;return i^=i>>37n,i=i*cx&K,i^=i>>32n,i},Tr=e=>{let i=e;return i^=i>>33n,i=i*Oo&K,i^=i>>29n,i=i*Tb&K,i^=i>>32n,i},Xb=(e,i,n,o=0,a=0)=>{for(let t=0;t<Db;t++){const s=i.readBigUInt64LE(o+t*8),r=s^n.readBigUInt64LE(a+t*8);e[t^1]+=s,e[t]+=mx(r,r>>32n)}return e},av=(e,i,n,o,a=0)=>{for(let t=0;t<o;t++)Xb(e,i,n,a+t*Xn,t*8);return e},wx=(e,i,n=0)=>{for(let o=0;o<Db;o++){const a=i.readBigUInt64LE(n+o*8);let t=e[o];t=Ql(t,47n),t^=a,t*=Jb,e[o]=t&K}return e},Ws=(e,i,n,o)=>Bb(e[i]^n.readBigUInt64LE(o),e[i+1]^n.readBigUInt64LE(o+vx)),tv=(e,i,n,o)=>{let a=o;return a+=Ws(e,0,i,n+0),a+=Ws(e,2,i,n+16),a+=Ws(e,4,i,n+32),a+=Ws(e,6,i,n+48),yn(a&K)},jx=(e,i,n)=>{const o=Math.floor((n.byteLength-Xn)/8),a=Xn*o,t=Math.floor((i.byteLength-1)/a);for(let r=0;r<t;r++)av(e,i,n,o,r*a),wx(e,n,n.byteLength-Xn);const s=Math.floor((i.byteLength-1-a*t)/Xn);return av(e,i,n,s,t*a),Xb(e,i,n,i.byteLength-Xn,n.byteLength-Xn-7),e},kx=e=>{const i=Buffer.from(Pi),n=Pi.byteLength>>4;for(let o=0;o<n;o++){const a=i.readBigUInt64LE(o*16)+e&K,t=i.readBigUInt64LE(o*16+8)-e&K;i.writeBigUInt64LE(a,o*16),i.writeBigUInt64LE(t,o*16+8)}return i},Sx=(e,i)=>{const n=new BigUint64Array([gx,to,Oo,Tb,oh,xb,hx,Jb]);jx(n,e,i);const o=tv(n,i,11,BigInt(e.byteLength)*to&K);return tv(n,i,i.byteLength-Xn-11,~(BigInt(e.byteLength)*Oo)&K)<<64n|o},sv=(e,i,n)=>Bb((e.readBigUInt64LE(0)^i.readBigUInt64LE(0)+n)&K,(e.readBigUInt64LE(8)^i.readBigUInt64LE(8)-n)&K),dr=(e,i,n,o,a)=>{let t=e&K,s=e>>64n&K;return t+=sv(i,o,a),t^=n.readBigUInt64LE(0)+n.readBigUInt64LE(8),t&=K,s+=sv(n,Si(o,16),a),s^=i.readBigUInt64LE(0)+i.readBigUInt64LE(8),s&=K,s<<64n|t},Lx=(e,i,n)=>{const o=e.byteLength,a=BigInt(e.readUInt8(o-1))|BigInt(o)<<8n|BigInt(e.readUInt8(0))<<16n|BigInt(e.readUInt8(o>>1))<<24n,t=(BigInt(i.readUInt32LE(0))^BigInt(i.readUInt32LE(4)))+n,s=(a^t)&K,r=(BigInt(i.readUInt32LE(8))^BigInt(i.readUInt32LE(12)))-n,u=(bx(fx(a),13n)^r)&K;return(Tr(u)&K)<<64n|Tr(s)},Cx=(e,i,n)=>{const o=e.byteLength,a=e.readUInt32LE(0),t=e.readUInt32LE(o-4),s=BigInt(a)|BigInt(t)<<32n,r=(i.readBigUInt64LE(16)^i.readBigUInt64LE(24))+n&K;let u=(s^r)*(to+(BigInt(o)<<2n))&Za;return u+=(u&K)<<65n,u&=Za,u^=u>>67n,Ql(Ql(u&K,35n)*px&K,28n)|yn(u>>64n)<<64n},Yx=(e,i,n)=>{const o=e.byteLength,a=(i.readBigUInt64LE(32)^i.readBigUInt64LE(40))+n&K,t=(i.readBigUInt64LE(48)^i.readBigUInt64LE(56))-n&K,s=e.readBigUInt64LE();let r=e.readBigUInt64LE(o-8),u=(s^r^a)*to;const d=(u&K)+(BigInt(o-1)<<54n);u=u&(Za^K)|d,r^=t,u+=r+(r&xr)*(xb-1n)<<64n,u&=Za,u^=yx(u>>64n);let l=(u&K)*Oo;return l+=(u>>64n)*Oo<<64n,l&=Za,yn(l&K)|yn(l>>64n)<<64n},$x=(e,i)=>{const n=e.byteLength;return n>8?Yx(e,Pi,i):n>=4?Cx(e,Pi,i):n>0?Lx(e,Pi,i):Tr(i^Pi.readBigUInt64LE(64)^Pi.readBigUInt64LE(72))|Tr(i^Pi.readBigUInt64LE(80)^Pi.readBigUInt64LE(88))<<64n},Zx=(e,i,n)=>{let o=BigInt(e.byteLength)*to&K,a=BigInt(e.byteLength-1)/32n;for(;a>=0n;){const r=Number(a);o=dr(o,Si(e,16*r),Si(e,e.byteLength-16*(r+1)),Si(i,32*r),n),a--}let t=o+(o>>64n)&K;t=yn(t);let s=(o&K)*to+(o>>64n)*oh+(BigInt(e.byteLength)-n&K)*Oo;return s&=K,s=Wl(yn(s)),t|s<<64n},Jx=(e,i,n)=>{let o=BigInt(e.byteLength)*to&K;for(let s=32;s<160;s+=32)o=dr(o,Si(e,s-32),Si(e,s-16),Si(i,s-32),n);o=yn(o&K)|yn(o>>64n)<<64n;for(let s=160;s<=e.byteLength;s+=32)o=dr(o,Si(e,s-32),Si(e,s-16),Si(i,3+s-160),n);o=dr(o,Si(e,e.byteLength-16),Si(e,e.byteLength-32),Si(i,103),Wl(n));let a=o+(o>>64n)&K;a=yn(a);let t=(o&K)*to+(o>>64n)*oh+(BigInt(e.byteLength)-n&K)*Oo;return t&=K,t=Wl(yn(t)),a|t<<64n},xx=(e,i=0n)=>{const n=e.byteLength;return n<=16?$x(e,i):n<=128?Zx(e,Pi,i):n<=240?Jx(e,Pi,i):Sx(e,i===0n?Pi:kx(i))},Tx=e=>{const i=e>>64n&K,n=e&K;return i.toString(16).padStart(16,"0")+n.toString(16).padStart(16,"0")},Hb=(e,i=0n)=>Tx(xx(typeof e=="string"?Buffer.from(e):e,i)),Vo=()=>L(yY(),"ai"),Dx=3600*1e3,Bx=1800*1e3,Mb=()=>{vo(Vo())},Pb=(e,i)=>{const n=`${e}.${String(process.pid)}.${CY()}.tmp`;try{He(n,i,"utf8"),_f(n,e)}catch(o){try{yo(n)}catch{}throw o}},F1e=(e,i,n)=>{const o=n.map(t=>({currentRange:t.currentRange,name:t.packageName,targetVersion:t.targetVersion})).toSorted((t,s)=>t.name.localeCompare(s.name)),a=JSON.stringify({analysisType:i,packages:o,provider:e});return Hb(Buffer.from(a))},Q1e=e=>{const i=L(Vo(),`${e}.json`);if(Z(i))try{const n=Qe(i);if(Date.now()-n.createdAt>n.ttlMs){Ma(i,{force:!0});return}return n.result}catch{Ma(i,{force:!0});return}},W1e=(e,i,n)=>{Mb();const o=Vo(),a={createdAt:Date.now(),result:i,ttlMs:n};Pb(L(o,`${e}.json`),JSON.stringify(a,void 0,2))},I1e=(e,i)=>i!==void 0&&i>0?i:e==="security"?Bx:Dx,Il=()=>{const e=Vo();if(!Z(e))return{entries:0,newestEntry:void 0,oldestEntry:void 0,totalSizeBytes:0};const i=Fi(e).filter(t=>t.endsWith(".json"));let n=0,o,a;for(const t of i){const s=L(e,t),r=Eo(s);n+=r.size;const{mtimeMs:u}=r;(o===void 0||u<o)&&(o=u),(a===void 0||u>a)&&(a=u)}return{entries:i.length,newestEntry:a,oldestEntry:o,totalSizeBytes:n}},_1e=e=>Hb(Buffer.from(JSON.stringify(e))),z1e=e=>{const i=L(Vo(),`${e}.json`);if(Z(i))try{const n=Qe(i);if(Date.now()-n.createdAt>n.ttlMs){Ma(i,{force:!0});return}return n.result}catch{Ma(i,{force:!0});return}},K1e=(e,i,n)=>{Mb();const o=Vo(),a={createdAt:Date.now(),result:i,ttlMs:n};Pb(L(o,`${e}.json`),JSON.stringify(a,void 0,2))},Xx=()=>{const e=Vo();if(!Z(e))return 0;const i=Fi(e).filter(n=>n.endsWith(".json"));for(const n of i)Ma(L(e,n),{force:!0});return i.length},Hx=wn(import.meta.url),ca=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,Kr=e=>{if(typeof ca<"u"&&ca.versions&&ca.versions.node){const[i,n]=ca.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return ca.getBuiltinModule(e)}return Hx(e)},{createRequire:Nb}=Kr("node:module"),Ho=ca,{execFileSync:Mx}=Kr("node:child_process"),Ft=Kr("node:fs"),Px=Kr("node:tty"),Nx=[161,161,164,164,167,168,170,170,173,174,176,180,182,186,188,191,198,198,208,208,215,216,222,225,230,230,232,234,236,237,240,240,242,243,247,250,252,252,254,254,257,257,273,273,275,275,283,283,294,295,299,299,305,307,312,312,319,322,324,324,328,331,333,333,338,339,358,359,363,363,462,462,464,464,466,466,468,468,470,470,472,472,474,474,476,476,593,593,609,609,708,708,711,711,713,715,717,717,720,720,728,731,733,733,735,735,768,879,913,929,931,937,945,961,963,969,1025,1025,1040,1103,1105,1105,8208,8208,8211,8214,8216,8217,8220,8221,8224,8226,8228,8231,8240,8240,8242,8243,8245,8245,8251,8251,8254,8254,8308,8308,8319,8319,8321,8324,8364,8364,8451,8451,8453,8453,8457,8457,8467,8467,8470,8470,8481,8482,8486,8486,8491,8491,8531,8532,8539,8542,8544,8555,8560,8569,8585,8585,8592,8601,8632,8633,8658,8658,8660,8660,8679,8679,8704,8704,8706,8707,8711,8712,8715,8715,8719,8719,8721,8721,8725,8725,8730,8730,8733,8736,8739,8739,8741,8741,8743,8748,8750,8750,8756,8759,8764,8765,8776,8776,8780,8780,8786,8786,8800,8801,8804,8807,8810,8811,8814,8815,8834,8835,8838,8839,8853,8853,8857,8857,8869,8869,8895,8895,8978,8978,9312,9449,9451,9547,9552,9587,9600,9615,9618,9621,9632,9633,9635,9641,9650,9651,9654,9655,9660,9661,9664,9665,9670,9672,9675,9675,9678,9681,9698,9701,9711,9711,9733,9734,9737,9737,9742,9743,9756,9756,9758,9758,9792,9792,9794,9794,9824,9825,9827,9829,9831,9834,9836,9837,9839,9839,9886,9887,9919,9919,9926,9933,9935,9939,9941,9953,9955,9955,9960,9961,9963,9969,9972,9972,9974,9977,9979,9980,9982,9983,10045,10045,10102,10111,11094,11097,12872,12879,57344,63743,65024,65039,65533,65533,127232,127242,127248,127277,127280,127337,127344,127373,127375,127376,127387,127404,917760,917999,983040,1048573,1048576,1114109],Ex=12288,Rx=65510,Ox=[12288,12288,65281,65376,65504,65510],Ax=8361,Gx=65518,Fx=[8361,8361,65377,65470,65474,65479,65482,65487,65490,65495,65498,65500,65512,65518],Qx=32,Wx=10630,Ix=[32,126,162,163,165,166,172,172,175,175,10214,10221,10629,10630],_x=4352,zx=262141,Eb=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141],Cs=(e,i)=>{let n=0,o=Math.floor(e.length/2)-1;for(;n<=o;){const a=Math.floor((n+o)/2),t=a*2;if(i<e[t])o=a-1;else if(i>e[t+1])n=a+1;else return!0}return!1},rv=19968,[Kx,qx]=Ux(Eb);function Ux(e){let i=e[0],n=e[1];for(let o=0;o<e.length;o+=2){const a=e[o],t=e[o+1];if(rv>=a&&rv<=t)return[a,t];t-a>n-i&&(i=a,n=t)}return[i,n]}const Vx=e=>e<161||e>1114109?!1:Cs(Nx,e),eT=e=>e<Ex||e>Rx?!1:Cs(Ox,e),iT=e=>e<Ax||e>Gx?!1:Cs(Fx,e),nT=e=>e<Qx||e>Wx?!1:Cs(Ix,e),oT=e=>e>=Kx&&e<=qx?!0:e<_x||e>zx?!1:Cs(Eb,e);function aT(e){return Vx(e)?"ambiguous":eT(e)?"fullwidth":iT(e)?"halfwidth":nT(e)?"narrow":oT(e)?"wide":"neutral"}function tT(e){if(!Number.isSafeInteger(e))throw new TypeError(`Expected a code point, got \`${typeof e}\`.`)}function Rb(e){return tT(e),aT(e)}const Ob=String.raw,uv=Ob`\p{Emoji}(?:\p{EMod}|[\u{E0020}-\u{E007E}]+\u{E007F}|\uFE0F?\u20E3?)`,sT=()=>new RegExp(Ob`\p{RI}{2}|(?![#*\d](?!\uFE0F?\u20E3))${uv}(?:\u200D${uv})*`,"gu"),Wa=new Set(["\x1B","›"]),qr="\x07",Ab="[",ah="m",ss="]8;;",rT=39,uT=/[\u200B\uFEFF\u2060-\u2064]/g,dT=new RegExp(`(?:\\${Ab}(?<code>\\d+)m|\\${ss}(?<uri>.*)${qr})`),lT=Object.freeze(new Map([[0,0],[1,22],[2,22],[3,23],[4,24],[7,27],[8,28],[9,29],[30,39],[31,39],[32,39],[33,39],[34,39],[35,39],[36,39],[37,39],[40,49],[41,49],[42,49],[43,49],[44,49],[45,49],[46,49],[47,49],[90,39]])),gT=/^[ \t]*(?:\r\n|\r|\n)/,hT=/(?:\r\n|\r|\n)[ \t]*$/,cT=/^(?:[\r\n]|$)/,pT=/(?:\r\n|\r|\n)([ \t]*)(?:[^ \t\r\n]|$)/,vT=/^[ \t]*[\r\n][ \t\r\n]*$/,yT=/\r\n|\n|\r/g,Ct=/[\u001B\u009B](?:[[()#;?]{0,10}(?:\d{1,4}(?:;\d{0,4})*)?[0-9A-ORZcf-nqry=><]|\]8;;[^\u0007\u001B]{0,100}(?:\u0007|\u001B\\))/g,Is=/[\u0000-\u0008\n-\u001F\u007F-\u009F]{1,1000}/y,$d=sT(),dv=new Map,fT=e=>[e.ambiguousIsNarrow?1:0,e.control,e.fullWidth,e.regular,e.wide].join("|"),mT=e=>{const i=fT(e.width);let n=dv.get(i);return n||(n=new Map,dv.set(i,n)),n},_s=/(?:[\u0020-\u007E\u00A0-\u00FF](?!\uFE0F)){1,1000}/y,Gb=e=>e>=32&&e<=126?"latin":e===8203||e===8204||e===8205||e===8288?"zero":e<=31||e>=127&&e<=159?"control":e>=160&&e<=255||e>=9472&&e<=9599?"latin":e>=4352&&e<=4607||e>=11904&&e<=40959||e>=44032&&e<=55215||e>=63744&&e<=64255||e>=65280&&e<=65519&&!(e>=65377&&e<=65439)||e>=12352&&e<=12543?"wide":e===8230?"latin":"other",bT=(e,i)=>{const n=mT(i),o=Math.floor(e/65536),a=e%65536;let t=n.get(o);if(t||(t=new Map,n.set(o,t)),t.has(a))return t.get(a);let s;switch(Gb(e)){case"control":{s=i.width.control;break}case"latin":{s=i.width.regular;break}case"wide":{s=i.width.wide;break}case"zero":{s=0;break}default:switch(Rb(e)){case"ambiguous":{s=i.width.ambiguousIsNarrow?i.width.regular:i.width.wide;break}case"fullwidth":{s=i.width.fullWidth;break}case"wide":{s=i.width.wide;break}default:s=i.width.regular}}return t.set(a,s),s},wT=e=>e>=768&&e<=879||e>=6832&&e<=6911||e>=7616&&e<=7679||e>=8400&&e<=8447||e>=65056&&e<=65071||e>=917760&&e<=917999||e>=65024&&e<=65039||e>=3633&&e<=3642||e>=3655&&e<=3662||e>=3761&&e<=3769||e>=3771&&e<=3772||e>=3784&&e<=3789||e>=2304&&e<=2307||e>=2362&&e<=2383||e>=2385&&e<=2391||e>=2402&&e<=2403||e>=2433&&e<=2435||e>=2492&&e<=2500||e>=2509&&e<=2509||e>=2561&&e<=2563||e>=2620&&e<=2637||e>=1611&&e<=1631||e>=1648&&e<=1648||e>=1750&&e<=1773||e>=2276&&e<=2302||e>=1425&&e<=1469||e>=1471&&e<=1471||e>=1473&&e<=1474||e>=1476&&e<=1477||e>=1479&&e<=1479||e>=3893&&e<=3893||e>=3895&&e<=3895||e>=3897&&e<=3897||e>=3953&&e<=3966||e>=3968&&e<=3972||e>=3974&&e<=3975?!0:e>=768&&e<=777||e>=803&&e<=803,_l=(e,i={})=>{if(!e||e.length===0)return{ellipsed:!1,index:0,truncated:!1,width:0};const n={truncation:{countAnsiEscapeCodes:i.countAnsiEscapeCodes??!1,ellipsis:i.ellipsis??"",ellipsisWidth:i.ellipsisWidth??(i.ellipsis?_l(i.ellipsis,{...i,ellipsis:"",ellipsisWidth:0,limit:Number.POSITIVE_INFINITY}).width:0),limit:i.limit??Number.POSITIVE_INFINITY},width:{ambiguousIsNarrow:i.ambiguousIsNarrow??!1,ansi:i.ansiWidth??0,control:i.controlWidth??0,emoji:i.emojiWidth??2,fullWidth:i.fullWidth??2,halfWidth:i.halfWidth??1,regular:i.regularWidth??1,tab:i.tabWidth??8,wide:i.wideWidth??2}},o=Math.max(0,n.truncation.limit-n.truncation.ellipsisWidth),{length:a}=e,t=a>1e4;let s=0,r=0,u=a,d=!1;const l=e.includes("\x1B")||e.includes("›");for(;s<a;){if(l&&(e[s]==="\x1B"||e[s]==="›")){if(e.startsWith("\x1B]8;;",s)){const w="\x1B]8;;\x07",v=w.length,j=e.indexOf("\x07",s+5);if(j!==-1){const C=e.indexOf(w,j+1);if(C!==-1){const y=C+v,k=e.slice(j+1,C).replace(Ct,""),S=_l(k,{ambiguousIsNarrow:n.width.ambiguousIsNarrow,ansiWidth:n.width.ansi,controlWidth:n.width.control,countAnsiEscapeCodes:!1,ellipsis:n.truncation.ellipsis,ellipsisWidth:n.truncation.ellipsisWidth,emojiWidth:n.width.emoji,fullWidth:n.width.fullWidth,halfWidth:n.width.halfWidth,limit:Math.max(0,o-r),regularWidth:n.width.regular,tabWidth:n.width.tab,wideWidth:n.width.wide}),J=S.width;if(S.truncated)d=!0,u=Math.min(u,s);else if(r+J>o&&(u=Math.min(u,s),d=!0,r+J>n.truncation.limit))break;if(r+=J,s=y,d&&r>=n.truncation.limit)break;continue}}}if(Ct.lastIndex=s,Ct.test(e)){const w=Ct.lastIndex-s,v=n.truncation.countAnsiEscapeCodes?w:n.width.ansi;if(r+v>o&&(u=Math.min(u,s),r+v>n.truncation.limit)){d=!0;break}r+=v,s=Ct.lastIndex;continue}}const c=e.codePointAt(s);if(c===8203||c===65279||c>=8288&&c<=8292){s+=1;continue}if(c===9){if(r+n.width.tab>o&&(u=Math.min(u,s),r+n.width.tab>n.truncation.limit)){d=!0;break}r+=n.width.tab,s+=1;continue}if(_s.lastIndex=s,_s.test(e)){const w=(_s.lastIndex-s)*n.width.regular;if(r+w>o){const v=Math.floor((o-r)/n.width.regular);if(u=Math.min(u,s+v),r+w>n.truncation.limit){d=!0;break}}r+=w,s=_s.lastIndex;continue}if((c<=31||c>=127&&c<=159)&&(Is.lastIndex=s,Is.test(e))){const w=(Is.lastIndex-s)*n.width.control;if(r+w>o&&(u=Math.min(u,s+Math.floor((o-r)/n.width.control)),r+w>n.truncation.limit)){d=!0;break}r+=w,s=Is.lastIndex;continue}if($d.lastIndex=s,$d.test(e)){if(r+n.width.emoji>o&&(u=Math.min(u,s),r+n.width.emoji>n.truncation.limit)){d=!0;break}r+=n.width.emoji,s=$d.lastIndex;continue}const p=e.codePointAt(s)??0;if(wT(p)){s+=p>65535?2:1;continue}let f;if(t)f=bT(p,n);else switch(Gb(p)){case"control":{f=n.width.control;break}case"latin":{f=n.width.regular;break}case"wide":{f=n.width.wide;break}case"zero":{f=0;break}default:switch(Rb(p)){case"ambiguous":{f=n.width.ambiguousIsNarrow?n.width.regular:n.width.wide;break}case"fullwidth":{f=n.width.fullWidth;break}case"wide":{f=n.width.wide;break}default:f=n.width.regular}}if(r+f>o&&(u=Math.min(u,s),r+f>n.truncation.limit)){d=!0;break}r+=f,s+=p>65535?2:1}let g=r,h=!1;return d&&n.truncation.limit>=n.truncation.ellipsisWidth&&(g=n.truncation.limit,h=!0),{ellipsed:h,index:d?u:a,truncated:d,width:g}},so=(e,i={})=>_l(e,{...i,ellipsis:"",ellipsisWidth:0,limit:Number.POSITIVE_INFINITY}).width,jT=Nb(import.meta.url),Yt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,kT=e=>{if(typeof Yt<"u"&&Yt.versions&&Yt.versions.node){const[i,n]=Yt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return Yt.getBuiltinModule(e)}return jT(e)};kT("node:util");const ST=new Uint8Array(128),LT=new Uint8Array(128),CT=new Uint8Array(128);for(let e=0;e<128;e++)ST[e]=e>=65&&e<=90?1:0,LT[e]=e>=97&&e<=122?1:0,CT[e]=e>=48&&e<=57?1:0;const YT=Nb(import.meta.url),$t=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,$T=e=>{if(typeof $t<"u"&&$t.versions&&$t.versions.node){const[i,n]=$t.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return $t.getBuiltinModule(e)}return YT(e)};$T("node:util");function ZT(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Zd,lv;function JT(){if(lv)return Zd;lv=1,Zd=i;function e(o){return o instanceof Buffer?Buffer.from(o):new o.constructor(o.buffer.slice(),o.byteOffset,o.length)}function i(o){if(o=o||{},o.circles)return n(o);const a=new Map;if(a.set(Date,d=>new Date(d)),a.set(Map,(d,l)=>new Map(s(Array.from(d),l))),a.set(Set,(d,l)=>new Set(s(Array.from(d),l))),o.constructorHandlers)for(const d of o.constructorHandlers)a.set(d[0],d[1]);let t=null;return o.proto?u:r;function s(d,l){const g=Object.keys(d),h=new Array(g.length);for(let c=0;c<g.length;c++){const p=g[c],f=d[p];typeof f!="object"||f===null?h[p]=f:f.constructor!==Object&&(t=a.get(f.constructor))?h[p]=t(f,l):ArrayBuffer.isView(f)?h[p]=e(f):h[p]=l(f)}return h}function r(d){if(typeof d!="object"||d===null)return d;if(Array.isArray(d))return s(d,r);if(d.constructor!==Object&&(t=a.get(d.constructor)))return t(d,r);const l={};for(const g in d){if(Object.hasOwnProperty.call(d,g)===!1)continue;const h=d[g];typeof h!="object"||h===null?l[g]=h:h.constructor!==Object&&(t=a.get(h.constructor))?l[g]=t(h,r):ArrayBuffer.isView(h)?l[g]=e(h):l[g]=r(h)}return l}function u(d){if(typeof d!="object"||d===null)return d;if(Array.isArray(d))return s(d,u);if(d.constructor!==Object&&(t=a.get(d.constructor)))return t(d,u);const l={};for(const g in d){const h=d[g];typeof h!="object"||h===null?l[g]=h:h.constructor!==Object&&(t=a.get(h.constructor))?l[g]=t(h,u):ArrayBuffer.isView(h)?l[g]=e(h):l[g]=u(h)}return l}}function n(o){const a=[],t=[],s=new Map;if(s.set(Date,g=>new Date(g)),s.set(Map,(g,h)=>new Map(u(Array.from(g),h))),s.set(Set,(g,h)=>new Set(u(Array.from(g),h))),o.constructorHandlers)for(const g of o.constructorHandlers)s.set(g[0],g[1]);let r=null;return o.proto?l:d;function u(g,h){const c=Object.keys(g),p=new Array(c.length);for(let f=0;f<c.length;f++){const w=c[f],v=g[w];if(typeof v!="object"||v===null)p[w]=v;else if(v.constructor!==Object&&(r=s.get(v.constructor)))p[w]=r(v,h);else if(ArrayBuffer.isView(v))p[w]=e(v);else{const j=a.indexOf(v);j!==-1?p[w]=t[j]:p[w]=h(v)}}return p}function d(g){if(typeof g!="object"||g===null)return g;if(Array.isArray(g))return u(g,d);if(g.constructor!==Object&&(r=s.get(g.constructor)))return r(g,d);const h={};a.push(g),t.push(h);for(const c in g){if(Object.hasOwnProperty.call(g,c)===!1)continue;const p=g[c];if(typeof p!="object"||p===null)h[c]=p;else if(p.constructor!==Object&&(r=s.get(p.constructor)))h[c]=r(p,d);else if(ArrayBuffer.isView(p))h[c]=e(p);else{const f=a.indexOf(p);f!==-1?h[c]=t[f]:h[c]=d(p)}}return a.pop(),t.pop(),h}function l(g){if(typeof g!="object"||g===null)return g;if(Array.isArray(g))return u(g,l);if(g.constructor!==Object&&(r=s.get(g.constructor)))return r(g,l);const h={};a.push(g),t.push(h);for(const c in g){const p=g[c];if(typeof p!="object"||p===null)h[c]=p;else if(p.constructor!==Object&&(r=s.get(p.constructor)))h[c]=r(p,l);else if(ArrayBuffer.isView(p))h[c]=e(p);else{const f=a.indexOf(p);f!==-1?h[c]=t[f]:h[c]=l(p)}}return a.pop(),t.pop(),h}}return Zd}var xT=JT();const Fb=ZT(xT);Fb();var Qb=typeof global=="object"&&global&&global.Object===Object&&global,TT=typeof self=="object"&&self&&self.Object===Object&&self,_e=Qb||TT||Function("return this")(),oi=_e.Symbol,Wb=Object.prototype,DT=Wb.hasOwnProperty,BT=Wb.toString,Zt=oi?oi.toStringTag:void 0;function XT(e){var i=DT.call(e,Zt),n=e[Zt];try{e[Zt]=void 0;var o=!0}catch{}var a=BT.call(e);return o&&(i?e[Zt]=n:delete e[Zt]),a}var HT=Object.prototype,MT=HT.toString;function PT(e){return MT.call(e)}var NT="[object Null]",ET="[object Undefined]",gv=oi?oi.toStringTag:void 0;function di(e){return e==null?e===void 0?ET:NT:gv&&gv in Object(e)?XT(e):PT(e)}function Ne(e){return e!=null&&typeof e=="object"}var RT="[object Symbol]";function Li(e){return typeof e=="symbol"||Ne(e)&&di(e)==RT}var OT=NaN;function hv(e){return typeof e=="number"?e:Li(e)?OT:+e}function De(e,i){for(var n=-1,o=e==null?0:e.length,a=Array(o);++n<o;)a[n]=i(e[n],n,e);return a}var oe=Array.isArray,cv=oi?oi.prototype:void 0,pv=cv?cv.toString:void 0;function Ci(e){if(typeof e=="string")return e;if(oe(e))return De(e,Ci)+"";if(Li(e))return pv?pv.call(e):"";var i=e+"";return i=="0"&&1/e==-1/0?"-0":i}function Ur(e,i){return function(n,o){var a;if(n===void 0&&o===void 0)return i;if(n!==void 0&&(a=n),o!==void 0){if(a===void 0)return o;typeof n=="string"||typeof o=="string"?(n=Ci(n),o=Ci(o)):(n=hv(n),o=hv(o)),a=e(n,o)}return a}}var AT=Ur(function(e,i){return e+i},0),GT=/\s/;function Ib(e){for(var i=e.length;i--&&GT.test(e.charAt(i)););return i}var FT=/^\s+/;function _b(e){return e&&e.slice(0,Ib(e)+1).replace(FT,"")}function Me(e){var i=typeof e;return e!=null&&(i=="object"||i=="function")}var vv=NaN,QT=/^[-+]0x[0-9a-f]+$/i,WT=/^0b[01]+$/i,IT=/^0o[0-7]+$/i,_T=parseInt;function Ri(e){if(typeof e=="number")return e;if(Li(e))return vv;if(Me(e)){var i=typeof e.valueOf=="function"?e.valueOf():e;e=Me(i)?i+"":i}if(typeof e!="string")return e===0?e:+e;e=_b(e);var n=WT.test(e);return n||IT.test(e)?_T(e.slice(2),n?2:8):QT.test(e)?vv:+e}var yv=1/0,zT=17976931348623157e292;function Pn(e){if(!e)return e===0?e:0;if(e=Ri(e),e===yv||e===-yv){var i=e<0?-1:1;return i*zT}return e===e?e:0}function se(e){var i=Pn(e),n=i%1;return i===i?n?i-n:i:0}var KT="Expected a function";function qT(e,i){if(typeof i!="function")throw new TypeError(KT);return e=se(e),function(){if(--e<1)return i.apply(this,arguments)}}function fi(e){return e}var UT="[object AsyncFunction]",VT="[object Function]",eD="[object GeneratorFunction]",iD="[object Proxy]";function Rn(e){if(!Me(e))return!1;var i=di(e);return i==VT||i==eD||i==UT||i==iD}var lr=_e["__core-js_shared__"],fv=(function(){var e=/[^.]+$/.exec(lr&&lr.keys&&lr.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function nD(e){return!!fv&&fv in e}var oD=Function.prototype,aD=oD.toString;function ea(e){if(e!=null){try{return aD.call(e)}catch{}try{return e+""}catch{}}return""}var tD=/[\\^$.*+?()[\]{}|]/g,sD=/^\[object .+?Constructor\]$/,rD=Function.prototype,uD=Object.prototype,dD=rD.toString,lD=uD.hasOwnProperty,gD=RegExp("^"+dD.call(lD).replace(tD,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function zb(e){if(!Me(e)||nD(e))return!1;var i=Rn(e)?gD:sD;return i.test(ea(e))}function hD(e,i){return e?.[i]}function ia(e,i){var n=hD(e,i);return zb(n)?n:void 0}var rs=ia(_e,"WeakMap"),Dr=rs&&new rs,Kb=Dr?function(e,i){return Dr.set(e,i),e}:fi,mv=Object.create,Ia=(function(){function e(){}return function(i){if(!Me(i))return{};if(mv)return mv(i);e.prototype=i;var n=new e;return e.prototype=void 0,n}})();function us(e){return function(){var i=arguments;switch(i.length){case 0:return new e;case 1:return new e(i[0]);case 2:return new e(i[0],i[1]);case 3:return new e(i[0],i[1],i[2]);case 4:return new e(i[0],i[1],i[2],i[3]);case 5:return new e(i[0],i[1],i[2],i[3],i[4]);case 6:return new e(i[0],i[1],i[2],i[3],i[4],i[5]);case 7:return new e(i[0],i[1],i[2],i[3],i[4],i[5],i[6])}var n=Ia(e.prototype),o=e.apply(n,i);return Me(o)?o:n}}var cD=1;function pD(e,i,n){var o=i&cD,a=us(e);function t(){var s=this&&this!==_e&&this instanceof t?a:e;return s.apply(o?n:this,arguments)}return t}function Yi(e,i,n){switch(n.length){case 0:return e.call(i);case 1:return e.call(i,n[0]);case 2:return e.call(i,n[0],n[1]);case 3:return e.call(i,n[0],n[1],n[2])}return e.apply(i,n)}var vD=Math.max;function qb(e,i,n,o){for(var a=-1,t=e.length,s=n.length,r=-1,u=i.length,d=vD(t-s,0),l=Array(u+d),g=!o;++r<u;)l[r]=i[r];for(;++a<s;)(g||a<t)&&(l[n[a]]=e[a]);for(;d--;)l[r++]=e[a++];return l}var yD=Math.max;function Ub(e,i,n,o){for(var a=-1,t=e.length,s=-1,r=n.length,u=-1,d=i.length,l=yD(t-r,0),g=Array(l+d),h=!o;++a<l;)g[a]=e[a];for(var c=a;++u<d;)g[c+u]=i[u];for(;++s<r;)(h||a<t)&&(g[c+n[s]]=e[a++]);return g}function fD(e,i){for(var n=e.length,o=0;n--;)e[n]===i&&++o;return o}function Vr(){}var mD=4294967295;function ce(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=mD,this.__views__=[]}ce.prototype=Ia(Vr.prototype);ce.prototype.constructor=ce;function th(){}var sh=Dr?function(e){return Dr.get(e)}:th,Ja={},bD=Object.prototype,wD=bD.hasOwnProperty;function gr(e){for(var i=e.name+"",n=Ja[i],o=wD.call(Ja,i)?n.length:0;o--;){var a=n[o],t=a.func;if(t==null||t==e)return a.name}return i}function Qi(e,i){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!i,this.__index__=0,this.__values__=void 0}Qi.prototype=Ia(Vr.prototype);Qi.prototype.constructor=Qi;function vi(e,i){var n=-1,o=e.length;for(i||(i=Array(o));++n<o;)i[n]=e[n];return i}function Vb(e){if(e instanceof ce)return e.clone();var i=new Qi(e.__wrapped__,e.__chain__);return i.__actions__=vi(e.__actions__),i.__index__=e.__index__,i.__values__=e.__values__,i}var jD=Object.prototype,kD=jD.hasOwnProperty;function m(e){if(Ne(e)&&!oe(e)&&!(e instanceof ce)){if(e instanceof Qi)return e;if(kD.call(e,"__wrapped__"))return Vb(e)}return new Qi(e)}m.prototype=Vr.prototype;m.prototype.constructor=m;function zl(e){var i=gr(e),n=m[i];if(typeof n!="function"||!(i in ce.prototype))return!1;if(e===n)return!0;var o=sh(n);return!!o&&e===o[0]}var SD=800,LD=16,CD=Date.now;function ew(e){var i=0,n=0;return function(){var o=CD(),a=LD-(o-n);if(n=o,a>0){if(++i>=SD)return arguments[0]}else i=0;return e.apply(void 0,arguments)}}var iw=ew(Kb),YD=/\{\n\/\* \[wrapped with (.+)\] \*/,$D=/,? & /;function ZD(e){var i=e.match(YD);return i?i[1].split($D):[]}var JD=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;function xD(e,i){var n=i.length;if(!n)return e;var o=n-1;return i[o]=(n>1?"& ":"")+i[o],i=i.join(n>2?", ":" "),e.replace(JD,`{
15
+ `;await this.write(o)}},ux=async(e,i,n)=>{try{await i(e)}catch(o){console.error(o)}finally{e.close()}},dx=new WeakMap,lx=(e,i,n)=>{const{readable:o,writable:a}=new TransformStream,t=new rx(a,o);return Zb()&&e.req.raw.signal.addEventListener("abort",()=>{t.closed||t.abort()}),dx.set(t.responseReadable,e),e.header("Transfer-Encoding","chunked"),e.header("Content-Type","text/event-stream"),e.header("Cache-Control","no-cache"),e.header("Connection","keep-alive"),ux(t,i),e.newResponse(t.responseReadable)};const Za=(1n<<128n)-1n,K=(1n<<64n)-1n,xr=(1n<<32n)-1n,Jb=0x9E3779B1n,xb=0x85EBCA77n,gx=0xC2B2AE3Dn,to=0x9E3779B185EBCA87n,Oo=0xC2B2AE3D27D4EB4Fn,Tb=0x165667B19E3779F9n,oh=0x85EBCA77C2B2AE63n,hx=0x27D4EB2F165667C5n,cx=0x165667919E3779F9n,px=0x9FB21C651E98DF25n,Xn=64,Db=Xn/8,vx=8,Pi=Buffer.from("b8fe6c3923a44bbe7c01812cf721ad1cded46de9839097db7240a4a4b7b3671fcb79e64eccc0e578825ad07dccff7221b8084674f743248ee03590e6813a264c3c2852bb91c300cb88d0658b1b532ea371644897a20df94e3819ef46a9deacd8a8fa763fe39c343ff9dcbbc7c70b4f1d8a51e04bcdb45931c89f7ec9d9787364eac5ac8334d3ebc3c581a0fffa1363eb170ddd51b7f0da49d316552629d4689e2b16be587d47a1fc8ff8b8d17ad031ce45cb3a8f95160428afd7fbcabb4b407e","hex"),Si=(e,i=0)=>Buffer.from(e.buffer,e.byteOffset+i,e.length-i),yx=e=>{let i=e&K;return i=(i&0x00000000FFFFFFFFn)<<32n|(i&0xFFFFFFFF00000000n)>>32n,i=(i&0x0000FFFF0000FFFFn)<<16n|(i&0xFFFF0000FFFF0000n)>>16n,i=(i&0x00FF00FF00FF00FFn)<<8n|(i&0xFF00FF00FF00FF00n)>>8n,i&K},fx=e=>{let i=e;return i=(i&0x0000FFFFn)<<16n|(i&0xFFFF0000n)>>16n,i=(i&0x00FF00FFn)<<8n|(i&0xFF00FF00n)>>8n,i},mx=(e,i)=>(e&xr)*(i&xr)&K,bx=(e,i)=>(e<<i|e>>32n-i)&xr,Ql=(e,i)=>e^e>>i,Wl=e=>~e+1n&K,Bb=(e,i)=>{const n=e*i&Za;return n&K^n>>64n},yn=e=>{let i=e;return i^=i>>37n,i=i*cx&K,i^=i>>32n,i},Tr=e=>{let i=e;return i^=i>>33n,i=i*Oo&K,i^=i>>29n,i=i*Tb&K,i^=i>>32n,i},Xb=(e,i,n,o=0,a=0)=>{for(let t=0;t<Db;t++){const s=i.readBigUInt64LE(o+t*8),r=s^n.readBigUInt64LE(a+t*8);e[t^1]+=s,e[t]+=mx(r,r>>32n)}return e},av=(e,i,n,o,a=0)=>{for(let t=0;t<o;t++)Xb(e,i,n,a+t*Xn,t*8);return e},wx=(e,i,n=0)=>{for(let o=0;o<Db;o++){const a=i.readBigUInt64LE(n+o*8);let t=e[o];t=Ql(t,47n),t^=a,t*=Jb,e[o]=t&K}return e},Ws=(e,i,n,o)=>Bb(e[i]^n.readBigUInt64LE(o),e[i+1]^n.readBigUInt64LE(o+vx)),tv=(e,i,n,o)=>{let a=o;return a+=Ws(e,0,i,n+0),a+=Ws(e,2,i,n+16),a+=Ws(e,4,i,n+32),a+=Ws(e,6,i,n+48),yn(a&K)},jx=(e,i,n)=>{const o=Math.floor((n.byteLength-Xn)/8),a=Xn*o,t=Math.floor((i.byteLength-1)/a);for(let r=0;r<t;r++)av(e,i,n,o,r*a),wx(e,n,n.byteLength-Xn);const s=Math.floor((i.byteLength-1-a*t)/Xn);return av(e,i,n,s,t*a),Xb(e,i,n,i.byteLength-Xn,n.byteLength-Xn-7),e},kx=e=>{const i=Buffer.from(Pi),n=Pi.byteLength>>4;for(let o=0;o<n;o++){const a=i.readBigUInt64LE(o*16)+e&K,t=i.readBigUInt64LE(o*16+8)-e&K;i.writeBigUInt64LE(a,o*16),i.writeBigUInt64LE(t,o*16+8)}return i},Sx=(e,i)=>{const n=new BigUint64Array([gx,to,Oo,Tb,oh,xb,hx,Jb]);jx(n,e,i);const o=tv(n,i,11,BigInt(e.byteLength)*to&K);return tv(n,i,i.byteLength-Xn-11,~(BigInt(e.byteLength)*Oo)&K)<<64n|o},sv=(e,i,n)=>Bb((e.readBigUInt64LE(0)^i.readBigUInt64LE(0)+n)&K,(e.readBigUInt64LE(8)^i.readBigUInt64LE(8)-n)&K),dr=(e,i,n,o,a)=>{let t=e&K,s=e>>64n&K;return t+=sv(i,o,a),t^=n.readBigUInt64LE(0)+n.readBigUInt64LE(8),t&=K,s+=sv(n,Si(o,16),a),s^=i.readBigUInt64LE(0)+i.readBigUInt64LE(8),s&=K,s<<64n|t},Lx=(e,i,n)=>{const o=e.byteLength,a=BigInt(e.readUInt8(o-1))|BigInt(o)<<8n|BigInt(e.readUInt8(0))<<16n|BigInt(e.readUInt8(o>>1))<<24n,t=(BigInt(i.readUInt32LE(0))^BigInt(i.readUInt32LE(4)))+n,s=(a^t)&K,r=(BigInt(i.readUInt32LE(8))^BigInt(i.readUInt32LE(12)))-n,u=(bx(fx(a),13n)^r)&K;return(Tr(u)&K)<<64n|Tr(s)},Cx=(e,i,n)=>{const o=e.byteLength,a=e.readUInt32LE(0),t=e.readUInt32LE(o-4),s=BigInt(a)|BigInt(t)<<32n,r=(i.readBigUInt64LE(16)^i.readBigUInt64LE(24))+n&K;let u=(s^r)*(to+(BigInt(o)<<2n))&Za;return u+=(u&K)<<65n,u&=Za,u^=u>>67n,Ql(Ql(u&K,35n)*px&K,28n)|yn(u>>64n)<<64n},Yx=(e,i,n)=>{const o=e.byteLength,a=(i.readBigUInt64LE(32)^i.readBigUInt64LE(40))+n&K,t=(i.readBigUInt64LE(48)^i.readBigUInt64LE(56))-n&K,s=e.readBigUInt64LE();let r=e.readBigUInt64LE(o-8),u=(s^r^a)*to;const d=(u&K)+(BigInt(o-1)<<54n);u=u&(Za^K)|d,r^=t,u+=r+(r&xr)*(xb-1n)<<64n,u&=Za,u^=yx(u>>64n);let l=(u&K)*Oo;return l+=(u>>64n)*Oo<<64n,l&=Za,yn(l&K)|yn(l>>64n)<<64n},$x=(e,i)=>{const n=e.byteLength;return n>8?Yx(e,Pi,i):n>=4?Cx(e,Pi,i):n>0?Lx(e,Pi,i):Tr(i^Pi.readBigUInt64LE(64)^Pi.readBigUInt64LE(72))|Tr(i^Pi.readBigUInt64LE(80)^Pi.readBigUInt64LE(88))<<64n},Zx=(e,i,n)=>{let o=BigInt(e.byteLength)*to&K,a=BigInt(e.byteLength-1)/32n;for(;a>=0n;){const r=Number(a);o=dr(o,Si(e,16*r),Si(e,e.byteLength-16*(r+1)),Si(i,32*r),n),a--}let t=o+(o>>64n)&K;t=yn(t);let s=(o&K)*to+(o>>64n)*oh+(BigInt(e.byteLength)-n&K)*Oo;return s&=K,s=Wl(yn(s)),t|s<<64n},Jx=(e,i,n)=>{let o=BigInt(e.byteLength)*to&K;for(let s=32;s<160;s+=32)o=dr(o,Si(e,s-32),Si(e,s-16),Si(i,s-32),n);o=yn(o&K)|yn(o>>64n)<<64n;for(let s=160;s<=e.byteLength;s+=32)o=dr(o,Si(e,s-32),Si(e,s-16),Si(i,3+s-160),n);o=dr(o,Si(e,e.byteLength-16),Si(e,e.byteLength-32),Si(i,103),Wl(n));let a=o+(o>>64n)&K;a=yn(a);let t=(o&K)*to+(o>>64n)*oh+(BigInt(e.byteLength)-n&K)*Oo;return t&=K,t=Wl(yn(t)),a|t<<64n},xx=(e,i=0n)=>{const n=e.byteLength;return n<=16?$x(e,i):n<=128?Zx(e,Pi,i):n<=240?Jx(e,Pi,i):Sx(e,i===0n?Pi:kx(i))},Tx=e=>{const i=e>>64n&K,n=e&K;return i.toString(16).padStart(16,"0")+n.toString(16).padStart(16,"0")},Hb=(e,i=0n)=>Tx(xx(typeof e=="string"?Buffer.from(e):e,i)),Vo=()=>L(yY(),"ai"),Dx=3600*1e3,Bx=1800*1e3,Mb=()=>{vo(Vo())},Pb=(e,i)=>{const n=`${e}.${String(process.pid)}.${CY()}.tmp`;try{He(n,i,"utf8"),_f(n,e)}catch(o){try{yo(n)}catch{}throw o}},QSe=(e,i,n)=>{const o=n.map(t=>({currentRange:t.currentRange,name:t.packageName,targetVersion:t.targetVersion})).toSorted((t,s)=>t.name.localeCompare(s.name)),a=JSON.stringify({analysisType:i,packages:o,provider:e});return Hb(Buffer.from(a))},WSe=e=>{const i=L(Vo(),`${e}.json`);if(Z(i))try{const n=Qe(i);if(Date.now()-n.createdAt>n.ttlMs){Ma(i,{force:!0});return}return n.result}catch{Ma(i,{force:!0});return}},ISe=(e,i,n)=>{Mb();const o=Vo(),a={createdAt:Date.now(),result:i,ttlMs:n};Pb(L(o,`${e}.json`),JSON.stringify(a,void 0,2))},_Se=(e,i)=>i!==void 0&&i>0?i:e==="security"?Bx:Dx,Il=()=>{const e=Vo();if(!Z(e))return{entries:0,newestEntry:void 0,oldestEntry:void 0,totalSizeBytes:0};const i=Fi(e).filter(t=>t.endsWith(".json"));let n=0,o,a;for(const t of i){const s=L(e,t),r=Eo(s);n+=r.size;const{mtimeMs:u}=r;(o===void 0||u<o)&&(o=u),(a===void 0||u>a)&&(a=u)}return{entries:i.length,newestEntry:a,oldestEntry:o,totalSizeBytes:n}},zSe=e=>Hb(Buffer.from(JSON.stringify(e))),KSe=e=>{const i=L(Vo(),`${e}.json`);if(Z(i))try{const n=Qe(i);if(Date.now()-n.createdAt>n.ttlMs){Ma(i,{force:!0});return}return n.result}catch{Ma(i,{force:!0});return}},qSe=(e,i,n)=>{Mb();const o=Vo(),a={createdAt:Date.now(),result:i,ttlMs:n};Pb(L(o,`${e}.json`),JSON.stringify(a,void 0,2))},Xx=()=>{const e=Vo();if(!Z(e))return 0;const i=Fi(e).filter(n=>n.endsWith(".json"));for(const n of i)Ma(L(e,n),{force:!0});return i.length},Hx=wn(import.meta.url),ca=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,Kr=e=>{if(typeof ca<"u"&&ca.versions&&ca.versions.node){const[i,n]=ca.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return ca.getBuiltinModule(e)}return Hx(e)},{createRequire:Nb}=Kr("node:module"),Ho=ca,{execFileSync:Mx}=Kr("node:child_process"),Ft=Kr("node:fs"),Px=Kr("node:tty"),Nx=[161,161,164,164,167,168,170,170,173,174,176,180,182,186,188,191,198,198,208,208,215,216,222,225,230,230,232,234,236,237,240,240,242,243,247,250,252,252,254,254,257,257,273,273,275,275,283,283,294,295,299,299,305,307,312,312,319,322,324,324,328,331,333,333,338,339,358,359,363,363,462,462,464,464,466,466,468,468,470,470,472,472,474,474,476,476,593,593,609,609,708,708,711,711,713,715,717,717,720,720,728,731,733,733,735,735,768,879,913,929,931,937,945,961,963,969,1025,1025,1040,1103,1105,1105,8208,8208,8211,8214,8216,8217,8220,8221,8224,8226,8228,8231,8240,8240,8242,8243,8245,8245,8251,8251,8254,8254,8308,8308,8319,8319,8321,8324,8364,8364,8451,8451,8453,8453,8457,8457,8467,8467,8470,8470,8481,8482,8486,8486,8491,8491,8531,8532,8539,8542,8544,8555,8560,8569,8585,8585,8592,8601,8632,8633,8658,8658,8660,8660,8679,8679,8704,8704,8706,8707,8711,8712,8715,8715,8719,8719,8721,8721,8725,8725,8730,8730,8733,8736,8739,8739,8741,8741,8743,8748,8750,8750,8756,8759,8764,8765,8776,8776,8780,8780,8786,8786,8800,8801,8804,8807,8810,8811,8814,8815,8834,8835,8838,8839,8853,8853,8857,8857,8869,8869,8895,8895,8978,8978,9312,9449,9451,9547,9552,9587,9600,9615,9618,9621,9632,9633,9635,9641,9650,9651,9654,9655,9660,9661,9664,9665,9670,9672,9675,9675,9678,9681,9698,9701,9711,9711,9733,9734,9737,9737,9742,9743,9756,9756,9758,9758,9792,9792,9794,9794,9824,9825,9827,9829,9831,9834,9836,9837,9839,9839,9886,9887,9919,9919,9926,9933,9935,9939,9941,9953,9955,9955,9960,9961,9963,9969,9972,9972,9974,9977,9979,9980,9982,9983,10045,10045,10102,10111,11094,11097,12872,12879,57344,63743,65024,65039,65533,65533,127232,127242,127248,127277,127280,127337,127344,127373,127375,127376,127387,127404,917760,917999,983040,1048573,1048576,1114109],Ex=12288,Rx=65510,Ox=[12288,12288,65281,65376,65504,65510],Ax=8361,Gx=65518,Fx=[8361,8361,65377,65470,65474,65479,65482,65487,65490,65495,65498,65500,65512,65518],Qx=32,Wx=10630,Ix=[32,126,162,163,165,166,172,172,175,175,10214,10221,10629,10630],_x=4352,zx=262141,Eb=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141],Cs=(e,i)=>{let n=0,o=Math.floor(e.length/2)-1;for(;n<=o;){const a=Math.floor((n+o)/2),t=a*2;if(i<e[t])o=a-1;else if(i>e[t+1])n=a+1;else return!0}return!1},rv=19968,[Kx,qx]=Ux(Eb);function Ux(e){let i=e[0],n=e[1];for(let o=0;o<e.length;o+=2){const a=e[o],t=e[o+1];if(rv>=a&&rv<=t)return[a,t];t-a>n-i&&(i=a,n=t)}return[i,n]}const Vx=e=>e<161||e>1114109?!1:Cs(Nx,e),eT=e=>e<Ex||e>Rx?!1:Cs(Ox,e),iT=e=>e<Ax||e>Gx?!1:Cs(Fx,e),nT=e=>e<Qx||e>Wx?!1:Cs(Ix,e),oT=e=>e>=Kx&&e<=qx?!0:e<_x||e>zx?!1:Cs(Eb,e);function aT(e){return Vx(e)?"ambiguous":eT(e)?"fullwidth":iT(e)?"halfwidth":nT(e)?"narrow":oT(e)?"wide":"neutral"}function tT(e){if(!Number.isSafeInteger(e))throw new TypeError(`Expected a code point, got \`${typeof e}\`.`)}function Rb(e){return tT(e),aT(e)}const Ob=String.raw,uv=Ob`\p{Emoji}(?:\p{EMod}|[\u{E0020}-\u{E007E}]+\u{E007F}|\uFE0F?\u20E3?)`,sT=()=>new RegExp(Ob`\p{RI}{2}|(?![#*\d](?!\uFE0F?\u20E3))${uv}(?:\u200D${uv})*`,"gu"),Wa=new Set(["\x1B","›"]),qr="\x07",Ab="[",ah="m",ss="]8;;",rT=39,uT=/[\u200B\uFEFF\u2060-\u2064]/g,dT=new RegExp(`(?:\\${Ab}(?<code>\\d+)m|\\${ss}(?<uri>.*)${qr})`),lT=Object.freeze(new Map([[0,0],[1,22],[2,22],[3,23],[4,24],[7,27],[8,28],[9,29],[30,39],[31,39],[32,39],[33,39],[34,39],[35,39],[36,39],[37,39],[40,49],[41,49],[42,49],[43,49],[44,49],[45,49],[46,49],[47,49],[90,39]])),gT=/^[ \t]*(?:\r\n|\r|\n)/,hT=/(?:\r\n|\r|\n)[ \t]*$/,cT=/^(?:[\r\n]|$)/,pT=/(?:\r\n|\r|\n)([ \t]*)(?:[^ \t\r\n]|$)/,vT=/^[ \t]*[\r\n][ \t\r\n]*$/,yT=/\r\n|\n|\r/g,Ct=/[\u001B\u009B](?:[[()#;?]{0,10}(?:\d{1,4}(?:;\d{0,4})*)?[0-9A-ORZcf-nqry=><]|\]8;;[^\u0007\u001B]{0,100}(?:\u0007|\u001B\\))/g,Is=/[\u0000-\u0008\n-\u001F\u007F-\u009F]{1,1000}/y,$d=sT(),dv=new Map,fT=e=>[e.ambiguousIsNarrow?1:0,e.control,e.fullWidth,e.regular,e.wide].join("|"),mT=e=>{const i=fT(e.width);let n=dv.get(i);return n||(n=new Map,dv.set(i,n)),n},_s=/(?:[\u0020-\u007E\u00A0-\u00FF](?!\uFE0F)){1,1000}/y,Gb=e=>e>=32&&e<=126?"latin":e===8203||e===8204||e===8205||e===8288?"zero":e<=31||e>=127&&e<=159?"control":e>=160&&e<=255||e>=9472&&e<=9599?"latin":e>=4352&&e<=4607||e>=11904&&e<=40959||e>=44032&&e<=55215||e>=63744&&e<=64255||e>=65280&&e<=65519&&!(e>=65377&&e<=65439)||e>=12352&&e<=12543?"wide":e===8230?"latin":"other",bT=(e,i)=>{const n=mT(i),o=Math.floor(e/65536),a=e%65536;let t=n.get(o);if(t||(t=new Map,n.set(o,t)),t.has(a))return t.get(a);let s;switch(Gb(e)){case"control":{s=i.width.control;break}case"latin":{s=i.width.regular;break}case"wide":{s=i.width.wide;break}case"zero":{s=0;break}default:switch(Rb(e)){case"ambiguous":{s=i.width.ambiguousIsNarrow?i.width.regular:i.width.wide;break}case"fullwidth":{s=i.width.fullWidth;break}case"wide":{s=i.width.wide;break}default:s=i.width.regular}}return t.set(a,s),s},wT=e=>e>=768&&e<=879||e>=6832&&e<=6911||e>=7616&&e<=7679||e>=8400&&e<=8447||e>=65056&&e<=65071||e>=917760&&e<=917999||e>=65024&&e<=65039||e>=3633&&e<=3642||e>=3655&&e<=3662||e>=3761&&e<=3769||e>=3771&&e<=3772||e>=3784&&e<=3789||e>=2304&&e<=2307||e>=2362&&e<=2383||e>=2385&&e<=2391||e>=2402&&e<=2403||e>=2433&&e<=2435||e>=2492&&e<=2500||e>=2509&&e<=2509||e>=2561&&e<=2563||e>=2620&&e<=2637||e>=1611&&e<=1631||e>=1648&&e<=1648||e>=1750&&e<=1773||e>=2276&&e<=2302||e>=1425&&e<=1469||e>=1471&&e<=1471||e>=1473&&e<=1474||e>=1476&&e<=1477||e>=1479&&e<=1479||e>=3893&&e<=3893||e>=3895&&e<=3895||e>=3897&&e<=3897||e>=3953&&e<=3966||e>=3968&&e<=3972||e>=3974&&e<=3975?!0:e>=768&&e<=777||e>=803&&e<=803,_l=(e,i={})=>{if(!e||e.length===0)return{ellipsed:!1,index:0,truncated:!1,width:0};const n={truncation:{countAnsiEscapeCodes:i.countAnsiEscapeCodes??!1,ellipsis:i.ellipsis??"",ellipsisWidth:i.ellipsisWidth??(i.ellipsis?_l(i.ellipsis,{...i,ellipsis:"",ellipsisWidth:0,limit:Number.POSITIVE_INFINITY}).width:0),limit:i.limit??Number.POSITIVE_INFINITY},width:{ambiguousIsNarrow:i.ambiguousIsNarrow??!1,ansi:i.ansiWidth??0,control:i.controlWidth??0,emoji:i.emojiWidth??2,fullWidth:i.fullWidth??2,halfWidth:i.halfWidth??1,regular:i.regularWidth??1,tab:i.tabWidth??8,wide:i.wideWidth??2}},o=Math.max(0,n.truncation.limit-n.truncation.ellipsisWidth),{length:a}=e,t=a>1e4;let s=0,r=0,u=a,d=!1;const l=e.includes("\x1B")||e.includes("›");for(;s<a;){if(l&&(e[s]==="\x1B"||e[s]==="›")){if(e.startsWith("\x1B]8;;",s)){const w="\x1B]8;;\x07",v=w.length,j=e.indexOf("\x07",s+5);if(j!==-1){const C=e.indexOf(w,j+1);if(C!==-1){const y=C+v,k=e.slice(j+1,C).replace(Ct,""),S=_l(k,{ambiguousIsNarrow:n.width.ambiguousIsNarrow,ansiWidth:n.width.ansi,controlWidth:n.width.control,countAnsiEscapeCodes:!1,ellipsis:n.truncation.ellipsis,ellipsisWidth:n.truncation.ellipsisWidth,emojiWidth:n.width.emoji,fullWidth:n.width.fullWidth,halfWidth:n.width.halfWidth,limit:Math.max(0,o-r),regularWidth:n.width.regular,tabWidth:n.width.tab,wideWidth:n.width.wide}),J=S.width;if(S.truncated)d=!0,u=Math.min(u,s);else if(r+J>o&&(u=Math.min(u,s),d=!0,r+J>n.truncation.limit))break;if(r+=J,s=y,d&&r>=n.truncation.limit)break;continue}}}if(Ct.lastIndex=s,Ct.test(e)){const w=Ct.lastIndex-s,v=n.truncation.countAnsiEscapeCodes?w:n.width.ansi;if(r+v>o&&(u=Math.min(u,s),r+v>n.truncation.limit)){d=!0;break}r+=v,s=Ct.lastIndex;continue}}const c=e.codePointAt(s);if(c===8203||c===65279||c>=8288&&c<=8292){s+=1;continue}if(c===9){if(r+n.width.tab>o&&(u=Math.min(u,s),r+n.width.tab>n.truncation.limit)){d=!0;break}r+=n.width.tab,s+=1;continue}if(_s.lastIndex=s,_s.test(e)){const w=(_s.lastIndex-s)*n.width.regular;if(r+w>o){const v=Math.floor((o-r)/n.width.regular);if(u=Math.min(u,s+v),r+w>n.truncation.limit){d=!0;break}}r+=w,s=_s.lastIndex;continue}if((c<=31||c>=127&&c<=159)&&(Is.lastIndex=s,Is.test(e))){const w=(Is.lastIndex-s)*n.width.control;if(r+w>o&&(u=Math.min(u,s+Math.floor((o-r)/n.width.control)),r+w>n.truncation.limit)){d=!0;break}r+=w,s=Is.lastIndex;continue}if($d.lastIndex=s,$d.test(e)){if(r+n.width.emoji>o&&(u=Math.min(u,s),r+n.width.emoji>n.truncation.limit)){d=!0;break}r+=n.width.emoji,s=$d.lastIndex;continue}const p=e.codePointAt(s)??0;if(wT(p)){s+=p>65535?2:1;continue}let f;if(t)f=bT(p,n);else switch(Gb(p)){case"control":{f=n.width.control;break}case"latin":{f=n.width.regular;break}case"wide":{f=n.width.wide;break}case"zero":{f=0;break}default:switch(Rb(p)){case"ambiguous":{f=n.width.ambiguousIsNarrow?n.width.regular:n.width.wide;break}case"fullwidth":{f=n.width.fullWidth;break}case"wide":{f=n.width.wide;break}default:f=n.width.regular}}if(r+f>o&&(u=Math.min(u,s),r+f>n.truncation.limit)){d=!0;break}r+=f,s+=p>65535?2:1}let g=r,h=!1;return d&&n.truncation.limit>=n.truncation.ellipsisWidth&&(g=n.truncation.limit,h=!0),{ellipsed:h,index:d?u:a,truncated:d,width:g}},so=(e,i={})=>_l(e,{...i,ellipsis:"",ellipsisWidth:0,limit:Number.POSITIVE_INFINITY}).width,jT=Nb(import.meta.url),Yt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,kT=e=>{if(typeof Yt<"u"&&Yt.versions&&Yt.versions.node){const[i,n]=Yt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return Yt.getBuiltinModule(e)}return jT(e)};kT("node:util");const ST=new Uint8Array(128),LT=new Uint8Array(128),CT=new Uint8Array(128);for(let e=0;e<128;e++)ST[e]=e>=65&&e<=90?1:0,LT[e]=e>=97&&e<=122?1:0,CT[e]=e>=48&&e<=57?1:0;const YT=Nb(import.meta.url),$t=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,$T=e=>{if(typeof $t<"u"&&$t.versions&&$t.versions.node){const[i,n]=$t.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return $t.getBuiltinModule(e)}return YT(e)};$T("node:util");function ZT(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Zd,lv;function JT(){if(lv)return Zd;lv=1,Zd=i;function e(o){return o instanceof Buffer?Buffer.from(o):new o.constructor(o.buffer.slice(),o.byteOffset,o.length)}function i(o){if(o=o||{},o.circles)return n(o);const a=new Map;if(a.set(Date,d=>new Date(d)),a.set(Map,(d,l)=>new Map(s(Array.from(d),l))),a.set(Set,(d,l)=>new Set(s(Array.from(d),l))),o.constructorHandlers)for(const d of o.constructorHandlers)a.set(d[0],d[1]);let t=null;return o.proto?u:r;function s(d,l){const g=Object.keys(d),h=new Array(g.length);for(let c=0;c<g.length;c++){const p=g[c],f=d[p];typeof f!="object"||f===null?h[p]=f:f.constructor!==Object&&(t=a.get(f.constructor))?h[p]=t(f,l):ArrayBuffer.isView(f)?h[p]=e(f):h[p]=l(f)}return h}function r(d){if(typeof d!="object"||d===null)return d;if(Array.isArray(d))return s(d,r);if(d.constructor!==Object&&(t=a.get(d.constructor)))return t(d,r);const l={};for(const g in d){if(Object.hasOwnProperty.call(d,g)===!1)continue;const h=d[g];typeof h!="object"||h===null?l[g]=h:h.constructor!==Object&&(t=a.get(h.constructor))?l[g]=t(h,r):ArrayBuffer.isView(h)?l[g]=e(h):l[g]=r(h)}return l}function u(d){if(typeof d!="object"||d===null)return d;if(Array.isArray(d))return s(d,u);if(d.constructor!==Object&&(t=a.get(d.constructor)))return t(d,u);const l={};for(const g in d){const h=d[g];typeof h!="object"||h===null?l[g]=h:h.constructor!==Object&&(t=a.get(h.constructor))?l[g]=t(h,u):ArrayBuffer.isView(h)?l[g]=e(h):l[g]=u(h)}return l}}function n(o){const a=[],t=[],s=new Map;if(s.set(Date,g=>new Date(g)),s.set(Map,(g,h)=>new Map(u(Array.from(g),h))),s.set(Set,(g,h)=>new Set(u(Array.from(g),h))),o.constructorHandlers)for(const g of o.constructorHandlers)s.set(g[0],g[1]);let r=null;return o.proto?l:d;function u(g,h){const c=Object.keys(g),p=new Array(c.length);for(let f=0;f<c.length;f++){const w=c[f],v=g[w];if(typeof v!="object"||v===null)p[w]=v;else if(v.constructor!==Object&&(r=s.get(v.constructor)))p[w]=r(v,h);else if(ArrayBuffer.isView(v))p[w]=e(v);else{const j=a.indexOf(v);j!==-1?p[w]=t[j]:p[w]=h(v)}}return p}function d(g){if(typeof g!="object"||g===null)return g;if(Array.isArray(g))return u(g,d);if(g.constructor!==Object&&(r=s.get(g.constructor)))return r(g,d);const h={};a.push(g),t.push(h);for(const c in g){if(Object.hasOwnProperty.call(g,c)===!1)continue;const p=g[c];if(typeof p!="object"||p===null)h[c]=p;else if(p.constructor!==Object&&(r=s.get(p.constructor)))h[c]=r(p,d);else if(ArrayBuffer.isView(p))h[c]=e(p);else{const f=a.indexOf(p);f!==-1?h[c]=t[f]:h[c]=d(p)}}return a.pop(),t.pop(),h}function l(g){if(typeof g!="object"||g===null)return g;if(Array.isArray(g))return u(g,l);if(g.constructor!==Object&&(r=s.get(g.constructor)))return r(g,l);const h={};a.push(g),t.push(h);for(const c in g){const p=g[c];if(typeof p!="object"||p===null)h[c]=p;else if(p.constructor!==Object&&(r=s.get(p.constructor)))h[c]=r(p,l);else if(ArrayBuffer.isView(p))h[c]=e(p);else{const f=a.indexOf(p);f!==-1?h[c]=t[f]:h[c]=l(p)}}return a.pop(),t.pop(),h}}return Zd}var xT=JT();const Fb=ZT(xT);Fb();var Qb=typeof global=="object"&&global&&global.Object===Object&&global,TT=typeof self=="object"&&self&&self.Object===Object&&self,_e=Qb||TT||Function("return this")(),oi=_e.Symbol,Wb=Object.prototype,DT=Wb.hasOwnProperty,BT=Wb.toString,Zt=oi?oi.toStringTag:void 0;function XT(e){var i=DT.call(e,Zt),n=e[Zt];try{e[Zt]=void 0;var o=!0}catch{}var a=BT.call(e);return o&&(i?e[Zt]=n:delete e[Zt]),a}var HT=Object.prototype,MT=HT.toString;function PT(e){return MT.call(e)}var NT="[object Null]",ET="[object Undefined]",gv=oi?oi.toStringTag:void 0;function di(e){return e==null?e===void 0?ET:NT:gv&&gv in Object(e)?XT(e):PT(e)}function Ne(e){return e!=null&&typeof e=="object"}var RT="[object Symbol]";function Li(e){return typeof e=="symbol"||Ne(e)&&di(e)==RT}var OT=NaN;function hv(e){return typeof e=="number"?e:Li(e)?OT:+e}function De(e,i){for(var n=-1,o=e==null?0:e.length,a=Array(o);++n<o;)a[n]=i(e[n],n,e);return a}var oe=Array.isArray,cv=oi?oi.prototype:void 0,pv=cv?cv.toString:void 0;function Ci(e){if(typeof e=="string")return e;if(oe(e))return De(e,Ci)+"";if(Li(e))return pv?pv.call(e):"";var i=e+"";return i=="0"&&1/e==-1/0?"-0":i}function Ur(e,i){return function(n,o){var a;if(n===void 0&&o===void 0)return i;if(n!==void 0&&(a=n),o!==void 0){if(a===void 0)return o;typeof n=="string"||typeof o=="string"?(n=Ci(n),o=Ci(o)):(n=hv(n),o=hv(o)),a=e(n,o)}return a}}var AT=Ur(function(e,i){return e+i},0),GT=/\s/;function Ib(e){for(var i=e.length;i--&&GT.test(e.charAt(i)););return i}var FT=/^\s+/;function _b(e){return e&&e.slice(0,Ib(e)+1).replace(FT,"")}function Me(e){var i=typeof e;return e!=null&&(i=="object"||i=="function")}var vv=NaN,QT=/^[-+]0x[0-9a-f]+$/i,WT=/^0b[01]+$/i,IT=/^0o[0-7]+$/i,_T=parseInt;function Ri(e){if(typeof e=="number")return e;if(Li(e))return vv;if(Me(e)){var i=typeof e.valueOf=="function"?e.valueOf():e;e=Me(i)?i+"":i}if(typeof e!="string")return e===0?e:+e;e=_b(e);var n=WT.test(e);return n||IT.test(e)?_T(e.slice(2),n?2:8):QT.test(e)?vv:+e}var yv=1/0,zT=17976931348623157e292;function Pn(e){if(!e)return e===0?e:0;if(e=Ri(e),e===yv||e===-yv){var i=e<0?-1:1;return i*zT}return e===e?e:0}function se(e){var i=Pn(e),n=i%1;return i===i?n?i-n:i:0}var KT="Expected a function";function qT(e,i){if(typeof i!="function")throw new TypeError(KT);return e=se(e),function(){if(--e<1)return i.apply(this,arguments)}}function fi(e){return e}var UT="[object AsyncFunction]",VT="[object Function]",eD="[object GeneratorFunction]",iD="[object Proxy]";function Rn(e){if(!Me(e))return!1;var i=di(e);return i==VT||i==eD||i==UT||i==iD}var lr=_e["__core-js_shared__"],fv=(function(){var e=/[^.]+$/.exec(lr&&lr.keys&&lr.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function nD(e){return!!fv&&fv in e}var oD=Function.prototype,aD=oD.toString;function ea(e){if(e!=null){try{return aD.call(e)}catch{}try{return e+""}catch{}}return""}var tD=/[\\^$.*+?()[\]{}|]/g,sD=/^\[object .+?Constructor\]$/,rD=Function.prototype,uD=Object.prototype,dD=rD.toString,lD=uD.hasOwnProperty,gD=RegExp("^"+dD.call(lD).replace(tD,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function zb(e){if(!Me(e)||nD(e))return!1;var i=Rn(e)?gD:sD;return i.test(ea(e))}function hD(e,i){return e?.[i]}function ia(e,i){var n=hD(e,i);return zb(n)?n:void 0}var rs=ia(_e,"WeakMap"),Dr=rs&&new rs,Kb=Dr?function(e,i){return Dr.set(e,i),e}:fi,mv=Object.create,Ia=(function(){function e(){}return function(i){if(!Me(i))return{};if(mv)return mv(i);e.prototype=i;var n=new e;return e.prototype=void 0,n}})();function us(e){return function(){var i=arguments;switch(i.length){case 0:return new e;case 1:return new e(i[0]);case 2:return new e(i[0],i[1]);case 3:return new e(i[0],i[1],i[2]);case 4:return new e(i[0],i[1],i[2],i[3]);case 5:return new e(i[0],i[1],i[2],i[3],i[4]);case 6:return new e(i[0],i[1],i[2],i[3],i[4],i[5]);case 7:return new e(i[0],i[1],i[2],i[3],i[4],i[5],i[6])}var n=Ia(e.prototype),o=e.apply(n,i);return Me(o)?o:n}}var cD=1;function pD(e,i,n){var o=i&cD,a=us(e);function t(){var s=this&&this!==_e&&this instanceof t?a:e;return s.apply(o?n:this,arguments)}return t}function Yi(e,i,n){switch(n.length){case 0:return e.call(i);case 1:return e.call(i,n[0]);case 2:return e.call(i,n[0],n[1]);case 3:return e.call(i,n[0],n[1],n[2])}return e.apply(i,n)}var vD=Math.max;function qb(e,i,n,o){for(var a=-1,t=e.length,s=n.length,r=-1,u=i.length,d=vD(t-s,0),l=Array(u+d),g=!o;++r<u;)l[r]=i[r];for(;++a<s;)(g||a<t)&&(l[n[a]]=e[a]);for(;d--;)l[r++]=e[a++];return l}var yD=Math.max;function Ub(e,i,n,o){for(var a=-1,t=e.length,s=-1,r=n.length,u=-1,d=i.length,l=yD(t-r,0),g=Array(l+d),h=!o;++a<l;)g[a]=e[a];for(var c=a;++u<d;)g[c+u]=i[u];for(;++s<r;)(h||a<t)&&(g[c+n[s]]=e[a++]);return g}function fD(e,i){for(var n=e.length,o=0;n--;)e[n]===i&&++o;return o}function Vr(){}var mD=4294967295;function ce(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=mD,this.__views__=[]}ce.prototype=Ia(Vr.prototype);ce.prototype.constructor=ce;function th(){}var sh=Dr?function(e){return Dr.get(e)}:th,Ja={},bD=Object.prototype,wD=bD.hasOwnProperty;function gr(e){for(var i=e.name+"",n=Ja[i],o=wD.call(Ja,i)?n.length:0;o--;){var a=n[o],t=a.func;if(t==null||t==e)return a.name}return i}function Qi(e,i){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!i,this.__index__=0,this.__values__=void 0}Qi.prototype=Ia(Vr.prototype);Qi.prototype.constructor=Qi;function vi(e,i){var n=-1,o=e.length;for(i||(i=Array(o));++n<o;)i[n]=e[n];return i}function Vb(e){if(e instanceof ce)return e.clone();var i=new Qi(e.__wrapped__,e.__chain__);return i.__actions__=vi(e.__actions__),i.__index__=e.__index__,i.__values__=e.__values__,i}var jD=Object.prototype,kD=jD.hasOwnProperty;function m(e){if(Ne(e)&&!oe(e)&&!(e instanceof ce)){if(e instanceof Qi)return e;if(kD.call(e,"__wrapped__"))return Vb(e)}return new Qi(e)}m.prototype=Vr.prototype;m.prototype.constructor=m;function zl(e){var i=gr(e),n=m[i];if(typeof n!="function"||!(i in ce.prototype))return!1;if(e===n)return!0;var o=sh(n);return!!o&&e===o[0]}var SD=800,LD=16,CD=Date.now;function ew(e){var i=0,n=0;return function(){var o=CD(),a=LD-(o-n);if(n=o,a>0){if(++i>=SD)return arguments[0]}else i=0;return e.apply(void 0,arguments)}}var iw=ew(Kb),YD=/\{\n\/\* \[wrapped with (.+)\] \*/,$D=/,? & /;function ZD(e){var i=e.match(YD);return i?i[1].split($D):[]}var JD=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;function xD(e,i){var n=i.length;if(!n)return e;var o=n-1;return i[o]=(n>1?"& ":"")+i[o],i=i.join(n>2?", ":" "),e.replace(JD,`{
16
16
  /* [wrapped with `+i+`] */
17
17
  `)}function rh(e){return function(){return e}}var Br=(function(){try{var e=ia(Object,"defineProperty");return e({},"",{}),e}catch{}})(),TD=Br?function(e,i){return Br(e,"toString",{configurable:!0,enumerable:!1,value:rh(i),writable:!0})}:fi,uh=ew(TD);function Bi(e,i){for(var n=-1,o=e==null?0:e.length;++n<o&&i(e[n],n,e)!==!1;);return e}function eu(e,i,n,o){for(var a=e.length,t=n+(o?1:-1);o?t--:++t<a;)if(i(e[t],t,e))return t;return-1}function nw(e){return e!==e}function DD(e,i,n){for(var o=n-1,a=e.length;++o<a;)if(e[o]===i)return o;return-1}function _a(e,i,n){return i===i?DD(e,i,n):eu(e,nw,n)}function iu(e,i){var n=e==null?0:e.length;return!!n&&_a(e,i,0)>-1}var BD=1,XD=2,HD=8,MD=16,PD=32,ND=64,ED=128,RD=256,OD=512,AD=[["ary",ED],["bind",BD],["bindKey",XD],["curry",HD],["curryRight",MD],["flip",OD],["partial",PD],["partialRight",ND],["rearg",RD]];function GD(e,i){return Bi(AD,function(n){var o="_."+n[0];i&n[1]&&!iu(e,o)&&e.push(o)}),e.sort()}function ow(e,i,n){var o=i+"";return uh(e,xD(o,GD(ZD(o),n)))}var FD=4,QD=8,bv=32,wv=64;function aw(e,i,n,o,a,t,s,r,u,d){var l=i&QD,g=l?s:void 0,h=l?void 0:s,c=l?t:void 0,p=l?void 0:t;i|=l?bv:wv,i&=~(l?wv:bv),i&FD||(i&=-4);var f=[e,i,a,c,g,p,h,r,u,d],w=n.apply(void 0,f);return zl(e)&&iw(w,f),w.placeholder=o,ow(w,e,i)}function za(e){var i=e;return i.placeholder}var WD=9007199254740991,ID=/^(?:0|[1-9]\d*)$/;function On(e,i){var n=typeof e;return i=i??WD,!!i&&(n=="number"||n!="symbol"&&ID.test(e))&&e>-1&&e%1==0&&e<i}var _D=Math.min;function zD(e,i){for(var n=e.length,o=_D(i.length,n),a=vi(e);o--;){var t=i[o];e[o]=On(t,n)?a[t]:void 0}return e}var jv="__lodash_placeholder__";function ro(e,i){for(var n=-1,o=e.length,a=0,t=[];++n<o;){var s=e[n];(s===i||s===jv)&&(e[n]=jv,t[a++]=n)}return t}var KD=1,qD=2,UD=8,VD=16,eB=128,iB=512;function nu(e,i,n,o,a,t,s,r,u,d){var l=i&eB,g=i&KD,h=i&qD,c=i&(UD|VD),p=i&iB,f=h?void 0:us(e);function w(){for(var v=arguments.length,j=Array(v),C=v;C--;)j[C]=arguments[C];if(c)var y=za(w),k=fD(j,y);if(o&&(j=qb(j,o,a,c)),t&&(j=Ub(j,t,s,c)),v-=k,c&&v<d){var S=ro(j,y);return aw(e,i,nu,w.placeholder,n,j,S,r,u,d-v)}var J=g?n:this,T=h?J[e]:e;return v=j.length,r?j=zD(j,r):p&&v>1&&j.reverse(),l&&u<v&&(j.length=u),this&&this!==_e&&this instanceof w&&(T=f||us(T)),T.apply(J,j)}return w}function nB(e,i,n){var o=us(e);function a(){for(var t=arguments.length,s=Array(t),r=t,u=za(a);r--;)s[r]=arguments[r];var d=t<3&&s[0]!==u&&s[t-1]!==u?[]:ro(s,u);if(t-=d.length,t<n)return aw(e,i,nu,a.placeholder,void 0,s,d,void 0,void 0,n-t);var l=this&&this!==_e&&this instanceof a?o:e;return Yi(l,this,s)}return a}var oB=1;function aB(e,i,n,o){var a=i&oB,t=us(e);function s(){for(var r=-1,u=arguments.length,d=-1,l=o.length,g=Array(l+u),h=this&&this!==_e&&this instanceof s?t:e;++d<l;)g[d]=o[d];for(;u--;)g[d++]=arguments[++r];return Yi(h,a?n:this,g)}return s}var kv="__lodash_placeholder__",Jd=1,tB=2,sB=4,Sv=8,Jt=128,Lv=256,rB=Math.min;function uB(e,i){var n=e[1],o=i[1],a=n|o,t=a<(Jd|tB|Jt),s=o==Jt&&n==Sv||o==Jt&&n==Lv&&e[7].length<=i[8]||o==(Jt|Lv)&&i[7].length<=i[8]&&n==Sv;if(!(t||s))return e;o&Jd&&(e[2]=i[2],a|=n&Jd?0:sB);var r=i[3];if(r){var u=e[3];e[3]=u?qb(u,r,i[4]):r,e[4]=u?ro(e[3],kv):i[4]}return r=i[5],r&&(u=e[5],e[5]=u?Ub(u,r,i[6]):r,e[6]=u?ro(e[5],kv):i[6]),r=i[7],r&&(e[7]=r),o&Jt&&(e[8]=e[8]==null?i[8]:rB(e[8],i[8])),e[9]==null&&(e[9]=i[9]),e[0]=i[0],e[1]=a,e}var dB="Expected a function",Cv=1,lB=2,Yv=8,$v=16,Zv=32,gB=64,Jv=Math.max;function An(e,i,n,o,a,t,s,r){var u=i&lB;if(!u&&typeof e!="function")throw new TypeError(dB);var d=o?o.length:0;if(d||(i&=-97,o=a=void 0),s=s===void 0?s:Jv(se(s),0),r=r===void 0?r:se(r),d-=a?a.length:0,i&gB){var l=o,g=a;o=a=void 0}var h=u?void 0:sh(e),c=[e,i,n,o,a,l,g,t,s,r];if(h&&uB(c,h),e=c[0],i=c[1],n=c[2],o=c[3],a=c[4],r=c[9]=c[9]===void 0?u?0:e.length:Jv(c[9]-d,0),!r&&i&(Yv|$v)&&(i&=-25),!i||i==Cv)var p=pD(e,i,n);else i==Yv||i==$v?p=nB(e,i,r):(i==Zv||i==(Cv|Zv))&&!a.length?p=aB(e,i,n,o):p=nu.apply(void 0,c);var f=h?Kb:iw;return ow(f(p,c),e,i)}var hB=128;function tw(e,i,n){return i=n?void 0:i,i=e&&i==null?e.length:i,An(e,hB,void 0,void 0,void 0,void 0,i)}function kn(e,i,n){i=="__proto__"&&Br?Br(e,i,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[i]=n}function dn(e,i){return e===i||e!==e&&i!==i}var cB=Object.prototype,pB=cB.hasOwnProperty;function Ys(e,i,n){var o=e[i];(!(pB.call(e,i)&&dn(o,n))||n===void 0&&!(i in e))&&kn(e,i,n)}function Sn(e,i,n,o){var a=!n;n||(n={});for(var t=-1,s=i.length;++t<s;){var r=i[t],u=o?o(n[r],e[r],r,n,e):void 0;u===void 0&&(u=e[r]),a?kn(n,r,u):Ys(n,r,u)}return n}var xv=Math.max;function sw(e,i,n){return i=xv(i===void 0?e.length-1:i,0),function(){for(var o=arguments,a=-1,t=xv(o.length-i,0),s=Array(t);++a<t;)s[a]=o[i+a];a=-1;for(var r=Array(i+1);++a<i;)r[a]=o[a];return r[i]=n(s),Yi(e,this,r)}}function ue(e,i){return uh(sw(e,i,fi),e+"")}var vB=9007199254740991;function ou(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=vB}function mi(e){return e!=null&&ou(e.length)&&!Rn(e)}function si(e,i,n){if(!Me(n))return!1;var o=typeof i;return(o=="number"?mi(n)&&On(i,n.length):o=="string"&&i in n)?dn(n[i],e):!1}function Ka(e){return ue(function(i,n){var o=-1,a=n.length,t=a>1?n[a-1]:void 0,s=a>2?n[2]:void 0;for(t=e.length>3&&typeof t=="function"?(a--,t):void 0,s&&si(n[0],n[1],s)&&(t=a<3?void 0:t,a=1),i=Object(i);++o<a;){var r=n[o];r&&e(i,r,o,t)}return i})}var yB=Object.prototype;function $s(e){var i=e&&e.constructor,n=typeof i=="function"&&i.prototype||yB;return e===n}function dh(e,i){for(var n=-1,o=Array(e);++n<e;)o[n]=i(n);return o}var fB="[object Arguments]";function Tv(e){return Ne(e)&&di(e)==fB}var rw=Object.prototype,mB=rw.hasOwnProperty,bB=rw.propertyIsEnumerable,Ao=Tv((function(){return arguments})())?Tv:function(e){return Ne(e)&&mB.call(e,"callee")&&!bB.call(e,"callee")};function lh(){return!1}var uw=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Dv=uw&&typeof module=="object"&&module&&!module.nodeType&&module,wB=Dv&&Dv.exports===uw,Bv=wB?_e.Buffer:void 0,jB=Bv?Bv.isBuffer:void 0,uo=jB||lh,kB="[object Arguments]",SB="[object Array]",LB="[object Boolean]",CB="[object Date]",YB="[object Error]",$B="[object Function]",ZB="[object Map]",JB="[object Number]",xB="[object Object]",TB="[object RegExp]",DB="[object Set]",BB="[object String]",XB="[object WeakMap]",HB="[object ArrayBuffer]",MB="[object DataView]",PB="[object Float32Array]",NB="[object Float64Array]",EB="[object Int8Array]",RB="[object Int16Array]",OB="[object Int32Array]",AB="[object Uint8Array]",GB="[object Uint8ClampedArray]",FB="[object Uint16Array]",QB="[object Uint32Array]",xe={};xe[PB]=xe[NB]=xe[EB]=xe[RB]=xe[OB]=xe[AB]=xe[GB]=xe[FB]=xe[QB]=!0;xe[kB]=xe[SB]=xe[HB]=xe[LB]=xe[MB]=xe[CB]=xe[YB]=xe[$B]=xe[ZB]=xe[JB]=xe[xB]=xe[TB]=xe[DB]=xe[BB]=xe[XB]=!1;function WB(e){return Ne(e)&&ou(e.length)&&!!xe[di(e)]}function $i(e){return function(i){return e(i)}}var dw=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Vt=dw&&typeof module=="object"&&module&&!module.nodeType&&module,IB=Vt&&Vt.exports===dw,xd=IB&&Qb.process,Wi=(function(){try{var e=Vt&&Vt.require&&Vt.require("util").types;return e||xd&&xd.binding&&xd.binding("util")}catch{}})(),Xv=Wi&&Wi.isTypedArray,qa=Xv?$i(Xv):WB,_B=Object.prototype,zB=_B.hasOwnProperty;function lw(e,i){var n=oe(e),o=!n&&Ao(e),a=!n&&!o&&uo(e),t=!n&&!o&&!a&&qa(e),s=n||o||a||t,r=s?dh(e.length,String):[],u=r.length;for(var d in e)(i||zB.call(e,d))&&!(s&&(d=="length"||a&&(d=="offset"||d=="parent")||t&&(d=="buffer"||d=="byteLength"||d=="byteOffset")||On(d,u)))&&r.push(d);return r}function gw(e,i){return function(n){return e(i(n))}}var KB=gw(Object.keys,Object),qB=Object.prototype,UB=qB.hasOwnProperty;function gh(e){if(!$s(e))return KB(e);var i=[];for(var n in Object(e))UB.call(e,n)&&n!="constructor"&&i.push(n);return i}function ze(e){return mi(e)?lw(e):gh(e)}var VB=Object.prototype,eX=VB.hasOwnProperty,iX=Ka(function(e,i){if($s(i)||mi(i)){Sn(i,ze(i),e);return}for(var n in i)eX.call(i,n)&&Ys(e,n,i[n])});function nX(e){var i=[];if(e!=null)for(var n in Object(e))i.push(n);return i}var oX=Object.prototype,aX=oX.hasOwnProperty;function tX(e){if(!Me(e))return nX(e);var i=$s(e),n=[];for(var o in e)o=="constructor"&&(i||!aX.call(e,o))||n.push(o);return n}function bi(e){return mi(e)?lw(e,!0):tX(e)}var sX=Ka(function(e,i){Sn(i,bi(i),e)}),rX=Ka(function(e,i,n,o){Sn(i,bi(i),e,o)}),Kl=Ka(function(e,i,n,o){Sn(i,ze(i),e,o)}),uX=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,dX=/^\w*$/;function hh(e,i){if(oe(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||Li(e)?!0:dX.test(e)||!uX.test(e)||i!=null&&e in Object(i)}var ds=ia(Object,"create");function lX(){this.__data__=ds?ds(null):{},this.size=0}function gX(e){var i=this.has(e)&&delete this.__data__[e];return this.size-=i?1:0,i}var hX="__lodash_hash_undefined__",cX=Object.prototype,pX=cX.hasOwnProperty;function vX(e){var i=this.__data__;if(ds){var n=i[e];return n===hX?void 0:n}return pX.call(i,e)?i[e]:void 0}var yX=Object.prototype,fX=yX.hasOwnProperty;function mX(e){var i=this.__data__;return ds?i[e]!==void 0:fX.call(i,e)}var bX="__lodash_hash_undefined__";function wX(e,i){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=ds&&i===void 0?bX:i,this}function Go(e){var i=-1,n=e==null?0:e.length;for(this.clear();++i<n;){var o=e[i];this.set(o[0],o[1])}}Go.prototype.clear=lX;Go.prototype.delete=gX;Go.prototype.get=vX;Go.prototype.has=mX;Go.prototype.set=wX;function jX(){this.__data__=[],this.size=0}function au(e,i){for(var n=e.length;n--;)if(dn(e[n][0],i))return n;return-1}var kX=Array.prototype,SX=kX.splice;function LX(e){var i=this.__data__,n=au(i,e);if(n<0)return!1;var o=i.length-1;return n==o?i.pop():SX.call(i,n,1),--this.size,!0}function CX(e){var i=this.__data__,n=au(i,e);return n<0?void 0:i[n][1]}function YX(e){return au(this.__data__,e)>-1}function $X(e,i){var n=this.__data__,o=au(n,e);return o<0?(++this.size,n.push([e,i])):n[o][1]=i,this}function Gn(e){var i=-1,n=e==null?0:e.length;for(this.clear();++i<n;){var o=e[i];this.set(o[0],o[1])}}Gn.prototype.clear=jX;Gn.prototype.delete=LX;Gn.prototype.get=CX;Gn.prototype.has=YX;Gn.prototype.set=$X;var ls=ia(_e,"Map");function ZX(){this.size=0,this.__data__={hash:new Go,map:new(ls||Gn),string:new Go}}function JX(e){var i=typeof e;return i=="string"||i=="number"||i=="symbol"||i=="boolean"?e!=="__proto__":e===null}function tu(e,i){var n=e.__data__;return JX(i)?n[typeof i=="string"?"string":"hash"]:n.map}function xX(e){var i=tu(this,e).delete(e);return this.size-=i?1:0,i}function TX(e){return tu(this,e).get(e)}function DX(e){return tu(this,e).has(e)}function BX(e,i){var n=tu(this,e),o=n.size;return n.set(e,i),this.size+=n.size==o?0:1,this}function Fn(e){var i=-1,n=e==null?0:e.length;for(this.clear();++i<n;){var o=e[i];this.set(o[0],o[1])}}Fn.prototype.clear=ZX;Fn.prototype.delete=xX;Fn.prototype.get=TX;Fn.prototype.has=DX;Fn.prototype.set=BX;var XX="Expected a function";function su(e,i){if(typeof e!="function"||i!=null&&typeof i!="function")throw new TypeError(XX);var n=function(){var o=arguments,a=i?i.apply(this,o):o[0],t=n.cache;if(t.has(a))return t.get(a);var s=e.apply(this,o);return n.cache=t.set(a,s)||t,s};return n.cache=new(su.Cache||Fn),n}su.Cache=Fn;var HX=500;function MX(e){var i=su(e,function(o){return n.size===HX&&n.clear(),o}),n=i.cache;return i}var PX=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,NX=/\\(\\)?/g,hw=MX(function(e){var i=[];return e.charCodeAt(0)===46&&i.push(""),e.replace(PX,function(n,o,a,t){i.push(a?t.replace(NX,"$1"):o||n)}),i});function me(e){return e==null?"":Ci(e)}function bo(e,i){return oe(e)?e:hh(e,i)?[e]:hw(me(e))}function an(e){if(typeof e=="string"||Li(e))return e;var i=e+"";return i=="0"&&1/e==-1/0?"-0":i}function na(e,i){i=bo(i,e);for(var n=0,o=i.length;e!=null&&n<o;)e=e[an(i[n++])];return n&&n==o?e:void 0}function ch(e,i,n){var o=e==null?void 0:na(e,i);return o===void 0?n:o}function ph(e,i){for(var n=-1,o=i.length,a=Array(o),t=e==null;++n<o;)a[n]=t?void 0:ch(e,i[n]);return a}function wo(e,i){for(var n=-1,o=i.length,a=e.length;++n<o;)e[a+n]=i[n];return e}var Hv=oi?oi.isConcatSpreadable:void 0;function EX(e){return oe(e)||Ao(e)||!!(Hv&&e&&e[Hv])}function Ve(e,i,n,o,a){var t=-1,s=e.length;for(n||(n=EX),a||(a=[]);++t<s;){var r=e[t];i>0&&n(r)?i>1?Ve(r,i-1,n,o,a):wo(a,r):o||(a[a.length]=r)}return a}function cw(e){var i=e==null?0:e.length;return i?Ve(e,1):[]}function Qn(e){return uh(sw(e,void 0,cw),e+"")}var RX=Qn(ph),ru=gw(Object.getPrototypeOf,Object),OX="[object Object]",AX=Function.prototype,GX=Object.prototype,pw=AX.toString,FX=GX.hasOwnProperty,QX=pw.call(Object);function Zs(e){if(!Ne(e)||di(e)!=OX)return!1;var i=ru(e);if(i===null)return!0;var n=FX.call(i,"constructor")&&i.constructor;return typeof n=="function"&&n instanceof n&&pw.call(n)==QX}var WX="[object DOMException]",IX="[object Error]";function vh(e){if(!Ne(e))return!1;var i=di(e);return i==IX||i==WX||typeof e.message=="string"&&typeof e.name=="string"&&!Zs(e)}var vw=ue(function(e,i){try{return Yi(e,void 0,i)}catch(n){return vh(n)?n:new Error(n)}}),_X="Expected a function";function yw(e,i){var n;if(typeof i!="function")throw new TypeError(_X);return e=se(e),function(){return--e>0&&(n=i.apply(this,arguments)),e<=1&&(i=void 0),n}}var zX=1,KX=32,uu=ue(function(e,i,n){var o=zX;if(n.length){var a=ro(n,za(uu));o|=KX}return An(e,o,i,n,a)});uu.placeholder={};var qX=Qn(function(e,i){return Bi(i,function(n){n=an(n),kn(e,n,uu(e[n],e))}),e}),UX=1,VX=2,eH=32,yh=ue(function(e,i,n){var o=UX|VX;if(n.length){var a=ro(n,za(yh));o|=eH}return An(i,o,e,n,a)});yh.placeholder={};function Ii(e,i,n){var o=-1,a=e.length;i<0&&(i=-i>a?0:a+i),n=n>a?a:n,n<0&&(n+=a),a=i>n?0:n-i>>>0,i>>>=0;for(var t=Array(a);++o<a;)t[o]=e[o+i];return t}function jo(e,i,n){var o=e.length;return n=n===void 0?o:n,!i&&n>=o?e:Ii(e,i,n)}var iH="\\ud800-\\udfff",nH="\\u0300-\\u036f",oH="\\ufe20-\\ufe2f",aH="\\u20d0-\\u20ff",tH=nH+oH+aH,sH="\\ufe0e\\ufe0f",rH="\\u200d",uH=RegExp("["+rH+iH+tH+sH+"]");function Ua(e){return uH.test(e)}function dH(e){return e.split("")}var fw="\\ud800-\\udfff",lH="\\u0300-\\u036f",gH="\\ufe20-\\ufe2f",hH="\\u20d0-\\u20ff",cH=lH+gH+hH,pH="\\ufe0e\\ufe0f",vH="["+fw+"]",ql="["+cH+"]",Ul="\\ud83c[\\udffb-\\udfff]",yH="(?:"+ql+"|"+Ul+")",mw="[^"+fw+"]",bw="(?:\\ud83c[\\udde6-\\uddff]){2}",ww="[\\ud800-\\udbff][\\udc00-\\udfff]",fH="\\u200d",jw=yH+"?",kw="["+pH+"]?",mH="(?:"+fH+"(?:"+[mw,bw,ww].join("|")+")"+kw+jw+")*",bH=kw+jw+mH,wH="(?:"+[mw+ql+"?",ql,bw,ww,vH].join("|")+")",jH=RegExp(Ul+"(?="+Ul+")|"+wH+bH,"g");function kH(e){return e.match(jH)||[]}function tn(e){return Ua(e)?kH(e):dH(e)}function Sw(e){return function(i){i=me(i);var n=Ua(i)?tn(i):void 0,o=n?n[0]:i.charAt(0),a=n?jo(n,1).join(""):i.slice(1);return o[e]()+a}}var fh=Sw("toUpperCase");function Lw(e){return fh(me(e).toLowerCase())}function mh(e,i,n,o){var a=-1,t=e==null?0:e.length;for(o&&t&&(n=e[++a]);++a<t;)n=i(n,e[a],a,e);return n}function bh(e){return function(i){return e?.[i]}}var SH={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},LH=bh(SH),CH=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,YH="\\u0300-\\u036f",$H="\\ufe20-\\ufe2f",ZH="\\u20d0-\\u20ff",JH=YH+$H+ZH,xH="["+JH+"]",TH=RegExp(xH,"g");function Cw(e){return e=me(e),e&&e.replace(CH,LH).replace(TH,"")}var DH=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function BH(e){return e.match(DH)||[]}var XH=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function HH(e){return XH.test(e)}var Yw="\\ud800-\\udfff",MH="\\u0300-\\u036f",PH="\\ufe20-\\ufe2f",NH="\\u20d0-\\u20ff",EH=MH+PH+NH,$w="\\u2700-\\u27bf",Zw="a-z\\xdf-\\xf6\\xf8-\\xff",RH="\\xac\\xb1\\xd7\\xf7",OH="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",AH="\\u2000-\\u206f",GH=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Jw="A-Z\\xc0-\\xd6\\xd8-\\xde",FH="\\ufe0e\\ufe0f",xw=RH+OH+AH+GH,Tw="['’]",Mv="["+xw+"]",QH="["+EH+"]",Dw="\\d+",WH="["+$w+"]",Bw="["+Zw+"]",Xw="[^"+Yw+xw+Dw+$w+Zw+Jw+"]",IH="\\ud83c[\\udffb-\\udfff]",_H="(?:"+QH+"|"+IH+")",zH="[^"+Yw+"]",Hw="(?:\\ud83c[\\udde6-\\uddff]){2}",Mw="[\\ud800-\\udbff][\\udc00-\\udfff]",pa="["+Jw+"]",KH="\\u200d",Pv="(?:"+Bw+"|"+Xw+")",qH="(?:"+pa+"|"+Xw+")",Nv="(?:"+Tw+"(?:d|ll|m|re|s|t|ve))?",Ev="(?:"+Tw+"(?:D|LL|M|RE|S|T|VE))?",Pw=_H+"?",Nw="["+FH+"]?",UH="(?:"+KH+"(?:"+[zH,Hw,Mw].join("|")+")"+Nw+Pw+")*",VH="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",eM="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",iM=Nw+Pw+UH,nM="(?:"+[WH,Hw,Mw].join("|")+")"+iM,oM=RegExp([pa+"?"+Bw+"+"+Nv+"(?="+[Mv,pa,"$"].join("|")+")",qH+"+"+Ev+"(?="+[Mv,pa+Pv,"$"].join("|")+")",pa+"?"+Pv+"+"+Nv,pa+"+"+Ev,eM,VH,Dw,nM].join("|"),"g");function aM(e){return e.match(oM)||[]}function Ew(e,i,n){return e=me(e),i=n?void 0:i,i===void 0?HH(e)?aM(e):BH(e):e.match(i)||[]}var tM="['’]",sM=RegExp(tM,"g");function Va(e){return function(i){return mh(Ew(Cw(i).replace(sM,"")),e,"")}}var rM=Va(function(e,i,n){return i=i.toLowerCase(),e+(n?Lw(i):i)});function uM(){if(!arguments.length)return[];var e=arguments[0];return oe(e)?e:[e]}var dM=_e.isFinite,lM=Math.min;function wh(e){var i=Math[e];return function(n,o){if(n=Ri(n),o=o==null?0:lM(se(o),292),o&&dM(n)){var a=(me(n)+"e").split("e"),t=i(a[0]+"e"+(+a[1]+o));return a=(me(t)+"e").split("e"),+(a[0]+"e"+(+a[1]-o))}return i(n)}}var gM=wh("ceil");function Rw(e){var i=m(e);return i.__chain__=!0,i}var hM=Math.ceil,cM=Math.max;function pM(e,i,n){(n?si(e,i,n):i===void 0)?i=1:i=cM(se(i),0);var o=e==null?0:e.length;if(!o||i<1)return[];for(var a=0,t=0,s=Array(hM(o/i));a<o;)s[t++]=Ii(e,a,a+=i);return s}function oa(e,i,n){return e===e&&(n!==void 0&&(e=e<=n?e:n),i!==void 0&&(e=e>=i?e:i)),e}function vM(e,i,n){return n===void 0&&(n=i,i=void 0),n!==void 0&&(n=Ri(n),n=n===n?n:0),i!==void 0&&(i=Ri(i),i=i===i?i:0),oa(Ri(e),i,n)}function yM(){this.__data__=new Gn,this.size=0}function fM(e){var i=this.__data__,n=i.delete(e);return this.size=i.size,n}function mM(e){return this.__data__.get(e)}function bM(e){return this.__data__.has(e)}var wM=200;function jM(e,i){var n=this.__data__;if(n instanceof Gn){var o=n.__data__;if(!ls||o.length<wM-1)return o.push([e,i]),this.size=++n.size,this;n=this.__data__=new Fn(o)}return n.set(e,i),this.size=n.size,this}function nn(e){var i=this.__data__=new Gn(e);this.size=i.size}nn.prototype.clear=yM;nn.prototype.delete=fM;nn.prototype.get=mM;nn.prototype.has=bM;nn.prototype.set=jM;function Ow(e,i){return e&&Sn(i,ze(i),e)}function kM(e,i){return e&&Sn(i,bi(i),e)}var Aw=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Rv=Aw&&typeof module=="object"&&module&&!module.nodeType&&module,SM=Rv&&Rv.exports===Aw,Ov=SM?_e.Buffer:void 0,Av=Ov?Ov.allocUnsafe:void 0;function Gw(e,i){if(i)return e.slice();var n=e.length,o=Av?Av(n):new e.constructor(n);return e.copy(o),o}function ko(e,i){for(var n=-1,o=e==null?0:e.length,a=0,t=[];++n<o;){var s=e[n];i(s,n,e)&&(t[a++]=s)}return t}function jh(){return[]}var LM=Object.prototype,CM=LM.propertyIsEnumerable,Gv=Object.getOwnPropertySymbols,kh=Gv?function(e){return e==null?[]:(e=Object(e),ko(Gv(e),function(i){return CM.call(e,i)}))}:jh;function YM(e,i){return Sn(e,kh(e),i)}var $M=Object.getOwnPropertySymbols,Fw=$M?function(e){for(var i=[];e;)wo(i,kh(e)),e=ru(e);return i}:jh;function ZM(e,i){return Sn(e,Fw(e),i)}function Qw(e,i,n){var o=i(e);return oe(e)?o:wo(o,n(e))}function Vl(e){return Qw(e,ze,kh)}function Sh(e){return Qw(e,bi,Fw)}var eg=ia(_e,"DataView"),ig=ia(_e,"Promise"),xa=ia(_e,"Set"),Fv="[object Map]",JM="[object Object]",Qv="[object Promise]",Wv="[object Set]",Iv="[object WeakMap]",_v="[object DataView]",xM=ea(eg),TM=ea(ls),DM=ea(ig),BM=ea(xa),XM=ea(rs),Bo=di;(eg&&Bo(new eg(new ArrayBuffer(1)))!=_v||ls&&Bo(new ls)!=Fv||ig&&Bo(ig.resolve())!=Qv||xa&&Bo(new xa)!=Wv||rs&&Bo(new rs)!=Iv)&&(Bo=function(e){var i=di(e),n=i==JM?e.constructor:void 0,o=n?ea(n):"";if(o)switch(o){case xM:return _v;case TM:return Fv;case DM:return Qv;case BM:return Wv;case XM:return Iv}return i});const mn=Bo;var HM=Object.prototype,MM=HM.hasOwnProperty;function PM(e){var i=e.length,n=new e.constructor(i);return i&&typeof e[0]=="string"&&MM.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var Xr=_e.Uint8Array;function Lh(e){var i=new e.constructor(e.byteLength);return new Xr(i).set(new Xr(e)),i}function NM(e,i){var n=i?Lh(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var EM=/\w*$/;function RM(e){var i=new e.constructor(e.source,EM.exec(e));return i.lastIndex=e.lastIndex,i}var zv=oi?oi.prototype:void 0,Kv=zv?zv.valueOf:void 0;function OM(e){return Kv?Object(Kv.call(e)):{}}function Ww(e,i){var n=i?Lh(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var AM="[object Boolean]",GM="[object Date]",FM="[object Map]",QM="[object Number]",WM="[object RegExp]",IM="[object Set]",_M="[object String]",zM="[object Symbol]",KM="[object ArrayBuffer]",qM="[object DataView]",UM="[object Float32Array]",VM="[object Float64Array]",eP="[object Int8Array]",iP="[object Int16Array]",nP="[object Int32Array]",oP="[object Uint8Array]",aP="[object Uint8ClampedArray]",tP="[object Uint16Array]",sP="[object Uint32Array]";function rP(e,i,n){var o=e.constructor;switch(i){case KM:return Lh(e);case AM:case GM:return new o(+e);case qM:return NM(e,n);case UM:case VM:case eP:case iP:case nP:case oP:case aP:case tP:case sP:return Ww(e,n);case FM:return new o;case QM:case _M:return new o(e);case WM:return RM(e);case IM:return new o;case zM:return OM(e)}}function Iw(e){return typeof e.constructor=="function"&&!$s(e)?Ia(ru(e)):{}}var uP="[object Map]";function dP(e){return Ne(e)&&mn(e)==uP}var qv=Wi&&Wi.isMap,_w=qv?$i(qv):dP,lP="[object Set]";function gP(e){return Ne(e)&&mn(e)==lP}var Uv=Wi&&Wi.isSet,zw=Uv?$i(Uv):gP,hP=1,cP=2,pP=4,Kw="[object Arguments]",vP="[object Array]",yP="[object Boolean]",fP="[object Date]",mP="[object Error]",qw="[object Function]",bP="[object GeneratorFunction]",wP="[object Map]",jP="[object Number]",Uw="[object Object]",kP="[object RegExp]",SP="[object Set]",LP="[object String]",CP="[object Symbol]",YP="[object WeakMap]",$P="[object ArrayBuffer]",ZP="[object DataView]",JP="[object Float32Array]",xP="[object Float64Array]",TP="[object Int8Array]",DP="[object Int16Array]",BP="[object Int32Array]",XP="[object Uint8Array]",HP="[object Uint8ClampedArray]",MP="[object Uint16Array]",PP="[object Uint32Array]",$e={};$e[Kw]=$e[vP]=$e[$P]=$e[ZP]=$e[yP]=$e[fP]=$e[JP]=$e[xP]=$e[TP]=$e[DP]=$e[BP]=$e[wP]=$e[jP]=$e[Uw]=$e[kP]=$e[SP]=$e[LP]=$e[CP]=$e[XP]=$e[HP]=$e[MP]=$e[PP]=!0;$e[mP]=$e[qw]=$e[YP]=!1;function Oi(e,i,n,o,a,t){var s,r=i&hP,u=i&cP,d=i&pP;if(n&&(s=a?n(e,o,a,t):n(e)),s!==void 0)return s;if(!Me(e))return e;var l=oe(e);if(l){if(s=PM(e),!r)return vi(e,s)}else{var g=mn(e),h=g==qw||g==bP;if(uo(e))return Gw(e,r);if(g==Uw||g==Kw||h&&!a){if(s=u||h?{}:Iw(e),!r)return u?ZM(e,kM(s,e)):YM(e,Ow(s,e))}else{if(!$e[g])return a?e:{};s=rP(e,g,r)}}t||(t=new nn);var c=t.get(e);if(c)return c;t.set(e,s),zw(e)?e.forEach(function(w){s.add(Oi(w,i,n,w,e,t))}):_w(e)&&e.forEach(function(w,v){s.set(v,Oi(w,i,n,v,e,t))});var p=d?u?Sh:Vl:u?bi:ze,f=l?void 0:p(e);return Bi(f||e,function(w,v){f&&(v=w,w=e[v]),Ys(s,v,Oi(w,i,n,v,e,t))}),s}var NP=4;function EP(e){return Oi(e,NP)}var RP=1,OP=4;function AP(e){return Oi(e,RP|OP)}var GP=1,FP=4;function QP(e,i){return i=typeof i=="function"?i:void 0,Oi(e,GP|FP,i)}var WP=4;function IP(e,i){return i=typeof i=="function"?i:void 0,Oi(e,WP,i)}function _P(){return new Qi(this.value(),this.__chain__)}function zP(e){for(var i=-1,n=e==null?0:e.length,o=0,a=[];++i<n;){var t=e[i];t&&(a[o++]=t)}return a}function KP(){var e=arguments.length;if(!e)return[];for(var i=Array(e-1),n=arguments[0],o=e;o--;)i[o-1]=arguments[o];return wo(oe(n)?vi(n):[n],Ve(i,1))}var qP="__lodash_hash_undefined__";function UP(e){return this.__data__.set(e,qP),this}function VP(e){return this.__data__.has(e)}function Fo(e){var i=-1,n=e==null?0:e.length;for(this.__data__=new Fn;++i<n;)this.add(e[i])}Fo.prototype.add=Fo.prototype.push=UP;Fo.prototype.has=VP;function Ch(e,i){for(var n=-1,o=e==null?0:e.length;++n<o;)if(i(e[n],n,e))return!0;return!1}function gs(e,i){return e.has(i)}var e2=1,i2=2;function Vw(e,i,n,o,a,t){var s=n&e2,r=e.length,u=i.length;if(r!=u&&!(s&&u>r))return!1;var d=t.get(e),l=t.get(i);if(d&&l)return d==i&&l==e;var g=-1,h=!0,c=n&i2?new Fo:void 0;for(t.set(e,i),t.set(i,e);++g<r;){var p=e[g],f=i[g];if(o)var w=s?o(f,p,g,i,e,t):o(p,f,g,e,i,t);if(w!==void 0){if(w)continue;h=!1;break}if(c){if(!Ch(i,function(v,j){if(!gs(c,j)&&(p===v||a(p,v,n,o,t)))return c.push(j)})){h=!1;break}}else if(!(p===f||a(p,f,n,o,t))){h=!1;break}}return t.delete(e),t.delete(i),h}function Yh(e){var i=-1,n=Array(e.size);return e.forEach(function(o,a){n[++i]=[a,o]}),n}function du(e){var i=-1,n=Array(e.size);return e.forEach(function(o){n[++i]=o}),n}var n2=1,o2=2,a2="[object Boolean]",t2="[object Date]",s2="[object Error]",r2="[object Map]",u2="[object Number]",d2="[object RegExp]",l2="[object Set]",g2="[object String]",h2="[object Symbol]",c2="[object ArrayBuffer]",p2="[object DataView]",Vv=oi?oi.prototype:void 0,Td=Vv?Vv.valueOf:void 0;function v2(e,i,n,o,a,t,s){switch(n){case p2:if(e.byteLength!=i.byteLength||e.byteOffset!=i.byteOffset)return!1;e=e.buffer,i=i.buffer;case c2:return!(e.byteLength!=i.byteLength||!t(new Xr(e),new Xr(i)));case a2:case t2:case u2:return dn(+e,+i);case s2:return e.name==i.name&&e.message==i.message;case d2:case g2:return e==i+"";case r2:var r=Yh;case l2:var u=o&n2;if(r||(r=du),e.size!=i.size&&!u)return!1;var d=s.get(e);if(d)return d==i;o|=o2,s.set(e,i);var l=Vw(r(e),r(i),o,a,t,s);return s.delete(e),l;case h2:if(Td)return Td.call(e)==Td.call(i)}return!1}var y2=1,f2=Object.prototype,m2=f2.hasOwnProperty;function b2(e,i,n,o,a,t){var s=n&y2,r=Vl(e),u=r.length,d=Vl(i),l=d.length;if(u!=l&&!s)return!1;for(var g=u;g--;){var h=r[g];if(!(s?h in i:m2.call(i,h)))return!1}var c=t.get(e),p=t.get(i);if(c&&p)return c==i&&p==e;var f=!0;t.set(e,i),t.set(i,e);for(var w=s;++g<u;){h=r[g];var v=e[h],j=i[h];if(o)var C=s?o(j,v,h,i,e,t):o(v,j,h,e,i,t);if(!(C===void 0?v===j||a(v,j,n,o,t):C)){f=!1;break}w||(w=h=="constructor")}if(f&&!w){var y=e.constructor,k=i.constructor;y!=k&&"constructor"in e&&"constructor"in i&&!(typeof y=="function"&&y instanceof y&&typeof k=="function"&&k instanceof k)&&(f=!1)}return t.delete(e),t.delete(i),f}var w2=1,ey="[object Arguments]",iy="[object Array]",zs="[object Object]",j2=Object.prototype,ny=j2.hasOwnProperty;function k2(e,i,n,o,a,t){var s=oe(e),r=oe(i),u=s?iy:mn(e),d=r?iy:mn(i);u=u==ey?zs:u,d=d==ey?zs:d;var l=u==zs,g=d==zs,h=u==d;if(h&&uo(e)){if(!uo(i))return!1;s=!0,l=!1}if(h&&!l)return t||(t=new nn),s||qa(e)?Vw(e,i,n,o,a,t):v2(e,i,u,n,o,a,t);if(!(n&w2)){var c=l&&ny.call(e,"__wrapped__"),p=g&&ny.call(i,"__wrapped__");if(c||p){var f=c?e.value():e,w=p?i.value():i;return t||(t=new nn),a(f,w,n,o,t)}}return h?(t||(t=new nn),b2(e,i,n,o,a,t)):!1}function Js(e,i,n,o,a){return e===i?!0:e==null||i==null||!Ne(e)&&!Ne(i)?e!==e&&i!==i:k2(e,i,n,o,Js,a)}var S2=1,L2=2;function $h(e,i,n,o){var a=n.length,t=a,s=!o;if(e==null)return!t;for(e=Object(e);a--;){var r=n[a];if(s&&r[2]?r[1]!==e[r[0]]:!(r[0]in e))return!1}for(;++a<t;){r=n[a];var u=r[0],d=e[u],l=r[1];if(s&&r[2]){if(d===void 0&&!(u in e))return!1}else{var g=new nn;if(o)var h=o(d,l,u,e,i,g);if(!(h===void 0?Js(l,d,S2|L2,o,g):h))return!1}}return!0}function ej(e){return e===e&&!Me(e)}function Zh(e){for(var i=ze(e),n=i.length;n--;){var o=i[n],a=e[o];i[n]=[o,a,ej(a)]}return i}function ij(e,i){return function(n){return n==null?!1:n[e]===i&&(i!==void 0||e in Object(n))}}function nj(e){var i=Zh(e);return i.length==1&&i[0][2]?ij(i[0][0],i[0][1]):function(n){return n===e||$h(n,e,i)}}function C2(e,i){return e!=null&&i in Object(e)}function oj(e,i,n){i=bo(i,e);for(var o=-1,a=i.length,t=!1;++o<a;){var s=an(i[o]);if(!(t=e!=null&&n(e,s)))break;e=e[s]}return t||++o!=a?t:(a=e==null?0:e.length,!!a&&ou(a)&&On(s,a)&&(oe(e)||Ao(e)))}function Jh(e,i){return e!=null&&oj(e,i,C2)}var Y2=1,$2=2;function aj(e,i){return hh(e)&&ej(i)?ij(an(e),i):function(n){var o=ch(n,e);return o===void 0&&o===i?Jh(n,e):Js(i,o,Y2|$2)}}function xh(e){return function(i){return i?.[e]}}function Z2(e){return function(i){return na(i,e)}}function tj(e){return hh(e)?xh(an(e)):Z2(e)}function ee(e){return typeof e=="function"?e:e==null?fi:typeof e=="object"?oe(e)?aj(e[0],e[1]):nj(e):tj(e)}var J2="Expected a function";function x2(e){var i=e==null?0:e.length,n=ee;return e=i?De(e,function(o){if(typeof o[1]!="function")throw new TypeError(J2);return[n(o[0]),o[1]]}):[],ue(function(o){for(var a=-1;++a<i;){var t=e[a];if(Yi(t[0],this,o))return Yi(t[1],this,o)}})}function sj(e,i,n){var o=n.length;if(e==null)return!o;for(e=Object(e);o--;){var a=n[o],t=i[a],s=e[a];if(s===void 0&&!(a in e)||!t(s))return!1}return!0}function T2(e){var i=ze(e);return function(n){return sj(n,e,i)}}var D2=1;function B2(e){return T2(Oi(e,D2))}function X2(e,i){return i==null||sj(e,i,ze(i))}function H2(e,i,n,o){for(var a=-1,t=e==null?0:e.length;++a<t;){var s=e[a];i(o,s,n(s),e)}return o}function rj(e){return function(i,n,o){for(var a=-1,t=Object(i),s=o(i),r=s.length;r--;){var u=s[e?r:++a];if(n(t[u],u,t)===!1)break}return i}}var Th=rj();function Ln(e,i){return e&&Th(e,i,ze)}function uj(e,i){return function(n,o){if(n==null)return n;if(!mi(n))return e(n,o);for(var a=n.length,t=i?a:-1,s=Object(n);(i?t--:++t<a)&&o(s[t],t,s)!==!1;);return n}}var So=uj(Ln);function M2(e,i,n,o){return So(e,function(a,t,s){i(o,a,n(a),s)}),o}function lu(e,i){return function(n,o){var a=oe(n)?H2:M2,t=i?i():{};return a(n,e,ee(o),t)}}var P2=Object.prototype,N2=P2.hasOwnProperty,E2=lu(function(e,i,n){N2.call(e,n)?++e[n]:kn(e,n,1)});function R2(e,i){var n=Ia(e);return i==null?n:Ow(n,i)}var O2=8;function Dh(e,i,n){i=n?void 0:i;var o=An(e,O2,void 0,void 0,void 0,void 0,void 0,i);return o.placeholder=Dh.placeholder,o}Dh.placeholder={};var A2=16;function Bh(e,i,n){i=n?void 0:i;var o=An(e,A2,void 0,void 0,void 0,void 0,void 0,i);return o.placeholder=Bh.placeholder,o}Bh.placeholder={};var hr=function(){return _e.Date.now()},G2="Expected a function",F2=Math.max,Q2=Math.min;function dj(e,i,n){var o,a,t,s,r,u,d=0,l=!1,g=!1,h=!0;if(typeof e!="function")throw new TypeError(G2);i=Ri(i)||0,Me(n)&&(l=!!n.leading,g="maxWait"in n,t=g?F2(Ri(n.maxWait)||0,i):t,h="trailing"in n?!!n.trailing:h);function c(S){var J=o,T=a;return o=a=void 0,d=S,s=e.apply(T,J),s}function p(S){return d=S,r=setTimeout(v,i),l?c(S):s}function f(S){var J=S-u,T=S-d,M=i-J;return g?Q2(M,t-T):M}function w(S){var J=S-u,T=S-d;return u===void 0||J>=i||J<0||g&&T>=t}function v(){var S=hr();if(w(S))return j(S);r=setTimeout(v,f(S))}function j(S){return r=void 0,h&&o?c(S):(o=a=void 0,s)}function C(){r!==void 0&&clearTimeout(r),d=0,o=u=a=r=void 0}function y(){return r===void 0?s:j(hr())}function k(){var S=hr(),J=w(S);if(o=arguments,a=this,u=S,J){if(r===void 0)return p(u);if(g)return clearTimeout(r),r=setTimeout(v,i),c(u)}return r===void 0&&(r=setTimeout(v,i)),s}return k.cancel=C,k.flush=y,k}function W2(e,i){return e==null||e!==e?i:e}var lj=Object.prototype,I2=lj.hasOwnProperty,_2=ue(function(e,i){e=Object(e);var n=-1,o=i.length,a=o>2?i[2]:void 0;for(a&&si(i[0],i[1],a)&&(o=1);++n<o;)for(var t=i[n],s=bi(t),r=-1,u=s.length;++r<u;){var d=s[r],l=e[d];(l===void 0||dn(l,lj[d])&&!I2.call(e,d))&&(e[d]=t[d])}return e});function ng(e,i,n){(n!==void 0&&!dn(e[i],n)||n===void 0&&!(i in e))&&kn(e,i,n)}function Ge(e){return Ne(e)&&mi(e)}function og(e,i){if(!(i==="constructor"&&typeof e[i]=="function")&&i!="__proto__")return e[i]}function gj(e){return Sn(e,bi(e))}function z2(e,i,n,o,a,t,s){var r=og(e,n),u=og(i,n),d=s.get(u);if(d){ng(e,n,d);return}var l=t?t(r,u,n+"",e,i,s):void 0,g=l===void 0;if(g){var h=oe(u),c=!h&&uo(u),p=!h&&!c&&qa(u);l=u,h||c||p?oe(r)?l=r:Ge(r)?l=vi(r):c?(g=!1,l=Gw(u,!0)):p?(g=!1,l=Ww(u,!0)):l=[]:Zs(u)||Ao(u)?(l=r,Ao(r)?l=gj(r):(!Me(r)||Rn(r))&&(l=Iw(u))):g=!1}g&&(s.set(u,l),a(l,u,o,t,s),s.delete(u)),ng(e,n,l)}function gu(e,i,n,o,a){e!==i&&Th(i,function(t,s){if(a||(a=new nn),Me(t))z2(e,i,s,n,gu,o,a);else{var r=o?o(og(e,s),t,s+"",e,i,a):void 0;r===void 0&&(r=t),ng(e,s,r)}},bi)}function hj(e,i,n,o,a,t){return Me(e)&&Me(i)&&(t.set(i,e),gu(e,i,void 0,hj,t),t.delete(i)),e}var cj=Ka(function(e,i,n,o){gu(e,i,n,o)}),K2=ue(function(e){return e.push(void 0,hj),Yi(cj,void 0,e)}),q2="Expected a function";function pj(e,i,n){if(typeof e!="function")throw new TypeError(q2);return setTimeout(function(){e.apply(void 0,n)},i)}var U2=ue(function(e,i){return pj(e,1,i)}),V2=ue(function(e,i,n){return pj(e,Ri(i)||0,n)});function Xh(e,i,n){for(var o=-1,a=e==null?0:e.length;++o<a;)if(n(i,e[o]))return!0;return!1}var eN=200;function xs(e,i,n,o){var a=-1,t=iu,s=!0,r=e.length,u=[],d=i.length;if(!r)return u;n&&(i=De(i,$i(n))),o?(t=Xh,s=!1):i.length>=eN&&(t=gs,s=!1,i=new Fo(i));e:for(;++a<r;){var l=e[a],g=n==null?l:n(l);if(l=o||l!==0?l:0,s&&g===g){for(var h=d;h--;)if(i[h]===g)continue e;u.push(l)}else t(i,g,o)||u.push(l)}return u}var iN=ue(function(e,i){return Ge(e)?xs(e,Ve(i,1,Ge,!0)):[]});function _i(e){var i=e==null?0:e.length;return i?e[i-1]:void 0}var nN=ue(function(e,i){var n=_i(i);return Ge(n)&&(n=void 0),Ge(e)?xs(e,Ve(i,1,Ge,!0),ee(n)):[]}),oN=ue(function(e,i){var n=_i(i);return Ge(n)&&(n=void 0),Ge(e)?xs(e,Ve(i,1,Ge,!0),void 0,n):[]}),aN=Ur(function(e,i){return e/i},1);function tN(e,i,n){var o=e==null?0:e.length;return o?(i=n||i===void 0?1:se(i),Ii(e,i<0?0:i,o)):[]}function sN(e,i,n){var o=e==null?0:e.length;return o?(i=n||i===void 0?1:se(i),i=o-i,Ii(e,0,i<0?0:i)):[]}function hu(e,i,n,o){for(var a=e.length,t=o?a:-1;(o?t--:++t<a)&&i(e[t],t,e););return n?Ii(e,o?0:t,o?t+1:a):Ii(e,o?t+1:0,o?a:t)}function rN(e,i){return e&&e.length?hu(e,ee(i),!0,!0):[]}function uN(e,i){return e&&e.length?hu(e,ee(i),!0):[]}function Cn(e){return typeof e=="function"?e:fi}function dN(e,i){var n=oe(e)?Bi:So;return n(e,Cn(i))}function lN(e,i){for(var n=e==null?0:e.length;n--&&i(e[n],n,e)!==!1;);return e}var vj=rj(!0);function Hh(e,i){return e&&vj(e,i,ze)}var yj=uj(Hh,!0);function gN(e,i){var n=oe(e)?lN:yj;return n(e,Cn(i))}function hN(e,i,n){e=me(e),i=Ci(i);var o=e.length;n=n===void 0?o:oa(se(n),0,o);var a=n;return n-=i.length,n>=0&&e.slice(n,a)==i}function cN(e,i){return De(i,function(n){return[n,e[n]]})}function pN(e){var i=-1,n=Array(e.size);return e.forEach(function(o){n[++i]=[o,o]}),n}var vN="[object Map]",yN="[object Set]";function fj(e){return function(i){var n=mn(i);return n==vN?Yh(i):n==yN?pN(i):cN(i,e(i))}}var fN=fj(ze),mN=fj(bi),bN={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},wN=bh(bN),mj=/[&<>"']/g,jN=RegExp(mj.source);function bj(e){return e=me(e),e&&jN.test(e)?e.replace(mj,wN):e}var wj=/[\\^$.*+?()[\]{}|]/g,kN=RegExp(wj.source);function SN(e){return e=me(e),e&&kN.test(e)?e.replace(wj,"\\$&"):e}function jj(e,i){for(var n=-1,o=e==null?0:e.length;++n<o;)if(!i(e[n],n,e))return!1;return!0}function LN(e,i){var n=!0;return So(e,function(o,a,t){return n=!!i(o,a,t),n}),n}function CN(e,i,n){var o=oe(e)?jj:LN;return n&&si(e,i,n)&&(i=void 0),o(e,ee(i))}var YN=4294967295;function kj(e){return e?oa(se(e),0,YN):0}function $N(e,i,n,o){var a=e.length;for(n=se(n),n<0&&(n=-n>a?0:a+n),o=o===void 0||o>a?a:se(o),o<0&&(o+=a),o=n>o?0:kj(o);n<o;)e[n++]=i;return e}function ZN(e,i,n,o){var a=e==null?0:e.length;return a?(n&&typeof n!="number"&&si(e,i,n)&&(n=0,o=a),$N(e,i,n,o)):[]}function Sj(e,i){var n=[];return So(e,function(o,a,t){i(o,a,t)&&n.push(o)}),n}function JN(e,i){var n=oe(e)?ko:Sj;return n(e,ee(i))}function Lj(e){return function(i,n,o){var a=Object(i);if(!mi(i)){var t=ee(n);i=ze(i),n=function(r){return t(a[r],r,a)}}var s=e(i,n,o);return s>-1?a[t?i[s]:s]:void 0}}var xN=Math.max;function Cj(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=n==null?0:se(n);return a<0&&(a=xN(o+a,0)),eu(e,ee(i),a)}var TN=Lj(Cj);function Yj(e,i,n){var o;return n(e,function(a,t,s){if(i(a,t,s))return o=t,!1}),o}function DN(e,i){return Yj(e,ee(i),Ln)}var BN=Math.max,XN=Math.min;function $j(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=o-1;return n!==void 0&&(a=se(n),a=n<0?BN(o+a,0):XN(a,o-1)),eu(e,ee(i),a,!0)}var HN=Lj($j);function MN(e,i){return Yj(e,ee(i),Hh)}function PN(e){return e&&e.length?e[0]:void 0}function Zj(e,i){var n=-1,o=mi(e)?Array(e.length):[];return So(e,function(a,t,s){o[++n]=i(a,t,s)}),o}function cu(e,i){var n=oe(e)?De:Zj;return n(e,ee(i))}function NN(e,i){return Ve(cu(e,i),1)}var EN=1/0;function RN(e,i){return Ve(cu(e,i),EN)}function ON(e,i,n){return n=n===void 0?1:se(n),Ve(cu(e,i),n)}var AN=1/0;function GN(e){var i=e==null?0:e.length;return i?Ve(e,AN):[]}function FN(e,i){var n=e==null?0:e.length;return n?(i=i===void 0?1:se(i),Ve(e,i)):[]}var QN=512;function WN(e){return An(e,QN)}var IN=wh("floor"),_N="Expected a function",zN=8,KN=32,qN=128,UN=256;function Jj(e){return Qn(function(i){var n=i.length,o=n,a=Qi.prototype.thru;for(e&&i.reverse();o--;){var t=i[o];if(typeof t!="function")throw new TypeError(_N);if(a&&!s&&gr(t)=="wrapper")var s=new Qi([],!0)}for(o=s?o:n;++o<n;){t=i[o];var r=gr(t),u=r=="wrapper"?sh(t):void 0;u&&zl(u[0])&&u[1]==(qN|zN|KN|UN)&&!u[4].length&&u[9]==1?s=s[gr(u[0])].apply(s,u[3]):s=t.length==1&&zl(t)?s[r]():s.thru(t)}return function(){var d=arguments,l=d[0];if(s&&d.length==1&&oe(l))return s.plant(l).value();for(var g=0,h=n?i[g].apply(this,d):l;++g<n;)h=i[g].call(this,h);return h}})}var VN=Jj(),eE=Jj(!0);function iE(e,i){return e==null?e:Th(e,Cn(i),bi)}function nE(e,i){return e==null?e:vj(e,Cn(i),bi)}function oE(e,i){return e&&Ln(e,Cn(i))}function aE(e,i){return e&&Hh(e,Cn(i))}function tE(e){for(var i=-1,n=e==null?0:e.length,o={};++i<n;){var a=e[i];kn(o,a[0],a[1])}return o}function pu(e,i){return ko(i,function(n){return Rn(e[n])})}function sE(e){return e==null?[]:pu(e,ze(e))}function rE(e){return e==null?[]:pu(e,bi(e))}var uE=Object.prototype,dE=uE.hasOwnProperty,lE=lu(function(e,i,n){dE.call(e,n)?e[n].push(i):kn(e,n,[i])});function Mh(e,i){return e>i}function vu(e){return function(i,n){return typeof i=="string"&&typeof n=="string"||(i=Ri(i),n=Ri(n)),e(i,n)}}var gE=vu(Mh),hE=vu(function(e,i){return e>=i}),cE=Object.prototype,pE=cE.hasOwnProperty;function vE(e,i){return e!=null&&pE.call(e,i)}function yE(e,i){return e!=null&&oj(e,i,vE)}var fE=Math.max,mE=Math.min;function bE(e,i,n){return e>=mE(i,n)&&e<fE(i,n)}function wE(e,i,n){return i=Pn(i),n===void 0?(n=i,i=0):n=Pn(n),e=Ri(e),bE(e,i,n)}var jE="[object String]";function yu(e){return typeof e=="string"||!oe(e)&&Ne(e)&&di(e)==jE}function Ph(e,i){return De(i,function(n){return e[n]})}function et(e){return e==null?[]:Ph(e,ze(e))}var kE=Math.max;function SE(e,i,n,o){e=mi(e)?e:et(e),n=n&&!o?se(n):0;var a=e.length;return n<0&&(n=kE(a+n,0)),yu(e)?n<=a&&e.indexOf(i,n)>-1:!!a&&_a(e,i,n)>-1}var LE=Math.max;function CE(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=n==null?0:se(n);return a<0&&(a=LE(o+a,0)),_a(e,i,a)}function YE(e){var i=e==null?0:e.length;return i?Ii(e,0,-1):[]}var $E=Math.min;function Nh(e,i,n){for(var o=n?Xh:iu,a=e[0].length,t=e.length,s=t,r=Array(t),u=1/0,d=[];s--;){var l=e[s];s&&i&&(l=De(l,$i(i))),u=$E(l.length,u),r[s]=!n&&(i||a>=120&&l.length>=120)?new Fo(s&&l):void 0}l=e[0];var g=-1,h=r[0];e:for(;++g<a&&d.length<u;){var c=l[g],p=i?i(c):c;if(c=n||c!==0?c:0,!(h?gs(h,p):o(d,p,n))){for(s=t;--s;){var f=r[s];if(!(f?gs(f,p):o(e[s],p,n)))continue e}h&&h.push(p),d.push(c)}}return d}function Eh(e){return Ge(e)?e:[]}var ZE=ue(function(e){var i=De(e,Eh);return i.length&&i[0]===e[0]?Nh(i):[]}),JE=ue(function(e){var i=_i(e),n=De(e,Eh);return i===_i(n)?i=void 0:n.pop(),n.length&&n[0]===e[0]?Nh(n,ee(i)):[]}),xE=ue(function(e){var i=_i(e),n=De(e,Eh);return i=typeof i=="function"?i:void 0,i&&n.pop(),n.length&&n[0]===e[0]?Nh(n,void 0,i):[]});function TE(e,i,n,o){return Ln(e,function(a,t,s){i(o,n(a),t,s)}),o}function xj(e,i){return function(n,o){return TE(n,e,i(o),{})}}var DE=Object.prototype,BE=DE.toString,XE=xj(function(e,i,n){i!=null&&typeof i.toString!="function"&&(i=BE.call(i)),e[i]=n},rh(fi)),Tj=Object.prototype,HE=Tj.hasOwnProperty,ME=Tj.toString,PE=xj(function(e,i,n){i!=null&&typeof i.toString!="function"&&(i=ME.call(i)),HE.call(e,i)?e[i].push(n):e[i]=[n]},ee);function Dj(e,i){return i.length<2?e:na(e,Ii(i,0,-1))}function Ts(e,i,n){i=bo(i,e),e=Dj(e,i);var o=e==null?e:e[an(_i(i))];return o==null?void 0:Yi(o,e,n)}var NE=ue(Ts),EE=ue(function(e,i,n){var o=-1,a=typeof i=="function",t=mi(e)?Array(e.length):[];return So(e,function(s){t[++o]=a?Yi(i,s,n):Ts(s,i,n)}),t}),RE="[object ArrayBuffer]";function OE(e){return Ne(e)&&di(e)==RE}var oy=Wi&&Wi.isArrayBuffer,AE=oy?$i(oy):OE,GE="[object Boolean]";function FE(e){return e===!0||e===!1||Ne(e)&&di(e)==GE}var QE="[object Date]";function WE(e){return Ne(e)&&di(e)==QE}var ay=Wi&&Wi.isDate,IE=ay?$i(ay):WE;function _E(e){return Ne(e)&&e.nodeType===1&&!Zs(e)}var zE="[object Map]",KE="[object Set]",qE=Object.prototype,UE=qE.hasOwnProperty;function VE(e){if(e==null)return!0;if(mi(e)&&(oe(e)||typeof e=="string"||typeof e.splice=="function"||uo(e)||qa(e)||Ao(e)))return!e.length;var i=mn(e);if(i==zE||i==KE)return!e.size;if($s(e))return!gh(e).length;for(var n in e)if(UE.call(e,n))return!1;return!0}function eR(e,i){return Js(e,i)}function iR(e,i,n){n=typeof n=="function"?n:void 0;var o=n?n(e,i):void 0;return o===void 0?Js(e,i,void 0,n):!!o}var nR=_e.isFinite;function oR(e){return typeof e=="number"&&nR(e)}function Bj(e){return typeof e=="number"&&e==se(e)}function aR(e,i){return e===i||$h(e,i,Zh(i))}function tR(e,i,n){return n=typeof n=="function"?n:void 0,$h(e,i,Zh(i),n)}var sR="[object Number]";function Xj(e){return typeof e=="number"||Ne(e)&&di(e)==sR}function rR(e){return Xj(e)&&e!=+e}var uR=lr?Rn:lh,dR="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.";function lR(e){if(uR(e))throw new Error(dR);return zb(e)}function gR(e){return e==null}function hR(e){return e===null}var cR="[object RegExp]";function pR(e){return Ne(e)&&di(e)==cR}var ty=Wi&&Wi.isRegExp,Rh=ty?$i(ty):pR,sy=9007199254740991;function vR(e){return Bj(e)&&e>=-sy&&e<=sy}function yR(e){return e===void 0}var fR="[object WeakMap]";function mR(e){return Ne(e)&&mn(e)==fR}var bR="[object WeakSet]";function wR(e){return Ne(e)&&di(e)==bR}var jR=1;function kR(e){return ee(typeof e=="function"?e:Oi(e,jR))}var SR=Array.prototype,LR=SR.join;function CR(e,i){return e==null?"":LR.call(e,i)}var YR=Va(function(e,i,n){return e+(n?"-":"")+i.toLowerCase()}),$R=lu(function(e,i,n){kn(e,n,i)});function ZR(e,i,n){for(var o=n+1;o--;)if(e[o]===i)return o;return o}var JR=Math.max,xR=Math.min;function TR(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=o;return n!==void 0&&(a=se(n),a=a<0?JR(o+a,0):xR(a,o-1)),i===i?ZR(e,i,a):eu(e,nw,a,!0)}var DR=Va(function(e,i,n){return e+(n?" ":"")+i.toLowerCase()}),BR=Sw("toLowerCase");function Oh(e,i){return e<i}var XR=vu(Oh),HR=vu(function(e,i){return e<=i});function MR(e,i){var n={};return i=ee(i),Ln(e,function(o,a,t){kn(n,i(o,a,t),o)}),n}function PR(e,i){var n={};return i=ee(i),Ln(e,function(o,a,t){kn(n,a,i(o,a,t))}),n}var NR=1;function ER(e){return nj(Oi(e,NR))}var RR=1;function OR(e,i){return aj(e,Oi(i,RR))}function fu(e,i,n){for(var o=-1,a=e.length;++o<a;){var t=e[o],s=i(t);if(s!=null&&(r===void 0?s===s&&!Li(s):n(s,r)))var r=s,u=t}return u}function AR(e){return e&&e.length?fu(e,fi,Mh):void 0}function GR(e,i){return e&&e.length?fu(e,ee(i),Mh):void 0}function Ah(e,i){for(var n,o=-1,a=e.length;++o<a;){var t=i(e[o]);t!==void 0&&(n=n===void 0?t:n+t)}return n}var FR=NaN;function Hj(e,i){var n=e==null?0:e.length;return n?Ah(e,i)/n:FR}function QR(e){return Hj(e,fi)}function WR(e,i){return Hj(e,ee(i))}var IR=Ka(function(e,i,n){gu(e,i,n)}),_R=ue(function(e,i){return function(n){return Ts(n,e,i)}}),zR=ue(function(e,i){return function(n){return Ts(e,n,i)}});function KR(e){return e&&e.length?fu(e,fi,Oh):void 0}function qR(e,i){return e&&e.length?fu(e,ee(i),Oh):void 0}function UR(e,i,n){var o=ze(i),a=pu(i,o),t=!(Me(n)&&"chain"in n)||!!n.chain,s=Rn(e);return Bi(a,function(r){var u=i[r];e[r]=u,s&&(e.prototype[r]=function(){var d=this.__chain__;if(t||d){var l=e(this.__wrapped__),g=l.__actions__=vi(this.__actions__);return g.push({func:u,args:arguments,thisArg:e}),l.__chain__=d,l}return u.apply(e,wo([this.value()],arguments))})}),e}var VR=Ur(function(e,i){return e*i},1),eO="Expected a function";function mu(e){if(typeof e!="function")throw new TypeError(eO);return function(){var i=arguments;switch(i.length){case 0:return!e.call(this);case 1:return!e.call(this,i[0]);case 2:return!e.call(this,i[0],i[1]);case 3:return!e.call(this,i[0],i[1],i[2])}return!e.apply(this,i)}}function iO(e){for(var i,n=[];!(i=e.next()).done;)n.push(i.value);return n}var nO="[object Map]",oO="[object Set]",Dd=oi?oi.iterator:void 0;function Mj(e){if(!e)return[];if(mi(e))return yu(e)?tn(e):vi(e);if(Dd&&e[Dd])return iO(e[Dd]());var i=mn(e),n=i==nO?Yh:i==oO?du:et;return n(e)}function aO(){this.__values__===void 0&&(this.__values__=Mj(this.value()));var e=this.__index__>=this.__values__.length,i=e?void 0:this.__values__[this.__index__++];return{done:e,value:i}}function Pj(e,i){var n=e.length;if(n)return i+=i<0?n:0,On(i,n)?e[i]:void 0}function tO(e,i){return e&&e.length?Pj(e,se(i)):void 0}function sO(e){return e=se(e),ue(function(i){return Pj(i,e)})}var rO=Object.prototype,uO=rO.hasOwnProperty;function Gh(e,i){i=bo(i,e);var n=-1,o=i.length;if(!o)return!0;for(;++n<o;){var a=an(i[n]);if(a==="__proto__"&&!uO.call(e,"__proto__")||(a==="constructor"||a==="prototype")&&n<o-1)return!1}var t=Dj(e,i);return t==null||delete t[an(_i(i))]}function dO(e){return Zs(e)?void 0:e}var lO=1,gO=2,hO=4,cO=Qn(function(e,i){var n={};if(e==null)return n;var o=!1;i=De(i,function(t){return t=bo(t,e),o||(o=t.length>1),t}),Sn(e,Sh(e),n),o&&(n=Oi(n,lO|gO|hO,dO));for(var a=i.length;a--;)Gh(n,i[a]);return n});function Ds(e,i,n,o){if(!Me(e))return e;i=bo(i,e);for(var a=-1,t=i.length,s=t-1,r=e;r!=null&&++a<t;){var u=an(i[a]),d=n;if(u==="__proto__"||u==="constructor"||u==="prototype")return e;if(a!=s){var l=r[u];d=o?o(l,u,r):void 0,d===void 0&&(d=Me(l)?l:On(i[a+1])?[]:{})}Ys(r,u,d),r=r[u]}return e}function Nj(e,i,n){for(var o=-1,a=i.length,t={};++o<a;){var s=i[o],r=na(e,s);n(r,s)&&Ds(t,bo(s,e),r)}return t}function Ej(e,i){if(e==null)return{};var n=De(Sh(e),function(o){return[o]});return i=ee(i),Nj(e,n,function(o,a){return i(o,a[0])})}function pO(e,i){return Ej(e,mu(ee(i)))}function vO(e){return yw(2,e)}function yO(e,i){var n=e.length;for(e.sort(i);n--;)e[n]=e[n].value;return e}function Rj(e,i){if(e!==i){var n=e!==void 0,o=e===null,a=e===e,t=Li(e),s=i!==void 0,r=i===null,u=i===i,d=Li(i);if(!r&&!d&&!t&&e>i||t&&s&&u&&!r&&!d||o&&s&&u||!n&&u||!a)return 1;if(!o&&!t&&!d&&e<i||d&&n&&a&&!o&&!t||r&&n&&a||!s&&a||!u)return-1}return 0}function fO(e,i,n){for(var o=-1,a=e.criteria,t=i.criteria,s=a.length,r=n.length;++o<s;){var u=Rj(a[o],t[o]);if(u){if(o>=r)return u;var d=n[o];return u*(d=="desc"?-1:1)}}return e.index-i.index}function Oj(e,i,n){i.length?i=De(i,function(t){return oe(t)?function(s){return na(s,t.length===1?t[0]:t)}:t}):i=[fi];var o=-1;i=De(i,$i(ee));var a=Zj(e,function(t,s,r){var u=De(i,function(d){return d(t)});return{criteria:u,index:++o,value:t}});return yO(a,function(t,s){return fO(t,s,n)})}function mO(e,i,n,o){return e==null?[]:(oe(i)||(i=i==null?[]:[i]),n=o?void 0:n,oe(n)||(n=n==null?[]:[n]),Oj(e,i,n))}function Fh(e){return Qn(function(i){return i=De(i,$i(ee)),ue(function(n){var o=this;return e(i,function(a){return Yi(a,o,n)})})})}var bO=Fh(De),wO=ue,jO=Math.min,kO=wO(function(e,i){i=i.length==1&&oe(i[0])?De(i[0],$i(ee)):De(Ve(i,1),$i(ee));var n=i.length;return ue(function(o){for(var a=-1,t=jO(o.length,n);++a<t;)o[a]=i[a].call(this,o[a]);return Yi(e,this,o)})}),SO=Fh(jj),LO=Fh(Ch),CO=9007199254740991,YO=Math.floor;function ag(e,i){var n="";if(!e||i<1||i>CO)return n;do i%2&&(n+=e),i=YO(i/2),i&&(e+=e);while(i);return n}var $O=xh("length"),Aj="\\ud800-\\udfff",ZO="\\u0300-\\u036f",JO="\\ufe20-\\ufe2f",xO="\\u20d0-\\u20ff",TO=ZO+JO+xO,DO="\\ufe0e\\ufe0f",BO="["+Aj+"]",tg="["+TO+"]",sg="\\ud83c[\\udffb-\\udfff]",XO="(?:"+tg+"|"+sg+")",Gj="[^"+Aj+"]",Fj="(?:\\ud83c[\\udde6-\\uddff]){2}",Qj="[\\ud800-\\udbff][\\udc00-\\udfff]",HO="\\u200d",Wj=XO+"?",Ij="["+DO+"]?",MO="(?:"+HO+"(?:"+[Gj,Fj,Qj].join("|")+")"+Ij+Wj+")*",PO=Ij+Wj+MO,NO="(?:"+[Gj+tg+"?",tg,Fj,Qj,BO].join("|")+")",ry=RegExp(sg+"(?="+sg+")|"+NO+PO,"g");function EO(e){for(var i=ry.lastIndex=0;ry.test(e);)++i;return i}function it(e){return Ua(e)?EO(e):$O(e)}var RO=Math.ceil;function Hr(e,i){i=i===void 0?" ":Ci(i);var n=i.length;if(n<2)return n?ag(i,e):i;var o=ag(i,RO(e/it(i)));return Ua(i)?jo(tn(o),0,e).join(""):o.slice(0,e)}var OO=Math.ceil,AO=Math.floor;function GO(e,i,n){e=me(e),i=se(i);var o=i?it(e):0;if(!i||o>=i)return e;var a=(i-o)/2;return Hr(AO(a),n)+e+Hr(OO(a),n)}function FO(e,i,n){e=me(e),i=se(i);var o=i?it(e):0;return i&&o<i?e+Hr(i-o,n):e}function QO(e,i,n){e=me(e),i=se(i);var o=i?it(e):0;return i&&o<i?Hr(i-o,n)+e:e}var WO=/^\s+/,IO=_e.parseInt;function _O(e,i,n){return n||i==null?i=0:i&&(i=+i),IO(me(e).replace(WO,""),i||0)}var zO=32,bu=ue(function(e,i){var n=ro(i,za(bu));return An(e,zO,void 0,i,n)});bu.placeholder={};var KO=64,Qh=ue(function(e,i){var n=ro(i,za(Qh));return An(e,KO,void 0,i,n)});Qh.placeholder={};var qO=lu(function(e,i,n){e[n?0:1].push(i)},function(){return[[],[]]});function UO(e,i){return Nj(e,i,function(n,o){return Jh(e,o)})}var VO=Qn(function(e,i){return e==null?{}:UO(e,i)});function eA(e){for(var i,n=this;n instanceof Vr;){var o=Vb(n);o.__index__=0,o.__values__=void 0,i?a.__wrapped__=o:i=o;var a=o;n=n.__wrapped__}return a.__wrapped__=e,i}function iA(e){return function(i){return e==null?void 0:na(e,i)}}function nA(e,i,n,o){for(var a=n-1,t=e.length;++a<t;)if(o(e[a],i))return a;return-1}var oA=Array.prototype,uy=oA.splice;function Wh(e,i,n,o){var a=o?nA:_a,t=-1,s=i.length,r=e;for(e===i&&(i=vi(i)),n&&(r=De(e,$i(n)));++t<s;)for(var u=0,d=i[t],l=n?n(d):d;(u=a(r,l,u,o))>-1;)r!==e&&uy.call(r,u,1),uy.call(e,u,1);return e}function _j(e,i){return e&&e.length&&i&&i.length?Wh(e,i):e}var aA=ue(_j);function tA(e,i,n){return e&&e.length&&i&&i.length?Wh(e,i,ee(n)):e}function sA(e,i,n){return e&&e.length&&i&&i.length?Wh(e,i,void 0,n):e}var rA=Array.prototype,uA=rA.splice;function zj(e,i){for(var n=e?i.length:0,o=n-1;n--;){var a=i[n];if(n==o||a!==t){var t=a;On(a)?uA.call(e,a,1):Gh(e,a)}}return e}var dA=Qn(function(e,i){var n=e==null?0:e.length,o=ph(e,i);return zj(e,De(i,function(a){return On(a,n)?+a:a}).sort(Rj)),o}),lA=Math.floor,gA=Math.random;function Ih(e,i){return e+lA(gA()*(i-e+1))}var hA=parseFloat,cA=Math.min,pA=Math.random;function vA(e,i,n){if(n&&typeof n!="boolean"&&si(e,i,n)&&(i=n=void 0),n===void 0&&(typeof i=="boolean"?(n=i,i=void 0):typeof e=="boolean"&&(n=e,e=void 0)),e===void 0&&i===void 0?(e=0,i=1):(e=Pn(e),i===void 0?(i=e,e=0):i=Pn(i)),e>i){var o=e;e=i,i=o}if(n||e%1||i%1){var a=pA();return cA(e+a*(i-e+hA("1e-"+((a+"").length-1))),i)}return Ih(e,i)}var yA=Math.ceil,fA=Math.max;function mA(e,i,n,o){for(var a=-1,t=fA(yA((i-e)/(n||1)),0),s=Array(t);t--;)s[o?t:++a]=e,e+=n;return s}function Kj(e){return function(i,n,o){return o&&typeof o!="number"&&si(i,n,o)&&(n=o=void 0),i=Pn(i),n===void 0?(n=i,i=0):n=Pn(n),o=o===void 0?i<n?1:-1:Pn(o),mA(i,n,o,e)}}var bA=Kj(),wA=Kj(!0),jA=256,kA=Qn(function(e,i){return An(e,jA,void 0,void 0,void 0,i)});function qj(e,i,n,o,a){return a(e,function(t,s,r){n=o?(o=!1,t):i(n,t,s,r)}),n}function SA(e,i,n){var o=oe(e)?mh:qj,a=arguments.length<3;return o(e,ee(i),n,a,So)}function LA(e,i,n,o){var a=e==null?0:e.length;for(o&&a&&(n=e[--a]);a--;)n=i(n,e[a],a,e);return n}function CA(e,i,n){var o=oe(e)?LA:qj,a=arguments.length<3;return o(e,ee(i),n,a,yj)}function YA(e,i){var n=oe(e)?ko:Sj;return n(e,mu(ee(i)))}function $A(e,i){var n=[];if(!(e&&e.length))return n;var o=-1,a=[],t=e.length;for(i=ee(i);++o<t;){var s=e[o];i(s,o,e)&&(n.push(s),a.push(o))}return zj(e,a),n}function ZA(e,i,n){return(n?si(e,i,n):i===void 0)?i=1:i=se(i),ag(me(e),i)}function JA(){var e=arguments,i=me(e[0]);return e.length<3?i:i.replace(e[1],e[2])}var xA="Expected a function";function TA(e,i){if(typeof e!="function")throw new TypeError(xA);return i=i===void 0?i:se(i),ue(e,i)}function DA(e,i,n){i=bo(i,e);var o=-1,a=i.length;for(a||(a=1,e=void 0);++o<a;){var t=e?.[an(i[o])];t===void 0&&(o=a,t=n),e=Rn(t)?t.call(e):t}return e}var BA=Array.prototype,XA=BA.reverse;function rg(e){return e==null?e:XA.call(e)}var HA=wh("round");function Uj(e){var i=e.length;return i?e[Ih(0,i-1)]:void 0}function MA(e){return Uj(et(e))}function PA(e){var i=oe(e)?Uj:MA;return i(e)}function wu(e,i){var n=-1,o=e.length,a=o-1;for(i=i===void 0?o:i;++n<i;){var t=Ih(n,a),s=e[t];e[t]=e[n],e[n]=s}return e.length=i,e}function NA(e,i){return wu(vi(e),oa(i,0,e.length))}function EA(e,i){var n=et(e);return wu(n,oa(i,0,n.length))}function RA(e,i,n){(n?si(e,i,n):i===void 0)?i=1:i=se(i);var o=oe(e)?NA:EA;return o(e,i)}function OA(e,i,n){return e==null?e:Ds(e,i,n)}function AA(e,i,n,o){return o=typeof o=="function"?o:void 0,e==null?e:Ds(e,i,n,o)}function GA(e){return wu(vi(e))}function FA(e){return wu(et(e))}function QA(e){var i=oe(e)?GA:FA;return i(e)}var WA="[object Map]",IA="[object Set]";function _A(e){if(e==null)return 0;if(mi(e))return yu(e)?it(e):e.length;var i=mn(e);return i==WA||i==IA?e.size:gh(e).length}function zA(e,i,n){var o=e==null?0:e.length;return o?(n&&typeof n!="number"&&si(e,i,n)?(i=0,n=o):(i=i==null?0:se(i),n=n===void 0?o:se(n)),Ii(e,i,n)):[]}var KA=Va(function(e,i,n){return e+(n?"_":"")+i.toLowerCase()});function qA(e,i){var n;return So(e,function(o,a,t){return n=i(o,a,t),!n}),!!n}function UA(e,i,n){var o=oe(e)?Ch:qA;return n&&si(e,i,n)&&(i=void 0),o(e,ee(i))}var VA=ue(function(e,i){if(e==null)return[];var n=i.length;return n>1&&si(e,i[0],i[1])?i=[]:n>2&&si(i[0],i[1],i[2])&&(i=[i[0]]),Oj(e,Ve(i,1),[])}),eG=4294967295,iG=eG-1,nG=Math.floor,oG=Math.min;function _h(e,i,n,o){var a=0,t=e==null?0:e.length;if(t===0)return 0;i=n(i);for(var s=i!==i,r=i===null,u=Li(i),d=i===void 0;a<t;){var l=nG((a+t)/2),g=n(e[l]),h=g!==void 0,c=g===null,p=g===g,f=Li(g);if(s)var w=o||p;else d?w=p&&(o||h):r?w=p&&h&&(o||!c):u?w=p&&h&&!c&&(o||!f):c||f?w=!1:w=o?g<=i:g<i;w?a=l+1:t=l}return oG(t,iG)}var aG=4294967295,tG=aG>>>1;function ju(e,i,n){var o=0,a=e==null?o:e.length;if(typeof i=="number"&&i===i&&a<=tG){for(;o<a;){var t=o+a>>>1,s=e[t];s!==null&&!Li(s)&&(n?s<=i:s<i)?o=t+1:a=t}return a}return _h(e,i,fi,n)}function sG(e,i){return ju(e,i)}function rG(e,i,n){return _h(e,i,ee(n))}function uG(e,i){var n=e==null?0:e.length;if(n){var o=ju(e,i);if(o<n&&dn(e[o],i))return o}return-1}function dG(e,i){return ju(e,i,!0)}function lG(e,i,n){return _h(e,i,ee(n),!0)}function gG(e,i){var n=e==null?0:e.length;if(n){var o=ju(e,i,!0)-1;if(dn(e[o],i))return o}return-1}function Vj(e,i){for(var n=-1,o=e.length,a=0,t=[];++n<o;){var s=e[n],r=i?i(s):s;if(!n||!dn(r,u)){var u=r;t[a++]=s===0?0:s}}return t}function hG(e){return e&&e.length?Vj(e):[]}function cG(e,i){return e&&e.length?Vj(e,ee(i)):[]}var pG=4294967295;function vG(e,i,n){return n&&typeof n!="number"&&si(e,i,n)&&(i=n=void 0),n=n===void 0?pG:n>>>0,n?(e=me(e),e&&(typeof i=="string"||i!=null&&!Rh(i))&&(i=Ci(i),!i&&Ua(e))?jo(tn(e),0,n):e.split(i,n)):[]}var yG="Expected a function",fG=Math.max;function mG(e,i){if(typeof e!="function")throw new TypeError(yG);return i=i==null?0:fG(se(i),0),ue(function(n){var o=n[i],a=jo(n,0,i);return o&&wo(a,o),Yi(e,this,a)})}var bG=Va(function(e,i,n){return e+(n?" ":"")+fh(i)});function wG(e,i,n){return e=me(e),n=n==null?0:oa(se(n),0,e.length),i=Ci(i),e.slice(n,n+i.length)==i}function jG(){return{}}function kG(){return""}function SG(){return!0}var LG=Ur(function(e,i){return e-i},0);function CG(e){return e&&e.length?Ah(e,fi):0}function YG(e,i){return e&&e.length?Ah(e,ee(i)):0}function $G(e){var i=e==null?0:e.length;return i?Ii(e,1,i):[]}function ZG(e,i,n){return e&&e.length?(i=n||i===void 0?1:se(i),Ii(e,0,i<0?0:i)):[]}function JG(e,i,n){var o=e==null?0:e.length;return o?(i=n||i===void 0?1:se(i),i=o-i,Ii(e,i<0?0:i,o)):[]}function xG(e,i){return e&&e.length?hu(e,ee(i),!1,!0):[]}function TG(e,i){return e&&e.length?hu(e,ee(i)):[]}function DG(e,i){return i(e),e}var ek=Object.prototype,BG=ek.hasOwnProperty;function dy(e,i,n,o){return e===void 0||dn(e,ek[n])&&!BG.call(o,n)?i:e}var XG={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};function HG(e){return"\\"+XG[e]}var ik=/<%=([\s\S]+?)%>/g,MG=/<%-([\s\S]+?)%>/g,PG=/<%([\s\S]+?)%>/g,ug={escape:MG,evaluate:PG,interpolate:ik,variable:"",imports:{_:{escape:bj}}},NG="Invalid `variable` option passed into `_.template`",EG="Invalid `imports` option passed into `_.template`",RG=/\b__p \+= '';/g,OG=/\b(__p \+=) '' \+/g,AG=/(__e\(.*?\)|\b__t\)) \+\n'';/g,ly=/[()=,{}\[\]\/\s]/,GG=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Ks=/($^)/,FG=/['\n\r\u2028\u2029\\]/g,QG=Object.prototype,gy=QG.hasOwnProperty;function WG(e,i,n){var o=ug.imports._.templateSettings||ug;n&&si(e,i,n)&&(i=void 0),e=me(e),i=Kl({},i,o,dy);var a=Kl({},i.imports,o.imports,dy),t=ze(a),s=Ph(a,t);Bi(t,function(w){if(ly.test(w))throw new Error(EG)});var r,u,d=0,l=i.interpolate||Ks,g="__p += '",h=RegExp((i.escape||Ks).source+"|"+l.source+"|"+(l===ik?GG:Ks).source+"|"+(i.evaluate||Ks).source+"|$","g"),c=gy.call(i,"sourceURL")?"//# sourceURL="+(i.sourceURL+"").replace(/\s/g," ")+`
18
18
  `:"";e.replace(h,function(w,v,j,C,y,k){return j||(j=C),g+=e.slice(d,k).replace(FG,HG),v&&(r=!0,g+=`' +
@@ -54,7 +54,7 @@ ${Array.from({length:i+1}).join(n)}`}},Yu=(e,i)=>{if(e.length===0)return"";const
54
54
  `);typeof o.tabWidth=="number"&&e.includes(" ")&&(t=t.map(p=>p.replaceAll(" "," ".repeat(o.tabWidth))));const{end:s,markerLines:r,start:u}=JK(i,t,o.linesAbove,o.linesBelow),d=String(s).length,{gutter:l,marker:g,message:h}=o.color;let c=t.slice(u,s).map((p,f)=>{const w=u+1+f,v=r[w],j=String(w).padStart(d),C=!r[w+1],y=` ${j}${o.showGutter?" |":""}`;if(v){let k="";if(Array.isArray(v)){const S=p.replaceAll(/[^\t]/g," ").slice(0,Math.max(v[0]-1,0)),J=v[1]||1;k=[`
55
55
  `,o.prefix+l(y.replaceAll(/\d/g," "))," ",S,g("^").repeat(J)].join(""),C&&o.message&&(k+=` ${h(o.message)}`)}return[o.prefix+g(xK),l(y),p.length>0?` ${p}`:"",k].join("")}return`${o.prefix} ${l(y)}${p.length>0?` ${p}`:""}`}).join(`
56
56
  `);return o.message&&!a&&(c=`${o.prefix+" ".repeat(d+1)+o.message}
57
- ${c}`),c},DK=()=>hg.env?.DEBUG==="true",Qo=(e,...i)=>{if(DK()){const n=i.map(o=>typeof o=="function"?o():o);console.debug(`error:parse-stacktrace: ${e}`,...n)}},Wo="<unknown>",BK=/^(?:node:internal\/|node:|internal\/)/,XK=e=>e!==void 0&&BK.test(e),HK=/^.*?\s*at\s(?:(.+?\)(?:\s\[.+\])?|\(?.*?)\s?\((?:address\sat\s)?)?(?:async\s)?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,MK=/\((\S+)\),\s(<[^>]+>)?:(\d+)?:(\d+)?\)?/,PK=/(.*?):(\d+):(\d+)(?:\s<-\s.+:\d+:\d+)?/,NK=/eval\sat\s(<anonymous>)\s\((.*)\)?:(\d+)?:(\d+)\),\s*<anonymous>?:(\d+)?:(\d+)/,EK=/^\s*in\s(?:([^\\/]+(?:\s\[as\s\S+\])?)\s\(?)?\(at?\s?(.*?):(\d+)(?::(\d+))?\)?\s*$/,RK=/in\s(.*)\s\(at\s(.+)\)\sat/,OK=/^(?:.*@)?(.*):(\d+):(\d+)$/,AK=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. \/=]+)(?::(\d+))?(?::(\d+))?\s*$/i,GK=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,FK=/(\S[^\s[]*\[.*\]|.*?)@(.*):(\d+):(\d+)/,Ey=/\(error: (.*)\)/,QK=/at\s/,WK=/^(\S+):(\d+):(\d+)$|^(\S+):(\d+)$/,IK=/\S*(?:Error: |AggregateError:)/,xk=/^Anonymous function$/,_K=/^\s*in\s.*/,zK=/^.*?\s*at\s.*/,KK=/^.*?\s*@.*|\[native code\]/,Tk=(e,i)=>{const n=e.includes("safari-extension"),o=e.includes("safari-web-extension");return n||o?[e.includes("@")?e.split("@")[0]:Wo,n?`safari-extension:${i}`:`safari-web-extension:${i}`]:[e,i]},Dk=(e,i)=>{const n=PK.exec(i);n&&(e.file=n[1],e.line=+n[2],e.column=+n[3])},qK=e=>{const i=RK.exec(e);if(i){Qo(`parse nested node error stack line: "${e}"`,()=>`found: ${JSON.stringify(i)}`);const o=i[2].split(":");return{column:o[2]?+o[2]:void 0,file:o[0],line:o[1]?+o[1]:void 0,methodName:i[1]??Wo,raw:e,type:void 0}}const n=EK.exec(e);if(n){Qo(`parse node error stack line: "${e}"`,()=>`found: ${JSON.stringify(n)}`);const o={column:n[4]?+n[4]:void 0,file:n[2]?n[2].replace(QK,""):void 0,line:n[3]?+n[3]:void 0,methodName:n[1]??Wo,raw:e,type:e.startsWith("internal")?"internal":void 0};return Dk(o,`${n[2]}:${n[3]}:${n[4]}`),o}},UK=e=>{const i=HK.exec(e);if(i){Qo(`parse chrome error stack line: "${e}"`,()=>`found: ${JSON.stringify(i)}`);const n=i[2]?.startsWith("native"),o=i[2]?.startsWith("eval")||i[1]?.startsWith("eval");let a,t;if(o){const d=MK.exec(e);if(d){const l=WK.exec(d[1]);l?(i[2]=l[4]??l[1],i[3]=l[5]??l[2],i[4]=l[3]):d[2]&&(i[2]=d[1]),d[2]&&(a={column:d[4]?+d[4]:void 0,file:d[2],line:d[3]?+d[3]:void 0,methodName:"eval",raw:e,type:"eval"})}else{const l=NK.exec(e);l&&(t={column:l[4]?+l[4]:void 0,file:l[2],line:l[3]?+l[3]:void 0},a={column:l[6]?+l[6]:void 0,file:l[1],line:l[5]?+l[5]:void 0,methodName:"eval",raw:l[0],type:"eval"})}}const[s,r]=Tk(i[1]?i[1].replace(xk,"<anonymous>"):Wo,i[2]),u={column:i[4]?+i[4]:void 0,evalOrigin:a,file:r,line:i[3]?+i[3]:void 0,methodName:s,raw:e,type:o?"eval":n?"native":XK(r)?"internal":void 0};return t?(u.column=t.column,u.file=t.file,u.line=t.line):Dk(u,`${r}:${i[3]}:${i[4]}`),u}},VK=(e,i)=>{const n=AK.exec(e);if(n){Qo(`parse gecko error stack line: "${e}"`,()=>`found: ${JSON.stringify(n)}`);const o=n[3]?.includes(" > eval"),a=o&&n[3]&&GK.exec(n[3]);let t;o&&a&&(n[3]=a[1],t={column:n[5]?+n[5]:void 0,file:n[3],line:n[4]?+n[4]:void 0,methodName:"eval",raw:e,type:"eval"},n[4]=a[2]);const[s,r]=Tk(n[1]?n[1].replace(xk,"<anonymous>"):Wo,n[3]);let u;(i?.type==="safari"||!o&&i?.type==="firefox")&&i.column?u=i.column:!o&&n[5]&&(u=+n[5]);let d;return(i?.type==="safari"||!o&&i?.type==="firefox")&&i.line?d=i.line:n[4]&&(d=+n[4]),{column:u,evalOrigin:t,file:r,line:d,methodName:s,raw:e,type:o?"eval":r.includes("[native code]")?"native":void 0}}},e7=(e,i)=>{const n=FK.exec(e);if(!(n&&n[2].includes(" > eval"))&&n)return Qo(`parse firefox error stack line: "${e}"`,()=>`found: ${JSON.stringify(n)}`),{column:n[4]?+n[4]:i?.column??void 0,file:n[2],line:n[3]?+n[3]:i?.line??void 0,methodName:n[1]||Wo,raw:e,type:void 0}},i7=e=>{const i=OK.exec(e);if(i)return Qo(`parse react android native error stack line: "${e}"`,()=>`found: ${JSON.stringify(i)}`),{column:i[3]?+i[3]:void 0,file:i[1],line:i[2]?+i[2]:void 0,methodName:Wo,raw:e,type:void 0}},Bk=(e,{filter:i,frameLimit:n=50}={})=>{const o=e;let a=(typeof o.stacktrace=="string"?o.stacktrace:e.stack??"").split(`
57
+ ${c}`),c},DK=()=>hg.env?.DEBUG==="true",Qo=(e,...i)=>{if(DK()){const n=i.map(o=>typeof o=="function"?o():o);console.debug(`error:parse-stacktrace: ${e}`,...n)}},Wo="<unknown>",BK=/^(?:node:internal\/|node:|internal\/)/,XK=e=>e!==void 0&&BK.test(e),HK=/^.*?\s*at\s(?:(.+?\)(?:\s\[.+\])?|\(?.*?)\s?\((?:address\sat\s)?)?(?:async\s)?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,MK=/\((\S+)\),\s(<[^>]+>)?:(\d+)?:(\d+)?\)?/,PK=/(.*?):(\d+):(\d+)(?:\s<-\s.+:\d+:\d+)?/,NK=/eval\sat\s(<anonymous>)\s\((.*)\)?:(\d+)?:(\d+)\),\s*<anonymous>?:(\d+)?:(\d+)/,EK=/^\s*in\s(?:([^\\/]+(?:\s\[as\s\S+\])?)\s\(?)?\(at?\s?(.*?):(\d+)(?::(\d+))?\)?\s*$/,RK=/in\s(.*)\s\(at\s(.+)\)\sat/,OK=/^(?:.*@)?(.*):(\d+):(\d+)$/,AK=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. \/=]+)(?::(\d+))?(?::(\d+))?\s*$/i,GK=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,FK=/(\S[^\s[]*\[.*\]|.*?)@(.*):(\d+):(\d+)/,Ey=/\(error: ([^)]*)\)/,QK=/at\s/,WK=/^(\S+):(\d+):(\d+)$|^(\S+):(\d+)$/,IK=/Error: |AggregateError:/,xk=/^Anonymous function$/,_K=/^\s*in\s.*/,zK=/^.*?\s*at\s.*/,KK=/^.*?\s*@.*|\[native code\]/,Tk=(e,i)=>{const n=e.includes("safari-extension"),o=e.includes("safari-web-extension");return n||o?[e.includes("@")?e.split("@")[0]:Wo,n?`safari-extension:${i}`:`safari-web-extension:${i}`]:[e,i]},Dk=(e,i)=>{const n=PK.exec(i);n&&(e.file=n[1],e.line=+n[2],e.column=+n[3])},qK=e=>{const i=RK.exec(e);if(i){Qo(`parse nested node error stack line: "${e}"`,()=>`found: ${JSON.stringify(i)}`);const o=i[2].split(":");return{column:o[2]?+o[2]:void 0,file:o[0],line:o[1]?+o[1]:void 0,methodName:i[1]??Wo,raw:e,type:void 0}}const n=EK.exec(e);if(n){Qo(`parse node error stack line: "${e}"`,()=>`found: ${JSON.stringify(n)}`);const o={column:n[4]?+n[4]:void 0,file:n[2]?n[2].replace(QK,""):void 0,line:n[3]?+n[3]:void 0,methodName:n[1]??Wo,raw:e,type:e.startsWith("internal")?"internal":void 0};return Dk(o,`${n[2]}:${n[3]}:${n[4]}`),o}},UK=e=>{const i=HK.exec(e);if(i){Qo(`parse chrome error stack line: "${e}"`,()=>`found: ${JSON.stringify(i)}`);const n=i[2]?.startsWith("native"),o=i[2]?.startsWith("eval")||i[1]?.startsWith("eval");let a,t;if(o){const d=MK.exec(e);if(d){const l=WK.exec(d[1]);l?(i[2]=l[4]??l[1],i[3]=l[5]??l[2],i[4]=l[3]):d[2]&&(i[2]=d[1]),d[2]&&(a={column:d[4]?+d[4]:void 0,file:d[2],line:d[3]?+d[3]:void 0,methodName:"eval",raw:e,type:"eval"})}else{const l=NK.exec(e);l&&(t={column:l[4]?+l[4]:void 0,file:l[2],line:l[3]?+l[3]:void 0},a={column:l[6]?+l[6]:void 0,file:l[1],line:l[5]?+l[5]:void 0,methodName:"eval",raw:l[0],type:"eval"})}}const[s,r]=Tk(i[1]?i[1].replace(xk,"<anonymous>"):Wo,i[2]),u={column:i[4]?+i[4]:void 0,evalOrigin:a,file:r,line:i[3]?+i[3]:void 0,methodName:s,raw:e,type:o?"eval":n?"native":XK(r)?"internal":void 0};return t?(u.column=t.column,u.file=t.file,u.line=t.line):Dk(u,`${r}:${i[3]}:${i[4]}`),u}},VK=(e,i)=>{const n=AK.exec(e);if(n){Qo(`parse gecko error stack line: "${e}"`,()=>`found: ${JSON.stringify(n)}`);const o=n[3]?.includes(" > eval"),a=o&&n[3]&&GK.exec(n[3]);let t;o&&a&&(n[3]=a[1],t={column:n[5]?+n[5]:void 0,file:n[3],line:n[4]?+n[4]:void 0,methodName:"eval",raw:e,type:"eval"},n[4]=a[2]);const[s,r]=Tk(n[1]?n[1].replace(xk,"<anonymous>"):Wo,n[3]);let u;(i?.type==="safari"||!o&&i?.type==="firefox")&&i.column?u=i.column:!o&&n[5]&&(u=+n[5]);let d;return(i?.type==="safari"||!o&&i?.type==="firefox")&&i.line?d=i.line:n[4]&&(d=+n[4]),{column:u,evalOrigin:t,file:r,line:d,methodName:s,raw:e,type:o?"eval":r.includes("[native code]")?"native":void 0}}},e7=(e,i)=>{const n=FK.exec(e);if(!(n&&n[2].includes(" > eval"))&&n)return Qo(`parse firefox error stack line: "${e}"`,()=>`found: ${JSON.stringify(n)}`),{column:n[4]?+n[4]:i?.column??void 0,file:n[2],line:n[3]?+n[3]:i?.line??void 0,methodName:n[1]||Wo,raw:e,type:void 0}},i7=e=>{const i=OK.exec(e);if(i)return Qo(`parse react android native error stack line: "${e}"`,()=>`found: ${JSON.stringify(i)}`),{column:i[3]?+i[3]:void 0,file:i[1],line:i[2]?+i[2]:void 0,methodName:Wo,raw:e,type:void 0}},Bk=(e,{filter:i,frameLimit:n=50}={})=>{const o=e;let a=(typeof o.stacktrace=="string"?o.stacktrace:e.stack??"").split(`
58
58
  `).map(t=>(Ey.test(t)?t.replace(Ey,"$1"):t).trim()).filter(t=>!IK.test(t)&&t!=="eval code");return i&&(a=a.filter(t=>i(t))),a=a.slice(0,n),a.reduce((t,s,r)=>{if(!s||s.length>1024)return t;let u;if(_K.test(s))u=qK(s);else if(zK.test(s))u=UK(s);else if(KK.test(s)){let d;if(r===0){const l=e,g=l.columnNumber,h=l.lineNumber,c=l.line,p=l.column;g||h?d={column:g,line:h,type:"firefox"}:(c||p)&&(d={column:p,line:c,type:"safari"})}u=e7(s,d)??VK(s,d)}else u=i7(s);return u?t.push(u):Qo(`parse error stack line: "${s}"`,"not parser found"),t},[])},n7=Cu(import.meta.url),ya=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,nc=e=>{if(typeof ya<"u"&&ya.versions&&ya.versions.node){const[i,n]=ya.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return ya.getBuiltinModule(e)}return n7(e)},{existsSync:o7,readFileSync:a7}=nc("node:fs"),{relative:t7,resolve:Ry,sep:s7}=nc("node:path"),{cwd:r7}=ya,{fileURLToPath:u7}=nc("node:url"),Io=(e,i,n)=>n===0?e:i===" "?e+" ".repeat(n):e+" ".repeat(i*n),Xk=e=>e.replaceAll("\\","/"),d7=(e,i)=>{const n=e.replace("async file:","file:");return Xk(t7(i,n.startsWith("file:")?u7(n):n))},l7=(e,i,n)=>{if(i)return n.title(e.message);const o=e.message?`: ${e.message}`:"";return n.title(e.name+o)},Hk=(e,{color:i,hideErrorTitle:n,indentation:o,prefix:a},t)=>`${Io(a,o,t)}${l7(e,n,i)}
59
59
  `,Mk=(e,{color:i,indentation:n,prefix:o},a)=>{if(e.hint===void 0)return;const t=Io(o,n,a);let s="";if(Array.isArray(e.hint))for(const r of e.hint)s+=`${t+r}
60
60
  `;else s+=t+e.hint;return i.hint(s)},Pk=(e,i)=>{if(!i||e.file===void 0||e.line===void 0)return{trace:e};try{const n=i({column:e.column,file:e.file,line:e.line});return n?{source:n.source,trace:{...e,column:n.column??e.column,file:n.file??e.file,line:n.line??e.line}}:{trace:e}}catch{return{trace:e}}},oc=(e,i,n=0)=>{const{color:o,cwd:a,displayShortPath:t,indentation:s,prefix:r}=i,{trace:u}=Pk(e,i.sourceMap),d=t?d7(u.file,a):Xk(u.file),{fileLine:l,method:g}=o;return`${Io(r,s,n)}at ${u.methodName?`${g(u.methodName)} `:""}${l(d)}:${l(u.line?.toString()??"")}`},g7=(e,i)=>{if(i.allowAllFilePaths)return!0;const n=Ry(i.cwd),o=Ry(n,e);return o===n||o.startsWith(n+s7)},Nk=(e,i,n)=>{const{color:o,indentation:a,linesAbove:t,linesBelow:s,prefix:r,showGutter:u,showLineNumbers:d,tabWidth:l}=i,{source:g,trace:h}=Pk(e,i.sourceMap);if(h.file===void 0)return;let c;if(g===void 0){const p=h.file.replace("file://","");if(!g7(p,i)||!o7(p))return;c=a7(p,"utf8")}else c=g;return TK(c,{start:{column:h.column,line:h.line}},{color:o,linesAbove:t,linesBelow:s,prefix:Io(r,a,n),showGutter:u,showLineNumbers:d,tabWidth:l})},Ek=(e,i,n)=>{if(e.errors.length===0)return;let o=`${Io(i.prefix,i.indentation,n)}Errors:
@@ -73,9 +73,9 @@ ${Rk(t,i,n+1,o)}`),`
73
73
  ${a}`},h7=(e,i)=>(e.length>0?`
74
74
  `:"")+e.map(n=>oc(n,i)).join(`
75
75
  `),Ok=(e,i,n)=>{const o={allowAllFilePaths:!1,cwd:r7(),displayShortPath:!1,filterStacktrace:void 0,framesMaxLimit:Number.POSITIVE_INFINITY,hideErrorCauseCodeView:!1,hideErrorCodeView:!1,hideErrorErrorsCodeView:!1,hideErrorTitle:!1,hideMessage:!1,indentation:4,linesAbove:2,linesBelow:3,prefix:"",showGutter:!0,showLineNumbers:!0,tabWidth:4,...i,color:{fileLine:s=>s,gutter:s=>s,hint:s=>s,marker:s=>s,message:s=>s,method:s=>s,title:s=>s,...i.color}},a=Bk(e,{filter:i.filterStacktrace,frameLimit:o.framesMaxLimit}),t=a.shift();return[i.hideMessage?void 0:Hk(e,o,n),Mk(e,o,n),t?oc(t,o,n):void 0,t&&!o.hideErrorCodeView?Nk(t,o,n):void 0,e instanceof AggregateError?Ek(e,o,n):void 0,e.cause===void 0?void 0:Rk(e,o,n),a.length>0?h7(a,o):void 0].filter(Boolean).join(`
76
- `)},_d=(e,i={})=>{if(i.framesMaxLimit!==void 0&&i.framesMaxLimit<=0)throw new RangeError("The 'framesMaxLimit' option must be a positive number");return Ok(e,i,0)},c7=new Map([["Error",Error],["EvalError",EvalError],["RangeError",RangeError],["ReferenceError",ReferenceError],["SyntaxError",SyntaxError],["TypeError",TypeError],["URIError",URIError]]);typeof AggregateError<"u"&&c7.set("AggregateError",AggregateError);const p7=[161,161,164,164,167,168,170,170,173,174,176,180,182,186,188,191,198,198,208,208,215,216,222,225,230,230,232,234,236,237,240,240,242,243,247,250,252,252,254,254,257,257,273,273,275,275,283,283,294,295,299,299,305,307,312,312,319,322,324,324,328,331,333,333,338,339,358,359,363,363,462,462,464,464,466,466,468,468,470,470,472,472,474,474,476,476,593,593,609,609,708,708,711,711,713,715,717,717,720,720,728,731,733,733,735,735,768,879,913,929,931,937,945,961,963,969,1025,1025,1040,1103,1105,1105,8208,8208,8211,8214,8216,8217,8220,8221,8224,8226,8228,8231,8240,8240,8242,8243,8245,8245,8251,8251,8254,8254,8308,8308,8319,8319,8321,8324,8364,8364,8451,8451,8453,8453,8457,8457,8467,8467,8470,8470,8481,8482,8486,8486,8491,8491,8531,8532,8539,8542,8544,8555,8560,8569,8585,8585,8592,8601,8632,8633,8658,8658,8660,8660,8679,8679,8704,8704,8706,8707,8711,8712,8715,8715,8719,8719,8721,8721,8725,8725,8730,8730,8733,8736,8739,8739,8741,8741,8743,8748,8750,8750,8756,8759,8764,8765,8776,8776,8780,8780,8786,8786,8800,8801,8804,8807,8810,8811,8814,8815,8834,8835,8838,8839,8853,8853,8857,8857,8869,8869,8895,8895,8978,8978,9312,9449,9451,9547,9552,9587,9600,9615,9618,9621,9632,9633,9635,9641,9650,9651,9654,9655,9660,9661,9664,9665,9670,9672,9675,9675,9678,9681,9698,9701,9711,9711,9733,9734,9737,9737,9742,9743,9756,9756,9758,9758,9792,9792,9794,9794,9824,9825,9827,9829,9831,9834,9836,9837,9839,9839,9886,9887,9919,9919,9926,9933,9935,9939,9941,9953,9955,9955,9960,9961,9963,9969,9972,9972,9974,9977,9979,9980,9982,9983,10045,10045,10102,10111,11094,11097,12872,12879,57344,63743,65024,65039,65533,65533,127232,127242,127248,127277,127280,127337,127344,127373,127375,127376,127387,127404,917760,917999,983040,1048573,1048576,1114109],v7=12288,y7=65510,f7=[12288,12288,65281,65376,65504,65510],m7=8361,b7=65518,w7=[8361,8361,65377,65470,65474,65479,65482,65487,65490,65495,65498,65500,65512,65518],j7=32,k7=10630,S7=[32,126,162,163,165,166,172,172,175,175,10214,10221,10629,10630],L7=4352,C7=262141,Ak=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141],Bs=(e,i)=>{let n=0,o=Math.floor(e.length/2)-1;for(;n<=o;){const a=Math.floor((n+o)/2),t=a*2;if(i<e[t])o=a-1;else if(i>e[t+1])n=a+1;else return!0}return!1},Oy=19968,[Y7,$7]=Z7(Ak);function Z7(e){let i=e[0],n=e[1];for(let o=0;o<e.length;o+=2){const a=e[o],t=e[o+1];if(Oy>=a&&Oy<=t)return[a,t];t-a>n-i&&(i=a,n=t)}return[i,n]}const J7=e=>e<161||e>1114109?!1:Bs(p7,e),x7=e=>e<v7||e>y7?!1:Bs(f7,e),T7=e=>e<m7||e>b7?!1:Bs(w7,e),D7=e=>e<j7||e>k7?!1:Bs(S7,e),B7=e=>e>=Y7&&e<=$7?!0:e<L7||e>C7?!1:Bs(Ak,e);function X7(e){return J7(e)?"ambiguous":x7(e)?"fullwidth":T7(e)?"halfwidth":D7(e)?"narrow":B7(e)?"wide":"neutral"}function H7(e){if(!Number.isSafeInteger(e))throw new TypeError(`Expected a code point, got \`${typeof e}\`.`)}function Gk(e){return H7(e),X7(e)}const Fk=String.raw,Ay=Fk`\p{Emoji}(?:\p{EMod}|[\u{E0020}-\u{E007E}]+\u{E007F}|\uFE0F?\u20E3?)`,M7=()=>new RegExp(Fk`\p{RI}{2}|(?![#*\d](?!\uFE0F?\u20E3))${Ay}(?:\u200D${Ay})*`,"gu"),ot=new Set(["\x1B","›"]),$u="\x07",Qk="[",ac="m",cs="]8;;",P7=39,N7=/[\u200B\uFEFF\u2060-\u2064]/g,E7=new RegExp(`(?:\\${Qk}(?<code>\\d+)m|\\${cs}(?<uri>.*)${$u})`),R7=Object.freeze(new Map([[0,0],[1,22],[2,22],[3,23],[4,24],[7,27],[8,28],[9,29],[30,39],[31,39],[32,39],[33,39],[34,39],[35,39],[36,39],[37,39],[40,49],[41,49],[42,49],[43,49],[44,49],[45,49],[46,49],[47,49],[90,39]])),O7=/^[ \t]*(?:\r\n|\r|\n)/,A7=/(?:\r\n|\r|\n)[ \t]*$/,G7=/^(?:[\r\n]|$)/,F7=/(?:\r\n|\r|\n)([ \t]*)(?:[^ \t\r\n]|$)/,Q7=/^[ \t]*[\r\n][ \t\r\n]*$/,W7=/\r\n|\n|\r/g,Bt=/[\u001B\u009B](?:[[()#;?]{0,10}(?:\d{1,4}(?:;\d{0,4})*)?[0-9A-ORZcf-nqry=><]|\]8;;[^\u0007\u001B]{0,100}(?:\u0007|\u001B\\))/g,Us=/[\u0000-\u0008\n-\u001F\u007F-\u009F]{1,1000}/y,zd=M7(),Gy=new Map,I7=e=>[e.ambiguousIsNarrow?1:0,e.control,e.fullWidth,e.regular,e.wide].join("|"),_7=e=>{const i=I7(e.width);let n=Gy.get(i);return n||(n=new Map,Gy.set(i,n)),n},Vs=/(?:[\u0020-\u007E\u00A0-\u00FF](?!\uFE0F)){1,1000}/y,Wk=e=>e>=32&&e<=126?"latin":e===8203||e===8204||e===8205||e===8288?"zero":e<=31||e>=127&&e<=159?"control":e>=160&&e<=255||e>=9472&&e<=9599?"latin":e>=4352&&e<=4607||e>=11904&&e<=40959||e>=44032&&e<=55215||e>=63744&&e<=64255||e>=65280&&e<=65519&&!(e>=65377&&e<=65439)||e>=12352&&e<=12543?"wide":e===8230?"latin":"other",z7=(e,i)=>{const n=_7(i),o=Math.floor(e/65536),a=e%65536;let t=n.get(o);if(t||(t=new Map,n.set(o,t)),t.has(a))return t.get(a);let s;switch(Wk(e)){case"control":{s=i.width.control;break}case"latin":{s=i.width.regular;break}case"wide":{s=i.width.wide;break}case"zero":{s=0;break}default:switch(Gk(e)){case"ambiguous":{s=i.width.ambiguousIsNarrow?i.width.regular:i.width.wide;break}case"fullwidth":{s=i.width.fullWidth;break}case"wide":{s=i.width.wide;break}default:s=i.width.regular}}return t.set(a,s),s},K7=e=>e>=768&&e<=879||e>=6832&&e<=6911||e>=7616&&e<=7679||e>=8400&&e<=8447||e>=65056&&e<=65071||e>=917760&&e<=917999||e>=65024&&e<=65039||e>=3633&&e<=3642||e>=3655&&e<=3662||e>=3761&&e<=3769||e>=3771&&e<=3772||e>=3784&&e<=3789||e>=2304&&e<=2307||e>=2362&&e<=2383||e>=2385&&e<=2391||e>=2402&&e<=2403||e>=2433&&e<=2435||e>=2492&&e<=2500||e>=2509&&e<=2509||e>=2561&&e<=2563||e>=2620&&e<=2637||e>=1611&&e<=1631||e>=1648&&e<=1648||e>=1750&&e<=1773||e>=2276&&e<=2302||e>=1425&&e<=1469||e>=1471&&e<=1471||e>=1473&&e<=1474||e>=1476&&e<=1477||e>=1479&&e<=1479||e>=3893&&e<=3893||e>=3895&&e<=3895||e>=3897&&e<=3897||e>=3953&&e<=3966||e>=3968&&e<=3972||e>=3974&&e<=3975?!0:e>=768&&e<=777||e>=803&&e<=803,cg=(e,i={})=>{if(!e||e.length===0)return{ellipsed:!1,index:0,truncated:!1,width:0};const n={truncation:{countAnsiEscapeCodes:i.countAnsiEscapeCodes??!1,ellipsis:i.ellipsis??"",ellipsisWidth:i.ellipsisWidth??(i.ellipsis?cg(i.ellipsis,{...i,ellipsis:"",ellipsisWidth:0,limit:Number.POSITIVE_INFINITY}).width:0),limit:i.limit??Number.POSITIVE_INFINITY},width:{ambiguousIsNarrow:i.ambiguousIsNarrow??!1,ansi:i.ansiWidth??0,control:i.controlWidth??0,emoji:i.emojiWidth??2,fullWidth:i.fullWidth??2,halfWidth:i.halfWidth??1,regular:i.regularWidth??1,tab:i.tabWidth??8,wide:i.wideWidth??2}},o=Math.max(0,n.truncation.limit-n.truncation.ellipsisWidth),{length:a}=e,t=a>1e4;let s=0,r=0,u=a,d=!1;const l=e.includes("\x1B")||e.includes("›");for(;s<a;){if(l&&(e[s]==="\x1B"||e[s]==="›")){if(e.startsWith("\x1B]8;;",s)){const w="\x1B]8;;\x07",v=w.length,j=e.indexOf("\x07",s+5);if(j!==-1){const C=e.indexOf(w,j+1);if(C!==-1){const y=C+v,k=e.slice(j+1,C).replace(Bt,""),S=cg(k,{ambiguousIsNarrow:n.width.ambiguousIsNarrow,ansiWidth:n.width.ansi,controlWidth:n.width.control,countAnsiEscapeCodes:!1,ellipsis:n.truncation.ellipsis,ellipsisWidth:n.truncation.ellipsisWidth,emojiWidth:n.width.emoji,fullWidth:n.width.fullWidth,halfWidth:n.width.halfWidth,limit:Math.max(0,o-r),regularWidth:n.width.regular,tabWidth:n.width.tab,wideWidth:n.width.wide}),J=S.width;if(S.truncated)d=!0,u=Math.min(u,s);else if(r+J>o&&(u=Math.min(u,s),d=!0,r+J>n.truncation.limit))break;if(r+=J,s=y,d&&r>=n.truncation.limit)break;continue}}}if(Bt.lastIndex=s,Bt.test(e)){const w=Bt.lastIndex-s,v=n.truncation.countAnsiEscapeCodes?w:n.width.ansi;if(r+v>o&&(u=Math.min(u,s),r+v>n.truncation.limit)){d=!0;break}r+=v,s=Bt.lastIndex;continue}}const c=e.codePointAt(s);if(c===8203||c===65279||c>=8288&&c<=8292){s+=1;continue}if(c===9){if(r+n.width.tab>o&&(u=Math.min(u,s),r+n.width.tab>n.truncation.limit)){d=!0;break}r+=n.width.tab,s+=1;continue}if(Vs.lastIndex=s,Vs.test(e)){const w=(Vs.lastIndex-s)*n.width.regular;if(r+w>o){const v=Math.floor((o-r)/n.width.regular);if(u=Math.min(u,s+v),r+w>n.truncation.limit){d=!0;break}}r+=w,s=Vs.lastIndex;continue}if((c<=31||c>=127&&c<=159)&&(Us.lastIndex=s,Us.test(e))){const w=(Us.lastIndex-s)*n.width.control;if(r+w>o&&(u=Math.min(u,s+Math.floor((o-r)/n.width.control)),r+w>n.truncation.limit)){d=!0;break}r+=w,s=Us.lastIndex;continue}if(zd.lastIndex=s,zd.test(e)){if(r+n.width.emoji>o&&(u=Math.min(u,s),r+n.width.emoji>n.truncation.limit)){d=!0;break}r+=n.width.emoji,s=zd.lastIndex;continue}const p=e.codePointAt(s)??0;if(K7(p)){s+=p>65535?2:1;continue}let f;if(t)f=z7(p,n);else switch(Wk(p)){case"control":{f=n.width.control;break}case"latin":{f=n.width.regular;break}case"wide":{f=n.width.wide;break}case"zero":{f=0;break}default:switch(Gk(p)){case"ambiguous":{f=n.width.ambiguousIsNarrow?n.width.regular:n.width.wide;break}case"fullwidth":{f=n.width.fullWidth;break}case"wide":{f=n.width.wide;break}default:f=n.width.regular}}if(r+f>o&&(u=Math.min(u,s),r+f>n.truncation.limit)){d=!0;break}r+=f,s+=p>65535?2:1}let g=r,h=!1;return d&&n.truncation.limit>=n.truncation.ellipsisWidth&&(g=n.truncation.limit,h=!0),{ellipsed:h,index:d?u:a,truncated:d,width:g}},Ni=(e,i={})=>cg(e,{...i,ellipsis:"",ellipsisWidth:0,limit:Number.POSITIVE_INFINITY}).width,q7=Cu(import.meta.url),Xt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,U7=e=>{if(typeof Xt<"u"&&Xt.versions&&Xt.versions.node){const[i,n]=Xt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return Xt.getBuiltinModule(e)}return q7(e)};U7("node:util");const V7=new Uint8Array(128),e9=new Uint8Array(128),i9=new Uint8Array(128);for(let e=0;e<128;e++)V7[e]=e>=65&&e<=90?1:0,e9[e]=e>=97&&e<=122?1:0,i9[e]=e>=48&&e<=57?1:0;const n9=Cu(import.meta.url),Ht=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,o9=e=>{if(typeof Ht<"u"&&Ht.versions&&Ht.versions.node){const[i,n]=Ht.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return Ht.getBuiltinModule(e)}return n9(e)};o9("node:util");function a9(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Kd,Fy;function t9(){if(Fy)return Kd;Fy=1,Kd=i;function e(o){return o instanceof Buffer?Buffer.from(o):new o.constructor(o.buffer.slice(),o.byteOffset,o.length)}function i(o){if(o=o||{},o.circles)return n(o);const a=new Map;if(a.set(Date,d=>new Date(d)),a.set(Map,(d,l)=>new Map(s(Array.from(d),l))),a.set(Set,(d,l)=>new Set(s(Array.from(d),l))),o.constructorHandlers)for(const d of o.constructorHandlers)a.set(d[0],d[1]);let t=null;return o.proto?u:r;function s(d,l){const g=Object.keys(d),h=new Array(g.length);for(let c=0;c<g.length;c++){const p=g[c],f=d[p];typeof f!="object"||f===null?h[p]=f:f.constructor!==Object&&(t=a.get(f.constructor))?h[p]=t(f,l):ArrayBuffer.isView(f)?h[p]=e(f):h[p]=l(f)}return h}function r(d){if(typeof d!="object"||d===null)return d;if(Array.isArray(d))return s(d,r);if(d.constructor!==Object&&(t=a.get(d.constructor)))return t(d,r);const l={};for(const g in d){if(Object.hasOwnProperty.call(d,g)===!1)continue;const h=d[g];typeof h!="object"||h===null?l[g]=h:h.constructor!==Object&&(t=a.get(h.constructor))?l[g]=t(h,r):ArrayBuffer.isView(h)?l[g]=e(h):l[g]=r(h)}return l}function u(d){if(typeof d!="object"||d===null)return d;if(Array.isArray(d))return s(d,u);if(d.constructor!==Object&&(t=a.get(d.constructor)))return t(d,u);const l={};for(const g in d){const h=d[g];typeof h!="object"||h===null?l[g]=h:h.constructor!==Object&&(t=a.get(h.constructor))?l[g]=t(h,u):ArrayBuffer.isView(h)?l[g]=e(h):l[g]=u(h)}return l}}function n(o){const a=[],t=[],s=new Map;if(s.set(Date,g=>new Date(g)),s.set(Map,(g,h)=>new Map(u(Array.from(g),h))),s.set(Set,(g,h)=>new Set(u(Array.from(g),h))),o.constructorHandlers)for(const g of o.constructorHandlers)s.set(g[0],g[1]);let r=null;return o.proto?l:d;function u(g,h){const c=Object.keys(g),p=new Array(c.length);for(let f=0;f<c.length;f++){const w=c[f],v=g[w];if(typeof v!="object"||v===null)p[w]=v;else if(v.constructor!==Object&&(r=s.get(v.constructor)))p[w]=r(v,h);else if(ArrayBuffer.isView(v))p[w]=e(v);else{const j=a.indexOf(v);j!==-1?p[w]=t[j]:p[w]=h(v)}}return p}function d(g){if(typeof g!="object"||g===null)return g;if(Array.isArray(g))return u(g,d);if(g.constructor!==Object&&(r=s.get(g.constructor)))return r(g,d);const h={};a.push(g),t.push(h);for(const c in g){if(Object.hasOwnProperty.call(g,c)===!1)continue;const p=g[c];if(typeof p!="object"||p===null)h[c]=p;else if(p.constructor!==Object&&(r=s.get(p.constructor)))h[c]=r(p,d);else if(ArrayBuffer.isView(p))h[c]=e(p);else{const f=a.indexOf(p);f!==-1?h[c]=t[f]:h[c]=d(p)}}return a.pop(),t.pop(),h}function l(g){if(typeof g!="object"||g===null)return g;if(Array.isArray(g))return u(g,l);if(g.constructor!==Object&&(r=s.get(g.constructor)))return r(g,l);const h={};a.push(g),t.push(h);for(const c in g){const p=g[c];if(typeof p!="object"||p===null)h[c]=p;else if(p.constructor!==Object&&(r=s.get(p.constructor)))h[c]=r(p,l);else if(ArrayBuffer.isView(p))h[c]=e(p);else{const f=a.indexOf(p);f!==-1?h[c]=t[f]:h[c]=l(p)}}return a.pop(),t.pop(),h}}return Kd}var s9=t9();const Ik=a9(s9);Ik();var _k=typeof global=="object"&&global&&global.Object===Object&&global,r9=typeof self=="object"&&self&&self.Object===Object&&self,Ke=_k||r9||Function("return this")(),ai=Ke.Symbol,zk=Object.prototype,u9=zk.hasOwnProperty,d9=zk.toString,Mt=ai?ai.toStringTag:void 0;function l9(e){var i=u9.call(e,Mt),n=e[Mt];try{e[Mt]=void 0;var o=!0}catch{}var a=d9.call(e);return o&&(i?e[Mt]=n:delete e[Mt]),a}var g9=Object.prototype,h9=g9.toString;function c9(e){return h9.call(e)}var p9="[object Null]",v9="[object Undefined]",Qy=ai?ai.toStringTag:void 0;function gi(e){return e==null?e===void 0?v9:p9:Qy&&Qy in Object(e)?l9(e):c9(e)}function Ee(e){return e!=null&&typeof e=="object"}var y9="[object Symbol]";function Zi(e){return typeof e=="symbol"||Ee(e)&&gi(e)==y9}var f9=NaN;function Wy(e){return typeof e=="number"?e:Zi(e)?f9:+e}function Be(e,i){for(var n=-1,o=e==null?0:e.length,a=Array(o);++n<o;)a[n]=i(e[n],n,e);return a}var ae=Array.isArray,Iy=ai?ai.prototype:void 0,_y=Iy?Iy.toString:void 0;function Ji(e){if(typeof e=="string")return e;if(ae(e))return Be(e,Ji)+"";if(Zi(e))return _y?_y.call(e):"";var i=e+"";return i=="0"&&1/e==-1/0?"-0":i}function Zu(e,i){return function(n,o){var a;if(n===void 0&&o===void 0)return i;if(n!==void 0&&(a=n),o!==void 0){if(a===void 0)return o;typeof n=="string"||typeof o=="string"?(n=Ji(n),o=Ji(o)):(n=Wy(n),o=Wy(o)),a=e(n,o)}return a}}var m9=Zu(function(e,i){return e+i},0),b9=/\s/;function Kk(e){for(var i=e.length;i--&&b9.test(e.charAt(i)););return i}var w9=/^\s+/;function qk(e){return e&&e.slice(0,Kk(e)+1).replace(w9,"")}function Pe(e){var i=typeof e;return e!=null&&(i=="object"||i=="function")}var zy=NaN,j9=/^[-+]0x[0-9a-f]+$/i,k9=/^0b[01]+$/i,S9=/^0o[0-7]+$/i,L9=parseInt;function Ai(e){if(typeof e=="number")return e;if(Zi(e))return zy;if(Pe(e)){var i=typeof e.valueOf=="function"?e.valueOf():e;e=Pe(i)?i+"":i}if(typeof e!="string")return e===0?e:+e;e=qk(e);var n=k9.test(e);return n||S9.test(e)?L9(e.slice(2),n?2:8):j9.test(e)?zy:+e}var Ky=1/0,C9=17976931348623157e292;function Nn(e){if(!e)return e===0?e:0;if(e=Ai(e),e===Ky||e===-Ky){var i=e<0?-1:1;return i*C9}return e===e?e:0}function re(e){var i=Nn(e),n=i%1;return i===i?n?i-n:i:0}var Y9="Expected a function";function $9(e,i){if(typeof i!="function")throw new TypeError(Y9);return e=re(e),function(){if(--e<1)return i.apply(this,arguments)}}function wi(e){return e}var Z9="[object AsyncFunction]",J9="[object Function]",x9="[object GeneratorFunction]",T9="[object Proxy]";function Wn(e){if(!Pe(e))return!1;var i=gi(e);return i==J9||i==x9||i==Z9||i==T9}var fr=Ke["__core-js_shared__"],qy=(function(){var e=/[^.]+$/.exec(fr&&fr.keys&&fr.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function D9(e){return!!qy&&qy in e}var B9=Function.prototype,X9=B9.toString;function aa(e){if(e!=null){try{return X9.call(e)}catch{}try{return e+""}catch{}}return""}var H9=/[\\^$.*+?()[\]{}|]/g,M9=/^\[object .+?Constructor\]$/,P9=Function.prototype,N9=Object.prototype,E9=P9.toString,R9=N9.hasOwnProperty,O9=RegExp("^"+E9.call(R9).replace(H9,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Uk(e){if(!Pe(e)||D9(e))return!1;var i=Wn(e)?O9:M9;return i.test(aa(e))}function A9(e,i){return e?.[i]}function ta(e,i){var n=A9(e,i);return Uk(n)?n:void 0}var ps=ta(Ke,"WeakMap"),Er=ps&&new ps,Vk=Er?function(e,i){return Er.set(e,i),e}:wi,Uy=Object.create,at=(function(){function e(){}return function(i){if(!Pe(i))return{};if(Uy)return Uy(i);e.prototype=i;var n=new e;return e.prototype=void 0,n}})();function vs(e){return function(){var i=arguments;switch(i.length){case 0:return new e;case 1:return new e(i[0]);case 2:return new e(i[0],i[1]);case 3:return new e(i[0],i[1],i[2]);case 4:return new e(i[0],i[1],i[2],i[3]);case 5:return new e(i[0],i[1],i[2],i[3],i[4]);case 6:return new e(i[0],i[1],i[2],i[3],i[4],i[5]);case 7:return new e(i[0],i[1],i[2],i[3],i[4],i[5],i[6])}var n=at(e.prototype),o=e.apply(n,i);return Pe(o)?o:n}}var G9=1;function F9(e,i,n){var o=i&G9,a=vs(e);function t(){var s=this&&this!==Ke&&this instanceof t?a:e;return s.apply(o?n:this,arguments)}return t}function xi(e,i,n){switch(n.length){case 0:return e.call(i);case 1:return e.call(i,n[0]);case 2:return e.call(i,n[0],n[1]);case 3:return e.call(i,n[0],n[1],n[2])}return e.apply(i,n)}var Q9=Math.max;function e1(e,i,n,o){for(var a=-1,t=e.length,s=n.length,r=-1,u=i.length,d=Q9(t-s,0),l=Array(u+d),g=!o;++r<u;)l[r]=i[r];for(;++a<s;)(g||a<t)&&(l[n[a]]=e[a]);for(;d--;)l[r++]=e[a++];return l}var W9=Math.max;function i1(e,i,n,o){for(var a=-1,t=e.length,s=-1,r=n.length,u=-1,d=i.length,l=W9(t-r,0),g=Array(l+d),h=!o;++a<l;)g[a]=e[a];for(var c=a;++u<d;)g[c+u]=i[u];for(;++s<r;)(h||a<t)&&(g[c+n[s]]=e[a++]);return g}function I9(e,i){for(var n=e.length,o=0;n--;)e[n]===i&&++o;return o}function Ju(){}var _9=4294967295;function pe(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=_9,this.__views__=[]}pe.prototype=at(Ju.prototype);pe.prototype.constructor=pe;function tc(){}var sc=Er?function(e){return Er.get(e)}:tc,Da={},z9=Object.prototype,K9=z9.hasOwnProperty;function mr(e){for(var i=e.name+"",n=Da[i],o=K9.call(Da,i)?n.length:0;o--;){var a=n[o],t=a.func;if(t==null||t==e)return a.name}return i}function zi(e,i){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!i,this.__index__=0,this.__values__=void 0}zi.prototype=at(Ju.prototype);zi.prototype.constructor=zi;function yi(e,i){var n=-1,o=e.length;for(i||(i=Array(o));++n<o;)i[n]=e[n];return i}function n1(e){if(e instanceof pe)return e.clone();var i=new zi(e.__wrapped__,e.__chain__);return i.__actions__=yi(e.__actions__),i.__index__=e.__index__,i.__values__=e.__values__,i}var q9=Object.prototype,U9=q9.hasOwnProperty;function b(e){if(Ee(e)&&!ae(e)&&!(e instanceof pe)){if(e instanceof zi)return e;if(U9.call(e,"__wrapped__"))return n1(e)}return new zi(e)}b.prototype=Ju.prototype;b.prototype.constructor=b;function pg(e){var i=mr(e),n=b[i];if(typeof n!="function"||!(i in pe.prototype))return!1;if(e===n)return!0;var o=sc(n);return!!o&&e===o[0]}var V9=800,e5=16,i5=Date.now;function o1(e){var i=0,n=0;return function(){var o=i5(),a=e5-(o-n);if(n=o,a>0){if(++i>=V9)return arguments[0]}else i=0;return e.apply(void 0,arguments)}}var a1=o1(Vk),n5=/\{\n\/\* \[wrapped with (.+)\] \*/,o5=/,? & /;function a5(e){var i=e.match(n5);return i?i[1].split(o5):[]}var t5=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;function s5(e,i){var n=i.length;if(!n)return e;var o=n-1;return i[o]=(n>1?"& ":"")+i[o],i=i.join(n>2?", ":" "),e.replace(t5,`{
76
+ `)},_d=(e,i={})=>{if(i.framesMaxLimit!==void 0&&i.framesMaxLimit<=0)throw new RangeError("The 'framesMaxLimit' option must be a positive number");return Ok(e,i,0)},c7=new Map([["Error",Error],["EvalError",EvalError],["RangeError",RangeError],["ReferenceError",ReferenceError],["SyntaxError",SyntaxError],["TypeError",TypeError],["URIError",URIError]]);typeof AggregateError<"u"&&c7.set("AggregateError",AggregateError);const p7=[161,161,164,164,167,168,170,170,173,174,176,180,182,186,188,191,198,198,208,208,215,216,222,225,230,230,232,234,236,237,240,240,242,243,247,250,252,252,254,254,257,257,273,273,275,275,283,283,294,295,299,299,305,307,312,312,319,322,324,324,328,331,333,333,338,339,358,359,363,363,462,462,464,464,466,466,468,468,470,470,472,472,474,474,476,476,593,593,609,609,708,708,711,711,713,715,717,717,720,720,728,731,733,733,735,735,768,879,913,929,931,937,945,961,963,969,1025,1025,1040,1103,1105,1105,8208,8208,8211,8214,8216,8217,8220,8221,8224,8226,8228,8231,8240,8240,8242,8243,8245,8245,8251,8251,8254,8254,8308,8308,8319,8319,8321,8324,8364,8364,8451,8451,8453,8453,8457,8457,8467,8467,8470,8470,8481,8482,8486,8486,8491,8491,8531,8532,8539,8542,8544,8555,8560,8569,8585,8585,8592,8601,8632,8633,8658,8658,8660,8660,8679,8679,8704,8704,8706,8707,8711,8712,8715,8715,8719,8719,8721,8721,8725,8725,8730,8730,8733,8736,8739,8739,8741,8741,8743,8748,8750,8750,8756,8759,8764,8765,8776,8776,8780,8780,8786,8786,8800,8801,8804,8807,8810,8811,8814,8815,8834,8835,8838,8839,8853,8853,8857,8857,8869,8869,8895,8895,8978,8978,9312,9449,9451,9547,9552,9587,9600,9615,9618,9621,9632,9633,9635,9641,9650,9651,9654,9655,9660,9661,9664,9665,9670,9672,9675,9675,9678,9681,9698,9701,9711,9711,9733,9734,9737,9737,9742,9743,9756,9756,9758,9758,9792,9792,9794,9794,9824,9825,9827,9829,9831,9834,9836,9837,9839,9839,9886,9887,9919,9919,9926,9933,9935,9939,9941,9953,9955,9955,9960,9961,9963,9969,9972,9972,9974,9977,9979,9980,9982,9983,10045,10045,10102,10111,11094,11097,12872,12879,57344,63743,65024,65039,65533,65533,127232,127242,127248,127277,127280,127337,127344,127373,127375,127376,127387,127404,917760,917999,983040,1048573,1048576,1114109],v7=12288,y7=65510,f7=[12288,12288,65281,65376,65504,65510],m7=8361,b7=65518,w7=[8361,8361,65377,65470,65474,65479,65482,65487,65490,65495,65498,65500,65512,65518],j7=32,k7=10630,S7=[32,126,162,163,165,166,172,172,175,175,10214,10221,10629,10630],L7=4352,C7=262141,Ak=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141],Bs=(e,i)=>{let n=0,o=Math.floor(e.length/2)-1;for(;n<=o;){const a=Math.floor((n+o)/2),t=a*2;if(i<e[t])o=a-1;else if(i>e[t+1])n=a+1;else return!0}return!1},Oy=19968,[Y7,$7]=Z7(Ak);function Z7(e){let i=e[0],n=e[1];for(let o=0;o<e.length;o+=2){const a=e[o],t=e[o+1];if(Oy>=a&&Oy<=t)return[a,t];t-a>n-i&&(i=a,n=t)}return[i,n]}const J7=e=>e<161||e>1114109?!1:Bs(p7,e),x7=e=>e<v7||e>y7?!1:Bs(f7,e),T7=e=>e<m7||e>b7?!1:Bs(w7,e),D7=e=>e<j7||e>k7?!1:Bs(S7,e),B7=e=>e>=Y7&&e<=$7?!0:e<L7||e>C7?!1:Bs(Ak,e);function X7(e){return J7(e)?"ambiguous":x7(e)?"fullwidth":T7(e)?"halfwidth":D7(e)?"narrow":B7(e)?"wide":"neutral"}function H7(e){if(!Number.isSafeInteger(e))throw new TypeError(`Expected a code point, got \`${typeof e}\`.`)}function Gk(e){return H7(e),X7(e)}const Fk=String.raw,Ay=Fk`\p{Emoji}(?:\p{EMod}|[\u{E0020}-\u{E007E}]+\u{E007F}|\uFE0F?\u20E3?)`,M7=()=>new RegExp(Fk`\p{RI}{2}|(?![#*\d](?!\uFE0F?\u20E3))${Ay}(?:\u200D${Ay})*`,"gu"),ot=new Set(["\x1B","›"]),$u="\x07",Qk="[",ac="m",cs="]8;;",P7=39,N7=/[\u200B\uFEFF\u2060-\u2064]/g,E7=new RegExp(`(?:\\${Qk}(?<code>\\d+)m|\\${cs}(?<uri>.*)${$u})`),R7=Object.freeze(new Map([[0,0],[1,22],[2,22],[3,23],[4,24],[7,27],[8,28],[9,29],[30,39],[31,39],[32,39],[33,39],[34,39],[35,39],[36,39],[37,39],[40,49],[41,49],[42,49],[43,49],[44,49],[45,49],[46,49],[47,49],[90,39]])),O7=/^[ \t]*(?:\r\n|\r|\n)/,A7=/(?:\r\n|\r|\n)[ \t]*$/,G7=/^(?:[\r\n]|$)/,F7=/(?:\r\n|\r|\n)([ \t]*)(?:[^ \t\r\n]|$)/,Q7=/^[ \t]*[\r\n][ \t\r\n]*$/,W7=/\r\n|\n|\r/g,Bt=/[\u001B\u009B](?:[[()#;?]{0,10}(?:\d{1,4}(?:;\d{0,4})*)?[0-9A-ORZcf-nqry=><]|\]8;;[^\u0007\u001B]{0,100}(?:\u0007|\u001B\\))/g,Us=/[\u0000-\u0008\n-\u001F\u007F-\u009F]{1,1000}/y,zd=M7(),Gy=new Map,I7=e=>[e.ambiguousIsNarrow?1:0,e.control,e.fullWidth,e.regular,e.wide].join("|"),_7=e=>{const i=I7(e.width);let n=Gy.get(i);return n||(n=new Map,Gy.set(i,n)),n},Vs=/(?:[\u0020-\u007E\u00A0-\u00FF](?!\uFE0F)){1,1000}/y,Wk=e=>e>=32&&e<=126?"latin":e===8203||e===8204||e===8205||e===8288?"zero":e<=31||e>=127&&e<=159?"control":e>=160&&e<=255||e>=9472&&e<=9599?"latin":e>=4352&&e<=4607||e>=11904&&e<=40959||e>=44032&&e<=55215||e>=63744&&e<=64255||e>=65280&&e<=65519&&!(e>=65377&&e<=65439)||e>=12352&&e<=12543?"wide":e===8230?"latin":"other",z7=(e,i)=>{const n=_7(i),o=Math.floor(e/65536),a=e%65536;let t=n.get(o);if(t||(t=new Map,n.set(o,t)),t.has(a))return t.get(a);let s;switch(Wk(e)){case"control":{s=i.width.control;break}case"latin":{s=i.width.regular;break}case"wide":{s=i.width.wide;break}case"zero":{s=0;break}default:switch(Gk(e)){case"ambiguous":{s=i.width.ambiguousIsNarrow?i.width.regular:i.width.wide;break}case"fullwidth":{s=i.width.fullWidth;break}case"wide":{s=i.width.wide;break}default:s=i.width.regular}}return t.set(a,s),s},K7=e=>e>=768&&e<=879||e>=6832&&e<=6911||e>=7616&&e<=7679||e>=8400&&e<=8447||e>=65056&&e<=65071||e>=917760&&e<=917999||e>=65024&&e<=65039||e>=3633&&e<=3642||e>=3655&&e<=3662||e>=3761&&e<=3769||e>=3771&&e<=3772||e>=3784&&e<=3789||e>=2304&&e<=2307||e>=2362&&e<=2383||e>=2385&&e<=2391||e>=2402&&e<=2403||e>=2433&&e<=2435||e>=2492&&e<=2500||e>=2509&&e<=2509||e>=2561&&e<=2563||e>=2620&&e<=2637||e>=1611&&e<=1631||e>=1648&&e<=1648||e>=1750&&e<=1773||e>=2276&&e<=2302||e>=1425&&e<=1469||e>=1471&&e<=1471||e>=1473&&e<=1474||e>=1476&&e<=1477||e>=1479&&e<=1479||e>=3893&&e<=3893||e>=3895&&e<=3895||e>=3897&&e<=3897||e>=3953&&e<=3966||e>=3968&&e<=3972||e>=3974&&e<=3975?!0:e>=768&&e<=777||e>=803&&e<=803,cg=(e,i={})=>{if(!e||e.length===0)return{ellipsed:!1,index:0,truncated:!1,width:0};const n={truncation:{countAnsiEscapeCodes:i.countAnsiEscapeCodes??!1,ellipsis:i.ellipsis??"",ellipsisWidth:i.ellipsisWidth??(i.ellipsis?cg(i.ellipsis,{...i,ellipsis:"",ellipsisWidth:0,limit:Number.POSITIVE_INFINITY}).width:0),limit:i.limit??Number.POSITIVE_INFINITY},width:{ambiguousIsNarrow:i.ambiguousIsNarrow??!1,ansi:i.ansiWidth??0,control:i.controlWidth??0,emoji:i.emojiWidth??2,fullWidth:i.fullWidth??2,halfWidth:i.halfWidth??1,regular:i.regularWidth??1,tab:i.tabWidth??8,wide:i.wideWidth??2}},o=Math.max(0,n.truncation.limit-n.truncation.ellipsisWidth),{length:a}=e,t=a>1e4;let s=0,r=0,u=a,d=!1;const l=e.includes("\x1B")||e.includes("›");for(;s<a;){if(l&&(e[s]==="\x1B"||e[s]==="›")){if(e.startsWith("\x1B]8;;",s)){const w="\x1B]8;;\x07",v=w.length,j=e.indexOf("\x07",s+5);if(j!==-1){const C=e.indexOf(w,j+1);if(C!==-1){const y=C+v,k=e.slice(j+1,C).replace(Bt,""),S=cg(k,{ambiguousIsNarrow:n.width.ambiguousIsNarrow,ansiWidth:n.width.ansi,controlWidth:n.width.control,countAnsiEscapeCodes:!1,ellipsis:n.truncation.ellipsis,ellipsisWidth:n.truncation.ellipsisWidth,emojiWidth:n.width.emoji,fullWidth:n.width.fullWidth,halfWidth:n.width.halfWidth,limit:Math.max(0,o-r),regularWidth:n.width.regular,tabWidth:n.width.tab,wideWidth:n.width.wide}),J=S.width;if(S.truncated)d=!0,u=Math.min(u,s);else if(r+J>o&&(u=Math.min(u,s),d=!0,r+J>n.truncation.limit))break;if(r+=J,s=y,d&&r>=n.truncation.limit)break;continue}}}if(Bt.lastIndex=s,Bt.test(e)){const w=Bt.lastIndex-s,v=n.truncation.countAnsiEscapeCodes?w:n.width.ansi;if(r+v>o&&(u=Math.min(u,s),r+v>n.truncation.limit)){d=!0;break}r+=v,s=Bt.lastIndex;continue}}const c=e.codePointAt(s);if(c===8203||c===65279||c>=8288&&c<=8292){s+=1;continue}if(c===9){if(r+n.width.tab>o&&(u=Math.min(u,s),r+n.width.tab>n.truncation.limit)){d=!0;break}r+=n.width.tab,s+=1;continue}if(Vs.lastIndex=s,Vs.test(e)){const w=(Vs.lastIndex-s)*n.width.regular;if(r+w>o){const v=Math.floor((o-r)/n.width.regular);if(u=Math.min(u,s+v),r+w>n.truncation.limit){d=!0;break}}r+=w,s=Vs.lastIndex;continue}if((c<=31||c>=127&&c<=159)&&(Us.lastIndex=s,Us.test(e))){const w=(Us.lastIndex-s)*n.width.control;if(r+w>o&&(u=Math.min(u,s+Math.floor((o-r)/n.width.control)),r+w>n.truncation.limit)){d=!0;break}r+=w,s=Us.lastIndex;continue}if(zd.lastIndex=s,zd.test(e)){if(r+n.width.emoji>o&&(u=Math.min(u,s),r+n.width.emoji>n.truncation.limit)){d=!0;break}r+=n.width.emoji,s=zd.lastIndex;continue}const p=e.codePointAt(s)??0;if(K7(p)){s+=p>65535?2:1;continue}let f;if(t)f=z7(p,n);else switch(Wk(p)){case"control":{f=n.width.control;break}case"latin":{f=n.width.regular;break}case"wide":{f=n.width.wide;break}case"zero":{f=0;break}default:switch(Gk(p)){case"ambiguous":{f=n.width.ambiguousIsNarrow?n.width.regular:n.width.wide;break}case"fullwidth":{f=n.width.fullWidth;break}case"wide":{f=n.width.wide;break}default:f=n.width.regular}}if(r+f>o&&(u=Math.min(u,s),r+f>n.truncation.limit)){d=!0;break}r+=f,s+=p>65535?2:1}let g=r,h=!1;return d&&n.truncation.limit>=n.truncation.ellipsisWidth&&(g=n.truncation.limit,h=!0),{ellipsed:h,index:d?u:a,truncated:d,width:g}},Ni=(e,i={})=>cg(e,{...i,ellipsis:"",ellipsisWidth:0,limit:Number.POSITIVE_INFINITY}).width,q7=Cu(import.meta.url),Xt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,U7=e=>{if(typeof Xt<"u"&&Xt.versions&&Xt.versions.node){const[i,n]=Xt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return Xt.getBuiltinModule(e)}return q7(e)};U7("node:util");const V7=new Uint8Array(128),e9=new Uint8Array(128),i9=new Uint8Array(128);for(let e=0;e<128;e++)V7[e]=e>=65&&e<=90?1:0,e9[e]=e>=97&&e<=122?1:0,i9[e]=e>=48&&e<=57?1:0;const n9=Cu(import.meta.url),Ht=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,o9=e=>{if(typeof Ht<"u"&&Ht.versions&&Ht.versions.node){const[i,n]=Ht.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return Ht.getBuiltinModule(e)}return n9(e)};o9("node:util");function a9(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Kd,Fy;function t9(){if(Fy)return Kd;Fy=1,Kd=i;function e(o){return o instanceof Buffer?Buffer.from(o):new o.constructor(o.buffer.slice(),o.byteOffset,o.length)}function i(o){if(o=o||{},o.circles)return n(o);const a=new Map;if(a.set(Date,d=>new Date(d)),a.set(Map,(d,l)=>new Map(s(Array.from(d),l))),a.set(Set,(d,l)=>new Set(s(Array.from(d),l))),o.constructorHandlers)for(const d of o.constructorHandlers)a.set(d[0],d[1]);let t=null;return o.proto?u:r;function s(d,l){const g=Object.keys(d),h=new Array(g.length);for(let c=0;c<g.length;c++){const p=g[c],f=d[p];typeof f!="object"||f===null?h[p]=f:f.constructor!==Object&&(t=a.get(f.constructor))?h[p]=t(f,l):ArrayBuffer.isView(f)?h[p]=e(f):h[p]=l(f)}return h}function r(d){if(typeof d!="object"||d===null)return d;if(Array.isArray(d))return s(d,r);if(d.constructor!==Object&&(t=a.get(d.constructor)))return t(d,r);const l={};for(const g in d){if(Object.hasOwnProperty.call(d,g)===!1)continue;const h=d[g];typeof h!="object"||h===null?l[g]=h:h.constructor!==Object&&(t=a.get(h.constructor))?l[g]=t(h,r):ArrayBuffer.isView(h)?l[g]=e(h):l[g]=r(h)}return l}function u(d){if(typeof d!="object"||d===null)return d;if(Array.isArray(d))return s(d,u);if(d.constructor!==Object&&(t=a.get(d.constructor)))return t(d,u);const l={};for(const g in d){const h=d[g];typeof h!="object"||h===null?l[g]=h:h.constructor!==Object&&(t=a.get(h.constructor))?l[g]=t(h,u):ArrayBuffer.isView(h)?l[g]=e(h):l[g]=u(h)}return l}}function n(o){const a=[],t=[],s=new Map;if(s.set(Date,g=>new Date(g)),s.set(Map,(g,h)=>new Map(u(Array.from(g),h))),s.set(Set,(g,h)=>new Set(u(Array.from(g),h))),o.constructorHandlers)for(const g of o.constructorHandlers)s.set(g[0],g[1]);let r=null;return o.proto?l:d;function u(g,h){const c=Object.keys(g),p=new Array(c.length);for(let f=0;f<c.length;f++){const w=c[f],v=g[w];if(typeof v!="object"||v===null)p[w]=v;else if(v.constructor!==Object&&(r=s.get(v.constructor)))p[w]=r(v,h);else if(ArrayBuffer.isView(v))p[w]=e(v);else{const j=a.indexOf(v);j!==-1?p[w]=t[j]:p[w]=h(v)}}return p}function d(g){if(typeof g!="object"||g===null)return g;if(Array.isArray(g))return u(g,d);if(g.constructor!==Object&&(r=s.get(g.constructor)))return r(g,d);const h={};a.push(g),t.push(h);for(const c in g){if(Object.hasOwnProperty.call(g,c)===!1)continue;const p=g[c];if(typeof p!="object"||p===null)h[c]=p;else if(p.constructor!==Object&&(r=s.get(p.constructor)))h[c]=r(p,d);else if(ArrayBuffer.isView(p))h[c]=e(p);else{const f=a.indexOf(p);f!==-1?h[c]=t[f]:h[c]=d(p)}}return a.pop(),t.pop(),h}function l(g){if(typeof g!="object"||g===null)return g;if(Array.isArray(g))return u(g,l);if(g.constructor!==Object&&(r=s.get(g.constructor)))return r(g,l);const h={};a.push(g),t.push(h);for(const c in g){const p=g[c];if(typeof p!="object"||p===null)h[c]=p;else if(p.constructor!==Object&&(r=s.get(p.constructor)))h[c]=r(p,l);else if(ArrayBuffer.isView(p))h[c]=e(p);else{const f=a.indexOf(p);f!==-1?h[c]=t[f]:h[c]=l(p)}}return a.pop(),t.pop(),h}}return Kd}var s9=t9();const Ik=a9(s9);Ik();var _k=typeof global=="object"&&global&&global.Object===Object&&global,r9=typeof self=="object"&&self&&self.Object===Object&&self,Ke=_k||r9||Function("return this")(),ai=Ke.Symbol,zk=Object.prototype,u9=zk.hasOwnProperty,d9=zk.toString,Mt=ai?ai.toStringTag:void 0;function l9(e){var i=u9.call(e,Mt),n=e[Mt];try{e[Mt]=void 0;var o=!0}catch{}var a=d9.call(e);return o&&(i?e[Mt]=n:delete e[Mt]),a}var g9=Object.prototype,h9=g9.toString;function c9(e){return h9.call(e)}var p9="[object Null]",v9="[object Undefined]",Qy=ai?ai.toStringTag:void 0;function gi(e){return e==null?e===void 0?v9:p9:Qy&&Qy in Object(e)?l9(e):c9(e)}function Ee(e){return e!=null&&typeof e=="object"}var y9="[object Symbol]";function Zi(e){return typeof e=="symbol"||Ee(e)&&gi(e)==y9}var f9=NaN;function Wy(e){return typeof e=="number"?e:Zi(e)?f9:+e}function Be(e,i){for(var n=-1,o=e==null?0:e.length,a=Array(o);++n<o;)a[n]=i(e[n],n,e);return a}var ae=Array.isArray,Iy=ai?ai.prototype:void 0,_y=Iy?Iy.toString:void 0;function Ji(e){if(typeof e=="string")return e;if(ae(e))return Be(e,Ji)+"";if(Zi(e))return _y?_y.call(e):"";var i=e+"";return i=="0"&&1/e==-1/0?"-0":i}function Zu(e,i){return function(n,o){var a;if(n===void 0&&o===void 0)return i;if(n!==void 0&&(a=n),o!==void 0){if(a===void 0)return o;typeof n=="string"||typeof o=="string"?(n=Ji(n),o=Ji(o)):(n=Wy(n),o=Wy(o)),a=e(n,o)}return a}}var m9=Zu(function(e,i){return e+i},0),b9=/\s/;function Kk(e){for(var i=e.length;i--&&b9.test(e.charAt(i)););return i}var w9=/^\s+/;function qk(e){return e&&e.slice(0,Kk(e)+1).replace(w9,"")}function Pe(e){var i=typeof e;return e!=null&&(i=="object"||i=="function")}var zy=NaN,j9=/^[-+]0x[0-9a-f]+$/i,k9=/^0b[01]+$/i,S9=/^0o[0-7]+$/i,L9=parseInt;function Ai(e){if(typeof e=="number")return e;if(Zi(e))return zy;if(Pe(e)){var i=typeof e.valueOf=="function"?e.valueOf():e;e=Pe(i)?i+"":i}if(typeof e!="string")return e===0?e:+e;e=qk(e);var n=k9.test(e);return n||S9.test(e)?L9(e.slice(2),n?2:8):j9.test(e)?zy:+e}var Ky=1/0,C9=17976931348623157e292;function Nn(e){if(!e)return e===0?e:0;if(e=Ai(e),e===Ky||e===-Ky){var i=e<0?-1:1;return i*C9}return e===e?e:0}function re(e){var i=Nn(e),n=i%1;return i===i?n?i-n:i:0}var Y9="Expected a function";function $9(e,i){if(typeof i!="function")throw new TypeError(Y9);return e=re(e),function(){if(--e<1)return i.apply(this,arguments)}}function wi(e){return e}var Z9="[object AsyncFunction]",J9="[object Function]",x9="[object GeneratorFunction]",T9="[object Proxy]";function Wn(e){if(!Pe(e))return!1;var i=gi(e);return i==J9||i==x9||i==Z9||i==T9}var fr=Ke["__core-js_shared__"],qy=(function(){var e=/[^.]+$/.exec(fr&&fr.keys&&fr.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function D9(e){return!!qy&&qy in e}var B9=Function.prototype,X9=B9.toString;function aa(e){if(e!=null){try{return X9.call(e)}catch{}try{return e+""}catch{}}return""}var H9=/[\\^$.*+?()[\]{}|]/g,M9=/^\[object .+?Constructor\]$/,P9=Function.prototype,N9=Object.prototype,E9=P9.toString,R9=N9.hasOwnProperty,O9=RegExp("^"+E9.call(R9).replace(H9,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Uk(e){if(!Pe(e)||D9(e))return!1;var i=Wn(e)?O9:M9;return i.test(aa(e))}function A9(e,i){return e?.[i]}function ta(e,i){var n=A9(e,i);return Uk(n)?n:void 0}var ps=ta(Ke,"WeakMap"),Er=ps&&new ps,Vk=Er?function(e,i){return Er.set(e,i),e}:wi,Uy=Object.create,at=(function(){function e(){}return function(i){if(!Pe(i))return{};if(Uy)return Uy(i);e.prototype=i;var n=new e;return e.prototype=void 0,n}})();function vs(e){return function(){var i=arguments;switch(i.length){case 0:return new e;case 1:return new e(i[0]);case 2:return new e(i[0],i[1]);case 3:return new e(i[0],i[1],i[2]);case 4:return new e(i[0],i[1],i[2],i[3]);case 5:return new e(i[0],i[1],i[2],i[3],i[4]);case 6:return new e(i[0],i[1],i[2],i[3],i[4],i[5]);case 7:return new e(i[0],i[1],i[2],i[3],i[4],i[5],i[6])}var n=at(e.prototype),o=e.apply(n,i);return Pe(o)?o:n}}var G9=1;function F9(e,i,n){var o=i&G9,a=vs(e);function t(){var s=this&&this!==Ke&&this instanceof t?a:e;return s.apply(o?n:this,arguments)}return t}function xi(e,i,n){switch(n.length){case 0:return e.call(i);case 1:return e.call(i,n[0]);case 2:return e.call(i,n[0],n[1]);case 3:return e.call(i,n[0],n[1],n[2])}return e.apply(i,n)}var Q9=Math.max;function eS(e,i,n,o){for(var a=-1,t=e.length,s=n.length,r=-1,u=i.length,d=Q9(t-s,0),l=Array(u+d),g=!o;++r<u;)l[r]=i[r];for(;++a<s;)(g||a<t)&&(l[n[a]]=e[a]);for(;d--;)l[r++]=e[a++];return l}var W9=Math.max;function iS(e,i,n,o){for(var a=-1,t=e.length,s=-1,r=n.length,u=-1,d=i.length,l=W9(t-r,0),g=Array(l+d),h=!o;++a<l;)g[a]=e[a];for(var c=a;++u<d;)g[c+u]=i[u];for(;++s<r;)(h||a<t)&&(g[c+n[s]]=e[a++]);return g}function I9(e,i){for(var n=e.length,o=0;n--;)e[n]===i&&++o;return o}function Ju(){}var _9=4294967295;function pe(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=_9,this.__views__=[]}pe.prototype=at(Ju.prototype);pe.prototype.constructor=pe;function tc(){}var sc=Er?function(e){return Er.get(e)}:tc,Da={},z9=Object.prototype,K9=z9.hasOwnProperty;function mr(e){for(var i=e.name+"",n=Da[i],o=K9.call(Da,i)?n.length:0;o--;){var a=n[o],t=a.func;if(t==null||t==e)return a.name}return i}function zi(e,i){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!i,this.__index__=0,this.__values__=void 0}zi.prototype=at(Ju.prototype);zi.prototype.constructor=zi;function yi(e,i){var n=-1,o=e.length;for(i||(i=Array(o));++n<o;)i[n]=e[n];return i}function nS(e){if(e instanceof pe)return e.clone();var i=new zi(e.__wrapped__,e.__chain__);return i.__actions__=yi(e.__actions__),i.__index__=e.__index__,i.__values__=e.__values__,i}var q9=Object.prototype,U9=q9.hasOwnProperty;function b(e){if(Ee(e)&&!ae(e)&&!(e instanceof pe)){if(e instanceof zi)return e;if(U9.call(e,"__wrapped__"))return nS(e)}return new zi(e)}b.prototype=Ju.prototype;b.prototype.constructor=b;function pg(e){var i=mr(e),n=b[i];if(typeof n!="function"||!(i in pe.prototype))return!1;if(e===n)return!0;var o=sc(n);return!!o&&e===o[0]}var V9=800,e5=16,i5=Date.now;function oS(e){var i=0,n=0;return function(){var o=i5(),a=e5-(o-n);if(n=o,a>0){if(++i>=V9)return arguments[0]}else i=0;return e.apply(void 0,arguments)}}var aS=oS(Vk),n5=/\{\n\/\* \[wrapped with (.+)\] \*/,o5=/,? & /;function a5(e){var i=e.match(n5);return i?i[1].split(o5):[]}var t5=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;function s5(e,i){var n=i.length;if(!n)return e;var o=n-1;return i[o]=(n>1?"& ":"")+i[o],i=i.join(n>2?", ":" "),e.replace(t5,`{
77
77
  /* [wrapped with `+i+`] */
78
- `)}function rc(e){return function(){return e}}var Rr=(function(){try{var e=ta(Object,"defineProperty");return e({},"",{}),e}catch{}})(),r5=Rr?function(e,i){return Rr(e,"toString",{configurable:!0,enumerable:!1,value:rc(i),writable:!0})}:wi,uc=o1(r5);function Xi(e,i){for(var n=-1,o=e==null?0:e.length;++n<o&&i(e[n],n,e)!==!1;);return e}function xu(e,i,n,o){for(var a=e.length,t=n+(o?1:-1);o?t--:++t<a;)if(i(e[t],t,e))return t;return-1}function t1(e){return e!==e}function u5(e,i,n){for(var o=n-1,a=e.length;++o<a;)if(e[o]===i)return o;return-1}function tt(e,i,n){return i===i?u5(e,i,n):xu(e,t1,n)}function Tu(e,i){var n=e==null?0:e.length;return!!n&&tt(e,i,0)>-1}var d5=1,l5=2,g5=8,h5=16,c5=32,p5=64,v5=128,y5=256,f5=512,m5=[["ary",v5],["bind",d5],["bindKey",l5],["curry",g5],["curryRight",h5],["flip",f5],["partial",c5],["partialRight",p5],["rearg",y5]];function b5(e,i){return Xi(m5,function(n){var o="_."+n[0];i&n[1]&&!Tu(e,o)&&e.push(o)}),e.sort()}function s1(e,i,n){var o=i+"";return uc(e,s5(o,b5(a5(o),n)))}var w5=4,j5=8,Vy=32,e0=64;function r1(e,i,n,o,a,t,s,r,u,d){var l=i&j5,g=l?s:void 0,h=l?void 0:s,c=l?t:void 0,p=l?void 0:t;i|=l?Vy:e0,i&=~(l?e0:Vy),i&w5||(i&=-4);var f=[e,i,a,c,g,p,h,r,u,d],w=n.apply(void 0,f);return pg(e)&&a1(w,f),w.placeholder=o,s1(w,e,i)}function st(e){var i=e;return i.placeholder}var k5=9007199254740991,S5=/^(?:0|[1-9]\d*)$/;function In(e,i){var n=typeof e;return i=i??k5,!!i&&(n=="number"||n!="symbol"&&S5.test(e))&&e>-1&&e%1==0&&e<i}var L5=Math.min;function C5(e,i){for(var n=e.length,o=L5(i.length,n),a=yi(e);o--;){var t=i[o];e[o]=In(t,n)?a[t]:void 0}return e}var i0="__lodash_placeholder__";function go(e,i){for(var n=-1,o=e.length,a=0,t=[];++n<o;){var s=e[n];(s===i||s===i0)&&(e[n]=i0,t[a++]=n)}return t}var Y5=1,$5=2,Z5=8,J5=16,x5=128,T5=512;function Du(e,i,n,o,a,t,s,r,u,d){var l=i&x5,g=i&Y5,h=i&$5,c=i&(Z5|J5),p=i&T5,f=h?void 0:vs(e);function w(){for(var v=arguments.length,j=Array(v),C=v;C--;)j[C]=arguments[C];if(c)var y=st(w),k=I9(j,y);if(o&&(j=e1(j,o,a,c)),t&&(j=i1(j,t,s,c)),v-=k,c&&v<d){var S=go(j,y);return r1(e,i,Du,w.placeholder,n,j,S,r,u,d-v)}var J=g?n:this,T=h?J[e]:e;return v=j.length,r?j=C5(j,r):p&&v>1&&j.reverse(),l&&u<v&&(j.length=u),this&&this!==Ke&&this instanceof w&&(T=f||vs(T)),T.apply(J,j)}return w}function D5(e,i,n){var o=vs(e);function a(){for(var t=arguments.length,s=Array(t),r=t,u=st(a);r--;)s[r]=arguments[r];var d=t<3&&s[0]!==u&&s[t-1]!==u?[]:go(s,u);if(t-=d.length,t<n)return r1(e,i,Du,a.placeholder,void 0,s,d,void 0,void 0,n-t);var l=this&&this!==Ke&&this instanceof a?o:e;return xi(l,this,s)}return a}var B5=1;function X5(e,i,n,o){var a=i&B5,t=vs(e);function s(){for(var r=-1,u=arguments.length,d=-1,l=o.length,g=Array(l+u),h=this&&this!==Ke&&this instanceof s?t:e;++d<l;)g[d]=o[d];for(;u--;)g[d++]=arguments[++r];return xi(h,a?n:this,g)}return s}var n0="__lodash_placeholder__",qd=1,H5=2,M5=4,o0=8,Pt=128,a0=256,P5=Math.min;function N5(e,i){var n=e[1],o=i[1],a=n|o,t=a<(qd|H5|Pt),s=o==Pt&&n==o0||o==Pt&&n==a0&&e[7].length<=i[8]||o==(Pt|a0)&&i[7].length<=i[8]&&n==o0;if(!(t||s))return e;o&qd&&(e[2]=i[2],a|=n&qd?0:M5);var r=i[3];if(r){var u=e[3];e[3]=u?e1(u,r,i[4]):r,e[4]=u?go(e[3],n0):i[4]}return r=i[5],r&&(u=e[5],e[5]=u?i1(u,r,i[6]):r,e[6]=u?go(e[5],n0):i[6]),r=i[7],r&&(e[7]=r),o&Pt&&(e[8]=e[8]==null?i[8]:P5(e[8],i[8])),e[9]==null&&(e[9]=i[9]),e[0]=i[0],e[1]=a,e}var E5="Expected a function",t0=1,R5=2,s0=8,r0=16,u0=32,O5=64,d0=Math.max;function _n(e,i,n,o,a,t,s,r){var u=i&R5;if(!u&&typeof e!="function")throw new TypeError(E5);var d=o?o.length:0;if(d||(i&=-97,o=a=void 0),s=s===void 0?s:d0(re(s),0),r=r===void 0?r:re(r),d-=a?a.length:0,i&O5){var l=o,g=a;o=a=void 0}var h=u?void 0:sc(e),c=[e,i,n,o,a,l,g,t,s,r];if(h&&N5(c,h),e=c[0],i=c[1],n=c[2],o=c[3],a=c[4],r=c[9]=c[9]===void 0?u?0:e.length:d0(c[9]-d,0),!r&&i&(s0|r0)&&(i&=-25),!i||i==t0)var p=F9(e,i,n);else i==s0||i==r0?p=D5(e,i,r):(i==u0||i==(t0|u0))&&!a.length?p=X5(e,i,n,o):p=Du.apply(void 0,c);var f=h?Vk:a1;return s1(f(p,c),e,i)}var A5=128;function u1(e,i,n){return i=n?void 0:i,i=e&&i==null?e.length:i,_n(e,A5,void 0,void 0,void 0,void 0,i)}function $n(e,i,n){i=="__proto__"&&Rr?Rr(e,i,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[i]=n}function ln(e,i){return e===i||e!==e&&i!==i}var G5=Object.prototype,F5=G5.hasOwnProperty;function Xs(e,i,n){var o=e[i];(!(F5.call(e,i)&&ln(o,n))||n===void 0&&!(i in e))&&$n(e,i,n)}function Zn(e,i,n,o){var a=!n;n||(n={});for(var t=-1,s=i.length;++t<s;){var r=i[t],u=o?o(n[r],e[r],r,n,e):void 0;u===void 0&&(u=e[r]),a?$n(n,r,u):Xs(n,r,u)}return n}var l0=Math.max;function d1(e,i,n){return i=l0(i===void 0?e.length-1:i,0),function(){for(var o=arguments,a=-1,t=l0(o.length-i,0),s=Array(t);++a<t;)s[a]=o[i+a];a=-1;for(var r=Array(i+1);++a<i;)r[a]=o[a];return r[i]=n(s),xi(e,this,r)}}function de(e,i){return uc(d1(e,i,wi),e+"")}var Q5=9007199254740991;function Bu(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Q5}function ji(e){return e!=null&&Bu(e.length)&&!Wn(e)}function ri(e,i,n){if(!Pe(n))return!1;var o=typeof i;return(o=="number"?ji(n)&&In(i,n.length):o=="string"&&i in n)?ln(n[i],e):!1}function rt(e){return de(function(i,n){var o=-1,a=n.length,t=a>1?n[a-1]:void 0,s=a>2?n[2]:void 0;for(t=e.length>3&&typeof t=="function"?(a--,t):void 0,s&&ri(n[0],n[1],s)&&(t=a<3?void 0:t,a=1),i=Object(i);++o<a;){var r=n[o];r&&e(i,r,o,t)}return i})}var W5=Object.prototype;function Hs(e){var i=e&&e.constructor,n=typeof i=="function"&&i.prototype||W5;return e===n}function dc(e,i){for(var n=-1,o=Array(e);++n<e;)o[n]=i(n);return o}var I5="[object Arguments]";function g0(e){return Ee(e)&&gi(e)==I5}var l1=Object.prototype,_5=l1.hasOwnProperty,z5=l1.propertyIsEnumerable,_o=g0((function(){return arguments})())?g0:function(e){return Ee(e)&&_5.call(e,"callee")&&!z5.call(e,"callee")};function lc(){return!1}var g1=typeof exports=="object"&&exports&&!exports.nodeType&&exports,h0=g1&&typeof module=="object"&&module&&!module.nodeType&&module,K5=h0&&h0.exports===g1,c0=K5?Ke.Buffer:void 0,q5=c0?c0.isBuffer:void 0,ho=q5||lc,U5="[object Arguments]",V5="[object Array]",e6="[object Boolean]",i6="[object Date]",n6="[object Error]",o6="[object Function]",a6="[object Map]",t6="[object Number]",s6="[object Object]",r6="[object RegExp]",u6="[object Set]",d6="[object String]",l6="[object WeakMap]",g6="[object ArrayBuffer]",h6="[object DataView]",c6="[object Float32Array]",p6="[object Float64Array]",v6="[object Int8Array]",y6="[object Int16Array]",f6="[object Int32Array]",m6="[object Uint8Array]",b6="[object Uint8ClampedArray]",w6="[object Uint16Array]",j6="[object Uint32Array]",Te={};Te[c6]=Te[p6]=Te[v6]=Te[y6]=Te[f6]=Te[m6]=Te[b6]=Te[w6]=Te[j6]=!0;Te[U5]=Te[V5]=Te[g6]=Te[e6]=Te[h6]=Te[i6]=Te[n6]=Te[o6]=Te[a6]=Te[t6]=Te[s6]=Te[r6]=Te[u6]=Te[d6]=Te[l6]=!1;function k6(e){return Ee(e)&&Bu(e.length)&&!!Te[gi(e)]}function Ti(e){return function(i){return e(i)}}var h1=typeof exports=="object"&&exports&&!exports.nodeType&&exports,es=h1&&typeof module=="object"&&module&&!module.nodeType&&module,S6=es&&es.exports===h1,Ud=S6&&_k.process,Ki=(function(){try{var e=es&&es.require&&es.require("util").types;return e||Ud&&Ud.binding&&Ud.binding("util")}catch{}})(),p0=Ki&&Ki.isTypedArray,ut=p0?Ti(p0):k6,L6=Object.prototype,C6=L6.hasOwnProperty;function c1(e,i){var n=ae(e),o=!n&&_o(e),a=!n&&!o&&ho(e),t=!n&&!o&&!a&&ut(e),s=n||o||a||t,r=s?dc(e.length,String):[],u=r.length;for(var d in e)(i||C6.call(e,d))&&!(s&&(d=="length"||a&&(d=="offset"||d=="parent")||t&&(d=="buffer"||d=="byteLength"||d=="byteOffset")||In(d,u)))&&r.push(d);return r}function p1(e,i){return function(n){return e(i(n))}}var Y6=p1(Object.keys,Object),$6=Object.prototype,Z6=$6.hasOwnProperty;function gc(e){if(!Hs(e))return Y6(e);var i=[];for(var n in Object(e))Z6.call(e,n)&&n!="constructor"&&i.push(n);return i}function qe(e){return ji(e)?c1(e):gc(e)}var J6=Object.prototype,x6=J6.hasOwnProperty,T6=rt(function(e,i){if(Hs(i)||ji(i)){Zn(i,qe(i),e);return}for(var n in i)x6.call(i,n)&&Xs(e,n,i[n])});function D6(e){var i=[];if(e!=null)for(var n in Object(e))i.push(n);return i}var B6=Object.prototype,X6=B6.hasOwnProperty;function H6(e){if(!Pe(e))return D6(e);var i=Hs(e),n=[];for(var o in e)o=="constructor"&&(i||!X6.call(e,o))||n.push(o);return n}function ki(e){return ji(e)?c1(e,!0):H6(e)}var M6=rt(function(e,i){Zn(i,ki(i),e)}),P6=rt(function(e,i,n,o){Zn(i,ki(i),e,o)}),vg=rt(function(e,i,n,o){Zn(i,qe(i),e,o)}),N6=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,E6=/^\w*$/;function hc(e,i){if(ae(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||Zi(e)?!0:E6.test(e)||!N6.test(e)||i!=null&&e in Object(i)}var ys=ta(Object,"create");function R6(){this.__data__=ys?ys(null):{},this.size=0}function O6(e){var i=this.has(e)&&delete this.__data__[e];return this.size-=i?1:0,i}var A6="__lodash_hash_undefined__",G6=Object.prototype,F6=G6.hasOwnProperty;function Q6(e){var i=this.__data__;if(ys){var n=i[e];return n===A6?void 0:n}return F6.call(i,e)?i[e]:void 0}var W6=Object.prototype,I6=W6.hasOwnProperty;function _6(e){var i=this.__data__;return ys?i[e]!==void 0:I6.call(i,e)}var z6="__lodash_hash_undefined__";function K6(e,i){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=ys&&i===void 0?z6:i,this}function zo(e){var i=-1,n=e==null?0:e.length;for(this.clear();++i<n;){var o=e[i];this.set(o[0],o[1])}}zo.prototype.clear=R6;zo.prototype.delete=O6;zo.prototype.get=Q6;zo.prototype.has=_6;zo.prototype.set=K6;function q6(){this.__data__=[],this.size=0}function Xu(e,i){for(var n=e.length;n--;)if(ln(e[n][0],i))return n;return-1}var U6=Array.prototype,V6=U6.splice;function eq(e){var i=this.__data__,n=Xu(i,e);if(n<0)return!1;var o=i.length-1;return n==o?i.pop():V6.call(i,n,1),--this.size,!0}function iq(e){var i=this.__data__,n=Xu(i,e);return n<0?void 0:i[n][1]}function nq(e){return Xu(this.__data__,e)>-1}function oq(e,i){var n=this.__data__,o=Xu(n,e);return o<0?(++this.size,n.push([e,i])):n[o][1]=i,this}function zn(e){var i=-1,n=e==null?0:e.length;for(this.clear();++i<n;){var o=e[i];this.set(o[0],o[1])}}zn.prototype.clear=q6;zn.prototype.delete=eq;zn.prototype.get=iq;zn.prototype.has=nq;zn.prototype.set=oq;var fs=ta(Ke,"Map");function aq(){this.size=0,this.__data__={hash:new zo,map:new(fs||zn),string:new zo}}function tq(e){var i=typeof e;return i=="string"||i=="number"||i=="symbol"||i=="boolean"?e!=="__proto__":e===null}function Hu(e,i){var n=e.__data__;return tq(i)?n[typeof i=="string"?"string":"hash"]:n.map}function sq(e){var i=Hu(this,e).delete(e);return this.size-=i?1:0,i}function rq(e){return Hu(this,e).get(e)}function uq(e){return Hu(this,e).has(e)}function dq(e,i){var n=Hu(this,e),o=n.size;return n.set(e,i),this.size+=n.size==o?0:1,this}function Kn(e){var i=-1,n=e==null?0:e.length;for(this.clear();++i<n;){var o=e[i];this.set(o[0],o[1])}}Kn.prototype.clear=aq;Kn.prototype.delete=sq;Kn.prototype.get=rq;Kn.prototype.has=uq;Kn.prototype.set=dq;var lq="Expected a function";function Mu(e,i){if(typeof e!="function"||i!=null&&typeof i!="function")throw new TypeError(lq);var n=function(){var o=arguments,a=i?i.apply(this,o):o[0],t=n.cache;if(t.has(a))return t.get(a);var s=e.apply(this,o);return n.cache=t.set(a,s)||t,s};return n.cache=new(Mu.Cache||Kn),n}Mu.Cache=Kn;var gq=500;function hq(e){var i=Mu(e,function(o){return n.size===gq&&n.clear(),o}),n=i.cache;return i}var cq=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,pq=/\\(\\)?/g,v1=hq(function(e){var i=[];return e.charCodeAt(0)===46&&i.push(""),e.replace(cq,function(n,o,a,t){i.push(a?t.replace(pq,"$1"):o||n)}),i});function be(e){return e==null?"":Ji(e)}function Co(e,i){return ae(e)?e:hc(e,i)?[e]:v1(be(e))}function rn(e){if(typeof e=="string"||Zi(e))return e;var i=e+"";return i=="0"&&1/e==-1/0?"-0":i}function sa(e,i){i=Co(i,e);for(var n=0,o=i.length;e!=null&&n<o;)e=e[rn(i[n++])];return n&&n==o?e:void 0}function cc(e,i,n){var o=e==null?void 0:sa(e,i);return o===void 0?n:o}function pc(e,i){for(var n=-1,o=i.length,a=Array(o),t=e==null;++n<o;)a[n]=t?void 0:cc(e,i[n]);return a}function Yo(e,i){for(var n=-1,o=i.length,a=e.length;++n<o;)e[a+n]=i[n];return e}var v0=ai?ai.isConcatSpreadable:void 0;function vq(e){return ae(e)||_o(e)||!!(v0&&e&&e[v0])}function ei(e,i,n,o,a){var t=-1,s=e.length;for(n||(n=vq),a||(a=[]);++t<s;){var r=e[t];i>0&&n(r)?i>1?ei(r,i-1,n,o,a):Yo(a,r):o||(a[a.length]=r)}return a}function y1(e){var i=e==null?0:e.length;return i?ei(e,1):[]}function qn(e){return uc(d1(e,void 0,y1),e+"")}var yq=qn(pc),Pu=p1(Object.getPrototypeOf,Object),fq="[object Object]",mq=Function.prototype,bq=Object.prototype,f1=mq.toString,wq=bq.hasOwnProperty,jq=f1.call(Object);function Ms(e){if(!Ee(e)||gi(e)!=fq)return!1;var i=Pu(e);if(i===null)return!0;var n=wq.call(i,"constructor")&&i.constructor;return typeof n=="function"&&n instanceof n&&f1.call(n)==jq}var kq="[object DOMException]",Sq="[object Error]";function vc(e){if(!Ee(e))return!1;var i=gi(e);return i==Sq||i==kq||typeof e.message=="string"&&typeof e.name=="string"&&!Ms(e)}var m1=de(function(e,i){try{return xi(e,void 0,i)}catch(n){return vc(n)?n:new Error(n)}}),Lq="Expected a function";function b1(e,i){var n;if(typeof i!="function")throw new TypeError(Lq);return e=re(e),function(){return--e>0&&(n=i.apply(this,arguments)),e<=1&&(i=void 0),n}}var Cq=1,Yq=32,Nu=de(function(e,i,n){var o=Cq;if(n.length){var a=go(n,st(Nu));o|=Yq}return _n(e,o,i,n,a)});Nu.placeholder={};var $q=qn(function(e,i){return Xi(i,function(n){n=rn(n),$n(e,n,Nu(e[n],e))}),e}),Zq=1,Jq=2,xq=32,yc=de(function(e,i,n){var o=Zq|Jq;if(n.length){var a=go(n,st(yc));o|=xq}return _n(i,o,e,n,a)});yc.placeholder={};function qi(e,i,n){var o=-1,a=e.length;i<0&&(i=-i>a?0:a+i),n=n>a?a:n,n<0&&(n+=a),a=i>n?0:n-i>>>0,i>>>=0;for(var t=Array(a);++o<a;)t[o]=e[o+i];return t}function $o(e,i,n){var o=e.length;return n=n===void 0?o:n,!i&&n>=o?e:qi(e,i,n)}var Tq="\\ud800-\\udfff",Dq="\\u0300-\\u036f",Bq="\\ufe20-\\ufe2f",Xq="\\u20d0-\\u20ff",Hq=Dq+Bq+Xq,Mq="\\ufe0e\\ufe0f",Pq="\\u200d",Nq=RegExp("["+Pq+Tq+Hq+Mq+"]");function dt(e){return Nq.test(e)}function Eq(e){return e.split("")}var w1="\\ud800-\\udfff",Rq="\\u0300-\\u036f",Oq="\\ufe20-\\ufe2f",Aq="\\u20d0-\\u20ff",Gq=Rq+Oq+Aq,Fq="\\ufe0e\\ufe0f",Qq="["+w1+"]",yg="["+Gq+"]",fg="\\ud83c[\\udffb-\\udfff]",Wq="(?:"+yg+"|"+fg+")",j1="[^"+w1+"]",k1="(?:\\ud83c[\\udde6-\\uddff]){2}",S1="[\\ud800-\\udbff][\\udc00-\\udfff]",Iq="\\u200d",L1=Wq+"?",C1="["+Fq+"]?",_q="(?:"+Iq+"(?:"+[j1,k1,S1].join("|")+")"+C1+L1+")*",zq=C1+L1+_q,Kq="(?:"+[j1+yg+"?",yg,k1,S1,Qq].join("|")+")",qq=RegExp(fg+"(?="+fg+")|"+Kq+zq,"g");function Uq(e){return e.match(qq)||[]}function un(e){return dt(e)?Uq(e):Eq(e)}function Y1(e){return function(i){i=be(i);var n=dt(i)?un(i):void 0,o=n?n[0]:i.charAt(0),a=n?$o(n,1).join(""):i.slice(1);return o[e]()+a}}var fc=Y1("toUpperCase");function $1(e){return fc(be(e).toLowerCase())}function mc(e,i,n,o){var a=-1,t=e==null?0:e.length;for(o&&t&&(n=e[++a]);++a<t;)n=i(n,e[a],a,e);return n}function bc(e){return function(i){return e?.[i]}}var Vq={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},eU=bc(Vq),iU=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,nU="\\u0300-\\u036f",oU="\\ufe20-\\ufe2f",aU="\\u20d0-\\u20ff",tU=nU+oU+aU,sU="["+tU+"]",rU=RegExp(sU,"g");function Z1(e){return e=be(e),e&&e.replace(iU,eU).replace(rU,"")}var uU=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function dU(e){return e.match(uU)||[]}var lU=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function gU(e){return lU.test(e)}var J1="\\ud800-\\udfff",hU="\\u0300-\\u036f",cU="\\ufe20-\\ufe2f",pU="\\u20d0-\\u20ff",vU=hU+cU+pU,x1="\\u2700-\\u27bf",T1="a-z\\xdf-\\xf6\\xf8-\\xff",yU="\\xac\\xb1\\xd7\\xf7",fU="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",mU="\\u2000-\\u206f",bU=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",D1="A-Z\\xc0-\\xd6\\xd8-\\xde",wU="\\ufe0e\\ufe0f",B1=yU+fU+mU+bU,X1="['’]",y0="["+B1+"]",jU="["+vU+"]",H1="\\d+",kU="["+x1+"]",M1="["+T1+"]",P1="[^"+J1+B1+H1+x1+T1+D1+"]",SU="\\ud83c[\\udffb-\\udfff]",LU="(?:"+jU+"|"+SU+")",CU="[^"+J1+"]",N1="(?:\\ud83c[\\udde6-\\uddff]){2}",E1="[\\ud800-\\udbff][\\udc00-\\udfff]",fa="["+D1+"]",YU="\\u200d",f0="(?:"+M1+"|"+P1+")",$U="(?:"+fa+"|"+P1+")",m0="(?:"+X1+"(?:d|ll|m|re|s|t|ve))?",b0="(?:"+X1+"(?:D|LL|M|RE|S|T|VE))?",R1=LU+"?",O1="["+wU+"]?",ZU="(?:"+YU+"(?:"+[CU,N1,E1].join("|")+")"+O1+R1+")*",JU="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",xU="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",TU=O1+R1+ZU,DU="(?:"+[kU,N1,E1].join("|")+")"+TU,BU=RegExp([fa+"?"+M1+"+"+m0+"(?="+[y0,fa,"$"].join("|")+")",$U+"+"+b0+"(?="+[y0,fa+f0,"$"].join("|")+")",fa+"?"+f0+"+"+m0,fa+"+"+b0,xU,JU,H1,DU].join("|"),"g");function XU(e){return e.match(BU)||[]}function A1(e,i,n){return e=be(e),i=n?void 0:i,i===void 0?gU(e)?XU(e):dU(e):e.match(i)||[]}var HU="['’]",MU=RegExp(HU,"g");function lt(e){return function(i){return mc(A1(Z1(i).replace(MU,"")),e,"")}}var PU=lt(function(e,i,n){return i=i.toLowerCase(),e+(n?$1(i):i)});function NU(){if(!arguments.length)return[];var e=arguments[0];return ae(e)?e:[e]}var EU=Ke.isFinite,RU=Math.min;function wc(e){var i=Math[e];return function(n,o){if(n=Ai(n),o=o==null?0:RU(re(o),292),o&&EU(n)){var a=(be(n)+"e").split("e"),t=i(a[0]+"e"+(+a[1]+o));return a=(be(t)+"e").split("e"),+(a[0]+"e"+(+a[1]-o))}return i(n)}}var OU=wc("ceil");function G1(e){var i=b(e);return i.__chain__=!0,i}var AU=Math.ceil,GU=Math.max;function FU(e,i,n){(n?ri(e,i,n):i===void 0)?i=1:i=GU(re(i),0);var o=e==null?0:e.length;if(!o||i<1)return[];for(var a=0,t=0,s=Array(AU(o/i));a<o;)s[t++]=qi(e,a,a+=i);return s}function ra(e,i,n){return e===e&&(n!==void 0&&(e=e<=n?e:n),i!==void 0&&(e=e>=i?e:i)),e}function QU(e,i,n){return n===void 0&&(n=i,i=void 0),n!==void 0&&(n=Ai(n),n=n===n?n:0),i!==void 0&&(i=Ai(i),i=i===i?i:0),ra(Ai(e),i,n)}function WU(){this.__data__=new zn,this.size=0}function IU(e){var i=this.__data__,n=i.delete(e);return this.size=i.size,n}function _U(e){return this.__data__.get(e)}function zU(e){return this.__data__.has(e)}var KU=200;function qU(e,i){var n=this.__data__;if(n instanceof zn){var o=n.__data__;if(!fs||o.length<KU-1)return o.push([e,i]),this.size=++n.size,this;n=this.__data__=new Kn(o)}return n.set(e,i),this.size=n.size,this}function on(e){var i=this.__data__=new zn(e);this.size=i.size}on.prototype.clear=WU;on.prototype.delete=IU;on.prototype.get=_U;on.prototype.has=zU;on.prototype.set=qU;function F1(e,i){return e&&Zn(i,qe(i),e)}function UU(e,i){return e&&Zn(i,ki(i),e)}var Q1=typeof exports=="object"&&exports&&!exports.nodeType&&exports,w0=Q1&&typeof module=="object"&&module&&!module.nodeType&&module,VU=w0&&w0.exports===Q1,j0=VU?Ke.Buffer:void 0,k0=j0?j0.allocUnsafe:void 0;function W1(e,i){if(i)return e.slice();var n=e.length,o=k0?k0(n):new e.constructor(n);return e.copy(o),o}function Zo(e,i){for(var n=-1,o=e==null?0:e.length,a=0,t=[];++n<o;){var s=e[n];i(s,n,e)&&(t[a++]=s)}return t}function jc(){return[]}var eV=Object.prototype,iV=eV.propertyIsEnumerable,S0=Object.getOwnPropertySymbols,kc=S0?function(e){return e==null?[]:(e=Object(e),Zo(S0(e),function(i){return iV.call(e,i)}))}:jc;function nV(e,i){return Zn(e,kc(e),i)}var oV=Object.getOwnPropertySymbols,I1=oV?function(e){for(var i=[];e;)Yo(i,kc(e)),e=Pu(e);return i}:jc;function aV(e,i){return Zn(e,I1(e),i)}function _1(e,i,n){var o=i(e);return ae(e)?o:Yo(o,n(e))}function mg(e){return _1(e,qe,kc)}function Sc(e){return _1(e,ki,I1)}var bg=ta(Ke,"DataView"),wg=ta(Ke,"Promise"),Ba=ta(Ke,"Set"),L0="[object Map]",tV="[object Object]",C0="[object Promise]",Y0="[object Set]",$0="[object WeakMap]",Z0="[object DataView]",sV=aa(bg),rV=aa(fs),uV=aa(wg),dV=aa(Ba),lV=aa(ps),Xo=gi;(bg&&Xo(new bg(new ArrayBuffer(1)))!=Z0||fs&&Xo(new fs)!=L0||wg&&Xo(wg.resolve())!=C0||Ba&&Xo(new Ba)!=Y0||ps&&Xo(new ps)!=$0)&&(Xo=function(e){var i=gi(e),n=i==tV?e.constructor:void 0,o=n?aa(n):"";if(o)switch(o){case sV:return Z0;case rV:return L0;case uV:return C0;case dV:return Y0;case lV:return $0}return i});const bn=Xo;var gV=Object.prototype,hV=gV.hasOwnProperty;function cV(e){var i=e.length,n=new e.constructor(i);return i&&typeof e[0]=="string"&&hV.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var Or=Ke.Uint8Array;function Lc(e){var i=new e.constructor(e.byteLength);return new Or(i).set(new Or(e)),i}function pV(e,i){var n=i?Lc(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var vV=/\w*$/;function yV(e){var i=new e.constructor(e.source,vV.exec(e));return i.lastIndex=e.lastIndex,i}var J0=ai?ai.prototype:void 0,x0=J0?J0.valueOf:void 0;function fV(e){return x0?Object(x0.call(e)):{}}function z1(e,i){var n=i?Lc(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var mV="[object Boolean]",bV="[object Date]",wV="[object Map]",jV="[object Number]",kV="[object RegExp]",SV="[object Set]",LV="[object String]",CV="[object Symbol]",YV="[object ArrayBuffer]",$V="[object DataView]",ZV="[object Float32Array]",JV="[object Float64Array]",xV="[object Int8Array]",TV="[object Int16Array]",DV="[object Int32Array]",BV="[object Uint8Array]",XV="[object Uint8ClampedArray]",HV="[object Uint16Array]",MV="[object Uint32Array]";function PV(e,i,n){var o=e.constructor;switch(i){case YV:return Lc(e);case mV:case bV:return new o(+e);case $V:return pV(e,n);case ZV:case JV:case xV:case TV:case DV:case BV:case XV:case HV:case MV:return z1(e,n);case wV:return new o;case jV:case LV:return new o(e);case kV:return yV(e);case SV:return new o;case CV:return fV(e)}}function K1(e){return typeof e.constructor=="function"&&!Hs(e)?at(Pu(e)):{}}var NV="[object Map]";function EV(e){return Ee(e)&&bn(e)==NV}var T0=Ki&&Ki.isMap,q1=T0?Ti(T0):EV,RV="[object Set]";function OV(e){return Ee(e)&&bn(e)==RV}var D0=Ki&&Ki.isSet,U1=D0?Ti(D0):OV,AV=1,GV=2,FV=4,V1="[object Arguments]",QV="[object Array]",WV="[object Boolean]",IV="[object Date]",_V="[object Error]",eS="[object Function]",zV="[object GeneratorFunction]",KV="[object Map]",qV="[object Number]",iS="[object Object]",UV="[object RegExp]",VV="[object Set]",eee="[object String]",iee="[object Symbol]",nee="[object WeakMap]",oee="[object ArrayBuffer]",aee="[object DataView]",tee="[object Float32Array]",see="[object Float64Array]",ree="[object Int8Array]",uee="[object Int16Array]",dee="[object Int32Array]",lee="[object Uint8Array]",gee="[object Uint8ClampedArray]",hee="[object Uint16Array]",cee="[object Uint32Array]",Ze={};Ze[V1]=Ze[QV]=Ze[oee]=Ze[aee]=Ze[WV]=Ze[IV]=Ze[tee]=Ze[see]=Ze[ree]=Ze[uee]=Ze[dee]=Ze[KV]=Ze[qV]=Ze[iS]=Ze[UV]=Ze[VV]=Ze[eee]=Ze[iee]=Ze[lee]=Ze[gee]=Ze[hee]=Ze[cee]=!0;Ze[_V]=Ze[eS]=Ze[nee]=!1;function Gi(e,i,n,o,a,t){var s,r=i&AV,u=i&GV,d=i&FV;if(n&&(s=a?n(e,o,a,t):n(e)),s!==void 0)return s;if(!Pe(e))return e;var l=ae(e);if(l){if(s=cV(e),!r)return yi(e,s)}else{var g=bn(e),h=g==eS||g==zV;if(ho(e))return W1(e,r);if(g==iS||g==V1||h&&!a){if(s=u||h?{}:K1(e),!r)return u?aV(e,UU(s,e)):nV(e,F1(s,e))}else{if(!Ze[g])return a?e:{};s=PV(e,g,r)}}t||(t=new on);var c=t.get(e);if(c)return c;t.set(e,s),U1(e)?e.forEach(function(w){s.add(Gi(w,i,n,w,e,t))}):q1(e)&&e.forEach(function(w,v){s.set(v,Gi(w,i,n,v,e,t))});var p=d?u?Sc:mg:u?ki:qe,f=l?void 0:p(e);return Xi(f||e,function(w,v){f&&(v=w,w=e[v]),Xs(s,v,Gi(w,i,n,v,e,t))}),s}var pee=4;function vee(e){return Gi(e,pee)}var yee=1,fee=4;function mee(e){return Gi(e,yee|fee)}var bee=1,wee=4;function jee(e,i){return i=typeof i=="function"?i:void 0,Gi(e,bee|wee,i)}var kee=4;function See(e,i){return i=typeof i=="function"?i:void 0,Gi(e,kee,i)}function Lee(){return new zi(this.value(),this.__chain__)}function Cee(e){for(var i=-1,n=e==null?0:e.length,o=0,a=[];++i<n;){var t=e[i];t&&(a[o++]=t)}return a}function Yee(){var e=arguments.length;if(!e)return[];for(var i=Array(e-1),n=arguments[0],o=e;o--;)i[o-1]=arguments[o];return Yo(ae(n)?yi(n):[n],ei(i,1))}var $ee="__lodash_hash_undefined__";function Zee(e){return this.__data__.set(e,$ee),this}function Jee(e){return this.__data__.has(e)}function Ko(e){var i=-1,n=e==null?0:e.length;for(this.__data__=new Kn;++i<n;)this.add(e[i])}Ko.prototype.add=Ko.prototype.push=Zee;Ko.prototype.has=Jee;function Cc(e,i){for(var n=-1,o=e==null?0:e.length;++n<o;)if(i(e[n],n,e))return!0;return!1}function ms(e,i){return e.has(i)}var xee=1,Tee=2;function nS(e,i,n,o,a,t){var s=n&xee,r=e.length,u=i.length;if(r!=u&&!(s&&u>r))return!1;var d=t.get(e),l=t.get(i);if(d&&l)return d==i&&l==e;var g=-1,h=!0,c=n&Tee?new Ko:void 0;for(t.set(e,i),t.set(i,e);++g<r;){var p=e[g],f=i[g];if(o)var w=s?o(f,p,g,i,e,t):o(p,f,g,e,i,t);if(w!==void 0){if(w)continue;h=!1;break}if(c){if(!Cc(i,function(v,j){if(!ms(c,j)&&(p===v||a(p,v,n,o,t)))return c.push(j)})){h=!1;break}}else if(!(p===f||a(p,f,n,o,t))){h=!1;break}}return t.delete(e),t.delete(i),h}function Yc(e){var i=-1,n=Array(e.size);return e.forEach(function(o,a){n[++i]=[a,o]}),n}function Eu(e){var i=-1,n=Array(e.size);return e.forEach(function(o){n[++i]=o}),n}var Dee=1,Bee=2,Xee="[object Boolean]",Hee="[object Date]",Mee="[object Error]",Pee="[object Map]",Nee="[object Number]",Eee="[object RegExp]",Ree="[object Set]",Oee="[object String]",Aee="[object Symbol]",Gee="[object ArrayBuffer]",Fee="[object DataView]",B0=ai?ai.prototype:void 0,Vd=B0?B0.valueOf:void 0;function Qee(e,i,n,o,a,t,s){switch(n){case Fee:if(e.byteLength!=i.byteLength||e.byteOffset!=i.byteOffset)return!1;e=e.buffer,i=i.buffer;case Gee:return!(e.byteLength!=i.byteLength||!t(new Or(e),new Or(i)));case Xee:case Hee:case Nee:return ln(+e,+i);case Mee:return e.name==i.name&&e.message==i.message;case Eee:case Oee:return e==i+"";case Pee:var r=Yc;case Ree:var u=o&Dee;if(r||(r=Eu),e.size!=i.size&&!u)return!1;var d=s.get(e);if(d)return d==i;o|=Bee,s.set(e,i);var l=nS(r(e),r(i),o,a,t,s);return s.delete(e),l;case Aee:if(Vd)return Vd.call(e)==Vd.call(i)}return!1}var Wee=1,Iee=Object.prototype,_ee=Iee.hasOwnProperty;function zee(e,i,n,o,a,t){var s=n&Wee,r=mg(e),u=r.length,d=mg(i),l=d.length;if(u!=l&&!s)return!1;for(var g=u;g--;){var h=r[g];if(!(s?h in i:_ee.call(i,h)))return!1}var c=t.get(e),p=t.get(i);if(c&&p)return c==i&&p==e;var f=!0;t.set(e,i),t.set(i,e);for(var w=s;++g<u;){h=r[g];var v=e[h],j=i[h];if(o)var C=s?o(j,v,h,i,e,t):o(v,j,h,e,i,t);if(!(C===void 0?v===j||a(v,j,n,o,t):C)){f=!1;break}w||(w=h=="constructor")}if(f&&!w){var y=e.constructor,k=i.constructor;y!=k&&"constructor"in e&&"constructor"in i&&!(typeof y=="function"&&y instanceof y&&typeof k=="function"&&k instanceof k)&&(f=!1)}return t.delete(e),t.delete(i),f}var Kee=1,X0="[object Arguments]",H0="[object Array]",er="[object Object]",qee=Object.prototype,M0=qee.hasOwnProperty;function Uee(e,i,n,o,a,t){var s=ae(e),r=ae(i),u=s?H0:bn(e),d=r?H0:bn(i);u=u==X0?er:u,d=d==X0?er:d;var l=u==er,g=d==er,h=u==d;if(h&&ho(e)){if(!ho(i))return!1;s=!0,l=!1}if(h&&!l)return t||(t=new on),s||ut(e)?nS(e,i,n,o,a,t):Qee(e,i,u,n,o,a,t);if(!(n&Kee)){var c=l&&M0.call(e,"__wrapped__"),p=g&&M0.call(i,"__wrapped__");if(c||p){var f=c?e.value():e,w=p?i.value():i;return t||(t=new on),a(f,w,n,o,t)}}return h?(t||(t=new on),zee(e,i,n,o,a,t)):!1}function Ps(e,i,n,o,a){return e===i?!0:e==null||i==null||!Ee(e)&&!Ee(i)?e!==e&&i!==i:Uee(e,i,n,o,Ps,a)}var Vee=1,eie=2;function $c(e,i,n,o){var a=n.length,t=a,s=!o;if(e==null)return!t;for(e=Object(e);a--;){var r=n[a];if(s&&r[2]?r[1]!==e[r[0]]:!(r[0]in e))return!1}for(;++a<t;){r=n[a];var u=r[0],d=e[u],l=r[1];if(s&&r[2]){if(d===void 0&&!(u in e))return!1}else{var g=new on;if(o)var h=o(d,l,u,e,i,g);if(!(h===void 0?Ps(l,d,Vee|eie,o,g):h))return!1}}return!0}function oS(e){return e===e&&!Pe(e)}function Zc(e){for(var i=qe(e),n=i.length;n--;){var o=i[n],a=e[o];i[n]=[o,a,oS(a)]}return i}function aS(e,i){return function(n){return n==null?!1:n[e]===i&&(i!==void 0||e in Object(n))}}function tS(e){var i=Zc(e);return i.length==1&&i[0][2]?aS(i[0][0],i[0][1]):function(n){return n===e||$c(n,e,i)}}function iie(e,i){return e!=null&&i in Object(e)}function sS(e,i,n){i=Co(i,e);for(var o=-1,a=i.length,t=!1;++o<a;){var s=rn(i[o]);if(!(t=e!=null&&n(e,s)))break;e=e[s]}return t||++o!=a?t:(a=e==null?0:e.length,!!a&&Bu(a)&&In(s,a)&&(ae(e)||_o(e)))}function Jc(e,i){return e!=null&&sS(e,i,iie)}var nie=1,oie=2;function rS(e,i){return hc(e)&&oS(i)?aS(rn(e),i):function(n){var o=cc(n,e);return o===void 0&&o===i?Jc(n,e):Ps(i,o,nie|oie)}}function xc(e){return function(i){return i?.[e]}}function aie(e){return function(i){return sa(i,e)}}function uS(e){return hc(e)?xc(rn(e)):aie(e)}function ie(e){return typeof e=="function"?e:e==null?wi:typeof e=="object"?ae(e)?rS(e[0],e[1]):tS(e):uS(e)}var tie="Expected a function";function sie(e){var i=e==null?0:e.length,n=ie;return e=i?Be(e,function(o){if(typeof o[1]!="function")throw new TypeError(tie);return[n(o[0]),o[1]]}):[],de(function(o){for(var a=-1;++a<i;){var t=e[a];if(xi(t[0],this,o))return xi(t[1],this,o)}})}function dS(e,i,n){var o=n.length;if(e==null)return!o;for(e=Object(e);o--;){var a=n[o],t=i[a],s=e[a];if(s===void 0&&!(a in e)||!t(s))return!1}return!0}function rie(e){var i=qe(e);return function(n){return dS(n,e,i)}}var uie=1;function die(e){return rie(Gi(e,uie))}function lie(e,i){return i==null||dS(e,i,qe(i))}function gie(e,i,n,o){for(var a=-1,t=e==null?0:e.length;++a<t;){var s=e[a];i(o,s,n(s),e)}return o}function lS(e){return function(i,n,o){for(var a=-1,t=Object(i),s=o(i),r=s.length;r--;){var u=s[e?r:++a];if(n(t[u],u,t)===!1)break}return i}}var Tc=lS();function Jn(e,i){return e&&Tc(e,i,qe)}function gS(e,i){return function(n,o){if(n==null)return n;if(!ji(n))return e(n,o);for(var a=n.length,t=i?a:-1,s=Object(n);(i?t--:++t<a)&&o(s[t],t,s)!==!1;);return n}}var Jo=gS(Jn);function hie(e,i,n,o){return Jo(e,function(a,t,s){i(o,a,n(a),s)}),o}function Ru(e,i){return function(n,o){var a=ae(n)?gie:hie,t=i?i():{};return a(n,e,ie(o),t)}}var cie=Object.prototype,pie=cie.hasOwnProperty,vie=Ru(function(e,i,n){pie.call(e,n)?++e[n]:$n(e,n,1)});function yie(e,i){var n=at(e);return i==null?n:F1(n,i)}var fie=8;function Dc(e,i,n){i=n?void 0:i;var o=_n(e,fie,void 0,void 0,void 0,void 0,void 0,i);return o.placeholder=Dc.placeholder,o}Dc.placeholder={};var mie=16;function Bc(e,i,n){i=n?void 0:i;var o=_n(e,mie,void 0,void 0,void 0,void 0,void 0,i);return o.placeholder=Bc.placeholder,o}Bc.placeholder={};var br=function(){return Ke.Date.now()},bie="Expected a function",wie=Math.max,jie=Math.min;function hS(e,i,n){var o,a,t,s,r,u,d=0,l=!1,g=!1,h=!0;if(typeof e!="function")throw new TypeError(bie);i=Ai(i)||0,Pe(n)&&(l=!!n.leading,g="maxWait"in n,t=g?wie(Ai(n.maxWait)||0,i):t,h="trailing"in n?!!n.trailing:h);function c(S){var J=o,T=a;return o=a=void 0,d=S,s=e.apply(T,J),s}function p(S){return d=S,r=setTimeout(v,i),l?c(S):s}function f(S){var J=S-u,T=S-d,M=i-J;return g?jie(M,t-T):M}function w(S){var J=S-u,T=S-d;return u===void 0||J>=i||J<0||g&&T>=t}function v(){var S=br();if(w(S))return j(S);r=setTimeout(v,f(S))}function j(S){return r=void 0,h&&o?c(S):(o=a=void 0,s)}function C(){r!==void 0&&clearTimeout(r),d=0,o=u=a=r=void 0}function y(){return r===void 0?s:j(br())}function k(){var S=br(),J=w(S);if(o=arguments,a=this,u=S,J){if(r===void 0)return p(u);if(g)return clearTimeout(r),r=setTimeout(v,i),c(u)}return r===void 0&&(r=setTimeout(v,i)),s}return k.cancel=C,k.flush=y,k}function kie(e,i){return e==null||e!==e?i:e}var cS=Object.prototype,Sie=cS.hasOwnProperty,Lie=de(function(e,i){e=Object(e);var n=-1,o=i.length,a=o>2?i[2]:void 0;for(a&&ri(i[0],i[1],a)&&(o=1);++n<o;)for(var t=i[n],s=ki(t),r=-1,u=s.length;++r<u;){var d=s[r],l=e[d];(l===void 0||ln(l,cS[d])&&!Sie.call(e,d))&&(e[d]=t[d])}return e});function jg(e,i,n){(n!==void 0&&!ln(e[i],n)||n===void 0&&!(i in e))&&$n(e,i,n)}function Fe(e){return Ee(e)&&ji(e)}function kg(e,i){if(!(i==="constructor"&&typeof e[i]=="function")&&i!="__proto__")return e[i]}function pS(e){return Zn(e,ki(e))}function Cie(e,i,n,o,a,t,s){var r=kg(e,n),u=kg(i,n),d=s.get(u);if(d){jg(e,n,d);return}var l=t?t(r,u,n+"",e,i,s):void 0,g=l===void 0;if(g){var h=ae(u),c=!h&&ho(u),p=!h&&!c&&ut(u);l=u,h||c||p?ae(r)?l=r:Fe(r)?l=yi(r):c?(g=!1,l=W1(u,!0)):p?(g=!1,l=z1(u,!0)):l=[]:Ms(u)||_o(u)?(l=r,_o(r)?l=pS(r):(!Pe(r)||Wn(r))&&(l=K1(u))):g=!1}g&&(s.set(u,l),a(l,u,o,t,s),s.delete(u)),jg(e,n,l)}function Ou(e,i,n,o,a){e!==i&&Tc(i,function(t,s){if(a||(a=new on),Pe(t))Cie(e,i,s,n,Ou,o,a);else{var r=o?o(kg(e,s),t,s+"",e,i,a):void 0;r===void 0&&(r=t),jg(e,s,r)}},ki)}function vS(e,i,n,o,a,t){return Pe(e)&&Pe(i)&&(t.set(i,e),Ou(e,i,void 0,vS,t),t.delete(i)),e}var yS=rt(function(e,i,n,o){Ou(e,i,n,o)}),Yie=de(function(e){return e.push(void 0,vS),xi(yS,void 0,e)}),$ie="Expected a function";function fS(e,i,n){if(typeof e!="function")throw new TypeError($ie);return setTimeout(function(){e.apply(void 0,n)},i)}var Zie=de(function(e,i){return fS(e,1,i)}),Jie=de(function(e,i,n){return fS(e,Ai(i)||0,n)});function Xc(e,i,n){for(var o=-1,a=e==null?0:e.length;++o<a;)if(n(i,e[o]))return!0;return!1}var xie=200;function Ns(e,i,n,o){var a=-1,t=Tu,s=!0,r=e.length,u=[],d=i.length;if(!r)return u;n&&(i=Be(i,Ti(n))),o?(t=Xc,s=!1):i.length>=xie&&(t=ms,s=!1,i=new Ko(i));e:for(;++a<r;){var l=e[a],g=n==null?l:n(l);if(l=o||l!==0?l:0,s&&g===g){for(var h=d;h--;)if(i[h]===g)continue e;u.push(l)}else t(i,g,o)||u.push(l)}return u}var Tie=de(function(e,i){return Fe(e)?Ns(e,ei(i,1,Fe,!0)):[]});function Ui(e){var i=e==null?0:e.length;return i?e[i-1]:void 0}var Die=de(function(e,i){var n=Ui(i);return Fe(n)&&(n=void 0),Fe(e)?Ns(e,ei(i,1,Fe,!0),ie(n)):[]}),Bie=de(function(e,i){var n=Ui(i);return Fe(n)&&(n=void 0),Fe(e)?Ns(e,ei(i,1,Fe,!0),void 0,n):[]}),Xie=Zu(function(e,i){return e/i},1);function Hie(e,i,n){var o=e==null?0:e.length;return o?(i=n||i===void 0?1:re(i),qi(e,i<0?0:i,o)):[]}function Mie(e,i,n){var o=e==null?0:e.length;return o?(i=n||i===void 0?1:re(i),i=o-i,qi(e,0,i<0?0:i)):[]}function Au(e,i,n,o){for(var a=e.length,t=o?a:-1;(o?t--:++t<a)&&i(e[t],t,e););return n?qi(e,o?0:t,o?t+1:a):qi(e,o?t+1:0,o?a:t)}function Pie(e,i){return e&&e.length?Au(e,ie(i),!0,!0):[]}function Nie(e,i){return e&&e.length?Au(e,ie(i),!0):[]}function xn(e){return typeof e=="function"?e:wi}function Eie(e,i){var n=ae(e)?Xi:Jo;return n(e,xn(i))}function Rie(e,i){for(var n=e==null?0:e.length;n--&&i(e[n],n,e)!==!1;);return e}var mS=lS(!0);function Hc(e,i){return e&&mS(e,i,qe)}var bS=gS(Hc,!0);function Oie(e,i){var n=ae(e)?Rie:bS;return n(e,xn(i))}function Aie(e,i,n){e=be(e),i=Ji(i);var o=e.length;n=n===void 0?o:ra(re(n),0,o);var a=n;return n-=i.length,n>=0&&e.slice(n,a)==i}function Gie(e,i){return Be(i,function(n){return[n,e[n]]})}function Fie(e){var i=-1,n=Array(e.size);return e.forEach(function(o){n[++i]=[o,o]}),n}var Qie="[object Map]",Wie="[object Set]";function wS(e){return function(i){var n=bn(i);return n==Qie?Yc(i):n==Wie?Fie(i):Gie(i,e(i))}}var Iie=wS(qe),_ie=wS(ki),zie={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},Kie=bc(zie),jS=/[&<>"']/g,qie=RegExp(jS.source);function kS(e){return e=be(e),e&&qie.test(e)?e.replace(jS,Kie):e}var SS=/[\\^$.*+?()[\]{}|]/g,Uie=RegExp(SS.source);function Vie(e){return e=be(e),e&&Uie.test(e)?e.replace(SS,"\\$&"):e}function LS(e,i){for(var n=-1,o=e==null?0:e.length;++n<o;)if(!i(e[n],n,e))return!1;return!0}function ene(e,i){var n=!0;return Jo(e,function(o,a,t){return n=!!i(o,a,t),n}),n}function ine(e,i,n){var o=ae(e)?LS:ene;return n&&ri(e,i,n)&&(i=void 0),o(e,ie(i))}var nne=4294967295;function CS(e){return e?ra(re(e),0,nne):0}function one(e,i,n,o){var a=e.length;for(n=re(n),n<0&&(n=-n>a?0:a+n),o=o===void 0||o>a?a:re(o),o<0&&(o+=a),o=n>o?0:CS(o);n<o;)e[n++]=i;return e}function ane(e,i,n,o){var a=e==null?0:e.length;return a?(n&&typeof n!="number"&&ri(e,i,n)&&(n=0,o=a),one(e,i,n,o)):[]}function YS(e,i){var n=[];return Jo(e,function(o,a,t){i(o,a,t)&&n.push(o)}),n}function tne(e,i){var n=ae(e)?Zo:YS;return n(e,ie(i))}function $S(e){return function(i,n,o){var a=Object(i);if(!ji(i)){var t=ie(n);i=qe(i),n=function(r){return t(a[r],r,a)}}var s=e(i,n,o);return s>-1?a[t?i[s]:s]:void 0}}var sne=Math.max;function ZS(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=n==null?0:re(n);return a<0&&(a=sne(o+a,0)),xu(e,ie(i),a)}var rne=$S(ZS);function JS(e,i,n){var o;return n(e,function(a,t,s){if(i(a,t,s))return o=t,!1}),o}function une(e,i){return JS(e,ie(i),Jn)}var dne=Math.max,lne=Math.min;function xS(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=o-1;return n!==void 0&&(a=re(n),a=n<0?dne(o+a,0):lne(a,o-1)),xu(e,ie(i),a,!0)}var gne=$S(xS);function hne(e,i){return JS(e,ie(i),Hc)}function cne(e){return e&&e.length?e[0]:void 0}function TS(e,i){var n=-1,o=ji(e)?Array(e.length):[];return Jo(e,function(a,t,s){o[++n]=i(a,t,s)}),o}function Gu(e,i){var n=ae(e)?Be:TS;return n(e,ie(i))}function pne(e,i){return ei(Gu(e,i),1)}var vne=1/0;function yne(e,i){return ei(Gu(e,i),vne)}function fne(e,i,n){return n=n===void 0?1:re(n),ei(Gu(e,i),n)}var mne=1/0;function bne(e){var i=e==null?0:e.length;return i?ei(e,mne):[]}function wne(e,i){var n=e==null?0:e.length;return n?(i=i===void 0?1:re(i),ei(e,i)):[]}var jne=512;function kne(e){return _n(e,jne)}var Sne=wc("floor"),Lne="Expected a function",Cne=8,Yne=32,$ne=128,Zne=256;function DS(e){return qn(function(i){var n=i.length,o=n,a=zi.prototype.thru;for(e&&i.reverse();o--;){var t=i[o];if(typeof t!="function")throw new TypeError(Lne);if(a&&!s&&mr(t)=="wrapper")var s=new zi([],!0)}for(o=s?o:n;++o<n;){t=i[o];var r=mr(t),u=r=="wrapper"?sc(t):void 0;u&&pg(u[0])&&u[1]==($ne|Cne|Yne|Zne)&&!u[4].length&&u[9]==1?s=s[mr(u[0])].apply(s,u[3]):s=t.length==1&&pg(t)?s[r]():s.thru(t)}return function(){var d=arguments,l=d[0];if(s&&d.length==1&&ae(l))return s.plant(l).value();for(var g=0,h=n?i[g].apply(this,d):l;++g<n;)h=i[g].call(this,h);return h}})}var Jne=DS(),xne=DS(!0);function Tne(e,i){return e==null?e:Tc(e,xn(i),ki)}function Dne(e,i){return e==null?e:mS(e,xn(i),ki)}function Bne(e,i){return e&&Jn(e,xn(i))}function Xne(e,i){return e&&Hc(e,xn(i))}function Hne(e){for(var i=-1,n=e==null?0:e.length,o={};++i<n;){var a=e[i];$n(o,a[0],a[1])}return o}function Fu(e,i){return Zo(i,function(n){return Wn(e[n])})}function Mne(e){return e==null?[]:Fu(e,qe(e))}function Pne(e){return e==null?[]:Fu(e,ki(e))}var Nne=Object.prototype,Ene=Nne.hasOwnProperty,Rne=Ru(function(e,i,n){Ene.call(e,n)?e[n].push(i):$n(e,n,[i])});function Mc(e,i){return e>i}function Qu(e){return function(i,n){return typeof i=="string"&&typeof n=="string"||(i=Ai(i),n=Ai(n)),e(i,n)}}var One=Qu(Mc),Ane=Qu(function(e,i){return e>=i}),Gne=Object.prototype,Fne=Gne.hasOwnProperty;function Qne(e,i){return e!=null&&Fne.call(e,i)}function Wne(e,i){return e!=null&&sS(e,i,Qne)}var Ine=Math.max,_ne=Math.min;function zne(e,i,n){return e>=_ne(i,n)&&e<Ine(i,n)}function Kne(e,i,n){return i=Nn(i),n===void 0?(n=i,i=0):n=Nn(n),e=Ai(e),zne(e,i,n)}var qne="[object String]";function Wu(e){return typeof e=="string"||!ae(e)&&Ee(e)&&gi(e)==qne}function Pc(e,i){return Be(i,function(n){return e[n]})}function gt(e){return e==null?[]:Pc(e,qe(e))}var Une=Math.max;function Vne(e,i,n,o){e=ji(e)?e:gt(e),n=n&&!o?re(n):0;var a=e.length;return n<0&&(n=Une(a+n,0)),Wu(e)?n<=a&&e.indexOf(i,n)>-1:!!a&&tt(e,i,n)>-1}var eoe=Math.max;function ioe(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=n==null?0:re(n);return a<0&&(a=eoe(o+a,0)),tt(e,i,a)}function noe(e){var i=e==null?0:e.length;return i?qi(e,0,-1):[]}var ooe=Math.min;function Nc(e,i,n){for(var o=n?Xc:Tu,a=e[0].length,t=e.length,s=t,r=Array(t),u=1/0,d=[];s--;){var l=e[s];s&&i&&(l=Be(l,Ti(i))),u=ooe(l.length,u),r[s]=!n&&(i||a>=120&&l.length>=120)?new Ko(s&&l):void 0}l=e[0];var g=-1,h=r[0];e:for(;++g<a&&d.length<u;){var c=l[g],p=i?i(c):c;if(c=n||c!==0?c:0,!(h?ms(h,p):o(d,p,n))){for(s=t;--s;){var f=r[s];if(!(f?ms(f,p):o(e[s],p,n)))continue e}h&&h.push(p),d.push(c)}}return d}function Ec(e){return Fe(e)?e:[]}var aoe=de(function(e){var i=Be(e,Ec);return i.length&&i[0]===e[0]?Nc(i):[]}),toe=de(function(e){var i=Ui(e),n=Be(e,Ec);return i===Ui(n)?i=void 0:n.pop(),n.length&&n[0]===e[0]?Nc(n,ie(i)):[]}),soe=de(function(e){var i=Ui(e),n=Be(e,Ec);return i=typeof i=="function"?i:void 0,i&&n.pop(),n.length&&n[0]===e[0]?Nc(n,void 0,i):[]});function roe(e,i,n,o){return Jn(e,function(a,t,s){i(o,n(a),t,s)}),o}function BS(e,i){return function(n,o){return roe(n,e,i(o),{})}}var uoe=Object.prototype,doe=uoe.toString,loe=BS(function(e,i,n){i!=null&&typeof i.toString!="function"&&(i=doe.call(i)),e[i]=n},rc(wi)),XS=Object.prototype,goe=XS.hasOwnProperty,hoe=XS.toString,coe=BS(function(e,i,n){i!=null&&typeof i.toString!="function"&&(i=hoe.call(i)),goe.call(e,i)?e[i].push(n):e[i]=[n]},ie);function HS(e,i){return i.length<2?e:sa(e,qi(i,0,-1))}function Es(e,i,n){i=Co(i,e),e=HS(e,i);var o=e==null?e:e[rn(Ui(i))];return o==null?void 0:xi(o,e,n)}var poe=de(Es),voe=de(function(e,i,n){var o=-1,a=typeof i=="function",t=ji(e)?Array(e.length):[];return Jo(e,function(s){t[++o]=a?xi(i,s,n):Es(s,i,n)}),t}),yoe="[object ArrayBuffer]";function foe(e){return Ee(e)&&gi(e)==yoe}var P0=Ki&&Ki.isArrayBuffer,moe=P0?Ti(P0):foe,boe="[object Boolean]";function woe(e){return e===!0||e===!1||Ee(e)&&gi(e)==boe}var joe="[object Date]";function koe(e){return Ee(e)&&gi(e)==joe}var N0=Ki&&Ki.isDate,Soe=N0?Ti(N0):koe;function Loe(e){return Ee(e)&&e.nodeType===1&&!Ms(e)}var Coe="[object Map]",Yoe="[object Set]",$oe=Object.prototype,Zoe=$oe.hasOwnProperty;function Joe(e){if(e==null)return!0;if(ji(e)&&(ae(e)||typeof e=="string"||typeof e.splice=="function"||ho(e)||ut(e)||_o(e)))return!e.length;var i=bn(e);if(i==Coe||i==Yoe)return!e.size;if(Hs(e))return!gc(e).length;for(var n in e)if(Zoe.call(e,n))return!1;return!0}function xoe(e,i){return Ps(e,i)}function Toe(e,i,n){n=typeof n=="function"?n:void 0;var o=n?n(e,i):void 0;return o===void 0?Ps(e,i,void 0,n):!!o}var Doe=Ke.isFinite;function Boe(e){return typeof e=="number"&&Doe(e)}function MS(e){return typeof e=="number"&&e==re(e)}function Xoe(e,i){return e===i||$c(e,i,Zc(i))}function Hoe(e,i,n){return n=typeof n=="function"?n:void 0,$c(e,i,Zc(i),n)}var Moe="[object Number]";function PS(e){return typeof e=="number"||Ee(e)&&gi(e)==Moe}function Poe(e){return PS(e)&&e!=+e}var Noe=fr?Wn:lc,Eoe="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.";function Roe(e){if(Noe(e))throw new Error(Eoe);return Uk(e)}function Ooe(e){return e==null}function Aoe(e){return e===null}var Goe="[object RegExp]";function Foe(e){return Ee(e)&&gi(e)==Goe}var E0=Ki&&Ki.isRegExp,Rc=E0?Ti(E0):Foe,R0=9007199254740991;function Qoe(e){return MS(e)&&e>=-R0&&e<=R0}function Woe(e){return e===void 0}var Ioe="[object WeakMap]";function _oe(e){return Ee(e)&&bn(e)==Ioe}var zoe="[object WeakSet]";function Koe(e){return Ee(e)&&gi(e)==zoe}var qoe=1;function Uoe(e){return ie(typeof e=="function"?e:Gi(e,qoe))}var Voe=Array.prototype,eae=Voe.join;function iae(e,i){return e==null?"":eae.call(e,i)}var nae=lt(function(e,i,n){return e+(n?"-":"")+i.toLowerCase()}),oae=Ru(function(e,i,n){$n(e,n,i)});function aae(e,i,n){for(var o=n+1;o--;)if(e[o]===i)return o;return o}var tae=Math.max,sae=Math.min;function rae(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=o;return n!==void 0&&(a=re(n),a=a<0?tae(o+a,0):sae(a,o-1)),i===i?aae(e,i,a):xu(e,t1,a,!0)}var uae=lt(function(e,i,n){return e+(n?" ":"")+i.toLowerCase()}),dae=Y1("toLowerCase");function Oc(e,i){return e<i}var lae=Qu(Oc),gae=Qu(function(e,i){return e<=i});function hae(e,i){var n={};return i=ie(i),Jn(e,function(o,a,t){$n(n,i(o,a,t),o)}),n}function cae(e,i){var n={};return i=ie(i),Jn(e,function(o,a,t){$n(n,a,i(o,a,t))}),n}var pae=1;function vae(e){return tS(Gi(e,pae))}var yae=1;function fae(e,i){return rS(e,Gi(i,yae))}function Iu(e,i,n){for(var o=-1,a=e.length;++o<a;){var t=e[o],s=i(t);if(s!=null&&(r===void 0?s===s&&!Zi(s):n(s,r)))var r=s,u=t}return u}function mae(e){return e&&e.length?Iu(e,wi,Mc):void 0}function bae(e,i){return e&&e.length?Iu(e,ie(i),Mc):void 0}function Ac(e,i){for(var n,o=-1,a=e.length;++o<a;){var t=i(e[o]);t!==void 0&&(n=n===void 0?t:n+t)}return n}var wae=NaN;function NS(e,i){var n=e==null?0:e.length;return n?Ac(e,i)/n:wae}function jae(e){return NS(e,wi)}function kae(e,i){return NS(e,ie(i))}var Sae=rt(function(e,i,n){Ou(e,i,n)}),Lae=de(function(e,i){return function(n){return Es(n,e,i)}}),Cae=de(function(e,i){return function(n){return Es(e,n,i)}});function Yae(e){return e&&e.length?Iu(e,wi,Oc):void 0}function $ae(e,i){return e&&e.length?Iu(e,ie(i),Oc):void 0}function Zae(e,i,n){var o=qe(i),a=Fu(i,o),t=!(Pe(n)&&"chain"in n)||!!n.chain,s=Wn(e);return Xi(a,function(r){var u=i[r];e[r]=u,s&&(e.prototype[r]=function(){var d=this.__chain__;if(t||d){var l=e(this.__wrapped__),g=l.__actions__=yi(this.__actions__);return g.push({func:u,args:arguments,thisArg:e}),l.__chain__=d,l}return u.apply(e,Yo([this.value()],arguments))})}),e}var Jae=Zu(function(e,i){return e*i},1),xae="Expected a function";function _u(e){if(typeof e!="function")throw new TypeError(xae);return function(){var i=arguments;switch(i.length){case 0:return!e.call(this);case 1:return!e.call(this,i[0]);case 2:return!e.call(this,i[0],i[1]);case 3:return!e.call(this,i[0],i[1],i[2])}return!e.apply(this,i)}}function Tae(e){for(var i,n=[];!(i=e.next()).done;)n.push(i.value);return n}var Dae="[object Map]",Bae="[object Set]",el=ai?ai.iterator:void 0;function ES(e){if(!e)return[];if(ji(e))return Wu(e)?un(e):yi(e);if(el&&e[el])return Tae(e[el]());var i=bn(e),n=i==Dae?Yc:i==Bae?Eu:gt;return n(e)}function Xae(){this.__values__===void 0&&(this.__values__=ES(this.value()));var e=this.__index__>=this.__values__.length,i=e?void 0:this.__values__[this.__index__++];return{done:e,value:i}}function RS(e,i){var n=e.length;if(n)return i+=i<0?n:0,In(i,n)?e[i]:void 0}function Hae(e,i){return e&&e.length?RS(e,re(i)):void 0}function Mae(e){return e=re(e),de(function(i){return RS(i,e)})}var Pae=Object.prototype,Nae=Pae.hasOwnProperty;function Gc(e,i){i=Co(i,e);var n=-1,o=i.length;if(!o)return!0;for(;++n<o;){var a=rn(i[n]);if(a==="__proto__"&&!Nae.call(e,"__proto__")||(a==="constructor"||a==="prototype")&&n<o-1)return!1}var t=HS(e,i);return t==null||delete t[rn(Ui(i))]}function Eae(e){return Ms(e)?void 0:e}var Rae=1,Oae=2,Aae=4,Gae=qn(function(e,i){var n={};if(e==null)return n;var o=!1;i=Be(i,function(t){return t=Co(t,e),o||(o=t.length>1),t}),Zn(e,Sc(e),n),o&&(n=Gi(n,Rae|Oae|Aae,Eae));for(var a=i.length;a--;)Gc(n,i[a]);return n});function Rs(e,i,n,o){if(!Pe(e))return e;i=Co(i,e);for(var a=-1,t=i.length,s=t-1,r=e;r!=null&&++a<t;){var u=rn(i[a]),d=n;if(u==="__proto__"||u==="constructor"||u==="prototype")return e;if(a!=s){var l=r[u];d=o?o(l,u,r):void 0,d===void 0&&(d=Pe(l)?l:In(i[a+1])?[]:{})}Xs(r,u,d),r=r[u]}return e}function OS(e,i,n){for(var o=-1,a=i.length,t={};++o<a;){var s=i[o],r=sa(e,s);n(r,s)&&Rs(t,Co(s,e),r)}return t}function AS(e,i){if(e==null)return{};var n=Be(Sc(e),function(o){return[o]});return i=ie(i),OS(e,n,function(o,a){return i(o,a[0])})}function Fae(e,i){return AS(e,_u(ie(i)))}function Qae(e){return b1(2,e)}function Wae(e,i){var n=e.length;for(e.sort(i);n--;)e[n]=e[n].value;return e}function GS(e,i){if(e!==i){var n=e!==void 0,o=e===null,a=e===e,t=Zi(e),s=i!==void 0,r=i===null,u=i===i,d=Zi(i);if(!r&&!d&&!t&&e>i||t&&s&&u&&!r&&!d||o&&s&&u||!n&&u||!a)return 1;if(!o&&!t&&!d&&e<i||d&&n&&a&&!o&&!t||r&&n&&a||!s&&a||!u)return-1}return 0}function Iae(e,i,n){for(var o=-1,a=e.criteria,t=i.criteria,s=a.length,r=n.length;++o<s;){var u=GS(a[o],t[o]);if(u){if(o>=r)return u;var d=n[o];return u*(d=="desc"?-1:1)}}return e.index-i.index}function FS(e,i,n){i.length?i=Be(i,function(t){return ae(t)?function(s){return sa(s,t.length===1?t[0]:t)}:t}):i=[wi];var o=-1;i=Be(i,Ti(ie));var a=TS(e,function(t,s,r){var u=Be(i,function(d){return d(t)});return{criteria:u,index:++o,value:t}});return Wae(a,function(t,s){return Iae(t,s,n)})}function _ae(e,i,n,o){return e==null?[]:(ae(i)||(i=i==null?[]:[i]),n=o?void 0:n,ae(n)||(n=n==null?[]:[n]),FS(e,i,n))}function Fc(e){return qn(function(i){return i=Be(i,Ti(ie)),de(function(n){var o=this;return e(i,function(a){return xi(a,o,n)})})})}var zae=Fc(Be),Kae=de,qae=Math.min,Uae=Kae(function(e,i){i=i.length==1&&ae(i[0])?Be(i[0],Ti(ie)):Be(ei(i,1),Ti(ie));var n=i.length;return de(function(o){for(var a=-1,t=qae(o.length,n);++a<t;)o[a]=i[a].call(this,o[a]);return xi(e,this,o)})}),Vae=Fc(LS),ete=Fc(Cc),ite=9007199254740991,nte=Math.floor;function Sg(e,i){var n="";if(!e||i<1||i>ite)return n;do i%2&&(n+=e),i=nte(i/2),i&&(e+=e);while(i);return n}var ote=xc("length"),QS="\\ud800-\\udfff",ate="\\u0300-\\u036f",tte="\\ufe20-\\ufe2f",ste="\\u20d0-\\u20ff",rte=ate+tte+ste,ute="\\ufe0e\\ufe0f",dte="["+QS+"]",Lg="["+rte+"]",Cg="\\ud83c[\\udffb-\\udfff]",lte="(?:"+Lg+"|"+Cg+")",WS="[^"+QS+"]",IS="(?:\\ud83c[\\udde6-\\uddff]){2}",_S="[\\ud800-\\udbff][\\udc00-\\udfff]",gte="\\u200d",zS=lte+"?",KS="["+ute+"]?",hte="(?:"+gte+"(?:"+[WS,IS,_S].join("|")+")"+KS+zS+")*",cte=KS+zS+hte,pte="(?:"+[WS+Lg+"?",Lg,IS,_S,dte].join("|")+")",O0=RegExp(Cg+"(?="+Cg+")|"+pte+cte,"g");function vte(e){for(var i=O0.lastIndex=0;O0.test(e);)++i;return i}function ht(e){return dt(e)?vte(e):ote(e)}var yte=Math.ceil;function Ar(e,i){i=i===void 0?" ":Ji(i);var n=i.length;if(n<2)return n?Sg(i,e):i;var o=Sg(i,yte(e/ht(i)));return dt(i)?$o(un(o),0,e).join(""):o.slice(0,e)}var fte=Math.ceil,mte=Math.floor;function bte(e,i,n){e=be(e),i=re(i);var o=i?ht(e):0;if(!i||o>=i)return e;var a=(i-o)/2;return Ar(mte(a),n)+e+Ar(fte(a),n)}function wte(e,i,n){e=be(e),i=re(i);var o=i?ht(e):0;return i&&o<i?e+Ar(i-o,n):e}function jte(e,i,n){e=be(e),i=re(i);var o=i?ht(e):0;return i&&o<i?Ar(i-o,n)+e:e}var kte=/^\s+/,Ste=Ke.parseInt;function Lte(e,i,n){return n||i==null?i=0:i&&(i=+i),Ste(be(e).replace(kte,""),i||0)}var Cte=32,zu=de(function(e,i){var n=go(i,st(zu));return _n(e,Cte,void 0,i,n)});zu.placeholder={};var Yte=64,Qc=de(function(e,i){var n=go(i,st(Qc));return _n(e,Yte,void 0,i,n)});Qc.placeholder={};var $te=Ru(function(e,i,n){e[n?0:1].push(i)},function(){return[[],[]]});function Zte(e,i){return OS(e,i,function(n,o){return Jc(e,o)})}var Jte=qn(function(e,i){return e==null?{}:Zte(e,i)});function xte(e){for(var i,n=this;n instanceof Ju;){var o=n1(n);o.__index__=0,o.__values__=void 0,i?a.__wrapped__=o:i=o;var a=o;n=n.__wrapped__}return a.__wrapped__=e,i}function Tte(e){return function(i){return e==null?void 0:sa(e,i)}}function Dte(e,i,n,o){for(var a=n-1,t=e.length;++a<t;)if(o(e[a],i))return a;return-1}var Bte=Array.prototype,A0=Bte.splice;function Wc(e,i,n,o){var a=o?Dte:tt,t=-1,s=i.length,r=e;for(e===i&&(i=yi(i)),n&&(r=Be(e,Ti(n)));++t<s;)for(var u=0,d=i[t],l=n?n(d):d;(u=a(r,l,u,o))>-1;)r!==e&&A0.call(r,u,1),A0.call(e,u,1);return e}function qS(e,i){return e&&e.length&&i&&i.length?Wc(e,i):e}var Xte=de(qS);function Hte(e,i,n){return e&&e.length&&i&&i.length?Wc(e,i,ie(n)):e}function Mte(e,i,n){return e&&e.length&&i&&i.length?Wc(e,i,void 0,n):e}var Pte=Array.prototype,Nte=Pte.splice;function US(e,i){for(var n=e?i.length:0,o=n-1;n--;){var a=i[n];if(n==o||a!==t){var t=a;In(a)?Nte.call(e,a,1):Gc(e,a)}}return e}var Ete=qn(function(e,i){var n=e==null?0:e.length,o=pc(e,i);return US(e,Be(i,function(a){return In(a,n)?+a:a}).sort(GS)),o}),Rte=Math.floor,Ote=Math.random;function Ic(e,i){return e+Rte(Ote()*(i-e+1))}var Ate=parseFloat,Gte=Math.min,Fte=Math.random;function Qte(e,i,n){if(n&&typeof n!="boolean"&&ri(e,i,n)&&(i=n=void 0),n===void 0&&(typeof i=="boolean"?(n=i,i=void 0):typeof e=="boolean"&&(n=e,e=void 0)),e===void 0&&i===void 0?(e=0,i=1):(e=Nn(e),i===void 0?(i=e,e=0):i=Nn(i)),e>i){var o=e;e=i,i=o}if(n||e%1||i%1){var a=Fte();return Gte(e+a*(i-e+Ate("1e-"+((a+"").length-1))),i)}return Ic(e,i)}var Wte=Math.ceil,Ite=Math.max;function _te(e,i,n,o){for(var a=-1,t=Ite(Wte((i-e)/(n||1)),0),s=Array(t);t--;)s[o?t:++a]=e,e+=n;return s}function VS(e){return function(i,n,o){return o&&typeof o!="number"&&ri(i,n,o)&&(n=o=void 0),i=Nn(i),n===void 0?(n=i,i=0):n=Nn(n),o=o===void 0?i<n?1:-1:Nn(o),_te(i,n,o,e)}}var zte=VS(),Kte=VS(!0),qte=256,Ute=qn(function(e,i){return _n(e,qte,void 0,void 0,void 0,i)});function eL(e,i,n,o,a){return a(e,function(t,s,r){n=o?(o=!1,t):i(n,t,s,r)}),n}function Vte(e,i,n){var o=ae(e)?mc:eL,a=arguments.length<3;return o(e,ie(i),n,a,Jo)}function ese(e,i,n,o){var a=e==null?0:e.length;for(o&&a&&(n=e[--a]);a--;)n=i(n,e[a],a,e);return n}function ise(e,i,n){var o=ae(e)?ese:eL,a=arguments.length<3;return o(e,ie(i),n,a,bS)}function nse(e,i){var n=ae(e)?Zo:YS;return n(e,_u(ie(i)))}function ose(e,i){var n=[];if(!(e&&e.length))return n;var o=-1,a=[],t=e.length;for(i=ie(i);++o<t;){var s=e[o];i(s,o,e)&&(n.push(s),a.push(o))}return US(e,a),n}function ase(e,i,n){return(n?ri(e,i,n):i===void 0)?i=1:i=re(i),Sg(be(e),i)}function tse(){var e=arguments,i=be(e[0]);return e.length<3?i:i.replace(e[1],e[2])}var sse="Expected a function";function rse(e,i){if(typeof e!="function")throw new TypeError(sse);return i=i===void 0?i:re(i),de(e,i)}function use(e,i,n){i=Co(i,e);var o=-1,a=i.length;for(a||(a=1,e=void 0);++o<a;){var t=e?.[rn(i[o])];t===void 0&&(o=a,t=n),e=Wn(t)?t.call(e):t}return e}var dse=Array.prototype,lse=dse.reverse;function Yg(e){return e==null?e:lse.call(e)}var gse=wc("round");function iL(e){var i=e.length;return i?e[Ic(0,i-1)]:void 0}function hse(e){return iL(gt(e))}function cse(e){var i=ae(e)?iL:hse;return i(e)}function Ku(e,i){var n=-1,o=e.length,a=o-1;for(i=i===void 0?o:i;++n<i;){var t=Ic(n,a),s=e[t];e[t]=e[n],e[n]=s}return e.length=i,e}function pse(e,i){return Ku(yi(e),ra(i,0,e.length))}function vse(e,i){var n=gt(e);return Ku(n,ra(i,0,n.length))}function yse(e,i,n){(n?ri(e,i,n):i===void 0)?i=1:i=re(i);var o=ae(e)?pse:vse;return o(e,i)}function fse(e,i,n){return e==null?e:Rs(e,i,n)}function mse(e,i,n,o){return o=typeof o=="function"?o:void 0,e==null?e:Rs(e,i,n,o)}function bse(e){return Ku(yi(e))}function wse(e){return Ku(gt(e))}function jse(e){var i=ae(e)?bse:wse;return i(e)}var kse="[object Map]",Sse="[object Set]";function Lse(e){if(e==null)return 0;if(ji(e))return Wu(e)?ht(e):e.length;var i=bn(e);return i==kse||i==Sse?e.size:gc(e).length}function Cse(e,i,n){var o=e==null?0:e.length;return o?(n&&typeof n!="number"&&ri(e,i,n)?(i=0,n=o):(i=i==null?0:re(i),n=n===void 0?o:re(n)),qi(e,i,n)):[]}var Yse=lt(function(e,i,n){return e+(n?"_":"")+i.toLowerCase()});function $se(e,i){var n;return Jo(e,function(o,a,t){return n=i(o,a,t),!n}),!!n}function Zse(e,i,n){var o=ae(e)?Cc:$se;return n&&ri(e,i,n)&&(i=void 0),o(e,ie(i))}var Jse=de(function(e,i){if(e==null)return[];var n=i.length;return n>1&&ri(e,i[0],i[1])?i=[]:n>2&&ri(i[0],i[1],i[2])&&(i=[i[0]]),FS(e,ei(i,1),[])}),xse=4294967295,Tse=xse-1,Dse=Math.floor,Bse=Math.min;function _c(e,i,n,o){var a=0,t=e==null?0:e.length;if(t===0)return 0;i=n(i);for(var s=i!==i,r=i===null,u=Zi(i),d=i===void 0;a<t;){var l=Dse((a+t)/2),g=n(e[l]),h=g!==void 0,c=g===null,p=g===g,f=Zi(g);if(s)var w=o||p;else d?w=p&&(o||h):r?w=p&&h&&(o||!c):u?w=p&&h&&!c&&(o||!f):c||f?w=!1:w=o?g<=i:g<i;w?a=l+1:t=l}return Bse(t,Tse)}var Xse=4294967295,Hse=Xse>>>1;function qu(e,i,n){var o=0,a=e==null?o:e.length;if(typeof i=="number"&&i===i&&a<=Hse){for(;o<a;){var t=o+a>>>1,s=e[t];s!==null&&!Zi(s)&&(n?s<=i:s<i)?o=t+1:a=t}return a}return _c(e,i,wi,n)}function Mse(e,i){return qu(e,i)}function Pse(e,i,n){return _c(e,i,ie(n))}function Nse(e,i){var n=e==null?0:e.length;if(n){var o=qu(e,i);if(o<n&&ln(e[o],i))return o}return-1}function Ese(e,i){return qu(e,i,!0)}function Rse(e,i,n){return _c(e,i,ie(n),!0)}function Ose(e,i){var n=e==null?0:e.length;if(n){var o=qu(e,i,!0)-1;if(ln(e[o],i))return o}return-1}function nL(e,i){for(var n=-1,o=e.length,a=0,t=[];++n<o;){var s=e[n],r=i?i(s):s;if(!n||!ln(r,u)){var u=r;t[a++]=s===0?0:s}}return t}function Ase(e){return e&&e.length?nL(e):[]}function Gse(e,i){return e&&e.length?nL(e,ie(i)):[]}var Fse=4294967295;function Qse(e,i,n){return n&&typeof n!="number"&&ri(e,i,n)&&(i=n=void 0),n=n===void 0?Fse:n>>>0,n?(e=be(e),e&&(typeof i=="string"||i!=null&&!Rc(i))&&(i=Ji(i),!i&&dt(e))?$o(un(e),0,n):e.split(i,n)):[]}var Wse="Expected a function",Ise=Math.max;function _se(e,i){if(typeof e!="function")throw new TypeError(Wse);return i=i==null?0:Ise(re(i),0),de(function(n){var o=n[i],a=$o(n,0,i);return o&&Yo(a,o),xi(e,this,a)})}var zse=lt(function(e,i,n){return e+(n?" ":"")+fc(i)});function Kse(e,i,n){return e=be(e),n=n==null?0:ra(re(n),0,e.length),i=Ji(i),e.slice(n,n+i.length)==i}function qse(){return{}}function Use(){return""}function Vse(){return!0}var ere=Zu(function(e,i){return e-i},0);function ire(e){return e&&e.length?Ac(e,wi):0}function nre(e,i){return e&&e.length?Ac(e,ie(i)):0}function ore(e){var i=e==null?0:e.length;return i?qi(e,1,i):[]}function are(e,i,n){return e&&e.length?(i=n||i===void 0?1:re(i),qi(e,0,i<0?0:i)):[]}function tre(e,i,n){var o=e==null?0:e.length;return o?(i=n||i===void 0?1:re(i),i=o-i,qi(e,i<0?0:i,o)):[]}function sre(e,i){return e&&e.length?Au(e,ie(i),!1,!0):[]}function rre(e,i){return e&&e.length?Au(e,ie(i)):[]}function ure(e,i){return i(e),e}var oL=Object.prototype,dre=oL.hasOwnProperty;function G0(e,i,n,o){return e===void 0||ln(e,oL[n])&&!dre.call(o,n)?i:e}var lre={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};function gre(e){return"\\"+lre[e]}var aL=/<%=([\s\S]+?)%>/g,hre=/<%-([\s\S]+?)%>/g,cre=/<%([\s\S]+?)%>/g,$g={escape:hre,evaluate:cre,interpolate:aL,variable:"",imports:{_:{escape:kS}}},pre="Invalid `variable` option passed into `_.template`",vre="Invalid `imports` option passed into `_.template`",yre=/\b__p \+= '';/g,fre=/\b(__p \+=) '' \+/g,mre=/(__e\(.*?\)|\b__t\)) \+\n'';/g,F0=/[()=,{}\[\]\/\s]/,bre=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,ir=/($^)/,wre=/['\n\r\u2028\u2029\\]/g,jre=Object.prototype,Q0=jre.hasOwnProperty;function kre(e,i,n){var o=$g.imports._.templateSettings||$g;n&&ri(e,i,n)&&(i=void 0),e=be(e),i=vg({},i,o,G0);var a=vg({},i.imports,o.imports,G0),t=qe(a),s=Pc(a,t);Xi(t,function(w){if(F0.test(w))throw new Error(vre)});var r,u,d=0,l=i.interpolate||ir,g="__p += '",h=RegExp((i.escape||ir).source+"|"+l.source+"|"+(l===aL?bre:ir).source+"|"+(i.evaluate||ir).source+"|$","g"),c=Q0.call(i,"sourceURL")?"//# sourceURL="+(i.sourceURL+"").replace(/\s/g," ")+`
78
+ `)}function rc(e){return function(){return e}}var Rr=(function(){try{var e=ta(Object,"defineProperty");return e({},"",{}),e}catch{}})(),r5=Rr?function(e,i){return Rr(e,"toString",{configurable:!0,enumerable:!1,value:rc(i),writable:!0})}:wi,uc=oS(r5);function Xi(e,i){for(var n=-1,o=e==null?0:e.length;++n<o&&i(e[n],n,e)!==!1;);return e}function xu(e,i,n,o){for(var a=e.length,t=n+(o?1:-1);o?t--:++t<a;)if(i(e[t],t,e))return t;return-1}function tS(e){return e!==e}function u5(e,i,n){for(var o=n-1,a=e.length;++o<a;)if(e[o]===i)return o;return-1}function tt(e,i,n){return i===i?u5(e,i,n):xu(e,tS,n)}function Tu(e,i){var n=e==null?0:e.length;return!!n&&tt(e,i,0)>-1}var d5=1,l5=2,g5=8,h5=16,c5=32,p5=64,v5=128,y5=256,f5=512,m5=[["ary",v5],["bind",d5],["bindKey",l5],["curry",g5],["curryRight",h5],["flip",f5],["partial",c5],["partialRight",p5],["rearg",y5]];function b5(e,i){return Xi(m5,function(n){var o="_."+n[0];i&n[1]&&!Tu(e,o)&&e.push(o)}),e.sort()}function sS(e,i,n){var o=i+"";return uc(e,s5(o,b5(a5(o),n)))}var w5=4,j5=8,Vy=32,e0=64;function rS(e,i,n,o,a,t,s,r,u,d){var l=i&j5,g=l?s:void 0,h=l?void 0:s,c=l?t:void 0,p=l?void 0:t;i|=l?Vy:e0,i&=~(l?e0:Vy),i&w5||(i&=-4);var f=[e,i,a,c,g,p,h,r,u,d],w=n.apply(void 0,f);return pg(e)&&aS(w,f),w.placeholder=o,sS(w,e,i)}function st(e){var i=e;return i.placeholder}var k5=9007199254740991,S5=/^(?:0|[1-9]\d*)$/;function In(e,i){var n=typeof e;return i=i??k5,!!i&&(n=="number"||n!="symbol"&&S5.test(e))&&e>-1&&e%1==0&&e<i}var L5=Math.min;function C5(e,i){for(var n=e.length,o=L5(i.length,n),a=yi(e);o--;){var t=i[o];e[o]=In(t,n)?a[t]:void 0}return e}var i0="__lodash_placeholder__";function go(e,i){for(var n=-1,o=e.length,a=0,t=[];++n<o;){var s=e[n];(s===i||s===i0)&&(e[n]=i0,t[a++]=n)}return t}var Y5=1,$5=2,Z5=8,J5=16,x5=128,T5=512;function Du(e,i,n,o,a,t,s,r,u,d){var l=i&x5,g=i&Y5,h=i&$5,c=i&(Z5|J5),p=i&T5,f=h?void 0:vs(e);function w(){for(var v=arguments.length,j=Array(v),C=v;C--;)j[C]=arguments[C];if(c)var y=st(w),k=I9(j,y);if(o&&(j=eS(j,o,a,c)),t&&(j=iS(j,t,s,c)),v-=k,c&&v<d){var S=go(j,y);return rS(e,i,Du,w.placeholder,n,j,S,r,u,d-v)}var J=g?n:this,T=h?J[e]:e;return v=j.length,r?j=C5(j,r):p&&v>1&&j.reverse(),l&&u<v&&(j.length=u),this&&this!==Ke&&this instanceof w&&(T=f||vs(T)),T.apply(J,j)}return w}function D5(e,i,n){var o=vs(e);function a(){for(var t=arguments.length,s=Array(t),r=t,u=st(a);r--;)s[r]=arguments[r];var d=t<3&&s[0]!==u&&s[t-1]!==u?[]:go(s,u);if(t-=d.length,t<n)return rS(e,i,Du,a.placeholder,void 0,s,d,void 0,void 0,n-t);var l=this&&this!==Ke&&this instanceof a?o:e;return xi(l,this,s)}return a}var B5=1;function X5(e,i,n,o){var a=i&B5,t=vs(e);function s(){for(var r=-1,u=arguments.length,d=-1,l=o.length,g=Array(l+u),h=this&&this!==Ke&&this instanceof s?t:e;++d<l;)g[d]=o[d];for(;u--;)g[d++]=arguments[++r];return xi(h,a?n:this,g)}return s}var n0="__lodash_placeholder__",qd=1,H5=2,M5=4,o0=8,Pt=128,a0=256,P5=Math.min;function N5(e,i){var n=e[1],o=i[1],a=n|o,t=a<(qd|H5|Pt),s=o==Pt&&n==o0||o==Pt&&n==a0&&e[7].length<=i[8]||o==(Pt|a0)&&i[7].length<=i[8]&&n==o0;if(!(t||s))return e;o&qd&&(e[2]=i[2],a|=n&qd?0:M5);var r=i[3];if(r){var u=e[3];e[3]=u?eS(u,r,i[4]):r,e[4]=u?go(e[3],n0):i[4]}return r=i[5],r&&(u=e[5],e[5]=u?iS(u,r,i[6]):r,e[6]=u?go(e[5],n0):i[6]),r=i[7],r&&(e[7]=r),o&Pt&&(e[8]=e[8]==null?i[8]:P5(e[8],i[8])),e[9]==null&&(e[9]=i[9]),e[0]=i[0],e[1]=a,e}var E5="Expected a function",t0=1,R5=2,s0=8,r0=16,u0=32,O5=64,d0=Math.max;function _n(e,i,n,o,a,t,s,r){var u=i&R5;if(!u&&typeof e!="function")throw new TypeError(E5);var d=o?o.length:0;if(d||(i&=-97,o=a=void 0),s=s===void 0?s:d0(re(s),0),r=r===void 0?r:re(r),d-=a?a.length:0,i&O5){var l=o,g=a;o=a=void 0}var h=u?void 0:sc(e),c=[e,i,n,o,a,l,g,t,s,r];if(h&&N5(c,h),e=c[0],i=c[1],n=c[2],o=c[3],a=c[4],r=c[9]=c[9]===void 0?u?0:e.length:d0(c[9]-d,0),!r&&i&(s0|r0)&&(i&=-25),!i||i==t0)var p=F9(e,i,n);else i==s0||i==r0?p=D5(e,i,r):(i==u0||i==(t0|u0))&&!a.length?p=X5(e,i,n,o):p=Du.apply(void 0,c);var f=h?Vk:aS;return sS(f(p,c),e,i)}var A5=128;function uS(e,i,n){return i=n?void 0:i,i=e&&i==null?e.length:i,_n(e,A5,void 0,void 0,void 0,void 0,i)}function $n(e,i,n){i=="__proto__"&&Rr?Rr(e,i,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[i]=n}function ln(e,i){return e===i||e!==e&&i!==i}var G5=Object.prototype,F5=G5.hasOwnProperty;function Xs(e,i,n){var o=e[i];(!(F5.call(e,i)&&ln(o,n))||n===void 0&&!(i in e))&&$n(e,i,n)}function Zn(e,i,n,o){var a=!n;n||(n={});for(var t=-1,s=i.length;++t<s;){var r=i[t],u=o?o(n[r],e[r],r,n,e):void 0;u===void 0&&(u=e[r]),a?$n(n,r,u):Xs(n,r,u)}return n}var l0=Math.max;function dS(e,i,n){return i=l0(i===void 0?e.length-1:i,0),function(){for(var o=arguments,a=-1,t=l0(o.length-i,0),s=Array(t);++a<t;)s[a]=o[i+a];a=-1;for(var r=Array(i+1);++a<i;)r[a]=o[a];return r[i]=n(s),xi(e,this,r)}}function de(e,i){return uc(dS(e,i,wi),e+"")}var Q5=9007199254740991;function Bu(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Q5}function ji(e){return e!=null&&Bu(e.length)&&!Wn(e)}function ri(e,i,n){if(!Pe(n))return!1;var o=typeof i;return(o=="number"?ji(n)&&In(i,n.length):o=="string"&&i in n)?ln(n[i],e):!1}function rt(e){return de(function(i,n){var o=-1,a=n.length,t=a>1?n[a-1]:void 0,s=a>2?n[2]:void 0;for(t=e.length>3&&typeof t=="function"?(a--,t):void 0,s&&ri(n[0],n[1],s)&&(t=a<3?void 0:t,a=1),i=Object(i);++o<a;){var r=n[o];r&&e(i,r,o,t)}return i})}var W5=Object.prototype;function Hs(e){var i=e&&e.constructor,n=typeof i=="function"&&i.prototype||W5;return e===n}function dc(e,i){for(var n=-1,o=Array(e);++n<e;)o[n]=i(n);return o}var I5="[object Arguments]";function g0(e){return Ee(e)&&gi(e)==I5}var lS=Object.prototype,_5=lS.hasOwnProperty,z5=lS.propertyIsEnumerable,_o=g0((function(){return arguments})())?g0:function(e){return Ee(e)&&_5.call(e,"callee")&&!z5.call(e,"callee")};function lc(){return!1}var gS=typeof exports=="object"&&exports&&!exports.nodeType&&exports,h0=gS&&typeof module=="object"&&module&&!module.nodeType&&module,K5=h0&&h0.exports===gS,c0=K5?Ke.Buffer:void 0,q5=c0?c0.isBuffer:void 0,ho=q5||lc,U5="[object Arguments]",V5="[object Array]",e6="[object Boolean]",i6="[object Date]",n6="[object Error]",o6="[object Function]",a6="[object Map]",t6="[object Number]",s6="[object Object]",r6="[object RegExp]",u6="[object Set]",d6="[object String]",l6="[object WeakMap]",g6="[object ArrayBuffer]",h6="[object DataView]",c6="[object Float32Array]",p6="[object Float64Array]",v6="[object Int8Array]",y6="[object Int16Array]",f6="[object Int32Array]",m6="[object Uint8Array]",b6="[object Uint8ClampedArray]",w6="[object Uint16Array]",j6="[object Uint32Array]",Te={};Te[c6]=Te[p6]=Te[v6]=Te[y6]=Te[f6]=Te[m6]=Te[b6]=Te[w6]=Te[j6]=!0;Te[U5]=Te[V5]=Te[g6]=Te[e6]=Te[h6]=Te[i6]=Te[n6]=Te[o6]=Te[a6]=Te[t6]=Te[s6]=Te[r6]=Te[u6]=Te[d6]=Te[l6]=!1;function k6(e){return Ee(e)&&Bu(e.length)&&!!Te[gi(e)]}function Ti(e){return function(i){return e(i)}}var hS=typeof exports=="object"&&exports&&!exports.nodeType&&exports,es=hS&&typeof module=="object"&&module&&!module.nodeType&&module,S6=es&&es.exports===hS,Ud=S6&&_k.process,Ki=(function(){try{var e=es&&es.require&&es.require("util").types;return e||Ud&&Ud.binding&&Ud.binding("util")}catch{}})(),p0=Ki&&Ki.isTypedArray,ut=p0?Ti(p0):k6,L6=Object.prototype,C6=L6.hasOwnProperty;function cS(e,i){var n=ae(e),o=!n&&_o(e),a=!n&&!o&&ho(e),t=!n&&!o&&!a&&ut(e),s=n||o||a||t,r=s?dc(e.length,String):[],u=r.length;for(var d in e)(i||C6.call(e,d))&&!(s&&(d=="length"||a&&(d=="offset"||d=="parent")||t&&(d=="buffer"||d=="byteLength"||d=="byteOffset")||In(d,u)))&&r.push(d);return r}function pS(e,i){return function(n){return e(i(n))}}var Y6=pS(Object.keys,Object),$6=Object.prototype,Z6=$6.hasOwnProperty;function gc(e){if(!Hs(e))return Y6(e);var i=[];for(var n in Object(e))Z6.call(e,n)&&n!="constructor"&&i.push(n);return i}function qe(e){return ji(e)?cS(e):gc(e)}var J6=Object.prototype,x6=J6.hasOwnProperty,T6=rt(function(e,i){if(Hs(i)||ji(i)){Zn(i,qe(i),e);return}for(var n in i)x6.call(i,n)&&Xs(e,n,i[n])});function D6(e){var i=[];if(e!=null)for(var n in Object(e))i.push(n);return i}var B6=Object.prototype,X6=B6.hasOwnProperty;function H6(e){if(!Pe(e))return D6(e);var i=Hs(e),n=[];for(var o in e)o=="constructor"&&(i||!X6.call(e,o))||n.push(o);return n}function ki(e){return ji(e)?cS(e,!0):H6(e)}var M6=rt(function(e,i){Zn(i,ki(i),e)}),P6=rt(function(e,i,n,o){Zn(i,ki(i),e,o)}),vg=rt(function(e,i,n,o){Zn(i,qe(i),e,o)}),N6=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,E6=/^\w*$/;function hc(e,i){if(ae(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||Zi(e)?!0:E6.test(e)||!N6.test(e)||i!=null&&e in Object(i)}var ys=ta(Object,"create");function R6(){this.__data__=ys?ys(null):{},this.size=0}function O6(e){var i=this.has(e)&&delete this.__data__[e];return this.size-=i?1:0,i}var A6="__lodash_hash_undefined__",G6=Object.prototype,F6=G6.hasOwnProperty;function Q6(e){var i=this.__data__;if(ys){var n=i[e];return n===A6?void 0:n}return F6.call(i,e)?i[e]:void 0}var W6=Object.prototype,I6=W6.hasOwnProperty;function _6(e){var i=this.__data__;return ys?i[e]!==void 0:I6.call(i,e)}var z6="__lodash_hash_undefined__";function K6(e,i){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=ys&&i===void 0?z6:i,this}function zo(e){var i=-1,n=e==null?0:e.length;for(this.clear();++i<n;){var o=e[i];this.set(o[0],o[1])}}zo.prototype.clear=R6;zo.prototype.delete=O6;zo.prototype.get=Q6;zo.prototype.has=_6;zo.prototype.set=K6;function q6(){this.__data__=[],this.size=0}function Xu(e,i){for(var n=e.length;n--;)if(ln(e[n][0],i))return n;return-1}var U6=Array.prototype,V6=U6.splice;function eq(e){var i=this.__data__,n=Xu(i,e);if(n<0)return!1;var o=i.length-1;return n==o?i.pop():V6.call(i,n,1),--this.size,!0}function iq(e){var i=this.__data__,n=Xu(i,e);return n<0?void 0:i[n][1]}function nq(e){return Xu(this.__data__,e)>-1}function oq(e,i){var n=this.__data__,o=Xu(n,e);return o<0?(++this.size,n.push([e,i])):n[o][1]=i,this}function zn(e){var i=-1,n=e==null?0:e.length;for(this.clear();++i<n;){var o=e[i];this.set(o[0],o[1])}}zn.prototype.clear=q6;zn.prototype.delete=eq;zn.prototype.get=iq;zn.prototype.has=nq;zn.prototype.set=oq;var fs=ta(Ke,"Map");function aq(){this.size=0,this.__data__={hash:new zo,map:new(fs||zn),string:new zo}}function tq(e){var i=typeof e;return i=="string"||i=="number"||i=="symbol"||i=="boolean"?e!=="__proto__":e===null}function Hu(e,i){var n=e.__data__;return tq(i)?n[typeof i=="string"?"string":"hash"]:n.map}function sq(e){var i=Hu(this,e).delete(e);return this.size-=i?1:0,i}function rq(e){return Hu(this,e).get(e)}function uq(e){return Hu(this,e).has(e)}function dq(e,i){var n=Hu(this,e),o=n.size;return n.set(e,i),this.size+=n.size==o?0:1,this}function Kn(e){var i=-1,n=e==null?0:e.length;for(this.clear();++i<n;){var o=e[i];this.set(o[0],o[1])}}Kn.prototype.clear=aq;Kn.prototype.delete=sq;Kn.prototype.get=rq;Kn.prototype.has=uq;Kn.prototype.set=dq;var lq="Expected a function";function Mu(e,i){if(typeof e!="function"||i!=null&&typeof i!="function")throw new TypeError(lq);var n=function(){var o=arguments,a=i?i.apply(this,o):o[0],t=n.cache;if(t.has(a))return t.get(a);var s=e.apply(this,o);return n.cache=t.set(a,s)||t,s};return n.cache=new(Mu.Cache||Kn),n}Mu.Cache=Kn;var gq=500;function hq(e){var i=Mu(e,function(o){return n.size===gq&&n.clear(),o}),n=i.cache;return i}var cq=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,pq=/\\(\\)?/g,vS=hq(function(e){var i=[];return e.charCodeAt(0)===46&&i.push(""),e.replace(cq,function(n,o,a,t){i.push(a?t.replace(pq,"$1"):o||n)}),i});function be(e){return e==null?"":Ji(e)}function Co(e,i){return ae(e)?e:hc(e,i)?[e]:vS(be(e))}function rn(e){if(typeof e=="string"||Zi(e))return e;var i=e+"";return i=="0"&&1/e==-1/0?"-0":i}function sa(e,i){i=Co(i,e);for(var n=0,o=i.length;e!=null&&n<o;)e=e[rn(i[n++])];return n&&n==o?e:void 0}function cc(e,i,n){var o=e==null?void 0:sa(e,i);return o===void 0?n:o}function pc(e,i){for(var n=-1,o=i.length,a=Array(o),t=e==null;++n<o;)a[n]=t?void 0:cc(e,i[n]);return a}function Yo(e,i){for(var n=-1,o=i.length,a=e.length;++n<o;)e[a+n]=i[n];return e}var v0=ai?ai.isConcatSpreadable:void 0;function vq(e){return ae(e)||_o(e)||!!(v0&&e&&e[v0])}function ei(e,i,n,o,a){var t=-1,s=e.length;for(n||(n=vq),a||(a=[]);++t<s;){var r=e[t];i>0&&n(r)?i>1?ei(r,i-1,n,o,a):Yo(a,r):o||(a[a.length]=r)}return a}function yS(e){var i=e==null?0:e.length;return i?ei(e,1):[]}function qn(e){return uc(dS(e,void 0,yS),e+"")}var yq=qn(pc),Pu=pS(Object.getPrototypeOf,Object),fq="[object Object]",mq=Function.prototype,bq=Object.prototype,fS=mq.toString,wq=bq.hasOwnProperty,jq=fS.call(Object);function Ms(e){if(!Ee(e)||gi(e)!=fq)return!1;var i=Pu(e);if(i===null)return!0;var n=wq.call(i,"constructor")&&i.constructor;return typeof n=="function"&&n instanceof n&&fS.call(n)==jq}var kq="[object DOMException]",Sq="[object Error]";function vc(e){if(!Ee(e))return!1;var i=gi(e);return i==Sq||i==kq||typeof e.message=="string"&&typeof e.name=="string"&&!Ms(e)}var mS=de(function(e,i){try{return xi(e,void 0,i)}catch(n){return vc(n)?n:new Error(n)}}),Lq="Expected a function";function bS(e,i){var n;if(typeof i!="function")throw new TypeError(Lq);return e=re(e),function(){return--e>0&&(n=i.apply(this,arguments)),e<=1&&(i=void 0),n}}var Cq=1,Yq=32,Nu=de(function(e,i,n){var o=Cq;if(n.length){var a=go(n,st(Nu));o|=Yq}return _n(e,o,i,n,a)});Nu.placeholder={};var $q=qn(function(e,i){return Xi(i,function(n){n=rn(n),$n(e,n,Nu(e[n],e))}),e}),Zq=1,Jq=2,xq=32,yc=de(function(e,i,n){var o=Zq|Jq;if(n.length){var a=go(n,st(yc));o|=xq}return _n(i,o,e,n,a)});yc.placeholder={};function qi(e,i,n){var o=-1,a=e.length;i<0&&(i=-i>a?0:a+i),n=n>a?a:n,n<0&&(n+=a),a=i>n?0:n-i>>>0,i>>>=0;for(var t=Array(a);++o<a;)t[o]=e[o+i];return t}function $o(e,i,n){var o=e.length;return n=n===void 0?o:n,!i&&n>=o?e:qi(e,i,n)}var Tq="\\ud800-\\udfff",Dq="\\u0300-\\u036f",Bq="\\ufe20-\\ufe2f",Xq="\\u20d0-\\u20ff",Hq=Dq+Bq+Xq,Mq="\\ufe0e\\ufe0f",Pq="\\u200d",Nq=RegExp("["+Pq+Tq+Hq+Mq+"]");function dt(e){return Nq.test(e)}function Eq(e){return e.split("")}var wS="\\ud800-\\udfff",Rq="\\u0300-\\u036f",Oq="\\ufe20-\\ufe2f",Aq="\\u20d0-\\u20ff",Gq=Rq+Oq+Aq,Fq="\\ufe0e\\ufe0f",Qq="["+wS+"]",yg="["+Gq+"]",fg="\\ud83c[\\udffb-\\udfff]",Wq="(?:"+yg+"|"+fg+")",jS="[^"+wS+"]",kS="(?:\\ud83c[\\udde6-\\uddff]){2}",SS="[\\ud800-\\udbff][\\udc00-\\udfff]",Iq="\\u200d",LS=Wq+"?",CS="["+Fq+"]?",_q="(?:"+Iq+"(?:"+[jS,kS,SS].join("|")+")"+CS+LS+")*",zq=CS+LS+_q,Kq="(?:"+[jS+yg+"?",yg,kS,SS,Qq].join("|")+")",qq=RegExp(fg+"(?="+fg+")|"+Kq+zq,"g");function Uq(e){return e.match(qq)||[]}function un(e){return dt(e)?Uq(e):Eq(e)}function YS(e){return function(i){i=be(i);var n=dt(i)?un(i):void 0,o=n?n[0]:i.charAt(0),a=n?$o(n,1).join(""):i.slice(1);return o[e]()+a}}var fc=YS("toUpperCase");function $S(e){return fc(be(e).toLowerCase())}function mc(e,i,n,o){var a=-1,t=e==null?0:e.length;for(o&&t&&(n=e[++a]);++a<t;)n=i(n,e[a],a,e);return n}function bc(e){return function(i){return e?.[i]}}var Vq={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},eU=bc(Vq),iU=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,nU="\\u0300-\\u036f",oU="\\ufe20-\\ufe2f",aU="\\u20d0-\\u20ff",tU=nU+oU+aU,sU="["+tU+"]",rU=RegExp(sU,"g");function ZS(e){return e=be(e),e&&e.replace(iU,eU).replace(rU,"")}var uU=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function dU(e){return e.match(uU)||[]}var lU=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function gU(e){return lU.test(e)}var JS="\\ud800-\\udfff",hU="\\u0300-\\u036f",cU="\\ufe20-\\ufe2f",pU="\\u20d0-\\u20ff",vU=hU+cU+pU,xS="\\u2700-\\u27bf",TS="a-z\\xdf-\\xf6\\xf8-\\xff",yU="\\xac\\xb1\\xd7\\xf7",fU="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",mU="\\u2000-\\u206f",bU=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",DS="A-Z\\xc0-\\xd6\\xd8-\\xde",wU="\\ufe0e\\ufe0f",BS=yU+fU+mU+bU,XS="['’]",y0="["+BS+"]",jU="["+vU+"]",HS="\\d+",kU="["+xS+"]",MS="["+TS+"]",PS="[^"+JS+BS+HS+xS+TS+DS+"]",SU="\\ud83c[\\udffb-\\udfff]",LU="(?:"+jU+"|"+SU+")",CU="[^"+JS+"]",NS="(?:\\ud83c[\\udde6-\\uddff]){2}",ES="[\\ud800-\\udbff][\\udc00-\\udfff]",fa="["+DS+"]",YU="\\u200d",f0="(?:"+MS+"|"+PS+")",$U="(?:"+fa+"|"+PS+")",m0="(?:"+XS+"(?:d|ll|m|re|s|t|ve))?",b0="(?:"+XS+"(?:D|LL|M|RE|S|T|VE))?",RS=LU+"?",OS="["+wU+"]?",ZU="(?:"+YU+"(?:"+[CU,NS,ES].join("|")+")"+OS+RS+")*",JU="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",xU="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",TU=OS+RS+ZU,DU="(?:"+[kU,NS,ES].join("|")+")"+TU,BU=RegExp([fa+"?"+MS+"+"+m0+"(?="+[y0,fa,"$"].join("|")+")",$U+"+"+b0+"(?="+[y0,fa+f0,"$"].join("|")+")",fa+"?"+f0+"+"+m0,fa+"+"+b0,xU,JU,HS,DU].join("|"),"g");function XU(e){return e.match(BU)||[]}function AS(e,i,n){return e=be(e),i=n?void 0:i,i===void 0?gU(e)?XU(e):dU(e):e.match(i)||[]}var HU="['’]",MU=RegExp(HU,"g");function lt(e){return function(i){return mc(AS(ZS(i).replace(MU,"")),e,"")}}var PU=lt(function(e,i,n){return i=i.toLowerCase(),e+(n?$S(i):i)});function NU(){if(!arguments.length)return[];var e=arguments[0];return ae(e)?e:[e]}var EU=Ke.isFinite,RU=Math.min;function wc(e){var i=Math[e];return function(n,o){if(n=Ai(n),o=o==null?0:RU(re(o),292),o&&EU(n)){var a=(be(n)+"e").split("e"),t=i(a[0]+"e"+(+a[1]+o));return a=(be(t)+"e").split("e"),+(a[0]+"e"+(+a[1]-o))}return i(n)}}var OU=wc("ceil");function GS(e){var i=b(e);return i.__chain__=!0,i}var AU=Math.ceil,GU=Math.max;function FU(e,i,n){(n?ri(e,i,n):i===void 0)?i=1:i=GU(re(i),0);var o=e==null?0:e.length;if(!o||i<1)return[];for(var a=0,t=0,s=Array(AU(o/i));a<o;)s[t++]=qi(e,a,a+=i);return s}function ra(e,i,n){return e===e&&(n!==void 0&&(e=e<=n?e:n),i!==void 0&&(e=e>=i?e:i)),e}function QU(e,i,n){return n===void 0&&(n=i,i=void 0),n!==void 0&&(n=Ai(n),n=n===n?n:0),i!==void 0&&(i=Ai(i),i=i===i?i:0),ra(Ai(e),i,n)}function WU(){this.__data__=new zn,this.size=0}function IU(e){var i=this.__data__,n=i.delete(e);return this.size=i.size,n}function _U(e){return this.__data__.get(e)}function zU(e){return this.__data__.has(e)}var KU=200;function qU(e,i){var n=this.__data__;if(n instanceof zn){var o=n.__data__;if(!fs||o.length<KU-1)return o.push([e,i]),this.size=++n.size,this;n=this.__data__=new Kn(o)}return n.set(e,i),this.size=n.size,this}function on(e){var i=this.__data__=new zn(e);this.size=i.size}on.prototype.clear=WU;on.prototype.delete=IU;on.prototype.get=_U;on.prototype.has=zU;on.prototype.set=qU;function FS(e,i){return e&&Zn(i,qe(i),e)}function UU(e,i){return e&&Zn(i,ki(i),e)}var QS=typeof exports=="object"&&exports&&!exports.nodeType&&exports,w0=QS&&typeof module=="object"&&module&&!module.nodeType&&module,VU=w0&&w0.exports===QS,j0=VU?Ke.Buffer:void 0,k0=j0?j0.allocUnsafe:void 0;function WS(e,i){if(i)return e.slice();var n=e.length,o=k0?k0(n):new e.constructor(n);return e.copy(o),o}function Zo(e,i){for(var n=-1,o=e==null?0:e.length,a=0,t=[];++n<o;){var s=e[n];i(s,n,e)&&(t[a++]=s)}return t}function jc(){return[]}var eV=Object.prototype,iV=eV.propertyIsEnumerable,S0=Object.getOwnPropertySymbols,kc=S0?function(e){return e==null?[]:(e=Object(e),Zo(S0(e),function(i){return iV.call(e,i)}))}:jc;function nV(e,i){return Zn(e,kc(e),i)}var oV=Object.getOwnPropertySymbols,IS=oV?function(e){for(var i=[];e;)Yo(i,kc(e)),e=Pu(e);return i}:jc;function aV(e,i){return Zn(e,IS(e),i)}function _S(e,i,n){var o=i(e);return ae(e)?o:Yo(o,n(e))}function mg(e){return _S(e,qe,kc)}function Sc(e){return _S(e,ki,IS)}var bg=ta(Ke,"DataView"),wg=ta(Ke,"Promise"),Ba=ta(Ke,"Set"),L0="[object Map]",tV="[object Object]",C0="[object Promise]",Y0="[object Set]",$0="[object WeakMap]",Z0="[object DataView]",sV=aa(bg),rV=aa(fs),uV=aa(wg),dV=aa(Ba),lV=aa(ps),Xo=gi;(bg&&Xo(new bg(new ArrayBuffer(1)))!=Z0||fs&&Xo(new fs)!=L0||wg&&Xo(wg.resolve())!=C0||Ba&&Xo(new Ba)!=Y0||ps&&Xo(new ps)!=$0)&&(Xo=function(e){var i=gi(e),n=i==tV?e.constructor:void 0,o=n?aa(n):"";if(o)switch(o){case sV:return Z0;case rV:return L0;case uV:return C0;case dV:return Y0;case lV:return $0}return i});const bn=Xo;var gV=Object.prototype,hV=gV.hasOwnProperty;function cV(e){var i=e.length,n=new e.constructor(i);return i&&typeof e[0]=="string"&&hV.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var Or=Ke.Uint8Array;function Lc(e){var i=new e.constructor(e.byteLength);return new Or(i).set(new Or(e)),i}function pV(e,i){var n=i?Lc(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var vV=/\w*$/;function yV(e){var i=new e.constructor(e.source,vV.exec(e));return i.lastIndex=e.lastIndex,i}var J0=ai?ai.prototype:void 0,x0=J0?J0.valueOf:void 0;function fV(e){return x0?Object(x0.call(e)):{}}function zS(e,i){var n=i?Lc(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var mV="[object Boolean]",bV="[object Date]",wV="[object Map]",jV="[object Number]",kV="[object RegExp]",SV="[object Set]",LV="[object String]",CV="[object Symbol]",YV="[object ArrayBuffer]",$V="[object DataView]",ZV="[object Float32Array]",JV="[object Float64Array]",xV="[object Int8Array]",TV="[object Int16Array]",DV="[object Int32Array]",BV="[object Uint8Array]",XV="[object Uint8ClampedArray]",HV="[object Uint16Array]",MV="[object Uint32Array]";function PV(e,i,n){var o=e.constructor;switch(i){case YV:return Lc(e);case mV:case bV:return new o(+e);case $V:return pV(e,n);case ZV:case JV:case xV:case TV:case DV:case BV:case XV:case HV:case MV:return zS(e,n);case wV:return new o;case jV:case LV:return new o(e);case kV:return yV(e);case SV:return new o;case CV:return fV(e)}}function KS(e){return typeof e.constructor=="function"&&!Hs(e)?at(Pu(e)):{}}var NV="[object Map]";function EV(e){return Ee(e)&&bn(e)==NV}var T0=Ki&&Ki.isMap,qS=T0?Ti(T0):EV,RV="[object Set]";function OV(e){return Ee(e)&&bn(e)==RV}var D0=Ki&&Ki.isSet,US=D0?Ti(D0):OV,AV=1,GV=2,FV=4,VS="[object Arguments]",QV="[object Array]",WV="[object Boolean]",IV="[object Date]",_V="[object Error]",e1="[object Function]",zV="[object GeneratorFunction]",KV="[object Map]",qV="[object Number]",i1="[object Object]",UV="[object RegExp]",VV="[object Set]",eee="[object String]",iee="[object Symbol]",nee="[object WeakMap]",oee="[object ArrayBuffer]",aee="[object DataView]",tee="[object Float32Array]",see="[object Float64Array]",ree="[object Int8Array]",uee="[object Int16Array]",dee="[object Int32Array]",lee="[object Uint8Array]",gee="[object Uint8ClampedArray]",hee="[object Uint16Array]",cee="[object Uint32Array]",Ze={};Ze[VS]=Ze[QV]=Ze[oee]=Ze[aee]=Ze[WV]=Ze[IV]=Ze[tee]=Ze[see]=Ze[ree]=Ze[uee]=Ze[dee]=Ze[KV]=Ze[qV]=Ze[i1]=Ze[UV]=Ze[VV]=Ze[eee]=Ze[iee]=Ze[lee]=Ze[gee]=Ze[hee]=Ze[cee]=!0;Ze[_V]=Ze[e1]=Ze[nee]=!1;function Gi(e,i,n,o,a,t){var s,r=i&AV,u=i&GV,d=i&FV;if(n&&(s=a?n(e,o,a,t):n(e)),s!==void 0)return s;if(!Pe(e))return e;var l=ae(e);if(l){if(s=cV(e),!r)return yi(e,s)}else{var g=bn(e),h=g==e1||g==zV;if(ho(e))return WS(e,r);if(g==i1||g==VS||h&&!a){if(s=u||h?{}:KS(e),!r)return u?aV(e,UU(s,e)):nV(e,FS(s,e))}else{if(!Ze[g])return a?e:{};s=PV(e,g,r)}}t||(t=new on);var c=t.get(e);if(c)return c;t.set(e,s),US(e)?e.forEach(function(w){s.add(Gi(w,i,n,w,e,t))}):qS(e)&&e.forEach(function(w,v){s.set(v,Gi(w,i,n,v,e,t))});var p=d?u?Sc:mg:u?ki:qe,f=l?void 0:p(e);return Xi(f||e,function(w,v){f&&(v=w,w=e[v]),Xs(s,v,Gi(w,i,n,v,e,t))}),s}var pee=4;function vee(e){return Gi(e,pee)}var yee=1,fee=4;function mee(e){return Gi(e,yee|fee)}var bee=1,wee=4;function jee(e,i){return i=typeof i=="function"?i:void 0,Gi(e,bee|wee,i)}var kee=4;function See(e,i){return i=typeof i=="function"?i:void 0,Gi(e,kee,i)}function Lee(){return new zi(this.value(),this.__chain__)}function Cee(e){for(var i=-1,n=e==null?0:e.length,o=0,a=[];++i<n;){var t=e[i];t&&(a[o++]=t)}return a}function Yee(){var e=arguments.length;if(!e)return[];for(var i=Array(e-1),n=arguments[0],o=e;o--;)i[o-1]=arguments[o];return Yo(ae(n)?yi(n):[n],ei(i,1))}var $ee="__lodash_hash_undefined__";function Zee(e){return this.__data__.set(e,$ee),this}function Jee(e){return this.__data__.has(e)}function Ko(e){var i=-1,n=e==null?0:e.length;for(this.__data__=new Kn;++i<n;)this.add(e[i])}Ko.prototype.add=Ko.prototype.push=Zee;Ko.prototype.has=Jee;function Cc(e,i){for(var n=-1,o=e==null?0:e.length;++n<o;)if(i(e[n],n,e))return!0;return!1}function ms(e,i){return e.has(i)}var xee=1,Tee=2;function n1(e,i,n,o,a,t){var s=n&xee,r=e.length,u=i.length;if(r!=u&&!(s&&u>r))return!1;var d=t.get(e),l=t.get(i);if(d&&l)return d==i&&l==e;var g=-1,h=!0,c=n&Tee?new Ko:void 0;for(t.set(e,i),t.set(i,e);++g<r;){var p=e[g],f=i[g];if(o)var w=s?o(f,p,g,i,e,t):o(p,f,g,e,i,t);if(w!==void 0){if(w)continue;h=!1;break}if(c){if(!Cc(i,function(v,j){if(!ms(c,j)&&(p===v||a(p,v,n,o,t)))return c.push(j)})){h=!1;break}}else if(!(p===f||a(p,f,n,o,t))){h=!1;break}}return t.delete(e),t.delete(i),h}function Yc(e){var i=-1,n=Array(e.size);return e.forEach(function(o,a){n[++i]=[a,o]}),n}function Eu(e){var i=-1,n=Array(e.size);return e.forEach(function(o){n[++i]=o}),n}var Dee=1,Bee=2,Xee="[object Boolean]",Hee="[object Date]",Mee="[object Error]",Pee="[object Map]",Nee="[object Number]",Eee="[object RegExp]",Ree="[object Set]",Oee="[object String]",Aee="[object Symbol]",Gee="[object ArrayBuffer]",Fee="[object DataView]",B0=ai?ai.prototype:void 0,Vd=B0?B0.valueOf:void 0;function Qee(e,i,n,o,a,t,s){switch(n){case Fee:if(e.byteLength!=i.byteLength||e.byteOffset!=i.byteOffset)return!1;e=e.buffer,i=i.buffer;case Gee:return!(e.byteLength!=i.byteLength||!t(new Or(e),new Or(i)));case Xee:case Hee:case Nee:return ln(+e,+i);case Mee:return e.name==i.name&&e.message==i.message;case Eee:case Oee:return e==i+"";case Pee:var r=Yc;case Ree:var u=o&Dee;if(r||(r=Eu),e.size!=i.size&&!u)return!1;var d=s.get(e);if(d)return d==i;o|=Bee,s.set(e,i);var l=n1(r(e),r(i),o,a,t,s);return s.delete(e),l;case Aee:if(Vd)return Vd.call(e)==Vd.call(i)}return!1}var Wee=1,Iee=Object.prototype,_ee=Iee.hasOwnProperty;function zee(e,i,n,o,a,t){var s=n&Wee,r=mg(e),u=r.length,d=mg(i),l=d.length;if(u!=l&&!s)return!1;for(var g=u;g--;){var h=r[g];if(!(s?h in i:_ee.call(i,h)))return!1}var c=t.get(e),p=t.get(i);if(c&&p)return c==i&&p==e;var f=!0;t.set(e,i),t.set(i,e);for(var w=s;++g<u;){h=r[g];var v=e[h],j=i[h];if(o)var C=s?o(j,v,h,i,e,t):o(v,j,h,e,i,t);if(!(C===void 0?v===j||a(v,j,n,o,t):C)){f=!1;break}w||(w=h=="constructor")}if(f&&!w){var y=e.constructor,k=i.constructor;y!=k&&"constructor"in e&&"constructor"in i&&!(typeof y=="function"&&y instanceof y&&typeof k=="function"&&k instanceof k)&&(f=!1)}return t.delete(e),t.delete(i),f}var Kee=1,X0="[object Arguments]",H0="[object Array]",er="[object Object]",qee=Object.prototype,M0=qee.hasOwnProperty;function Uee(e,i,n,o,a,t){var s=ae(e),r=ae(i),u=s?H0:bn(e),d=r?H0:bn(i);u=u==X0?er:u,d=d==X0?er:d;var l=u==er,g=d==er,h=u==d;if(h&&ho(e)){if(!ho(i))return!1;s=!0,l=!1}if(h&&!l)return t||(t=new on),s||ut(e)?n1(e,i,n,o,a,t):Qee(e,i,u,n,o,a,t);if(!(n&Kee)){var c=l&&M0.call(e,"__wrapped__"),p=g&&M0.call(i,"__wrapped__");if(c||p){var f=c?e.value():e,w=p?i.value():i;return t||(t=new on),a(f,w,n,o,t)}}return h?(t||(t=new on),zee(e,i,n,o,a,t)):!1}function Ps(e,i,n,o,a){return e===i?!0:e==null||i==null||!Ee(e)&&!Ee(i)?e!==e&&i!==i:Uee(e,i,n,o,Ps,a)}var Vee=1,eie=2;function $c(e,i,n,o){var a=n.length,t=a,s=!o;if(e==null)return!t;for(e=Object(e);a--;){var r=n[a];if(s&&r[2]?r[1]!==e[r[0]]:!(r[0]in e))return!1}for(;++a<t;){r=n[a];var u=r[0],d=e[u],l=r[1];if(s&&r[2]){if(d===void 0&&!(u in e))return!1}else{var g=new on;if(o)var h=o(d,l,u,e,i,g);if(!(h===void 0?Ps(l,d,Vee|eie,o,g):h))return!1}}return!0}function o1(e){return e===e&&!Pe(e)}function Zc(e){for(var i=qe(e),n=i.length;n--;){var o=i[n],a=e[o];i[n]=[o,a,o1(a)]}return i}function a1(e,i){return function(n){return n==null?!1:n[e]===i&&(i!==void 0||e in Object(n))}}function t1(e){var i=Zc(e);return i.length==1&&i[0][2]?a1(i[0][0],i[0][1]):function(n){return n===e||$c(n,e,i)}}function iie(e,i){return e!=null&&i in Object(e)}function s1(e,i,n){i=Co(i,e);for(var o=-1,a=i.length,t=!1;++o<a;){var s=rn(i[o]);if(!(t=e!=null&&n(e,s)))break;e=e[s]}return t||++o!=a?t:(a=e==null?0:e.length,!!a&&Bu(a)&&In(s,a)&&(ae(e)||_o(e)))}function Jc(e,i){return e!=null&&s1(e,i,iie)}var nie=1,oie=2;function r1(e,i){return hc(e)&&o1(i)?a1(rn(e),i):function(n){var o=cc(n,e);return o===void 0&&o===i?Jc(n,e):Ps(i,o,nie|oie)}}function xc(e){return function(i){return i?.[e]}}function aie(e){return function(i){return sa(i,e)}}function u1(e){return hc(e)?xc(rn(e)):aie(e)}function ie(e){return typeof e=="function"?e:e==null?wi:typeof e=="object"?ae(e)?r1(e[0],e[1]):t1(e):u1(e)}var tie="Expected a function";function sie(e){var i=e==null?0:e.length,n=ie;return e=i?Be(e,function(o){if(typeof o[1]!="function")throw new TypeError(tie);return[n(o[0]),o[1]]}):[],de(function(o){for(var a=-1;++a<i;){var t=e[a];if(xi(t[0],this,o))return xi(t[1],this,o)}})}function d1(e,i,n){var o=n.length;if(e==null)return!o;for(e=Object(e);o--;){var a=n[o],t=i[a],s=e[a];if(s===void 0&&!(a in e)||!t(s))return!1}return!0}function rie(e){var i=qe(e);return function(n){return d1(n,e,i)}}var uie=1;function die(e){return rie(Gi(e,uie))}function lie(e,i){return i==null||d1(e,i,qe(i))}function gie(e,i,n,o){for(var a=-1,t=e==null?0:e.length;++a<t;){var s=e[a];i(o,s,n(s),e)}return o}function l1(e){return function(i,n,o){for(var a=-1,t=Object(i),s=o(i),r=s.length;r--;){var u=s[e?r:++a];if(n(t[u],u,t)===!1)break}return i}}var Tc=l1();function Jn(e,i){return e&&Tc(e,i,qe)}function g1(e,i){return function(n,o){if(n==null)return n;if(!ji(n))return e(n,o);for(var a=n.length,t=i?a:-1,s=Object(n);(i?t--:++t<a)&&o(s[t],t,s)!==!1;);return n}}var Jo=g1(Jn);function hie(e,i,n,o){return Jo(e,function(a,t,s){i(o,a,n(a),s)}),o}function Ru(e,i){return function(n,o){var a=ae(n)?gie:hie,t=i?i():{};return a(n,e,ie(o),t)}}var cie=Object.prototype,pie=cie.hasOwnProperty,vie=Ru(function(e,i,n){pie.call(e,n)?++e[n]:$n(e,n,1)});function yie(e,i){var n=at(e);return i==null?n:FS(n,i)}var fie=8;function Dc(e,i,n){i=n?void 0:i;var o=_n(e,fie,void 0,void 0,void 0,void 0,void 0,i);return o.placeholder=Dc.placeholder,o}Dc.placeholder={};var mie=16;function Bc(e,i,n){i=n?void 0:i;var o=_n(e,mie,void 0,void 0,void 0,void 0,void 0,i);return o.placeholder=Bc.placeholder,o}Bc.placeholder={};var br=function(){return Ke.Date.now()},bie="Expected a function",wie=Math.max,jie=Math.min;function h1(e,i,n){var o,a,t,s,r,u,d=0,l=!1,g=!1,h=!0;if(typeof e!="function")throw new TypeError(bie);i=Ai(i)||0,Pe(n)&&(l=!!n.leading,g="maxWait"in n,t=g?wie(Ai(n.maxWait)||0,i):t,h="trailing"in n?!!n.trailing:h);function c(S){var J=o,T=a;return o=a=void 0,d=S,s=e.apply(T,J),s}function p(S){return d=S,r=setTimeout(v,i),l?c(S):s}function f(S){var J=S-u,T=S-d,M=i-J;return g?jie(M,t-T):M}function w(S){var J=S-u,T=S-d;return u===void 0||J>=i||J<0||g&&T>=t}function v(){var S=br();if(w(S))return j(S);r=setTimeout(v,f(S))}function j(S){return r=void 0,h&&o?c(S):(o=a=void 0,s)}function C(){r!==void 0&&clearTimeout(r),d=0,o=u=a=r=void 0}function y(){return r===void 0?s:j(br())}function k(){var S=br(),J=w(S);if(o=arguments,a=this,u=S,J){if(r===void 0)return p(u);if(g)return clearTimeout(r),r=setTimeout(v,i),c(u)}return r===void 0&&(r=setTimeout(v,i)),s}return k.cancel=C,k.flush=y,k}function kie(e,i){return e==null||e!==e?i:e}var c1=Object.prototype,Sie=c1.hasOwnProperty,Lie=de(function(e,i){e=Object(e);var n=-1,o=i.length,a=o>2?i[2]:void 0;for(a&&ri(i[0],i[1],a)&&(o=1);++n<o;)for(var t=i[n],s=ki(t),r=-1,u=s.length;++r<u;){var d=s[r],l=e[d];(l===void 0||ln(l,c1[d])&&!Sie.call(e,d))&&(e[d]=t[d])}return e});function jg(e,i,n){(n!==void 0&&!ln(e[i],n)||n===void 0&&!(i in e))&&$n(e,i,n)}function Fe(e){return Ee(e)&&ji(e)}function kg(e,i){if(!(i==="constructor"&&typeof e[i]=="function")&&i!="__proto__")return e[i]}function p1(e){return Zn(e,ki(e))}function Cie(e,i,n,o,a,t,s){var r=kg(e,n),u=kg(i,n),d=s.get(u);if(d){jg(e,n,d);return}var l=t?t(r,u,n+"",e,i,s):void 0,g=l===void 0;if(g){var h=ae(u),c=!h&&ho(u),p=!h&&!c&&ut(u);l=u,h||c||p?ae(r)?l=r:Fe(r)?l=yi(r):c?(g=!1,l=WS(u,!0)):p?(g=!1,l=zS(u,!0)):l=[]:Ms(u)||_o(u)?(l=r,_o(r)?l=p1(r):(!Pe(r)||Wn(r))&&(l=KS(u))):g=!1}g&&(s.set(u,l),a(l,u,o,t,s),s.delete(u)),jg(e,n,l)}function Ou(e,i,n,o,a){e!==i&&Tc(i,function(t,s){if(a||(a=new on),Pe(t))Cie(e,i,s,n,Ou,o,a);else{var r=o?o(kg(e,s),t,s+"",e,i,a):void 0;r===void 0&&(r=t),jg(e,s,r)}},ki)}function v1(e,i,n,o,a,t){return Pe(e)&&Pe(i)&&(t.set(i,e),Ou(e,i,void 0,v1,t),t.delete(i)),e}var y1=rt(function(e,i,n,o){Ou(e,i,n,o)}),Yie=de(function(e){return e.push(void 0,v1),xi(y1,void 0,e)}),$ie="Expected a function";function f1(e,i,n){if(typeof e!="function")throw new TypeError($ie);return setTimeout(function(){e.apply(void 0,n)},i)}var Zie=de(function(e,i){return f1(e,1,i)}),Jie=de(function(e,i,n){return f1(e,Ai(i)||0,n)});function Xc(e,i,n){for(var o=-1,a=e==null?0:e.length;++o<a;)if(n(i,e[o]))return!0;return!1}var xie=200;function Ns(e,i,n,o){var a=-1,t=Tu,s=!0,r=e.length,u=[],d=i.length;if(!r)return u;n&&(i=Be(i,Ti(n))),o?(t=Xc,s=!1):i.length>=xie&&(t=ms,s=!1,i=new Ko(i));e:for(;++a<r;){var l=e[a],g=n==null?l:n(l);if(l=o||l!==0?l:0,s&&g===g){for(var h=d;h--;)if(i[h]===g)continue e;u.push(l)}else t(i,g,o)||u.push(l)}return u}var Tie=de(function(e,i){return Fe(e)?Ns(e,ei(i,1,Fe,!0)):[]});function Ui(e){var i=e==null?0:e.length;return i?e[i-1]:void 0}var Die=de(function(e,i){var n=Ui(i);return Fe(n)&&(n=void 0),Fe(e)?Ns(e,ei(i,1,Fe,!0),ie(n)):[]}),Bie=de(function(e,i){var n=Ui(i);return Fe(n)&&(n=void 0),Fe(e)?Ns(e,ei(i,1,Fe,!0),void 0,n):[]}),Xie=Zu(function(e,i){return e/i},1);function Hie(e,i,n){var o=e==null?0:e.length;return o?(i=n||i===void 0?1:re(i),qi(e,i<0?0:i,o)):[]}function Mie(e,i,n){var o=e==null?0:e.length;return o?(i=n||i===void 0?1:re(i),i=o-i,qi(e,0,i<0?0:i)):[]}function Au(e,i,n,o){for(var a=e.length,t=o?a:-1;(o?t--:++t<a)&&i(e[t],t,e););return n?qi(e,o?0:t,o?t+1:a):qi(e,o?t+1:0,o?a:t)}function Pie(e,i){return e&&e.length?Au(e,ie(i),!0,!0):[]}function Nie(e,i){return e&&e.length?Au(e,ie(i),!0):[]}function xn(e){return typeof e=="function"?e:wi}function Eie(e,i){var n=ae(e)?Xi:Jo;return n(e,xn(i))}function Rie(e,i){for(var n=e==null?0:e.length;n--&&i(e[n],n,e)!==!1;);return e}var m1=l1(!0);function Hc(e,i){return e&&m1(e,i,qe)}var b1=g1(Hc,!0);function Oie(e,i){var n=ae(e)?Rie:b1;return n(e,xn(i))}function Aie(e,i,n){e=be(e),i=Ji(i);var o=e.length;n=n===void 0?o:ra(re(n),0,o);var a=n;return n-=i.length,n>=0&&e.slice(n,a)==i}function Gie(e,i){return Be(i,function(n){return[n,e[n]]})}function Fie(e){var i=-1,n=Array(e.size);return e.forEach(function(o){n[++i]=[o,o]}),n}var Qie="[object Map]",Wie="[object Set]";function w1(e){return function(i){var n=bn(i);return n==Qie?Yc(i):n==Wie?Fie(i):Gie(i,e(i))}}var Iie=w1(qe),_ie=w1(ki),zie={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},Kie=bc(zie),j1=/[&<>"']/g,qie=RegExp(j1.source);function k1(e){return e=be(e),e&&qie.test(e)?e.replace(j1,Kie):e}var S1=/[\\^$.*+?()[\]{}|]/g,Uie=RegExp(S1.source);function Vie(e){return e=be(e),e&&Uie.test(e)?e.replace(S1,"\\$&"):e}function L1(e,i){for(var n=-1,o=e==null?0:e.length;++n<o;)if(!i(e[n],n,e))return!1;return!0}function ene(e,i){var n=!0;return Jo(e,function(o,a,t){return n=!!i(o,a,t),n}),n}function ine(e,i,n){var o=ae(e)?L1:ene;return n&&ri(e,i,n)&&(i=void 0),o(e,ie(i))}var nne=4294967295;function C1(e){return e?ra(re(e),0,nne):0}function one(e,i,n,o){var a=e.length;for(n=re(n),n<0&&(n=-n>a?0:a+n),o=o===void 0||o>a?a:re(o),o<0&&(o+=a),o=n>o?0:C1(o);n<o;)e[n++]=i;return e}function ane(e,i,n,o){var a=e==null?0:e.length;return a?(n&&typeof n!="number"&&ri(e,i,n)&&(n=0,o=a),one(e,i,n,o)):[]}function Y1(e,i){var n=[];return Jo(e,function(o,a,t){i(o,a,t)&&n.push(o)}),n}function tne(e,i){var n=ae(e)?Zo:Y1;return n(e,ie(i))}function $1(e){return function(i,n,o){var a=Object(i);if(!ji(i)){var t=ie(n);i=qe(i),n=function(r){return t(a[r],r,a)}}var s=e(i,n,o);return s>-1?a[t?i[s]:s]:void 0}}var sne=Math.max;function Z1(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=n==null?0:re(n);return a<0&&(a=sne(o+a,0)),xu(e,ie(i),a)}var rne=$1(Z1);function J1(e,i,n){var o;return n(e,function(a,t,s){if(i(a,t,s))return o=t,!1}),o}function une(e,i){return J1(e,ie(i),Jn)}var dne=Math.max,lne=Math.min;function x1(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=o-1;return n!==void 0&&(a=re(n),a=n<0?dne(o+a,0):lne(a,o-1)),xu(e,ie(i),a,!0)}var gne=$1(x1);function hne(e,i){return J1(e,ie(i),Hc)}function cne(e){return e&&e.length?e[0]:void 0}function T1(e,i){var n=-1,o=ji(e)?Array(e.length):[];return Jo(e,function(a,t,s){o[++n]=i(a,t,s)}),o}function Gu(e,i){var n=ae(e)?Be:T1;return n(e,ie(i))}function pne(e,i){return ei(Gu(e,i),1)}var vne=1/0;function yne(e,i){return ei(Gu(e,i),vne)}function fne(e,i,n){return n=n===void 0?1:re(n),ei(Gu(e,i),n)}var mne=1/0;function bne(e){var i=e==null?0:e.length;return i?ei(e,mne):[]}function wne(e,i){var n=e==null?0:e.length;return n?(i=i===void 0?1:re(i),ei(e,i)):[]}var jne=512;function kne(e){return _n(e,jne)}var Sne=wc("floor"),Lne="Expected a function",Cne=8,Yne=32,$ne=128,Zne=256;function D1(e){return qn(function(i){var n=i.length,o=n,a=zi.prototype.thru;for(e&&i.reverse();o--;){var t=i[o];if(typeof t!="function")throw new TypeError(Lne);if(a&&!s&&mr(t)=="wrapper")var s=new zi([],!0)}for(o=s?o:n;++o<n;){t=i[o];var r=mr(t),u=r=="wrapper"?sc(t):void 0;u&&pg(u[0])&&u[1]==($ne|Cne|Yne|Zne)&&!u[4].length&&u[9]==1?s=s[mr(u[0])].apply(s,u[3]):s=t.length==1&&pg(t)?s[r]():s.thru(t)}return function(){var d=arguments,l=d[0];if(s&&d.length==1&&ae(l))return s.plant(l).value();for(var g=0,h=n?i[g].apply(this,d):l;++g<n;)h=i[g].call(this,h);return h}})}var Jne=D1(),xne=D1(!0);function Tne(e,i){return e==null?e:Tc(e,xn(i),ki)}function Dne(e,i){return e==null?e:m1(e,xn(i),ki)}function Bne(e,i){return e&&Jn(e,xn(i))}function Xne(e,i){return e&&Hc(e,xn(i))}function Hne(e){for(var i=-1,n=e==null?0:e.length,o={};++i<n;){var a=e[i];$n(o,a[0],a[1])}return o}function Fu(e,i){return Zo(i,function(n){return Wn(e[n])})}function Mne(e){return e==null?[]:Fu(e,qe(e))}function Pne(e){return e==null?[]:Fu(e,ki(e))}var Nne=Object.prototype,Ene=Nne.hasOwnProperty,Rne=Ru(function(e,i,n){Ene.call(e,n)?e[n].push(i):$n(e,n,[i])});function Mc(e,i){return e>i}function Qu(e){return function(i,n){return typeof i=="string"&&typeof n=="string"||(i=Ai(i),n=Ai(n)),e(i,n)}}var One=Qu(Mc),Ane=Qu(function(e,i){return e>=i}),Gne=Object.prototype,Fne=Gne.hasOwnProperty;function Qne(e,i){return e!=null&&Fne.call(e,i)}function Wne(e,i){return e!=null&&s1(e,i,Qne)}var Ine=Math.max,_ne=Math.min;function zne(e,i,n){return e>=_ne(i,n)&&e<Ine(i,n)}function Kne(e,i,n){return i=Nn(i),n===void 0?(n=i,i=0):n=Nn(n),e=Ai(e),zne(e,i,n)}var qne="[object String]";function Wu(e){return typeof e=="string"||!ae(e)&&Ee(e)&&gi(e)==qne}function Pc(e,i){return Be(i,function(n){return e[n]})}function gt(e){return e==null?[]:Pc(e,qe(e))}var Une=Math.max;function Vne(e,i,n,o){e=ji(e)?e:gt(e),n=n&&!o?re(n):0;var a=e.length;return n<0&&(n=Une(a+n,0)),Wu(e)?n<=a&&e.indexOf(i,n)>-1:!!a&&tt(e,i,n)>-1}var eoe=Math.max;function ioe(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=n==null?0:re(n);return a<0&&(a=eoe(o+a,0)),tt(e,i,a)}function noe(e){var i=e==null?0:e.length;return i?qi(e,0,-1):[]}var ooe=Math.min;function Nc(e,i,n){for(var o=n?Xc:Tu,a=e[0].length,t=e.length,s=t,r=Array(t),u=1/0,d=[];s--;){var l=e[s];s&&i&&(l=Be(l,Ti(i))),u=ooe(l.length,u),r[s]=!n&&(i||a>=120&&l.length>=120)?new Ko(s&&l):void 0}l=e[0];var g=-1,h=r[0];e:for(;++g<a&&d.length<u;){var c=l[g],p=i?i(c):c;if(c=n||c!==0?c:0,!(h?ms(h,p):o(d,p,n))){for(s=t;--s;){var f=r[s];if(!(f?ms(f,p):o(e[s],p,n)))continue e}h&&h.push(p),d.push(c)}}return d}function Ec(e){return Fe(e)?e:[]}var aoe=de(function(e){var i=Be(e,Ec);return i.length&&i[0]===e[0]?Nc(i):[]}),toe=de(function(e){var i=Ui(e),n=Be(e,Ec);return i===Ui(n)?i=void 0:n.pop(),n.length&&n[0]===e[0]?Nc(n,ie(i)):[]}),soe=de(function(e){var i=Ui(e),n=Be(e,Ec);return i=typeof i=="function"?i:void 0,i&&n.pop(),n.length&&n[0]===e[0]?Nc(n,void 0,i):[]});function roe(e,i,n,o){return Jn(e,function(a,t,s){i(o,n(a),t,s)}),o}function B1(e,i){return function(n,o){return roe(n,e,i(o),{})}}var uoe=Object.prototype,doe=uoe.toString,loe=B1(function(e,i,n){i!=null&&typeof i.toString!="function"&&(i=doe.call(i)),e[i]=n},rc(wi)),X1=Object.prototype,goe=X1.hasOwnProperty,hoe=X1.toString,coe=B1(function(e,i,n){i!=null&&typeof i.toString!="function"&&(i=hoe.call(i)),goe.call(e,i)?e[i].push(n):e[i]=[n]},ie);function H1(e,i){return i.length<2?e:sa(e,qi(i,0,-1))}function Es(e,i,n){i=Co(i,e),e=H1(e,i);var o=e==null?e:e[rn(Ui(i))];return o==null?void 0:xi(o,e,n)}var poe=de(Es),voe=de(function(e,i,n){var o=-1,a=typeof i=="function",t=ji(e)?Array(e.length):[];return Jo(e,function(s){t[++o]=a?xi(i,s,n):Es(s,i,n)}),t}),yoe="[object ArrayBuffer]";function foe(e){return Ee(e)&&gi(e)==yoe}var P0=Ki&&Ki.isArrayBuffer,moe=P0?Ti(P0):foe,boe="[object Boolean]";function woe(e){return e===!0||e===!1||Ee(e)&&gi(e)==boe}var joe="[object Date]";function koe(e){return Ee(e)&&gi(e)==joe}var N0=Ki&&Ki.isDate,Soe=N0?Ti(N0):koe;function Loe(e){return Ee(e)&&e.nodeType===1&&!Ms(e)}var Coe="[object Map]",Yoe="[object Set]",$oe=Object.prototype,Zoe=$oe.hasOwnProperty;function Joe(e){if(e==null)return!0;if(ji(e)&&(ae(e)||typeof e=="string"||typeof e.splice=="function"||ho(e)||ut(e)||_o(e)))return!e.length;var i=bn(e);if(i==Coe||i==Yoe)return!e.size;if(Hs(e))return!gc(e).length;for(var n in e)if(Zoe.call(e,n))return!1;return!0}function xoe(e,i){return Ps(e,i)}function Toe(e,i,n){n=typeof n=="function"?n:void 0;var o=n?n(e,i):void 0;return o===void 0?Ps(e,i,void 0,n):!!o}var Doe=Ke.isFinite;function Boe(e){return typeof e=="number"&&Doe(e)}function M1(e){return typeof e=="number"&&e==re(e)}function Xoe(e,i){return e===i||$c(e,i,Zc(i))}function Hoe(e,i,n){return n=typeof n=="function"?n:void 0,$c(e,i,Zc(i),n)}var Moe="[object Number]";function P1(e){return typeof e=="number"||Ee(e)&&gi(e)==Moe}function Poe(e){return P1(e)&&e!=+e}var Noe=fr?Wn:lc,Eoe="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.";function Roe(e){if(Noe(e))throw new Error(Eoe);return Uk(e)}function Ooe(e){return e==null}function Aoe(e){return e===null}var Goe="[object RegExp]";function Foe(e){return Ee(e)&&gi(e)==Goe}var E0=Ki&&Ki.isRegExp,Rc=E0?Ti(E0):Foe,R0=9007199254740991;function Qoe(e){return M1(e)&&e>=-R0&&e<=R0}function Woe(e){return e===void 0}var Ioe="[object WeakMap]";function _oe(e){return Ee(e)&&bn(e)==Ioe}var zoe="[object WeakSet]";function Koe(e){return Ee(e)&&gi(e)==zoe}var qoe=1;function Uoe(e){return ie(typeof e=="function"?e:Gi(e,qoe))}var Voe=Array.prototype,eae=Voe.join;function iae(e,i){return e==null?"":eae.call(e,i)}var nae=lt(function(e,i,n){return e+(n?"-":"")+i.toLowerCase()}),oae=Ru(function(e,i,n){$n(e,n,i)});function aae(e,i,n){for(var o=n+1;o--;)if(e[o]===i)return o;return o}var tae=Math.max,sae=Math.min;function rae(e,i,n){var o=e==null?0:e.length;if(!o)return-1;var a=o;return n!==void 0&&(a=re(n),a=a<0?tae(o+a,0):sae(a,o-1)),i===i?aae(e,i,a):xu(e,tS,a,!0)}var uae=lt(function(e,i,n){return e+(n?" ":"")+i.toLowerCase()}),dae=YS("toLowerCase");function Oc(e,i){return e<i}var lae=Qu(Oc),gae=Qu(function(e,i){return e<=i});function hae(e,i){var n={};return i=ie(i),Jn(e,function(o,a,t){$n(n,i(o,a,t),o)}),n}function cae(e,i){var n={};return i=ie(i),Jn(e,function(o,a,t){$n(n,a,i(o,a,t))}),n}var pae=1;function vae(e){return t1(Gi(e,pae))}var yae=1;function fae(e,i){return r1(e,Gi(i,yae))}function Iu(e,i,n){for(var o=-1,a=e.length;++o<a;){var t=e[o],s=i(t);if(s!=null&&(r===void 0?s===s&&!Zi(s):n(s,r)))var r=s,u=t}return u}function mae(e){return e&&e.length?Iu(e,wi,Mc):void 0}function bae(e,i){return e&&e.length?Iu(e,ie(i),Mc):void 0}function Ac(e,i){for(var n,o=-1,a=e.length;++o<a;){var t=i(e[o]);t!==void 0&&(n=n===void 0?t:n+t)}return n}var wae=NaN;function N1(e,i){var n=e==null?0:e.length;return n?Ac(e,i)/n:wae}function jae(e){return N1(e,wi)}function kae(e,i){return N1(e,ie(i))}var Sae=rt(function(e,i,n){Ou(e,i,n)}),Lae=de(function(e,i){return function(n){return Es(n,e,i)}}),Cae=de(function(e,i){return function(n){return Es(e,n,i)}});function Yae(e){return e&&e.length?Iu(e,wi,Oc):void 0}function $ae(e,i){return e&&e.length?Iu(e,ie(i),Oc):void 0}function Zae(e,i,n){var o=qe(i),a=Fu(i,o),t=!(Pe(n)&&"chain"in n)||!!n.chain,s=Wn(e);return Xi(a,function(r){var u=i[r];e[r]=u,s&&(e.prototype[r]=function(){var d=this.__chain__;if(t||d){var l=e(this.__wrapped__),g=l.__actions__=yi(this.__actions__);return g.push({func:u,args:arguments,thisArg:e}),l.__chain__=d,l}return u.apply(e,Yo([this.value()],arguments))})}),e}var Jae=Zu(function(e,i){return e*i},1),xae="Expected a function";function _u(e){if(typeof e!="function")throw new TypeError(xae);return function(){var i=arguments;switch(i.length){case 0:return!e.call(this);case 1:return!e.call(this,i[0]);case 2:return!e.call(this,i[0],i[1]);case 3:return!e.call(this,i[0],i[1],i[2])}return!e.apply(this,i)}}function Tae(e){for(var i,n=[];!(i=e.next()).done;)n.push(i.value);return n}var Dae="[object Map]",Bae="[object Set]",el=ai?ai.iterator:void 0;function E1(e){if(!e)return[];if(ji(e))return Wu(e)?un(e):yi(e);if(el&&e[el])return Tae(e[el]());var i=bn(e),n=i==Dae?Yc:i==Bae?Eu:gt;return n(e)}function Xae(){this.__values__===void 0&&(this.__values__=E1(this.value()));var e=this.__index__>=this.__values__.length,i=e?void 0:this.__values__[this.__index__++];return{done:e,value:i}}function R1(e,i){var n=e.length;if(n)return i+=i<0?n:0,In(i,n)?e[i]:void 0}function Hae(e,i){return e&&e.length?R1(e,re(i)):void 0}function Mae(e){return e=re(e),de(function(i){return R1(i,e)})}var Pae=Object.prototype,Nae=Pae.hasOwnProperty;function Gc(e,i){i=Co(i,e);var n=-1,o=i.length;if(!o)return!0;for(;++n<o;){var a=rn(i[n]);if(a==="__proto__"&&!Nae.call(e,"__proto__")||(a==="constructor"||a==="prototype")&&n<o-1)return!1}var t=H1(e,i);return t==null||delete t[rn(Ui(i))]}function Eae(e){return Ms(e)?void 0:e}var Rae=1,Oae=2,Aae=4,Gae=qn(function(e,i){var n={};if(e==null)return n;var o=!1;i=Be(i,function(t){return t=Co(t,e),o||(o=t.length>1),t}),Zn(e,Sc(e),n),o&&(n=Gi(n,Rae|Oae|Aae,Eae));for(var a=i.length;a--;)Gc(n,i[a]);return n});function Rs(e,i,n,o){if(!Pe(e))return e;i=Co(i,e);for(var a=-1,t=i.length,s=t-1,r=e;r!=null&&++a<t;){var u=rn(i[a]),d=n;if(u==="__proto__"||u==="constructor"||u==="prototype")return e;if(a!=s){var l=r[u];d=o?o(l,u,r):void 0,d===void 0&&(d=Pe(l)?l:In(i[a+1])?[]:{})}Xs(r,u,d),r=r[u]}return e}function O1(e,i,n){for(var o=-1,a=i.length,t={};++o<a;){var s=i[o],r=sa(e,s);n(r,s)&&Rs(t,Co(s,e),r)}return t}function A1(e,i){if(e==null)return{};var n=Be(Sc(e),function(o){return[o]});return i=ie(i),O1(e,n,function(o,a){return i(o,a[0])})}function Fae(e,i){return A1(e,_u(ie(i)))}function Qae(e){return bS(2,e)}function Wae(e,i){var n=e.length;for(e.sort(i);n--;)e[n]=e[n].value;return e}function G1(e,i){if(e!==i){var n=e!==void 0,o=e===null,a=e===e,t=Zi(e),s=i!==void 0,r=i===null,u=i===i,d=Zi(i);if(!r&&!d&&!t&&e>i||t&&s&&u&&!r&&!d||o&&s&&u||!n&&u||!a)return 1;if(!o&&!t&&!d&&e<i||d&&n&&a&&!o&&!t||r&&n&&a||!s&&a||!u)return-1}return 0}function Iae(e,i,n){for(var o=-1,a=e.criteria,t=i.criteria,s=a.length,r=n.length;++o<s;){var u=G1(a[o],t[o]);if(u){if(o>=r)return u;var d=n[o];return u*(d=="desc"?-1:1)}}return e.index-i.index}function F1(e,i,n){i.length?i=Be(i,function(t){return ae(t)?function(s){return sa(s,t.length===1?t[0]:t)}:t}):i=[wi];var o=-1;i=Be(i,Ti(ie));var a=T1(e,function(t,s,r){var u=Be(i,function(d){return d(t)});return{criteria:u,index:++o,value:t}});return Wae(a,function(t,s){return Iae(t,s,n)})}function _ae(e,i,n,o){return e==null?[]:(ae(i)||(i=i==null?[]:[i]),n=o?void 0:n,ae(n)||(n=n==null?[]:[n]),F1(e,i,n))}function Fc(e){return qn(function(i){return i=Be(i,Ti(ie)),de(function(n){var o=this;return e(i,function(a){return xi(a,o,n)})})})}var zae=Fc(Be),Kae=de,qae=Math.min,Uae=Kae(function(e,i){i=i.length==1&&ae(i[0])?Be(i[0],Ti(ie)):Be(ei(i,1),Ti(ie));var n=i.length;return de(function(o){for(var a=-1,t=qae(o.length,n);++a<t;)o[a]=i[a].call(this,o[a]);return xi(e,this,o)})}),Vae=Fc(L1),ete=Fc(Cc),ite=9007199254740991,nte=Math.floor;function Sg(e,i){var n="";if(!e||i<1||i>ite)return n;do i%2&&(n+=e),i=nte(i/2),i&&(e+=e);while(i);return n}var ote=xc("length"),Q1="\\ud800-\\udfff",ate="\\u0300-\\u036f",tte="\\ufe20-\\ufe2f",ste="\\u20d0-\\u20ff",rte=ate+tte+ste,ute="\\ufe0e\\ufe0f",dte="["+Q1+"]",Lg="["+rte+"]",Cg="\\ud83c[\\udffb-\\udfff]",lte="(?:"+Lg+"|"+Cg+")",W1="[^"+Q1+"]",I1="(?:\\ud83c[\\udde6-\\uddff]){2}",_1="[\\ud800-\\udbff][\\udc00-\\udfff]",gte="\\u200d",z1=lte+"?",K1="["+ute+"]?",hte="(?:"+gte+"(?:"+[W1,I1,_1].join("|")+")"+K1+z1+")*",cte=K1+z1+hte,pte="(?:"+[W1+Lg+"?",Lg,I1,_1,dte].join("|")+")",O0=RegExp(Cg+"(?="+Cg+")|"+pte+cte,"g");function vte(e){for(var i=O0.lastIndex=0;O0.test(e);)++i;return i}function ht(e){return dt(e)?vte(e):ote(e)}var yte=Math.ceil;function Ar(e,i){i=i===void 0?" ":Ji(i);var n=i.length;if(n<2)return n?Sg(i,e):i;var o=Sg(i,yte(e/ht(i)));return dt(i)?$o(un(o),0,e).join(""):o.slice(0,e)}var fte=Math.ceil,mte=Math.floor;function bte(e,i,n){e=be(e),i=re(i);var o=i?ht(e):0;if(!i||o>=i)return e;var a=(i-o)/2;return Ar(mte(a),n)+e+Ar(fte(a),n)}function wte(e,i,n){e=be(e),i=re(i);var o=i?ht(e):0;return i&&o<i?e+Ar(i-o,n):e}function jte(e,i,n){e=be(e),i=re(i);var o=i?ht(e):0;return i&&o<i?Ar(i-o,n)+e:e}var kte=/^\s+/,Ste=Ke.parseInt;function Lte(e,i,n){return n||i==null?i=0:i&&(i=+i),Ste(be(e).replace(kte,""),i||0)}var Cte=32,zu=de(function(e,i){var n=go(i,st(zu));return _n(e,Cte,void 0,i,n)});zu.placeholder={};var Yte=64,Qc=de(function(e,i){var n=go(i,st(Qc));return _n(e,Yte,void 0,i,n)});Qc.placeholder={};var $te=Ru(function(e,i,n){e[n?0:1].push(i)},function(){return[[],[]]});function Zte(e,i){return O1(e,i,function(n,o){return Jc(e,o)})}var Jte=qn(function(e,i){return e==null?{}:Zte(e,i)});function xte(e){for(var i,n=this;n instanceof Ju;){var o=nS(n);o.__index__=0,o.__values__=void 0,i?a.__wrapped__=o:i=o;var a=o;n=n.__wrapped__}return a.__wrapped__=e,i}function Tte(e){return function(i){return e==null?void 0:sa(e,i)}}function Dte(e,i,n,o){for(var a=n-1,t=e.length;++a<t;)if(o(e[a],i))return a;return-1}var Bte=Array.prototype,A0=Bte.splice;function Wc(e,i,n,o){var a=o?Dte:tt,t=-1,s=i.length,r=e;for(e===i&&(i=yi(i)),n&&(r=Be(e,Ti(n)));++t<s;)for(var u=0,d=i[t],l=n?n(d):d;(u=a(r,l,u,o))>-1;)r!==e&&A0.call(r,u,1),A0.call(e,u,1);return e}function q1(e,i){return e&&e.length&&i&&i.length?Wc(e,i):e}var Xte=de(q1);function Hte(e,i,n){return e&&e.length&&i&&i.length?Wc(e,i,ie(n)):e}function Mte(e,i,n){return e&&e.length&&i&&i.length?Wc(e,i,void 0,n):e}var Pte=Array.prototype,Nte=Pte.splice;function U1(e,i){for(var n=e?i.length:0,o=n-1;n--;){var a=i[n];if(n==o||a!==t){var t=a;In(a)?Nte.call(e,a,1):Gc(e,a)}}return e}var Ete=qn(function(e,i){var n=e==null?0:e.length,o=pc(e,i);return U1(e,Be(i,function(a){return In(a,n)?+a:a}).sort(G1)),o}),Rte=Math.floor,Ote=Math.random;function Ic(e,i){return e+Rte(Ote()*(i-e+1))}var Ate=parseFloat,Gte=Math.min,Fte=Math.random;function Qte(e,i,n){if(n&&typeof n!="boolean"&&ri(e,i,n)&&(i=n=void 0),n===void 0&&(typeof i=="boolean"?(n=i,i=void 0):typeof e=="boolean"&&(n=e,e=void 0)),e===void 0&&i===void 0?(e=0,i=1):(e=Nn(e),i===void 0?(i=e,e=0):i=Nn(i)),e>i){var o=e;e=i,i=o}if(n||e%1||i%1){var a=Fte();return Gte(e+a*(i-e+Ate("1e-"+((a+"").length-1))),i)}return Ic(e,i)}var Wte=Math.ceil,Ite=Math.max;function _te(e,i,n,o){for(var a=-1,t=Ite(Wte((i-e)/(n||1)),0),s=Array(t);t--;)s[o?t:++a]=e,e+=n;return s}function V1(e){return function(i,n,o){return o&&typeof o!="number"&&ri(i,n,o)&&(n=o=void 0),i=Nn(i),n===void 0?(n=i,i=0):n=Nn(n),o=o===void 0?i<n?1:-1:Nn(o),_te(i,n,o,e)}}var zte=V1(),Kte=V1(!0),qte=256,Ute=qn(function(e,i){return _n(e,qte,void 0,void 0,void 0,i)});function eL(e,i,n,o,a){return a(e,function(t,s,r){n=o?(o=!1,t):i(n,t,s,r)}),n}function Vte(e,i,n){var o=ae(e)?mc:eL,a=arguments.length<3;return o(e,ie(i),n,a,Jo)}function ese(e,i,n,o){var a=e==null?0:e.length;for(o&&a&&(n=e[--a]);a--;)n=i(n,e[a],a,e);return n}function ise(e,i,n){var o=ae(e)?ese:eL,a=arguments.length<3;return o(e,ie(i),n,a,b1)}function nse(e,i){var n=ae(e)?Zo:Y1;return n(e,_u(ie(i)))}function ose(e,i){var n=[];if(!(e&&e.length))return n;var o=-1,a=[],t=e.length;for(i=ie(i);++o<t;){var s=e[o];i(s,o,e)&&(n.push(s),a.push(o))}return U1(e,a),n}function ase(e,i,n){return(n?ri(e,i,n):i===void 0)?i=1:i=re(i),Sg(be(e),i)}function tse(){var e=arguments,i=be(e[0]);return e.length<3?i:i.replace(e[1],e[2])}var sse="Expected a function";function rse(e,i){if(typeof e!="function")throw new TypeError(sse);return i=i===void 0?i:re(i),de(e,i)}function use(e,i,n){i=Co(i,e);var o=-1,a=i.length;for(a||(a=1,e=void 0);++o<a;){var t=e?.[rn(i[o])];t===void 0&&(o=a,t=n),e=Wn(t)?t.call(e):t}return e}var dse=Array.prototype,lse=dse.reverse;function Yg(e){return e==null?e:lse.call(e)}var gse=wc("round");function iL(e){var i=e.length;return i?e[Ic(0,i-1)]:void 0}function hse(e){return iL(gt(e))}function cse(e){var i=ae(e)?iL:hse;return i(e)}function Ku(e,i){var n=-1,o=e.length,a=o-1;for(i=i===void 0?o:i;++n<i;){var t=Ic(n,a),s=e[t];e[t]=e[n],e[n]=s}return e.length=i,e}function pse(e,i){return Ku(yi(e),ra(i,0,e.length))}function vse(e,i){var n=gt(e);return Ku(n,ra(i,0,n.length))}function yse(e,i,n){(n?ri(e,i,n):i===void 0)?i=1:i=re(i);var o=ae(e)?pse:vse;return o(e,i)}function fse(e,i,n){return e==null?e:Rs(e,i,n)}function mse(e,i,n,o){return o=typeof o=="function"?o:void 0,e==null?e:Rs(e,i,n,o)}function bse(e){return Ku(yi(e))}function wse(e){return Ku(gt(e))}function jse(e){var i=ae(e)?bse:wse;return i(e)}var kse="[object Map]",Sse="[object Set]";function Lse(e){if(e==null)return 0;if(ji(e))return Wu(e)?ht(e):e.length;var i=bn(e);return i==kse||i==Sse?e.size:gc(e).length}function Cse(e,i,n){var o=e==null?0:e.length;return o?(n&&typeof n!="number"&&ri(e,i,n)?(i=0,n=o):(i=i==null?0:re(i),n=n===void 0?o:re(n)),qi(e,i,n)):[]}var Yse=lt(function(e,i,n){return e+(n?"_":"")+i.toLowerCase()});function $se(e,i){var n;return Jo(e,function(o,a,t){return n=i(o,a,t),!n}),!!n}function Zse(e,i,n){var o=ae(e)?Cc:$se;return n&&ri(e,i,n)&&(i=void 0),o(e,ie(i))}var Jse=de(function(e,i){if(e==null)return[];var n=i.length;return n>1&&ri(e,i[0],i[1])?i=[]:n>2&&ri(i[0],i[1],i[2])&&(i=[i[0]]),F1(e,ei(i,1),[])}),xse=4294967295,Tse=xse-1,Dse=Math.floor,Bse=Math.min;function _c(e,i,n,o){var a=0,t=e==null?0:e.length;if(t===0)return 0;i=n(i);for(var s=i!==i,r=i===null,u=Zi(i),d=i===void 0;a<t;){var l=Dse((a+t)/2),g=n(e[l]),h=g!==void 0,c=g===null,p=g===g,f=Zi(g);if(s)var w=o||p;else d?w=p&&(o||h):r?w=p&&h&&(o||!c):u?w=p&&h&&!c&&(o||!f):c||f?w=!1:w=o?g<=i:g<i;w?a=l+1:t=l}return Bse(t,Tse)}var Xse=4294967295,Hse=Xse>>>1;function qu(e,i,n){var o=0,a=e==null?o:e.length;if(typeof i=="number"&&i===i&&a<=Hse){for(;o<a;){var t=o+a>>>1,s=e[t];s!==null&&!Zi(s)&&(n?s<=i:s<i)?o=t+1:a=t}return a}return _c(e,i,wi,n)}function Mse(e,i){return qu(e,i)}function Pse(e,i,n){return _c(e,i,ie(n))}function Nse(e,i){var n=e==null?0:e.length;if(n){var o=qu(e,i);if(o<n&&ln(e[o],i))return o}return-1}function Ese(e,i){return qu(e,i,!0)}function Rse(e,i,n){return _c(e,i,ie(n),!0)}function Ose(e,i){var n=e==null?0:e.length;if(n){var o=qu(e,i,!0)-1;if(ln(e[o],i))return o}return-1}function nL(e,i){for(var n=-1,o=e.length,a=0,t=[];++n<o;){var s=e[n],r=i?i(s):s;if(!n||!ln(r,u)){var u=r;t[a++]=s===0?0:s}}return t}function Ase(e){return e&&e.length?nL(e):[]}function Gse(e,i){return e&&e.length?nL(e,ie(i)):[]}var Fse=4294967295;function Qse(e,i,n){return n&&typeof n!="number"&&ri(e,i,n)&&(i=n=void 0),n=n===void 0?Fse:n>>>0,n?(e=be(e),e&&(typeof i=="string"||i!=null&&!Rc(i))&&(i=Ji(i),!i&&dt(e))?$o(un(e),0,n):e.split(i,n)):[]}var Wse="Expected a function",Ise=Math.max;function _se(e,i){if(typeof e!="function")throw new TypeError(Wse);return i=i==null?0:Ise(re(i),0),de(function(n){var o=n[i],a=$o(n,0,i);return o&&Yo(a,o),xi(e,this,a)})}var zse=lt(function(e,i,n){return e+(n?" ":"")+fc(i)});function Kse(e,i,n){return e=be(e),n=n==null?0:ra(re(n),0,e.length),i=Ji(i),e.slice(n,n+i.length)==i}function qse(){return{}}function Use(){return""}function Vse(){return!0}var ere=Zu(function(e,i){return e-i},0);function ire(e){return e&&e.length?Ac(e,wi):0}function nre(e,i){return e&&e.length?Ac(e,ie(i)):0}function ore(e){var i=e==null?0:e.length;return i?qi(e,1,i):[]}function are(e,i,n){return e&&e.length?(i=n||i===void 0?1:re(i),qi(e,0,i<0?0:i)):[]}function tre(e,i,n){var o=e==null?0:e.length;return o?(i=n||i===void 0?1:re(i),i=o-i,qi(e,i<0?0:i,o)):[]}function sre(e,i){return e&&e.length?Au(e,ie(i),!1,!0):[]}function rre(e,i){return e&&e.length?Au(e,ie(i)):[]}function ure(e,i){return i(e),e}var oL=Object.prototype,dre=oL.hasOwnProperty;function G0(e,i,n,o){return e===void 0||ln(e,oL[n])&&!dre.call(o,n)?i:e}var lre={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};function gre(e){return"\\"+lre[e]}var aL=/<%=([\s\S]+?)%>/g,hre=/<%-([\s\S]+?)%>/g,cre=/<%([\s\S]+?)%>/g,$g={escape:hre,evaluate:cre,interpolate:aL,variable:"",imports:{_:{escape:k1}}},pre="Invalid `variable` option passed into `_.template`",vre="Invalid `imports` option passed into `_.template`",yre=/\b__p \+= '';/g,fre=/\b(__p \+=) '' \+/g,mre=/(__e\(.*?\)|\b__t\)) \+\n'';/g,F0=/[()=,{}\[\]\/\s]/,bre=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,ir=/($^)/,wre=/['\n\r\u2028\u2029\\]/g,jre=Object.prototype,Q0=jre.hasOwnProperty;function kre(e,i,n){var o=$g.imports._.templateSettings||$g;n&&ri(e,i,n)&&(i=void 0),e=be(e),i=vg({},i,o,G0);var a=vg({},i.imports,o.imports,G0),t=qe(a),s=Pc(a,t);Xi(t,function(w){if(F0.test(w))throw new Error(vre)});var r,u,d=0,l=i.interpolate||ir,g="__p += '",h=RegExp((i.escape||ir).source+"|"+l.source+"|"+(l===aL?bre:ir).source+"|"+(i.evaluate||ir).source+"|$","g"),c=Q0.call(i,"sourceURL")?"//# sourceURL="+(i.sourceURL+"").replace(/\s/g," ")+`
79
79
  `:"";e.replace(h,function(w,v,j,C,y,k){return j||(j=C),g+=e.slice(d,k).replace(wre,gre),v&&(r=!0,g+=`' +
80
80
  __e(`+v+`) +
81
81
  '`),y&&(u=!0,g+=`';
@@ -92,7 +92,7 @@ __p += '`),j&&(g+=`' +
92
92
  function print() { __p += __j.call(arguments, '') }
93
93
  `:`;
94
94
  `)+g+`return __p
95
- }`;var f=m1(function(){return Function(t,c+"return "+g).apply(void 0,s)});if(f.source=g,vc(f))throw f;return f}var Sre="Expected a function";function Lre(e,i,n){var o=!0,a=!0;if(typeof e!="function")throw new TypeError(Sre);return Pe(n)&&(o="leading"in n?!!n.leading:o,a="trailing"in n?!!n.trailing:a),hS(e,i,{leading:o,maxWait:i,trailing:a})}function Uu(e,i){return i(e)}var Cre=9007199254740991,il=4294967295,Yre=Math.min;function $re(e,i){if(e=re(e),e<1||e>Cre)return[];var n=il,o=Yre(e,il);i=xn(i),e-=il;for(var a=dc(o,i);++n<e;)i(n);return a}function Zre(){return this}function tL(e,i){var n=e;return n instanceof pe&&(n=n.value()),mc(i,function(o,a){return a.func.apply(a.thisArg,Yo([o],a.args))},n)}function Jre(){return tL(this.__wrapped__,this.__actions__)}function xre(e){return be(e).toLowerCase()}function Tre(e){return ae(e)?Be(e,rn):Zi(e)?[e]:yi(v1(be(e)))}var W0=9007199254740991;function Dre(e){return e?ra(re(e),-W0,W0):e===0?e:0}function Bre(e){return be(e).toUpperCase()}function Xre(e,i,n){var o=ae(e),a=o||ho(e)||ut(e);if(i=ie(i),n==null){var t=e&&e.constructor;a?n=o?new t:[]:Pe(e)?n=Wn(t)?at(Pu(e)):{}:n={}}return(a?Xi:Jn)(e,function(s,r,u){return i(n,s,r,u)}),n}function sL(e,i){for(var n=e.length;n--&&tt(i,e[n],0)>-1;);return n}function rL(e,i){for(var n=-1,o=e.length;++n<o&&tt(i,e[n],0)>-1;);return n}function Hre(e,i,n){if(e=be(e),e&&(n||i===void 0))return qk(e);if(!e||!(i=Ji(i)))return e;var o=un(e),a=un(i),t=rL(o,a),s=sL(o,a)+1;return $o(o,t,s).join("")}function Mre(e,i,n){if(e=be(e),e&&(n||i===void 0))return e.slice(0,Kk(e)+1);if(!e||!(i=Ji(i)))return e;var o=un(e),a=sL(o,un(i))+1;return $o(o,0,a).join("")}var Pre=/^\s+/;function Nre(e,i,n){if(e=be(e),e&&(n||i===void 0))return e.replace(Pre,"");if(!e||!(i=Ji(i)))return e;var o=un(e),a=rL(o,un(i));return $o(o,a).join("")}var Ere=30,Rre="...",Ore=/\w*$/;function Are(e,i){var n=Ere,o=Rre;if(Pe(i)){var a="separator"in i?i.separator:a;n="length"in i?re(i.length):n,o="omission"in i?Ji(i.omission):o}e=be(e);var t=e.length;if(dt(e)){var s=un(e);t=s.length}if(n>=t)return e;var r=n-ht(o);if(r<1)return o;var u=s?$o(s,0,r).join(""):e.slice(0,r);if(a===void 0)return u+o;if(s&&(r+=u.length-r),Rc(a)){if(e.slice(r).search(a)){var d,l=u;for(a.global||(a=RegExp(a.source,be(Ore.exec(a))+"g")),a.lastIndex=0;d=a.exec(l);)var g=d.index;u=u.slice(0,g===void 0?r:g)}}else if(e.indexOf(Ji(a),r)!=r){var h=u.lastIndexOf(a);h>-1&&(u=u.slice(0,h))}return u+o}function Gre(e){return u1(e,1)}var Fre={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},Qre=bc(Fre),uL=/&(?:amp|lt|gt|quot|#39);/g,Wre=RegExp(uL.source);function Ire(e){return e=be(e),e&&Wre.test(e)?e.replace(uL,Qre):e}var _re=1/0,zre=Ba&&1/Eu(new Ba([,-0]))[1]==_re?function(e){return new Ba(e)}:tc,Kre=200;function co(e,i,n){var o=-1,a=Tu,t=e.length,s=!0,r=[],u=r;if(n)s=!1,a=Xc;else if(t>=Kre){var d=i?null:zre(e);if(d)return Eu(d);s=!1,a=ms,u=new Ko}else u=i?[]:r;e:for(;++o<t;){var l=e[o],g=i?i(l):l;if(l=n||l!==0?l:0,s&&g===g){for(var h=u.length;h--;)if(u[h]===g)continue e;i&&u.push(g),r.push(l)}else a(u,g,n)||(u!==r&&u.push(g),r.push(l))}return r}var qre=de(function(e){return co(ei(e,1,Fe,!0))}),Ure=de(function(e){var i=Ui(e);return Fe(i)&&(i=void 0),co(ei(e,1,Fe,!0),ie(i))}),Vre=de(function(e){var i=Ui(e);return i=typeof i=="function"?i:void 0,co(ei(e,1,Fe,!0),void 0,i)});function eue(e){return e&&e.length?co(e):[]}function iue(e,i){return e&&e.length?co(e,ie(i)):[]}function nue(e,i){return i=typeof i=="function"?i:void 0,e&&e.length?co(e,void 0,i):[]}var oue=0;function aue(e){var i=++oue;return be(e)+i}function tue(e,i){return e==null?!0:Gc(e,i)}var sue=Math.max;function zc(e){if(!(e&&e.length))return[];var i=0;return e=Zo(e,function(n){if(Fe(n))return i=sue(n.length,i),!0}),dc(i,function(n){return Be(e,xc(n))})}function dL(e,i){if(!(e&&e.length))return[];var n=zc(e);return i==null?n:Be(n,function(o){return xi(i,void 0,o)})}function lL(e,i,n,o){return Rs(e,i,n(sa(e,i)),o)}function rue(e,i,n){return e==null?e:lL(e,i,xn(n))}function uue(e,i,n,o){return o=typeof o=="function"?o:void 0,e==null?e:lL(e,i,xn(n),o)}var due=lt(function(e,i,n){return e+(n?" ":"")+i.toUpperCase()});function lue(e){return e==null?[]:Pc(e,ki(e))}var gue=de(function(e,i){return Fe(e)?Ns(e,i):[]});function hue(e,i){return zu(xn(i),e)}var cue=qn(function(e){var i=e.length,n=i?e[0]:0,o=this.__wrapped__,a=function(t){return pc(t,e)};return i>1||this.__actions__.length||!(o instanceof pe)||!In(n)?this.thru(a):(o=o.slice(n,+n+(i?1:0)),o.__actions__.push({func:Uu,args:[a],thisArg:void 0}),new zi(o,this.__chain__).thru(function(t){return i&&!t.length&&t.push(void 0),t}))});function pue(){return G1(this)}function vue(){var e=this.__wrapped__;if(e instanceof pe){var i=e;return this.__actions__.length&&(i=new pe(this)),i=i.reverse(),i.__actions__.push({func:Uu,args:[Yg],thisArg:void 0}),new zi(i,this.__chain__)}return this.thru(Yg)}function Kc(e,i,n){var o=e.length;if(o<2)return o?co(e[0]):[];for(var a=-1,t=Array(o);++a<o;)for(var s=e[a],r=-1;++r<o;)r!=a&&(t[a]=Ns(t[a]||s,e[r],i,n));return co(ei(t,1),i,n)}var yue=de(function(e){return Kc(Zo(e,Fe))}),fue=de(function(e){var i=Ui(e);return Fe(i)&&(i=void 0),Kc(Zo(e,Fe),ie(i))}),mue=de(function(e){var i=Ui(e);return i=typeof i=="function"?i:void 0,Kc(Zo(e,Fe),void 0,i)}),bue=de(zc);function gL(e,i,n){for(var o=-1,a=e.length,t=i.length,s={};++o<a;){var r=o<t?i[o]:void 0;n(s,e[o],r)}return s}function wue(e,i){return gL(e||[],i||[],Xs)}function jue(e,i){return gL(e||[],i||[],Rs)}var kue=de(function(e){var i=e.length,n=i>1?e[i-1]:void 0;return n=typeof n=="function"?(e.pop(),n):void 0,dL(e,n)});const O={chunk:FU,compact:Cee,concat:Yee,difference:Tie,differenceBy:Die,differenceWith:Bie,drop:Hie,dropRight:Mie,dropRightWhile:Pie,dropWhile:Nie,fill:ane,findIndex:ZS,findLastIndex:xS,flatten:y1,flattenDeep:bne,flattenDepth:wne,fromPairs:Hne,head:cne,indexOf:ioe,initial:noe,intersection:aoe,intersectionBy:toe,intersectionWith:soe,join:iae,lastIndexOf:rae,nth:Hae,pull:Xte,pullAll:qS,pullAllBy:Hte,pullAllWith:Mte,pullAt:Ete,remove:ose,reverse:Yg,slice:Cse,sortedIndex:Mse,sortedIndexBy:Pse,sortedIndexOf:Nse,sortedLastIndex:Ese,sortedLastIndexBy:Rse,sortedLastIndexOf:Ose,sortedUniq:Ase,sortedUniqBy:Gse,tail:ore,take:are,takeRight:tre,takeRightWhile:sre,takeWhile:rre,union:qre,unionBy:Ure,unionWith:Vre,uniq:eue,uniqBy:iue,uniqWith:nue,unzip:zc,unzipWith:dL,without:gue,xor:yue,xorBy:fue,xorWith:mue,zip:bue,zipObject:wue,zipObjectDeep:jue,zipWith:kue},Ye={countBy:vie,every:ine,filter:tne,find:rne,findLast:gne,flatMap:pne,flatMapDeep:yne,flatMapDepth:fne,forEach:Eie,forEachRight:Oie,groupBy:Rne,includes:Vne,invokeMap:voe,keyBy:oae,map:Gu,orderBy:_ae,partition:$te,reduce:Vte,reduceRight:ise,reject:nse,sample:cse,sampleSize:yse,shuffle:jse,size:Lse,some:Zse,sortBy:Jse},Sue={now:br},Oe={after:$9,ary:u1,before:b1,bind:Nu,bindKey:yc,curry:Dc,curryRight:Bc,debounce:hS,defer:Zie,delay:Jie,flip:kne,memoize:Mu,once:Qae,overArgs:Uae,partial:zu,partialRight:Qc,rearg:Ute,rest:rse,spread:_se,throttle:Lre,unary:Gre,wrap:hue},Q={castArray:NU,clone:vee,cloneDeep:mee,cloneDeepWith:jee,cloneWith:See,conformsTo:lie,eq:ln,gt:One,gte:Ane,isArguments:_o,isArrayBuffer:moe,isArrayLike:ji,isArrayLikeObject:Fe,isBoolean:woe,isBuffer:ho,isDate:Soe,isElement:Loe,isEmpty:Joe,isEqual:xoe,isEqualWith:Toe,isError:vc,isFinite:Boe,isFunction:Wn,isInteger:MS,isLength:Bu,isMap:q1,isMatch:Xoe,isMatchWith:Hoe,isNaN:Poe,isNative:Roe,isNil:Ooe,isNull:Aoe,isNumber:PS,isObjectLike:Ee,isPlainObject:Ms,isRegExp:Rc,isSafeInteger:Qoe,isSet:U1,isString:Wu,isSymbol:Zi,isTypedArray:ut,isUndefined:Woe,isWeakMap:_oe,isWeakSet:Koe,lt:lae,lte:gae,toArray:ES,toFinite:Nn,toLength:CS,toNumber:Ai,toPlainObject:pS,toSafeInteger:Dre,toString:be},hi={add:m9,ceil:OU,divide:Xie,floor:Sne,max:mae,maxBy:bae,mean:jae,meanBy:kae,min:Yae,minBy:$ae,multiply:Jae,round:gse,subtract:ere,sum:ire,sumBy:nre},qc={clamp:QU,inRange:Kne,random:Qte},U={assign:T6,assignIn:M6,assignInWith:P6,assignWith:vg,at:yq,create:yie,defaults:Lie,defaultsDeep:Yie,findKey:une,findLastKey:hne,forIn:Tne,forInRight:Dne,forOwn:Bne,forOwnRight:Xne,functions:Mne,functionsIn:Pne,get:cc,has:Wne,hasIn:Jc,invert:loe,invertBy:coe,invoke:poe,keysIn:ki,mapKeys:hae,mapValues:cae,merge:Sae,mergeWith:yS,omit:Gae,omitBy:Fae,pick:Jte,pickBy:AS,result:use,set:fse,setWith:mse,toPairs:Iie,toPairsIn:_ie,transform:Xre,unset:tue,update:rue,updateWith:uue,values:gt,valuesIn:lue},Tn={at:cue,chain:G1,commit:Lee,next:Xae,plant:xte,reverse:vue,tap:ure,toIterator:Zre,value:Jre,wrapperChain:pue},fe={camelCase:PU,capitalize:$1,deburr:Z1,endsWith:Aie,escape:kS,escapeRegExp:Vie,kebabCase:nae,lowerCase:uae,lowerFirst:dae,pad:bte,padEnd:wte,padStart:jte,parseInt:Lte,repeat:ase,replace:tse,snakeCase:Yse,split:Qse,startCase:zse,startsWith:Kse,template:kre,templateSettings:$g,toLower:xre,toUpper:Bre,trim:Hre,trimEnd:Mre,trimStart:Nre,truncate:Are,unescape:Ire,upperCase:due,upperFirst:fc,words:A1},ke={attempt:m1,bindAll:$q,cond:sie,conforms:die,constant:rc,defaultTo:kie,flow:Jne,flowRight:xne,iteratee:Uoe,matches:vae,matchesProperty:fae,method:Lae,methodOf:Cae,noop:tc,nthArg:Mae,over:zae,overEvery:Vae,overSome:ete,property:uS,propertyOf:Tte,range:zte,rangeRight:Kte,stubArray:jc,stubFalse:lc,stubObject:qse,stubString:Use,stubTrue:Vse,times:$re,toPath:Tre,uniqueId:aue};function Lue(){var e=new pe(this.__wrapped__);return e.__actions__=yi(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=yi(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=yi(this.__views__),e}function Cue(){if(this.__filtered__){var e=new pe(this);e.__dir__=-1,e.__filtered__=!0}else e=this.clone(),e.__dir__*=-1;return e}var Yue=Math.max,$ue=Math.min;function Zue(e,i,n){for(var o=-1,a=n.length;++o<a;){var t=n[o],s=t.size;switch(t.type){case"drop":e+=s;break;case"dropRight":i-=s;break;case"take":i=$ue(i,e+s);break;case"takeRight":e=Yue(e,i-s);break}}return{start:e,end:i}}var Jue=1,xue=2,Tue=Math.min;function Due(){var e=this.__wrapped__.value(),i=this.__dir__,n=ae(e),o=i<0,a=n?e.length:0,t=Zue(0,a,this.__views__),s=t.start,r=t.end,u=r-s,d=o?r:s-1,l=this.__iteratees__,g=l.length,h=0,c=Tue(u,this.__takeCount__);if(!n||!o&&a==u&&c==u)return tL(e,this.__actions__);var p=[];e:for(;u--&&h<c;){d+=i;for(var f=-1,w=e[d];++f<g;){var v=l[f],j=v.iteratee,C=v.type,y=j(w);if(C==xue)w=y;else if(!y){if(C==Jue)continue e;break e}}p[h++]=w}return p}var Bue="4.18.1",Xue=2,Hue=1,Mue=3,hL=4294967295,Pue=Array.prototype,Nue=Object.prototype,cL=Nue.hasOwnProperty,I0=ai?ai.iterator:void 0,Eue=Math.max,_0=Math.min,Uc=(function(e){return function(i,n,o){if(o==null){var a=Pe(n),t=a&&qe(n),s=t&&t.length&&Fu(n,t);(s?s.length:a)||(o=n,n=i,i=this)}return e(i,n,o)}})(Zae);b.after=Oe.after;b.ary=Oe.ary;b.assign=U.assign;b.assignIn=U.assignIn;b.assignInWith=U.assignInWith;b.assignWith=U.assignWith;b.at=U.at;b.before=Oe.before;b.bind=Oe.bind;b.bindAll=ke.bindAll;b.bindKey=Oe.bindKey;b.castArray=Q.castArray;b.chain=Tn.chain;b.chunk=O.chunk;b.compact=O.compact;b.concat=O.concat;b.cond=ke.cond;b.conforms=ke.conforms;b.constant=ke.constant;b.countBy=Ye.countBy;b.create=U.create;b.curry=Oe.curry;b.curryRight=Oe.curryRight;b.debounce=Oe.debounce;b.defaults=U.defaults;b.defaultsDeep=U.defaultsDeep;b.defer=Oe.defer;b.delay=Oe.delay;b.difference=O.difference;b.differenceBy=O.differenceBy;b.differenceWith=O.differenceWith;b.drop=O.drop;b.dropRight=O.dropRight;b.dropRightWhile=O.dropRightWhile;b.dropWhile=O.dropWhile;b.fill=O.fill;b.filter=Ye.filter;b.flatMap=Ye.flatMap;b.flatMapDeep=Ye.flatMapDeep;b.flatMapDepth=Ye.flatMapDepth;b.flatten=O.flatten;b.flattenDeep=O.flattenDeep;b.flattenDepth=O.flattenDepth;b.flip=Oe.flip;b.flow=ke.flow;b.flowRight=ke.flowRight;b.fromPairs=O.fromPairs;b.functions=U.functions;b.functionsIn=U.functionsIn;b.groupBy=Ye.groupBy;b.initial=O.initial;b.intersection=O.intersection;b.intersectionBy=O.intersectionBy;b.intersectionWith=O.intersectionWith;b.invert=U.invert;b.invertBy=U.invertBy;b.invokeMap=Ye.invokeMap;b.iteratee=ke.iteratee;b.keyBy=Ye.keyBy;b.keys=qe;b.keysIn=U.keysIn;b.map=Ye.map;b.mapKeys=U.mapKeys;b.mapValues=U.mapValues;b.matches=ke.matches;b.matchesProperty=ke.matchesProperty;b.memoize=Oe.memoize;b.merge=U.merge;b.mergeWith=U.mergeWith;b.method=ke.method;b.methodOf=ke.methodOf;b.mixin=Uc;b.negate=_u;b.nthArg=ke.nthArg;b.omit=U.omit;b.omitBy=U.omitBy;b.once=Oe.once;b.orderBy=Ye.orderBy;b.over=ke.over;b.overArgs=Oe.overArgs;b.overEvery=ke.overEvery;b.overSome=ke.overSome;b.partial=Oe.partial;b.partialRight=Oe.partialRight;b.partition=Ye.partition;b.pick=U.pick;b.pickBy=U.pickBy;b.property=ke.property;b.propertyOf=ke.propertyOf;b.pull=O.pull;b.pullAll=O.pullAll;b.pullAllBy=O.pullAllBy;b.pullAllWith=O.pullAllWith;b.pullAt=O.pullAt;b.range=ke.range;b.rangeRight=ke.rangeRight;b.rearg=Oe.rearg;b.reject=Ye.reject;b.remove=O.remove;b.rest=Oe.rest;b.reverse=O.reverse;b.sampleSize=Ye.sampleSize;b.set=U.set;b.setWith=U.setWith;b.shuffle=Ye.shuffle;b.slice=O.slice;b.sortBy=Ye.sortBy;b.sortedUniq=O.sortedUniq;b.sortedUniqBy=O.sortedUniqBy;b.split=fe.split;b.spread=Oe.spread;b.tail=O.tail;b.take=O.take;b.takeRight=O.takeRight;b.takeRightWhile=O.takeRightWhile;b.takeWhile=O.takeWhile;b.tap=Tn.tap;b.throttle=Oe.throttle;b.thru=Uu;b.toArray=Q.toArray;b.toPairs=U.toPairs;b.toPairsIn=U.toPairsIn;b.toPath=ke.toPath;b.toPlainObject=Q.toPlainObject;b.transform=U.transform;b.unary=Oe.unary;b.union=O.union;b.unionBy=O.unionBy;b.unionWith=O.unionWith;b.uniq=O.uniq;b.uniqBy=O.uniqBy;b.uniqWith=O.uniqWith;b.unset=U.unset;b.unzip=O.unzip;b.unzipWith=O.unzipWith;b.update=U.update;b.updateWith=U.updateWith;b.values=U.values;b.valuesIn=U.valuesIn;b.without=O.without;b.words=fe.words;b.wrap=Oe.wrap;b.xor=O.xor;b.xorBy=O.xorBy;b.xorWith=O.xorWith;b.zip=O.zip;b.zipObject=O.zipObject;b.zipObjectDeep=O.zipObjectDeep;b.zipWith=O.zipWith;b.entries=U.toPairs;b.entriesIn=U.toPairsIn;b.extend=U.assignIn;b.extendWith=U.assignInWith;Uc(b,b);b.add=hi.add;b.attempt=ke.attempt;b.camelCase=fe.camelCase;b.capitalize=fe.capitalize;b.ceil=hi.ceil;b.clamp=qc.clamp;b.clone=Q.clone;b.cloneDeep=Q.cloneDeep;b.cloneDeepWith=Q.cloneDeepWith;b.cloneWith=Q.cloneWith;b.conformsTo=Q.conformsTo;b.deburr=fe.deburr;b.defaultTo=ke.defaultTo;b.divide=hi.divide;b.endsWith=fe.endsWith;b.eq=Q.eq;b.escape=fe.escape;b.escapeRegExp=fe.escapeRegExp;b.every=Ye.every;b.find=Ye.find;b.findIndex=O.findIndex;b.findKey=U.findKey;b.findLast=Ye.findLast;b.findLastIndex=O.findLastIndex;b.findLastKey=U.findLastKey;b.floor=hi.floor;b.forEach=Ye.forEach;b.forEachRight=Ye.forEachRight;b.forIn=U.forIn;b.forInRight=U.forInRight;b.forOwn=U.forOwn;b.forOwnRight=U.forOwnRight;b.get=U.get;b.gt=Q.gt;b.gte=Q.gte;b.has=U.has;b.hasIn=U.hasIn;b.head=O.head;b.identity=wi;b.includes=Ye.includes;b.indexOf=O.indexOf;b.inRange=qc.inRange;b.invoke=U.invoke;b.isArguments=Q.isArguments;b.isArray=ae;b.isArrayBuffer=Q.isArrayBuffer;b.isArrayLike=Q.isArrayLike;b.isArrayLikeObject=Q.isArrayLikeObject;b.isBoolean=Q.isBoolean;b.isBuffer=Q.isBuffer;b.isDate=Q.isDate;b.isElement=Q.isElement;b.isEmpty=Q.isEmpty;b.isEqual=Q.isEqual;b.isEqualWith=Q.isEqualWith;b.isError=Q.isError;b.isFinite=Q.isFinite;b.isFunction=Q.isFunction;b.isInteger=Q.isInteger;b.isLength=Q.isLength;b.isMap=Q.isMap;b.isMatch=Q.isMatch;b.isMatchWith=Q.isMatchWith;b.isNaN=Q.isNaN;b.isNative=Q.isNative;b.isNil=Q.isNil;b.isNull=Q.isNull;b.isNumber=Q.isNumber;b.isObject=Pe;b.isObjectLike=Q.isObjectLike;b.isPlainObject=Q.isPlainObject;b.isRegExp=Q.isRegExp;b.isSafeInteger=Q.isSafeInteger;b.isSet=Q.isSet;b.isString=Q.isString;b.isSymbol=Q.isSymbol;b.isTypedArray=Q.isTypedArray;b.isUndefined=Q.isUndefined;b.isWeakMap=Q.isWeakMap;b.isWeakSet=Q.isWeakSet;b.join=O.join;b.kebabCase=fe.kebabCase;b.last=Ui;b.lastIndexOf=O.lastIndexOf;b.lowerCase=fe.lowerCase;b.lowerFirst=fe.lowerFirst;b.lt=Q.lt;b.lte=Q.lte;b.max=hi.max;b.maxBy=hi.maxBy;b.mean=hi.mean;b.meanBy=hi.meanBy;b.min=hi.min;b.minBy=hi.minBy;b.stubArray=ke.stubArray;b.stubFalse=ke.stubFalse;b.stubObject=ke.stubObject;b.stubString=ke.stubString;b.stubTrue=ke.stubTrue;b.multiply=hi.multiply;b.nth=O.nth;b.noop=ke.noop;b.now=Sue.now;b.pad=fe.pad;b.padEnd=fe.padEnd;b.padStart=fe.padStart;b.parseInt=fe.parseInt;b.random=qc.random;b.reduce=Ye.reduce;b.reduceRight=Ye.reduceRight;b.repeat=fe.repeat;b.replace=fe.replace;b.result=U.result;b.round=hi.round;b.sample=Ye.sample;b.size=Ye.size;b.snakeCase=fe.snakeCase;b.some=Ye.some;b.sortedIndex=O.sortedIndex;b.sortedIndexBy=O.sortedIndexBy;b.sortedIndexOf=O.sortedIndexOf;b.sortedLastIndex=O.sortedLastIndex;b.sortedLastIndexBy=O.sortedLastIndexBy;b.sortedLastIndexOf=O.sortedLastIndexOf;b.startCase=fe.startCase;b.startsWith=fe.startsWith;b.subtract=hi.subtract;b.sum=hi.sum;b.sumBy=hi.sumBy;b.template=fe.template;b.times=ke.times;b.toFinite=Q.toFinite;b.toInteger=re;b.toLength=Q.toLength;b.toLower=fe.toLower;b.toNumber=Q.toNumber;b.toSafeInteger=Q.toSafeInteger;b.toString=Q.toString;b.toUpper=fe.toUpper;b.trim=fe.trim;b.trimEnd=fe.trimEnd;b.trimStart=fe.trimStart;b.truncate=fe.truncate;b.unescape=fe.unescape;b.uniqueId=ke.uniqueId;b.upperCase=fe.upperCase;b.upperFirst=fe.upperFirst;b.each=Ye.forEach;b.eachRight=Ye.forEachRight;b.first=O.head;Uc(b,(function(){var e={};return Jn(b,function(i,n){cL.call(b.prototype,n)||(e[n]=i)}),e})(),{chain:!1});b.VERSION=Bue;(b.templateSettings=fe.templateSettings).imports._=b;Xi(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){b[e].placeholder=b});Xi(["drop","take"],function(e,i){pe.prototype[e]=function(n){n=n===void 0?1:Eue(re(n),0);var o=this.__filtered__&&!i?new pe(this):this.clone();return o.__filtered__?o.__takeCount__=_0(n,o.__takeCount__):o.__views__.push({size:_0(n,hL),type:e+(o.__dir__<0?"Right":"")}),o},pe.prototype[e+"Right"]=function(n){return this.reverse()[e](n).reverse()}});Xi(["filter","map","takeWhile"],function(e,i){var n=i+1,o=n==Hue||n==Mue;pe.prototype[e]=function(a){var t=this.clone();return t.__iteratees__.push({iteratee:ie(a),type:n}),t.__filtered__=t.__filtered__||o,t}});Xi(["head","last"],function(e,i){var n="take"+(i?"Right":"");pe.prototype[e]=function(){return this[n](1).value()[0]}});Xi(["initial","tail"],function(e,i){var n="drop"+(i?"":"Right");pe.prototype[e]=function(){return this.__filtered__?new pe(this):this[n](1)}});pe.prototype.compact=function(){return this.filter(wi)};pe.prototype.find=function(e){return this.filter(e).head()};pe.prototype.findLast=function(e){return this.reverse().find(e)};pe.prototype.invokeMap=de(function(e,i){return typeof e=="function"?new pe(this):this.map(function(n){return Es(n,e,i)})});pe.prototype.reject=function(e){return this.filter(_u(ie(e)))};pe.prototype.slice=function(e,i){e=re(e);var n=this;return n.__filtered__&&(e>0||i<0)?new pe(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),i!==void 0&&(i=re(i),n=i<0?n.dropRight(-i):n.take(i-e)),n)};pe.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()};pe.prototype.toArray=function(){return this.take(hL)};Jn(pe.prototype,function(e,i){var n=/^(?:filter|find|map|reject)|While$/.test(i),o=/^(?:head|last)$/.test(i),a=b[o?"take"+(i=="last"?"Right":""):i],t=o||/^find/.test(i);a&&(b.prototype[i]=function(){var s=this.__wrapped__,r=o?[1]:arguments,u=s instanceof pe,d=r[0],l=u||ae(s),g=function(v){var j=a.apply(b,Yo([v],r));return o&&h?j[0]:j};l&&n&&typeof d=="function"&&d.length!=1&&(u=l=!1);var h=this.__chain__,c=!!this.__actions__.length,p=t&&!h,f=u&&!c;if(!t&&l){s=f?s:new pe(this);var w=e.apply(s,r);return w.__actions__.push({func:Uu,args:[g],thisArg:void 0}),new zi(w,h)}return p&&f?e.apply(this,r):(w=this.thru(g),p?o?w.value()[0]:w.value():w)})});Xi(["pop","push","shift","sort","splice","unshift"],function(e){var i=Pue[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",o=/^(?:pop|shift)$/.test(e);b.prototype[e]=function(){var a=arguments;if(o&&!this.__chain__){var t=this.value();return i.apply(ae(t)?t:[],a)}return this[n](function(s){return i.apply(ae(s)?s:[],a)})}});Jn(pe.prototype,function(e,i){var n=b[i];if(n){var o=n.name+"";cL.call(Da,o)||(Da[o]=[]),Da[o].push({name:i,func:n})}});Da[Du(void 0,Xue).name]=[{name:"wrapper",func:void 0}];pe.prototype.clone=Lue;pe.prototype.reverse=Cue;pe.prototype.value=Due;b.prototype.at=Tn.at;b.prototype.chain=Tn.wrapperChain;b.prototype.commit=Tn.commit;b.prototype.next=Tn.next;b.prototype.plant=Tn.plant;b.prototype.reverse=Tn.reverse;b.prototype.toJSON=b.prototype.valueOf=b.prototype.value=Tn.value;b.prototype.first=b.prototype.head;I0&&(b.prototype[I0]=Tn.toIterator);var ka=function(){return ka=Object.assign||function(e){for(var i,n=1,o=arguments.length;n<o;n++){i=arguments[n];for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(e[a]=i[a])}return e},ka.apply(this,arguments)},Rue="~",Oue="~~";function Vc(e,i){for(var n={},o={},a=e.split(Oue),t=!1,s=0;a.length>s;s++){for(var r=a[s].split(Rue),u=0;u<r.length;u+=2){var d=r[u],l=r[u+1],g="&"+d+";";n[g]=l,t&&(n["&"+d]=l),o[l]=g}t=!0}return i?{entities:ka(ka({},n),i.entities),characters:ka(ka({},o),i.characters)}:{entities:n,characters:o}}var nl={xml:/&(?:#\d+|#[xX][\da-fA-F]+|[0-9a-zA-Z]+);?/g,html4:/&notin;|&(?:nbsp|iexcl|cent|pound|curren|yen|brvbar|sect|uml|copy|ordf|laquo|not|shy|reg|macr|deg|plusmn|sup2|sup3|acute|micro|para|middot|cedil|sup1|ordm|raquo|frac14|frac12|frac34|iquest|Agrave|Aacute|Acirc|Atilde|Auml|Aring|AElig|Ccedil|Egrave|Eacute|Ecirc|Euml|Igrave|Iacute|Icirc|Iuml|ETH|Ntilde|Ograve|Oacute|Ocirc|Otilde|Ouml|times|Oslash|Ugrave|Uacute|Ucirc|Uuml|Yacute|THORN|szlig|agrave|aacute|acirc|atilde|auml|aring|aelig|ccedil|egrave|eacute|ecirc|euml|igrave|iacute|icirc|iuml|eth|ntilde|ograve|oacute|ocirc|otilde|ouml|divide|oslash|ugrave|uacute|ucirc|uuml|yacute|thorn|yuml|quot|amp|lt|gt|#\d+|#[xX][\da-fA-F]+|[0-9a-zA-Z]+);?/g,html5:/&centerdot;|&copysr;|&divideontimes;|&gtcc;|&gtcir;|&gtdot;|&gtlPar;|&gtquest;|&gtrapprox;|&gtrarr;|&gtrdot;|&gtreqless;|&gtreqqless;|&gtrless;|&gtrsim;|&ltcc;|&ltcir;|&ltdot;|&lthree;|&ltimes;|&ltlarr;|&ltquest;|&ltrPar;|&ltri;|&ltrie;|&ltrif;|&notin;|&notinE;|&notindot;|&notinva;|&notinvb;|&notinvc;|&notni;|&notniva;|&notnivb;|&notnivc;|&parallel;|&timesb;|&timesbar;|&timesd;|&(?:AElig|AMP|Aacute|Acirc|Agrave|Aring|Atilde|Auml|COPY|Ccedil|ETH|Eacute|Ecirc|Egrave|Euml|GT|Iacute|Icirc|Igrave|Iuml|LT|Ntilde|Oacute|Ocirc|Ograve|Oslash|Otilde|Ouml|QUOT|REG|THORN|Uacute|Ucirc|Ugrave|Uuml|Yacute|aacute|acirc|acute|aelig|agrave|amp|aring|atilde|auml|brvbar|ccedil|cedil|cent|copy|curren|deg|divide|eacute|ecirc|egrave|eth|euml|frac12|frac14|frac34|gt|iacute|icirc|iexcl|igrave|iquest|iuml|laquo|lt|macr|micro|middot|nbsp|not|ntilde|oacute|ocirc|ograve|ordf|ordm|oslash|otilde|ouml|para|plusmn|pound|quot|raquo|reg|sect|shy|sup1|sup2|sup3|szlig|thorn|times|uacute|ucirc|ugrave|uml|uuml|yacute|yen|yuml|#\d+|#[xX][\da-fA-F]+|[0-9a-zA-Z]+);?/g},Aa={};Aa.xml=Vc(`lt~<~gt~>~quot~"~apos~'~amp~&`);Aa.html4=Vc(`apos~'~OElig~Œ~oelig~œ~Scaron~Š~scaron~š~Yuml~Ÿ~circ~ˆ~tilde~˜~ensp~ ~emsp~ ~thinsp~ ~zwnj~‌~zwj~‍~lrm~‎~rlm~‏~ndash~–~mdash~—~lsquo~‘~rsquo~’~sbquo~‚~ldquo~“~rdquo~”~bdquo~„~dagger~†~Dagger~‡~permil~‰~lsaquo~‹~rsaquo~›~euro~€~fnof~ƒ~Alpha~Α~Beta~Β~Gamma~Γ~Delta~Δ~Epsilon~Ε~Zeta~Ζ~Eta~Η~Theta~Θ~Iota~Ι~Kappa~Κ~Lambda~Λ~Mu~Μ~Nu~Ν~Xi~Ξ~Omicron~Ο~Pi~Π~Rho~Ρ~Sigma~Σ~Tau~Τ~Upsilon~Υ~Phi~Φ~Chi~Χ~Psi~Ψ~Omega~Ω~alpha~α~beta~β~gamma~γ~delta~δ~epsilon~ε~zeta~ζ~eta~η~theta~θ~iota~ι~kappa~κ~lambda~λ~mu~μ~nu~ν~xi~ξ~omicron~ο~pi~π~rho~ρ~sigmaf~ς~sigma~σ~tau~τ~upsilon~υ~phi~φ~chi~χ~psi~ψ~omega~ω~thetasym~ϑ~upsih~ϒ~piv~ϖ~bull~•~hellip~…~prime~′~Prime~″~oline~‾~frasl~⁄~weierp~℘~image~ℑ~real~ℜ~trade~™~alefsym~ℵ~larr~←~uarr~↑~rarr~→~darr~↓~harr~↔~crarr~↵~lArr~⇐~uArr~⇑~rArr~⇒~dArr~⇓~hArr~⇔~forall~∀~part~∂~exist~∃~empty~∅~nabla~∇~isin~∈~notin~∉~ni~∋~prod~∏~sum~∑~minus~−~lowast~∗~radic~√~prop~∝~infin~∞~ang~∠~and~∧~or~∨~cap~∩~cup~∪~int~∫~there4~∴~sim~∼~cong~≅~asymp~≈~ne~≠~equiv~≡~le~≤~ge~≥~sub~⊂~sup~⊃~nsub~⊄~sube~⊆~supe~⊇~oplus~⊕~otimes~⊗~perp~⊥~sdot~⋅~lceil~⌈~rceil~⌉~lfloor~⌊~rfloor~⌋~lang~〈~rang~〉~loz~◊~spades~♠~clubs~♣~hearts~♥~diams~♦~~nbsp~ ~iexcl~¡~cent~¢~pound~£~curren~¤~yen~¥~brvbar~¦~sect~§~uml~¨~copy~©~ordf~ª~laquo~«~not~¬~shy~­~reg~®~macr~¯~deg~°~plusmn~±~sup2~²~sup3~³~acute~´~micro~µ~para~¶~middot~·~cedil~¸~sup1~¹~ordm~º~raquo~»~frac14~¼~frac12~½~frac34~¾~iquest~¿~Agrave~À~Aacute~Á~Acirc~Â~Atilde~Ã~Auml~Ä~Aring~Å~AElig~Æ~Ccedil~Ç~Egrave~È~Eacute~É~Ecirc~Ê~Euml~Ë~Igrave~Ì~Iacute~Í~Icirc~Î~Iuml~Ï~ETH~Ð~Ntilde~Ñ~Ograve~Ò~Oacute~Ó~Ocirc~Ô~Otilde~Õ~Ouml~Ö~times~×~Oslash~Ø~Ugrave~Ù~Uacute~Ú~Ucirc~Û~Uuml~Ü~Yacute~Ý~THORN~Þ~szlig~ß~agrave~à~aacute~á~acirc~â~atilde~ã~auml~ä~aring~å~aelig~æ~ccedil~ç~egrave~è~eacute~é~ecirc~ê~euml~ë~igrave~ì~iacute~í~icirc~î~iuml~ï~eth~ð~ntilde~ñ~ograve~ò~oacute~ó~ocirc~ô~otilde~õ~ouml~ö~divide~÷~oslash~ø~ugrave~ù~uacute~ú~ucirc~û~uuml~ü~yacute~ý~thorn~þ~yuml~ÿ~quot~"~amp~&~lt~<~gt~>`);Aa.html5=Vc('Abreve~Ă~Acy~А~Afr~𝔄~Amacr~Ā~And~⩓~Aogon~Ą~Aopf~𝔸~ApplyFunction~⁡~Ascr~𝒜~Assign~≔~Backslash~∖~Barv~⫧~Barwed~⌆~Bcy~Б~Because~∵~Bernoullis~ℬ~Bfr~𝔅~Bopf~𝔹~Breve~˘~Bscr~ℬ~Bumpeq~≎~CHcy~Ч~Cacute~Ć~Cap~⋒~CapitalDifferentialD~ⅅ~Cayleys~ℭ~Ccaron~Č~Ccirc~Ĉ~Cconint~∰~Cdot~Ċ~Cedilla~¸~CenterDot~·~Cfr~ℭ~CircleDot~⊙~CircleMinus~⊖~CirclePlus~⊕~CircleTimes~⊗~ClockwiseContourIntegral~∲~CloseCurlyDoubleQuote~”~CloseCurlyQuote~’~Colon~∷~Colone~⩴~Congruent~≡~Conint~∯~ContourIntegral~∮~Copf~ℂ~Coproduct~∐~CounterClockwiseContourIntegral~∳~Cross~⨯~Cscr~𝒞~Cup~⋓~CupCap~≍~DD~ⅅ~DDotrahd~⤑~DJcy~Ђ~DScy~Ѕ~DZcy~Џ~Darr~↡~Dashv~⫤~Dcaron~Ď~Dcy~Д~Del~∇~Dfr~𝔇~DiacriticalAcute~´~DiacriticalDot~˙~DiacriticalDoubleAcute~˝~DiacriticalGrave~`~DiacriticalTilde~˜~Diamond~⋄~DifferentialD~ⅆ~Dopf~𝔻~Dot~¨~DotDot~⃜~DotEqual~≐~DoubleContourIntegral~∯~DoubleDot~¨~DoubleDownArrow~⇓~DoubleLeftArrow~⇐~DoubleLeftRightArrow~⇔~DoubleLeftTee~⫤~DoubleLongLeftArrow~⟸~DoubleLongLeftRightArrow~⟺~DoubleLongRightArrow~⟹~DoubleRightArrow~⇒~DoubleRightTee~⊨~DoubleUpArrow~⇑~DoubleUpDownArrow~⇕~DoubleVerticalBar~∥~DownArrow~↓~DownArrowBar~⤓~DownArrowUpArrow~⇵~DownBreve~̑~DownLeftRightVector~⥐~DownLeftTeeVector~⥞~DownLeftVector~↽~DownLeftVectorBar~⥖~DownRightTeeVector~⥟~DownRightVector~⇁~DownRightVectorBar~⥗~DownTee~⊤~DownTeeArrow~↧~Downarrow~⇓~Dscr~𝒟~Dstrok~Đ~ENG~Ŋ~Ecaron~Ě~Ecy~Э~Edot~Ė~Efr~𝔈~Element~∈~Emacr~Ē~EmptySmallSquare~◻~EmptyVerySmallSquare~▫~Eogon~Ę~Eopf~𝔼~Equal~⩵~EqualTilde~≂~Equilibrium~⇌~Escr~ℰ~Esim~⩳~Exists~∃~ExponentialE~ⅇ~Fcy~Ф~Ffr~𝔉~FilledSmallSquare~◼~FilledVerySmallSquare~▪~Fopf~𝔽~ForAll~∀~Fouriertrf~ℱ~Fscr~ℱ~GJcy~Ѓ~Gammad~Ϝ~Gbreve~Ğ~Gcedil~Ģ~Gcirc~Ĝ~Gcy~Г~Gdot~Ġ~Gfr~𝔊~Gg~⋙~Gopf~𝔾~GreaterEqual~≥~GreaterEqualLess~⋛~GreaterFullEqual~≧~GreaterGreater~⪢~GreaterLess~≷~GreaterSlantEqual~⩾~GreaterTilde~≳~Gscr~𝒢~Gt~≫~HARDcy~Ъ~Hacek~ˇ~Hat~^~Hcirc~Ĥ~Hfr~ℌ~HilbertSpace~ℋ~Hopf~ℍ~HorizontalLine~─~Hscr~ℋ~Hstrok~Ħ~HumpDownHump~≎~HumpEqual~≏~IEcy~Е~IJlig~IJ~IOcy~Ё~Icy~И~Idot~İ~Ifr~ℑ~Im~ℑ~Imacr~Ī~ImaginaryI~ⅈ~Implies~⇒~Int~∬~Integral~∫~Intersection~⋂~InvisibleComma~⁣~InvisibleTimes~⁢~Iogon~Į~Iopf~𝕀~Iscr~ℐ~Itilde~Ĩ~Iukcy~І~Jcirc~Ĵ~Jcy~Й~Jfr~𝔍~Jopf~𝕁~Jscr~𝒥~Jsercy~Ј~Jukcy~Є~KHcy~Х~KJcy~Ќ~Kcedil~Ķ~Kcy~К~Kfr~𝔎~Kopf~𝕂~Kscr~𝒦~LJcy~Љ~Lacute~Ĺ~Lang~⟪~Laplacetrf~ℒ~Larr~↞~Lcaron~Ľ~Lcedil~Ļ~Lcy~Л~LeftAngleBracket~⟨~LeftArrow~←~LeftArrowBar~⇤~LeftArrowRightArrow~⇆~LeftCeiling~⌈~LeftDoubleBracket~⟦~LeftDownTeeVector~⥡~LeftDownVector~⇃~LeftDownVectorBar~⥙~LeftFloor~⌊~LeftRightArrow~↔~LeftRightVector~⥎~LeftTee~⊣~LeftTeeArrow~↤~LeftTeeVector~⥚~LeftTriangle~⊲~LeftTriangleBar~⧏~LeftTriangleEqual~⊴~LeftUpDownVector~⥑~LeftUpTeeVector~⥠~LeftUpVector~↿~LeftUpVectorBar~⥘~LeftVector~↼~LeftVectorBar~⥒~Leftarrow~⇐~Leftrightarrow~⇔~LessEqualGreater~⋚~LessFullEqual~≦~LessGreater~≶~LessLess~⪡~LessSlantEqual~⩽~LessTilde~≲~Lfr~𝔏~Ll~⋘~Lleftarrow~⇚~Lmidot~Ŀ~LongLeftArrow~⟵~LongLeftRightArrow~⟷~LongRightArrow~⟶~Longleftarrow~⟸~Longleftrightarrow~⟺~Longrightarrow~⟹~Lopf~𝕃~LowerLeftArrow~↙~LowerRightArrow~↘~Lscr~ℒ~Lsh~↰~Lstrok~Ł~Lt~≪~Map~⤅~Mcy~М~MediumSpace~ ~Mellintrf~ℳ~Mfr~𝔐~MinusPlus~∓~Mopf~𝕄~Mscr~ℳ~NJcy~Њ~Nacute~Ń~Ncaron~Ň~Ncedil~Ņ~Ncy~Н~NegativeMediumSpace~​~NegativeThickSpace~​~NegativeThinSpace~​~NegativeVeryThinSpace~​~NestedGreaterGreater~≫~NestedLessLess~≪~NewLine~\n~Nfr~𝔑~NoBreak~⁠~NonBreakingSpace~ ~Nopf~ℕ~Not~⫬~NotCongruent~≢~NotCupCap~≭~NotDoubleVerticalBar~∦~NotElement~∉~NotEqual~≠~NotEqualTilde~≂̸~NotExists~∄~NotGreater~≯~NotGreaterEqual~≱~NotGreaterFullEqual~≧̸~NotGreaterGreater~≫̸~NotGreaterLess~≹~NotGreaterSlantEqual~⩾̸~NotGreaterTilde~≵~NotHumpDownHump~≎̸~NotHumpEqual~≏̸~NotLeftTriangle~⋪~NotLeftTriangleBar~⧏̸~NotLeftTriangleEqual~⋬~NotLess~≮~NotLessEqual~≰~NotLessGreater~≸~NotLessLess~≪̸~NotLessSlantEqual~⩽̸~NotLessTilde~≴~NotNestedGreaterGreater~⪢̸~NotNestedLessLess~⪡̸~NotPrecedes~⊀~NotPrecedesEqual~⪯̸~NotPrecedesSlantEqual~⋠~NotReverseElement~∌~NotRightTriangle~⋫~NotRightTriangleBar~⧐̸~NotRightTriangleEqual~⋭~NotSquareSubset~⊏̸~NotSquareSubsetEqual~⋢~NotSquareSuperset~⊐̸~NotSquareSupersetEqual~⋣~NotSubset~⊂⃒~NotSubsetEqual~⊈~NotSucceeds~⊁~NotSucceedsEqual~⪰̸~NotSucceedsSlantEqual~⋡~NotSucceedsTilde~≿̸~NotSuperset~⊃⃒~NotSupersetEqual~⊉~NotTilde~≁~NotTildeEqual~≄~NotTildeFullEqual~≇~NotTildeTilde~≉~NotVerticalBar~∤~Nscr~𝒩~Ocy~О~Odblac~Ő~Ofr~𝔒~Omacr~Ō~Oopf~𝕆~OpenCurlyDoubleQuote~“~OpenCurlyQuote~‘~Or~⩔~Oscr~𝒪~Otimes~⨷~OverBar~‾~OverBrace~⏞~OverBracket~⎴~OverParenthesis~⏜~PartialD~∂~Pcy~П~Pfr~𝔓~PlusMinus~±~Poincareplane~ℌ~Popf~ℙ~Pr~⪻~Precedes~≺~PrecedesEqual~⪯~PrecedesSlantEqual~≼~PrecedesTilde~≾~Product~∏~Proportion~∷~Proportional~∝~Pscr~𝒫~Qfr~𝔔~Qopf~ℚ~Qscr~𝒬~RBarr~⤐~Racute~Ŕ~Rang~⟫~Rarr~↠~Rarrtl~⤖~Rcaron~Ř~Rcedil~Ŗ~Rcy~Р~Re~ℜ~ReverseElement~∋~ReverseEquilibrium~⇋~ReverseUpEquilibrium~⥯~Rfr~ℜ~RightAngleBracket~⟩~RightArrow~→~RightArrowBar~⇥~RightArrowLeftArrow~⇄~RightCeiling~⌉~RightDoubleBracket~⟧~RightDownTeeVector~⥝~RightDownVector~⇂~RightDownVectorBar~⥕~RightFloor~⌋~RightTee~⊢~RightTeeArrow~↦~RightTeeVector~⥛~RightTriangle~⊳~RightTriangleBar~⧐~RightTriangleEqual~⊵~RightUpDownVector~⥏~RightUpTeeVector~⥜~RightUpVector~↾~RightUpVectorBar~⥔~RightVector~⇀~RightVectorBar~⥓~Rightarrow~⇒~Ropf~ℝ~RoundImplies~⥰~Rrightarrow~⇛~Rscr~ℛ~Rsh~↱~RuleDelayed~⧴~SHCHcy~Щ~SHcy~Ш~SOFTcy~Ь~Sacute~Ś~Sc~⪼~Scedil~Ş~Scirc~Ŝ~Scy~С~Sfr~𝔖~ShortDownArrow~↓~ShortLeftArrow~←~ShortRightArrow~→~ShortUpArrow~↑~SmallCircle~∘~Sopf~𝕊~Sqrt~√~Square~□~SquareIntersection~⊓~SquareSubset~⊏~SquareSubsetEqual~⊑~SquareSuperset~⊐~SquareSupersetEqual~⊒~SquareUnion~⊔~Sscr~𝒮~Star~⋆~Sub~⋐~Subset~⋐~SubsetEqual~⊆~Succeeds~≻~SucceedsEqual~⪰~SucceedsSlantEqual~≽~SucceedsTilde~≿~SuchThat~∋~Sum~∑~Sup~⋑~Superset~⊃~SupersetEqual~⊇~Supset~⋑~TRADE~™~TSHcy~Ћ~TScy~Ц~Tab~ ~Tcaron~Ť~Tcedil~Ţ~Tcy~Т~Tfr~𝔗~Therefore~∴~ThickSpace~  ~ThinSpace~ ~Tilde~∼~TildeEqual~≃~TildeFullEqual~≅~TildeTilde~≈~Topf~𝕋~TripleDot~⃛~Tscr~𝒯~Tstrok~Ŧ~Uarr~↟~Uarrocir~⥉~Ubrcy~Ў~Ubreve~Ŭ~Ucy~У~Udblac~Ű~Ufr~𝔘~Umacr~Ū~UnderBar~_~UnderBrace~⏟~UnderBracket~⎵~UnderParenthesis~⏝~Union~⋃~UnionPlus~⊎~Uogon~Ų~Uopf~𝕌~UpArrow~↑~UpArrowBar~⤒~UpArrowDownArrow~⇅~UpDownArrow~↕~UpEquilibrium~⥮~UpTee~⊥~UpTeeArrow~↥~Uparrow~⇑~Updownarrow~⇕~UpperLeftArrow~↖~UpperRightArrow~↗~Upsi~ϒ~Uring~Ů~Uscr~𝒰~Utilde~Ũ~VDash~⊫~Vbar~⫫~Vcy~В~Vdash~⊩~Vdashl~⫦~Vee~⋁~Verbar~‖~Vert~‖~VerticalBar~∣~VerticalLine~|~VerticalSeparator~❘~VerticalTilde~≀~VeryThinSpace~ ~Vfr~𝔙~Vopf~𝕍~Vscr~𝒱~Vvdash~⊪~Wcirc~Ŵ~Wedge~⋀~Wfr~𝔚~Wopf~𝕎~Wscr~𝒲~Xfr~𝔛~Xopf~𝕏~Xscr~𝒳~YAcy~Я~YIcy~Ї~YUcy~Ю~Ycirc~Ŷ~Ycy~Ы~Yfr~𝔜~Yopf~𝕐~Yscr~𝒴~ZHcy~Ж~Zacute~Ź~Zcaron~Ž~Zcy~З~Zdot~Ż~ZeroWidthSpace~​~Zfr~ℨ~Zopf~ℤ~Zscr~𝒵~abreve~ă~ac~∾~acE~∾̳~acd~∿~acy~а~af~⁡~afr~𝔞~aleph~ℵ~amacr~ā~amalg~⨿~andand~⩕~andd~⩜~andslope~⩘~andv~⩚~ange~⦤~angle~∠~angmsd~∡~angmsdaa~⦨~angmsdab~⦩~angmsdac~⦪~angmsdad~⦫~angmsdae~⦬~angmsdaf~⦭~angmsdag~⦮~angmsdah~⦯~angrt~∟~angrtvb~⊾~angrtvbd~⦝~angsph~∢~angst~Å~angzarr~⍼~aogon~ą~aopf~𝕒~ap~≈~apE~⩰~apacir~⩯~ape~≊~apid~≋~approx~≈~approxeq~≊~ascr~𝒶~ast~*~asympeq~≍~awconint~∳~awint~⨑~bNot~⫭~backcong~≌~backepsilon~϶~backprime~‵~backsim~∽~backsimeq~⋍~barvee~⊽~barwed~⌅~barwedge~⌅~bbrk~⎵~bbrktbrk~⎶~bcong~≌~bcy~б~becaus~∵~because~∵~bemptyv~⦰~bepsi~϶~bernou~ℬ~beth~ℶ~between~≬~bfr~𝔟~bigcap~⋂~bigcirc~◯~bigcup~⋃~bigodot~⨀~bigoplus~⨁~bigotimes~⨂~bigsqcup~⨆~bigstar~★~bigtriangledown~▽~bigtriangleup~△~biguplus~⨄~bigvee~⋁~bigwedge~⋀~bkarow~⤍~blacklozenge~⧫~blacksquare~▪~blacktriangle~▴~blacktriangledown~▾~blacktriangleleft~◂~blacktriangleright~▸~blank~␣~blk12~▒~blk14~░~blk34~▓~block~█~bne~=⃥~bnequiv~≡⃥~bnot~⌐~bopf~𝕓~bot~⊥~bottom~⊥~bowtie~⋈~boxDL~╗~boxDR~╔~boxDl~╖~boxDr~╓~boxH~═~boxHD~╦~boxHU~╩~boxHd~╤~boxHu~╧~boxUL~╝~boxUR~╚~boxUl~╜~boxUr~╙~boxV~║~boxVH~╬~boxVL~╣~boxVR~╠~boxVh~╫~boxVl~╢~boxVr~╟~boxbox~⧉~boxdL~╕~boxdR~╒~boxdl~┐~boxdr~┌~boxh~─~boxhD~╥~boxhU~╨~boxhd~┬~boxhu~┴~boxminus~⊟~boxplus~⊞~boxtimes~⊠~boxuL~╛~boxuR~╘~boxul~┘~boxur~└~boxv~│~boxvH~╪~boxvL~╡~boxvR~╞~boxvh~┼~boxvl~┤~boxvr~├~bprime~‵~breve~˘~bscr~𝒷~bsemi~⁏~bsim~∽~bsime~⋍~bsol~\\~bsolb~⧅~bsolhsub~⟈~bullet~•~bump~≎~bumpE~⪮~bumpe~≏~bumpeq~≏~cacute~ć~capand~⩄~capbrcup~⩉~capcap~⩋~capcup~⩇~capdot~⩀~caps~∩︀~caret~⁁~caron~ˇ~ccaps~⩍~ccaron~č~ccirc~ĉ~ccups~⩌~ccupssm~⩐~cdot~ċ~cemptyv~⦲~centerdot~·~cfr~𝔠~chcy~ч~check~✓~checkmark~✓~cir~○~cirE~⧃~circeq~≗~circlearrowleft~↺~circlearrowright~↻~circledR~®~circledS~Ⓢ~circledast~⊛~circledcirc~⊚~circleddash~⊝~cire~≗~cirfnint~⨐~cirmid~⫯~cirscir~⧂~clubsuit~♣~colon~:~colone~≔~coloneq~≔~comma~,~commat~@~comp~∁~compfn~∘~complement~∁~complexes~ℂ~congdot~⩭~conint~∮~copf~𝕔~coprod~∐~copysr~℗~cross~✗~cscr~𝒸~csub~⫏~csube~⫑~csup~⫐~csupe~⫒~ctdot~⋯~cudarrl~⤸~cudarrr~⤵~cuepr~⋞~cuesc~⋟~cularr~↶~cularrp~⤽~cupbrcap~⩈~cupcap~⩆~cupcup~⩊~cupdot~⊍~cupor~⩅~cups~∪︀~curarr~↷~curarrm~⤼~curlyeqprec~⋞~curlyeqsucc~⋟~curlyvee~⋎~curlywedge~⋏~curvearrowleft~↶~curvearrowright~↷~cuvee~⋎~cuwed~⋏~cwconint~∲~cwint~∱~cylcty~⌭~dHar~⥥~daleth~ℸ~dash~‐~dashv~⊣~dbkarow~⤏~dblac~˝~dcaron~ď~dcy~д~dd~ⅆ~ddagger~‡~ddarr~⇊~ddotseq~⩷~demptyv~⦱~dfisht~⥿~dfr~𝔡~dharl~⇃~dharr~⇂~diam~⋄~diamond~⋄~diamondsuit~♦~die~¨~digamma~ϝ~disin~⋲~div~÷~divideontimes~⋇~divonx~⋇~djcy~ђ~dlcorn~⌞~dlcrop~⌍~dollar~$~dopf~𝕕~dot~˙~doteq~≐~doteqdot~≑~dotminus~∸~dotplus~∔~dotsquare~⊡~doublebarwedge~⌆~downarrow~↓~downdownarrows~⇊~downharpoonleft~⇃~downharpoonright~⇂~drbkarow~⤐~drcorn~⌟~drcrop~⌌~dscr~𝒹~dscy~ѕ~dsol~⧶~dstrok~đ~dtdot~⋱~dtri~▿~dtrif~▾~duarr~⇵~duhar~⥯~dwangle~⦦~dzcy~џ~dzigrarr~⟿~eDDot~⩷~eDot~≑~easter~⩮~ecaron~ě~ecir~≖~ecolon~≕~ecy~э~edot~ė~ee~ⅇ~efDot~≒~efr~𝔢~eg~⪚~egs~⪖~egsdot~⪘~el~⪙~elinters~⏧~ell~ℓ~els~⪕~elsdot~⪗~emacr~ē~emptyset~∅~emptyv~∅~emsp13~ ~emsp14~ ~eng~ŋ~eogon~ę~eopf~𝕖~epar~⋕~eparsl~⧣~eplus~⩱~epsi~ε~epsiv~ϵ~eqcirc~≖~eqcolon~≕~eqsim~≂~eqslantgtr~⪖~eqslantless~⪕~equals~=~equest~≟~equivDD~⩸~eqvparsl~⧥~erDot~≓~erarr~⥱~escr~ℯ~esdot~≐~esim~≂~excl~!~expectation~ℰ~exponentiale~ⅇ~fallingdotseq~≒~fcy~ф~female~♀~ffilig~ffi~fflig~ff~ffllig~ffl~ffr~𝔣~filig~fi~fjlig~fj~flat~♭~fllig~fl~fltns~▱~fopf~𝕗~fork~⋔~forkv~⫙~fpartint~⨍~frac13~⅓~frac15~⅕~frac16~⅙~frac18~⅛~frac23~⅔~frac25~⅖~frac35~⅗~frac38~⅜~frac45~⅘~frac56~⅚~frac58~⅝~frac78~⅞~frown~⌢~fscr~𝒻~gE~≧~gEl~⪌~gacute~ǵ~gammad~ϝ~gap~⪆~gbreve~ğ~gcirc~ĝ~gcy~г~gdot~ġ~gel~⋛~geq~≥~geqq~≧~geqslant~⩾~ges~⩾~gescc~⪩~gesdot~⪀~gesdoto~⪂~gesdotol~⪄~gesl~⋛︀~gesles~⪔~gfr~𝔤~gg~≫~ggg~⋙~gimel~ℷ~gjcy~ѓ~gl~≷~glE~⪒~gla~⪥~glj~⪤~gnE~≩~gnap~⪊~gnapprox~⪊~gne~⪈~gneq~⪈~gneqq~≩~gnsim~⋧~gopf~𝕘~grave~`~gscr~ℊ~gsim~≳~gsime~⪎~gsiml~⪐~gtcc~⪧~gtcir~⩺~gtdot~⋗~gtlPar~⦕~gtquest~⩼~gtrapprox~⪆~gtrarr~⥸~gtrdot~⋗~gtreqless~⋛~gtreqqless~⪌~gtrless~≷~gtrsim~≳~gvertneqq~≩︀~gvnE~≩︀~hairsp~ ~half~½~hamilt~ℋ~hardcy~ъ~harrcir~⥈~harrw~↭~hbar~ℏ~hcirc~ĥ~heartsuit~♥~hercon~⊹~hfr~𝔥~hksearow~⤥~hkswarow~⤦~hoarr~⇿~homtht~∻~hookleftarrow~↩~hookrightarrow~↪~hopf~𝕙~horbar~―~hscr~𝒽~hslash~ℏ~hstrok~ħ~hybull~⁃~hyphen~‐~ic~⁣~icy~и~iecy~е~iff~⇔~ifr~𝔦~ii~ⅈ~iiiint~⨌~iiint~∭~iinfin~⧜~iiota~℩~ijlig~ij~imacr~ī~imagline~ℐ~imagpart~ℑ~imath~ı~imof~⊷~imped~Ƶ~in~∈~incare~℅~infintie~⧝~inodot~ı~intcal~⊺~integers~ℤ~intercal~⊺~intlarhk~⨗~intprod~⨼~iocy~ё~iogon~į~iopf~𝕚~iprod~⨼~iscr~𝒾~isinE~⋹~isindot~⋵~isins~⋴~isinsv~⋳~isinv~∈~it~⁢~itilde~ĩ~iukcy~і~jcirc~ĵ~jcy~й~jfr~𝔧~jmath~ȷ~jopf~𝕛~jscr~𝒿~jsercy~ј~jukcy~є~kappav~ϰ~kcedil~ķ~kcy~к~kfr~𝔨~kgreen~ĸ~khcy~х~kjcy~ќ~kopf~𝕜~kscr~𝓀~lAarr~⇚~lAtail~⤛~lBarr~⤎~lE~≦~lEg~⪋~lHar~⥢~lacute~ĺ~laemptyv~⦴~lagran~ℒ~langd~⦑~langle~⟨~lap~⪅~larrb~⇤~larrbfs~⤟~larrfs~⤝~larrhk~↩~larrlp~↫~larrpl~⤹~larrsim~⥳~larrtl~↢~lat~⪫~latail~⤙~late~⪭~lates~⪭︀~lbarr~⤌~lbbrk~❲~lbrace~{~lbrack~[~lbrke~⦋~lbrksld~⦏~lbrkslu~⦍~lcaron~ľ~lcedil~ļ~lcub~{~lcy~л~ldca~⤶~ldquor~„~ldrdhar~⥧~ldrushar~⥋~ldsh~↲~leftarrow~←~leftarrowtail~↢~leftharpoondown~↽~leftharpoonup~↼~leftleftarrows~⇇~leftrightarrow~↔~leftrightarrows~⇆~leftrightharpoons~⇋~leftrightsquigarrow~↭~leftthreetimes~⋋~leg~⋚~leq~≤~leqq~≦~leqslant~⩽~les~⩽~lescc~⪨~lesdot~⩿~lesdoto~⪁~lesdotor~⪃~lesg~⋚︀~lesges~⪓~lessapprox~⪅~lessdot~⋖~lesseqgtr~⋚~lesseqqgtr~⪋~lessgtr~≶~lesssim~≲~lfisht~⥼~lfr~𝔩~lg~≶~lgE~⪑~lhard~↽~lharu~↼~lharul~⥪~lhblk~▄~ljcy~љ~ll~≪~llarr~⇇~llcorner~⌞~llhard~⥫~lltri~◺~lmidot~ŀ~lmoust~⎰~lmoustache~⎰~lnE~≨~lnap~⪉~lnapprox~⪉~lne~⪇~lneq~⪇~lneqq~≨~lnsim~⋦~loang~⟬~loarr~⇽~lobrk~⟦~longleftarrow~⟵~longleftrightarrow~⟷~longmapsto~⟼~longrightarrow~⟶~looparrowleft~↫~looparrowright~↬~lopar~⦅~lopf~𝕝~loplus~⨭~lotimes~⨴~lowbar~_~lozenge~◊~lozf~⧫~lpar~(~lparlt~⦓~lrarr~⇆~lrcorner~⌟~lrhar~⇋~lrhard~⥭~lrtri~⊿~lscr~𝓁~lsh~↰~lsim~≲~lsime~⪍~lsimg~⪏~lsqb~[~lsquor~‚~lstrok~ł~ltcc~⪦~ltcir~⩹~ltdot~⋖~lthree~⋋~ltimes~⋉~ltlarr~⥶~ltquest~⩻~ltrPar~⦖~ltri~◃~ltrie~⊴~ltrif~◂~lurdshar~⥊~luruhar~⥦~lvertneqq~≨︀~lvnE~≨︀~mDDot~∺~male~♂~malt~✠~maltese~✠~map~↦~mapsto~↦~mapstodown~↧~mapstoleft~↤~mapstoup~↥~marker~▮~mcomma~⨩~mcy~м~measuredangle~∡~mfr~𝔪~mho~℧~mid~∣~midast~*~midcir~⫰~minusb~⊟~minusd~∸~minusdu~⨪~mlcp~⫛~mldr~…~mnplus~∓~models~⊧~mopf~𝕞~mp~∓~mscr~𝓂~mstpos~∾~multimap~⊸~mumap~⊸~nGg~⋙̸~nGt~≫⃒~nGtv~≫̸~nLeftarrow~⇍~nLeftrightarrow~⇎~nLl~⋘̸~nLt~≪⃒~nLtv~≪̸~nRightarrow~⇏~nVDash~⊯~nVdash~⊮~nacute~ń~nang~∠⃒~nap~≉~napE~⩰̸~napid~≋̸~napos~ʼn~napprox~≉~natur~♮~natural~♮~naturals~ℕ~nbump~≎̸~nbumpe~≏̸~ncap~⩃~ncaron~ň~ncedil~ņ~ncong~≇~ncongdot~⩭̸~ncup~⩂~ncy~н~neArr~⇗~nearhk~⤤~nearr~↗~nearrow~↗~nedot~≐̸~nequiv~≢~nesear~⤨~nesim~≂̸~nexist~∄~nexists~∄~nfr~𝔫~ngE~≧̸~nge~≱~ngeq~≱~ngeqq~≧̸~ngeqslant~⩾̸~nges~⩾̸~ngsim~≵~ngt~≯~ngtr~≯~nhArr~⇎~nharr~↮~nhpar~⫲~nis~⋼~nisd~⋺~niv~∋~njcy~њ~nlArr~⇍~nlE~≦̸~nlarr~↚~nldr~‥~nle~≰~nleftarrow~↚~nleftrightarrow~↮~nleq~≰~nleqq~≦̸~nleqslant~⩽̸~nles~⩽̸~nless~≮~nlsim~≴~nlt~≮~nltri~⋪~nltrie~⋬~nmid~∤~nopf~𝕟~notinE~⋹̸~notindot~⋵̸~notinva~∉~notinvb~⋷~notinvc~⋶~notni~∌~notniva~∌~notnivb~⋾~notnivc~⋽~npar~∦~nparallel~∦~nparsl~⫽⃥~npart~∂̸~npolint~⨔~npr~⊀~nprcue~⋠~npre~⪯̸~nprec~⊀~npreceq~⪯̸~nrArr~⇏~nrarr~↛~nrarrc~⤳̸~nrarrw~↝̸~nrightarrow~↛~nrtri~⋫~nrtrie~⋭~nsc~⊁~nsccue~⋡~nsce~⪰̸~nscr~𝓃~nshortmid~∤~nshortparallel~∦~nsim~≁~nsime~≄~nsimeq~≄~nsmid~∤~nspar~∦~nsqsube~⋢~nsqsupe~⋣~nsubE~⫅̸~nsube~⊈~nsubset~⊂⃒~nsubseteq~⊈~nsubseteqq~⫅̸~nsucc~⊁~nsucceq~⪰̸~nsup~⊅~nsupE~⫆̸~nsupe~⊉~nsupset~⊃⃒~nsupseteq~⊉~nsupseteqq~⫆̸~ntgl~≹~ntlg~≸~ntriangleleft~⋪~ntrianglelefteq~⋬~ntriangleright~⋫~ntrianglerighteq~⋭~num~#~numero~№~numsp~ ~nvDash~⊭~nvHarr~⤄~nvap~≍⃒~nvdash~⊬~nvge~≥⃒~nvgt~>⃒~nvinfin~⧞~nvlArr~⤂~nvle~≤⃒~nvlt~<⃒~nvltrie~⊴⃒~nvrArr~⤃~nvrtrie~⊵⃒~nvsim~∼⃒~nwArr~⇖~nwarhk~⤣~nwarr~↖~nwarrow~↖~nwnear~⤧~oS~Ⓢ~oast~⊛~ocir~⊚~ocy~о~odash~⊝~odblac~ő~odiv~⨸~odot~⊙~odsold~⦼~ofcir~⦿~ofr~𝔬~ogon~˛~ogt~⧁~ohbar~⦵~ohm~Ω~oint~∮~olarr~↺~olcir~⦾~olcross~⦻~olt~⧀~omacr~ō~omid~⦶~ominus~⊖~oopf~𝕠~opar~⦷~operp~⦹~orarr~↻~ord~⩝~order~ℴ~orderof~ℴ~origof~⊶~oror~⩖~orslope~⩗~orv~⩛~oscr~ℴ~osol~⊘~otimesas~⨶~ovbar~⌽~par~∥~parallel~∥~parsim~⫳~parsl~⫽~pcy~п~percnt~%~period~.~pertenk~‱~pfr~𝔭~phiv~ϕ~phmmat~ℳ~phone~☎~pitchfork~⋔~planck~ℏ~planckh~ℎ~plankv~ℏ~plus~+~plusacir~⨣~plusb~⊞~pluscir~⨢~plusdo~∔~plusdu~⨥~pluse~⩲~plussim~⨦~plustwo~⨧~pm~±~pointint~⨕~popf~𝕡~pr~≺~prE~⪳~prap~⪷~prcue~≼~pre~⪯~prec~≺~precapprox~⪷~preccurlyeq~≼~preceq~⪯~precnapprox~⪹~precneqq~⪵~precnsim~⋨~precsim~≾~primes~ℙ~prnE~⪵~prnap~⪹~prnsim~⋨~profalar~⌮~profline~⌒~profsurf~⌓~propto~∝~prsim~≾~prurel~⊰~pscr~𝓅~puncsp~ ~qfr~𝔮~qint~⨌~qopf~𝕢~qprime~⁗~qscr~𝓆~quaternions~ℍ~quatint~⨖~quest~?~questeq~≟~rAarr~⇛~rAtail~⤜~rBarr~⤏~rHar~⥤~race~∽̱~racute~ŕ~raemptyv~⦳~rangd~⦒~range~⦥~rangle~⟩~rarrap~⥵~rarrb~⇥~rarrbfs~⤠~rarrc~⤳~rarrfs~⤞~rarrhk~↪~rarrlp~↬~rarrpl~⥅~rarrsim~⥴~rarrtl~↣~rarrw~↝~ratail~⤚~ratio~∶~rationals~ℚ~rbarr~⤍~rbbrk~❳~rbrace~}~rbrack~]~rbrke~⦌~rbrksld~⦎~rbrkslu~⦐~rcaron~ř~rcedil~ŗ~rcub~}~rcy~р~rdca~⤷~rdldhar~⥩~rdquor~”~rdsh~↳~realine~ℛ~realpart~ℜ~reals~ℝ~rect~▭~rfisht~⥽~rfr~𝔯~rhard~⇁~rharu~⇀~rharul~⥬~rhov~ϱ~rightarrow~→~rightarrowtail~↣~rightharpoondown~⇁~rightharpoonup~⇀~rightleftarrows~⇄~rightleftharpoons~⇌~rightrightarrows~⇉~rightsquigarrow~↝~rightthreetimes~⋌~ring~˚~risingdotseq~≓~rlarr~⇄~rlhar~⇌~rmoust~⎱~rmoustache~⎱~rnmid~⫮~roang~⟭~roarr~⇾~robrk~⟧~ropar~⦆~ropf~𝕣~roplus~⨮~rotimes~⨵~rpar~)~rpargt~⦔~rppolint~⨒~rrarr~⇉~rscr~𝓇~rsh~↱~rsqb~]~rsquor~’~rthree~⋌~rtimes~⋊~rtri~▹~rtrie~⊵~rtrif~▸~rtriltri~⧎~ruluhar~⥨~rx~℞~sacute~ś~sc~≻~scE~⪴~scap~⪸~sccue~≽~sce~⪰~scedil~ş~scirc~ŝ~scnE~⪶~scnap~⪺~scnsim~⋩~scpolint~⨓~scsim~≿~scy~с~sdotb~⊡~sdote~⩦~seArr~⇘~searhk~⤥~searr~↘~searrow~↘~semi~;~seswar~⤩~setminus~∖~setmn~∖~sext~✶~sfr~𝔰~sfrown~⌢~sharp~♯~shchcy~щ~shcy~ш~shortmid~∣~shortparallel~∥~sigmav~ς~simdot~⩪~sime~≃~simeq~≃~simg~⪞~simgE~⪠~siml~⪝~simlE~⪟~simne~≆~simplus~⨤~simrarr~⥲~slarr~←~smallsetminus~∖~smashp~⨳~smeparsl~⧤~smid~∣~smile~⌣~smt~⪪~smte~⪬~smtes~⪬︀~softcy~ь~sol~/~solb~⧄~solbar~⌿~sopf~𝕤~spadesuit~♠~spar~∥~sqcap~⊓~sqcaps~⊓︀~sqcup~⊔~sqcups~⊔︀~sqsub~⊏~sqsube~⊑~sqsubset~⊏~sqsubseteq~⊑~sqsup~⊐~sqsupe~⊒~sqsupset~⊐~sqsupseteq~⊒~squ~□~square~□~squarf~▪~squf~▪~srarr~→~sscr~𝓈~ssetmn~∖~ssmile~⌣~sstarf~⋆~star~☆~starf~★~straightepsilon~ϵ~straightphi~ϕ~strns~¯~subE~⫅~subdot~⪽~subedot~⫃~submult~⫁~subnE~⫋~subne~⊊~subplus~⪿~subrarr~⥹~subset~⊂~subseteq~⊆~subseteqq~⫅~subsetneq~⊊~subsetneqq~⫋~subsim~⫇~subsub~⫕~subsup~⫓~succ~≻~succapprox~⪸~succcurlyeq~≽~succeq~⪰~succnapprox~⪺~succneqq~⪶~succnsim~⋩~succsim~≿~sung~♪~supE~⫆~supdot~⪾~supdsub~⫘~supedot~⫄~suphsol~⟉~suphsub~⫗~suplarr~⥻~supmult~⫂~supnE~⫌~supne~⊋~supplus~⫀~supset~⊃~supseteq~⊇~supseteqq~⫆~supsetneq~⊋~supsetneqq~⫌~supsim~⫈~supsub~⫔~supsup~⫖~swArr~⇙~swarhk~⤦~swarr~↙~swarrow~↙~swnwar~⤪~target~⌖~tbrk~⎴~tcaron~ť~tcedil~ţ~tcy~т~tdot~⃛~telrec~⌕~tfr~𝔱~therefore~∴~thetav~ϑ~thickapprox~≈~thicksim~∼~thkap~≈~thksim~∼~timesb~⊠~timesbar~⨱~timesd~⨰~tint~∭~toea~⤨~top~⊤~topbot~⌶~topcir~⫱~topf~𝕥~topfork~⫚~tosa~⤩~tprime~‴~triangle~▵~triangledown~▿~triangleleft~◃~trianglelefteq~⊴~triangleq~≜~triangleright~▹~trianglerighteq~⊵~tridot~◬~trie~≜~triminus~⨺~triplus~⨹~trisb~⧍~tritime~⨻~trpezium~⏢~tscr~𝓉~tscy~ц~tshcy~ћ~tstrok~ŧ~twixt~≬~twoheadleftarrow~↞~twoheadrightarrow~↠~uHar~⥣~ubrcy~ў~ubreve~ŭ~ucy~у~udarr~⇅~udblac~ű~udhar~⥮~ufisht~⥾~ufr~𝔲~uharl~↿~uharr~↾~uhblk~▀~ulcorn~⌜~ulcorner~⌜~ulcrop~⌏~ultri~◸~umacr~ū~uogon~ų~uopf~𝕦~uparrow~↑~updownarrow~↕~upharpoonleft~↿~upharpoonright~↾~uplus~⊎~upsi~υ~upuparrows~⇈~urcorn~⌝~urcorner~⌝~urcrop~⌎~uring~ů~urtri~◹~uscr~𝓊~utdot~⋰~utilde~ũ~utri~▵~utrif~▴~uuarr~⇈~uwangle~⦧~vArr~⇕~vBar~⫨~vBarv~⫩~vDash~⊨~vangrt~⦜~varepsilon~ϵ~varkappa~ϰ~varnothing~∅~varphi~ϕ~varpi~ϖ~varpropto~∝~varr~↕~varrho~ϱ~varsigma~ς~varsubsetneq~⊊︀~varsubsetneqq~⫋︀~varsupsetneq~⊋︀~varsupsetneqq~⫌︀~vartheta~ϑ~vartriangleleft~⊲~vartriangleright~⊳~vcy~в~vdash~⊢~vee~∨~veebar~⊻~veeeq~≚~vellip~⋮~verbar~|~vert~|~vfr~𝔳~vltri~⊲~vnsub~⊂⃒~vnsup~⊃⃒~vopf~𝕧~vprop~∝~vrtri~⊳~vscr~𝓋~vsubnE~⫋︀~vsubne~⊊︀~vsupnE~⫌︀~vsupne~⊋︀~vzigzag~⦚~wcirc~ŵ~wedbar~⩟~wedge~∧~wedgeq~≙~wfr~𝔴~wopf~𝕨~wp~℘~wr~≀~wreath~≀~wscr~𝓌~xcap~⋂~xcirc~◯~xcup~⋃~xdtri~▽~xfr~𝔵~xhArr~⟺~xharr~⟷~xlArr~⟸~xlarr~⟵~xmap~⟼~xnis~⋻~xodot~⨀~xopf~𝕩~xoplus~⨁~xotime~⨂~xrArr~⟹~xrarr~⟶~xscr~𝓍~xsqcup~⨆~xuplus~⨄~xutri~△~xvee~⋁~xwedge~⋀~yacy~я~ycirc~ŷ~ycy~ы~yfr~𝔶~yicy~ї~yopf~𝕪~yscr~𝓎~yucy~ю~zacute~ź~zcaron~ž~zcy~з~zdot~ż~zeetrf~ℨ~zfr~𝔷~zhcy~ж~zigrarr~⇝~zopf~𝕫~zscr~𝓏~~AMP~&~COPY~©~GT~>~LT~<~QUOT~"~REG~®',Aa.html4);var Ga=function(){return Ga=Object.assign||function(e){for(var i,n=1,o=arguments.length;n<o;n++){i=arguments[n];for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(e[a]=i[a])}return e},Ga.apply(this,arguments)};Ga(Ga({},Aa),{all:Aa.html5});var ol=/&(?:#\d+|#[xX][\da-fA-F]+|[0-9a-zA-Z]+);/g,al=/&(?:#\d+|#[xX][\da-fA-F]+|[0-9a-zA-Z]+)[;=]?/g,z0={xml:{strict:ol,attribute:al,body:nl.xml},html4:{strict:ol,attribute:al,body:nl.html4},html5:{strict:ol,attribute:al,body:nl.html5}};Ga(Ga({},z0),{all:z0.html5});Ik();const K0=(e,i)=>Object.hasOwn(e,i),tl=(e,i)=>Object.assign(e,i),sl=(e,i,n)=>{if(e.length===0)return[];let o=0;const a=F7.exec(e[0]);a&&(o=a[1].length);const t=String.raw`(\r\n|\r|\n).{0,${o}}`,s=new RegExp(t,"g"),r=i?e.slice(1):e,{newline:u,trimLeadingNewline:d,trimTrailingNewline:l}=n,g=typeof u=="string",h=r.length,c=Array.from({length:h});for(let p=0;p<h;p++){let f=r[p];f=f.replace(s,"$1"),p===0&&d&&(f=f.replace(O7,"")),p===h-1&&l&&(f=f.replace(A7,"")),g&&(f=f.replaceAll(W7,u)),c[p]=f}return c},Aue=(e,i)=>{const n=Array.from({length:e.length+i.length});let o=0;const a=e.length;for(;o<a-1;o++)n[o*2]=e[o],n[o*2+1]=String(i[o]);return n[o*2]=e[o],n.join("")},Gue=e=>K0(e,"raw")&&K0(e,"length"),Fue=new WeakMap,pL=e=>{const i=e.cache!==!1,n=i?e.cacheStore??Fue:void 0,o=e.newline!==void 0;function a(t,...s){if(Gue(t)){const r=t,u=s.length;if(r.length===1&&r[0]==="")return"";if(u===0){if(i&&n&&!o){const h=n.get(r);if(h)return h[0]}const g=sl(r,!1,e);return i&&n&&n.set(r,g),g[0]}const d=(s[0]===a||s[0]===Que)&&Q7.test(r[0])&&G7.test(r[1]);let l;return i&&n&&!o&&(l=n.get(r)),l||(l=sl(r,d,e),i&&n&&n.set(r,l)),Aue(l,d?s.slice(1):s)}return pL(tl(tl({},e),t))}return tl(a,{string(t){return t===""||!t?"":sl([t],!1,e)[0]}})},Que=pL({cache:!0,newline:null,trimLeadingNewline:!0,trimTrailingNewline:!0}),Wue=["\0","","","","","","","\x07","\b"," ",`
95
+ }`;var f=mS(function(){return Function(t,c+"return "+g).apply(void 0,s)});if(f.source=g,vc(f))throw f;return f}var Sre="Expected a function";function Lre(e,i,n){var o=!0,a=!0;if(typeof e!="function")throw new TypeError(Sre);return Pe(n)&&(o="leading"in n?!!n.leading:o,a="trailing"in n?!!n.trailing:a),h1(e,i,{leading:o,maxWait:i,trailing:a})}function Uu(e,i){return i(e)}var Cre=9007199254740991,il=4294967295,Yre=Math.min;function $re(e,i){if(e=re(e),e<1||e>Cre)return[];var n=il,o=Yre(e,il);i=xn(i),e-=il;for(var a=dc(o,i);++n<e;)i(n);return a}function Zre(){return this}function tL(e,i){var n=e;return n instanceof pe&&(n=n.value()),mc(i,function(o,a){return a.func.apply(a.thisArg,Yo([o],a.args))},n)}function Jre(){return tL(this.__wrapped__,this.__actions__)}function xre(e){return be(e).toLowerCase()}function Tre(e){return ae(e)?Be(e,rn):Zi(e)?[e]:yi(vS(be(e)))}var W0=9007199254740991;function Dre(e){return e?ra(re(e),-W0,W0):e===0?e:0}function Bre(e){return be(e).toUpperCase()}function Xre(e,i,n){var o=ae(e),a=o||ho(e)||ut(e);if(i=ie(i),n==null){var t=e&&e.constructor;a?n=o?new t:[]:Pe(e)?n=Wn(t)?at(Pu(e)):{}:n={}}return(a?Xi:Jn)(e,function(s,r,u){return i(n,s,r,u)}),n}function sL(e,i){for(var n=e.length;n--&&tt(i,e[n],0)>-1;);return n}function rL(e,i){for(var n=-1,o=e.length;++n<o&&tt(i,e[n],0)>-1;);return n}function Hre(e,i,n){if(e=be(e),e&&(n||i===void 0))return qk(e);if(!e||!(i=Ji(i)))return e;var o=un(e),a=un(i),t=rL(o,a),s=sL(o,a)+1;return $o(o,t,s).join("")}function Mre(e,i,n){if(e=be(e),e&&(n||i===void 0))return e.slice(0,Kk(e)+1);if(!e||!(i=Ji(i)))return e;var o=un(e),a=sL(o,un(i))+1;return $o(o,0,a).join("")}var Pre=/^\s+/;function Nre(e,i,n){if(e=be(e),e&&(n||i===void 0))return e.replace(Pre,"");if(!e||!(i=Ji(i)))return e;var o=un(e),a=rL(o,un(i));return $o(o,a).join("")}var Ere=30,Rre="...",Ore=/\w*$/;function Are(e,i){var n=Ere,o=Rre;if(Pe(i)){var a="separator"in i?i.separator:a;n="length"in i?re(i.length):n,o="omission"in i?Ji(i.omission):o}e=be(e);var t=e.length;if(dt(e)){var s=un(e);t=s.length}if(n>=t)return e;var r=n-ht(o);if(r<1)return o;var u=s?$o(s,0,r).join(""):e.slice(0,r);if(a===void 0)return u+o;if(s&&(r+=u.length-r),Rc(a)){if(e.slice(r).search(a)){var d,l=u;for(a.global||(a=RegExp(a.source,be(Ore.exec(a))+"g")),a.lastIndex=0;d=a.exec(l);)var g=d.index;u=u.slice(0,g===void 0?r:g)}}else if(e.indexOf(Ji(a),r)!=r){var h=u.lastIndexOf(a);h>-1&&(u=u.slice(0,h))}return u+o}function Gre(e){return uS(e,1)}var Fre={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},Qre=bc(Fre),uL=/&(?:amp|lt|gt|quot|#39);/g,Wre=RegExp(uL.source);function Ire(e){return e=be(e),e&&Wre.test(e)?e.replace(uL,Qre):e}var _re=1/0,zre=Ba&&1/Eu(new Ba([,-0]))[1]==_re?function(e){return new Ba(e)}:tc,Kre=200;function co(e,i,n){var o=-1,a=Tu,t=e.length,s=!0,r=[],u=r;if(n)s=!1,a=Xc;else if(t>=Kre){var d=i?null:zre(e);if(d)return Eu(d);s=!1,a=ms,u=new Ko}else u=i?[]:r;e:for(;++o<t;){var l=e[o],g=i?i(l):l;if(l=n||l!==0?l:0,s&&g===g){for(var h=u.length;h--;)if(u[h]===g)continue e;i&&u.push(g),r.push(l)}else a(u,g,n)||(u!==r&&u.push(g),r.push(l))}return r}var qre=de(function(e){return co(ei(e,1,Fe,!0))}),Ure=de(function(e){var i=Ui(e);return Fe(i)&&(i=void 0),co(ei(e,1,Fe,!0),ie(i))}),Vre=de(function(e){var i=Ui(e);return i=typeof i=="function"?i:void 0,co(ei(e,1,Fe,!0),void 0,i)});function eue(e){return e&&e.length?co(e):[]}function iue(e,i){return e&&e.length?co(e,ie(i)):[]}function nue(e,i){return i=typeof i=="function"?i:void 0,e&&e.length?co(e,void 0,i):[]}var oue=0;function aue(e){var i=++oue;return be(e)+i}function tue(e,i){return e==null?!0:Gc(e,i)}var sue=Math.max;function zc(e){if(!(e&&e.length))return[];var i=0;return e=Zo(e,function(n){if(Fe(n))return i=sue(n.length,i),!0}),dc(i,function(n){return Be(e,xc(n))})}function dL(e,i){if(!(e&&e.length))return[];var n=zc(e);return i==null?n:Be(n,function(o){return xi(i,void 0,o)})}function lL(e,i,n,o){return Rs(e,i,n(sa(e,i)),o)}function rue(e,i,n){return e==null?e:lL(e,i,xn(n))}function uue(e,i,n,o){return o=typeof o=="function"?o:void 0,e==null?e:lL(e,i,xn(n),o)}var due=lt(function(e,i,n){return e+(n?" ":"")+i.toUpperCase()});function lue(e){return e==null?[]:Pc(e,ki(e))}var gue=de(function(e,i){return Fe(e)?Ns(e,i):[]});function hue(e,i){return zu(xn(i),e)}var cue=qn(function(e){var i=e.length,n=i?e[0]:0,o=this.__wrapped__,a=function(t){return pc(t,e)};return i>1||this.__actions__.length||!(o instanceof pe)||!In(n)?this.thru(a):(o=o.slice(n,+n+(i?1:0)),o.__actions__.push({func:Uu,args:[a],thisArg:void 0}),new zi(o,this.__chain__).thru(function(t){return i&&!t.length&&t.push(void 0),t}))});function pue(){return GS(this)}function vue(){var e=this.__wrapped__;if(e instanceof pe){var i=e;return this.__actions__.length&&(i=new pe(this)),i=i.reverse(),i.__actions__.push({func:Uu,args:[Yg],thisArg:void 0}),new zi(i,this.__chain__)}return this.thru(Yg)}function Kc(e,i,n){var o=e.length;if(o<2)return o?co(e[0]):[];for(var a=-1,t=Array(o);++a<o;)for(var s=e[a],r=-1;++r<o;)r!=a&&(t[a]=Ns(t[a]||s,e[r],i,n));return co(ei(t,1),i,n)}var yue=de(function(e){return Kc(Zo(e,Fe))}),fue=de(function(e){var i=Ui(e);return Fe(i)&&(i=void 0),Kc(Zo(e,Fe),ie(i))}),mue=de(function(e){var i=Ui(e);return i=typeof i=="function"?i:void 0,Kc(Zo(e,Fe),void 0,i)}),bue=de(zc);function gL(e,i,n){for(var o=-1,a=e.length,t=i.length,s={};++o<a;){var r=o<t?i[o]:void 0;n(s,e[o],r)}return s}function wue(e,i){return gL(e||[],i||[],Xs)}function jue(e,i){return gL(e||[],i||[],Rs)}var kue=de(function(e){var i=e.length,n=i>1?e[i-1]:void 0;return n=typeof n=="function"?(e.pop(),n):void 0,dL(e,n)});const O={chunk:FU,compact:Cee,concat:Yee,difference:Tie,differenceBy:Die,differenceWith:Bie,drop:Hie,dropRight:Mie,dropRightWhile:Pie,dropWhile:Nie,fill:ane,findIndex:Z1,findLastIndex:x1,flatten:yS,flattenDeep:bne,flattenDepth:wne,fromPairs:Hne,head:cne,indexOf:ioe,initial:noe,intersection:aoe,intersectionBy:toe,intersectionWith:soe,join:iae,lastIndexOf:rae,nth:Hae,pull:Xte,pullAll:q1,pullAllBy:Hte,pullAllWith:Mte,pullAt:Ete,remove:ose,reverse:Yg,slice:Cse,sortedIndex:Mse,sortedIndexBy:Pse,sortedIndexOf:Nse,sortedLastIndex:Ese,sortedLastIndexBy:Rse,sortedLastIndexOf:Ose,sortedUniq:Ase,sortedUniqBy:Gse,tail:ore,take:are,takeRight:tre,takeRightWhile:sre,takeWhile:rre,union:qre,unionBy:Ure,unionWith:Vre,uniq:eue,uniqBy:iue,uniqWith:nue,unzip:zc,unzipWith:dL,without:gue,xor:yue,xorBy:fue,xorWith:mue,zip:bue,zipObject:wue,zipObjectDeep:jue,zipWith:kue},Ye={countBy:vie,every:ine,filter:tne,find:rne,findLast:gne,flatMap:pne,flatMapDeep:yne,flatMapDepth:fne,forEach:Eie,forEachRight:Oie,groupBy:Rne,includes:Vne,invokeMap:voe,keyBy:oae,map:Gu,orderBy:_ae,partition:$te,reduce:Vte,reduceRight:ise,reject:nse,sample:cse,sampleSize:yse,shuffle:jse,size:Lse,some:Zse,sortBy:Jse},Sue={now:br},Oe={after:$9,ary:uS,before:bS,bind:Nu,bindKey:yc,curry:Dc,curryRight:Bc,debounce:h1,defer:Zie,delay:Jie,flip:kne,memoize:Mu,once:Qae,overArgs:Uae,partial:zu,partialRight:Qc,rearg:Ute,rest:rse,spread:_se,throttle:Lre,unary:Gre,wrap:hue},Q={castArray:NU,clone:vee,cloneDeep:mee,cloneDeepWith:jee,cloneWith:See,conformsTo:lie,eq:ln,gt:One,gte:Ane,isArguments:_o,isArrayBuffer:moe,isArrayLike:ji,isArrayLikeObject:Fe,isBoolean:woe,isBuffer:ho,isDate:Soe,isElement:Loe,isEmpty:Joe,isEqual:xoe,isEqualWith:Toe,isError:vc,isFinite:Boe,isFunction:Wn,isInteger:M1,isLength:Bu,isMap:qS,isMatch:Xoe,isMatchWith:Hoe,isNaN:Poe,isNative:Roe,isNil:Ooe,isNull:Aoe,isNumber:P1,isObjectLike:Ee,isPlainObject:Ms,isRegExp:Rc,isSafeInteger:Qoe,isSet:US,isString:Wu,isSymbol:Zi,isTypedArray:ut,isUndefined:Woe,isWeakMap:_oe,isWeakSet:Koe,lt:lae,lte:gae,toArray:E1,toFinite:Nn,toLength:C1,toNumber:Ai,toPlainObject:p1,toSafeInteger:Dre,toString:be},hi={add:m9,ceil:OU,divide:Xie,floor:Sne,max:mae,maxBy:bae,mean:jae,meanBy:kae,min:Yae,minBy:$ae,multiply:Jae,round:gse,subtract:ere,sum:ire,sumBy:nre},qc={clamp:QU,inRange:Kne,random:Qte},U={assign:T6,assignIn:M6,assignInWith:P6,assignWith:vg,at:yq,create:yie,defaults:Lie,defaultsDeep:Yie,findKey:une,findLastKey:hne,forIn:Tne,forInRight:Dne,forOwn:Bne,forOwnRight:Xne,functions:Mne,functionsIn:Pne,get:cc,has:Wne,hasIn:Jc,invert:loe,invertBy:coe,invoke:poe,keysIn:ki,mapKeys:hae,mapValues:cae,merge:Sae,mergeWith:y1,omit:Gae,omitBy:Fae,pick:Jte,pickBy:A1,result:use,set:fse,setWith:mse,toPairs:Iie,toPairsIn:_ie,transform:Xre,unset:tue,update:rue,updateWith:uue,values:gt,valuesIn:lue},Tn={at:cue,chain:GS,commit:Lee,next:Xae,plant:xte,reverse:vue,tap:ure,toIterator:Zre,value:Jre,wrapperChain:pue},fe={camelCase:PU,capitalize:$S,deburr:ZS,endsWith:Aie,escape:k1,escapeRegExp:Vie,kebabCase:nae,lowerCase:uae,lowerFirst:dae,pad:bte,padEnd:wte,padStart:jte,parseInt:Lte,repeat:ase,replace:tse,snakeCase:Yse,split:Qse,startCase:zse,startsWith:Kse,template:kre,templateSettings:$g,toLower:xre,toUpper:Bre,trim:Hre,trimEnd:Mre,trimStart:Nre,truncate:Are,unescape:Ire,upperCase:due,upperFirst:fc,words:AS},ke={attempt:mS,bindAll:$q,cond:sie,conforms:die,constant:rc,defaultTo:kie,flow:Jne,flowRight:xne,iteratee:Uoe,matches:vae,matchesProperty:fae,method:Lae,methodOf:Cae,noop:tc,nthArg:Mae,over:zae,overEvery:Vae,overSome:ete,property:u1,propertyOf:Tte,range:zte,rangeRight:Kte,stubArray:jc,stubFalse:lc,stubObject:qse,stubString:Use,stubTrue:Vse,times:$re,toPath:Tre,uniqueId:aue};function Lue(){var e=new pe(this.__wrapped__);return e.__actions__=yi(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=yi(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=yi(this.__views__),e}function Cue(){if(this.__filtered__){var e=new pe(this);e.__dir__=-1,e.__filtered__=!0}else e=this.clone(),e.__dir__*=-1;return e}var Yue=Math.max,$ue=Math.min;function Zue(e,i,n){for(var o=-1,a=n.length;++o<a;){var t=n[o],s=t.size;switch(t.type){case"drop":e+=s;break;case"dropRight":i-=s;break;case"take":i=$ue(i,e+s);break;case"takeRight":e=Yue(e,i-s);break}}return{start:e,end:i}}var Jue=1,xue=2,Tue=Math.min;function Due(){var e=this.__wrapped__.value(),i=this.__dir__,n=ae(e),o=i<0,a=n?e.length:0,t=Zue(0,a,this.__views__),s=t.start,r=t.end,u=r-s,d=o?r:s-1,l=this.__iteratees__,g=l.length,h=0,c=Tue(u,this.__takeCount__);if(!n||!o&&a==u&&c==u)return tL(e,this.__actions__);var p=[];e:for(;u--&&h<c;){d+=i;for(var f=-1,w=e[d];++f<g;){var v=l[f],j=v.iteratee,C=v.type,y=j(w);if(C==xue)w=y;else if(!y){if(C==Jue)continue e;break e}}p[h++]=w}return p}var Bue="4.18.1",Xue=2,Hue=1,Mue=3,hL=4294967295,Pue=Array.prototype,Nue=Object.prototype,cL=Nue.hasOwnProperty,I0=ai?ai.iterator:void 0,Eue=Math.max,_0=Math.min,Uc=(function(e){return function(i,n,o){if(o==null){var a=Pe(n),t=a&&qe(n),s=t&&t.length&&Fu(n,t);(s?s.length:a)||(o=n,n=i,i=this)}return e(i,n,o)}})(Zae);b.after=Oe.after;b.ary=Oe.ary;b.assign=U.assign;b.assignIn=U.assignIn;b.assignInWith=U.assignInWith;b.assignWith=U.assignWith;b.at=U.at;b.before=Oe.before;b.bind=Oe.bind;b.bindAll=ke.bindAll;b.bindKey=Oe.bindKey;b.castArray=Q.castArray;b.chain=Tn.chain;b.chunk=O.chunk;b.compact=O.compact;b.concat=O.concat;b.cond=ke.cond;b.conforms=ke.conforms;b.constant=ke.constant;b.countBy=Ye.countBy;b.create=U.create;b.curry=Oe.curry;b.curryRight=Oe.curryRight;b.debounce=Oe.debounce;b.defaults=U.defaults;b.defaultsDeep=U.defaultsDeep;b.defer=Oe.defer;b.delay=Oe.delay;b.difference=O.difference;b.differenceBy=O.differenceBy;b.differenceWith=O.differenceWith;b.drop=O.drop;b.dropRight=O.dropRight;b.dropRightWhile=O.dropRightWhile;b.dropWhile=O.dropWhile;b.fill=O.fill;b.filter=Ye.filter;b.flatMap=Ye.flatMap;b.flatMapDeep=Ye.flatMapDeep;b.flatMapDepth=Ye.flatMapDepth;b.flatten=O.flatten;b.flattenDeep=O.flattenDeep;b.flattenDepth=O.flattenDepth;b.flip=Oe.flip;b.flow=ke.flow;b.flowRight=ke.flowRight;b.fromPairs=O.fromPairs;b.functions=U.functions;b.functionsIn=U.functionsIn;b.groupBy=Ye.groupBy;b.initial=O.initial;b.intersection=O.intersection;b.intersectionBy=O.intersectionBy;b.intersectionWith=O.intersectionWith;b.invert=U.invert;b.invertBy=U.invertBy;b.invokeMap=Ye.invokeMap;b.iteratee=ke.iteratee;b.keyBy=Ye.keyBy;b.keys=qe;b.keysIn=U.keysIn;b.map=Ye.map;b.mapKeys=U.mapKeys;b.mapValues=U.mapValues;b.matches=ke.matches;b.matchesProperty=ke.matchesProperty;b.memoize=Oe.memoize;b.merge=U.merge;b.mergeWith=U.mergeWith;b.method=ke.method;b.methodOf=ke.methodOf;b.mixin=Uc;b.negate=_u;b.nthArg=ke.nthArg;b.omit=U.omit;b.omitBy=U.omitBy;b.once=Oe.once;b.orderBy=Ye.orderBy;b.over=ke.over;b.overArgs=Oe.overArgs;b.overEvery=ke.overEvery;b.overSome=ke.overSome;b.partial=Oe.partial;b.partialRight=Oe.partialRight;b.partition=Ye.partition;b.pick=U.pick;b.pickBy=U.pickBy;b.property=ke.property;b.propertyOf=ke.propertyOf;b.pull=O.pull;b.pullAll=O.pullAll;b.pullAllBy=O.pullAllBy;b.pullAllWith=O.pullAllWith;b.pullAt=O.pullAt;b.range=ke.range;b.rangeRight=ke.rangeRight;b.rearg=Oe.rearg;b.reject=Ye.reject;b.remove=O.remove;b.rest=Oe.rest;b.reverse=O.reverse;b.sampleSize=Ye.sampleSize;b.set=U.set;b.setWith=U.setWith;b.shuffle=Ye.shuffle;b.slice=O.slice;b.sortBy=Ye.sortBy;b.sortedUniq=O.sortedUniq;b.sortedUniqBy=O.sortedUniqBy;b.split=fe.split;b.spread=Oe.spread;b.tail=O.tail;b.take=O.take;b.takeRight=O.takeRight;b.takeRightWhile=O.takeRightWhile;b.takeWhile=O.takeWhile;b.tap=Tn.tap;b.throttle=Oe.throttle;b.thru=Uu;b.toArray=Q.toArray;b.toPairs=U.toPairs;b.toPairsIn=U.toPairsIn;b.toPath=ke.toPath;b.toPlainObject=Q.toPlainObject;b.transform=U.transform;b.unary=Oe.unary;b.union=O.union;b.unionBy=O.unionBy;b.unionWith=O.unionWith;b.uniq=O.uniq;b.uniqBy=O.uniqBy;b.uniqWith=O.uniqWith;b.unset=U.unset;b.unzip=O.unzip;b.unzipWith=O.unzipWith;b.update=U.update;b.updateWith=U.updateWith;b.values=U.values;b.valuesIn=U.valuesIn;b.without=O.without;b.words=fe.words;b.wrap=Oe.wrap;b.xor=O.xor;b.xorBy=O.xorBy;b.xorWith=O.xorWith;b.zip=O.zip;b.zipObject=O.zipObject;b.zipObjectDeep=O.zipObjectDeep;b.zipWith=O.zipWith;b.entries=U.toPairs;b.entriesIn=U.toPairsIn;b.extend=U.assignIn;b.extendWith=U.assignInWith;Uc(b,b);b.add=hi.add;b.attempt=ke.attempt;b.camelCase=fe.camelCase;b.capitalize=fe.capitalize;b.ceil=hi.ceil;b.clamp=qc.clamp;b.clone=Q.clone;b.cloneDeep=Q.cloneDeep;b.cloneDeepWith=Q.cloneDeepWith;b.cloneWith=Q.cloneWith;b.conformsTo=Q.conformsTo;b.deburr=fe.deburr;b.defaultTo=ke.defaultTo;b.divide=hi.divide;b.endsWith=fe.endsWith;b.eq=Q.eq;b.escape=fe.escape;b.escapeRegExp=fe.escapeRegExp;b.every=Ye.every;b.find=Ye.find;b.findIndex=O.findIndex;b.findKey=U.findKey;b.findLast=Ye.findLast;b.findLastIndex=O.findLastIndex;b.findLastKey=U.findLastKey;b.floor=hi.floor;b.forEach=Ye.forEach;b.forEachRight=Ye.forEachRight;b.forIn=U.forIn;b.forInRight=U.forInRight;b.forOwn=U.forOwn;b.forOwnRight=U.forOwnRight;b.get=U.get;b.gt=Q.gt;b.gte=Q.gte;b.has=U.has;b.hasIn=U.hasIn;b.head=O.head;b.identity=wi;b.includes=Ye.includes;b.indexOf=O.indexOf;b.inRange=qc.inRange;b.invoke=U.invoke;b.isArguments=Q.isArguments;b.isArray=ae;b.isArrayBuffer=Q.isArrayBuffer;b.isArrayLike=Q.isArrayLike;b.isArrayLikeObject=Q.isArrayLikeObject;b.isBoolean=Q.isBoolean;b.isBuffer=Q.isBuffer;b.isDate=Q.isDate;b.isElement=Q.isElement;b.isEmpty=Q.isEmpty;b.isEqual=Q.isEqual;b.isEqualWith=Q.isEqualWith;b.isError=Q.isError;b.isFinite=Q.isFinite;b.isFunction=Q.isFunction;b.isInteger=Q.isInteger;b.isLength=Q.isLength;b.isMap=Q.isMap;b.isMatch=Q.isMatch;b.isMatchWith=Q.isMatchWith;b.isNaN=Q.isNaN;b.isNative=Q.isNative;b.isNil=Q.isNil;b.isNull=Q.isNull;b.isNumber=Q.isNumber;b.isObject=Pe;b.isObjectLike=Q.isObjectLike;b.isPlainObject=Q.isPlainObject;b.isRegExp=Q.isRegExp;b.isSafeInteger=Q.isSafeInteger;b.isSet=Q.isSet;b.isString=Q.isString;b.isSymbol=Q.isSymbol;b.isTypedArray=Q.isTypedArray;b.isUndefined=Q.isUndefined;b.isWeakMap=Q.isWeakMap;b.isWeakSet=Q.isWeakSet;b.join=O.join;b.kebabCase=fe.kebabCase;b.last=Ui;b.lastIndexOf=O.lastIndexOf;b.lowerCase=fe.lowerCase;b.lowerFirst=fe.lowerFirst;b.lt=Q.lt;b.lte=Q.lte;b.max=hi.max;b.maxBy=hi.maxBy;b.mean=hi.mean;b.meanBy=hi.meanBy;b.min=hi.min;b.minBy=hi.minBy;b.stubArray=ke.stubArray;b.stubFalse=ke.stubFalse;b.stubObject=ke.stubObject;b.stubString=ke.stubString;b.stubTrue=ke.stubTrue;b.multiply=hi.multiply;b.nth=O.nth;b.noop=ke.noop;b.now=Sue.now;b.pad=fe.pad;b.padEnd=fe.padEnd;b.padStart=fe.padStart;b.parseInt=fe.parseInt;b.random=qc.random;b.reduce=Ye.reduce;b.reduceRight=Ye.reduceRight;b.repeat=fe.repeat;b.replace=fe.replace;b.result=U.result;b.round=hi.round;b.sample=Ye.sample;b.size=Ye.size;b.snakeCase=fe.snakeCase;b.some=Ye.some;b.sortedIndex=O.sortedIndex;b.sortedIndexBy=O.sortedIndexBy;b.sortedIndexOf=O.sortedIndexOf;b.sortedLastIndex=O.sortedLastIndex;b.sortedLastIndexBy=O.sortedLastIndexBy;b.sortedLastIndexOf=O.sortedLastIndexOf;b.startCase=fe.startCase;b.startsWith=fe.startsWith;b.subtract=hi.subtract;b.sum=hi.sum;b.sumBy=hi.sumBy;b.template=fe.template;b.times=ke.times;b.toFinite=Q.toFinite;b.toInteger=re;b.toLength=Q.toLength;b.toLower=fe.toLower;b.toNumber=Q.toNumber;b.toSafeInteger=Q.toSafeInteger;b.toString=Q.toString;b.toUpper=fe.toUpper;b.trim=fe.trim;b.trimEnd=fe.trimEnd;b.trimStart=fe.trimStart;b.truncate=fe.truncate;b.unescape=fe.unescape;b.uniqueId=ke.uniqueId;b.upperCase=fe.upperCase;b.upperFirst=fe.upperFirst;b.each=Ye.forEach;b.eachRight=Ye.forEachRight;b.first=O.head;Uc(b,(function(){var e={};return Jn(b,function(i,n){cL.call(b.prototype,n)||(e[n]=i)}),e})(),{chain:!1});b.VERSION=Bue;(b.templateSettings=fe.templateSettings).imports._=b;Xi(["bind","bindKey","curry","curryRight","partial","partialRight"],function(e){b[e].placeholder=b});Xi(["drop","take"],function(e,i){pe.prototype[e]=function(n){n=n===void 0?1:Eue(re(n),0);var o=this.__filtered__&&!i?new pe(this):this.clone();return o.__filtered__?o.__takeCount__=_0(n,o.__takeCount__):o.__views__.push({size:_0(n,hL),type:e+(o.__dir__<0?"Right":"")}),o},pe.prototype[e+"Right"]=function(n){return this.reverse()[e](n).reverse()}});Xi(["filter","map","takeWhile"],function(e,i){var n=i+1,o=n==Hue||n==Mue;pe.prototype[e]=function(a){var t=this.clone();return t.__iteratees__.push({iteratee:ie(a),type:n}),t.__filtered__=t.__filtered__||o,t}});Xi(["head","last"],function(e,i){var n="take"+(i?"Right":"");pe.prototype[e]=function(){return this[n](1).value()[0]}});Xi(["initial","tail"],function(e,i){var n="drop"+(i?"":"Right");pe.prototype[e]=function(){return this.__filtered__?new pe(this):this[n](1)}});pe.prototype.compact=function(){return this.filter(wi)};pe.prototype.find=function(e){return this.filter(e).head()};pe.prototype.findLast=function(e){return this.reverse().find(e)};pe.prototype.invokeMap=de(function(e,i){return typeof e=="function"?new pe(this):this.map(function(n){return Es(n,e,i)})});pe.prototype.reject=function(e){return this.filter(_u(ie(e)))};pe.prototype.slice=function(e,i){e=re(e);var n=this;return n.__filtered__&&(e>0||i<0)?new pe(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),i!==void 0&&(i=re(i),n=i<0?n.dropRight(-i):n.take(i-e)),n)};pe.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()};pe.prototype.toArray=function(){return this.take(hL)};Jn(pe.prototype,function(e,i){var n=/^(?:filter|find|map|reject)|While$/.test(i),o=/^(?:head|last)$/.test(i),a=b[o?"take"+(i=="last"?"Right":""):i],t=o||/^find/.test(i);a&&(b.prototype[i]=function(){var s=this.__wrapped__,r=o?[1]:arguments,u=s instanceof pe,d=r[0],l=u||ae(s),g=function(v){var j=a.apply(b,Yo([v],r));return o&&h?j[0]:j};l&&n&&typeof d=="function"&&d.length!=1&&(u=l=!1);var h=this.__chain__,c=!!this.__actions__.length,p=t&&!h,f=u&&!c;if(!t&&l){s=f?s:new pe(this);var w=e.apply(s,r);return w.__actions__.push({func:Uu,args:[g],thisArg:void 0}),new zi(w,h)}return p&&f?e.apply(this,r):(w=this.thru(g),p?o?w.value()[0]:w.value():w)})});Xi(["pop","push","shift","sort","splice","unshift"],function(e){var i=Pue[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",o=/^(?:pop|shift)$/.test(e);b.prototype[e]=function(){var a=arguments;if(o&&!this.__chain__){var t=this.value();return i.apply(ae(t)?t:[],a)}return this[n](function(s){return i.apply(ae(s)?s:[],a)})}});Jn(pe.prototype,function(e,i){var n=b[i];if(n){var o=n.name+"";cL.call(Da,o)||(Da[o]=[]),Da[o].push({name:i,func:n})}});Da[Du(void 0,Xue).name]=[{name:"wrapper",func:void 0}];pe.prototype.clone=Lue;pe.prototype.reverse=Cue;pe.prototype.value=Due;b.prototype.at=Tn.at;b.prototype.chain=Tn.wrapperChain;b.prototype.commit=Tn.commit;b.prototype.next=Tn.next;b.prototype.plant=Tn.plant;b.prototype.reverse=Tn.reverse;b.prototype.toJSON=b.prototype.valueOf=b.prototype.value=Tn.value;b.prototype.first=b.prototype.head;I0&&(b.prototype[I0]=Tn.toIterator);var ka=function(){return ka=Object.assign||function(e){for(var i,n=1,o=arguments.length;n<o;n++){i=arguments[n];for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(e[a]=i[a])}return e},ka.apply(this,arguments)},Rue="~",Oue="~~";function Vc(e,i){for(var n={},o={},a=e.split(Oue),t=!1,s=0;a.length>s;s++){for(var r=a[s].split(Rue),u=0;u<r.length;u+=2){var d=r[u],l=r[u+1],g="&"+d+";";n[g]=l,t&&(n["&"+d]=l),o[l]=g}t=!0}return i?{entities:ka(ka({},n),i.entities),characters:ka(ka({},o),i.characters)}:{entities:n,characters:o}}var nl={xml:/&(?:#\d+|#[xX][\da-fA-F]+|[0-9a-zA-Z]+);?/g,html4:/&notin;|&(?:nbsp|iexcl|cent|pound|curren|yen|brvbar|sect|uml|copy|ordf|laquo|not|shy|reg|macr|deg|plusmn|sup2|sup3|acute|micro|para|middot|cedil|sup1|ordm|raquo|frac14|frac12|frac34|iquest|Agrave|Aacute|Acirc|Atilde|Auml|Aring|AElig|Ccedil|Egrave|Eacute|Ecirc|Euml|Igrave|Iacute|Icirc|Iuml|ETH|Ntilde|Ograve|Oacute|Ocirc|Otilde|Ouml|times|Oslash|Ugrave|Uacute|Ucirc|Uuml|Yacute|THORN|szlig|agrave|aacute|acirc|atilde|auml|aring|aelig|ccedil|egrave|eacute|ecirc|euml|igrave|iacute|icirc|iuml|eth|ntilde|ograve|oacute|ocirc|otilde|ouml|divide|oslash|ugrave|uacute|ucirc|uuml|yacute|thorn|yuml|quot|amp|lt|gt|#\d+|#[xX][\da-fA-F]+|[0-9a-zA-Z]+);?/g,html5:/&centerdot;|&copysr;|&divideontimes;|&gtcc;|&gtcir;|&gtdot;|&gtlPar;|&gtquest;|&gtrapprox;|&gtrarr;|&gtrdot;|&gtreqless;|&gtreqqless;|&gtrless;|&gtrsim;|&ltcc;|&ltcir;|&ltdot;|&lthree;|&ltimes;|&ltlarr;|&ltquest;|&ltrPar;|&ltri;|&ltrie;|&ltrif;|&notin;|&notinE;|&notindot;|&notinva;|&notinvb;|&notinvc;|&notni;|&notniva;|&notnivb;|&notnivc;|&parallel;|&timesb;|&timesbar;|&timesd;|&(?:AElig|AMP|Aacute|Acirc|Agrave|Aring|Atilde|Auml|COPY|Ccedil|ETH|Eacute|Ecirc|Egrave|Euml|GT|Iacute|Icirc|Igrave|Iuml|LT|Ntilde|Oacute|Ocirc|Ograve|Oslash|Otilde|Ouml|QUOT|REG|THORN|Uacute|Ucirc|Ugrave|Uuml|Yacute|aacute|acirc|acute|aelig|agrave|amp|aring|atilde|auml|brvbar|ccedil|cedil|cent|copy|curren|deg|divide|eacute|ecirc|egrave|eth|euml|frac12|frac14|frac34|gt|iacute|icirc|iexcl|igrave|iquest|iuml|laquo|lt|macr|micro|middot|nbsp|not|ntilde|oacute|ocirc|ograve|ordf|ordm|oslash|otilde|ouml|para|plusmn|pound|quot|raquo|reg|sect|shy|sup1|sup2|sup3|szlig|thorn|times|uacute|ucirc|ugrave|uml|uuml|yacute|yen|yuml|#\d+|#[xX][\da-fA-F]+|[0-9a-zA-Z]+);?/g},Aa={};Aa.xml=Vc(`lt~<~gt~>~quot~"~apos~'~amp~&`);Aa.html4=Vc(`apos~'~OElig~Œ~oelig~œ~Scaron~Š~scaron~š~Yuml~Ÿ~circ~ˆ~tilde~˜~ensp~ ~emsp~ ~thinsp~ ~zwnj~‌~zwj~‍~lrm~‎~rlm~‏~ndash~–~mdash~—~lsquo~‘~rsquo~’~sbquo~‚~ldquo~“~rdquo~”~bdquo~„~dagger~†~Dagger~‡~permil~‰~lsaquo~‹~rsaquo~›~euro~€~fnof~ƒ~Alpha~Α~Beta~Β~Gamma~Γ~Delta~Δ~Epsilon~Ε~Zeta~Ζ~Eta~Η~Theta~Θ~Iota~Ι~Kappa~Κ~Lambda~Λ~Mu~Μ~Nu~Ν~Xi~Ξ~Omicron~Ο~Pi~Π~Rho~Ρ~Sigma~Σ~Tau~Τ~Upsilon~Υ~Phi~Φ~Chi~Χ~Psi~Ψ~Omega~Ω~alpha~α~beta~β~gamma~γ~delta~δ~epsilon~ε~zeta~ζ~eta~η~theta~θ~iota~ι~kappa~κ~lambda~λ~mu~μ~nu~ν~xi~ξ~omicron~ο~pi~π~rho~ρ~sigmaf~ς~sigma~σ~tau~τ~upsilon~υ~phi~φ~chi~χ~psi~ψ~omega~ω~thetasym~ϑ~upsih~ϒ~piv~ϖ~bull~•~hellip~…~prime~′~Prime~″~oline~‾~frasl~⁄~weierp~℘~image~ℑ~real~ℜ~trade~™~alefsym~ℵ~larr~←~uarr~↑~rarr~→~darr~↓~harr~↔~crarr~↵~lArr~⇐~uArr~⇑~rArr~⇒~dArr~⇓~hArr~⇔~forall~∀~part~∂~exist~∃~empty~∅~nabla~∇~isin~∈~notin~∉~ni~∋~prod~∏~sum~∑~minus~−~lowast~∗~radic~√~prop~∝~infin~∞~ang~∠~and~∧~or~∨~cap~∩~cup~∪~int~∫~there4~∴~sim~∼~cong~≅~asymp~≈~ne~≠~equiv~≡~le~≤~ge~≥~sub~⊂~sup~⊃~nsub~⊄~sube~⊆~supe~⊇~oplus~⊕~otimes~⊗~perp~⊥~sdot~⋅~lceil~⌈~rceil~⌉~lfloor~⌊~rfloor~⌋~lang~〈~rang~〉~loz~◊~spades~♠~clubs~♣~hearts~♥~diams~♦~~nbsp~ ~iexcl~¡~cent~¢~pound~£~curren~¤~yen~¥~brvbar~¦~sect~§~uml~¨~copy~©~ordf~ª~laquo~«~not~¬~shy~­~reg~®~macr~¯~deg~°~plusmn~±~sup2~²~sup3~³~acute~´~micro~µ~para~¶~middot~·~cedil~¸~sup1~¹~ordm~º~raquo~»~frac14~¼~frac12~½~frac34~¾~iquest~¿~Agrave~À~Aacute~Á~Acirc~Â~Atilde~Ã~Auml~Ä~Aring~Å~AElig~Æ~Ccedil~Ç~Egrave~È~Eacute~É~Ecirc~Ê~Euml~Ë~Igrave~Ì~Iacute~Í~Icirc~Î~Iuml~Ï~ETH~Ð~Ntilde~Ñ~Ograve~Ò~Oacute~Ó~Ocirc~Ô~Otilde~Õ~Ouml~Ö~times~×~Oslash~Ø~Ugrave~Ù~Uacute~Ú~Ucirc~Û~Uuml~Ü~Yacute~Ý~THORN~Þ~szlig~ß~agrave~à~aacute~á~acirc~â~atilde~ã~auml~ä~aring~å~aelig~æ~ccedil~ç~egrave~è~eacute~é~ecirc~ê~euml~ë~igrave~ì~iacute~í~icirc~î~iuml~ï~eth~ð~ntilde~ñ~ograve~ò~oacute~ó~ocirc~ô~otilde~õ~ouml~ö~divide~÷~oslash~ø~ugrave~ù~uacute~ú~ucirc~û~uuml~ü~yacute~ý~thorn~þ~yuml~ÿ~quot~"~amp~&~lt~<~gt~>`);Aa.html5=Vc('Abreve~Ă~Acy~А~Afr~𝔄~Amacr~Ā~And~⩓~Aogon~Ą~Aopf~𝔸~ApplyFunction~⁡~Ascr~𝒜~Assign~≔~Backslash~∖~Barv~⫧~Barwed~⌆~Bcy~Б~Because~∵~Bernoullis~ℬ~Bfr~𝔅~Bopf~𝔹~Breve~˘~Bscr~ℬ~Bumpeq~≎~CHcy~Ч~Cacute~Ć~Cap~⋒~CapitalDifferentialD~ⅅ~Cayleys~ℭ~Ccaron~Č~Ccirc~Ĉ~Cconint~∰~Cdot~Ċ~Cedilla~¸~CenterDot~·~Cfr~ℭ~CircleDot~⊙~CircleMinus~⊖~CirclePlus~⊕~CircleTimes~⊗~ClockwiseContourIntegral~∲~CloseCurlyDoubleQuote~”~CloseCurlyQuote~’~Colon~∷~Colone~⩴~Congruent~≡~Conint~∯~ContourIntegral~∮~Copf~ℂ~Coproduct~∐~CounterClockwiseContourIntegral~∳~Cross~⨯~Cscr~𝒞~Cup~⋓~CupCap~≍~DD~ⅅ~DDotrahd~⤑~DJcy~Ђ~DScy~Ѕ~DZcy~Џ~Darr~↡~Dashv~⫤~Dcaron~Ď~Dcy~Д~Del~∇~Dfr~𝔇~DiacriticalAcute~´~DiacriticalDot~˙~DiacriticalDoubleAcute~˝~DiacriticalGrave~`~DiacriticalTilde~˜~Diamond~⋄~DifferentialD~ⅆ~Dopf~𝔻~Dot~¨~DotDot~⃜~DotEqual~≐~DoubleContourIntegral~∯~DoubleDot~¨~DoubleDownArrow~⇓~DoubleLeftArrow~⇐~DoubleLeftRightArrow~⇔~DoubleLeftTee~⫤~DoubleLongLeftArrow~⟸~DoubleLongLeftRightArrow~⟺~DoubleLongRightArrow~⟹~DoubleRightArrow~⇒~DoubleRightTee~⊨~DoubleUpArrow~⇑~DoubleUpDownArrow~⇕~DoubleVerticalBar~∥~DownArrow~↓~DownArrowBar~⤓~DownArrowUpArrow~⇵~DownBreve~̑~DownLeftRightVector~⥐~DownLeftTeeVector~⥞~DownLeftVector~↽~DownLeftVectorBar~⥖~DownRightTeeVector~⥟~DownRightVector~⇁~DownRightVectorBar~⥗~DownTee~⊤~DownTeeArrow~↧~Downarrow~⇓~Dscr~𝒟~Dstrok~Đ~ENG~Ŋ~Ecaron~Ě~Ecy~Э~Edot~Ė~Efr~𝔈~Element~∈~Emacr~Ē~EmptySmallSquare~◻~EmptyVerySmallSquare~▫~Eogon~Ę~Eopf~𝔼~Equal~⩵~EqualTilde~≂~Equilibrium~⇌~Escr~ℰ~Esim~⩳~Exists~∃~ExponentialE~ⅇ~Fcy~Ф~Ffr~𝔉~FilledSmallSquare~◼~FilledVerySmallSquare~▪~Fopf~𝔽~ForAll~∀~Fouriertrf~ℱ~Fscr~ℱ~GJcy~Ѓ~Gammad~Ϝ~Gbreve~Ğ~Gcedil~Ģ~Gcirc~Ĝ~Gcy~Г~Gdot~Ġ~Gfr~𝔊~Gg~⋙~Gopf~𝔾~GreaterEqual~≥~GreaterEqualLess~⋛~GreaterFullEqual~≧~GreaterGreater~⪢~GreaterLess~≷~GreaterSlantEqual~⩾~GreaterTilde~≳~Gscr~𝒢~Gt~≫~HARDcy~Ъ~Hacek~ˇ~Hat~^~Hcirc~Ĥ~Hfr~ℌ~HilbertSpace~ℋ~Hopf~ℍ~HorizontalLine~─~Hscr~ℋ~Hstrok~Ħ~HumpDownHump~≎~HumpEqual~≏~IEcy~Е~IJlig~IJ~IOcy~Ё~Icy~И~Idot~İ~Ifr~ℑ~Im~ℑ~Imacr~Ī~ImaginaryI~ⅈ~Implies~⇒~Int~∬~Integral~∫~Intersection~⋂~InvisibleComma~⁣~InvisibleTimes~⁢~Iogon~Į~Iopf~𝕀~Iscr~ℐ~Itilde~Ĩ~Iukcy~І~Jcirc~Ĵ~Jcy~Й~Jfr~𝔍~Jopf~𝕁~Jscr~𝒥~Jsercy~Ј~Jukcy~Є~KHcy~Х~KJcy~Ќ~Kcedil~Ķ~Kcy~К~Kfr~𝔎~Kopf~𝕂~Kscr~𝒦~LJcy~Љ~Lacute~Ĺ~Lang~⟪~Laplacetrf~ℒ~Larr~↞~Lcaron~Ľ~Lcedil~Ļ~Lcy~Л~LeftAngleBracket~⟨~LeftArrow~←~LeftArrowBar~⇤~LeftArrowRightArrow~⇆~LeftCeiling~⌈~LeftDoubleBracket~⟦~LeftDownTeeVector~⥡~LeftDownVector~⇃~LeftDownVectorBar~⥙~LeftFloor~⌊~LeftRightArrow~↔~LeftRightVector~⥎~LeftTee~⊣~LeftTeeArrow~↤~LeftTeeVector~⥚~LeftTriangle~⊲~LeftTriangleBar~⧏~LeftTriangleEqual~⊴~LeftUpDownVector~⥑~LeftUpTeeVector~⥠~LeftUpVector~↿~LeftUpVectorBar~⥘~LeftVector~↼~LeftVectorBar~⥒~Leftarrow~⇐~Leftrightarrow~⇔~LessEqualGreater~⋚~LessFullEqual~≦~LessGreater~≶~LessLess~⪡~LessSlantEqual~⩽~LessTilde~≲~Lfr~𝔏~Ll~⋘~Lleftarrow~⇚~Lmidot~Ŀ~LongLeftArrow~⟵~LongLeftRightArrow~⟷~LongRightArrow~⟶~Longleftarrow~⟸~Longleftrightarrow~⟺~Longrightarrow~⟹~Lopf~𝕃~LowerLeftArrow~↙~LowerRightArrow~↘~Lscr~ℒ~Lsh~↰~Lstrok~Ł~Lt~≪~Map~⤅~Mcy~М~MediumSpace~ ~Mellintrf~ℳ~Mfr~𝔐~MinusPlus~∓~Mopf~𝕄~Mscr~ℳ~NJcy~Њ~Nacute~Ń~Ncaron~Ň~Ncedil~Ņ~Ncy~Н~NegativeMediumSpace~​~NegativeThickSpace~​~NegativeThinSpace~​~NegativeVeryThinSpace~​~NestedGreaterGreater~≫~NestedLessLess~≪~NewLine~\n~Nfr~𝔑~NoBreak~⁠~NonBreakingSpace~ ~Nopf~ℕ~Not~⫬~NotCongruent~≢~NotCupCap~≭~NotDoubleVerticalBar~∦~NotElement~∉~NotEqual~≠~NotEqualTilde~≂̸~NotExists~∄~NotGreater~≯~NotGreaterEqual~≱~NotGreaterFullEqual~≧̸~NotGreaterGreater~≫̸~NotGreaterLess~≹~NotGreaterSlantEqual~⩾̸~NotGreaterTilde~≵~NotHumpDownHump~≎̸~NotHumpEqual~≏̸~NotLeftTriangle~⋪~NotLeftTriangleBar~⧏̸~NotLeftTriangleEqual~⋬~NotLess~≮~NotLessEqual~≰~NotLessGreater~≸~NotLessLess~≪̸~NotLessSlantEqual~⩽̸~NotLessTilde~≴~NotNestedGreaterGreater~⪢̸~NotNestedLessLess~⪡̸~NotPrecedes~⊀~NotPrecedesEqual~⪯̸~NotPrecedesSlantEqual~⋠~NotReverseElement~∌~NotRightTriangle~⋫~NotRightTriangleBar~⧐̸~NotRightTriangleEqual~⋭~NotSquareSubset~⊏̸~NotSquareSubsetEqual~⋢~NotSquareSuperset~⊐̸~NotSquareSupersetEqual~⋣~NotSubset~⊂⃒~NotSubsetEqual~⊈~NotSucceeds~⊁~NotSucceedsEqual~⪰̸~NotSucceedsSlantEqual~⋡~NotSucceedsTilde~≿̸~NotSuperset~⊃⃒~NotSupersetEqual~⊉~NotTilde~≁~NotTildeEqual~≄~NotTildeFullEqual~≇~NotTildeTilde~≉~NotVerticalBar~∤~Nscr~𝒩~Ocy~О~Odblac~Ő~Ofr~𝔒~Omacr~Ō~Oopf~𝕆~OpenCurlyDoubleQuote~“~OpenCurlyQuote~‘~Or~⩔~Oscr~𝒪~Otimes~⨷~OverBar~‾~OverBrace~⏞~OverBracket~⎴~OverParenthesis~⏜~PartialD~∂~Pcy~П~Pfr~𝔓~PlusMinus~±~Poincareplane~ℌ~Popf~ℙ~Pr~⪻~Precedes~≺~PrecedesEqual~⪯~PrecedesSlantEqual~≼~PrecedesTilde~≾~Product~∏~Proportion~∷~Proportional~∝~Pscr~𝒫~Qfr~𝔔~Qopf~ℚ~Qscr~𝒬~RBarr~⤐~Racute~Ŕ~Rang~⟫~Rarr~↠~Rarrtl~⤖~Rcaron~Ř~Rcedil~Ŗ~Rcy~Р~Re~ℜ~ReverseElement~∋~ReverseEquilibrium~⇋~ReverseUpEquilibrium~⥯~Rfr~ℜ~RightAngleBracket~⟩~RightArrow~→~RightArrowBar~⇥~RightArrowLeftArrow~⇄~RightCeiling~⌉~RightDoubleBracket~⟧~RightDownTeeVector~⥝~RightDownVector~⇂~RightDownVectorBar~⥕~RightFloor~⌋~RightTee~⊢~RightTeeArrow~↦~RightTeeVector~⥛~RightTriangle~⊳~RightTriangleBar~⧐~RightTriangleEqual~⊵~RightUpDownVector~⥏~RightUpTeeVector~⥜~RightUpVector~↾~RightUpVectorBar~⥔~RightVector~⇀~RightVectorBar~⥓~Rightarrow~⇒~Ropf~ℝ~RoundImplies~⥰~Rrightarrow~⇛~Rscr~ℛ~Rsh~↱~RuleDelayed~⧴~SHCHcy~Щ~SHcy~Ш~SOFTcy~Ь~Sacute~Ś~Sc~⪼~Scedil~Ş~Scirc~Ŝ~Scy~С~Sfr~𝔖~ShortDownArrow~↓~ShortLeftArrow~←~ShortRightArrow~→~ShortUpArrow~↑~SmallCircle~∘~Sopf~𝕊~Sqrt~√~Square~□~SquareIntersection~⊓~SquareSubset~⊏~SquareSubsetEqual~⊑~SquareSuperset~⊐~SquareSupersetEqual~⊒~SquareUnion~⊔~Sscr~𝒮~Star~⋆~Sub~⋐~Subset~⋐~SubsetEqual~⊆~Succeeds~≻~SucceedsEqual~⪰~SucceedsSlantEqual~≽~SucceedsTilde~≿~SuchThat~∋~Sum~∑~Sup~⋑~Superset~⊃~SupersetEqual~⊇~Supset~⋑~TRADE~™~TSHcy~Ћ~TScy~Ц~Tab~ ~Tcaron~Ť~Tcedil~Ţ~Tcy~Т~Tfr~𝔗~Therefore~∴~ThickSpace~  ~ThinSpace~ ~Tilde~∼~TildeEqual~≃~TildeFullEqual~≅~TildeTilde~≈~Topf~𝕋~TripleDot~⃛~Tscr~𝒯~Tstrok~Ŧ~Uarr~↟~Uarrocir~⥉~Ubrcy~Ў~Ubreve~Ŭ~Ucy~У~Udblac~Ű~Ufr~𝔘~Umacr~Ū~UnderBar~_~UnderBrace~⏟~UnderBracket~⎵~UnderParenthesis~⏝~Union~⋃~UnionPlus~⊎~Uogon~Ų~Uopf~𝕌~UpArrow~↑~UpArrowBar~⤒~UpArrowDownArrow~⇅~UpDownArrow~↕~UpEquilibrium~⥮~UpTee~⊥~UpTeeArrow~↥~Uparrow~⇑~Updownarrow~⇕~UpperLeftArrow~↖~UpperRightArrow~↗~Upsi~ϒ~Uring~Ů~Uscr~𝒰~Utilde~Ũ~VDash~⊫~Vbar~⫫~Vcy~В~Vdash~⊩~Vdashl~⫦~Vee~⋁~Verbar~‖~Vert~‖~VerticalBar~∣~VerticalLine~|~VerticalSeparator~❘~VerticalTilde~≀~VeryThinSpace~ ~Vfr~𝔙~Vopf~𝕍~Vscr~𝒱~Vvdash~⊪~Wcirc~Ŵ~Wedge~⋀~Wfr~𝔚~Wopf~𝕎~Wscr~𝒲~Xfr~𝔛~Xopf~𝕏~Xscr~𝒳~YAcy~Я~YIcy~Ї~YUcy~Ю~Ycirc~Ŷ~Ycy~Ы~Yfr~𝔜~Yopf~𝕐~Yscr~𝒴~ZHcy~Ж~Zacute~Ź~Zcaron~Ž~Zcy~З~Zdot~Ż~ZeroWidthSpace~​~Zfr~ℨ~Zopf~ℤ~Zscr~𝒵~abreve~ă~ac~∾~acE~∾̳~acd~∿~acy~а~af~⁡~afr~𝔞~aleph~ℵ~amacr~ā~amalg~⨿~andand~⩕~andd~⩜~andslope~⩘~andv~⩚~ange~⦤~angle~∠~angmsd~∡~angmsdaa~⦨~angmsdab~⦩~angmsdac~⦪~angmsdad~⦫~angmsdae~⦬~angmsdaf~⦭~angmsdag~⦮~angmsdah~⦯~angrt~∟~angrtvb~⊾~angrtvbd~⦝~angsph~∢~angst~Å~angzarr~⍼~aogon~ą~aopf~𝕒~ap~≈~apE~⩰~apacir~⩯~ape~≊~apid~≋~approx~≈~approxeq~≊~ascr~𝒶~ast~*~asympeq~≍~awconint~∳~awint~⨑~bNot~⫭~backcong~≌~backepsilon~϶~backprime~‵~backsim~∽~backsimeq~⋍~barvee~⊽~barwed~⌅~barwedge~⌅~bbrk~⎵~bbrktbrk~⎶~bcong~≌~bcy~б~becaus~∵~because~∵~bemptyv~⦰~bepsi~϶~bernou~ℬ~beth~ℶ~between~≬~bfr~𝔟~bigcap~⋂~bigcirc~◯~bigcup~⋃~bigodot~⨀~bigoplus~⨁~bigotimes~⨂~bigsqcup~⨆~bigstar~★~bigtriangledown~▽~bigtriangleup~△~biguplus~⨄~bigvee~⋁~bigwedge~⋀~bkarow~⤍~blacklozenge~⧫~blacksquare~▪~blacktriangle~▴~blacktriangledown~▾~blacktriangleleft~◂~blacktriangleright~▸~blank~␣~blk12~▒~blk14~░~blk34~▓~block~█~bne~=⃥~bnequiv~≡⃥~bnot~⌐~bopf~𝕓~bot~⊥~bottom~⊥~bowtie~⋈~boxDL~╗~boxDR~╔~boxDl~╖~boxDr~╓~boxH~═~boxHD~╦~boxHU~╩~boxHd~╤~boxHu~╧~boxUL~╝~boxUR~╚~boxUl~╜~boxUr~╙~boxV~║~boxVH~╬~boxVL~╣~boxVR~╠~boxVh~╫~boxVl~╢~boxVr~╟~boxbox~⧉~boxdL~╕~boxdR~╒~boxdl~┐~boxdr~┌~boxh~─~boxhD~╥~boxhU~╨~boxhd~┬~boxhu~┴~boxminus~⊟~boxplus~⊞~boxtimes~⊠~boxuL~╛~boxuR~╘~boxul~┘~boxur~└~boxv~│~boxvH~╪~boxvL~╡~boxvR~╞~boxvh~┼~boxvl~┤~boxvr~├~bprime~‵~breve~˘~bscr~𝒷~bsemi~⁏~bsim~∽~bsime~⋍~bsol~\\~bsolb~⧅~bsolhsub~⟈~bullet~•~bump~≎~bumpE~⪮~bumpe~≏~bumpeq~≏~cacute~ć~capand~⩄~capbrcup~⩉~capcap~⩋~capcup~⩇~capdot~⩀~caps~∩︀~caret~⁁~caron~ˇ~ccaps~⩍~ccaron~č~ccirc~ĉ~ccups~⩌~ccupssm~⩐~cdot~ċ~cemptyv~⦲~centerdot~·~cfr~𝔠~chcy~ч~check~✓~checkmark~✓~cir~○~cirE~⧃~circeq~≗~circlearrowleft~↺~circlearrowright~↻~circledR~®~circledS~Ⓢ~circledast~⊛~circledcirc~⊚~circleddash~⊝~cire~≗~cirfnint~⨐~cirmid~⫯~cirscir~⧂~clubsuit~♣~colon~:~colone~≔~coloneq~≔~comma~,~commat~@~comp~∁~compfn~∘~complement~∁~complexes~ℂ~congdot~⩭~conint~∮~copf~𝕔~coprod~∐~copysr~℗~cross~✗~cscr~𝒸~csub~⫏~csube~⫑~csup~⫐~csupe~⫒~ctdot~⋯~cudarrl~⤸~cudarrr~⤵~cuepr~⋞~cuesc~⋟~cularr~↶~cularrp~⤽~cupbrcap~⩈~cupcap~⩆~cupcup~⩊~cupdot~⊍~cupor~⩅~cups~∪︀~curarr~↷~curarrm~⤼~curlyeqprec~⋞~curlyeqsucc~⋟~curlyvee~⋎~curlywedge~⋏~curvearrowleft~↶~curvearrowright~↷~cuvee~⋎~cuwed~⋏~cwconint~∲~cwint~∱~cylcty~⌭~dHar~⥥~daleth~ℸ~dash~‐~dashv~⊣~dbkarow~⤏~dblac~˝~dcaron~ď~dcy~д~dd~ⅆ~ddagger~‡~ddarr~⇊~ddotseq~⩷~demptyv~⦱~dfisht~⥿~dfr~𝔡~dharl~⇃~dharr~⇂~diam~⋄~diamond~⋄~diamondsuit~♦~die~¨~digamma~ϝ~disin~⋲~div~÷~divideontimes~⋇~divonx~⋇~djcy~ђ~dlcorn~⌞~dlcrop~⌍~dollar~$~dopf~𝕕~dot~˙~doteq~≐~doteqdot~≑~dotminus~∸~dotplus~∔~dotsquare~⊡~doublebarwedge~⌆~downarrow~↓~downdownarrows~⇊~downharpoonleft~⇃~downharpoonright~⇂~drbkarow~⤐~drcorn~⌟~drcrop~⌌~dscr~𝒹~dscy~ѕ~dsol~⧶~dstrok~đ~dtdot~⋱~dtri~▿~dtrif~▾~duarr~⇵~duhar~⥯~dwangle~⦦~dzcy~џ~dzigrarr~⟿~eDDot~⩷~eDot~≑~easter~⩮~ecaron~ě~ecir~≖~ecolon~≕~ecy~э~edot~ė~ee~ⅇ~efDot~≒~efr~𝔢~eg~⪚~egs~⪖~egsdot~⪘~el~⪙~elinters~⏧~ell~ℓ~els~⪕~elsdot~⪗~emacr~ē~emptyset~∅~emptyv~∅~emsp13~ ~emsp14~ ~eng~ŋ~eogon~ę~eopf~𝕖~epar~⋕~eparsl~⧣~eplus~⩱~epsi~ε~epsiv~ϵ~eqcirc~≖~eqcolon~≕~eqsim~≂~eqslantgtr~⪖~eqslantless~⪕~equals~=~equest~≟~equivDD~⩸~eqvparsl~⧥~erDot~≓~erarr~⥱~escr~ℯ~esdot~≐~esim~≂~excl~!~expectation~ℰ~exponentiale~ⅇ~fallingdotseq~≒~fcy~ф~female~♀~ffilig~ffi~fflig~ff~ffllig~ffl~ffr~𝔣~filig~fi~fjlig~fj~flat~♭~fllig~fl~fltns~▱~fopf~𝕗~fork~⋔~forkv~⫙~fpartint~⨍~frac13~⅓~frac15~⅕~frac16~⅙~frac18~⅛~frac23~⅔~frac25~⅖~frac35~⅗~frac38~⅜~frac45~⅘~frac56~⅚~frac58~⅝~frac78~⅞~frown~⌢~fscr~𝒻~gE~≧~gEl~⪌~gacute~ǵ~gammad~ϝ~gap~⪆~gbreve~ğ~gcirc~ĝ~gcy~г~gdot~ġ~gel~⋛~geq~≥~geqq~≧~geqslant~⩾~ges~⩾~gescc~⪩~gesdot~⪀~gesdoto~⪂~gesdotol~⪄~gesl~⋛︀~gesles~⪔~gfr~𝔤~gg~≫~ggg~⋙~gimel~ℷ~gjcy~ѓ~gl~≷~glE~⪒~gla~⪥~glj~⪤~gnE~≩~gnap~⪊~gnapprox~⪊~gne~⪈~gneq~⪈~gneqq~≩~gnsim~⋧~gopf~𝕘~grave~`~gscr~ℊ~gsim~≳~gsime~⪎~gsiml~⪐~gtcc~⪧~gtcir~⩺~gtdot~⋗~gtlPar~⦕~gtquest~⩼~gtrapprox~⪆~gtrarr~⥸~gtrdot~⋗~gtreqless~⋛~gtreqqless~⪌~gtrless~≷~gtrsim~≳~gvertneqq~≩︀~gvnE~≩︀~hairsp~ ~half~½~hamilt~ℋ~hardcy~ъ~harrcir~⥈~harrw~↭~hbar~ℏ~hcirc~ĥ~heartsuit~♥~hercon~⊹~hfr~𝔥~hksearow~⤥~hkswarow~⤦~hoarr~⇿~homtht~∻~hookleftarrow~↩~hookrightarrow~↪~hopf~𝕙~horbar~―~hscr~𝒽~hslash~ℏ~hstrok~ħ~hybull~⁃~hyphen~‐~ic~⁣~icy~и~iecy~е~iff~⇔~ifr~𝔦~ii~ⅈ~iiiint~⨌~iiint~∭~iinfin~⧜~iiota~℩~ijlig~ij~imacr~ī~imagline~ℐ~imagpart~ℑ~imath~ı~imof~⊷~imped~Ƶ~in~∈~incare~℅~infintie~⧝~inodot~ı~intcal~⊺~integers~ℤ~intercal~⊺~intlarhk~⨗~intprod~⨼~iocy~ё~iogon~į~iopf~𝕚~iprod~⨼~iscr~𝒾~isinE~⋹~isindot~⋵~isins~⋴~isinsv~⋳~isinv~∈~it~⁢~itilde~ĩ~iukcy~і~jcirc~ĵ~jcy~й~jfr~𝔧~jmath~ȷ~jopf~𝕛~jscr~𝒿~jsercy~ј~jukcy~є~kappav~ϰ~kcedil~ķ~kcy~к~kfr~𝔨~kgreen~ĸ~khcy~х~kjcy~ќ~kopf~𝕜~kscr~𝓀~lAarr~⇚~lAtail~⤛~lBarr~⤎~lE~≦~lEg~⪋~lHar~⥢~lacute~ĺ~laemptyv~⦴~lagran~ℒ~langd~⦑~langle~⟨~lap~⪅~larrb~⇤~larrbfs~⤟~larrfs~⤝~larrhk~↩~larrlp~↫~larrpl~⤹~larrsim~⥳~larrtl~↢~lat~⪫~latail~⤙~late~⪭~lates~⪭︀~lbarr~⤌~lbbrk~❲~lbrace~{~lbrack~[~lbrke~⦋~lbrksld~⦏~lbrkslu~⦍~lcaron~ľ~lcedil~ļ~lcub~{~lcy~л~ldca~⤶~ldquor~„~ldrdhar~⥧~ldrushar~⥋~ldsh~↲~leftarrow~←~leftarrowtail~↢~leftharpoondown~↽~leftharpoonup~↼~leftleftarrows~⇇~leftrightarrow~↔~leftrightarrows~⇆~leftrightharpoons~⇋~leftrightsquigarrow~↭~leftthreetimes~⋋~leg~⋚~leq~≤~leqq~≦~leqslant~⩽~les~⩽~lescc~⪨~lesdot~⩿~lesdoto~⪁~lesdotor~⪃~lesg~⋚︀~lesges~⪓~lessapprox~⪅~lessdot~⋖~lesseqgtr~⋚~lesseqqgtr~⪋~lessgtr~≶~lesssim~≲~lfisht~⥼~lfr~𝔩~lg~≶~lgE~⪑~lhard~↽~lharu~↼~lharul~⥪~lhblk~▄~ljcy~љ~ll~≪~llarr~⇇~llcorner~⌞~llhard~⥫~lltri~◺~lmidot~ŀ~lmoust~⎰~lmoustache~⎰~lnE~≨~lnap~⪉~lnapprox~⪉~lne~⪇~lneq~⪇~lneqq~≨~lnsim~⋦~loang~⟬~loarr~⇽~lobrk~⟦~longleftarrow~⟵~longleftrightarrow~⟷~longmapsto~⟼~longrightarrow~⟶~looparrowleft~↫~looparrowright~↬~lopar~⦅~lopf~𝕝~loplus~⨭~lotimes~⨴~lowbar~_~lozenge~◊~lozf~⧫~lpar~(~lparlt~⦓~lrarr~⇆~lrcorner~⌟~lrhar~⇋~lrhard~⥭~lrtri~⊿~lscr~𝓁~lsh~↰~lsim~≲~lsime~⪍~lsimg~⪏~lsqb~[~lsquor~‚~lstrok~ł~ltcc~⪦~ltcir~⩹~ltdot~⋖~lthree~⋋~ltimes~⋉~ltlarr~⥶~ltquest~⩻~ltrPar~⦖~ltri~◃~ltrie~⊴~ltrif~◂~lurdshar~⥊~luruhar~⥦~lvertneqq~≨︀~lvnE~≨︀~mDDot~∺~male~♂~malt~✠~maltese~✠~map~↦~mapsto~↦~mapstodown~↧~mapstoleft~↤~mapstoup~↥~marker~▮~mcomma~⨩~mcy~м~measuredangle~∡~mfr~𝔪~mho~℧~mid~∣~midast~*~midcir~⫰~minusb~⊟~minusd~∸~minusdu~⨪~mlcp~⫛~mldr~…~mnplus~∓~models~⊧~mopf~𝕞~mp~∓~mscr~𝓂~mstpos~∾~multimap~⊸~mumap~⊸~nGg~⋙̸~nGt~≫⃒~nGtv~≫̸~nLeftarrow~⇍~nLeftrightarrow~⇎~nLl~⋘̸~nLt~≪⃒~nLtv~≪̸~nRightarrow~⇏~nVDash~⊯~nVdash~⊮~nacute~ń~nang~∠⃒~nap~≉~napE~⩰̸~napid~≋̸~napos~ʼn~napprox~≉~natur~♮~natural~♮~naturals~ℕ~nbump~≎̸~nbumpe~≏̸~ncap~⩃~ncaron~ň~ncedil~ņ~ncong~≇~ncongdot~⩭̸~ncup~⩂~ncy~н~neArr~⇗~nearhk~⤤~nearr~↗~nearrow~↗~nedot~≐̸~nequiv~≢~nesear~⤨~nesim~≂̸~nexist~∄~nexists~∄~nfr~𝔫~ngE~≧̸~nge~≱~ngeq~≱~ngeqq~≧̸~ngeqslant~⩾̸~nges~⩾̸~ngsim~≵~ngt~≯~ngtr~≯~nhArr~⇎~nharr~↮~nhpar~⫲~nis~⋼~nisd~⋺~niv~∋~njcy~њ~nlArr~⇍~nlE~≦̸~nlarr~↚~nldr~‥~nle~≰~nleftarrow~↚~nleftrightarrow~↮~nleq~≰~nleqq~≦̸~nleqslant~⩽̸~nles~⩽̸~nless~≮~nlsim~≴~nlt~≮~nltri~⋪~nltrie~⋬~nmid~∤~nopf~𝕟~notinE~⋹̸~notindot~⋵̸~notinva~∉~notinvb~⋷~notinvc~⋶~notni~∌~notniva~∌~notnivb~⋾~notnivc~⋽~npar~∦~nparallel~∦~nparsl~⫽⃥~npart~∂̸~npolint~⨔~npr~⊀~nprcue~⋠~npre~⪯̸~nprec~⊀~npreceq~⪯̸~nrArr~⇏~nrarr~↛~nrarrc~⤳̸~nrarrw~↝̸~nrightarrow~↛~nrtri~⋫~nrtrie~⋭~nsc~⊁~nsccue~⋡~nsce~⪰̸~nscr~𝓃~nshortmid~∤~nshortparallel~∦~nsim~≁~nsime~≄~nsimeq~≄~nsmid~∤~nspar~∦~nsqsube~⋢~nsqsupe~⋣~nsubE~⫅̸~nsube~⊈~nsubset~⊂⃒~nsubseteq~⊈~nsubseteqq~⫅̸~nsucc~⊁~nsucceq~⪰̸~nsup~⊅~nsupE~⫆̸~nsupe~⊉~nsupset~⊃⃒~nsupseteq~⊉~nsupseteqq~⫆̸~ntgl~≹~ntlg~≸~ntriangleleft~⋪~ntrianglelefteq~⋬~ntriangleright~⋫~ntrianglerighteq~⋭~num~#~numero~№~numsp~ ~nvDash~⊭~nvHarr~⤄~nvap~≍⃒~nvdash~⊬~nvge~≥⃒~nvgt~>⃒~nvinfin~⧞~nvlArr~⤂~nvle~≤⃒~nvlt~<⃒~nvltrie~⊴⃒~nvrArr~⤃~nvrtrie~⊵⃒~nvsim~∼⃒~nwArr~⇖~nwarhk~⤣~nwarr~↖~nwarrow~↖~nwnear~⤧~oS~Ⓢ~oast~⊛~ocir~⊚~ocy~о~odash~⊝~odblac~ő~odiv~⨸~odot~⊙~odsold~⦼~ofcir~⦿~ofr~𝔬~ogon~˛~ogt~⧁~ohbar~⦵~ohm~Ω~oint~∮~olarr~↺~olcir~⦾~olcross~⦻~olt~⧀~omacr~ō~omid~⦶~ominus~⊖~oopf~𝕠~opar~⦷~operp~⦹~orarr~↻~ord~⩝~order~ℴ~orderof~ℴ~origof~⊶~oror~⩖~orslope~⩗~orv~⩛~oscr~ℴ~osol~⊘~otimesas~⨶~ovbar~⌽~par~∥~parallel~∥~parsim~⫳~parsl~⫽~pcy~п~percnt~%~period~.~pertenk~‱~pfr~𝔭~phiv~ϕ~phmmat~ℳ~phone~☎~pitchfork~⋔~planck~ℏ~planckh~ℎ~plankv~ℏ~plus~+~plusacir~⨣~plusb~⊞~pluscir~⨢~plusdo~∔~plusdu~⨥~pluse~⩲~plussim~⨦~plustwo~⨧~pm~±~pointint~⨕~popf~𝕡~pr~≺~prE~⪳~prap~⪷~prcue~≼~pre~⪯~prec~≺~precapprox~⪷~preccurlyeq~≼~preceq~⪯~precnapprox~⪹~precneqq~⪵~precnsim~⋨~precsim~≾~primes~ℙ~prnE~⪵~prnap~⪹~prnsim~⋨~profalar~⌮~profline~⌒~profsurf~⌓~propto~∝~prsim~≾~prurel~⊰~pscr~𝓅~puncsp~ ~qfr~𝔮~qint~⨌~qopf~𝕢~qprime~⁗~qscr~𝓆~quaternions~ℍ~quatint~⨖~quest~?~questeq~≟~rAarr~⇛~rAtail~⤜~rBarr~⤏~rHar~⥤~race~∽̱~racute~ŕ~raemptyv~⦳~rangd~⦒~range~⦥~rangle~⟩~rarrap~⥵~rarrb~⇥~rarrbfs~⤠~rarrc~⤳~rarrfs~⤞~rarrhk~↪~rarrlp~↬~rarrpl~⥅~rarrsim~⥴~rarrtl~↣~rarrw~↝~ratail~⤚~ratio~∶~rationals~ℚ~rbarr~⤍~rbbrk~❳~rbrace~}~rbrack~]~rbrke~⦌~rbrksld~⦎~rbrkslu~⦐~rcaron~ř~rcedil~ŗ~rcub~}~rcy~р~rdca~⤷~rdldhar~⥩~rdquor~”~rdsh~↳~realine~ℛ~realpart~ℜ~reals~ℝ~rect~▭~rfisht~⥽~rfr~𝔯~rhard~⇁~rharu~⇀~rharul~⥬~rhov~ϱ~rightarrow~→~rightarrowtail~↣~rightharpoondown~⇁~rightharpoonup~⇀~rightleftarrows~⇄~rightleftharpoons~⇌~rightrightarrows~⇉~rightsquigarrow~↝~rightthreetimes~⋌~ring~˚~risingdotseq~≓~rlarr~⇄~rlhar~⇌~rmoust~⎱~rmoustache~⎱~rnmid~⫮~roang~⟭~roarr~⇾~robrk~⟧~ropar~⦆~ropf~𝕣~roplus~⨮~rotimes~⨵~rpar~)~rpargt~⦔~rppolint~⨒~rrarr~⇉~rscr~𝓇~rsh~↱~rsqb~]~rsquor~’~rthree~⋌~rtimes~⋊~rtri~▹~rtrie~⊵~rtrif~▸~rtriltri~⧎~ruluhar~⥨~rx~℞~sacute~ś~sc~≻~scE~⪴~scap~⪸~sccue~≽~sce~⪰~scedil~ş~scirc~ŝ~scnE~⪶~scnap~⪺~scnsim~⋩~scpolint~⨓~scsim~≿~scy~с~sdotb~⊡~sdote~⩦~seArr~⇘~searhk~⤥~searr~↘~searrow~↘~semi~;~seswar~⤩~setminus~∖~setmn~∖~sext~✶~sfr~𝔰~sfrown~⌢~sharp~♯~shchcy~щ~shcy~ш~shortmid~∣~shortparallel~∥~sigmav~ς~simdot~⩪~sime~≃~simeq~≃~simg~⪞~simgE~⪠~siml~⪝~simlE~⪟~simne~≆~simplus~⨤~simrarr~⥲~slarr~←~smallsetminus~∖~smashp~⨳~smeparsl~⧤~smid~∣~smile~⌣~smt~⪪~smte~⪬~smtes~⪬︀~softcy~ь~sol~/~solb~⧄~solbar~⌿~sopf~𝕤~spadesuit~♠~spar~∥~sqcap~⊓~sqcaps~⊓︀~sqcup~⊔~sqcups~⊔︀~sqsub~⊏~sqsube~⊑~sqsubset~⊏~sqsubseteq~⊑~sqsup~⊐~sqsupe~⊒~sqsupset~⊐~sqsupseteq~⊒~squ~□~square~□~squarf~▪~squf~▪~srarr~→~sscr~𝓈~ssetmn~∖~ssmile~⌣~sstarf~⋆~star~☆~starf~★~straightepsilon~ϵ~straightphi~ϕ~strns~¯~subE~⫅~subdot~⪽~subedot~⫃~submult~⫁~subnE~⫋~subne~⊊~subplus~⪿~subrarr~⥹~subset~⊂~subseteq~⊆~subseteqq~⫅~subsetneq~⊊~subsetneqq~⫋~subsim~⫇~subsub~⫕~subsup~⫓~succ~≻~succapprox~⪸~succcurlyeq~≽~succeq~⪰~succnapprox~⪺~succneqq~⪶~succnsim~⋩~succsim~≿~sung~♪~supE~⫆~supdot~⪾~supdsub~⫘~supedot~⫄~suphsol~⟉~suphsub~⫗~suplarr~⥻~supmult~⫂~supnE~⫌~supne~⊋~supplus~⫀~supset~⊃~supseteq~⊇~supseteqq~⫆~supsetneq~⊋~supsetneqq~⫌~supsim~⫈~supsub~⫔~supsup~⫖~swArr~⇙~swarhk~⤦~swarr~↙~swarrow~↙~swnwar~⤪~target~⌖~tbrk~⎴~tcaron~ť~tcedil~ţ~tcy~т~tdot~⃛~telrec~⌕~tfr~𝔱~therefore~∴~thetav~ϑ~thickapprox~≈~thicksim~∼~thkap~≈~thksim~∼~timesb~⊠~timesbar~⨱~timesd~⨰~tint~∭~toea~⤨~top~⊤~topbot~⌶~topcir~⫱~topf~𝕥~topfork~⫚~tosa~⤩~tprime~‴~triangle~▵~triangledown~▿~triangleleft~◃~trianglelefteq~⊴~triangleq~≜~triangleright~▹~trianglerighteq~⊵~tridot~◬~trie~≜~triminus~⨺~triplus~⨹~trisb~⧍~tritime~⨻~trpezium~⏢~tscr~𝓉~tscy~ц~tshcy~ћ~tstrok~ŧ~twixt~≬~twoheadleftarrow~↞~twoheadrightarrow~↠~uHar~⥣~ubrcy~ў~ubreve~ŭ~ucy~у~udarr~⇅~udblac~ű~udhar~⥮~ufisht~⥾~ufr~𝔲~uharl~↿~uharr~↾~uhblk~▀~ulcorn~⌜~ulcorner~⌜~ulcrop~⌏~ultri~◸~umacr~ū~uogon~ų~uopf~𝕦~uparrow~↑~updownarrow~↕~upharpoonleft~↿~upharpoonright~↾~uplus~⊎~upsi~υ~upuparrows~⇈~urcorn~⌝~urcorner~⌝~urcrop~⌎~uring~ů~urtri~◹~uscr~𝓊~utdot~⋰~utilde~ũ~utri~▵~utrif~▴~uuarr~⇈~uwangle~⦧~vArr~⇕~vBar~⫨~vBarv~⫩~vDash~⊨~vangrt~⦜~varepsilon~ϵ~varkappa~ϰ~varnothing~∅~varphi~ϕ~varpi~ϖ~varpropto~∝~varr~↕~varrho~ϱ~varsigma~ς~varsubsetneq~⊊︀~varsubsetneqq~⫋︀~varsupsetneq~⊋︀~varsupsetneqq~⫌︀~vartheta~ϑ~vartriangleleft~⊲~vartriangleright~⊳~vcy~в~vdash~⊢~vee~∨~veebar~⊻~veeeq~≚~vellip~⋮~verbar~|~vert~|~vfr~𝔳~vltri~⊲~vnsub~⊂⃒~vnsup~⊃⃒~vopf~𝕧~vprop~∝~vrtri~⊳~vscr~𝓋~vsubnE~⫋︀~vsubne~⊊︀~vsupnE~⫌︀~vsupne~⊋︀~vzigzag~⦚~wcirc~ŵ~wedbar~⩟~wedge~∧~wedgeq~≙~wfr~𝔴~wopf~𝕨~wp~℘~wr~≀~wreath~≀~wscr~𝓌~xcap~⋂~xcirc~◯~xcup~⋃~xdtri~▽~xfr~𝔵~xhArr~⟺~xharr~⟷~xlArr~⟸~xlarr~⟵~xmap~⟼~xnis~⋻~xodot~⨀~xopf~𝕩~xoplus~⨁~xotime~⨂~xrArr~⟹~xrarr~⟶~xscr~𝓍~xsqcup~⨆~xuplus~⨄~xutri~△~xvee~⋁~xwedge~⋀~yacy~я~ycirc~ŷ~ycy~ы~yfr~𝔶~yicy~ї~yopf~𝕪~yscr~𝓎~yucy~ю~zacute~ź~zcaron~ž~zcy~з~zdot~ż~zeetrf~ℨ~zfr~𝔷~zhcy~ж~zigrarr~⇝~zopf~𝕫~zscr~𝓏~~AMP~&~COPY~©~GT~>~LT~<~QUOT~"~REG~®',Aa.html4);var Ga=function(){return Ga=Object.assign||function(e){for(var i,n=1,o=arguments.length;n<o;n++){i=arguments[n];for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(e[a]=i[a])}return e},Ga.apply(this,arguments)};Ga(Ga({},Aa),{all:Aa.html5});var ol=/&(?:#\d+|#[xX][\da-fA-F]+|[0-9a-zA-Z]+);/g,al=/&(?:#\d+|#[xX][\da-fA-F]+|[0-9a-zA-Z]+)[;=]?/g,z0={xml:{strict:ol,attribute:al,body:nl.xml},html4:{strict:ol,attribute:al,body:nl.html4},html5:{strict:ol,attribute:al,body:nl.html5}};Ga(Ga({},z0),{all:z0.html5});Ik();const K0=(e,i)=>Object.hasOwn(e,i),tl=(e,i)=>Object.assign(e,i),sl=(e,i,n)=>{if(e.length===0)return[];let o=0;const a=F7.exec(e[0]);a&&(o=a[1].length);const t=String.raw`(\r\n|\r|\n).{0,${o}}`,s=new RegExp(t,"g"),r=i?e.slice(1):e,{newline:u,trimLeadingNewline:d,trimTrailingNewline:l}=n,g=typeof u=="string",h=r.length,c=Array.from({length:h});for(let p=0;p<h;p++){let f=r[p];f=f.replace(s,"$1"),p===0&&d&&(f=f.replace(O7,"")),p===h-1&&l&&(f=f.replace(A7,"")),g&&(f=f.replaceAll(W7,u)),c[p]=f}return c},Aue=(e,i)=>{const n=Array.from({length:e.length+i.length});let o=0;const a=e.length;for(;o<a-1;o++)n[o*2]=e[o],n[o*2+1]=String(i[o]);return n[o*2]=e[o],n.join("")},Gue=e=>K0(e,"raw")&&K0(e,"length"),Fue=new WeakMap,pL=e=>{const i=e.cache!==!1,n=i?e.cacheStore??Fue:void 0,o=e.newline!==void 0;function a(t,...s){if(Gue(t)){const r=t,u=s.length;if(r.length===1&&r[0]==="")return"";if(u===0){if(i&&n&&!o){const h=n.get(r);if(h)return h[0]}const g=sl(r,!1,e);return i&&n&&n.set(r,g),g[0]}const d=(s[0]===a||s[0]===Que)&&Q7.test(r[0])&&G7.test(r[1]);let l;return i&&n&&!o&&(l=n.get(r)),l||(l=sl(r,d,e),i&&n&&n.set(r,l)),Aue(l,d?s.slice(1):s)}return pL(tl(tl({},e),t))}return tl(a,{string(t){return t===""||!t?"":sl([t],!1,e)[0]}})},Que=pL({cache:!0,newline:null,trimLeadingNewline:!0,trimTrailingNewline:!0}),Wue=["\0","","","","","","","\x07","\b"," ",`
96
96
  `,"\v","\f","\r","","","","","","","","","","","","","","\x1B","","","",""," ","!",'"',"#","$","%","&","'","(",")","*","+",",","-",".","/","0","1","2","3","4","5","6","7","8","9",":",";","<","=",">","?","@","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","[","\\","]","^","_","`","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","{","|","}","~",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0," ","!","C/","PS","$?","Y=","|","SS",'"',"(c)","a","<<","!",void 0,"(r)","-","deg","+-","2","3","'","u","P","*",",","1","o",">>","1/4","1/2","3/4","?","A","A","A","A","Ae","Aa","AE","C","E","E","E","E","I","I","I","I","D","N","O","O","O","O","Oe","x","Oe","U","U","U","Ue","U","Th","ss","a","a","a","a","ae","aa","ae","c","e","e","e","e","i","i","i","i","d","n","o","o","o","o","oe","/","oe","u","u","u","ue","y","th","y"],Iue=Object.freeze(Wue),_ue=["A","a","A","a","A","a","C","c","C","c","C","c","C","c","D","d","D","d","E","e","E","e","E","e","E","e","E","e","G","g","G","g","G","g","G","g","H","h","H","h","I","i","I","i","I","i","I","i","I","i","IJ","ij","J","j","K","k","k","L","l","L","l","L","l","L","l","L","l","N","n","N","n","N","n","'n","NG","ng","O","o","O","o","O","o","OE","oe","R","r","R","r","R","r","S","s","S","s","S","s","S","s","T","t","T","t","T","t","U","u","U","u","U","u","U","u","U","u","U","u","W","w","Y","y","Y","Z","z","Z","z","Z","z","s","b","B","B","b","6","6","O","C","c","D","D","D","d","d","3","@","E","F","f","G","G","hv","I","I","K","k","l","l","W","N","n","O","O","o","OI","oi","P","p","YR","2","2","SH","sh","t","T","t","T","U","u","Y","V","Y","y","Z","z","ZH","ZH","zh","zh","2","5","5","ts","w","|","||","|=","!","DZ","Dz","dz","LJ","Lj","lj","NJ","Nj","nj","A","a","I","i","O","o","U","u","U","u","U","u","U","u","U","u","@","A","a","A","a","AE","ae","G","g","G","g","K","k","O","o","O","o","ZH","zh","j","DZ","D","dz","G","g","HV","W","N","n","A","a","AE","ae","O","o"],zue=Object.freeze(_ue),Kue=["A","a","A","a","E","e","E","e","I","i","I","i","O","o","O","o","R","r","R","r","U","u","U","u","S","s","T","t","Y","y","H","h","N","d","OU","ou","Z","z","A","a","E","e","O","o","O","o","O","o","O","o","Y","y","l","n","t","j","db","qp","A","C","c","L","T","s","z","?","?","B","U","V","E","e","J","j","Q","q","R","r","Y","y","a","a","a","b","o","c","d","d","e","@","@","e","e","e","e","j","g","g","g","g","u","Y","h","h","i","i","I","l","l","l","lZ","W","W","m","n","n","n","o","OE","O","F","R","R","R","R","r","r","R","R","R","s","S","j","S","S","t","t","U","U","v","^","W","Y","Y","z","z","Z","Z","?","?","?","C","@","B","E","G","H","j","k","L","q","?","?","dz","dZ","dz","ts","tS","tC","fN","ls","lz","WW","]]","h","h","k","h","j","r","r","r","r","w","y","'",'"',"`","'","`","`","'","?","?","<",">","^","V","^","V","'","-","/","\\",",","_","\\","/",":",".","`","'","^","V","+","-","V",".","@",",","~",'"',"R","X","G","l","s","x","?",void 0,void 0,void 0,void 0,void 0,void 0,void 0,"V","=",'"',void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],que=Object.freeze(Kue),Uue=[void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"'",",",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"?",void 0,void 0,void 0,void 0,void 0,void 0,void 0,"A",";","E","I","I",void 0,"O",void 0,"U","O","I","A","V","G","D","E","Z","I","Th","I","K","L","M","N","KS","O","P","R",void 0,"S","T","Y","F","H","Ps","O","I","Y","a","e","i","i","y","a","v","g","d","e","z","i","th","i","k","l","m","n","x","o","p","r","s","s","t","y","f","h","ps","o","i","y","o","y","o",void 0,"b","th","U","U","U","ph","p","&",void 0,void 0,"St","st","W","w","Q","q","Sp","sp","Sh","sh","F","f","Kh","kh","H","h","G","g","CH","ch","Ti","ti","k","r","c","j",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],Vue=Object.freeze(Uue),ede=["Jo","Yo","Dj","Gj","Ye","Dz","I","Yi","J","Lj","Nj","Tsh","Kj","I","U","Dzh","A","B","V","G","D","E","Zh","Z","I","Y","K","L","M","N","O","P","R","S","T","U","F","H","C","Ch","Sh","Shch",void 0,"Y",void 0,"E","Yu","Ya","a","b","v","g","d","e","zh","z","i","y","k","l","m","n","o","p","r","s","t","u","f","h","c","ch","sh","shch",void 0,"y",void 0,"e","yu","ya","je","yo","dj","gj","ie","dz","i","yi","j","lj","nj","tsh","kj","i","u","dz","O","o","E","e","Ie","ie","E","e","Ie","ie","O","o","Io","io","Ks","ks","Ps","ps","F","f","Y","y","Y","y","u","u","O","o","O","o","Ot","ot","Q","q","*1000*",void 0,void 0,void 0,void 0,void 0,"*100.000*","*1.000.000*",void 0,void 0,'"','"',"R'","r'","G","g'","G'","g'","G'","g'","Zh'","zh'","Z'","z'","K'","k'","K'","k'","K'","k'","K'","k'","N'","n'","Ng","ng","P'","p'","Kh","kh","S'","s'","T'","t'","U","u","U'","u'","Kh'","kh'","Tts","tts","Ch'","ch'","Ch'","ch'","H","h","Ch","ch","Ch'","ch'","`","Zh","zh","K'","k'",void 0,void 0,"N'","n'",void 0,void 0,"Ch","ch",void 0,void 0,void 0,"a","a","A","a","Ae","ae","Ie","ie","@","@","@","@","Zh","zh","Z","z","Dz","dz","I","i","I","i","O","o","O","o","O","o","E","e","U","u","U","u","U","u","Ch","ch",void 0,void 0,"Y","y",void 0,void 0,void 0,void 0,void 0,void 0],ide=Object.freeze(ede),nde=[void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"A","B","G","D","Ye","Z","E","E","T`","Zh","I","L","Kh","Ts","K","H","Dz","Gh","Ch","M","Y","N","Sh","O","Ch`","P","J","Rh","S","V","T","R","Ts`","W","P`","K`","O","F",void 0,void 0,"<","'","/","!",",","?",".",void 0,"a","b","g","d","e","z","e","e","t`","zh","i","l","kh","ts","k","h","dz","gh","ch","m","y","n","sh","o","ch`","p","j","rh","s","v","t","r","ts`","w","p`","k`","o","f","yev",void 0,".","-",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"@","e","a","o","i","e","e","a","a","o",void 0,"u","'",void 0,void 0,void 0,void 0,void 0,void 0,":",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"b","g","d","h","v","z","kh","t","y","k","k","l","m","m","n","n","s","`","p","p","ts","ts","q","r","sh","t",void 0,void 0,void 0,void 0,void 0,"V","oy","i","'",'"',void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],ode=Object.freeze(nde),ade=[void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,",",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,";",void 0,void 0,void 0,"?",void 0,void 0,"a","'","w'",void 0,"y'",void 0,"b","@","t","th","j","H","kh","d","dh","r","z","s","sh","S","D","T","Z","aa","G",void 0,void 0,void 0,void 0,void 0,void 0,"f","q","k","l","m","n","h","w","~","y","an","un","in","a","u","i","W",void 0,void 0,"'","'",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9","%",".",",","*",void 0,void 0,void 0,"'","'","'",void 0,"'","'w","'u","'y","t","tth","b","t","T","p","th","bh","'h","H","ny","dy","c","ch","cch","d","D","D","Dt","dh","ddh","d","D","D","rr","R","r","R","R","R","R","j","R","S","S","S","S","S","T","GH","F","F","F","v","f","ph","Q","Q","kh","k","g","K","ng","K","g","G","N","G","G","G","L","L","L","L","N","N","N","N","N","h","Ch","hy","h","H","@","W","oe","oe","u","yu","yu","W","v","y","Y","Y","W",void 0,void 0,"y","y'",".","ae",void 0,void 0,void 0,void 0,void 0,void 0,void 0,"@","#",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"^",void 0,void 0,void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9","Sh","D","Gh","&","+m",void 0],tde=Object.freeze(ade),sde=["//","/",",","!","!","-",",",",",";","?","~","{","}","*",void 0,void 0,"'",void 0,"b","g","g","d","d","h","w","z","H","t","t","y","yh","k","l","m","n","s","s","`","p","p","S","q","r","sh","t",void 0,void 0,void 0,"a","a","a","A","A","A","e","e","e","E","i","i","u","u","u","o",void 0,"`","'",void 0,void 0,"X","Q","@","@","|","+",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"h","sh","n","r","b","L","k","'","v","m","f","dh","th","l","g","ny","s","d","z","t","y","p","j","ch","tt","hh","kh","th","z","sh","s","d","t","z","`","gh","q","w","a","aa","i","ee","u","oo","e","ey","o","oa",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],rde=Object.freeze(sde),ude=[void 0,"N","N","H",void 0,"a","aa","i","ii","u","uu","R","L","eN","e","e","ai","oN","o","o","au","k","kh","g","gh","ng","c","ch","j","jh","ny","tt","tth","dd","ddh","nn","t","th","d","dh","n","nnn","p","ph","b","bh","m","y","r","rr","l","l","lll","v","sh","ss","s","h",void 0,void 0,"'","'","aa","i","ii","u","uu","R","RR","eN","e","e","ai","oN","o","o","au",void 0,void 0,void 0,"AUM","'","'","`","'",void 0,void 0,void 0,"q","khh","ghh","z","dddh","rh","f","yy","RR","LL","L","LL"," / "," // ","0","1","2","3","4","5","6","7","8","9",".",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"N","N","H",void 0,"a","aa","i","ii","u","uu","R","RR",void 0,void 0,"e","ai",void 0,void 0,"o","au","k","kh","g","gh","ng","c","ch","j","jh","ny","tt","tth","dd","ddh","nn","t","th","d","dh","n",void 0,"p","ph","b","bh","m","y","r",void 0,"l",void 0,void 0,void 0,"sh","ss","s","h",void 0,void 0,"'",void 0,"aa","i","ii","u","uu","R","RR",void 0,void 0,"e","ai",void 0,void 0,"o","au",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"+",void 0,void 0,void 0,void 0,"rr","rh",void 0,"yy","RR","LL","L","LL",void 0,void 0,"0","1","2","3","4","5","6","7","8","9","r'","r`","Rs","Rs","1/","2/","3/","4/"," 1 - 1/","/16",void 0,void 0,void 0,void 0,void 0,void 0],dde=Object.freeze(ude),lde=[void 0,void 0,"N",void 0,void 0,"a","aa","i","ii","u","uu",void 0,void 0,void 0,void 0,"ee","ai",void 0,void 0,"oo","au","k","kh","g","gh","ng","c","ch","j","jh","ny","tt","tth","dd","ddh","nn","t","th","d","dh","n",void 0,"p","ph","b","bb","m","y","r",void 0,"l","ll",void 0,"v","sh",void 0,"s","h",void 0,void 0,"'",void 0,"aa","i","ii","u","uu",void 0,void 0,void 0,void 0,"ee","ai",void 0,void 0,"oo","au",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"khh","ghh","z","rr",void 0,"f",void 0,void 0,void 0,void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9","N","H",void 0,void 0,"G.E.O.",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"N","N","H",void 0,"a","aa","i","ii","u","uu","R",void 0,"eN",void 0,"e","ai","oN",void 0,"o","au","k","kh","g","gh","ng","c","ch","j","jh","ny","tt","tth","dd","ddh","nn","t","th","d","dh","n",void 0,"p","ph","b","bh","m","ya","r",void 0,"l","ll",void 0,"v","sh","ss","s","h",void 0,void 0,"'","'","aa","i","ii","u","uu","R","RR","eN",void 0,"e","ai","oN",void 0,"o","au",void 0,void 0,void 0,"AUM",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"RR",void 0,void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],gde=Object.freeze(lde),hde=[void 0,"N","N","H",void 0,"a","aa","i","ii","u","uu","R","L",void 0,void 0,"e","ai",void 0,void 0,"o","au","k","kh","g","gh","ng","c","ch","j","jh","ny","tt","tth","dd","ddh","nn","t","th","d","dh","n",void 0,"p","ph","b","bh","m","y","r",void 0,"l","ll",void 0,void 0,"sh","ss","s","h",void 0,void 0,"'","'","aa","i","ii","u","uu","R",void 0,void 0,void 0,"e","ai",void 0,void 0,"o","au",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"+","+",void 0,void 0,void 0,void 0,"rr","rh",void 0,"yy","RR","LL",void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"N","H",void 0,"a","aa","i","ii","u","uu",void 0,void 0,void 0,"e","ee","ai",void 0,"o","oo","au","ka",void 0,void 0,void 0,"ng","c",void 0,"j",void 0,"ny","tt",void 0,void 0,void 0,"nn","t",void 0,void 0,void 0,"n","nn","p",void 0,void 0,void 0,"m","y","r","rr","l","ll","lll","v",void 0,"ss","s","h",void 0,void 0,void 0,void 0,"aa","i","ii","u","uu",void 0,void 0,void 0,"e","ee","ai",void 0,"o","oo","au",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"+",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9","+10+","+100+","+1000+",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],cde=Object.freeze(hde),pde=[void 0,"N","N","H",void 0,"a","aa","i","ii","u","uu","R","L",void 0,"e","ee","ai",void 0,"o","oo","au","k","kh","g","gh","ng","c","ch","j","jh","ny","tt","tth","dd","ddh","nn","t","th","d","dh","n",void 0,"p","ph","b","bh","m","y","r","rr","l","ll",void 0,"v","sh","ss","s","h",void 0,void 0,void 0,void 0,"aa","i","ii","u","uu","R","RR",void 0,"e","ee","ai",void 0,"o","oo","au",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"+","+",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"RR","LL",void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"N","H",void 0,"a","aa","i","ii","u","uu","R","L",void 0,"e","ee","ai",void 0,"o","oo","au","k","kh","g","gh","ng","c","ch","j","jh","ny","tt","tth","dd","ddh","nn","t","th","d","dh","n",void 0,"p","ph","b","bh","m","y","r","rr","l","ll",void 0,"v","sh","ss","s","h",void 0,void 0,void 0,void 0,"aa","i","ii","u","uu","R","RR",void 0,"e","ee","ai",void 0,"o","oo","au",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"+","+",void 0,void 0,void 0,void 0,void 0,void 0,void 0,"lll",void 0,"RR","LL",void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],vde=Object.freeze(pde),yde=[void 0,void 0,"N","H",void 0,"a","aa","i","ii","u","uu","R","L",void 0,"e","ee","ai",void 0,"o","oo","au","k","kh","g","gh","ng","c","ch","j","jh","ny","tt","tth","dd","ddh","nn","t","th","d","dh","n",void 0,"p","ph","b","bh","m","y","r","rr","l","ll","lll","v","sh","ss","s","h",void 0,void 0,void 0,void 0,"aa","i","ii","u","uu","R",void 0,void 0,"e","ee","ai",void 0,"o","oo","au",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"+",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"RR","LL",void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"N","H",void 0,"a","aa","ae","aae","i","ii","u","uu","R","RR","L","LL","e","ee","ai","o","oo","au",void 0,void 0,void 0,"k","kh","g","gh","ng","nng","c","ch","j","jh","ny","jny","nyj","tt","tth","dd","ddh","nn","nndd","t","th","d","dh","n",void 0,"nd","p","ph","b","bh","m","mb","y","r",void 0,"l",void 0,void 0,"v","sh","ss","s","h","ll","f",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"aa","ae","aae","i","ii","u",void 0,"uu",void 0,"R","e","ee","ai","o","oo","au","L",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"RR","LL"," . ",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],fde=Object.freeze(yde),mde=[void 0,"k","kh","kh","kh","kh","kh","ng","cch","ch","ch","ch","ch","y","d","t","th","th","th","n","d","t","th","th","th","n","b","p","ph","f","ph","f","ph",void 0,void 0,"r","R","l","L","w","s","s","s",void 0,"l","`","h","~","a","a","aa","am","i","ia","ue","uue","u","uu","'",void 0,void 0,void 0,void 0,"Bh.",void 0,"ae","o","mai","ai","ao","+",void 0,void 0,void 0,void 0,void 0,void 0,"M",void 0," * ","0","1","2","3","4","5","6","7","8","9"," // "," /// ",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"k","kh",void 0,"kh",void 0,void 0,"ng","ch",void 0,"s",void 0,void 0,"ny",void 0,void 0,void 0,void 0,void 0,void 0,"d","h","th","th",void 0,"n","b","p","ph","f","ph","f",void 0,"m","y","r",void 0,"l",void 0,"w",void 0,void 0,"s","h",void 0,"`",void 0,"~","a",void 0,"aa","am","i","ii","y","yy","u","uu",void 0,"o","l","ny",void 0,void 0,"e","ei","o","ay","ai",void 0,"+",void 0,void 0,void 0,void 0,void 0,void 0,"M",void 0,void 0,"0","1","2","3","4","5","6","7","8","9",void 0,void 0,"hn","hm",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],bde=Object.freeze(mde),wde=["AUM",void 0,void 0,void 0,void 0,void 0,void 0,void 0," // "," * ",void 0,"-"," / "," / "," // "," -/ "," +/ "," X/ "," /XX/ "," /X/ ",",",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9",".5","1.5","2.5","3.5","4.5","5.5","6.5","7.5","8.5","-.5","+","*","^","_",void 0,"~",void 0,"]","[[","]]",void 0,void 0,"k","kh","g","gh","ng","c","ch","j",void 0,"ny","tt","tth","dd","ddh","nn","t","th","d","dh","n","p","ph","b","bh","m","ts","tsh","dz","dzh","w","zh","z","'","y","r","l","sh","ssh","s","h","a","kss","r",void 0,void 0,void 0,void 0,void 0,void 0,"aa","i","ii","u","uu","R","RR","L","LL","e","ee","o","oo","M","H","i","ii",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"k","kh","g","gh","ng","c","ch","j",void 0,"ny","tt","tth","dd","ddh","nn","t","th","d","dh","n","p","ph","b","bh","m","ts","tsh","dz","dzh","w","zh","z","'","y","r","l","sh","ss","s","h","a","kss","w","y","r",void 0,"X"," :X: "," /O/ "," /o/ "," \\o\\ "," (O) ",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],jde=Object.freeze(wde),kde=["k","kh","g","gh","ng","c","ch","j","jh","ny","nny","tt","tth","dd","ddh","nn","tt","th","d","dh","n","p","ph","b","bh","m","y","r","l","w","s","h","ll","a",void 0,"i","ii","u","uu","e",void 0,"o","au",void 0,"aa","i","ii","u","uu","e","ai",void 0,void 0,void 0,"N","'",":",void 0,void 0,void 0,void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9"," / "," // ","n*","r*","l*","e*","sh","ss","R","RR","L","LL","R","RR","L","LL",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"A","B","G","D","E","V","Z","T`","I","K","L","M","N","O","P","Zh","R","S","T","U","P`","K`","G'","Q","Sh","Ch`","C`","Z'","C","Ch","X","J","H","E","Y","W","Xh","OE",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"a","b","g","d","e","v","z","t","i","k","l","m","n","o","p","zh","r","s","t","u","p`","k`","gh","q","sh","ch`","c`","z'","c","ch","x","j","h","e","y","w","xh","oe","f",void 0,void 0,void 0,void 0," // ",void 0,void 0,void 0,void 0],Sde=Object.freeze(kde),Lde=["g","gg","n","d","dd","r","m","b","bb","s","ss",void 0,"j","jj","c","k","t","p","h","ng","nn","nd","nb","dg","rn","rr","rh","rN","mb","mN","bg","bn",void 0,"bs","bsg","bst","bsb","bss","bsj","bj","bc","bt","bp","bN","bbN","sg","sn","sd","sr","sm","sb","sbg","sss","s","sj","sc","sk","st","sp","sh",void 0,void 0,void 0,void 0,"Z","g","d","m","b","s","Z",void 0,"j","c","t","p","N","j",void 0,void 0,void 0,void 0,"ck","ch",void 0,void 0,"pb","pN","hh","Q",void 0,void 0,void 0,void 0,void 0,void 0,void 0,"a","ae","ya","yae","eo","e","yeo","ye","o","wa","wae","oe","yo","u","weo","we","wi","yu","eu","yi","i","a-o","a-u","ya-o","ya-yo","eo-o","eo-u","eo-eu","yeo-o","yeo-u","o-eo","o-e","o-ye","o-o","o-u","yo-ya","yo-yae","yo-yeo","yo-o","yo-i","u-a","u-ae","u-eo-eu","u-ye","u-u","yu-a","yu-eo","yu-e","yu-yeo","yu-ye","yu-u","yu-i","eu-u","eu-eu","yi-u","i-a","i-ya","i-o","i-u","i-eu","i-U","U","U-eo","U-u","U-i","UU",void 0,void 0,void 0,void 0,void 0,"g","gg","gs","n","nj","nh","d","l","lg","lm","lb","ls","lt","lp","lh","m","b","bs","s","ss","ng","j","c","k","t","p","h","gl","gsg","ng","nd","ns","nZ","nt","dg","tl","lgs","ln","ld","lth","ll","lmg","lms","lbs","lbh","rNp","lss","lZ","lk","lQ","mg","ml","mb","ms","mss","mZ","mc","mh","mN","bl","bp","ph","pN","sg","sd","sl","sb","Z","g","ss",void 0,"kh","N","Ns","NZ","pb","pN","hn","hl","hm","hb","Q",void 0,void 0,void 0,void 0,void 0,void 0],Cde=Object.freeze(Lde),Yde=["ha","hu","hi","haa","hee","he","ho",void 0,"la","lu","li","laa","lee","le","lo","lwa","hha","hhu","hhi","hhaa","hhee","hhe","hho","hhwa","ma","mu","mi","maa","mee","me","mo","mwa","sza","szu","szi","szaa","szee","sze","szo","szwa","ra","ru","ri","raa","ree","re","ro","rwa","sa","su","si","saa","see","se","so","swa","sha","shu","shi","shaa","shee","she","sho","shwa","qa","qu","qi","qaa","qee","qe","qo",void 0,"qwa",void 0,"qwi","qwaa","qwee","qwe",void 0,void 0,"qha","qhu","qhi","qhaa","qhee","qhe","qho",void 0,"qhwa",void 0,"qhwi","qhwaa","qhwee","qhwe",void 0,void 0,"ba","bu","bi","baa","bee","be","bo","bwa","va","vu","vi","vaa","vee","ve","vo","vwa","ta","tu","ti","taa","tee","te","to","twa","ca","cu","ci","caa","cee","ce","co","cwa","xa","xu","xi","xaa","xee","xe","xo",void 0,"xwa",void 0,"xwi","xwaa","xwee","xwe",void 0,void 0,"na","nu","ni","naa","nee","ne","no","nwa","nya","nyu","nyi","nyaa","nyee","nye","nyo","nywa","'a","'u",void 0,"'aa","'ee","'e","'o","'wa","ka","ku","ki","kaa","kee","ke","ko",void 0,"kwa",void 0,"kwi","kwaa","kwee","kwe",void 0,void 0,"kxa","kxu","kxi","kxaa","kxee","kxe","kxo",void 0,"kxwa",void 0,"kxwi","kxwaa","kxwee","kxwe",void 0,void 0,"wa","wu","wi","waa","wee","we","wo",void 0,"`a","`u","`i","`aa","`ee","`e","`o",void 0,"za","zu","zi","zaa","zee","ze","zo","zwa","zha","zhu","zhi","zhaa","zhee","zhe","zho","zhwa","ya","yu","yi","yaa","yee","ye","yo",void 0,"da","du","di","daa","dee","de","do","dwa","dda","ddu","ddi","ddaa","ddee","dde","ddo","ddwa"],$de=Object.freeze(Yde),Zde=["ja","ju","ji","jaa","jee","je","jo","jwa","ga","gu","gi","gaa","gee","ge","go",void 0,"gwa",void 0,"gwi","gwaa","gwee","gwe",void 0,void 0,"gga","ggu","ggi","ggaa","ggee","gge","ggo",void 0,"tha","thu","thi","thaa","thee","the","tho","thwa","cha","chu","chi","chaa","chee","che","cho","chwa","pha","phu","phi","phaa","phee","phe","pho","phwa","tsa","tsu","tsi","tsaa","tsee","tse","tso","tswa","tza","tzu","tzi","tzaa","tzee","tze","tzo",void 0,"fa","fu","fi","faa","fee","fe","fo","fwa","pa","pu","pi","paa","pee","pe","po","pwa","rya","mya","fya",void 0,void 0,void 0,void 0,void 0,void 0," ",".",",",";",":",":: ","?","//","1","2","3","4","5","6","7","8","9","10+","20+","30+","40+","50+","60+","70+","80+","90+","100+","10,000+",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"a","e","i","o","u","v","ga","ka","ge","gi","go","gu","gv","ha","he","hi","ho","hu","hv","la","le","li","lo","lu","lv","ma","me","mi","mo","mu","na","hna","nah","ne","ni","no","nu","nv","qua","que","qui","quo","quu","quv","sa","s","se","si","so","su","sv","da","ta","de","te","di","ti","do","du","dv","dla","tla","tle","tli","tlo","tlu","tlv","tsa","tse","tsi","tso","tsu","tsv","wa","we","wi","wo","wu","wv","ya","ye","yi","yo","yu","yv",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],Jde=Object.freeze(Zde),xde=[void 0,"ai","aai","i","ii","u","uu","oo","ee","i","a","aa","we","we","wi","wi","wii","wii","wo","wo","woo","woo","woo","wa","wa","waa","waa","waa","ai","w","'","t","k","sh","s","n","w","n",void 0,"w","c","?","l","en","in","on","an","pai","paai","pi","pii","pu","puu","poo","hee","hi","pa","paa","pwe","pwe","pwi","pwi","pwii","pwii","pwo","pwo","pwoo","pwoo","pwa","pwa","pwaa","pwaa","pwaa","p","p","h","tai","taai","ti","tii","tu","tuu","too","dee","di","ta","taa","twe","twe","twi","twi","twii","twii","two","two","twoo","twoo","twa","twa","twaa","twaa","twaa","t","tte","tti","tto","tta","kai","kaai","ki","kii","ku","kuu","koo","ka","kaa","kwe","kwe","kwi","kwi","kwii","kwii","kwo","kwo","kwoo","kwoo","kwa","kwa","kwaa","kwaa","kwaa","k","kw","keh","kih","koh","kah","gai","caai","gi","gii","gu","guu","coo","ga","gaa","cwe","cwe","cwi","cwi","cwii","cwii","cwo","cwo","cwoo","cwoo","cwa","cwa","cwaa","cwaa","cwaa","g","th","mai","maai","mi","mii","mu","muu","moo","ma","maa","mwe","mwe","mwi","mwi","mwii","mwii","mwo","mwo","mwoo","mwoo","mwa","mwa","mwaa","mwaa","mwaa","m","m","mh","m","m","nai","naai","ni","nii","nu","nuu","noo","na","naa","nwe","nwe","nwa","nwa","nwaa","nwaa","nwaa","n","ng","nh","lai","laai","li","lii","lu","luu","loo","la","laa","lwe","lwe","lwi","lwi","lwii","lwii","lwo","lwo","lwoo","lwoo","lwa","lwa","lwaa","lwaa","l","l","l","sai","saai","si","sii","su","suu","soo","sa","saa","swe","swe","swi","swi","swii","swii","swo","swo","swoo","swoo"],Tde=Object.freeze(xde),Dde=["swa","swa","swaa","swaa","swaa","s","s","sw","s","sk","skw","sW","spwa","stwa","skwa","scwa","she","shi","shii","sho","shoo","sha","shaa","shwe","shwe","shwi","shwi","shwii","shwii","shwo","shwo","shwoo","shwoo","shwa","shwa","shwaa","shwaa","sh","jai","yaai","ji","jii","ju","juu","yoo","ja","jaa","ywe","ywe","ywi","ywi","ywii","ywii","ywo","ywo","ywoo","ywoo","ywa","ywa","ywaa","ywaa","ywaa","j","y","y","yi","re","rai","le","raai","ri","rii","ru","ruu","lo","ra","raa","la","rwaa","rwaa","r","r","r","vai","faai","vi","vii","vu","vuu","va","vaa","fwaa","fwaa","v","the","the","thi","thi","thii","thii","tho","thoo","tha","thaa","thwaa","thwaa","th","tthe","tthi","ttho","ttha","tth","tye","tyi","tyo","tya","he","hi","hii","ho","hoo","ha","haa","h","h","hk","qaai","qi","qii","qu","quu","qa","qaa","q","tlhe","tlhi","tlho","tlha","re","ri","ro","ra","ngaai","ngi","ngii","ngu","nguu","nga","ngaa","ng","nng","she","shi","sho","sha","the","thi","tho","tha","th","lhi","lhii","lho","lhoo","lha","lhaa","lh","the","thi","thii","tho","thoo","tha","thaa","th","b","e","i","o","a","we","wi","wo","wa","ne","ni","no","na","ke","ki","ko","ka","he","hi","ho","ha","ghu","gho","ghe","ghee","ghi","gha","ru","ro","re","ree","ri","ra","wu","wo","we","wee","wi","wa","hwu","hwo","hwe","hwee","hwi","hwa","thu","tho","the","thee","thi","tha","ttu","tto","tte","ttee","tti","tta","pu","po","pe","pee","pi","pa","p","gu","go","ge","gee","gi","ga","khu","kho","khe","khee","khi","kha","kku","kko","kke","kkee","kki"],Bde=Object.freeze(Dde),Xde=["kka","kk","nu","no","ne","nee","ni","na","mu","mo","me","mee","mi","ma","yu","yo","ye","yee","yi","ya","ju","ju","jo","je","jee","ji","ji","ja","jju","jjo","jje","jjee","jji","jja","lu","lo","le","lee","li","la","dlu","dlo","dle","dlee","dli","dla","lhu","lho","lhe","lhee","lhi","lha","tlhu","tlho","tlhe","tlhee","tlhi","tlha","tlu","tlo","tle","tlee","tli","tla","zu","zo","ze","zee","zi","za","z","z","dzu","dzo","dze","dzee","dzi","dza","su","so","se","see","si","sa","shu","sho","she","shee","shi","sha","sh","tsu","tso","tse","tsee","tsi","tsa","chu","cho","che","chee","chi","cha","ttsu","ttso","ttse","ttsee","ttsi","ttsa","X",".","qai","ngai","nngi","nngii","nngo","nngoo","nnga","nngaa",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0," ","b","l","f","s","n","h","d","t","c","q","m","g","ng","z","r","a","o","u","e","i","ch","th","ph","p","x","p","<",">",void 0,void 0,void 0,"f","v","u","yr","y","w","th","th","a","o","ac","ae","o","o","o","oe","on","r","k","c","k","g","ng","g","g","w","h","h","h","h","n","n","n","i","e","j","g","ae","a","eo","p","z","s","s","s","c","z","t","t","d","b","b","p","p","e","m","m","m","l","l","ng","ng","d","o","ear","ior","qu","qu","qu","s","yr","yr","yr","q","x",".",":","+","17","18","19",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],Hde=Object.freeze(Xde),Mde=[void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"k","kh","g","gh","ng","c","ch","j","jh","ny","t","tth","d","ddh","nn","t","th","d","dh","n","p","ph","b","bh","m","y","r","l","v","sh","ss","s","h","l","q","a","aa","i","ii","u","uk","uu","uuv","ry","ryy","ly","lyy","e","ai","oo","oo","au","a","aa","aa","i","ii","y","yy","u","uu","ua","oe","ya","ie","e","ae","ai","oo","au","M","H","a`",void 0,void 0,void 0,"r",void 0,"!",void 0,void 0,void 0,void 0,void 0,"."," // ",":","+","++"," * "," /// ","KR","'",void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],Pde=Object.freeze(Mde),Nde=[" @ "," ... ",",",". ",": "," // ",void 0,"-",",",". ",void 0,void 0,void 0,void 0,void 0,void 0,"0","1","2","3","4","5","6","7","8","9",void 0,void 0,void 0,void 0,void 0,void 0,"a","e","i","o","u","O","U","ee","n","ng","b","p","q","g","m","l","s","sh","t","d","ch","j","y","r","w","f","k","kha","ts","z","h","zr","lh","zh","ch","-","e","i","o","u","O","U","ng","b","p","q","g","m","t","d","ch","j","ts","y","w","k","g","h","jy","ny","dz","e","i","iy","U","u","ng","k","g","h","p","sh","t","d","j","f","g","h","ts","z","r","ch","zh","i","k","r","f","zh",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,"H","X","W","M"," 3 "," 333 ","a","i","k","ng","c","tt","tth","dd","nn","t","d","p","ph","ss","zh","z","a","t","zh","gh","ng","c","jh","tta","ddh","t","dh","ss","cy","zh","z","u","y","bh","'",void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0],Ede=Object.freeze(Nde),Rde=["A","a","B","b","B","b","B","b","C","c","D","d","D","d","D","d","D","d","D","d","E","e","E","e","E","e","E","e","E","e","F","f","G","g","H","h","H","h","H","h","H","h","H","h","I","i","I","i","K","k","K","k","K","k","L","l","L","l","L","l","L","l","M","m","M","m","M","m","N","n","N","n","N","n","N","n","O","o","O","o","O","o","O","o","P","p","P","p","R","r","R","r","R","r","R","r","S","s","S","s","S","s","S","s","S","s","T","t","T","t","T","t","T","t","U","u","U","u","U","u","U","u","U","u","V","v","V","v","W","w","W","w","W","w","W","w","W","w","X","x","X","x","Y","y","Z","z","Z","z","Z","z","h","t","w","y","a","S",void 0,void 0,void 0,void 0,"A","a","A","a","A","a","A","a","A","a","A","a","A","a","A","a","A","a","A","a","A","a","A","a","E","e","E","e","E","e","E","e","E","e","E","e","E","e","E","e","I","i","I","i","O","o","O","o","O","o","O","o","O","o","O","o","O","o","O","o","O","o","O","o","O","o","O","o","U","u","U","u","U","u","U","u","U","u","U","u","U","u","Y","y","Y","y","Y","y","Y","y",void 0,void 0,void 0,void 0,void 0,void 0],Ode=Object.freeze(Rde),Ade=["a","a","a","a","a","a","a","a","A","A","A","A","A","A","A","A","e","e","e","e","e","e",void 0,void 0,"E","E","E","E","E","E",void 0,void 0,"e","e","e","e","e","e","e","e","E","E","E","E","E","E","E","E","i","i","i","i","i","i","i","i","I","I","I","I","I","I","I","I","o","o","o","o","o","o",void 0,void 0,"O","O","O","O","O","O",void 0,void 0,"u","u","u","u","u","u","u","u",void 0,"U",void 0,"U",void 0,"U",void 0,"U","o","o","o","o","o","o","o","o","O","O","O","O","O","O","O","O","a","a","e","e","e","e","i","i","o","o","u","u","o","o",void 0,void 0,"a","a","a","a","a","a","a","a","A","A","A","A","A","A","A","A","e","e","e","e","e","e","e","e","E","E","E","E","E","E","E","E","o","o","o","o","o","o","o","o","O","O","O","O","O","O","O","O","a","a","a","a","a",void 0,"a","a","A","A","A","A","A","'","i","'","~",'"~',"e","e","e",void 0,"e","e","E","E","E","E","E","'`","''","'~","i","i","i","i",void 0,void 0,"i","i","I","I","I","I",void 0,"`'","`'","`~","u","u","u","u","R","R","u","u","U","U","U","U","R",'"`',`"'`,"`",void 0,void 0,"o","o","o",void 0,"o","o","O","O","O","O","O","'","`",void 0],Gde=Object.freeze(Ade),Fde=[" "," "," "," "," "," "," "," "," "," "," "," ",void 0,void 0,void 0,void 0,"-","-","-","-","--","--","||","_","'","'",",","'",'"','"',",,",'"',"+","++","*","*>",".","..","...",".",`
97
97
  `,`
98
98
 
@@ -134,7 +134,7 @@ ${_d(T,{...this.#a,filterStacktrace:ml,prefix:C})}`;if(typeof T=="object")return
134
134
  ${_d(f,{...this.#a,filterStacktrace:ml,hideErrorCauseCodeView:!0,hideErrorCodeView:!0,hideErrorErrorsCodeView:!0,hideMessage:!0,prefix:C})}`),p&&y.push(`
135
135
  `,C+Vi(this.styles.underline.suffix?gf(p):p)),y.join("")}_log(i,n){const o=Zk(n)?"stderr":"stdout",a=o==="stderr"?this.#i:this.#n;this.#t&&this.#e!==void 0&&a.isTTY?this.#e.update(o,i.split(`
136
136
  `),0):Jk(`${i}
137
- `,a)}}const zye=()=>is.NODE_ENV==="debug"||is.DEBUG!==void 0?"debug":is.NODE_ENV==="test"?"warning":"informational",CL=e=>{let i=zye();return is.PAIL_LOG_LEVEL!==void 0&&(i=is.PAIL_LOG_LEVEL),new Sye({logLevel:i,processors:[new Oye],reporters:[new _ye],stderr:ip,stdout:ep,...e})};CL();const x=CL(),Xg=(e,i)=>e.tasks.find(n=>n.taskId===i),bl=(e,i)=>{const n=e??{},o=i??{},a=[],t=[],s=[];for(const r of Object.keys(n))r in o?n[r]!==o[r]&&s.push(r):a.push(r);for(const r of Object.keys(o))r in n||t.push(r);return a.sort(),t.sort(),s.sort(),{added:a,changed:s,removed:t}},Kye=(e,i)=>({commandChanged:(e?.command??"")!==(i?.command??""),implicitDeps:bl(e?.implicitDeps,i?.implicitDeps),nodes:bl(e?.nodes,i?.nodes),runtime:bl(e?.runtime,i?.runtime)}),YL=async(e,i)=>{const n=L(fo(e),`${i}.json`);try{const o=await Wf(n,"utf8");return JSON.parse(o)}catch{return}},qye=async(e,i)=>{const n=fo(e);let o;try{o=await js(n)}catch{return}const a=[];for(const t of o){if(!t.endsWith(".json")||i!==void 0&&t===`${i}.json`)continue;const s=L(n,t);try{const r=await Qa(s);r.isFile()&&a.push({mtimeMs:r.mtimeMs,path:s})}catch{}}if(a.length!==0){a.sort((t,s)=>s.mtimeMs-t.mtimeMs);try{const t=await Wf(a[0].path,"utf8");return JSON.parse(t)}catch{return}}},tSe=async e=>{const i=fo(e);let n;try{n=await js(i)}catch{return[]}const o=[];for(const a of n){if(!a.endsWith(".json"))continue;const t=L(i,a);try{const s=await Qa(t);s.isFile()&&o.push({id:a.slice(0,-5),mtimeMs:s.mtimeMs,path:t})}catch{}}return o.sort((a,t)=>t.mtimeMs-a.mtimeMs),o},$L=async e=>{let i=0;try{const n=await js(e,{withFileTypes:!0});for(const o of n){const a=L(e,o.name);if(o.isDirectory())i+=await $L(a);else if(o.isFile()){const t=await Qa(a);i+=t.size}}}catch{}return i},po=async e=>{const i=[];let n;try{n=await js(e)}catch{return[]}for(const o of n){if(o.startsWith("."))continue;const a=L(e,o);try{const t=await Qa(a);if(!t.isDirectory())continue;const s=await $L(a);i.push({hash:o,mtimeMs:t.mtimeMs,path:a,sizeBytes:s})}catch{}}return i.sort((o,a)=>a.mtimeMs-o.mtimeMs),i},ZL=(e,i=Date.now())=>{const n=Math.max(0,Math.floor((i-e)/1e3));return n<60?`${String(n)}s`:n<3600?`${String(Math.floor(n/60))}m`:n<86400?`${String(Math.floor(n/3600))}h`:`${String(Math.floor(n/86400))}d`},Uye=e=>new Promise(i=>{const n=Kf({input:process.stdin,output:process.stderr});n.question(`${e} (y/N) `,o=>{n.close();const a=o.trim().toLowerCase();i(a==="y"||a==="yes")})}),JL=async(e,i,n)=>{if(!Z(e)){if(i==="json"){process.stdout.write(`${JSON.stringify({directory:e,entries:[],totalBytes:0,totalCount:0},void 0,2)}
137
+ `,a)}}const zye=()=>is.NODE_ENV==="debug"||is.DEBUG!==void 0?"debug":is.NODE_ENV==="test"?"warning":"informational",CL=e=>{let i=zye();return is.PAIL_LOG_LEVEL!==void 0&&(i=is.PAIL_LOG_LEVEL),new Sye({logLevel:i,processors:[new Oye],reporters:[new _ye],stderr:ip,stdout:ep,...e})};CL();const x=CL(),Xg=(e,i)=>e.tasks.find(n=>n.taskId===i),bl=(e,i)=>{const n=e??{},o=i??{},a=[],t=[],s=[];for(const r of Object.keys(n))r in o?n[r]!==o[r]&&s.push(r):a.push(r);for(const r of Object.keys(o))r in n||t.push(r);return a.sort(),t.sort(),s.sort(),{added:a,changed:s,removed:t}},Kye=(e,i)=>({commandChanged:(e?.command??"")!==(i?.command??""),implicitDeps:bl(e?.implicitDeps,i?.implicitDeps),nodes:bl(e?.nodes,i?.nodes),runtime:bl(e?.runtime,i?.runtime)}),YL=async(e,i)=>{const n=L(fo(e),`${i}.json`);try{const o=await Wf(n,"utf8");return JSON.parse(o)}catch{return}},qye=async(e,i)=>{const n=fo(e);let o;try{o=await js(n)}catch{return}const a=[];for(const t of o){if(!t.endsWith(".json")||i!==void 0&&t===`${i}.json`)continue;const s=L(n,t);try{const r=await Qa(s);r.isFile()&&a.push({mtimeMs:r.mtimeMs,path:s})}catch{}}if(a.length!==0){a.sort((t,s)=>s.mtimeMs-t.mtimeMs);try{const t=await Wf(a[0].path,"utf8");return JSON.parse(t)}catch{return}}},s1e=async e=>{const i=fo(e);let n;try{n=await js(i)}catch{return[]}const o=[];for(const a of n){if(!a.endsWith(".json"))continue;const t=L(i,a);try{const s=await Qa(t);s.isFile()&&o.push({id:a.slice(0,-5),mtimeMs:s.mtimeMs,path:t})}catch{}}return o.sort((a,t)=>t.mtimeMs-a.mtimeMs),o},$L=async e=>{let i=0;try{const n=await js(e,{withFileTypes:!0});for(const o of n){const a=L(e,o.name);if(o.isDirectory())i+=await $L(a);else if(o.isFile()){const t=await Qa(a);i+=t.size}}}catch{}return i},po=async e=>{const i=[];let n;try{n=await js(e)}catch{return[]}for(const o of n){if(o.startsWith("."))continue;const a=L(e,o);try{const t=await Qa(a);if(!t.isDirectory())continue;const s=await $L(a);i.push({hash:o,mtimeMs:t.mtimeMs,path:a,sizeBytes:s})}catch{}}return i.sort((o,a)=>a.mtimeMs-o.mtimeMs),i},ZL=(e,i=Date.now())=>{const n=Math.max(0,Math.floor((i-e)/1e3));return n<60?`${String(n)}s`:n<3600?`${String(Math.floor(n/60))}m`:n<86400?`${String(Math.floor(n/3600))}h`:`${String(Math.floor(n/86400))}d`},Uye=e=>new Promise(i=>{const n=Kf({input:process.stdin,output:process.stderr});n.question(`${e} (y/N) `,o=>{n.close();const a=o.trim().toLowerCase();i(a==="y"||a==="yes")})}),JL=async(e,i,n)=>{if(!Z(e)){if(i==="json"){process.stdout.write(`${JSON.stringify({directory:e,entries:[],totalBytes:0,totalCount:0},void 0,2)}
138
138
  `);return}x.info(`No cache directory found at ${e}`);return}const o=await po(e);if(o.length===0){if(i==="json"){process.stdout.write(`${JSON.stringify({directory:e,entries:[],totalBytes:0,totalCount:0},void 0,2)}
139
139
  `);return}x.info(`Cache directory is empty: ${e}`);return}const a=o.reduce((l,g)=>l+g.sizeBytes,0);if(i==="json"){const l=Date.now();process.stdout.write(`${JSON.stringify({directory:e,entries:o.map(g=>({ageMs:l-g.mtimeMs,hash:g.hash,mtimeIso:new Date(g.mtimeMs).toISOString(),sizeBytes:g.sizeBytes})),totalBytes:a,totalCount:o.length},void 0,2)}
140
140
  `);return}x.info(`Cache directory: ${e}`),x.info(`Entries: ${String(o.length)} (${Pa(a,{decimals:1,space:!1})})`),n.info("");const t=Date.now(),s=o.map(l=>({age:ZL(l.mtimeMs,t),hash:l.hash.slice(0,12),size:Pa(l.sizeBytes,{decimals:1,space:!1})})),r=Math.max(4,...s.map(l=>l.hash.length)),u=Math.max(4,...s.map(l=>l.size.length)),d=Math.max(3,...s.map(l=>l.age.length));n.info(` ${"hash".padEnd(r)} ${"size".padEnd(u)} ${"age".padEnd(d)}`),n.info(` ${"-".repeat(r)} ${"-".repeat(u)} ${"-".repeat(d)}`);for(const l of s)n.info(` ${l.hash.padEnd(r)} ${l.size.padEnd(u)} ${l.age.padEnd(d)}`)},xL=()=>{try{const e=Xx();e>0&&x.info(`Cleared ${String(e)} cached AI response${e===1?"":"s"}.`)}catch(e){x.warn(`Failed to clear AI response cache: ${e instanceof Error?e.message:String(e)}`)}},TL=()=>{try{const e=fY();e>0&&x.info(`Cleared ${String(e)} cached Socket.dev report${e===1?"":"s"}.`)}catch(e){x.warn(`Failed to clear Socket.dev cache: ${e instanceof Error?e.message:String(e)}`)}},DL=()=>{try{const e=ZY();e>0&&x.info(`Cleared ${String(e)} cached deps.dev record${e===1?"":"s"}.`)}catch(e){x.warn(`Failed to clear deps.dev cache: ${e instanceof Error?e.message:String(e)}`)}},BL=()=>{try{const e=JY();e>0&&x.info(`Cleared ${String(e)} cached Snyk record${e===1?"":"s"}.`)}catch(e){x.warn(`Failed to clear Snyk cache: ${e instanceof Error?e.message:String(e)}`)}},XL=async(e,i,n)=>{if(!Z(e)){x.info(`No cache directory to clean at ${e}`);return}if(n.dryRun){const a=await po(e),t=a.reduce((s,r)=>s+r.sizeBytes,0);x.info(`Would remove ${String(a.length)} cache entr${a.length===1?"y":"ies"} (${Pa(t,{decimals:1,space:!1})}) from ${e}`);return}const o=OZ(e,i);try{const a=await fp(e),t=await fp(i);if(a===t){x.error("Refusing to delete the workspace root. The cache directory resolved to the same path as the workspace."),process.exitCode=1;return}}catch{}if(!o&&!n.force){if(x.warn(`Cache directory is outside the workspace root: ${e}`),x.warn("This will recursively delete the entire directory, including anything stored there by other tools."),!process.stdin.isTTY){x.error("Refusing to clean an out-of-workspace cache without --force (stdin is not a TTY)."),process.exitCode=1;return}if(!await Uye(" Continue?")){x.info("Aborted.");return}}o?await new Yr({cacheDirectory:e,workspaceRoot:i}).clear():await Ig(e,{force:!0,recursive:!0}),x.success(`Cleared cache: ${e}`)},HL=async(e,i,n)=>{if(!Z(e)){x.info(`No cache directory to prune at ${e}`);return}if(n.maxCacheAgeDays!==void 0&&(!Number.isFinite(n.maxCacheAgeDays)||n.maxCacheAgeDays<0)){x.error(`Invalid --max-age-days value: expected a finite number >= 0, got ${String(n.maxCacheAgeDays)}`),process.exitCode=1;return}if(n.keepLast!==void 0&&(!Number.isFinite(n.keepLast)||n.keepLast<0||!Number.isInteger(n.keepLast))){x.error(`Invalid --keep-last value: expected a non-negative integer, got ${String(n.keepLast)}`),process.exitCode=1;return}if(n.maxCacheSize!==void 0){let l;try{l=vY(n.maxCacheSize)}catch(g){x.error(`Invalid --max-size value: ${g instanceof Error?g.message:String(g)}`),process.exitCode=1;return}if(!Number.isFinite(l)||l<=0){x.error(`Invalid --max-size value: expected a positive size, got "${n.maxCacheSize}" (${String(l)} bytes)`),process.exitCode=1;return}}const o=n.maxCacheAgeDays===void 0?void 0:n.maxCacheAgeDays*24*60*60*1e3,a=await po(e),t=a.reduce((l,g)=>l+g.sizeBytes,0);if(n.keepLast!==void 0&&a.length>n.keepLast){const l=a.slice(n.keepLast);await Promise.all(l.map(g=>Ig(g.path,{force:!0,recursive:!0})))}await new Yr({cacheDirectory:e,maxCacheAge:o,maxCacheSize:n.maxCacheSize,workspaceRoot:i}).removeOldEntries();const s=await po(e),r=s.reduce((l,g)=>l+g.sizeBytes,0),u=a.length-s.length,d=t-r;if(u<=0){x.info("Nothing to prune — all entries are within the configured limits.");return}x.success(`Pruned ${String(u)} entr${u===1?"y":"ies"}, freed ${Pa(d,{decimals:1,space:!1})}.`)},hf=16,ML=e=>e.length>hf?`${e.slice(0,hf)}…`:e,wl=(e,i,n)=>{const o=Object.entries(i??{});if(o.length!==0){n.info(` ${e}:`),o.sort(([a],[t])=>a.localeCompare(t));for(const[a,t]of o)n.info(` ${a.padEnd(40)} ${ML(t)}`)}},PL=async(e,i,n)=>{const{format:o,runId:a,workspaceRoot:t}=i,s=a===void 0?await Uf(t,{dataDirectory:_t(t)}):await YL(t,a);if(!s){if(o==="json"){process.stdout.write(`${JSON.stringify({error:"no-summary",runId:a??null,taskId:e},void 0,2)}
@@ -151,7 +151,7 @@ ${_d(f,{...this.#a,filterStacktrace:ml,hideErrorCauseCodeView:!0,hideErrorCodeVi
151
151
  `):x.error(`Cache restore failed for ${e} (hash ${r.hash}).`),process.exitCode=1;return}const d=await Vye(u);if(d.length===0){a==="json"?process.stdout.write(`${JSON.stringify({diffs:[],hash:r.hash,status:"no-outputs",taskId:e},void 0,2)}
152
152
  `):x.info(`Cached entry for ${e} has no recorded outputs — nothing to verify.`);return}const l=Array.from({length:d.length});for(let h=0;h<d.length;h+=cf){const c=d.slice(h,h+cf),p=await Promise.all(c.map(async f=>i0e(f,t)));for(const[f,w]of p.entries())l[h+f]=w}const g=l.filter(h=>h!==void 0);if(a==="json"){process.stdout.write(`${JSON.stringify({cachedFileCount:d.length,cacheDirectory:s,diffs:g,hash:r.hash,status:g.length===0?"ok":"drift",taskId:e},void 0,2)}
153
153
  `),g.length>0&&(process.exitCode=1);return}if(x.info(`Verify ${e} (hash ${r.hash})`),n.info(""),n.info(` cache: ${s}`),n.info(` files: ${String(d.length)}`),g.length===0){n.info(""),x.success("Cache restore is faithful — all files match content, mode, and mtime.");return}n.info(` drift: ${String(g.length)} file(s)`),n.info("");for(const h of g){const c=h.issues.includes("missing")?"MISSING":h.issues.join(",").toUpperCase();n.info(` [${c}] ${h.relativePath}`),!h.issues.includes("missing")&&h.expected&&h.actual&&(h.issues.includes("content")&&(n.info(` expected hash: ${h.expected.hash||"(none)"}`),n.info(` actual hash: ${h.actual.hash??"(unreadable)"}`)),h.issues.includes("mode")&&(n.info(` expected mode: ${h.expected.mode.toString(8)}`),n.info(` actual mode: ${(h.actual.mode??0).toString(8)}`)),h.issues.includes("mtime")&&(n.info(` expected mtime: ${new Date(h.expected.mtimeMs).toISOString()}`),n.info(` actual mtime: ${h.actual.mtimeMs===void 0?"(unreadable)":new Date(h.actual.mtimeMs).toISOString()}`)))}process.exitCode=1}finally{await Ig(u,{force:!0,recursive:!0}).catch(()=>{})}},OL=e=>e==="task"||e==="ai"||e==="socket"||e==="deps-dev"||e==="snyk"||e==="all"?e:(e&&e.length>0&&x.warn(`Unknown --type value '${e}'; falling back to 'all'.`),"all"),ti=(e,i)=>e==="all"||e===i,cn=e=>e===void 0?null:new Date(e).toISOString(),or=(e,i)=>{x.info(`${e}:`),x.info(` Entries: ${String(i.entries)}`),x.info(` Total size: ${Pa(i.totalSizeBytes,{decimals:1,space:!1})}`),x.info(` Oldest: ${i.oldestEntry?new Date(i.oldestEntry).toISOString():"N/A"}`),x.info(` Newest: ${i.newestEntry?new Date(i.newestEntry).toISOString():"N/A"}`)},n0e=e=>e==="worktree"||e==="shared"||e==="all"?e:(e&&e.length>0&&x.warn(`Unknown --scope value '${e}'; falling back to 'shared'.`),"shared"),Fa=(e,i,n)=>{const o=e??process.cwd(),a=n??{},t=a.taskRunner??{},s=n0e(i.scope),r=i.cacheDir,u=Kp(o,r,t.cacheDirectory,!1),d=Kp(o,r,t.cacheDirectory,a.sharedWorktreeCache);let l,g;switch(s){case"all":{l=d,g=d===u?[d]:[d,u];break}case"worktree":{l=u,g=[u];break}default:l=d,g=[d]}return{cacheDirectories:g,cacheDirectory:l,scope:s,sharedWorktreeCache:a.sharedWorktreeCache,workspaceRoot:o}},o0e=async({logger:e,options:i,visConfig:n,workspaceRoot:o})=>{const{cacheDirectories:a}=Fa(o,i,n),t=i.format??"table";for(const s of a)a.length>1&&x.info(`# ${s}`),await JL(s,t,e)},a0e=async({options:e,visConfig:i,workspaceRoot:n})=>{const o=OL(e.type),a=!!e.dryRun;if(ti(o,"task")){const{cacheDirectory:t,workspaceRoot:s}=Fa(n,e,i);await XL(t,s,{dryRun:a,force:!!e.force})}if(ti(o,"ai"))if(a){const t=Il();x.info(`Would clear ${String(t.entries)} cached AI response${t.entries===1?"":"s"}.`)}else xL();if(ti(o,"socket"))if(a){const t=Bl();x.info(`Would clear ${String(t.entries)} cached Socket.dev report${t.entries===1?"":"s"}.`)}else TL();if(ti(o,"deps-dev"))if(a){const t=Xl();x.info(`Would clear ${String(t.entries)} cached deps.dev record${t.entries===1?"":"s"}.`)}else DL();if(ti(o,"snyk"))if(a){const t=Hl();x.info(`Would clear ${String(t.entries)} cached Snyk record${t.entries===1?"":"s"}.`)}else BL()},t0e=async({options:e,visConfig:i,workspaceRoot:n})=>{const{cacheDirectories:o,workspaceRoot:a}=Fa(n,e,i);for(const t of o)o.length>1&&x.info(`# ${t}`),await HL(t,a,{keepLast:typeof e.keepLast=="number"?e.keepLast:void 0,maxCacheAgeDays:typeof e.maxAgeDays=="number"?e.maxAgeDays:void 0,maxCacheSize:e.maxSize})},AL=e=>e??process.cwd(),s0e=async({argument:e,logger:i,options:n,workspaceRoot:o})=>{const a=e[0];if(!a){x.error("No task ID specified. Usage: vis cache why <project>:<target>"),process.exitCode=1;return}await PL(a,{format:n.format??"table",runId:n.run,workspaceRoot:AL(o)},i)},r0e=async({argument:e,logger:i,options:n,workspaceRoot:o})=>{const a=e[0];if(!a){x.error("No task ID specified. Usage: vis cache hash <project>:<target>"),process.exitCode=1;return}await NL(a,{format:n.format??"table",runId:n.run,workspaceRoot:AL(o)},i)},u0e=async({options:e,visConfig:i,workspaceRoot:n})=>{const o=OL(e.type);if((e.format??"table")==="json"){const a={};if(ti(o,"task")){const{cacheDirectories:t}=Fa(n,e,i);a.task=await Promise.all(t.map(async s=>{const r=Z(s),u=r?await po(s):[],d=u.reduce((l,g)=>l+g.sizeBytes,0);return{directory:s,entries:u.length,exists:r,newestEntry:cn(u[0]?.mtimeMs),oldestEntry:cn(u.at(-1)?.mtimeMs),totalBytes:d}}))}if(ti(o,"ai")){const t=Il();a.ai={entries:t.entries,newestEntry:cn(t.newestEntry),oldestEntry:cn(t.oldestEntry),totalBytes:t.totalSizeBytes}}if(ti(o,"socket")){const t=Bl();a.socket={entries:t.entries,newestEntry:cn(t.newestEntry),oldestEntry:cn(t.oldestEntry),totalBytes:t.totalSizeBytes}}if(ti(o,"deps-dev")){const t=Xl();a["deps-dev"]={entries:t.entries,newestEntry:cn(t.newestEntry),oldestEntry:cn(t.oldestEntry),totalBytes:t.totalSizeBytes}}if(ti(o,"snyk")){const t=Hl();a.snyk={entries:t.entries,newestEntry:cn(t.newestEntry),oldestEntry:cn(t.oldestEntry),totalBytes:t.totalSizeBytes}}process.stdout.write(`${JSON.stringify(a,void 0,2)}
154
- `);return}if(ti(o,"task")){const{cacheDirectories:a}=Fa(n,e,i);for(const t of a)a.length>1&&x.info(`# ${t}`),await EL(t,"table")}ti(o,"ai")&&or("AI response cache",Il()),ti(o,"socket")&&or("Socket.dev report cache",Bl()),ti(o,"deps-dev")&&or("deps.dev cache",Xl()),ti(o,"snyk")&&or("Snyk issue cache",Hl())},d0e=async({argument:e,logger:i,options:n,visConfig:o,workspaceRoot:a})=>{const t=e[0];if(!t){x.error("No task ID specified. Usage: vis cache verify <project>:<target>"),process.exitCode=1;return}const{cacheDirectories:s,workspaceRoot:r}=Fa(a,n,o);await RL(t,{cacheDirectories:s,format:n.format??"table",workspaceRoot:r},i)},ua=Object.defineProperty({__proto__:null,cacheCleanExecute:a0e,cacheHashExecute:r0e,cacheListExecute:o0e,cachePruneExecute:t0e,cacheSizeExecute:u0e,cacheVerifyExecute:d0e,cacheWhyExecute:s0e,clearAiCacheSafe:xL,clearDepsDevCacheSafe:DL,clearSnykCacheSafe:BL,clearSocketCacheSafe:TL,collectCacheEntries:po,formatAge:ZL,runClean:XL,runHash:NL,runList:JL,runPrune:HL,runSize:EL,runVerify:RL,runWhy:PL},Symbol.toStringTag,{value:"Module"}),sSe=(e,i)=>{let n=0,o=0,a=0;for(const[,r]of e)switch(r.status){case"failure":{a+=1;break}case"local-cache":case"local-cache-kept-existing":case"remote-cache":{o+=1;break}case"success":{n+=1;break}}const t=[];n>0&&t.push(`${String(n)} succeeded`),o>0&&t.push(`${String(o)} cached`),a>0&&t.push(`${String(a)} failed`);const s=(i/1e3).toFixed(1);return t.push(`${s}s`),t.join(" · ")},ns=e=>{const i=fo(e);if(Z(i)){const o=Fi(i).filter(t=>t.endsWith(".json")),a=[];for(const t of o)try{a.push(Qe(L(i,t)))}catch{}if(a.length>0)return a}const n=im(e);if(Z(n))try{return[Qe(n)]}catch{}return[]},rSe=(e,i,n)=>{const o=n??ns(e);if(o.length<2)return;let a=0,t=0;for(const u of o)typeof u.duration=="number"&&u.duration>0&&(a+=u.duration,t+=1);if(t<2)return;const s=a/t-i,r=Math.abs(s/1e3).toFixed(1);return Math.abs(s)<500?"(about average)":s>0?`(${r}s faster than avg)`:`(${r}s slower than avg)`},l0e=(e,i={},n)=>{const o=n??ns(e);if(o.length===0)return[];const a=new Map;for(const r of o)if(!(i.since&&(r.startTime===void 0||r.startTime<i.since))&&Array.isArray(r.tasks))for(const u of r.tasks){if(u.cacheStatus==="HIT"||u.cacheStatus==="REMOTE_HIT"||u.cacheStatus==="SKIPPED")continue;const d=a.get(u.taskId)??{failures:0,project:u.target.project,retriedSuccesses:0,successes:0,target:u.target.target,totalRuns:0};d.totalRuns+=1,u.exitCode!==void 0&&u.exitCode!==0?(d.failures+=1,d.lastFailure=u.startTime??r.startTime):(u.retryAttempts&&u.retryAttempts>0&&(d.retriedSuccesses+=1,d.lastRetry=u.startTime??r.startTime),d.successes+=1),a.set(u.taskId,d)}const t=i.minRuns??2,s=[];for(const[r,u]of a){if(u.totalRuns<t||u.failures===0&&u.retriedSuccesses===0)continue;const d=(u.failures+.5*u.retriedSuccesses)/u.totalRuns;s.push({failures:u.failures,flakinessRate:d,lastFailure:u.lastFailure,lastRetry:u.lastRetry,project:u.project,retriedSuccesses:u.retriedSuccesses,successes:u.successes,target:u.target,taskId:r,totalRuns:u.totalRuns})}return s.sort((r,u)=>u.flakinessRate-r.flakinessRate),s},uSe=e=>{if(e.length===0)return["No flaky tasks detected."];const i=["Task","Runs","Failures","Retried","Rate","Last Failure"],n=e.map(r=>[r.taskId,String(r.totalRuns),String(r.failures),String(r.retriedSuccesses),`${(r.flakinessRate*100).toFixed(1)}%`,r.lastFailure??r.lastRetry??"—"]),o=i.map((r,u)=>{let d=0;for(const l of n)d=Math.max(d,(l[u]??"").length);return Math.max(r.length,d)}),a=(r,u)=>r.padEnd(u),t=o.map(r=>"─".repeat(r)).join("──"),s=[i.map((r,u)=>a(r,o[u])).join(" "),t];for(const r of n)s.push(r.map((u,d)=>a(u,o[d])).join(" "));return s},jl=(e,i,n)=>{const o=[],a=i??{},t=n??{},s=new Set([...Object.keys(a),...Object.keys(t)]);for(const r of s){const u=a[r],d=t[r];u!==d&&(u===void 0?o.push({change:"added",current:d,key:r,kind:e,previous:void 0}):d===void 0?o.push({change:"removed",current:void 0,key:r,kind:e,previous:u}):o.push({change:"modified",current:d,key:r,kind:e,previous:u}))}return o.sort((r,u)=>r.key.localeCompare(u.key)),o},g0e=e=>{if(e.length===0)return"No input changes detected. The cache may have been evicted or was never stored.";if(e.some(a=>a.kind==="command"))return"The resolved command changed.";const i=new Map;for(const a of e)i.set(a.kind,(i.get(a.kind)??0)+1);const[n]=[...i.entries()].sort((a,t)=>t[1]-a[1])[0]??["nodes",0],o={command:"command",implicitDeps:"lockfile or dependency",nodes:"input file",runtime:"runtime value"};return`${String(e.length)} ${o[n]??n} change(s) detected.`},h0e=(e,i,n)=>{const o=e.find(t=>t.id===n)?.startTime,a=[...e].sort((t,s)=>(s.startTime??"").localeCompare(t.startTime??"")).filter(t=>!(t.id!==void 0&&t.id===n||o!==void 0&&t.startTime!==void 0&&t.startTime>o));for(const t of a){const s=t.tasks?.find(r=>r.taskId===i);if(s&&(s.cacheStatus==="HIT"||s.cacheStatus==="REMOTE_HIT"))return{run:t,task:s}}for(const t of a){const s=t.tasks?.find(r=>r.taskId===i);if(s?.hashDetails)return{run:t,task:s}}},c0e=(e,i,n)=>{const o=e,a=n.taskId??"",t=h0e(o,a,i);if(!t)return{currentHash:n.hash,entries:[],previousHash:void 0,previousRunId:void 0,previousRunStartTime:void 0,reason:"No previous run recorded this task — first observation.",taskId:a};const s=[],r=t.task.hashDetails?.command,u=n.hashDetails?.command;return r!==u&&s.push({change:r===void 0?"added":u===void 0?"removed":"modified",current:u,key:"command",kind:"command",previous:r}),s.push(...jl("nodes",t.task.hashDetails?.nodes,n.hashDetails?.nodes)),s.push(...jl("implicitDeps",t.task.hashDetails?.implicitDeps,n.hashDetails?.implicitDeps)),s.push(...jl("runtime",t.task.hashDetails?.runtime,n.hashDetails?.runtime)),{currentHash:n.hash,entries:s,previousHash:t.task.hash,previousRunId:t.run.id,previousRunStartTime:t.run.startTime,reason:g0e(s),taskId:a}},pf=If(lY(import.meta.url)),p0e=[Cr(pf,"..","..","dashboard","dist","index.html"),Cr(pf,"..","dashboard","dist","index.html")],vf=`<!DOCTYPE html>
154
+ `);return}if(ti(o,"task")){const{cacheDirectories:a}=Fa(n,e,i);for(const t of a)a.length>1&&x.info(`# ${t}`),await EL(t,"table")}ti(o,"ai")&&or("AI response cache",Il()),ti(o,"socket")&&or("Socket.dev report cache",Bl()),ti(o,"deps-dev")&&or("deps.dev cache",Xl()),ti(o,"snyk")&&or("Snyk issue cache",Hl())},d0e=async({argument:e,logger:i,options:n,visConfig:o,workspaceRoot:a})=>{const t=e[0];if(!t){x.error("No task ID specified. Usage: vis cache verify <project>:<target>"),process.exitCode=1;return}const{cacheDirectories:s,workspaceRoot:r}=Fa(a,n,o);await RL(t,{cacheDirectories:s,format:n.format??"table",workspaceRoot:r},i)},ua=Object.defineProperty({__proto__:null,cacheCleanExecute:a0e,cacheHashExecute:r0e,cacheListExecute:o0e,cachePruneExecute:t0e,cacheSizeExecute:u0e,cacheVerifyExecute:d0e,cacheWhyExecute:s0e,clearAiCacheSafe:xL,clearDepsDevCacheSafe:DL,clearSnykCacheSafe:BL,clearSocketCacheSafe:TL,collectCacheEntries:po,formatAge:ZL,runClean:XL,runHash:NL,runList:JL,runPrune:HL,runSize:EL,runVerify:RL,runWhy:PL},Symbol.toStringTag,{value:"Module"}),r1e=(e,i)=>{let n=0,o=0,a=0;for(const[,r]of e)switch(r.status){case"failure":{a+=1;break}case"local-cache":case"local-cache-kept-existing":case"remote-cache":{o+=1;break}case"success":{n+=1;break}}const t=[];n>0&&t.push(`${String(n)} succeeded`),o>0&&t.push(`${String(o)} cached`),a>0&&t.push(`${String(a)} failed`);const s=(i/1e3).toFixed(1);return t.push(`${s}s`),t.join(" · ")},ns=e=>{const i=fo(e);if(Z(i)){const o=Fi(i).filter(t=>t.endsWith(".json")),a=[];for(const t of o)try{a.push(Qe(L(i,t)))}catch{}if(a.length>0)return a}const n=im(e);if(Z(n))try{return[Qe(n)]}catch{}return[]},u1e=(e,i,n)=>{const o=n??ns(e);if(o.length<2)return;let a=0,t=0;for(const u of o)typeof u.duration=="number"&&u.duration>0&&(a+=u.duration,t+=1);if(t<2)return;const s=a/t-i,r=Math.abs(s/1e3).toFixed(1);return Math.abs(s)<500?"(about average)":s>0?`(${r}s faster than avg)`:`(${r}s slower than avg)`},l0e=(e,i={},n)=>{const o=n??ns(e);if(o.length===0)return[];const a=new Map;for(const r of o)if(!(i.since&&(r.startTime===void 0||r.startTime<i.since))&&Array.isArray(r.tasks))for(const u of r.tasks){if(u.cacheStatus==="HIT"||u.cacheStatus==="REMOTE_HIT"||u.cacheStatus==="SKIPPED")continue;const d=a.get(u.taskId)??{failures:0,project:u.target.project,retriedSuccesses:0,successes:0,target:u.target.target,totalRuns:0};d.totalRuns+=1,u.exitCode!==void 0&&u.exitCode!==0?(d.failures+=1,d.lastFailure=u.startTime??r.startTime):(u.retryAttempts&&u.retryAttempts>0&&(d.retriedSuccesses+=1,d.lastRetry=u.startTime??r.startTime),d.successes+=1),a.set(u.taskId,d)}const t=i.minRuns??2,s=[];for(const[r,u]of a){if(u.totalRuns<t||u.failures===0&&u.retriedSuccesses===0)continue;const d=(u.failures+.5*u.retriedSuccesses)/u.totalRuns;s.push({failures:u.failures,flakinessRate:d,lastFailure:u.lastFailure,lastRetry:u.lastRetry,project:u.project,retriedSuccesses:u.retriedSuccesses,successes:u.successes,target:u.target,taskId:r,totalRuns:u.totalRuns})}return s.sort((r,u)=>u.flakinessRate-r.flakinessRate),s},d1e=e=>{if(e.length===0)return["No flaky tasks detected."];const i=["Task","Runs","Failures","Retried","Rate","Last Failure"],n=e.map(r=>[r.taskId,String(r.totalRuns),String(r.failures),String(r.retriedSuccesses),`${(r.flakinessRate*100).toFixed(1)}%`,r.lastFailure??r.lastRetry??"—"]),o=i.map((r,u)=>{let d=0;for(const l of n)d=Math.max(d,(l[u]??"").length);return Math.max(r.length,d)}),a=(r,u)=>r.padEnd(u),t=o.map(r=>"─".repeat(r)).join("──"),s=[i.map((r,u)=>a(r,o[u])).join(" "),t];for(const r of n)s.push(r.map((u,d)=>a(u,o[d])).join(" "));return s},jl=(e,i,n)=>{const o=[],a=i??{},t=n??{},s=new Set([...Object.keys(a),...Object.keys(t)]);for(const r of s){const u=a[r],d=t[r];u!==d&&(u===void 0?o.push({change:"added",current:d,key:r,kind:e,previous:void 0}):d===void 0?o.push({change:"removed",current:void 0,key:r,kind:e,previous:u}):o.push({change:"modified",current:d,key:r,kind:e,previous:u}))}return o.sort((r,u)=>r.key.localeCompare(u.key)),o},g0e=e=>{if(e.length===0)return"No input changes detected. The cache may have been evicted or was never stored.";if(e.some(a=>a.kind==="command"))return"The resolved command changed.";const i=new Map;for(const a of e)i.set(a.kind,(i.get(a.kind)??0)+1);const[n]=[...i.entries()].sort((a,t)=>t[1]-a[1])[0]??["nodes",0],o={command:"command",implicitDeps:"lockfile or dependency",nodes:"input file",runtime:"runtime value"};return`${String(e.length)} ${o[n]??n} change(s) detected.`},h0e=(e,i,n)=>{const o=e.find(t=>t.id===n)?.startTime,a=[...e].sort((t,s)=>(s.startTime??"").localeCompare(t.startTime??"")).filter(t=>!(t.id!==void 0&&t.id===n||o!==void 0&&t.startTime!==void 0&&t.startTime>o));for(const t of a){const s=t.tasks?.find(r=>r.taskId===i);if(s&&(s.cacheStatus==="HIT"||s.cacheStatus==="REMOTE_HIT"))return{run:t,task:s}}for(const t of a){const s=t.tasks?.find(r=>r.taskId===i);if(s?.hashDetails)return{run:t,task:s}}},c0e=(e,i,n)=>{const o=e,a=n.taskId??"",t=h0e(o,a,i);if(!t)return{currentHash:n.hash,entries:[],previousHash:void 0,previousRunId:void 0,previousRunStartTime:void 0,reason:"No previous run recorded this task — first observation.",taskId:a};const s=[],r=t.task.hashDetails?.command,u=n.hashDetails?.command;return r!==u&&s.push({change:r===void 0?"added":u===void 0?"removed":"modified",current:u,key:"command",kind:"command",previous:r}),s.push(...jl("nodes",t.task.hashDetails?.nodes,n.hashDetails?.nodes)),s.push(...jl("implicitDeps",t.task.hashDetails?.implicitDeps,n.hashDetails?.implicitDeps)),s.push(...jl("runtime",t.task.hashDetails?.runtime,n.hashDetails?.runtime)),{currentHash:n.hash,entries:s,previousHash:t.task.hash,previousRunId:t.run.id,previousRunStartTime:t.run.startTime,reason:g0e(s),taskId:a}},pf=If(lY(import.meta.url)),p0e=[Cr(pf,"..","..","dashboard","dist","index.html"),Cr(pf,"..","dashboard","dist","index.html")],vf=`<!DOCTYPE html>
155
155
  <html lang="en">
156
156
  <head>
157
157
  <meta charset="UTF-8" />
@@ -169,8 +169,8 @@ ${_d(f,{...this.#a,filterStacktrace:ml,hideErrorCauseCodeView:!0,hideErrorCodeVi
169
169
  <p>Or run the full vis build:</p>
170
170
  <pre><code>pnpm --filter @visulima/vis run build</code></pre>
171
171
  </body>
172
- </html>`;let To;const v0e=()=>{for(const e of p0e)try{if(Eo(e).isFile())return e}catch{}},y0e=()=>{if(To!==void 0&&!process.env.VIS_DASHBOARD_NO_CACHE)return To;const e=v0e();if(!e)return To=vf,To;try{const i=nY(e,"utf8");return To=i,i}catch{return To=vf,To}},f0e=e=>{if(e.length===0)return;const i=[...e].sort((o,a)=>o-a),n=Math.floor(i.length/2);return i.length%2===0?(i[n-1]+i[n])/2:i[n]},m0e=e=>{const i=new Map;for(const o of e)if(Array.isArray(o.tasks))for(const a of o.tasks){if(!a.taskId)continue;const t=i.get(a.taskId)??{durations:[],failures:0,hits:0,misses:0,project:a.target?.project??"",runs:0,target:a.target?.target??"",taskId:a.taskId};a.cacheStatus==="HIT"||a.cacheStatus==="REMOTE_HIT"?(t.runs+=1,t.hits+=1):a.cacheStatus==="MISS"&&(t.runs+=1,t.misses+=1,typeof a.duration=="number"&&a.duration>0&&t.durations.push(a.duration),a.exitCode!==void 0&&a.exitCode!==0&&(t.failures+=1)),i.set(a.taskId,t)}const n=new Map;for(const[o,a]of i){const t=a.durations.length===0?0:a.durations.reduce((s,r)=>s+r,0)/a.durations.length;n.set(o,{averageDurationMs:t,failures:a.failures,hitRate:a.runs===0?0:a.hits/a.runs,hits:a.hits,misses:a.misses,project:a.project,runs:a.runs,target:a.target,taskId:o,timeSavedMs:t*a.hits})}return n},b0e=e=>{const i=e,n=[...i].sort((v,j)=>(v.startTime??"").localeCompare(j.startTime??""));let o=0,a=0,t=0,s=0,r=0,u=0;const d=[],l=[],g=[];for(const v of n){const j=v.stats??{};o+=j.total??0,a+=j.succeeded??0,t+=j.failed??0,s+=j.cached??0,r+=j.skipped??0,typeof v.duration=="number"&&v.duration>0&&(u+=v.duration,d.push(v.duration),v.startTime&&g.push({timestamp:v.startTime,value:v.duration})),(j.total??0)>0&&v.startTime&&l.push({timestamp:v.startTime,value:(j.cached??0)/(j.total??1)})}const h=[...m0e(n).values()],c=h.filter(v=>v.averageDurationMs>0).sort((v,j)=>j.averageDurationMs-v.averageDurationMs).slice(0,10),p=h.filter(v=>v.runs>=2).sort((v,j)=>j.timeSavedMs-v.timeSavedMs||j.hitRate-v.hitRate).slice(0,10),f=h.filter(v=>v.runs>=3&&v.hits>0&&v.misses>0).sort((v,j)=>j.misses/j.runs-v.misses/v.runs).slice(0,10),w=h.reduce((v,j)=>v+j.timeSavedMs,0);return{averageRunDurationMs:d.length===0?null:d.reduce((v,j)=>v+j,0)/d.length,cacheHitRate:s+a+t===0?null:s/(s+a+t),durationOverTime:g,hitRateOverTime:l,medianRunDurationMs:f0e(d)??null,mostCachedTasks:p,mostInvalidatedTasks:f,slowestTasks:c,totals:{cached:s,estimatedTimeSavedMs:w,failed:t,runs:i.length,skipped:r,succeeded:a,tasks:o,totalDurationMs:u}}},yf=(e,i)=>{const n=i.replaceAll(/[^\w.\-:]/g,"");if(n.length===0||n!==i)return;const o=L(fo(e),`${n}.json`);if(Z(o))try{return Qe(o)}catch{return}const a=im(e);if(Z(a))try{const t=Qe(a);return t.id===n?t:void 0}catch{return}},w0e=async e=>{const i=new Set,n=fo(e);try{await iY(n,{recursive:!0})}catch{}let o,a;const t=r=>{a=r,o&&clearTimeout(o),o=setTimeout(()=>{if(o=void 0,!a)return;const u=a;a=void 0;for(const d of i)try{d(u)}catch{}},200)};let s;try{s=oY(n,(r,u)=>{if(!u||typeof u!="string"||!u.endsWith(".json"))return;const d=u.slice(0,-5);t({id:d,type:"run-changed"})})}catch{s=void 0}return{close:()=>{o&&clearTimeout(o),s?.close(),i.clear()},subscribe:r=>(i.add(r),()=>{i.delete(r)})}},j0e=(e,i)=>{const n=new tx;return n.get("/",o=>o.html(y0e())),n.get("/api/overview",o=>{const a=ns(e.workspaceRoot),t=b0e(a),s=l0e(e.workspaceRoot,{minRuns:2},a);return o.json({flaky:s,metrics:t})}),n.get("/api/runs",o=>{const a=ns(e.workspaceRoot).filter(t=>typeof t.id=="string"&&typeof t.startTime=="string"&&typeof t.endTime=="string"&&typeof t.duration=="number").map(t=>{const s=t.stats,r=s?{cached:typeof s.cached=="number"?s.cached:void 0,failed:typeof s.failed=="number"?s.failed:void 0,skipped:typeof s.skipped=="number"?s.skipped:void 0,succeeded:typeof s.succeeded=="number"?s.succeeded:void 0,total:typeof s.total=="number"?s.total:void 0}:void 0;return{duration:t.duration,endTime:t.endTime,id:t.id,startTime:t.startTime,stats:r}}).sort((t,s)=>s.startTime.localeCompare(t.startTime));return o.json({runs:a})}),n.get("/api/runs/:id",o=>{const a=yf(e.workspaceRoot,o.req.param("id"));return a?o.json(a):o.json({error:"Not found"},404)}),n.get("/api/runs/:runId/tasks/:taskId/diff",o=>{const a=yf(e.workspaceRoot,o.req.param("runId"));if(!a)return o.json({error:"Run not found"},404);const t=o.req.param("taskId"),s=a.tasks?.find(d=>d.taskId===t);if(!s)return o.json({error:"Task not found"},404);const r=ns(e.workspaceRoot),u=c0e(r,a.id,s);return o.json(u)}),n.get("/api/cache",async o=>{if(!Z(e.cacheDirectory))return o.json({directory:e.cacheDirectory,entries:[],exists:!1,totalBytes:0});const a=await po(e.cacheDirectory),t=a.reduce((r,u)=>r+u.sizeBytes,0),s=Date.now();return o.json({directory:e.cacheDirectory,entries:a.map(r=>({ageMs:s-r.mtimeMs,hash:r.hash,mtimeIso:new Date(r.mtimeMs).toISOString(),sizeBytes:r.sizeBytes})),exists:!0,totalBytes:t})}),n.get("/api/environment",o=>o.json({arch:process.arch,cacheDirectory:e.cacheDirectory,node:process.version,platform:process.platform,workspaceRoot:e.workspaceRoot})),n.get("/api/events",o=>lx(o,async a=>{const t=[];let s;const r=i(d=>{if(t.push(d),s){const l=s;s=void 0,l()}});a.onAbort(()=>{if(r(),s){const d=s;s=void 0,d()}}),await a.writeSSE({data:JSON.stringify({ok:!0}),event:"ready"});const u=15e3;for(;!a.aborted;){if(t.length===0){const l=a.sleep(u),g=new Promise(h=>{s=h});if(await Promise.race([l,g]),a.aborted)break;if(t.length===0){await a.writeSSE({data:"",event:"heartbeat"});continue}}const d=t.shift();await a.writeSSE({data:JSON.stringify(d),event:"change"})}})),n},k0e=async e=>{const i=await w0e(e.workspaceRoot),n=j0e(e,i.subscribe),o=SJ({fetch:n.fetch,hostname:e.host,port:e.port});await new Promise((r,u)=>{o.once("listening",()=>{r()}),o.once("error",d=>{u(d)})});const a=o.address(),t=typeof a=="object"&&a?a.port:e.port,s=`http://${e.host==="0.0.0.0"||e.host==="::"||e.host==="::0"?"localhost":e.host}:${String(t)}`;return{close:()=>new Promise((r,u)=>{i.close(),o.close(d=>{d?u(d):r()})}),port:t,url:s}},S0e=e=>{const{platform:i}=process,[n,o]=i==="darwin"?["open",[e]]:i==="win32"?["cmd",["/c","start","",e]]:["xdg-open",[e]];uY(n,o,a=>{})},L0e={description:"Open a browser dashboard with cache, run history, and cache-miss diffs",examples:[["vis dashboard","Start the dashboard on a random port (server only — does not open a browser)"],["vis dashboard --open","Start the dashboard and open it in the default browser"],["vis dashboard --port=7788","Pin the server to a specific port"],["vis dashboard --host=0.0.0.0 --port=7788","Expose the dashboard on all interfaces"]],execute:async({options:e,process:i,visConfig:n,workspaceRoot:o})=>{const a=o??i.cwd,t=ib(a,e.cacheDir,n?.taskRunner?.cacheDirectory),s=typeof e.port=="number"&&Number.isFinite(e.port)?e.port:0,r=typeof e.host=="string"&&e.host.length>0?e.host:"127.0.0.1",u=await k0e({cacheDirectory:t,host:r,port:s,workspaceRoot:a});x.success(`Dashboard listening on ${u.url}`),x.info(`Workspace: ${a}`),x.info(`Cache: ${t}`),x.info("Press Ctrl+C to stop."),e.open===!0&&S0e(u.url),await new Promise(d=>{let l=!1;const g=()=>{l||(l=!0,process.off("SIGINT",g),process.off("SIGTERM",g),(async()=>{try{await u.close()}catch{}finally{d()}})())};process.once("SIGINT",g),process.once("SIGTERM",g)})},group:"Workspace",name:"dashboard",options:[{defaultValue:0,description:"Port to bind the dashboard server to (0 = auto-assign)",name:"port",type:Number},{defaultValue:"127.0.0.1",description:"Host interface to bind to. Default binds to localhost only.",name:"host",type:String},{defaultValue:!1,description:"Open the dashboard in the default browser after starting",name:"open",type:Boolean},{description:"Cache directory to inspect (overrides config and default). Relative paths resolve against the workspace root.",name:"cache-dir",type:String}]},C0e={description:"Deduplicate dependencies using the detected package manager",examples:[["vis dedupe","Run deduplication"],["vis dedupe --check","Preview changes without modifying (CI-friendly)"]],group:"Dependencies",loader:()=>import("./handler9.js"),name:"dedupe",options:[{defaultValue:!1,description:"Preview changes without modifying files (dry-run)",name:"check",type:Boolean}]},Y0e={description:"Lint workspace dependency policies (workspace-protocol, banned-deps, redefine-root, workspace-versions, custom-types, empty-deps, root-private, root-package-manager, root-deps, missing-package-json, dead-workspace-patterns, types-in-deps, similar-deps)",examples:[["vis deps","Run every enabled lint and exit non-zero on failures"],["vis deps --workspace-protocol","Only check that internal deps use workspace:*"],["vis deps --workspace-protocol --fix","Auto-rewrite internal deps to use workspace:*"],["vis deps --redefine-root","Flag deps duplicated between root and child packages"],["vis deps --banned-deps","Flag deps matching policy.bannedDeps in vis config"],["vis deps --workspace-versions","Flag external deps declared at different versions across packages"],["vis deps --workspace-versions --fix","Rewrite drifting deps to the highest sibling version"],["vis deps --workspace-versions --dep react","Limit version-drift check to a single dep"],["vis deps --workspace-versions --resolve catalog --fix","Rewrite drifting deps to catalog: when a catalog already pins them"],["vis deps --workspace-versions --resolve catalog --propose-min 3","Suggest new catalog entries for deps ≥3 packages already agree on"],["vis deps --custom-types","Flag drift in engines.{node,pnpm}, packageManager, volta.{node,pnpm,yarn}, devEngines"],["vis deps --custom-types --fix","Align all engines/packageManager/volta versions to the highest sibling"],["vis deps --empty-deps --fix","Drop empty `dependencies` / `devDependencies` / etc. blocks across the workspace"],["vis deps --root-private --fix",'Ensure the workspace root package.json has "private": true'],["vis deps --root-package-manager","Ensure the root package.json declares a `packageManager` field"],["vis deps --root-deps --fix","Move runtime deps off the private workspace root into devDependencies"],["vis deps --missing-package-json","Flag workspace dirs that don't contain a package.json"],["vis deps --dead-workspace-patterns --fix","Drop workspace patterns that match zero packages"],["vis deps --types-in-deps --fix","Move @types/* out of dependencies on private packages"],["vis deps --similar-deps","Flag drift across related dep families (react+react-dom, @babel/*, …)"],["vis deps --ban left-pad --ban request","One-off ban: flag any package declaring left-pad or request"],["vis deps --pin react@18.2.0","One-off pin: flag any package declaring react at a different version"],["vis deps --format json","Emit findings as JSON for CI / editor integrations"]],group:"Security & Health",loader:()=>import("./handler67.js"),name:"deps",options:[{defaultValue:!1,description:"Lint that internal deps use the workspace: protocol",name:"workspace-protocol",type:Boolean},{defaultValue:!1,description:"Lint that no child re-declares a dep already pinned in the workspace root",name:"redefine-root",type:Boolean},{defaultValue:!1,description:"Lint deps against policy.bannedDeps in vis config",name:"banned-deps",type:Boolean},{defaultValue:!1,description:"Lint that all packages declare external deps at the same version",name:"workspace-versions",type:Boolean},{defaultValue:!1,description:"Lint engines.{node,pnpm}, packageManager, volta.*, devEngines.* for drift across packages",name:"custom-types",type:Boolean},{defaultValue:!1,description:"Flag empty dependency blocks (`dependencies: {}`, `devDependencies: {}`, …) across the workspace",name:"empty-deps",type:Boolean},{defaultValue:!1,description:'Ensure the workspace root package.json sets `"private": true`',name:"root-private",type:Boolean},{defaultValue:!1,description:"Ensure the workspace root package.json declares a `packageManager` field",name:"root-package-manager",type:Boolean},{defaultValue:!1,description:"Flag runtime dependencies on the private workspace root (move them to devDependencies)",name:"root-deps",type:Boolean},{defaultValue:!1,description:"Flag workspace directories that lack a package.json",name:"missing-package-json",type:Boolean},{defaultValue:!1,description:"Flag workspace patterns (in `pnpm-workspace.yaml` / `package.json#workspaces`) that match zero packages",name:"dead-workspace-patterns",type:Boolean},{defaultValue:!1,description:"Flag `@types/*` declared in `dependencies` on a private package (should be in devDependencies)",name:"types-in-deps",type:Boolean},{defaultValue:!1,description:"Flag version drift across related dep families (react+react-dom, @babel/*, @storybook/*, …)",name:"similar-deps",type:Boolean},{description:"Restrict --workspace-versions to a single dep",name:"dep",type:String},{description:"Ban a dep name or glob for this run (repeatable). Auto-enables --banned-deps.",multiple:!0,name:"ban",type:String},{description:"Pin a dep to an exact specifier for this run, e.g. react@^18.2.0 (repeatable). Auto-enables --workspace-versions.",multiple:!0,name:"pin",type:String},{description:"Conflict resolution for --workspace-versions: highest, lowest, or catalog (default: highest)",name:"resolve",type:String},{description:"Propose catalog entries for deps ≥N packages already agree on. Activates with --resolve catalog.",name:"propose-min",type:Number},{defaultValue:!1,description:"Auto-fix violations in place (writes package.json files)",name:"fix",type:Boolean},{description:"Specifier used by --fix for workspace-protocol (default: workspace:*)",name:"fix-specifier",type:String},{description:"Output format: human, json, or minimal (default: human)",name:"format",type:String},{defaultValue:!1,description:"Suppress all output except errors",name:"quiet",type:Boolean}]},$0e={alias:"dc",description:"Create or update .devcontainer/devcontainer.json interactively",examples:[["vis devcontainer","Launch interactive devcontainer config editor"],["vis dc","Alias for devcontainer"],["vis devcontainer --template node-pnpm","Start from Node.js + pnpm template"]],group:"Scaffold & Config",loader:()=>import("./handler75.js"),name:"devcontainer",options:[{alias:"t",description:"Start from a template: node, node-pnpm, node-postgres, node-dind, fullstack, python, go, rust, java, devops, minimal, custom",name:"template",type:String},{alias:"o",description:"Output path (default: .devcontainer/devcontainer.json)",name:"output",type:String}]},Vu="Workspace",Z0e={commandPath:["docker"],description:"Build a minimal, cache-friendly Docker context for a focus project + its deps",examples:[["vis docker scaffold --focus=my-app","Generate .vis/docker/workspace for my-app + its deps"],["vis docker scaffold --focus=my-app --include-sources","Also copy focus source trees"],["vis docker scaffold --focus=my-app,other --out=.vis/docker","Focus multiple projects"]],group:Vu,loader:le(()=>import("./handler58.js"),"scaffoldExecute"),name:"scaffold",options:[{description:"Project name(s) to focus on — comma-separated for multiple",name:"focus",type:String},{description:"Output directory for the scaffold (default: .vis/docker)",name:"out",type:String},{defaultValue:!1,description:"Also copy focus project source trees to <out>/sources",name:"include-sources",type:Boolean},{defaultValue:!0,description:"Rewrite the workspace lockfile to drop unfocused projects (use --no-prune-lockfile to copy verbatim)",name:"prune-lockfile",type:Boolean}]},J0e={commandPath:["docker"],description:"Strip unfocused workspace projects from a scaffolded context (run inside a build stage)",examples:[["vis docker prune --context=.vis/docker","Strip unfocused projects inside a build stage"]],group:Vu,loader:le(()=>import("./handler58.js"),"pruneExecute"),name:"prune",options:[{description:"Scaffold root for prune (default: .vis/docker)",name:"context",type:String}]},x0e={argument:{description:"Output path for the Dockerfile (default: ./Dockerfile)",name:"path",type:String},commandPath:["docker"],description:"Generate a multi-stage Dockerfile wired to the scaffold/prune flow (create-only)",examples:[["vis docker init","Generate ./Dockerfile for the detected package manager"],["vis docker init --focus=my-app","Target a specific project's build"],["vis docker init --node=24 --force","Use Node 24 and overwrite without prompting"],["vis docker init --dry-run","Print the Dockerfile instead of writing it"]],group:Vu,loader:le(()=>import("./handler58.js"),"initExecute"),name:"init",options:[{description:"Focus project name for the build filter",name:"focus",type:String},{description:"Node.js version tag for the base image (default: 22)",name:"node",type:String},{defaultValue:!1,description:"Overwrite an existing Dockerfile without prompting",name:"force",type:Boolean},{defaultValue:!1,description:"Print the Dockerfile to stdout instead of writing it",name:"dry-run",type:Boolean}]},T0e={argument:{description:"Dockerfile path(s) to lint (default: ./Dockerfile)",name:"file",type:String},commandPath:["docker"],description:"Lint a Dockerfile with hadolint (downloaded on demand); --fix applies safe autofixes",examples:[["vis docker lint","Lint ./Dockerfile (prompts to download hadolint on first use)"],["vis docker lint apps/web/Dockerfile","Lint a specific Dockerfile"],["vis docker lint --fix","Apply safe autofixes, then report what remains"],["vis docker lint --install --json","Auto-download hadolint and emit JSON"]],group:Vu,loader:le(()=>import("./handler58.js"),"lintExecute"),name:"lint",options:[{defaultValue:!1,description:"Apply safe autofixes, then re-lint and report what remains",name:"fix",type:Boolean},{defaultValue:!1,description:"Download hadolint without prompting if it is missing",name:"install",type:Boolean},{description:"Path to a hadolint config (.hadolint.yaml)",name:"config",type:String},{defaultValue:!1,description:"Emit findings as JSON",name:"json",type:Boolean}]},D0e=[Z0e,J0e,x0e,T0e],B0e={description:"Run a full project health check (outdated, security, duplicates, optimizations)",examples:[["vis doctor","Full project health check"],["vis doctor --fix","Check and auto-apply safe fixes"],["vis doctor --format json","Machine-readable output for CI"],["vis doctor --only security","Only run the security scans"],["vis doctor --skip optimization,runtime","Skip the listed sections"],["vis doctor --quiet","Summary only, no per-section breakdown"],["vis doctor --no-progress","Disable live progress UI (sequential logs)"],["vis doctor --exit-code","Exit with code 1 if security issues found"],["vis doctor --exit-code --strict","Fail on any issue (outdated, duplicates, security)"]],group:"Security & Health",loader:()=>import("./handler69.js"),name:"doctor",options:[{description:"Output format: table or json (default: table). Alias: --json",name:"format",type:String},{defaultValue:!1,description:"Shorthand for --format json",name:"json",type:Boolean},{defaultValue:!1,description:"Exit with code 1 if issues found",name:"exit-code",type:Boolean},{defaultValue:!1,description:"Auto-apply safe fixes (security overrides + codemods, SIGTERM orphans)",name:"fix",type:Boolean},{defaultValue:!1,description:"With --fix: escalate orphan cleanup to SIGKILL / taskkill /F (use when SIGTERM is ignored)",name:"fix-force",type:Boolean},{defaultValue:!1,description:"With --exit-code: also fail on outdated and duplicate deps",name:"strict",type:Boolean},{description:"Comma-separated sections to run: dependencies,security,optimization,runtime",name:"only",type:String},{description:"Comma-separated sections to skip",name:"skip",type:String},{defaultValue:!1,description:"Suppress per-section detail; print summary only",name:"quiet",type:Boolean},{defaultValue:!1,description:"Disable live progress UI (forces sequential logs)",name:"no-progress",type:Boolean},{defaultValue:!1,description:"Bypass the doctor result cache (~/.vis/cache/doctor)",name:"no-cache",type:Boolean},{description:"Comma-separated package name patterns to scope findings (supports * globs, e.g. '@types/*,react')",name:"filter",type:String}]},X0e={description:"Orchestrate detected formatters (prettier, …) across the workspace",examples:[["vis fmt","Apply formatting in place using every detected formatter"],["vis fmt --check","Report files that would change without writing"],["vis fmt --check --format json","Emit findings as JSON for CI / editor integrations"],["vis fmt --check --format sarif","Emit a SARIF 2.1.0 document for code-scanning uploads"],["vis fmt --check --format junit","Emit a JUnit XML report for CI dashboards"],["vis fmt --check --format github","Emit GitHub Actions workflow commands for inline PR annotations"],["vis fmt src/foo.ts src/bar.ts","Format a specific file list"],["vis fmt --quiet","Suppress per-file logs"],["vis fmt --since main","Only format files changed vs the main branch"],["vis fmt --staged","Only format files currently staged in the git index"],["vis fmt --watch","Re-run formatters when watched files change (cache makes incremental --check near-free)"],["vis fmt --check --format sarif --output fmt.sarif","Write the SARIF report to fmt.sarif instead of stdout"]],group:"Lint & Format",loader:()=>import("./handler59.js"),name:"fmt",options:[{defaultValue:!1,description:"Report files that would change without writing",name:"check",type:Boolean},{defaultValue:"human",description:"Output format: human, json, minimal, sarif, junit, or github",name:"format",type:String},{defaultValue:!1,description:"Suppress per-file logs",name:"quiet",type:Boolean},{description:"Only format files changed vs the given git ref (branch, tag, sha)",name:"since",type:String},{defaultValue:!1,description:"Only format files currently staged in the git index",name:"staged",type:Boolean},{description:"Write formatted output to a file path instead of stdout (also accepts `-`/`stdout`/`stderr`)",name:"output",type:String},{defaultValue:!1,description:"Re-run formatters whenever watched files change",name:"watch",type:Boolean}]},H0e={argument:{description:"Template name (or remote source like git://… or npm://…) — omit for interactive picker",name:"template",type:String},description:"Scaffold files from an in-repo template",examples:[["vis generate","Pick a template interactively"],["vis generate package","Run the 'package' template"],["vis generate component -- --name=Button --style=primary","Pre-fill option values"],["vis generate package --to=./packages/new --force","Custom destination + overwrite"],["vis generate package --dry-run","Print planned writes without touching disk"],["vis generate git://github.com/org/template#main","Fetch and run a remote template"],["vis generate --list","Show discovered templates"],["vis generate --list --json","Machine-readable template list"],["vis generate package --describe --json","Print template metadata (variables, destination) as JSON"]],group:"Scaffold & Config",loader:()=>import("./handler60.js"),name:"generate",options:[{defaultValue:!1,description:"List discovered templates",name:"list",type:Boolean},{defaultValue:!1,description:"Print template metadata (about, destination, variables) without running produce",name:"describe",type:Boolean},{defaultValue:!1,description:"Emit JSON output (with --list or --describe)",name:"json",type:Boolean},{description:"Destination directory",name:"to",type:String},{defaultValue:!1,description:"Print planned writes without touching disk",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Overwrite existing files without prompting",name:"force",type:Boolean},{defaultValue:!1,description:"Skip prompts; use template defaults",name:"defaults",type:Boolean},{defaultValue:!1,description:"Skip running post-generation scripts",name:"skip-scripts",type:Boolean},{defaultValue:!1,description:"Skip interactive prompts (errors on missing required values)",name:"no-interactive",type:Boolean},{defaultValue:!1,description:"Prefer locally cached remote templates over re-downloading",name:"prefer-offline",type:Boolean}]},M0e={description:"Visualize the project dependency graph",examples:[["vis graph","Show colored dependency graph (TUI in TTY, ASCII otherwise)"],["vis graph --format=ascii","Force ASCII tree output"],["vis graph --format=dot","Output in Graphviz DOT format"],["vis graph --format=html --output=graph.html","Generate interactive HTML graph"],["vis graph --format=json --output=graph.json","Save JSON graph to file"]],group:"Workspace",loader:()=>import("./handler72.js"),name:"graph",options:[{alias:"f",defaultValue:void 0,description:"Output format: tui, ascii, dot, json, html (default: tui in TTY, ascii otherwise)",name:"format",type:String},{alias:"o",description:"Write output to file instead of stdout",name:"output",type:String},{alias:"d",description:"Maximum dependency tree depth for ASCII output (default: unlimited)",name:"depth",type:Number}]},GL=["pre-commit","pre-merge-commit","prepare-commit-msg","commit-msg","post-commit","applypatch-msg","pre-applypatch","post-applypatch","pre-rebase","post-rewrite","post-checkout","post-merge","pre-push","pre-auto-gc"],ap=".vis/hooks",Sa=".vis-hooks",dSe=[".pre-commit-config.yaml",".pre-commit-config.yml","prek.toml"],lSe={commit:"pre-commit","merge-commit":"pre-merge-commit",push:"pre-push"},gSe=new Set(["commit-msg","post-checkout","post-commit","post-merge","post-rewrite","pre-commit","pre-merge-commit","pre-push","pre-rebase","prepare-commit-msg"]),hSe=new Set(["commit-msg","post-checkout","post-merge","post-rewrite","pre-rebase","prepare-commit-msg"]),cSe=new Set(["fail","script","system"]),da={defaultValue:ap,description:"Custom hooks directory",name:"hooks-dir",type:String},la=[{defaultValue:void 0,description:"Set to 0 to disable git hooks, 1 to force-enable them under CI (override skipInCI), 2 for debug output",name:"VIS_GIT_HOOKS",type:String}],P0e={commandPath:["hook"],description:"Install git hooks for the workspace (migrates husky / prek on prompt)",env:[...la],examples:[["vis hook install","Install git hooks in .vis/hooks/"],["vis hook install --hooks-dir=.githooks","Install hooks in a custom directory"]],group:"Git Hooks",loader:()=>import("./handler70.js").then(e=>({default:e.hookInstallExecute})),name:"install",options:[da]},N0e={commandPath:["hook"],description:"Remove git hooks and reset core.hooksPath",env:[...la],examples:[["vis hook uninstall","Remove git hooks and reset core.hooksPath"]],group:"Git Hooks",loader:()=>import("./handler70.js").then(e=>({default:e.hookUninstallExecute})),name:"uninstall",options:[da]},E0e={commandPath:["hook"],description:"Migrate from husky or prek to vis hooks (auto-detected)",env:[...la],examples:[["vis hook migrate","Migrate from husky or prek to vis hooks (auto-detected)"],["vis hook migrate --dry-run","Preview what a migration would write without touching disk"]],group:"Git Hooks",loader:()=>import("./handler70.js").then(e=>({default:e.hookMigrateExecute})),name:"migrate",options:[da,{defaultValue:!1,description:"Preview migrate without writing files",name:"dry-run",type:Boolean}]},R0e={commandPath:["hook"],description:"Show configured hooks grouped by stage",env:[...la],examples:[["vis hook list","Show configured hooks grouped by stage"]],group:"Git Hooks",loader:()=>import("./handler70.js").then(e=>({default:e.hookListExecute})),name:"list",options:[da]},O0e={commandPath:["hook"],description:"Sanity-check installed hooks and the bundled runner",env:[...la],examples:[["vis hook validate","Sanity-check installed hooks and the bundled runner"]],group:"Git Hooks",loader:()=>import("./handler70.js").then(e=>({default:e.hookValidateExecute})),name:"validate",options:[da]},A0e={argument:{description:"Hook stage to run (e.g. pre-commit, commit-msg). Defaults to pre-commit.",name:"stage",type:String},commandPath:["hook"],description:"Run a specific hook stage against tracked files",env:[...la],examples:[["vis hook run pre-commit --all-files","Run the pre-commit hooks against every tracked file"],["vis hook run pre-commit --from-ref=main --to-ref=HEAD","Run pre-commit hooks on files changed between two refs"],["vis hook run pre-commit --last-commit","Shortcut for --from-ref HEAD~1 --to-ref HEAD"]],group:"Git Hooks",loader:()=>import("./handler70.js").then(e=>({default:e.hookRunExecute})),name:"run",options:[da,{defaultValue:!1,description:"Run against every tracked file",name:"all-files",type:Boolean},{defaultValue:void 0,description:"Include files changed since this ref",name:"from-ref",type:String},{defaultValue:void 0,description:"Include files changed up to this ref",name:"to-ref",type:String},{defaultValue:!1,description:"Shortcut for --from-ref HEAD~1 --to-ref HEAD",name:"last-commit",type:Boolean}]},G0e={argument:{description:"Target to add (currently: `secrets`)",name:"target",type:String},commandPath:["hook"],description:"Add a managed hook snippet (e.g. `vis secrets --staged`)",env:[...la],examples:[["vis hook add secrets","Add a pre-commit hook that runs `vis secrets --staged`"]],group:"Git Hooks",loader:()=>import("./handler70.js").then(e=>({default:e.hookAddExecute})),name:"add",options:[da]},F0e=[P0e,N0e,E0e,R0e,O0e,A0e,G0e],Q0e={description:"Generate or merge an ignore file (.dockerignore/.vercelignore/.npmignore/.slugignore) without duplicate entries",examples:[["vis ignore","Print a .dockerignore (deduped against an existing one)"],["vis ignore --write","Write/merge the .dockerignore in place"],["vis ignore --target=vercel --write","Write a deduped .vercelignore"],["vis ignore --target=npm --json","Emit the npm-target result as JSON"]],group:"Scaffold & Config",loader:()=>import("./handler53.js"),name:"ignore",options:[{description:"Ignore-file target: docker | vercel | npm | slug (default: docker)",name:"target",type:String},{defaultValue:!1,description:"Write the result to disk instead of printing to stdout",name:"write",type:Boolean},{defaultValue:!1,description:"Emit the result as JSON",name:"json",type:Boolean}]},W0e={description:"Remove vis from the system (self-uninstall)",examples:[["vis implode","Interactive uninstall"],["vis implode --yes","Non-interactive uninstall (CI)"]],group:"System",loader:()=>import("./handler10.js"),name:"implode",options:[{alias:"y",defaultValue:!1,description:"Skip confirmation prompt",name:"yes",type:Boolean}]},I0e={argument:{description:"Source git repository URL or local path to import",name:"source",type:String},description:"Import an external repo into the monorepo under a prefix, preserving history",examples:[["vis import git@github.com:me/foo.git --prefix packages/tooling/foo","Import a repo under packages/tooling/foo"],["vis import ../foo --prefix packages/foo --ref v1.2.0","Import a specific tag/branch/commit"],["vis import ../foo --prefix packages/foo --squash","Collapse the incoming history into one commit"],["vis import ../foo --prefix packages/foo --dry-run","Print the git plan without making changes"]],group:"Workspace",loader:()=>import("./handler54.js"),name:"import",options:[{alias:"p",description:"Target directory in the monorepo (e.g. packages/tooling/foo)",name:"prefix",type:String},{alias:"r",description:"Branch, tag, or commit to import (default: HEAD)",name:"ref",type:String},{defaultValue:!1,description:"Collapse the incoming history into a single merge commit",name:"squash",type:Boolean},{alias:"m",description:"Commit message for the subtree merge",name:"message",type:String},{defaultValue:!1,description:"Do not register the package into the workspace config",name:"no-register",type:Boolean},{defaultValue:!1,description:"Print the git plan instead of executing it",name:"dry-run",type:Boolean}]},_0e={alias:"view",argument:{description:"Package name followed by optional metadata fields (e.g. 'react version dependencies')",name:"args",type:String},description:"Show npm registry metadata for a package (alias of `npm view` / `pnpm view` / `yarn info` / `bun pm view`)",examples:[["vis info react","Full registry metadata for react"],["vis info react version","Latest version only"],["vis info react versions","All published versions"],["vis info react@18 dependencies","Dependencies of react@18"],["vis info react --json","Emit JSON"],["vis view react","Alias matching npm/pnpm"]],group:"Dependencies",loader:()=>import("./handler11.js"),name:"info",options:[{defaultValue:!1,description:"Output as JSON",name:"json",type:Boolean}]},z0e={description:"Initialize vis.config.ts with best-practice security defaults",examples:[["vis init","Interactive setup wizard"],["vis init --no-interactive","Create minimal config without prompts"],["vis init --force","Overwrite existing config"],["vis init --sync-native","Also sync to native PM config files"],["vis init --schema","Print the workspace-relative `$schema` refs to paste into project.json and vis.config.ts"]],group:"Scaffold & Config",loader:()=>import("./handler12.js"),name:"init",options:[{defaultValue:!1,description:"Overwrite existing config file",name:"force",type:Boolean},{defaultValue:!1,description:"Skip interactive prompts",name:"no-interactive",type:Boolean},{defaultValue:!1,description:"Sync settings to native PM config files",name:"sync-native",type:Boolean},{defaultValue:!1,description:"Print workspace-relative $schema paths for project.json and vis.config.ts, then exit",name:"schema",type:Boolean}]},K0e={argument:{description:"Package to inspect, optionally pinned: `<name>` or `<name>@<spec>`. `<spec>` may be a version, range, or dist-tag.",name:"package"},description:"Run all marshalls against a package without installing it",examples:[["vis inspect express","Run every marshall against express@latest"],["vis inspect lodash@4.17.21","Pin to an exact version"],["vis inspect react@^18","Resolve a semver range, then inspect the best match"],["vis inspect express --json","Emit findings as JSON for CI integration"],["vis inspect express --strict","Exit non-zero on any warning, not just errors"],["vis inspect express --only author,downloads","Run a subset of marshalls"],["vis inspect express --only signatures","Signatures are off by default; opt in with --only"]],group:"Security & Health",loader:()=>import("./handler13.js"),name:"inspect",options:[{defaultValue:!1,description:"Emit findings as a JSON document instead of the human-readable table.",name:"json",type:Boolean},{defaultValue:!1,description:"Exit non-zero on any finding (warnings included). Default exits non-zero only on errors.",name:"strict",type:Boolean},{description:"Comma-separated subset of marshalls to run. Known: author, archivedRepo, downloads, expiredDomains, metadata, newBin, provenance, signatures. Signatures only runs when explicitly requested here.",name:"only",type:String}]},q0e={alias:"i",argument:{description:"Optional package names. When provided, delegates to `vis add` (enables npm-style `alias npm='vis install'` wrappers).",name:"packages",type:String},description:"Install dependencies using the detected package manager",examples:[["vis install","Install all dependencies (frozen-lockfile by default when a lockfile is present)"],["vis install react react-dom","Delegates to `vis add` — enables shell aliases like `alias npm='vis install'`"],["vis i --no-frozen-lockfile","Allow lockfile updates (escape hatch for the default)"],["vis install --ci","Clean install: wipe node_modules + frozen lockfile (mirrors npm ci / pnpm ci)"],["vis install --prefer-offline","Use cached packages when available, fall back to network"],["vis install --prod","Install production dependencies only"],["vis install --filter app","Install for specific workspace package"],["vis install --run-scripts","Run lifecycle scripts (opts out of vis's default block-by-default policy; allowlisted packages run via security.policies.installScripts.allow)"],["vis install --no-typosquat-check","Skip typosquat name check"],["vis install --installer aube","Force aube as the installer (errors if not on PATH)"],["vis install --no-aube","Bypass aube; use the lockfile-detected PM"]],group:"Dependencies",loader:()=>import("./handler14.js"),name:"install",options:[{alias:"P",conflicts:"dev",description:"Skip devDependencies (no positional args) / add as peer (with positional args, npm-style)",name:"prod",type:Boolean},{alias:"D",conflicts:"prod",description:"Install devDependencies only (no positional args) / add as dev (with positional args, npm-style)",name:"dev",type:Boolean},{defaultValue:!1,description:"Add as optional dependency (only with positional args; mirrors `npm install -O`)",name:"save-optional",type:Boolean},{alias:"E",defaultValue:!1,description:"Save exact version (only with positional args; mirrors `npm install -E`)",name:"exact",type:Boolean},{defaultValue:!1,description:"Skip Socket.dev security check (only with positional args; mirrors `vis add --no-socket-check`)",name:"no-socket-check",type:Boolean},{defaultValue:!1,description:"Skip the offline marshall pipeline (only with positional args; mirrors `vis add --no-marshall-check`)",name:"no-marshall-check",type:Boolean},{defaultValue:!1,description:"Use frozen lockfile (CI mode, maps to npm ci)",name:"frozen-lockfile",type:Boolean},{defaultValue:!1,description:"Opt out of vis's default frozen-lockfile behavior and allow lockfile updates",name:"no-frozen-lockfile",type:Boolean},{defaultValue:!1,description:"Clean install: wipe node_modules then install with frozen lockfile",name:"ci",type:Boolean},{alias:"f",defaultValue:!1,description:"Force reinstall all dependencies",name:"force",type:Boolean},{defaultValue:!1,description:"Run lifecycle scripts (opts out of vis's default block-by-default policy; allowlisted packages run via security.policies.installScripts.allow)",name:"run-scripts",type:Boolean},{defaultValue:!1,description:"Update lockfile without installing",name:"lockfile-only",type:Boolean},{defaultValue:!1,description:"Skip optional dependencies",name:"no-optional",type:Boolean},{defaultValue:!1,description:"Use only cached packages",name:"offline",type:Boolean},{defaultValue:!1,description:"Prefer cached packages, fall back to network when missing",name:"prefer-offline",type:Boolean},{alias:"s",defaultValue:!1,description:"Suppress output",name:"silent",type:Boolean},{alias:"r",defaultValue:!1,description:"Install in all workspace packages",name:"recursive",type:Boolean},{alias:"w",defaultValue:!1,description:"Target workspace root",name:"workspace-root",type:Boolean},{alias:"F",description:"Filter by workspace package name",multiple:!0,name:"filter",type:String},{defaultValue:!1,description:"Skip typosquat name check",name:"no-typosquat-check",type:Boolean},{description:"Pick the installer explicitly. One of: auto, aube, pnpm, npm, yarn, bun. Overrides VIS_INSTALLER and install.backend in vis.config.",name:"installer",type:String},{defaultValue:!1,description:"Skip aube and use the lockfile-detected PM. Wins over --installer / VIS_INSTALLER / install.backend.",name:"no-aube",type:Boolean}]},U0e={alias:"ln",argument:{description:"Package name or directory path to link (omit to register current package)",name:"target",type:String},description:"Link a local package for development",examples:[["vis link ./packages/utils","Link local directory package (works on all PMs)"],["vis link","Register current package globally (pnpm <=10, yarn, npm, bun)"],["vis link react","Link global package into current project (pnpm <=10, yarn, npm, bun)"]],group:"Dependencies",loader:()=>import("./handler16.js"),name:"link"},V0e={description:"Orchestrate detected source-code linters (eslint, …) across the workspace",examples:[["vis lint","Run every detected linter against the workspace"],["vis lint --fix","Apply auto-fixes where the tool supports them"],["vis lint --format json","Emit findings as JSON for CI / editor integrations"],["vis lint --format sarif","Emit a SARIF 2.1.0 document for code-scanning uploads"],["vis lint --format junit","Emit a JUnit XML report for CI dashboards"],["vis lint --format github","Emit GitHub Actions workflow commands for inline PR annotations"],["vis lint src/foo.ts src/bar.ts","Lint a specific file list"],["vis lint --quiet","Suppress warnings — only errors are reported"],["vis lint --max-warnings 0","Treat any warning as a failure"],["vis lint --since main","Only lint files changed vs the main branch"],["vis lint --staged","Only lint files currently staged in the git index"],["vis lint --watch","Re-run linters when watched files change (cache makes incremental near-free)"],["vis lint --format sarif --output lint.sarif","Write the SARIF report to lint.sarif instead of stdout"]],group:"Lint & Format",loader:()=>import("./handler62.js"),name:"lint",options:[{defaultValue:!1,description:"Apply auto-fixes in place",name:"fix",type:Boolean},{defaultValue:"human",description:"Output format: human, json, minimal, sarif, junit, or github",name:"format",type:String},{defaultValue:!1,description:"Suppress warnings — report errors only",name:"quiet",type:Boolean},{description:"Fail the run if more than N warnings are reported",name:"max-warnings",type:Number},{description:"Only lint files changed vs the given git ref (branch, tag, sha)",name:"since",type:String},{defaultValue:!1,description:"Only lint files currently staged in the git index",name:"staged",type:Boolean},{description:"Write formatted output to a file path instead of stdout (also accepts `-`/`stdout`/`stderr`)",name:"output",type:String},{defaultValue:!1,description:"Re-run linters whenever watched files change",name:"watch",type:Boolean}]},efe={description:"List all workspace projects with metadata",examples:[["vis list","Show all projects"],["vis list --targets","Per-target rows with type, cache status and description"],["vis list --targets --inferred","Only show targets synthesized by Project Crystal-style inference"],["vis list --deps","Human-readable table of every dep-instance across the workspace"],["vis list --deps --internal-only","Only workspace deps in human form"],["vis list --deps --format=ndjson","Stream every dep-instance as NDJSON for jq pipelines"],["vis list --deps --format=json --pretty","Single pretty-printed JSON array of dep-instances"],["vis list --format=json","Machine-readable project listing"],['vis list --query "tag=frontend"',"Filter by query"]],group:"Workspace",loader:()=>import("./handler55.js"),name:"list",options:[{defaultValue:!1,description:"Filter target rows to only inferred targets (implies --targets)",name:"inferred",type:Boolean},{description:"Output format: table (default), json (single document), or ndjson (one record per line; --deps only)",name:"format",type:String},{defaultValue:!1,description:"Pretty-print with 2-space indent (only meaningful with --format=json)",name:"pretty",type:Boolean},{description:"Filter projects by query",name:"query",type:String},{defaultValue:!1,description:"Show per-target rows (type, cache, description)",name:"targets",type:Boolean},{defaultValue:!1,description:"Render a dep-instance view (table by default; use --format=ndjson|json for jq-friendly streams)",name:"deps",type:Boolean},{description:"Restrict --deps to specific dep blocks (repeatable)",multiple:!0,name:"dep-type",type:String},{defaultValue:!1,description:"With --deps: only show internal/workspace deps",name:"internal-only",type:Boolean},{defaultValue:!1,description:"With --deps: only show external/registry deps",name:"external-only",type:Boolean},{description:"With --deps: glob of declaring package names to keep (repeatable)",multiple:!0,name:"include",type:String},{description:"With --deps: glob of declaring package names to drop (repeatable)",multiple:!0,name:"exclude",type:String}]},Hi=[{defaultValue:!1,description:"Preview changes without applying",name:"dry-run",type:Boolean},{alias:"y",defaultValue:!1,description:"Skip the confirmation prompt",name:"yes",type:Boolean}],ife={commandPath:["migrate"],description:"Migrate dependencies and scripts to vis",group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateDepsExecute})),name:"deps",options:[...Hi]},nfe={commandPath:["migrate"],description:"Inline lint-staged configuration into vis",group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateLintStagedExecute})),name:"lint-staged",options:[...Hi]},ofe={commandPath:["migrate"],description:"Inline nano-staged configuration into vis",group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateNanoStagedExecute})),name:"nano-staged",options:[...Hi]},afe={commandPath:["migrate"],description:"Migrate turborepo tasks/config to vis",group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateTurborepoExecute})),name:"turborepo",options:[...Hi]},tfe={commandPath:["migrate"],description:"Migrate nx targets/config to vis",group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateNxExecute})),name:"nx",options:[...Hi,{defaultValue:!1,description:"Overwrite an existing vis.config.ts (a .bak is taken first)",name:"force",type:Boolean},{defaultValue:!1,description:"For each project.json `syncGenerators`, add a `pre<target>` script to sibling package.json (with a TODO for the user to wire up)",name:"rewrite-sync-generators",type:Boolean},{defaultValue:!1,description:"Auto-apply the safe cleanup items the migrator would otherwise leave on the checklist: delete nx.json + ignore-files-for-nx-affected.yml, strip nx/@nx/*/@nrwl/* devDependencies, rewrite mechanical `nx run-many|run|affected` scripts. Implies --force.",name:"aggressive",type:Boolean}]},sfe={commandPath:["migrate"],description:"Migrate moon tasks/templates to vis",group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateMoonExecute})),name:"moon",options:[...Hi,{defaultValue:!1,description:"Copy .moon/templates/* into .vis/templates/* so `vis generate` works without .moon/",name:"copy-templates",type:Boolean}]},rfe={commandPath:["migrate"],description:"Migrate gitleaks config/baseline/hooks to `vis secrets`",examples:[["vis migrate gitleaks","Migrate gitleaks config/baseline/hooks to `vis secrets`"]],group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateGitleaksExecute})),name:"gitleaks",options:[...Hi]},ufe={commandPath:["migrate"],description:"Migrate Kingfisher baseline/hooks/scripts to `vis secrets`",examples:[["vis migrate kingfisher","Migrate Kingfisher baseline/hooks/scripts to `vis secrets`"]],group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateKingfisherExecute})),name:"kingfisher",options:[...Hi]},dfe={commandPath:["migrate"],description:"Replace secretlint with `vis secrets`",examples:[["vis migrate secretlint","Replace secretlint with `vis secrets`"]],group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateSecretlintExecute})),name:"secretlint",options:[...Hi]},lfe={commandPath:["migrate"],description:"Translate syncpack customTypes into vis policy and strip the syncpack dep/scripts",examples:[["vis migrate syncpack","Translate syncpack customTypes into vis policy and strip the syncpack dep/scripts"]],group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateSyncpackExecute})),name:"syncpack",options:[...Hi]},gfe={commandPath:["migrate"],description:"Strip sherif config/dep/scripts and surface ignore-rules as a positive `vis lint --<rule>` command",examples:[["vis migrate sherif","Strip sherif config/dep/scripts and surface ignore-rules as a positive `vis lint --<rule>` command"]],group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateSherifExecute})),name:"sherif",options:[...Hi]},hfe={commandPath:["migrate"],description:"Auto-rewrite vis.config.ts to use renamed fields (targetDefaults → tasks, taskDefaults → scopedTasks, taskRunnerOptions → taskRunner)",examples:[["vis migrate self","Rewrite vis.config.ts in-place (a .bak is taken first)"],["vis migrate self --dry-run","Preview the rewrite without writing"]],group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateSelfExecute})),name:"self",options:[...Hi]},cfe={commandPath:["migrate"],description:"Audit the workspace for stray gitleaks/secretlint/sherif/syncpack references (exit 1 on issues)",examples:[["vis migrate verify","Audit the workspace for stray gitleaks/secretlint/sherif/syncpack references (exit 1 on issues)"]],group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateVerifyExecute})),name:"verify",options:[]},pfe={commandPath:["migrate"],description:"Prove a turbo/nx/moon → vis migration preserved the task graph + cache-key surface (exit 1 on divergence)",examples:[["vis migrate verify-graph","Auto-detect the source tool and diff its task graph against the migrated vis.config.ts"],["vis migrate verify-graph --from turbo --format json","Machine-readable equivalence report on stdout (Axis A)"],["vis migrate verify-graph --fail-on warning","Also gate CI on additive/extra-target warnings"]],group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateVerifyGraphExecute})),name:"verify-graph",options:[{description:"Source tool to compare against (turbo|nx|moon). Auto-detected when omitted.",name:"from",type:String},{description:"Output format: table | json | ndjson (default: table)",name:"format",type:String},{description:"Exit non-zero on: error (default) | warning",name:"fail-on",type:String}]},vfe={commandPath:["migrate"],description:"Run every applicable migration non-interactively (autodetected)",examples:[["vis migrate all --yes","Run every detected migration without prompting (CI-friendly)"],["vis migrate all --dry-run","Preview every detected migration without writing files"]],group:"Migrate",loader:()=>import("./handler57.js").then(e=>({default:e.migrateAllExecute})),name:"all",options:[...Hi]},yfe=[vfe,ife,nfe,ofe,afe,tfe,sfe,hfe,rfe,ufe,dfe,lfe,gfe,cfe,pfe],ffe=new Set(["--cwd"]),mfe=new Set(["--help","--version","-h","-V"]),bfe=e=>{const i=[];for(let n=0;n<e.length;n+=1){const o=e[n];if(o!==void 0){if(mfe.has(o))return!1;if(o.startsWith("-")){const a=o.indexOf("="),t=a===-1?o:o.slice(0,a);if(ffe.has(t)&&a===-1){const s=e[n+1];s!==void 0&&!s.startsWith("-")&&(n+=1)}continue}i.push(o)}}return i.length===1&&i[0]==="migrate"},wfe=e=>{if(e.length===0)return!1;for(const i of e){const n=i.codePointAt(0)??0;return!(n<=127||n<=255)}return!1};let jfe=class{buffer="";timer;onFlush;timeout;constructor({onFlush:i,timeout:n}){this.onFlush=i,this.timeout=n}add(i){this.buffer+=i,this.timer!==void 0&&clearTimeout(this.timer),this.timer=setTimeout(()=>{this.flush()},this.timeout)}flush(){if(this.timer!==void 0&&(clearTimeout(this.timer),this.timer=void 0),this.buffer.length>0){const i=this.buffer;this.buffer="",this.onFlush(i)}}destroy(){this.timer!==void 0&&(clearTimeout(this.timer),this.timer=void 0),this.buffer=""}};const ar=e=>{const i=/rgb:([\da-f]{2,4})\/([\da-f]{2,4})\/([\da-f]{2,4})/i.exec(e);if(!i)return null;const n=o=>o.length<=2?o.padStart(2,"0"):o.slice(0,2);return`#${n(i[1])}${n(i[2])}${n(i[3])}`},kfe=()=>{const e=process.env.TERM_PROGRAM??"";return new Set(["Alacritty","contour","foot","Ghostty","iTerm2","iTerm.app","kitty","rio","WezTerm"]).has(e)?!0:(process.env.TERM??"").startsWith("xterm")||!!process.env.WT_SESSION},tr=(e,i,n,o=500)=>new Promise(a=>{let t="",s;const r=()=>{s&&clearTimeout(s),e.removeListener("data",u)},u=d=>{if(t+=d.toString(),t.length>256){r(),a(null);return}(t.includes("\x07")||t.includes("\x1B\\"))&&(r(),a(t))};s=setTimeout(()=>{r(),a(null)},o),e.on("data",u),i.write(n)}),Sfe=async(e,i,n=500)=>{const o={},a=await tr(e,i,"\x1B]10;?\x07",n);if(a){const u=ar(a);u&&(o.foreground=u)}const t=await tr(e,i,"\x1B]11;?\x07",n);if(t){const u=ar(t);u&&(o.background=u)}const s=await tr(e,i,"\x1B]12;?\x07",n);if(s){const u=ar(s);u&&(o.cursor=u)}const r=[];for(let u=0;u<16;u++){const d=await tr(e,i,`\x1B]4;${u};?\x07`,n);if(d){const l=ar(d);r.push(l??"")}else r.push("")}return r.some(u=>u.length>0)&&(o.colors=r),o},FL=()=>D.useContext(xY),QL=()=>{const{stdout:e}=FL(),[i,n]=D.useState(()=>jp(e));return D.useEffect(()=>{const o=()=>{n(jp(e))};return e.on("resize",o),()=>{e.off("resize",o)}},[e]),i},Lfe=()=>D.useContext(nm),WL=()=>D.useContext(nm);class Cfe{#n;#i=new Set;constructor(i){this.#n={applyProgress:null,checkedItems:new Set(i.map(n=>n.entry.id)),error:null,focusedPanel:"list",items:i,phase:"browsing",selectedIndex:0}}getSnapshot=()=>this.#n;subscribe=i=>(this.#i.add(i),()=>{this.#i.delete(i)});getCheckedItems(){return this.#n.items.filter(i=>this.#n.checkedItems.has(i.entry.id))}getSelectedItem(){return this.#n.items[this.#n.selectedIndex]??null}setSelectedIndex(i){const n=Math.max(0,Math.min(i,this.#n.items.length-1));n!==this.#n.selectedIndex&&this.#e({...this.#n,selectedIndex:n})}setFocusedPanel(i){i!==this.#n.focusedPanel&&this.#e({...this.#n,focusedPanel:i})}toggleCheck(i){const n=new Set(this.#n.checkedItems);n.has(i)?n.delete(i):n.add(i),this.#e({...this.#n,checkedItems:n})}checkAll(){this.#e({...this.#n,checkedItems:new Set(this.#n.items.map(i=>i.entry.id))})}uncheckAll(){this.#e({...this.#n,checkedItems:new Set})}toggleAll(){this.#n.checkedItems.size===this.#n.items.length?this.uncheckAll():this.checkAll()}startApply(){const i=this.getCheckedItems().length;this.#e({...this.#n,applyProgress:{current:0,total:i},phase:"applying"})}updateApplyProgress(i){this.#n.applyProgress&&this.#e({...this.#n,applyProgress:{...this.#n.applyProgress,current:i}})}markDone(){this.#e({...this.#n,phase:"done"})}setError(i){this.#e({...this.#n,error:i,phase:"error"})}#e(i){this.#n=i;for(const n of this.#i)try{n()}catch{}}}const Yfe=()=>{const{stdin:e}=WL(),{stdout:i}=FL(),[n,o]=D.useState(null),[a,t]=D.useState(!0),s=D.useMemo(()=>kfe(),[]);return D.useEffect(()=>{if(!s||!e||!i){t(!1);return}let r=!1;return(async()=>{try{const u=await Sfe(e,i,200);r||o(u)}catch{}finally{r||t(!1)}})(),()=>{r=!0}},[s,e,i]),{isLoading:a,isSupported:s,palette:n}},$fe=({autoFocus:e=!1,id:i,isActive:n=!0}={})=>{const{isRawModeSupported:o,setRawMode:a}=Lfe(),{activate:t,activeId:s,add:r,deactivate:u,focus:d,remove:l}=D.useContext(TY),g=D.useMemo(()=>i??Math.random().toString().slice(2,7),[i]);return D.useEffect(()=>(r(g,{autoFocus:e}),()=>{l(g)}),[g,e]),D.useEffect(()=>{n?t(g):u(g)},[n,g]),D.useEffect(()=>{if(!(!o||!n))return a(!0),()=>{a(!1)}},[n]),{focus:d,isFocused:!!g&&s===g}},Zfe=wn(import.meta.url),Nt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,Jfe=e=>{if(typeof Nt<"u"&&Nt.versions&&Nt.versions.node){const[i,n]=Nt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return Nt.getBuiltinModule(e)}return Zfe(e)},{Buffer:xfe}=Jfe("node:buffer"),Tfe=/^\u001B([a-z0-9])$/i,Dfe=/^\u001B+([ON[]|\[\[)(?:(\d+)(?:;(\d+))?([~^$])|(?:1;)?(\d+)?([a-zA-Z]))/,IL={"[1~":"home","[2$":"insert","[2^":"insert","[2~":"insert","[3$":"delete","[3^":"delete","[3~":"delete","[4~":"end","[5$":"pageup","[5^":"pageup","[5~":"pageup","[6$":"pagedown","[6^":"pagedown","[6~":"pagedown","[7$":"home","[7^":"home","[7~":"home","[8$":"end","[8^":"end","[8~":"end","[11~":"f1","[12~":"f2","[13~":"f3","[14~":"f4","[15~":"f5","[17~":"f6","[18~":"f7","[19~":"f8","[20~":"f9","[21~":"f10","[23~":"f11","[24~":"f12","[[5~":"pageup","[[6~":"pagedown","[[A":"f1","[[B":"f2","[[C":"f3","[[D":"f4","[[E":"f5","[A":"up","[a":"up","[B":"down","[b":"down","[C":"right","[c":"right","[D":"left","[d":"left","[E":"clear","[e":"clear","[F":"end","[H":"home","[P":"f1","[Q":"f2","[R":"f3","[S":"f4","[Z":"tab",OA:"up",Oa:"up",OB:"down",Ob:"down",OC:"right",Oc:"right",OD:"left",Od:"left",OE:"clear",Oe:"clear",OF:"end",OH:"home",OP:"f1",OQ:"f2",OR:"f3",OS:"f4"},Bfe=[...Object.values(IL),"backspace"],Xfe=e=>["[2$","[3$","[5$","[6$","[7$","[8$","[a","[b","[c","[d","[e","[Z"].includes(e),Hfe=e=>["[2^","[3^","[5^","[6^","[7^","[8^","Oa","Ob","Oc","Od","Oe"].includes(e),_L=/^\u001B\[(\d+)(?:;(\d+)(?::(\d+))?(?:;([\d:]+))?)?u$/,Mfe=/^\u001B\[(\d+);(\d+):(\d+)([A-Z~])$/i,Pfe={A:"up",B:"down",C:"right",D:"left",E:"clear",F:"end",H:"home",P:"f1",Q:"f2",R:"f3",S:"f4"},Nfe={2:"insert",3:"delete",5:"pageup",6:"pagedown",7:"home",8:"end",11:"f1",12:"f2",13:"f3",14:"f4",15:"f5",17:"f6",18:"f7",19:"f8",20:"f9",21:"f10",23:"f11",24:"f12"},ff={8:"backspace",9:"tab",27:"escape",127:"backspace",57358:"capslock",57359:"scrolllock",57360:"numlock",57361:"printscreen",57362:"pause",57363:"menu",57376:"f13",57377:"f14",57378:"f15",57379:"f16",57380:"f17",57381:"f18",57382:"f19",57383:"f20",57384:"f21",57385:"f22",57386:"f23",57387:"f24",57388:"f25",57389:"f26",57390:"f27",57391:"f28",57392:"f29",57393:"f30",57394:"f31",57395:"f32",57396:"f33",57397:"f34",57398:"f35",57399:"kp0",57400:"kp1",57401:"kp2",57402:"kp3",57403:"kp4",57404:"kp5",57405:"kp6",57406:"kp7",57407:"kp8",57408:"kp9",57409:"kpdecimal",57410:"kpdivide",57411:"kpmultiply",57412:"kpsubtract",57413:"kpadd",57414:"kpenter",57415:"kpequal",57416:"kpseparator",57417:"kpleft",57418:"kpright",57419:"kpup",57420:"kpdown",57421:"kppageup",57422:"kppagedown",57423:"kphome",57424:"kpend",57425:"kpinsert",57426:"kpdelete",57427:"kpbegin",57428:"mediaplay",57429:"mediapause",57430:"mediaplaypause",57431:"mediareverse",57432:"mediastop",57433:"mediafastforward",57434:"mediarewind",57435:"mediatracknext",57436:"mediatrackprevious",57437:"mediarecord",57438:"lowervolume",57439:"raisevolume",57440:"mutevolume",57441:"leftshift",57442:"leftcontrol",57443:"leftalt",57444:"leftsuper",57445:"lefthyper",57446:"leftmeta",57447:"rightshift",57448:"rightcontrol",57449:"rightalt",57450:"rightsuper",57451:"righthyper",57452:"rightmeta",57453:"isoLevel3Shift",57454:"isoLevel5Shift"},zL=e=>e>=0&&e<=1114111&&!(e>=55296&&e<=57343),kl=e=>zL(e)?String.fromCodePoint(e):"?";function KL(e){return e===3?"release":e===2?"repeat":"press"}function qL(e){return{capsLock:!!(e&Un.capsLock),ctrl:!!(e&Un.ctrl),hyper:!!(e&Un.hyper),meta:!!(e&Un.meta),numLock:!!(e&Un.numLock),option:!!(e&Un.alt),shift:!!(e&Un.shift),super:!!(e&Un.super)}}const Efe=e=>{const i=_L.exec(e);if(!i)return null;const n=Number.parseInt(i[1],10),o=i[2]?Math.max(0,Number.parseInt(i[2],10)-1):0,a=i[3]?Number.parseInt(i[3],10):1,t=i[4];if(!zL(n))return null;let s;t&&(s=t.split(":").map(d=>kl(Number.parseInt(d,10))).join(""));let r,u;return n===32?(r="space",u=!0):n===13?(r="return",u=!0):ff[n]?(r=ff[n],u=!1):n>=1&&n<=26?(r=String.fromCodePoint(n+96),u=!1):(r=kl(n).toLowerCase(),u=!0),u&&!s&&(s=kl(n)),{name:r,...qL(o),eventType:KL(a),isKittyProtocol:!0,isPrintable:u,raw:e,sequence:e,text:s}},Rfe=e=>{const i=Mfe.exec(e);if(!i)return null;const n=Number.parseInt(i[1],10),o=Math.max(0,Number.parseInt(i[2],10)-1),a=Number.parseInt(i[3],10),t=i[4],s=t==="~"?Nfe[n]:Pfe[t];return s?{name:s,...qL(o),eventType:KL(a),isKittyProtocol:!0,isPrintable:!1,raw:e,sequence:e}:null},Ofe=(e="")=>{let i;xfe.isBuffer(e)?e[0]>127&&e[1]===void 0?(e[0]-=128,e=`\x1B${String(e)}`):e=String(e):e!==void 0&&typeof e!="string"?e=String(e):e||(e="");const n=Efe(e);if(n)return n;const o=Rfe(e);if(o)return o;if(_L.test(e))return{ctrl:!1,isKittyProtocol:!0,isPrintable:!1,meta:!1,name:"",option:!1,raw:e,sequence:e,shift:!1};const a={ctrl:!1,meta:!1,name:"",option:!1,raw:e,sequence:e,shift:!1};switch(a.sequence=a.sequence||e||a.name,e){case"\r":case"\x1B\r":{a.raw=void 0,a.name="return",a.option=e.length===2;break}case`
173
- `:{a.name="enter";break}case" ":{a.name="tab";break}case" ":case"\x1B ":{a.name="space",a.meta=e.length===2;break}case"\b":case"\x1B\b":{a.name="backspace",a.meta=e.charAt(0)==="\x1B";break}case"\x1B":case"\x1B\x1B":{a.name="escape",a.meta=e.length===2;break}case"\x1B":case"":{a.name="backspace",a.meta=e.charAt(0)==="\x1B";break}default:if(e.length===1&&e<="")a.name=String.fromCharCode(e.charCodeAt(0)+97-1),a.ctrl=!0;else if(e.length===1&&e>="0"&&e<="9")a.name="number";else if(e.length===1&&e>="a"&&e<="z")a.name=e;else if(e.length===1&&e>="A"&&e<="Z")a.name=e.toLowerCase(),a.shift=!0;else if(i=Tfe.exec(e))a.meta=!0,a.shift=/^[A-Z]$/.test(i[1]);else if(i=Dfe.exec(e)){const t=[...e];t[0]==="\x1B"&&t[1]==="\x1B"&&(a.option=!0);const s=[i[1],i[2],i[4],i[6]].filter(Boolean).join(""),r=(i[3]||i[5]||1)-1;a.ctrl=!!(r&4),a.meta=!!(r&10),a.shift=!!(r&1),a.code=s,a.name=IL[s]??"",a.shift=Xfe(s)||a.shift,a.ctrl=Hfe(s)||a.ctrl}}return a},tp=(e,i={})=>{const{internal_eventEmitter:n,internal_exitOnCtrlC:o,setRawMode:a,stdin:t}=WL(),s=i.imeEnabled??!0,r=i.imeTimeout??50,u=D.useRef(void 0),d=D.useEffectEvent(e);D.useEffect(()=>{if(s)return u.current=new jfe({onFlush:l=>{const g={backspace:!1,capsLock:!1,ctrl:!1,delete:!1,downArrow:!1,end:!1,escape:!1,home:!1,hyper:!1,leftArrow:!1,meta:!1,numLock:!1,pageDown:!1,pageUp:!1,return:!1,rightArrow:!1,shift:!1,super:!1,tab:!1,upArrow:!1};kp.discreteUpdates(()=>{d(l,g)})},timeout:r}),()=>{u.current?.destroy(),u.current=void 0}},[s,r]),D.useEffect(()=>{if(i.isActive!==!1)return a(!0),()=>{a(!1)}},[i.isActive,a]),D.useEffect(()=>{if(i.isActive===!1)return;const l=g=>{if(s&&wfe(g)){u.current?.add(g);return}u.current?.flush();const h=Ofe(g),c={backspace:h.name==="backspace",capsLock:h.capsLock??!1,ctrl:h.ctrl,delete:h.name==="delete",downArrow:h.name==="down",end:h.name==="end",escape:h.name==="escape",eventType:h.eventType,home:h.name==="home",hyper:h.hyper??!1,leftArrow:h.name==="left",meta:h.meta||h.option,numLock:h.numLock??!1,pageDown:h.name==="pagedown",pageUp:h.name==="pageup",return:h.name==="return",rightArrow:h.name==="right",shift:h.shift,super:h.super??!1,tab:h.name==="tab",upArrow:h.name==="up"};let p;h.isKittyProtocol?h.isPrintable?p=h.text??h.name:h.ctrl&&h.name.length===1?p=h.name:p="":h.ctrl?p=h.name:p=h.sequence,!h.isKittyProtocol&&Bfe.includes(h.name)&&(p=""),p.startsWith("\x1B")&&(p=p.slice(1)),p.length===1&&typeof p[0]=="string"&&/[A-Z]/.test(p[0])&&(c.shift=!0),!(p==="c"&&c.ctrl&&o)&&(!h.name&&p===""||kp.discreteUpdates(()=>{d(p,c)}))};return n.on("input",l),()=>{n.removeListener("input",l)}},[i.isActive,t,o,s])},Afe=e=>{const{getViewportHeight:i,isActive:n=!0,scrollBy:o,scrollToBottom:a,scrollToTop:t,vimBindings:s=!1}=e,{isFocused:r}=$fe({isActive:n});return tp((u,d)=>{if(d.upArrow){o(-1);return}if(d.downArrow){o(1);return}if(d.pageUp){o(-i());return}if(d.pageDown){o(i());return}if(d.home){t();return}if(d.end){a();return}if(d.ctrl&&u==="u"){o(-Math.floor(i()/2));return}if(d.ctrl&&u==="d"){o(Math.floor(i()/2));return}if(s){if(u==="k"){o(-1);return}if(u==="j"){o(1);return}if(u==="G"&&d.shift){a();return}if(u==="g"&&!d.shift){t();return}if(u==="u"&&!d.ctrl){o(-Math.floor(i()/2));return}u==="d"&&!d.ctrl&&o(Math.floor(i()/2))}},{isActive:n}),{isFocused:r}},Hg=e=>{const[i,n]=D.useState(e),o=D.useRef(e),a=D.useCallback(s=>{const r=typeof s=="function"?s(o.current):s;o.current=r,n(r)},[]),t=D.useCallback(()=>o.current,[]);return[i,a,t]},Gfe=({children:e,index:i,measureKey:n,onMeasure:o,width:a})=>{const t=D.useRef(null);return D.useLayoutEffect(()=>{if(t.current){const{height:s}=om(t.current);o(i,s)}},[i,o,a,n,e]),Y.jsx(_,{flexDirection:"column",flexShrink:0,ref:t,width:"100%",children:e})},Qr=e=>{if(e==null)return[];if(Array.isArray(e)){const i=[];for(let n=0;n<e.length;n+=1){const o=e[n];D.isValidElement(o)&&o.type===D.Fragment?i.push(...Qr(o.props.children)):i.push(o)}return i}return D.isValidElement(e)&&e.type===D.Fragment?Qr(e.props.children):[e]},mf=({children:e,debug:i=!1,onContentHeightChange:n,onItemHeightChange:o,onViewportSizeChange:a,overscan:t=3,ref:s,scrollOffset:r,virtualize:u=!1,...d})=>{const l=D.useRef(!1),[g,h,c]=Hg({height:0,width:0}),[p,f,w]=Hg(0),[v,j]=D.useState({}),C=D.useRef(null),y=D.useRef(0);D.useLayoutEffect(()=>{p!==y.current&&(n?.(p,y.current),y.current=p)},[p,n]);const k=D.useRef({}),S=D.useRef([]),J=D.useRef([]),T=D.useRef(0),M=D.useCallback((H,N)=>{const X=S.current[H]??H;if(k.current[X]!==N){const G=k.current[X]??0;k.current={...k.current,[X]:N};let I=0;for(let te=0;te<S.current.length;te+=1){const E=S.current[te];E!=null&&(I+=k.current[E]??0)}const V=w();I!==V&&f(I),o?.(H,N,G),T.current=Math.min(T.current,H+1)}},[o,w,f]),he=D.useCallback(()=>{if(C.current){const{height:H,width:N}=om(C.current),X=c();(N!==X.width||H!==X.height)&&(a?.({height:H,width:N},X),h({height:H,width:N}))}},[C,a,c,h]);D.useLayoutEffect(()=>{he()});const Je=D.useRef(null);if(Je.current!==e){Je.current=e;const H=[],N={};Qr(e).forEach((I,V)=>{if(!I)return;const te=(D.isValidElement(I)?I.key:null)??V;H[V]=te;const E=k.current[te]??0;N[te]=E}),k.current=N,S.current=H,J.current=Array.from({length:H.length}).fill(0),T.current=0;let X=0;H.forEach(I=>{X+=N[I]??0});const G=w();X!==G&&f(X)}D.useImperativeHandle(s,()=>({getBottomOffset:()=>Math.max(0,w()-c().height),getContentHeight:w,getItemHeight:H=>{const N=S.current[H]??H;return k.current[N]??0},getItemPosition:H=>{if(H<0||H>=S.current.length)return null;if(H>=T.current){let G=0,I=0;if(T.current>0){I=T.current;const V=I-1,te=S.current[V]??V,E=k.current[te]??0;G=(J.current[V]??0)+E}for(let V=I;V<=H;V+=1){J.current[V]=G;const te=S.current[V]??V,E=k.current[te]??0;G+=E}T.current=H+1}const N=J.current[H]??0,X=S.current[H]??H;return{height:k.current[X]??0,top:N}},getViewportHeight:()=>c().height,remeasure:he,remeasureItem:H=>{j(N=>({...N,[H]:(N[H]??0)+1}))}}),[he,w,c,j]);const Se=Qr(e);!l.current&&p>0&&(l.current=!0);let Le=0,Xe=Se.length-1,A=0,$=0;const P=Se.length>0&&Se.every((H,N)=>{const X=S.current[N]??N;return(k.current[X]??0)>0}),W=u&&l.current&&P;if(W){const H=S.current.length;if(T.current<H){let X=0,G=0;if(T.current>0){G=T.current;const I=G-1,V=S.current[I]??I,te=k.current[V]??0;X=(J.current[I]??0)+te}for(let I=G;I<H;I+=1){J.current[I]=X;const V=S.current[I]??I;X+=k.current[V]??0}T.current=H}const N=r+g.height;Le=Se.length,Xe=-1;for(let X=0;X<H;X+=1){const G=J.current[X]??0,I=S.current[X]??X,V=k.current[I]??0;G+V>r&&G<N&&(X<Le&&(Le=X),Xe=X)}if(Le>Xe&&(Le=0,Xe=-1),Le=Math.max(0,Le-t),Xe=Math.min(Se.length-1,Math.max(-1,Xe)+t),A=J.current[Le]??0,Xe<Se.length-1){const X=S.current[Xe]??Xe,G=(J.current[Xe]??0)+(k.current[X]??0);$=p-G}}return Y.jsx(_,{...d,children:Y.jsx(_,{ref:C,width:"100%",children:Y.jsx(_,{overflow:i?void 0:"hidden",width:"100%",children:Y.jsxs(_,{flexDirection:"column",marginTop:-r,width:"100%",children:[W&&A>0&&Y.jsx(_,{height:A}),Se.map((H,N)=>!H||W&&(N<Le||N>Xe)?null:Y.jsx(Gfe,{index:N,measureKey:v[N],onMeasure:M,width:g.width,children:H},D.isValidElement(H)?H.key??N:N)),W&&$>0&&Y.jsx(_,{height:$})]})})})})},bf={arrow:{lowerThumb:"╽",thumb:"┃",track:"|",upperThumb:"╿"},block:{thumb:"█",track:"░"},bold:{lowerThumb:"╿",thumb:"│",track:"┃",upperThumb:"╽"},classic:{thumb:"┃",track:"|"},dots:{thumb:"●",track:"·"},double:{thumb:"┃",track:"║"},doubleSingle:{lowerThumb:"╽",thumb:"┃",track:"│",upperThumb:"╿"},line:{thumb:"│",track:" "},round:{lowerThumb:"╽",thumb:"┃",track:"│",upperThumb:"╿"},single:{lowerThumb:"╽",thumb:"┃",track:"│",upperThumb:"╿"},singleDouble:{thumb:"┃",track:"║"},thick:{thumb:"┃",track:"╏"}},wf={arrow:{bottomLeft:"└",bottomRight:"┘",topLeft:"┌",topRight:"┐"},bold:{bottomLeft:"┗",bottomRight:"┛",topLeft:"┏",topRight:"┓"},classic:{bottomLeft:"+",bottomRight:"+",topLeft:"+",topRight:"+"},double:{bottomLeft:"╚",bottomRight:"╝",topLeft:"╔",topRight:"╗"},doubleSingle:{bottomLeft:"╘",bottomRight:"╛",topLeft:"╒",topRight:"╕"},round:{bottomLeft:"╰",bottomRight:"╯",topLeft:"╭",topRight:"╮"},single:{bottomLeft:"└",bottomRight:"┘",topLeft:"┌",topRight:"┐"},singleDouble:{bottomLeft:"╙",bottomRight:"╜",topLeft:"╓",topRight:"╖"}},Ffe=e=>bf[typeof e=="string"?e:"single"]??bf.single??{thumb:"┃",track:"│"},Qfe=e=>wf[typeof e=="string"?e:"single"]??wf.single??{bottomLeft:"└",bottomRight:"┘",topLeft:"┌",topRight:"┐"},UL=({autoHide:e=!1,color:i,contentHeight:n,dimColor:o,placement:a="right",scrollOffset:t,style:s,thumbChar:r,trackChar:u,viewportHeight:d})=>{const l=D.useMemo(()=>{const p=Math.max(n,d);if(e&&p<=d)return null;const f=Ffe(s),w=r??f.thumb,v=u??f.track,j=d*2,C=Math.min(d/p,1),y=Math.max(2,Math.round(j*C)),k=p-d,S=k>0?Math.min(Math.max(t/k,0),1):0,J=j-y,T=Math.round(S*J),M=T+y,he=[];for(let Je=0;Je<d;Je+=1){const Se=Je*2,Le=Je*2+1,Xe=Se>=T&&Se<M,A=Le>=T&&Le<M;Xe&&A?he.push(w):Xe&&!A?he.push(f.lowerThumb??w):!Xe&&A?he.push(f.upperThumb??w):he.push(v)}return he},[n,d,t,s,r,u,e]);if(l===null)return null;if(a==="inset")return Y.jsx(_,{flexDirection:"column",flexShrink:0,width:1,children:l.map((p,f)=>Y.jsx(B,{color:i,dimColor:o,children:p},f))});const g=Qfe(s),h=a==="left"?g.topLeft:g.topRight,c=a==="left"?g.bottomLeft:g.bottomRight;return Y.jsxs(_,{flexDirection:"column",flexShrink:0,width:1,children:[Y.jsx(B,{color:i,dimColor:o,children:h}),l.map((p,f)=>Y.jsx(B,{color:i,dimColor:o,children:p},f)),Y.jsx(B,{color:i,dimColor:o,children:c})]})},VL=({children:e,debug:i=!1,followOutput:n=!1,followThreshold:o=3,keyboard:a=!1,onContentHeightChange:t,onItemHeightChange:s,onReachEnd:r,onReachStart:u,onScroll:d,onViewportSizeChange:l,overscan:g,reachThreshold:h=5,ref:c,scrollbar:p=!1,scrollbarColor:f,scrollbarStyle:w="line",vimBindings:v=!1,virtualize:j,...C})=>{const[y,k,S]=Hg(0),J=D.useRef(null),T=D.useRef(0),M=D.useRef(0),[he,Je]=D.useState(0),[Se,Le]=D.useState(0),Xe=D.useRef(!1),A=D.useRef(!1),$=D.useCallback(()=>Math.max(0,T.current-M.current),[]),P=D.useCallback(E=>{const ne=$();r&&E>=ne-h&&!Xe.current?(Xe.current=!0,r()):E<ne-h&&(Xe.current=!1),u&&E<=h&&!A.current?(A.current=!0,u()):E>h&&(A.current=!1)},[r,u,h,$]),W=D.useCallback(E=>{E!==S()&&(k(E),d?.(E),P(E))},[S,k,d,P]),H=D.useCallback((E,ne)=>{const Ae=S()>=$()-o;if(T.current=E,Je(E),t?.(E,ne),n&&Ae&&E>ne){const ii=Math.max(0,E-M.current);W(ii)}else{const ii=Math.max(0,E-M.current);S()>ii&&W(ii)}},[t,n,o,S,$,W]),N=D.useCallback((E,ne)=>{M.current=E.height,Le(E.height),l?.(E,ne)},[l]),X=D.useCallback(E=>{if(typeof E!="number"||Number.isNaN(E))return;const ne=Math.max(0,T.current-M.current),Ae=Math.max(0,Math.min(S()+E,ne));W(Ae)},[S,W]),G=D.useCallback(E=>{if(typeof E!="number"||Number.isNaN(E))return;const ne=Math.max(0,T.current-M.current),Ae=Math.max(0,Math.min(E,ne));W(Ae)},[W]),I=D.useCallback(()=>{const E=$();W(E)},[$,W]),V=D.useCallback(()=>{W(0)},[W]),te=D.useCallback(()=>M.current,[]);return Afe({getViewportHeight:te,isActive:a,scrollBy:X,scrollToBottom:I,scrollToTop:V,vimBindings:v}),D.useImperativeHandle(c,()=>({getBottomOffset:$,getContentHeight:()=>T.current,getItemHeight:E=>J.current?.getItemHeight(E)??0,getItemPosition:E=>J.current?.getItemPosition(E)??null,getScrollOffset:S,getViewportHeight:()=>M.current,remeasure:()=>J.current?.remeasure(),remeasureItem:E=>J.current?.remeasureItem(E),scrollBy:X,scrollTo:G,scrollToBottom:I,scrollToTop:V}),[$,S,X,G,I,V]),p&&he>Se&&Se>0?Y.jsxs(_,{flexDirection:"row",flexGrow:C.flexGrow,flexShrink:C.flexShrink,overflow:"hidden",children:[Y.jsx(mf,{children:e,debug:i,onContentHeightChange:H,onItemHeightChange:s,onViewportSizeChange:N,overscan:g,ref:J,scrollOffset:y,virtualize:j,...C,flexGrow:1}),Y.jsx(UL,{color:f,contentHeight:he,placement:"inset",scrollOffset:y,style:w,viewportHeight:Se})]}):Y.jsx(mf,{children:e,debug:i,onContentHeightChange:H,onItemHeightChange:s,onViewportSizeChange:N,overscan:g,ref:J,scrollOffset:y,virtualize:j,...C})},Mg=({backgroundColor:e,borderColor:i="cyan",borderStyle:n="round",children:o,columns:a,footer:t,maxHeight:s=.8,paddingX:r=2,paddingY:u=1,rows:d,scrollbarStyle:l="block",scrollRef:g,title:h,visible:c=!0,width:p=60})=>{const f=QL(),{isLoading:w,palette:v}=Yfe(),j=D.useRef(null),C=g??j;if(!c)return null;const y=a??(f.columns||80),k=d??(f.rows||24),S=e??(w?"black":v?.background??"black"),J=s<=1?Math.floor(k*s):Math.min(s,k-2),T=typeof h=="string"?Y.jsx(_,{marginBottom:1,children:Y.jsx(B,{bold:!0,color:i,children:h})}):h??null;return Y.jsx(_,{alignItems:"center",height:k,justifyContent:"center",position:"absolute",width:y,children:Y.jsxs(_,{backgroundColor:S,borderBackgroundColor:S,borderColor:i,borderStyle:n,flexDirection:"column",maxHeight:J,opaque:!0,paddingY:u,width:Math.min(p,y-4),children:[T!=null&&Y.jsx(_,{flexShrink:0,paddingX:r,children:T}),Y.jsx(VL,{flexGrow:1,flexShrink:1,paddingX:r,ref:C,scrollbar:!0,scrollbarColor:i,scrollbarStyle:l,children:o}),t!=null&&Y.jsx(_,{alignItems:"center",flexDirection:"column",flexShrink:0,marginTop:1,paddingX:r,children:t})]})})},eC=()=>D.useContext(DY),jf=({autoExitSeconds:e,onCancel:i,visible:n})=>{const{exit:o}=eC(),[a,t]=D.useState(e||3),s=D.useRef(null),r=D.useRef(0);D.useEffect(()=>{if(!n)return;const d=e||3;t(d),r.current=Date.now();let l=d;return s.current=setInterval(()=>{l-=1,l<=0?(s.current&&(clearInterval(s.current),s.current=null),t(0),o()):t(l)},1e3),()=>{s.current&&(clearInterval(s.current),s.current=null)}},[n,e,o]);const u=D.useCallback(()=>{s.current&&(clearInterval(s.current),s.current=null),i()},[i]);return tp((d,l)=>{Date.now()-r.current<200||(d==="q"?o():u())},{isActive:n}),Y.jsx(Mg,{backgroundColor:"#1e1e1e",footer:Y.jsxs(B,{dimColor:!0,children:["Press"," ",Y.jsx(B,{bold:!0,color:"white",children:"q"})," ","to exit,"," ",Y.jsx(B,{bold:!0,color:"white",children:"any key"})," ","to stay"]}),title:`Exiting in ${a}…`,visible:n,width:50,children:Y.jsx(B,{dimColor:!0,children:"Stay to explore the results interactively."})})},Wfe=e=>{if(e.startsWith("⚠"))return"yellow";e.startsWith("── ")||e.startsWith("[dry-run]")},Ife=({focused:e,item:i,scrollRef:n})=>{const o=e?"white":"gray";return i?Y.jsxs(_,{borderColor:o,borderStyle:"single",flexDirection:"column",flexGrow:1,children:[Y.jsx(_,{flexShrink:0,paddingTop:1,paddingX:2,children:Y.jsx(B,{bold:!0,color:"white",children:i.entry.title})}),Y.jsx(_,{flexShrink:0,paddingBottom:1,paddingX:2,children:Y.jsx(B,{dimColor:!0,children:i.entry.description})}),Y.jsx(VL,{flexGrow:1,flexShrink:1,paddingX:2,ref:n,scrollbar:!0,scrollbarColor:"gray",scrollbarStyle:"block",children:Y.jsxs(_,{flexDirection:"column",children:[Y.jsx(B,{dimColor:!0,children:"── What will change ──"}),Y.jsx(B,{}),i.preview.length===0&&Y.jsx(B,{dimColor:!0,children:"(no preview available)"}),i.preview.map((a,t)=>{const s=Wfe(a);return a===""?Y.jsx(B,{},`blank-${String(t)}`):Y.jsx(B,{color:s,children:a},`${String(t)}-${a.slice(0,20)}`)})]})})]}):Y.jsx(_,{alignItems:"center",borderColor:"gray",borderStyle:"single",flexDirection:"column",flexGrow:1,justifyContent:"center",children:Y.jsx(B,{dimColor:!0,children:"No migration selected"})})},_fe=({checked:e,isSelected:i,item:n})=>{const o=e?"☑":"☐",a=n.preview.length;return Y.jsxs(_,{flexShrink:0,height:1,children:[Y.jsx(B,{children:i?">":" "}),Y.jsxs(B,{color:e?"white":"gray",children:[" ",o," "]}),Y.jsx(_,{flexGrow:1,children:Y.jsx(B,{bold:i,inverse:i,wrap:"truncate",children:n.entry.title})}),Y.jsxs(B,{dimColor:!0,children:[" ",a," ","change",a===1?"":"s"," "]})]})},zfe=({checkedItems:e,focused:i,isDryRun:n,items:o,scrollOffset:a,selectedIndex:t,viewportHeight:s})=>{const r=i?"white":"gray",u=o.filter(h=>e.has(h.entry.id)).length,d=o.map((h,c)=>Y.jsx(_fe,{checked:e.has(h.entry.id),isSelected:c===t,item:h},h.entry.id)),l=o.length,g=l>s&&s>0;return Y.jsxs(_,{borderColor:r,borderStyle:"single",flexDirection:"column",flexGrow:1,children:[Y.jsxs(_,{flexShrink:0,gap:1,paddingX:1,children:[Y.jsx(B,{bold:!0,inverse:!0,children:" MIGRATE "}),Y.jsxs(B,{wrap:"truncate",children:[o.length," ","applicable"]}),u>0&&Y.jsxs(B,{dimColor:!0,children:[" — ",u," selected"]}),n&&Y.jsx(B,{color:"yellow",children:" (dry-run)"})]}),Y.jsxs(_,{flexDirection:"row",flexGrow:1,overflow:"hidden",children:[Y.jsx(_,{flexDirection:"column",flexGrow:1,overflow:"hidden",paddingLeft:1,children:Y.jsx(_,{flexDirection:"column",marginTop:-a,children:d})}),g&&Y.jsx(_,{flexShrink:0,marginLeft:1,marginRight:1,children:Y.jsx(UL,{contentHeight:l,placement:"inset",scrollOffset:a,style:"block",viewportHeight:s})})]})]})},Kfe=100,qfe=40,Ufe=10,Vfe=({autoExitSeconds:e=0,isDryRun:i,store:n})=>{const{exit:o}=eC(),{columns:a,rows:t}=QL(),s=D.useSyncExternalStore(n.subscribe,n.getSnapshot),[r,u]=D.useState(!1),[d,l]=D.useState(!1),[g,h]=D.useState(!1),[c,p]=D.useState(0),f=D.useRef(null),w=D.useRef(null),v=D.useRef(null),j=s.items[s.selectedIndex]??null,C=Math.max(1,t-6),y=D.useCallback(A=>{p($=>A>=$+C?Math.max(0,A-C+1):A<$?Math.max(0,A):$)},[C]);if(D.useEffect(()=>{w.current?.scrollToTop()},[j?.entry.id]),tp((A,$)=>{if(A==="c"&&$.ctrl){o();return}if(!g){if(d){A==="u"||$.return?(l(!1),n.startApply(),o(n.getCheckedItems())):$.escape||A==="q"?l(!1):$.downArrow||A==="j"?v.current?.scrollBy(1):($.upArrow||A==="k")&&v.current?.scrollBy(-1);return}if(r){$.escape||A==="?"?u(!1):A==="q"?(u(!1),h(!0)):$.downArrow||A==="j"?f.current?.scrollBy(1):($.upArrow||A==="k")&&f.current?.scrollBy(-1);return}if(A==="?"){u(!0);return}if(A==="q"){h(!0);return}if($.tab){n.setFocusedPanel(s.focusedPanel==="list"?"detail":"list");return}if(s.focusedPanel==="list"){if($.downArrow||A==="j"){const P=Math.min(s.selectedIndex+1,s.items.length-1);n.setSelectedIndex(P),y(P);return}if($.upArrow||A==="k"){const P=Math.max(s.selectedIndex-1,0);n.setSelectedIndex(P),y(P);return}if($.pageDown){const P=Math.min(s.selectedIndex+10,s.items.length-1);n.setSelectedIndex(P),y(P);return}if($.pageUp){const P=Math.max(s.selectedIndex-10,0);n.setSelectedIndex(P),y(P);return}if($.home){n.setSelectedIndex(0),p(0);return}if($.end){const P=s.items.length-1;n.setSelectedIndex(P),y(P);return}if(A===" "||$.return){j&&n.toggleCheck(j.entry.id);return}if(A==="a"){n.toggleAll();return}if(A==="u"&&!i&&s.checkedItems.size>0){l(!0);return}$.rightArrow&&n.setFocusedPanel("detail");return}if(s.focusedPanel==="detail"){if($.escape||$.leftArrow){n.setFocusedPanel("list");return}if($.downArrow||A==="j"){w.current?.scrollBy(1);return}if($.upArrow||A==="k"){w.current?.scrollBy(-1);return}if($.pageDown){w.current?.scrollBy(10);return}if($.pageUp){w.current?.scrollBy(-10);return}if($.home){w.current?.scrollToTop();return}$.end&&w.current?.scrollToBottom()}}},{isActive:!0}),a<qfe||t<Ufe)return Y.jsx(_,{alignItems:"center",height:t,justifyContent:"center",width:a,children:Y.jsxs(B,{color:"yellow",children:["Terminal too small (",a,"x",t,")"]})});const k=a>=Kfe,S=[Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"q"}),Y.jsx(B,{dimColor:!0,children:"QUIT"})]},"q"),Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"?"}),Y.jsx(B,{dimColor:!0,children:"HELP"})]},"?"),Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"↑↓"}),Y.jsx(B,{dimColor:!0,children:"NAV"})]},"nav"),Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"Space"}),Y.jsx(B,{dimColor:!0,children:"CHECK"})]},"sp"),Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"a"}),Y.jsx(B,{dimColor:!0,children:"ALL"})]},"a")];!i&&s.checkedItems.size>0&&S.push(Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"green",children:"u"}),Y.jsx(B,{dimColor:!0,children:"APPLY"})]},"u")),S.push(Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"Tab"}),Y.jsx(B,{dimColor:!0,children:"PANEL"})]},"tab"));const J=Y.jsx(_,{borderBottom:!1,borderColor:"gray",borderLeft:!1,borderRight:!1,borderStyle:"single",flexShrink:0,children:Y.jsx(_,{flexWrap:"wrap",gap:2,paddingX:1,children:S})}),T=Y.jsxs(Mg,{footer:Y.jsxs(B,{dimColor:!0,children:[Y.jsx(B,{bold:!0,color:"white",children:"↑↓"})," scroll ",Y.jsx(B,{bold:!0,color:"white",children:"?"}),"/",Y.jsx(B,{bold:!0,color:"white",children:"Esc"})," close"]}),scrollRef:f,title:"KEYBOARD SHORTCUTS",visible:r,width:52,children:[Y.jsxs(_,{flexDirection:"column",marginBottom:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"NAVIGATION"}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" ↑/k"}),Y.jsx(B,{dimColor:!0,children:" Move up"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" ↓/j"}),Y.jsx(B,{dimColor:!0,children:" Move down"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" Tab"}),Y.jsx(B,{dimColor:!0,children:" Switch panel"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" →/←"}),Y.jsx(B,{dimColor:!0,children:" Focus detail/list"})]})]}),Y.jsxs(_,{flexDirection:"column",marginBottom:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"SELECTION"}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" Space"}),Y.jsx(B,{dimColor:!0,children:" Toggle migration"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" a"}),Y.jsx(B,{dimColor:!0,children:" Toggle all"})]})]}),Y.jsxs(_,{flexDirection:"column",children:[Y.jsx(B,{bold:!0,color:"white",children:"ACTIONS"}),!i&&Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" u"}),Y.jsx(B,{dimColor:!0,children:" Apply selected migrations"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" q"}),Y.jsx(B,{dimColor:!0,children:" Quit"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" ?"}),Y.jsx(B,{dimColor:!0,children:" Toggle help"})]})]})]}),M=n.getCheckedItems(),he=Y.jsx(_,{alignItems:"center",flexDirection:"column",children:Y.jsxs(B,{dimColor:!0,children:["Press ",Y.jsx(B,{bold:!0,color:"white",children:"u"})," or ",Y.jsx(B,{bold:!0,color:"white",children:"Enter"})," to confirm, ",Y.jsx(B,{bold:!0,color:"white",children:"Esc"})," to cancel"]})}),Je=Y.jsx(Mg,{footer:he,scrollRef:v,title:`Apply ${String(M.length)} migration${M.length===1?"":"s"}?`,visible:d,width:70,children:M.map(A=>Y.jsxs(_,{gap:1,children:[Y.jsxs(B,{children:[" ",A.entry.title]}),Y.jsxs(B,{dimColor:!0,children:["(",A.preview.length," ","change",A.preview.length===1?"":"s",")"]})]},A.entry.id))}),Se=Y.jsx(zfe,{checkedItems:s.checkedItems,focused:s.focusedPanel==="list",isDryRun:i,items:s.items,scrollOffset:c,selectedIndex:s.selectedIndex,viewportHeight:C}),Le=Y.jsx(Ife,{focused:s.focusedPanel==="detail",item:j,scrollRef:w});if(k){const A=Math.floor(a*.55);return Y.jsxs(_,{flexDirection:"column",height:t,width:a,children:[Y.jsxs(_,{flexDirection:"row",flexGrow:1,children:[Y.jsx(_,{flexGrow:1,children:Se}),Y.jsx(_,{width:A,children:Le})]}),J,Je,Y.jsx(jf,{autoExitSeconds:e||3,onCancel:()=>{h(!1)},visible:g}),T]})}const Xe=Math.floor(t*.45);return Y.jsxs(_,{flexDirection:"column",height:t,width:a,children:[Y.jsx(_,{height:Xe,children:Se}),Y.jsx(_,{flexGrow:1,children:Le}),J,Je,Y.jsx(jf,{autoExitSeconds:e||3,onCancel:()=>{h(!1)},visible:g}),T]})},iC=[".lintstagedrc.json",".lintstagedrc"],nC=[".lintstagedrc.yaml",".lintstagedrc.yml",".lintstagedrc.mjs","lint-staged.config.mjs",".lintstagedrc.cjs","lint-staged.config.cjs",".lintstagedrc.js","lint-staged.config.js",".lintstagedrc.ts","lint-staged.config.ts",".lintstagedrc.mts","lint-staged.config.mts",".lintstagedrc.cts","lint-staged.config.cts"],oC=[...iC,...nC],eme=[/^((?:[A-Z_][A-Z0-9_]*(?:=\S*)?\s+)*)(pnpm|pnpm exec|npx|yarn|yarn run|npm exec|npm run|bunx|bun run|bun x)\s+lint-staged\b/,/^((?:[A-Z_][A-Z0-9_]*(?:=\S*)?\s+)*)lint-staged\b/],aC=[".nano-staged.json",".nanostagedrc"],tC=[".nano-staged.mjs",".nano-staged.cjs",".nano-staged.js","nano-staged.config.mjs","nano-staged.config.cjs","nano-staged.config.js","nano-staged.config.mts","nano-staged.config.cts","nano-staged.config.ts"],sC=[...aC,...tC],ime=[/^((?:[A-Z_][A-Z0-9_]*(?:=\S*)?\s+)*)(pnpm|pnpm exec|npx|yarn|yarn run|npm exec|npm run|bunx|bun run|bun x)\s+nano-staged\b/,/^((?:[A-Z_][A-Z0-9_]*(?:=\S*)?\s+)*)nano-staged\b/],rC=["husky","lint-staged","nano-staged"],nme=/\(is-ci \|\| husky \|\| exit 0\)\s*&&\s*/g,ome=/\bhusky(?:\s+install)?\s*&&\s*/g,ame=/\s*&&\s*husky(?:\s+install)?/g,tme=/\s*\|\|\s*husky(?:\s+install)?/g,sme=[nme,ome,ame,tme],uC=e=>{if(e==="husky"||e==="husky install")return;let i=e;for(const n of sme)i=i.replace(n,"");return i=i.trim(),i===e?e:i||void 0},rme="config.json",Sl=1,ume=new Set(["alwaysRun","args","builtin","entry","exclude","excludeTypes","fail","files","id","name","passFilenames","types","typesOr","verbose"]),dme=new Set(["failFast","skipInCI","stages","version"]),lme=["args","exclude","excludeTypes","files","passFilenames","types","typesOr"],dC=(e,i)=>L(e,i,rme),Pg=e=>e!==null&&typeof e=="object"&&!Array.isArray(e),sr=e=>{if(!Array.isArray(e))return;const i=[];for(const n of e){if(typeof n!="string")return;i.push(n)}return i},os=e=>typeof e=="boolean"?e:void 0,ha=e=>typeof e=="string"&&e.length>0?e:void 0,gme=(e,i,n)=>{if(!Pg(e))throw new TypeError("hook entry must be an object");if(typeof e.id!="string"||e.id.length===0)throw new TypeError("hook entry is missing `id`");const o={id:e.id},a=os(e.alwaysRun);a!==void 0&&(o.alwaysRun=a);const t=sr(e.args);t&&(o.args=t);const s=ha(e.builtin);s&&(o.builtin=s);const r=ha(e.entry);r&&(o.entry=r);const u=ha(e.exclude);u&&(o.exclude=u);const d=sr(e.excludeTypes);d&&(o.excludeTypes=d);const l=ha(e.fail);l&&(o.fail=l);const g=ha(e.files);g&&(o.files=g);const h=ha(e.name);h&&(o.name=h);const c=os(e.passFilenames);c!==void 0&&(o.passFilenames=c);const p=sr(e.types);p&&(o.types=p);const f=sr(e.typesOr);f&&(o.typesOr=f);const w=os(e.verbose);if(w!==void 0&&(o.verbose=w),[o.builtin,o.entry,o.fail].filter(v=>v!==void 0).length!==1)throw new TypeError(`hook "${o.id}" must set exactly one of \`builtin\`, \`entry\`, \`fail\``);if(o.fail!==void 0){const v=lme.filter(j=>o[j]!==void 0);if(v.length>0)throw new TypeError(`hook "${o.id}" is a \`fail\` entry — remove ${v.join(", ")} (filters do not apply)`)}for(const v of Object.keys(e))ume.has(v)||i.push({hookId:o.id,message:`unknown field "${v}" ignored`,stage:n});return o},hme=(e,i)=>{if(!Pg(e))throw new TypeError("hook config must be an object");if(e.version!==Sl)throw new TypeError(`unsupported hook config version: expected ${Sl}, got ${String(e.version)}`);if(!Pg(e.stages))throw new TypeError("hook config is missing `stages` map");const n={};for(const[s,r]of Object.entries(e.stages)){if(!Array.isArray(r))throw new TypeError(`hook config: stage "${s}" must be an array`);n[s]=r.map(u=>gme(u,i,s))}const o={stages:n,version:Sl},a=os(e.failFast);a!==void 0&&(o.failFast=a);const t=os(e.skipInCI);t!==void 0&&(o.skipInCI=t);for(const s of Object.keys(e))dme.has(s)||i.push({message:`unknown top-level field "${s}" ignored`});return o},cme=(e,i=ap,n)=>{const o=dC(e,i);if(!Z(o))return;const a=z(o);let t;try{t=JSON.parse(a)}catch(s){const r=s instanceof Error?s.message:String(s);throw new TypeError(`failed to parse ${o}: ${r}`,{cause:s})}return hme(t,[])},vSe=(e,i,n)=>{const o=dC(e,i);He(o,`${JSON.stringify(n,void 0,4)}
172
+ </html>`;let To;const v0e=()=>{for(const e of p0e)try{if(Eo(e).isFile())return e}catch{}},y0e=()=>{if(To!==void 0&&!process.env.VIS_DASHBOARD_NO_CACHE)return To;const e=v0e();if(!e)return To=vf,To;try{const i=nY(e,"utf8");return To=i,i}catch{return To=vf,To}},f0e=e=>{if(e.length===0)return;const i=[...e].sort((o,a)=>o-a),n=Math.floor(i.length/2);return i.length%2===0?(i[n-1]+i[n])/2:i[n]},m0e=e=>{const i=new Map;for(const o of e)if(Array.isArray(o.tasks))for(const a of o.tasks){if(!a.taskId)continue;const t=i.get(a.taskId)??{durations:[],failures:0,hits:0,misses:0,project:a.target?.project??"",runs:0,target:a.target?.target??"",taskId:a.taskId};a.cacheStatus==="HIT"||a.cacheStatus==="REMOTE_HIT"?(t.runs+=1,t.hits+=1):a.cacheStatus==="MISS"&&(t.runs+=1,t.misses+=1,typeof a.duration=="number"&&a.duration>0&&t.durations.push(a.duration),a.exitCode!==void 0&&a.exitCode!==0&&(t.failures+=1)),i.set(a.taskId,t)}const n=new Map;for(const[o,a]of i){const t=a.durations.length===0?0:a.durations.reduce((s,r)=>s+r,0)/a.durations.length;n.set(o,{averageDurationMs:t,failures:a.failures,hitRate:a.runs===0?0:a.hits/a.runs,hits:a.hits,misses:a.misses,project:a.project,runs:a.runs,target:a.target,taskId:o,timeSavedMs:t*a.hits})}return n},b0e=e=>{const i=e,n=[...i].sort((v,j)=>(v.startTime??"").localeCompare(j.startTime??""));let o=0,a=0,t=0,s=0,r=0,u=0;const d=[],l=[],g=[];for(const v of n){const j=v.stats??{};o+=j.total??0,a+=j.succeeded??0,t+=j.failed??0,s+=j.cached??0,r+=j.skipped??0,typeof v.duration=="number"&&v.duration>0&&(u+=v.duration,d.push(v.duration),v.startTime&&g.push({timestamp:v.startTime,value:v.duration})),(j.total??0)>0&&v.startTime&&l.push({timestamp:v.startTime,value:(j.cached??0)/(j.total??1)})}const h=[...m0e(n).values()],c=h.filter(v=>v.averageDurationMs>0).sort((v,j)=>j.averageDurationMs-v.averageDurationMs).slice(0,10),p=h.filter(v=>v.runs>=2).sort((v,j)=>j.timeSavedMs-v.timeSavedMs||j.hitRate-v.hitRate).slice(0,10),f=h.filter(v=>v.runs>=3&&v.hits>0&&v.misses>0).sort((v,j)=>j.misses/j.runs-v.misses/v.runs).slice(0,10),w=h.reduce((v,j)=>v+j.timeSavedMs,0);return{averageRunDurationMs:d.length===0?null:d.reduce((v,j)=>v+j,0)/d.length,cacheHitRate:s+a+t===0?null:s/(s+a+t),durationOverTime:g,hitRateOverTime:l,medianRunDurationMs:f0e(d)??null,mostCachedTasks:p,mostInvalidatedTasks:f,slowestTasks:c,totals:{cached:s,estimatedTimeSavedMs:w,failed:t,runs:i.length,skipped:r,succeeded:a,tasks:o,totalDurationMs:u}}},yf=(e,i)=>{const n=i.replaceAll(/[^\w.\-:]/g,"");if(n.length===0||n!==i)return;const o=L(fo(e),`${n}.json`);if(Z(o))try{return Qe(o)}catch{return}const a=im(e);if(Z(a))try{const t=Qe(a);return t.id===n?t:void 0}catch{return}},w0e=async e=>{const i=new Set,n=fo(e);try{await iY(n,{recursive:!0})}catch{}let o,a;const t=r=>{a=r,o&&clearTimeout(o),o=setTimeout(()=>{if(o=void 0,!a)return;const u=a;a=void 0;for(const d of i)try{d(u)}catch{}},200)};let s;try{s=oY(n,(r,u)=>{if(!u||typeof u!="string"||!u.endsWith(".json"))return;const d=u.slice(0,-5);t({id:d,type:"run-changed"})})}catch{s=void 0}return{close:()=>{o&&clearTimeout(o),s?.close(),i.clear()},subscribe:r=>(i.add(r),()=>{i.delete(r)})}},j0e=(e,i)=>{const n=new tx;return n.get("/",o=>o.html(y0e())),n.get("/api/overview",o=>{const a=ns(e.workspaceRoot),t=b0e(a),s=l0e(e.workspaceRoot,{minRuns:2},a);return o.json({flaky:s,metrics:t})}),n.get("/api/runs",o=>{const a=ns(e.workspaceRoot).filter(t=>typeof t.id=="string"&&typeof t.startTime=="string"&&typeof t.endTime=="string"&&typeof t.duration=="number").map(t=>{const s=t.stats,r=s?{cached:typeof s.cached=="number"?s.cached:void 0,failed:typeof s.failed=="number"?s.failed:void 0,skipped:typeof s.skipped=="number"?s.skipped:void 0,succeeded:typeof s.succeeded=="number"?s.succeeded:void 0,total:typeof s.total=="number"?s.total:void 0}:void 0;return{duration:t.duration,endTime:t.endTime,id:t.id,startTime:t.startTime,stats:r}}).sort((t,s)=>s.startTime.localeCompare(t.startTime));return o.json({runs:a})}),n.get("/api/runs/:id",o=>{const a=yf(e.workspaceRoot,o.req.param("id"));return a?o.json(a):o.json({error:"Not found"},404)}),n.get("/api/runs/:runId/tasks/:taskId/diff",o=>{const a=yf(e.workspaceRoot,o.req.param("runId"));if(!a)return o.json({error:"Run not found"},404);const t=o.req.param("taskId"),s=a.tasks?.find(d=>d.taskId===t);if(!s)return o.json({error:"Task not found"},404);const r=ns(e.workspaceRoot),u=c0e(r,a.id,s);return o.json(u)}),n.get("/api/cache",async o=>{if(!Z(e.cacheDirectory))return o.json({directory:e.cacheDirectory,entries:[],exists:!1,totalBytes:0});const a=await po(e.cacheDirectory),t=a.reduce((r,u)=>r+u.sizeBytes,0),s=Date.now();return o.json({directory:e.cacheDirectory,entries:a.map(r=>({ageMs:s-r.mtimeMs,hash:r.hash,mtimeIso:new Date(r.mtimeMs).toISOString(),sizeBytes:r.sizeBytes})),exists:!0,totalBytes:t})}),n.get("/api/environment",o=>o.json({arch:process.arch,cacheDirectory:e.cacheDirectory,node:process.version,platform:process.platform,workspaceRoot:e.workspaceRoot})),n.get("/api/events",o=>lx(o,async a=>{const t=[];let s;const r=i(d=>{if(t.push(d),s){const l=s;s=void 0,l()}});a.onAbort(()=>{if(r(),s){const d=s;s=void 0,d()}}),await a.writeSSE({data:JSON.stringify({ok:!0}),event:"ready"});const u=15e3;for(;!a.aborted;){if(t.length===0){const l=a.sleep(u),g=new Promise(h=>{s=h});if(await Promise.race([l,g]),a.aborted)break;if(t.length===0){await a.writeSSE({data:"",event:"heartbeat"});continue}}const d=t.shift();await a.writeSSE({data:JSON.stringify(d),event:"change"})}})),n},k0e=async e=>{const i=await w0e(e.workspaceRoot),n=j0e(e,i.subscribe),o=SJ({fetch:n.fetch,hostname:e.host,port:e.port});await new Promise((r,u)=>{o.once("listening",()=>{r()}),o.once("error",d=>{u(d)})});const a=o.address(),t=typeof a=="object"&&a?a.port:e.port,s=`http://${e.host==="0.0.0.0"||e.host==="::"||e.host==="::0"?"localhost":e.host}:${String(t)}`;return{close:()=>new Promise((r,u)=>{i.close(),o.close(d=>{d?u(d):r()})}),port:t,url:s}},S0e=e=>{const{platform:i}=process,[n,o]=i==="darwin"?["open",[e]]:i==="win32"?["cmd",["/c","start","",e]]:["xdg-open",[e]];uY(n,o,a=>{})},L0e={description:"Open a browser dashboard with cache, run history, and cache-miss diffs",examples:[["vis dashboard","Start the dashboard on a random port (server only — does not open a browser)"],["vis dashboard --open","Start the dashboard and open it in the default browser"],["vis dashboard --port=7788","Pin the server to a specific port"],["vis dashboard --host=0.0.0.0 --port=7788","Expose the dashboard on all interfaces"]],execute:async({options:e,process:i,visConfig:n,workspaceRoot:o})=>{const a=o??i.cwd,t=ib(a,e.cacheDir,n?.taskRunner?.cacheDirectory),s=typeof e.port=="number"&&Number.isFinite(e.port)?e.port:0,r=typeof e.host=="string"&&e.host.length>0?e.host:"127.0.0.1",u=await k0e({cacheDirectory:t,host:r,port:s,workspaceRoot:a});x.success(`Dashboard listening on ${u.url}`),x.info(`Workspace: ${a}`),x.info(`Cache: ${t}`),x.info("Press Ctrl+C to stop."),e.open===!0&&S0e(u.url),await new Promise(d=>{let l=!1;const g=()=>{l||(l=!0,process.off("SIGINT",g),process.off("SIGTERM",g),(async()=>{try{await u.close()}catch{}finally{d()}})())};process.once("SIGINT",g),process.once("SIGTERM",g)})},group:"Workspace",name:"dashboard",options:[{defaultValue:0,description:"Port to bind the dashboard server to (0 = auto-assign)",name:"port",type:Number},{defaultValue:"127.0.0.1",description:"Host interface to bind to. Default binds to localhost only.",name:"host",type:String},{defaultValue:!1,description:"Open the dashboard in the default browser after starting",name:"open",type:Boolean},{description:"Cache directory to inspect (overrides config and default). Relative paths resolve against the workspace root.",name:"cache-dir",type:String}]},C0e={description:"Deduplicate dependencies using the detected package manager",examples:[["vis dedupe","Run deduplication"],["vis dedupe --check","Preview changes without modifying (CI-friendly)"]],group:"Dependencies",loader:()=>import("./handler9.js"),name:"dedupe",options:[{defaultValue:!1,description:"Preview changes without modifying files (dry-run)",name:"check",type:Boolean}]},Y0e={description:"Lint workspace dependency policies (workspace-protocol, banned-deps, redefine-root, workspace-versions, custom-types, empty-deps, root-private, root-package-manager, root-deps, missing-package-json, dead-workspace-patterns, types-in-deps, similar-deps)",examples:[["vis deps","Run every enabled lint and exit non-zero on failures"],["vis deps --workspace-protocol","Only check that internal deps use workspace:*"],["vis deps --workspace-protocol --fix","Auto-rewrite internal deps to use workspace:*"],["vis deps --redefine-root","Flag deps duplicated between root and child packages"],["vis deps --banned-deps","Flag deps matching policy.bannedDeps in vis config"],["vis deps --workspace-versions","Flag external deps declared at different versions across packages"],["vis deps --workspace-versions --fix","Rewrite drifting deps to the highest sibling version"],["vis deps --workspace-versions --dep react","Limit version-drift check to a single dep"],["vis deps --workspace-versions --resolve catalog --fix","Rewrite drifting deps to catalog: when a catalog already pins them"],["vis deps --workspace-versions --resolve catalog --propose-min 3","Suggest new catalog entries for deps ≥3 packages already agree on"],["vis deps --custom-types","Flag drift in engines.{node,pnpm}, packageManager, volta.{node,pnpm,yarn}, devEngines"],["vis deps --custom-types --fix","Align all engines/packageManager/volta versions to the highest sibling"],["vis deps --empty-deps --fix","Drop empty `dependencies` / `devDependencies` / etc. blocks across the workspace"],["vis deps --root-private --fix",'Ensure the workspace root package.json has "private": true'],["vis deps --root-package-manager","Ensure the root package.json declares a `packageManager` field"],["vis deps --root-deps --fix","Move runtime deps off the private workspace root into devDependencies"],["vis deps --missing-package-json","Flag workspace dirs that don't contain a package.json"],["vis deps --dead-workspace-patterns --fix","Drop workspace patterns that match zero packages"],["vis deps --types-in-deps --fix","Move @types/* out of dependencies on private packages"],["vis deps --similar-deps","Flag drift across related dep families (react+react-dom, @babel/*, …)"],["vis deps --ban left-pad --ban request","One-off ban: flag any package declaring left-pad or request"],["vis deps --pin react@18.2.0","One-off pin: flag any package declaring react at a different version"],["vis deps --format json","Emit findings as JSON for CI / editor integrations"]],group:"Security & Health",loader:()=>import("./handler68.js"),name:"deps",options:[{defaultValue:!1,description:"Lint that internal deps use the workspace: protocol",name:"workspace-protocol",type:Boolean},{defaultValue:!1,description:"Lint that no child re-declares a dep already pinned in the workspace root",name:"redefine-root",type:Boolean},{defaultValue:!1,description:"Lint deps against policy.bannedDeps in vis config",name:"banned-deps",type:Boolean},{defaultValue:!1,description:"Lint that all packages declare external deps at the same version",name:"workspace-versions",type:Boolean},{defaultValue:!1,description:"Lint engines.{node,pnpm}, packageManager, volta.*, devEngines.* for drift across packages",name:"custom-types",type:Boolean},{defaultValue:!1,description:"Flag empty dependency blocks (`dependencies: {}`, `devDependencies: {}`, …) across the workspace",name:"empty-deps",type:Boolean},{defaultValue:!1,description:'Ensure the workspace root package.json sets `"private": true`',name:"root-private",type:Boolean},{defaultValue:!1,description:"Ensure the workspace root package.json declares a `packageManager` field",name:"root-package-manager",type:Boolean},{defaultValue:!1,description:"Flag runtime dependencies on the private workspace root (move them to devDependencies)",name:"root-deps",type:Boolean},{defaultValue:!1,description:"Flag workspace directories that lack a package.json",name:"missing-package-json",type:Boolean},{defaultValue:!1,description:"Flag workspace patterns (in `pnpm-workspace.yaml` / `package.json#workspaces`) that match zero packages",name:"dead-workspace-patterns",type:Boolean},{defaultValue:!1,description:"Flag `@types/*` declared in `dependencies` on a private package (should be in devDependencies)",name:"types-in-deps",type:Boolean},{defaultValue:!1,description:"Flag version drift across related dep families (react+react-dom, @babel/*, @storybook/*, …)",name:"similar-deps",type:Boolean},{description:"Restrict --workspace-versions to a single dep",name:"dep",type:String},{description:"Ban a dep name or glob for this run (repeatable). Auto-enables --banned-deps.",multiple:!0,name:"ban",type:String},{description:"Pin a dep to an exact specifier for this run, e.g. react@^18.2.0 (repeatable). Auto-enables --workspace-versions.",multiple:!0,name:"pin",type:String},{description:"Conflict resolution for --workspace-versions: highest, lowest, or catalog (default: highest)",name:"resolve",type:String},{description:"Propose catalog entries for deps ≥N packages already agree on. Activates with --resolve catalog.",name:"propose-min",type:Number},{defaultValue:!1,description:"Auto-fix violations in place (writes package.json files)",name:"fix",type:Boolean},{description:"Specifier used by --fix for workspace-protocol (default: workspace:*)",name:"fix-specifier",type:String},{description:"Output format: human, json, or minimal (default: human)",name:"format",type:String},{defaultValue:!1,description:"Suppress all output except errors",name:"quiet",type:Boolean}]},$0e={alias:"dc",description:"Create or update .devcontainer/devcontainer.json interactively",examples:[["vis devcontainer","Launch interactive devcontainer config editor"],["vis dc","Alias for devcontainer"],["vis devcontainer --template node-pnpm","Start from Node.js + pnpm template"]],group:"Scaffold & Config",loader:()=>import("./handler76.js"),name:"devcontainer",options:[{alias:"t",description:"Start from a template: node, node-pnpm, node-postgres, node-dind, fullstack, python, go, rust, java, devops, minimal, custom",name:"template",type:String},{alias:"o",description:"Output path (default: .devcontainer/devcontainer.json)",name:"output",type:String}]},Vu="Workspace",Z0e={commandPath:["docker"],description:"Build a minimal, cache-friendly Docker context for a focus project + its deps",examples:[["vis docker scaffold --focus=my-app","Generate .vis/docker/workspace for my-app + its deps"],["vis docker scaffold --focus=my-app --include-sources","Also copy focus source trees"],["vis docker scaffold --focus=my-app,other --out=.vis/docker","Focus multiple projects"]],group:Vu,loader:le(()=>import("./handler59.js"),"scaffoldExecute"),name:"scaffold",options:[{description:"Project name(s) to focus on — comma-separated for multiple",name:"focus",type:String},{description:"Output directory for the scaffold (default: .vis/docker)",name:"out",type:String},{defaultValue:!1,description:"Also copy focus project source trees to <out>/sources",name:"include-sources",type:Boolean},{defaultValue:!0,description:"Rewrite the workspace lockfile to drop unfocused projects (use --no-prune-lockfile to copy verbatim)",name:"prune-lockfile",type:Boolean}]},J0e={commandPath:["docker"],description:"Strip unfocused workspace projects from a scaffolded context (run inside a build stage)",examples:[["vis docker prune --context=.vis/docker","Strip unfocused projects inside a build stage"]],group:Vu,loader:le(()=>import("./handler59.js"),"pruneExecute"),name:"prune",options:[{description:"Scaffold root for prune (default: .vis/docker)",name:"context",type:String}]},x0e={argument:{description:"Output path for the Dockerfile (default: ./Dockerfile)",name:"path",type:String},commandPath:["docker"],description:"Generate a multi-stage Dockerfile wired to the scaffold/prune flow (create-only)",examples:[["vis docker init","Generate ./Dockerfile for the detected package manager"],["vis docker init --focus=my-app","Target a specific project's build"],["vis docker init --node=24 --force","Use Node 24 and overwrite without prompting"],["vis docker init --dry-run","Print the Dockerfile instead of writing it"]],group:Vu,loader:le(()=>import("./handler59.js"),"initExecute"),name:"init",options:[{description:"Focus project name for the build filter",name:"focus",type:String},{description:"Node.js version tag for the base image (default: 22)",name:"node",type:String},{defaultValue:!1,description:"Overwrite an existing Dockerfile without prompting",name:"force",type:Boolean},{defaultValue:!1,description:"Print the Dockerfile to stdout instead of writing it",name:"dry-run",type:Boolean}]},T0e={argument:{description:"Dockerfile path(s) to lint (default: ./Dockerfile)",name:"file",type:String},commandPath:["docker"],description:"Lint a Dockerfile with hadolint (downloaded on demand); --fix applies safe autofixes",examples:[["vis docker lint","Lint ./Dockerfile (prompts to download hadolint on first use)"],["vis docker lint apps/web/Dockerfile","Lint a specific Dockerfile"],["vis docker lint --fix","Apply safe autofixes, then report what remains"],["vis docker lint --install --json","Auto-download hadolint and emit JSON"]],group:Vu,loader:le(()=>import("./handler59.js"),"lintExecute"),name:"lint",options:[{defaultValue:!1,description:"Apply safe autofixes, then re-lint and report what remains",name:"fix",type:Boolean},{defaultValue:!1,description:"Download hadolint without prompting if it is missing",name:"install",type:Boolean},{description:"Path to a hadolint config (.hadolint.yaml)",name:"config",type:String},{defaultValue:!1,description:"Emit findings as JSON",name:"json",type:Boolean}]},D0e=[Z0e,J0e,x0e,T0e],B0e={description:"Run a full project health check (outdated, security, duplicates, optimizations)",examples:[["vis doctor","Full project health check"],["vis doctor --fix","Check and auto-apply safe fixes"],["vis doctor --format json","Machine-readable output for CI"],["vis doctor --only security","Only run the security scans"],["vis doctor --skip optimization,runtime","Skip the listed sections"],["vis doctor --quiet","Summary only, no per-section breakdown"],["vis doctor --no-progress","Disable live progress UI (sequential logs)"],["vis doctor --exit-code","Exit with code 1 if security issues found"],["vis doctor --exit-code --strict","Fail on any issue (outdated, duplicates, security)"]],group:"Security & Health",loader:()=>import("./handler70.js"),name:"doctor",options:[{description:"Output format: table or json (default: table). Alias: --json",name:"format",type:String},{defaultValue:!1,description:"Shorthand for --format json",name:"json",type:Boolean},{defaultValue:!1,description:"Exit with code 1 if issues found",name:"exit-code",type:Boolean},{defaultValue:!1,description:"Auto-apply safe fixes (security overrides + codemods, SIGTERM orphans)",name:"fix",type:Boolean},{defaultValue:!1,description:"With --fix: escalate orphan cleanup to SIGKILL / taskkill /F (use when SIGTERM is ignored)",name:"fix-force",type:Boolean},{defaultValue:!1,description:"With --exit-code: also fail on outdated and duplicate deps",name:"strict",type:Boolean},{description:"Comma-separated sections to run: dependencies,security,optimization,runtime",name:"only",type:String},{description:"Comma-separated sections to skip",name:"skip",type:String},{defaultValue:!1,description:"Suppress per-section detail; print summary only",name:"quiet",type:Boolean},{defaultValue:!1,description:"Disable live progress UI (forces sequential logs)",name:"no-progress",type:Boolean},{defaultValue:!1,description:"Bypass the doctor result cache (~/.vis/cache/doctor)",name:"no-cache",type:Boolean},{description:"Comma-separated package name patterns to scope findings (supports * globs, e.g. '@types/*,react')",name:"filter",type:String}]},X0e={description:"Orchestrate detected formatters (prettier, …) across the workspace",examples:[["vis fmt","Apply formatting in place using every detected formatter"],["vis fmt --check","Report files that would change without writing"],["vis fmt --check --format json","Emit findings as JSON for CI / editor integrations"],["vis fmt --check --format sarif","Emit a SARIF 2.1.0 document for code-scanning uploads"],["vis fmt --check --format junit","Emit a JUnit XML report for CI dashboards"],["vis fmt --check --format github","Emit GitHub Actions workflow commands for inline PR annotations"],["vis fmt src/foo.ts src/bar.ts","Format a specific file list"],["vis fmt --quiet","Suppress per-file logs"],["vis fmt --since main","Only format files changed vs the main branch"],["vis fmt --staged","Only format files currently staged in the git index"],["vis fmt --watch","Re-run formatters when watched files change (cache makes incremental --check near-free)"],["vis fmt --check --format sarif --output fmt.sarif","Write the SARIF report to fmt.sarif instead of stdout"]],group:"Lint & Format",loader:()=>import("./handler60.js"),name:"fmt",options:[{defaultValue:!1,description:"Report files that would change without writing",name:"check",type:Boolean},{defaultValue:"human",description:"Output format: human, json, minimal, sarif, junit, or github",name:"format",type:String},{defaultValue:!1,description:"Suppress per-file logs",name:"quiet",type:Boolean},{description:"Only format files changed vs the given git ref (branch, tag, sha)",name:"since",type:String},{defaultValue:!1,description:"Only format files currently staged in the git index",name:"staged",type:Boolean},{description:"Write formatted output to a file path instead of stdout (also accepts `-`/`stdout`/`stderr`)",name:"output",type:String},{defaultValue:!1,description:"Re-run formatters whenever watched files change",name:"watch",type:Boolean}]},H0e={argument:{description:"Template name (or remote source like git://… or npm://…) — omit for interactive picker",name:"template",type:String},description:"Scaffold files from an in-repo template",examples:[["vis generate","Pick a template interactively"],["vis generate package","Run the 'package' template"],["vis generate component -- --name=Button --style=primary","Pre-fill option values"],["vis generate package --to=./packages/new --force","Custom destination + overwrite"],["vis generate package --dry-run","Print planned writes without touching disk"],["vis generate git://github.com/org/template#main","Fetch and run a remote template"],["vis generate --list","Show discovered templates"],["vis generate --list --json","Machine-readable template list"],["vis generate package --describe --json","Print template metadata (variables, destination) as JSON"]],group:"Scaffold & Config",loader:()=>import("./handler61.js"),name:"generate",options:[{defaultValue:!1,description:"List discovered templates",name:"list",type:Boolean},{defaultValue:!1,description:"Print template metadata (about, destination, variables) without running produce",name:"describe",type:Boolean},{defaultValue:!1,description:"Emit JSON output (with --list or --describe)",name:"json",type:Boolean},{description:"Destination directory",name:"to",type:String},{defaultValue:!1,description:"Print planned writes without touching disk",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Overwrite existing files without prompting",name:"force",type:Boolean},{defaultValue:!1,description:"Skip prompts; use template defaults",name:"defaults",type:Boolean},{defaultValue:!1,description:"Skip running post-generation scripts",name:"skip-scripts",type:Boolean},{defaultValue:!1,description:"Skip interactive prompts (errors on missing required values)",name:"no-interactive",type:Boolean},{defaultValue:!1,description:"Prefer locally cached remote templates over re-downloading",name:"prefer-offline",type:Boolean}]},M0e={description:"Visualize the project dependency graph",examples:[["vis graph","Show colored dependency graph (TUI in TTY, ASCII otherwise)"],["vis graph --format=ascii","Force ASCII tree output"],["vis graph --format=dot","Output in Graphviz DOT format"],["vis graph --format=html --output=graph.html","Generate interactive HTML graph"],["vis graph --format=json --output=graph.json","Save JSON graph to file"]],group:"Workspace",loader:()=>import("./handler73.js"),name:"graph",options:[{alias:"f",defaultValue:void 0,description:"Output format: tui, ascii, dot, json, html (default: tui in TTY, ascii otherwise)",name:"format",type:String},{alias:"o",description:"Write output to file instead of stdout",name:"output",type:String},{alias:"d",description:"Maximum dependency tree depth for ASCII output (default: unlimited)",name:"depth",type:Number}]},GL=["pre-commit","pre-merge-commit","prepare-commit-msg","commit-msg","post-commit","applypatch-msg","pre-applypatch","post-applypatch","pre-rebase","post-rewrite","post-checkout","post-merge","pre-push","pre-auto-gc"],ap=".vis/hooks",Sa=".vis-hooks",l1e=[".pre-commit-config.yaml",".pre-commit-config.yml","prek.toml"],g1e={commit:"pre-commit","merge-commit":"pre-merge-commit",push:"pre-push"},h1e=new Set(["commit-msg","post-checkout","post-commit","post-merge","post-rewrite","pre-commit","pre-merge-commit","pre-push","pre-rebase","prepare-commit-msg"]),c1e=new Set(["commit-msg","post-checkout","post-merge","post-rewrite","pre-rebase","prepare-commit-msg"]),p1e=new Set(["fail","script","system"]),da={defaultValue:ap,description:"Custom hooks directory",name:"hooks-dir",type:String},la=[{defaultValue:void 0,description:"Set to 0 to disable git hooks, 1 to force-enable them under CI (override skipInCI), 2 for debug output",name:"VIS_GIT_HOOKS",type:String}],P0e={commandPath:["hook"],description:"Install git hooks for the workspace (migrates husky / prek on prompt)",env:[...la],examples:[["vis hook install","Install git hooks in .vis/hooks/"],["vis hook install --hooks-dir=.githooks","Install hooks in a custom directory"]],group:"Git Hooks",loader:()=>import("./handler71.js").then(e=>({default:e.hookInstallExecute})),name:"install",options:[da]},N0e={commandPath:["hook"],description:"Remove git hooks and reset core.hooksPath",env:[...la],examples:[["vis hook uninstall","Remove git hooks and reset core.hooksPath"]],group:"Git Hooks",loader:()=>import("./handler71.js").then(e=>({default:e.hookUninstallExecute})),name:"uninstall",options:[da]},E0e={commandPath:["hook"],description:"Migrate from husky or prek to vis hooks (auto-detected)",env:[...la],examples:[["vis hook migrate","Migrate from husky or prek to vis hooks (auto-detected)"],["vis hook migrate --dry-run","Preview what a migration would write without touching disk"]],group:"Git Hooks",loader:()=>import("./handler71.js").then(e=>({default:e.hookMigrateExecute})),name:"migrate",options:[da,{defaultValue:!1,description:"Preview migrate without writing files",name:"dry-run",type:Boolean}]},R0e={commandPath:["hook"],description:"Show configured hooks grouped by stage",env:[...la],examples:[["vis hook list","Show configured hooks grouped by stage"]],group:"Git Hooks",loader:()=>import("./handler71.js").then(e=>({default:e.hookListExecute})),name:"list",options:[da]},O0e={commandPath:["hook"],description:"Sanity-check installed hooks and the bundled runner",env:[...la],examples:[["vis hook validate","Sanity-check installed hooks and the bundled runner"]],group:"Git Hooks",loader:()=>import("./handler71.js").then(e=>({default:e.hookValidateExecute})),name:"validate",options:[da]},A0e={argument:{description:"Hook stage to run (e.g. pre-commit, commit-msg). Defaults to pre-commit.",name:"stage",type:String},commandPath:["hook"],description:"Run a specific hook stage against tracked files",env:[...la],examples:[["vis hook run pre-commit --all-files","Run the pre-commit hooks against every tracked file"],["vis hook run pre-commit --from-ref=main --to-ref=HEAD","Run pre-commit hooks on files changed between two refs"],["vis hook run pre-commit --last-commit","Shortcut for --from-ref HEAD~1 --to-ref HEAD"]],group:"Git Hooks",loader:()=>import("./handler71.js").then(e=>({default:e.hookRunExecute})),name:"run",options:[da,{defaultValue:!1,description:"Run against every tracked file",name:"all-files",type:Boolean},{defaultValue:void 0,description:"Include files changed since this ref",name:"from-ref",type:String},{defaultValue:void 0,description:"Include files changed up to this ref",name:"to-ref",type:String},{defaultValue:!1,description:"Shortcut for --from-ref HEAD~1 --to-ref HEAD",name:"last-commit",type:Boolean}]},G0e={argument:{description:"Target to add (currently: `secrets`)",name:"target",type:String},commandPath:["hook"],description:"Add a managed hook snippet (e.g. `vis secrets --staged`)",env:[...la],examples:[["vis hook add secrets","Add a pre-commit hook that runs `vis secrets --staged`"]],group:"Git Hooks",loader:()=>import("./handler71.js").then(e=>({default:e.hookAddExecute})),name:"add",options:[da]},F0e=[P0e,N0e,E0e,R0e,O0e,A0e,G0e],Q0e={description:"Generate or merge an ignore file (.dockerignore/.vercelignore/.npmignore/.slugignore) without duplicate entries",examples:[["vis ignore","Print a .dockerignore (deduped against an existing one)"],["vis ignore --write","Write/merge the .dockerignore in place"],["vis ignore --target=vercel --write","Write a deduped .vercelignore"],["vis ignore --target=npm --json","Emit the npm-target result as JSON"]],group:"Scaffold & Config",loader:()=>import("./handler53.js"),name:"ignore",options:[{description:"Ignore-file target: docker | vercel | npm | slug (default: docker)",name:"target",type:String},{defaultValue:!1,description:"Write the result to disk instead of printing to stdout",name:"write",type:Boolean},{defaultValue:!1,description:"Emit the result as JSON",name:"json",type:Boolean}]},W0e={description:"Remove vis from the system (self-uninstall)",examples:[["vis implode","Interactive uninstall"],["vis implode --yes","Non-interactive uninstall (CI)"]],group:"System",loader:()=>import("./handler10.js"),name:"implode",options:[{alias:"y",defaultValue:!1,description:"Skip confirmation prompt",name:"yes",type:Boolean}]},I0e={argument:{description:"Source git repository URL or local path to import",name:"source",type:String},description:"Import an external repo into the monorepo under a prefix, preserving history",examples:[["vis import git@github.com:me/foo.git --prefix packages/tooling/foo","Import a repo under packages/tooling/foo"],["vis import ../foo --prefix packages/foo --ref v1.2.0","Import a specific tag/branch/commit"],["vis import ../foo --prefix packages/foo --squash","Collapse the incoming history into one commit"],["vis import ../foo --prefix packages/foo --dry-run","Print the git plan without making changes"]],group:"Workspace",loader:()=>import("./handler54.js"),name:"import",options:[{alias:"p",description:"Target directory in the monorepo (e.g. packages/tooling/foo)",name:"prefix",type:String},{alias:"r",description:"Branch, tag, or commit to import (default: HEAD)",name:"ref",type:String},{defaultValue:!1,description:"Collapse the incoming history into a single merge commit",name:"squash",type:Boolean},{alias:"m",description:"Commit message for the subtree merge",name:"message",type:String},{defaultValue:!1,description:"Do not register the package into the workspace config",name:"no-register",type:Boolean},{defaultValue:!1,description:"Print the git plan instead of executing it",name:"dry-run",type:Boolean}]},_0e={alias:"view",argument:{description:"Package name followed by optional metadata fields (e.g. 'react version dependencies')",name:"args",type:String},description:"Show npm registry metadata for a package (alias of `npm view` / `pnpm view` / `yarn info` / `bun pm view`)",examples:[["vis info react","Full registry metadata for react"],["vis info react version","Latest version only"],["vis info react versions","All published versions"],["vis info react@18 dependencies","Dependencies of react@18"],["vis info react --json","Emit JSON"],["vis view react","Alias matching npm/pnpm"]],group:"Dependencies",loader:()=>import("./handler11.js"),name:"info",options:[{defaultValue:!1,description:"Output as JSON",name:"json",type:Boolean}]},z0e={description:"Initialize vis.config.ts with best-practice security defaults",examples:[["vis init","Interactive setup wizard"],["vis init --no-interactive","Create minimal config without prompts"],["vis init --force","Overwrite existing config"],["vis init --sync-native","Also sync to native PM config files"],["vis init --schema","Print the workspace-relative `$schema` refs to paste into project.json and vis.config.ts"]],group:"Scaffold & Config",loader:()=>import("./handler12.js"),name:"init",options:[{defaultValue:!1,description:"Overwrite existing config file",name:"force",type:Boolean},{defaultValue:!1,description:"Skip interactive prompts",name:"no-interactive",type:Boolean},{defaultValue:!1,description:"Sync settings to native PM config files",name:"sync-native",type:Boolean},{defaultValue:!1,description:"Print workspace-relative $schema paths for project.json and vis.config.ts, then exit",name:"schema",type:Boolean}]},K0e={argument:{description:"Package to inspect, optionally pinned: `<name>` or `<name>@<spec>`. `<spec>` may be a version, range, or dist-tag.",name:"package"},description:"Run all marshalls against a package without installing it",examples:[["vis inspect express","Run every marshall against express@latest"],["vis inspect lodash@4.17.21","Pin to an exact version"],["vis inspect react@^18","Resolve a semver range, then inspect the best match"],["vis inspect express --json","Emit findings as JSON for CI integration"],["vis inspect express --strict","Exit non-zero on any warning, not just errors"],["vis inspect express --only author,downloads","Run a subset of marshalls"],["vis inspect express --only signatures","Signatures are off by default; opt in with --only"]],group:"Security & Health",loader:()=>import("./handler13.js"),name:"inspect",options:[{defaultValue:!1,description:"Emit findings as a JSON document instead of the human-readable table.",name:"json",type:Boolean},{defaultValue:!1,description:"Exit non-zero on any finding (warnings included). Default exits non-zero only on errors.",name:"strict",type:Boolean},{description:"Comma-separated subset of marshalls to run. Known: author, archivedRepo, downloads, expiredDomains, metadata, newBin, provenance, signatures. Signatures only runs when explicitly requested here.",name:"only",type:String}]},q0e={alias:"i",argument:{description:"Optional package names. When provided, delegates to `vis add` (enables npm-style `alias npm='vis install'` wrappers).",name:"packages",type:String},description:"Install dependencies using the detected package manager",examples:[["vis install","Install all dependencies (frozen-lockfile by default when a lockfile is present)"],["vis install react react-dom","Delegates to `vis add` — enables shell aliases like `alias npm='vis install'`"],["vis i --no-frozen-lockfile","Allow lockfile updates (escape hatch for the default)"],["vis install --ci","Clean install: wipe node_modules + frozen lockfile (mirrors npm ci / pnpm ci)"],["vis install --prefer-offline","Use cached packages when available, fall back to network"],["vis install --prod","Install production dependencies only"],["vis install --filter app","Install for specific workspace package"],["vis install --run-scripts","Run lifecycle scripts (opts out of vis's default block-by-default policy; allowlisted packages run via security.policies.installScripts.allow)"],["vis install --no-typosquat-check","Skip typosquat name check"],["vis install --installer aube","Force aube as the installer (errors if not on PATH)"],["vis install --no-aube","Bypass aube; use the lockfile-detected PM"]],group:"Dependencies",loader:()=>import("./handler14.js"),name:"install",options:[{alias:"P",conflicts:"dev",description:"Skip devDependencies (no positional args) / add as peer (with positional args, npm-style)",name:"prod",type:Boolean},{alias:"D",conflicts:"prod",description:"Install devDependencies only (no positional args) / add as dev (with positional args, npm-style)",name:"dev",type:Boolean},{defaultValue:!1,description:"Add as optional dependency (only with positional args; mirrors `npm install -O`)",name:"save-optional",type:Boolean},{alias:"E",defaultValue:!1,description:"Save exact version (only with positional args; mirrors `npm install -E`)",name:"exact",type:Boolean},{defaultValue:!1,description:"Skip Socket.dev security check (only with positional args; mirrors `vis add --no-socket-check`)",name:"no-socket-check",type:Boolean},{defaultValue:!1,description:"Skip the offline marshall pipeline (only with positional args; mirrors `vis add --no-marshall-check`)",name:"no-marshall-check",type:Boolean},{defaultValue:!1,description:"Use frozen lockfile (CI mode, maps to npm ci)",name:"frozen-lockfile",type:Boolean},{defaultValue:!1,description:"Opt out of vis's default frozen-lockfile behavior and allow lockfile updates",name:"no-frozen-lockfile",type:Boolean},{defaultValue:!1,description:"Clean install: wipe node_modules then install with frozen lockfile",name:"ci",type:Boolean},{alias:"f",defaultValue:!1,description:"Force reinstall all dependencies",name:"force",type:Boolean},{defaultValue:!1,description:"Run lifecycle scripts (opts out of vis's default block-by-default policy; allowlisted packages run via security.policies.installScripts.allow)",name:"run-scripts",type:Boolean},{defaultValue:!1,description:"Update lockfile without installing",name:"lockfile-only",type:Boolean},{defaultValue:!1,description:"Skip optional dependencies",name:"no-optional",type:Boolean},{defaultValue:!1,description:"Use only cached packages",name:"offline",type:Boolean},{defaultValue:!1,description:"Prefer cached packages, fall back to network when missing",name:"prefer-offline",type:Boolean},{alias:"s",defaultValue:!1,description:"Suppress output",name:"silent",type:Boolean},{alias:"r",defaultValue:!1,description:"Install in all workspace packages",name:"recursive",type:Boolean},{alias:"w",defaultValue:!1,description:"Target workspace root",name:"workspace-root",type:Boolean},{alias:"F",description:"Filter by workspace package name",multiple:!0,name:"filter",type:String},{defaultValue:!1,description:"Skip typosquat name check",name:"no-typosquat-check",type:Boolean},{description:"Pick the installer explicitly. One of: auto, aube, pnpm, npm, yarn, bun. Overrides VIS_INSTALLER and install.backend in vis.config.",name:"installer",type:String},{defaultValue:!1,description:"Skip aube and use the lockfile-detected PM. Wins over --installer / VIS_INSTALLER / install.backend.",name:"no-aube",type:Boolean}]},U0e={alias:"ln",argument:{description:"Package name or directory path to link (omit to register current package)",name:"target",type:String},description:"Link a local package for development",examples:[["vis link ./packages/utils","Link local directory package (works on all PMs)"],["vis link","Register current package globally (pnpm <=10, yarn, npm, bun)"],["vis link react","Link global package into current project (pnpm <=10, yarn, npm, bun)"]],group:"Dependencies",loader:()=>import("./handler16.js"),name:"link"},V0e={description:"Orchestrate detected source-code linters (eslint, …) across the workspace",examples:[["vis lint","Run every detected linter against the workspace"],["vis lint --fix","Apply auto-fixes where the tool supports them"],["vis lint --format json","Emit findings as JSON for CI / editor integrations"],["vis lint --format sarif","Emit a SARIF 2.1.0 document for code-scanning uploads"],["vis lint --format junit","Emit a JUnit XML report for CI dashboards"],["vis lint --format github","Emit GitHub Actions workflow commands for inline PR annotations"],["vis lint src/foo.ts src/bar.ts","Lint a specific file list"],["vis lint --quiet","Suppress warnings — only errors are reported"],["vis lint --max-warnings 0","Treat any warning as a failure"],["vis lint --since main","Only lint files changed vs the main branch"],["vis lint --staged","Only lint files currently staged in the git index"],["vis lint --watch","Re-run linters when watched files change (cache makes incremental near-free)"],["vis lint --format sarif --output lint.sarif","Write the SARIF report to lint.sarif instead of stdout"]],group:"Lint & Format",loader:()=>import("./handler63.js"),name:"lint",options:[{defaultValue:!1,description:"Apply auto-fixes in place",name:"fix",type:Boolean},{defaultValue:"human",description:"Output format: human, json, minimal, sarif, junit, or github",name:"format",type:String},{defaultValue:!1,description:"Suppress warnings — report errors only",name:"quiet",type:Boolean},{description:"Fail the run if more than N warnings are reported",name:"max-warnings",type:Number},{description:"Only lint files changed vs the given git ref (branch, tag, sha)",name:"since",type:String},{defaultValue:!1,description:"Only lint files currently staged in the git index",name:"staged",type:Boolean},{description:"Write formatted output to a file path instead of stdout (also accepts `-`/`stdout`/`stderr`)",name:"output",type:String},{defaultValue:!1,description:"Re-run linters whenever watched files change",name:"watch",type:Boolean}]},efe={description:"List all workspace projects with metadata",examples:[["vis list","Show all projects"],["vis list --targets","Per-target rows with type, cache status and description"],["vis list --targets --inferred","Only show targets synthesized by Project Crystal-style inference"],["vis list --deps","Human-readable table of every dep-instance across the workspace"],["vis list --deps --internal-only","Only workspace deps in human form"],["vis list --deps --format=ndjson","Stream every dep-instance as NDJSON for jq pipelines"],["vis list --deps --format=json --pretty","Single pretty-printed JSON array of dep-instances"],["vis list --format=json","Machine-readable project listing"],['vis list --query "tag=frontend"',"Filter by query"]],group:"Workspace",loader:()=>import("./handler55.js"),name:"list",options:[{defaultValue:!1,description:"Filter target rows to only inferred targets (implies --targets)",name:"inferred",type:Boolean},{description:"Output format: table (default), json (single document), or ndjson (one record per line; --deps only)",name:"format",type:String},{defaultValue:!1,description:"Pretty-print with 2-space indent (only meaningful with --format=json)",name:"pretty",type:Boolean},{description:"Filter projects by query",name:"query",type:String},{defaultValue:!1,description:"Show per-target rows (type, cache, description)",name:"targets",type:Boolean},{defaultValue:!1,description:"Render a dep-instance view (table by default; use --format=ndjson|json for jq-friendly streams)",name:"deps",type:Boolean},{description:"Restrict --deps to specific dep blocks (repeatable)",multiple:!0,name:"dep-type",type:String},{defaultValue:!1,description:"With --deps: only show internal/workspace deps",name:"internal-only",type:Boolean},{defaultValue:!1,description:"With --deps: only show external/registry deps",name:"external-only",type:Boolean},{description:"With --deps: glob of declaring package names to keep (repeatable)",multiple:!0,name:"include",type:String},{description:"With --deps: glob of declaring package names to drop (repeatable)",multiple:!0,name:"exclude",type:String}]},Hi=[{defaultValue:!1,description:"Preview changes without applying",name:"dry-run",type:Boolean},{alias:"y",defaultValue:!1,description:"Skip the confirmation prompt",name:"yes",type:Boolean}],ife={commandPath:["migrate"],description:"Migrate dependencies and scripts to vis",group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateDepsExecute})),name:"deps",options:[...Hi]},nfe={commandPath:["migrate"],description:"Inline lint-staged configuration into vis",group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateLintStagedExecute})),name:"lint-staged",options:[...Hi]},ofe={commandPath:["migrate"],description:"Inline nano-staged configuration into vis",group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateNanoStagedExecute})),name:"nano-staged",options:[...Hi]},afe={commandPath:["migrate"],description:"Migrate turborepo tasks/config to vis",group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateTurborepoExecute})),name:"turborepo",options:[...Hi]},tfe={commandPath:["migrate"],description:"Migrate nx targets/config to vis",group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateNxExecute})),name:"nx",options:[...Hi,{defaultValue:!1,description:"Overwrite an existing vis.config.ts (a .bak is taken first)",name:"force",type:Boolean},{defaultValue:!1,description:"For each project.json `syncGenerators`, add a `pre<target>` script to sibling package.json (with a TODO for the user to wire up)",name:"rewrite-sync-generators",type:Boolean},{defaultValue:!1,description:"Auto-apply the safe cleanup items the migrator would otherwise leave on the checklist: delete nx.json + ignore-files-for-nx-affected.yml, strip nx/@nx/*/@nrwl/* devDependencies, rewrite mechanical `nx run-many|run|affected` scripts. Implies --force.",name:"aggressive",type:Boolean}]},sfe={commandPath:["migrate"],description:"Migrate moon tasks/templates to vis",group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateMoonExecute})),name:"moon",options:[...Hi,{defaultValue:!1,description:"Copy .moon/templates/* into .vis/templates/* so `vis generate` works without .moon/",name:"copy-templates",type:Boolean}]},rfe={commandPath:["migrate"],description:"Migrate gitleaks config/baseline/hooks to `vis secrets`",examples:[["vis migrate gitleaks","Migrate gitleaks config/baseline/hooks to `vis secrets`"]],group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateGitleaksExecute})),name:"gitleaks",options:[...Hi]},ufe={commandPath:["migrate"],description:"Migrate Kingfisher baseline/hooks/scripts to `vis secrets`",examples:[["vis migrate kingfisher","Migrate Kingfisher baseline/hooks/scripts to `vis secrets`"]],group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateKingfisherExecute})),name:"kingfisher",options:[...Hi]},dfe={commandPath:["migrate"],description:"Replace secretlint with `vis secrets`",examples:[["vis migrate secretlint","Replace secretlint with `vis secrets`"]],group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateSecretlintExecute})),name:"secretlint",options:[...Hi]},lfe={commandPath:["migrate"],description:"Translate syncpack customTypes into vis policy and strip the syncpack dep/scripts",examples:[["vis migrate syncpack","Translate syncpack customTypes into vis policy and strip the syncpack dep/scripts"]],group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateSyncpackExecute})),name:"syncpack",options:[...Hi]},gfe={commandPath:["migrate"],description:"Strip sherif config/dep/scripts and surface ignore-rules as a positive `vis lint --<rule>` command",examples:[["vis migrate sherif","Strip sherif config/dep/scripts and surface ignore-rules as a positive `vis lint --<rule>` command"]],group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateSherifExecute})),name:"sherif",options:[...Hi]},hfe={commandPath:["migrate"],description:"Auto-rewrite vis.config.ts to use renamed fields (targetDefaults → tasks, taskDefaults → scopedTasks, taskRunnerOptions → taskRunner)",examples:[["vis migrate self","Rewrite vis.config.ts in-place (a .bak is taken first)"],["vis migrate self --dry-run","Preview the rewrite without writing"]],group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateSelfExecute})),name:"self",options:[...Hi]},cfe={commandPath:["migrate"],description:"Audit the workspace for stray gitleaks/secretlint/sherif/syncpack references (exit 1 on issues)",examples:[["vis migrate verify","Audit the workspace for stray gitleaks/secretlint/sherif/syncpack references (exit 1 on issues)"]],group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateVerifyExecute})),name:"verify",options:[]},pfe={commandPath:["migrate"],description:"Prove a turbo/nx/moon → vis migration preserved the task graph + cache-key surface (exit 1 on divergence)",examples:[["vis migrate verify-graph","Auto-detect the source tool and diff its task graph against the migrated vis.config.ts"],["vis migrate verify-graph --from turbo --format json","Machine-readable equivalence report on stdout (Axis A)"],["vis migrate verify-graph --fail-on warning","Also gate CI on additive/extra-target warnings"]],group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateVerifyGraphExecute})),name:"verify-graph",options:[{description:"Source tool to compare against (turbo|nx|moon). Auto-detected when omitted.",name:"from",type:String},{description:"Output format: table | json | ndjson (default: table)",name:"format",type:String},{description:"Exit non-zero on: error (default) | warning",name:"fail-on",type:String}]},vfe={commandPath:["migrate"],description:"Run every applicable migration non-interactively (autodetected)",examples:[["vis migrate all --yes","Run every detected migration without prompting (CI-friendly)"],["vis migrate all --dry-run","Preview every detected migration without writing files"]],group:"Migrate",loader:()=>import("./handler58.js").then(e=>({default:e.migrateAllExecute})),name:"all",options:[...Hi]},yfe=[vfe,ife,nfe,ofe,afe,tfe,sfe,hfe,rfe,ufe,dfe,lfe,gfe,cfe,pfe],ffe=new Set(["--cwd"]),mfe=new Set(["--help","--version","-h","-V"]),bfe=e=>{const i=[];for(let n=0;n<e.length;n+=1){const o=e[n];if(o!==void 0){if(mfe.has(o))return!1;if(o.startsWith("-")){const a=o.indexOf("="),t=a===-1?o:o.slice(0,a);if(ffe.has(t)&&a===-1){const s=e[n+1];s!==void 0&&!s.startsWith("-")&&(n+=1)}continue}i.push(o)}}return i.length===1&&i[0]==="migrate"},wfe=e=>{if(e.length===0)return!1;for(const i of e){const n=i.codePointAt(0)??0;return!(n<=127||n<=255)}return!1};let jfe=class{buffer="";timer;onFlush;timeout;constructor({onFlush:i,timeout:n}){this.onFlush=i,this.timeout=n}add(i){this.buffer+=i,this.timer!==void 0&&clearTimeout(this.timer),this.timer=setTimeout(()=>{this.flush()},this.timeout)}flush(){if(this.timer!==void 0&&(clearTimeout(this.timer),this.timer=void 0),this.buffer.length>0){const i=this.buffer;this.buffer="",this.onFlush(i)}}destroy(){this.timer!==void 0&&(clearTimeout(this.timer),this.timer=void 0),this.buffer=""}};const ar=e=>{const i=/rgb:([\da-f]{2,4})\/([\da-f]{2,4})\/([\da-f]{2,4})/i.exec(e);if(!i)return null;const n=o=>o.length<=2?o.padStart(2,"0"):o.slice(0,2);return`#${n(i[1])}${n(i[2])}${n(i[3])}`},kfe=()=>{const e=process.env.TERM_PROGRAM??"";return new Set(["Alacritty","contour","foot","Ghostty","iTerm2","iTerm.app","kitty","rio","WezTerm"]).has(e)?!0:(process.env.TERM??"").startsWith("xterm")||!!process.env.WT_SESSION},tr=(e,i,n,o=500)=>new Promise(a=>{let t="",s;const r=()=>{s&&clearTimeout(s),e.removeListener("data",u)},u=d=>{if(t+=d.toString(),t.length>256){r(),a(null);return}(t.includes("\x07")||t.includes("\x1B\\"))&&(r(),a(t))};s=setTimeout(()=>{r(),a(null)},o),e.on("data",u),i.write(n)}),Sfe=async(e,i,n=500)=>{const o={},a=await tr(e,i,"\x1B]10;?\x07",n);if(a){const u=ar(a);u&&(o.foreground=u)}const t=await tr(e,i,"\x1B]11;?\x07",n);if(t){const u=ar(t);u&&(o.background=u)}const s=await tr(e,i,"\x1B]12;?\x07",n);if(s){const u=ar(s);u&&(o.cursor=u)}const r=[];for(let u=0;u<16;u++){const d=await tr(e,i,`\x1B]4;${u};?\x07`,n);if(d){const l=ar(d);r.push(l??"")}else r.push("")}return r.some(u=>u.length>0)&&(o.colors=r),o},FL=()=>D.useContext(xY),QL=()=>{const{stdout:e}=FL(),[i,n]=D.useState(()=>jp(e));return D.useEffect(()=>{const o=()=>{n(jp(e))};return e.on("resize",o),()=>{e.off("resize",o)}},[e]),i},Lfe=()=>D.useContext(nm),WL=()=>D.useContext(nm);class Cfe{#n;#i=new Set;constructor(i){this.#n={applyProgress:null,checkedItems:new Set(i.map(n=>n.entry.id)),error:null,focusedPanel:"list",items:i,phase:"browsing",selectedIndex:0}}getSnapshot=()=>this.#n;subscribe=i=>(this.#i.add(i),()=>{this.#i.delete(i)});getCheckedItems(){return this.#n.items.filter(i=>this.#n.checkedItems.has(i.entry.id))}getSelectedItem(){return this.#n.items[this.#n.selectedIndex]??null}setSelectedIndex(i){const n=Math.max(0,Math.min(i,this.#n.items.length-1));n!==this.#n.selectedIndex&&this.#e({...this.#n,selectedIndex:n})}setFocusedPanel(i){i!==this.#n.focusedPanel&&this.#e({...this.#n,focusedPanel:i})}toggleCheck(i){const n=new Set(this.#n.checkedItems);n.has(i)?n.delete(i):n.add(i),this.#e({...this.#n,checkedItems:n})}checkAll(){this.#e({...this.#n,checkedItems:new Set(this.#n.items.map(i=>i.entry.id))})}uncheckAll(){this.#e({...this.#n,checkedItems:new Set})}toggleAll(){this.#n.checkedItems.size===this.#n.items.length?this.uncheckAll():this.checkAll()}startApply(){const i=this.getCheckedItems().length;this.#e({...this.#n,applyProgress:{current:0,total:i},phase:"applying"})}updateApplyProgress(i){this.#n.applyProgress&&this.#e({...this.#n,applyProgress:{...this.#n.applyProgress,current:i}})}markDone(){this.#e({...this.#n,phase:"done"})}setError(i){this.#e({...this.#n,error:i,phase:"error"})}#e(i){this.#n=i;for(const n of this.#i)try{n()}catch{}}}const Yfe=()=>{const{stdin:e}=WL(),{stdout:i}=FL(),[n,o]=D.useState(null),[a,t]=D.useState(!0),s=D.useMemo(()=>kfe(),[]);return D.useEffect(()=>{if(!s||!e||!i){t(!1);return}let r=!1;return(async()=>{try{const u=await Sfe(e,i,200);r||o(u)}catch{}finally{r||t(!1)}})(),()=>{r=!0}},[s,e,i]),{isLoading:a,isSupported:s,palette:n}},$fe=({autoFocus:e=!1,id:i,isActive:n=!0}={})=>{const{isRawModeSupported:o,setRawMode:a}=Lfe(),{activate:t,activeId:s,add:r,deactivate:u,focus:d,remove:l}=D.useContext(TY),g=D.useMemo(()=>i??Math.random().toString().slice(2,7),[i]);return D.useEffect(()=>(r(g,{autoFocus:e}),()=>{l(g)}),[g,e]),D.useEffect(()=>{n?t(g):u(g)},[n,g]),D.useEffect(()=>{if(!(!o||!n))return a(!0),()=>{a(!1)}},[n]),{focus:d,isFocused:!!g&&s===g}},Zfe=wn(import.meta.url),Nt=typeof globalThis<"u"&&typeof globalThis.process<"u"?globalThis.process:process,Jfe=e=>{if(typeof Nt<"u"&&Nt.versions&&Nt.versions.node){const[i,n]=Nt.versions.node.split(".").map(Number);if(i>22||i===22&&n>=3||i===20&&n>=16)return Nt.getBuiltinModule(e)}return Zfe(e)},{Buffer:xfe}=Jfe("node:buffer"),Tfe=/^\u001B([a-z0-9])$/i,Dfe=/^\u001B+([ON[]|\[\[)(?:(\d+)(?:;(\d+))?([~^$])|(?:1;)?(\d+)?([a-zA-Z]))/,IL={"[1~":"home","[2$":"insert","[2^":"insert","[2~":"insert","[3$":"delete","[3^":"delete","[3~":"delete","[4~":"end","[5$":"pageup","[5^":"pageup","[5~":"pageup","[6$":"pagedown","[6^":"pagedown","[6~":"pagedown","[7$":"home","[7^":"home","[7~":"home","[8$":"end","[8^":"end","[8~":"end","[11~":"f1","[12~":"f2","[13~":"f3","[14~":"f4","[15~":"f5","[17~":"f6","[18~":"f7","[19~":"f8","[20~":"f9","[21~":"f10","[23~":"f11","[24~":"f12","[[5~":"pageup","[[6~":"pagedown","[[A":"f1","[[B":"f2","[[C":"f3","[[D":"f4","[[E":"f5","[A":"up","[a":"up","[B":"down","[b":"down","[C":"right","[c":"right","[D":"left","[d":"left","[E":"clear","[e":"clear","[F":"end","[H":"home","[P":"f1","[Q":"f2","[R":"f3","[S":"f4","[Z":"tab",OA:"up",Oa:"up",OB:"down",Ob:"down",OC:"right",Oc:"right",OD:"left",Od:"left",OE:"clear",Oe:"clear",OF:"end",OH:"home",OP:"f1",OQ:"f2",OR:"f3",OS:"f4"},Bfe=[...Object.values(IL),"backspace"],Xfe=e=>["[2$","[3$","[5$","[6$","[7$","[8$","[a","[b","[c","[d","[e","[Z"].includes(e),Hfe=e=>["[2^","[3^","[5^","[6^","[7^","[8^","Oa","Ob","Oc","Od","Oe"].includes(e),_L=/^\u001B\[(\d+)(?:;(\d+)(?::(\d+))?(?:;([\d:]+))?)?u$/,Mfe=/^\u001B\[(\d+);(\d+):(\d+)([A-Z~])$/i,Pfe={A:"up",B:"down",C:"right",D:"left",E:"clear",F:"end",H:"home",P:"f1",Q:"f2",R:"f3",S:"f4"},Nfe={2:"insert",3:"delete",5:"pageup",6:"pagedown",7:"home",8:"end",11:"f1",12:"f2",13:"f3",14:"f4",15:"f5",17:"f6",18:"f7",19:"f8",20:"f9",21:"f10",23:"f11",24:"f12"},ff={8:"backspace",9:"tab",27:"escape",127:"backspace",57358:"capslock",57359:"scrolllock",57360:"numlock",57361:"printscreen",57362:"pause",57363:"menu",57376:"f13",57377:"f14",57378:"f15",57379:"f16",57380:"f17",57381:"f18",57382:"f19",57383:"f20",57384:"f21",57385:"f22",57386:"f23",57387:"f24",57388:"f25",57389:"f26",57390:"f27",57391:"f28",57392:"f29",57393:"f30",57394:"f31",57395:"f32",57396:"f33",57397:"f34",57398:"f35",57399:"kp0",57400:"kp1",57401:"kp2",57402:"kp3",57403:"kp4",57404:"kp5",57405:"kp6",57406:"kp7",57407:"kp8",57408:"kp9",57409:"kpdecimal",57410:"kpdivide",57411:"kpmultiply",57412:"kpsubtract",57413:"kpadd",57414:"kpenter",57415:"kpequal",57416:"kpseparator",57417:"kpleft",57418:"kpright",57419:"kpup",57420:"kpdown",57421:"kppageup",57422:"kppagedown",57423:"kphome",57424:"kpend",57425:"kpinsert",57426:"kpdelete",57427:"kpbegin",57428:"mediaplay",57429:"mediapause",57430:"mediaplaypause",57431:"mediareverse",57432:"mediastop",57433:"mediafastforward",57434:"mediarewind",57435:"mediatracknext",57436:"mediatrackprevious",57437:"mediarecord",57438:"lowervolume",57439:"raisevolume",57440:"mutevolume",57441:"leftshift",57442:"leftcontrol",57443:"leftalt",57444:"leftsuper",57445:"lefthyper",57446:"leftmeta",57447:"rightshift",57448:"rightcontrol",57449:"rightalt",57450:"rightsuper",57451:"righthyper",57452:"rightmeta",57453:"isoLevel3Shift",57454:"isoLevel5Shift"},zL=e=>e>=0&&e<=1114111&&!(e>=55296&&e<=57343),kl=e=>zL(e)?String.fromCodePoint(e):"?";function KL(e){return e===3?"release":e===2?"repeat":"press"}function qL(e){return{capsLock:!!(e&Un.capsLock),ctrl:!!(e&Un.ctrl),hyper:!!(e&Un.hyper),meta:!!(e&Un.meta),numLock:!!(e&Un.numLock),option:!!(e&Un.alt),shift:!!(e&Un.shift),super:!!(e&Un.super)}}const Efe=e=>{const i=_L.exec(e);if(!i)return null;const n=Number.parseInt(i[1],10),o=i[2]?Math.max(0,Number.parseInt(i[2],10)-1):0,a=i[3]?Number.parseInt(i[3],10):1,t=i[4];if(!zL(n))return null;let s;t&&(s=t.split(":").map(d=>kl(Number.parseInt(d,10))).join(""));let r,u;return n===32?(r="space",u=!0):n===13?(r="return",u=!0):ff[n]?(r=ff[n],u=!1):n>=1&&n<=26?(r=String.fromCodePoint(n+96),u=!1):(r=kl(n).toLowerCase(),u=!0),u&&!s&&(s=kl(n)),{name:r,...qL(o),eventType:KL(a),isKittyProtocol:!0,isPrintable:u,raw:e,sequence:e,text:s}},Rfe=e=>{const i=Mfe.exec(e);if(!i)return null;const n=Number.parseInt(i[1],10),o=Math.max(0,Number.parseInt(i[2],10)-1),a=Number.parseInt(i[3],10),t=i[4],s=t==="~"?Nfe[n]:Pfe[t];return s?{name:s,...qL(o),eventType:KL(a),isKittyProtocol:!0,isPrintable:!1,raw:e,sequence:e}:null},Ofe=(e="")=>{let i;xfe.isBuffer(e)?e[0]>127&&e[1]===void 0?(e[0]-=128,e=`\x1B${String(e)}`):e=String(e):e!==void 0&&typeof e!="string"?e=String(e):e||(e="");const n=Efe(e);if(n)return n;const o=Rfe(e);if(o)return o;if(_L.test(e))return{ctrl:!1,isKittyProtocol:!0,isPrintable:!1,meta:!1,name:"",option:!1,raw:e,sequence:e,shift:!1};const a={ctrl:!1,meta:!1,name:"",option:!1,raw:e,sequence:e,shift:!1};switch(a.sequence=a.sequence||e||a.name,e){case"\r":case"\x1B\r":{a.raw=void 0,a.name="return",a.option=e.length===2;break}case`
173
+ `:{a.name="enter";break}case" ":{a.name="tab";break}case" ":case"\x1B ":{a.name="space",a.meta=e.length===2;break}case"\b":case"\x1B\b":{a.name="backspace",a.meta=e.charAt(0)==="\x1B";break}case"\x1B":case"\x1B\x1B":{a.name="escape",a.meta=e.length===2;break}case"\x1B":case"":{a.name="backspace",a.meta=e.charAt(0)==="\x1B";break}default:if(e.length===1&&e<="")a.name=String.fromCharCode(e.charCodeAt(0)+97-1),a.ctrl=!0;else if(e.length===1&&e>="0"&&e<="9")a.name="number";else if(e.length===1&&e>="a"&&e<="z")a.name=e;else if(e.length===1&&e>="A"&&e<="Z")a.name=e.toLowerCase(),a.shift=!0;else if(i=Tfe.exec(e))a.meta=!0,a.shift=/^[A-Z]$/.test(i[1]);else if(i=Dfe.exec(e)){const t=[...e];t[0]==="\x1B"&&t[1]==="\x1B"&&(a.option=!0);const s=[i[1],i[2],i[4],i[6]].filter(Boolean).join(""),r=(i[3]||i[5]||1)-1;a.ctrl=!!(r&4),a.meta=!!(r&10),a.shift=!!(r&1),a.code=s,a.name=IL[s]??"",a.shift=Xfe(s)||a.shift,a.ctrl=Hfe(s)||a.ctrl}}return a},tp=(e,i={})=>{const{internal_eventEmitter:n,internal_exitOnCtrlC:o,setRawMode:a,stdin:t}=WL(),s=i.imeEnabled??!0,r=i.imeTimeout??50,u=D.useRef(void 0),d=D.useEffectEvent(e);D.useEffect(()=>{if(s)return u.current=new jfe({onFlush:l=>{const g={backspace:!1,capsLock:!1,ctrl:!1,delete:!1,downArrow:!1,end:!1,escape:!1,home:!1,hyper:!1,leftArrow:!1,meta:!1,numLock:!1,pageDown:!1,pageUp:!1,return:!1,rightArrow:!1,shift:!1,super:!1,tab:!1,upArrow:!1};kp.discreteUpdates(()=>{d(l,g)})},timeout:r}),()=>{u.current?.destroy(),u.current=void 0}},[s,r]),D.useEffect(()=>{if(i.isActive!==!1)return a(!0),()=>{a(!1)}},[i.isActive,a]),D.useEffect(()=>{if(i.isActive===!1)return;const l=g=>{if(s&&wfe(g)){u.current?.add(g);return}u.current?.flush();const h=Ofe(g),c={backspace:h.name==="backspace",capsLock:h.capsLock??!1,ctrl:h.ctrl,delete:h.name==="delete",downArrow:h.name==="down",end:h.name==="end",escape:h.name==="escape",eventType:h.eventType,home:h.name==="home",hyper:h.hyper??!1,leftArrow:h.name==="left",meta:h.meta||h.option,numLock:h.numLock??!1,pageDown:h.name==="pagedown",pageUp:h.name==="pageup",return:h.name==="return",rightArrow:h.name==="right",shift:h.shift,super:h.super??!1,tab:h.name==="tab",upArrow:h.name==="up"};let p;h.isKittyProtocol?h.isPrintable?p=h.text??h.name:h.ctrl&&h.name.length===1?p=h.name:p="":h.ctrl?p=h.name:p=h.sequence,!h.isKittyProtocol&&Bfe.includes(h.name)&&(p=""),p.startsWith("\x1B")&&(p=p.slice(1)),p.length===1&&typeof p[0]=="string"&&/[A-Z]/.test(p[0])&&(c.shift=!0),!(p==="c"&&c.ctrl&&o)&&(!h.name&&p===""||kp.discreteUpdates(()=>{d(p,c)}))};return n.on("input",l),()=>{n.removeListener("input",l)}},[i.isActive,t,o,s])},Afe=e=>{const{getViewportHeight:i,isActive:n=!0,scrollBy:o,scrollToBottom:a,scrollToTop:t,vimBindings:s=!1}=e,{isFocused:r}=$fe({isActive:n});return tp((u,d)=>{if(d.upArrow){o(-1);return}if(d.downArrow){o(1);return}if(d.pageUp){o(-i());return}if(d.pageDown){o(i());return}if(d.home){t();return}if(d.end){a();return}if(d.ctrl&&u==="u"){o(-Math.floor(i()/2));return}if(d.ctrl&&u==="d"){o(Math.floor(i()/2));return}if(s){if(u==="k"){o(-1);return}if(u==="j"){o(1);return}if(u==="G"&&d.shift){a();return}if(u==="g"&&!d.shift){t();return}if(u==="u"&&!d.ctrl){o(-Math.floor(i()/2));return}u==="d"&&!d.ctrl&&o(Math.floor(i()/2))}},{isActive:n}),{isFocused:r}},Hg=e=>{const[i,n]=D.useState(e),o=D.useRef(e),a=D.useCallback(s=>{const r=typeof s=="function"?s(o.current):s;o.current=r,n(r)},[]),t=D.useCallback(()=>o.current,[]);return[i,a,t]},Gfe=({children:e,index:i,measureKey:n,onMeasure:o,width:a})=>{const t=D.useRef(null);return D.useLayoutEffect(()=>{if(t.current){const{height:s}=om(t.current);o(i,s)}},[i,o,a,n,e]),Y.jsx(_,{flexDirection:"column",flexShrink:0,ref:t,width:"100%",children:e})},Qr=e=>{if(e==null)return[];if(Array.isArray(e)){const i=[];for(let n=0;n<e.length;n+=1){const o=e[n];D.isValidElement(o)&&o.type===D.Fragment?i.push(...Qr(o.props.children)):i.push(o)}return i}return D.isValidElement(e)&&e.type===D.Fragment?Qr(e.props.children):[e]},mf=({children:e,debug:i=!1,onContentHeightChange:n,onItemHeightChange:o,onViewportSizeChange:a,overscan:t=3,ref:s,scrollOffset:r,virtualize:u=!1,...d})=>{const l=D.useRef(!1),[g,h,c]=Hg({height:0,width:0}),[p,f,w]=Hg(0),[v,j]=D.useState({}),C=D.useRef(null),y=D.useRef(0);D.useLayoutEffect(()=>{p!==y.current&&(n?.(p,y.current),y.current=p)},[p,n]);const k=D.useRef({}),S=D.useRef([]),J=D.useRef([]),T=D.useRef(0),M=D.useCallback((H,N)=>{const X=S.current[H]??H;if(k.current[X]!==N){const G=k.current[X]??0;k.current={...k.current,[X]:N};let I=0;for(let te=0;te<S.current.length;te+=1){const E=S.current[te];E!=null&&(I+=k.current[E]??0)}const V=w();I!==V&&f(I),o?.(H,N,G),T.current=Math.min(T.current,H+1)}},[o,w,f]),he=D.useCallback(()=>{if(C.current){const{height:H,width:N}=om(C.current),X=c();(N!==X.width||H!==X.height)&&(a?.({height:H,width:N},X),h({height:H,width:N}))}},[C,a,c,h]);D.useLayoutEffect(()=>{he()});const Je=D.useRef(null);if(Je.current!==e){Je.current=e;const H=[],N={};Qr(e).forEach((I,V)=>{if(!I)return;const te=(D.isValidElement(I)?I.key:null)??V;H[V]=te;const E=k.current[te]??0;N[te]=E}),k.current=N,S.current=H,J.current=Array.from({length:H.length}).fill(0),T.current=0;let X=0;H.forEach(I=>{X+=N[I]??0});const G=w();X!==G&&f(X)}D.useImperativeHandle(s,()=>({getBottomOffset:()=>Math.max(0,w()-c().height),getContentHeight:w,getItemHeight:H=>{const N=S.current[H]??H;return k.current[N]??0},getItemPosition:H=>{if(H<0||H>=S.current.length)return null;if(H>=T.current){let G=0,I=0;if(T.current>0){I=T.current;const V=I-1,te=S.current[V]??V,E=k.current[te]??0;G=(J.current[V]??0)+E}for(let V=I;V<=H;V+=1){J.current[V]=G;const te=S.current[V]??V,E=k.current[te]??0;G+=E}T.current=H+1}const N=J.current[H]??0,X=S.current[H]??H;return{height:k.current[X]??0,top:N}},getViewportHeight:()=>c().height,remeasure:he,remeasureItem:H=>{j(N=>({...N,[H]:(N[H]??0)+1}))}}),[he,w,c,j]);const Se=Qr(e);!l.current&&p>0&&(l.current=!0);let Le=0,Xe=Se.length-1,A=0,$=0;const P=Se.length>0&&Se.every((H,N)=>{const X=S.current[N]??N;return(k.current[X]??0)>0}),W=u&&l.current&&P;if(W){const H=S.current.length;if(T.current<H){let X=0,G=0;if(T.current>0){G=T.current;const I=G-1,V=S.current[I]??I,te=k.current[V]??0;X=(J.current[I]??0)+te}for(let I=G;I<H;I+=1){J.current[I]=X;const V=S.current[I]??I;X+=k.current[V]??0}T.current=H}const N=r+g.height;Le=Se.length,Xe=-1;for(let X=0;X<H;X+=1){const G=J.current[X]??0,I=S.current[X]??X,V=k.current[I]??0;G+V>r&&G<N&&(X<Le&&(Le=X),Xe=X)}if(Le>Xe&&(Le=0,Xe=-1),Le=Math.max(0,Le-t),Xe=Math.min(Se.length-1,Math.max(-1,Xe)+t),A=J.current[Le]??0,Xe<Se.length-1){const X=S.current[Xe]??Xe,G=(J.current[Xe]??0)+(k.current[X]??0);$=p-G}}return Y.jsx(_,{...d,children:Y.jsx(_,{ref:C,width:"100%",children:Y.jsx(_,{overflow:i?void 0:"hidden",width:"100%",children:Y.jsxs(_,{flexDirection:"column",marginTop:-r,width:"100%",children:[W&&A>0&&Y.jsx(_,{height:A}),Se.map((H,N)=>!H||W&&(N<Le||N>Xe)?null:Y.jsx(Gfe,{index:N,measureKey:v[N],onMeasure:M,width:g.width,children:H},D.isValidElement(H)?H.key??N:N)),W&&$>0&&Y.jsx(_,{height:$})]})})})})},bf={arrow:{lowerThumb:"╽",thumb:"┃",track:"|",upperThumb:"╿"},block:{thumb:"█",track:"░"},bold:{lowerThumb:"╿",thumb:"│",track:"┃",upperThumb:"╽"},classic:{thumb:"┃",track:"|"},dots:{thumb:"●",track:"·"},double:{thumb:"┃",track:"║"},doubleSingle:{lowerThumb:"╽",thumb:"┃",track:"│",upperThumb:"╿"},line:{thumb:"│",track:" "},round:{lowerThumb:"╽",thumb:"┃",track:"│",upperThumb:"╿"},single:{lowerThumb:"╽",thumb:"┃",track:"│",upperThumb:"╿"},singleDouble:{thumb:"┃",track:"║"},thick:{thumb:"┃",track:"╏"}},wf={arrow:{bottomLeft:"└",bottomRight:"┘",topLeft:"┌",topRight:"┐"},bold:{bottomLeft:"┗",bottomRight:"┛",topLeft:"┏",topRight:"┓"},classic:{bottomLeft:"+",bottomRight:"+",topLeft:"+",topRight:"+"},double:{bottomLeft:"╚",bottomRight:"╝",topLeft:"╔",topRight:"╗"},doubleSingle:{bottomLeft:"╘",bottomRight:"╛",topLeft:"╒",topRight:"╕"},round:{bottomLeft:"╰",bottomRight:"╯",topLeft:"╭",topRight:"╮"},single:{bottomLeft:"└",bottomRight:"┘",topLeft:"┌",topRight:"┐"},singleDouble:{bottomLeft:"╙",bottomRight:"╜",topLeft:"╓",topRight:"╖"}},Ffe=e=>bf[typeof e=="string"?e:"single"]??bf.single??{thumb:"┃",track:"│"},Qfe=e=>wf[typeof e=="string"?e:"single"]??wf.single??{bottomLeft:"└",bottomRight:"┘",topLeft:"┌",topRight:"┐"},UL=({autoHide:e=!1,color:i,contentHeight:n,dimColor:o,placement:a="right",scrollOffset:t,style:s,thumbChar:r,trackChar:u,viewportHeight:d})=>{const l=D.useMemo(()=>{const p=Math.max(n,d);if(e&&p<=d)return null;const f=Ffe(s),w=r??f.thumb,v=u??f.track,j=d*2,C=Math.min(d/p,1),y=Math.max(2,Math.round(j*C)),k=p-d,S=k>0?Math.min(Math.max(t/k,0),1):0,J=j-y,T=Math.round(S*J),M=T+y,he=[];for(let Je=0;Je<d;Je+=1){const Se=Je*2,Le=Je*2+1,Xe=Se>=T&&Se<M,A=Le>=T&&Le<M;Xe&&A?he.push(w):Xe&&!A?he.push(f.lowerThumb??w):!Xe&&A?he.push(f.upperThumb??w):he.push(v)}return he},[n,d,t,s,r,u,e]);if(l===null)return null;if(a==="inset")return Y.jsx(_,{flexDirection:"column",flexShrink:0,width:1,children:l.map((p,f)=>Y.jsx(B,{color:i,dimColor:o,children:p},f))});const g=Qfe(s),h=a==="left"?g.topLeft:g.topRight,c=a==="left"?g.bottomLeft:g.bottomRight;return Y.jsxs(_,{flexDirection:"column",flexShrink:0,width:1,children:[Y.jsx(B,{color:i,dimColor:o,children:h}),l.map((p,f)=>Y.jsx(B,{color:i,dimColor:o,children:p},f)),Y.jsx(B,{color:i,dimColor:o,children:c})]})},VL=({children:e,debug:i=!1,followOutput:n=!1,followThreshold:o=3,keyboard:a=!1,onContentHeightChange:t,onItemHeightChange:s,onReachEnd:r,onReachStart:u,onScroll:d,onViewportSizeChange:l,overscan:g,reachThreshold:h=5,ref:c,scrollbar:p=!1,scrollbarColor:f,scrollbarStyle:w="line",vimBindings:v=!1,virtualize:j,...C})=>{const[y,k,S]=Hg(0),J=D.useRef(null),T=D.useRef(0),M=D.useRef(0),[he,Je]=D.useState(0),[Se,Le]=D.useState(0),Xe=D.useRef(!1),A=D.useRef(!1),$=D.useCallback(()=>Math.max(0,T.current-M.current),[]),P=D.useCallback(E=>{const ne=$();r&&E>=ne-h&&!Xe.current?(Xe.current=!0,r()):E<ne-h&&(Xe.current=!1),u&&E<=h&&!A.current?(A.current=!0,u()):E>h&&(A.current=!1)},[r,u,h,$]),W=D.useCallback(E=>{E!==S()&&(k(E),d?.(E),P(E))},[S,k,d,P]),H=D.useCallback((E,ne)=>{const Ae=S()>=$()-o;if(T.current=E,Je(E),t?.(E,ne),n&&Ae&&E>ne){const ii=Math.max(0,E-M.current);W(ii)}else{const ii=Math.max(0,E-M.current);S()>ii&&W(ii)}},[t,n,o,S,$,W]),N=D.useCallback((E,ne)=>{M.current=E.height,Le(E.height),l?.(E,ne)},[l]),X=D.useCallback(E=>{if(typeof E!="number"||Number.isNaN(E))return;const ne=Math.max(0,T.current-M.current),Ae=Math.max(0,Math.min(S()+E,ne));W(Ae)},[S,W]),G=D.useCallback(E=>{if(typeof E!="number"||Number.isNaN(E))return;const ne=Math.max(0,T.current-M.current),Ae=Math.max(0,Math.min(E,ne));W(Ae)},[W]),I=D.useCallback(()=>{const E=$();W(E)},[$,W]),V=D.useCallback(()=>{W(0)},[W]),te=D.useCallback(()=>M.current,[]);return Afe({getViewportHeight:te,isActive:a,scrollBy:X,scrollToBottom:I,scrollToTop:V,vimBindings:v}),D.useImperativeHandle(c,()=>({getBottomOffset:$,getContentHeight:()=>T.current,getItemHeight:E=>J.current?.getItemHeight(E)??0,getItemPosition:E=>J.current?.getItemPosition(E)??null,getScrollOffset:S,getViewportHeight:()=>M.current,remeasure:()=>J.current?.remeasure(),remeasureItem:E=>J.current?.remeasureItem(E),scrollBy:X,scrollTo:G,scrollToBottom:I,scrollToTop:V}),[$,S,X,G,I,V]),p&&he>Se&&Se>0?Y.jsxs(_,{flexDirection:"row",flexGrow:C.flexGrow,flexShrink:C.flexShrink,overflow:"hidden",children:[Y.jsx(mf,{children:e,debug:i,onContentHeightChange:H,onItemHeightChange:s,onViewportSizeChange:N,overscan:g,ref:J,scrollOffset:y,virtualize:j,...C,flexGrow:1}),Y.jsx(UL,{color:f,contentHeight:he,placement:"inset",scrollOffset:y,style:w,viewportHeight:Se})]}):Y.jsx(mf,{children:e,debug:i,onContentHeightChange:H,onItemHeightChange:s,onViewportSizeChange:N,overscan:g,ref:J,scrollOffset:y,virtualize:j,...C})},Mg=({backgroundColor:e,borderColor:i="cyan",borderStyle:n="round",children:o,columns:a,footer:t,maxHeight:s=.8,paddingX:r=2,paddingY:u=1,rows:d,scrollbarStyle:l="block",scrollRef:g,title:h,visible:c=!0,width:p=60})=>{const f=QL(),{isLoading:w,palette:v}=Yfe(),j=D.useRef(null),C=g??j;if(!c)return null;const y=a??(f.columns||80),k=d??(f.rows||24),S=e??(w?"black":v?.background??"black"),J=s<=1?Math.floor(k*s):Math.min(s,k-2),T=typeof h=="string"?Y.jsx(_,{marginBottom:1,children:Y.jsx(B,{bold:!0,color:i,children:h})}):h??null;return Y.jsx(_,{alignItems:"center",height:k,justifyContent:"center",position:"absolute",width:y,children:Y.jsxs(_,{backgroundColor:S,borderBackgroundColor:S,borderColor:i,borderStyle:n,flexDirection:"column",maxHeight:J,opaque:!0,paddingY:u,width:Math.min(p,y-4),children:[T!=null&&Y.jsx(_,{flexShrink:0,paddingX:r,children:T}),Y.jsx(VL,{flexGrow:1,flexShrink:1,paddingX:r,ref:C,scrollbar:!0,scrollbarColor:i,scrollbarStyle:l,children:o}),t!=null&&Y.jsx(_,{alignItems:"center",flexDirection:"column",flexShrink:0,marginTop:1,paddingX:r,children:t})]})})},eC=()=>D.useContext(DY),jf=({autoExitSeconds:e,onCancel:i,visible:n})=>{const{exit:o}=eC(),[a,t]=D.useState(e||3),s=D.useRef(null),r=D.useRef(0);D.useEffect(()=>{if(!n)return;const d=e||3;t(d),r.current=Date.now();let l=d;return s.current=setInterval(()=>{l-=1,l<=0?(s.current&&(clearInterval(s.current),s.current=null),t(0),o()):t(l)},1e3),()=>{s.current&&(clearInterval(s.current),s.current=null)}},[n,e,o]);const u=D.useCallback(()=>{s.current&&(clearInterval(s.current),s.current=null),i()},[i]);return tp((d,l)=>{Date.now()-r.current<200||(d==="q"?o():u())},{isActive:n}),Y.jsx(Mg,{backgroundColor:"#1e1e1e",footer:Y.jsxs(B,{dimColor:!0,children:["Press"," ",Y.jsx(B,{bold:!0,color:"white",children:"q"})," ","to exit,"," ",Y.jsx(B,{bold:!0,color:"white",children:"any key"})," ","to stay"]}),title:`Exiting in ${a}…`,visible:n,width:50,children:Y.jsx(B,{dimColor:!0,children:"Stay to explore the results interactively."})})},Wfe=e=>{if(e.startsWith("⚠"))return"yellow";e.startsWith("── ")||e.startsWith("[dry-run]")},Ife=({focused:e,item:i,scrollRef:n})=>{const o=e?"white":"gray";return i?Y.jsxs(_,{borderColor:o,borderStyle:"single",flexDirection:"column",flexGrow:1,children:[Y.jsx(_,{flexShrink:0,paddingTop:1,paddingX:2,children:Y.jsx(B,{bold:!0,color:"white",children:i.entry.title})}),Y.jsx(_,{flexShrink:0,paddingBottom:1,paddingX:2,children:Y.jsx(B,{dimColor:!0,children:i.entry.description})}),Y.jsx(VL,{flexGrow:1,flexShrink:1,paddingX:2,ref:n,scrollbar:!0,scrollbarColor:"gray",scrollbarStyle:"block",children:Y.jsxs(_,{flexDirection:"column",children:[Y.jsx(B,{dimColor:!0,children:"── What will change ──"}),Y.jsx(B,{}),i.preview.length===0&&Y.jsx(B,{dimColor:!0,children:"(no preview available)"}),i.preview.map((a,t)=>{const s=Wfe(a);return a===""?Y.jsx(B,{},`blank-${String(t)}`):Y.jsx(B,{color:s,children:a},`${String(t)}-${a.slice(0,20)}`)})]})})]}):Y.jsx(_,{alignItems:"center",borderColor:"gray",borderStyle:"single",flexDirection:"column",flexGrow:1,justifyContent:"center",children:Y.jsx(B,{dimColor:!0,children:"No migration selected"})})},_fe=({checked:e,isSelected:i,item:n})=>{const o=e?"☑":"☐",a=n.preview.length;return Y.jsxs(_,{flexShrink:0,height:1,children:[Y.jsx(B,{children:i?">":" "}),Y.jsxs(B,{color:e?"white":"gray",children:[" ",o," "]}),Y.jsx(_,{flexGrow:1,children:Y.jsx(B,{bold:i,inverse:i,wrap:"truncate",children:n.entry.title})}),Y.jsxs(B,{dimColor:!0,children:[" ",a," ","change",a===1?"":"s"," "]})]})},zfe=({checkedItems:e,focused:i,isDryRun:n,items:o,scrollOffset:a,selectedIndex:t,viewportHeight:s})=>{const r=i?"white":"gray",u=o.filter(h=>e.has(h.entry.id)).length,d=o.map((h,c)=>Y.jsx(_fe,{checked:e.has(h.entry.id),isSelected:c===t,item:h},h.entry.id)),l=o.length,g=l>s&&s>0;return Y.jsxs(_,{borderColor:r,borderStyle:"single",flexDirection:"column",flexGrow:1,children:[Y.jsxs(_,{flexShrink:0,gap:1,paddingX:1,children:[Y.jsx(B,{bold:!0,inverse:!0,children:" MIGRATE "}),Y.jsxs(B,{wrap:"truncate",children:[o.length," ","applicable"]}),u>0&&Y.jsxs(B,{dimColor:!0,children:[" — ",u," selected"]}),n&&Y.jsx(B,{color:"yellow",children:" (dry-run)"})]}),Y.jsxs(_,{flexDirection:"row",flexGrow:1,overflow:"hidden",children:[Y.jsx(_,{flexDirection:"column",flexGrow:1,overflow:"hidden",paddingLeft:1,children:Y.jsx(_,{flexDirection:"column",marginTop:-a,children:d})}),g&&Y.jsx(_,{flexShrink:0,marginLeft:1,marginRight:1,children:Y.jsx(UL,{contentHeight:l,placement:"inset",scrollOffset:a,style:"block",viewportHeight:s})})]})]})},Kfe=100,qfe=40,Ufe=10,Vfe=({autoExitSeconds:e=0,isDryRun:i,store:n})=>{const{exit:o}=eC(),{columns:a,rows:t}=QL(),s=D.useSyncExternalStore(n.subscribe,n.getSnapshot),[r,u]=D.useState(!1),[d,l]=D.useState(!1),[g,h]=D.useState(!1),[c,p]=D.useState(0),f=D.useRef(null),w=D.useRef(null),v=D.useRef(null),j=s.items[s.selectedIndex]??null,C=Math.max(1,t-6),y=D.useCallback(A=>{p($=>A>=$+C?Math.max(0,A-C+1):A<$?Math.max(0,A):$)},[C]);if(D.useEffect(()=>{w.current?.scrollToTop()},[j?.entry.id]),tp((A,$)=>{if(A==="c"&&$.ctrl){o();return}if(!g){if(d){A==="u"||$.return?(l(!1),n.startApply(),o(n.getCheckedItems())):$.escape||A==="q"?l(!1):$.downArrow||A==="j"?v.current?.scrollBy(1):($.upArrow||A==="k")&&v.current?.scrollBy(-1);return}if(r){$.escape||A==="?"?u(!1):A==="q"?(u(!1),h(!0)):$.downArrow||A==="j"?f.current?.scrollBy(1):($.upArrow||A==="k")&&f.current?.scrollBy(-1);return}if(A==="?"){u(!0);return}if(A==="q"){h(!0);return}if($.tab){n.setFocusedPanel(s.focusedPanel==="list"?"detail":"list");return}if(s.focusedPanel==="list"){if($.downArrow||A==="j"){const P=Math.min(s.selectedIndex+1,s.items.length-1);n.setSelectedIndex(P),y(P);return}if($.upArrow||A==="k"){const P=Math.max(s.selectedIndex-1,0);n.setSelectedIndex(P),y(P);return}if($.pageDown){const P=Math.min(s.selectedIndex+10,s.items.length-1);n.setSelectedIndex(P),y(P);return}if($.pageUp){const P=Math.max(s.selectedIndex-10,0);n.setSelectedIndex(P),y(P);return}if($.home){n.setSelectedIndex(0),p(0);return}if($.end){const P=s.items.length-1;n.setSelectedIndex(P),y(P);return}if(A===" "||$.return){j&&n.toggleCheck(j.entry.id);return}if(A==="a"){n.toggleAll();return}if(A==="u"&&!i&&s.checkedItems.size>0){l(!0);return}$.rightArrow&&n.setFocusedPanel("detail");return}if(s.focusedPanel==="detail"){if($.escape||$.leftArrow){n.setFocusedPanel("list");return}if($.downArrow||A==="j"){w.current?.scrollBy(1);return}if($.upArrow||A==="k"){w.current?.scrollBy(-1);return}if($.pageDown){w.current?.scrollBy(10);return}if($.pageUp){w.current?.scrollBy(-10);return}if($.home){w.current?.scrollToTop();return}$.end&&w.current?.scrollToBottom()}}},{isActive:!0}),a<qfe||t<Ufe)return Y.jsx(_,{alignItems:"center",height:t,justifyContent:"center",width:a,children:Y.jsxs(B,{color:"yellow",children:["Terminal too small (",a,"x",t,")"]})});const k=a>=Kfe,S=[Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"q"}),Y.jsx(B,{dimColor:!0,children:"QUIT"})]},"q"),Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"?"}),Y.jsx(B,{dimColor:!0,children:"HELP"})]},"?"),Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"↑↓"}),Y.jsx(B,{dimColor:!0,children:"NAV"})]},"nav"),Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"Space"}),Y.jsx(B,{dimColor:!0,children:"CHECK"})]},"sp"),Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"a"}),Y.jsx(B,{dimColor:!0,children:"ALL"})]},"a")];!i&&s.checkedItems.size>0&&S.push(Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"green",children:"u"}),Y.jsx(B,{dimColor:!0,children:"APPLY"})]},"u")),S.push(Y.jsxs(_,{gap:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"Tab"}),Y.jsx(B,{dimColor:!0,children:"PANEL"})]},"tab"));const J=Y.jsx(_,{borderBottom:!1,borderColor:"gray",borderLeft:!1,borderRight:!1,borderStyle:"single",flexShrink:0,children:Y.jsx(_,{flexWrap:"wrap",gap:2,paddingX:1,children:S})}),T=Y.jsxs(Mg,{footer:Y.jsxs(B,{dimColor:!0,children:[Y.jsx(B,{bold:!0,color:"white",children:"↑↓"})," scroll ",Y.jsx(B,{bold:!0,color:"white",children:"?"}),"/",Y.jsx(B,{bold:!0,color:"white",children:"Esc"})," close"]}),scrollRef:f,title:"KEYBOARD SHORTCUTS",visible:r,width:52,children:[Y.jsxs(_,{flexDirection:"column",marginBottom:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"NAVIGATION"}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" ↑/k"}),Y.jsx(B,{dimColor:!0,children:" Move up"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" ↓/j"}),Y.jsx(B,{dimColor:!0,children:" Move down"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" Tab"}),Y.jsx(B,{dimColor:!0,children:" Switch panel"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" →/←"}),Y.jsx(B,{dimColor:!0,children:" Focus detail/list"})]})]}),Y.jsxs(_,{flexDirection:"column",marginBottom:1,children:[Y.jsx(B,{bold:!0,color:"white",children:"SELECTION"}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" Space"}),Y.jsx(B,{dimColor:!0,children:" Toggle migration"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" a"}),Y.jsx(B,{dimColor:!0,children:" Toggle all"})]})]}),Y.jsxs(_,{flexDirection:"column",children:[Y.jsx(B,{bold:!0,color:"white",children:"ACTIONS"}),!i&&Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" u"}),Y.jsx(B,{dimColor:!0,children:" Apply selected migrations"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" q"}),Y.jsx(B,{dimColor:!0,children:" Quit"})]}),Y.jsxs(B,{children:[Y.jsx(B,{bold:!0,color:"white",children:" ?"}),Y.jsx(B,{dimColor:!0,children:" Toggle help"})]})]})]}),M=n.getCheckedItems(),he=Y.jsx(_,{alignItems:"center",flexDirection:"column",children:Y.jsxs(B,{dimColor:!0,children:["Press ",Y.jsx(B,{bold:!0,color:"white",children:"u"})," or ",Y.jsx(B,{bold:!0,color:"white",children:"Enter"})," to confirm, ",Y.jsx(B,{bold:!0,color:"white",children:"Esc"})," to cancel"]})}),Je=Y.jsx(Mg,{footer:he,scrollRef:v,title:`Apply ${String(M.length)} migration${M.length===1?"":"s"}?`,visible:d,width:70,children:M.map(A=>Y.jsxs(_,{gap:1,children:[Y.jsxs(B,{children:[" ",A.entry.title]}),Y.jsxs(B,{dimColor:!0,children:["(",A.preview.length," ","change",A.preview.length===1?"":"s",")"]})]},A.entry.id))}),Se=Y.jsx(zfe,{checkedItems:s.checkedItems,focused:s.focusedPanel==="list",isDryRun:i,items:s.items,scrollOffset:c,selectedIndex:s.selectedIndex,viewportHeight:C}),Le=Y.jsx(Ife,{focused:s.focusedPanel==="detail",item:j,scrollRef:w});if(k){const A=Math.floor(a*.55);return Y.jsxs(_,{flexDirection:"column",height:t,width:a,children:[Y.jsxs(_,{flexDirection:"row",flexGrow:1,children:[Y.jsx(_,{flexGrow:1,children:Se}),Y.jsx(_,{width:A,children:Le})]}),J,Je,Y.jsx(jf,{autoExitSeconds:e||3,onCancel:()=>{h(!1)},visible:g}),T]})}const Xe=Math.floor(t*.45);return Y.jsxs(_,{flexDirection:"column",height:t,width:a,children:[Y.jsx(_,{height:Xe,children:Se}),Y.jsx(_,{flexGrow:1,children:Le}),J,Je,Y.jsx(jf,{autoExitSeconds:e||3,onCancel:()=>{h(!1)},visible:g}),T]})},iC=[".lintstagedrc.json",".lintstagedrc"],nC=[".lintstagedrc.yaml",".lintstagedrc.yml",".lintstagedrc.mjs","lint-staged.config.mjs",".lintstagedrc.cjs","lint-staged.config.cjs",".lintstagedrc.js","lint-staged.config.js",".lintstagedrc.ts","lint-staged.config.ts",".lintstagedrc.mts","lint-staged.config.mts",".lintstagedrc.cts","lint-staged.config.cts"],oC=[...iC,...nC],eme=[/^((?:[A-Z_][A-Z0-9_]*(?:=\S*)?\s+)*)(pnpm|pnpm exec|npx|yarn|yarn run|npm exec|npm run|bunx|bun run|bun x)\s+lint-staged\b/,/^((?:[A-Z_][A-Z0-9_]*(?:=\S*)?\s+)*)lint-staged\b/],aC=[".nano-staged.json",".nanostagedrc"],tC=[".nano-staged.mjs",".nano-staged.cjs",".nano-staged.js","nano-staged.config.mjs","nano-staged.config.cjs","nano-staged.config.js","nano-staged.config.mts","nano-staged.config.cts","nano-staged.config.ts"],sC=[...aC,...tC],ime=[/^((?:[A-Z_][A-Z0-9_]*(?:=\S*)?\s+)*)(pnpm|pnpm exec|npx|yarn|yarn run|npm exec|npm run|bunx|bun run|bun x)\s+nano-staged\b/,/^((?:[A-Z_][A-Z0-9_]*(?:=\S*)?\s+)*)nano-staged\b/],rC=["husky","lint-staged","nano-staged"],nme=/\(is-ci \|\| husky \|\| exit 0\)\s*&&\s*/g,ome=/\bhusky(?:\s+install)?\s*&&\s*/g,ame=/\s*&&\s*husky(?:\s+install)?/g,tme=/\s*\|\|\s*husky(?:\s+install)?/g,sme=[nme,ome,ame,tme],uC=e=>{if(e==="husky"||e==="husky install")return;let i=e;for(const n of sme)i=i.replace(n,"");return i=i.trim(),i===e?e:i||void 0},rme="config.json",Sl=1,ume=new Set(["alwaysRun","args","builtin","entry","exclude","excludeTypes","fail","files","id","name","passFilenames","types","typesOr","verbose"]),dme=new Set(["failFast","skipInCI","stages","version"]),lme=["args","exclude","excludeTypes","files","passFilenames","types","typesOr"],dC=(e,i)=>L(e,i,rme),Pg=e=>e!==null&&typeof e=="object"&&!Array.isArray(e),sr=e=>{if(!Array.isArray(e))return;const i=[];for(const n of e){if(typeof n!="string")return;i.push(n)}return i},os=e=>typeof e=="boolean"?e:void 0,ha=e=>typeof e=="string"&&e.length>0?e:void 0,gme=(e,i,n)=>{if(!Pg(e))throw new TypeError("hook entry must be an object");if(typeof e.id!="string"||e.id.length===0)throw new TypeError("hook entry is missing `id`");const o={id:e.id},a=os(e.alwaysRun);a!==void 0&&(o.alwaysRun=a);const t=sr(e.args);t&&(o.args=t);const s=ha(e.builtin);s&&(o.builtin=s);const r=ha(e.entry);r&&(o.entry=r);const u=ha(e.exclude);u&&(o.exclude=u);const d=sr(e.excludeTypes);d&&(o.excludeTypes=d);const l=ha(e.fail);l&&(o.fail=l);const g=ha(e.files);g&&(o.files=g);const h=ha(e.name);h&&(o.name=h);const c=os(e.passFilenames);c!==void 0&&(o.passFilenames=c);const p=sr(e.types);p&&(o.types=p);const f=sr(e.typesOr);f&&(o.typesOr=f);const w=os(e.verbose);if(w!==void 0&&(o.verbose=w),[o.builtin,o.entry,o.fail].filter(v=>v!==void 0).length!==1)throw new TypeError(`hook "${o.id}" must set exactly one of \`builtin\`, \`entry\`, \`fail\``);if(o.fail!==void 0){const v=lme.filter(j=>o[j]!==void 0);if(v.length>0)throw new TypeError(`hook "${o.id}" is a \`fail\` entry — remove ${v.join(", ")} (filters do not apply)`)}for(const v of Object.keys(e))ume.has(v)||i.push({hookId:o.id,message:`unknown field "${v}" ignored`,stage:n});return o},hme=(e,i)=>{if(!Pg(e))throw new TypeError("hook config must be an object");if(e.version!==Sl)throw new TypeError(`unsupported hook config version: expected ${Sl}, got ${String(e.version)}`);if(!Pg(e.stages))throw new TypeError("hook config is missing `stages` map");const n={};for(const[s,r]of Object.entries(e.stages)){if(!Array.isArray(r))throw new TypeError(`hook config: stage "${s}" must be an array`);n[s]=r.map(u=>gme(u,i,s))}const o={stages:n,version:Sl},a=os(e.failFast);a!==void 0&&(o.failFast=a);const t=os(e.skipInCI);t!==void 0&&(o.skipInCI=t);for(const s of Object.keys(e))dme.has(s)||i.push({message:`unknown top-level field "${s}" ignored`});return o},cme=(e,i=ap,n)=>{const o=dC(e,i);if(!Z(o))return;const a=z(o);let t;try{t=JSON.parse(a)}catch(s){const r=s instanceof Error?s.message:String(s);throw new TypeError(`failed to parse ${o}: ${r}`,{cause:s})}return hme(t,[])},y1e=(e,i,n)=>{const o=dC(e,i);He(o,`${JSON.stringify(n,void 0,4)}
174
174
  `,"utf8")},pme=/\/$/,vme=e=>{if(e===Sa||!bp(Sa)||bp(e))return;const i=If(e);return i&&i!=="."&&vo(i),_f(Sa,e),`migrated ${Sa} → ${e}`},yme=e=>{let i='"$0"';for(let n=0;n<e;n+=1)i=`"$(dirname ${i})"`;return i},fme=(e,i={})=>{const n=e.split("/").filter(a=>a!==""&&a!==".").length+2,o=yme(n);return`#!/usr/bin/env sh
175
175
  { [ "$VIS_GIT_HOOKS" = "2" ]; } && set -x
176
176
  n=$(basename "$0")
@@ -189,7 +189,7 @@ c=$?
189
189
  [ $c = 127 ] && echo "vis - command not found in PATH=$PATH"
190
190
  exit $c`},mme=(e=ap)=>{if(process.env.VIS_GIT_HOOKS==="0")return{isError:!1,message:"skip install (git hooks disabled via VIS_GIT_HOOKS=0)"};if(e.includes(".."))return{isError:!0,message:'".." is not allowed in hooks directory path'};const i=La("git",["rev-parse","--show-prefix"]);if(i.status===null)return{isError:!0,message:"git command not found"};if(i.status!==0)return{isError:!1,message:".git directory not found (not a git repository)"};const n=vme(e),o=(h="")=>L(e,"_",h),a=i.stdout.toString().trim().replace(pme,""),t=a?`${a}/${e}/_`:`${e}/_`,s=a?`${a}/${Sa}/_`:`${Sa}/_`,r=La("git",["config","--local","core.hooksPath"]),u=r.status===0?r.stdout?.toString().trim():"";if(u&&u!==t&&u!==s)return{isError:!1,message:`core.hooksPath is already set to "${u}", skipping`};const{status:d,stderr:l}=La("git",["config","core.hooksPath",t]);if(d===null)return{isError:!0,message:"git command not found"};if(d)return{isError:!0,message:String(l)};const g=(()=>{try{return cme(process.cwd(),e)?.skipInCI??!1}catch{return!1}})();vo(o()),He(o(".gitignore"),"*"),He(o("h"),fme(e,{skipInCI:g}),{mode:493});for(const h of GL)He(o(h),`#!/usr/bin/env sh
191
191
  . "$(dirname "$0")/h"`,{mode:493});return{isError:!1,message:n??""}},bme=[".husky",".config/husky"],wme=/^\. "\$\(dirname "\$0"\)\/common\.sh"\s*/m,jme=e=>{for(const i of bme)if(Z(L(e,i))&&Eo(L(e,i)).isDirectory())return i},kme=(e,i)=>{const n=new Map,o=L(e,i),a=new Set(GL);for(const t of Fi(o)){if(t==="_"||t===".gitignore"||t.startsWith("."))continue;const s=L(o,t);Eo(s).isFile()&&(!a.has(t)&&t!=="common.sh"||n.set(t,z(s)))}return n},Sme=e=>e.replace(wme,""),lC=e=>Z(L(e,"pnpm-lock.yaml"))||Z(L(e,"pnpm-workspace.yaml"))?"pnpm":Z(L(e,"yarn.lock"))?"yarn":Z(L(e,"bun.lockb"))||Z(L(e,"bun.lock"))?"bun":"npm",Lme=(e,i)=>{const n=lC(e),o={bun:["bun","remove","husky"],npm:["npm","uninstall","husky"],pnpm:["pnpm","remove","husky"],yarn:["yarn","remove","husky"]},[a,...t]=o[n];i.info(`Removing husky package via ${n}...`);const s=La(a,t,{cwd:e,encoding:"utf8",stdio:"pipe"});return s.status!==0?(i.info(`Warning: failed to remove husky via ${n} (${s.stderr?.trim()??"unknown error"})`),!1):!0},Cme=(e,i,n)=>{const o=uC(n);if(o!==n)return o?(e[i]=o,`updated "${i}" script`):(delete e[i],`removed "${i}" script (was: "${n}")`)},Yme=(e,i)=>{const n=L(e,"package.json");if(!Z(n))return{modified:!1,removedScriptReferences:[]};const o=z(n),a=JSON.parse(o),t=[],s=a.scripts;if(s)for(const[r,u]of Object.entries(s)){if(typeof u!="string")continue;const d=Cme(s,r,u);d&&t.push(d)}if(t.length>0){const r=En(n,o,{defaultIndent:" ",useEditorconfig:i});He(n,`${JSON.stringify(a,void 0,r)}
192
- `,"utf8")}return{modified:t.length>0,removedScriptReferences:t}},ySe=(e,i,n,o={})=>{const a=jme(e),t=o.dryRun===!0;if(!a)return{isError:!0,message:"No husky installation found (.husky/ or .config/husky/)"};n.info(`Found husky at ${a}/`);const s=kme(e,a);if(s.size===0&&n.info("No user-defined hooks found in husky directory."),!t){const d=La("git",["config","--local","core.hooksPath"]),l=d.status===0?d.stdout?.toString().trim():"";l&&(l===".husky/_"||l.startsWith(".husky"))&&La("git",["config","--local","--unset","core.hooksPath"]);const g=mme(i);if(g.isError)return g;g.message&&n.info(g.message)}const r=L(e,i);t||vo(r);let u=0;for(const[d,l]of s){if(d==="common.sh"){t?n.info(" (would copy) common.sh"):(He(L(r,d),l,{mode:493}),n.info(" Copied common.sh"));continue}if(t)n.info(` (would migrate) ${d}`);else{const g=Sme(l);He(L(r,d),g,{mode:493}),n.info(` Migrated ${d}`)}u+=1}if(t)n.info(" (would remove) husky npm package and clean package.json scripts"),n.info(` (would remove) ${a}/ directory`);else{Lme(e,n);const d=Yme(e,o.useEditorconfig);if(d.modified){n.info("Updated package.json scripts:");for(const g of d.removedScriptReferences)n.info(` ${g}`)}const l=L(e,a);Ma(l,{force:!0,recursive:!0}),n.info(`Removed ${a}/`)}return{isError:!1,message:`${t?"would migrate":"Migration complete:"} ${u} hook${u===1?"":"s"} ${t?"from":"migrated from"} ${a}/ to ${i}/`}},we=(e,i)=>{if(!Z(e))return;const n=`${e}.bak`;Z(n)||(i?.backupsCreated.includes(n)??!1)||(aY(e,n),i&&i.backupsCreated.push(n))},Ue=e=>{try{const i=z(e);return JSON.parse(i)}catch{return}},ct=e=>{if(!Z(e))return!1;try{return JSON.parse(z(e)),!0}catch{return!1}},Os=(e,i,n={})=>En(e,i,{defaultIndent:" ",useEditorconfig:n.useEditorconfig}),qo=(e,i,n,o={})=>{if(!Z(e))return!1;const a=z(e);let t;try{t=JSON.parse(a)}catch{return!1}const s=i(t);if(s===void 0)return!1;const r=Os(e,a,o);return n&&we(e,n),He(e,`${JSON.stringify(s,void 0,r)}
192
+ `,"utf8")}return{modified:t.length>0,removedScriptReferences:t}},f1e=(e,i,n,o={})=>{const a=jme(e),t=o.dryRun===!0;if(!a)return{isError:!0,message:"No husky installation found (.husky/ or .config/husky/)"};n.info(`Found husky at ${a}/`);const s=kme(e,a);if(s.size===0&&n.info("No user-defined hooks found in husky directory."),!t){const d=La("git",["config","--local","core.hooksPath"]),l=d.status===0?d.stdout?.toString().trim():"";l&&(l===".husky/_"||l.startsWith(".husky"))&&La("git",["config","--local","--unset","core.hooksPath"]);const g=mme(i);if(g.isError)return g;g.message&&n.info(g.message)}const r=L(e,i);t||vo(r);let u=0;for(const[d,l]of s){if(d==="common.sh"){t?n.info(" (would copy) common.sh"):(He(L(r,d),l,{mode:493}),n.info(" Copied common.sh"));continue}if(t)n.info(` (would migrate) ${d}`);else{const g=Sme(l);He(L(r,d),g,{mode:493}),n.info(` Migrated ${d}`)}u+=1}if(t)n.info(" (would remove) husky npm package and clean package.json scripts"),n.info(` (would remove) ${a}/ directory`);else{Lme(e,n);const d=Yme(e,o.useEditorconfig);if(d.modified){n.info("Updated package.json scripts:");for(const g of d.removedScriptReferences)n.info(` ${g}`)}const l=L(e,a);Ma(l,{force:!0,recursive:!0}),n.info(`Removed ${a}/`)}return{isError:!1,message:`${t?"would migrate":"Migration complete:"} ${u} hook${u===1?"":"s"} ${t?"from":"migrated from"} ${a}/ to ${i}/`}},we=(e,i)=>{if(!Z(e))return;const n=`${e}.bak`;Z(n)||(i?.backupsCreated.includes(n)??!1)||(aY(e,n),i&&i.backupsCreated.push(n))},Ue=e=>{try{const i=z(e);return JSON.parse(i)}catch{return}},ct=e=>{if(!Z(e))return!1;try{return JSON.parse(z(e)),!0}catch{return!1}},Os=(e,i,n={})=>En(e,i,{defaultIndent:" ",useEditorconfig:n.useEditorconfig}),qo=(e,i,n,o={})=>{if(!Z(e))return!1;const a=z(e);let t;try{t=JSON.parse(a)}catch{return!1}const s=i(t);if(s===void 0)return!1;const r=Os(e,a,o);return n&&we(e,n),He(e,`${JSON.stringify(s,void 0,r)}
193
193
  `,"utf8"),!0},$me=/\blint-staged\b/g,Zme=(e,i)=>{let n=!1;const o={...e};for(const[a,t]of Object.entries(o)){if(typeof t!="string")continue;let s=uC(t);s&&(s=s.replaceAll($me,"vis staged").trim()||void 0),s!==t&&(s?o[a]=s:delete o[a],n=!0,i.rewrittenScriptCount+=1)}return{modified:n,scripts:o}},gC=(e,i,n,o)=>{const a=L(e,"package.json");Z(a)&&qo(a,t=>{let s=!1;for(const u of rC){const d=t.dependencies,l=t.devDependencies;d?.[u]&&(delete d[u],s=!0,o.removedPackageCount+=1),l?.[u]&&(delete l[u],s=!0,o.removedPackageCount+=1)}if(Object.keys(n).length>0)switch(i){case"bun":{const u=t.workspaces,d=u&&!Array.isArray(u)?u:void 0,l={...d?.catalog??t.catalog};for(const[h,c]of Object.entries(n))l[h]=c;d?.catalog===void 0?t.catalog=l:d.catalog=l;const g=t.overrides??{};for(const h of Object.keys(n))g[h]="catalog:";t.overrides=g,s=!0;break}case"npm":{const u=t.overrides??{};t.overrides={...u,...n},s=!0;break}case"pnpm":{const u=t.pnpm??{},d=u.overrides??{};u.overrides={...d,...n},t.pnpm=u,s=!0;break}case"yarn":{const u=t.resolutions??{};t.resolutions={...u,...n},s=!0;break}}const r=t.scripts;if(r){const u=Zme(r,o);u.modified&&(t.scripts=u.scripts,s=!0)}return s?t:void 0})},Jme=(e,i,n,o)=>{try{const{workspace:a}=BY(e);for(const t of Object.values(a.projects)){const s=L(e,t.root);gC(s,i,n,o)}}catch{}},xme=e=>e.startsWith("- ")||e!==""&&!e.includes(":")&&!e.startsWith("#"),Tme=e=>{let i=!1,n="";const o=new Set;for(const a of e){const t=a.trim();if(t==="catalog:"){i=!0;continue}if(!i)continue;if(xme(t))break;const s=t.includes(":")?t.split(":")[0]?.trim():void 0;s&&(o.add(s),n=n||a.slice(0,a.indexOf(t)))}return{entries:o,indent:n||" "}},Dme=(e,i,n)=>{const o=[];let a=!1,t=!1;for(let s=0;s<e.length;s+=1){const r=e[s],u=r.trim();if(o.push(r),u==="catalog:"){t=!0;continue}if(t&&!a){const d=e[s+1]?.trim()??"";(!d.includes(":")||d.startsWith("- ")||!d||d==="catalog:")&&(o.push(...i),a=!0,t=!1)}}return a||(n.includes("catalog:")||o.push("catalog:"),o.push(...i)),o},Bme=(e,i)=>{const n=L(e,"pnpm-workspace.yaml");if(!Z(n)||Object.keys(i).length===0)return;const o=z(n),a=o.split(`
194
194
  `),{entries:t,indent:s}=Tme(a),r=[];for(const[d,l]of Object.entries(i))t.has(d)||r.push(`${s}${d}: "${l}"`);if(r.length===0)return;const u=Dme(a,r,o);we(n),He(n,u.join(`
195
195
  `),"utf8")},kf=(e,i,n,o,a,t)=>{const s=n.overrides??{};if(o.dryRun){a.info("[dry-run] Would rewrite package.json files (remove husky/lint-staged, rewrite scripts)"),Object.keys(s).length>0&&a.info(`[dry-run] Would add overrides: ${JSON.stringify(s)}`);return}gC(e,i,s,t),a.info("Rewritten root package.json"),Jme(e,i,s,t),i==="pnpm"&&Bme(e,s)},Mi=()=>({backupsCreated:[],gitHooksConfigured:!1,inlinedLintStagedConfigCount:0,manualSteps:[],mergedStagedConfigCount:0,perMigration:{},removedConfigCount:0,removedPackageCount:0,rewrittenScriptCount:0,warnings:[]}),ge=(e,i)=>{!e||e.warnings.includes(i)||e.warnings.push(i)},ve=(e,i)=>{!e||e.manualSteps.includes(i)||e.manualSteps.push(i)},ni=(e,i,n,o=1)=>{const a=e.perMigration[i]??{removedConfigCount:0,removedPackageCount:0,rewrittenScriptCount:0};a[n]+=o,e.perMigration[i]=a,e[n]+=o},Xme=["gitleaks.toml",".gitleaks.toml"],Hme=["gitleaks-report.json",".gitleaks-report.json","baseline.json"],ed=e=>Xme.find(i=>Z(L(e,i))),sp=e=>{const i=L(e,".gitleaksignore");return Z(i)?i:void 0},rp=e=>{for(const i of Hme){const n=L(e,i);if(Z(n))try{const o=JSON.parse(z(n));if(Array.isArray(o)&&o.length>0&&typeof o[0]=="object"&&o[0]!==null&&"RuleID"in o[0])return n}catch{}}},Mme=e=>e.map(i=>({description:i.Description??"",endColumn:i.EndColumn??0,endLine:i.EndLine??i.StartLine??0,entropy:i.Entropy??0,file:i.File??"",match:i.Match??"",ruleId:i.RuleID??"",secret:i.Secret??"",startColumn:i.StartColumn??0,startLine:i.StartLine??0,tags:i.Tags??[]})),Pme=(e,i,n,o,a)=>{const t=rp(e);if(!t)return;const s=L(e,".secrets-baseline.json");if(Z(s)&&t!==s){ge(o,`.secrets-baseline.json already exists — leaving ${t} in place`);return}const r=Ue(t);if(!Array.isArray(r)){ge(o,`Could not parse ${t} as a gitleaks baseline`);return}const u=Mme(r);if(i){n.info(`[dry-run] Would convert ${t} -> ${s} (${String(u.length)} findings)`);return}we(t,o),ui(s,`${JSON.stringify(u,null,En(s,void 0,{defaultIndent:" ",useEditorconfig:a}))}
@@ -227,7 +227,7 @@ ${Eg(i)},
227
227
  `)),!0):!1},kbe=(e,i,n)=>{if(i==="package.json")return ybe(e);const o=L(e,i);if(!aC.includes(i)){ge(n,`${i} cannot be auto-migrated — please add "staged" config to vis.config.ts manually`),ve(n,`Manually convert ${i} to staged config in vis.config.ts`);return}if(i===".nanostagedrc"&&!ct(o)){ge(n,".nanostagedrc is not JSON format — please migrate manually");return}return fbe(o)},mC=(e,i,n)=>{const{configRemoved:o,dependencyRemoved:a}=bbe(e,n);o&&(i.inlinedLintStagedConfigCount+=1),a&&(i.removedPackageCount+=1),wbe(e,i)},Sbe=(e,i,n,o)=>{const a=[".vis/hooks",".husky"];for(const t of a)Z(L(e,t))&&jbe(e,t)&&(o.gitHooksConfigured=!0,i.silent||n.info(`Rewrote pre-commit hook in ${t}/ to use "vis staged"`))},Lbe=(e,i,n,o,a)=>{mbe(e,i,o)&&(a.mergedStagedConfigCount+=1),mC(e,a,n.useEditorconfig),Sbe(e,n,o,a)},Df=(e,i,n,o)=>{const a=fC(e);if(!a)return i.silent||n.info("No nano-staged configuration found — nothing to migrate."),!1;if(pbe(e)&&(ge(o,'Non-JSON nano-staged config found — please migrate to "staged" in vis.config.ts manually'),ve(o,"Convert your nano-staged config file to JSON format or add staged config to vis.config.ts manually")),vbe(e))return ge(o,'vis.config.ts already has a "staged" config — skipping nano-staged merge'),i.silent||n.warn('vis.config.ts already has a "staged" config — skipping'),i.dryRun||mC(e,o,i.useEditorconfig),!0;const t=kbe(e,a,o);return!t||Object.keys(t).length===0?(i.silent||n.warn("nano-staged config is empty — skipping"),!1):i.dryRun?(i.silent||(n.info("[dry-run] Would insert staged config into vis.config.ts:"),n.info(Eg(t))),!0):(Lbe(e,t,i,n,o),!0)},pi=(e,i)=>{const n=ws(e,i);return n.startsWith("..")?i:n.split(qC).join("/")},Cbe=new Set([".cache",".git",".next",".nx",".output",".svelte-kit",".turbo",".vercel",".vis","build","coverage","dist","node_modules"]),Ybe=(e,i=8)=>{const n=[],o=(a,t)=>{if(t>i)return;let s;try{s=Fi(a)}catch{return}for(const r of s){if(Cbe.has(r)||r.startsWith("."))continue;const u=L(a,r);let d;try{d=Eo(u)}catch{continue}d.isDirectory()?o(u,t+1):r==="project.json"&&n.push(u)}};return o(e,0),n},$be={"@nx/eslint:lint":"lint:eslint","@nx/jest:jest":"test","@nx/js:tsc":"build","@nx/next:build":"build","@nx/playwright:playwright":"test:e2e","@nx/storybook:build":"build-storybook","@nx/vite:build":"build","@nx/vite:test":"test","@nx/webpack:webpack":"build"},Zbe=["cache","dependsOn","inputs","outputs","persistent"],Jbe=(e,i,n)=>{const o={};for(const[a,t]of Object.entries(e))a.includes(":")||(o[a]=t);for(const[a,t]of Object.entries(e)){if(!a.includes(":"))continue;const s=$be[a];if(!s){i.warnings.push(`Dropped \`${a}\` from tasks — vis only supports script-name targets, not nx-namespaced executors.`);continue}if(o[s]){i.warnings.push(`Dropped \`${a}\` from tasks — \`${s}\` already has an explicit entry; the explicit one was kept.`);continue}const r={},u=[];for(const l of Zbe)t[l]!==void 0&&(r[l]=t[l],u.push(l));o[s]=r;const d=u.length>0?`carried ${u.join(", ")}`:"no settings to carry";n?.info(`Translated \`${a}\` → \`${s}\` in tasks (${d}).`)}return o},xbe=(e,i,n)=>{const o={},a=e.affected?.defaultBase??e.defaultBase;return typeof a=="string"&&a.length>0&&a!=="main"&&(o.defaultBase=a),e.namedInputs&&Object.keys(e.namedInputs).length>0&&(o.namedInputs=e.namedInputs),e.targetDefaults&&Object.keys(e.targetDefaults).length>0&&(o.tasks=e.targetDefaults),["// Migrated from nx.json by `vis migrate nx`.","// Per-project project.json files are compatible with vis and do not need to be rewritten —","// vis already reads targets, tags, implicitDependencies, and sourceRoot.","",'import { defineConfig } from "@visulima/vis/config";',"",`export default defineConfig(${dp(o,L(i,"vis.config.ts"),n)});`,""].join(`
228
228
  `)},Ll=/node_modules\/nx\/schemas\/project-schema\.json$/u,Tbe=(e,i,n,o)=>{let a=0;for(const t of e){if(i.dryRun){const s=gp(t);s?.$schema&&Ll.test(s.$schema)&&(n.info(`Would rewrite $schema in ${t}`),a+=1);continue}qo(t,s=>{if(!(!s.$schema||!Ll.test(s.$schema)))return s.$schema=s.$schema.replace(Ll,"node_modules/@visulima/vis/schemas/project.schema.json"),s},o,{useEditorconfig:i.useEditorconfig})&&(a+=1)}return a>0&&n.info(`Rewrote $schema in ${String(a)} project.json file(s).`),a},gp=e=>{if(Z(e))try{return JSON.parse(z(e))}catch{return}},Dbe=e=>{const i=new Map,n=new Set;for(const o of e){const a=gp(o);if(!a?.name)continue;n.add(a.name);const t=L(no(o),"package.json");if(Z(t))try{const s=JSON.parse(z(t));s.name&&s.name!==a.name&&i.set(s.name,a.name)}catch{}}return{knownProjects:n,pkgToProject:i}},Bbe=/&&|\|\||[;|><`]|\$\(/u,Xbe=/[*[\]^.]/u,Cl=(e,i)=>{if(i===""){e.complex=!0;return}if(i.startsWith("!")){e.hasExclusion=!0;return}if(Xbe.test(i)||i.includes("...")){e.hasGlob=!0;return}e.filters.push(i)},Hbe=e=>{if(typeof e!="string"||e.trim()===""||Bbe.test(e)||/['"]/u.test(e))return null;const i=e.trim().split(/\s+/u);if(i[0]!=="pnpm"&&i[0]!=="pnpm.cmd")return null;const n={complex:!1,filters:[],hasExclusion:!1,hasGlob:!1,parallel:!1,recursive:!1,target:""};let o=1;for(;o<i.length;){const a=i[o];if(a==="--filter"||a==="-F"){const t=i[o+1];if(t===void 0)return n.complex=!0,n;Cl(n,t),o+=2;continue}if(a.startsWith("--filter=")){Cl(n,a.slice(9)),o+=1;continue}if(a.startsWith("-F=")){Cl(n,a.slice(3)),o+=1;continue}if(a==="--parallel"){n.parallel=!0,o+=1;continue}if(a==="-r"||a==="--recursive"){n.recursive=!0,o+=1;continue}if(a==="--workspace-root"||a==="-w")return n.complex=!0,n;if(a==="run"||a==="exec"){if(a==="exec")return n.complex=!0,n;o+=1;continue}return a.startsWith("-")?(n.complex=!0,n):(n.target=a,o+=1,o<i.length&&(n.complex=!0),n)}return n.complex=!0,n},Mbe=(e,i)=>{const n=[],o=[];for(const a of e){const t=i.pkgToProject.get(a);if(t!==void 0){n.push(t);continue}if(i.knownProjects.has(a)){n.push(a);continue}o.push(a)}return{mapped:n,unmapped:o}},Pbe=(e,i)=>{const n=["vis","run",e.target];if(i.length>0){const o=[...i].sort((a,t)=>a.localeCompare(t)).join(",");n.push(`--projects=${o}`)}return n.join(" ")},Nbe=new Set(["dev","dev:server","dev:watch","serve","start:dev","storybook","watch"]),Ebe=(e,i,n,o,a)=>{const t={rewrittenTargets:new Set,unmappedHits:[]},s=L(e,"package.json");if(!Z(s))return t;let r;try{r=JSON.parse(z(s))}catch{return t}if(!r.scripts)return t;const u=new Map;for(const[d,l]of Object.entries(r.scripts)){const g=Hbe(l);if(!g||g.target===""||g.complex)continue;if(g.hasExclusion||g.hasGlob){a.warnings.push(`pnpm filter in scripts.${d} uses ${g.hasExclusion?"an exclusion (!)":"a glob/dependency selector"} — left untouched. Translate by hand to \`vis run ${g.target} --projects=...\` once you decide which projects should be selected.`);continue}if(g.filters.length===0&&!g.recursive)continue;const h=Mbe(g.filters,i);if(h.unmapped.length>0){t.unmappedHits.push({filters:h.unmapped,script:d});continue}const c=Pbe(g,h.mapped);c!==l&&(u.set(d,c),t.rewrittenTargets.add(g.target))}if(u.size===0)return t;if(n.dryRun){for(const[d,l]of u){const g=r.scripts[d];o.info(`Would rewrite scripts.${d}: \`${g??""}\` → \`${l}\``)}return t}return qo(s,d=>{if(!d.scripts)return;const l={...d.scripts};let g=!1;for(const[h,c]of u)l[h]!==void 0&&l[h]!==c&&(l[h]=c,g=!0);if(g)return d.scripts=l,d},a,{useEditorconfig:n.useEditorconfig}),o.info(`Rewrote ${String(u.size)} pnpm-filter script(s) in package.json to use \`vis run\`.`),t},Rbe=(e,i,n)=>{let o=e.targetDefaults??{},a=!1;for(const t of i){if(!Nbe.has(t))continue;const s={...o[t]??{}};let r=!1;s.persistent!==!0&&(s.persistent=!0,r=!0),s.cache!==!1&&(s.cache=!1,r=!0),r&&(o={...o,[t]:s},a=!0,n.manualSteps.push(`tasks.${t} set to { persistent: true, cache: false } — long-running task auto-detected from rewritten pnpm filter scripts. Adjust if your ${t} is actually short-lived.`))}a&&(e.targetDefaults=o)},Obe=e=>{if(e.executor!=="nx:run-script")return!1;const i=Object.keys(e.options??{});return i.length===0||i.length===1&&i[0]==="script"},Abe=(e,i,n,o)=>{let a=0,t=0,s=0;const r=[];for(const u of e){const d=gp(u);if(!d?.targets||Object.keys(d.targets).length===0)continue;const l=d.name??"<unnamed>",g=[],h=[],c=[];for(const[w,v]of Object.entries(d.targets))v.syncGenerators&&v.syncGenerators.length>0&&c.push({sync:[...v.syncGenerators],target:w}),Obe(v)?h.push(w):g.push(w);const p=g.length===0&&h.length>0,f=h.length>0;p?(i.dryRun?(n.info(`Would remove targets block from ${u} (all entries are nx:run-script shims).`),a+=1):(qo(u,w=>{if(w.targets)return delete w.targets,w},o,{useEditorconfig:i.useEditorconfig}),a+=1),c.length>0&&r.push({file:u,name:l,nonShimTargets:[],syncGenerators:c})):f?(i.dryRun?n.info(`Would strip ${String(h.length)} nx:run-script shim entr(y/ies) from ${u} (non-shim entries kept: ${g.join(", ")}).`):qo(u,w=>{if(w.targets){for(const v of h)Reflect.deleteProperty(w.targets,v);return w}},o,{useEditorconfig:i.useEditorconfig}),t+=1,s+=h.length,r.push({file:u,name:l,nonShimTargets:g,syncGenerators:c})):r.push({file:u,name:l,nonShimTargets:g,syncGenerators:c})}return a>0&&n.info(`Removed targets block from ${String(a)} project.json file(s) (entries were nx:run-script shims).`),s>0&&!i.dryRun&&n.info(`Stripped ${String(s)} nx:run-script shim entr(y/ies) across ${String(t)} project.json file(s) (non-shim entries remain for manual review).`),{droppedTargetBlocks:a,partialTargetBlocks:t,punchList:r,strippedShimEntries:s}},Gbe=(e,i,n,o)=>{const a=L(e,"pnpm-workspace.yaml");if(!Z(a))return{catalogEntriesRemoved:0,onlyBuiltRemoved:!1};let t;try{t=Ro(a)}catch{return{catalogEntriesRemoved:0,onlyBuiltRemoved:!1}}if(!t||typeof t!="object")return{catalogEntriesRemoved:0,onlyBuiltRemoved:!1};let s=0;const r=h=>h==="nx"||h.startsWith("@nx/"),u=(h,c,p)=>{if(!h||typeof h!="object")return;const f=Object.keys(h).length,w=Object.fromEntries(Object.entries(h).filter(([j])=>!r(j))),v=f-Object.keys(w).length;v>0&&(s+=v,c[p]=w)};u(t.catalog,t,"catalog");const d=t.catalogs;if(d&&typeof d=="object")for(const[h,c]of Object.entries(d))u(c,d,h);let l=!1;const g=t.onlyBuiltDependencies;if(Array.isArray(g)){const h=g.filter(c=>c!=="nx");h.length!==g.length&&(t.onlyBuiltDependencies=h,l=!0)}return(s>0||l)&&(i.dryRun?(s>0&&n.info(`Would remove ${String(s)} nx-related catalog entr(y/ies) from pnpm-workspace.yaml.`),l&&n.info("Would remove `nx` from pnpm-workspace.yaml#onlyBuiltDependencies.")):(we(a,o),am(a,t),s>0&&n.info(`Removed ${String(s)} nx-related catalog entr(y/ies) from pnpm-workspace.yaml.`),l&&n.info("Removed `nx` from pnpm-workspace.yaml#onlyBuiltDependencies."))),{catalogEntriesRemoved:s,onlyBuiltRemoved:l}},Fbe=(e,i,n,o,a,t,s)=>{const r=L(no(e),"package.json");if(!Z(r))return{reason:"no sibling package.json"};const u=`pre${n}`,d=`echo "TODO(vis): replace with logic equivalent to nx syncGenerators: ${o.join(", ")}" && exit 1`;if(a.dryRun){let g;try{g=JSON.parse(z(r)).scripts}catch{return{reason:"package.json unreadable"}}return g?.[u]?{reason:`\`${u}\` script already exists in ${pi(i,r)}`}:(t.info(`Would add \`${u}\` script to ${pi(i,r)} (TODO for nx syncGenerators: ${o.join(", ")}).`),{pkgPath:pi(i,r),preScript:u})}let l;return qo(r,g=>{if(g.scripts?.[u]){l=`\`${u}\` script already exists in ${pi(i,r)}`;return}return g.scripts={...g.scripts,[u]:d},g},s,{useEditorconfig:a.useEditorconfig})?(t.info(`Added \`${u}\` script (TODO) to ${pi(i,r)} — wire up replacement for: ${o.join(", ")}.`),{pkgPath:pi(i,r),preScript:u}):{reason:l??"package.json unwritable"}},Qbe=/^nx\s+(?:run-many|run|affected|reset|repair)\b|^nx\s+exec\b/u,Wbe=new Set(["affected","exec","repair","reset","run","run-many"]),Ibe=(e,i)=>{const n=e.trim();if(/[;&|"']/u.test(n))return;const o=/^nx\s+run-many\s+(?:-t|--target=?)\s*([\w:-]+)\s*$/u.exec(n);if(o)return`vis run ${o[1]}`;const a=/^nx\s+affected\s+(?:-t|--target=?)\s*([\w:-]+)\s*$/u.exec(n);if(a)return`vis run ${a[1]} --affected`;const t=/^nx\s+run\s+([\w@/-]+):([\w:-]+)\s*$/u.exec(n);if(t?.[1]&&t[2]&&i.has(t[1]))return`vis run ${t[2]} --projects=${t[1]}`;const s=/^nx\s+([\w:-]+)\s*$/u.exec(n);if(s?.[1]&&!Wbe.has(s[1]))return`vis run ${s[1]}`},_be=(e,i,n,o,a)=>{const t={deletedFiles:[],rewrittenScripts:[],skippedScripts:[],strippedDevDeps:[]},s=L(e,".github","ignore-files-for-nx-affected.yml");if(Z(s))if(n.dryRun)o.info(`Would delete ${pi(e,s)}.`),t.deletedFiles.push(pi(e,s));else{we(s,a);try{yo(s),o.info(`Removed ${pi(e,s)} (backup at \`${pi(e,s)}.bak\`).`),t.deletedFiles.push(pi(e,s))}catch{}}const r=L(e,"package.json");if(!Z(r))return t;if(qo(r,u=>{let d=!1;if(u.devDependencies)for(const l of Object.keys(u.devDependencies))(l==="nx"||l.startsWith("@nx/")||l.startsWith("@nrwl/"))&&(n.dryRun||Reflect.deleteProperty(u.devDependencies,l),t.strippedDevDeps.push(l),d=!0);if(u.scripts)for(const[l,g]of Object.entries(u.scripts)){if(typeof g!="string"||!(Qbe.test(g)||g.startsWith("nx ")))continue;const h=Ibe(g,i);if(h===void 0){t.skippedScripts.push(l);continue}n.dryRun||(u.scripts[l]=h),t.rewrittenScripts.push({from:g,name:l,to:h}),d=!0}return d?u:void 0},n.dryRun?void 0:a,{useEditorconfig:n.useEditorconfig}),t.strippedDevDeps.length>0){const u=n.dryRun?"Would strip":"Stripped";o.info(`${u} ${String(t.strippedDevDeps.length)} nx-related devDependenc(y/ies) from package.json: ${t.strippedDevDeps.join(", ")}.`)}for(const u of t.rewrittenScripts){const d=n.dryRun?"Would rewrite":"Rewrote";o.info(`${d} \`scripts.${u.name}\`: \`${u.from}\` -> \`${u.to}\``)}return t.skippedScripts.length>0&&a.manualSteps.push(`--aggressive could not rewrite these package.json scripts (they have shell complexity or unknown flags): ${t.skippedScripts.join(", ")}. Rewrite them manually to use \`vis run\`.`),t},zbe=e=>{const i={eslintHits:[],ignoreFile:!1,nxJson:!1,pkgDevDeps:[],pkgScripts:[],workflowHits:[]};Z(L(e,"nx.json"))&&(i.nxJson=!0),Z(L(e,".github/ignore-files-for-nx-affected.yml"))&&(i.ignoreFile=!0);const n=L(e,"package.json");if(Z(n))try{const a=JSON.parse(z(n));if(a.devDependencies)for(const t of Object.keys(a.devDependencies))(t==="nx"||t.startsWith("@nx/")||t.startsWith("@nrwl/"))&&i.pkgDevDeps.push(t);if(a.scripts)for(const[t,s]of Object.entries(a.scripts))typeof s=="string"&&(/\bnx\s+(?:run-many|run|affected|exec|reset|repair)\b/u.test(s)||s.startsWith("nx "))&&i.pkgScripts.push(t)}catch{}const o=L(e,".github/workflows");if(Z(o))try{for(const a of Fi(o)){if(!a.endsWith(".yml")&&!a.endsWith(".yaml"))continue;const t=L(o,a),s=z(t);/nrwl\/nx-set-shas/u.test(s)&&i.workflowHits.push({file:`.github/workflows/${a}`,reason:"uses nrwl/nx-set-shas action"}),/\bNX_BRANCH\b|\bNX_RUN_GROUP\b/u.test(s)&&i.workflowHits.push({file:`.github/workflows/${a}`,reason:"sets NX_BRANCH / NX_RUN_GROUP env"}),(/--files=\$\{\{[^}]*tj-actions/u.test(s)||/tj-actions\/changed-files/u.test(s))&&i.workflowHits.push({file:`.github/workflows/${a}`,reason:"uses tj-actions/changed-files (no longer needed; vis does its own affected diff)"})}}catch{}for(const a of["eslint.config.mjs","eslint.config.js","eslint.config.cjs","eslint.config.ts",".eslintrc.json",".eslintrc.js"]){const t=L(e,a);if(!Z(t))continue;const s=z(t);/@nx\/eslint-plugin|@nx\/enforce-module-boundaries|@nx\/dependency-checks|@nx\/nx-plugin-checks/u.test(s)&&i.eslintHits.push(a)}return i},Kbe=(e,i,n)=>{const o=[];if(e.nxJson&&!n.backedUpNxJson&&o.push(`Remove ${L(i,"nx.json")} once you're satisfied with vis.config.ts.`),e.ignoreFile&&o.push("Delete .github/ignore-files-for-nx-affected.yml — vis uses git-based affected diff and has no equivalent."),e.pkgDevDeps.length>0&&o.push(`Remove these nx devDependencies from package.json: ${e.pkgDevDeps.join(", ")}.`),e.pkgScripts.length>0&&o.push(`Rewrite these package.json scripts to use \`vis run\`: ${e.pkgScripts.join(", ")}.`),e.workflowHits.length>0){const a=new Map;for(const t of e.workflowHits){const s=a.get(t.file)??new Set;s.add(t.reason),a.set(t.file,s)}for(const[t,s]of a)o.push(`Update ${t}: ${[...s].join("; ")}.`)}return e.eslintHits.length>0&&o.push(`Remove @nx/eslint-plugin imports + rules (enforce-module-boundaries, dependency-checks, nx-plugin-checks) from: ${e.eslintHits.join(", ")}. There is no vis equivalent yet.`),o.map((a,t)=>`${String(t+1)}. ${a}`)},qbe=(e,i)=>{if(e.length!==0){i.info(""),i.info("── Post-migrate cleanup ──");for(const n of e)i.info(n)}},Bf=(e,i,n,o)=>{i.aggressive&&(i={...i,force:!0,rewriteSyncGenerators:!0});const a=yC(e,"nx.json");if(!a){n.warn("No nx.json found in workspace root — nothing to migrate."),o.warnings.push("No nx.json at workspace root.");return}a.targetDefaults&&(a.targetDefaults=Jbe(a.targetDefaults,o,n));const t=Ybe(e),s=Dbe(t),r=Ebe(e,s,i,n,o);Rbe(a,r.rewrittenTargets,o);for(const c of r.unmappedHits)o.warnings.push(`scripts.${c.script}: pnpm filter(s) ${c.filters.map(p=>`\`${p}\``).join(", ")} don't match any known project.json#name or sibling package.json#name. Left untouched — fix the filter or add the missing project.json before re-running.`);const u=xbe(a,e,i.useEditorconfig);if(!lp(e,u,i,n,o))return;Tbe(t,i,n,o);const{punchList:d}=Abe(t,i,n,o);for(const c of d){c.nonShimTargets.length>0&&o.manualSteps.push(`Review targets in ${pi(e,c.file)} (project: ${c.name}) — non-shim targets need manual review: ${c.nonShimTargets.join(", ")}.`);for(const p of c.syncGenerators){if(i.rewriteSyncGenerators){const f=Fbe(c.file,e,p.target,p.sync,i,n,o);if("preScript"in f){o.manualSteps.push(`${f.pkgPath} now has a \`${f.preScript}\` script that fails with a TODO. Replace it with the real equivalent of nx syncGenerators: ${p.sync.join(", ")}.`);continue}o.warnings.push(`syncGenerators on \`${c.name}#${p.target}\` (${pi(e,c.file)}) not auto-rewritten — ${f.reason}. Move ${p.sync.join(", ")} into a \`pre${p.target}\` script in package.json manually.`);continue}o.warnings.push(`syncGenerators on \`${c.name}#${p.target}\` (${pi(e,c.file)}) has no vis equivalent. Move ${p.sync.join(", ")} into a \`pre${p.target}\` script in package.json (or re-run with --rewrite-sync-generators to insert a TODO automatically).`)}}Gbe(e,i,n,o),i.aggressive&&_be(e,s.knownProjects,i,n,o),o.manualSteps.push("vis adds two task primitives nx doesn't expose declaratively: `when: { os, env, branch, ci, not.* }` for conditional execution (replaces ad-hoc `configurations`) and `always: true` for finally/teardown tasks that run even when upstream fails. See docs/guides/conditional-and-finally-tasks.mdx.");const l=a.affected?.defaultBase??a.defaultBase;typeof l=="string"&&l.length>0&&l!=="main"&&n.info(`Translated nx's default base branch (${l}) into vis.config.ts#defaultBase.`);const g=zbe(e),h=Kbe(g,e,{});if(qbe(h,n),i.force&&!i.dryRun&&g.nxJson){const c=L(e,"nx.json");we(c,o);try{yo(c),n.info(`Removed ${c} (backup at ${c}.bak).`)}catch{}}},bC=[".secretlintrc",".secretlintrc.json",".secretlintrc.js",".secretlintrc.mjs",".secretlintrc.cjs",".secretlintrc.yml",".secretlintrc.yaml"],wC=[".secretlintignore"],jC=e=>bC.find(i=>Z(L(e,i))),kC=e=>wC.find(i=>Z(L(e,i))),Ube=(e,i,n)=>{if(i.endsWith(".js")||i.endsWith(".mjs")||i.endsWith(".cjs"))return ge(n,`${i} is a JS config — cannot auto-extract rule IDs. Review manually to confirm coverage.`),[];if(i.endsWith(".yml")||i.endsWith(".yaml"))return ge(n,`${i} is YAML — cannot auto-extract rule IDs without a YAML parser. Review manually.`),[];const o=Ue(L(e,i));if(!o)return[];const a=new Set,t=s=>{if(s)for(const r of s)r.id&&a.add(r.id),r.rules&&t(r.rules)};return t(o.rules),[...a]},Vbe=(e,i,n,o)=>{for(const a of[...bC,...wC]){const t=L(e,a);if(Z(t)){if(i){n.info(`[dry-run] Would remove ${t}`);continue}we(t,o),yo(t),ni(o,"secretlint","removedConfigCount"),n.info(`Removed ${t}`)}}},ewe=(e,i,n,o)=>{const a=L(e,".secretlintignore");if(!Z(a))return;const t=z(a).split(/\r?\n/).map(s=>s.trim()).filter(s=>s&&!s.startsWith("#"));t.length!==0&&(ve(o,`.secretlintignore contained ${String(t.length)} path pattern(s). vis secrets uses .gitignore + --exclude / --exclude-from; add these globs to your .gitignore or pass --exclude: ${t.slice(0,5).join(", ")}${t.length>5?", ...":""}`),i&&n.info(`[dry-run] Would consume ${a} (${String(t.length)} patterns) and surface as manual step.`))},iwe=(e,i,n,o,a)=>{const t=L(e,"package.json");if(!Z(t))return;const s=Ue(t);if(!s)return;let r=!1;if(s.scripts){for(const[d,l]of Object.entries(s.scripts))if(typeof l=="string"&&/\bsecretlint\b/.test(l)){const g=l.replaceAll(/\bsecretlint\b[^\n&|;]*/g,"vis secrets").trim();g!==l&&(s.scripts[d]=g,r=!0,ni(o,"secretlint","rewrittenScriptCount"),n.info(` scripts.${d}: "${l}" -> "${g}"`))}}if(s.devDependencies){const d=s.devDependencies,l=[];for(const g of Object.keys(d))(g==="secretlint"||g.startsWith("@secretlint/"))&&(delete d[g],l.push(g),r=!0,ni(o,"secretlint","removedPackageCount"));l.length>0&&n.info(` removed ${String(l.length)} secretlint devDependencies: ${l.join(", ")}`)}if(!r)return;if(i){n.info(`[dry-run] Would update ${t}`);return}const u=En(t,z(t),{defaultIndent:" ",useEditorconfig:a});we(t,o),ui(t,`${JSON.stringify(s,null,u)}
229
229
  `)},nwe=(e,i,n,o)=>{const a=[".husky/pre-commit",".vis/hooks/pre-commit",".git/hooks/pre-commit"];for(const t of a){const s=L(e,t);if(!Z(s))continue;const r=z(s);if(!/\bsecretlint\b/.test(r))continue;const u=r.replaceAll(/\bsecretlint\b[^\n&|;]*/g,"vis secrets --staged");if(i){n.info(`[dry-run] Would rewrite ${s}`);continue}we(s,o),ui(s,u),o.gitHooksConfigured=!0,n.info(`Rewrote secretlint invocation in ${t}`)}},Xf=(e,i,n,o)=>{const a=jC(e),t=kC(e);if(!(a??t))return i.silent||n.info("No secretlint artifacts found — nothing to migrate."),!1;if(a){const s=Ube(e,a,o);n.info(`Found ${a}`),s.length>0?(n.info(` active rules/presets: ${s.join(", ")}`),ve(o,`secretlint used these rules: ${s.join(", ")}. vis secrets ships the gitleaks ruleset (177 rules covering AWS/GCP/Azure/GitHub/Slack/Stripe and more). Verify parity before removing secretlint.`)):ve(o,`Rule IDs could not be auto-extracted from ${a}. Verify that the bundled gitleaks ruleset covers your secretlint rule set.`)}return ewe(e,i.dryRun,n,o),iwe(e,i.dryRun,n,o,i.useEditorconfig),nwe(e,i.dryRun,n,o),Vbe(e,i.dryRun,n,o),!0},Yl="sherif",nd=/\bsherif\b/,Rg={"empty-dependencies":"empty-deps","multiple-dependency-versions":"workspace-versions","non-existant-packages":"dead-workspace-patterns","packages-without-package-json":"missing-package-json","root-package-dependencies":"root-deps","root-package-manager-field":"root-package-manager","root-package-private-field":"root-private","types-in-dependencies":"types-in-deps","unordered-dependencies":void 0,"unsync-similar-dependencies":"similar-deps"},owe=Object.values(Rg).filter(e=>e!==void 0),SC=e=>{const i=L(e,"package.json");return Z(i)&&Ue(i)?.sherif?"package.json":void 0},LC=e=>{const i=L(e,"package.json");if(!Z(i))return!1;const n=Ue(i);if(!n)return!1;if(n.devDependencies?.sherif||n.dependencies?.sherif)return!0;if(n.scripts){for(const o of Object.values(n.scripts))if(typeof o=="string"&&nd.test(o))return!0}return!1},awe=e=>Ue(L(e,"package.json"))?.sherif,CC=(e,i)=>{const n={unmapped:[],visDisabled:[]};if(!Array.isArray(e["ignore-rules"]))return n;for(const o of e["ignore-rules"]){if(typeof o!="string"||o.length===0)continue;const a=Rg[o];if(a===void 0){o==="unordered-dependencies"?ge(i,"sherif rule `unordered-dependencies` has no `vis lint` equivalent — vis covers ordering via `vis sort-package-json` (separate command). No migration needed; skip running it if you don't want it."):Object.hasOwn(Rg,o)?n.unmapped.push(o):ge(i,`sherif rule \`${o}\` is unknown to vis migrate — skipped.`);continue}n.visDisabled.push(a)}return n},YC=e=>{const i=owe.filter(n=>!e.includes(n));return i.length===0?"vis lint":`vis lint ${i.map(n=>`--${n}`).join(" ")}`},twe=(e,i)=>{const n=L(e,"package.json"),o={configRemoved:!1,dependencyRemoved:!1,removedScripts:[],scriptCount:0};if(!Z(n))return o;const a=z(n),t=JSON.parse(a);let s=!1;t.sherif&&(delete t.sherif,s=!0,o.configRemoved=!0);for(const u of["dependencies","devDependencies"]){const d=t[u];d?.sherif&&(delete d.sherif,s=!0,o.dependencyRemoved=!0)}const r=t.scripts;if(r){const u={};for(const[d,l]of Object.entries(r))typeof l=="string"&&nd.test(l)?(o.scriptCount+=1,o.removedScripts.push({name:d,value:l}),s=!0):u[d]=l;o.scriptCount>0&&(Object.keys(u).length===0?delete t.scripts:t.scripts=u)}if(s){const u=Os(n,a,{useEditorconfig:i});we(n),He(n,`${JSON.stringify(t,void 0,u)}
230
- `,"utf8")}return o},swe=[".husky/pre-commit",".vis/hooks/pre-commit",".git/hooks/pre-commit"],rwe=[".github/workflows",".gitlab-ci.yml",".circleci/config.yml",".woodpecker.yml",".drone.yml"],$C=(e,i)=>{const n=[];for(const o of swe){const a=L(e,o);Z(a)&&nd.test(z(a))&&(n.push(o),ve(i,`Update ${o} — replace \`sherif\` invocation with \`vis lint\`.`))}return n},ZC=(e,i)=>{const n=[],o=a=>{const t=L(e,a);Z(t)&&nd.test(z(t))&&(n.push(a),ve(i,`Update ${a} — replace \`sherif\` invocation with \`vis lint\`.`))};for(const a of rwe){const t=L(e,a);if(Z(t)){if(a===".github/workflows"){try{for(const s of Fi(t))(s.endsWith(".yml")||s.endsWith(".yaml"))&&o(`.github/workflows/${s}`)}catch{}continue}o(a)}}return n},uwe=(e,i,n,o,a)=>{const t=CC(i,a);if(t.visDisabled.length>0){const h=YC(t.visDisabled);ve(a,`sherif's \`ignore-rules\` was set to [${t.visDisabled.map(c=>JSON.stringify(c)).join(", ")}] (vis names). vis has no global rule-disable; replace any \`sherif\` script with the explicit positive list: \`${h}\`.`)}t.unmapped.length>0&&ge(a,`sherif rule(s) [${t.unmapped.map(h=>JSON.stringify(h)).join(", ")}] could not be mapped — please re-evaluate manually.`),Array.isArray(i["ignore-dependencies"])&&i["ignore-dependencies"].length>0&&ve(a,`sherif's \`ignore-dependencies\` was set to [${i["ignore-dependencies"].map(h=>JSON.stringify(h)).join(", ")}]. Mirror this in vis.config.ts under \`policy.workspaceVersions.ignore\`, \`policy.customTypes.ignore\`, \`policy.typesInDeps.ignore\` (and \`policy.redefineRoot.ignore\`) for the lints where it applies.`),Array.isArray(i["ignore-packages"])&&i["ignore-packages"].length>0&&(ge(a,`sherif's \`ignore-packages\` was set to [${i["ignore-packages"].map(h=>JSON.stringify(h)).join(", ")}] — vis has no global package-skip yet (only per-rule scoping via policy.bannedDeps.{packages,paths}). Tracked alongside the dep filter work.`),ve(a,"Re-evaluate sherif `ignore-packages` — vis has no equivalent global filter yet.")),Array.isArray(i["ignore-paths"])&&i["ignore-paths"].length>0&&(ge(a,`sherif's \`ignore-paths\` was set to [${i["ignore-paths"].map(h=>JSON.stringify(h)).join(", ")}] — vis has no global path-skip yet.`),ve(a,"Re-evaluate sherif `ignore-paths` — vis has no equivalent global filter yet."));const s=$C(e,a);s.length>0&&!n.silent&&o.warn(`Found sherif reference in ${String(s.length)} hook file(s) — see manualSteps for details.`);const r=ZC(e,a);r.length>0&&!n.silent&&o.warn(`Found sherif reference in ${String(r.length)} CI file(s) — see manualSteps for details.`);const{configRemoved:u,dependencyRemoved:d,removedScripts:l,scriptCount:g}=twe(e,n.useEditorconfig);if(u&&!n.silent&&o.info("Removed `sherif` block from package.json"),u&&ni(a,Yl,"removedConfigCount"),d&&ni(a,Yl,"removedPackageCount"),g>0){ni(a,Yl,"rewrittenScriptCount",g);for(const{name:h,value:c}of l)ve(a,`Recreate script \`${h}\` (removed; was \`${c}\`). Replace \`sherif\` with \`vis lint\` (sherif's lint surface ≈ \`vis lint\`).`);n.silent||o.info(`Removed ${String(g)} script(s) referencing \`sherif\`. Replace with \`vis lint\`.`)}},Hf=(e,i,n,o)=>{const a=SC(e),t=LC(e);if(!a&&!t)return i.silent||n.info("No sherif configuration or installation found — nothing to migrate."),!1;const s=awe(e)??{};if(i.dryRun){const r=CC(s,o);if($C(e,o),ZC(e,o),!i.silent&&(a&&n.info("[dry-run] Would remove `sherif` block from package.json"),t&&n.info("[dry-run] Would strip `sherif` from devDependencies/scripts"),r.visDisabled.length>0)){const u=YC(r.visDisabled);n.info(`[dry-run] Suggested replacement script: ${u}`)}return!0}return uwe(e,s,i,n,o),!0},dwe=["dependencies","devDependencies","peerDependencies","optionalDependencies","overrides","resolutions","pnpm.overrides"],lwe=(e,i)=>{const n=i.split(".");let o=e;for(const a of n){if(typeof o!="object"||o===null)return;o=o[a]}return typeof o=="object"&&o!==null?o:void 0},hp=e=>{const i=L(e,"package.json");if(!Z(i))return["."];const n=Qe(i).workspaces;let o=[];if(n){const a=Array.isArray(n)?n:n.packages;a&&(o=Sp(e,a))}if(o.length===0){const a=HY(e);a&&(o=Sp(e,a))}return[".",...o]},od=e=>{if(Z(e))try{return Qe(e)}catch{return}},gwe=e=>{const i=new Set,n=hp(e);for(const o of n){const a=od(L(e,o,"package.json"));a&&typeof a.name=="string"&&i.add(a.name)}return i},fSe=(e,i={})=>{const n=i.includeInternal??!0,o=i.depTypes??dwe,a=hp(e),t=gwe(e),s=[],r=o.includes("pnpm.overrides")?XY(e):void 0,u=r?L(e,"pnpm-workspace.yaml"):void 0;for(const d of a){const l=L(e,d,"package.json"),g=od(l);if(!g)continue;const h=typeof g.name=="string"?g.name:void 0,c=d==="."?".":ws(e,L(e,d));for(const p of o){const f=p.includes(".")?lwe(g,p):g[p];if(!(!f||typeof f!="object"))for(const[w,v]of Object.entries(f)){if(typeof v!="string")continue;const j=t.has(w);!n&&j||s.push({depName:w,depType:p,isInternal:j,packageDir:c,packageJsonPath:l,packageName:h,specifier:v})}}}if(r&&u)for(const[d,l]of Object.entries(r)){const g=t.has(d);!n&&g||s.push({depName:d,depType:"pnpm.overrides",isInternal:g,packageDir:".",packageJsonPath:u,packageName:void 0,specifier:l})}return s},cp=new Set(["devEngines.packageManager","devEngines.runtime","engines","packageManager","volta"]),hwe=["engines","volta"],cwe=new Set(["extends"]),pwe=/^([@\w./-]+?)@([^+]+)(\+.+)?$/,vwe=/^([@\w./-]+)~(.+)$/,ad=e=>{const i=pwe.exec(e.trim());if(!(!i?.[1]||!i[2]))return{hash:i[3]??"",name:i[1],version:i[2]}},JC=e=>{const i=vwe.exec(e.trim());if(!(!i?.[1]||!i[2]))return{name:i[1],version:i[2]}},bs=e=>typeof e=="object"&&e!==null&&!Array.isArray(e),xC=e=>typeof e=="object"&&e!==null&&!Array.isArray(e)&&typeof e.name=="string",ywe=new Set(["name@version","name~version","string","versionsByName"]),mSe=e=>{const i=[];if(!e)return i;const n=new Set;for(const o of e){const a=typeof o?.name=="string"&&o.name.length>0?o.name:"<unnamed>";if(typeof o?.name!="string"||o.name.length===0){i.push("extraTypes entry missing 'name'");continue}cp.has(o.name)&&i.push(`extraTypes[${a}]: name collides with a built-in customType`),n.has(o.name)&&i.push(`extraTypes[${a}]: duplicate name`),n.add(o.name),(typeof o.path!="string"||o.path.length===0)&&i.push(`extraTypes[${a}]: missing 'path'`),ywe.has(o.strategy)||i.push(`extraTypes[${a}]: invalid strategy "${String(o.strategy)}" (expected name@version | name~version | string | versionsByName)`),o.strategy==="string"&&(typeof o.depName!="string"||o.depName.length===0)&&i.push(`extraTypes[${a}]: strategy 'string' requires 'depName'`)}return i},fwe=(e,i)=>{if(i.length===0)return;let n=e;for(const o of i.split(".")){if(typeof n!="object"||n===null||Array.isArray(n))return;n=n[o]}return n},mwe=(e,i,n,o,a)=>{const t=fwe(i,e.path);if(t===void 0)return[];const s=Object.freeze({depName:e.depName,path:e.path,strategy:e.strategy});if(e.strategy==="versionsByName"){if(!bs(t))return[];const r=[];for(const[u,d]of Object.entries(t))typeof d=="string"&&r.push({customType:e.name,depName:u,extra:s,packageDir:n,packageJsonPath:o,packageName:a,rawValue:d,specifier:d});return r}if(e.strategy==="name@version"){if(typeof t!="string")return[];const r=ad(t);return r?[{customType:e.name,depName:r.name,extra:s,packageDir:n,packageJsonPath:o,packageName:a,rawValue:t,specifier:r.version}]:[]}if(e.strategy==="name~version"){if(typeof t!="string")return[];const r=JC(t);return r?[{customType:e.name,depName:r.name,extra:s,packageDir:n,packageJsonPath:o,packageName:a,rawValue:t,specifier:r.version}]:[]}return typeof t!="string"||typeof e.depName!="string"||e.depName.length===0?[]:[{customType:e.name,depName:e.depName,extra:s,packageDir:n,packageJsonPath:o,packageName:a,rawValue:t,specifier:t}]},bSe=(e,i)=>{const n=hp(e),o=[];for(const a of n){const t=L(e,a,"package.json"),s=od(t);if(!s)continue;const r=typeof s.name=="string"?s.name:void 0,u=a==="."?".":ws(e,L(e,a));for(const l of hwe){const g=s[l];if(bs(g))for(const[h,c]of Object.entries(g))typeof c=="string"&&(l==="volta"&&cwe.has(h)||o.push({customType:l,depName:h,packageDir:u,packageJsonPath:t,packageName:r,rawValue:c,specifier:c}))}if(typeof s.packageManager=="string"){const l=ad(s.packageManager);l&&o.push({customType:"packageManager",depName:l.name,packageDir:u,packageJsonPath:t,packageName:r,rawValue:s.packageManager,specifier:l.version})}const{devEngines:d}=s;if(typeof d=="object"&&d!==null&&!Array.isArray(d))for(const l of["runtime","packageManager"]){const g=d[l];if(g===void 0)continue;const h=Array.isArray(g)?g:[g];for(const c of h)!xC(c)||typeof c.version!="string"||o.push({customType:l==="runtime"?"devEngines.runtime":"devEngines.packageManager",depName:c.name,packageDir:u,packageJsonPath:t,packageName:r,rawValue:c.version,specifier:c.version})}if(i){for(const l of i)if(!(typeof l?.name!="string"||l.name.length===0)&&!cp.has(l.name))for(const g of mwe(l,s,u,t,r))o.push(g)}}return o},bwe=(e,i)=>`${e} ${i}`,wwe=(e,i)=>{const n=[...e].sort((a,t)=>(a.packageName??a.packageDir).localeCompare(t.packageName??t.packageDir));let o;for(const a of n){const t=Ml(a.specifier);if(!t)continue;if(!o){o=a;continue}const s=Ml(o.specifier);if(!s){o=a;continue}const r=Lp(s,t),u=Lp(t,s);(i==="highest"&&r||i==="lowest"&&u)&&(o=a)}return o},wSe=(e,i={})=>{const n=new Set(i.ignoreDeps),o=i.resolve??"highest",a=[],t=e.filter(r=>i.dep!==void 0&&r.depName!==i.dep?!1:!n.has(r.depName)),s=new Map;for(const r of t){const u=bwe(r.customType,r.depName),d=s.get(u);d?d.push(r):s.set(u,[r])}for(const[,r]of s){if(r.length<2||new Set(r.map(d=>d.specifier)).size<=1)continue;const u=wwe(r,o);if(u)for(const d of r)d.specifier!==u.specifier&&Ml(d.specifier)!==void 0&&a.push({canonicalSource:u.packageName??u.packageDir,customType:d.customType,depName:d.depName,...d.extra?{extra:d.extra}:{},fix:u.specifier,packageDir:d.packageDir,packageJsonPath:d.packageJsonPath,packageName:d.packageName,specifier:d.specifier})}return a},jwe=(e,i)=>{const n=i.extra;if(!n)return!1;const o=n.path.split(".");if(o.length===0||o.some(s=>s.length===0))return!1;let a=e;for(let s=0;s<o.length-1;s+=1){const r=a[o[s]];if(typeof r!="object"||r===null||Array.isArray(r))return!1;a=r}const t=o.at(-1);if(n.strategy==="versionsByName"){const s=a[t];return bs(s)?(s[i.depName]=i.fix,!0):!1}if(n.strategy==="name@version"){const s=a[t];if(typeof s!="string")return!1;const r=ad(s);return r?(a[t]=`${r.name}@${i.fix}`,!0):!1}if(n.strategy==="name~version"){const s=a[t];if(typeof s!="string")return!1;const r=JC(s);return r?(a[t]=`${r.name}~${i.fix}`,!0):!1}return typeof a[t]!="string"?!1:(a[t]=i.fix,!0)},jSe=(e,i={})=>{const{useEditorconfig:n}=i,o=new Map;for(const t of e){const s=o.get(t.packageJsonPath);s?s.push(t):o.set(t.packageJsonPath,[t])}const a=[];for(const[t,s]of o){const r=od(t);if(!r)continue;let u=!1;for(const d of s){if(d.extra){jwe(r,d)&&(u=!0);continue}if(d.customType==="engines"||d.customType==="volta"){const p=r[d.customType];bs(p)&&(p[d.depName]=d.fix,u=!0);continue}if(d.customType==="packageManager"){const p=r.packageManager;if(typeof p=="string"){const f=ad(p);f&&(r.packageManager=`${f.name}@${d.fix}`,u=!0)}continue}const l=d.customType==="devEngines.runtime"?"runtime":"packageManager",{devEngines:g}=r;if(!bs(g))continue;const h=g[l];if(h===void 0)continue;const c=Array.isArray(h)?h:[h];for(const p of c)xC(p)&&p.name===d.depName&&(p.version=d.fix,u=!0)}u&&(UC(t,r,{indent:MY(t,{useEditorconfig:n}),overwrite:!0}),a.push(t))}return a},Og="syncpack",TC=[".syncpackrc",".syncpackrc.json"],pp=[".syncpackrc.yaml",".syncpackrc.yml"],vp=[".syncpackrc.cjs",".syncpackrc.js",".syncpackrc.mjs",".syncpackrc.ts","syncpack.config.cjs","syncpack.config.js","syncpack.config.mjs","syncpack.config.ts"],kwe=[...TC,...pp,...vp],Swe=/\bextraTypes\s*:/,Lwe=/\bpolicy\s*:/,Mf=/(defineConfig\(\{)/,Pf=/(export\s+default\s+\{)/,yp=/\bsyncpack\b/,DC=e=>{const i=L(e,"package.json");if(Z(i)&&Ue(i)?.syncpack)return"package.json";for(const n of kwe)if(Z(L(e,n)))return n},Cwe=e=>{for(const n of vp)if(Z(L(e,n)))return n;const i=L(e,".syncpackrc");if(Z(i)&&!ct(i))try{Ro(i);return}catch{return".syncpackrc"}},Ywe=e=>{const i=Uo(e);return i?Swe.test(z(i)):!1},$we=e=>Ue(L(e,"package.json"))?.syncpack,Zwe=e=>Ue(e),Nf=e=>{try{return Ro(e)}catch{return}},Jwe=(e,i,n)=>{if(i==="package.json")return $we(e);if(vp.includes(i)){ge(n,`${i} is a TS/JS config and cannot be auto-migrated — vis migrate does not load executable config. Convert to .syncpackrc.json and re-run, or translate directly into vis.config.ts. Tracked in https://github.com/visulima/visulima/issues/622.`),ve(n,`Translate ${i} into vis.config.ts (policy.* and security.*) — see https://github.com/visulima/visulima/issues/622`);return}const o=L(e,i);if(pp.includes(i))return Nf(o);if(i===".syncpackrc"&&!ct(o)){const a=Nf(o);if(a)return a;ge(n,".syncpackrc is neither valid JSON nor YAML — please migrate manually.");return}return Zwe(o)},BC=(e,i)=>{const n=[];if(!e.customTypes)return n;for(const[o,a]of Object.entries(e.customTypes)){if(!a||typeof a!="object")continue;const{strategy:t}=a,{path:s}=a;if(typeof s!="string"||s.length===0){ge(i,`customType "${o}" has no \`path\` — skipped.`);continue}if(t!=="name@version"&&t!=="string"&&t!=="versionsByName"){ge(i,`customType "${o}" has unsupported strategy ${JSON.stringify(t)} — skipped.`);continue}if(cp.has(o)){ge(i,`customType "${o}" collides with a vis built-in and was dropped — vis already lints this surface.`);continue}const r={name:o,path:s,strategy:t};if(t==="string"){const{depName:u}=a;typeof u=="string"&&u.length>0?r.depName=u:(ge(i,`customType "${o}" uses strategy "string" but has no \`depName\` — vis requires it. Add it manually after migration.`),ve(i,`Set policy.customTypes.extraTypes[name="${o}"].depName before running vis lint`))}n.push(r)}return n},XC=e=>e.isBanned===!0,HC=(e,i)=>{if(Array.isArray(e.versionGroups)&&e.versionGroups.length>0){const n=e.versionGroups.filter(o=>o&&typeof o=="object"&&!XC(o));n.length>0&&(ge(i,`${String(n.length)} versionGroups rule(s) cannot be migrated — \`pinVersion\`, \`snapTo\`, and \`policy: "sameRange"\` (and other versionGroups DSL surfaces) are tracked in https://github.com/visulima/visulima/issues/622.`),ve(i,'Re-implement versionGroups rules using `pinVersion` / `snapTo` / `policy: "sameRange"` once the vis DSL ships (issue #622).'))}Array.isArray(e.semverGroups)&&e.semverGroups.length>0&&(ge(i,`${String(e.semverGroups.length)} semverGroups rule(s) cannot be migrated — semverGroups DSL is tracked in https://github.com/visulima/visulima/issues/622.`),ve(i,"Re-implement semverGroups rules manually once the vis DSL ships (issue #622)")),Array.isArray(e.dependencyTypes)&&e.dependencyTypes.length>0&&ve(i,"Review syncpack `dependencyTypes` — vis applies policies to dependencies/devDependencies/peerDependencies/optionalDependencies/overrides by default. Narrow via policy.* filters if needed."),Array.isArray(e.specifierTypes)&&e.specifierTypes.length>0&&ve(i,"Review syncpack `specifierTypes` — vis has no direct equivalent today; specifier filtering belongs in versionGroups (issue #622)."),typeof e.filter=="string"&&e.filter.length>0&&ve(i,`Re-implement syncpack \`filter\` regex (${e.filter}) once vis exposes a top-level dep filter.`),(Array.isArray(e.sortAz)&&e.sortAz.length>0||Array.isArray(e.sortFirst)&&e.sortFirst.length>0||Array.isArray(e.sortExports)&&e.sortExports.length>0)&&ge(i,"syncpack sort options (sortAz / sortFirst / sortExports) are superseded by `vis sort-package-json` — no migration needed."),(e.sortPackages!==void 0||e.formatBugs!==void 0||e.formatRepository!==void 0)&&ge(i,"syncpack package.json shape options (sortPackages / formatBugs / formatRepository) are superseded by `vis sort-package-json` — no migration needed."),(e.lintFormatting!==void 0||e.lintSemverRanges!==void 0||e.lintVersions!==void 0)&&ge(i,"syncpack lint toggles (lintFormatting / lintSemverRanges / lintVersions) are covered by `vis lint` by default — no migration needed."),Array.isArray(e.source)&&e.source.length>0&&ve(i,`syncpack \`source\` was set to [${e.source.map(n=>JSON.stringify(n)).join(", ")}]. vis derives workspace globs from pnpm-workspace.yaml / package.json#workspaces — verify they match before relying on \`vis lint\`.`),typeof e.indent=="string"&&e.indent.length>0&&ge(i,"syncpack `indent` is implicit in vis — JSON writers honor `.editorconfig` (and the source file's existing indentation). No migration needed.")},MC=(e,i)=>{const n={};if(!Array.isArray(e.versionGroups))return n;for(const o of e.versionGroups){if(!o||typeof o!="object")continue;const a=o;if(!XC(a))continue;const t=Array.isArray(a.dependencies)?a.dependencies.filter(d=>typeof d=="string"&&d.length>0):[];if(t.length===0){ge(i,"versionGroup with `isBanned: true` has no `dependencies` entries — skipped.");continue}const s=Array.isArray(a.packages)?a.packages.filter(d=>typeof d=="string"&&d.length>0):[],r=a.label,u=typeof r=="string"&&r.length>0?r:"banned via syncpack versionGroups";for(const d of t){if(n[d]!==void 0){ge(i,`Multiple banned versionGroups target "${d}" — kept the first match; merge manually if needed.`);continue}n[d]=s.length>0?{packages:s,reason:u}:u}}return n},xwe=e=>{const i=[`name: ${JSON.stringify(e.name)}`,`path: ${JSON.stringify(e.path)}`,`strategy: ${JSON.stringify(e.strategy)}`];return e.depName!==void 0&&i.push(`depName: ${JSON.stringify(e.depName)}`),` { ${i.join(", ")} }`},Twe=(e,i)=>{if(typeof i=="string")return` ${JSON.stringify(e)}: ${JSON.stringify(i)}`;const n=[`reason: ${JSON.stringify(i.reason)}`];return i.packages&&i.packages.length>0&&n.push(`packages: [${i.packages.map(o=>JSON.stringify(o)).join(", ")}]`),i.paths&&i.paths.length>0&&n.push(`paths: [${i.paths.map(o=>JSON.stringify(o)).join(", ")}]`),i.replacement!==void 0&&n.push(`replacement: ${JSON.stringify(i.replacement)}`),` ${JSON.stringify(e)}: { ${n.join(", ")} }`},Ag=(e,i={})=>{const n=[],o=Object.entries(i);if(o.length>0){const a=o.map(([t,s])=>Twe(t,s)).join(`,
230
+ `,"utf8")}return o},swe=[".husky/pre-commit",".vis/hooks/pre-commit",".git/hooks/pre-commit"],rwe=[".github/workflows",".gitlab-ci.yml",".circleci/config.yml",".woodpecker.yml",".drone.yml"],$C=(e,i)=>{const n=[];for(const o of swe){const a=L(e,o);Z(a)&&nd.test(z(a))&&(n.push(o),ve(i,`Update ${o} — replace \`sherif\` invocation with \`vis lint\`.`))}return n},ZC=(e,i)=>{const n=[],o=a=>{const t=L(e,a);Z(t)&&nd.test(z(t))&&(n.push(a),ve(i,`Update ${a} — replace \`sherif\` invocation with \`vis lint\`.`))};for(const a of rwe){const t=L(e,a);if(Z(t)){if(a===".github/workflows"){try{for(const s of Fi(t))(s.endsWith(".yml")||s.endsWith(".yaml"))&&o(`.github/workflows/${s}`)}catch{}continue}o(a)}}return n},uwe=(e,i,n,o,a)=>{const t=CC(i,a);if(t.visDisabled.length>0){const h=YC(t.visDisabled);ve(a,`sherif's \`ignore-rules\` was set to [${t.visDisabled.map(c=>JSON.stringify(c)).join(", ")}] (vis names). vis has no global rule-disable; replace any \`sherif\` script with the explicit positive list: \`${h}\`.`)}t.unmapped.length>0&&ge(a,`sherif rule(s) [${t.unmapped.map(h=>JSON.stringify(h)).join(", ")}] could not be mapped — please re-evaluate manually.`),Array.isArray(i["ignore-dependencies"])&&i["ignore-dependencies"].length>0&&ve(a,`sherif's \`ignore-dependencies\` was set to [${i["ignore-dependencies"].map(h=>JSON.stringify(h)).join(", ")}]. Mirror this in vis.config.ts under \`policy.workspaceVersions.ignore\`, \`policy.customTypes.ignore\`, \`policy.typesInDeps.ignore\` (and \`policy.redefineRoot.ignore\`) for the lints where it applies.`),Array.isArray(i["ignore-packages"])&&i["ignore-packages"].length>0&&(ge(a,`sherif's \`ignore-packages\` was set to [${i["ignore-packages"].map(h=>JSON.stringify(h)).join(", ")}] — vis has no global package-skip yet (only per-rule scoping via policy.bannedDeps.{packages,paths}). Tracked alongside the dep filter work.`),ve(a,"Re-evaluate sherif `ignore-packages` — vis has no equivalent global filter yet.")),Array.isArray(i["ignore-paths"])&&i["ignore-paths"].length>0&&(ge(a,`sherif's \`ignore-paths\` was set to [${i["ignore-paths"].map(h=>JSON.stringify(h)).join(", ")}] — vis has no global path-skip yet.`),ve(a,"Re-evaluate sherif `ignore-paths` — vis has no equivalent global filter yet."));const s=$C(e,a);s.length>0&&!n.silent&&o.warn(`Found sherif reference in ${String(s.length)} hook file(s) — see manualSteps for details.`);const r=ZC(e,a);r.length>0&&!n.silent&&o.warn(`Found sherif reference in ${String(r.length)} CI file(s) — see manualSteps for details.`);const{configRemoved:u,dependencyRemoved:d,removedScripts:l,scriptCount:g}=twe(e,n.useEditorconfig);if(u&&!n.silent&&o.info("Removed `sherif` block from package.json"),u&&ni(a,Yl,"removedConfigCount"),d&&ni(a,Yl,"removedPackageCount"),g>0){ni(a,Yl,"rewrittenScriptCount",g);for(const{name:h,value:c}of l)ve(a,`Recreate script \`${h}\` (removed; was \`${c}\`). Replace \`sherif\` with \`vis lint\` (sherif's lint surface ≈ \`vis lint\`).`);n.silent||o.info(`Removed ${String(g)} script(s) referencing \`sherif\`. Replace with \`vis lint\`.`)}},Hf=(e,i,n,o)=>{const a=SC(e),t=LC(e);if(!a&&!t)return i.silent||n.info("No sherif configuration or installation found — nothing to migrate."),!1;const s=awe(e)??{};if(i.dryRun){const r=CC(s,o);if($C(e,o),ZC(e,o),!i.silent&&(a&&n.info("[dry-run] Would remove `sherif` block from package.json"),t&&n.info("[dry-run] Would strip `sherif` from devDependencies/scripts"),r.visDisabled.length>0)){const u=YC(r.visDisabled);n.info(`[dry-run] Suggested replacement script: ${u}`)}return!0}return uwe(e,s,i,n,o),!0},dwe=["dependencies","devDependencies","peerDependencies","optionalDependencies","overrides","resolutions","pnpm.overrides"],lwe=(e,i)=>{const n=i.split(".");let o=e;for(const a of n){if(typeof o!="object"||o===null)return;o=o[a]}return typeof o=="object"&&o!==null?o:void 0},hp=e=>{const i=L(e,"package.json");if(!Z(i))return["."];const n=Qe(i).workspaces;let o=[];if(n){const a=Array.isArray(n)?n:n.packages;a&&(o=Sp(e,a))}if(o.length===0){const a=HY(e);a&&(o=Sp(e,a))}return[".",...o]},od=e=>{if(Z(e))try{return Qe(e)}catch{return}},gwe=e=>{const i=new Set,n=hp(e);for(const o of n){const a=od(L(e,o,"package.json"));a&&typeof a.name=="string"&&i.add(a.name)}return i},m1e=(e,i={})=>{const n=i.includeInternal??!0,o=i.depTypes??dwe,a=hp(e),t=gwe(e),s=[],r=o.includes("pnpm.overrides")?XY(e):void 0,u=r?L(e,"pnpm-workspace.yaml"):void 0;for(const d of a){const l=L(e,d,"package.json"),g=od(l);if(!g)continue;const h=typeof g.name=="string"?g.name:void 0,c=d==="."?".":ws(e,L(e,d));for(const p of o){const f=p.includes(".")?lwe(g,p):g[p];if(!(!f||typeof f!="object"))for(const[w,v]of Object.entries(f)){if(typeof v!="string")continue;const j=t.has(w);!n&&j||s.push({depName:w,depType:p,isInternal:j,packageDir:c,packageJsonPath:l,packageName:h,specifier:v})}}}if(r&&u)for(const[d,l]of Object.entries(r)){const g=t.has(d);!n&&g||s.push({depName:d,depType:"pnpm.overrides",isInternal:g,packageDir:".",packageJsonPath:u,packageName:void 0,specifier:l})}return s},cp=new Set(["devEngines.packageManager","devEngines.runtime","engines","packageManager","volta"]),hwe=["engines","volta"],cwe=new Set(["extends"]),pwe=/^([@\w./-]+?)@([^+]+)(\+.+)?$/,vwe=/^([@\w./-]+)~(.+)$/,ad=e=>{const i=pwe.exec(e.trim());if(!(!i?.[1]||!i[2]))return{hash:i[3]??"",name:i[1],version:i[2]}},JC=e=>{const i=vwe.exec(e.trim());if(!(!i?.[1]||!i[2]))return{name:i[1],version:i[2]}},bs=e=>typeof e=="object"&&e!==null&&!Array.isArray(e),xC=e=>typeof e=="object"&&e!==null&&!Array.isArray(e)&&typeof e.name=="string",ywe=new Set(["name@version","name~version","string","versionsByName"]),b1e=e=>{const i=[];if(!e)return i;const n=new Set;for(const o of e){const a=typeof o?.name=="string"&&o.name.length>0?o.name:"<unnamed>";if(typeof o?.name!="string"||o.name.length===0){i.push("extraTypes entry missing 'name'");continue}cp.has(o.name)&&i.push(`extraTypes[${a}]: name collides with a built-in customType`),n.has(o.name)&&i.push(`extraTypes[${a}]: duplicate name`),n.add(o.name),(typeof o.path!="string"||o.path.length===0)&&i.push(`extraTypes[${a}]: missing 'path'`),ywe.has(o.strategy)||i.push(`extraTypes[${a}]: invalid strategy "${String(o.strategy)}" (expected name@version | name~version | string | versionsByName)`),o.strategy==="string"&&(typeof o.depName!="string"||o.depName.length===0)&&i.push(`extraTypes[${a}]: strategy 'string' requires 'depName'`)}return i},fwe=(e,i)=>{if(i.length===0)return;let n=e;for(const o of i.split(".")){if(typeof n!="object"||n===null||Array.isArray(n))return;n=n[o]}return n},mwe=(e,i,n,o,a)=>{const t=fwe(i,e.path);if(t===void 0)return[];const s=Object.freeze({depName:e.depName,path:e.path,strategy:e.strategy});if(e.strategy==="versionsByName"){if(!bs(t))return[];const r=[];for(const[u,d]of Object.entries(t))typeof d=="string"&&r.push({customType:e.name,depName:u,extra:s,packageDir:n,packageJsonPath:o,packageName:a,rawValue:d,specifier:d});return r}if(e.strategy==="name@version"){if(typeof t!="string")return[];const r=ad(t);return r?[{customType:e.name,depName:r.name,extra:s,packageDir:n,packageJsonPath:o,packageName:a,rawValue:t,specifier:r.version}]:[]}if(e.strategy==="name~version"){if(typeof t!="string")return[];const r=JC(t);return r?[{customType:e.name,depName:r.name,extra:s,packageDir:n,packageJsonPath:o,packageName:a,rawValue:t,specifier:r.version}]:[]}return typeof t!="string"||typeof e.depName!="string"||e.depName.length===0?[]:[{customType:e.name,depName:e.depName,extra:s,packageDir:n,packageJsonPath:o,packageName:a,rawValue:t,specifier:t}]},w1e=(e,i)=>{const n=hp(e),o=[];for(const a of n){const t=L(e,a,"package.json"),s=od(t);if(!s)continue;const r=typeof s.name=="string"?s.name:void 0,u=a==="."?".":ws(e,L(e,a));for(const l of hwe){const g=s[l];if(bs(g))for(const[h,c]of Object.entries(g))typeof c=="string"&&(l==="volta"&&cwe.has(h)||o.push({customType:l,depName:h,packageDir:u,packageJsonPath:t,packageName:r,rawValue:c,specifier:c}))}if(typeof s.packageManager=="string"){const l=ad(s.packageManager);l&&o.push({customType:"packageManager",depName:l.name,packageDir:u,packageJsonPath:t,packageName:r,rawValue:s.packageManager,specifier:l.version})}const{devEngines:d}=s;if(typeof d=="object"&&d!==null&&!Array.isArray(d))for(const l of["runtime","packageManager"]){const g=d[l];if(g===void 0)continue;const h=Array.isArray(g)?g:[g];for(const c of h)!xC(c)||typeof c.version!="string"||o.push({customType:l==="runtime"?"devEngines.runtime":"devEngines.packageManager",depName:c.name,packageDir:u,packageJsonPath:t,packageName:r,rawValue:c.version,specifier:c.version})}if(i){for(const l of i)if(!(typeof l?.name!="string"||l.name.length===0)&&!cp.has(l.name))for(const g of mwe(l,s,u,t,r))o.push(g)}}return o},bwe=(e,i)=>`${e} ${i}`,wwe=(e,i)=>{const n=[...e].sort((a,t)=>(a.packageName??a.packageDir).localeCompare(t.packageName??t.packageDir));let o;for(const a of n){const t=Ml(a.specifier);if(!t)continue;if(!o){o=a;continue}const s=Ml(o.specifier);if(!s){o=a;continue}const r=Lp(s,t),u=Lp(t,s);(i==="highest"&&r||i==="lowest"&&u)&&(o=a)}return o},j1e=(e,i={})=>{const n=new Set(i.ignoreDeps),o=i.resolve??"highest",a=[],t=e.filter(r=>i.dep!==void 0&&r.depName!==i.dep?!1:!n.has(r.depName)),s=new Map;for(const r of t){const u=bwe(r.customType,r.depName),d=s.get(u);d?d.push(r):s.set(u,[r])}for(const[,r]of s){if(r.length<2||new Set(r.map(d=>d.specifier)).size<=1)continue;const u=wwe(r,o);if(u)for(const d of r)d.specifier!==u.specifier&&Ml(d.specifier)!==void 0&&a.push({canonicalSource:u.packageName??u.packageDir,customType:d.customType,depName:d.depName,...d.extra?{extra:d.extra}:{},fix:u.specifier,packageDir:d.packageDir,packageJsonPath:d.packageJsonPath,packageName:d.packageName,specifier:d.specifier})}return a},jwe=(e,i)=>{const n=i.extra;if(!n)return!1;const o=n.path.split(".");if(o.length===0||o.some(s=>s.length===0))return!1;let a=e;for(let s=0;s<o.length-1;s+=1){const r=a[o[s]];if(typeof r!="object"||r===null||Array.isArray(r))return!1;a=r}const t=o.at(-1);if(n.strategy==="versionsByName"){const s=a[t];return bs(s)?(s[i.depName]=i.fix,!0):!1}if(n.strategy==="name@version"){const s=a[t];if(typeof s!="string")return!1;const r=ad(s);return r?(a[t]=`${r.name}@${i.fix}`,!0):!1}if(n.strategy==="name~version"){const s=a[t];if(typeof s!="string")return!1;const r=JC(s);return r?(a[t]=`${r.name}~${i.fix}`,!0):!1}return typeof a[t]!="string"?!1:(a[t]=i.fix,!0)},k1e=(e,i={})=>{const{useEditorconfig:n}=i,o=new Map;for(const t of e){const s=o.get(t.packageJsonPath);s?s.push(t):o.set(t.packageJsonPath,[t])}const a=[];for(const[t,s]of o){const r=od(t);if(!r)continue;let u=!1;for(const d of s){if(d.extra){jwe(r,d)&&(u=!0);continue}if(d.customType==="engines"||d.customType==="volta"){const p=r[d.customType];bs(p)&&(p[d.depName]=d.fix,u=!0);continue}if(d.customType==="packageManager"){const p=r.packageManager;if(typeof p=="string"){const f=ad(p);f&&(r.packageManager=`${f.name}@${d.fix}`,u=!0)}continue}const l=d.customType==="devEngines.runtime"?"runtime":"packageManager",{devEngines:g}=r;if(!bs(g))continue;const h=g[l];if(h===void 0)continue;const c=Array.isArray(h)?h:[h];for(const p of c)xC(p)&&p.name===d.depName&&(p.version=d.fix,u=!0)}u&&(UC(t,r,{indent:MY(t,{useEditorconfig:n}),overwrite:!0}),a.push(t))}return a},Og="syncpack",TC=[".syncpackrc",".syncpackrc.json"],pp=[".syncpackrc.yaml",".syncpackrc.yml"],vp=[".syncpackrc.cjs",".syncpackrc.js",".syncpackrc.mjs",".syncpackrc.ts","syncpack.config.cjs","syncpack.config.js","syncpack.config.mjs","syncpack.config.ts"],kwe=[...TC,...pp,...vp],Swe=/\bextraTypes\s*:/,Lwe=/\bpolicy\s*:/,Mf=/(defineConfig\(\{)/,Pf=/(export\s+default\s+\{)/,yp=/\bsyncpack\b/,DC=e=>{const i=L(e,"package.json");if(Z(i)&&Ue(i)?.syncpack)return"package.json";for(const n of kwe)if(Z(L(e,n)))return n},Cwe=e=>{for(const n of vp)if(Z(L(e,n)))return n;const i=L(e,".syncpackrc");if(Z(i)&&!ct(i))try{Ro(i);return}catch{return".syncpackrc"}},Ywe=e=>{const i=Uo(e);return i?Swe.test(z(i)):!1},$we=e=>Ue(L(e,"package.json"))?.syncpack,Zwe=e=>Ue(e),Nf=e=>{try{return Ro(e)}catch{return}},Jwe=(e,i,n)=>{if(i==="package.json")return $we(e);if(vp.includes(i)){ge(n,`${i} is a TS/JS config and cannot be auto-migrated — vis migrate does not load executable config. Convert to .syncpackrc.json and re-run, or translate directly into vis.config.ts. Tracked in https://github.com/visulima/visulima/issues/622.`),ve(n,`Translate ${i} into vis.config.ts (policy.* and security.*) — see https://github.com/visulima/visulima/issues/622`);return}const o=L(e,i);if(pp.includes(i))return Nf(o);if(i===".syncpackrc"&&!ct(o)){const a=Nf(o);if(a)return a;ge(n,".syncpackrc is neither valid JSON nor YAML — please migrate manually.");return}return Zwe(o)},BC=(e,i)=>{const n=[];if(!e.customTypes)return n;for(const[o,a]of Object.entries(e.customTypes)){if(!a||typeof a!="object")continue;const{strategy:t}=a,{path:s}=a;if(typeof s!="string"||s.length===0){ge(i,`customType "${o}" has no \`path\` — skipped.`);continue}if(t!=="name@version"&&t!=="string"&&t!=="versionsByName"){ge(i,`customType "${o}" has unsupported strategy ${JSON.stringify(t)} — skipped.`);continue}if(cp.has(o)){ge(i,`customType "${o}" collides with a vis built-in and was dropped — vis already lints this surface.`);continue}const r={name:o,path:s,strategy:t};if(t==="string"){const{depName:u}=a;typeof u=="string"&&u.length>0?r.depName=u:(ge(i,`customType "${o}" uses strategy "string" but has no \`depName\` — vis requires it. Add it manually after migration.`),ve(i,`Set policy.customTypes.extraTypes[name="${o}"].depName before running vis lint`))}n.push(r)}return n},XC=e=>e.isBanned===!0,HC=(e,i)=>{if(Array.isArray(e.versionGroups)&&e.versionGroups.length>0){const n=e.versionGroups.filter(o=>o&&typeof o=="object"&&!XC(o));n.length>0&&(ge(i,`${String(n.length)} versionGroups rule(s) cannot be migrated — \`pinVersion\`, \`snapTo\`, and \`policy: "sameRange"\` (and other versionGroups DSL surfaces) are tracked in https://github.com/visulima/visulima/issues/622.`),ve(i,'Re-implement versionGroups rules using `pinVersion` / `snapTo` / `policy: "sameRange"` once the vis DSL ships (issue #622).'))}Array.isArray(e.semverGroups)&&e.semverGroups.length>0&&(ge(i,`${String(e.semverGroups.length)} semverGroups rule(s) cannot be migrated — semverGroups DSL is tracked in https://github.com/visulima/visulima/issues/622.`),ve(i,"Re-implement semverGroups rules manually once the vis DSL ships (issue #622)")),Array.isArray(e.dependencyTypes)&&e.dependencyTypes.length>0&&ve(i,"Review syncpack `dependencyTypes` — vis applies policies to dependencies/devDependencies/peerDependencies/optionalDependencies/overrides by default. Narrow via policy.* filters if needed."),Array.isArray(e.specifierTypes)&&e.specifierTypes.length>0&&ve(i,"Review syncpack `specifierTypes` — vis has no direct equivalent today; specifier filtering belongs in versionGroups (issue #622)."),typeof e.filter=="string"&&e.filter.length>0&&ve(i,`Re-implement syncpack \`filter\` regex (${e.filter}) once vis exposes a top-level dep filter.`),(Array.isArray(e.sortAz)&&e.sortAz.length>0||Array.isArray(e.sortFirst)&&e.sortFirst.length>0||Array.isArray(e.sortExports)&&e.sortExports.length>0)&&ge(i,"syncpack sort options (sortAz / sortFirst / sortExports) are superseded by `vis sort-package-json` — no migration needed."),(e.sortPackages!==void 0||e.formatBugs!==void 0||e.formatRepository!==void 0)&&ge(i,"syncpack package.json shape options (sortPackages / formatBugs / formatRepository) are superseded by `vis sort-package-json` — no migration needed."),(e.lintFormatting!==void 0||e.lintSemverRanges!==void 0||e.lintVersions!==void 0)&&ge(i,"syncpack lint toggles (lintFormatting / lintSemverRanges / lintVersions) are covered by `vis lint` by default — no migration needed."),Array.isArray(e.source)&&e.source.length>0&&ve(i,`syncpack \`source\` was set to [${e.source.map(n=>JSON.stringify(n)).join(", ")}]. vis derives workspace globs from pnpm-workspace.yaml / package.json#workspaces — verify they match before relying on \`vis lint\`.`),typeof e.indent=="string"&&e.indent.length>0&&ge(i,"syncpack `indent` is implicit in vis — JSON writers honor `.editorconfig` (and the source file's existing indentation). No migration needed.")},MC=(e,i)=>{const n={};if(!Array.isArray(e.versionGroups))return n;for(const o of e.versionGroups){if(!o||typeof o!="object")continue;const a=o;if(!XC(a))continue;const t=Array.isArray(a.dependencies)?a.dependencies.filter(d=>typeof d=="string"&&d.length>0):[];if(t.length===0){ge(i,"versionGroup with `isBanned: true` has no `dependencies` entries — skipped.");continue}const s=Array.isArray(a.packages)?a.packages.filter(d=>typeof d=="string"&&d.length>0):[],r=a.label,u=typeof r=="string"&&r.length>0?r:"banned via syncpack versionGroups";for(const d of t){if(n[d]!==void 0){ge(i,`Multiple banned versionGroups target "${d}" — kept the first match; merge manually if needed.`);continue}n[d]=s.length>0?{packages:s,reason:u}:u}}return n},xwe=e=>{const i=[`name: ${JSON.stringify(e.name)}`,`path: ${JSON.stringify(e.path)}`,`strategy: ${JSON.stringify(e.strategy)}`];return e.depName!==void 0&&i.push(`depName: ${JSON.stringify(e.depName)}`),` { ${i.join(", ")} }`},Twe=(e,i)=>{if(typeof i=="string")return` ${JSON.stringify(e)}: ${JSON.stringify(i)}`;const n=[`reason: ${JSON.stringify(i.reason)}`];return i.packages&&i.packages.length>0&&n.push(`packages: [${i.packages.map(o=>JSON.stringify(o)).join(", ")}]`),i.paths&&i.paths.length>0&&n.push(`paths: [${i.paths.map(o=>JSON.stringify(o)).join(", ")}]`),i.replacement!==void 0&&n.push(`replacement: ${JSON.stringify(i.replacement)}`),` ${JSON.stringify(e)}: { ${n.join(", ")} }`},Ag=(e,i={})=>{const n=[],o=Object.entries(i);if(o.length>0){const a=o.map(([t,s])=>Twe(t,s)).join(`,
231
231
  `);n.push(` bannedDeps: {
232
232
  ${a},
233
233
  }`)}if(e.length>0){const a=e.map(t=>xwe(t)).join(`,
@@ -248,21 +248,21 @@ ${Ag(i,o)},
248
248
  `;return He(s,r,"utf8"),n.info(`Created ${s} with ${a}`),!0},Bwe=(e,i)=>{const n=L(e,"package.json"),o={catalogStripped:!1,configRemoved:!1,dependencyRemoved:!1,removedScripts:[],scriptCount:0};if(!Z(n))return o;const a=z(n),t=JSON.parse(a);let s=!1;t.syncpack&&(delete t.syncpack,s=!0,o.configRemoved=!0);for(const l of["dependencies","devDependencies"]){const g=t[l];g?.syncpack&&(delete g.syncpack,s=!0,o.dependencyRemoved=!0)}const r=t.workspaces;if(r&&typeof r=="object"&&!Array.isArray(r)){const l=r.catalog;l&&typeof l.syncpack=="string"&&(delete l.syncpack,s=!0,o.catalogStripped=!0);const g=r.catalogs;if(g&&typeof g=="object")for(const h of Object.values(g))h&&typeof h.syncpack=="string"&&(delete h.syncpack,s=!0,o.catalogStripped=!0)}const u=t.catalog;u&&typeof u.syncpack=="string"&&(delete u.syncpack,s=!0,o.catalogStripped=!0);const d=t.scripts;if(d){const l={};for(const[g,h]of Object.entries(d))typeof h=="string"&&yp.test(h)?(o.scriptCount+=1,o.removedScripts.push({name:g,value:h}),s=!0):l[g]=h;o.scriptCount>0&&(Object.keys(l).length===0?delete t.scripts:t.scripts=l)}if(s){const l=Os(n,a,{useEditorconfig:i});we(n),He(n,`${JSON.stringify(t,void 0,l)}
249
249
  `,"utf8")}return o},Xwe=[".husky/pre-commit",".vis/hooks/pre-commit",".git/hooks/pre-commit"],Hwe=[".github/workflows",".gitlab-ci.yml",".circleci/config.yml",".woodpecker.yml",".drone.yml"],NC=(e,i)=>{const n=[],o=a=>{const t=L(e,a);Z(t)&&yp.test(z(t))&&(n.push(a),ve(i,`Update ${a} — replace \`syncpack\` invocation(s) with \`vis lint\` / \`vis sort-package-json\` as appropriate.`))};for(const a of Hwe){const t=L(e,a);if(Z(t)){if(a===".github/workflows"){try{for(const s of Fi(t))(s.endsWith(".yml")||s.endsWith(".yaml"))&&o(`.github/workflows/${s}`)}catch{}continue}o(a)}}return n},EC=(e,i)=>{const n=[];for(const o of Xwe){const a=L(e,o);Z(a)&&yp.test(z(a))&&(n.push(o),ve(i,`Update ${o} — replace \`syncpack\` invocation with \`vis lint\` / \`vis sort-package-json\` as appropriate.`))}return n},Mwe=e=>{const i=L(e,"pnpm-workspace.yaml");if(!Z(i))return!1;let n;try{n=Ro(i)}catch{return!1}if(!n||typeof n!="object")return!1;let o=!1;const a=n.catalog;a&&typeof a.syncpack=="string"&&(delete a.syncpack,o=!0);const t=n.catalogs;if(t&&typeof t=="object")for(const s of Object.values(t))s&&typeof s.syncpack=="string"&&(delete s.syncpack,o=!0);return o&&(we(i),am(i,n)),o},Pwe=(e,i)=>{for(const n of[...TC,...pp]){const o=L(e,n);Z(o)&&(we(o,i),yo(o),ni(i,Og,"removedConfigCount"))}},Nwe=(e,i,n,o,a)=>{const t=BC(i,a);HC(i,a);const s=EC(e,a);s.length>0&&!n.silent&&o.warn(`Found syncpack reference in ${String(s.length)} hook file(s) — see manualSteps for details.`);const r=NC(e,a);r.length>0&&!n.silent&&o.warn(`Found syncpack reference in ${String(r.length)} CI file(s) — see manualSteps for details.`);const u=MC(i,a);(t.length>0||Object.keys(u).length>0)&&Dwe(e,t,o,u);const{catalogStripped:d,configRemoved:l,dependencyRemoved:g,removedScripts:h,scriptCount:c}=Bwe(e,n.useEditorconfig);l&&!n.silent&&o.info("Removed `syncpack` block from package.json"),g&&ni(a,Og,"removedPackageCount");const p=Mwe(e);if((d||p)&&!n.silent&&o.info("Stripped `syncpack` from catalog protocol entries."),c>0){ni(a,Og,"rewrittenScriptCount",c);for(const{name:f,value:w}of h)ve(a,`Recreate script \`${f}\` (removed; was \`${w}\`). Replace \`syncpack\` with \`vis lint\` / \`vis sort-package-json\` as appropriate.`);n.silent||o.info(`Removed ${String(c)} script(s) referencing \`syncpack\`. Replace with \`vis lint\` / \`vis sort-package-json\` as appropriate.`)}Pwe(e,a)},Ef=(e,i,n,o)=>{const a=DC(e);if(!a)return i.silent||n.info("No syncpack configuration found — nothing to migrate."),!1;const t=Cwe(e);t&&(ge(o,`Syncpack config ${t} is a TS/JS format vis migrate cannot load — executable config support is tracked in https://github.com/visulima/visulima/issues/622. Convert to .syncpackrc.json and re-run.`),ve(o,`Convert ${t} to .syncpackrc.json (or translate it directly into policy.customTypes.extraTypes in vis.config.ts) — see https://github.com/visulima/visulima/issues/622`),i.silent||n.warn(`Cannot read ${t} — manual migration required (https://github.com/visulima/visulima/issues/622).`)),Ywe(e)&&(ge(o,"vis.config.ts already declares `policy.customTypes.extraTypes` — skipping syncpack customTypes merge to avoid duplicates."),i.silent||n.warn("vis.config.ts already has policy.customTypes.extraTypes — skipping merge"));const s=Jwe(e,a,o);if(!s)return!1;if(i.dryRun){const r=BC(s,o),u=MC(s,o);HC(s,o),EC(e,o),NC(e,o);const d=PC(r,u);return i.silent||(d===""?n.info("[dry-run] No policy entries to merge — manualSteps will surface the rest."):(n.info(`[dry-run] Would merge ${d} into vis.config.ts:`),n.info(Ag(r,u)))),!0}return Nwe(e,s,i,n,o),!0},Ewe=e=>e.map(i=>{if(i.startsWith("^"))return{dependencies:!0,target:i.slice(1)};if(i.includes("#")){const[n,o]=i.split("#");return{projects:n,target:o}}return i}),Rwe=(e,i,n)=>{const o=e.tasks??e.pipeline??{},a={};for(const[r,u]of Object.entries(o)){if(r.includes("#"))continue;const d={};u.persistent&&(d.persistent=!0),u.interactive&&(d.interactive=!0);const l={};u.cache===!1&&(l.cache=!1),u.dependsOn&&u.dependsOn.length>0&&(l.dependsOn=Ewe(u.dependsOn)),u.inputs&&u.inputs.length>0&&(l.inputs=u.inputs),u.outputs&&u.outputs.length>0&&(l.outputs=u.outputs),u.env&&u.env.length>0&&(l.env=u.env),u.passThroughEnv&&u.passThroughEnv.length>0&&(l.passThroughEnv=u.passThroughEnv),Object.keys(d).length>0&&(l.options=d),a[r]=l}const t={};Object.keys(a).length>0&&(t.tasks=a);const s={};return e.globalDependencies&&e.globalDependencies.length>0&&(s.globalInputs=e.globalDependencies),e.globalEnv&&e.globalEnv.length>0&&(s.globalEnv=e.globalEnv),e.globalPassThroughEnv&&e.globalPassThroughEnv.length>0&&(s.globalPassThroughEnv=e.globalPassThroughEnv),Object.keys(s).length>0&&(t.taskRunner=s),["// Migrated from turbo.json by `vis migrate turborepo`.","// Review the generated `tasks` block and move project-specific tasks","// into each project's project.json.","",'import { defineConfig } from "@visulima/vis/config";',"",`export default defineConfig(${dp(t,L(i,"vis.config.ts"),n)});`,""].join(`
250
250
  `)},Rf=(e,i,n,o)=>{const a=yC(e,"turbo.json");if(!a){n.warn("No turbo.json found in workspace root — nothing to migrate."),o.warnings.push("No turbo.json at workspace root.");return}const t=Rwe(a,e,i.useEditorconfig);if(!lp(e,t,i,n,o))return;o.manualSteps.push("Review the `tasks` block in vis.config.ts — project-specific tasks (turbo's project#task syntax) were skipped and should be moved into each project's project.json."),o.manualSteps.push("vis adds two task primitives turbo doesn't have: `when: { os, env, branch, ci, not.* }` for conditional execution and `always: true` for finally/teardown tasks that run even when upstream fails. See docs/guides/conditional-and-finally-tasks.mdx.");const s=a.tasks??a.pipeline??{};Object.values(s).some(r=>r.outputLogs!==void 0)&&o.warnings.push("`outputLogs` was found on one or more tasks but vis has no equivalent setting — review and remove."),a.remoteCache?.enabled&&o.manualSteps.push("turbo remote cache detected. vis speaks the same HTTP protocol — set taskRunner.remoteCache { url, token, teamId } in vis.config.ts, or keep your TURBO_API / TURBO_TOKEN / TURBO_TEAM env vars (vis honours them as fallbacks).")},Owe=/\b(?:husky|lint-staged|nano-staged)\b/,Awe=e=>{const i=L(e,"package.json");if(Z(i))try{return JSON.parse(z(i))}catch{return}},Gwe=(e,i)=>{const n=Awe(e);if(!n)return!1;const o={...n.dependencies,...n.devDependencies};for(const t of rC)if(o[t])return!0;if(n.scripts){for(const t of Object.values(n.scripts))if(typeof t=="string"&&Owe.test(t))return!0}const{overrides:a}=i;return a?Object.keys(a).length>0:!1},Fwe=e=>Z(L(e,"turbo.json")),Qwe=e=>Z(L(e,"nx.json")),Wwe=e=>Z(L(e,".moon")),en=()=>{const e=[];return{lines:e,logger:{info:i=>{e.push(i)},warn:i=>{e.push(`⚠ ${i}`)}}}},Iwe=[{apply:({packageManager:e,root:i,visConfig:n},o,a)=>{kf(i,e,n,{dryRun:!1},a,o)},description:"Remove husky/lint-staged/nano-staged from package.json and rewrite scripts to `vis staged`.",detect:({root:e,visConfig:i})=>Gwe(e,i),id:"deps",probe:({packageManager:e,root:i,visConfig:n})=>{const{lines:o,logger:a}=en(),t=Mi();return kf(i,e,n,{dryRun:!0},a,t),o},title:"Dependencies & scripts"},{apply:({root:e},i,n)=>{Zf(e,{dryRun:!1},n,i)},description:"Inline lint-staged configuration into vis.config.ts.",detect:({root:e})=>!!pC(e),id:"lint-staged",probe:({root:e})=>{const{lines:i,logger:n}=en(),o=Mi();return Zf(e,{dryRun:!0},n,o),i},title:"lint-staged"},{apply:({root:e},i,n)=>{Df(e,{dryRun:!1},n,i)},description:"Inline nano-staged configuration into vis.config.ts.",detect:({root:e})=>!!fC(e),id:"nano-staged",probe:({root:e})=>{const{lines:i,logger:n}=en(),o=Mi();return Df(e,{dryRun:!0},n,o),i},title:"nano-staged"},{apply:({root:e},i,n)=>{Rf(e,{dryRun:!1},n,i)},description:"Translate turbo.json tasks into vis.config.ts.",detect:({root:e})=>Fwe(e),id:"turborepo",probe:({root:e})=>{const{lines:i,logger:n}=en(),o=Mi();return Rf(e,{dryRun:!0},n,o),i},title:"Turborepo"},{apply:({root:e},i,n)=>{Bf(e,{dryRun:!1},n,i)},description:"Translate nx.json targets into vis.config.ts.",detect:({root:e})=>Qwe(e),id:"nx",probe:({root:e})=>{const{lines:i,logger:n}=en(),o=Mi();return Bf(e,{dryRun:!0},n,o),i},title:"Nx"},{apply:({root:e},i,n)=>{Jf(e,{copyTemplates:!1,dryRun:!1},n,i)},description:"Translate .moon/tasks.yml into vis.config.ts.",detect:({root:e})=>Wwe(e),id:"moon",probe:({root:e})=>{const{lines:i,logger:n}=en(),o=Mi();return Jf(e,{copyTemplates:!1,dryRun:!0},n,o),i},title:"Moon"},{apply:({root:e},i,n)=>{Sf(e,{dryRun:!1},n,i)},description:"Convert gitleaks config/baseline/hooks to `vis secrets`.",detect:({root:e})=>!!(ed(e)??sp(e)??rp(e)),id:"gitleaks",probe:({root:e})=>{const{lines:i,logger:n}=en(),o=Mi();return Sf(e,{dryRun:!0},n,o),i},title:"Gitleaks"},{apply:({root:e},i,n)=>{Cf(e,{dryRun:!1},n,i)},description:"Convert Kingfisher baseline/rules/hooks to `vis secrets`.",detect:({root:e})=>!!(up(e)??id(e)),id:"kingfisher",probe:({root:e})=>{const{lines:i,logger:n}=en(),o=Mi();return Cf(e,{dryRun:!0},n,o),i},title:"Kingfisher"},{apply:({root:e},i,n)=>{Xf(e,{dryRun:!1},n,i)},description:"Replace secretlint config/hooks with `vis secrets`.",detect:({root:e})=>!!(jC(e)??kC(e)),id:"secretlint",probe:({root:e})=>{const{lines:i,logger:n}=en(),o=Mi();return Xf(e,{dryRun:!0},n,o),i},title:"Secretlint"},{apply:({root:e},i,n)=>{Ef(e,{dryRun:!1},n,i)},description:"Translate syncpack customTypes into policy.customTypes.extraTypes and strip the syncpack dep/scripts.",detect:({root:e})=>!!DC(e),id:"syncpack",probe:({root:e})=>{const{lines:i,logger:n}=en(),o=Mi();return Ef(e,{dryRun:!0},n,o),i},title:"Syncpack"},{apply:({root:e},i,n)=>{Hf(e,{dryRun:!1},n,i)},description:"Strip sherif config/dep/scripts and surface ignore-rules as a positive `vis lint --<rule>` command.",detect:({root:e})=>!!SC(e)||LC(e),id:"sherif",probe:({root:e})=>{const{lines:i,logger:n}=en(),o=Mi();return Hf(e,{dryRun:!0},n,o),i},title:"Sherif"}],_we=e=>Iwe.filter(i=>i.detect(e)),zwe=(e,i)=>({packageManager:lC(e),root:e,visConfig:i}),Kwe=(e,i)=>{i.info("── Migration Summary ──");const n=[["Staged configs merged into vis.config.ts",e.mergedStagedConfigCount],["Lint-staged configs inlined",e.inlinedLintStagedConfigCount],["Config files removed",e.removedConfigCount],["Packages removed",e.removedPackageCount],["Scripts rewritten",e.rewrittenScriptCount]];for(const[a,t]of n)t>0&&i.info(` ${a}: ${String(t)}`);e.gitHooksConfigured&&i.info(" Pre-commit hook updated to use vis staged");const o=Object.entries(e.perMigration);if(o.length>0){i.info(""),i.info("By migration:");for(const[a,t]of o){const s=[];t.removedConfigCount>0&&s.push(`${String(t.removedConfigCount)} config(s) removed`),t.removedPackageCount>0&&s.push(`${String(t.removedPackageCount)} package(s) removed`),t.rewrittenScriptCount>0&&s.push(`${String(t.rewrittenScriptCount)} script(s) rewritten`),i.info(` ${a}: ${s.join(", ")||"no changes"}`)}}if(e.backupsCreated.length>0&&(i.info(""),i.info(`Created ${String(e.backupsCreated.length)} .bak file(s) for rollback. Remove them once you're happy.`)),e.warnings.length>0){i.info(""),i.warn("Warnings:");for(const a of e.warnings)i.warn(` - ${a}`)}if(e.manualSteps.length>0){i.info(""),i.info("Manual steps required:");for(const a of e.manualSteps)i.info(` - ${a}`)}},qwe=(e,i)=>{if(e.length===0){i.info("No applicable migrations detected in this workspace.");return}i.info(`Detected migrations (non-interactive preview):
251
- `);for(const n of e){i.info(` • ${n.entry.title} — ${n.entry.description}`);for(const o of n.preview)i.info(` ${o}`);i.info("")}i.info("Run a specific migration with `vis migrate <name>` (e.g. `vis migrate deps`).")},Uwe=async e=>{const i=e.workspaceRoot??process.cwd(),n=e.visConfig??{},o=zwe(i,n),a=_we(o).map(g=>({entry:g,preview:g.probe(o)}));if(!(process.stdout.isTTY&&!ao)){qwe(a,e.logger);return}if(a.length===0){e.logger.info("No applicable migrations detected in this workspace.");return}const t=new Cfe(a),s=n.tui?.autoExit??!1,r=s===!0?3:typeof s=="number"?s:0,u=await PY(NY.createElement(Vfe,{autoExitSeconds:r,isDryRun:!1,store:t}),{alternateScreen:!0,exitOnCtrlC:!1,interactive:!0,patchConsole:!0}).waitUntilExit();if(!u||u.length===0){e.logger.info("No migrations selected — exiting.");return}const d=Mi(),l=[];for(const g of u)try{e.logger.info(`── Applying ${g.entry.title} ──`),g.entry.apply(o,d,e.logger),e.logger.info("")}catch(h){l.push({entry:g.entry,error:h}),e.logger.warn(`Failed to apply ${g.entry.title}: ${h.message}`)}Kwe(d,e.logger),l.length>0&&(e.logger.warn(""),e.logger.warn(`${String(l.length)} migration(s) failed — see messages above.`),process.exitCode=1)},Vwe={description:"Analyze and optimize dependencies using e18e replacements and @socketregistry overrides",examples:[["vis optimize","Interactive TUI to select and apply optimizations"],["vis optimize --dry-run","Preview available optimizations"],["vis optimize --pin","Pin Socket.dev overrides to exact versions"],["vis optimize --prod","Only optimize production dependencies"]],group:"Workspace",loader:()=>import("./handler66.js").then(e=>e.h),name:"optimize",options:[{alias:"d",defaultValue:!1,description:"Preview available optimizations without applying",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Pin Socket.dev overrides to exact versions",name:"pin",type:Boolean},{defaultValue:!1,description:"Only optimize production dependencies",name:"prod",type:Boolean},{defaultValue:!1,description:"Skip running install after applying overrides",name:"no-install",type:Boolean},{description:"Output format: table or json (default: table)",name:"format",type:String}]},eje={argument:{description:"Subcommand and arguments (e.g., cache dir, publish --dry-run, list --depth 0)",name:"args",type:String},description:"Package manager utilities (cache, publish, audit, list, config, etc.)",examples:[["vis pm cache dir","Show cache directory"],["vis pm cache clean","Clean cache"],["vis pm publish --dry-run","Preview publishing"],["vis pm list --depth 0","List direct dependencies"],["vis pm audit","Run security audit"],["vis pm whoami","Show logged-in user"]],group:"System",loader:()=>import("./handler17.js"),name:"pm"},ije={commandPath:["release"],description:"Author a new change file (interactive, or non-interactive via --packages)",examples:[["vis release add","Interactive prompt"],["vis release add --packages '@scope/cerebro:minor,@scope/string:patch' --message 'Add tab completion'","Non-interactive"],["vis release add --empty","Author an empty change file (acknowledges PR but releases nothing)"],["vis release add --name fix-tab-completion","Use a fixed slug instead of a random animal name"],["vis release add --from-bot-pr","Generate a change file from the current Dependabot / Renovate PR (changesets #647)"]],group:"Release",loader:()=>import("./handler31.js"),name:"add",options:[{description:"Comma-separated package:level pairs (e.g. '@scope/a:minor,@scope/b:patch')",name:"packages",type:String},{description:"Changelog body for the change file",name:"message",type:String},{description:"Slug for the filename (default: random animal name)",name:"name",type:String},{description:"Author an empty change file (no bumps; satisfies non-strict `check`)",name:"empty",type:Boolean},{description:"Author a `none` change file (acknowledged but no direct bump)",name:"none",type:Boolean},{description:"Inspect the current PR (via `gh pr view`) and author a change file from its Dependabot / Renovate title (changesets #647)",name:"from-bot-pr",type:Boolean}]},nje={commandPath:["release"],description:"Render the would-be changelog entries without writing to disk",examples:[["vis release changelog","Print rendered entries for the pending plan"],["vis release changelog --json","Emit ChangelogResult (with projectChangelogs[]) as JSON"]],group:"Release",loader:()=>import("./handler32.js"),name:"changelog",options:[{description:"Emit machine-readable JSON",name:"json",type:Boolean},{description:"Limit to packages matching this glob (CSV)",name:"filter",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},oje={commandPath:["release"],description:"Verify pending change files cover changed packages — CI / husky gate",examples:[["vis release check","Pass if at least one change file exists"],["vis release check --strict","Fail if any changed package isn't covered by a change file"],["vis release check --hook pre-commit","Run as a husky pre-commit hook"],["vis release check --no-fail","Print warnings but always exit 0"]],group:"Release",loader:()=>import("./handler33.js"),name:"check",options:[{description:"Require every changed package to have its own non-empty change file",name:"strict",type:Boolean},{description:"Hook context (pre-commit, pre-push) — affects which file states are counted",name:"hook",type:String},{description:"Always exit 0; warnings still print to stderr",name:"no-fail",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},aje={commandPath:["release","ci"],description:"CI: post or update a sticky PR comment with the pending release plan",examples:[["vis release ci check","Resolve PR from GITHUB_REF, post/update the release plan comment"],["vis release ci check --strict","Fail if any changed package isn't covered"]],group:"Release",loader:()=>import("./handler34.js"),name:"check",options:[{description:"Require every changed package to be covered by a change file",name:"strict",type:Boolean},{description:"Always exit 0 (warnings still print)",name:"no-fail",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},tje={commandPath:["release","ci"],description:"CI: emit JSON plan + write to $GITHUB_OUTPUT for workflow gating",examples:[["vis release ci plan","Emit { mode, packages, json } and set $GITHUB_OUTPUT"]],group:"Release",loader:()=>import("./handler35.js"),name:"plan",options:[{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},sje={commandPath:["release","ci"],description:"CI: rebase the open version-PR onto the base branch and force-push",examples:[["vis release ci rebase-pr","Rebase the version-PR branch onto base + force-push"],["vis release ci rebase-pr --branch=release/version","Override the version-PR branch"]],group:"Release",loader:()=>import("./handler36.js"),name:"rebase-pr",options:[{description:"Override the version-PR branch (default: vis-release/version-packages)",name:"branch",type:String},{description:"Override the base branch (default: release.baseBranch)",name:"base",type:String}]},rje={commandPath:["release","ci"],description:"CI: maintain a rolling version-PR (default) or version+publish inline (--auto-publish)",examples:[["vis release ci release","On push to main: open/update Versioned release PR; on PR merge: publish"],["vis release ci release --auto-publish","Skip version-PR; version + publish inline (alpha/beta workflow)"]],group:"Release",loader:()=>import("./handler56.js"),name:"release",options:[{description:"Skip version-PR; version + publish inline",name:"auto-publish",type:Boolean},{description:"Override version-PR branch (default: vis-release/version-packages)",name:"branch",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String},{description:"Bootstrap mode for greenfield monorepos: force currentVersionResolver=disk and skip remote tag-collision checks. Use on the very first release before any git tags exist.",name:"first-release",type:Boolean}]},uje={commandPath:["release","ci"],description:"CI: print setup checklist for tokens (VIS_GH_TOKEN, NPM_TOKEN, OIDC) and workflow permissions",examples:[["vis release ci setup","Walk through the recommended secrets + workflow setup"]],group:"Release",loader:()=>import("./handler37.js"),name:"setup",options:[]},dje={commandPath:["release","ci"],description:"CI: publish snapshot of affected packages + post sticky PR comment with install instructions",examples:[["vis release ci snapshot --tag pr-1234","Publish PR snapshot + post install snippet"]],group:"Release",loader:()=>import("./handler38.js"),name:"snapshot",options:[{description:"Override dist-tag (default: pr-<PR_NUMBER>)",name:"tag",type:String},{description:"PR-close cleanup mode — enumerate the closed PR's commit SHAs and remove their snapshot tags from the registry (when supported by the backend)",name:"on-close",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},lje={commandPath:["release"],description:"Preflight diagnostics for the release subsystem (workspace, PM, OIDC, NAPI, guards)",examples:[["vis release doctor","Run all checks; exit non-zero if any error"],["vis release doctor --json","Emit machine-readable report"]],group:"Release",loader:()=>import("./handler39.js"),name:"doctor",options:[{description:"Emit machine-readable JSON instead of a table",name:"json",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String},{description:"Bootstrap mode for greenfield monorepos: doctor asserts the workspace has no release tags and no package has been published yet. Pair with `vis release version --first-release`.",name:"first-release",type:Boolean}]},gje={commandPath:["release"],description:"Auto-derive a change file from branch commits (conventional-commits + path heuristics)",examples:[["vis release generate","Walk commits since the merge-base with baseBranch"],["vis release generate --from origin/main","Walk commits since the given ref"],["vis release generate --dry-run","Print the would-be content without writing"]],group:"Release",loader:()=>import("./handler64.js"),name:"generate",options:[{description:"Git ref to compare against (default: merge-base with baseBranch)",name:"from",type:String},{description:"Slug for the generated filename (default: random animal name)",name:"name",type:String},{description:"Print would-be content without writing",name:"dry-run",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},hje={commandPath:["release"],description:"Scaffold .vis/release; migrate from changesets / bumpy / semantic-release",examples:[["vis release init","Auto-detect source tool and scaffold"],["vis release init --from-semantic-release","Force semantic-release migration"],["vis release init --from-changesets","Force changesets migration"],["vis release init --fresh","Skip migration; start clean"],["vis release init --dry-run","Print what would happen without writing files"],["vis release init --from-semantic-release --apply","Actually perform the semantic-release migration writes"]],group:"Release",loader:()=>import("./handler40.js"),name:"init",options:[{description:"Force migration from semantic-release / multi-semantic-release",name:"from-semantic-release",type:Boolean},{description:"Force migration from changesets",name:"from-changesets",type:Boolean},{description:"Force migration from bumpy",name:"from-bumpy",type:Boolean},{description:"Skip migration; start clean",name:"fresh",type:Boolean},{description:"Print what would happen without writing files",name:"dry-run",type:Boolean},{alias:"y",description:"Auto-confirm prompts (CI-safe)",name:"yes",type:Boolean},{description:"Generate CI workflow files. GitHub → `.github/workflows/vis-release{,-check,-snapshot}.yml`. GitLab → `.gitlab-ci.yml`.",name:"workflows",type:Boolean},{description:"Override package manager when generating workflows (npm | pnpm | yarn | bun). Default: auto-detect",name:"package-manager",type:String},{description:"Actually perform the migration writes (not dry-run)",name:"apply",type:Boolean}]},cje={commandPath:["release"],description:"Print the next computed version for each package in the release plan. Read-only; no mutations.",examples:[["vis release next-version","Print `<pkg> <old> -> <new>` for every package in the plan"],["vis release next-version --package=@scope/a","Single-package mode"],["vis release next-version --json","Emit a `{ name: { from, to } }` JSON map"]],group:"Release",loader:()=>import("./handler41.js"),name:"next-version",options:[{description:"Limit output to a single package",name:"package",type:String},{description:"Emit a JSON `{ name: { from, to } }` map instead of pretty lines",name:"json",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Bootstrap mode for greenfield monorepos: preview the plan without registry / tag lookups (matches `vis release version --first-release`).",name:"first-release",type:Boolean}]},pje={commandPath:["release"],description:"Dry-run the configured notification channels (slack / discord / webhook / plugins) with a synthetic release",examples:[["vis release notifications test","Dispatch a fake release to every configured channel"],["vis release notifications test --channel=slack","Dispatch to every Slack channel only"],["vis release notifications test --channel=slack:eng","Dispatch to the slack channel with id=eng only"],["vis release notifications test --custom-context=./fake.json","Use operator-supplied JSON instead of the built-in synthetic release"],["vis release notifications test --json","Emit machine-readable results"]],group:"Release",loader:()=>import("./handler42.js"),name:"notifications",options:[{defaultOption:!0,defaultValue:"test",description:"Subcommand: test",name:"action",type:String},{description:"Restrict dispatch to a single channel kind (`slack`, `discord`, `webhook`) or an id'd channel (`slack:eng`)",name:"channel",type:String},{description:"Path to a JSON file containing a NotificationContext to use instead of the synthetic default",name:"custom-context",type:String},{description:"Emit machine-readable JSON instead of a per-channel report",name:"json",type:Boolean}]},vje={commandPath:["release"],description:"Inspect the release plan; with --interactive, walk through and override bump levels",examples:[["vis release plan","Emit pending plan as JSON"],["vis release plan --interactive","Walk through pending releases, accept or override each bump"],["vis release plan -i --write","Walk through interactively and write the chosen overrides to a change file"]],group:"Release",loader:()=>import("./handler43.js"),name:"plan",options:[{description:"Filter packages by name glob",name:"filter",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{alias:"i",description:"Walk through pending releases interactively and accept / override each bump level",name:"interactive",type:Boolean},{description:"When used with --interactive, write the chosen overrides to a new change file (.vis/release/<id>.md)",name:"write",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},yje={commandPath:["release"],description:"Enter / exit pre-release mode (changesets-compatible — every `version` produces a prerelease until exit)",examples:[["vis release pre enter alpha","Enter pre-mode with the `alpha` tag"],["vis release pre enter rc --no-commit","Enter pre-mode locally without committing pre.json"],["vis release pre exit","Flag the next `version` to consolidate + exit pre-mode"],["vis release pre status","Print whether pre-mode is active, exit-pending, or off"]],group:"Release",loader:()=>import("./handler45.js"),name:"pre",options:[{defaultOption:!0,defaultValue:"status",description:"Subcommand: enter | exit | status",name:"action",type:String},{description:"Prerelease tag (e.g. alpha, beta, rc). Required for `enter`",multiple:!0,name:"tag",type:String},{defaultValue:!0,description:"Commit pre.json after writing. Default: commit",name:"commit",type:Boolean},{defaultValue:!0,description:"Push the commit. Default: push",name:"push",type:Boolean}]},fje={commandPath:["release"],description:"Pack-then-publish unpublished packages, push tags, create GH releases",examples:[["vis release publish","Publish all pending packages"],["vis release publish --dry-run","Print what would publish without uploading"],["vis release publish --tag alpha","Override dist-tag"],["vis release publish --filter '@scope/*'","Limit to packages matching the glob"]],group:"Release",loader:()=>import("./handler46.js"),name:"publish",options:[{description:"Skip uploads — print what would happen",name:"dry-run",type:Boolean},{description:"Override npm dist-tag",name:"tag",type:String},{description:"Limit to packages matching this glob (CSV)",name:"filter",type:String},{description:"Skip `git push --tags` after publish (lands in M5)",name:"no-push",type:Boolean},{description:"2FA OTP token",name:"otp",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Resume from a previous run's state file (skips already-published packages)",name:"resume",type:Boolean},{description:"Run preflight checks (config + workspace + plan + auth) and exit. No mutations.",name:"check-only",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String},{description:"Bootstrap mode for greenfield monorepos: force currentVersionResolver=disk and skip remote tag-collision checks. Use on the very first release before any git tags exist.",name:"first-release",type:Boolean}]},mje={commandPath:["release"],description:"Publish 0.0.0-<tag>-<sha> snapshot versions of affected packages",examples:[["vis release snapshot --tag pr-1234","Publish snapshots tagged with the PR number"],["vis release snapshot --tag canary --filter '@scope/*'","Limit to a glob"],["vis release snapshot --tag pr-1234 --dry-run","Preview without uploading"]],group:"Release",loader:()=>import("./handler47.js"),name:"snapshot",options:[{description:"Required: dist-tag for the snapshot release",name:"tag",type:String},{description:"Override registry URL (defaults to pkg-pr-new backend or `release.snapshot.registry`)",name:"registry",type:String},{description:"Glob filter (CSV) — limit snapshots to specific packages",name:"filter",type:String},{description:"Print what would publish without uploading",name:"dry-run",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},bje={commandPath:["release"],description:"List, approve, or reject npm staged-publish records (RFC §13.6 — approve/reject need 2FA)",examples:[["vis release stage list","List every staged version (both npm + the local .vis/release/staged.json registry)"],["vis release stage list @scope/pkg","List staged versions for a single package"],["vis release stage list --json","Emit a machine-readable view of both sources"],["vis release stage approve <stage-id>","Promote a staged version, drain it from staged.json, commit + push the registry"],["vis release stage approve --all","Approve every pending stage tracked in .vis/release/staged.json"],["vis release stage reject <stage-id>","Reject a staged version (permanent — cannot be re-approved unless re-staged)"],["vis release stage approve <stage-id> --no-push","Approve, update the registry, commit locally (skip the push)"],["vis release stage approve <stage-id> --no-commit","Approve and update the registry only — no git commit"]],group:"Release",loader:()=>import("./handler48.js"),name:"stage",options:[{defaultOption:!0,defaultValue:"list",description:"Subcommand: list | approve | reject",name:"action",type:String},{description:"Stage IDs (positional args after the action)",multiple:!0,name:"stage-ids",type:String},{description:"Approve every pending stage tracked in .vis/release/staged.json",name:"all",type:Boolean},{description:"Package name filter for `list`",name:"filter",type:String},{description:"Emit machine-readable JSON",name:"json",type:Boolean},{defaultValue:!0,description:"Update .vis/release/staged.json but skip the auto-commit. Default: commit",name:"commit",type:Boolean},{defaultValue:!0,description:"Skip pushing the registry commit to the remote. Default: push",name:"push",type:Boolean}]},wje={commandPath:["release"],description:"Print pending release plan (which packages will bump and to what version)",examples:[["vis release status","Print pending plan in human-readable format"],["vis release status --json","Emit the plan as JSON for scripting / CI"],["vis release status --bump major,minor","Filter to packages getting major or minor bumps"],["vis release status --filter '@scope/*'","Show only packages matching the glob"]],group:"Release",loader:()=>import("./handler44.js"),name:"status",options:[{description:"Emit machine-readable JSON instead of a table",name:"json",type:Boolean},{description:"Filter packages by name glob",name:"filter",type:String},{description:"Filter by bump level (CSV: major,minor,patch)",name:"bump",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},jje={commandPath:["release"],description:"Apply pending change files to disk: bump versions + write CHANGELOG entries",examples:[["vis release version","Apply the plan to disk"],["vis release version --dry-run","Print what would change without touching disk"],["vis release version --channel alpha","Force a specific channel (overrides branch detection)"]],group:"Release",loader:()=>import("./handler49.js"),name:"version",options:[{description:"Skip writes — print the diff and exit",name:"dry-run",type:Boolean},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Limit to packages matching this glob (CSV)",name:"filter",type:String},{description:"Auto-commit after applying",name:"commit",type:Boolean},{description:"Run preflight checks (config + workspace + plan) and exit. No mutations.",name:"check-only",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String},{description:"Bootstrap mode for greenfield monorepos: force currentVersionResolver=disk and skip remote tag-collision checks. Use on the very first release before any git tags exist.",name:"first-release",type:Boolean}]},kje=[ije,gje,wje,vje,nje,oje,lje,cje,jje,fje,mje,bje,yje,hje,pje,aje,tje,rje,sje,dje,uje],Sje={alias:["rm","un","uninstall"],argument:{description:"Packages to remove",name:"packages",type:String},description:"Remove packages using the detected package manager",examples:[["vis remove lodash","Remove a package"],["vis rm old-package","Remove using alias"],["vis remove --filter app react","Remove from specific workspace"],["vis remove -g typescript","Remove global package"]],group:"Dependencies",loader:()=>import("./handler18.js"),name:"remove",options:[{alias:"D",defaultValue:!1,description:"Remove from devDependencies",name:"save-dev",type:Boolean},{alias:"g",defaultValue:!1,description:"Remove global package",name:"global",type:Boolean},{alias:"r",defaultValue:!1,description:"Remove from all workspace packages",name:"recursive",type:Boolean},{alias:"w",defaultValue:!1,description:"Remove from workspace root",name:"workspace-root",type:Boolean},{alias:"F",description:"Filter by workspace package name",multiple:!0,name:"filter",type:String}]},Lje={description:"Replay a previous task run from .vis/runs/ — show task results without re-executing",examples:[["vis replay","Show the most recent run summary"],["vis replay --run 2026-04-28T12-34-56_ab12","Inspect a specific historical run"],["vis replay --list","List every recorded run, newest first"],["vis replay --task @myorg/app:build","Focus on one task within the loaded run"],["vis replay --failed","Filter to only failed tasks"],["vis replay --format=json","Machine-readable output for CI"]],group:"Workspace",loader:le(()=>import("./handler19.js"),"replayExecute"),name:"replay",options:[{description:"Run id to replay (defaults to the most recent run)",name:"run",type:String},{defaultValue:!1,description:"List every available run instead of replaying one",name:"list",type:Boolean},{description:"Filter the replay to a single task id (e.g. @my/app:build)",name:"task",type:String},{defaultValue:!1,description:"Filter the replay to failed tasks only",name:"failed",type:Boolean},{description:"Output format: table or json (default: table)",name:"format",type:String}]},Cje={argument:{description:"The target to run (e.g., build, test, lint)",name:"target",type:String},description:"Run a target across workspace projects",examples:[["vis run","List all available targets"],["vis run build","Run build on all projects"],["vis run :build","Run build on all projects (moon-style)"],["vis run ~:test","Run test on the project closest to the current directory"],['vis run "#frontend:build"',"Run build on projects tagged 'frontend'"],['vis run :build --query "language=typescript"',"Filter by project metadata"],['vis run build --filter "@org/web"',"Run build on a single package (pnpm filter)"],['vis run build --filter "...@org/web"',"Run build on @org/web and everything that depends on it"],['vis run build -F "@org/web..."',"Run build on @org/web and its dependencies"],['vis run build -F "...[origin/main]"',"Run build on packages changed since origin/main + their dependents"],['vis run build -F "./packages/*"',"Run build on packages matched by a path glob"],["vis run test --affected","Run test only on git-changed projects"],["vis run build --fail-fast","Stop on first failure"],["vis run build --dry-run","Show execution plan without running"],["vis run destroy --reverse","Run leaves-first (teardown order, e.g. CDK/Pulumi destroy)"]],group:"Run & Execute",loader:()=>import("./handler76.js"),name:"run",options:[{alias:"p",description:"Comma-separated list of projects to run",name:"projects",type:String},{alias:"F",description:"pnpm-style package selector (repeatable). Supports name globs (@org/*), graph modifiers (...pkg dependents, pkg... dependencies, ...^pkg / pkg^... exclude self), changed-since ([main], ...[origin/main]), and path globs (./packages/*, {glob}).",multiple:!0,name:"filter",type:String},{defaultValue:!1,description:"Skip the toolchain pre-flight (no auto-install for any pinned tool: node / pnpm / yarn / npm / bun / deno / go / python / ruby / rust)",name:"skip-toolchain",type:Boolean},{description:"Detect lockfile/node_modules drift before running (warns in TTY, fails in CI). Use --no-preflight to disable.",name:"preflight",type:Boolean},{defaultValue:3,description:"Maximum number of parallel tasks (falls back to VIS_RUN_CONCURRENCY_LIMIT env var, then 3)",name:"parallel",type:Number},{defaultValue:!0,description:"Enable caching (use --no-cache to disable)",name:"cache",type:Boolean},{description:"Comma-separated selectors of tasks to bypass cache for (e.g. 'app:test', ':e2e', '#flaky:lint'). Other tasks in the run still cache normally. --no-cache wins when both are set.",name:"skip-cache",type:String},{description:"Custom cache directory",name:"cache-dir",type:String},{description:"Remote cache mode: read | write | readwrite (defaults to readwrite when remoteCache is configured)",name:"cache-mode",type:String},{description:"Remote cache wire backend: http (Turborepo-compatible) or reapi (Bazel Remote Execution API gRPC)",name:"cache-backend",type:String},{description:"Override how the requested target is hashed for this run: declared (hash listed inputs) or trace (hash the files the task actually reads). Overrides per-target hashMode config for the directly-run target.",name:"hash-mode",type:String},{defaultValue:!1,description:"Show what would run without executing",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Generate a run summary after execution",name:"summarize",type:Boolean},{description:'Partition tasks for distributed CI (e.g., "1/4" for first of four runners). Falls back to VIS_PARTITION env var.',name:"partition",type:String},{defaultValue:!1,description:"Skip project constraint validation",name:"skip-constraints",type:Boolean},{description:"Filter matched projects by a query (e.g. 'language=typescript && tag=lib')",name:"query",type:String},{defaultValue:!1,description:"Only run on projects affected by git changes (shorthand for vis affected)",name:"affected",type:Boolean},{defaultValue:!1,description:"Rerun affected tasks on file change. Ctrl+C to exit.",name:"watch",type:Boolean},{defaultValue:!1,description:"Stop all tasks on first failure",name:"fail-fast",type:Boolean},{defaultValue:!1,description:"Run the dependency graph in reverse (leaves first, then their dependents). Useful for teardown targets like `destroy`/`undeploy` where dependents must run before the things they depend on.",name:"reverse",type:Boolean},{description:"Output mode: interleaved (pass-through), labeled (prefix each line with [pkg#task]), or grouped (vite-task-style block)",name:"log",type:String},{description:"Output style: normal (print every task) or quiet (skip output for successful/cached tasks; failed tasks still print in CI mode, and remain in TUI scrollback in interactive mode). Defaults to normal; set run.quietOnSuccess in config to make quiet the default. Per-target options.outputStyle overrides this.",name:"output-style",type:String},{defaultValue:!1,description:"Run every task through a pseudo-terminal so color-aware tools render as if attached to a TTY (disables caching)",name:"pty",type:Boolean},{description:"Global retry budget: cap on total task retries across the run (per-target retryCount is still honored up to the budget)",name:"retry-budget",type:Number},{description:"Write a Chrome Tracing JSON profile of the run to this path (open in chrome://tracing or Perfetto)",name:"profile",type:String},{defaultValue:!1,description:"Render the most-recent run's saved summary (from .vis/last-summary.json) and exit without executing any tasks",name:"last-details",type:Boolean},{defaultValue:!0,description:"Show flaky task report on failure (use --no-flaky to suppress)",name:"flaky",type:Boolean},{defaultValue:!1,description:"Treat any task that needed at least one retry as a run failure (exit non-zero), even when retries eventually succeeded. Use in CI to surface flakes that retries would otherwise mask.",name:"fail-on-retry",type:Boolean},{description:"Fail a task if its command references an env var that is unset (no silent empty-string substitution). Use --no-strict-env to disable when set in config.",name:"strict-env",type:Boolean},{description:"Comma-separated tags this runner advertises (e.g. 'gpu,slow'). Tasks declaring `options.runnerTags` only run when at least one tag overlaps. Untagged tasks always run. Falls back to VIS_RUNNER_TAGS env var.",name:"runner-tags",type:String},{description:"Auto-start service deps. One of: auto | ephemeral | persistent | off. Defaults to `auto` in TTY, `off` in CI.",name:"services",type:String},{defaultValue:!1,description:"Stop services this run auto-started in registry mode when the run exits (clean, q, or Ctrl+C). Ephemeral services already die with the run.",name:"stop-services",type:Boolean}]},Yje={description:"Generate a CycloneDX 1.7 Software Bill of Materials for the workspace",examples:[["vis sbom","Write the full-workspace SBOM to sbom.cdx.json"],["vis sbom --focus=my-app","Scope the SBOM to my-app's transitive closure"],["vis sbom --focus=my-app,other","Focus multiple projects"],["vis sbom --format=xml --output=sbom.cdx.xml","Emit XML instead of JSON"],["vis sbom --include-dev","Include devDependencies (default: production only)"],["vis sbom --output=-","Write to stdout"]],group:"Security & Health",loader:()=>import("./handler20.js"),name:"sbom",options:[{description:"Project name(s) to focus on — comma-separated for multiple",name:"focus",type:String},{defaultValue:"json",description:"Output format: json (default) or xml",name:"format",type:String},{description:"Output path (use '-' for stdout; default: sbom.cdx.json)",name:"output",type:String},{defaultValue:!1,description:"Include devDependencies (default: production only)",name:"include-dev",type:Boolean}]},$je={argument:{description:"One or more paths to scan (defaults to workspace root)",name:"paths",type:String},description:"Scan a repository for hardcoded secrets and credentials",examples:[["vis secrets","Scan the workspace with grouped, colourised output"],["vis secrets --staged","Scan only files staged for the current commit (pre-commit hooks)"],["vis secrets --since main","Scan only files changed since the `main` branch"],["vis secrets --affected","Scan only projects affected by the current branch"],["vis secrets --history","Scan the full git history for secrets that were committed then removed"],["vis secrets --history --history-range main..HEAD","Scan only commits on the current branch since main"],["vis secrets --history --max-commits 100 --redact","Scan the last 100 commits, masking any secret values"],["vis secrets --init","Write an initial baseline from current findings"],["vis secrets --list-rules","Print all bundled detection rules"],["vis secrets --list-validators","Print non-HTTP validator types in the ruleset + install hints for each"],["vis secrets --exclude-rule generic-api-key --exclude-rule aws-access-token","Drop noisy rules"],["vis secrets --include-rule stripe-access-token","Check a single rule"],["vis secrets --enable-rule tag:preset:weak-passwords","Enable an opt-in rule group additively (defaults still fire)"],["vis secrets --include-rule tag:preset:password-manager","Restrict output to one opt-in group only"],["vis secrets --min-confidence high","Drop rules without a high confidence label (CI-friendly precision filter)"],["vis secrets --validate --only-verified","Live-verify each finding against its provider (one HTTP call per finding)"],["vis secrets --exclude 'dist/**' --exclude-from .secretsignore","Extra gitignore-syntax exclusions for the walker"],["vis secrets --config ./leaks.json --no-extend-bundled","Use only the supplied config, skip the bundled ruleset"],["vis secrets --concurrency 4","Cap the rayon thread pool (0 / omit = auto)"],["vis secrets --baseline .secrets-baseline.json","Suppress known findings; print diff vs. baseline"],["vis secrets --update-baseline","Merge current findings into the baseline (use --replace-baseline to overwrite)"],["vis secrets --format sarif > report.sarif","SARIF output for GitHub code-scanning"]],group:"Security",loader:()=>import("./handler77.js"),name:"secrets",options:[{description:"Path to a JSON config (gitleaks-compatible shape). Defaults to the bundled ruleset.",name:"config",type:String},{description:"Drop rules below this author-declared confidence: low (default), medium, high. Rules without a declared confidence (every gitleaks rule) are treated as low, so --min-confidence medium or higher drops them along with explicit low-confidence rules.",name:"min-confidence",type:String},{defaultValue:!1,description:"Live-verify each finding against its provider (one HTTP call per finding, max 8 concurrent). Only supports Kingfisher-style HTTP validators with StatusMatch / WordMatch response matchers; other types (gRPC, multi-step, checksum) mark the finding as validation=skipped. WARNING: sends candidate secrets to the provider — some providers alert their security team on failed auth attempts.",name:"validate",type:Boolean},{defaultValue:!1,description:"With --validate, drop every finding whose validation is not 'verified'. Useful for CI gating.",name:"only-verified",type:Boolean},{defaultValue:!1,description:"With --config, do not merge on top of the bundled ruleset — replace it.",name:"no-extend-bundled",type:Boolean},{defaultValue:"text",description:"Output format: text (default), json, sarif",name:"format",type:String},{description:"Path to a baseline JSON of previously-triaged findings",name:"baseline",type:String},{defaultValue:!1,description:"Scan only files staged for commit",name:"staged",type:Boolean},{description:"Scan only files changed since <ref> (e.g. main, origin/HEAD)",name:"since",type:String},{defaultValue:!1,description:"Scan only projects affected by the current branch",name:"affected",type:Boolean},{defaultValue:!1,description:"Scan the entire git history (every added/modified blob across commits) instead of the working tree. Surfaces secrets that were committed and later removed. Cannot be combined with --staged/--since/--affected.",name:"history",type:Boolean},{description:"With --history, limit the walk to a rev-list range (e.g. main..HEAD, HEAD~50..HEAD, or a single ref). Defaults to all reachable history of HEAD.",name:"history-range",type:String},{description:"With --history, cap the number of commits walked (most-recent first)",name:"max-commits",type:Number},{description:"Enable an opt-in rule or tag without restricting output — additive (e.g. tag:preset:weak-passwords, tag:preset:password-manager). Repeatable.",multiple:!0,name:"enable-rule",type:String},{description:"Rule id or tag:<name> selector — whitelist, only matching findings are emitted. Implies enablement. Repeatable.",multiple:!0,name:"include-rule",type:String},{description:"Rule id or tag:<name> selector — drop matching findings. Repeatable.",multiple:!0,name:"exclude-rule",type:String},{description:"Gitignore-syntax pattern to exclude from the walk (repeatable)",multiple:!0,name:"exclude",type:String},{description:"Path to a gitignore-shaped file the walker should honor (repeatable)",multiple:!0,name:"exclude-from",type:String},{defaultValue:!1,description:"Mask secret values in output",name:"redact",type:Boolean},{defaultValue:!1,description:"Scan dotfiles",name:"include-hidden",type:Boolean},{defaultValue:!1,description:"Do not respect .gitignore",name:"no-gitignore",type:Boolean},{description:"Skip files larger than this (bytes). Default: 10 MiB",name:"max-size",type:Number},{description:"Rayon worker threads (0 / omit = auto)",name:"concurrency",type:Number},{defaultValue:!1,description:"Merge current findings into the baseline and exit 0",name:"update-baseline",type:Boolean},{defaultValue:!1,description:"With --update-baseline, replace rather than merge",name:"replace-baseline",type:Boolean},{defaultValue:!1,description:"Scaffold a baseline from current findings",name:"init",type:Boolean},{defaultValue:!1,description:"With --init, preview the baseline without writing files",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Print all bundled detection rules and exit",name:"list-rules",type:Boolean},{defaultValue:!1,description:"Print non-HTTP validator types referenced by the current ruleset, with install hints for their optional peer dependencies.",name:"list-validators",type:Boolean},{defaultValue:!1,description:"Suppress all progress output (only emit findings)",name:"quiet",type:Boolean},{defaultValue:!1,description:"Print diagnostic info (skipped rules, etc.)",name:"verbose",type:Boolean}]},Zje={commandPath:["security"],description:"List build-script status — allowed, unapproved, and stale allowlist entries",examples:[["vis security list","Show the full build-script triage report"],["vis security list --json","Emit the report as JSON for tooling"]],group:"Security & Health",loader:()=>import("./list.js"),name:"list",options:[{defaultValue:!1,description:"Emit the report as JSON instead of human-readable text",name:"json",type:Boolean}]},Jje={commandPath:["security"],description:"Push vis.config security settings to the package manager's native config",examples:[["vis security sync","Sync allowBuilds + minimumReleaseAge to the PM-native config files"],["vis security sync --skip-allow-builds","Sync only the minimumReleaseAge knobs"],["vis security sync --skip-min-release-age","Sync only allowBuilds (trustedDependencies / onlyBuiltDependencies)"]],group:"Security & Health",loader:()=>import("./sync2.js"),name:"sync",options:[{defaultValue:!1,description:"Skip syncing allowBuilds (trustedDependencies, onlyBuiltDependencies)",name:"skip-allow-builds",type:Boolean},{defaultValue:!1,description:"Skip syncing minimumReleaseAge and its excludes",name:"skip-min-release-age",type:Boolean}]},xje={commandPath:["security"],description:"Run lifecycle scripts for packages in security.policies.installScripts.allow (LavaMoat 'run' parity)",examples:[["vis security run","Run preinstall/install/postinstall for every approved package"],["vis security run --with-root","Also run the workspace root's prepublish + prepare hooks"],["vis security run --root-only","Run only the workspace root's prepublish + prepare hooks"]],group:"Security & Health",loader:()=>import("./run.js"),name:"run",options:[{defaultValue:!1,description:"Also run the workspace root's prepublish + prepare hooks after dependencies",name:"with-root",type:Boolean},{defaultValue:!1,description:"Skip dependency scripts and only run the workspace root's prepublish + prepare hooks",name:"root-only",type:Boolean}]},Tje={commandPath:["security"],description:"Install @lavamoat/preinstall-always-fail as a devDep so a missing ignore-scripts setting fails loudly",examples:[["vis security tripwire","Install the tripwire devDependency"],["vis security tripwire --status","Report whether the tripwire is installed"],["vis security tripwire --remove","Remove the tripwire from package.json"]],group:"Security & Health",loader:()=>import("./tripwire.js"),name:"tripwire",options:[{defaultValue:!1,description:"Report whether @lavamoat/preinstall-always-fail is installed",name:"status",type:Boolean},{defaultValue:!1,description:"Remove @lavamoat/preinstall-always-fail from package.json",name:"remove",type:Boolean}]},Dje={commandPath:["security"],description:"Force-refresh the cached npm signing keys used by the signatures marshall",examples:[["vis security keys-refresh","Drop the disk cache and fetch a fresh key set from registry.npmjs.org"],["vis security keys-refresh --clear","Only drop the cache, do not refetch"],["vis security keys-refresh --json","Emit the refresh result as JSON for tooling"]],group:"Security & Health",loader:()=>import("./keys-refresh.js"),name:"keys-refresh",options:[{defaultValue:!1,description:"Only clear the cache, do not refetch",name:"clear",type:Boolean},{defaultValue:!1,description:"Emit the result as JSON instead of human-readable text",name:"json",type:Boolean}]},Bje={commandPath:["security"],description:"Verify the entire lockfile closure against supply-chain policies (firstSeen, publisherChange, blockExoticSubdeps)",examples:[["vis security verify-lockfile","Re-validate every locked entry; exit non-zero on a policy violation"],["vis security verify-lockfile --offline","Verify without network (skips firstSeen / publisherChange)"],["vis security verify-lockfile --json","Emit the verification result as JSON for CI"]],group:"Security & Health",loader:()=>import("./verify-lockfile.js"),name:"verify-lockfile",options:[{defaultValue:!1,description:"Emit the result as JSON instead of human-readable text",name:"json",type:Boolean},{defaultValue:!1,description:"Skip network-bound policies (firstSeen, publisherChange)",name:"offline",type:Boolean}]},Xje=[Zje,Jje,xje,Tje,Dje,Bje],td={description:"Target id, e.g. @my/api:db",name:"targetId",type:String},Hje={description:"Output format: table or json (default: table)",name:"format",type:String},Mje={argument:td,commandPath:["service"],description:"Start a service target detached so it survives across `vis run` invocations",examples:[["vis service start @my/api:db","Boot the db target as a long-lived service"],["vis service start @my/api:db --timeout=60000","Override readiness timeout"],["vis service start @my/api:db --no-readiness","Skip the readiness probe"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceStartExecute"),name:"start",options:[{description:"Readiness probe timeout in milliseconds",name:"timeout",type:Number},{defaultValue:!1,description:"Skip the readiness probe",name:"no-readiness",type:Boolean}]},Pje={argument:{description:"Target id to stop, or omit when using --all",name:"targetId",required:!1,type:String},commandPath:["service"],description:"Stop a running service",examples:[["vis service stop @my/api:db","Stop the db service"],["vis service stop --all","Stop every running service in this workspace"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceStopExecute"),name:"stop",options:[{defaultValue:!1,description:"Stop every service registered for this workspace",name:"all",type:Boolean},{description:"Override the SIGTERM→SIGKILL grace period in milliseconds",name:"grace-ms",type:Number}]},Nje={commandPath:["service"],description:"List services registered for this workspace",examples:[["vis service list","Print running services"],["vis service list --format=json","Machine-readable list"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceListExecute"),name:"list",options:[Hje]},Eje={argument:td,commandPath:["service"],description:"Re-run the readiness probe and report a service's health",examples:[["vis service status @my/api:db","Check whether the db service is reachable"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceStatusExecute"),name:"status",options:[{description:"Probe timeout in milliseconds",name:"timeout",type:Number}]},Rje={argument:td,commandPath:["service"],description:"Stop and re-start a running service",examples:[["vis service restart @my/api:db","Recycle the db service"],["vis service restart @my/api:db --no-readiness","Recycle and skip the readiness probe"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceRestartExecute"),name:"restart",options:[{description:"Readiness probe timeout in milliseconds",name:"timeout",type:Number},{description:"Override the SIGTERM→SIGKILL grace period in milliseconds",name:"grace-ms",type:Number},{defaultValue:!1,description:"Skip the readiness probe after restart",name:"no-readiness",type:Boolean}]},Oje={argument:td,commandPath:["service"],description:"Print or tail a service's captured stdout/stderr",examples:[["vis service logs @my/api:db","Print the captured log"],["vis service logs @my/api:db -f","Tail the log (Ctrl-C to exit)"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceLogsExecute"),name:"logs",options:[{alias:"f",defaultValue:!1,description:"Follow the log file (like `tail -f`)",name:"follow",type:Boolean}]},Aje=[Mje,Pje,Nje,Eje,Rje,Oje],Gje={commandPath:["shim"],description:"Install project-local PM shims (.vis/shims) that enforce the project's package manager",examples:[["vis shim install","Write npm/pnpm/yarn/… wrapper scripts in .vis/shims"]],group:"Runtime",loader:()=>import("./handler22.js").then(e=>({default:e.shimInstallExecute})),name:"install"},Fje={commandPath:["shim"],description:"Remove the project-local PM shim dir (.vis/shims)",examples:[["vis shim uninstall","Delete .vis/shims"]],group:"Runtime",loader:()=>import("./handler22.js").then(e=>({default:e.shimUninstallExecute})),name:"uninstall"},Qje={commandPath:["shim"],description:"Report whether the PM shims are installed and active on PATH",examples:[["vis shim status","Show shim install + PATH state"]],group:"Runtime",loader:()=>import("./handler22.js").then(e=>({default:e.shimStatusExecute})),name:"status"},Wje=[Gje,Fje,Qje],Ije={description:"Sort package.json files across the workspace using the sort-package-json Rust crate",examples:[["vis sort-package-json","Sort all package.json files in the workspace"],["vis sort-package-json --check","Check if files are already sorted (exit 1 if not)"],["vis sort-package-json --sort-scripts","Also sort the scripts field alphabetically"],["vis sort-package-json --indent 4","Force 4-space indentation (overrides per-file detection)"],["vis sort-package-json --indent tab","Force tab indentation"],["vis sort-package-json --ignore '**/fixtures/**'","Skip files matching one or more glob patterns"],["vis sort-package-json --sort-order name,version,license","Pin a custom prefix order before the default field order"],["vis sort-package-json --unsorted dependencies,devDependencies","Preserve original key order for the listed top-level sections"],["vis sort-package-json --no-final-newline","Do not append a trailing newline"],["vis sort-package-json --line-ending crlf","Force CRLF line endings (default: auto-detect per file)"]],group:"Workspace",loader:()=>import("./handler63.js"),name:"sort-package-json",options:[{alias:"c",defaultValue:!1,description:"Check if package.json files are sorted without writing (exits 1 if unsorted)",name:"check",type:Boolean},{defaultValue:!1,description:"Also sort the scripts field alphabetically",name:"sort-scripts",type:Boolean},{description:"Indent override: a number of spaces, the literal `tab`, or a literal whitespace string. When unset, the original file's indent is preserved.",name:"indent",type:String},{description:"Glob pattern of files to skip (basename match, or path-relative when the pattern contains `/`). Repeatable.",multiple:!0,name:"ignore",type:String},{description:"Comma-separated list of top-level keys to place first, before the default field order. Repeatable.",multiple:!0,name:"sort-order",type:String},{description:"Comma-separated list of top-level sections whose key order should be preserved (e.g. dependencies,devDependencies). Repeatable.",multiple:!0,name:"unsorted",type:String},{defaultValue:!1,description:"Do not append a trailing newline to the output (default: append one).",name:"no-final-newline",type:Boolean},{defaultValue:"auto",description:"Line ending to write: auto (per-file detection, default), lf, or crlf.",name:"line-ending",type:String},{description:"Disable collapsing `bugs: { url }` to the bare string form (default: enabled).",name:"no-format-bugs",type:Boolean},{description:"Disable collapsing `repository: { type, url }` to the GitHub `owner/repo` shorthand (default: enabled).",name:"no-format-repository",type:Boolean},{description:"Disable canonical sorting of `exports` condition keys (default: enabled).",name:"no-sort-exports",type:Boolean},{description:"Disable .editorconfig discovery for indent / line-ending defaults (default: enabled).",name:"no-editorconfig",type:Boolean}]},_je={argument:{description:"Project name or workspace-relative path of the package to extract",name:"package",type:String},description:"Extract a package into a standalone git repo, preserving its history",examples:[["vis split @scope/pkg --output ../pkg-repo","Extract a package into a new repo at ../pkg-repo"],["vis split packages/tooling/foo -o ../foo --remote git@github.com:me/foo.git --push","Extract, set origin, and push"],["vis split @scope/pkg -o ../pkg --remove","Extract, then delete the package from the monorepo (committed)"],["vis split @scope/pkg --dry-run","Print the git plan without making changes"]],group:"Workspace",loader:()=>import("./handler23.js"),name:"split",options:[{alias:"o",description:"Destination directory for the new repo (required unless --dry-run)",name:"output",type:String},{alias:"b",description:'Default branch name in the new repo (default: vis.config defaultBase or "main")',name:"branch",type:String},{description:"Git remote URL to set as origin on the new repo",name:"remote",type:String},{defaultValue:!1,description:"Push the new repo to origin (requires --remote)",name:"push",type:Boolean},{defaultValue:!1,description:"Delete the package from the monorepo after extracting and commit the removal",name:"remove",type:Boolean},{defaultValue:!1,description:"Prefix the rewritten commit messages with the package name",name:"annotate",type:Boolean},{defaultValue:!1,description:"Use a non-empty --output directory anyway",name:"force",type:Boolean},{defaultValue:!1,description:"Print the git plan instead of executing it",name:"dry-run",type:Boolean}]},zje={description:"Run linters on staged files using config from vis.config.ts",examples:[["vis staged","Run staged linters"],["vis staged --verbose","Run with verbose output"],["vis staged --no-stash","Run without backup stash"],["vis staged --diff HEAD~1","Run against a specific diff"]],group:"Run & Execute",loader:()=>import("./handler74.js"),name:"staged",options:[{defaultValue:!1,description:"Allow empty commits when tasks revert all staged changes",name:"allow-empty",type:Boolean},{defaultValue:!1,description:"Automatically stage new files that tasks create during the run",name:"auto-stage",type:Boolean},{description:"Number of concurrent tasks or false for serial",name:"concurrent",type:String},{defaultValue:!1,description:"Run all tasks to completion even if one fails",name:"continue-on-error",type:Boolean},{description:"Working directory to run all tasks in",name:"cwd",type:String},{defaultValue:!1,description:"Enable debug output",name:"debug",type:Boolean},{description:"Override the default --staged flag of git diff",name:"diff",type:String},{description:"Override the default diff-filter",name:"diff-filter",type:String},{defaultValue:!1,description:"Fail with exit code 1 when tasks modify tracked files",name:"fail-on-changes",type:Boolean},{defaultValue:!1,description:"Kill in-flight tasks with SIGKILL on fast-fail instead of the default SIGTERM",name:"force-kill",type:Boolean},{defaultValue:!1,description:"Hide unstaged changes from partially staged files",name:"hide-partially-staged",type:Boolean},{defaultValue:!1,description:"Hide all unstaged changes before running tasks",name:"hide-unstaged",type:Boolean},{defaultValue:!1,description:"Suppress console output",name:"quiet",type:Boolean},{defaultValue:!1,description:"Pass filepaths relative to cwd to tasks",name:"relative",type:Boolean},{defaultValue:!1,description:"Revert to original state in case of errors",name:"revert",type:Boolean},{defaultValue:!0,description:"Enable backup stash",name:"stash",type:Boolean},{defaultValue:!1,description:"Show task output even when tasks succeed",name:"verbose",type:Boolean}]},Kje={description:"Show a workspace health dashboard at a glance",examples:[["vis status","Full status overview"],["vis status --json","Machine-readable output"]],group:"Workspace",loader:()=>import("./handler24.js"),name:"status",options:[{defaultValue:!1,description:"Emit JSON output",name:"json",type:Boolean}]},qje={argument:{description:"What to sync: codeowners | package-json-fields",name:"kind",type:String},description:"Synchronise derived workspace artefacts (codeowners, package.json fields, tsconfig refs, …)",examples:[["vis sync codeowners","Generate CODEOWNERS at the repository root"],["vis sync codeowners --out=.github/CODEOWNERS","Write to .github/CODEOWNERS instead"],["vis sync codeowners --check","Fail if the existing file is stale"],["vis sync codeowners --from=project-json,nested-codeowners","Also aggregate nested CODEOWNERS files in the tree"],["vis sync codeowners --regeneration-command='pnpm codeowners'","Set a custom header instruction"],["vis sync codeowners --preserve-block","Splice the generated block between markers in an existing CODEOWNERS"],["vis sync codeowners --write-guard","Also emit GitHub + GitLab Write Guard CI for restricted projects"],["vis sync package-json-fields","Mirror license/author/repository/bugs/homepage/engines from root to every workspace package"],["vis sync package-json-fields --check","Fail if any workspace package.json is out of sync"],["vis sync package-json-fields --fields license,engines","Override the default field list for this run"]],group:"Workspace",loader:()=>import("./handler61.js"),name:"sync",options:[{description:"Output path for the generated file (default: <workspace>/CODEOWNERS) — codeowners kind only",name:"out",type:String},{defaultValue:!1,description:"Verify state without writing (exit non-zero if drift is found)",name:"check",type:Boolean},{description:"Input sources for codeowners. Comma-separated or repeated. Values: project-json | nested-codeowners | package-json-maintainers. Defaults to project-json.",multiple:!0,name:"from",type:String},{description:"Glob (repeatable) used to discover nested CODEOWNERS files. Defaults to `**/CODEOWNERS`.",multiple:!0,name:"nested-includes",type:String},{description:"Header instruction shown to reviewers (replaces the default 'update project.json' note). Codeowners kind only.",name:"regeneration-command",type:String},{defaultValue:!1,description:"Splice the generated block between markers in the existing file instead of overwriting it. Codeowners kind only.",name:"preserve-block",type:Boolean},{defaultValue:!1,description:"Also emit a .github/workflows/write-guard.yml scoped to projects with `restricted: true` in project.json. Codeowners kind only.",name:"write-guard",type:Boolean},{description:"Comma-separated list of fields to mirror from root → workspace packages (package-json-fields kind only). Repeatable.",multiple:!0,name:"fields",type:String},{description:"Glob pattern of package names to skip (package-json-fields kind only). Repeatable.",multiple:!0,name:"ignore-package-name",type:String},{defaultValue:"human",description:"Output format for package-json-fields: human | json",name:"format",type:String},{defaultValue:!1,description:"Suppress per-package log lines; print only the summary (package-json-fields kind only)",name:"quiet",type:Boolean}]},Uje={argument:{description:"Task ID to explain (e.g. @my/app:build)",name:"taskId",type:String},description:"Explain why a task is included in the graph by walking its dependency chain to a root",examples:[["vis task-why @myorg/app:build","Show what pulls build in"],["vis task-why lib-a:test","Check the test task's triggers"]],group:"Workspace",loader:()=>import("./handler25.js"),name:"task-why"},As="Workspace",Vje={commandPath:["toolchain"],description:"Show every detected manager + expected vs actual tool versions",examples:[["vis toolchain status","Show every detected manager + expected vs actual tool versions"],["vis toolchain status --json","Emit the status as JSON"],["vis toolchain status --exit-code","Exit 1 if any tool mismatches (for CI)"]],group:As,loader:le(()=>import("./handler26.js"),"statusExecute"),name:"status",options:[{defaultValue:!1,description:"Exit 1 if any tool mismatches",name:"exit-code",type:Boolean},{defaultValue:!1,description:"Emit JSON",name:"json",type:Boolean}]},eke={commandPath:["toolchain"],description:"Print the primary manager's name (for scripts)",examples:[["vis toolchain detect","Print the primary manager's name"]],group:As,loader:le(()=>import("./handler26.js"),"detectExecute"),name:"detect"},ike={commandPath:["toolchain"],description:"Install pinned versions — per-tool delegation to the right manager",examples:[["vis toolchain install","Install pinned versions"],["vis toolchain install --dry-run","Print the commands that would run, but don't execute"]],group:As,loader:le(()=>import("./handler26.js"),"installExecute"),name:"install",options:[{defaultValue:!1,description:"Print the command that would run, but don't execute",name:"dry-run",type:Boolean}]},nke={argument:{description:"Tool and version to pin, e.g. node@22.13.0 or pnpm@10.32.1",name:"spec",type:String},commandPath:["toolchain"],description:"Pin a version via the best manager for that tool",examples:[["vis toolchain use node@22.13.0","Pin node 22.13.0 via the best runtime manager"],["vis toolchain use pnpm@10.32.1","Update the packageManager field; pnpm self-activates"],["vis toolchain use node@22.13.0 --dry-run","Print the command without running it"]],group:As,loader:le(()=>import("./handler26.js"),"useExecute"),name:"use",options:[{defaultValue:!1,description:"Print the command that would run, but don't execute",name:"dry-run",type:Boolean},{defaultValue:!0,description:"Also mirror the version into engines.<tool> when that field already exists. --no-engines to skip.",name:"engines",type:Boolean}]},oke={argument:{description:"Tool to resolve, e.g. node",name:"tool",type:String},commandPath:["toolchain"],description:"Print the resolved binary path a manager would launch for a tool",examples:[["vis toolchain which node","Resolve the node binary the manager would launch"]],group:As,loader:le(()=>import("./handler26.js"),"whichExecute"),name:"which"},ake=[Vje,eke,ike,nke,oke],tke={argument:{description:"Packages to unlink (omit for current package)",name:"packages",type:String},description:"Unlink a previously linked package",examples:[["vis unlink","Unlink current package"],["vis unlink react","Unlink specific package"],["vis unlink -r","Unlink in all workspace packages"]],group:"Dependencies",loader:()=>import("./handler27.js"),name:"unlink",options:[{alias:"r",defaultValue:!1,description:"Unlink in all workspace packages",name:"recursive",type:Boolean}]},ske={alias:"up",argument:{description:"Packages to update (updates all if omitted)",name:"packages",type:String},description:"Update packages to their latest versions",examples:[["vis update react","Update react within semver range"],["vis up react -L","Update react to latest"],["vis update -i","Interactive mode"],["vis update --filter app","Update in specific workspace"],["vis update -r","Update in all workspaces"],["vis update --target minor","Only apply minor/patch updates (catalog mode)"],["vis update --dry-run","Preview changes without applying"],["vis update --exclude '@types/*'","Exclude packages by pattern"],["vis update --changelog","Show changelog links after updating"],["vis update --rollback","Restore catalog from last backup"],["vis update --ai","Run AI analysis before applying updates"]],group:"Dependencies",loader:()=>import("./handler73.js"),name:"update",options:[{alias:"L",conflicts:"target",description:"Update to latest version (ignore semver range; equivalent to --target latest)",name:"latest",type:Boolean},{defaultValue:!1,description:"Ignore the minimumReleaseAge gate and select the truly latest version even if freshly published. The selected packages are added to the package manager's native age-gate exclude list (pnpm minimumReleaseAgeExclude, bun minimumReleaseAgeExcludes, yarn npmPreapprovedPackages) so the follow-up install isn't blocked; npm has no per-package exclude. Combine with --latest to also cross the semver range.",name:"ignore-release-age",type:Boolean},{alias:"t",conflicts:"latest",description:"Update target: latest, minor, or patch (default: latest, catalog mode)",name:"target",type:String},{alias:"d",defaultValue:!1,description:"Preview changes without applying",name:"dry-run",type:Boolean},{alias:"g",defaultValue:!1,description:"Update global packages",name:"global",type:Boolean},{alias:"r",defaultValue:!1,description:"Update recursively in all workspace packages",name:"recursive",type:Boolean},{description:"Filter packages in monorepo (pm-wrapper mode; catalog mode uses --include/--exclude)",name:"filter",type:String},{alias:"w",defaultValue:!1,description:"Include workspace root",name:"workspace-root",type:Boolean},{alias:"D",conflicts:"prod",description:"Update only devDependencies",name:"dev",type:Boolean},{alias:"P",conflicts:"dev",description:"Update only dependencies",name:"prod",type:Boolean},{alias:"i",defaultValue:!1,description:"Interactive mode",name:"interactive",type:Boolean},{defaultValue:!1,description:"Don't update optionalDependencies",name:"no-optional",type:Boolean},{defaultValue:!1,description:"Include peerDependencies in update checks",name:"peer",type:Boolean},{defaultValue:!1,description:"Also check workspace-owned package names against the registry (catalog mode)",name:"include-internal",type:Boolean},{alias:"l",defaultValue:!1,description:"Include packages with pinned/exact versions (no ^ or ~ prefix; catalog mode)",name:"include-locked",type:Boolean},{defaultValue:!1,description:"Update lockfile only",name:"no-save",type:Boolean},{description:"Glob pattern to include packages (repeatable, catalog mode)",lazyMultiple:!0,name:"include",type:String},{description:"Glob pattern to exclude packages (repeatable, catalog mode)",lazyMultiple:!0,name:"exclude",type:String},{defaultValue:!1,description:"Include prerelease versions (catalog mode)",name:"prerelease",type:Boolean},{description:"Check for known security vulnerabilities via OSV.dev (default: true; --no-security to skip)",name:"security",type:Boolean},{defaultValue:!1,description:"Skip catalog mode, use package manager directly",name:"no-catalog",type:Boolean},{description:"Output format: table, json, or minimal (default: table)",name:"format",type:String},{defaultValue:!1,description:"Show changelog URLs for updated packages",name:"changelog",type:Boolean},{description:"Run install after catalog update, --no-install to skip (default: true)",name:"install",type:Boolean},{defaultValue:!1,description:"Restore catalog file from the last backup",name:"rollback",type:Boolean},{defaultValue:!1,description:"Run AI analysis on outdated packages before updating (catalog mode)",name:"ai",type:Boolean},{description:"AI analysis type: impact, security, compatibility, or recommend (default: impact)",name:"ai-type",type:String},{defaultValue:!1,description:"Skip typosquat name check for package arguments",name:"no-typosquat-check",type:Boolean},{defaultValue:!1,description:"Skip the offline marshall pipeline (author, provenance, metadata, downloads, expired-domains, new-bin, signatures, archived-repo) when explicit package arguments are supplied",name:"no-marshall-check",type:Boolean},{description:"Cap concurrent registry requests during outdated checks (default: 8)",name:"max-concurrent-requests",type:Number},{description:"Release channel filter: stable (default), same (match current's prerelease channel), or any",name:"release-channel",type:String},{alias:"y",defaultValue:!1,description:"Skip the confirmation prompt for blanket --latest updates. Required in non-TTY contexts (CI) when running `vis update --latest` without explicit package arguments.",name:"yes",type:Boolean},{defaultValue:!1,description:"Skip the GitHub Actions ecosystem scan (workflows + composite action.yml files)",name:"no-actions",type:Boolean},{defaultValue:!1,description:"Skip the Docker ecosystem scan (Dockerfile + docker-compose images)",name:"no-docker",type:Boolean},{defaultValue:!1,description:"Skip the GitLab CI ecosystem scan (.gitlab-ci.yml + .gitlab/ci/**)",name:"no-gitlab",type:Boolean},{defaultValue:!1,description:"Include branch references (e.g. actions/checkout@main) when scanning workflows",name:"include-branches",type:Boolean},{description:"Reference style for GitHub Actions updates: sha (default, pin to commit SHA + version comment) or preserve",name:"style",type:String},{description:"GitHub token for actions resolution (overrides GITHUB_TOKEN / GH_TOKEN env)",name:"actions-token",type:String},{description:"GitLab token for include-ref resolution (overrides GITLAB_TOKEN / CI_JOB_TOKEN env)",name:"gitlab-token",type:String}]},rke={argument:{description:"Target version (defaults to latest)",name:"version",type:String},description:"Update vis itself to the latest version",examples:[["vis self-update","Update to latest"],["vis self-update 2.0.0","Install specific version"],["vis self-update --check","Check for updates without installing"]],group:"System",loader:()=>import("./handler28.js"),name:"self-update",options:[{defaultValue:!1,description:"Check for updates without installing",name:"check",type:Boolean},{defaultValue:!1,description:"Reinstall even if already current",name:"force",type:Boolean},{defaultValue:!1,description:"Suppress output (CI mode)",name:"silent",type:Boolean}]},uke={alias:"explain",argument:{description:"Package(s) to explain",name:"packages",type:String},description:"Show why a package is installed (dependency chain)",examples:[["vis why react","Show why react is installed"],["vis why react --json","Output as JSON"],["vis why react -r","Check across all workspaces"],["vis explain react","Alias matching npm's command"]],group:"Dependencies",loader:()=>import("./handler29.js"),name:"why",options:[{defaultValue:!1,description:"Output as JSON",name:"json",type:Boolean},{defaultValue:!1,description:"Show extended information (pnpm)",name:"long",type:Boolean},{defaultValue:!1,description:"Machine-readable output (pnpm)",name:"parseable",type:Boolean},{alias:"r",defaultValue:!1,description:"Check across all workspaces",name:"recursive",type:Boolean},{alias:"D",conflicts:"prod",description:"Filter to dev dependencies (pnpm)",name:"dev",type:Boolean},{alias:"P",conflicts:"dev",description:"Filter to production dependencies (pnpm)",name:"prod",type:Boolean},{defaultValue:!1,description:"Exclude optional dependencies (pnpm)",name:"no-optional",type:Boolean},{alias:"g",defaultValue:!1,description:"Check globally installed packages (pnpm)",name:"global",type:Boolean},{description:"Limit dependency tree depth",name:"depth",type:Number},{alias:"F",description:"Filter by workspace package name",multiple:!0,name:"filter",type:String}]},dke={argument:{description:"File to run, with any args to forward to it",name:"file",type:String},description:"Run a TypeScript/JavaScript file directly under the selected runtime (node | bun)",examples:[["vis x script.ts","Run a TypeScript file (full TS surface: enums, decorators)"],["vis x --runtime bun server.ts","Run under Bun"],["vis x build.ts foo bar","Forward positional args to the file"],["vis x task.ts -- --watch","Forward flags after -- to the file"]],group:"Run & Execute",loader:()=>import("./handler30.js"),name:"x",options:[]},lke={beforeCommand:async e=>{try{const i=e.options?.cwd,n=e.options?.config;let o;if(i)o=Ha(process.cwd(),i);else{const r=process.env.VIS_MONOREPO_ROOT;o=r&&r.length>0?r:lm(process.cwd()).path}e.workspaceRoot=o;const a=n?Ha(process.cwd(),n):void 0;let t=a??Uo(o);try{e.visConfig=await Cp(o,a?{explicitConfigPath:a}:void 0);const r=e.visConfig?.versionConstraint;if(r&&!Tl.validRange(r)){e.logger.error(""),e.logger.error(sd(pn("✖ Invalid versionConstraint"))),e.logger.error(` vis.config.ts has versionConstraint ${pn(JSON.stringify(r))}, which is not a valid semver range.`),e.logger.error(""),process.exitCode=1;return}if(r&&!Tl.satisfies(Lr.version,r)){e.logger.error(""),e.logger.error(sd(pn("✖ vis version too old"))),e.logger.error(` vis.config.ts requires vis ${pn(r)}, but the current version is ${pn(Lr.version)}.`),e.logger.error(` ${Rt("→")} Upgrade: ${eo("pnpm add -D @visulima/vis@latest")}`),e.logger.error(""),process.exitCode=1;return}}catch(r){const u=t,d=r instanceof Error?r.message:String(r);e.visConfigError={file:u??void 0,message:d};const l=!!process.stdout.isTTY&&!ao;if(u&&!l){if(e.logger.error(""),e.logger.error(sd(pn(`✖ Failed to load ${u}`))),e.logger.error(` ${d}`),e.logger.error(""),d.includes("Cannot find module")){const g=/Cannot find module '([^']+)'/.exec(d)?.[1]??"unknown";e.logger.error(`${Rt("→ Hint:")} The module ${pn(g)} could not be resolved.`),g.includes("@visulima/vis")?(e.logger.error(" This usually means the package isn't installed or the export path changed."),e.logger.error(` Try: ${eo("pnpm add @visulima/vis")}`),e.logger.error(` Or regenerate: ${eo("vis init --force")}`)):e.logger.error(` Try: ${eo(`pnpm add ${g}`)}`)}else d.includes("SyntaxError")||d.includes("Unexpected token")?(e.logger.error(`${Rt("→ Hint:")} The config file has a syntax error.`),e.logger.error(" Check your config for typos or invalid syntax."),e.logger.error(` Or regenerate: ${eo("vis init --force")}`)):(e.logger.error(`${Rt("→ Hint:")} Delete the broken config and recreate it:`),e.logger.error(` ${eo(`rm ${u} && vis init`)}`));e.logger.error(""),e.logger.error(` Continuing with default settings.
251
+ `);for(const n of e){i.info(` • ${n.entry.title} — ${n.entry.description}`);for(const o of n.preview)i.info(` ${o}`);i.info("")}i.info("Run a specific migration with `vis migrate <name>` (e.g. `vis migrate deps`).")},Uwe=async e=>{const i=e.workspaceRoot??process.cwd(),n=e.visConfig??{},o=zwe(i,n),a=_we(o).map(g=>({entry:g,preview:g.probe(o)}));if(!(process.stdout.isTTY&&!ao)){qwe(a,e.logger);return}if(a.length===0){e.logger.info("No applicable migrations detected in this workspace.");return}const t=new Cfe(a),s=n.tui?.autoExit??!1,r=s===!0?3:typeof s=="number"?s:0,u=await PY(NY.createElement(Vfe,{autoExitSeconds:r,isDryRun:!1,store:t}),{alternateScreen:!0,exitOnCtrlC:!1,interactive:!0,patchConsole:!0}).waitUntilExit();if(!u||u.length===0){e.logger.info("No migrations selected — exiting.");return}const d=Mi(),l=[];for(const g of u)try{e.logger.info(`── Applying ${g.entry.title} ──`),g.entry.apply(o,d,e.logger),e.logger.info("")}catch(h){l.push({entry:g.entry,error:h}),e.logger.warn(`Failed to apply ${g.entry.title}: ${h.message}`)}Kwe(d,e.logger),l.length>0&&(e.logger.warn(""),e.logger.warn(`${String(l.length)} migration(s) failed — see messages above.`),process.exitCode=1)},Vwe={description:"Analyze and optimize dependencies using e18e replacements and @socketregistry overrides",examples:[["vis optimize","Interactive TUI to select and apply optimizations"],["vis optimize --dry-run","Preview available optimizations"],["vis optimize --pin","Pin Socket.dev overrides to exact versions"],["vis optimize --prod","Only optimize production dependencies"]],group:"Workspace",loader:()=>import("./handler67.js").then(e=>e.h),name:"optimize",options:[{alias:"d",defaultValue:!1,description:"Preview available optimizations without applying",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Pin Socket.dev overrides to exact versions",name:"pin",type:Boolean},{defaultValue:!1,description:"Only optimize production dependencies",name:"prod",type:Boolean},{defaultValue:!1,description:"Skip running install after applying overrides",name:"no-install",type:Boolean},{description:"Output format: table or json (default: table)",name:"format",type:String}]},eje={argument:{description:"Subcommand and arguments (e.g., cache dir, publish --dry-run, list --depth 0)",name:"args",type:String},description:"Package manager utilities (cache, publish, audit, list, config, etc.)",examples:[["vis pm cache dir","Show cache directory"],["vis pm cache clean","Clean cache"],["vis pm publish --dry-run","Preview publishing"],["vis pm list --depth 0","List direct dependencies"],["vis pm audit","Run security audit"],["vis pm whoami","Show logged-in user"]],group:"System",loader:()=>import("./handler17.js"),name:"pm"},ije={commandPath:["release"],description:"Author a new change file (interactive, or non-interactive via --packages)",examples:[["vis release add","Interactive prompt"],["vis release add --packages '@scope/cerebro:minor,@scope/string:patch' --message 'Add tab completion'","Non-interactive"],["vis release add --empty","Author an empty change file (acknowledges PR but releases nothing)"],["vis release add --name fix-tab-completion","Use a fixed slug instead of a random animal name"],["vis release add --from-bot-pr","Generate a change file from the current Dependabot / Renovate PR (changesets #647)"]],group:"Release",loader:()=>import("./handler31.js"),name:"add",options:[{description:"Comma-separated package:level pairs (e.g. '@scope/a:minor,@scope/b:patch')",name:"packages",type:String},{description:"Changelog body for the change file",name:"message",type:String},{description:"Slug for the filename (default: random animal name)",name:"name",type:String},{description:"Author an empty change file (no bumps; satisfies non-strict `check`)",name:"empty",type:Boolean},{description:"Author a `none` change file (acknowledged but no direct bump)",name:"none",type:Boolean},{description:"Inspect the current PR (via `gh pr view`) and author a change file from its Dependabot / Renovate title (changesets #647)",name:"from-bot-pr",type:Boolean}]},nje={commandPath:["release"],description:"Render the would-be changelog entries without writing to disk",examples:[["vis release changelog","Print rendered entries for the pending plan"],["vis release changelog --json","Emit ChangelogResult (with projectChangelogs[]) as JSON"]],group:"Release",loader:()=>import("./handler32.js"),name:"changelog",options:[{description:"Emit machine-readable JSON",name:"json",type:Boolean},{description:"Limit to packages matching this glob (CSV)",name:"filter",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},oje={commandPath:["release"],description:"Verify pending change files cover changed packages — CI / husky gate",examples:[["vis release check","Pass if at least one change file exists"],["vis release check --strict","Fail if any changed package isn't covered by a change file"],["vis release check --hook pre-commit","Run as a husky pre-commit hook"],["vis release check --no-fail","Print warnings but always exit 0"]],group:"Release",loader:()=>import("./handler33.js"),name:"check",options:[{description:"Require every changed package to have its own non-empty change file",name:"strict",type:Boolean},{description:"Hook context (pre-commit, pre-push) — affects which file states are counted",name:"hook",type:String},{description:"Always exit 0; warnings still print to stderr",name:"no-fail",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},aje={commandPath:["release","ci"],description:"CI: post or update a sticky PR comment with the pending release plan",examples:[["vis release ci check","Resolve PR from GITHUB_REF, post/update the release plan comment"],["vis release ci check --strict","Fail if any changed package isn't covered"]],group:"Release",loader:()=>import("./handler34.js"),name:"check",options:[{description:"Require every changed package to be covered by a change file",name:"strict",type:Boolean},{description:"Always exit 0 (warnings still print)",name:"no-fail",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},tje={commandPath:["release","ci"],description:"CI: emit JSON plan + write to $GITHUB_OUTPUT for workflow gating",examples:[["vis release ci plan","Emit { mode, packages, json } and set $GITHUB_OUTPUT"]],group:"Release",loader:()=>import("./handler35.js"),name:"plan",options:[{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},sje={commandPath:["release","ci"],description:"CI: rebase the open version-PR onto the base branch and force-push",examples:[["vis release ci rebase-pr","Rebase the version-PR branch onto base + force-push"],["vis release ci rebase-pr --branch=release/version","Override the version-PR branch"]],group:"Release",loader:()=>import("./handler36.js"),name:"rebase-pr",options:[{description:"Override the version-PR branch (default: vis-release/version-packages)",name:"branch",type:String},{description:"Override the base branch (default: release.baseBranch)",name:"base",type:String}]},rje={commandPath:["release","ci"],description:"CI: maintain a rolling version-PR (default) or version+publish inline (--auto-publish)",examples:[["vis release ci release","On push to main: open/update Versioned release PR; on PR merge: publish"],["vis release ci release --auto-publish","Skip version-PR; version + publish inline (alpha/beta workflow)"]],group:"Release",loader:()=>import("./handler56.js"),name:"release",options:[{description:"Skip version-PR; version + publish inline",name:"auto-publish",type:Boolean},{description:"Override version-PR branch (default: vis-release/version-packages)",name:"branch",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String},{description:"Bootstrap mode for greenfield monorepos: force currentVersionResolver=disk and skip remote tag-collision checks. Use on the very first release before any git tags exist.",name:"first-release",type:Boolean}]},uje={commandPath:["release","ci"],description:"CI: print setup checklist for tokens (VIS_GH_TOKEN, NPM_TOKEN, OIDC) and workflow permissions",examples:[["vis release ci setup","Walk through the recommended secrets + workflow setup"]],group:"Release",loader:()=>import("./handler37.js"),name:"setup",options:[]},dje={commandPath:["release","ci"],description:"CI: publish snapshot of affected packages + post sticky PR comment with install instructions",examples:[["vis release ci snapshot --tag pr-1234","Publish PR snapshot + post install snippet"]],group:"Release",loader:()=>import("./handler38.js"),name:"snapshot",options:[{description:"Override dist-tag (default: pr-<PR_NUMBER>)",name:"tag",type:String},{description:"PR-close cleanup mode — enumerate the closed PR's commit SHAs and remove their snapshot tags from the registry (when supported by the backend)",name:"on-close",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},lje={commandPath:["release"],description:"Preflight diagnostics for the release subsystem (workspace, PM, OIDC, NAPI, guards)",examples:[["vis release doctor","Run all checks; exit non-zero if any error"],["vis release doctor --json","Emit machine-readable report"]],group:"Release",loader:()=>import("./handler39.js"),name:"doctor",options:[{description:"Emit machine-readable JSON instead of a table",name:"json",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String},{description:"Bootstrap mode for greenfield monorepos: doctor asserts the workspace has no release tags and no package has been published yet. Pair with `vis release version --first-release`.",name:"first-release",type:Boolean}]},gje={commandPath:["release"],description:"Auto-derive a change file from branch commits (conventional-commits + path heuristics)",examples:[["vis release generate","Walk commits since the merge-base with baseBranch"],["vis release generate --from origin/main","Walk commits since the given ref"],["vis release generate --dry-run","Print the would-be content without writing"]],group:"Release",loader:()=>import("./handler65.js"),name:"generate",options:[{description:"Git ref to compare against (default: merge-base with baseBranch)",name:"from",type:String},{description:"Slug for the generated filename (default: random animal name)",name:"name",type:String},{description:"Print would-be content without writing",name:"dry-run",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},hje={commandPath:["release"],description:"Scaffold .vis/release; migrate from changesets / bumpy / semantic-release",examples:[["vis release init","Auto-detect source tool and scaffold"],["vis release init --from-semantic-release","Force semantic-release migration"],["vis release init --from-changesets","Force changesets migration"],["vis release init --fresh","Skip migration; start clean"],["vis release init --dry-run","Print what would happen without writing files"],["vis release init --from-semantic-release --apply","Actually perform the semantic-release migration writes"]],group:"Release",loader:()=>import("./handler40.js"),name:"init",options:[{description:"Force migration from semantic-release / multi-semantic-release",name:"from-semantic-release",type:Boolean},{description:"Force migration from changesets",name:"from-changesets",type:Boolean},{description:"Force migration from bumpy",name:"from-bumpy",type:Boolean},{description:"Skip migration; start clean",name:"fresh",type:Boolean},{description:"Print what would happen without writing files",name:"dry-run",type:Boolean},{alias:"y",description:"Auto-confirm prompts (CI-safe)",name:"yes",type:Boolean},{description:"Generate CI workflow files. GitHub → `.github/workflows/vis-release{,-check,-snapshot}.yml`. GitLab → `.gitlab-ci.yml`.",name:"workflows",type:Boolean},{description:"Override package manager when generating workflows (npm | pnpm | yarn | bun). Default: auto-detect",name:"package-manager",type:String},{description:"Actually perform the migration writes (not dry-run)",name:"apply",type:Boolean},{description:"Append a 'Releasing with vis' section to AGENTS.md so AI agents know how to drive the release flow",name:"agent",type:Boolean}]},cje={commandPath:["release"],description:"Print the next computed version for each package in the release plan. Read-only; no mutations.",examples:[["vis release next-version","Print `<pkg> <old> -> <new>` for every package in the plan"],["vis release next-version --package=@scope/a","Single-package mode"],["vis release next-version --json","Emit a `{ name: { from, to } }` JSON map"]],group:"Release",loader:()=>import("./handler41.js"),name:"next-version",options:[{description:"Limit output to a single package",name:"package",type:String},{description:"Emit a JSON `{ name: { from, to } }` map instead of pretty lines",name:"json",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Bootstrap mode for greenfield monorepos: preview the plan without registry / tag lookups (matches `vis release version --first-release`).",name:"first-release",type:Boolean}]},pje={commandPath:["release"],description:"Dry-run the configured notification channels (slack / discord / webhook / plugins) with a synthetic release",examples:[["vis release notifications test","Dispatch a fake release to every configured channel"],["vis release notifications test --channel=slack","Dispatch to every Slack channel only"],["vis release notifications test --channel=slack:eng","Dispatch to the slack channel with id=eng only"],["vis release notifications test --custom-context=./fake.json","Use operator-supplied JSON instead of the built-in synthetic release"],["vis release notifications test --json","Emit machine-readable results"]],group:"Release",loader:()=>import("./handler42.js"),name:"notifications",options:[{defaultOption:!0,defaultValue:"test",description:"Subcommand: test",name:"action",type:String},{description:"Restrict dispatch to a single channel kind (`slack`, `discord`, `webhook`) or an id'd channel (`slack:eng`)",name:"channel",type:String},{description:"Path to a JSON file containing a NotificationContext to use instead of the synthetic default",name:"custom-context",type:String},{description:"Emit machine-readable JSON instead of a per-channel report",name:"json",type:Boolean}]},vje={commandPath:["release"],description:"Inspect the release plan; with --interactive, walk through and override bump levels",examples:[["vis release plan","Emit pending plan as JSON"],["vis release plan --interactive","Walk through pending releases, accept or override each bump"],["vis release plan -i --write","Walk through interactively and write the chosen overrides to a change file"]],group:"Release",loader:()=>import("./handler43.js"),name:"plan",options:[{description:"Filter packages by name glob",name:"filter",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{alias:"i",description:"Walk through pending releases interactively and accept / override each bump level",name:"interactive",type:Boolean},{description:"When used with --interactive, write the chosen overrides to a new change file (.vis/release/<id>.md)",name:"write",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},yje={commandPath:["release"],description:"Enter / exit pre-release mode (changesets-compatible — every `version` produces a prerelease until exit)",examples:[["vis release pre enter alpha","Enter pre-mode with the `alpha` tag"],["vis release pre enter rc --no-commit","Enter pre-mode locally without committing pre.json"],["vis release pre exit","Flag the next `version` to consolidate + exit pre-mode"],["vis release pre status","Print whether pre-mode is active, exit-pending, or off"]],group:"Release",loader:()=>import("./handler45.js"),name:"pre",options:[{defaultOption:!0,defaultValue:"status",description:"Subcommand: enter | exit | status",name:"action",type:String},{description:"Prerelease tag (e.g. alpha, beta, rc). Required for `enter`",multiple:!0,name:"tag",type:String},{defaultValue:!0,description:"Commit pre.json after writing. Default: commit",name:"commit",type:Boolean},{defaultValue:!0,description:"Push the commit. Default: push",name:"push",type:Boolean}]},fje={commandPath:["release"],description:"Publish non-functional placeholder packages so npm Trusted Publishing (OIDC) can be configured before the first release",examples:[["vis release pretrust","Publish a placeholder for every managed package missing from the registry"],["vis release pretrust --filter '@scope/*'","Limit to a glob"],["vis release pretrust --dry-run","Print what would be published without uploading"]],group:"Release",loader:()=>import("./handler57.js"),name:"pretrust",options:[{description:"Glob filter (CSV) — limit to specific packages",name:"filter",type:String},{description:"dist-tag for the placeholder (default: placeholder — keeps `latest` unset)",name:"tag",type:String},{description:"Placeholder version (default: 0.0.0)",name:"version",type:String},{description:"Publish access: public | restricted (default: public)",name:"access",type:String},{description:"Override registry URL",name:"registry",type:String},{description:"Publish a placeholder even if the package already exists on the registry",name:"force",type:Boolean},{description:"Skip the `npm trust` step (only publish placeholders)",name:"no-trust",type:Boolean},{description:"Trust claim: forge provider (github | gitlab). Default: auto-detect from the git remote",name:"provider",type:String},{description:"Trust claim: owner/repo (github) or group/project (gitlab). Default: detect from git remote",name:"repo",type:String},{description:"Trust claim: workflow/pipeline filename (npm trust --file). Default: auto-detect the release workflow",name:"workflow",type:String},{description:"Trust claim: restrict to a deployment environment (npm trust --env)",name:"env",type:String},{description:"Trust claim: also grant the staged-publish permission (--allow-stage-publish)",name:"allow-stage-publish",type:Boolean},{description:"Print what would publish without uploading",name:"dry-run",type:Boolean},{description:"Print the resolved release config and exit",name:"print-config",type:String}]},mje={commandPath:["release"],description:"Pack-then-publish unpublished packages, push tags, create GH releases",examples:[["vis release publish","Publish all pending packages"],["vis release publish --dry-run","Print what would publish without uploading"],["vis release publish --tag alpha","Override dist-tag"],["vis release publish --filter '@scope/*'","Limit to packages matching the glob"]],group:"Release",loader:()=>import("./handler46.js"),name:"publish",options:[{description:"Skip uploads — print what would happen",name:"dry-run",type:Boolean},{description:"Override npm dist-tag",name:"tag",type:String},{description:"Limit to packages matching this glob (CSV)",name:"filter",type:String},{description:"Skip `git push --tags` after publish (lands in M5)",name:"no-push",type:Boolean},{description:"2FA OTP token",name:"otp",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Resume from a previous run's state file (skips already-published packages)",name:"resume",type:Boolean},{description:"Run preflight checks (config + workspace + plan + auth) and exit. No mutations.",name:"check-only",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String},{description:"Bootstrap mode for greenfield monorepos: force currentVersionResolver=disk and skip remote tag-collision checks. Use on the very first release before any git tags exist.",name:"first-release",type:Boolean}]},bje={commandPath:["release"],description:"Publish 0.0.0-<tag>-<sha> snapshot versions of affected packages",examples:[["vis release snapshot --tag pr-1234","Publish snapshots tagged with the PR number"],["vis release snapshot --tag canary --filter '@scope/*'","Limit to a glob"],["vis release snapshot --tag pr-1234 --dry-run","Preview without uploading"]],group:"Release",loader:()=>import("./handler47.js"),name:"snapshot",options:[{description:"Required: dist-tag for the snapshot release",name:"tag",type:String},{description:"Override registry URL (defaults to pkg-pr-new backend or `release.snapshot.registry`)",name:"registry",type:String},{description:"Glob filter (CSV) — limit snapshots to specific packages",name:"filter",type:String},{description:"Print what would publish without uploading",name:"dry-run",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},wje={commandPath:["release"],description:"List, approve, or reject npm staged-publish records (RFC §13.6 — approve/reject need 2FA)",examples:[["vis release stage list","List every staged version (both npm + the local .vis/release/staged.json registry)"],["vis release stage list @scope/pkg","List staged versions for a single package"],["vis release stage list --json","Emit a machine-readable view of both sources"],["vis release stage approve <stage-id>","Promote a staged version, drain it from staged.json, commit + push the registry"],["vis release stage approve --all","Approve every pending stage tracked in .vis/release/staged.json"],["vis release stage reject <stage-id>","Reject a staged version (permanent — cannot be re-approved unless re-staged)"],["vis release stage approve <stage-id> --no-push","Approve, update the registry, commit locally (skip the push)"],["vis release stage approve <stage-id> --no-commit","Approve and update the registry only — no git commit"]],group:"Release",loader:()=>import("./handler48.js"),name:"stage",options:[{defaultOption:!0,defaultValue:"list",description:"Subcommand: list | approve | reject",name:"action",type:String},{description:"Stage IDs (positional args after the action)",multiple:!0,name:"stage-ids",type:String},{description:"Approve every pending stage tracked in .vis/release/staged.json",name:"all",type:Boolean},{description:"Package name filter for `list`",name:"filter",type:String},{description:"Emit machine-readable JSON",name:"json",type:Boolean},{defaultValue:!0,description:"Update .vis/release/staged.json but skip the auto-commit. Default: commit",name:"commit",type:Boolean},{defaultValue:!0,description:"Skip pushing the registry commit to the remote. Default: push",name:"push",type:Boolean}]},jje={commandPath:["release"],description:"Print pending release plan (which packages will bump and to what version)",examples:[["vis release status","Print pending plan in human-readable format"],["vis release status --json","Emit the plan as JSON for scripting / CI"],["vis release status --bump major,minor","Filter to packages getting major or minor bumps"],["vis release status --filter '@scope/*'","Show only packages matching the glob"]],group:"Release",loader:()=>import("./handler44.js"),name:"status",options:[{description:"Emit machine-readable JSON instead of a table",name:"json",type:Boolean},{description:"Filter packages by name glob",name:"filter",type:String},{description:"Filter by bump level (CSV: major,minor,patch)",name:"bump",type:String},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String}]},kje={commandPath:["release"],description:"Apply pending change files to disk: bump versions + write CHANGELOG entries",examples:[["vis release version","Apply the plan to disk"],["vis release version --dry-run","Print what would change without touching disk"],["vis release version --channel alpha","Force a specific channel (overrides branch detection)"]],group:"Release",loader:()=>import("./handler49.js"),name:"version",options:[{description:"Skip writes — print the diff and exit",name:"dry-run",type:Boolean},{description:"Override channel (defaults to current branch lookup)",name:"channel",type:String},{description:"Limit to packages matching this glob (CSV)",name:"filter",type:String},{description:"Auto-commit after applying",name:"commit",type:Boolean},{description:"Run preflight checks (config + workspace + plan) and exit. No mutations.",name:"check-only",type:Boolean},{description:"Print the resolved release config and exit (--print-config=debug for runtime-resolved fields)",name:"print-config",type:String},{description:"Bootstrap mode for greenfield monorepos: force currentVersionResolver=disk and skip remote tag-collision checks. Use on the very first release before any git tags exist.",name:"first-release",type:Boolean}]},Sje=[ije,gje,jje,vje,nje,oje,lje,cje,kje,mje,bje,wje,yje,fje,hje,pje,aje,tje,rje,sje,dje,uje],Lje={alias:["rm","un","uninstall"],argument:{description:"Packages to remove",name:"packages",type:String},description:"Remove packages using the detected package manager",examples:[["vis remove lodash","Remove a package"],["vis rm old-package","Remove using alias"],["vis remove --filter app react","Remove from specific workspace"],["vis remove -g typescript","Remove global package"]],group:"Dependencies",loader:()=>import("./handler18.js"),name:"remove",options:[{alias:"D",defaultValue:!1,description:"Remove from devDependencies",name:"save-dev",type:Boolean},{alias:"g",defaultValue:!1,description:"Remove global package",name:"global",type:Boolean},{alias:"r",defaultValue:!1,description:"Remove from all workspace packages",name:"recursive",type:Boolean},{alias:"w",defaultValue:!1,description:"Remove from workspace root",name:"workspace-root",type:Boolean},{alias:"F",description:"Filter by workspace package name",multiple:!0,name:"filter",type:String}]},Cje={description:"Replay a previous task run from .vis/runs/ — show task results without re-executing",examples:[["vis replay","Show the most recent run summary"],["vis replay --run 2026-04-28T12-34-56_ab12","Inspect a specific historical run"],["vis replay --list","List every recorded run, newest first"],["vis replay --task @myorg/app:build","Focus on one task within the loaded run"],["vis replay --failed","Filter to only failed tasks"],["vis replay --format=json","Machine-readable output for CI"]],group:"Workspace",loader:le(()=>import("./handler19.js"),"replayExecute"),name:"replay",options:[{description:"Run id to replay (defaults to the most recent run)",name:"run",type:String},{defaultValue:!1,description:"List every available run instead of replaying one",name:"list",type:Boolean},{description:"Filter the replay to a single task id (e.g. @my/app:build)",name:"task",type:String},{defaultValue:!1,description:"Filter the replay to failed tasks only",name:"failed",type:Boolean},{description:"Output format: table or json (default: table)",name:"format",type:String}]},Yje={argument:{description:"The target to run (e.g., build, test, lint)",name:"target",type:String},description:"Run a target across workspace projects",examples:[["vis run","List all available targets"],["vis run build","Run build on all projects"],["vis run :build","Run build on all projects (moon-style)"],["vis run ~:test","Run test on the project closest to the current directory"],['vis run "#frontend:build"',"Run build on projects tagged 'frontend'"],['vis run :build --query "language=typescript"',"Filter by project metadata"],['vis run build --filter "@org/web"',"Run build on a single package (pnpm filter)"],['vis run build --filter "...@org/web"',"Run build on @org/web and everything that depends on it"],['vis run build -F "@org/web..."',"Run build on @org/web and its dependencies"],['vis run build -F "...[origin/main]"',"Run build on packages changed since origin/main + their dependents"],['vis run build -F "./packages/*"',"Run build on packages matched by a path glob"],["vis run test --affected","Run test only on git-changed projects"],["vis run build --fail-fast","Stop on first failure"],["vis run build --dry-run","Show execution plan without running"],["vis run destroy --reverse","Run leaves-first (teardown order, e.g. CDK/Pulumi destroy)"]],group:"Run & Execute",loader:()=>import("./handler77.js"),name:"run",options:[{alias:"p",description:"Comma-separated list of projects to run",name:"projects",type:String},{alias:"F",description:"pnpm-style package selector (repeatable). Supports name globs (@org/*), graph modifiers (...pkg dependents, pkg... dependencies, ...^pkg / pkg^... exclude self), changed-since ([main], ...[origin/main]), and path globs (./packages/*, {glob}).",multiple:!0,name:"filter",type:String},{defaultValue:!1,description:"Skip the toolchain pre-flight (no auto-install for any pinned tool: node / pnpm / yarn / npm / bun / deno / go / python / ruby / rust)",name:"skip-toolchain",type:Boolean},{description:"Detect lockfile/node_modules drift before running (warns in TTY, fails in CI). Use --no-preflight to disable.",name:"preflight",type:Boolean},{defaultValue:3,description:"Maximum number of parallel tasks (falls back to VIS_RUN_CONCURRENCY_LIMIT env var, then 3)",name:"parallel",type:Number},{defaultValue:!0,description:"Enable caching (use --no-cache to disable)",name:"cache",type:Boolean},{description:"Comma-separated selectors of tasks to bypass cache for (e.g. 'app:test', ':e2e', '#flaky:lint'). Other tasks in the run still cache normally. --no-cache wins when both are set.",name:"skip-cache",type:String},{description:"Custom cache directory",name:"cache-dir",type:String},{description:"Remote cache mode: read | write | readwrite (defaults to readwrite when remoteCache is configured)",name:"cache-mode",type:String},{description:"Remote cache wire backend: http (Turborepo-compatible) or reapi (Bazel Remote Execution API gRPC)",name:"cache-backend",type:String},{description:"Override how the requested target is hashed for this run: declared (hash listed inputs) or trace (hash the files the task actually reads). Overrides per-target hashMode config for the directly-run target.",name:"hash-mode",type:String},{defaultValue:!1,description:"Show what would run without executing",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Generate a run summary after execution",name:"summarize",type:Boolean},{description:'Partition tasks for distributed CI (e.g., "1/4" for first of four runners). Falls back to VIS_PARTITION env var.',name:"partition",type:String},{defaultValue:!1,description:"Skip project constraint validation",name:"skip-constraints",type:Boolean},{description:"Filter matched projects by a query (e.g. 'language=typescript && tag=lib')",name:"query",type:String},{defaultValue:!1,description:"Only run on projects affected by git changes (shorthand for vis affected)",name:"affected",type:Boolean},{defaultValue:!1,description:"Rerun affected tasks on file change. Ctrl+C to exit.",name:"watch",type:Boolean},{defaultValue:!1,description:"Stop all tasks on first failure",name:"fail-fast",type:Boolean},{defaultValue:!1,description:"Run the dependency graph in reverse (leaves first, then their dependents). Useful for teardown targets like `destroy`/`undeploy` where dependents must run before the things they depend on.",name:"reverse",type:Boolean},{description:"Output mode: interleaved (pass-through), labeled (prefix each line with [pkg#task]), or grouped (vite-task-style block)",name:"log",type:String},{description:"Output style: normal (print every task) or quiet (skip output for successful/cached tasks; failed tasks still print in CI mode, and remain in TUI scrollback in interactive mode). Defaults to normal; set run.quietOnSuccess in config to make quiet the default. Per-target options.outputStyle overrides this.",name:"output-style",type:String},{defaultValue:!1,description:"Run every task through a pseudo-terminal so color-aware tools render as if attached to a TTY (disables caching)",name:"pty",type:Boolean},{description:"Global retry budget: cap on total task retries across the run (per-target retryCount is still honored up to the budget)",name:"retry-budget",type:Number},{description:"Write a Chrome Tracing JSON profile of the run to this path (open in chrome://tracing or Perfetto)",name:"profile",type:String},{defaultValue:!1,description:"Render the most-recent run's saved summary (from .vis/last-summary.json) and exit without executing any tasks",name:"last-details",type:Boolean},{defaultValue:!0,description:"Show flaky task report on failure (use --no-flaky to suppress)",name:"flaky",type:Boolean},{defaultValue:!1,description:"Treat any task that needed at least one retry as a run failure (exit non-zero), even when retries eventually succeeded. Use in CI to surface flakes that retries would otherwise mask.",name:"fail-on-retry",type:Boolean},{description:"Fail a task if its command references an env var that is unset (no silent empty-string substitution). Use --no-strict-env to disable when set in config.",name:"strict-env",type:Boolean},{description:"Comma-separated tags this runner advertises (e.g. 'gpu,slow'). Tasks declaring `options.runnerTags` only run when at least one tag overlaps. Untagged tasks always run. Falls back to VIS_RUNNER_TAGS env var.",name:"runner-tags",type:String},{description:"Auto-start service deps. One of: auto | ephemeral | persistent | off. Defaults to `auto` in TTY, `off` in CI.",name:"services",type:String},{defaultValue:!1,description:"Stop services this run auto-started in registry mode when the run exits (clean, q, or Ctrl+C). Ephemeral services already die with the run.",name:"stop-services",type:Boolean}]},$je={description:"Generate a CycloneDX 1.7 Software Bill of Materials for the workspace",examples:[["vis sbom","Write the full-workspace SBOM to sbom.cdx.json"],["vis sbom --focus=my-app","Scope the SBOM to my-app's transitive closure"],["vis sbom --focus=my-app,other","Focus multiple projects"],["vis sbom --format=xml --output=sbom.cdx.xml","Emit XML instead of JSON"],["vis sbom --include-dev","Include devDependencies (default: production only)"],["vis sbom --output=-","Write to stdout"]],group:"Security & Health",loader:()=>import("./handler20.js"),name:"sbom",options:[{description:"Project name(s) to focus on — comma-separated for multiple",name:"focus",type:String},{defaultValue:"json",description:"Output format: json (default) or xml",name:"format",type:String},{description:"Output path (use '-' for stdout; default: sbom.cdx.json)",name:"output",type:String},{defaultValue:!1,description:"Include devDependencies (default: production only)",name:"include-dev",type:Boolean}]},Zje={argument:{description:"One or more paths to scan (defaults to workspace root)",name:"paths",type:String},description:"Scan a repository for hardcoded secrets and credentials",examples:[["vis secrets","Scan the workspace with grouped, colourised output"],["vis secrets --staged","Scan only files staged for the current commit (pre-commit hooks)"],["vis secrets --since main","Scan only files changed since the `main` branch"],["vis secrets --affected","Scan only projects affected by the current branch"],["vis secrets --history","Scan the full git history for secrets that were committed then removed"],["vis secrets --history --history-range main..HEAD","Scan only commits on the current branch since main"],["vis secrets --history --max-commits 100 --redact","Scan the last 100 commits, masking any secret values"],["vis secrets --init","Write an initial baseline from current findings"],["vis secrets --list-rules","Print all bundled detection rules"],["vis secrets --list-validators","Print non-HTTP validator types in the ruleset + install hints for each"],["vis secrets --exclude-rule generic-api-key --exclude-rule aws-access-token","Drop noisy rules"],["vis secrets --include-rule stripe-access-token","Check a single rule"],["vis secrets --enable-rule tag:preset:weak-passwords","Enable an opt-in rule group additively (defaults still fire)"],["vis secrets --include-rule tag:preset:password-manager","Restrict output to one opt-in group only"],["vis secrets --min-confidence high","Drop rules without a high confidence label (CI-friendly precision filter)"],["vis secrets --validate --only-verified","Live-verify each finding against its provider (one HTTP call per finding)"],["vis secrets --exclude 'dist/**' --exclude-from .secretsignore","Extra gitignore-syntax exclusions for the walker"],["vis secrets --config ./leaks.json --no-extend-bundled","Use only the supplied config, skip the bundled ruleset"],["vis secrets --concurrency 4","Cap the rayon thread pool (0 / omit = auto)"],["vis secrets --baseline .secrets-baseline.json","Suppress known findings; print diff vs. baseline"],["vis secrets --update-baseline","Merge current findings into the baseline (use --replace-baseline to overwrite)"],["vis secrets --format sarif > report.sarif","SARIF output for GitHub code-scanning"]],group:"Security",loader:()=>import("./handler78.js"),name:"secrets",options:[{description:"Path to a JSON config (gitleaks-compatible shape). Defaults to the bundled ruleset.",name:"config",type:String},{description:"Drop rules below this author-declared confidence: low (default), medium, high. Rules without a declared confidence (every gitleaks rule) are treated as low, so --min-confidence medium or higher drops them along with explicit low-confidence rules.",name:"min-confidence",type:String},{defaultValue:!1,description:"Live-verify each finding against its provider (one HTTP call per finding, max 8 concurrent). Only supports Kingfisher-style HTTP validators with StatusMatch / WordMatch response matchers; other types (gRPC, multi-step, checksum) mark the finding as validation=skipped. WARNING: sends candidate secrets to the provider — some providers alert their security team on failed auth attempts.",name:"validate",type:Boolean},{defaultValue:!1,description:"With --validate, drop every finding whose validation is not 'verified'. Useful for CI gating.",name:"only-verified",type:Boolean},{defaultValue:!1,description:"With --config, do not merge on top of the bundled ruleset — replace it.",name:"no-extend-bundled",type:Boolean},{defaultValue:"text",description:"Output format: text (default), json, sarif",name:"format",type:String},{description:"Path to a baseline JSON of previously-triaged findings",name:"baseline",type:String},{defaultValue:!1,description:"Scan only files staged for commit",name:"staged",type:Boolean},{description:"Scan only files changed since <ref> (e.g. main, origin/HEAD)",name:"since",type:String},{defaultValue:!1,description:"Scan only projects affected by the current branch",name:"affected",type:Boolean},{defaultValue:!1,description:"Scan the entire git history (every added/modified blob across commits) instead of the working tree. Surfaces secrets that were committed and later removed. Cannot be combined with --staged/--since/--affected.",name:"history",type:Boolean},{description:"With --history, limit the walk to a rev-list range (e.g. main..HEAD, HEAD~50..HEAD, or a single ref). Defaults to all reachable history of HEAD.",name:"history-range",type:String},{description:"With --history, cap the number of commits walked (most-recent first)",name:"max-commits",type:Number},{description:"Enable an opt-in rule or tag without restricting output — additive (e.g. tag:preset:weak-passwords, tag:preset:password-manager). Repeatable.",multiple:!0,name:"enable-rule",type:String},{description:"Rule id or tag:<name> selector — whitelist, only matching findings are emitted. Implies enablement. Repeatable.",multiple:!0,name:"include-rule",type:String},{description:"Rule id or tag:<name> selector — drop matching findings. Repeatable.",multiple:!0,name:"exclude-rule",type:String},{description:"Gitignore-syntax pattern to exclude from the walk (repeatable)",multiple:!0,name:"exclude",type:String},{description:"Path to a gitignore-shaped file the walker should honor (repeatable)",multiple:!0,name:"exclude-from",type:String},{defaultValue:!1,description:"Mask secret values in output",name:"redact",type:Boolean},{defaultValue:!1,description:"Scan dotfiles",name:"include-hidden",type:Boolean},{defaultValue:!1,description:"Do not respect .gitignore",name:"no-gitignore",type:Boolean},{description:"Skip files larger than this (bytes). Default: 10 MiB",name:"max-size",type:Number},{description:"Rayon worker threads (0 / omit = auto)",name:"concurrency",type:Number},{defaultValue:!1,description:"Merge current findings into the baseline and exit 0",name:"update-baseline",type:Boolean},{defaultValue:!1,description:"With --update-baseline, replace rather than merge",name:"replace-baseline",type:Boolean},{defaultValue:!1,description:"Scaffold a baseline from current findings",name:"init",type:Boolean},{defaultValue:!1,description:"With --init, preview the baseline without writing files",name:"dry-run",type:Boolean},{defaultValue:!1,description:"Print all bundled detection rules and exit",name:"list-rules",type:Boolean},{defaultValue:!1,description:"Print non-HTTP validator types referenced by the current ruleset, with install hints for their optional peer dependencies.",name:"list-validators",type:Boolean},{defaultValue:!1,description:"Suppress all progress output (only emit findings)",name:"quiet",type:Boolean},{defaultValue:!1,description:"Print diagnostic info (skipped rules, etc.)",name:"verbose",type:Boolean}]},Jje={commandPath:["security"],description:"List build-script status — allowed, unapproved, and stale allowlist entries",examples:[["vis security list","Show the full build-script triage report"],["vis security list --json","Emit the report as JSON for tooling"]],group:"Security & Health",loader:()=>import("./list.js"),name:"list",options:[{defaultValue:!1,description:"Emit the report as JSON instead of human-readable text",name:"json",type:Boolean}]},xje={commandPath:["security"],description:"Push vis.config security settings to the package manager's native config",examples:[["vis security sync","Sync allowBuilds + minimumReleaseAge to the PM-native config files"],["vis security sync --skip-allow-builds","Sync only the minimumReleaseAge knobs"],["vis security sync --skip-min-release-age","Sync only allowBuilds (trustedDependencies / onlyBuiltDependencies)"]],group:"Security & Health",loader:()=>import("./sync2.js"),name:"sync",options:[{defaultValue:!1,description:"Skip syncing allowBuilds (trustedDependencies, onlyBuiltDependencies)",name:"skip-allow-builds",type:Boolean},{defaultValue:!1,description:"Skip syncing minimumReleaseAge and its excludes",name:"skip-min-release-age",type:Boolean}]},Tje={commandPath:["security"],description:"Run lifecycle scripts for packages in security.policies.installScripts.allow (LavaMoat 'run' parity)",examples:[["vis security run","Run preinstall/install/postinstall for every approved package"],["vis security run --with-root","Also run the workspace root's prepublish + prepare hooks"],["vis security run --root-only","Run only the workspace root's prepublish + prepare hooks"]],group:"Security & Health",loader:()=>import("./run.js"),name:"run",options:[{defaultValue:!1,description:"Also run the workspace root's prepublish + prepare hooks after dependencies",name:"with-root",type:Boolean},{defaultValue:!1,description:"Skip dependency scripts and only run the workspace root's prepublish + prepare hooks",name:"root-only",type:Boolean}]},Dje={commandPath:["security"],description:"Install @lavamoat/preinstall-always-fail as a devDep so a missing ignore-scripts setting fails loudly",examples:[["vis security tripwire","Install the tripwire devDependency"],["vis security tripwire --status","Report whether the tripwire is installed"],["vis security tripwire --remove","Remove the tripwire from package.json"]],group:"Security & Health",loader:()=>import("./tripwire.js"),name:"tripwire",options:[{defaultValue:!1,description:"Report whether @lavamoat/preinstall-always-fail is installed",name:"status",type:Boolean},{defaultValue:!1,description:"Remove @lavamoat/preinstall-always-fail from package.json",name:"remove",type:Boolean}]},Bje={commandPath:["security"],description:"Force-refresh the cached npm signing keys used by the signatures marshall",examples:[["vis security keys-refresh","Drop the disk cache and fetch a fresh key set from registry.npmjs.org"],["vis security keys-refresh --clear","Only drop the cache, do not refetch"],["vis security keys-refresh --json","Emit the refresh result as JSON for tooling"]],group:"Security & Health",loader:()=>import("./keys-refresh.js"),name:"keys-refresh",options:[{defaultValue:!1,description:"Only clear the cache, do not refetch",name:"clear",type:Boolean},{defaultValue:!1,description:"Emit the result as JSON instead of human-readable text",name:"json",type:Boolean}]},Xje={commandPath:["security"],description:"Verify the entire lockfile closure against supply-chain policies (firstSeen, publisherChange, blockExoticSubdeps)",examples:[["vis security verify-lockfile","Re-validate every locked entry; exit non-zero on a policy violation"],["vis security verify-lockfile --offline","Verify without network (skips firstSeen / publisherChange)"],["vis security verify-lockfile --json","Emit the verification result as JSON for CI"]],group:"Security & Health",loader:()=>import("./verify-lockfile.js"),name:"verify-lockfile",options:[{defaultValue:!1,description:"Emit the result as JSON instead of human-readable text",name:"json",type:Boolean},{defaultValue:!1,description:"Skip network-bound policies (firstSeen, publisherChange)",name:"offline",type:Boolean}]},Hje=[Jje,xje,Tje,Dje,Bje,Xje],td={description:"Target id, e.g. @my/api:db",name:"targetId",type:String},Mje={description:"Output format: table or json (default: table)",name:"format",type:String},Pje={argument:td,commandPath:["service"],description:"Start a service target detached so it survives across `vis run` invocations",examples:[["vis service start @my/api:db","Boot the db target as a long-lived service"],["vis service start @my/api:db --timeout=60000","Override readiness timeout"],["vis service start @my/api:db --no-readiness","Skip the readiness probe"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceStartExecute"),name:"start",options:[{description:"Readiness probe timeout in milliseconds",name:"timeout",type:Number},{defaultValue:!1,description:"Skip the readiness probe",name:"no-readiness",type:Boolean}]},Nje={argument:{description:"Target id to stop, or omit when using --all",name:"targetId",required:!1,type:String},commandPath:["service"],description:"Stop a running service",examples:[["vis service stop @my/api:db","Stop the db service"],["vis service stop --all","Stop every running service in this workspace"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceStopExecute"),name:"stop",options:[{defaultValue:!1,description:"Stop every service registered for this workspace",name:"all",type:Boolean},{description:"Override the SIGTERM→SIGKILL grace period in milliseconds",name:"grace-ms",type:Number}]},Eje={commandPath:["service"],description:"List services registered for this workspace",examples:[["vis service list","Print running services"],["vis service list --format=json","Machine-readable list"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceListExecute"),name:"list",options:[Mje]},Rje={argument:td,commandPath:["service"],description:"Re-run the readiness probe and report a service's health",examples:[["vis service status @my/api:db","Check whether the db service is reachable"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceStatusExecute"),name:"status",options:[{description:"Probe timeout in milliseconds",name:"timeout",type:Number}]},Oje={argument:td,commandPath:["service"],description:"Stop and re-start a running service",examples:[["vis service restart @my/api:db","Recycle the db service"],["vis service restart @my/api:db --no-readiness","Recycle and skip the readiness probe"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceRestartExecute"),name:"restart",options:[{description:"Readiness probe timeout in milliseconds",name:"timeout",type:Number},{description:"Override the SIGTERM→SIGKILL grace period in milliseconds",name:"grace-ms",type:Number},{defaultValue:!1,description:"Skip the readiness probe after restart",name:"no-readiness",type:Boolean}]},Aje={argument:td,commandPath:["service"],description:"Print or tail a service's captured stdout/stderr",examples:[["vis service logs @my/api:db","Print the captured log"],["vis service logs @my/api:db -f","Tail the log (Ctrl-C to exit)"]],group:"Workspace",loader:le(()=>import("./handler21.js"),"serviceLogsExecute"),name:"logs",options:[{alias:"f",defaultValue:!1,description:"Follow the log file (like `tail -f`)",name:"follow",type:Boolean}]},Gje=[Pje,Nje,Eje,Rje,Oje,Aje],Fje={commandPath:["shim"],description:"Install project-local PM shims (.vis/shims) that enforce the project's package manager",examples:[["vis shim install","Write npm/pnpm/yarn/… wrapper scripts in .vis/shims"]],group:"Runtime",loader:()=>import("./handler22.js").then(e=>({default:e.shimInstallExecute})),name:"install"},Qje={commandPath:["shim"],description:"Remove the project-local PM shim dir (.vis/shims)",examples:[["vis shim uninstall","Delete .vis/shims"]],group:"Runtime",loader:()=>import("./handler22.js").then(e=>({default:e.shimUninstallExecute})),name:"uninstall"},Wje={commandPath:["shim"],description:"Report whether the PM shims are installed and active on PATH",examples:[["vis shim status","Show shim install + PATH state"]],group:"Runtime",loader:()=>import("./handler22.js").then(e=>({default:e.shimStatusExecute})),name:"status"},Ije=[Fje,Qje,Wje],_je={description:"Sort package.json files across the workspace using the sort-package-json Rust crate",examples:[["vis sort-package-json","Sort all package.json files in the workspace"],["vis sort-package-json --check","Check if files are already sorted (exit 1 if not)"],["vis sort-package-json --sort-scripts","Also sort the scripts field alphabetically"],["vis sort-package-json --indent 4","Force 4-space indentation (overrides per-file detection)"],["vis sort-package-json --indent tab","Force tab indentation"],["vis sort-package-json --ignore '**/fixtures/**'","Skip files matching one or more glob patterns"],["vis sort-package-json --sort-order name,version,license","Pin a custom prefix order before the default field order"],["vis sort-package-json --unsorted dependencies,devDependencies","Preserve original key order for the listed top-level sections"],["vis sort-package-json --no-final-newline","Do not append a trailing newline"],["vis sort-package-json --line-ending crlf","Force CRLF line endings (default: auto-detect per file)"]],group:"Workspace",loader:()=>import("./handler64.js"),name:"sort-package-json",options:[{alias:"c",defaultValue:!1,description:"Check if package.json files are sorted without writing (exits 1 if unsorted)",name:"check",type:Boolean},{defaultValue:!1,description:"Also sort the scripts field alphabetically",name:"sort-scripts",type:Boolean},{description:"Indent override: a number of spaces, the literal `tab`, or a literal whitespace string. When unset, the original file's indent is preserved.",name:"indent",type:String},{description:"Glob pattern of files to skip (basename match, or path-relative when the pattern contains `/`). Repeatable.",multiple:!0,name:"ignore",type:String},{description:"Comma-separated list of top-level keys to place first, before the default field order. Repeatable.",multiple:!0,name:"sort-order",type:String},{description:"Comma-separated list of top-level sections whose key order should be preserved (e.g. dependencies,devDependencies). Repeatable.",multiple:!0,name:"unsorted",type:String},{defaultValue:!1,description:"Do not append a trailing newline to the output (default: append one).",name:"no-final-newline",type:Boolean},{defaultValue:"auto",description:"Line ending to write: auto (per-file detection, default), lf, or crlf.",name:"line-ending",type:String},{description:"Disable collapsing `bugs: { url }` to the bare string form (default: enabled).",name:"no-format-bugs",type:Boolean},{description:"Disable collapsing `repository: { type, url }` to the GitHub `owner/repo` shorthand (default: enabled).",name:"no-format-repository",type:Boolean},{description:"Disable canonical sorting of `exports` condition keys (default: enabled).",name:"no-sort-exports",type:Boolean},{description:"Disable .editorconfig discovery for indent / line-ending defaults (default: enabled).",name:"no-editorconfig",type:Boolean}]},zje={argument:{description:"Project name or workspace-relative path of the package to extract",name:"package",type:String},description:"Extract a package into a standalone git repo, preserving its history",examples:[["vis split @scope/pkg --output ../pkg-repo","Extract a package into a new repo at ../pkg-repo"],["vis split packages/tooling/foo -o ../foo --remote git@github.com:me/foo.git --push","Extract, set origin, and push"],["vis split @scope/pkg -o ../pkg --remove","Extract, then delete the package from the monorepo (committed)"],["vis split @scope/pkg --dry-run","Print the git plan without making changes"]],group:"Workspace",loader:()=>import("./handler23.js"),name:"split",options:[{alias:"o",description:"Destination directory for the new repo (required unless --dry-run)",name:"output",type:String},{alias:"b",description:'Default branch name in the new repo (default: vis.config defaultBase or "main")',name:"branch",type:String},{description:"Git remote URL to set as origin on the new repo",name:"remote",type:String},{defaultValue:!1,description:"Push the new repo to origin (requires --remote)",name:"push",type:Boolean},{defaultValue:!1,description:"Delete the package from the monorepo after extracting and commit the removal",name:"remove",type:Boolean},{defaultValue:!1,description:"Prefix the rewritten commit messages with the package name",name:"annotate",type:Boolean},{defaultValue:!1,description:"Use a non-empty --output directory anyway",name:"force",type:Boolean},{defaultValue:!1,description:"Print the git plan instead of executing it",name:"dry-run",type:Boolean}]},Kje={description:"Run linters on staged files using config from vis.config.ts",examples:[["vis staged","Run staged linters"],["vis staged --verbose","Run with verbose output"],["vis staged --no-stash","Run without backup stash"],["vis staged --diff HEAD~1","Run against a specific diff"]],group:"Run & Execute",loader:()=>import("./handler75.js"),name:"staged",options:[{defaultValue:!1,description:"Allow empty commits when tasks revert all staged changes",name:"allow-empty",type:Boolean},{defaultValue:!1,description:"Automatically stage new files that tasks create during the run",name:"auto-stage",type:Boolean},{description:"Number of concurrent tasks or false for serial",name:"concurrent",type:String},{defaultValue:!1,description:"Run all tasks to completion even if one fails",name:"continue-on-error",type:Boolean},{description:"Working directory to run all tasks in",name:"cwd",type:String},{defaultValue:!1,description:"Enable debug output",name:"debug",type:Boolean},{description:"Override the default --staged flag of git diff",name:"diff",type:String},{description:"Override the default diff-filter",name:"diff-filter",type:String},{defaultValue:!1,description:"Fail with exit code 1 when tasks modify tracked files",name:"fail-on-changes",type:Boolean},{defaultValue:!1,description:"Kill in-flight tasks with SIGKILL on fast-fail instead of the default SIGTERM",name:"force-kill",type:Boolean},{defaultValue:!1,description:"Hide unstaged changes from partially staged files",name:"hide-partially-staged",type:Boolean},{defaultValue:!1,description:"Hide all unstaged changes before running tasks",name:"hide-unstaged",type:Boolean},{defaultValue:!1,description:"Suppress console output",name:"quiet",type:Boolean},{defaultValue:!1,description:"Pass filepaths relative to cwd to tasks",name:"relative",type:Boolean},{defaultValue:!1,description:"Revert to original state in case of errors",name:"revert",type:Boolean},{defaultValue:!0,description:"Enable backup stash",name:"stash",type:Boolean},{defaultValue:!1,description:"Show task output even when tasks succeed",name:"verbose",type:Boolean}]},qje={description:"Show a workspace health dashboard at a glance",examples:[["vis status","Full status overview"],["vis status --json","Machine-readable output"]],group:"Workspace",loader:()=>import("./handler24.js"),name:"status",options:[{defaultValue:!1,description:"Emit JSON output",name:"json",type:Boolean}]},Uje={argument:{description:"What to sync: codeowners | package-json-fields",name:"kind",type:String},description:"Synchronise derived workspace artefacts (codeowners, package.json fields, tsconfig refs, …)",examples:[["vis sync codeowners","Generate CODEOWNERS at the repository root"],["vis sync codeowners --out=.github/CODEOWNERS","Write to .github/CODEOWNERS instead"],["vis sync codeowners --check","Fail if the existing file is stale"],["vis sync codeowners --from=project-json,nested-codeowners","Also aggregate nested CODEOWNERS files in the tree"],["vis sync codeowners --regeneration-command='pnpm codeowners'","Set a custom header instruction"],["vis sync codeowners --preserve-block","Splice the generated block between markers in an existing CODEOWNERS"],["vis sync codeowners --write-guard","Also emit GitHub + GitLab Write Guard CI for restricted projects"],["vis sync package-json-fields","Mirror license/author/repository/bugs/homepage/engines from root to every workspace package"],["vis sync package-json-fields --check","Fail if any workspace package.json is out of sync"],["vis sync package-json-fields --fields license,engines","Override the default field list for this run"]],group:"Workspace",loader:()=>import("./handler62.js"),name:"sync",options:[{description:"Output path for the generated file (default: <workspace>/CODEOWNERS) — codeowners kind only",name:"out",type:String},{defaultValue:!1,description:"Verify state without writing (exit non-zero if drift is found)",name:"check",type:Boolean},{description:"Input sources for codeowners. Comma-separated or repeated. Values: project-json | nested-codeowners | package-json-maintainers. Defaults to project-json.",multiple:!0,name:"from",type:String},{description:"Glob (repeatable) used to discover nested CODEOWNERS files. Defaults to `**/CODEOWNERS`.",multiple:!0,name:"nested-includes",type:String},{description:"Header instruction shown to reviewers (replaces the default 'update project.json' note). Codeowners kind only.",name:"regeneration-command",type:String},{defaultValue:!1,description:"Splice the generated block between markers in the existing file instead of overwriting it. Codeowners kind only.",name:"preserve-block",type:Boolean},{defaultValue:!1,description:"Also emit a .github/workflows/write-guard.yml scoped to projects with `restricted: true` in project.json. Codeowners kind only.",name:"write-guard",type:Boolean},{description:"Comma-separated list of fields to mirror from root → workspace packages (package-json-fields kind only). Repeatable.",multiple:!0,name:"fields",type:String},{description:"Glob pattern of package names to skip (package-json-fields kind only). Repeatable.",multiple:!0,name:"ignore-package-name",type:String},{defaultValue:"human",description:"Output format for package-json-fields: human | json",name:"format",type:String},{defaultValue:!1,description:"Suppress per-package log lines; print only the summary (package-json-fields kind only)",name:"quiet",type:Boolean}]},Vje={argument:{description:"Task ID to explain (e.g. @my/app:build)",name:"taskId",type:String},description:"Explain why a task is included in the graph by walking its dependency chain to a root",examples:[["vis task-why @myorg/app:build","Show what pulls build in"],["vis task-why lib-a:test","Check the test task's triggers"]],group:"Workspace",loader:()=>import("./handler25.js"),name:"task-why"},As="Workspace",eke={commandPath:["toolchain"],description:"Show every detected manager + expected vs actual tool versions",examples:[["vis toolchain status","Show every detected manager + expected vs actual tool versions"],["vis toolchain status --json","Emit the status as JSON"],["vis toolchain status --exit-code","Exit 1 if any tool mismatches (for CI)"]],group:As,loader:le(()=>import("./handler26.js"),"statusExecute"),name:"status",options:[{defaultValue:!1,description:"Exit 1 if any tool mismatches",name:"exit-code",type:Boolean},{defaultValue:!1,description:"Emit JSON",name:"json",type:Boolean}]},ike={commandPath:["toolchain"],description:"Print the primary manager's name (for scripts)",examples:[["vis toolchain detect","Print the primary manager's name"]],group:As,loader:le(()=>import("./handler26.js"),"detectExecute"),name:"detect"},nke={commandPath:["toolchain"],description:"Install pinned versions — per-tool delegation to the right manager",examples:[["vis toolchain install","Install pinned versions"],["vis toolchain install --dry-run","Print the commands that would run, but don't execute"]],group:As,loader:le(()=>import("./handler26.js"),"installExecute"),name:"install",options:[{defaultValue:!1,description:"Print the command that would run, but don't execute",name:"dry-run",type:Boolean}]},oke={argument:{description:"Tool and version to pin, e.g. node@22.13.0 or pnpm@10.32.1",name:"spec",type:String},commandPath:["toolchain"],description:"Pin a version via the best manager for that tool",examples:[["vis toolchain use node@22.13.0","Pin node 22.13.0 via the best runtime manager"],["vis toolchain use pnpm@10.32.1","Update the packageManager field; pnpm self-activates"],["vis toolchain use node@22.13.0 --dry-run","Print the command without running it"]],group:As,loader:le(()=>import("./handler26.js"),"useExecute"),name:"use",options:[{defaultValue:!1,description:"Print the command that would run, but don't execute",name:"dry-run",type:Boolean},{defaultValue:!0,description:"Also mirror the version into engines.<tool> when that field already exists. --no-engines to skip.",name:"engines",type:Boolean}]},ake={argument:{description:"Tool to resolve, e.g. node",name:"tool",type:String},commandPath:["toolchain"],description:"Print the resolved binary path a manager would launch for a tool",examples:[["vis toolchain which node","Resolve the node binary the manager would launch"]],group:As,loader:le(()=>import("./handler26.js"),"whichExecute"),name:"which"},tke=[eke,ike,nke,oke,ake],ske={argument:{description:"Packages to unlink (omit for current package)",name:"packages",type:String},description:"Unlink a previously linked package",examples:[["vis unlink","Unlink current package"],["vis unlink react","Unlink specific package"],["vis unlink -r","Unlink in all workspace packages"]],group:"Dependencies",loader:()=>import("./handler27.js"),name:"unlink",options:[{alias:"r",defaultValue:!1,description:"Unlink in all workspace packages",name:"recursive",type:Boolean}]},rke={alias:"up",argument:{description:"Packages to update (updates all if omitted)",name:"packages",type:String},description:"Update packages to their latest versions",examples:[["vis update react","Update react within semver range"],["vis up react -L","Update react to latest"],["vis update -i","Interactive mode"],["vis update --filter app","Update in specific workspace"],["vis update -r","Update in all workspaces"],["vis update --target minor","Only apply minor/patch updates (catalog mode)"],["vis update --dry-run","Preview changes without applying"],["vis update --exclude '@types/*'","Exclude packages by pattern"],["vis update --changelog","Show changelog links after updating"],["vis update --rollback","Restore catalog from last backup"],["vis update --ai","Run AI analysis before applying updates"]],group:"Dependencies",loader:()=>import("./handler74.js"),name:"update",options:[{alias:"L",conflicts:"target",description:"Update to latest version (ignore semver range; equivalent to --target latest)",name:"latest",type:Boolean},{defaultValue:!1,description:"Ignore the minimumReleaseAge gate and select the truly latest version even if freshly published. The selected packages are added to the package manager's native age-gate exclude list (pnpm minimumReleaseAgeExclude, bun minimumReleaseAgeExcludes, yarn npmPreapprovedPackages) so the follow-up install isn't blocked; npm has no per-package exclude. Combine with --latest to also cross the semver range.",name:"ignore-release-age",type:Boolean},{alias:"t",conflicts:"latest",description:"Update target: latest, minor, or patch (default: latest, catalog mode)",name:"target",type:String},{alias:"d",defaultValue:!1,description:"Preview changes without applying",name:"dry-run",type:Boolean},{alias:"g",defaultValue:!1,description:"Update global packages",name:"global",type:Boolean},{alias:"r",defaultValue:!1,description:"Update recursively in all workspace packages",name:"recursive",type:Boolean},{description:"Filter packages in monorepo (pm-wrapper mode; catalog mode uses --include/--exclude)",name:"filter",type:String},{alias:"w",defaultValue:!1,description:"Include workspace root",name:"workspace-root",type:Boolean},{alias:"D",conflicts:"prod",description:"Update only devDependencies",name:"dev",type:Boolean},{alias:"P",conflicts:"dev",description:"Update only dependencies",name:"prod",type:Boolean},{alias:"i",defaultValue:!1,description:"Interactive mode",name:"interactive",type:Boolean},{defaultValue:!1,description:"Don't update optionalDependencies",name:"no-optional",type:Boolean},{defaultValue:!1,description:"Include peerDependencies in update checks",name:"peer",type:Boolean},{defaultValue:!1,description:"Also check workspace-owned package names against the registry (catalog mode)",name:"include-internal",type:Boolean},{alias:"l",defaultValue:!1,description:"Include packages with pinned/exact versions (no ^ or ~ prefix; catalog mode)",name:"include-locked",type:Boolean},{defaultValue:!1,description:"Update lockfile only",name:"no-save",type:Boolean},{description:"Glob pattern to include packages (repeatable, catalog mode)",lazyMultiple:!0,name:"include",type:String},{description:"Glob pattern to exclude packages (repeatable, catalog mode)",lazyMultiple:!0,name:"exclude",type:String},{defaultValue:!1,description:"Include prerelease versions (catalog mode)",name:"prerelease",type:Boolean},{description:"Check for known security vulnerabilities via OSV.dev (default: true; --no-security to skip)",name:"security",type:Boolean},{defaultValue:!1,description:"Skip catalog mode, use package manager directly",name:"no-catalog",type:Boolean},{description:"Output format: table, json, or minimal (default: table)",name:"format",type:String},{defaultValue:!1,description:"Show changelog URLs for updated packages",name:"changelog",type:Boolean},{description:"Run install after catalog update, --no-install to skip (default: true)",name:"install",type:Boolean},{defaultValue:!1,description:"Restore catalog file from the last backup",name:"rollback",type:Boolean},{defaultValue:!1,description:"Run AI analysis on outdated packages before updating (catalog mode)",name:"ai",type:Boolean},{description:"AI analysis type: impact, security, compatibility, or recommend (default: impact)",name:"ai-type",type:String},{defaultValue:!1,description:"Skip typosquat name check for package arguments",name:"no-typosquat-check",type:Boolean},{defaultValue:!1,description:"Skip the offline marshall pipeline (author, provenance, metadata, downloads, expired-domains, new-bin, signatures, archived-repo) when explicit package arguments are supplied",name:"no-marshall-check",type:Boolean},{description:"Cap concurrent registry requests during outdated checks (default: 8)",name:"max-concurrent-requests",type:Number},{description:"Release channel filter: stable (default), same (match current's prerelease channel), or any",name:"release-channel",type:String},{alias:"y",defaultValue:!1,description:"Skip the confirmation prompt for blanket --latest updates. Required in non-TTY contexts (CI) when running `vis update --latest` without explicit package arguments.",name:"yes",type:Boolean},{defaultValue:!1,description:"Skip the GitHub Actions ecosystem scan (workflows + composite action.yml files)",name:"no-actions",type:Boolean},{defaultValue:!1,description:"Skip the Docker ecosystem scan (Dockerfile + docker-compose images)",name:"no-docker",type:Boolean},{defaultValue:!1,description:"Skip the GitLab CI ecosystem scan (.gitlab-ci.yml + .gitlab/ci/**)",name:"no-gitlab",type:Boolean},{defaultValue:!1,description:"Include branch references (e.g. actions/checkout@main) when scanning workflows",name:"include-branches",type:Boolean},{description:"Reference style for GitHub Actions updates: sha (default, pin to commit SHA + version comment) or preserve",name:"style",type:String},{description:"GitHub token for actions resolution (overrides GITHUB_TOKEN / GH_TOKEN env)",name:"actions-token",type:String},{description:"GitLab token for include-ref resolution (overrides GITLAB_TOKEN / CI_JOB_TOKEN env)",name:"gitlab-token",type:String}]},uke={argument:{description:"Target version (defaults to latest)",name:"version",type:String},description:"Update vis itself to the latest version",examples:[["vis self-update","Update to latest"],["vis self-update 2.0.0","Install specific version"],["vis self-update --check","Check for updates without installing"]],group:"System",loader:()=>import("./handler28.js"),name:"self-update",options:[{defaultValue:!1,description:"Check for updates without installing",name:"check",type:Boolean},{defaultValue:!1,description:"Reinstall even if already current",name:"force",type:Boolean},{defaultValue:!1,description:"Suppress output (CI mode)",name:"silent",type:Boolean}]},dke={alias:"explain",argument:{description:"Package(s) to explain",name:"packages",type:String},description:"Show why a package is installed (dependency chain)",examples:[["vis why react","Show why react is installed"],["vis why react --json","Output as JSON"],["vis why react -r","Check across all workspaces"],["vis explain react","Alias matching npm's command"]],group:"Dependencies",loader:()=>import("./handler29.js"),name:"why",options:[{defaultValue:!1,description:"Output as JSON",name:"json",type:Boolean},{defaultValue:!1,description:"Show extended information (pnpm)",name:"long",type:Boolean},{defaultValue:!1,description:"Machine-readable output (pnpm)",name:"parseable",type:Boolean},{alias:"r",defaultValue:!1,description:"Check across all workspaces",name:"recursive",type:Boolean},{alias:"D",conflicts:"prod",description:"Filter to dev dependencies (pnpm)",name:"dev",type:Boolean},{alias:"P",conflicts:"dev",description:"Filter to production dependencies (pnpm)",name:"prod",type:Boolean},{defaultValue:!1,description:"Exclude optional dependencies (pnpm)",name:"no-optional",type:Boolean},{alias:"g",defaultValue:!1,description:"Check globally installed packages (pnpm)",name:"global",type:Boolean},{description:"Limit dependency tree depth",name:"depth",type:Number},{alias:"F",description:"Filter by workspace package name",multiple:!0,name:"filter",type:String}]},lke={argument:{description:"File to run, with any args to forward to it",name:"file",type:String},description:"Run a TypeScript/JavaScript file directly under the selected runtime (node | bun)",examples:[["vis x script.ts","Run a TypeScript file (full TS surface: enums, decorators)"],["vis x --runtime bun server.ts","Run under Bun"],["vis x build.ts foo bar","Forward positional args to the file"],["vis x task.ts -- --watch","Forward flags after -- to the file"]],group:"Run & Execute",loader:()=>import("./handler30.js"),name:"x",options:[]},gke={beforeCommand:async e=>{try{const i=e.options?.cwd,n=e.options?.config;let o;if(i)o=Ha(process.cwd(),i);else{const r=process.env.VIS_MONOREPO_ROOT;o=r&&r.length>0?r:lm(process.cwd()).path}e.workspaceRoot=o;const a=n?Ha(process.cwd(),n):void 0;let t=a??Uo(o);try{e.visConfig=await Cp(o,a?{explicitConfigPath:a}:void 0);const r=e.visConfig?.versionConstraint;if(r&&!Tl.validRange(r)){e.logger.error(""),e.logger.error(sd(pn("✖ Invalid versionConstraint"))),e.logger.error(` vis.config.ts has versionConstraint ${pn(JSON.stringify(r))}, which is not a valid semver range.`),e.logger.error(""),process.exitCode=1;return}if(r&&!Tl.satisfies(Lr.version,r)){e.logger.error(""),e.logger.error(sd(pn("✖ vis version too old"))),e.logger.error(` vis.config.ts requires vis ${pn(r)}, but the current version is ${pn(Lr.version)}.`),e.logger.error(` ${Rt("→")} Upgrade: ${eo("pnpm add -D @visulima/vis@latest")}`),e.logger.error(""),process.exitCode=1;return}}catch(r){const u=t,d=r instanceof Error?r.message:String(r);e.visConfigError={file:u??void 0,message:d};const l=!!process.stdout.isTTY&&!ao;if(u&&!l){if(e.logger.error(""),e.logger.error(sd(pn(`✖ Failed to load ${u}`))),e.logger.error(` ${d}`),e.logger.error(""),d.includes("Cannot find module")){const g=/Cannot find module '([^']+)'/.exec(d)?.[1]??"unknown";e.logger.error(`${Rt("→ Hint:")} The module ${pn(g)} could not be resolved.`),g.includes("@visulima/vis")?(e.logger.error(" This usually means the package isn't installed or the export path changed."),e.logger.error(` Try: ${eo("pnpm add @visulima/vis")}`),e.logger.error(` Or regenerate: ${eo("vis init --force")}`)):e.logger.error(` Try: ${eo(`pnpm add ${g}`)}`)}else d.includes("SyntaxError")||d.includes("Unexpected token")?(e.logger.error(`${Rt("→ Hint:")} The config file has a syntax error.`),e.logger.error(" Check your config for typos or invalid syntax."),e.logger.error(` Or regenerate: ${eo("vis init --force")}`)):(e.logger.error(`${Rt("→ Hint:")} Delete the broken config and recreate it:`),e.logger.error(` ${eo(`rm ${u} && vis init`)}`));e.logger.error(""),e.logger.error(` Continuing with default settings.
252
252
  `)}e.visConfig={}}const s=process.argv[2]??"";if(!new Set(["--help","--version","-h","-V","create","help","implode","init"]).has(s)&&!t&&!ao)if(process.stdin.isTTY){const r=Kf({input:process.stdin,output:process.stderr}),u=await new Promise(d=>{r.question("\x1B[36;1m?\x1B[0m \x1B[1mNo vis.config.ts found. Create one with best-practice security defaults?\x1B[0m \x1B[90m(\x1B[92mY\x1B[90m/n)\x1B[0m ",d),r.on("SIGINT",()=>{r.close(),d("n")})});if(r.close(),!u.trim()||u.trim().toLowerCase()==="y"||u.trim().toLowerCase()==="yes"){const d=L(o,"vis.config.ts"),l=['import { defineConfig } from "@visulima/vis/config";',"","// Secure defaults are applied automatically by defineConfig().","// You only need to add allowBuilds for packages with build scripts.","// Run 'vis check --security-config' to see all active settings.","export default defineConfig({"," security: {"," allowBuilds: {",' // "esbuild": true,'," },"," },","});",""].join(`
253
253
  `);He(d,l),e.logger.info(`✓ Created ${d}
254
- `),e.visConfig=await Cp(o),t=d}}else e.logger.warn("No vis.config.ts found. Run 'vis init' to create one with best-practice security defaults.")}catch(i){i instanceof Error&&!i.message.includes("monorepo root")&&e.logger.warn(`Failed to detect workspace: ${i.message}`),e.visConfig={}}},name:"config-loader"},gke=336*60*60*1e3,Gg=L(mo(),"mcp-promote.json"),xo="@visulima/vis-mcp",hke=new Set(["--help","--version","-h","-V","ai","help","implode","mcp"]),cke=()=>{try{if(Z(Gg))return Qe(Gg)}catch{}return{lastShown:0}},pke=e=>{try{vo(mo()),ui(Gg,JSON.stringify(e))}catch{}},pt=e=>{try{return Z(e)?Qe(e):void 0}catch{return}},vt=e=>{if(typeof e!="object"||e===null)return!1;for(const i of Object.values(e)){if(typeof i!="object"||i===null)continue;const n=i,o=Array.isArray(n.args)?n.args.join(" "):"",a=`${typeof n.command=="string"?n.command:""} ${o}`;if(a.includes(xo)||a.includes("vis-mcp"))return!0}return!1},vke=e=>{if(!Array.isArray(e))return!1;for(const i of e){if(typeof i!="object"||i===null)continue;const n=i,o=Array.isArray(n.args)?n.args.join(" "):"",a=`${typeof n.command=="string"?n.command:""} ${o} ${typeof n.name=="string"?n.name:""}`;if(a.includes(xo)||a.includes("vis-mcp"))return!0}return!1},yke=e=>{const i=L(e,".claude"),n=L(e,".claude.json"),o=Z(i)||Z(n);let a=!1;if(o){const t=pt(n);a=vt(t?.mcpServers)}return{displayName:"Claude Code",id:"claude-code",installCommand:`claude mcp add vis -- npx -y ${xo}@latest`,isConfigured:a,isInstalled:o}},fke=e=>{const i=L(e,".cursor","mcp.json"),n=Z(L(e,".cursor"));let o=!1;if(n){const a=pt(i);o=vt(a?.mcpServers)}return{displayName:"Cursor",id:"cursor",installCommand:`Add to ~/.cursor/mcp.json: "vis": { "command": "npx", "args": ["-y", "${xo}@latest"] }`,isConfigured:o,isInstalled:n}},mke=e=>{const i=L(e,".codeium","windsurf"),n=L(i,"mcp_config.json"),o=Z(i);let a=!1;if(o){const t=pt(n);a=vt(t?.mcpServers)}return{displayName:"Windsurf",id:"windsurf",installCommand:`Add to ~/.codeium/windsurf/mcp_config.json: "vis": { "command": "npx", "args": ["-y", "${xo}@latest"] }`,isConfigured:a,isInstalled:o}},bke=e=>{const i=L(e,".continue"),n=L(i,"config.json"),o=Z(i);let a=!1;if(o){const t=pt(n);a=vt(t?.mcpServers)||vke(t?.mcpServers)}return{displayName:"Continue",id:"continue",installCommand:`Add to ~/.continue/config.json mcpServers: { "name": "vis", "command": "npx", "args": ["-y", "${xo}@latest"] }`,isConfigured:a,isInstalled:o}},wke=e=>{const i=L(e,"Library","Application Support","Zed","settings.json"),n=L(e,".config","zed","settings.json"),o=LY()==="darwin"?i:n,a=Z(o);let t=!1;if(a){const s=pt(o);t=vt(s?.context_servers)}return{displayName:"Zed",id:"zed",installCommand:`Add to Zed settings.json under context_servers: "vis": { "command": "npx", "args": ["-y", "${xo}@latest"] }`,isConfigured:t,isInstalled:a}},jke=e=>{const i=[L(e,".config","Code","User","globalStorage","saoudrizwan.claude-dev","settings","cline_mcp_settings.json"),L(e,"Library","Application Support","Code","User","globalStorage","saoudrizwan.claude-dev","settings","cline_mcp_settings.json")];let n;for(const t of i)if(Z(t)){n=t;break}const o=n!==void 0;let a=!1;if(n!==void 0){const t=pt(n);a=vt(t?.mcpServers)}return{displayName:"Cline",id:"cline",installCommand:`In VS Code: open Cline > MCP Servers, add "vis" with command "npx" and args ["-y", "${xo}@latest"]`,isConfigured:a,isInstalled:o}},kke=()=>{const e=SY();return[yke(e),fke(e),mke(e),bke(e),wke(e),jke(e)]},Ske=e=>{if(!e.success||process.env.VIS_CLI_TEST||ao||process.env.VIS_NO_MCP_PROMOTE==="1"||e.visConfig?.mcpPromote?.enabled===!1||!process.stderr.isTTY||e.command!==void 0&&hke.has(e.command))return!1;const i=new Set(process.argv.slice(2));return!(i.has("--silent")||i.has("-s")||i.has("--json"))},Lke=e=>{if(!Ske(e))return;const i=Date.now(),n=cke();if(i-n.lastShown<gke)return;const o=kke().find(a=>a.isInstalled&&!a.isConfigured);o!==void 0&&(process.stderr.write(`
254
+ `),e.visConfig=await Cp(o),t=d}}else e.logger.warn("No vis.config.ts found. Run 'vis init' to create one with best-practice security defaults.")}catch(i){i instanceof Error&&!i.message.includes("monorepo root")&&e.logger.warn(`Failed to detect workspace: ${i.message}`),e.visConfig={}}},name:"config-loader"},hke=336*60*60*1e3,Gg=L(mo(),"mcp-promote.json"),xo="@visulima/vis-mcp",cke=new Set(["--help","--version","-h","-V","ai","help","implode","mcp"]),pke=()=>{try{if(Z(Gg))return Qe(Gg)}catch{}return{lastShown:0}},vke=e=>{try{vo(mo()),ui(Gg,JSON.stringify(e))}catch{}},pt=e=>{try{return Z(e)?Qe(e):void 0}catch{return}},vt=e=>{if(typeof e!="object"||e===null)return!1;for(const i of Object.values(e)){if(typeof i!="object"||i===null)continue;const n=i,o=Array.isArray(n.args)?n.args.join(" "):"",a=`${typeof n.command=="string"?n.command:""} ${o}`;if(a.includes(xo)||a.includes("vis-mcp"))return!0}return!1},yke=e=>{if(!Array.isArray(e))return!1;for(const i of e){if(typeof i!="object"||i===null)continue;const n=i,o=Array.isArray(n.args)?n.args.join(" "):"",a=`${typeof n.command=="string"?n.command:""} ${o} ${typeof n.name=="string"?n.name:""}`;if(a.includes(xo)||a.includes("vis-mcp"))return!0}return!1},fke=e=>{const i=L(e,".claude"),n=L(e,".claude.json"),o=Z(i)||Z(n);let a=!1;if(o){const t=pt(n);a=vt(t?.mcpServers)}return{displayName:"Claude Code",id:"claude-code",installCommand:`claude mcp add vis -- npx -y ${xo}@latest`,isConfigured:a,isInstalled:o}},mke=e=>{const i=L(e,".cursor","mcp.json"),n=Z(L(e,".cursor"));let o=!1;if(n){const a=pt(i);o=vt(a?.mcpServers)}return{displayName:"Cursor",id:"cursor",installCommand:`Add to ~/.cursor/mcp.json: "vis": { "command": "npx", "args": ["-y", "${xo}@latest"] }`,isConfigured:o,isInstalled:n}},bke=e=>{const i=L(e,".codeium","windsurf"),n=L(i,"mcp_config.json"),o=Z(i);let a=!1;if(o){const t=pt(n);a=vt(t?.mcpServers)}return{displayName:"Windsurf",id:"windsurf",installCommand:`Add to ~/.codeium/windsurf/mcp_config.json: "vis": { "command": "npx", "args": ["-y", "${xo}@latest"] }`,isConfigured:a,isInstalled:o}},wke=e=>{const i=L(e,".continue"),n=L(i,"config.json"),o=Z(i);let a=!1;if(o){const t=pt(n);a=vt(t?.mcpServers)||yke(t?.mcpServers)}return{displayName:"Continue",id:"continue",installCommand:`Add to ~/.continue/config.json mcpServers: { "name": "vis", "command": "npx", "args": ["-y", "${xo}@latest"] }`,isConfigured:a,isInstalled:o}},jke=e=>{const i=L(e,"Library","Application Support","Zed","settings.json"),n=L(e,".config","zed","settings.json"),o=LY()==="darwin"?i:n,a=Z(o);let t=!1;if(a){const s=pt(o);t=vt(s?.context_servers)}return{displayName:"Zed",id:"zed",installCommand:`Add to Zed settings.json under context_servers: "vis": { "command": "npx", "args": ["-y", "${xo}@latest"] }`,isConfigured:t,isInstalled:a}},kke=e=>{const i=[L(e,".config","Code","User","globalStorage","saoudrizwan.claude-dev","settings","cline_mcp_settings.json"),L(e,"Library","Application Support","Code","User","globalStorage","saoudrizwan.claude-dev","settings","cline_mcp_settings.json")];let n;for(const t of i)if(Z(t)){n=t;break}const o=n!==void 0;let a=!1;if(n!==void 0){const t=pt(n);a=vt(t?.mcpServers)}return{displayName:"Cline",id:"cline",installCommand:`In VS Code: open Cline > MCP Servers, add "vis" with command "npx" and args ["-y", "${xo}@latest"]`,isConfigured:a,isInstalled:o}},Ske=()=>{const e=SY();return[fke(e),mke(e),bke(e),wke(e),jke(e),kke(e)]},Lke=e=>{if(!e.success||process.env.VIS_CLI_TEST||ao||process.env.VIS_NO_MCP_PROMOTE==="1"||e.visConfig?.mcpPromote?.enabled===!1||!process.stderr.isTTY||e.command!==void 0&&cke.has(e.command))return!1;const i=new Set(process.argv.slice(2));return!(i.has("--silent")||i.has("-s")||i.has("--json"))},Cke=e=>{if(!Lke(e))return;const i=Date.now(),n=pke();if(i-n.lastShown<hke)return;const o=Ske().find(a=>a.isInstalled&&!a.isConfigured);o!==void 0&&(process.stderr.write(`
255
255
  ${eo("✨")} ${pn(`vis ships an MCP server for ${o.displayName}.`)}
256
256
  ${o.installCommand}
257
257
  ${Ca("Hide this with VIS_NO_MCP_PROMOTE=1 or mcpPromote: { enabled: false } in vis.config.ts")}
258
- `),pke({lastShown:i}))},Cke=336*60*60*1e3,Yke="https://github.com/sponsors/prisis",Fg=L(mo(),"sponsor.json"),$ke=()=>{try{if(Z(Fg))return Qe(Fg)}catch{}return{lastShown:0}},Zke=e=>{try{vo(mo()),ui(Fg,JSON.stringify(e))}catch{}},Jke=e=>{if(!e.success||process.env.VIS_CLI_TEST||ao||process.env.VIS_NO_SPONSOR==="1"||e.visConfig?.sponsor?.enabled===!1||!process.stderr.isTTY)return;const i=Date.now(),n=$ke();i-n.lastShown<Cke||(process.stderr.write(`
259
- ${YY("♥")} ${pn("Enjoying visulima?")} ${Ca(`Consider sponsoring at ${Yke}`)}
258
+ `),vke({lastShown:i}))},Yke=336*60*60*1e3,$ke="https://github.com/sponsors/prisis",Fg=L(mo(),"sponsor.json"),Zke=()=>{try{if(Z(Fg))return Qe(Fg)}catch{}return{lastShown:0}},Jke=e=>{try{vo(mo()),ui(Fg,JSON.stringify(e))}catch{}},xke=e=>{if(!e.success||process.env.VIS_CLI_TEST||ao||process.env.VIS_NO_SPONSOR==="1"||e.visConfig?.sponsor?.enabled===!1||!process.stderr.isTTY)return;const i=Date.now(),n=Zke();i-n.lastShown<Yke||(process.stderr.write(`
259
+ ${YY("♥")} ${pn("Enjoying visulima?")} ${Ca(`Consider sponsoring at ${$ke}`)}
260
260
  ${Ca(" Hide this with VIS_NO_SPONSOR=1 or sponsor.enabled = false in vis.config.ts")}
261
- `),Zke({lastShown:i}))},Of=300*1e3,Qg=L(mo(),"tips.json"),xke=()=>{try{if(Z(Qg))return Qe(Qg)}catch{}return{lastGlobal:0,perTip:{}}},Tke=e=>{try{vo(mo()),ui(Qg,JSON.stringify(e))}catch{}},Dke=[{cooldownMs:1800*1e3,id:"short-aliases",matches:e=>["install","link","remove","uninstall","update"].includes(e.command),message:e=>{const i={install:"i",link:"ln",remove:"rm",uninstall:"rm",update:"up"}[e.command];return i?`You can use 'vis ${i}' as a shorthand for 'vis ${e.command}'`:""},probability:.5},{id:"use-exec",matches:e=>e.command==="dlx"&&e.success,message:()=>"Use 'vis exec' to run locally installed binaries without downloading."},{id:"security-check",matches:e=>(e.command==="check"||e.command==="update")&&e.success&&!e.args.includes("--security"),message:()=>"Add --security to check for known vulnerabilities via OSV.dev",probability:.3},{cooldownMs:3600*1e3,id:"ai-analysis",matches:e=>(e.command==="check"||e.command==="update")&&e.success&&!e.args.includes("--ai"),message:()=>"Add --ai to run AI analysis on outdated packages before updating.",probability:.2},{cooldownMs:1440*60*1e3,id:"socket-security",matches:e=>(e.command==="install"||e.command==="update"||e.command==="check")&&e.success,message:()=>"Enable Socket.dev in vis.config.ts for security scores and supply chain alerts: security.socket.enabled = true",probability:.15},{id:"dedupe-after-install",matches:e=>e.command==="install"&&e.success,message:()=>"Run 'vis dedupe' periodically to remove duplicate dependencies.",probability:.15},{cooldownMs:720*60*1e3,id:"doctor-checkup",matches:e=>(e.command==="install"||e.command==="add"||e.command==="update")&&e.success,message:()=>"Run 'vis doctor' for a full project health check — outdated, security, duplicates, and optimizations in one view.",probability:.25},{cooldownMs:10080*60*1e3,id:"init-config",matches:e=>(e.command==="install"||e.command==="run")&&e.success&&!e.hasVisConfig,message:()=>"Run 'vis init' to create a vis.config.ts with secure defaults — supply chain protection enabled automatically.",probability:.4},{id:"why-command",matches:e=>e.command==="outdated"&&e.success,message:()=>"Use 'vis why <package>' to understand why a dependency is installed.",probability:.3},{id:"graph-command",matches:e=>e.command==="run"&&e.success,message:()=>"Use 'vis graph' to visualize your project dependency graph.",probability:.1},{id:"affected-command",matches:e=>e.command==="run"&&e.success&&!e.args.includes("--projects"),message:()=>"Use 'vis affected <target>' to run tasks only on changed projects.",probability:.2},{id:"pm-cache",matches:e=>e.command==="install"&&e.success,message:()=>"Use 'vis pm cache dir' to find your package manager's cache location.",probability:.1},{id:"create-editor",matches:e=>e.command==="create"&&e.success,message:()=>"Add --editor vscode to generate VS Code configuration during project creation.",probability:.5},{id:"env-pin",matches:e=>e.command==="env"&&e.args.includes("install")&&e.success,message:()=>"Use 'vis env pin <version>' to pin the Node.js version for your project.",probability:.5},{cooldownMs:720*60*1e3,id:"docker-lint",matches:e=>!!e.hasDockerfile&&e.success&&e.command!=="docker",message:()=>"Found a Dockerfile — run 'vis docker lint' to check it against hadolint best practices.",probability:.3},{cooldownMs:1440*60*1e3,id:"docker-ignore",matches:e=>!!e.hasDockerfile&&!e.hasDockerignore&&e.success&&e.command!=="ignore",message:()=>"No .dockerignore next to your Dockerfile — run 'vis ignore --write' to shrink the build context.",probability:.4},{cooldownMs:1440*60*1e3,id:"vercel-ignore",matches:e=>!!e.hasVercelConfig&&e.success&&e.command!=="ignore",message:()=>"Deploying to Vercel? Run 'vis ignore --target=vercel --write' to generate a deduped .vercelignore.",probability:.25},{id:"upgrade-check",matches:e=>e.command!=="self-update"&&e.success,message:()=>"Run 'vis self-update --check' to see if a newer version of vis is available.",probability:.05}],Bke=e=>{if(process.env.VIS_CLI_TEST||ao)return;const i=Date.now(),n=xke();if(i-n.lastGlobal<Of)return;const o=Dke.filter(s=>{if(!s.matches(e))return!1;const r=n.perTip[s.id]??0,u=s.cooldownMs??Of;return i-r>=u});if(o.length===0)return;const a=o.find(s=>{const r=s.probability??1;return Math.random()<r});if(!a)return;const t=a.message(e);t&&(process.stderr.write(`
261
+ `),Jke({lastShown:i}))},Of=300*1e3,Qg=L(mo(),"tips.json"),Tke=()=>{try{if(Z(Qg))return Qe(Qg)}catch{}return{lastGlobal:0,perTip:{}}},Dke=e=>{try{vo(mo()),ui(Qg,JSON.stringify(e))}catch{}},Bke=[{cooldownMs:1800*1e3,id:"short-aliases",matches:e=>["install","link","remove","uninstall","update"].includes(e.command),message:e=>{const i={install:"i",link:"ln",remove:"rm",uninstall:"rm",update:"up"}[e.command];return i?`You can use 'vis ${i}' as a shorthand for 'vis ${e.command}'`:""},probability:.5},{id:"use-exec",matches:e=>e.command==="dlx"&&e.success,message:()=>"Use 'vis exec' to run locally installed binaries without downloading."},{id:"security-check",matches:e=>(e.command==="check"||e.command==="update")&&e.success&&!e.args.includes("--security"),message:()=>"Add --security to check for known vulnerabilities via OSV.dev",probability:.3},{cooldownMs:3600*1e3,id:"ai-analysis",matches:e=>(e.command==="check"||e.command==="update")&&e.success&&!e.args.includes("--ai"),message:()=>"Add --ai to run AI analysis on outdated packages before updating.",probability:.2},{cooldownMs:1440*60*1e3,id:"socket-security",matches:e=>(e.command==="install"||e.command==="update"||e.command==="check")&&e.success,message:()=>"Enable Socket.dev in vis.config.ts for security scores and supply chain alerts: security.socket.enabled = true",probability:.15},{id:"dedupe-after-install",matches:e=>e.command==="install"&&e.success,message:()=>"Run 'vis dedupe' periodically to remove duplicate dependencies.",probability:.15},{cooldownMs:720*60*1e3,id:"doctor-checkup",matches:e=>(e.command==="install"||e.command==="add"||e.command==="update")&&e.success,message:()=>"Run 'vis doctor' for a full project health check — outdated, security, duplicates, and optimizations in one view.",probability:.25},{cooldownMs:10080*60*1e3,id:"init-config",matches:e=>(e.command==="install"||e.command==="run")&&e.success&&!e.hasVisConfig,message:()=>"Run 'vis init' to create a vis.config.ts with secure defaults — supply chain protection enabled automatically.",probability:.4},{id:"why-command",matches:e=>e.command==="outdated"&&e.success,message:()=>"Use 'vis why <package>' to understand why a dependency is installed.",probability:.3},{id:"graph-command",matches:e=>e.command==="run"&&e.success,message:()=>"Use 'vis graph' to visualize your project dependency graph.",probability:.1},{id:"affected-command",matches:e=>e.command==="run"&&e.success&&!e.args.includes("--projects"),message:()=>"Use 'vis affected <target>' to run tasks only on changed projects.",probability:.2},{id:"pm-cache",matches:e=>e.command==="install"&&e.success,message:()=>"Use 'vis pm cache dir' to find your package manager's cache location.",probability:.1},{id:"create-editor",matches:e=>e.command==="create"&&e.success,message:()=>"Add --editor vscode to generate VS Code configuration during project creation.",probability:.5},{id:"env-pin",matches:e=>e.command==="env"&&e.args.includes("install")&&e.success,message:()=>"Use 'vis env pin <version>' to pin the Node.js version for your project.",probability:.5},{cooldownMs:720*60*1e3,id:"docker-lint",matches:e=>!!e.hasDockerfile&&e.success&&e.command!=="docker",message:()=>"Found a Dockerfile — run 'vis docker lint' to check it against hadolint best practices.",probability:.3},{cooldownMs:1440*60*1e3,id:"docker-ignore",matches:e=>!!e.hasDockerfile&&!e.hasDockerignore&&e.success&&e.command!=="ignore",message:()=>"No .dockerignore next to your Dockerfile — run 'vis ignore --write' to shrink the build context.",probability:.4},{cooldownMs:1440*60*1e3,id:"vercel-ignore",matches:e=>!!e.hasVercelConfig&&e.success&&e.command!=="ignore",message:()=>"Deploying to Vercel? Run 'vis ignore --target=vercel --write' to generate a deduped .vercelignore.",probability:.25},{id:"upgrade-check",matches:e=>e.command!=="self-update"&&e.success,message:()=>"Run 'vis self-update --check' to see if a newer version of vis is available.",probability:.05}],Xke=e=>{if(process.env.VIS_CLI_TEST||ao)return;const i=Date.now(),n=Tke();if(i-n.lastGlobal<Of)return;const o=Bke.filter(s=>{if(!s.matches(e))return!1;const r=n.perTip[s.id]??0,u=s.cooldownMs??Of;return i-r>=u});if(o.length===0)return;const a=o.find(s=>{const r=s.probability??1;return Math.random()<r});if(!a)return;const t=a.message(e);t&&(process.stderr.write(`
262
262
  \x1B[2mtip: ${t}\x1B[0m
263
- `),n.lastGlobal=i,n.perTip[a.id]=i,Tke(n))},Xke=e=>({afterCommand:async i=>{const n=process.argv.slice(2),o=n[0]??"",a=process.exitCode===void 0||process.exitCode===0;e&&e();const t=i.workspaceRoot??process.cwd();Bke({args:n,command:o,hasDockerfile:Z(L(t,"Dockerfile")),hasDockerignore:Z(L(t,".dockerignore")),hasVercelConfig:Z(L(t,"vercel.json"))||Z(L(t,".vercel")),hasVisConfig:i.visConfig!==void 0&&Object.keys(i.visConfig).length>0,success:a}),Jke({success:a,visConfig:i.visConfig}),Lke({command:o,success:a,visConfig:i.visConfig})},name:"post-command"}),Hke=e=>`MARSHALL_DISABLE_${e.replaceAll(/([A-Z])/g,"_$1").toUpperCase()}`,$l=(e,i=process.env)=>wp(i.MARSHALL_DISABLE_ALL)?!0:wp(i[Hke(e)]),RC=(e,i)=>{const n={errors:[],warnings:[]},{security:o}=e;if(!o)return n.warnings.push("No security settings configured. Use defineConfig() from '@visulima/vis/config' to get secure defaults automatically."),n;const a=o.policies??{},{installScripts:t}=a,s=t?.allow,r=s&&Object.keys(s).length>0;if(r||n.warnings.push(i==="pnpm"?"security.policies.installScripts.allow is not configured. pnpm blocks build scripts by default since v10. Run 'vis approve-builds' to review.":"security.policies.installScripts.allow is not configured. Consider listing which packages are allowed to run install/postinstall scripts."),a.firstSeen?.minutes===0&&n.warnings.push("security.policies.firstSeen.minutes is explicitly set to 0. New packages can be installed immediately after publishing."),a.publisherChange?.mode==="off"&&n.warnings.push("security.policies.publisherChange.mode is explicitly 'off'. Packages whose trust level has decreased will not be blocked."),o.blockExoticSubdeps===!1&&n.warnings.push("security.blockExoticSubdeps is explicitly disabled. Transitive dependencies can pull code from git repos or tarball URLs."),t?.strict===!1&&n.warnings.push("security.policies.installScripts.strict is explicitly disabled. Unapproved build scripts will only produce warnings, not errors."),t?.strict&&!r&&n.errors.push("security.policies.installScripts.strict is enabled but `.allow` is empty. All dependencies with build scripts will be blocked. Run 'vis approve-builds' to review and add packages."),o.acceptedRisks){const u=Date.now();for(const[d,l]of Object.entries(o.acceptedRisks)){const g=new Date(l.acceptedAt).getTime();u-g>7776e6&&n.warnings.push(`Accepted risk for "${d}" is over 90 days old (accepted ${l.acceptedAt}). Consider re-evaluating with 'vis audit'.`)}}return n},Mke=(e,i,n=!1)=>{if(ao&&!process.env.VIS_SECURITY_WARNINGS)return;const o=RC(e,i);for(const t of o.errors)x.error(t);const a=n?o.warnings.filter(t=>!t.startsWith("security.policies.installScripts.allow is not configured")):o.warnings;a.length>0&&x.warn(`${a.length} security recommendation${a.length===1?"":"s"} found. Run 'vis check --security-config' for details.`)},kSe=(e,i)=>{const n=RC(e,i),{security:o}=e;if(o){const a=o.policies??{},{firstSeen:t}=a,{publisherChange:s}=a,{installScripts:r}=a,{score:u}=a;if(x.info("Active security settings:"),x.info(` policies.firstSeen.minutes: ${t?.minutes??"not set"} minutes`),x.info(` policies.publisherChange.mode: ${s?.mode??"not set"}`),x.info(` policies.publisherChange.ignoreAfter: ${s?.ignoreAfter??"not set"} minutes`),x.info(` blockExoticSubdeps: ${o.blockExoticSubdeps??!1}`),x.info(` policies.installScripts.strict: ${r?.strict??!1}`),x.info(` policies.installScripts.allow: ${r?.allow?`${Object.keys(r.allow).length} entries`:"not configured"}`),x.info(""),x.info("Socket.dev integration:"),x.info(` socket.enabled: ${o.socket?.enabled??!1}`),x.info(` socket.apiToken: ${o.socket?.apiToken||process.env.VIS_SOCKET_TOKEN?"configured":"using public token"}`),x.info(` policies.score.minimum: ${u?.minimum??"default (0.4)"}`),x.info(` socket.cacheTtlMs: ${o.socket?.cacheTtlMs??"default (1 hour)"}`),x.info(` socket.timeoutMs: ${o.socket?.timeoutMs??"default (15s)"}`),o.acceptedRisks){const d=Object.entries(o.acceptedRisks);x.info(` acceptedRisks: ${String(d.length)} entr${d.length===1?"y":"ies"}`);for(const[l,g]of d)x.info(` ${l}: ${g.reason} (accepted ${g.acceptedAt.slice(0,10)})`)}else x.info(" acceptedRisks: none");x.info("")}if(n.errors.length===0&&n.warnings.length===0){x.info("All recommended security settings are configured.");return}for(const a of n.errors)x.error(a);for(const a of n.warnings)x.warn(a);x.notice(""),x.notice("Secure defaults are applied by defineConfig(). You only need to add install-script allowances:"),x.notice(""),x.notice(" import { defineConfig } from '@visulima/vis/config';"),x.notice(""),x.notice(" export default defineConfig({"),x.notice(" security: {"),x.notice(" policies: {"),x.notice(" installScripts: {"),x.notice(" allow: {"),x.notice(" esbuild: true,"),x.notice(" '@prisma/client': true,"),x.notice(" },"),x.notice(" },"),x.notice(" },"),x.notice(" },"),x.notice(" });")},SSe=e=>{const{security:i}=e;if(!i)return[];const n=i.policies??{},{firstSeen:o}=n,{publisherChange:a}=n,{installScripts:t}=n,s=[];return o?.minutes!==void 0&&s.push(`minimumReleaseAge: ${o.minutes}`),a?.mode&&a.mode!=="off"&&s.push(`trustPolicy: ${a.mode}`),i.blockExoticSubdeps&&s.push("blockExoticSubdeps: true"),t?.allow&&s.push(`allowBuilds: ${Object.keys(t.allow).length} entries`),t?.strict&&s.push("strictDepBuilds: true"),a?.ignoreAfter!==void 0&&s.push(`trustPolicyIgnoreAfter: ${a.ignoreAfter}`),s},OC=e=>{const i=e.trim();if(i==="")return;const n=/^(\d+(?:\.\d+)?)\s*([mhdw]?)$/i.exec(i);if(!n)return;const o=Number.parseFloat(n[1]);if(!(!Number.isFinite(o)||o<0))switch(n[2]?.toLowerCase()){case"":case"m":case void 0:return Math.round(o);case"d":return Math.round(o*1440);case"h":return Math.round(o*60);case"w":return Math.round(o*10080);default:return}},Pke=e=>e.startsWith("@")||e.includes("/")||/[:#\s]/.test(e),LSe=e=>Pke(e)?`'${e.replaceAll("'","''")}'`:e,Nke=e=>{const i=e.trim();return/^\d+$/.test(i)?Number.parseInt(i,10)*1440:OC(i)},Eke=(e,i)=>{const n={};try{switch(e){case"bun":{const o=L(i,"package.json");if(Z(o)){const t=Qe(o);Array.isArray(t.trustedDependencies)&&(n.allowBuilds=new Set(t.trustedDependencies))}const a=L(i,"bunfig.toml");if(Z(a)){const t=AY(a),s=t?.install?.minimumReleaseAge;typeof s=="number"&&(n.minReleaseAgeMinutes=Math.round(s/60)),Array.isArray(t?.install?.minimumReleaseAgeExcludes)&&(n.minReleaseAgeExcludes=new Set(t.install.minimumReleaseAgeExcludes))}break}case"npm":{const o=L(i,".npmrc");if(Z(o)){const a=z(o),t=/^\s*min-release-age\s*=\s*([^\s#;]+)/m.exec(a);t&&(n.minReleaseAgeMinutes=Nke(t[1]))}break}case"pnpm":{const o=L(i,"pnpm-workspace.yaml");if(Z(o)){const a=Ro(o);a?.allowBuilds&&typeof a.allowBuilds=="object"?n.allowBuilds=new Set(Object.entries(a.allowBuilds).filter(([,t])=>t).map(([t])=>t)):Array.isArray(a?.onlyBuiltDependencies)&&(n.allowBuilds=new Set(a.onlyBuiltDependencies)),typeof a?.minimumReleaseAge=="number"&&(n.minReleaseAgeMinutes=a.minimumReleaseAge),Array.isArray(a?.minimumReleaseAgeExclude)&&(n.minReleaseAgeExcludes=new Set(a.minimumReleaseAgeExclude))}break}case"yarn":{const o=L(i,".yarnrc.yml");if(Z(o)){const a=Ro(o),t=a?.npmMinimalAgeGate;typeof t=="string"?n.minReleaseAgeMinutes=OC(t):typeof t=="number"&&(n.minReleaseAgeMinutes=t),Array.isArray(a?.npmPreapprovedPackages)&&(n.minReleaseAgeExcludes=new Set(a.npmPreapprovedPackages))}break}}}catch{}return n},Rke=(e,i,n)=>{const o=Eke(i,n),a={hasDrift:!1,packageManager:i},t=(e.security??{}).policies??{},{installScripts:s}=t,{firstSeen:r}=t;if(s?.allow&&(i==="pnpm"||i==="bun")){const u=new Set(Object.entries(s.allow).filter(([,h])=>h).map(([h])=>h)),d=o.allowBuilds??new Set,l=[...u].filter(h=>!d.has(h)),g=[...d].filter(h=>!u.has(h));(l.length>0||g.length>0)&&(a.allowBuilds={onlyInPm:g,onlyInVis:l},a.hasDrift=!0)}if(r?.minutes!==void 0&&!(i==="yarn"&&o.minReleaseAgeMinutes===void 0&&!Z(L(n,".yarnrc.yml")))&&o.minReleaseAgeMinutes!==r.minutes&&(a.minReleaseAge={pm:o.minReleaseAgeMinutes,vis:r.minutes},a.hasDrift=!0),r?.exclude&&(i==="pnpm"||i==="bun"||i==="yarn")){const u=new Set(r.exclude),d=o.minReleaseAgeExcludes??new Set,l=[...u].filter(h=>!d.has(h)),g=[...d].filter(h=>!u.has(h));(l.length>0||g.length>0)&&(a.minReleaseAgeExcludes={onlyInPm:g,onlyInVis:l},a.hasDrift=!0)}return a},Oke=e=>{if(!e.hasDrift)return[];const i=[`vis.config and ${e.packageManager}-native config disagree on security settings:`];if(e.allowBuilds&&(e.allowBuilds.onlyInVis.length>0&&i.push(` security.policies.installScripts.allow — only in vis.config: ${e.allowBuilds.onlyInVis.join(", ")}`),e.allowBuilds.onlyInPm.length>0&&i.push(` security.policies.installScripts.allow — only in ${e.packageManager} config: ${e.allowBuilds.onlyInPm.join(", ")}`)),e.minReleaseAge){const n=e.minReleaseAge.vis===void 0?"unset":`${String(e.minReleaseAge.vis)} min`,o=e.minReleaseAge.pm===void 0?"unset":`${String(e.minReleaseAge.pm)} min`;i.push(` security.policies.firstSeen.minutes — vis.config: ${n}, ${e.packageManager}: ${o}`)}return e.minReleaseAgeExcludes&&(e.minReleaseAgeExcludes.onlyInVis.length>0&&i.push(` security.policies.firstSeen.exclude — only in vis.config: ${e.minReleaseAgeExcludes.onlyInVis.join(", ")}`),e.minReleaseAgeExcludes.onlyInPm.length>0&&i.push(` security.policies.firstSeen.exclude — only in ${e.packageManager} config: ${e.minReleaseAgeExcludes.onlyInPm.join(", ")}`)),i.push(" Run 'vis security sync' to push vis.config values to the native config."),i},Ake=e=>Z(L(e,".yarnrc.yml")),Gke=(e,i,n)=>{const o={extraArgs:[],postInstallPackages:[],scriptsBlockedByDefault:!1,warnings:[]},a=n.security?.policies?.installScripts?.allow??{},t=Object.keys(a).length>0;switch(e){case"bun":{if(o.scriptsBlockedByDefault=!0,t){const s=L(i,"package.json");try{(Z(s)?Qe(s):{}).trustedDependencies?.length||o.warnings.push("vis security.policies.installScripts.allow is configured but trustedDependencies is empty. Run 'vis approve-builds --sync-native'.")}catch{}}break}case"npm":{o.scriptsBlockedByDefault=!1;const s=L(i,".npmrc"),r=Z(s)&&/^\s*ignore-scripts\s*=\s*true\s*$/m.test(z(s));if(!r&&t?(o.warnings.push("npm does not block lifecycle scripts. vis will add --ignore-scripts automatically."),o.extraArgs.push("--ignore-scripts")):!r&&!t&&o.warnings.push("npm does not block lifecycle scripts. Add 'ignore-scripts=true' to .npmrc and configure security.policies.installScripts.allow."),t)for(const[u,d]of Object.entries(a))d&&o.postInstallPackages.push(u);break}case"pnpm":{o.scriptsBlockedByDefault=!0,t||o.warnings.push("pnpm blocks build scripts by default. Run 'vis approve-builds' to review packages that need scripts.");break}case"yarn":{if(o.scriptsBlockedByDefault=!1,Ake(i)){const s=z(L(i,".yarnrc.yml"));/^\s*enableScripts\s*:\s*false\s*$/m.test(s)?o.scriptsBlockedByDefault=!0:o.warnings.push("yarn berry supports enableScripts. Add 'enableScripts: false' to .yarnrc.yml.")}else if(o.warnings.push("yarn classic does not support blocking lifecycle scripts. Consider upgrading to yarn berry."),t){o.extraArgs.push("--ignore-scripts");for(const[s,r]of Object.entries(a))r&&o.postInstallPackages.push(s)}break}}return o},AC=(...e)=>{const i={...process.env},n=i.PATH??i.Path??"",o=e.filter(a=>a.length>0).join(mp);return i.PATH=o.length>0?n?`${o}${mp}${n}`:o:n,i},Fke=e=>{if(e.endsWith("*"))return e.endsWith("@*")?e.slice(0,-2):e;const i=e.startsWith("@"),n=e.indexOf("@",i?1:0);return n===-1?e:e.slice(0,n)},Qke=(e,i)=>{const n=L(e,"node_modules"),o=[];for(const a of i){if(!a.endsWith("*")){o.push(Fke(a));continue}const t=a.slice(0,-1);try{if(t.startsWith("@")&&t.endsWith("/")){const s=L(n,t.slice(0,-1));for(const r of Fi(s))!r.startsWith(".")&&Eo(L(s,r)).isDirectory()&&o.push(`${t.slice(0,-1)}/${r}`)}else for(const s of Fi(n))s.startsWith(t)&&Eo(L(n,s)).isDirectory()&&o.push(s)}catch{}}return o},Wke=(e,i)=>{if(i.length===0)return;const n=Qke(e,i);if(n.length===0)return;const o=L(e,"node_modules"),a=L(o,".bin");let t=!1;for(const s of n){if(s.includes("..")||s.startsWith("/")||s.startsWith("\\")){x.warn(`Skipping invalid package name: ${s}`);continue}const r=(s.match(/\//g)??[]).length;if(r>1||r===1&&!s.startsWith("@")){x.warn(`Skipping invalid package name: ${s}`);continue}const u=L(o,s),d=L(u,"package.json");if(Z(d))try{const l=Qe(d).scripts??{},g=L(u,"node_modules",".bin"),h=AC(g,a);for(const c of["preinstall","install","postinstall"])if(l[c]){x.info(`Running ${c} for ${s}...`);try{const p=l[c];zf(p,{cwd:u,env:h,stdio:"inherit"})}catch{x.error(`${c} script failed for ${s}`),t=!0}}}catch{}}t&&(process.exitCode=1)},CSe=(e,i=["prepublish","prepare"])=>{const n=L(e,"package.json");if(!Z(n))return;let o;try{o=Qe(n).scripts??{}}catch{return}let a=!1;const t=AC(L(e,"node_modules",".bin"));for(const s of i){const r=o[s];if(r){x.info(`Running root ${s}...`);try{zf(r,{cwd:e,env:t,stdio:"inherit"})}catch{x.error(`Root ${s} script failed.`),a=!0}}}a&&(process.exitCode=1)},Zl=new Set(["add","install","update"]),Ike=new Set(["add","dedupe","install","remove","update"]),_ke=/(\d+\.\d+\.\d+)/,zke=e=>{const i=L(e,"package.json");if(!Z(i))return[];const n=[];try{const o=Qe(i),a={...o.dependencies,...o.devDependencies};for(const[t,s]of Object.entries(a)){const r=L(e,"node_modules",t,"package.json");if(Z(r))try{const d=Qe(r);if(d.version){n.push({name:t,version:d.version});continue}}catch{}const u=_ke.exec(s);u?.[1]&&n.push({name:t,version:u[1]})}}catch{}return n},Kke={afterCommand:async e=>{if(process.exitCode&&process.exitCode!==0)return;const i=e.scriptEnforcement;i?.postInstallPackages.length&&e.workspaceRoot&&Wke(e.workspaceRoot,i.postInstallPackages);const n=process.argv[2]??"",o=Zl.has(n)&&e.workspaceRoot?Yp(e.workspaceRoot):void 0;if(o&&e.visConfig&&e.workspaceRoot&&new Set(["bun","npm","pnpm","yarn"]).has(o.name)){const a=Rke(e.visConfig,o.name,e.workspaceRoot);if(a.hasDrift){x.info("");for(const t of Oke(a))x.warn(t)}}if(Zl.has(n)&&e.workspaceRoot){const a=new Set;$l("socket")&&a.add("socket"),$l("depsDev")&&a.add("deps-dev");const t=e.visConfig?.security?.policies?.score?.minimum,s=EY(e.visConfig?.security,{disabled:a,minimumScore:t});if(s.length>0)try{const r=zke(e.workspaceRoot);if(r.length>0){const u=await RY(s,r);if(u.size>0){const d=mY(u,t);if(d){x.info(""),x.info(d);let l=0;for(const g of u.values())for(const h of g.alerts)(h.severity==="critical"||h.severity==="high")&&l++;l>0&&x.warn(`${String(l)} critical/high severity alert${l===1?"":"s"} detected. Run 'vis check --security' for details.`)}}}}catch{}}},beforeCommand:async e=>{const i=process.argv[2]??"";if(Ike.has(i)&&e.visConfig&&e.workspaceRoot){const n=Yp(e.workspaceRoot),o=Zl.has(i);if(Mke(e.visConfig,n.name,o),o&&!$l("installScripts")){const a=Gke(n.name,e.workspaceRoot,e.visConfig);for(const t of a.warnings)e.logger.warn(`security: ${t}`);e.scriptEnforcement=a}}},name:"security-enforcement"},qke=e=>{for(let i=0;i<e.length;i+=1){const n=e[i];if(n==="--ca-cert"){const o=e[i+1];return o===void 0||o.startsWith("-")?void 0:Cr(o)}if(n.startsWith("--ca-cert=")){const o=n.slice(10);return o===""?void 0:Cr(o)}}},Uke=()=>process.platform==="win32"?!!process.env.WT_SESSION||process.env.TERM_PROGRAM==="vscode"||process.env.TERM==="xterm-256color":process.env.TERM!=="linux",Et=Uke(),Vke={arrow:Et?"→":"->",dash:Et?"—":"-",failure:Et?"✗":"x",success:Et?"✓":"v",warning:Et?"⚠":"!"},Wg=L(mo(),"upgrade-check.json"),e1e=1440*60*1e3,i1e=1440*60*1e3,n1e=500,o1e=new Set(["--help","--version","-h","-V","help","implode","upgrade"]),a1e=()=>{try{if(Z(Wg))return Qe(Wg)}catch{}},GC=e=>{try{vo(mo()),ui(Wg,JSON.stringify(e))}catch{}},t1e=async e=>{try{const i=new AbortController,n=setTimeout(()=>{i.abort()},n1e),o=await fetch(`https://registry.npmjs.org/${e}/latest`,{headers:{accept:"application/json"},signal:i.signal});return clearTimeout(n),o.ok?(await o.json()).version:void 0}catch{return}},Af=(e,i)=>{let n;try{n=Tl.gt(i.latestVersion,e,{loose:!0})}catch{return}if(!n)return;const o=Date.now();o-i.lastNoticeAt<i1e||(process.stderr.write(`
264
- ${Ca("vis update available:")} ${Rt(e)} ${Ca(Vke.arrow)} ${$Y(pn(i.latestVersion))}${Ca(", run")} ${eo("vis upgrade")}
265
- `),i.lastNoticeAt=o,GC(i))},s1e=e=>{if(ao||process.env.VIS_CLI_TEST||process.env.VIS_NO_UPDATE_CHECK==="1"||!process.stderr.isTTY||o1e.has(e))return!1;const i=new Set(process.argv.slice(2));return!(i.has("--silent")||i.has("-s")||i.has("--json"))},r1e=(e,i)=>{if(!s1e(i))return;const n=a1e(),o=Date.now();if(n&&o-n.lastQueryAt<e1e)return()=>{Af(e,n)};let a=n;return t1e("@visulima/vis").then(t=>{t&&(a={lastNoticeAt:n?.lastNoticeAt??0,lastQueryAt:o,latestVersion:t},GC(a))}).catch(()=>{}),()=>{a&&Af(e,a)}},u1e=async()=>{const e=qke(process.argv);e!==void 0&&!process.env.NODE_EXTRA_CA_CERTS&&(process.env.NODE_EXTRA_CA_CERTS=e);try{const a=lm(process.cwd()).path;process.env.VIS_MONOREPO_ROOT=a;const t=Qe(L(a,"package.json"));t.name&&GY(t.name)}catch{}const i=r1e(Lr.version,process.argv[2]??""),n=IC("vis",{packageName:"vis",packageVersion:Lr.version}),o=process.argv.includes("--debug")||!!process.env.DEBUG;n.addPlugin(_C({detailed:o,exitOnError:!1})),n.addGlobalOption({description:"Override workspace root directory",name:"cwd",type:String}),n.addGlobalOption({description:"Target JS runtime: node (default) or bun. Overrides VIS_RUNTIME and config; falls back to lockfile detection.",name:"runtime",type:String}),n.addGlobalOption({description:"Path to a vis config file (overrides discovery)",name:"config",type:String}),n.addGlobalOption({description:"Path to a CA bundle (PEM) to trust for HTTPS — for corporate proxies. Equivalent to NODE_EXTRA_CA_CERTS.",name:"ca-cert",type:String}),n.addPlugin(lke),n.addPlugin(Kke),n.addCommand(Cje),n.addCommand(DZ),n.addCommand(M0e),n.addCommand(eZ),n.addCommand(uZ),n.addCommand(Uje),n.addCommand(Lje),n.addCommand(Q0e),n.addCommand(ske),n.addCommand(TZ),n.addCommand(Y0e),n.addCommand(yZ),n.addCommand(Ije),n.addCommand(zje),n.addCommand(Kje),n.addCommand(L0e),n.addCommand(qje),n.addCommand(efe),n.addCommand(UY),n.addCommand(VY),n.addCommand(V0e),n.addCommand(X0e),n.addCommand(q0e),n.addCommand(iZ),n.addCommand(Sje),n.addCommand(C0e),n.addCommand(uke),n.addCommand(_0e),n.addCommand(U0e),n.addCommand(tke),n.addCommand(zC),n.addCommand(OY),n.addCommand(dke),n.addCommand(eje),n.addCommand(z0e),n.addCommand(XZ),n.addCommand(HZ),n.addCommand(H0e),n.addCommand($0e),n.addCommand(rke),n.addCommand(W0e),n.addCommand(_je),n.addCommand(I0e),n.addCommand(fZ),n.addCommand(jZ),n.addCommand(K0e),n.addCommand(B0e),n.addCommand(Vwe),n.addCommand(Yje),n.addCommand($je);for(const a of F0e)n.addCommand(a);for(const a of yfe)n.addCommand(a);for(const a of xZ)n.addCommand(a);for(const a of rZ)n.addCommand(a);for(const a of qm)n.addCommand(a);for(const a of Aje)n.addCommand(a);for(const a of Xje)n.addCommand(a);for(const a of wZ)n.addCommand(a);for(const a of D0e)n.addCommand(a);for(const a of ake)n.addCommand(a);for(const a of Wje)n.addCommand(a);n.addCommand(BZ);for(const a of kje)n.addCommand(a);if(n.addPlugin(Xke(i)),bfe(process.argv.slice(2))){const{loadVisConfig:a}=await import("./CONFIG_FILES.js"),t=process.env.VIS_MONOREPO_ROOT||process.cwd();let s;try{s=await a(t)}catch{s=void 0}try{await Uwe({logger:{info:r=>{process.stdout.write(`${r}
263
+ `),n.lastGlobal=i,n.perTip[a.id]=i,Dke(n))},Hke=e=>({afterCommand:async i=>{const n=process.argv.slice(2),o=n[0]??"",a=process.exitCode===void 0||process.exitCode===0;e&&e();const t=i.workspaceRoot??process.cwd();Xke({args:n,command:o,hasDockerfile:Z(L(t,"Dockerfile")),hasDockerignore:Z(L(t,".dockerignore")),hasVercelConfig:Z(L(t,"vercel.json"))||Z(L(t,".vercel")),hasVisConfig:i.visConfig!==void 0&&Object.keys(i.visConfig).length>0,success:a}),xke({success:a,visConfig:i.visConfig}),Cke({command:o,success:a,visConfig:i.visConfig})},name:"post-command"}),Mke=e=>`MARSHALL_DISABLE_${e.replaceAll(/([A-Z])/g,"_$1").toUpperCase()}`,$l=(e,i=process.env)=>wp(i.MARSHALL_DISABLE_ALL)?!0:wp(i[Mke(e)]),RC=(e,i)=>{const n={errors:[],warnings:[]},{security:o}=e;if(!o)return n.warnings.push("No security settings configured. Use defineConfig() from '@visulima/vis/config' to get secure defaults automatically."),n;const a=o.policies??{},{installScripts:t}=a,s=t?.allow,r=s&&Object.keys(s).length>0;if(r||n.warnings.push(i==="pnpm"?"security.policies.installScripts.allow is not configured. pnpm blocks build scripts by default since v10. Run 'vis approve-builds' to review.":"security.policies.installScripts.allow is not configured. Consider listing which packages are allowed to run install/postinstall scripts."),a.firstSeen?.minutes===0&&n.warnings.push("security.policies.firstSeen.minutes is explicitly set to 0. New packages can be installed immediately after publishing."),a.publisherChange?.mode==="off"&&n.warnings.push("security.policies.publisherChange.mode is explicitly 'off'. Packages whose trust level has decreased will not be blocked."),o.blockExoticSubdeps===!1&&n.warnings.push("security.blockExoticSubdeps is explicitly disabled. Transitive dependencies can pull code from git repos or tarball URLs."),t?.strict===!1&&n.warnings.push("security.policies.installScripts.strict is explicitly disabled. Unapproved build scripts will only produce warnings, not errors."),t?.strict&&!r&&n.errors.push("security.policies.installScripts.strict is enabled but `.allow` is empty. All dependencies with build scripts will be blocked. Run 'vis approve-builds' to review and add packages."),o.acceptedRisks){const u=Date.now();for(const[d,l]of Object.entries(o.acceptedRisks)){const g=new Date(l.acceptedAt).getTime();u-g>7776e6&&n.warnings.push(`Accepted risk for "${d}" is over 90 days old (accepted ${l.acceptedAt}). Consider re-evaluating with 'vis audit'.`)}}return n},Pke=(e,i,n=!1)=>{if(ao&&!process.env.VIS_SECURITY_WARNINGS)return;const o=RC(e,i);for(const t of o.errors)x.error(t);const a=n?o.warnings.filter(t=>!t.startsWith("security.policies.installScripts.allow is not configured")):o.warnings;a.length>0&&x.warn(`${a.length} security recommendation${a.length===1?"":"s"} found. Run 'vis check --security-config' for details.`)},S1e=(e,i)=>{const n=RC(e,i),{security:o}=e;if(o){const a=o.policies??{},{firstSeen:t}=a,{publisherChange:s}=a,{installScripts:r}=a,{score:u}=a;if(x.info("Active security settings:"),x.info(` policies.firstSeen.minutes: ${t?.minutes??"not set"} minutes`),x.info(` policies.publisherChange.mode: ${s?.mode??"not set"}`),x.info(` policies.publisherChange.ignoreAfter: ${s?.ignoreAfter??"not set"} minutes`),x.info(` blockExoticSubdeps: ${o.blockExoticSubdeps??!1}`),x.info(` policies.installScripts.strict: ${r?.strict??!1}`),x.info(` policies.installScripts.allow: ${r?.allow?`${Object.keys(r.allow).length} entries`:"not configured"}`),x.info(""),x.info("Socket.dev integration:"),x.info(` socket.enabled: ${o.socket?.enabled??!1}`),x.info(` socket.apiToken: ${o.socket?.apiToken||process.env.VIS_SOCKET_TOKEN?"configured":"using public token"}`),x.info(` policies.score.minimum: ${u?.minimum??"default (0.4)"}`),x.info(` socket.cacheTtlMs: ${o.socket?.cacheTtlMs??"default (1 hour)"}`),x.info(` socket.timeoutMs: ${o.socket?.timeoutMs??"default (15s)"}`),o.acceptedRisks){const d=Object.entries(o.acceptedRisks);x.info(` acceptedRisks: ${String(d.length)} entr${d.length===1?"y":"ies"}`);for(const[l,g]of d)x.info(` ${l}: ${g.reason} (accepted ${g.acceptedAt.slice(0,10)})`)}else x.info(" acceptedRisks: none");x.info("")}if(n.errors.length===0&&n.warnings.length===0){x.info("All recommended security settings are configured.");return}for(const a of n.errors)x.error(a);for(const a of n.warnings)x.warn(a);x.notice(""),x.notice("Secure defaults are applied by defineConfig(). You only need to add install-script allowances:"),x.notice(""),x.notice(" import { defineConfig } from '@visulima/vis/config';"),x.notice(""),x.notice(" export default defineConfig({"),x.notice(" security: {"),x.notice(" policies: {"),x.notice(" installScripts: {"),x.notice(" allow: {"),x.notice(" esbuild: true,"),x.notice(" '@prisma/client': true,"),x.notice(" },"),x.notice(" },"),x.notice(" },"),x.notice(" },"),x.notice(" });")},L1e=e=>{const{security:i}=e;if(!i)return[];const n=i.policies??{},{firstSeen:o}=n,{publisherChange:a}=n,{installScripts:t}=n,s=[];return o?.minutes!==void 0&&s.push(`minimumReleaseAge: ${o.minutes}`),a?.mode&&a.mode!=="off"&&s.push(`trustPolicy: ${a.mode}`),i.blockExoticSubdeps&&s.push("blockExoticSubdeps: true"),t?.allow&&s.push(`allowBuilds: ${Object.keys(t.allow).length} entries`),t?.strict&&s.push("strictDepBuilds: true"),a?.ignoreAfter!==void 0&&s.push(`trustPolicyIgnoreAfter: ${a.ignoreAfter}`),s},OC=e=>{const i=e.trim();if(i==="")return;const n=/^(\d+(?:\.\d+)?)\s*([mhdw]?)$/i.exec(i);if(!n)return;const o=Number.parseFloat(n[1]);if(!(!Number.isFinite(o)||o<0))switch(n[2]?.toLowerCase()){case"":case"m":case void 0:return Math.round(o);case"d":return Math.round(o*1440);case"h":return Math.round(o*60);case"w":return Math.round(o*10080);default:return}},Nke=e=>e.startsWith("@")||e.includes("/")||/[:#\s]/.test(e),C1e=e=>Nke(e)?`'${e.replaceAll("'","''")}'`:e,Eke=e=>{const i=e.trim();return/^\d+$/.test(i)?Number.parseInt(i,10)*1440:OC(i)},Rke=(e,i)=>{const n={};try{switch(e){case"bun":{const o=L(i,"package.json");if(Z(o)){const t=Qe(o);Array.isArray(t.trustedDependencies)&&(n.allowBuilds=new Set(t.trustedDependencies))}const a=L(i,"bunfig.toml");if(Z(a)){const t=AY(a),s=t?.install?.minimumReleaseAge;typeof s=="number"&&(n.minReleaseAgeMinutes=Math.round(s/60)),Array.isArray(t?.install?.minimumReleaseAgeExcludes)&&(n.minReleaseAgeExcludes=new Set(t.install.minimumReleaseAgeExcludes))}break}case"npm":{const o=L(i,".npmrc");if(Z(o)){const a=z(o),t=/^\s*min-release-age\s*=\s*([^\s#;]+)/m.exec(a);t&&(n.minReleaseAgeMinutes=Eke(t[1]))}break}case"pnpm":{const o=L(i,"pnpm-workspace.yaml");if(Z(o)){const a=Ro(o);a?.allowBuilds&&typeof a.allowBuilds=="object"?n.allowBuilds=new Set(Object.entries(a.allowBuilds).filter(([,t])=>t).map(([t])=>t)):Array.isArray(a?.onlyBuiltDependencies)&&(n.allowBuilds=new Set(a.onlyBuiltDependencies)),typeof a?.minimumReleaseAge=="number"&&(n.minReleaseAgeMinutes=a.minimumReleaseAge),Array.isArray(a?.minimumReleaseAgeExclude)&&(n.minReleaseAgeExcludes=new Set(a.minimumReleaseAgeExclude))}break}case"yarn":{const o=L(i,".yarnrc.yml");if(Z(o)){const a=Ro(o),t=a?.npmMinimalAgeGate;typeof t=="string"?n.minReleaseAgeMinutes=OC(t):typeof t=="number"&&(n.minReleaseAgeMinutes=t),Array.isArray(a?.npmPreapprovedPackages)&&(n.minReleaseAgeExcludes=new Set(a.npmPreapprovedPackages))}break}}}catch{}return n},Oke=(e,i,n)=>{const o=Rke(i,n),a={hasDrift:!1,packageManager:i},t=(e.security??{}).policies??{},{installScripts:s}=t,{firstSeen:r}=t;if(s?.allow&&(i==="pnpm"||i==="bun")){const u=new Set(Object.entries(s.allow).filter(([,h])=>h).map(([h])=>h)),d=o.allowBuilds??new Set,l=[...u].filter(h=>!d.has(h)),g=[...d].filter(h=>!u.has(h));(l.length>0||g.length>0)&&(a.allowBuilds={onlyInPm:g,onlyInVis:l},a.hasDrift=!0)}if(r?.minutes!==void 0&&!(i==="yarn"&&o.minReleaseAgeMinutes===void 0&&!Z(L(n,".yarnrc.yml")))&&o.minReleaseAgeMinutes!==r.minutes&&(a.minReleaseAge={pm:o.minReleaseAgeMinutes,vis:r.minutes},a.hasDrift=!0),r?.exclude&&(i==="pnpm"||i==="bun"||i==="yarn")){const u=new Set(r.exclude),d=o.minReleaseAgeExcludes??new Set,l=[...u].filter(h=>!d.has(h)),g=[...d].filter(h=>!u.has(h));(l.length>0||g.length>0)&&(a.minReleaseAgeExcludes={onlyInPm:g,onlyInVis:l},a.hasDrift=!0)}return a},Ake=e=>{if(!e.hasDrift)return[];const i=[`vis.config and ${e.packageManager}-native config disagree on security settings:`];if(e.allowBuilds&&(e.allowBuilds.onlyInVis.length>0&&i.push(` security.policies.installScripts.allow — only in vis.config: ${e.allowBuilds.onlyInVis.join(", ")}`),e.allowBuilds.onlyInPm.length>0&&i.push(` security.policies.installScripts.allow — only in ${e.packageManager} config: ${e.allowBuilds.onlyInPm.join(", ")}`)),e.minReleaseAge){const n=e.minReleaseAge.vis===void 0?"unset":`${String(e.minReleaseAge.vis)} min`,o=e.minReleaseAge.pm===void 0?"unset":`${String(e.minReleaseAge.pm)} min`;i.push(` security.policies.firstSeen.minutes — vis.config: ${n}, ${e.packageManager}: ${o}`)}return e.minReleaseAgeExcludes&&(e.minReleaseAgeExcludes.onlyInVis.length>0&&i.push(` security.policies.firstSeen.exclude — only in vis.config: ${e.minReleaseAgeExcludes.onlyInVis.join(", ")}`),e.minReleaseAgeExcludes.onlyInPm.length>0&&i.push(` security.policies.firstSeen.exclude — only in ${e.packageManager} config: ${e.minReleaseAgeExcludes.onlyInPm.join(", ")}`)),i.push(" Run 'vis security sync' to push vis.config values to the native config."),i},Gke=e=>Z(L(e,".yarnrc.yml")),Fke=(e,i,n)=>{const o={extraArgs:[],postInstallPackages:[],scriptsBlockedByDefault:!1,warnings:[]},a=n.security?.policies?.installScripts?.allow??{},t=Object.keys(a).length>0;switch(e){case"bun":{if(o.scriptsBlockedByDefault=!0,t){const s=L(i,"package.json");try{(Z(s)?Qe(s):{}).trustedDependencies?.length||o.warnings.push("vis security.policies.installScripts.allow is configured but trustedDependencies is empty. Run 'vis approve-builds --sync-native'.")}catch{}}break}case"npm":{o.scriptsBlockedByDefault=!1;const s=L(i,".npmrc"),r=Z(s)&&/^\s*ignore-scripts\s*=\s*true\s*$/m.test(z(s));if(!r&&t?(o.warnings.push("npm does not block lifecycle scripts. vis will add --ignore-scripts automatically."),o.extraArgs.push("--ignore-scripts")):!r&&!t&&o.warnings.push("npm does not block lifecycle scripts. Add 'ignore-scripts=true' to .npmrc and configure security.policies.installScripts.allow."),t)for(const[u,d]of Object.entries(a))d&&o.postInstallPackages.push(u);break}case"pnpm":{o.scriptsBlockedByDefault=!0,t||o.warnings.push("pnpm blocks build scripts by default. Run 'vis approve-builds' to review packages that need scripts.");break}case"yarn":{if(o.scriptsBlockedByDefault=!1,Gke(i)){const s=z(L(i,".yarnrc.yml"));/^\s*enableScripts\s*:\s*false\s*$/m.test(s)?o.scriptsBlockedByDefault=!0:o.warnings.push("yarn berry supports enableScripts. Add 'enableScripts: false' to .yarnrc.yml.")}else if(o.warnings.push("yarn classic does not support blocking lifecycle scripts. Consider upgrading to yarn berry."),t){o.extraArgs.push("--ignore-scripts");for(const[s,r]of Object.entries(a))r&&o.postInstallPackages.push(s)}break}}return o},AC=(...e)=>{const i={...process.env},n=i.PATH??i.Path??"",o=e.filter(a=>a.length>0).join(mp);return i.PATH=o.length>0?n?`${o}${mp}${n}`:o:n,i},Qke=e=>{if(e.endsWith("*"))return e.endsWith("@*")?e.slice(0,-2):e;const i=e.startsWith("@"),n=e.indexOf("@",i?1:0);return n===-1?e:e.slice(0,n)},Wke=(e,i)=>{const n=L(e,"node_modules"),o=[];for(const a of i){if(!a.endsWith("*")){o.push(Qke(a));continue}const t=a.slice(0,-1);try{if(t.startsWith("@")&&t.endsWith("/")){const s=L(n,t.slice(0,-1));for(const r of Fi(s))!r.startsWith(".")&&Eo(L(s,r)).isDirectory()&&o.push(`${t.slice(0,-1)}/${r}`)}else for(const s of Fi(n))s.startsWith(t)&&Eo(L(n,s)).isDirectory()&&o.push(s)}catch{}}return o},Ike=(e,i)=>{if(i.length===0)return;const n=Wke(e,i);if(n.length===0)return;const o=L(e,"node_modules"),a=L(o,".bin");let t=!1;for(const s of n){if(s.includes("..")||s.startsWith("/")||s.startsWith("\\")){x.warn(`Skipping invalid package name: ${s}`);continue}const r=(s.match(/\//g)??[]).length;if(r>1||r===1&&!s.startsWith("@")){x.warn(`Skipping invalid package name: ${s}`);continue}const u=L(o,s),d=L(u,"package.json");if(Z(d))try{const l=Qe(d).scripts??{},g=L(u,"node_modules",".bin"),h=AC(g,a);for(const c of["preinstall","install","postinstall"])if(l[c]){x.info(`Running ${c} for ${s}...`);try{const p=l[c];zf(p,{cwd:u,env:h,stdio:"inherit"})}catch{x.error(`${c} script failed for ${s}`),t=!0}}}catch{}}t&&(process.exitCode=1)},Y1e=(e,i=["prepublish","prepare"])=>{const n=L(e,"package.json");if(!Z(n))return;let o;try{o=Qe(n).scripts??{}}catch{return}let a=!1;const t=AC(L(e,"node_modules",".bin"));for(const s of i){const r=o[s];if(r){x.info(`Running root ${s}...`);try{zf(r,{cwd:e,env:t,stdio:"inherit"})}catch{x.error(`Root ${s} script failed.`),a=!0}}}a&&(process.exitCode=1)},Zl=new Set(["add","install","update"]),_ke=new Set(["add","dedupe","install","remove","update"]),zke=/(\d+\.\d+\.\d+)/,Kke=e=>{const i=L(e,"package.json");if(!Z(i))return[];const n=[];try{const o=Qe(i),a={...o.dependencies,...o.devDependencies};for(const[t,s]of Object.entries(a)){const r=L(e,"node_modules",t,"package.json");if(Z(r))try{const d=Qe(r);if(d.version){n.push({name:t,version:d.version});continue}}catch{}const u=zke.exec(s);u?.[1]&&n.push({name:t,version:u[1]})}}catch{}return n},qke={afterCommand:async e=>{if(process.exitCode&&process.exitCode!==0)return;const i=e.scriptEnforcement;i?.postInstallPackages.length&&e.workspaceRoot&&Ike(e.workspaceRoot,i.postInstallPackages);const n=process.argv[2]??"",o=Zl.has(n)&&e.workspaceRoot?Yp(e.workspaceRoot):void 0;if(o&&e.visConfig&&e.workspaceRoot&&new Set(["bun","npm","pnpm","yarn"]).has(o.name)){const a=Oke(e.visConfig,o.name,e.workspaceRoot);if(a.hasDrift){x.info("");for(const t of Ake(a))x.warn(t)}}if(Zl.has(n)&&e.workspaceRoot){const a=new Set;$l("socket")&&a.add("socket"),$l("depsDev")&&a.add("deps-dev");const t=e.visConfig?.security?.policies?.score?.minimum,s=EY(e.visConfig?.security,{disabled:a,minimumScore:t});if(s.length>0)try{const r=Kke(e.workspaceRoot);if(r.length>0){const u=await RY(s,r);if(u.size>0){const d=mY(u,t);if(d){x.info(""),x.info(d);let l=0;for(const g of u.values())for(const h of g.alerts)(h.severity==="critical"||h.severity==="high")&&l++;l>0&&x.warn(`${String(l)} critical/high severity alert${l===1?"":"s"} detected. Run 'vis check --security' for details.`)}}}}catch{}}},beforeCommand:async e=>{const i=process.argv[2]??"";if(_ke.has(i)&&e.visConfig&&e.workspaceRoot){const n=Yp(e.workspaceRoot),o=Zl.has(i);if(Pke(e.visConfig,n.name,o),o&&!$l("installScripts")){const a=Fke(n.name,e.workspaceRoot,e.visConfig);for(const t of a.warnings)e.logger.warn(`security: ${t}`);e.scriptEnforcement=a}}},name:"security-enforcement"},Uke=e=>{for(let i=0;i<e.length;i+=1){const n=e[i];if(n==="--ca-cert"){const o=e[i+1];return o===void 0||o.startsWith("-")?void 0:Cr(o)}if(n.startsWith("--ca-cert=")){const o=n.slice(10);return o===""?void 0:Cr(o)}}},Vke=()=>process.platform==="win32"?!!process.env.WT_SESSION||process.env.TERM_PROGRAM==="vscode"||process.env.TERM==="xterm-256color":process.env.TERM!=="linux",Et=Vke(),eSe={arrow:Et?"→":"->",dash:Et?"—":"-",failure:Et?"✗":"x",success:Et?"✓":"v",warning:Et?"⚠":"!"},Wg=L(mo(),"upgrade-check.json"),iSe=1440*60*1e3,nSe=1440*60*1e3,oSe=500,aSe=new Set(["--help","--version","-h","-V","help","implode","upgrade"]),tSe=()=>{try{if(Z(Wg))return Qe(Wg)}catch{}},GC=e=>{try{vo(mo()),ui(Wg,JSON.stringify(e))}catch{}},sSe=async e=>{try{const i=new AbortController,n=setTimeout(()=>{i.abort()},oSe),o=await fetch(`https://registry.npmjs.org/${e}/latest`,{headers:{accept:"application/json"},signal:i.signal});return clearTimeout(n),o.ok?(await o.json()).version:void 0}catch{return}},Af=(e,i)=>{let n;try{n=Tl.gt(i.latestVersion,e,{loose:!0})}catch{return}if(!n)return;const o=Date.now();o-i.lastNoticeAt<nSe||(process.stderr.write(`
264
+ ${Ca("vis update available:")} ${Rt(e)} ${Ca(eSe.arrow)} ${$Y(pn(i.latestVersion))}${Ca(", run")} ${eo("vis upgrade")}
265
+ `),i.lastNoticeAt=o,GC(i))},rSe=e=>{if(ao||process.env.VIS_CLI_TEST||process.env.VIS_NO_UPDATE_CHECK==="1"||!process.stderr.isTTY||aSe.has(e))return!1;const i=new Set(process.argv.slice(2));return!(i.has("--silent")||i.has("-s")||i.has("--json"))},uSe=(e,i)=>{if(!rSe(i))return;const n=tSe(),o=Date.now();if(n&&o-n.lastQueryAt<iSe)return()=>{Af(e,n)};let a=n;return sSe("@visulima/vis").then(t=>{t&&(a={lastNoticeAt:n?.lastNoticeAt??0,lastQueryAt:o,latestVersion:t},GC(a))}).catch(()=>{}),()=>{a&&Af(e,a)}},dSe=async()=>{const e=Uke(process.argv);e!==void 0&&!process.env.NODE_EXTRA_CA_CERTS&&(process.env.NODE_EXTRA_CA_CERTS=e);try{const a=lm(process.cwd()).path;process.env.VIS_MONOREPO_ROOT=a;const t=Qe(L(a,"package.json"));t.name&&GY(t.name)}catch{}const i=uSe(Lr.version,process.argv[2]??""),n=IC("vis",{packageName:"vis",packageVersion:Lr.version}),o=process.argv.includes("--debug")||!!process.env.DEBUG;n.addPlugin(_C({detailed:o,exitOnError:!1})),n.addGlobalOption({description:"Override workspace root directory",name:"cwd",type:String}),n.addGlobalOption({description:"Target JS runtime: node (default) or bun. Overrides VIS_RUNTIME and config; falls back to lockfile detection.",name:"runtime",type:String}),n.addGlobalOption({description:"Path to a vis config file (overrides discovery)",name:"config",type:String}),n.addGlobalOption({description:"Path to a CA bundle (PEM) to trust for HTTPS — for corporate proxies. Equivalent to NODE_EXTRA_CA_CERTS.",name:"ca-cert",type:String}),n.addPlugin(gke),n.addPlugin(qke),n.addCommand(Yje),n.addCommand(DZ),n.addCommand(M0e),n.addCommand(eZ),n.addCommand(uZ),n.addCommand(Vje),n.addCommand(Cje),n.addCommand(Q0e),n.addCommand(rke),n.addCommand(TZ),n.addCommand(Y0e),n.addCommand(yZ),n.addCommand(_je),n.addCommand(Kje),n.addCommand(qje),n.addCommand(L0e),n.addCommand(Uje),n.addCommand(efe),n.addCommand(UY),n.addCommand(VY),n.addCommand(V0e),n.addCommand(X0e),n.addCommand(q0e),n.addCommand(iZ),n.addCommand(Lje),n.addCommand(C0e),n.addCommand(dke),n.addCommand(_0e),n.addCommand(U0e),n.addCommand(ske),n.addCommand(zC),n.addCommand(OY),n.addCommand(lke),n.addCommand(eje),n.addCommand(z0e),n.addCommand(XZ),n.addCommand(HZ),n.addCommand(H0e),n.addCommand($0e),n.addCommand(uke),n.addCommand(W0e),n.addCommand(zje),n.addCommand(I0e),n.addCommand(fZ),n.addCommand(jZ),n.addCommand(K0e),n.addCommand(B0e),n.addCommand(Vwe),n.addCommand($je),n.addCommand(Zje);for(const a of F0e)n.addCommand(a);for(const a of yfe)n.addCommand(a);for(const a of xZ)n.addCommand(a);for(const a of rZ)n.addCommand(a);for(const a of qm)n.addCommand(a);for(const a of Gje)n.addCommand(a);for(const a of Hje)n.addCommand(a);for(const a of wZ)n.addCommand(a);for(const a of D0e)n.addCommand(a);for(const a of tke)n.addCommand(a);for(const a of Ije)n.addCommand(a);n.addCommand(BZ);for(const a of Sje)n.addCommand(a);if(n.addPlugin(Hke(i)),bfe(process.argv.slice(2))){const{loadVisConfig:a}=await import("./CONFIG_FILES.js"),t=process.env.VIS_MONOREPO_ROOT||process.cwd();let s;try{s=await a(t)}catch{s=void 0}try{await Uwe({logger:{info:r=>{process.stdout.write(`${r}
266
266
  `)},warn:r=>{process.stderr.write(`${r}
267
267
  `)}},visConfig:s,workspaceRoot:t})}catch(r){process.stderr.write(`${r.message}
268
- `),process.exitCode=1}return}await KC(n)},YSe=Object.defineProperty({__proto__:null,runCli:u1e},Symbol.toStringTag,{value:"Module"});export{lC as $,Wke as A,K1e as B,Sf as C,Z1e as D,Cf as E,Ef as F,Mi as G,Hf as H,F1e as I,Q1e as J,W1e as K,Xf as L,I1e as M,_1e as N,z1e as O,s$ as P,QL as Q,CSe as R,Vke as S,VL as T,eC as U,Mg as V,jf as W,Kp as X,Df as Y,od as Z,UL as _,LSe as a,hp as a0,mSe as a1,bSe as a2,wSe as a3,jSe as a4,Hb as a5,GL as a6,dSe as a7,mme as a8,rme as a9,vSe as aa,cSe as ab,gSe as ac,Sl as ad,hSe as ae,lSe as af,cme as ag,ap as ah,jme as ai,ySe as aj,$1e as ak,T1e as al,uSe as am,sSe as an,ns as ao,rSe as ap,i4 as aq,Ly as ar,x1e as as,YSe as at,l0e as b,Xg as c,qye as d,Kye as e,ZL as f,fSe as g,Rke as h,$l as i,we as j,SSe as k,tSe as l,zwe as m,Ake as n,_we as o,x as p,Kwe as q,YL as r,kf as s,Zf as t,Rf as u,Oke as v,kSe as w,Bf as x,tp as y,Jf as z};
268
+ `),process.exitCode=1}return}await KC(n)},$1e=Object.defineProperty({__proto__:null,runCli:dSe},Symbol.toStringTag,{value:"Module"});export{lC as $,Ike as A,qSe as B,Sf as C,JSe as D,Cf as E,Ef as F,Mi as G,Hf as H,QSe as I,WSe as J,ISe as K,Xf as L,_Se as M,zSe as N,KSe as O,s$ as P,QL as Q,Y1e as R,eSe as S,VL as T,eC as U,Mg as V,jf as W,Kp as X,Df as Y,od as Z,UL as _,C1e as a,hp as a0,b1e as a1,w1e as a2,j1e as a3,k1e as a4,Hb as a5,GL as a6,l1e as a7,mme as a8,rme as a9,y1e as aa,p1e as ab,h1e as ac,Sl as ad,c1e as ae,g1e as af,cme as ag,ap as ah,jme as ai,f1e as aj,ZSe as ak,DSe as al,d1e as am,r1e as an,ns as ao,u1e as ap,i4 as aq,Ly as ar,TSe as as,$1e as at,l0e as b,Xg as c,qye as d,Kye as e,ZL as f,m1e as g,Oke as h,$l as i,we as j,L1e as k,s1e as l,zwe as m,Gke as n,_we as o,x as p,Kwe as q,YL as r,kf as s,Zf as t,Rf as u,Ake as v,S1e as w,Bf as x,tp as y,Jf as z};