@ignix-social/editor 0.1.0

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 (586) hide show
  1. package/LICENSE +190 -0
  2. package/NOTICE +54 -0
  3. package/README.md +23 -0
  4. package/bin/ignix-editor.mjs +8 -0
  5. package/package.json +53 -0
  6. package/patches/index.mjs +53 -0
  7. package/scripts/build-ffmpeg-macos.sh +35 -0
  8. package/scripts/build-whisper-macos.sh +21 -0
  9. package/scripts/vendor.mjs +41 -0
  10. package/skills/ignix-editor/SKILL.md +132 -0
  11. package/src/audio.mjs +31 -0
  12. package/src/binaries.json +46 -0
  13. package/src/binaries.mjs +83 -0
  14. package/src/cli.mjs +254 -0
  15. package/src/prepare.mjs +74 -0
  16. package/src/runtime/ignix-frame.js +92 -0
  17. package/src/transcribe.mjs +71 -0
  18. package/src/validate.mjs +71 -0
  19. package/templates/blank/index.html +41 -0
  20. package/vendor/hyperframes/README.md +181 -0
  21. package/vendor/hyperframes/UPSTREAM.json +12 -0
  22. package/vendor/hyperframes/bin/hyperframes-localize-fonts.mjs +12 -0
  23. package/vendor/hyperframes/bin/hyperframes.mjs +11 -0
  24. package/vendor/hyperframes/dist/add-LR3ZR2A5.js +79 -0
  25. package/vendor/hyperframes/dist/agentPromptGenerator-VIIPZCJ3.js +143 -0
  26. package/vendor/hyperframes/dist/animatedGifPrep-P2T6YM7Z.js +34 -0
  27. package/vendor/hyperframes/dist/asset-BE2DOV72.js +26 -0
  28. package/vendor/hyperframes/dist/assetCataloger-VBLPHX24.js +340 -0
  29. package/vendor/hyperframes/dist/auth-RCQB2ZT7.js +60 -0
  30. package/vendor/hyperframes/dist/autoUpdate-RJAX3DAZ.js +268 -0
  31. package/vendor/hyperframes/dist/backgroundChecks-H2LCUIMJ.js +61 -0
  32. package/vendor/hyperframes/dist/backgroundChecksWorker.js +26 -0
  33. package/vendor/hyperframes/dist/batchRender-FT7AP7XH.js +355 -0
  34. package/vendor/hyperframes/dist/beat-analyzer.global.js +338 -0
  35. package/vendor/hyperframes/dist/beats-Y2EOP72P.js +309 -0
  36. package/vendor/hyperframes/dist/benchmark-MZ7GY3JW.js +231 -0
  37. package/vendor/hyperframes/dist/browser-HUTAMRQE.js +237 -0
  38. package/vendor/hyperframes/dist/bundleWithLocalizedFonts-5QOPOB5D.js +52 -0
  39. package/vendor/hyperframes/dist/capture-RLZA6EMR.js +4079 -0
  40. package/vendor/hyperframes/dist/capture-SZZ4IYJK.js +290 -0
  41. package/vendor/hyperframes/dist/captureFile-LYOJOUIE.js +15 -0
  42. package/vendor/hyperframes/dist/captureTimeout-PA4FYWT5.js +27 -0
  43. package/vendor/hyperframes/dist/catalog-KYU55EWR.js +1001 -0
  44. package/vendor/hyperframes/dist/check-TCG4PXLR.js +1697 -0
  45. package/vendor/hyperframes/dist/checkBrowser-RPMO4OW5.js +1032 -0
  46. package/vendor/hyperframes/dist/chunk-2EAXUCCE.js +88 -0
  47. package/vendor/hyperframes/dist/chunk-2EGFTPWD.js +1077 -0
  48. package/vendor/hyperframes/dist/chunk-2PSPARWP.js +6058 -0
  49. package/vendor/hyperframes/dist/chunk-2YN64IN5.js +5747 -0
  50. package/vendor/hyperframes/dist/chunk-3GXQPCJC.js +682 -0
  51. package/vendor/hyperframes/dist/chunk-3ZP5DXE7.js +15 -0
  52. package/vendor/hyperframes/dist/chunk-4NWOGZZS.js +1990 -0
  53. package/vendor/hyperframes/dist/chunk-4PFZPP2N.js +587 -0
  54. package/vendor/hyperframes/dist/chunk-4THIAPBL.js +128 -0
  55. package/vendor/hyperframes/dist/chunk-4YYJOFKS.js +28 -0
  56. package/vendor/hyperframes/dist/chunk-54HJ63Q2.js +29 -0
  57. package/vendor/hyperframes/dist/chunk-5ETJX6WM.js +89 -0
  58. package/vendor/hyperframes/dist/chunk-5IAKAQA7.js +389 -0
  59. package/vendor/hyperframes/dist/chunk-5Z63TBTX.js +37 -0
  60. package/vendor/hyperframes/dist/chunk-6BEFEWFB.js +25 -0
  61. package/vendor/hyperframes/dist/chunk-6CSYCFQV.js +68 -0
  62. package/vendor/hyperframes/dist/chunk-6CTIGJY7.js +154 -0
  63. package/vendor/hyperframes/dist/chunk-7HG4BFIN.js +93 -0
  64. package/vendor/hyperframes/dist/chunk-7JZ4FXP2.js +118 -0
  65. package/vendor/hyperframes/dist/chunk-A2Z4Z4VL.js +2961 -0
  66. package/vendor/hyperframes/dist/chunk-AMKC3AXA.js +25 -0
  67. package/vendor/hyperframes/dist/chunk-AVUUN2XD.js +4847 -0
  68. package/vendor/hyperframes/dist/chunk-AWDFDFI3.js +46 -0
  69. package/vendor/hyperframes/dist/chunk-AWNBM3MZ.js +94 -0
  70. package/vendor/hyperframes/dist/chunk-BXCMXMJQ.js +73 -0
  71. package/vendor/hyperframes/dist/chunk-BZ56MTDX.js +6 -0
  72. package/vendor/hyperframes/dist/chunk-CFKU7HTK.js +171 -0
  73. package/vendor/hyperframes/dist/chunk-CWPVM2QV.js +308 -0
  74. package/vendor/hyperframes/dist/chunk-DPVXBVLL.js +31292 -0
  75. package/vendor/hyperframes/dist/chunk-DQBY7FRR.js +397 -0
  76. package/vendor/hyperframes/dist/chunk-E6RPWJVC.js +213 -0
  77. package/vendor/hyperframes/dist/chunk-EISRN4E6.js +294 -0
  78. package/vendor/hyperframes/dist/chunk-EOVYQ3IG.js +143 -0
  79. package/vendor/hyperframes/dist/chunk-F3WZGU7C.js +479 -0
  80. package/vendor/hyperframes/dist/chunk-FCSIGXXP.js +366 -0
  81. package/vendor/hyperframes/dist/chunk-FI4I7CME.js +56 -0
  82. package/vendor/hyperframes/dist/chunk-FLWXXDNS.js +15 -0
  83. package/vendor/hyperframes/dist/chunk-GK4AIFIH.js +11171 -0
  84. package/vendor/hyperframes/dist/chunk-GMECXFAN.js +57 -0
  85. package/vendor/hyperframes/dist/chunk-GULOKZLI.js +155 -0
  86. package/vendor/hyperframes/dist/chunk-H4YZZ2VQ.js +68 -0
  87. package/vendor/hyperframes/dist/chunk-H6QMKUYA.js +477 -0
  88. package/vendor/hyperframes/dist/chunk-HBBJFK6I.js +273 -0
  89. package/vendor/hyperframes/dist/chunk-HRUGC23L.js +212 -0
  90. package/vendor/hyperframes/dist/chunk-HVW7ABXD.js +19 -0
  91. package/vendor/hyperframes/dist/chunk-HW6OYASV.js +344 -0
  92. package/vendor/hyperframes/dist/chunk-HWKCIWQT.js +3578 -0
  93. package/vendor/hyperframes/dist/chunk-I465DBM6.js +1214 -0
  94. package/vendor/hyperframes/dist/chunk-IGLEPPTN.js +24 -0
  95. package/vendor/hyperframes/dist/chunk-IGNAAHS3.js +433 -0
  96. package/vendor/hyperframes/dist/chunk-IHFUKJOR.js +85 -0
  97. package/vendor/hyperframes/dist/chunk-IQ3OUQ5Z.js +213 -0
  98. package/vendor/hyperframes/dist/chunk-ISN5GRYI.js +20 -0
  99. package/vendor/hyperframes/dist/chunk-IUZFXWSV.js +446 -0
  100. package/vendor/hyperframes/dist/chunk-JH556Q42.js +647 -0
  101. package/vendor/hyperframes/dist/chunk-JTHMTOMQ.js +601 -0
  102. package/vendor/hyperframes/dist/chunk-K2EQN4VU.js +405 -0
  103. package/vendor/hyperframes/dist/chunk-K2FTXJYH.js +16044 -0
  104. package/vendor/hyperframes/dist/chunk-K4WIOZFP.js +32 -0
  105. package/vendor/hyperframes/dist/chunk-K4WKGXRC.js +18 -0
  106. package/vendor/hyperframes/dist/chunk-KBJUXVOJ.js +172 -0
  107. package/vendor/hyperframes/dist/chunk-KC5XXX3X.js +590 -0
  108. package/vendor/hyperframes/dist/chunk-KNU5COPB.js +29 -0
  109. package/vendor/hyperframes/dist/chunk-KZI44OPA.js +185 -0
  110. package/vendor/hyperframes/dist/chunk-L3YOGIPG.js +48 -0
  111. package/vendor/hyperframes/dist/chunk-LAOCA3MQ.js +189 -0
  112. package/vendor/hyperframes/dist/chunk-LCSMOLGX.js +312 -0
  113. package/vendor/hyperframes/dist/chunk-LFGJWOVA.js +61 -0
  114. package/vendor/hyperframes/dist/chunk-LHSR3M4M.js +498 -0
  115. package/vendor/hyperframes/dist/chunk-LYNI3FOL.js +123 -0
  116. package/vendor/hyperframes/dist/chunk-M2WBOQ2Q.js +54 -0
  117. package/vendor/hyperframes/dist/chunk-MRF4AMKD.js +104 -0
  118. package/vendor/hyperframes/dist/chunk-MWB3ZIFM.js +852 -0
  119. package/vendor/hyperframes/dist/chunk-NGKM64BP.js +39 -0
  120. package/vendor/hyperframes/dist/chunk-NXMYHJAL.js +43 -0
  121. package/vendor/hyperframes/dist/chunk-OAF4XJOW.js +192 -0
  122. package/vendor/hyperframes/dist/chunk-OFQWTKPW.js +117 -0
  123. package/vendor/hyperframes/dist/chunk-P6LJ4Y32.js +4662 -0
  124. package/vendor/hyperframes/dist/chunk-PBN6GBJE.js +108 -0
  125. package/vendor/hyperframes/dist/chunk-PDAMK4Q5.js +28 -0
  126. package/vendor/hyperframes/dist/chunk-PFCFR3KZ.js +20 -0
  127. package/vendor/hyperframes/dist/chunk-PJ3HDUCY.js +108 -0
  128. package/vendor/hyperframes/dist/chunk-PMRBLBUP.js +152 -0
  129. package/vendor/hyperframes/dist/chunk-PPQUYWTW.js +240 -0
  130. package/vendor/hyperframes/dist/chunk-Q5X2B5WT.js +29 -0
  131. package/vendor/hyperframes/dist/chunk-Q7IU7MOR.js +351 -0
  132. package/vendor/hyperframes/dist/chunk-QC4FJVLM.js +371 -0
  133. package/vendor/hyperframes/dist/chunk-QNYYOUU3.js +1318 -0
  134. package/vendor/hyperframes/dist/chunk-RDNNAKEP.js +161 -0
  135. package/vendor/hyperframes/dist/chunk-RMHUQGRK.js +657 -0
  136. package/vendor/hyperframes/dist/chunk-RQVDTPGD.js +6 -0
  137. package/vendor/hyperframes/dist/chunk-RVCWIIZ7.js +68 -0
  138. package/vendor/hyperframes/dist/chunk-S3D6GE5W.js +72 -0
  139. package/vendor/hyperframes/dist/chunk-S3S4TGEH.js +424 -0
  140. package/vendor/hyperframes/dist/chunk-S7NPLFWV.js +11395 -0
  141. package/vendor/hyperframes/dist/chunk-SHB5VDMH.js +51 -0
  142. package/vendor/hyperframes/dist/chunk-TCLGPL65.js +860 -0
  143. package/vendor/hyperframes/dist/chunk-THXFSPLV.js +40 -0
  144. package/vendor/hyperframes/dist/chunk-TJSTGSAW.js +354 -0
  145. package/vendor/hyperframes/dist/chunk-TQFG7HTI.js +1024 -0
  146. package/vendor/hyperframes/dist/chunk-TVCRUG2S.js +265 -0
  147. package/vendor/hyperframes/dist/chunk-TWWSYAKJ.js +24 -0
  148. package/vendor/hyperframes/dist/chunk-U7CZBDMV.js +27 -0
  149. package/vendor/hyperframes/dist/chunk-UEZXMWG3.js +139 -0
  150. package/vendor/hyperframes/dist/chunk-UYEZTK4U.js +61 -0
  151. package/vendor/hyperframes/dist/chunk-VC76R6W2.js +27 -0
  152. package/vendor/hyperframes/dist/chunk-VFCKXTBB.js +159 -0
  153. package/vendor/hyperframes/dist/chunk-VWG7OQKU.js +22 -0
  154. package/vendor/hyperframes/dist/chunk-VXVRPIJA.js +105 -0
  155. package/vendor/hyperframes/dist/chunk-WBLXWOYK.js +15 -0
  156. package/vendor/hyperframes/dist/chunk-WERLJGIC.js +20 -0
  157. package/vendor/hyperframes/dist/chunk-WMQNIQDJ.js +2057 -0
  158. package/vendor/hyperframes/dist/chunk-WPHMNO44.js +4528 -0
  159. package/vendor/hyperframes/dist/chunk-X5HWXQPU.js +113 -0
  160. package/vendor/hyperframes/dist/chunk-X7MTZ4T2.js +6 -0
  161. package/vendor/hyperframes/dist/chunk-XH4DSOS5.js +59 -0
  162. package/vendor/hyperframes/dist/chunk-XS4EJSKU.js +23 -0
  163. package/vendor/hyperframes/dist/chunk-XT5P4QMO.js +181 -0
  164. package/vendor/hyperframes/dist/chunk-XT7X6QCP.js +6 -0
  165. package/vendor/hyperframes/dist/chunk-XUHOIDKG.js +6 -0
  166. package/vendor/hyperframes/dist/chunk-XUXGIA7H.js +485 -0
  167. package/vendor/hyperframes/dist/chunk-XZABUQTX.js +113 -0
  168. package/vendor/hyperframes/dist/chunk-Y6W4DVPS.js +356 -0
  169. package/vendor/hyperframes/dist/chunk-YEIFI443.js +44 -0
  170. package/vendor/hyperframes/dist/chunk-YQZNILVH.js +375 -0
  171. package/vendor/hyperframes/dist/chunk-Z27A7NUB.js +65 -0
  172. package/vendor/hyperframes/dist/chunk-Z6B37SNM.js +3081 -0
  173. package/vendor/hyperframes/dist/chunk-ZJUKFZ2P.js +10954 -0
  174. package/vendor/hyperframes/dist/chunk-ZKDMAOFU.js +32 -0
  175. package/vendor/hyperframes/dist/chunk-ZMXUQLI2.js +17219 -0
  176. package/vendor/hyperframes/dist/chunk-ZTZ7NCJT.js +58 -0
  177. package/vendor/hyperframes/dist/chunk-ZTZA4UWZ.js +108 -0
  178. package/vendor/hyperframes/dist/clean-W57E5YQ3.js +293 -0
  179. package/vendor/hyperframes/dist/cli.js +495 -0
  180. package/vendor/hyperframes/dist/cloud-FFTJGZ24.js +70 -0
  181. package/vendor/hyperframes/dist/cloudrun-AJUTHUEA.js +763 -0
  182. package/vendor/hyperframes/dist/colors-HKWSZCGK.js +15 -0
  183. package/vendor/hyperframes/dist/commands/contrast-audit.browser.js +459 -0
  184. package/vendor/hyperframes/dist/commands/layout-audit.browser.js +2102 -0
  185. package/vendor/hyperframes/dist/commands/motion-sample.browser.js +74 -0
  186. package/vendor/hyperframes/dist/commands/motion-signature.browser.js +374 -0
  187. package/vendor/hyperframes/dist/compare-AYCTT55F.js +421 -0
  188. package/vendor/hyperframes/dist/compiler-QO36EXLS.js +121 -0
  189. package/vendor/hyperframes/dist/component-VFFR2O7T.js +176 -0
  190. package/vendor/hyperframes/dist/compositions-QTVN3U2A.js +228 -0
  191. package/vendor/hyperframes/dist/contactSheet-27SRU7A4.js +22 -0
  192. package/vendor/hyperframes/dist/delete-ZAKYCB7I.js +114 -0
  193. package/vendor/hyperframes/dist/deploy-MX76RZ36.js +101 -0
  194. package/vendor/hyperframes/dist/destroy-H2TZBYHH.js +42 -0
  195. package/vendor/hyperframes/dist/deterministicFonts-HAEMV4TM.js +50 -0
  196. package/vendor/hyperframes/dist/dist-EWXJGN63.js +129 -0
  197. package/vendor/hyperframes/dist/dist-FNNGCKFS.js +29 -0
  198. package/vendor/hyperframes/dist/dist-S3PJNPXQ.js +392 -0
  199. package/vendor/hyperframes/dist/docker/Dockerfile.render +65 -0
  200. package/vendor/hyperframes/dist/docs/compositions.md +67 -0
  201. package/vendor/hyperframes/dist/docs/data-attributes.md +27 -0
  202. package/vendor/hyperframes/dist/docs/examples.md +19 -0
  203. package/vendor/hyperframes/dist/docs/gsap.md +26 -0
  204. package/vendor/hyperframes/dist/docs/rendering.md +35 -0
  205. package/vendor/hyperframes/dist/docs/troubleshooting.md +29 -0
  206. package/vendor/hyperframes/dist/docs-QAPJEGLS.js +131 -0
  207. package/vendor/hyperframes/dist/doctor-AI7C3FON.js +67 -0
  208. package/vendor/hyperframes/dist/dom-IROKGVJI.js +14 -0
  209. package/vendor/hyperframes/dist/dotEnv-AECLXQSO.js +14 -0
  210. package/vendor/hyperframes/dist/events-7LALYNKZ.js +92 -0
  211. package/vendor/hyperframes/dist/events-FQY3HGKZ.js +88 -0
  212. package/vendor/hyperframes/dist/feedback-WCMDMSTK.js +472 -0
  213. package/vendor/hyperframes/dist/ffmpeg-QIUFEFTY.js +35 -0
  214. package/vendor/hyperframes/dist/figma-64WY462P.js +63 -0
  215. package/vendor/hyperframes/dist/fontData.generated-NXAOI4GH.js +13 -0
  216. package/vendor/hyperframes/dist/fontLocalizeCli.js +132 -0
  217. package/vendor/hyperframes/dist/get-FPOMJMZB.js +103 -0
  218. package/vendor/hyperframes/dist/gpuPolicy-2ZUZE5D6.js +38 -0
  219. package/vendor/hyperframes/dist/grade-compare-E2CKPST4.js +647 -0
  220. package/vendor/hyperframes/dist/gsapParser-DIYYX6JT.js +2846 -0
  221. package/vendor/hyperframes/dist/gsapParserAcorn-E3GEIRZB.js +28 -0
  222. package/vendor/hyperframes/dist/help-YRQIDDML.js +197 -0
  223. package/vendor/hyperframes/dist/history-PP5NDRV3.js +571 -0
  224. package/vendor/hyperframes/dist/hyperframe-runtime.js +1081 -0
  225. package/vendor/hyperframes/dist/hyperframe.manifest.json +22 -0
  226. package/vendor/hyperframes/dist/hyperframe.runtime.iife.js +1081 -0
  227. package/vendor/hyperframes/dist/hyperframes-player.global.js +474 -0
  228. package/vendor/hyperframes/dist/hyperframes-slideshow.global.js +149 -0
  229. package/vendor/hyperframes/dist/info-SEX3B7JL.js +153 -0
  230. package/vendor/hyperframes/dist/init-U3AKHO5B.js +1147 -0
  231. package/vendor/hyperframes/dist/inspect-Q3K6EDEK.js +97 -0
  232. package/vendor/hyperframes/dist/installer-K6O5WF44.js +37 -0
  233. package/vendor/hyperframes/dist/keyframes-DC64JCI3.js +2602 -0
  234. package/vendor/hyperframes/dist/lambda-D7UMN4DJ.js +451 -0
  235. package/vendor/hyperframes/dist/layout-XSPPDHOO.js +86 -0
  236. package/vendor/hyperframes/dist/lib-TPG2ZMAX.js +128 -0
  237. package/vendor/hyperframes/dist/lint-7DQZE7L3.js +164 -0
  238. package/vendor/hyperframes/dist/lintProject-OHBBM3DJ.js +27 -0
  239. package/vendor/hyperframes/dist/list-4K5MVDQX.js +162 -0
  240. package/vendor/hyperframes/dist/login-NTX4OWXL.js +377 -0
  241. package/vendor/hyperframes/dist/logout-Q654A3SI.js +100 -0
  242. package/vendor/hyperframes/dist/manager-67P2XFXQ.js +34 -0
  243. package/vendor/hyperframes/dist/manager-CT3D67CG.js +38 -0
  244. package/vendor/hyperframes/dist/manager-GFN75DM4.js +30 -0
  245. package/vendor/hyperframes/dist/media-treatment-5FYAOPNL.js +972 -0
  246. package/vendor/hyperframes/dist/media-use-4XXGABIL.js +113 -0
  247. package/vendor/hyperframes/dist/models-C4E4IWJD.js +137 -0
  248. package/vendor/hyperframes/dist/motionShot-S4MIGMT5.js +614 -0
  249. package/vendor/hyperframes/dist/normalize-O76AC4HE.js +333 -0
  250. package/vendor/hyperframes/dist/normalize-audio-CSFTXLXD.js +276 -0
  251. package/vendor/hyperframes/dist/open-2ZD6BHZG.js +115 -0
  252. package/vendor/hyperframes/dist/pipeline-TNGWUZQC.js +54 -0
  253. package/vendor/hyperframes/dist/play-CTMUXX6E.js +349 -0
  254. package/vendor/hyperframes/dist/policies-FSDZVS2E.js +292 -0
  255. package/vendor/hyperframes/dist/preflight-SMNV6RW2.js +45 -0
  256. package/vendor/hyperframes/dist/present-WQVHV5CR.js +350 -0
  257. package/vendor/hyperframes/dist/preview-JOJXTH75.js +1820 -0
  258. package/vendor/hyperframes/dist/producer-ECLEN5RP.js +13 -0
  259. package/vendor/hyperframes/dist/progress-FBIEEB7Y.js +73 -0
  260. package/vendor/hyperframes/dist/projectConfig-HYJMJ5BY.js +56 -0
  261. package/vendor/hyperframes/dist/publication-HQ5Y3KBM.js +29 -0
  262. package/vendor/hyperframes/dist/publish-VHDYQASC.js +430 -0
  263. package/vendor/hyperframes/dist/refresh-K24ETHMA.js +53 -0
  264. package/vendor/hyperframes/dist/remove-background-W2YX2NVH.js +253 -0
  265. package/vendor/hyperframes/dist/render-AO5VX3YI.js +177 -0
  266. package/vendor/hyperframes/dist/render-LNO62LEL.js +2367 -0
  267. package/vendor/hyperframes/dist/render-TTQI7TGN.js +796 -0
  268. package/vendor/hyperframes/dist/render-batch-YH7CTWNY.js +284 -0
  269. package/vendor/hyperframes/dist/renderCancellation-JPIHE47X.js +35 -0
  270. package/vendor/hyperframes/dist/renderSetupWorker.js +79 -0
  271. package/vendor/hyperframes/dist/resolver-IZ647GBZ.js +38 -0
  272. package/vendor/hyperframes/dist/runtimeVersion.js +18 -0
  273. package/vendor/hyperframes/dist/screenshotCapture-ECBTLCU6.js +179 -0
  274. package/vendor/hyperframes/dist/shaderTransitionWorker.js +44 -0
  275. package/vendor/hyperframes/dist/sherpa-KKLNW6U2.js +314 -0
  276. package/vendor/hyperframes/dist/sherpaWorker.js +77 -0
  277. package/vendor/hyperframes/dist/sites-TNVKZS73.js +52 -0
  278. package/vendor/hyperframes/dist/skill-ZHVLH7KX.js +15 -0
  279. package/vendor/hyperframes/dist/skills/hyperframes/SKILL.md +152 -0
  280. package/vendor/hyperframes/dist/skills/hyperframes/references/brief-contract.md +108 -0
  281. package/vendor/hyperframes/dist/skills/hyperframes/references/brief-format.md +72 -0
  282. package/vendor/hyperframes/dist/skills/hyperframes/references/capability-menu.md +47 -0
  283. package/vendor/hyperframes/dist/skills/hyperframes/references/frame-worker-core.md +80 -0
  284. package/vendor/hyperframes/dist/skills/hyperframes/references/intent-interview.md +73 -0
  285. package/vendor/hyperframes/dist/skills/hyperframes/references/pitch-round.md +40 -0
  286. package/vendor/hyperframes/dist/skills/hyperframes/references/plugin-installation.md +43 -0
  287. package/vendor/hyperframes/dist/skills/hyperframes/references/production-loop.md +26 -0
  288. package/vendor/hyperframes/dist/skills/hyperframes/references/review-loop.md +37 -0
  289. package/vendor/hyperframes/dist/skills/hyperframes/references/route-briefs.md +11 -0
  290. package/vendor/hyperframes/dist/skills/hyperframes/references/routes/embedded-captions.md +11 -0
  291. package/vendor/hyperframes/dist/skills/hyperframes/references/routes/faceless-explainer.md +12 -0
  292. package/vendor/hyperframes/dist/skills/hyperframes/references/routes/general-video.md +12 -0
  293. package/vendor/hyperframes/dist/skills/hyperframes/references/routes/motion-graphics.md +11 -0
  294. package/vendor/hyperframes/dist/skills/hyperframes/references/routes/music-to-video.md +12 -0
  295. package/vendor/hyperframes/dist/skills/hyperframes/references/routes/pr-to-video.md +28 -0
  296. package/vendor/hyperframes/dist/skills/hyperframes/references/routes/product-launch-video.md +13 -0
  297. package/vendor/hyperframes/dist/skills/hyperframes/references/routes/remotion-to-hyperframes.md +9 -0
  298. package/vendor/hyperframes/dist/skills/hyperframes/references/routes/slideshow.md +11 -0
  299. package/vendor/hyperframes/dist/skills/hyperframes/references/routes/talking-head-recut.md +11 -0
  300. package/vendor/hyperframes/dist/skills/hyperframes/references/script-format.md +52 -0
  301. package/vendor/hyperframes/dist/skills/hyperframes/references/skill-lifecycle.md +35 -0
  302. package/vendor/hyperframes/dist/skills/hyperframes/references/storyboard-format.md +99 -0
  303. package/vendor/hyperframes/dist/skills/hyperframes/references/subagent-dispatch.md +35 -0
  304. package/vendor/hyperframes/dist/skills/hyperframes/references/workflow-catalog.md +10 -0
  305. package/vendor/hyperframes/dist/skills/hyperframes/scripts/lib/frame-packets-core.mjs +194 -0
  306. package/vendor/hyperframes/dist/skills/hyperframes/scripts/plugin-cli.mjs +88 -0
  307. package/vendor/hyperframes/dist/skills/hyperframes/scripts/plugin-cli.test.mjs +117 -0
  308. package/vendor/hyperframes/dist/skills/hyperframes-cli/SKILL.md +189 -0
  309. package/vendor/hyperframes/dist/skills/hyperframes-cli/references/beats.md +19 -0
  310. package/vendor/hyperframes/dist/skills/hyperframes-cli/references/cloud.md +163 -0
  311. package/vendor/hyperframes/dist/skills/hyperframes-cli/references/cloudrun.md +62 -0
  312. package/vendor/hyperframes/dist/skills/hyperframes-cli/references/compare-and-batch.md +105 -0
  313. package/vendor/hyperframes/dist/skills/hyperframes-cli/references/doctor-browser.md +57 -0
  314. package/vendor/hyperframes/dist/skills/hyperframes-cli/references/init-and-scaffold.md +74 -0
  315. package/vendor/hyperframes/dist/skills/hyperframes-cli/references/lambda.md +185 -0
  316. package/vendor/hyperframes/dist/skills/hyperframes-cli/references/lint-validate-inspect.md +132 -0
  317. package/vendor/hyperframes/dist/skills/hyperframes-cli/references/preview-render.md +193 -0
  318. package/vendor/hyperframes/dist/skills/hyperframes-cli/references/upgrade-info-misc.md +134 -0
  319. package/vendor/hyperframes/dist/skills/media-use/SKILL.md +100 -0
  320. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/CREDITS.md +35 -0
  321. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/chime.mp3 +0 -0
  322. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/click-soft.mp3 +0 -0
  323. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/click.mp3 +0 -0
  324. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/error.mp3 +0 -0
  325. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/glitch-1.mp3 +0 -0
  326. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/glitch-2.mp3 +0 -0
  327. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/glitch-3.mp3 +0 -0
  328. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/impact-bass-1.mp3 +0 -0
  329. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/impact-bass-2.mp3 +0 -0
  330. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/key-press.mp3 +0 -0
  331. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/manifest.json +97 -0
  332. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/notification.mp3 +0 -0
  333. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/ping.mp3 +0 -0
  334. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/pop.mp3 +0 -0
  335. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/riser.mp3 +0 -0
  336. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/sparkle.mp3 +0 -0
  337. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/typing.mp3 +0 -0
  338. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/whoosh-cinematic.mp3 +0 -0
  339. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/whoosh-short.mp3 +0 -0
  340. package/vendor/hyperframes/dist/skills/media-use/audio/assets/sfx/whoosh.mp3 +0 -0
  341. package/vendor/hyperframes/dist/skills/media-use/audio/references/bgm.md +76 -0
  342. package/vendor/hyperframes/dist/skills/media-use/audio/references/captions/authoring.md +163 -0
  343. package/vendor/hyperframes/dist/skills/media-use/audio/references/captions/motion.md +87 -0
  344. package/vendor/hyperframes/dist/skills/media-use/audio/references/captions/transcript-handling.md +97 -0
  345. package/vendor/hyperframes/dist/skills/media-use/audio/references/remove-background.md +143 -0
  346. package/vendor/hyperframes/dist/skills/media-use/audio/references/requirements.md +29 -0
  347. package/vendor/hyperframes/dist/skills/media-use/audio/references/sfx.md +42 -0
  348. package/vendor/hyperframes/dist/skills/media-use/audio/references/transcribe.md +52 -0
  349. package/vendor/hyperframes/dist/skills/media-use/audio/references/tts-to-captions.md +35 -0
  350. package/vendor/hyperframes/dist/skills/media-use/audio/references/tts.md +260 -0
  351. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/audio.mjs +311 -0
  352. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/audio.test.mjs +159 -0
  353. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/gemini-pipeline.test.mjs +131 -0
  354. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/heygen-tts.mjs +122 -0
  355. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/heygen-tts.test.mjs +38 -0
  356. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/heygen-voice.mjs +98 -0
  357. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/heygen-voice.test.mjs +233 -0
  358. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/audio-meta.mjs +39 -0
  359. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/audio-meta.test.mjs +136 -0
  360. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/bgm-volume.mjs +4 -0
  361. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/bgm.mjs +257 -0
  362. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/bgm.test.mjs +74 -0
  363. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/concurrency.mjs +14 -0
  364. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/concurrency.test.mjs +41 -0
  365. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-auth.mjs +43 -0
  366. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-auth.py +52 -0
  367. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-auth.test.mjs +86 -0
  368. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-auth_test.py +90 -0
  369. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-tts.mjs +122 -0
  370. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/gemini-tts.test.mjs +243 -0
  371. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/heygen.mjs +197 -0
  372. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/heygen.test.mjs +185 -0
  373. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/media-record.mjs +114 -0
  374. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/media-record.test.mjs +205 -0
  375. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/python.mjs +77 -0
  376. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/python.test.mjs +136 -0
  377. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/sfx.mjs +165 -0
  378. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/sfx.test.mjs +121 -0
  379. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/tts.mjs +389 -0
  380. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/tts.spawn.test.mjs +158 -0
  381. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lib/tts.test.mjs +230 -0
  382. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/lyria-recipe.py +136 -0
  383. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/wait-bgm.mjs +175 -0
  384. package/vendor/hyperframes/dist/skills/media-use/audio/scripts/wait-bgm.test.mjs +108 -0
  385. package/vendor/hyperframes/dist/skills/media-use/luts/README.md +28 -0
  386. package/vendor/hyperframes/dist/skills/media-use/luts/index.json +57 -0
  387. package/vendor/hyperframes/dist/skills/media-use/references/audio.md +20 -0
  388. package/vendor/hyperframes/dist/skills/media-use/references/grading.md +160 -0
  389. package/vendor/hyperframes/dist/skills/media-use/references/media-treatment-recipes.md +929 -0
  390. package/vendor/hyperframes/dist/skills/media-use/references/media-treatments.md +202 -0
  391. package/vendor/hyperframes/dist/skills/media-use/references/memory.md +37 -0
  392. package/vendor/hyperframes/dist/skills/media-use/references/meta.md +61 -0
  393. package/vendor/hyperframes/dist/skills/media-use/references/operations.md +327 -0
  394. package/vendor/hyperframes/dist/skills/media-use/references/resolve.md +150 -0
  395. package/vendor/hyperframes/dist/skills/media-use/references/setup-providers.md +80 -0
  396. package/vendor/hyperframes/dist/skills/media-use/references/telemetry-dashboard.md +49 -0
  397. package/vendor/hyperframes/dist/skills/media-use/scripts/audio-duck.mjs +113 -0
  398. package/vendor/hyperframes/dist/skills/media-use/scripts/compatibility.test.mjs +96 -0
  399. package/vendor/hyperframes/dist/skills/media-use/scripts/dither.mjs +328 -0
  400. package/vendor/hyperframes/dist/skills/media-use/scripts/dither.test.mjs +176 -0
  401. package/vendor/hyperframes/dist/skills/media-use/scripts/eval.mjs +369 -0
  402. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/adopt.mjs +128 -0
  403. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/adopt.test.mjs +95 -0
  404. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/bgm-provider.mjs +20 -0
  405. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/brand-provider.mjs +59 -0
  406. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/bundled-sfx-provider.mjs +119 -0
  407. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/bundled-sfx-provider.test.mjs +139 -0
  408. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cache.mjs +148 -0
  409. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/candidates.mjs +91 -0
  410. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/candidates.test.mjs +155 -0
  411. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/codex-provider.mjs +161 -0
  412. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/codex-provider.test.mjs +34 -0
  413. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/config-lock.d.mts +3 -0
  414. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/config-lock.mjs +45 -0
  415. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/config-lock.test.mjs +79 -0
  416. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/coverage.test.mjs +136 -0
  417. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cube-build.mjs +181 -0
  418. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cube-build.test.mjs +80 -0
  419. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cube-validate.mjs +198 -0
  420. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cube-validate.test.mjs +125 -0
  421. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cutlist.mjs +184 -0
  422. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/cutlist.test.mjs +162 -0
  423. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/duck.mjs +95 -0
  424. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/duck.test.mjs +153 -0
  425. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/error-diffusion.mjs +230 -0
  426. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/error-diffusion.test.mjs +102 -0
  427. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/ff-binaries.mjs +37 -0
  428. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/freeze.mjs +72 -0
  429. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/freeze.test.mjs +138 -0
  430. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/grade-analyzer.mjs +265 -0
  431. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/grade-analyzer.test.mjs +285 -0
  432. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-cli.mjs +191 -0
  433. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-cli.test.mjs +301 -0
  434. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-search.mjs +45 -0
  435. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-search.test.mjs +49 -0
  436. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-video-provider.mjs +138 -0
  437. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/heygen-video-provider.test.mjs +435 -0
  438. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/image-provider.mjs +44 -0
  439. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/index-gen.mjs +63 -0
  440. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/local-media-search.mjs +32 -0
  441. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/local-models.mjs +318 -0
  442. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/local-models.test.mjs +220 -0
  443. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/local-run.mjs +78 -0
  444. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/local-run.test.mjs +121 -0
  445. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/logo-provider.mjs +244 -0
  446. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/logo-provider.test.mjs +298 -0
  447. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/ltx-video-provider.mjs +94 -0
  448. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/ltx-video-provider.test.mjs +316 -0
  449. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/lut-preset-provider.mjs +271 -0
  450. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/lut-preset-provider.test.mjs +199 -0
  451. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/manifest.d.mts +19 -0
  452. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/manifest.mjs +279 -0
  453. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/manifest.test.mjs +397 -0
  454. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/match.mjs +47 -0
  455. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-fetch.mjs +85 -0
  456. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-fetch.test.mjs +197 -0
  457. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-home.mjs +20 -0
  458. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-home.test.mjs +61 -0
  459. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-search.d.mts +9 -0
  460. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/media-search.mjs +107 -0
  461. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/mflux-provider.mjs +128 -0
  462. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/mflux-provider.test.mjs +174 -0
  463. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/misses.mjs +49 -0
  464. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/misses.test.mjs +89 -0
  465. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/npx-sync.mjs +31 -0
  466. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/npx-sync.test.mjs +50 -0
  467. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/parakeet-words.mjs +27 -0
  468. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/parakeet-words.test.mjs +44 -0
  469. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/prefs-store.mjs +180 -0
  470. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/prefs-store.test.mjs +189 -0
  471. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/probe.mjs +41 -0
  472. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/probe.test.mjs +148 -0
  473. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/providers.mjs +5 -0
  474. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/recipe-store.mjs +367 -0
  475. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/recipe-store.test.mjs +367 -0
  476. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/registry.mjs +212 -0
  477. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/registry.test.mjs +262 -0
  478. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/search.mjs +24 -0
  479. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/search.test.mjs +32 -0
  480. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/sfx-provider.mjs +23 -0
  481. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/specs.mjs +132 -0
  482. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/specs.test.mjs +157 -0
  483. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/stats.mjs +117 -0
  484. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/stats.test.mjs +165 -0
  485. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/svg-sanitize.mjs +21 -0
  486. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/telemetry.mjs +210 -0
  487. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/telemetry.test.mjs +437 -0
  488. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/test-home.test.mjs +10 -0
  489. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/transcriptCutFade.mjs +21 -0
  490. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/transcriptCutFade.test.mjs +33 -0
  491. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/tts-local-provider.mjs +94 -0
  492. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/tts-local-provider.test.mjs +72 -0
  493. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/usage.mjs +57 -0
  494. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/usage.test.mjs +54 -0
  495. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/voice-provider.mjs +57 -0
  496. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/voice-provider.test.mjs +46 -0
  497. package/vendor/hyperframes/dist/skills/media-use/scripts/lib/words.mjs +18 -0
  498. package/vendor/hyperframes/dist/skills/media-use/scripts/prefs.mjs +70 -0
  499. package/vendor/hyperframes/dist/skills/media-use/scripts/recipe.mjs +103 -0
  500. package/vendor/hyperframes/dist/skills/media-use/scripts/resolve-plugin.test.mjs +62 -0
  501. package/vendor/hyperframes/dist/skills/media-use/scripts/resolve.mjs +1369 -0
  502. package/vendor/hyperframes/dist/skills/media-use/scripts/transcribe.mjs +194 -0
  503. package/vendor/hyperframes/dist/skills/media-use/scripts/transcribe.test.mjs +112 -0
  504. package/vendor/hyperframes/dist/skills/media-use/scripts/transcript-cut.mjs +270 -0
  505. package/vendor/hyperframes/dist/skills/media-use/scripts/transcript-cut.test.mjs +117 -0
  506. package/vendor/hyperframes/dist/skills-MJ2J4GEM.js +808 -0
  507. package/vendor/hyperframes/dist/skillsUpdateCheck-TKTYQN5R.js +26 -0
  508. package/vendor/hyperframes/dist/slideshow-EJ4IMY6P.js +24 -0
  509. package/vendor/hyperframes/dist/snapshot-KIVDUUMN.js +875 -0
  510. package/vendor/hyperframes/dist/src-6YQBJGWR.js +202 -0
  511. package/vendor/hyperframes/dist/src-PVYUYV3M.js +471 -0
  512. package/vendor/hyperframes/dist/state-KAXGHF77.js +26 -0
  513. package/vendor/hyperframes/dist/staticProjectServer-7EU666GS.js +49 -0
  514. package/vendor/hyperframes/dist/status-YM52BQ6S.js +311 -0
  515. package/vendor/hyperframes/dist/studio/assets/hyperframes-player-Cp8e_Zst.js +473 -0
  516. package/vendor/hyperframes/dist/studio/assets/index-BX3KHhGX.js +71 -0
  517. package/vendor/hyperframes/dist/studio/assets/index-CASEBNy2.js +1 -0
  518. package/vendor/hyperframes/dist/studio/assets/index-D11atkBt.css +1 -0
  519. package/vendor/hyperframes/dist/studio/assets/index-DMTt9nTf.js +531 -0
  520. package/vendor/hyperframes/dist/studio/assets/index-oE1pOdAy.js +399 -0
  521. package/vendor/hyperframes/dist/studio/chunk-5VSXRGIX.js +948 -0
  522. package/vendor/hyperframes/dist/studio/chunk-5VSXRGIX.js.map +1 -0
  523. package/vendor/hyperframes/dist/studio/chunk-7UQWVN52.js +938 -0
  524. package/vendor/hyperframes/dist/studio/chunk-7UQWVN52.js.map +1 -0
  525. package/vendor/hyperframes/dist/studio/chunk-EEXSYY5F.js +190 -0
  526. package/vendor/hyperframes/dist/studio/chunk-EEXSYY5F.js.map +1 -0
  527. package/vendor/hyperframes/dist/studio/chunk-FOEID72M.js +1441 -0
  528. package/vendor/hyperframes/dist/studio/chunk-FOEID72M.js.map +1 -0
  529. package/vendor/hyperframes/dist/studio/chunk-PZ5AY32C.js +10 -0
  530. package/vendor/hyperframes/dist/studio/chunk-PZ5AY32C.js.map +1 -0
  531. package/vendor/hyperframes/dist/studio/chunk-TDWGXBUT.js +1103 -0
  532. package/vendor/hyperframes/dist/studio/chunk-TDWGXBUT.js.map +1 -0
  533. package/vendor/hyperframes/dist/studio/domEditingLayers-IEVLO54Z.js +47 -0
  534. package/vendor/hyperframes/dist/studio/domEditingLayers-IEVLO54Z.js.map +1 -0
  535. package/vendor/hyperframes/dist/studio/favicon.svg +14 -0
  536. package/vendor/hyperframes/dist/studio/icons/timeline/audio.svg +7 -0
  537. package/vendor/hyperframes/dist/studio/icons/timeline/captions.svg +5 -0
  538. package/vendor/hyperframes/dist/studio/icons/timeline/composition.svg +12 -0
  539. package/vendor/hyperframes/dist/studio/icons/timeline/image.svg +18 -0
  540. package/vendor/hyperframes/dist/studio/icons/timeline/music.svg +10 -0
  541. package/vendor/hyperframes/dist/studio/icons/timeline/text.svg +3 -0
  542. package/vendor/hyperframes/dist/studio/index.css +165 -0
  543. package/vendor/hyperframes/dist/studio/index.css.map +1 -0
  544. package/vendor/hyperframes/dist/studio/index.d.ts +4296 -0
  545. package/vendor/hyperframes/dist/studio/index.html +23 -0
  546. package/vendor/hyperframes/dist/studio/index.js +99693 -0
  547. package/vendor/hyperframes/dist/studio/index.js.map +1 -0
  548. package/vendor/hyperframes/dist/studio/player.d.ts +30 -0
  549. package/vendor/hyperframes/dist/studio/player.js +10 -0
  550. package/vendor/hyperframes/dist/studio/player.js.map +1 -0
  551. package/vendor/hyperframes/dist/studio/styles/tailwind-preset.d.ts +39 -0
  552. package/vendor/hyperframes/dist/studio/styles/tailwind-preset.js +50 -0
  553. package/vendor/hyperframes/dist/studio/styles/tailwind-preset.js.map +1 -0
  554. package/vendor/hyperframes/dist/studio/styles.css +1 -0
  555. package/vendor/hyperframes/dist/studio/ui.d.ts +296 -0
  556. package/vendor/hyperframes/dist/studio/ui.js +66 -0
  557. package/vendor/hyperframes/dist/studio/ui.js.map +1 -0
  558. package/vendor/hyperframes/dist/studio-api-PNQZRPX5.js +136 -0
  559. package/vendor/hyperframes/dist/studioSelectionClient-IUUPKUHZ.js +25 -0
  560. package/vendor/hyperframes/dist/studioServer-UWRBPIOJ.js +1457 -0
  561. package/vendor/hyperframes/dist/synthesize-K62TIZWI.js +182 -0
  562. package/vendor/hyperframes/dist/system-EZYZNUFD.js +44 -0
  563. package/vendor/hyperframes/dist/telemetry-2YC4SGQU.js +144 -0
  564. package/vendor/hyperframes/dist/telemetry-QMYM4WME.js +95 -0
  565. package/vendor/hyperframes/dist/templates/_shared/AGENTS.md +107 -0
  566. package/vendor/hyperframes/dist/templates/_shared/CLAUDE.md +107 -0
  567. package/vendor/hyperframes/dist/templates/blank/index.html +55 -0
  568. package/vendor/hyperframes/dist/templates/from-file/index.html +75 -0
  569. package/vendor/hyperframes/dist/templates/warm-grain/compositions/captions.html +154 -0
  570. package/vendor/hyperframes/dist/templates/warm-grain/compositions/graphics.html +162 -0
  571. package/vendor/hyperframes/dist/templates/warm-grain/compositions/intro.html +87 -0
  572. package/vendor/hyperframes/dist/templates/warm-grain/index.html +264 -0
  573. package/vendor/hyperframes/dist/templates/warm-grain/registry-item.json +34 -0
  574. package/vendor/hyperframes/dist/timeline-77Z3BBQM.js +1377 -0
  575. package/vendor/hyperframes/dist/tokens-OBGTYE4Z.js +92 -0
  576. package/vendor/hyperframes/dist/transcribe-7NVFHCGA.js +387 -0
  577. package/vendor/hyperframes/dist/transcribe-BNSJRR4M.js +62 -0
  578. package/vendor/hyperframes/dist/tts-P3LIPIL5.js +234 -0
  579. package/vendor/hyperframes/dist/updateCheck-UDWIJ4ZQ.js +39 -0
  580. package/vendor/hyperframes/dist/upgrade-CT3CPO3E.js +231 -0
  581. package/vendor/hyperframes/dist/urlDownloader-H6WRI2UE.js +39 -0
  582. package/vendor/hyperframes/dist/usage-EC3KFUIJ.js +2139 -0
  583. package/vendor/hyperframes/dist/validate-65QDZJWZ.js +70 -0
  584. package/vendor/hyperframes/dist/video-FGSGKRSV.js +261 -0
  585. package/vendor/hyperframes/dist/workspaceBuildCheck-TOLGAI4T.js +133 -0
  586. package/vendor/hyperframes/package.json +80 -0
@@ -0,0 +1,2057 @@
1
+ import { createRequire as __hf_createRequire } from "node:module";
2
+ import { fileURLToPath as __hf_fileURLToPath } from "node:url";
3
+ import { dirname as __hf_dirname } from "node:path";
4
+ var require = __hf_createRequire(import.meta.url);
5
+ var __filename = __hf_fileURLToPath(import.meta.url);
6
+ var __dirname = __hf_dirname(__filename);
7
+ import {
8
+ __commonJS,
9
+ __toESM
10
+ } from "./chunk-M2WBOQ2Q.js";
11
+
12
+ // ../../node_modules/.bun/sisteransi@1.0.5/node_modules/sisteransi/src/index.js
13
+ var require_src = __commonJS({
14
+ "../../node_modules/.bun/sisteransi@1.0.5/node_modules/sisteransi/src/index.js"(exports, module) {
15
+ "use strict";
16
+ var ESC2 = "\x1B";
17
+ var CSI2 = `${ESC2}[`;
18
+ var beep = "\x07";
19
+ var cursor = {
20
+ to(x2, y) {
21
+ if (!y) return `${CSI2}${x2 + 1}G`;
22
+ return `${CSI2}${y + 1};${x2 + 1}H`;
23
+ },
24
+ move(x2, y) {
25
+ let ret = "";
26
+ if (x2 < 0) ret += `${CSI2}${-x2}D`;
27
+ else if (x2 > 0) ret += `${CSI2}${x2}C`;
28
+ if (y < 0) ret += `${CSI2}${-y}A`;
29
+ else if (y > 0) ret += `${CSI2}${y}B`;
30
+ return ret;
31
+ },
32
+ up: (count = 1) => `${CSI2}${count}A`,
33
+ down: (count = 1) => `${CSI2}${count}B`,
34
+ forward: (count = 1) => `${CSI2}${count}C`,
35
+ backward: (count = 1) => `${CSI2}${count}D`,
36
+ nextLine: (count = 1) => `${CSI2}E`.repeat(count),
37
+ prevLine: (count = 1) => `${CSI2}F`.repeat(count),
38
+ left: `${CSI2}G`,
39
+ hide: `${CSI2}?25l`,
40
+ show: `${CSI2}?25h`,
41
+ save: `${ESC2}7`,
42
+ restore: `${ESC2}8`
43
+ };
44
+ var scroll = {
45
+ up: (count = 1) => `${CSI2}S`.repeat(count),
46
+ down: (count = 1) => `${CSI2}T`.repeat(count)
47
+ };
48
+ var erase = {
49
+ screen: `${CSI2}2J`,
50
+ up: (count = 1) => `${CSI2}1J`.repeat(count),
51
+ down: (count = 1) => `${CSI2}J`.repeat(count),
52
+ line: `${CSI2}2K`,
53
+ lineEnd: `${CSI2}K`,
54
+ lineStart: `${CSI2}1K`,
55
+ lines(count) {
56
+ let clear = "";
57
+ for (let i = 0; i < count; i++)
58
+ clear += this.line + (i < count - 1 ? cursor.up() : "");
59
+ if (count)
60
+ clear += cursor.left;
61
+ return clear;
62
+ }
63
+ };
64
+ module.exports = { cursor, scroll, erase, beep };
65
+ }
66
+ });
67
+
68
+ // ../../node_modules/.bun/@clack+core@1.3.0/node_modules/@clack/core/dist/index.mjs
69
+ import { styleText as v } from "util";
70
+ import { stdout as S, stdin as D } from "process";
71
+ import * as b from "readline";
72
+ import E from "readline";
73
+
74
+ // ../../node_modules/.bun/fast-string-truncated-width@3.0.3/node_modules/fast-string-truncated-width/dist/utils.js
75
+ var getCodePointsLength = /* @__PURE__ */ (() => {
76
+ const SURROGATE_PAIR_RE = /[\uD800-\uDBFF][\uDC00-\uDFFF]/g;
77
+ return (input) => {
78
+ let surrogatePairsNr = 0;
79
+ SURROGATE_PAIR_RE.lastIndex = 0;
80
+ while (SURROGATE_PAIR_RE.test(input)) {
81
+ surrogatePairsNr += 1;
82
+ }
83
+ return input.length - surrogatePairsNr;
84
+ };
85
+ })();
86
+ var isFullWidth = (x2) => {
87
+ return x2 === 12288 || x2 >= 65281 && x2 <= 65376 || x2 >= 65504 && x2 <= 65510;
88
+ };
89
+ var isWideNotCJKTNotEmoji = (x2) => {
90
+ return x2 === 8987 || x2 === 9001 || x2 >= 12272 && x2 <= 12287 || x2 >= 12289 && x2 <= 12350 || x2 >= 12441 && x2 <= 12543 || x2 >= 12549 && x2 <= 12591 || x2 >= 12593 && x2 <= 12686 || x2 >= 12688 && x2 <= 12771 || x2 >= 12783 && x2 <= 12830 || x2 >= 12832 && x2 <= 12871 || x2 >= 12880 && x2 <= 19903 || x2 >= 65040 && x2 <= 65049 || x2 >= 65072 && x2 <= 65106 || x2 >= 65108 && x2 <= 65126 || x2 >= 65128 && x2 <= 65131 || x2 >= 127488 && x2 <= 127490 || x2 >= 127504 && x2 <= 127547 || x2 >= 127552 && x2 <= 127560 || x2 >= 131072 && x2 <= 196605 || x2 >= 196608 && x2 <= 262141;
91
+ };
92
+
93
+ // ../../node_modules/.bun/fast-string-truncated-width@3.0.3/node_modules/fast-string-truncated-width/dist/index.js
94
+ var ANSI_RE = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]|\u001b\]8;[^;]*;.*?(?:\u0007|\u001b\u005c)/y;
95
+ var CONTROL_RE = /[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y;
96
+ var CJKT_WIDE_RE = /(?:(?![\uFF61-\uFF9F\uFF00-\uFFEF])[\p{Script=Han}\p{Script=Hiragana}\p{Script=Katakana}\p{Script=Hangul}\p{Script=Tangut}]){1,1000}/yu;
97
+ var TAB_RE = /\t{1,1000}/y;
98
+ var EMOJI_RE = new RegExp("[\\u{1F1E6}-\\u{1F1FF}]{2}|\\u{1F3F4}[\\u{E0061}-\\u{E007A}]{2}[\\u{E0030}-\\u{E0039}\\u{E0061}-\\u{E007A}]{1,3}\\u{E007F}|(?:\\p{Emoji}\\uFE0F\\u20E3?|\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation})(?:\\u200D(?:\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation}|\\p{Emoji}\\uFE0F\\u20E3?))*", "yu");
99
+ var LATIN_RE = /(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y;
100
+ var MODIFIER_RE = new RegExp("\\p{M}+", "gu");
101
+ var NO_TRUNCATION = { limit: Infinity, ellipsis: "" };
102
+ var getStringTruncatedWidth = (input, truncationOptions = {}, widthOptions = {}) => {
103
+ const LIMIT = truncationOptions.limit ?? Infinity;
104
+ const ELLIPSIS = truncationOptions.ellipsis ?? "";
105
+ const ELLIPSIS_WIDTH = truncationOptions?.ellipsisWidth ?? (ELLIPSIS ? getStringTruncatedWidth(ELLIPSIS, NO_TRUNCATION, widthOptions).width : 0);
106
+ const ANSI_WIDTH = 0;
107
+ const CONTROL_WIDTH = widthOptions.controlWidth ?? 0;
108
+ const TAB_WIDTH = widthOptions.tabWidth ?? 8;
109
+ const EMOJI_WIDTH = widthOptions.emojiWidth ?? 2;
110
+ const FULL_WIDTH_WIDTH = 2;
111
+ const REGULAR_WIDTH = widthOptions.regularWidth ?? 1;
112
+ const WIDE_WIDTH = widthOptions.wideWidth ?? FULL_WIDTH_WIDTH;
113
+ const PARSE_BLOCKS = [
114
+ [LATIN_RE, REGULAR_WIDTH],
115
+ [ANSI_RE, ANSI_WIDTH],
116
+ [CONTROL_RE, CONTROL_WIDTH],
117
+ [TAB_RE, TAB_WIDTH],
118
+ [EMOJI_RE, EMOJI_WIDTH],
119
+ [CJKT_WIDE_RE, WIDE_WIDTH]
120
+ ];
121
+ let indexPrev = 0;
122
+ let index = 0;
123
+ let length = input.length;
124
+ let lengthExtra = 0;
125
+ let truncationEnabled = false;
126
+ let truncationIndex = length;
127
+ let truncationLimit = Math.max(0, LIMIT - ELLIPSIS_WIDTH);
128
+ let unmatchedStart = 0;
129
+ let unmatchedEnd = 0;
130
+ let width = 0;
131
+ let widthExtra = 0;
132
+ outer: while (true) {
133
+ if (unmatchedEnd > unmatchedStart || index >= length && index > indexPrev) {
134
+ const unmatched = input.slice(unmatchedStart, unmatchedEnd) || input.slice(indexPrev, index);
135
+ lengthExtra = 0;
136
+ for (const char of unmatched.replaceAll(MODIFIER_RE, "")) {
137
+ const codePoint = char.codePointAt(0) || 0;
138
+ if (isFullWidth(codePoint)) {
139
+ widthExtra = FULL_WIDTH_WIDTH;
140
+ } else if (isWideNotCJKTNotEmoji(codePoint)) {
141
+ widthExtra = WIDE_WIDTH;
142
+ } else {
143
+ widthExtra = REGULAR_WIDTH;
144
+ }
145
+ if (width + widthExtra > truncationLimit) {
146
+ truncationIndex = Math.min(truncationIndex, Math.max(unmatchedStart, indexPrev) + lengthExtra);
147
+ }
148
+ if (width + widthExtra > LIMIT) {
149
+ truncationEnabled = true;
150
+ break outer;
151
+ }
152
+ lengthExtra += char.length;
153
+ width += widthExtra;
154
+ }
155
+ unmatchedStart = unmatchedEnd = 0;
156
+ }
157
+ if (index >= length) {
158
+ break outer;
159
+ }
160
+ for (let i = 0, l = PARSE_BLOCKS.length; i < l; i++) {
161
+ const [BLOCK_RE, BLOCK_WIDTH] = PARSE_BLOCKS[i];
162
+ BLOCK_RE.lastIndex = index;
163
+ if (BLOCK_RE.test(input)) {
164
+ lengthExtra = BLOCK_RE === CJKT_WIDE_RE ? getCodePointsLength(input.slice(index, BLOCK_RE.lastIndex)) : BLOCK_RE === EMOJI_RE ? 1 : BLOCK_RE.lastIndex - index;
165
+ widthExtra = lengthExtra * BLOCK_WIDTH;
166
+ if (width + widthExtra > truncationLimit) {
167
+ truncationIndex = Math.min(truncationIndex, index + Math.floor((truncationLimit - width) / BLOCK_WIDTH));
168
+ }
169
+ if (width + widthExtra > LIMIT) {
170
+ truncationEnabled = true;
171
+ break outer;
172
+ }
173
+ width += widthExtra;
174
+ unmatchedStart = indexPrev;
175
+ unmatchedEnd = index;
176
+ index = indexPrev = BLOCK_RE.lastIndex;
177
+ continue outer;
178
+ }
179
+ }
180
+ index += 1;
181
+ }
182
+ return {
183
+ width: truncationEnabled ? truncationLimit : width,
184
+ index: truncationEnabled ? truncationIndex : length,
185
+ truncated: truncationEnabled,
186
+ ellipsed: truncationEnabled && LIMIT >= ELLIPSIS_WIDTH
187
+ };
188
+ };
189
+ var dist_default = getStringTruncatedWidth;
190
+
191
+ // ../../node_modules/.bun/fast-string-width@3.0.2/node_modules/fast-string-width/dist/index.js
192
+ var NO_TRUNCATION2 = {
193
+ limit: Infinity,
194
+ ellipsis: "",
195
+ ellipsisWidth: 0
196
+ };
197
+ var fastStringWidth = (input, options = {}) => {
198
+ return dist_default(input, NO_TRUNCATION2, options).width;
199
+ };
200
+ var dist_default2 = fastStringWidth;
201
+
202
+ // ../../node_modules/.bun/fast-wrap-ansi@0.2.0/node_modules/fast-wrap-ansi/lib/main.js
203
+ var ESC = "\x1B";
204
+ var CSI = "\x9B";
205
+ var END_CODE = 39;
206
+ var ANSI_ESCAPE_BELL = "\x07";
207
+ var ANSI_CSI = "[";
208
+ var ANSI_OSC = "]";
209
+ var ANSI_SGR_TERMINATOR = "m";
210
+ var ANSI_ESCAPE_LINK = `${ANSI_OSC}8;;`;
211
+ var GROUP_REGEX = new RegExp(`(?:\\${ANSI_CSI}(?<code>\\d+)m|\\${ANSI_ESCAPE_LINK}(?<uri>.*)${ANSI_ESCAPE_BELL})`, "y");
212
+ var getClosingCode = (openingCode) => {
213
+ if (openingCode >= 30 && openingCode <= 37)
214
+ return 39;
215
+ if (openingCode >= 90 && openingCode <= 97)
216
+ return 39;
217
+ if (openingCode >= 40 && openingCode <= 47)
218
+ return 49;
219
+ if (openingCode >= 100 && openingCode <= 107)
220
+ return 49;
221
+ if (openingCode === 1 || openingCode === 2)
222
+ return 22;
223
+ if (openingCode === 3)
224
+ return 23;
225
+ if (openingCode === 4)
226
+ return 24;
227
+ if (openingCode === 7)
228
+ return 27;
229
+ if (openingCode === 8)
230
+ return 28;
231
+ if (openingCode === 9)
232
+ return 29;
233
+ if (openingCode === 0)
234
+ return 0;
235
+ return void 0;
236
+ };
237
+ var wrapAnsiCode = (code) => `${ESC}${ANSI_CSI}${code}${ANSI_SGR_TERMINATOR}`;
238
+ var wrapAnsiHyperlink = (url) => `${ESC}${ANSI_ESCAPE_LINK}${url}${ANSI_ESCAPE_BELL}`;
239
+ var wrapWord = (rows, word, columns) => {
240
+ const characters = word[Symbol.iterator]();
241
+ let isInsideEscape = false;
242
+ let isInsideLinkEscape = false;
243
+ let lastRow = rows.at(-1);
244
+ let visible = lastRow === void 0 ? 0 : dist_default2(lastRow);
245
+ let currentCharacter = characters.next();
246
+ let nextCharacter = characters.next();
247
+ let rawCharacterIndex = 0;
248
+ while (!currentCharacter.done) {
249
+ const character = currentCharacter.value;
250
+ const characterLength = dist_default2(character);
251
+ if (visible + characterLength <= columns) {
252
+ rows[rows.length - 1] += character;
253
+ } else {
254
+ rows.push(character);
255
+ visible = 0;
256
+ }
257
+ if (character === ESC || character === CSI) {
258
+ isInsideEscape = true;
259
+ isInsideLinkEscape = word.startsWith(ANSI_ESCAPE_LINK, rawCharacterIndex + 1);
260
+ }
261
+ if (isInsideEscape) {
262
+ if (isInsideLinkEscape) {
263
+ if (character === ANSI_ESCAPE_BELL) {
264
+ isInsideEscape = false;
265
+ isInsideLinkEscape = false;
266
+ }
267
+ } else if (character === ANSI_SGR_TERMINATOR) {
268
+ isInsideEscape = false;
269
+ }
270
+ } else {
271
+ visible += characterLength;
272
+ if (visible === columns && !nextCharacter.done) {
273
+ rows.push("");
274
+ visible = 0;
275
+ }
276
+ }
277
+ currentCharacter = nextCharacter;
278
+ nextCharacter = characters.next();
279
+ rawCharacterIndex += character.length;
280
+ }
281
+ lastRow = rows.at(-1);
282
+ if (!visible && lastRow !== void 0 && lastRow.length && rows.length > 1) {
283
+ rows[rows.length - 2] += rows.pop();
284
+ }
285
+ };
286
+ var stringVisibleTrimSpacesRight = (string) => {
287
+ const words = string.split(" ");
288
+ let last = words.length;
289
+ while (last) {
290
+ if (dist_default2(words[last - 1])) {
291
+ break;
292
+ }
293
+ last--;
294
+ }
295
+ if (last === words.length) {
296
+ return string;
297
+ }
298
+ return words.slice(0, last).join(" ") + words.slice(last).join("");
299
+ };
300
+ var exec = (string, columns, options = {}) => {
301
+ if (options.trim !== false && string.trim() === "") {
302
+ return "";
303
+ }
304
+ let returnValue = "";
305
+ let escapeCode;
306
+ let escapeUrl;
307
+ const words = string.split(" ");
308
+ let rows = [""];
309
+ let rowLength = 0;
310
+ for (let index = 0; index < words.length; index++) {
311
+ const word = words[index];
312
+ if (options.trim !== false) {
313
+ const row = rows.at(-1) ?? "";
314
+ const trimmed = row.trimStart();
315
+ if (row.length !== trimmed.length) {
316
+ rows[rows.length - 1] = trimmed;
317
+ rowLength = dist_default2(trimmed);
318
+ }
319
+ }
320
+ if (index !== 0) {
321
+ if (rowLength >= columns && (options.wordWrap === false || options.trim === false)) {
322
+ rows.push("");
323
+ rowLength = 0;
324
+ }
325
+ if (rowLength || options.trim === false) {
326
+ rows[rows.length - 1] += " ";
327
+ rowLength++;
328
+ }
329
+ }
330
+ const wordLength = dist_default2(word);
331
+ if (options.hard && wordLength > columns) {
332
+ const remainingColumns = columns - rowLength;
333
+ const breaksStartingThisLine = 1 + Math.floor((wordLength - remainingColumns - 1) / columns);
334
+ const breaksStartingNextLine = Math.floor((wordLength - 1) / columns);
335
+ if (breaksStartingNextLine < breaksStartingThisLine) {
336
+ rows.push("");
337
+ }
338
+ wrapWord(rows, word, columns);
339
+ rowLength = dist_default2(rows.at(-1) ?? "");
340
+ continue;
341
+ }
342
+ if (rowLength + wordLength > columns && rowLength && wordLength) {
343
+ if (options.wordWrap === false && rowLength < columns) {
344
+ wrapWord(rows, word, columns);
345
+ rowLength = dist_default2(rows.at(-1) ?? "");
346
+ continue;
347
+ }
348
+ rows.push("");
349
+ rowLength = 0;
350
+ }
351
+ if (rowLength + wordLength > columns && options.wordWrap === false) {
352
+ wrapWord(rows, word, columns);
353
+ rowLength = dist_default2(rows.at(-1) ?? "");
354
+ continue;
355
+ }
356
+ rows[rows.length - 1] += word;
357
+ rowLength += wordLength;
358
+ }
359
+ if (options.trim !== false) {
360
+ rows = rows.map((row) => stringVisibleTrimSpacesRight(row));
361
+ }
362
+ const preString = rows.join("\n");
363
+ let inSurrogate = false;
364
+ for (let i = 0; i < preString.length; i++) {
365
+ const character = preString[i];
366
+ returnValue += character;
367
+ if (!inSurrogate) {
368
+ inSurrogate = character >= "\uD800" && character <= "\uDBFF";
369
+ if (inSurrogate) {
370
+ continue;
371
+ }
372
+ } else {
373
+ inSurrogate = false;
374
+ }
375
+ if (character === ESC || character === CSI) {
376
+ GROUP_REGEX.lastIndex = i + 1;
377
+ const groupsResult = GROUP_REGEX.exec(preString);
378
+ const groups = groupsResult?.groups;
379
+ if (groups?.code !== void 0) {
380
+ const code = Number.parseFloat(groups.code);
381
+ escapeCode = code === END_CODE ? void 0 : code;
382
+ } else if (groups?.uri !== void 0) {
383
+ escapeUrl = groups.uri.length === 0 ? void 0 : groups.uri;
384
+ }
385
+ }
386
+ if (preString[i + 1] === "\n") {
387
+ if (escapeUrl) {
388
+ returnValue += wrapAnsiHyperlink("");
389
+ }
390
+ const closingCode = escapeCode ? getClosingCode(escapeCode) : void 0;
391
+ if (escapeCode && closingCode) {
392
+ returnValue += wrapAnsiCode(closingCode);
393
+ }
394
+ } else if (character === "\n") {
395
+ if (escapeCode && getClosingCode(escapeCode)) {
396
+ returnValue += wrapAnsiCode(escapeCode);
397
+ }
398
+ if (escapeUrl) {
399
+ returnValue += wrapAnsiHyperlink(escapeUrl);
400
+ }
401
+ }
402
+ }
403
+ return returnValue;
404
+ };
405
+ var CRLF_OR_LF = /\r?\n/;
406
+ function wrapAnsi(string, columns, options) {
407
+ return String(string).normalize().split(CRLF_OR_LF).map((line) => exec(line, columns, options)).join("\n");
408
+ }
409
+
410
+ // ../../node_modules/.bun/@clack+core@1.3.0/node_modules/@clack/core/dist/index.mjs
411
+ var import_sisteransi = __toESM(require_src(), 1);
412
+ import { ReadStream as O } from "tty";
413
+ function d(r, t, s) {
414
+ if (!s.some((o) => !o.disabled)) return r;
415
+ const e2 = r + t, i = Math.max(s.length - 1, 0), n = e2 < 0 ? i : e2 > i ? 0 : e2;
416
+ return s[n].disabled ? d(n, t < 0 ? -1 : 1, s) : n;
417
+ }
418
+ function I(r, t, s, e2) {
419
+ const i = e2.split(`
420
+ `);
421
+ let n = 0, o = r;
422
+ for (const a of i) {
423
+ if (o <= a.length) break;
424
+ o -= a.length + 1, n++;
425
+ }
426
+ for (n = Math.max(0, Math.min(i.length - 1, n + s)), o = Math.min(o, i[n].length) + t; o < 0 && n > 0; ) n--, o += i[n].length + 1;
427
+ for (; o > i[n].length && n < i.length - 1; ) o -= i[n].length + 1, n++;
428
+ o = Math.max(0, Math.min(i[n].length, o));
429
+ let u = 0;
430
+ for (let a = 0; a < n; a++) u += i[a].length + 1;
431
+ return u + o;
432
+ }
433
+ var G = ["up", "down", "left", "right", "space", "enter", "cancel"];
434
+ var K = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
435
+ var h = { actions: new Set(G), aliases: /* @__PURE__ */ new Map([["k", "up"], ["j", "down"], ["h", "left"], ["l", "right"], ["", "cancel"], ["escape", "cancel"]]), messages: { cancel: "Canceled", error: "Something went wrong" }, withGuide: true, date: { monthNames: [...K], messages: { required: "Please enter a valid date", invalidMonth: "There are only 12 months in a year", invalidDay: (r, t) => `There are only ${r} days in ${t}`, afterMin: (r) => `Date must be on or after ${r.toISOString().slice(0, 10)}`, beforeMax: (r) => `Date must be on or before ${r.toISOString().slice(0, 10)}` } } };
436
+ function j(r) {
437
+ if (r.aliases !== void 0) {
438
+ const t = r.aliases;
439
+ for (const s in t) {
440
+ if (!Object.hasOwn(t, s)) continue;
441
+ const e2 = t[s];
442
+ h.actions.has(e2) && (h.aliases.has(s) || h.aliases.set(s, e2));
443
+ }
444
+ }
445
+ if (r.messages !== void 0) {
446
+ const t = r.messages;
447
+ t.cancel !== void 0 && (h.messages.cancel = t.cancel), t.error !== void 0 && (h.messages.error = t.error);
448
+ }
449
+ if (r.withGuide !== void 0 && (h.withGuide = r.withGuide !== false), r.date !== void 0) {
450
+ const t = r.date;
451
+ t.monthNames !== void 0 && (h.date.monthNames = [...t.monthNames]), t.messages !== void 0 && (t.messages.required !== void 0 && (h.date.messages.required = t.messages.required), t.messages.invalidMonth !== void 0 && (h.date.messages.invalidMonth = t.messages.invalidMonth), t.messages.invalidDay !== void 0 && (h.date.messages.invalidDay = t.messages.invalidDay), t.messages.afterMin !== void 0 && (h.date.messages.afterMin = t.messages.afterMin), t.messages.beforeMax !== void 0 && (h.date.messages.beforeMax = t.messages.beforeMax));
452
+ }
453
+ }
454
+ function C(r, t) {
455
+ if (typeof r == "string") return h.aliases.get(r) === t;
456
+ for (const s of r) if (s !== void 0 && C(s, t)) return true;
457
+ return false;
458
+ }
459
+ function z(r, t) {
460
+ if (r === t) return;
461
+ const s = r.split(`
462
+ `), e2 = t.split(`
463
+ `), i = Math.max(s.length, e2.length), n = [];
464
+ for (let o = 0; o < i; o++) s[o] !== e2[o] && n.push(o);
465
+ return { lines: n, numLinesBefore: s.length, numLinesAfter: e2.length, numLines: i };
466
+ }
467
+ var Y = globalThis.process.platform.startsWith("win");
468
+ var k = /* @__PURE__ */ Symbol("clack:cancel");
469
+ function q(r) {
470
+ return r === k;
471
+ }
472
+ function w(r, t) {
473
+ const s = r;
474
+ s.isTTY && s.setRawMode(t);
475
+ }
476
+ function R({ input: r = D, output: t = S, overwrite: s = true, hideCursor: e2 = true } = {}) {
477
+ const i = b.createInterface({ input: r, output: t, prompt: "", tabSize: 1 });
478
+ b.emitKeypressEvents(r, i), r instanceof O && r.isTTY && r.setRawMode(true);
479
+ const n = (o, { name: u, sequence: a }) => {
480
+ const l = String(o);
481
+ if (C([l, u, a], "cancel")) {
482
+ e2 && t.write(import_sisteransi.cursor.show), process.exit(0);
483
+ return;
484
+ }
485
+ if (!s) return;
486
+ const f = u === "return" ? 0 : -1, y = u === "return" ? -1 : 0;
487
+ b.moveCursor(t, f, y, () => {
488
+ b.clearLine(t, 1, () => {
489
+ r.once("keypress", n);
490
+ });
491
+ });
492
+ };
493
+ return e2 && t.write(import_sisteransi.cursor.hide), r.once("keypress", n), () => {
494
+ r.off("keypress", n), e2 && t.write(import_sisteransi.cursor.show), r instanceof O && r.isTTY && !Y && r.setRawMode(false), i.terminal = false, i.close();
495
+ };
496
+ }
497
+ var A = (r) => "columns" in r && typeof r.columns == "number" ? r.columns : 80;
498
+ var L = (r) => "rows" in r && typeof r.rows == "number" ? r.rows : 20;
499
+ function W(r, t, s, e2 = s, i) {
500
+ const n = A(r ?? S);
501
+ return wrapAnsi(t, n - s.length, { hard: true, trim: false }).split(`
502
+ `).map((o, u) => {
503
+ const a = i ? i(o, u) : o;
504
+ return `${u === 0 ? e2 : s}${a}`;
505
+ }).join(`
506
+ `);
507
+ }
508
+ var p = class {
509
+ input;
510
+ output;
511
+ _abortSignal;
512
+ rl;
513
+ opts;
514
+ _render;
515
+ _track = false;
516
+ _prevFrame = "";
517
+ _subscribers = /* @__PURE__ */ new Map();
518
+ _cursor = 0;
519
+ state = "initial";
520
+ error = "";
521
+ value;
522
+ userInput = "";
523
+ constructor(t, s = true) {
524
+ const { input: e2 = D, output: i = S, render: n, signal: o, ...u } = t;
525
+ this.opts = u, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = n.bind(this), this._track = s, this._abortSignal = o, this.input = e2, this.output = i;
526
+ }
527
+ unsubscribe() {
528
+ this._subscribers.clear();
529
+ }
530
+ setSubscriber(t, s) {
531
+ const e2 = this._subscribers.get(t) ?? [];
532
+ e2.push(s), this._subscribers.set(t, e2);
533
+ }
534
+ on(t, s) {
535
+ this.setSubscriber(t, { cb: s });
536
+ }
537
+ once(t, s) {
538
+ this.setSubscriber(t, { cb: s, once: true });
539
+ }
540
+ emit(t, ...s) {
541
+ const e2 = this._subscribers.get(t) ?? [], i = [];
542
+ for (const n of e2) n.cb(...s), n.once && i.push(() => e2.splice(e2.indexOf(n), 1));
543
+ for (const n of i) n();
544
+ }
545
+ prompt() {
546
+ return new Promise((t) => {
547
+ if (this._abortSignal) {
548
+ if (this._abortSignal.aborted) return this.state = "cancel", this.close(), t(k);
549
+ this._abortSignal.addEventListener("abort", () => {
550
+ this.state = "cancel", this.close();
551
+ }, { once: true });
552
+ }
553
+ this.rl = E.createInterface({ input: this.input, tabSize: 2, prompt: "", escapeCodeTimeout: 50, terminal: true }), this.rl.prompt(), this.opts.initialUserInput !== void 0 && this._setUserInput(this.opts.initialUserInput, true), this.input.on("keypress", this.onKeypress), w(this.input, true), this.output.on("resize", this.render), this.render(), this.once("submit", () => {
554
+ this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), w(this.input, false), t(this.value);
555
+ }), this.once("cancel", () => {
556
+ this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), w(this.input, false), t(k);
557
+ });
558
+ });
559
+ }
560
+ _isActionKey(t, s) {
561
+ return t === " ";
562
+ }
563
+ _shouldSubmit(t, s) {
564
+ return true;
565
+ }
566
+ _setValue(t) {
567
+ this.value = t, this.emit("value", this.value);
568
+ }
569
+ _setUserInput(t, s) {
570
+ this.userInput = t ?? "", this.emit("userInput", this.userInput), s && this._track && this.rl && (this.rl.write(this.userInput), this._cursor = this.rl.cursor);
571
+ }
572
+ _clearUserInput() {
573
+ this.rl?.write(null, { ctrl: true, name: "u" }), this._setUserInput("");
574
+ }
575
+ onKeypress(t, s) {
576
+ if (this._track && s.name !== "return" && (s.name && this._isActionKey(t, s) && this.rl?.write(null, { ctrl: true, name: "h" }), this._cursor = this.rl?.cursor ?? 0, this._setUserInput(this.rl?.line)), this.state === "error" && (this.state = "active"), s?.name && (!this._track && h.aliases.has(s.name) && this.emit("cursor", h.aliases.get(s.name)), h.actions.has(s.name) && this.emit("cursor", s.name)), t && (t.toLowerCase() === "y" || t.toLowerCase() === "n") && this.emit("confirm", t.toLowerCase() === "y"), this.emit("key", t?.toLowerCase(), s), s?.name === "return" && this._shouldSubmit(t, s)) {
577
+ if (this.opts.validate) {
578
+ const e2 = this.opts.validate(this.value);
579
+ e2 && (this.error = e2 instanceof Error ? e2.message : e2, this.state = "error", this.rl?.write(this.userInput));
580
+ }
581
+ this.state !== "error" && (this.state = "submit");
582
+ }
583
+ C([t, s?.name, s?.sequence], "cancel") && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
584
+ }
585
+ close() {
586
+ this.input.unpipe(), this.input.removeListener("keypress", this.onKeypress), this.output.write(`
587
+ `), w(this.input, false), this.rl?.close(), this.rl = void 0, this.emit(`${this.state}`, this.value), this.unsubscribe();
588
+ }
589
+ restoreCursor() {
590
+ const t = wrapAnsi(this._prevFrame, process.stdout.columns, { hard: true, trim: false }).split(`
591
+ `).length - 1;
592
+ this.output.write(import_sisteransi.cursor.move(-999, t * -1));
593
+ }
594
+ render() {
595
+ const t = wrapAnsi(this._render(this) ?? "", process.stdout.columns, { hard: true, trim: false });
596
+ if (t !== this._prevFrame) {
597
+ if (this.state === "initial") this.output.write(import_sisteransi.cursor.hide);
598
+ else {
599
+ const s = z(this._prevFrame, t), e2 = L(this.output);
600
+ if (this.restoreCursor(), s) {
601
+ const i = Math.max(0, s.numLinesAfter - e2), n = Math.max(0, s.numLinesBefore - e2);
602
+ let o = s.lines.find((u) => u >= i);
603
+ if (o === void 0) {
604
+ this._prevFrame = t;
605
+ return;
606
+ }
607
+ if (s.lines.length === 1) {
608
+ this.output.write(import_sisteransi.cursor.move(0, o - n)), this.output.write(import_sisteransi.erase.lines(1));
609
+ const u = t.split(`
610
+ `);
611
+ this.output.write(u[o]), this._prevFrame = t, this.output.write(import_sisteransi.cursor.move(0, u.length - o - 1));
612
+ return;
613
+ } else if (s.lines.length > 1) {
614
+ if (i < n) o = i;
615
+ else {
616
+ const a = o - n;
617
+ a > 0 && this.output.write(import_sisteransi.cursor.move(0, a));
618
+ }
619
+ this.output.write(import_sisteransi.erase.down());
620
+ const u = t.split(`
621
+ `).slice(o);
622
+ this.output.write(u.join(`
623
+ `)), this._prevFrame = t;
624
+ return;
625
+ }
626
+ }
627
+ this.output.write(import_sisteransi.erase.down());
628
+ }
629
+ this.output.write(t), this.state === "initial" && (this.state = "active"), this._prevFrame = t;
630
+ }
631
+ }
632
+ };
633
+ function B(r, t) {
634
+ if (r === void 0 || t.length === 0) return 0;
635
+ const s = t.findIndex((e2) => e2.value === r);
636
+ return s !== -1 ? s : 0;
637
+ }
638
+ function J(r, t) {
639
+ return (t.label ?? String(t.value)).toLowerCase().includes(r.toLowerCase());
640
+ }
641
+ function H(r, t) {
642
+ if (t) return r ? t : t[0];
643
+ }
644
+ var Q = class extends p {
645
+ filteredOptions;
646
+ multiple;
647
+ isNavigating = false;
648
+ selectedValues = [];
649
+ focusedValue;
650
+ #s = 0;
651
+ #r = "";
652
+ #t;
653
+ #n;
654
+ #u;
655
+ get cursor() {
656
+ return this.#s;
657
+ }
658
+ get userInputWithCursor() {
659
+ if (!this.userInput) return v(["inverse", "hidden"], "_");
660
+ if (this._cursor >= this.userInput.length) return `${this.userInput}\u2588`;
661
+ const t = this.userInput.slice(0, this._cursor), [s, ...e2] = this.userInput.slice(this._cursor);
662
+ return `${t}${v("inverse", s)}${e2.join("")}`;
663
+ }
664
+ get options() {
665
+ return typeof this.#n == "function" ? this.#n() : this.#n;
666
+ }
667
+ constructor(t) {
668
+ super(t), this.#n = t.options, this.#u = t.placeholder;
669
+ const s = this.options;
670
+ this.filteredOptions = [...s], this.multiple = t.multiple === true, this.#t = typeof t.options == "function" ? t.filter : t.filter ?? J;
671
+ let e2;
672
+ if (t.initialValue && Array.isArray(t.initialValue) ? this.multiple ? e2 = t.initialValue : e2 = t.initialValue.slice(0, 1) : !this.multiple && this.options.length > 0 && (e2 = [this.options[0].value]), e2) for (const i of e2) {
673
+ const n = s.findIndex((o) => o.value === i);
674
+ n !== -1 && (this.toggleSelected(i), this.#s = n);
675
+ }
676
+ this.focusedValue = this.options[this.#s]?.value, this.on("key", (i, n) => this.#e(i, n)), this.on("userInput", (i) => this.#i(i));
677
+ }
678
+ _isActionKey(t, s) {
679
+ return t === " " || this.multiple && this.isNavigating && s.name === "space" && t !== void 0 && t !== "";
680
+ }
681
+ #e(t, s) {
682
+ const e2 = s.name === "up", i = s.name === "down", n = s.name === "return", o = this.userInput === "" || this.userInput === " ", u = this.#u, a = this.options, l = u !== void 0 && u !== "" && a.some((f) => !f.disabled && (this.#t ? this.#t(u, f) : true));
683
+ if (s.name === "tab" && o && l) {
684
+ this.userInput === " " && this._clearUserInput(), this._setUserInput(u, true), this.isNavigating = false;
685
+ return;
686
+ }
687
+ e2 || i ? (this.#s = d(this.#s, e2 ? -1 : 1, this.filteredOptions), this.focusedValue = this.filteredOptions[this.#s]?.value, this.multiple || (this.selectedValues = [this.focusedValue]), this.isNavigating = true) : n ? this.value = H(this.multiple, this.selectedValues) : this.multiple ? this.focusedValue !== void 0 && (s.name === "tab" || this.isNavigating && s.name === "space") ? this.toggleSelected(this.focusedValue) : this.isNavigating = false : (this.focusedValue && (this.selectedValues = [this.focusedValue]), this.isNavigating = false);
688
+ }
689
+ deselectAll() {
690
+ this.selectedValues = [];
691
+ }
692
+ toggleSelected(t) {
693
+ this.filteredOptions.length !== 0 && (this.multiple ? this.selectedValues.includes(t) ? this.selectedValues = this.selectedValues.filter((s) => s !== t) : this.selectedValues = [...this.selectedValues, t] : this.selectedValues = [t]);
694
+ }
695
+ #i(t) {
696
+ if (t !== this.#r) {
697
+ this.#r = t;
698
+ const s = this.options;
699
+ t && this.#t ? this.filteredOptions = s.filter((n) => this.#t?.(t, n)) : this.filteredOptions = [...s];
700
+ const e2 = B(this.focusedValue, this.filteredOptions);
701
+ this.#s = d(e2, 0, this.filteredOptions);
702
+ const i = this.filteredOptions[this.#s];
703
+ i && !i.disabled ? this.focusedValue = i.value : this.focusedValue = void 0, this.multiple || (this.focusedValue !== void 0 ? this.toggleSelected(this.focusedValue) : this.deselectAll());
704
+ }
705
+ }
706
+ };
707
+ var X = class extends p {
708
+ get cursor() {
709
+ return this.value ? 0 : 1;
710
+ }
711
+ get _value() {
712
+ return this.cursor === 0;
713
+ }
714
+ constructor(t) {
715
+ super(t, false), this.value = !!t.initialValue, this.on("userInput", () => {
716
+ this.value = this._value;
717
+ }), this.on("confirm", (s) => {
718
+ this.output.write(import_sisteransi.cursor.move(0, -1)), this.value = s, this.state = "submit", this.close();
719
+ }), this.on("cursor", () => {
720
+ this.value = !this.value;
721
+ });
722
+ }
723
+ };
724
+ var Z = { Y: { type: "year", len: 4 }, M: { type: "month", len: 2 }, D: { type: "day", len: 2 } };
725
+ function P(r) {
726
+ return [...r].map((t) => Z[t]);
727
+ }
728
+ function tt(r) {
729
+ const t = new Intl.DateTimeFormat(r, { year: "numeric", month: "2-digit", day: "2-digit" }).formatToParts(new Date(2e3, 0, 15)), s = [];
730
+ let e2 = "/";
731
+ for (const i of t) i.type === "literal" ? e2 = i.value.trim() || i.value : (i.type === "year" || i.type === "month" || i.type === "day") && s.push({ type: i.type, len: i.type === "year" ? 4 : 2 });
732
+ return { segments: s, separator: e2 };
733
+ }
734
+ function U(r) {
735
+ return Number.parseInt((r || "0").replace(/_/g, "0"), 10) || 0;
736
+ }
737
+ function x(r) {
738
+ return { year: U(r.year), month: U(r.month), day: U(r.day) };
739
+ }
740
+ function $(r, t) {
741
+ return new Date(r || 2001, t || 1, 0).getDate();
742
+ }
743
+ function F(r) {
744
+ const { year: t, month: s, day: e2 } = x(r);
745
+ if (!t || t < 0 || t > 9999 || !s || s < 1 || s > 12 || !e2 || e2 < 1) return;
746
+ const i = new Date(Date.UTC(t, s - 1, e2));
747
+ if (!(i.getUTCFullYear() !== t || i.getUTCMonth() !== s - 1 || i.getUTCDate() !== e2)) return { year: t, month: s, day: e2 };
748
+ }
749
+ function N(r) {
750
+ const t = F(r);
751
+ return t ? new Date(Date.UTC(t.year, t.month - 1, t.day)) : void 0;
752
+ }
753
+ function st(r, t, s, e2) {
754
+ const i = s ? { year: s.getUTCFullYear(), month: s.getUTCMonth() + 1, day: s.getUTCDate() } : null, n = e2 ? { year: e2.getUTCFullYear(), month: e2.getUTCMonth() + 1, day: e2.getUTCDate() } : null;
755
+ return r === "year" ? { min: i?.year ?? 1, max: n?.year ?? 9999 } : r === "month" ? { min: i && t.year === i.year ? i.month : 1, max: n && t.year === n.year ? n.month : 12 } : { min: i && t.year === i.year && t.month === i.month ? i.day : 1, max: n && t.year === n.year && t.month === n.month ? n.day : $(t.year, t.month) };
756
+ }
757
+ var et = class extends p {
758
+ #s;
759
+ #r;
760
+ #t;
761
+ #n;
762
+ #u;
763
+ #e = { segmentIndex: 0, positionInSegment: 0 };
764
+ #i = true;
765
+ #o = null;
766
+ inlineError = "";
767
+ get segmentCursor() {
768
+ return { ...this.#e };
769
+ }
770
+ get segmentValues() {
771
+ return { ...this.#t };
772
+ }
773
+ get segments() {
774
+ return this.#s;
775
+ }
776
+ get separator() {
777
+ return this.#r;
778
+ }
779
+ get formattedValue() {
780
+ return this.#c(this.#t);
781
+ }
782
+ #c(t) {
783
+ return this.#s.map((s) => t[s.type]).join(this.#r);
784
+ }
785
+ #a() {
786
+ this._setUserInput(this.#c(this.#t)), this._setValue(N(this.#t) ?? void 0);
787
+ }
788
+ constructor(t) {
789
+ const s = t.format ? { segments: P(t.format), separator: t.separator ?? "/" } : tt(t.locale), e2 = t.separator ?? s.separator, i = t.format ? P(t.format) : s.segments, n = t.initialValue ?? t.defaultValue, o = n ? { year: String(n.getUTCFullYear()).padStart(4, "0"), month: String(n.getUTCMonth() + 1).padStart(2, "0"), day: String(n.getUTCDate()).padStart(2, "0") } : { year: "____", month: "__", day: "__" }, u = i.map((a) => o[a.type]).join(e2);
790
+ super({ ...t, initialUserInput: u }, false), this.#s = i, this.#r = e2, this.#t = o, this.#n = t.minDate, this.#u = t.maxDate, this.#a(), this.on("cursor", (a) => this.#d(a)), this.on("key", (a, l) => this.#f(a, l)), this.on("finalize", () => this.#g(t));
791
+ }
792
+ #h() {
793
+ const t = Math.max(0, Math.min(this.#e.segmentIndex, this.#s.length - 1)), s = this.#s[t];
794
+ if (s) return this.#e.positionInSegment = Math.max(0, Math.min(this.#e.positionInSegment, s.len - 1)), { segment: s, index: t };
795
+ }
796
+ #l(t) {
797
+ this.inlineError = "", this.#o = null;
798
+ const s = this.#h();
799
+ s && (this.#e.segmentIndex = Math.max(0, Math.min(this.#s.length - 1, s.index + t)), this.#e.positionInSegment = 0, this.#i = true);
800
+ }
801
+ #p(t) {
802
+ const s = this.#h();
803
+ if (!s) return;
804
+ const { segment: e2 } = s, i = this.#t[e2.type], n = !i || i.replace(/_/g, "") === "", o = Number.parseInt((i || "0").replace(/_/g, "0"), 10) || 0, u = st(e2.type, x(this.#t), this.#n, this.#u);
805
+ let a;
806
+ n ? a = t === 1 ? u.min : u.max : a = Math.max(Math.min(u.max, o + t), u.min), this.#t = { ...this.#t, [e2.type]: a.toString().padStart(e2.len, "0") }, this.#i = true, this.#o = null, this.#a();
807
+ }
808
+ #d(t) {
809
+ if (t) switch (t) {
810
+ case "right":
811
+ return this.#l(1);
812
+ case "left":
813
+ return this.#l(-1);
814
+ case "up":
815
+ return this.#p(1);
816
+ case "down":
817
+ return this.#p(-1);
818
+ }
819
+ }
820
+ #f(t, s) {
821
+ if (s?.name === "backspace" || s?.sequence === "\x7F" || s?.sequence === "\b" || t === "\x7F" || t === "\b") {
822
+ this.inlineError = "";
823
+ const e2 = this.#h();
824
+ if (!e2) return;
825
+ if (!this.#t[e2.segment.type].replace(/_/g, "")) {
826
+ this.#l(-1);
827
+ return;
828
+ }
829
+ this.#t[e2.segment.type] = "_".repeat(e2.segment.len), this.#i = true, this.#e.positionInSegment = 0, this.#a();
830
+ return;
831
+ }
832
+ if (s?.name === "tab") {
833
+ this.inlineError = "";
834
+ const e2 = this.#h();
835
+ if (!e2) return;
836
+ const i = s.shift ? -1 : 1, n = e2.index + i;
837
+ n >= 0 && n < this.#s.length && (this.#e.segmentIndex = n, this.#e.positionInSegment = 0, this.#i = true);
838
+ return;
839
+ }
840
+ if (t && /^[0-9]$/.test(t)) {
841
+ const e2 = this.#h();
842
+ if (!e2) return;
843
+ const { segment: i } = e2, n = !this.#t[i.type].replace(/_/g, "");
844
+ if (this.#i && this.#o !== null && !n) {
845
+ const m = this.#o + t, g = { ...this.#t, [i.type]: m }, _ = this.#m(g, i);
846
+ if (_) {
847
+ this.inlineError = _, this.#o = null, this.#i = false;
848
+ return;
849
+ }
850
+ this.inlineError = "", this.#t[i.type] = m, this.#o = null, this.#i = false, this.#a(), e2.index < this.#s.length - 1 && (this.#e.segmentIndex = e2.index + 1, this.#e.positionInSegment = 0, this.#i = true);
851
+ return;
852
+ }
853
+ this.#i && !n && (this.#t[i.type] = "_".repeat(i.len), this.#e.positionInSegment = 0), this.#i = false, this.#o = null;
854
+ const o = this.#t[i.type], u = o.indexOf("_"), a = u >= 0 ? u : Math.min(this.#e.positionInSegment, i.len - 1);
855
+ if (a < 0 || a >= i.len) return;
856
+ let l = o.slice(0, a) + t + o.slice(a + 1), f = false;
857
+ if (a === 0 && o === "__" && (i.type === "month" || i.type === "day")) {
858
+ const m = Number.parseInt(t, 10);
859
+ l = `0${t}`, f = m <= (i.type === "month" ? 1 : 2);
860
+ }
861
+ if (i.type === "year" && (l = (o.replace(/_/g, "") + t).padStart(i.len, "_")), !l.includes("_")) {
862
+ const m = { ...this.#t, [i.type]: l }, g = this.#m(m, i);
863
+ if (g) {
864
+ this.inlineError = g;
865
+ return;
866
+ }
867
+ }
868
+ this.inlineError = "", this.#t[i.type] = l;
869
+ const y = l.includes("_") ? void 0 : F(this.#t);
870
+ if (y) {
871
+ const { year: m, month: g } = y, _ = $(m, g);
872
+ this.#t = { year: String(Math.max(0, Math.min(9999, m))).padStart(4, "0"), month: String(Math.max(1, Math.min(12, g))).padStart(2, "0"), day: String(Math.max(1, Math.min(_, y.day))).padStart(2, "0") };
873
+ }
874
+ this.#a();
875
+ const T = l.indexOf("_");
876
+ f ? (this.#i = true, this.#o = t) : T >= 0 ? this.#e.positionInSegment = T : u >= 0 && e2.index < this.#s.length - 1 ? (this.#e.segmentIndex = e2.index + 1, this.#e.positionInSegment = 0, this.#i = true) : this.#e.positionInSegment = Math.min(a + 1, i.len - 1);
877
+ }
878
+ }
879
+ #m(t, s) {
880
+ const { month: e2, day: i } = x(t);
881
+ if (s.type === "month" && (e2 < 0 || e2 > 12)) return h.date.messages.invalidMonth;
882
+ if (s.type === "day" && (i < 0 || i > 31)) return h.date.messages.invalidDay(31, "any month");
883
+ }
884
+ #g(t) {
885
+ const { year: s, month: e2, day: i } = x(this.#t);
886
+ if (s && e2 && i) {
887
+ const n = $(s, e2);
888
+ this.#t = { ...this.#t, day: String(Math.min(i, n)).padStart(2, "0") };
889
+ }
890
+ this.value = N(this.#t) ?? t.defaultValue ?? void 0;
891
+ }
892
+ };
893
+ var it = class extends p {
894
+ options;
895
+ cursor = 0;
896
+ #s;
897
+ getGroupItems(t) {
898
+ return this.options.filter((s) => s.group === t);
899
+ }
900
+ isGroupSelected(t) {
901
+ const s = this.getGroupItems(t), e2 = this.value;
902
+ return e2 === void 0 ? false : s.every((i) => e2.includes(i.value));
903
+ }
904
+ toggleValue() {
905
+ const t = this.options[this.cursor];
906
+ if (this.value === void 0 && (this.value = []), t.group === true) {
907
+ const s = t.value, e2 = this.getGroupItems(s);
908
+ this.isGroupSelected(s) ? this.value = this.value.filter((i) => e2.findIndex((n) => n.value === i) === -1) : this.value = [...this.value, ...e2.map((i) => i.value)], this.value = Array.from(new Set(this.value));
909
+ } else {
910
+ const s = this.value.includes(t.value);
911
+ this.value = s ? this.value.filter((e2) => e2 !== t.value) : [...this.value, t.value];
912
+ }
913
+ }
914
+ constructor(t) {
915
+ super(t, false);
916
+ const { options: s } = t;
917
+ this.#s = t.selectableGroups !== false, this.options = Object.entries(s).flatMap(([e2, i]) => [{ value: e2, group: true, label: e2 }, ...i.map((n) => ({ ...n, group: e2 }))]), this.value = [...t.initialValues ?? []], this.cursor = Math.max(this.options.findIndex(({ value: e2 }) => e2 === t.cursorAt), this.#s ? 0 : 1), this.on("cursor", (e2) => {
918
+ switch (e2) {
919
+ case "left":
920
+ case "up": {
921
+ this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1;
922
+ const i = this.options[this.cursor]?.group === true;
923
+ !this.#s && i && (this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1);
924
+ break;
925
+ }
926
+ case "down":
927
+ case "right": {
928
+ this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1;
929
+ const i = this.options[this.cursor]?.group === true;
930
+ !this.#s && i && (this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1);
931
+ break;
932
+ }
933
+ case "space":
934
+ this.toggleValue();
935
+ break;
936
+ }
937
+ });
938
+ }
939
+ };
940
+ var rt = class extends p {
941
+ #s = false;
942
+ #r;
943
+ focused = "editor";
944
+ get userInputWithCursor() {
945
+ if (this.state === "submit") return this.userInput;
946
+ const t = this.userInput;
947
+ if (this.cursor >= t.length) return `${t}\u2588`;
948
+ const s = t.slice(0, this.cursor), e2 = t[this.cursor], i = t.slice(this.cursor + 1);
949
+ return e2 === `
950
+ ` ? `${s}\u2588
951
+ ${i}` : `${s}${v("inverse", e2)}${i}`;
952
+ }
953
+ get cursor() {
954
+ return this._cursor;
955
+ }
956
+ #t(t) {
957
+ if (this.userInput.length === 0) {
958
+ this._setUserInput(t);
959
+ return;
960
+ }
961
+ this._setUserInput(this.userInput.slice(0, this.cursor) + t + this.userInput.slice(this.cursor));
962
+ }
963
+ #n(t) {
964
+ const s = this.value ?? "";
965
+ switch (t) {
966
+ case "up":
967
+ this._cursor = I(this._cursor, 0, -1, s);
968
+ return;
969
+ case "down":
970
+ this._cursor = I(this._cursor, 0, 1, s);
971
+ return;
972
+ case "left":
973
+ this._cursor = I(this._cursor, -1, 0, s);
974
+ return;
975
+ case "right":
976
+ this._cursor = I(this._cursor, 1, 0, s);
977
+ return;
978
+ }
979
+ }
980
+ _shouldSubmit(t, s) {
981
+ if (this.#r) return this.focused === "submit" ? true : (this.#t(`
982
+ `), this._cursor++, false);
983
+ const e2 = this.#s;
984
+ return this.#s = true, e2 ? (this.userInput[this.cursor - 1] === `
985
+ ` && (this._setUserInput(this.userInput.slice(0, this.cursor - 1) + this.userInput.slice(this.cursor)), this._cursor--), true) : (this.#t(`
986
+ `), this._cursor++, false);
987
+ }
988
+ constructor(t) {
989
+ super(t, false), this.#r = t.showSubmit ?? false, this.on("key", (s, e2) => {
990
+ if (e2?.name && h.actions.has(e2.name)) {
991
+ this.#n(e2.name);
992
+ return;
993
+ }
994
+ if (s === " " && this.#r) {
995
+ this.focused = this.focused === "editor" ? "submit" : "editor";
996
+ return;
997
+ }
998
+ if (e2?.name !== "return") {
999
+ if (this.#s = false, e2?.name === "backspace" && this.cursor > 0) {
1000
+ this._setUserInput(this.userInput.slice(0, this.cursor - 1) + this.userInput.slice(this.cursor)), this._cursor--;
1001
+ return;
1002
+ }
1003
+ if (e2?.name === "delete" && this.cursor < this.userInput.length) {
1004
+ this._setUserInput(this.userInput.slice(0, this.cursor) + this.userInput.slice(this.cursor + 1));
1005
+ return;
1006
+ }
1007
+ s && (this.#r && this.focused === "submit" && (this.focused = "editor"), this.#t(s ?? ""), this._cursor++);
1008
+ }
1009
+ }), this.on("userInput", (s) => {
1010
+ this._setValue(s);
1011
+ }), this.on("finalize", () => {
1012
+ this.value || (this.value = t.defaultValue), this.value === void 0 && (this.value = "");
1013
+ });
1014
+ }
1015
+ };
1016
+ var nt = class extends p {
1017
+ options;
1018
+ cursor = 0;
1019
+ get _value() {
1020
+ return this.options[this.cursor].value;
1021
+ }
1022
+ get _enabledOptions() {
1023
+ return this.options.filter((t) => t.disabled !== true);
1024
+ }
1025
+ toggleAll() {
1026
+ const t = this._enabledOptions, s = this.value !== void 0 && this.value.length === t.length;
1027
+ this.value = s ? [] : t.map((e2) => e2.value);
1028
+ }
1029
+ toggleInvert() {
1030
+ const t = this.value;
1031
+ if (!t) return;
1032
+ const s = this._enabledOptions.filter((e2) => !t.includes(e2.value));
1033
+ this.value = s.map((e2) => e2.value);
1034
+ }
1035
+ toggleValue() {
1036
+ this.value === void 0 && (this.value = []);
1037
+ const t = this.value.includes(this._value);
1038
+ this.value = t ? this.value.filter((s) => s !== this._value) : [...this.value, this._value];
1039
+ }
1040
+ constructor(t) {
1041
+ super(t, false), this.options = t.options, this.value = [...t.initialValues ?? []];
1042
+ const s = Math.max(this.options.findIndex(({ value: e2 }) => e2 === t.cursorAt), 0);
1043
+ this.cursor = this.options[s].disabled ? d(s, 1, this.options) : s, this.on("key", (e2) => {
1044
+ e2 === "a" && this.toggleAll(), e2 === "i" && this.toggleInvert();
1045
+ }), this.on("cursor", (e2) => {
1046
+ switch (e2) {
1047
+ case "left":
1048
+ case "up":
1049
+ this.cursor = d(this.cursor, -1, this.options);
1050
+ break;
1051
+ case "down":
1052
+ case "right":
1053
+ this.cursor = d(this.cursor, 1, this.options);
1054
+ break;
1055
+ case "space":
1056
+ this.toggleValue();
1057
+ break;
1058
+ }
1059
+ });
1060
+ }
1061
+ };
1062
+ var ot = class extends p {
1063
+ _mask = "\u2022";
1064
+ get cursor() {
1065
+ return this._cursor;
1066
+ }
1067
+ get masked() {
1068
+ return this.userInput.replaceAll(/./g, this._mask);
1069
+ }
1070
+ get userInputWithCursor() {
1071
+ if (this.state === "submit" || this.state === "cancel") return this.masked;
1072
+ const t = this.userInput;
1073
+ if (this.cursor >= t.length) return `${this.masked}${v(["inverse", "hidden"], "_")}`;
1074
+ const s = this.masked, e2 = s.slice(0, this.cursor), i = s.slice(this.cursor);
1075
+ return `${e2}${v("inverse", i[0])}${i.slice(1)}`;
1076
+ }
1077
+ clear() {
1078
+ this._clearUserInput();
1079
+ }
1080
+ constructor({ mask: t, ...s }) {
1081
+ super(s), this._mask = t ?? "\u2022", this.on("userInput", (e2) => {
1082
+ this._setValue(e2);
1083
+ });
1084
+ }
1085
+ };
1086
+ var ut = class extends p {
1087
+ options;
1088
+ cursor = 0;
1089
+ get _selectedValue() {
1090
+ return this.options[this.cursor];
1091
+ }
1092
+ changeValue() {
1093
+ this.value = this._selectedValue.value;
1094
+ }
1095
+ constructor(t) {
1096
+ super(t, false), this.options = t.options;
1097
+ const s = this.options.findIndex(({ value: i }) => i === t.initialValue), e2 = s === -1 ? 0 : s;
1098
+ this.cursor = this.options[e2].disabled ? d(e2, 1, this.options) : e2, this.changeValue(), this.on("cursor", (i) => {
1099
+ switch (i) {
1100
+ case "left":
1101
+ case "up":
1102
+ this.cursor = d(this.cursor, -1, this.options);
1103
+ break;
1104
+ case "down":
1105
+ case "right":
1106
+ this.cursor = d(this.cursor, 1, this.options);
1107
+ break;
1108
+ }
1109
+ this.changeValue();
1110
+ });
1111
+ }
1112
+ };
1113
+ var at = class extends p {
1114
+ options;
1115
+ cursor = 0;
1116
+ constructor(t) {
1117
+ super(t, false), this.options = t.options;
1118
+ const s = t.caseSensitive === true, e2 = this.options.map(({ value: [i] }) => s ? i : i?.toLowerCase());
1119
+ this.cursor = Math.max(e2.indexOf(t.initialValue), 0), this.on("key", (i, n) => {
1120
+ if (!i) return;
1121
+ const o = s && n.shift ? i.toUpperCase() : i;
1122
+ if (!e2.includes(o)) return;
1123
+ const u = this.options.find(({ value: [a] }) => s ? a === o : a?.toLowerCase() === i);
1124
+ u && (this.value = u.value, this.state = "submit", this.emit("submit"));
1125
+ });
1126
+ }
1127
+ };
1128
+ var ht = class extends p {
1129
+ get userInputWithCursor() {
1130
+ if (this.state === "submit") return this.userInput;
1131
+ const t = this.userInput;
1132
+ if (this.cursor >= t.length) return `${this.userInput}\u2588`;
1133
+ const s = t.slice(0, this.cursor), [e2, ...i] = t.slice(this.cursor);
1134
+ return `${s}${v("inverse", e2)}${i.join("")}`;
1135
+ }
1136
+ get cursor() {
1137
+ return this._cursor;
1138
+ }
1139
+ constructor(t) {
1140
+ super({ ...t, initialUserInput: t.initialUserInput ?? t.initialValue }), this.on("userInput", (s) => {
1141
+ this._setValue(s);
1142
+ }), this.on("finalize", () => {
1143
+ this.value || (this.value = t.defaultValue), this.value === void 0 && (this.value = "");
1144
+ });
1145
+ }
1146
+ };
1147
+
1148
+ // ../../node_modules/.bun/@clack+prompts@1.3.0/node_modules/@clack/prompts/dist/index.mjs
1149
+ import { styleText as e, stripVTControlCharacters as nt2 } from "util";
1150
+ import j2 from "process";
1151
+ var import_sisteransi2 = __toESM(require_src(), 1);
1152
+ import { existsSync as zt, lstatSync as wt, readdirSync as Qt } from "fs";
1153
+ import { dirname as bt, join as Zt } from "path";
1154
+ function te() {
1155
+ return j2.platform !== "win32" ? j2.env.TERM !== "linux" : !!j2.env.CI || !!j2.env.WT_SESSION || !!j2.env.TERMINUS_SUBLIME || j2.env.ConEmuTask === "{cmd::Cmder}" || j2.env.TERM_PROGRAM === "Terminus-Sublime" || j2.env.TERM_PROGRAM === "vscode" || j2.env.TERM === "xterm-256color" || j2.env.TERM === "alacritty" || j2.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
1156
+ }
1157
+ var tt2 = te();
1158
+ var at2 = () => process.env.CI === "true";
1159
+ var Tt = (t) => t.isTTY === true;
1160
+ var w2 = (t, r) => tt2 ? t : r;
1161
+ var _t = w2("\u25C6", "*");
1162
+ var ot2 = w2("\u25A0", "x");
1163
+ var ut2 = w2("\u25B2", "x");
1164
+ var F2 = w2("\u25C7", "o");
1165
+ var lt = w2("\u250C", "T");
1166
+ var $2 = w2("\u2502", "|");
1167
+ var E2 = w2("\u2514", "\u2014");
1168
+ var It = w2("\u2510", "T");
1169
+ var Et = w2("\u2518", "\u2014");
1170
+ var z2 = w2("\u25CF", ">");
1171
+ var H2 = w2("\u25CB", " ");
1172
+ var et2 = w2("\u25FB", "[\u2022]");
1173
+ var U2 = w2("\u25FC", "[+]");
1174
+ var J2 = w2("\u25FB", "[ ]");
1175
+ var Gt = w2("\u25AA", "\u2022");
1176
+ var st2 = w2("\u2500", "-");
1177
+ var ct = w2("\u256E", "+");
1178
+ var xt = w2("\u251C", "+");
1179
+ var $t = w2("\u256F", "+");
1180
+ var dt = w2("\u2570", "+");
1181
+ var Ot = w2("\u256D", "+");
1182
+ var ht2 = w2("\u25CF", "\u2022");
1183
+ var pt = w2("\u25C6", "*");
1184
+ var mt = w2("\u25B2", "!");
1185
+ var gt = w2("\u25A0", "x");
1186
+ var M = (t) => {
1187
+ switch (t) {
1188
+ case "initial":
1189
+ case "active":
1190
+ return e("cyan", _t);
1191
+ case "cancel":
1192
+ return e("red", ot2);
1193
+ case "error":
1194
+ return e("yellow", ut2);
1195
+ case "submit":
1196
+ return e("green", F2);
1197
+ }
1198
+ };
1199
+ var yt = (t) => {
1200
+ switch (t) {
1201
+ case "initial":
1202
+ case "active":
1203
+ return e("cyan", $2);
1204
+ case "cancel":
1205
+ return e("red", $2);
1206
+ case "error":
1207
+ return e("yellow", $2);
1208
+ case "submit":
1209
+ return e("green", $2);
1210
+ }
1211
+ };
1212
+ var ee = (t, r, s, i, u) => {
1213
+ let n = r, o = 0;
1214
+ for (let c2 = s; c2 < i; c2++) {
1215
+ const a = t[c2];
1216
+ if (n = n - a.length, o++, n <= u) break;
1217
+ }
1218
+ return { lineCount: n, removals: o };
1219
+ };
1220
+ var Y2 = ({ cursor: t, options: r, style: s, output: i = process.stdout, maxItems: u = Number.POSITIVE_INFINITY, columnPadding: n = 0, rowPadding: o = 4 }) => {
1221
+ const c2 = A(i) - n, a = L(i), l = e("dim", "..."), d2 = Math.max(a - o, 0), y = Math.max(Math.min(u, d2), 5);
1222
+ let p2 = 0;
1223
+ t >= y - 3 && (p2 = Math.max(Math.min(t - y + 3, r.length - y), 0));
1224
+ let m = y < r.length && p2 > 0, g = y < r.length && p2 + y < r.length;
1225
+ const S2 = Math.min(p2 + y, r.length), h2 = [];
1226
+ let f = 0;
1227
+ m && f++, g && f++;
1228
+ const v2 = p2 + (m ? 1 : 0), T = S2 - (g ? 1 : 0);
1229
+ for (let b2 = v2; b2 < T; b2++) {
1230
+ const G2 = wrapAnsi(s(r[b2], b2 === t), c2, { hard: true, trim: false }).split(`
1231
+ `);
1232
+ h2.push(G2), f += G2.length;
1233
+ }
1234
+ if (f > d2) {
1235
+ let b2 = 0, G2 = 0, x2 = f;
1236
+ const A2 = t - v2, P2 = (N2, D2) => ee(h2, x2, N2, D2, d2);
1237
+ m ? ({ lineCount: x2, removals: b2 } = P2(0, A2), x2 > d2 && ({ lineCount: x2, removals: G2 } = P2(A2 + 1, h2.length))) : ({ lineCount: x2, removals: G2 } = P2(A2 + 1, h2.length), x2 > d2 && ({ lineCount: x2, removals: b2 } = P2(0, A2))), b2 > 0 && (m = true, h2.splice(0, b2)), G2 > 0 && (g = true, h2.splice(h2.length - G2, G2));
1238
+ }
1239
+ const C2 = [];
1240
+ m && C2.push(l);
1241
+ for (const b2 of h2) for (const G2 of b2) C2.push(G2);
1242
+ return g && C2.push(l), C2;
1243
+ };
1244
+ function Mt(t) {
1245
+ return t.label ?? String(t.value ?? "");
1246
+ }
1247
+ function Rt(t, r) {
1248
+ if (!t) return true;
1249
+ const s = (r.label ?? String(r.value ?? "")).toLowerCase(), i = (r.hint ?? "").toLowerCase(), u = String(r.value).toLowerCase(), n = t.toLowerCase();
1250
+ return s.includes(n) || i.includes(n) || u.includes(n);
1251
+ }
1252
+ function se(t, r) {
1253
+ const s = [];
1254
+ for (const i of r) t.includes(i.value) && s.push(i);
1255
+ return s;
1256
+ }
1257
+ var At = (t) => new Q({ options: t.options, initialValue: t.initialValue ? [t.initialValue] : void 0, initialUserInput: t.initialUserInput, placeholder: t.placeholder, filter: t.filter ?? ((r, s) => Rt(r, s)), signal: t.signal, input: t.input, output: t.output, validate: t.validate, render() {
1258
+ const r = t.withGuide ?? h.withGuide, s = r ? [`${e("gray", $2)}`, `${M(this.state)} ${t.message}`] : [`${M(this.state)} ${t.message}`], i = this.userInput, u = this.options, n = t.placeholder, o = i === "" && n !== void 0, c2 = (a, l) => {
1259
+ const d2 = Mt(a), y = a.hint && a.value === this.focusedValue ? e("dim", ` (${a.hint})`) : "";
1260
+ switch (l) {
1261
+ case "active":
1262
+ return `${e("green", z2)} ${d2}${y}`;
1263
+ case "inactive":
1264
+ return `${e("dim", H2)} ${e("dim", d2)}`;
1265
+ case "disabled":
1266
+ return `${e("gray", H2)} ${e(["strikethrough", "gray"], d2)}`;
1267
+ }
1268
+ };
1269
+ switch (this.state) {
1270
+ case "submit": {
1271
+ const a = se(this.selectedValues, u), l = a.length > 0 ? ` ${e("dim", a.map(Mt).join(", "))}` : "", d2 = r ? e("gray", $2) : "";
1272
+ return `${s.join(`
1273
+ `)}
1274
+ ${d2}${l}`;
1275
+ }
1276
+ case "cancel": {
1277
+ const a = i ? ` ${e(["strikethrough", "dim"], i)}` : "", l = r ? e("gray", $2) : "";
1278
+ return `${s.join(`
1279
+ `)}
1280
+ ${l}${a}`;
1281
+ }
1282
+ default: {
1283
+ const a = this.state === "error" ? "yellow" : "cyan", l = r ? `${e(a, $2)} ` : "", d2 = r ? e(a, E2) : "";
1284
+ let y = "";
1285
+ if (this.isNavigating || o) {
1286
+ const v2 = o ? n : i;
1287
+ y = v2 !== "" ? ` ${e("dim", v2)}` : "";
1288
+ } else y = ` ${this.userInputWithCursor}`;
1289
+ const p2 = this.filteredOptions.length !== u.length ? e("dim", ` (${this.filteredOptions.length} match${this.filteredOptions.length === 1 ? "" : "es"})`) : "", m = this.filteredOptions.length === 0 && i ? [`${l}${e("yellow", "No matches found")}`] : [], g = this.state === "error" ? [`${l}${e("yellow", this.error)}`] : [];
1290
+ r && s.push(`${l.trimEnd()}`), s.push(`${l}${e("dim", "Search:")}${y}${p2}`, ...m, ...g);
1291
+ const S2 = [`${e("dim", "\u2191/\u2193")} to select`, `${e("dim", "Enter:")} confirm`, `${e("dim", "Type:")} to search`], h2 = [`${l}${S2.join(" \u2022 ")}`, d2], f = this.filteredOptions.length === 0 ? [] : Y2({ cursor: this.cursor, options: this.filteredOptions, columnPadding: r ? 3 : 0, rowPadding: s.length + h2.length, style: (v2, T) => c2(v2, v2.disabled ? "disabled" : T ? "active" : "inactive"), maxItems: t.maxItems, output: t.output });
1292
+ return [...s, ...f.map((v2) => `${l}${v2}`), ...h2].join(`
1293
+ `);
1294
+ }
1295
+ }
1296
+ } }).prompt();
1297
+ var ie = (t) => {
1298
+ const r = (i, u, n, o) => {
1299
+ const c2 = n.includes(i.value), a = i.label ?? String(i.value ?? ""), l = i.hint && o !== void 0 && i.value === o ? e("dim", ` (${i.hint})`) : "", d2 = c2 ? e("green", U2) : e("dim", J2);
1300
+ return i.disabled ? `${e("gray", J2)} ${e(["strikethrough", "gray"], a)}` : u ? `${d2} ${a}${l}` : `${d2} ${e("dim", a)}`;
1301
+ }, s = new Q({ options: t.options, multiple: true, placeholder: t.placeholder, filter: t.filter ?? ((i, u) => Rt(i, u)), validate: () => {
1302
+ if (t.required && s.selectedValues.length === 0) return "Please select at least one item";
1303
+ }, initialValue: t.initialValues, signal: t.signal, input: t.input, output: t.output, render() {
1304
+ const i = t.withGuide ?? h.withGuide, u = `${i ? `${e("gray", $2)}
1305
+ ` : ""}${M(this.state)} ${t.message}
1306
+ `, n = this.userInput, o = t.placeholder, c2 = n === "" && o !== void 0, a = this.isNavigating || c2 ? e("dim", c2 ? o : n) : this.userInputWithCursor, l = this.options, d2 = this.filteredOptions.length !== l.length ? e("dim", ` (${this.filteredOptions.length} match${this.filteredOptions.length === 1 ? "" : "es"})`) : "";
1307
+ switch (this.state) {
1308
+ case "submit":
1309
+ return `${u}${i ? `${e("gray", $2)} ` : ""}${e("dim", `${this.selectedValues.length} items selected`)}`;
1310
+ case "cancel":
1311
+ return `${u}${i ? `${e("gray", $2)} ` : ""}${e(["strikethrough", "dim"], n)}`;
1312
+ default: {
1313
+ const y = this.state === "error" ? "yellow" : "cyan", p2 = i ? `${e(y, $2)} ` : "", m = i ? e(y, E2) : "", g = [`${e("dim", "\u2191/\u2193")} to navigate`, `${e("dim", this.isNavigating ? "Space/Tab:" : "Tab:")} select`, `${e("dim", "Enter:")} confirm`, `${e("dim", "Type:")} to search`], S2 = this.filteredOptions.length === 0 && n ? [`${p2}${e("yellow", "No matches found")}`] : [], h2 = this.state === "error" ? [`${p2}${e("yellow", this.error)}`] : [], f = [...`${u}${i ? e(y, $2) : ""}`.split(`
1314
+ `), `${p2}${e("dim", "Search:")} ${a}${d2}`, ...S2, ...h2], v2 = [`${p2}${g.join(" \u2022 ")}`, m], T = Y2({ cursor: this.cursor, options: this.filteredOptions, style: (C2, b2) => r(C2, b2, this.selectedValues, this.focusedValue), maxItems: t.maxItems, output: t.output, rowPadding: f.length + v2.length });
1315
+ return [...f, ...T.map((C2) => `${p2}${C2}`), ...v2].join(`
1316
+ `);
1317
+ }
1318
+ }
1319
+ } });
1320
+ return s.prompt();
1321
+ };
1322
+ var re = [Ot, ct, dt, $t];
1323
+ var ne = [lt, It, E2, Et];
1324
+ function Pt(t, r, s, i) {
1325
+ let u = s, n = s;
1326
+ return i === "center" ? u = Math.floor((r - t) / 2) : i === "right" && (u = r - t - s), n = r - u - t, [u, n];
1327
+ }
1328
+ var ae = (t) => t;
1329
+ var oe = (t = "", r = "", s) => {
1330
+ const i = s?.output ?? process.stdout, u = A(i), n = 2, o = s?.titlePadding ?? 1, c2 = s?.contentPadding ?? 2, a = s?.width === void 0 || s.width === "auto" ? 1 : Math.min(1, s.width), l = s?.withGuide ?? h.withGuide ? `${$2} ` : "", d2 = s?.formatBorder ?? ae, y = (s?.rounded ? re : ne).map(d2), p2 = d2(st2), m = d2($2), g = dist_default2(l), S2 = dist_default2(r), h2 = u - g;
1331
+ let f = Math.floor(u * a) - g;
1332
+ if (s?.width === "auto") {
1333
+ const P2 = t.split(`
1334
+ `);
1335
+ let N2 = S2 + o * 2;
1336
+ for (const rt2 of P2) {
1337
+ const W2 = dist_default2(rt2) + c2 * 2;
1338
+ W2 > N2 && (N2 = W2);
1339
+ }
1340
+ const D2 = N2 + n;
1341
+ D2 < f && (f = D2);
1342
+ }
1343
+ f % 2 !== 0 && (f < h2 ? f++ : f--);
1344
+ const v2 = f - n, T = v2 - o * 2, C2 = S2 > T ? `${r.slice(0, T - 3)}...` : r, [b2, G2] = Pt(dist_default2(C2), v2, o, s?.titleAlign), x2 = wrapAnsi(t, v2 - c2 * 2, { hard: true, trim: false });
1345
+ i.write(`${l}${y[0]}${p2.repeat(b2)}${C2}${p2.repeat(G2)}${y[1]}
1346
+ `);
1347
+ const A2 = x2.split(`
1348
+ `);
1349
+ for (const P2 of A2) {
1350
+ const [N2, D2] = Pt(dist_default2(P2), v2, c2, s?.contentAlign);
1351
+ i.write(`${l}${m}${" ".repeat(N2)}${P2}${" ".repeat(D2)}${m}
1352
+ `);
1353
+ }
1354
+ i.write(`${l}${y[2]}${p2.repeat(v2)}${y[3]}
1355
+ `);
1356
+ };
1357
+ var ue = (t) => {
1358
+ const r = t.active ?? "Yes", s = t.inactive ?? "No";
1359
+ return new X({ active: r, inactive: s, signal: t.signal, input: t.input, output: t.output, initialValue: t.initialValue ?? true, render() {
1360
+ const i = t.withGuide ?? h.withGuide, u = `${M(this.state)} `, n = i ? `${e("gray", $2)} ` : "", o = W(t.output, t.message, n, u), c2 = `${i ? `${e("gray", $2)}
1361
+ ` : ""}${o}
1362
+ `, a = this.value ? r : s;
1363
+ switch (this.state) {
1364
+ case "submit": {
1365
+ const l = i ? `${e("gray", $2)} ` : "";
1366
+ return `${c2}${l}${e("dim", a)}`;
1367
+ }
1368
+ case "cancel": {
1369
+ const l = i ? `${e("gray", $2)} ` : "";
1370
+ return `${c2}${l}${e(["strikethrough", "dim"], a)}${i ? `
1371
+ ${e("gray", $2)}` : ""}`;
1372
+ }
1373
+ default: {
1374
+ const l = i ? `${e("cyan", $2)} ` : "", d2 = i ? e("cyan", E2) : "";
1375
+ return `${c2}${l}${this.value ? `${e("green", z2)} ${r}` : `${e("dim", H2)} ${e("dim", r)}`}${t.vertical ? i ? `
1376
+ ${e("cyan", $2)} ` : `
1377
+ ` : ` ${e("dim", "/")} `}${this.value ? `${e("dim", H2)} ${e("dim", s)}` : `${e("green", z2)} ${s}`}
1378
+ ${d2}
1379
+ `;
1380
+ }
1381
+ }
1382
+ } }).prompt();
1383
+ };
1384
+ var le = (t) => {
1385
+ const r = t.validate;
1386
+ return new et({ ...t, validate(s) {
1387
+ if (s === void 0) return t.defaultValue !== void 0 ? void 0 : r ? r(s) : h.date.messages.required;
1388
+ const i = (u) => u.toISOString().slice(0, 10);
1389
+ if (t.minDate && i(s) < i(t.minDate)) return h.date.messages.afterMin(t.minDate);
1390
+ if (t.maxDate && i(s) > i(t.maxDate)) return h.date.messages.beforeMax(t.maxDate);
1391
+ if (r) return r(s);
1392
+ }, render() {
1393
+ const s = (t?.withGuide ?? h.withGuide) !== false, i = `${`${s ? `${e("gray", $2)}
1394
+ ` : ""}${M(this.state)} `}${t.message}
1395
+ `, u = this.state !== "initial" ? this.state : "active", n = ce(this, u), o = this.value instanceof Date ? this.formattedValue : "";
1396
+ switch (this.state) {
1397
+ case "error": {
1398
+ const c2 = this.error ? ` ${e("yellow", this.error)}` : "", a = s ? `${e("yellow", $2)} ` : "", l = s ? e("yellow", E2) : "";
1399
+ return `${i.trim()}
1400
+ ${a}${n}
1401
+ ${l}${c2}
1402
+ `;
1403
+ }
1404
+ case "submit": {
1405
+ const c2 = o ? ` ${e("dim", o)}` : "", a = s ? e("gray", $2) : "";
1406
+ return `${i}${a}${c2}`;
1407
+ }
1408
+ case "cancel": {
1409
+ const c2 = o ? ` ${e(["strikethrough", "dim"], o)}` : "", a = s ? e("gray", $2) : "";
1410
+ return `${i}${a}${c2}${o.trim() ? `
1411
+ ${a}` : ""}`;
1412
+ }
1413
+ default: {
1414
+ const c2 = s ? `${e("cyan", $2)} ` : "", a = s ? e("cyan", E2) : "", l = s ? `${e("cyan", $2)} ` : "", d2 = this.inlineError ? `
1415
+ ${l}${e("yellow", this.inlineError)}` : "";
1416
+ return `${i}${c2}${n}${d2}
1417
+ ${a}
1418
+ `;
1419
+ }
1420
+ }
1421
+ } }).prompt();
1422
+ };
1423
+ function ce(t, r) {
1424
+ const s = t.segmentValues, i = t.segmentCursor;
1425
+ if (r === "submit" || r === "cancel") return t.formattedValue;
1426
+ const u = e("gray", t.separator);
1427
+ return t.segments.map((n, o) => {
1428
+ const c2 = o === i.segmentIndex && !["submit", "cancel"].includes(r), a = de[n.type];
1429
+ return $e(s[n.type], { isActive: c2, label: a });
1430
+ }).join(u);
1431
+ }
1432
+ function $e(t, r) {
1433
+ const s = !t || t.replace(/_/g, "") === "";
1434
+ return r.isActive ? e("inverse", s ? r.label : t.replace(/_/g, " ")) : s ? e("dim", r.label) : t.replace(/_/g, e("dim", " "));
1435
+ }
1436
+ var de = { year: "yyyy", month: "mm", day: "dd" };
1437
+ var he = async (t, r) => {
1438
+ const s = {}, i = Object.keys(t);
1439
+ for (const u of i) {
1440
+ const n = t[u], o = await n({ results: s })?.catch((c2) => {
1441
+ throw c2;
1442
+ });
1443
+ if (typeof r?.onCancel == "function" && q(o)) {
1444
+ s[u] = "canceled", r.onCancel({ results: s });
1445
+ continue;
1446
+ }
1447
+ s[u] = o;
1448
+ }
1449
+ return s;
1450
+ };
1451
+ var pe = (t) => {
1452
+ const { selectableGroups: r = true, groupSpacing: s = 0 } = t, i = (n, o, c2 = []) => {
1453
+ const a = n.label ?? String(n.value), l = typeof n.group == "string", d2 = l && (c2[c2.indexOf(n) + 1] ?? { group: true }), y = l && d2 && d2.group === true, p2 = l ? r ? `${y ? E2 : $2} ` : " " : "";
1454
+ let m = "";
1455
+ if (s > 0 && !l) {
1456
+ const S2 = `
1457
+ ${e("cyan", $2)}`;
1458
+ m = `${S2.repeat(s - 1)}${S2} `;
1459
+ }
1460
+ if (o === "active") return `${m}${e("dim", p2)}${e("cyan", et2)} ${a}${n.hint ? ` ${e("dim", `(${n.hint})`)}` : ""}`;
1461
+ if (o === "group-active") return `${m}${p2}${e("cyan", et2)} ${e("dim", a)}`;
1462
+ if (o === "group-active-selected") return `${m}${p2}${e("green", U2)} ${e("dim", a)}`;
1463
+ if (o === "selected") {
1464
+ const S2 = l || r ? e("green", U2) : "";
1465
+ return `${m}${e("dim", p2)}${S2} ${e("dim", a)}${n.hint ? ` ${e("dim", `(${n.hint})`)}` : ""}`;
1466
+ }
1467
+ if (o === "cancelled") return `${e(["strikethrough", "dim"], a)}`;
1468
+ if (o === "active-selected") return `${m}${e("dim", p2)}${e("green", U2)} ${a}${n.hint ? ` ${e("dim", `(${n.hint})`)}` : ""}`;
1469
+ if (o === "submitted") return `${e("dim", a)}`;
1470
+ const g = l || r ? e("dim", J2) : "";
1471
+ return `${m}${e("dim", p2)}${g} ${e("dim", a)}`;
1472
+ }, u = t.required ?? true;
1473
+ return new it({ options: t.options, signal: t.signal, input: t.input, output: t.output, initialValues: t.initialValues, required: u, cursorAt: t.cursorAt, selectableGroups: r, validate(n) {
1474
+ if (u && (n === void 0 || n.length === 0)) return `Please select at least one option.
1475
+ ${e("reset", e("dim", `Press ${e(["gray", "bgWhite", "inverse"], " space ")} to select, ${e("gray", e(["bgWhite", "inverse"], " enter "))} to submit`))}`;
1476
+ }, render() {
1477
+ const n = t.withGuide ?? h.withGuide, o = `${n ? `${e("gray", $2)}
1478
+ ` : ""}${M(this.state)} ${t.message}
1479
+ `, c2 = this.value ?? [];
1480
+ switch (this.state) {
1481
+ case "submit": {
1482
+ const a = this.options.filter(({ value: d2 }) => c2.includes(d2)).map((d2) => i(d2, "submitted")), l = a.length === 0 ? "" : ` ${a.join(e("dim", ", "))}`;
1483
+ return `${o}${n ? e("gray", $2) : ""}${l}`;
1484
+ }
1485
+ case "cancel": {
1486
+ const a = this.options.filter(({ value: l }) => c2.includes(l)).map((l) => i(l, "cancelled")).join(e("dim", ", "));
1487
+ return `${o}${n ? `${e("gray", $2)} ` : ""}${a.trim() ? `${a}${n ? `
1488
+ ${e("gray", $2)}` : ""}` : ""}`;
1489
+ }
1490
+ case "error": {
1491
+ const a = this.error.split(`
1492
+ `).map((l, d2) => d2 === 0 ? `${n ? `${e("yellow", E2)} ` : ""}${e("yellow", l)}` : ` ${l}`).join(`
1493
+ `);
1494
+ return `${o}${n ? `${e("yellow", $2)} ` : ""}${this.options.map((l, d2, y) => {
1495
+ const p2 = c2.includes(l.value) || l.group === true && this.isGroupSelected(`${l.value}`), m = d2 === this.cursor;
1496
+ return !m && typeof l.group == "string" && this.options[this.cursor].value === l.group ? i(l, p2 ? "group-active-selected" : "group-active", y) : m && p2 ? i(l, "active-selected", y) : p2 ? i(l, "selected", y) : i(l, m ? "active" : "inactive", y);
1497
+ }).join(`
1498
+ ${n ? `${e("yellow", $2)} ` : ""}`)}
1499
+ ${a}
1500
+ `;
1501
+ }
1502
+ default: {
1503
+ const a = this.options.map((d2, y, p2) => {
1504
+ const m = c2.includes(d2.value) || d2.group === true && this.isGroupSelected(`${d2.value}`), g = y === this.cursor, S2 = !g && typeof d2.group == "string" && this.options[this.cursor].value === d2.group;
1505
+ let h2 = "";
1506
+ return S2 ? h2 = i(d2, m ? "group-active-selected" : "group-active", p2) : g && m ? h2 = i(d2, "active-selected", p2) : m ? h2 = i(d2, "selected", p2) : h2 = i(d2, g ? "active" : "inactive", p2), `${y !== 0 && !h2.startsWith(`
1507
+ `) ? " " : ""}${h2}`;
1508
+ }).join(`
1509
+ ${n ? e("cyan", $2) : ""}`), l = a.startsWith(`
1510
+ `) ? "" : " ";
1511
+ return `${o}${n ? e("cyan", $2) : ""}${l}${a}
1512
+ ${n ? e("cyan", E2) : ""}
1513
+ `;
1514
+ }
1515
+ }
1516
+ } }).prompt();
1517
+ };
1518
+ var R2 = { message: (t = [], { symbol: r = e("gray", $2), secondarySymbol: s = e("gray", $2), output: i = process.stdout, spacing: u = 1, withGuide: n } = {}) => {
1519
+ const o = [], c2 = n ?? h.withGuide, a = c2 ? s : "", l = c2 ? `${r} ` : "", d2 = c2 ? `${s} ` : "";
1520
+ for (let p2 = 0; p2 < u; p2++) o.push(a);
1521
+ const y = Array.isArray(t) ? t : t.split(`
1522
+ `);
1523
+ if (y.length > 0) {
1524
+ const [p2, ...m] = y;
1525
+ p2.length > 0 ? o.push(`${l}${p2}`) : o.push(c2 ? r : "");
1526
+ for (const g of m) g.length > 0 ? o.push(`${d2}${g}`) : o.push(c2 ? s : "");
1527
+ }
1528
+ i.write(`${o.join(`
1529
+ `)}
1530
+ `);
1531
+ }, info: (t, r) => {
1532
+ R2.message(t, { ...r, symbol: e("blue", ht2) });
1533
+ }, success: (t, r) => {
1534
+ R2.message(t, { ...r, symbol: e("green", pt) });
1535
+ }, step: (t, r) => {
1536
+ R2.message(t, { ...r, symbol: e("green", F2) });
1537
+ }, warn: (t, r) => {
1538
+ R2.message(t, { ...r, symbol: e("yellow", mt) });
1539
+ }, warning: (t, r) => {
1540
+ R2.warn(t, r);
1541
+ }, error: (t, r) => {
1542
+ R2.message(t, { ...r, symbol: e("red", gt) });
1543
+ } };
1544
+ var me = (t = "", r) => {
1545
+ const s = r?.output ?? process.stdout, i = r?.withGuide ?? h.withGuide ? `${e("gray", E2)} ` : "";
1546
+ s.write(`${i}${e("red", t)}
1547
+
1548
+ `);
1549
+ };
1550
+ var ge = (t = "", r) => {
1551
+ const s = r?.output ?? process.stdout, i = r?.withGuide ?? h.withGuide ? `${e("gray", lt)} ` : "";
1552
+ s.write(`${i}${t}
1553
+ `);
1554
+ };
1555
+ var ye = (t = "", r) => {
1556
+ const s = r?.output ?? process.stdout, i = r?.withGuide ?? h.withGuide ? `${e("gray", $2)}
1557
+ ${e("gray", E2)} ` : "";
1558
+ s.write(`${i}${t}
1559
+
1560
+ `);
1561
+ };
1562
+ var fe = (t) => new rt({ validate: t.validate, placeholder: t.placeholder, defaultValue: t.defaultValue, initialValue: t.initialValue, showSubmit: t.showSubmit, output: t.output, signal: t.signal, input: t.input, render() {
1563
+ const r = t?.withGuide ?? h.withGuide, s = `${`${r ? `${e("gray", $2)}
1564
+ ` : ""}${M(this.state)} `}${t.message}
1565
+ `, i = t.placeholder ? e("inverse", t.placeholder[0]) + e("dim", t.placeholder.slice(1)) : e(["inverse", "hidden"], "_"), u = this.userInput ? this.userInputWithCursor : i, n = this.value ?? "", o = t.showSubmit ? `
1566
+ ${e(this.focused === "submit" ? "cyan" : "dim", "[ submit ]")}` : "";
1567
+ switch (this.state) {
1568
+ case "error": {
1569
+ const c2 = `${e("yellow", $2)} `, a = r ? W(t.output, u, c2, void 0) : u, l = e("yellow", E2);
1570
+ return `${s}${a}
1571
+ ${l} ${e("yellow", this.error)}${o}
1572
+ `;
1573
+ }
1574
+ case "submit": {
1575
+ const c2 = `${e("gray", $2)} `, a = r ? W(t.output, n, c2, void 0, (l) => e("dim", l)) : n ? e("dim", n) : "";
1576
+ return `${s}${a}`;
1577
+ }
1578
+ case "cancel": {
1579
+ const c2 = `${e("gray", $2)} `, a = r ? W(t.output, n, c2, void 0, (l) => e(["strikethrough", "dim"], l)) : n ? e(["strikethrough", "dim"], n) : "";
1580
+ return `${s}${a}`;
1581
+ }
1582
+ default: {
1583
+ const c2 = r ? `${e("cyan", $2)} ` : "", a = r ? e("cyan", E2) : "", l = r ? W(t.output, u, c2) : u;
1584
+ return `${s}${l}
1585
+ ${a}${o}
1586
+ `;
1587
+ }
1588
+ }
1589
+ } }).prompt();
1590
+ var Q2 = (t, r) => t.split(`
1591
+ `).map((s) => r(s)).join(`
1592
+ `);
1593
+ var ve = (t) => {
1594
+ const r = (i, u) => {
1595
+ const n = i.label ?? String(i.value);
1596
+ return u === "disabled" ? `${e("gray", J2)} ${Q2(n, (o) => e(["strikethrough", "gray"], o))}${i.hint ? ` ${e("dim", `(${i.hint ?? "disabled"})`)}` : ""}` : u === "active" ? `${e("cyan", et2)} ${n}${i.hint ? ` ${e("dim", `(${i.hint})`)}` : ""}` : u === "selected" ? `${e("green", U2)} ${Q2(n, (o) => e("dim", o))}${i.hint ? ` ${e("dim", `(${i.hint})`)}` : ""}` : u === "cancelled" ? `${Q2(n, (o) => e(["strikethrough", "dim"], o))}` : u === "active-selected" ? `${e("green", U2)} ${n}${i.hint ? ` ${e("dim", `(${i.hint})`)}` : ""}` : u === "submitted" ? `${Q2(n, (o) => e("dim", o))}` : `${e("dim", J2)} ${Q2(n, (o) => e("dim", o))}`;
1597
+ }, s = t.required ?? true;
1598
+ return new nt({ options: t.options, signal: t.signal, input: t.input, output: t.output, initialValues: t.initialValues, required: s, cursorAt: t.cursorAt, validate(i) {
1599
+ if (s && (i === void 0 || i.length === 0)) return `Please select at least one option.
1600
+ ${e("reset", e("dim", `Press ${e(["gray", "bgWhite", "inverse"], " space ")} to select, ${e("gray", e("bgWhite", e("inverse", " enter ")))} to submit`))}`;
1601
+ }, render() {
1602
+ const i = t.withGuide ?? h.withGuide, u = W(t.output, t.message, i ? `${yt(this.state)} ` : "", `${M(this.state)} `), n = `${i ? `${e("gray", $2)}
1603
+ ` : ""}${u}
1604
+ `, o = this.value ?? [], c2 = (a, l) => {
1605
+ if (a.disabled) return r(a, "disabled");
1606
+ const d2 = o.includes(a.value);
1607
+ return l && d2 ? r(a, "active-selected") : d2 ? r(a, "selected") : r(a, l ? "active" : "inactive");
1608
+ };
1609
+ switch (this.state) {
1610
+ case "submit": {
1611
+ const a = this.options.filter(({ value: d2 }) => o.includes(d2)).map((d2) => r(d2, "submitted")).join(e("dim", ", ")) || e("dim", "none"), l = W(t.output, a, i ? `${e("gray", $2)} ` : "");
1612
+ return `${n}${l}`;
1613
+ }
1614
+ case "cancel": {
1615
+ const a = this.options.filter(({ value: d2 }) => o.includes(d2)).map((d2) => r(d2, "cancelled")).join(e("dim", ", "));
1616
+ if (a.trim() === "") return `${n}${e("gray", $2)}`;
1617
+ const l = W(t.output, a, i ? `${e("gray", $2)} ` : "");
1618
+ return `${n}${l}${i ? `
1619
+ ${e("gray", $2)}` : ""}`;
1620
+ }
1621
+ case "error": {
1622
+ const a = i ? `${e("yellow", $2)} ` : "", l = this.error.split(`
1623
+ `).map((p2, m) => m === 0 ? `${i ? `${e("yellow", E2)} ` : ""}${e("yellow", p2)}` : ` ${p2}`).join(`
1624
+ `), d2 = n.split(`
1625
+ `).length, y = l.split(`
1626
+ `).length + 1;
1627
+ return `${n}${a}${Y2({ output: t.output, options: this.options, cursor: this.cursor, maxItems: t.maxItems, columnPadding: a.length, rowPadding: d2 + y, style: c2 }).join(`
1628
+ ${a}`)}
1629
+ ${l}
1630
+ `;
1631
+ }
1632
+ default: {
1633
+ const a = i ? `${e("cyan", $2)} ` : "", l = n.split(`
1634
+ `).length, d2 = i ? 2 : 1;
1635
+ return `${n}${a}${Y2({ output: t.output, options: this.options, cursor: this.cursor, maxItems: t.maxItems, columnPadding: a.length, rowPadding: l + d2, style: c2 }).join(`
1636
+ ${a}`)}
1637
+ ${i ? e("cyan", E2) : ""}
1638
+ `;
1639
+ }
1640
+ }
1641
+ } }).prompt();
1642
+ };
1643
+ var we = (t) => e("dim", t);
1644
+ var be = (t, r, s) => {
1645
+ const i = { hard: true, trim: false }, u = wrapAnsi(t, r, i).split(`
1646
+ `), n = u.reduce((a, l) => Math.max(dist_default2(l), a), 0), o = u.map(s).reduce((a, l) => Math.max(dist_default2(l), a), 0), c2 = r - (o - n);
1647
+ return wrapAnsi(t, c2, i);
1648
+ };
1649
+ var Se = (t = "", r = "", s) => {
1650
+ const i = s?.output ?? j2.stdout, u = s?.withGuide ?? h.withGuide, n = s?.format ?? we, o = ["", ...be(t, A(i) - 6, n).split(`
1651
+ `).map(n), ""], c2 = dist_default2(r), a = Math.max(o.reduce((p2, m) => {
1652
+ const g = dist_default2(m);
1653
+ return g > p2 ? g : p2;
1654
+ }, 0), c2) + 2, l = o.map((p2) => `${e("gray", $2)} ${p2}${" ".repeat(a - dist_default2(p2))}${e("gray", $2)}`).join(`
1655
+ `), d2 = u ? `${e("gray", $2)}
1656
+ ` : "", y = u ? xt : dt;
1657
+ i.write(`${d2}${e("green", F2)} ${e("reset", r)} ${e("gray", st2.repeat(Math.max(a - c2 - 1, 1)) + ct)}
1658
+ ${l}
1659
+ ${e("gray", y + st2.repeat(a + 2) + $t)}
1660
+ `);
1661
+ };
1662
+ var Ce = (t) => new ot({ validate: t.validate, mask: t.mask ?? Gt, signal: t.signal, input: t.input, output: t.output, render() {
1663
+ const r = t.withGuide ?? h.withGuide, s = `${r ? `${e("gray", $2)}
1664
+ ` : ""}${M(this.state)} ${t.message}
1665
+ `, i = this.userInputWithCursor, u = this.masked;
1666
+ switch (this.state) {
1667
+ case "error": {
1668
+ const n = r ? `${e("yellow", $2)} ` : "", o = r ? `${e("yellow", E2)} ` : "", c2 = u ?? "";
1669
+ return t.clearOnError && this.clear(), `${s.trim()}
1670
+ ${n}${c2}
1671
+ ${o}${e("yellow", this.error)}
1672
+ `;
1673
+ }
1674
+ case "submit": {
1675
+ const n = r ? `${e("gray", $2)} ` : "", o = u ? e("dim", u) : "";
1676
+ return `${s}${n}${o}`;
1677
+ }
1678
+ case "cancel": {
1679
+ const n = r ? `${e("gray", $2)} ` : "", o = u ? e(["strikethrough", "dim"], u) : "";
1680
+ return `${s}${n}${o}${u && r ? `
1681
+ ${e("gray", $2)}` : ""}`;
1682
+ }
1683
+ default: {
1684
+ const n = r ? `${e("cyan", $2)} ` : "", o = r ? e("cyan", E2) : "";
1685
+ return `${s}${n}${i}
1686
+ ${o}
1687
+ `;
1688
+ }
1689
+ }
1690
+ } }).prompt();
1691
+ var Te = (t) => {
1692
+ const r = t.validate;
1693
+ return At({ ...t, initialUserInput: t.initialValue ?? t.root ?? process.cwd(), maxItems: 5, validate(s) {
1694
+ if (!Array.isArray(s)) {
1695
+ if (!s) return "Please select a path";
1696
+ if (r) return r(s);
1697
+ }
1698
+ }, options() {
1699
+ const s = this.userInput;
1700
+ if (s === "") return [];
1701
+ try {
1702
+ let i;
1703
+ zt(s) ? wt(s).isDirectory() && (!t.directory || s.endsWith("/")) ? i = s : i = bt(s) : i = bt(s);
1704
+ const u = s.length > 1 && s.endsWith("/") ? s.slice(0, -1) : s;
1705
+ return Qt(i).map((n) => {
1706
+ const o = Zt(i, n), c2 = wt(o);
1707
+ return { name: n, path: o, isDirectory: c2.isDirectory() };
1708
+ }).filter(({ path: n, isDirectory: o }) => n.startsWith(u) && (o || !t.directory)).map((n) => ({ value: n.path }));
1709
+ } catch {
1710
+ return [];
1711
+ }
1712
+ } });
1713
+ };
1714
+ var _e = (t) => e("magenta", t);
1715
+ var ft = ({ indicator: t = "dots", onCancel: r, output: s = process.stdout, cancelMessage: i, errorMessage: u, frames: n = tt2 ? ["\u25D2", "\u25D0", "\u25D3", "\u25D1"] : ["\u2022", "o", "O", "0"], delay: o = tt2 ? 80 : 120, signal: c2, ...a } = {}) => {
1716
+ const l = at2();
1717
+ let d2, y, p2 = false, m = false, g = "", S2, h2 = performance.now();
1718
+ const f = A(s), v2 = a?.styleFrame ?? _e, T = (I2) => {
1719
+ const V2 = I2 > 1 ? u ?? h.messages.error : i ?? h.messages.cancel;
1720
+ m = I2 === 1, p2 && (W2(V2, I2), m && typeof r == "function" && r());
1721
+ }, C2 = () => T(2), b2 = () => T(1), G2 = () => {
1722
+ process.on("uncaughtExceptionMonitor", C2), process.on("unhandledRejection", C2), process.on("SIGINT", b2), process.on("SIGTERM", b2), process.on("exit", T), c2 && c2.addEventListener("abort", b2);
1723
+ }, x2 = () => {
1724
+ process.removeListener("uncaughtExceptionMonitor", C2), process.removeListener("unhandledRejection", C2), process.removeListener("SIGINT", b2), process.removeListener("SIGTERM", b2), process.removeListener("exit", T), c2 && c2.removeEventListener("abort", b2);
1725
+ }, A2 = () => {
1726
+ if (S2 === void 0) return;
1727
+ l && s.write(`
1728
+ `);
1729
+ const I2 = wrapAnsi(S2, f, { hard: true, trim: false }).split(`
1730
+ `);
1731
+ I2.length > 1 && s.write(import_sisteransi2.cursor.up(I2.length - 1)), s.write(import_sisteransi2.cursor.to(0)), s.write(import_sisteransi2.erase.down());
1732
+ }, P2 = (I2) => I2.replace(/\.+$/, ""), N2 = (I2) => {
1733
+ const V2 = (performance.now() - I2) / 1e3, B2 = Math.floor(V2 / 60), L2 = Math.floor(V2 % 60);
1734
+ return B2 > 0 ? `[${B2}m ${L2}s]` : `[${L2}s]`;
1735
+ }, D2 = a.withGuide ?? h.withGuide, rt2 = (I2 = "") => {
1736
+ p2 = true, d2 = R({ output: s }), g = P2(I2), h2 = performance.now(), D2 && s.write(`${e("gray", $2)}
1737
+ `);
1738
+ let V2 = 0, B2 = 0;
1739
+ G2(), y = setInterval(() => {
1740
+ if (l && g === S2) return;
1741
+ A2(), S2 = g;
1742
+ const L2 = v2(n[V2]);
1743
+ let Z2;
1744
+ if (l) Z2 = `${L2} ${g}...`;
1745
+ else if (t === "timer") Z2 = `${L2} ${g} ${N2(h2)}`;
1746
+ else {
1747
+ const kt = ".".repeat(Math.floor(B2)).slice(0, 3);
1748
+ Z2 = `${L2} ${g}${kt}`;
1749
+ }
1750
+ const Nt = wrapAnsi(Z2, f, { hard: true, trim: false });
1751
+ s.write(Nt), V2 = V2 + 1 < n.length ? V2 + 1 : 0, B2 = B2 < 4 ? B2 + 0.125 : 0;
1752
+ }, o);
1753
+ }, W2 = (I2 = "", V2 = 0, B2 = false) => {
1754
+ if (!p2) return;
1755
+ p2 = false, clearInterval(y), A2();
1756
+ const L2 = V2 === 0 ? e("green", F2) : V2 === 1 ? e("red", ot2) : e("red", ut2);
1757
+ g = I2 ?? g, B2 || (t === "timer" ? s.write(`${L2} ${g} ${N2(h2)}
1758
+ `) : s.write(`${L2} ${g}
1759
+ `)), x2(), d2();
1760
+ };
1761
+ return { start: rt2, stop: (I2 = "") => W2(I2, 0), message: (I2 = "") => {
1762
+ g = P2(I2 ?? g);
1763
+ }, cancel: (I2 = "") => W2(I2, 1), error: (I2 = "") => W2(I2, 2), clear: () => W2("", 0, true), get isCancelled() {
1764
+ return m;
1765
+ } };
1766
+ };
1767
+ var Vt = { light: w2("\u2500", "-"), heavy: w2("\u2501", "="), block: w2("\u2588", "#") };
1768
+ function Ie({ style: t = "heavy", max: r = 100, size: s = 40, ...i } = {}) {
1769
+ const u = ft(i);
1770
+ let n = 0, o = "";
1771
+ const c2 = Math.max(1, r), a = Math.max(1, s), l = (m) => {
1772
+ switch (m) {
1773
+ case "initial":
1774
+ case "active":
1775
+ return (g) => e("magenta", g);
1776
+ case "error":
1777
+ case "cancel":
1778
+ return (g) => e("red", g);
1779
+ case "submit":
1780
+ return (g) => e("green", g);
1781
+ default:
1782
+ return (g) => e("magenta", g);
1783
+ }
1784
+ }, d2 = (m, g) => {
1785
+ const S2 = Math.floor(n / c2 * a);
1786
+ return `${l(m)(Vt[t].repeat(S2))}${e("dim", Vt[t].repeat(a - S2))} ${g}`;
1787
+ }, y = (m = "") => {
1788
+ o = m, u.start(d2("initial", m));
1789
+ }, p2 = (m = 1, g) => {
1790
+ n = Math.min(c2, m + n), u.message(d2("active", g ?? o)), o = g ?? o;
1791
+ };
1792
+ return { start: y, stop: u.stop, cancel: u.cancel, error: u.error, clear: u.clear, advance: p2, isCancelled: u.isCancelled, message: (m) => p2(0, m) };
1793
+ }
1794
+ var it2 = (t, r) => t.includes(`
1795
+ `) ? t.split(`
1796
+ `).map((s) => r(s)).join(`
1797
+ `) : r(t);
1798
+ var Ee = (t) => {
1799
+ const r = (s, i) => {
1800
+ const u = s.label ?? String(s.value);
1801
+ switch (i) {
1802
+ case "disabled":
1803
+ return `${e("gray", H2)} ${it2(u, (n) => e("gray", n))}${s.hint ? ` ${e("dim", `(${s.hint ?? "disabled"})`)}` : ""}`;
1804
+ case "selected":
1805
+ return `${it2(u, (n) => e("dim", n))}`;
1806
+ case "active":
1807
+ return `${e("green", z2)} ${u}${s.hint ? ` ${e("dim", `(${s.hint})`)}` : ""}`;
1808
+ case "cancelled":
1809
+ return `${it2(u, (n) => e(["strikethrough", "dim"], n))}`;
1810
+ default:
1811
+ return `${e("dim", H2)} ${it2(u, (n) => e("dim", n))}`;
1812
+ }
1813
+ };
1814
+ return new ut({ options: t.options, signal: t.signal, input: t.input, output: t.output, initialValue: t.initialValue, render() {
1815
+ const s = t.withGuide ?? h.withGuide, i = `${M(this.state)} `, u = `${yt(this.state)} `, n = W(t.output, t.message, u, i), o = `${s ? `${e("gray", $2)}
1816
+ ` : ""}${n}
1817
+ `;
1818
+ switch (this.state) {
1819
+ case "submit": {
1820
+ const c2 = s ? `${e("gray", $2)} ` : "", a = W(t.output, r(this.options[this.cursor], "selected"), c2);
1821
+ return `${o}${a}`;
1822
+ }
1823
+ case "cancel": {
1824
+ const c2 = s ? `${e("gray", $2)} ` : "", a = W(t.output, r(this.options[this.cursor], "cancelled"), c2);
1825
+ return `${o}${a}${s ? `
1826
+ ${e("gray", $2)}` : ""}`;
1827
+ }
1828
+ default: {
1829
+ const c2 = s ? `${e("cyan", $2)} ` : "", a = s ? e("cyan", E2) : "", l = o.split(`
1830
+ `).length, d2 = s ? 2 : 1;
1831
+ return `${o}${c2}${Y2({ output: t.output, cursor: this.cursor, options: this.options, maxItems: t.maxItems, columnPadding: c2.length, rowPadding: l + d2, style: (y, p2) => r(y, y.disabled ? "disabled" : p2 ? "active" : "inactive") }).join(`
1832
+ ${c2}`)}
1833
+ ${a}
1834
+ `;
1835
+ }
1836
+ }
1837
+ } }).prompt();
1838
+ };
1839
+ var Ge = (t) => {
1840
+ const r = (s, i = "inactive") => {
1841
+ const u = s.label ?? String(s.value);
1842
+ return i === "selected" ? `${e("dim", u)}` : i === "cancelled" ? `${e(["strikethrough", "dim"], u)}` : i === "active" ? `${e(["bgCyan", "gray"], ` ${s.value} `)} ${u}${s.hint ? ` ${e("dim", `(${s.hint})`)}` : ""}` : `${e(["gray", "bgWhite", "inverse"], ` ${s.value} `)} ${u}${s.hint ? ` ${e("dim", `(${s.hint})`)}` : ""}`;
1843
+ };
1844
+ return new at({ options: t.options, signal: t.signal, input: t.input, output: t.output, initialValue: t.initialValue, caseSensitive: t.caseSensitive, render() {
1845
+ const s = t.withGuide ?? h.withGuide, i = `${s ? `${e("gray", $2)}
1846
+ ` : ""}${M(this.state)} ${t.message}
1847
+ `;
1848
+ switch (this.state) {
1849
+ case "submit": {
1850
+ const u = s ? `${e("gray", $2)} ` : "", n = this.options.find((c2) => c2.value === this.value) ?? t.options[0], o = W(t.output, r(n, "selected"), u);
1851
+ return `${i}${o}`;
1852
+ }
1853
+ case "cancel": {
1854
+ const u = s ? `${e("gray", $2)} ` : "", n = W(t.output, r(this.options[0], "cancelled"), u);
1855
+ return `${i}${n}${s ? `
1856
+ ${e("gray", $2)}` : ""}`;
1857
+ }
1858
+ default: {
1859
+ const u = s ? `${e("cyan", $2)} ` : "", n = s ? e("cyan", E2) : "", o = this.options.map((c2, a) => W(t.output, r(c2, a === this.cursor ? "active" : "inactive"), u)).join(`
1860
+ `);
1861
+ return `${i}${o}
1862
+ ${n}
1863
+ `;
1864
+ }
1865
+ }
1866
+ } }).prompt();
1867
+ };
1868
+ var jt = `${e("gray", $2)} `;
1869
+ var K2 = { message: async (t, { symbol: r = e("gray", $2) } = {}) => {
1870
+ process.stdout.write(`${e("gray", $2)}
1871
+ ${r} `);
1872
+ let s = 3;
1873
+ for await (let i of t) {
1874
+ i = i.replace(/\n/g, `
1875
+ ${jt}`), i.includes(`
1876
+ `) && (s = 3 + nt2(i.slice(i.lastIndexOf(`
1877
+ `))).length);
1878
+ const u = nt2(i).length;
1879
+ s + u < process.stdout.columns ? (s += u, process.stdout.write(i)) : (process.stdout.write(`
1880
+ ${jt}${i.trimStart()}`), s = 3 + nt2(i.trimStart()).length);
1881
+ }
1882
+ process.stdout.write(`
1883
+ `);
1884
+ }, info: (t) => K2.message(t, { symbol: e("blue", ht2) }), success: (t) => K2.message(t, { symbol: e("green", pt) }), step: (t) => K2.message(t, { symbol: e("green", F2) }), warn: (t) => K2.message(t, { symbol: e("yellow", mt) }), warning: (t) => K2.warn(t), error: (t) => K2.message(t, { symbol: e("red", gt) }) };
1885
+ var xe = async (t, r) => {
1886
+ for (const s of t) {
1887
+ if (s.enabled === false) continue;
1888
+ const i = ft(r);
1889
+ i.start(s.title);
1890
+ const u = await s.task(i.message);
1891
+ i.stop(u || s.title);
1892
+ }
1893
+ };
1894
+ var Oe = (t) => t.replace(/\x1b\[(?:\d+;)*\d*[ABCDEFGHfJKSTsu]|\x1b\[(s|u)/g, "");
1895
+ var Me = (t) => {
1896
+ const r = t.output ?? process.stdout, s = A(r), i = e("gray", $2), u = t.spacing ?? 1, n = 3, o = t.retainLog === true, c2 = !at2() && Tt(r);
1897
+ r.write(`${i}
1898
+ `), r.write(`${e("green", F2)} ${t.title}
1899
+ `);
1900
+ for (let h2 = 0; h2 < u; h2++) r.write(`${i}
1901
+ `);
1902
+ const a = [{ value: "", full: "" }];
1903
+ let l = false;
1904
+ const d2 = (h2) => {
1905
+ if (a.length === 0) return;
1906
+ let f = 0;
1907
+ h2 && (f += u + 2);
1908
+ for (const v2 of a) {
1909
+ const { value: T, result: C2 } = v2;
1910
+ let b2 = C2?.message ?? T;
1911
+ if (b2.length === 0) continue;
1912
+ C2 === void 0 && v2.header !== void 0 && v2.header !== "" && (b2 += `
1913
+ ${v2.header}`);
1914
+ const G2 = b2.split(`
1915
+ `).reduce((x2, A2) => A2 === "" ? x2 + 1 : x2 + Math.ceil((A2.length + n) / s), 0);
1916
+ f += G2;
1917
+ }
1918
+ f > 0 && (f += 1, r.write(import_sisteransi2.erase.lines(f)));
1919
+ }, y = (h2, f, v2) => {
1920
+ const T = v2 ? `${h2.full}
1921
+ ${h2.value}` : h2.value;
1922
+ h2.header !== void 0 && h2.header !== "" && R2.message(h2.header.split(`
1923
+ `).map((C2) => e("bold", C2)), { output: r, secondarySymbol: i, symbol: i, spacing: 0 }), R2.message(T.split(`
1924
+ `).map((C2) => e("dim", C2)), { output: r, secondarySymbol: i, symbol: i, spacing: f ?? u });
1925
+ }, p2 = () => {
1926
+ for (const h2 of a) {
1927
+ const { header: f, value: v2, full: T } = h2;
1928
+ (f === void 0 || f.length === 0) && v2.length === 0 || y(h2, void 0, o === true && T.length > 0);
1929
+ }
1930
+ }, m = (h2, f, v2) => {
1931
+ if (d2(false), (v2?.raw !== true || !l) && h2.value !== "" && (h2.value += `
1932
+ `), h2.value += Oe(f), l = v2?.raw === true, t.limit !== void 0) {
1933
+ const T = h2.value.split(`
1934
+ `), C2 = T.length - t.limit;
1935
+ if (C2 > 0) {
1936
+ const b2 = T.splice(0, C2);
1937
+ o && (h2.full += (h2.full === "" ? "" : `
1938
+ `) + b2.join(`
1939
+ `));
1940
+ }
1941
+ h2.value = T.join(`
1942
+ `);
1943
+ }
1944
+ c2 && g();
1945
+ }, g = () => {
1946
+ for (const h2 of a) h2.result ? h2.result.status === "error" ? R2.error(h2.result.message, { output: r, secondarySymbol: i, spacing: 0 }) : R2.success(h2.result.message, { output: r, secondarySymbol: i, spacing: 0 }) : h2.value !== "" && y(h2, 0);
1947
+ }, S2 = (h2, f) => {
1948
+ d2(false), h2.result = f, c2 && g();
1949
+ };
1950
+ return { message(h2, f) {
1951
+ m(a[0], h2, f);
1952
+ }, group(h2) {
1953
+ const f = { header: h2, value: "", full: "" };
1954
+ return a.push(f), { message(v2, T) {
1955
+ m(f, v2, T);
1956
+ }, error(v2) {
1957
+ S2(f, { status: "error", message: v2 });
1958
+ }, success(v2) {
1959
+ S2(f, { status: "success", message: v2 });
1960
+ } };
1961
+ }, error(h2, f) {
1962
+ d2(true), R2.error(h2, { output: r, secondarySymbol: i, spacing: 1 }), f?.showLog !== false && p2(), a.splice(1, a.length - 1), a[0].value = "", a[0].full = "";
1963
+ }, success(h2, f) {
1964
+ d2(true), R2.success(h2, { output: r, secondarySymbol: i, spacing: 1 }), f?.showLog === true && p2(), a.splice(1, a.length - 1), a[0].value = "", a[0].full = "";
1965
+ } };
1966
+ };
1967
+ var Re = (t) => new ht({ validate: t.validate, placeholder: t.placeholder, defaultValue: t.defaultValue, initialValue: t.initialValue, output: t.output, signal: t.signal, input: t.input, render() {
1968
+ const r = t?.withGuide ?? h.withGuide, s = `${`${r ? `${e("gray", $2)}
1969
+ ` : ""}${M(this.state)} `}${t.message}
1970
+ `, i = t.placeholder ? e("inverse", t.placeholder[0]) + e("dim", t.placeholder.slice(1)) : e(["inverse", "hidden"], "_"), u = this.userInput ? this.userInputWithCursor : i, n = this.value ?? "";
1971
+ switch (this.state) {
1972
+ case "error": {
1973
+ const o = this.error ? ` ${e("yellow", this.error)}` : "", c2 = r ? `${e("yellow", $2)} ` : "", a = r ? e("yellow", E2) : "";
1974
+ return `${s.trim()}
1975
+ ${c2}${u}
1976
+ ${a}${o}
1977
+ `;
1978
+ }
1979
+ case "submit": {
1980
+ const o = n ? ` ${e("dim", n)}` : "", c2 = r ? e("gray", $2) : "";
1981
+ return `${s}${c2}${o}`;
1982
+ }
1983
+ case "cancel": {
1984
+ const o = n ? ` ${e(["strikethrough", "dim"], n)}` : "", c2 = r ? e("gray", $2) : "";
1985
+ return `${s}${c2}${o}${n.trim() ? `
1986
+ ${c2}` : ""}`;
1987
+ }
1988
+ default: {
1989
+ const o = r ? `${e("cyan", $2)} ` : "", c2 = r ? e("cyan", E2) : "";
1990
+ return `${s}${o}${u}
1991
+ ${c2}
1992
+ `;
1993
+ }
1994
+ }
1995
+ } }).prompt();
1996
+
1997
+ export {
1998
+ h,
1999
+ j,
2000
+ q,
2001
+ tt2 as tt,
2002
+ at2 as at,
2003
+ Tt,
2004
+ w2 as w,
2005
+ _t,
2006
+ ot2 as ot,
2007
+ ut2 as ut,
2008
+ F2 as F,
2009
+ lt,
2010
+ $2 as $,
2011
+ E2 as E,
2012
+ It,
2013
+ Et,
2014
+ z2 as z,
2015
+ H2 as H,
2016
+ et2 as et,
2017
+ U2 as U,
2018
+ J2 as J,
2019
+ Gt,
2020
+ st2 as st,
2021
+ ct,
2022
+ xt,
2023
+ $t,
2024
+ dt,
2025
+ Ot,
2026
+ ht2 as ht,
2027
+ pt,
2028
+ mt,
2029
+ gt,
2030
+ M,
2031
+ yt,
2032
+ Y2 as Y,
2033
+ At,
2034
+ ie,
2035
+ oe,
2036
+ ue,
2037
+ le,
2038
+ he,
2039
+ pe,
2040
+ R2 as R,
2041
+ me,
2042
+ ge,
2043
+ ye,
2044
+ fe,
2045
+ ve,
2046
+ Se,
2047
+ Ce,
2048
+ Te,
2049
+ ft,
2050
+ Ie,
2051
+ Ee,
2052
+ Ge,
2053
+ K2 as K,
2054
+ xe,
2055
+ Me,
2056
+ Re
2057
+ };