@shopify/cli 4.9.4 → 5.0.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 (501) hide show
  1. package/dist/analytics-Q6QDIDYT.js +1 -0
  2. package/dist/analytics-VKKJNJ62.js +1 -0
  3. package/dist/assets/hydrogen/starter/CHANGELOG.md +7 -0
  4. package/dist/assets/hydrogen/starter/package.json +2 -2
  5. package/dist/assets/hydrogen/vite/package.json +3 -4
  6. package/dist/assets/hydrogen/vite/vite.config.js +3 -3
  7. package/dist/bootstrap.js +1 -1
  8. package/dist/{chunk-LKXFHYLI.js → chunk-24NUJTIH.js} +1 -1
  9. package/dist/chunk-2CMEKSI7.js +1 -0
  10. package/dist/chunk-2DID73ML.js +1 -0
  11. package/dist/chunk-2ORRV7GH.js +1 -0
  12. package/dist/chunk-2VSNFOKD.js +1 -0
  13. package/dist/chunk-335BUVBP.js +1 -0
  14. package/dist/{chunk-UEBUGSBT.js → chunk-3A3DZVEJ.js} +1 -1
  15. package/dist/chunk-3C6VLJ5D.js +319 -0
  16. package/dist/{chunk-PB5ZZET5.js → chunk-3G4HJO72.js} +30 -30
  17. package/dist/chunk-3LVCG4JB.js +1 -0
  18. package/dist/chunk-43KLFFP7.js +1 -0
  19. package/dist/chunk-43R5VGKT.js +1 -0
  20. package/dist/chunk-46MSIQ6Z.js +1 -0
  21. package/dist/chunk-4ARCB6DT.js +1 -0
  22. package/dist/chunk-4C2DAX5T.js +1 -0
  23. package/dist/chunk-4CRBTSVP.js +2 -0
  24. package/dist/chunk-4GCI2YCZ.js +8 -0
  25. package/dist/chunk-4GOJQKY5.js +1 -0
  26. package/dist/chunk-4RDFMBRG.js +9 -0
  27. package/dist/chunk-4SS6DXC7.js +5 -0
  28. package/dist/{chunk-J4J2YXH3.js → chunk-4TI7U2PN.js} +1 -1
  29. package/dist/{chunk-67EBF76X.js → chunk-52FDK2LC.js} +1 -1
  30. package/dist/chunk-53BG3NLH.js +3 -0
  31. package/dist/{chunk-LD6ZCTZ3.js → chunk-5B76DT7X.js} +1 -1
  32. package/dist/{chunk-A2VCTDKH.js → chunk-5NEGOQT6.js} +1 -1
  33. package/dist/{chunk-MW3JKGJH.js → chunk-5OMJFPQW.js} +1 -1
  34. package/dist/chunk-5TB52UUV.js +2 -0
  35. package/dist/chunk-5UWMXOHM.js +7 -0
  36. package/dist/chunk-6BNKBCCU.js +1 -0
  37. package/dist/chunk-6DXP7PQ7.js +1 -0
  38. package/dist/chunk-6PUU6ZNQ.js +1 -0
  39. package/dist/chunk-7GHSE7SG.js +1 -0
  40. package/dist/{chunk-7556AIVG.js → chunk-7IFE4UQY.js} +1 -1
  41. package/dist/chunk-7LAKWAKX.js +25 -0
  42. package/dist/chunk-7MVWDCI3.js +1 -0
  43. package/dist/chunk-7NSK77WG.js +3 -0
  44. package/dist/chunk-7QUZWCJZ.js +3 -0
  45. package/dist/chunk-7RPFJZLP.js +1 -0
  46. package/dist/{chunk-LJIJEGND.js → chunk-7UOA4DI7.js} +2 -2
  47. package/dist/chunk-7WPUV7GY.js +6 -0
  48. package/dist/chunk-7Y7AZRL3.js +10 -0
  49. package/dist/{chunk-NGSEF3UX.js → chunk-ACA2BGAD.js} +1 -1
  50. package/dist/chunk-AJMDF3QC.js +1 -0
  51. package/dist/{chunk-R7YJNDXW.js → chunk-AXC2MHHO.js} +1 -1
  52. package/dist/{chunk-DEF2G7S4.js → chunk-AYL6KBPE.js} +1 -1
  53. package/dist/chunk-BAHIL37I.js +1 -0
  54. package/dist/{chunk-RSC5NQAT.js → chunk-BCYTZ7LM.js} +1 -1
  55. package/dist/{chunk-AVMNIZAJ.js → chunk-BJPDJIS4.js} +1 -1
  56. package/dist/{chunk-7VAKNVFD.js → chunk-BN7ZXAZJ.js} +1 -1
  57. package/dist/chunk-BVSKBX7T.js +16 -0
  58. package/dist/chunk-BWRNXCVN.js +4 -0
  59. package/dist/{chunk-XNPUZRWP.js → chunk-C3KEDG33.js} +1 -1
  60. package/dist/{chunk-WEXOA4C4.js → chunk-C7V755IT.js} +1 -1
  61. package/dist/chunk-CCMDZX35.js +7 -0
  62. package/dist/chunk-CCQNP5YR.js +1 -0
  63. package/dist/chunk-CEIJKJOF.js +11 -0
  64. package/dist/chunk-CIK5BF7V.js +1 -0
  65. package/dist/{chunk-6YDLNP4G.js → chunk-CVVQQLCF.js} +1 -1
  66. package/dist/chunk-CW2T7EOQ.js +1 -0
  67. package/dist/chunk-CZ22VZDA.js +376 -0
  68. package/dist/{chunk-3G2ZQ2EF.js → chunk-D7NB7YR6.js} +1 -1
  69. package/dist/{chunk-DYPZX7MW.js → chunk-DFQ4WTET.js} +2 -2
  70. package/dist/chunk-DJAZBPYA.js +3 -0
  71. package/dist/chunk-DNMXVMJM.js +47 -0
  72. package/dist/{chunk-CLD3NZYD.js → chunk-EGCWR5AS.js} +1 -1
  73. package/dist/{chunk-BOE2ST6J.js → chunk-EITIW5OX.js} +1 -1
  74. package/dist/chunk-EMSF57ZB.js +1 -0
  75. package/dist/{chunk-ZEBMW5KS.js → chunk-EXFBZPZS.js} +1 -1
  76. package/dist/chunk-FDXHQZTO.js +26 -0
  77. package/dist/{chunk-Q2XLIWG4.js → chunk-FFHH5LOR.js} +1 -1
  78. package/dist/{chunk-MMQZO2W2.js → chunk-FNLECT7B.js} +1 -1
  79. package/dist/{chunk-PO5T44H3.js → chunk-FWB3GLMW.js} +1 -1
  80. package/dist/chunk-FZCGRIOM.js +1 -0
  81. package/dist/{chunk-G7JW4UIM.js → chunk-G6ZMSWEU.js} +1 -1
  82. package/dist/chunk-GAMC2BNY.js +7 -0
  83. package/dist/chunk-GB6E3ATN.js +4 -0
  84. package/dist/chunk-GCNA3HXH.js +8 -0
  85. package/dist/{chunk-IGDVKRB4.js → chunk-GFVKTWFT.js} +1 -1
  86. package/dist/chunk-GQNOVEKP.js +2 -0
  87. package/dist/{chunk-5BTLE67Z.js → chunk-GRGFA26K.js} +1 -1
  88. package/dist/chunk-GXORLBVN.js +2 -0
  89. package/dist/{chunk-3V4VL3SD.js → chunk-H4V55Y3Z.js} +118 -118
  90. package/dist/chunk-HCZG7YJ6.js +16 -0
  91. package/dist/chunk-HF4NDEX3.js +1 -0
  92. package/dist/chunk-HIRTL45Q.js +1 -0
  93. package/dist/chunk-I4OVLRQR.js +1 -0
  94. package/dist/{chunk-ENQXB532.js → chunk-I6FRVYGE.js} +1 -1
  95. package/dist/chunk-IEQ4UOH3.js +4 -0
  96. package/dist/{chunk-PIZDYS7T.js → chunk-IILLQOUC.js} +60 -60
  97. package/dist/{chunk-45SZ5PSE.js → chunk-IQVRP7CT.js} +1 -1
  98. package/dist/chunk-IUP7POIE.js +6 -0
  99. package/dist/chunk-IUTZIN2T.js +10 -0
  100. package/dist/chunk-IWEKM5Y3.js +1 -0
  101. package/dist/chunk-IWTNUJGY.js +2 -0
  102. package/dist/chunk-J6TW43TG.js +1 -0
  103. package/dist/chunk-JDR6UVZA.js +8 -0
  104. package/dist/{chunk-CVFPY2SH.js → chunk-JEA3C7ON.js} +1 -1
  105. package/dist/chunk-JOJV5E2K.js +1 -0
  106. package/dist/chunk-JYMDWR25.js +1 -0
  107. package/dist/{chunk-TPHHQAUD.js → chunk-KDPQXURV.js} +1 -1
  108. package/dist/{chunk-MW3IMZJ5.js → chunk-KGRIYAMA.js} +1 -1
  109. package/dist/chunk-KJQDS5HI.js +1 -0
  110. package/dist/chunk-KKPOOIE4.js +2 -0
  111. package/dist/{chunk-VS7QVU3Z.js → chunk-KSDU4YOB.js} +1 -1
  112. package/dist/chunk-L7MSPGDS.js +5 -0
  113. package/dist/{chunk-43URS56H.js → chunk-LDU5T3DN.js} +1 -1
  114. package/dist/chunk-LHKVXJPX.js +1 -0
  115. package/dist/{chunk-EO4YJFMY.js → chunk-LMQGNECW.js} +86 -200
  116. package/dist/{chunk-TQ7URMGS.js → chunk-LQ7ENG4V.js} +1 -1
  117. package/dist/chunk-LVLAOBJM.js +103 -0
  118. package/dist/chunk-LWCTKI4Z.js +18 -0
  119. package/dist/chunk-M3ACZWMR.js +1 -0
  120. package/dist/chunk-M4BVLMPH.js +31 -0
  121. package/dist/{chunk-NCRWOW6F.js → chunk-M5TGCSUK.js} +1 -1
  122. package/dist/chunk-M7LPHCP2.js +274 -0
  123. package/dist/{chunk-IDKRJ2F4.js → chunk-MDRVCBDO.js} +1 -1
  124. package/dist/chunk-MR2AUT7Q.js +1 -0
  125. package/dist/chunk-MXJAH2GW.js +5 -0
  126. package/dist/{chunk-UU6BRRYS.js → chunk-MYAIWSOO.js} +1 -1
  127. package/dist/{chunk-NT4A37HG.js → chunk-N2RFDHRY.js} +1 -1
  128. package/dist/{chunk-GSE6FXZU.js → chunk-NB4BRW3H.js} +1 -1
  129. package/dist/chunk-NDKSG4CC.js +97 -0
  130. package/dist/chunk-NK2MGR6A.js +1 -0
  131. package/dist/chunk-NOH63WC6.js +12 -0
  132. package/dist/{chunk-BVB3DTNE.js → chunk-OGWPS55W.js} +1 -1
  133. package/dist/chunk-OQ5CLM2H.js +4 -0
  134. package/dist/{chunk-PVAZCZSY.js → chunk-OQU3HLAE.js} +1 -1
  135. package/dist/chunk-OVWUGAEU.js +11 -0
  136. package/dist/chunk-OX7UVDSU.js +6 -0
  137. package/dist/chunk-P33TONYG.js +1 -0
  138. package/dist/chunk-PEVIRAMR.js +6 -0
  139. package/dist/{chunk-YPCXVZ2N.js → chunk-PGLWZMJU.js} +4 -4
  140. package/dist/chunk-PIAD3F6M.js +16 -0
  141. package/dist/chunk-PMHP57MH.js +20 -0
  142. package/dist/{chunk-F3PZGSOY.js → chunk-POKY4RWR.js} +1 -1
  143. package/dist/chunk-PSSYLJG4.js +2 -0
  144. package/dist/chunk-PYIICTLX.js +1 -0
  145. package/dist/chunk-PZUGDE7N.js +2 -0
  146. package/dist/{chunk-NU5WLZ6Y.js → chunk-Q2SZCZE7.js} +1 -1
  147. package/dist/{chunk-MUM34KUM.js → chunk-Q2XRITUG.js} +1 -1
  148. package/dist/chunk-Q5MEFIMV.js +4 -0
  149. package/dist/chunk-Q66CI37F.js +7 -0
  150. package/dist/chunk-QFWWCZOI.js +1 -0
  151. package/dist/{chunk-TR4OWSEX.js → chunk-QFYLJVJW.js} +1 -1
  152. package/dist/chunk-QKVVJXWS.js +3 -0
  153. package/dist/chunk-QN3774QI.js +1 -0
  154. package/dist/chunk-R2BDABJD.js +213 -0
  155. package/dist/{chunk-7HWMURCW.js → chunk-R7EMV77H.js} +1 -1
  156. package/dist/chunk-RFGEM5JC.js +3 -0
  157. package/dist/{chunk-7A3RW2VM.js → chunk-RVQV6G5M.js} +1 -1
  158. package/dist/chunk-S67I4E7M.js +5 -0
  159. package/dist/chunk-SFPXYHHL.js +1 -0
  160. package/dist/{chunk-4OCVXE5Y.js → chunk-SFQEHDJY.js} +1 -1
  161. package/dist/chunk-SL3VBI62.js +3 -0
  162. package/dist/{chunk-LOWSU4BB.js → chunk-SNNZ4U2W.js} +1 -1
  163. package/dist/chunk-T2IUXXCT.js +1 -0
  164. package/dist/chunk-TPSA4JN5.js +1 -0
  165. package/dist/chunk-TTEF7GTX.js +1 -0
  166. package/dist/{chunk-FQL2WEKX.js → chunk-U25W35TX.js} +1 -1
  167. package/dist/chunk-UIQL5ZF3.js +1 -0
  168. package/dist/chunk-UK6576EO.js +1 -0
  169. package/dist/chunk-ULD7CIOY.js +4 -0
  170. package/dist/{chunk-D3KFKT4D.js → chunk-UOS2XLGG.js} +1 -1
  171. package/dist/{chunk-EMH7OHCW.js → chunk-UVRKTMF7.js} +1 -1
  172. package/dist/{chunk-ZTICX3AO.js → chunk-UWMZ5CSB.js} +1 -1
  173. package/dist/chunk-UZROQRLX.js +2 -0
  174. package/dist/{chunk-5BGUKF7L.js → chunk-V75WUEFU.js} +1 -1
  175. package/dist/chunk-VB7YQMAM.js +5 -0
  176. package/dist/chunk-VHUD3CBC.js +3 -0
  177. package/dist/chunk-VMMUJN4T.js +17 -0
  178. package/dist/{chunk-S36VGP37.js → chunk-VW6QS7DO.js} +1 -1
  179. package/dist/chunk-VWH3VPYI.js +1 -0
  180. package/dist/{chunk-4TF7ER72.js → chunk-WBJ6ZHYH.js} +1 -1
  181. package/dist/chunk-WDFCOZAY.js +16 -0
  182. package/dist/chunk-WFWISGLS.js +1 -0
  183. package/dist/chunk-WGUOLSMG.js +1 -0
  184. package/dist/{chunk-PFXNBHQQ.js → chunk-WJSUIUBW.js} +2 -2
  185. package/dist/{chunk-TFXUDHCP.js → chunk-WMAFG2JD.js} +1 -1
  186. package/dist/chunk-X2H6I2WW.js +5 -0
  187. package/dist/{chunk-DSS4ECIH.js → chunk-X7HVAVSZ.js} +1 -1
  188. package/dist/{chunk-NYYXH2SX.js → chunk-XBQDMGUN.js} +1 -1
  189. package/dist/chunk-XITZIDCL.js +18 -0
  190. package/dist/chunk-XKRJKUA7.js +1 -0
  191. package/dist/{chunk-FEQHCE2E.js → chunk-XM7YUXTF.js} +2 -2
  192. package/dist/chunk-XMODGI45.js +1 -0
  193. package/dist/{chunk-B3M3KIOU.js → chunk-XNNKLUTN.js} +1 -1
  194. package/dist/chunk-XTREQ4A2.js +1 -0
  195. package/dist/chunk-YGYEM6QO.js +1 -0
  196. package/dist/{chunk-LWU5TKNA.js → chunk-YKS7MH3F.js} +9 -6
  197. package/dist/chunk-YTUDXZLN.js +1 -0
  198. package/dist/{chunk-I3J63RFV.js → chunk-YTUUU33R.js} +1 -1
  199. package/dist/chunk-YVVU4J5O.js +3 -0
  200. package/dist/{chunk-4TZCRMBJ.js → chunk-YVY32DNA.js} +1 -1
  201. package/dist/chunk-Z5SILNH2.js +7 -0
  202. package/dist/chunk-ZAA2DXK5.js +5 -0
  203. package/dist/chunk-ZDQO6CNY.js +1 -0
  204. package/dist/chunk-ZGV3HNEV.js +1 -0
  205. package/dist/chunk-ZQDDRIBA.js +22 -0
  206. package/dist/{chunk-QTLGMJDW.js → chunk-ZT5WFUKJ.js} +4 -4
  207. package/dist/chunk-ZYQ2XWC5.js +5 -0
  208. package/dist/cli/commands/app/build.js +1 -1
  209. package/dist/cli/commands/app/bulk/cancel.js +1 -1
  210. package/dist/cli/commands/app/bulk/execute.js +1 -1
  211. package/dist/cli/commands/app/bulk/status.js +1 -1
  212. package/dist/cli/commands/app/config/link.js +1 -1
  213. package/dist/cli/commands/app/config/pull.js +1 -1
  214. package/dist/cli/commands/app/config/use.js +1 -1
  215. package/dist/cli/commands/app/config/validate.js +1 -1
  216. package/dist/cli/commands/app/demo/watcher.js +1 -1
  217. package/dist/cli/commands/app/deploy.js +1 -1
  218. package/dist/cli/commands/app/dev/clean.js +1 -1
  219. package/dist/cli/commands/app/dev.js +1 -1
  220. package/dist/cli/commands/app/env/pull.js +1 -1
  221. package/dist/cli/commands/app/env/show.js +1 -1
  222. package/dist/cli/commands/app/execute.js +1 -1
  223. package/dist/cli/commands/app/function/build.js +1 -1
  224. package/dist/cli/commands/app/function/info.js +1 -1
  225. package/dist/cli/commands/app/function/replay.js +1 -1
  226. package/dist/cli/commands/app/function/run.js +1 -1
  227. package/dist/cli/commands/app/function/schema.js +1 -1
  228. package/dist/cli/commands/app/function/typegen.js +1 -1
  229. package/dist/cli/commands/app/generate/extension.js +1 -1
  230. package/dist/cli/commands/app/graphiql.js +1 -1
  231. package/dist/cli/commands/app/import/channel-config.js +1 -1
  232. package/dist/cli/commands/app/import/custom-data-definitions.js +1 -1
  233. package/dist/cli/commands/app/import/dashboard-extensions.js +1 -1
  234. package/dist/cli/commands/app/import-custom-data-definitions.js +1 -1
  235. package/dist/cli/commands/app/import-extensions.js +1 -1
  236. package/dist/cli/commands/app/info.js +1 -1
  237. package/dist/cli/commands/app/init.js +1 -1
  238. package/dist/cli/commands/app/logs.js +1 -1
  239. package/dist/cli/commands/app/release.js +1 -1
  240. package/dist/cli/commands/app/security/check.js +1 -1
  241. package/dist/cli/commands/app/security/clean.js +1 -1
  242. package/dist/cli/commands/app/security/instructions.js +1 -1
  243. package/dist/cli/commands/app/security/record.js +1 -1
  244. package/dist/cli/commands/app/security/review.js +1 -1
  245. package/dist/cli/commands/app/subscription-migrations/cancel.js +1 -1
  246. package/dist/cli/commands/app/subscription-migrations/list.js +1 -1
  247. package/dist/cli/commands/app/subscription-migrations/schedule.js +1 -1
  248. package/dist/cli/commands/app/subscription-migrations/status.js +1 -1
  249. package/dist/cli/commands/app/subscription-migrations/unschedule.js +1 -1
  250. package/dist/cli/commands/app/versions/list.js +1 -1
  251. package/dist/cli/commands/app/webhook/trigger.js +1 -1
  252. package/dist/cli/commands/auth/login.js +1 -1
  253. package/dist/cli/commands/auth/logout.js +1 -1
  254. package/dist/cli/commands/cache/clear.js +1 -1
  255. package/dist/cli/commands/config/autoupgrade/off.js +1 -1
  256. package/dist/cli/commands/config/autoupgrade/on.js +1 -1
  257. package/dist/cli/commands/config/autoupgrade/status.js +1 -1
  258. package/dist/cli/commands/debug/command-flags.js +1 -1
  259. package/dist/cli/commands/doc/fetch.d.ts +34 -1
  260. package/dist/cli/commands/doc/fetch.js +1 -1
  261. package/dist/cli/commands/doc/search.d.ts +53 -1
  262. package/dist/cli/commands/doc/search.js +1 -1
  263. package/dist/cli/commands/docs/generate.js +1 -1
  264. package/dist/cli/commands/doctor-release/doctor-release.js +1 -1
  265. package/dist/cli/commands/doctor-release/theme/index.js +1 -1
  266. package/dist/cli/commands/help.d.ts +6 -6
  267. package/dist/cli/commands/help.js +1 -1
  268. package/dist/cli/commands/kitchen-sink/async.js +1 -1
  269. package/dist/cli/commands/kitchen-sink/index.js +1 -1
  270. package/dist/cli/commands/kitchen-sink/prompts.js +1 -1
  271. package/dist/cli/commands/kitchen-sink/static.js +1 -1
  272. package/dist/cli/commands/notifications/generate.js +1 -1
  273. package/dist/cli/commands/notifications/list.js +1 -1
  274. package/dist/cli/commands/organization/list.js +1 -1
  275. package/dist/cli/commands/search.js +1 -1
  276. package/dist/cli/commands/send-analytics.js +1 -1
  277. package/dist/cli/commands/theme/check.js +1 -1
  278. package/dist/cli/commands/theme/console.js +1 -1
  279. package/dist/cli/commands/theme/delete.js +1 -1
  280. package/dist/cli/commands/theme/dev.js +1 -1
  281. package/dist/cli/commands/theme/duplicate.js +1 -1
  282. package/dist/cli/commands/theme/info.js +1 -1
  283. package/dist/cli/commands/theme/init.js +1 -1
  284. package/dist/cli/commands/theme/language-server.js +1 -1
  285. package/dist/cli/commands/theme/list.js +1 -1
  286. package/dist/cli/commands/theme/metafields/pull.js +1 -1
  287. package/dist/cli/commands/theme/open.js +1 -1
  288. package/dist/cli/commands/theme/package.js +1 -1
  289. package/dist/cli/commands/theme/preview.js +1 -1
  290. package/dist/cli/commands/theme/profile.js +1 -1
  291. package/dist/cli/commands/theme/publish.js +1 -1
  292. package/dist/cli/commands/theme/pull.js +1 -1
  293. package/dist/cli/commands/theme/push.js +1 -1
  294. package/dist/cli/commands/theme/rename.js +1 -1
  295. package/dist/cli/commands/theme/share.js +1 -1
  296. package/dist/cli/commands/upgrade.d.ts +64 -0
  297. package/dist/cli/commands/upgrade.js +1 -1
  298. package/dist/cli/commands/version.js +1 -1
  299. package/dist/cli/help.js +1 -1
  300. package/dist/cli/services/commands/doc/fetch-result.d.ts +2 -0
  301. package/dist/cli/services/commands/doc/fetch-result.js +22 -0
  302. package/dist/cli/services/commands/doc/fetch.d.ts +2 -1
  303. package/dist/cli/services/commands/doc/fetch.js +2 -15
  304. package/dist/cli/services/commands/doc/search-result.d.ts +2 -0
  305. package/dist/cli/services/commands/doc/search-result.js +14 -0
  306. package/dist/cli/services/commands/doc/search.d.ts +9 -1
  307. package/dist/cli/services/commands/doc/search.js +27 -2
  308. package/dist/cli/services/commands/doc/types.d.ts +107 -0
  309. package/dist/cli/services/commands/doc/types.js +47 -0
  310. package/dist/cli/services/commands/help/types.d.ts +6 -6
  311. package/dist/command-event-context-LFUZ7UCA.js +1 -0
  312. package/dist/command-json-schema-2UMKY7MY.js +1 -0
  313. package/dist/command-registry.js +1 -1
  314. package/dist/conf-store-RI3TL6I4.js +1 -0
  315. package/dist/custom-oclif-loader-IZCKN67O.js +1 -0
  316. package/dist/deprecations-IFVUXXDB.js +1 -0
  317. package/dist/dist-4H2B7BMN.js +1 -0
  318. package/dist/dist-QNWOGQN3.js +1 -0
  319. package/dist/{environment-RSUK27TA.js → environment-O7ECODHU.js} +1 -1
  320. package/dist/environments-CYMEN7NV.js +1 -0
  321. package/dist/error-IL6WQMSW.js +1 -0
  322. package/dist/error-handler-74HKA23T.js +1 -0
  323. package/dist/fs-AINFLJ2E.js +1 -0
  324. package/dist/hooks/did-you-mean.js +1 -1
  325. package/dist/hooks/hydrogen-init.js +1 -1
  326. package/dist/hooks/plugin-plugins.js +1 -1
  327. package/dist/hooks/postrun.js +1 -1
  328. package/dist/hooks/prerun.js +1 -1
  329. package/dist/hooks/public-metadata.js +1 -1
  330. package/dist/hooks/sensitive-metadata.js +1 -1
  331. package/dist/hooks/tunnel-provider.js +1 -1
  332. package/dist/hooks/tunnel-start.js +1 -1
  333. package/dist/index.js +13 -13
  334. package/dist/is-global-2VLKV46Q.js +1 -0
  335. package/dist/json-error-HZB5YIHV.js +1 -0
  336. package/dist/{lib-TYM5B75S.js → lib-PJHT4MKY.js} +1 -1
  337. package/dist/{lib-55QUD4AJ.js → lib-VKSQ65BQ.js} +1 -1
  338. package/dist/{lib-PH52G55H.js → lib-YEZOHXF3.js} +1 -1
  339. package/dist/{local-R3UAQN7T.js → local-KOZETREJ.js} +1 -1
  340. package/dist/{metadata-JWJG4JV4.js → metadata-IBPHZB7N.js} +1 -1
  341. package/dist/{morph-BABFBRSW.js → morph-CRY35DIK.js} +1 -1
  342. package/dist/node-package-manager-DXSRNEDC.js +1 -0
  343. package/dist/notifications-system-XA3EBOGJ.js +1 -0
  344. package/dist/os-X73O7BAB.js +1 -0
  345. package/dist/out-B2GISN65.js +1 -0
  346. package/dist/output-3OYXK3Z5.js +1 -0
  347. package/dist/{path-CPAYTWQW.js → path-3L2QRACZ.js} +1 -1
  348. package/dist/system-JWYYT4PM.js +1 -0
  349. package/dist/tsconfig.tsbuildinfo +1 -1
  350. package/dist/ui-PCG5D6RZ.js +1 -0
  351. package/dist/upgrade-7U2TUNC4.js +1 -0
  352. package/dist/version-7DGU2KYH.js +1 -0
  353. package/dist/version-SXQTRBXB.js +1 -0
  354. package/dist/workerd-MQZ3NKJI.js +18 -0
  355. package/oclif.manifest.json +1664 -427
  356. package/package.json +8 -8
  357. package/dist/analytics-APDNTBDE.js +0 -1
  358. package/dist/analytics-LX52KYSE.js +0 -1
  359. package/dist/chunk-2PDVBGQH.js +0 -7
  360. package/dist/chunk-2YVSZFXJ.js +0 -4
  361. package/dist/chunk-35WQTGN3.js +0 -5
  362. package/dist/chunk-37BGAWAW.js +0 -2
  363. package/dist/chunk-3C4WVKSO.js +0 -6
  364. package/dist/chunk-3LHE4GIX.js +0 -1
  365. package/dist/chunk-47IQIIFX.js +0 -383
  366. package/dist/chunk-4ES7BJEK.js +0 -1
  367. package/dist/chunk-4IFY7V7W.js +0 -1
  368. package/dist/chunk-4JGWKUJN.js +0 -2
  369. package/dist/chunk-4O5GQ3DS.js +0 -7
  370. package/dist/chunk-4O7LK5RG.js +0 -26
  371. package/dist/chunk-4TFJ5RW7.js +0 -8
  372. package/dist/chunk-4ZNBEMRT.js +0 -20
  373. package/dist/chunk-5JIJDUXX.js +0 -20
  374. package/dist/chunk-66YRAUWX.js +0 -3
  375. package/dist/chunk-6A4H3HPY.js +0 -7
  376. package/dist/chunk-6HPUOCFF.js +0 -1
  377. package/dist/chunk-6IDEDOXW.js +0 -2
  378. package/dist/chunk-6IMHGT7F.js +0 -8
  379. package/dist/chunk-6MC2BEW4.js +0 -1
  380. package/dist/chunk-73D5O7A3.js +0 -1
  381. package/dist/chunk-7E4MJCVE.js +0 -10
  382. package/dist/chunk-7HNRK2CR.js +0 -1
  383. package/dist/chunk-7SJHVJ3W.js +0 -5
  384. package/dist/chunk-ALK66U3O.js +0 -3
  385. package/dist/chunk-AMLCWRHU.js +0 -4
  386. package/dist/chunk-AYIU6Z4C.js +0 -1
  387. package/dist/chunk-BIWG3FQQ.js +0 -5
  388. package/dist/chunk-BQ3U3CQV.js +0 -1
  389. package/dist/chunk-C6IBY7NW.js +0 -16
  390. package/dist/chunk-CQF5NDTJ.js +0 -4
  391. package/dist/chunk-DMDLJRLW.js +0 -1
  392. package/dist/chunk-DMNWSUKV.js +0 -5
  393. package/dist/chunk-FK7GA4QQ.js +0 -1
  394. package/dist/chunk-FO2R6KHG.js +0 -1
  395. package/dist/chunk-FOAV642V.js +0 -1
  396. package/dist/chunk-GE4MLO3C.js +0 -5
  397. package/dist/chunk-GM4EFJJF.js +0 -7
  398. package/dist/chunk-GN66BRYF.js +0 -1
  399. package/dist/chunk-GPRZYFDE.js +0 -1
  400. package/dist/chunk-GZ7VGCVW.js +0 -3
  401. package/dist/chunk-HASIOUH2.js +0 -3
  402. package/dist/chunk-HILYTMVA.js +0 -1
  403. package/dist/chunk-HJHS23Q3.js +0 -1
  404. package/dist/chunk-HLPAVELJ.js +0 -1
  405. package/dist/chunk-HPM3HF7A.js +0 -1
  406. package/dist/chunk-HQJ62PII.js +0 -3
  407. package/dist/chunk-HQY6JM6G.js +0 -6
  408. package/dist/chunk-HSYMUYEZ.js +0 -359
  409. package/dist/chunk-I5PQZRYM.js +0 -32
  410. package/dist/chunk-IPZ6LUJV.js +0 -4
  411. package/dist/chunk-J4NBPC57.js +0 -1
  412. package/dist/chunk-J6LQR2F6.js +0 -7
  413. package/dist/chunk-JYGZD4HM.js +0 -1
  414. package/dist/chunk-K3HUQLIC.js +0 -6
  415. package/dist/chunk-K7D53KSJ.js +0 -1
  416. package/dist/chunk-KQFA5YTT.js +0 -97
  417. package/dist/chunk-KTD7VLHL.js +0 -2
  418. package/dist/chunk-L4DFMMOI.js +0 -1
  419. package/dist/chunk-LJZTSQRD.js +0 -11
  420. package/dist/chunk-LLPB6JN5.js +0 -9
  421. package/dist/chunk-LYIXRMQJ.js +0 -46
  422. package/dist/chunk-MCNK5SJ6.js +0 -2
  423. package/dist/chunk-MJZSSCGD.js +0 -5
  424. package/dist/chunk-N55MSO3X.js +0 -12
  425. package/dist/chunk-N5AZZYQA.js +0 -4
  426. package/dist/chunk-NCVGCVQ5.js +0 -6
  427. package/dist/chunk-O5FFMTJE.js +0 -25
  428. package/dist/chunk-OE3HSNSE.js +0 -16
  429. package/dist/chunk-ONF7XXEL.js +0 -1
  430. package/dist/chunk-PG4S5HJJ.js +0 -5
  431. package/dist/chunk-PHG4DASY.js +0 -18
  432. package/dist/chunk-PP4VCR4Y.js +0 -1
  433. package/dist/chunk-PWS4VFSD.js +0 -1
  434. package/dist/chunk-Q37WAD6F.js +0 -1
  435. package/dist/chunk-Q43LBSPT.js +0 -1
  436. package/dist/chunk-QAJZUJR5.js +0 -1
  437. package/dist/chunk-QO5RNGWA.js +0 -1
  438. package/dist/chunk-QPQS2YU3.js +0 -1
  439. package/dist/chunk-QUXQM3S3.js +0 -1
  440. package/dist/chunk-R3KSOCMB.js +0 -6
  441. package/dist/chunk-R74WHKHH.js +0 -15
  442. package/dist/chunk-RJSQMKKS.js +0 -1
  443. package/dist/chunk-RK2V6OIJ.js +0 -2
  444. package/dist/chunk-RUHQNF2W.js +0 -1
  445. package/dist/chunk-RXTLNUPF.js +0 -1
  446. package/dist/chunk-SNE4RHM4.js +0 -1
  447. package/dist/chunk-SQAS5RVZ.js +0 -10
  448. package/dist/chunk-SZI6G247.js +0 -103
  449. package/dist/chunk-TVCWDEVS.js +0 -1
  450. package/dist/chunk-TYMYIUIQ.js +0 -1
  451. package/dist/chunk-UIC7K2HX.js +0 -7
  452. package/dist/chunk-UNHT4ZFP.js +0 -317
  453. package/dist/chunk-UQ6ALA3Y.js +0 -3
  454. package/dist/chunk-UWI76E2L.js +0 -18
  455. package/dist/chunk-VE35YELD.js +0 -1
  456. package/dist/chunk-VGBUN3CZ.js +0 -17
  457. package/dist/chunk-VMNOSVPT.js +0 -8
  458. package/dist/chunk-VNFUCH6T.js +0 -1
  459. package/dist/chunk-W4KE7AO6.js +0 -1
  460. package/dist/chunk-WEPO4J2F.js +0 -19
  461. package/dist/chunk-WLWHCUPZ.js +0 -1
  462. package/dist/chunk-XGKCPD6W.js +0 -1
  463. package/dist/chunk-XNVOKAF2.js +0 -1
  464. package/dist/chunk-XSMCQLJW.js +0 -1
  465. package/dist/chunk-XUUIBSLW.js +0 -1
  466. package/dist/chunk-XWQM2NZ2.js +0 -2
  467. package/dist/chunk-Y3PY5LP7.js +0 -3
  468. package/dist/chunk-Y62EMOQA.js +0 -1
  469. package/dist/chunk-Y743UVBS.js +0 -16
  470. package/dist/chunk-YBSX53QP.js +0 -1
  471. package/dist/chunk-YHCP326A.js +0 -16
  472. package/dist/chunk-YHESTFMZ.js +0 -4
  473. package/dist/chunk-YT27FIQN.js +0 -275
  474. package/dist/chunk-YTR5JHNJ.js +0 -2
  475. package/dist/chunk-YYA5VGDW.js +0 -1
  476. package/dist/chunk-Z6X2GT6Q.js +0 -1
  477. package/dist/chunk-ZEE32UH6.js +0 -1
  478. package/dist/cli/commands/app/app-logs/sources.js +0 -1
  479. package/dist/command-json-schema-SS4GDJTQ.js +0 -1
  480. package/dist/conf-store-54YJCIDK.js +0 -1
  481. package/dist/custom-oclif-loader-3UBH7Q7R.js +0 -1
  482. package/dist/deprecations-ZX7ZKF6L.js +0 -1
  483. package/dist/dist-JMNE7MP6.js +0 -1
  484. package/dist/dist-M2AXGBOL.js +0 -1
  485. package/dist/environments-KD2IDYPG.js +0 -1
  486. package/dist/error-AA6LW3PN.js +0 -1
  487. package/dist/error-handler-4VW3AV2G.js +0 -1
  488. package/dist/fs-4QZCAEP7.js +0 -1
  489. package/dist/is-global-FKG327CG.js +0 -1
  490. package/dist/json-error-32ETFU3V.js +0 -1
  491. package/dist/node-package-manager-M4XHUTQR.js +0 -1
  492. package/dist/notifications-system-QVM2JWKB.js +0 -1
  493. package/dist/os-FEHBQQKP.js +0 -1
  494. package/dist/out-53ABAVL7.js +0 -1
  495. package/dist/output-2LS5AOAH.js +0 -1
  496. package/dist/system-TMD2LYZM.js +0 -1
  497. package/dist/ui-FNPICAAH.js +0 -1
  498. package/dist/upgrade-YYPP5VZY.js +0 -1
  499. package/dist/version-OX3MORI6.js +0 -1
  500. package/dist/version-P7D5ME4Z.js +0 -1
  501. package/dist/workerd-TKVRZK2F.js +0 -18
@@ -0,0 +1,25 @@
1
+ import{a as R,b as V,c as H,d as i,e as O,f as _,g as q,h as x,i as C}from"./chunk-U25W35TX.js";import{a as M}from"./chunk-ZGV3HNEV.js";import{a as k}from"./chunk-FWB3GLMW.js";import{Ma as L,ja as F}from"./chunk-3C6VLJ5D.js";import{b as I,c as A,f as p}from"./chunk-Q2SZCZE7.js";import{E as m,G as b,K as w}from"./chunk-CZ22VZDA.js";import{a as g}from"./chunk-BN7ZXAZJ.js";import{h as P}from"./chunk-2VSNFOKD.js";import{Cb as S,Eb as E,wb as T,zb as h}from"./chunk-LWCTKI4Z.js";import{b as n}from"./chunk-FZCGRIOM.js";import{b as Q}from"./chunk-YTUUU33R.js";import{i as v}from"./chunk-IWTNUJGY.js";import{e as X,g as a}from"./chunk-VKWPEFWQ.js";a();a();a();a();async function D(e,t,r){let o={api_version:t},{webhookTopics:s}=await e.topics(o,r);return s}a();async function W(e){let t=e.map(o=>({label:o,value:o}));return await b({message:"Webhook Topic",choices:t})}async function B(e){return m({message:"Webhook ApiVersion",choices:e.map(t=>({label:t,value:t}))})}async function N(){return m({message:"Delivery method",choices:[{label:"HTTP",value:i.HTTP},{label:"Google Pub/Sub",value:i.PUBSUB},{label:"Amazon EventBridge",value:i.EVENTBRIDGE}]})}async function Y(e){return(await w({message:"Address for delivery",validate:r=>{let o=r.trim();if(o.length===0)return"Address can't be empty";if(!O(o,e))return`Invalid address.
2
+ ${c(e)}`}})).trim()}function Z(e){return e===i.HTTP?["For remote HTTP testing, use a URL that starts with https://","For local HTTP testing, use http://localhost:{port}/{url-path}"]:e===i.PUBSUB?["For Google Pub/Sub, use pubsub://{project-id}:{topic-id}"]:e===i.EVENTBRIDGE?["For Amazon EventBridge, use an Amazon Resource Name (ARN) starting with arn:aws:events:"]:[]}function c(e){return Z(e).map(t=>` \xB7 ${E(t)}`).join(`
3
+ `)}async function G(e,t){let{clientSecret:r,clientId:o,remoteApp:s,app:l}=e;return r&&(o||t!==i.EVENTBRIDGE)?{clientSecret:r,apiKey:o}:(F({appName:s.title,configFile:v(l.configPath)}),{clientSecret:s.apiSecretKeys.find(y=>y.secret).secret,apiKey:s.apiKey})}async function j(e,t,r){let o=await R(e,r);return t?q(t,o):B(o)}async function z(e,t,r,o){let s=await D(e,t,o);return r?x(r,t,s):W(s)}async function U(e,t){let r=e??C(t)??await N(),o=t??await Y(r);return _(o,r)}async function J(e){let t=await ee(e);return te(t)}async function ee(e){let t=await j(e.developerPlatformClient,e.apiVersion,e.organizationId),r=await z(e.developerPlatformClient,t,e.topic,e.organizationId),[o,s]=await U(e.deliveryMethod,e.address),l=await G(e,s);return{topic:r,apiVersion:t,deliveryMethod:s,address:o,apiKey:l.apiKey,clientSecret:l.clientSecret,developerPlatformClient:e.developerPlatformClient,organizationId:e.organizationId}}async function te(e){let t={topic:e.topic,api_version:e.apiVersion,address:e.address,delivery_method:e.deliveryMethod,shared_secret:e.clientSecret,api_key:e.apiKey},r=await V(e.developerPlatformClient,t,e.organizationId);if(!r.success)return{status:"failed",reason:"sample-request",userErrors:r.userErrors};let o={topic:e.topic,apiVersion:e.apiVersion,deliveryMethod:e.deliveryMethod,address:e.address,status:"enqueued"};return e.deliveryMethod===i.LOCALHOST?await H(e.address,r.samplePayload,r.headers)?{status:"success",delivery:{...o,status:"delivered"},samplePayloadIsEmpty:r.samplePayload===JSON.stringify({})}:{status:"failed",reason:"localhost-delivery"}:{status:"success",delivery:o,samplePayloadIsEmpty:r.samplePayload===JSON.stringify({})}}a();var K=n.object({topic:n.string(),apiVersion:n.string(),deliveryMethod:n.enum(["localhost","http","google-pub-sub","event-bridge"]),address:n.string(),status:n.enum(["delivered","enqueued"]).describe("Remote delivery is enqueued, not confirmed received.")}).strict(),u=g({name:"AppWebhookTriggerResult",schema:n.object({status:n.literal("success"),delivery:K}).strict(),definitions:{AppWebhookDelivery:K}});a();function $(e,t){if(e.status==="failed"){if(t==="json"){let r=new P(e.reason==="sample-request"?"Webhook sample request failed.":"Localhost delivery failed");throw e.reason==="sample-request"&&(r.details={userErrors:e.userErrors.map(({message:o,fields:s})=>({message:o,fieldPath:s}))}),r}S(e.reason==="sample-request"?`Request errors:
4
+ ${re(e.userErrors)}`:"Localhost delivery failed");return}t==="json"?T(u.encode({status:e.status,delivery:e.delivery})):e.delivery.status==="delivered"?h("Localhost delivery sucessful"):e.samplePayloadIsEmpty&&h("Webhook has been enqueued for delivery")}function re(e){try{return e.map(t=>JSON.parse(t.message).map(r=>` \xB7 ${r}`).join(`
5
+ `)).join(`
6
+ `)}catch{return JSON.stringify(e)}}var d=X(Q(),1);var f=class e extends M{static summary="Trigger delivery of a sample webhook topic payload to a designated address.";static descriptionWithMarkdown=`
7
+ Triggers the delivery of a sample Admin API event topic payload to a designated address.
8
+
9
+ You should use this command to experiment with webhooks, to initially test your webhook configuration, or for unit testing. However, to test your webhook configuration from end to end, you should always trigger webhooks by performing the related action in Shopify.
10
+
11
+ Because most webhook deliveries use remote endpoints, you can trigger the command from any directory where you can use Shopify CLI, and send the webhook to any of the supported endpoint types. For example, you can run the command from your app's local directory, but send the webhook to a staging environment endpoint.
12
+
13
+ To learn more about using webhooks in a Shopify app, refer to [Webhooks overview](https://shopify.dev/docs/apps/webhooks).
14
+
15
+ ### Limitations
16
+
17
+ - Webhooks triggered using this method always have the same payload, so they can't be used to test scenarios that differ based on the payload contents.
18
+ - Webhooks triggered using this method aren't retried when they fail.
19
+ - Trigger requests are rate-limited using the [Partner API rate limit](https://shopify.dev/docs/api/partner#rate_limits).
20
+ - You can't use this method to validate your API webhook subscriptions.
21
+ `;static get jsonOutputSchema(){return u}static description=this.descriptionForHelp();static flags={...I,...k,...A,help:d.Flags.help({required:!1,hidden:!1,env:"SHOPIFY_FLAG_HELP",description:"This help. When you run the trigger command the CLI will prompt you for any information that isn't passed using flags."}),topic:p(d.Flags.string({required:!1,hidden:!1,env:"SHOPIFY_FLAG_TOPIC",description:"The requested webhook topic."})),"api-version":p(d.Flags.string({required:!1,hidden:!1,env:"SHOPIFY_FLAG_API_VERSION",description:"The API Version of the webhook topic."})),"delivery-method":d.Flags.string({required:!1,hidden:!1,options:[i.HTTP,i.PUBSUB,i.EVENTBRIDGE],env:"SHOPIFY_FLAG_DELIVERY_METHOD",description:"Method chosen to deliver the topic payload. If not passed, it's inferred from the address."}),"client-secret":d.Flags.string({required:!1,hidden:!1,env:"SHOPIFY_FLAG_CLIENT_SECRET",description:"Your app's client secret. This secret allows us to return the X-Shopify-Hmac-SHA256 header that lets you validate the origin of the response that you receive."}),address:p(d.Flags.string({required:!1,hidden:!1,env:"SHOPIFY_FLAG_ADDRESS",description:`The URL where the webhook payload should be sent.
22
+ You will need a different address type for each delivery-method:
23
+ ${c(i.HTTP)}
24
+ ${c(i.PUBSUB)}
25
+ ${c(i.EVENTBRIDGE)}`}))};async run(){let{flags:t}=await this.parse(e),r=await L({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config}),o={...r,topic:t.topic,apiVersion:t["api-version"],deliveryMethod:t["delivery-method"],address:t.address,clientId:t["client-id"],clientSecret:t["client-secret"],path:t.path,config:t.config,organizationId:r.organization.id},s=await J(o);return $(s,t.json?"json":"text"),{app:r.app}}};export{f as a};
@@ -0,0 +1 @@
1
+ import{E as h,F as e,G as r,K as o,L as s,p as n}from"./chunk-CZ22VZDA.js";import{g as i}from"./chunk-VKWPEFWQ.js";i();async function y(){await h({message:"Associate your project with the org Castile Ventures?",choices:[{label:"first",value:"first",disabled:!0},{label:"second",value:"second"},{label:"third (limit reached)",value:"third",disabled:!0},{label:"fourth (limit reached)",value:"fourth",disabled:!0},{label:"fifth",value:"fifth",group:"Automations",disabled:!0},{label:"sixth",value:"sixth",group:"Automations"},{label:"seventh",value:"seventh"},{label:"eighth (limit reached)",value:"eighth",group:"Merchant Admin",disabled:!0},{label:"ninth",value:"ninth",group:"Merchant Admin"},{label:"tenth",value:"tenth"}],infoTable:[{header:"add",items:["new-ext"],bullet:"+"},{header:"remove",items:["integrated-demand-ext","order-discount"],bullet:"-"}]}),await o({message:"App project name (can be changed later)",defaultValue:"expansive commerce app",validate:t=>{if(t.includes("shopify"))return`Can't include "shopify" in the name`}});let l=[{label:"first",value:"first"},{label:"second",value:"second"},{label:"third",value:"third"},{label:"fourth",value:"fourth"},{label:"fifth",value:"fifth"},{label:"sixth",value:"sixth"},{label:"seventh",value:"seventh"},{label:"eighth",value:"eighth"},{label:"ninth",value:"ninth"},{label:"tenth",value:"tenth"},{label:"eleventh",value:"eleventh"},{label:"twelfth",value:"twelfth"},{label:"thirteenth",value:"thirteenth"},{label:"fourteenth",value:"fourteenth"},{label:"fifteenth",value:"fifteenth"},{label:"sixteenth",value:"sixteenth"},{label:"seventeenth",value:"seventeenth"},{label:"eighteenth",value:"eighteenth"},{label:"nineteenth",value:"nineteenth"},{label:"twentieth",value:"twentieth"},{label:"twenty-first",value:"twenty-first"},{label:"twenty-second",value:"twenty-second"},{label:"twenty-third",value:"twenty-third"},{label:"twenty-fourth",value:"twenty-fourth"},{label:"twenty-fifth",value:"twenty-fifth"},{label:"twenty-sixth",value:"twenty-sixth"},{label:"twenty-seventh",value:"twenty-seventh"},{label:"twenty-eighth",value:"twenty-eighth"},{label:"twenty-ninth",value:"twenty-ninth"},{label:"thirtieth",value:"thirtieth"},{label:"thirty-first",value:"thirty-first"},{label:"thirty-second",value:"thirty-second"},{label:"thirty-third",value:"thirty-third"},{label:"thirty-fourth",value:"thirty-fourth"},{label:"thirty-fifth",value:"thirty-fifth"},{label:"thirty-sixth",value:"thirty-sixth"},{label:"thirty-seventh",value:"thirty-seventh"},{label:"thirty-eighth",value:"thirty-eighth"},{label:"thirty-ninth",value:"thirty-ninth"},{label:"fortieth",value:"fortieth"},{label:"forty-first",value:"forty-first"},{label:"forty-second",value:"forty-second"},{label:"forty-third",value:"forty-third"},{label:"forty-fourth",value:"forty-fourth"},{label:"forty-fifth",value:"forty-fifth"},{label:"forty-sixth",value:"forty-sixth"},{label:"forty-seventh",value:"forty-seventh"},{label:"forty-eighth",value:"forty-eighth"},{label:"forty-ninth",value:"forty-ninth"},{label:"fiftieth",value:"fiftieth"}];await r({message:"Template",choices:l,search(t){return Promise.resolve({data:l.filter(f=>f.label.includes(t))})}});let a=[["first theme",{subdued:"(#1)"}],["second theme",{subdued:"(#2)"}]];await e({message:"Add the following themes to the store?",infoTable:{"":a},confirmationMessage:"Yes, add them",cancellationMessage:"Cancel"});let u={title:{color:"red",text:`${n.warning} This can't be undone.`},body:"The action you are executing should be confirmed to proceed."};await e({message:"Delete the following themes from the store?",infoTable:{"":a},infoMessage:u,confirmationMessage:"Yes, delete them",cancellationMessage:"Cancel",defaultValue:!1}),await e({message:["Make the following changes to your",{filePath:".env"},"file?"],defaultValue:!0,confirmationMessage:"Yes, confirm changes",cancellationMessage:"No, make changes later"}),await s({message:"Release this version of Mega App?",infoTable:[{header:"Includes",items:["My subscription extension","Order discount function","Subscription cancelled trigger","Add subscription action"],bullet:"+"},{header:"Removes",items:["product-discount-function","product-subscription-extension"],bullet:"-"}],confirmation:"Mega App"})}export{y as a};
@@ -0,0 +1,3 @@
1
+ import{a as J}from"./chunk-ZGV3HNEV.js";import{a as x}from"./chunk-FWB3GLMW.js";import{A,E as S,I as E,J as F,K as R,Ma as k}from"./chunk-3C6VLJ5D.js";import{a as f}from"./chunk-IQVRP7CT.js";import{b as j,c as V}from"./chunk-Q2SZCZE7.js";import{A as y,C as u}from"./chunk-CZ22VZDA.js";import{a as C}from"./chunk-BN7ZXAZJ.js";import{j as h}from"./chunk-2VSNFOKD.js";import{wb as g,xb as v}from"./chunk-LWCTKI4Z.js";import{b as i}from"./chunk-FZCGRIOM.js";import{g as w,i as m}from"./chunk-IWTNUJGY.js";import{g as r}from"./chunk-VKWPEFWQ.js";r();r();var M=i.object({filePath:i.string().refine(w,"Expected an absolute filesystem path.").nullable(),message:i.string(),fieldPath:i.array(i.union([i.string(),i.number().int().nonnegative()])).nullable(),code:i.string().nullable().describe("The upstream validation code, or null when unavailable.")}).strict(),c=C({name:"AppConfigValidateResult",schema:i.object({path:i.string().refine(w,"Expected an absolute filesystem path."),valid:i.boolean(),issues:i.array(M)}).strict(),definitions:{ValidationIssue:M}});r();function O(a,t){t==="json"?g(c.encode(a)):a.valid?y({headline:`App configuration '${m(a.path)}' is valid.`}):u({headline:"Validation errors found.",body:a.issues.map(e=>`\u2022 ${R({file:e.filePath??a.path,path:e.fieldPath??void 0,code:e.code??void 0,message:e.message})}`).join(`
2
+ `)})}r();import{resolve as z}from"node:path";async function B(a,t){let e=new Set(t.map(o=>o.file)).size;await f.addPublicMetadata(()=>({cmd_app_validate_valid:a,cmd_app_validate_issue_count:t.length,cmd_app_validate_file_count:e}))}async function I(a){let t=a.errors?.getErrors()??[];return await B(t.length===0,t),{path:z(a.configPath),valid:t.length===0,issues:t.map(({file:e,message:o,path:p,code:d})=>({filePath:z(e),message:o,fieldPath:p??null,code:d??null}))}}import{resolve as _}from"node:path";async function T(a,t){await f.addPublicMetadata(()=>({cmd_app_validate_valid:!1,cmd_app_validate_issue_count:a,cmd_app_validate_file_count:t}))}async function $(a,t){let e=new Set(t.map(o=>o.filePath)).size;throw await T(t.length,e),g(c.encode({path:_(a),valid:!1,issues:t})),await v(),new h}var b=class a extends J{static summary="Validate your app configuration and extensions.";static descriptionWithMarkdown="Validates the selected app configuration file and all extension configurations against their schemas and reports any errors found.";static get jsonOutputSchema(){return c}static description=this.descriptionForHelp();static flags={...j,...x,...V};async run(){let{flags:t}=await this.parse(a);await f.addPublicMetadata(()=>({cmd_app_validate_json:t.json}));let e=await A.load(t.path),o=await E(e,t.config,{clientId:t["client-id"],skipPrompts:!!t["client-id"]}),p=S(e,o.file);if(p.length>0){let n=p.map(s=>({filePath:_(s.path),message:s.message,fieldPath:null,code:null}));t.json&&await $(o.file.path,n);let l=new Set(p.map(s=>s.path)).size;throw await T(n.length,l),u({headline:"Validation errors found.",body:n.map(s=>`\u2022 ${s.message}`).join(`
3
+ `)}),new h}let d;try{d=(await k({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config??(t["client-id"]?m(o.file.path):void 0),unsafeTolerateErrors:!0})).app}catch(n){throw n instanceof F&&t.json&&await $(n.configurationPath,n.errors.map(l=>({filePath:_(l.file),message:l.message,fieldPath:l.path??null,code:l.code??null}))),n}let P=await I(d);if(O(P,t.json?"json":"text"),!P.valid)throw await v(),new h;return{app:d}}};export{b as a};
@@ -0,0 +1,3 @@
1
+ import{b as f}from"./chunk-RVQV6G5M.js";import{D as c}from"./chunk-H4V55Y3Z.js";import{z as m}from"./chunk-CZ22VZDA.js";import{a}from"./chunk-BN7ZXAZJ.js";import{k as d}from"./chunk-2VSNFOKD.js";import{yb as h}from"./chunk-LWCTKI4Z.js";import{b as t,c as l,d as s}from"./chunk-FZCGRIOM.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();o();var u=t.string().regex(/^gid:\/\/shopify\/BulkOperation\/[^/]+$/).describe("The Shopify global ID of a bulk operation."),n=t.object({gid:u,type:t.string(),status:t.string(),errorCode:t.string().nullable(),createdAt:l,completedAt:l.nullable(),objectCount:t.string().regex(/^\d+$/).describe("A nonnegative decimal count, without loss of integer precision."),url:t.string().url().nullable(),partialDataUrl:t.string().url().nullable()}).strict(),i=t.object({storeDomain:t.string().regex(/^[^.]+\.myshopify\.com$/).nullable(),apiVersion:t.string().nullable().describe("The API version selected for the request.")}).strict();var B=n.omit({type:!0}),O=i.extend({operationGid:u,operation:n.nullable()}),b=i.extend({operations:t.array(B),pageInfo:t.object({hasNextPage:t.boolean().nullable().describe("Unknown when the API result reaches the fetch limit.")}).strict()}),D=a({name:"BulkOperationStatusResult",schema:t.union([O,b]),definitions:{GetBulkOperationStatusResult:O,ListBulkOperationsResult:b,BulkOperation:n,ListedBulkOperation:B}}),J=a({name:"CancelBulkOperationResult",schema:i.extend({status:t.literal("success"),operation:n}),definitions:{BulkOperation:n}}),k=i.extend({status:t.enum(["success","partial","cancelled"]),reason:t.literal("watch-aborted").optional(),operation:n,resultsJsonl:t.string().optional().describe("Downloaded results in their native JSONL format.")}),g=t.object({path:t.string().describe("The absolute path of the downloaded results file."),format:t.literal("jsonl")}).strict(),R=a({name:"ExecuteBulkOperationResult",schema:t.union([k,g]),definitions:{BulkOperation:n,ExecuteBulkOperationResult:k,BulkOperationFile:g}});o();function U(e,r,S){let p=[...r.operationId?[`ID: ${r.operationId}`]:[],...f(r)];if(S==="json"){h(`${e}
2
+ ${p.join(`
3
+ `)}`);return}m({headline:e,body:[{list:{items:p}}]})}o();function F(e){let r=c(e.store);return{storeDomain:r?`${r}.myshopify.com`:null,apiVersion:e.apiVersion??null}}function q(e){if(typeof e.objectCount=="number"&&!Number.isSafeInteger(e.objectCount))throw new d("Shopify returned a bulk operation count that can't be represented exactly.");return{gid:e.id,..."type"in e?{type:e.type}:{},status:e.status,errorCode:e.errorCode??null,createdAt:s(new Date(String(e.createdAt))),completedAt:e.completedAt?s(new Date(String(e.completedAt))):null,objectCount:String(e.objectCount),url:e.url??null,partialDataUrl:e.partialDataUrl??null}}export{D as a,J as b,R as c,F as d,q as e,U as f};
@@ -0,0 +1 @@
1
+ import{a as o}from"./chunk-MDRVCBDO.js";import{g as e}from"./chunk-VKWPEFWQ.js";e();var t=class extends o{};export{t as a};
@@ -1,8 +1,8 @@
1
- import{i as E}from"./chunk-Q37WAD6F.js";import{Cb as $,Eb as T,Nb as O,Xa as V,qa as N}from"./chunk-UWI76E2L.js";import{a as g,c as w,e as Y,g as m}from"./chunk-VKWPEFWQ.js";var I=w((z,R)=>{R.exports={name:"dotenv",version:"16.6.1",description:"Loads environment variables from .env file",main:"lib/main.js",types:"lib/main.d.ts",exports:{".":{types:"./lib/main.d.ts",require:"./lib/main.js",default:"./lib/main.js"},"./config":"./config.js","./config.js":"./config.js","./lib/env-options":"./lib/env-options.js","./lib/env-options.js":"./lib/env-options.js","./lib/cli-options":"./lib/cli-options.js","./lib/cli-options.js":"./lib/cli-options.js","./package.json":"./package.json"},scripts:{"dts-check":"tsc --project tests/types/tsconfig.json",lint:"standard",pretest:"npm run lint && npm run dts-check",test:"tap run --allow-empty-coverage --disable-coverage --timeout=60000","test:coverage":"tap run --show-full-coverage --timeout=60000 --coverage-report=text --coverage-report=lcov",prerelease:"npm test",release:"standard-version"},repository:{type:"git",url:"git://github.com/motdotla/dotenv.git"},homepage:"https://github.com/motdotla/dotenv#readme",funding:"https://dotenvx.com",keywords:["dotenv","env",".env","environment","variables","config","settings"],readmeFilename:"README.md",license:"BSD-2-Clause",devDependencies:{"@types/node":"^18.11.3",decache:"^4.6.2",sinon:"^14.0.1",standard:"^17.0.0","standard-version":"^9.5.0",tap:"^19.2.0",typescript:"^4.8.4"},engines:{node:">=12"},browser:{fs:!1}}});var K=w((X,d)=>{m();var b=g("fs"),y=g("path"),q=g("os"),F=g("crypto"),P=I(),D=P.version,C=/(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/mg;function S(e){let n={},r=e.toString();r=r.replace(/\r\n?/mg,`
1
+ import{h as E}from"./chunk-2VSNFOKD.js";import{Bb as O,Sa as V,la as N,qb as $,sb as T}from"./chunk-LWCTKI4Z.js";import{a as g,c as w,e as Y,g as m}from"./chunk-VKWPEFWQ.js";var I=w((z,R)=>{R.exports={name:"dotenv",version:"16.6.1",description:"Loads environment variables from .env file",main:"lib/main.js",types:"lib/main.d.ts",exports:{".":{types:"./lib/main.d.ts",require:"./lib/main.js",default:"./lib/main.js"},"./config":"./config.js","./config.js":"./config.js","./lib/env-options":"./lib/env-options.js","./lib/env-options.js":"./lib/env-options.js","./lib/cli-options":"./lib/cli-options.js","./lib/cli-options.js":"./lib/cli-options.js","./package.json":"./package.json"},scripts:{"dts-check":"tsc --project tests/types/tsconfig.json",lint:"standard",pretest:"npm run lint && npm run dts-check",test:"tap run --allow-empty-coverage --disable-coverage --timeout=60000","test:coverage":"tap run --show-full-coverage --timeout=60000 --coverage-report=text --coverage-report=lcov",prerelease:"npm test",release:"standard-version"},repository:{type:"git",url:"git://github.com/motdotla/dotenv.git"},homepage:"https://github.com/motdotla/dotenv#readme",funding:"https://dotenvx.com",keywords:["dotenv","env",".env","environment","variables","config","settings"],readmeFilename:"README.md",license:"BSD-2-Clause",devDependencies:{"@types/node":"^18.11.3",decache:"^4.6.2",sinon:"^14.0.1",standard:"^17.0.0","standard-version":"^9.5.0",tap:"^19.2.0",typescript:"^4.8.4"},engines:{node:">=12"},browser:{fs:!1}}});var K=w((X,d)=>{m();var b=g("fs"),y=g("path"),q=g("os"),F=g("crypto"),P=I(),D=P.version,C=/(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/mg;function S(e){let n={},r=e.toString();r=r.replace(/\r\n?/mg,`
2
2
  `);let s;for(;(s=C.exec(r))!=null;){let a=s[1],t=s[2]||"";t=t.trim();let o=t[0];t=t.replace(/^(['"`])([\s\S]*)\1$/mg,"$2"),o==='"'&&(t=t.replace(/\\n/g,`
3
3
  `),t=t.replace(/\\r/g,"\r")),n[a]=t}return n}function U(e){e=e||{};let n=x(e);e.path=n;let r=l.configDotenv(e);if(!r.parsed){let o=new Error(`MISSING_DATA: Cannot parse ${n} for an unknown reason`);throw o.code="MISSING_DATA",o}let s=A(e).split(","),a=s.length,t;for(let o=0;o<a;o++)try{let i=s[o].trim(),f=M(r,i);t=l.decrypt(f.ciphertext,f.key);break}catch(i){if(o+1>=a)throw i}return l.parse(t)}function B(e){console.log(`[dotenv@${D}][WARN] ${e}`)}function v(e){console.log(`[dotenv@${D}][DEBUG] ${e}`)}function j(e){console.log(`[dotenv@${D}] ${e}`)}function A(e){return e&&e.DOTENV_KEY&&e.DOTENV_KEY.length>0?e.DOTENV_KEY:process.env.DOTENV_KEY&&process.env.DOTENV_KEY.length>0?process.env.DOTENV_KEY:""}function M(e,n){let r;try{r=new URL(n)}catch(i){if(i.code==="ERR_INVALID_URL"){let f=new Error("INVALID_DOTENV_KEY: Wrong format. Must be in valid uri format like dotenv://:key_1234@dotenvx.com/vault/.env.vault?environment=development");throw f.code="INVALID_DOTENV_KEY",f}throw i}let s=r.password;if(!s){let i=new Error("INVALID_DOTENV_KEY: Missing key part");throw i.code="INVALID_DOTENV_KEY",i}let a=r.searchParams.get("environment");if(!a){let i=new Error("INVALID_DOTENV_KEY: Missing environment part");throw i.code="INVALID_DOTENV_KEY",i}let t=`DOTENV_VAULT_${a.toUpperCase()}`,o=e.parsed[t];if(!o){let i=new Error(`NOT_FOUND_DOTENV_ENVIRONMENT: Cannot locate environment ${t} in your .env.vault file.`);throw i.code="NOT_FOUND_DOTENV_ENVIRONMENT",i}return{ciphertext:o,key:s}}function x(e){let n=null;if(e&&e.path&&e.path.length>0)if(Array.isArray(e.path))for(let r of e.path)b.existsSync(r)&&(n=r.endsWith(".vault")?r:`${r}.vault`);else n=e.path.endsWith(".vault")?e.path:`${e.path}.vault`;else n=y.resolve(process.cwd(),".env.vault");return b.existsSync(n)?n:null}function k(e){return e[0]==="~"?y.join(q.homedir(),e.slice(1)):e}function W(e){let n=!!(e&&e.debug),r=e&&"quiet"in e?e.quiet:!0;(n||!r)&&j("Loading env from encrypted .env.vault");let s=l._parseVault(e),a=process.env;return e&&e.processEnv!=null&&(a=e.processEnv),l.populate(a,s,e),{parsed:s}}function G(e){let n=y.resolve(process.cwd(),".env"),r="utf8",s=!!(e&&e.debug),a=e&&"quiet"in e?e.quiet:!0;e&&e.encoding?r=e.encoding:s&&v("No encoding is specified. UTF-8 is used by default");let t=[n];if(e&&e.path)if(!Array.isArray(e.path))t=[k(e.path)];else{t=[];for(let u of e.path)t.push(k(u))}let o,i={};for(let u of t)try{let c=l.parse(b.readFileSync(u,{encoding:r}));l.populate(i,c,e)}catch(c){s&&v(`Failed to load ${u} ${c.message}`),o=c}let f=process.env;if(e&&e.processEnv!=null&&(f=e.processEnv),l.populate(f,i,e),s||!a){let u=Object.keys(i).length,c=[];for(let p of t)try{let h=y.relative(process.cwd(),p);c.push(h)}catch(h){s&&v(`Failed to load ${p} ${h.message}`),o=h}j(`injecting env (${u}) from ${c.join(",")}`)}return o?{parsed:i,error:o}:{parsed:i}}function J(e){if(A(e).length===0)return l.configDotenv(e);let n=x(e);return n?l._configVault(e):(B(`You set DOTENV_KEY but you are missing a .env.vault file at ${n}. Did you forget to build it?`),l.configDotenv(e))}function Q(e,n){let r=Buffer.from(n.slice(-64),"hex"),s=Buffer.from(e,"base64"),a=s.subarray(0,12),t=s.subarray(-16);s=s.subarray(12,-16);try{let o=F.createDecipheriv("aes-256-gcm",r,a);return o.setAuthTag(t),`${o.update(s)}${o.final()}`}catch(o){let i=o instanceof RangeError,f=o.message==="Invalid key length",u=o.message==="Unsupported state or unable to authenticate data";if(i||f){let c=new Error("INVALID_DOTENV_KEY: It must be 64 characters long (or more)");throw c.code="INVALID_DOTENV_KEY",c}else if(u){let c=new Error("DECRYPTION_FAILED: Please check your DOTENV_KEY");throw c.code="DECRYPTION_FAILED",c}else throw o}}function H(e,n,r={}){let s=!!(r&&r.debug),a=!!(r&&r.override);if(typeof n!="object"){let t=new Error("OBJECT_REQUIRED: Please check the processEnv argument being passed to populate");throw t.code="OBJECT_REQUIRED",t}for(let t of Object.keys(n))Object.prototype.hasOwnProperty.call(e,t)?(a===!0&&(e[t]=n[t]),s&&v(a===!0?`"${t}" is already defined and WAS overwritten`:`"${t}" is already defined and was NOT overwritten`)):e[t]=n[t]}var l={configDotenv:G,_configVault:W,_parseVault:U,config:J,decrypt:Q,parse:S,populate:H};d.exports.configDotenv=l.configDotenv;d.exports._configVault=l._configVault;d.exports._parseVault=l._parseVault;d.exports.config=l.config;d.exports.decrypt=l.decrypt;d.exports.parse=l.parse;d.exports.populate=l.populate;d.exports=l});m();var L=Y(K());async function oe(e){if(O(T`Reading the .env file at ${$.path(e)}`),!await V(e))throw new E(`The environment file at ${e} does not exist.`);let n=await N(e);return{path:e,variables:(0,L.parse)(n)}}function se(e,n){let r=[],s=e===null?[]:e.split(`
4
4
  `),a=[],t;for(let o of s){if(t){if(o.endsWith(t.quote)){let u=_(t.key,t.value+o.slice(0,-1),t.quote),c=n[t.key];c&&(a.push(t.key),u=_(t.key,c)),r.push(u),t=void 0}else t.value+=`${o}
5
5
  `;continue}let i=o.match(/^([^=:#]+?)[=:](.*)/),f=o;if(i){let u=i[1].trim(),c=(i[2]??"").trim();if(/^["'`]/.test(c)&&!c.endsWith(c[0])){t={key:u,value:`${c.slice(1)}
6
6
  `,quote:c[0]};continue}let p=n[u];p&&(a.push(u),f=_(u,p))}r.push(f)}if(t)throw new E(`Multi-line environment variable '${t.key}' is not properly enclosed.`);for(let[o,i]of Object.entries(n))a.includes(o)||r.push(_(o,i));return r.join(`
7
7
  `)}function _(e,n,r){if(r)return`${e}=${r}${n}${r}`;if(n?.includes(`
8
- `)){let s=['"',"'","`"].find(a=>!n.includes(a));if(!s)throw new E(`The environment file patch has an env value that can't be surrounded by quotes: ${n}`);return`${e}=${s}${n}${s}`}return`${e}=${n}`}export{oe as a,se as b,_ as c};
8
+ `)){let s=['"',"'","`"].find(a=>!n.includes(a));if(!s)throw new E(`The environment file patch has an env value that can't be surrounded by quotes: ${n}`);return`${e}=${s}${n}${s}`}return`${e}=${n}`}export{oe as a,se as b};
@@ -0,0 +1,6 @@
1
+ import{a as N,b as c,c as S}from"./chunk-HF4NDEX3.js";import{a as O}from"./chunk-6PUU6ZNQ.js";import{a as w}from"./chunk-PSSYLJG4.js";import{a as E}from"./chunk-P33TONYG.js";import{e as g}from"./chunk-QFWWCZOI.js";import{f as R,o as F}from"./chunk-5TB52UUV.js";import{p as v,v as T}from"./chunk-DJAZBPYA.js";import{b as u,c as d,f}from"./chunk-Q2SZCZE7.js";import{A as l}from"./chunk-CZ22VZDA.js";import{wb as h}from"./chunk-LWCTKI4Z.js";import{b as r}from"./chunk-FZCGRIOM.js";import{b as j}from"./chunk-YTUUU33R.js";import{e as _,g as m}from"./chunk-VKWPEFWQ.js";m();m();var x=O.extend({originalName:r.string(),theme:N}),a=g({name:"ThemeRenameResult",schema:r.object({status:r.literal("success"),changed:r.boolean(),originalName:r.string(),theme:c}).strict(),definitions:{Theme:c},project(t){let e=x.parse(t);return{status:e.status,changed:e.originalName!==e.theme.name,originalName:e.originalName,theme:S(e.theme)}}});m();function y(t,e,n){if(e==="json"){h(a.encode(t.data));return}l({body:[...n?[{subdued:`Environment: ${n}
2
+
3
+ `}]:[],"The theme",...w(t.originalTheme),"was renamed to",`'${t.requestedName}'`]})}m();async function I(t,e){let n=t.name??await R("New name for the theme"),o=await E(e,{header:"Select a theme to rename",filter:{theme:t.theme,development:t.development,live:t.live}}),s=await F(o.id,{name:n},e);return{data:{status:"success",originalName:o.name,theme:{...s,processing:o.processing,shop:e.storeFqdn}},originalTheme:o,requestedName:n}}var i=_(j(),1);var p=class extends T{static get jsonOutputSchema(){return a}static summary="Renames an existing theme.";static descriptionWithMarkdown=`Renames a theme in your store.
4
+
5
+ If no theme is specified, then you're prompted to select the theme that you want to rename from the list of themes in your store.
6
+ `;static description=this.descriptionForHelp();static flags={...u,...d,...v,name:f(i.Flags.string({char:"n",description:"The new name for the theme.",env:"SHOPIFY_FLAG_NEW_NAME",required:!1})),development:i.Flags.boolean({char:"d",description:"Rename your development theme. Use --development, --live, or --theme in non-interactive environments.",env:"SHOPIFY_FLAG_DEVELOPMENT"}),theme:i.Flags.string({char:"t",description:"Theme ID or name of the remote theme. Use --development, --live, or --theme in non-interactive environments.",env:"SHOPIFY_FLAG_THEME_ID"}),live:i.Flags.boolean({char:"l",description:"Rename your remote live theme. Use --development, --live, or --theme in non-interactive environments.",env:"SHOPIFY_FLAG_LIVE"})};static multiEnvironmentsFlags=["store","password","name",["live","development","theme"]];static nonTTYFlagRequirements(){return[{flags:["theme","development","live"]}]}async command(e,n,o=!1){let s=await I(e,n);if(e.json&&o)return s.data;y(s,e.json?"json":"text",e.environment)}renderEnvironmentResults(e){h(a.encode({environments:e}))}};export{p as a};
@@ -0,0 +1,10 @@
1
+ import{a as hD}from"./chunk-5HBIIYSK.js";import{b as pD,e as X,g as BD,h as M}from"./chunk-B4OMIONW.js";import{a as fD,c as g,d as dD,e as J,g as i}from"./chunk-VKWPEFWQ.js";var pu=g((It,du)=>{i();du.exports=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g});var yu=g((Qt,Tu)=>{i();var GD=pD(),qD=function(){return GD.Date.now()};Tu.exports=qD});var Su=g((ur,vu)=>{i();var HD=/\s/;function VD(u){for(var D=u.length;D--&&HD.test(u.charAt(D)););return D}vu.exports=VD});var Nu=g((er,$u)=>{i();var UD=Su(),KD=/^\s+/;function zD(u){return u&&u.slice(0,UD(u)+1).replace(KD,"")}$u.exports=zD});var _u=g((rr,Lu)=>{i();var YD=Nu(),Ru=X(),JD=BD(),Wu=NaN,XD=/^[-+]0x[0-9a-f]+$/i,QD=/^0b[01]+$/i,ZD=/^0o[0-7]+$/i,ue=parseInt;function De(u){if(typeof u=="number")return u;if(JD(u))return Wu;if(Ru(u)){var D=typeof u.valueOf=="function"?u.valueOf():u;u=Ru(D)?D+"":D}if(typeof u!="string")return u===0?u:+u;u=YD(u);var e=QD.test(u);return e||ZD.test(u)?ue(u.slice(2),e?2:8):XD.test(u)?Wu:+u}Lu.exports=De});var ku=g((nr,Iu)=>{i();var ee=X(),eu=yu(),Ou=_u(),te="Expected a function",re=Math.max,Fe=Math.min;function ne(u,D,e){var t,r,F,o,n,s,C=0,b=!1,c=!1,p=!0;if(typeof u!="function")throw new TypeError(te);D=Ou(D)||0,ee(e)&&(b=!!e.leading,c="maxWait"in e,F=c?re(Ou(e.maxWait)||0,D):F,p="trailing"in e?!!e.trailing:p);function l(d){var x=t,R=r;return t=r=void 0,C=d,o=u.apply(R,x),o}function B(d){return C=d,n=setTimeout(h,D),b?l(d):o}function f(d){var x=d-s,R=d-C,Eu=D-x;return c?Fe(Eu,F-R):Eu}function m(d){var x=d-s,R=d-C;return s===void 0||x>=D||x<0||c&&R>=F}function h(){var d=eu();if(m(d))return k(d);n=setTimeout(h,f(d))}function k(d){return n=void 0,p&&t?l(d):(t=r=void 0,o)}function Cu(){n!==void 0&&clearTimeout(n),C=0,t=s=r=n=void 0}function lD(){return n===void 0?o:k(eu())}function Y(){var d=eu(),x=m(d);if(t=arguments,r=this,s=d,x){if(n===void 0)return B(s);if(c)return clearTimeout(n),n=setTimeout(h,D),l(s)}return n===void 0&&(n=setTimeout(h,D)),o}return Y.cancel=Cu,Y.flush=lD,Y}Iu.exports=ne});var Ce=g((ir,Mu)=>{i();var oe=ku(),ie=X(),se="Expected a function";function ae(u,D,e){var t=!0,r=!0;if(typeof u!="function")throw new TypeError(se);return ie(e)&&(t="leading"in e?!!e.leading:t,r="trailing"in e?!!e.trailing:r),oe(u,D,{leading:t,maxWait:D,trailing:r})}Mu.exports=ae});var Qu=g((Mr,Fu)=>{"use strict";i();var Xu=(u,D)=>{for(let e of Reflect.ownKeys(D))Object.defineProperty(u,e,Object.getOwnPropertyDescriptor(D,e));return u};Fu.exports=Xu;Fu.exports.default=Xu});var uD=g((Pr,K)=>{"use strict";i();var ze=Qu(),U=new WeakMap,Zu=(u,D={})=>{if(typeof u!="function")throw new TypeError("Expected a function");let e,t=0,r=u.displayName||u.name||"<anonymous>",F=function(...o){if(U.set(F,++t),t===1)e=u.apply(this,o),u=null;else if(D.throw===!0)throw new Error(`Function \`${r}\` can only be called once`);return e};return ze(F,u),U.set(F,t),F};K.exports=Zu;K.exports.default=Zu;K.exports.callCount=u=>{if(!U.has(u))throw new Error(`The given function \`${u.name}\` is not wrapped by the \`onetime\` package`);return U.get(u)}});var nD=g((nF,it)=>{it.exports={single:{topLeft:"\u250C",top:"\u2500",topRight:"\u2510",right:"\u2502",bottomRight:"\u2518",bottom:"\u2500",bottomLeft:"\u2514",left:"\u2502"},double:{topLeft:"\u2554",top:"\u2550",topRight:"\u2557",right:"\u2551",bottomRight:"\u255D",bottom:"\u2550",bottomLeft:"\u255A",left:"\u2551"},round:{topLeft:"\u256D",top:"\u2500",topRight:"\u256E",right:"\u2502",bottomRight:"\u256F",bottom:"\u2500",bottomLeft:"\u2570",left:"\u2502"},bold:{topLeft:"\u250F",top:"\u2501",topRight:"\u2513",right:"\u2503",bottomRight:"\u251B",bottom:"\u2501",bottomLeft:"\u2517",left:"\u2503"},singleDouble:{topLeft:"\u2553",top:"\u2500",topRight:"\u2556",right:"\u2551",bottomRight:"\u255C",bottom:"\u2500",bottomLeft:"\u2559",left:"\u2551"},doubleSingle:{topLeft:"\u2552",top:"\u2550",topRight:"\u2555",right:"\u2502",bottomRight:"\u255B",bottom:"\u2550",bottomLeft:"\u2558",left:"\u2502"},classic:{topLeft:"+",top:"-",topRight:"+",right:"|",bottomRight:"+",bottom:"-",bottomLeft:"+",left:"|"},arrow:{topLeft:"\u2198",top:"\u2193",topRight:"\u2199",right:"\u2190",bottomRight:"\u2196",bottom:"\u2191",bottomLeft:"\u2197",left:"\u2192"}}});var st=g((oF,su)=>{"use strict";i();var oD=nD();su.exports=oD;su.exports.default=oD});var sD=g((sF,iD)=>{"use strict";i();var at=/[|\\{}()[\]^$+*?.-]/g;iD.exports=u=>{if(typeof u!="string")throw new TypeError("Expected a string");return u.replace(at,"\\$&")}});var dt=g((CF,ED)=>{"use strict";i();var Ct=sD(),Et=typeof process=="object"&&process&&typeof process.cwd=="function"?process.cwd():".",CD=[].concat(fD("module").builtinModules,"bootstrap_node","node").map(u=>new RegExp(`(?:\\((?:node:)?${u}(?:\\.js)?:\\d+:\\d+\\)$|^\\s*at (?:node:)?${u}(?:\\.js)?:\\d+:\\d+$)`));CD.push(/\((?:node:)?internal\/[^:]+:\d+:\d+\)$/,/\s*at (?:node:)?internal\/[^:]+:\d+:\d+$/,/\/\.node-spawn-wrap-\w+-\w+\/node:\d+:\d+\)?$/);var au=class u{constructor(D){D={ignoredPackages:[],...D},"internals"in D||(D.internals=u.nodeInternals()),"cwd"in D||(D.cwd=Et),this._cwd=D.cwd.replace(/\\/g,"/"),this._internals=[].concat(D.internals,ct(D.ignoredPackages)),this._wrapCallSite=D.wrapCallSite||!1}static nodeInternals(){return[...CD]}clean(D,e=0){e=" ".repeat(e),Array.isArray(D)||(D=D.split(`
2
+ `)),!/^\s*at /.test(D[0])&&/^\s*at /.test(D[1])&&(D=D.slice(1));let t=!1,r=null,F=[];return D.forEach(o=>{if(o=o.replace(/\\/g,"/"),this._internals.some(s=>s.test(o)))return;let n=/^\s*at /.test(o);t?o=o.trimEnd().replace(/^(\s+)at /,"$1"):(o=o.trim(),n&&(o=o.slice(3))),o=o.replace(`${this._cwd}/`,""),o&&(n?(r&&(F.push(r),r=null),F.push(o)):(t=!0,r=o))}),F.map(o=>`${e}${o}
3
+ `).join("")}captureString(D,e=this.captureString){typeof D=="function"&&(e=D,D=1/0);let{stackTraceLimit:t}=Error;D&&(Error.stackTraceLimit=D);let r={};Error.captureStackTrace(r,e);let{stack:F}=r;return Error.stackTraceLimit=t,this.clean(F)}capture(D,e=this.capture){typeof D=="function"&&(e=D,D=1/0);let{prepareStackTrace:t,stackTraceLimit:r}=Error;Error.prepareStackTrace=(n,s)=>this._wrapCallSite?s.map(this._wrapCallSite):s,D&&(Error.stackTraceLimit=D);let F={};Error.captureStackTrace(F,e);let{stack:o}=F;return Object.assign(Error,{prepareStackTrace:t,stackTraceLimit:r}),o}at(D=this.at){let[e]=this.capture(1,D);if(!e)return{};let t={line:e.getLineNumber(),column:e.getColumnNumber()};aD(t,e.getFileName(),this._cwd),e.isConstructor()&&Object.defineProperty(t,"constructor",{value:!0,configurable:!0}),e.isEval()&&(t.evalOrigin=e.getEvalOrigin()),e.isNative()&&(t.native=!0);let r;try{r=e.getTypeName()}catch{}r&&r!=="Object"&&r!=="[object Object]"&&(t.type=r);let F=e.getFunctionName();F&&(t.function=F);let o=e.getMethodName();return o&&F!==o&&(t.method=o),t}parseLine(D){let e=D&&D.match(lt);if(!e)return null;let t=e[1]==="new",r=e[2],F=e[3],o=e[4],n=Number(e[5]),s=Number(e[6]),C=e[7],b=e[8],c=e[9],p=e[10]==="native",l=e[11]===")",B,f={};if(b&&(f.line=Number(b)),c&&(f.column=Number(c)),l&&C){let m=0;for(let h=C.length-1;h>0;h--)if(C.charAt(h)===")")m++;else if(C.charAt(h)==="("&&C.charAt(h-1)===" "&&(m--,m===-1&&C.charAt(h-1)===" ")){let k=C.slice(0,h-1);C=C.slice(h+1),r+=` (${k}`;break}}if(r){let m=r.match(ft);m&&(r=m[1],B=m[2])}return aD(f,C,this._cwd),t&&Object.defineProperty(f,"constructor",{value:!0,configurable:!0}),F&&(f.evalOrigin=F,f.evalLine=n,f.evalColumn=s,f.evalFile=o&&o.replace(/\\/g,"/")),p&&(f.native=!0),r&&(f.function=r),B&&r!==B&&(f.method=B),f}};function aD(u,D,e){D&&(D=D.replace(/\\/g,"/"),D.startsWith(`${e}/`)&&(D=D.slice(e.length+1)),u.file=D)}function ct(u){if(u.length===0)return[];let D=u.map(e=>Ct(e));return new RegExp(`[/\\\\]node_modules[/\\\\](?:${D.join("|")})[/\\\\][^:]+:\\d+:\\d+`)}var lt=new RegExp("^(?:\\s*at )?(?:(new) )?(?:(.*?) \\()?(?:eval at ([^ ]+) \\((.+?):(\\d+):(\\d+)\\), )?(?:(.+?):(\\d+):(\\d+)|(native))(\\)?)$"),ft=/^(.*?) \[as (.*?)\]$/;ED.exports=au});i();i();i();i();var j=[161,161,164,164,167,168,170,170,173,174,176,180,182,186,188,191,198,198,208,208,215,216,222,225,230,230,232,234,236,237,240,240,242,243,247,250,252,252,254,254,257,257,273,273,275,275,283,283,294,295,299,299,305,307,312,312,319,322,324,324,328,331,333,333,338,339,358,359,363,363,462,462,464,464,466,466,468,468,470,470,472,472,474,474,476,476,593,593,609,609,708,708,711,711,713,715,717,717,720,720,728,731,733,733,735,735,768,879,913,929,931,937,945,961,963,969,1025,1025,1040,1103,1105,1105,8208,8208,8211,8214,8216,8217,8220,8221,8224,8226,8228,8231,8240,8240,8242,8243,8245,8245,8251,8251,8254,8254,8308,8308,8319,8319,8321,8324,8364,8364,8451,8451,8453,8453,8457,8457,8467,8467,8470,8470,8481,8482,8486,8486,8491,8491,8531,8532,8539,8542,8544,8555,8560,8569,8585,8585,8592,8601,8632,8633,8658,8658,8660,8660,8679,8679,8704,8704,8706,8707,8711,8712,8715,8715,8719,8719,8721,8721,8725,8725,8730,8730,8733,8736,8739,8739,8741,8741,8743,8748,8750,8750,8756,8759,8764,8765,8776,8776,8780,8780,8786,8786,8800,8801,8804,8807,8810,8811,8814,8815,8834,8835,8838,8839,8853,8853,8857,8857,8869,8869,8895,8895,8978,8978,9312,9449,9451,9547,9552,9587,9600,9615,9618,9621,9632,9633,9635,9641,9650,9651,9654,9655,9660,9661,9664,9665,9670,9672,9675,9675,9678,9681,9698,9701,9711,9711,9733,9734,9737,9737,9742,9743,9756,9756,9758,9758,9792,9792,9794,9794,9824,9825,9827,9829,9831,9834,9836,9837,9839,9839,9886,9887,9919,9919,9926,9933,9935,9939,9941,9953,9955,9955,9960,9961,9963,9969,9972,9972,9974,9977,9979,9980,9982,9983,10045,10045,10102,10111,11094,11097,12872,12879,57344,63743,65024,65039,65533,65533,127232,127242,127248,127277,127280,127337,127344,127373,127375,127376,127387,127404,917760,917999,983040,1048573,1048576,1114109],P=[12288,12288,65281,65376,65504,65510],Q=[8361,8361,65377,65470,65474,65479,65482,65487,65490,65495,65498,65500,65512,65518],Z=[32,126,162,163,165,166,172,172,175,175,10214,10221,10629,10630],W=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141];i();var G=(u,D)=>{let e=0,t=Math.floor(u.length/2)-1;for(;e<=t;){let r=Math.floor((e+t)/2),F=r*2;if(D<u[F])t=r-1;else if(D>u[F+1])e=r+1;else return!0}return!1};var gD=j[0],mD=j.at(-1),AD=P[0],bD=P.at(-1),Tt=Q[0],yt=Q.at(-1),vt=Z[0],St=Z.at(-1),xD=W[0],wD=W.at(-1),cu=19968,[TD,yD]=vD(W);function vD(u){let D=u[0],e=u[1];for(let t=0;t<u.length;t+=2){let r=u[t],F=u[t+1];if(cu>=r&&cu<=F)return[r,F];F-r>e-D&&(D=r,e=F)}return[D,e]}var lu=u=>u<gD||u>mD?!1:G(j,u),L=u=>u<AD||u>bD?!1:G(P,u);var _=u=>u>=TD&&u<=yD?!0:u<xD||u>wD?!1:G(W,u);function SD(u){if(!Number.isSafeInteger(u))throw new TypeError(`Expected a code point, got \`${typeof u}\`.`)}function fu(u,{ambiguousAsWide:D=!1}={}){return SD(u),L(u)||_(u)||D&&lu(u)?2:1}var Bu=J(pu(),1),$D=new Intl.Segmenter,ND=/^\p{Default_Ignorable_Code_Point}$/u;function w(u,D={}){if(typeof u!="string"||u.length===0)return 0;let{ambiguousIsNarrow:e=!0,countAnsiEscapeCodes:t=!1}=D;if(t||(u=M(u)),u.length===0)return 0;let r=0,F={ambiguousAsWide:!e};for(let{segment:o}of $D.segment(u)){let n=o.codePointAt(0);if(!(n<=31||n>=127&&n<=159)&&!(n>=8203&&n<=8207||n===65279)&&!(n>=768&&n<=879||n>=6832&&n<=6911||n>=7616&&n<=7679||n>=8400&&n<=8447||n>=65056&&n<=65071)&&!(n>=55296&&n<=57343)&&!(n>=65024&&n<=65039)&&!ND.test(o)){if((0,Bu.default)().test(o)){r+=2;continue}r+=fu(n,F)}}return r}i();i();var hu=(u=0)=>D=>`\x1B[${D+u}m`,gu=(u=0)=>D=>`\x1B[${38+u};5;${D}m`,mu=(u=0)=>(D,e,t)=>`\x1B[${38+u};2;${D};${e};${t}m`,E={modifier:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],overline:[53,55],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},color:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],blackBright:[90,39],gray:[90,39],grey:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39]},bgColor:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],bgBlackBright:[100,49],bgGray:[100,49],bgGrey:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]}},qt=Object.keys(E.modifier),RD=Object.keys(E.color),WD=Object.keys(E.bgColor),Ht=[...RD,...WD];function LD(){let u=new Map;for(let[D,e]of Object.entries(E)){for(let[t,r]of Object.entries(e))E[t]={open:`\x1B[${r[0]}m`,close:`\x1B[${r[1]}m`},e[t]=E[t],u.set(r[0],r[1]);Object.defineProperty(E,D,{value:e,enumerable:!1})}return Object.defineProperty(E,"codes",{value:u,enumerable:!1}),E.color.close="\x1B[39m",E.bgColor.close="\x1B[49m",E.color.ansi=hu(),E.color.ansi256=gu(),E.color.ansi16m=mu(),E.bgColor.ansi=hu(10),E.bgColor.ansi256=gu(10),E.bgColor.ansi16m=mu(10),Object.defineProperties(E,{rgbToAnsi256:{value(D,e,t){return D===e&&e===t?D<8?16:D>248?231:Math.round((D-8)/247*24)+232:16+36*Math.round(D/255*5)+6*Math.round(e/255*5)+Math.round(t/255*5)},enumerable:!1},hexToRgb:{value(D){let e=/[a-f\d]{6}|[a-f\d]{3}/i.exec(D.toString(16));if(!e)return[0,0,0];let[t]=e;t.length===3&&(t=[...t].map(F=>F+F).join(""));let r=Number.parseInt(t,16);return[r>>16&255,r>>8&255,r&255]},enumerable:!1},hexToAnsi256:{value:D=>E.rgbToAnsi256(...E.hexToRgb(D)),enumerable:!1},ansi256ToAnsi:{value(D){if(D<8)return 30+D;if(D<16)return 90+(D-8);let e,t,r;if(D>=232)e=((D-232)*10+8)/255,t=e,r=e;else{D-=16;let n=D%36;e=Math.floor(D/36)/5,t=Math.floor(n/6)/5,r=n%6/5}let F=Math.max(e,t,r)*2;if(F===0)return 30;let o=30+(Math.round(r)<<2|Math.round(t)<<1|Math.round(e));return F===2&&(o+=60),o},enumerable:!1},rgbToAnsi:{value:(D,e,t)=>E.ansi256ToAnsi(E.rgbToAnsi256(D,e,t)),enumerable:!1},hexToAnsi:{value:D=>E.ansi256ToAnsi(E.hexToAnsi256(D)),enumerable:!1}}),E}var _D=LD(),A=_D;var H=new Set(["\x1B","\x9B"]),OD=39,Du="\x07",xu="[",ID="]",wu="m",q=`${ID}8;;`,Au=u=>`${H.values().next().value}${xu}${u}${wu}`,bu=u=>`${H.values().next().value}${q}${u}${Du}`,kD=u=>u.split(" ").map(D=>w(D)),uu=(u,D,e)=>{let t=[...D],r=!1,F=!1,o=w(M(u.at(-1)));for(let[n,s]of t.entries()){let C=w(s);if(o+C<=e?u[u.length-1]+=s:(u.push(s),o=0),H.has(s)&&(r=!0,F=t.slice(n+1,n+1+q.length).join("")===q),r){F?s===Du&&(r=!1,F=!1):s===wu&&(r=!1);continue}o+=C,o===e&&n<t.length-1&&(u.push(""),o=0)}!o&&u.at(-1).length>0&&u.length>1&&(u[u.length-2]+=u.pop())},MD=u=>{let D=u.split(" "),e=D.length;for(;e>0&&!(w(D[e-1])>0);)e--;return e===D.length?u:D.slice(0,e).join(" ")+D.slice(e).join("")},jD=(u,D,e={})=>{if(e.trim!==!1&&u.trim()==="")return"";let t="",r,F,o=kD(u),n=[""];for(let[c,p]of u.split(" ").entries()){e.trim!==!1&&(n[n.length-1]=n.at(-1).trimStart());let l=w(n.at(-1));if(c!==0&&(l>=D&&(e.wordWrap===!1||e.trim===!1)&&(n.push(""),l=0),(l>0||e.trim===!1)&&(n[n.length-1]+=" ",l++)),e.hard&&o[c]>D){let B=D-l,f=1+Math.floor((o[c]-B-1)/D);Math.floor((o[c]-1)/D)<f&&n.push(""),uu(n,p,D);continue}if(l+o[c]>D&&l>0&&o[c]>0){if(e.wordWrap===!1&&l<D){uu(n,p,D);continue}n.push("")}if(l+o[c]>D&&e.wordWrap===!1){uu(n,p,D);continue}n[n.length-1]+=p}e.trim!==!1&&(n=n.map(c=>MD(c)));let s=n.join(`
4
+ `),C=[...s],b=0;for(let[c,p]of C.entries()){if(t+=p,H.has(p)){let{groups:B}=new RegExp(`(?:\\${xu}(?<code>\\d+)m|\\${q}(?<uri>.*)${Du})`).exec(s.slice(b))||{groups:{}};if(B.code!==void 0){let f=Number.parseFloat(B.code);r=f===OD?void 0:f}else B.uri!==void 0&&(F=B.uri.length===0?void 0:B.uri)}let l=A.codes.get(Number(r));C[c+1]===`
5
+ `?(F&&(t+=bu("")),r&&l&&(t+=Au(l))):p===`
6
+ `&&(r&&l&&(t+=Au(r)),F&&(t+=bu(F))),b+=p.length}return t};function PD(u,D,e){return String(u).normalize().replaceAll(`\r
7
+ `,`
8
+ `).split(`
9
+ `).map(t=>jD(t,D,e)).join(`
10
+ `)}var zu={};dD(zu,{ConEmu:()=>Ku,beep:()=>Pe,beginSynchronizedOutput:()=>Hu,clearScreen:()=>Le,clearTerminal:()=>Ie,clearViewport:()=>_e,cursorBackward:()=>he,cursorDown:()=>pe,cursorForward:()=>Be,cursorGetPosition:()=>Ae,cursorHide:()=>we,cursorLeft:()=>Gu,cursorMove:()=>de,cursorNextLine:()=>be,cursorPrevLine:()=>xe,cursorRestorePosition:()=>me,cursorSavePosition:()=>ge,cursorShow:()=>Te,cursorTo:()=>fe,cursorUp:()=>Pu,endSynchronizedOutput:()=>Vu,enterAlternativeScreen:()=>ke,eraseDown:()=>$e,eraseEndLine:()=>ve,eraseLine:()=>qu,eraseLines:()=>ye,eraseScreen:()=>V,eraseStartLine:()=>Se,eraseUp:()=>Ne,exitAlternativeScreen:()=>Me,iTerm:()=>Uu,image:()=>qe,link:()=>Ge,scrollDown:()=>We,scrollUp:()=>Re,setCwd:()=>He,synchronizedOutput:()=>je});i();import v from"node:process";import Ee from"node:os";i();var y=globalThis.window?.document!==void 0,ar=globalThis.process?.versions?.node!==void 0,Cr=globalThis.process?.versions?.bun!==void 0,Er=globalThis.Deno?.version?.deno!==void 0,cr=globalThis.process?.versions?.electron!==void 0,lr=globalThis.navigator?.userAgent?.includes("jsdom")===!0,fr=typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope,dr=typeof DedicatedWorkerGlobalScope<"u"&&globalThis instanceof DedicatedWorkerGlobalScope,pr=typeof SharedWorkerGlobalScope<"u"&&globalThis instanceof SharedWorkerGlobalScope,Br=typeof ServiceWorkerGlobalScope<"u"&&globalThis instanceof ServiceWorkerGlobalScope,O=globalThis.navigator?.userAgentData?.platform,hr=O==="macOS"||globalThis.navigator?.platform==="MacIntel"||globalThis.navigator?.userAgent?.includes(" Mac ")===!0||globalThis.process?.platform==="darwin",gr=O==="Windows"||globalThis.navigator?.platform==="Win32"||globalThis.process?.platform==="win32",mr=O==="Linux"||globalThis.navigator?.platform?.startsWith("Linux")===!0||globalThis.navigator?.userAgent?.includes(" Linux ")===!0||globalThis.process?.platform==="linux",Ar=O==="iOS"||globalThis.navigator?.platform==="MacIntel"&&globalThis.navigator?.maxTouchPoints>1||/iPad|iPhone|iPod/.test(globalThis.navigator?.platform),br=O==="Android"||globalThis.navigator?.platform==="Android"||globalThis.navigator?.userAgent?.includes(" Android ")===!0||globalThis.process?.platform==="android";var a="\x1B[",S="\x1B]",T="\x07",I=";",ju=!y&&v.env.TERM_PROGRAM==="Apple_Terminal",ce=!y&&v.platform==="win32",le=!y&&(v.env.TERM?.startsWith("screen")||v.env.TERM?.startsWith("tmux")||v.env.TMUX!==void 0),tu=y?()=>{throw new Error("`process.cwd()` only works in Node.js, not the browser.")}:v.cwd,$=u=>le?"\x1BPtmux;"+u.replaceAll("\x1B","\x1B\x1B")+"\x1B\\":u,fe=(u,D)=>{if(typeof u!="number")throw new TypeError("The `x` argument is required");return typeof D!="number"?a+(u+1)+"G":a+(D+1)+I+(u+1)+"H"},de=(u,D)=>{if(typeof u!="number")throw new TypeError("The `x` argument is required");let e="";return u<0?e+=a+-u+"D":u>0&&(e+=a+u+"C"),D<0?e+=a+-D+"A":D>0&&(e+=a+D+"B"),e},Pu=(u=1)=>a+u+"A",pe=(u=1)=>a+u+"B",Be=(u=1)=>a+u+"C",he=(u=1)=>a+u+"D",Gu=a+"G",ge=ju?"\x1B7":a+"s",me=ju?"\x1B8":a+"u",Ae=a+"6n",be=a+"E",xe=a+"F",we=a+"?25l",Te=a+"?25h",ye=u=>{let D="";for(let e=0;e<u;e++)D+=qu+(e<u-1?Pu():"");return u&&(D+=Gu),D},ve=a+"K",Se=a+"1K",qu=a+"2K",$e=a+"J",Ne=a+"1J",V=a+"2J",Re=a+"S",We=a+"T",Le="\x1Bc",_e=`${V}${a}H`,Oe=()=>{if(y||!ce)return!1;let u=Ee.release().split("."),D=Number(u[0]),e=Number(u[2]??0);return D<10||D===10&&e<10586},Ie=Oe()?`${V}${a}0f`:`${V}${a}3J${a}H`,ke=a+"?1049h",Me=a+"?1049l",Hu=a+"?2026h",Vu=a+"?2026l",je=u=>Hu+u+Vu,Pe=T,Ge=(u,D)=>{let e=$(`${S}8${I}${I}${D}${T}`),t=$(`${S}8${I}${I}${T}`);return e+u+t},qe=(u,D={})=>{let e=`${S}1337;File=inline=1`;D.width&&(e+=`;width=${D.width}`),D.height&&(e+=`;height=${D.height}`),D.preserveAspectRatio===!1&&(e+=";preserveAspectRatio=0");let t=Buffer.from(u);return $(e+`;size=${t.byteLength}:`+t.toString("base64")+T)},Uu={setCwd:(u=tu())=>$(`${S}50;CurrentDir=${u}${T}`),annotation(u,D={}){let e=`${S}1337;`,t=D.x!==void 0,r=D.y!==void 0;if((t||r)&&!(t&&r&&D.length!==void 0))throw new Error("`x`, `y` and `length` must be defined when `x` or `y` is defined");return u=u.replaceAll("|",""),e+=D.isHidden?"AddHiddenAnnotation=":"AddAnnotation=",D.length>0?e+=(t?[u,D.length,D.x,D.y]:[D.length,u]).join("|"):e+=u,$(e+T)}},Ku={setCwd:(u=tu())=>$(`${S}9;9;${u}${T}`)},He=(u=tu())=>Uu.setCwd(u)+Ku.setCwd(u);i();i();var Ve=u=>{let D=new Set;do for(let e of Reflect.ownKeys(u))D.add([u,e]);while((u=Reflect.getPrototypeOf(u))&&u!==Object.prototype);return D};function Ue(u,{include:D,exclude:e}={}){let t=r=>{let F=o=>typeof o=="string"?r===o:o.test(r);return D?D.some(F):e?!e.some(F):!0};for(let[r,F]of Ve(u.constructor.prototype)){if(F==="constructor"||!t(F))continue;let o=Reflect.getOwnPropertyDescriptor(r,F);o&&typeof o.value=="function"&&(u[F]=u[F].bind(u))}return u}i();import{PassThrough as Yu}from"node:stream";var Ju=["assert","count","countReset","debug","dir","dirxml","error","group","groupCollapsed","groupEnd","info","log","table","time","timeEnd","timeLog","trace","warn"],ru={},Ke=u=>{let D=new Yu,e=new Yu;D.write=r=>{u("stdout",r)},e.write=r=>{u("stderr",r)};let t=new console.Console(D,e);for(let r of Ju)ru[r]=console[r],console[r]=t[r];return()=>{for(let r of Ju)console[r]=ru[r];ru={}}},Or=Ke;i();import rD from"node:process";i();var DD=J(uD(),1),eD=J(hD(),1);import Ye from"node:process";var Je=(0,DD.default)(()=>{(0,eD.default)(()=>{Ye.stderr.write("\x1B[?25h")},{alwaysLast:!0})}),tD=Je;var z=!1,N={};N.show=(u=rD.stderr)=>{u.isTTY&&(z=!1,u.write("\x1B[?25h"))};N.hide=(u=rD.stderr)=>{u.isTTY&&(tD(),z=!0,u.write("\x1B[?25l"))};N.toggle=(u,D)=>{u!==void 0&&(z=u),z?N.show(D):N.hide(D)};var zr=N;i();function Xe(u,D=1,e={}){let{indent:t=" ",includeEmptyLines:r=!1}=e;if(typeof u!="string")throw new TypeError(`Expected \`input\` to be a \`string\`, got \`${typeof u}\``);if(typeof D!="number")throw new TypeError(`Expected \`count\` to be a \`number\`, got \`${typeof D}\``);if(D<0)throw new RangeError(`Expected \`count\` to be at least 0, got \`${D}\``);if(typeof t!="string")throw new TypeError(`Expected \`options.indent\` to be a \`string\`, got \`${typeof t}\``);if(D===0)return u;let F=r?/^/gm:/^(?!\s*$)/gm;return u.replace(F,t.repeat(D))}i();function nu(u){return Number.isInteger(u)?L(u)||_(u):!1}i();var Qe=new Set([27,155]),Ze="0".codePointAt(0),ut="9".codePointAt(0),Dt=19,iu=new Set,ou=new Map;for(let[u,D]of A.codes)iu.add(A.color.ansi(D)),ou.set(A.color.ansi(u),A.color.ansi(D));function et(u){if(iu.has(u))return u;if(ou.has(u))return ou.get(u);u=u.slice(2),u.includes(";")&&(u=u[0]+"0");let D=A.codes.get(Number.parseInt(u,10));return D?A.color.ansi(D):A.reset.open}function tt(u){for(let D=0;D<u.length;D++){let e=u.codePointAt(D);if(e>=Ze&&e<=ut)return D}return-1}function rt(u,D){u=u.slice(D,D+Dt);let e=tt(u);if(e!==-1){let t=u.indexOf("m",e);return t===-1&&(t=u.length),u.slice(0,t+1)}}function Ft(u,D=Number.POSITIVE_INFINITY){let e=[],t=0,r=0;for(;t<u.length;){let F=u.codePointAt(t);if(Qe.has(F)){let s=rt(u,t);if(s){e.push({type:"ansi",code:s,endCode:et(s)}),t+=s.length;continue}}let o=nu(F),n=String.fromCodePoint(F);if(e.push({type:"character",value:n,isFullWidth:o}),t+=n.length,r+=o?2:n.length,r>=D)break}return e}function FD(u){let D=[];for(let e of u)e.code===A.reset.open?D=[]:iu.has(e.code)?D=D.filter(t=>t.endCode!==e.code):(D=D.filter(t=>t.endCode!==e.endCode),D.push(e));return D}function nt(u){return FD(u).map(({endCode:t})=>t).reverse().join("")}function ot(u,D,e){let t=Ft(u,e),r=[],F=0,o="",n=!1;for(let s of t){if(e!==void 0&&F>=e)break;s.type==="ansi"?(r.push(s),n&&(o+=s.code)):(!n&&F>=D&&(n=!0,r=FD(r),o=r.map(({code:C})=>C).join("")),n&&(o+=s.value),F+=s.isFullWidth?2:s.value.length)}return o+=nt(r),o}i();i();var pt=(u,D=2)=>u.replace(/^\t+/gm,e=>" ".repeat(e.length*D)),cD=pt;var Bt=(u,D)=>{let e=[],t=u-D,r=u+D;for(let F=t;F<=r;F++)e.push(F);return e},ht=(u,D,e={})=>{var t;if(typeof u!="string")throw new TypeError("Source code is missing.");if(!D||D<1)throw new TypeError("Line number must start from `1`.");let r=cD(u).split(/\r?\n/);if(!(D>r.length))return Bt(D,(t=e.around)!==null&&t!==void 0?t:3).filter(F=>r[F-1]!==void 0).map(F=>({line:F,value:r[F-1]}))},dF=ht;export{zu as a,Ue as b,Or as c,fu as d,w as e,A as f,PD as g,nu as h,ot as i,Xe as j,st as k,zr as l,dt as m,dF as n,ku as o,Ce as p};
@@ -1 +1 @@
1
- import{a as n}from"./chunk-7VAKNVFD.js";import{b as r}from"./chunk-UWI76E2L.js";import{g as t}from"./chunk-VKWPEFWQ.js";t();var e=r.object({title:r.string().optional(),body:r.union([r.string(),r.array(r.array(r.string()))])}).strict(),o={message:r.string(),code:r.string().min(1).optional().describe("A stable error code, included only when known."),tryMessage:r.string().optional(),nextSteps:r.array(r.string()).optional(),customSections:r.array(e).optional(),details:r.unknown().optional().describe("Selected domain details, preserving native API payloads such as GraphQL errors, extensions, and data.")},s=r.object({type:r.literal("abort"),...o}).strict(),a=r.object({type:r.literal("bug"),...o,stack:r.string().optional()}).strict(),i=r.object({type:r.literal("external"),...o,command:r.string(),args:r.array(r.string())}).strict(),c=r.union([s,a,i]),m=r.object({error:c}).strict(),d=n({name:"JsonErrorDocument",schema:m,definitions:{JsonError:c,JsonErrorCustomSection:e,JsonAbortError:s,JsonBugError:a,JsonExternalError:i}});export{d as a};
1
+ import{a as n}from"./chunk-BN7ZXAZJ.js";import{b as r}from"./chunk-FZCGRIOM.js";import{g as t}from"./chunk-VKWPEFWQ.js";t();var e=r.object({title:r.string().optional(),body:r.union([r.string(),r.array(r.array(r.string()))])}).strict(),o={message:r.string(),code:r.string().min(1).optional().describe("A stable error code, included only when known."),tryMessage:r.string().optional(),nextSteps:r.array(r.string()).optional(),customSections:r.array(e).optional(),details:r.unknown().optional().describe("Selected domain details, preserving native API payloads such as GraphQL errors, extensions, and data.")},s=r.object({type:r.literal("abort"),...o}).strict(),a=r.object({type:r.literal("bug"),...o,stack:r.string().optional()}).strict(),i=r.object({type:r.literal("external"),...o,command:r.string(),args:r.array(r.string())}).strict(),c=r.union([s,a,i]),m=r.object({error:c}).strict(),d=n({name:"JsonErrorDocument",schema:m,definitions:{JsonError:c,JsonErrorCustomSection:e,JsonAbortError:s,JsonBugError:a,JsonExternalError:i}});export{s as a,c as b,d as c};
@@ -0,0 +1 @@
1
+ import{A as u,c as a,f as q,g as A,ha as g,ia as v,n as l}from"./chunk-H4V55Y3Z.js";import{b as m}from"./chunk-ZT5WFUKJ.js";import{h as n,k as F}from"./chunk-2VSNFOKD.js";import{qb as b,sb as f}from"./chunk-LWCTKI4Z.js";import{i as k}from"./chunk-ZDQO6CNY.js";import{g as p}from"./chunk-VKWPEFWQ.js";p();p();var $={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"publicApiVersions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"publicApiVersions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"handle"}},{kind:"Field",name:{kind:"Name",value:"supported"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};var S=new Map;async function Y(t,r,e,o){let d="Admin",h=o??await T(r),s=r.storeFqdn,i=V(r);m()==="local"&&(i["x-forwarded-host"]=s,s=new l().host("app"));let c=D(s,h,r);return g({query:t,api:d,addedHeaders:i,url:c,token:r.token,variables:e})}async function x(t){let{query:r,session:e,variables:o,version:d,responseOptions:h,preferredBehaviour:s}=t,i=d??S.get(e.storeFqdn);i??=await T(e,s);let c=e.storeFqdn,w=V(e);m()==="local"&&(w["x-forwarded-host"]=c,c=new l().host("app"));let E={url:D(c,i,e),api:"Admin",token:e.token,addedHeaders:w},y;return"refresh"in e&&(y={type:"token_refresh",handler:e.refresh}),v({...E,query:r,variables:o,responseOptions:h,unauthorizedHandler:y,preferredBehaviour:s})}function V(t){return u(t)?{"X-Shopify-Shop":t.storeFqdn,"X-Shopify-Access-Token":t.token}:{}}async function T(t,r){let o=(await N(t,r)).reverse()[0];return S.set(t.storeFqdn,o),o}async function N(t,r){return(await R(t,r)).filter(o=>o.supported).map(o=>o.handle).sort()}async function R(t,r){try{return(await x({query:$,session:t,variables:{},version:"unstable",responseOptions:{handleErrors:!1},preferredBehaviour:r})).publicApiVersions}catch(e){if(e instanceof a&&e.response.status===403){let o=t.storeFqdn.replace(".myshopify.com","");throw new n(f`Looks like you don't have access to this dev store: (${b.link(o,`https://${t.storeFqdn}`)})`,f`If you're not the owner, create a dev store staff account for yourself`)}throw e instanceof a&&e.response.status===401&&u(t)?new n(`The Theme Access password was rejected for the store ${t.storeFqdn}.`,"Theme Access passwords only work on the store they were generated for, and only with its permanent .myshopify.com domain.",["Check that the password was created in the Theme Access app on this store and has not been deleted.",["Pass the permanent domain to",{command:"--store"},{char:"."},"It is the .myshopify.com domain listed in the Shopify admin under",{subdued:"Settings > Domains"},{char:"."}]]):e instanceof a&&(e.response.status===401||e.response.status===404)?new n(`Error connecting to your store ${t.storeFqdn}: ${e.message} ${e.response.status} ${e.response.data}`):e instanceof a&&e.response.status===402?new n(`The store ${t.storeFqdn} is currently unavailable.`,"This usually means the store is frozen, paused, or closed. Check the store in the Shopify admin and try again once it is reactivated."):e instanceof a&&e.response.status>=500?new n(`The Admin API for ${t.storeFqdn} returned a server error (HTTP ${e.response.status}).`,"This is a problem on the Shopify side, not with your command. Wait a moment and try again."):A(e)?new n(`Request to ${t.storeFqdn} was aborted before it completed.`,"The request was cancelled or timed out before the store responded. Try running the command again."):q(e)?new n(`Network error connecting to your store ${t.storeFqdn}: ${e instanceof Error?e.message:String(e)}`,"Check your internet connection and try again."):new F(`Unknown error connecting to your store ${t.storeFqdn}: ${e instanceof Error?e.message:String(e)}`)}}function D(t,r,e){let o=r??"unstable";return e&&u(e)?`https://${k}/cli/admin/api/${o}/graphql.json`:`https://${t}/admin/api/${o}/graphql.json`}export{Y as a,x as b,N as c,R as d,D as e};
@@ -1 +1 @@
1
- import{b as E}from"./chunk-NU5WLZ6Y.js";import{b}from"./chunk-4ZNBEMRT.js";import{Q as F,R as N}from"./chunk-47IQIIFX.js";import{Kb as k,W as C,Xa as w,qa as O}from"./chunk-UWI76E2L.js";import{i as n}from"./chunk-B4OMIONW.js";import{k as R}from"./chunk-UEBUGSBT.js";import{b as U}from"./chunk-I3J63RFV.js";import{c as u,e as P,f as x,g,m as T,p as y}from"./chunk-6IDEDOXW.js";import{e as H,g as d}from"./chunk-VKWPEFWQ.js";d();d();d();d();var m=class{static description="Doctor test suite";context;assertions=[];registeredTests=[];async runSuite(t){this.context=t,this.registeredTests=[];let e=[];this.tests();for(let o of this.registeredTests){this.assertions=[];let s=Date.now();try{await o.fn(),e.push({name:o.name,status:this.hasFailures()?"failed":"passed",duration:Date.now()-s,assertions:[...this.assertions]})}catch(r){e.push({name:o.name,status:"failed",duration:Date.now()-s,assertions:[...this.assertions],error:r instanceof Error?r:new Error(String(r))})}}return e}test(t,e){this.registeredTests.push({name:t,fn:e})}tests(){}async run(t,e){let o=e?.cwd??this.context.workingDirectory,s=await F(t,{cwd:o,env:e?.env});return{command:t,exitCode:s.exitCode,stdout:s.stdout,stderr:s.stderr,output:String(s.stdout)+String(s.stderr),success:s.exitCode===0}}async runInteractive(t,e){let o=e?.cwd??this.context.workingDirectory,s=0;try{await N(t,{cwd:o,env:e?.env,stdin:"inherit"})}catch{s=1}return{command:t,exitCode:s,stdout:"",stderr:"",output:"",success:s===0}}assertSuccess(t,e){this.assertions.push({description:e??`Command succeeded: ${t.command}`,passed:t.success,expected:"exit code 0",actual:`exit code ${t.exitCode}`})}assertError(t,e,o){let s=!t.success;if(e){let h=(typeof e=="string"?new RegExp(e):e).test(t.output),c;s?h?c="matched":c=`output: ${t.output.slice(0,200)}`:c="command succeeded",this.assertions.push({description:o??`Command failed with expected error: ${e}`,passed:s&&h,expected:`failure with error matching ${e}`,actual:c})}else this.assertions.push({description:o??`Command failed: ${t.command}`,passed:s,expected:"non-zero exit code",actual:`exit code ${t.exitCode}`})}async assertFile(t,e,o){let s=g(t)?t:u(this.context.workingDirectory,t),r=x(this.context.workingDirectory,s);if(!await w(s)){this.assertions.push({description:o??`File exists: ${r}`,passed:!1,expected:"file exists",actual:"file not found"});return}if(e){let c=await O(s),D=(typeof e=="string"?new RegExp(e):e).test(c);this.assertions.push({description:o??`File ${r} matches ${e}`,passed:D,expected:`content matching ${e}`,actual:D?"matched":`content: ${c.slice(0,200)}...`})}else this.assertions.push({description:o??`File exists: ${r}`,passed:!0,expected:"file exists",actual:"file exists"})}async assertNoFile(t,e){let o=g(t)?t:u(this.context.workingDirectory,t),s=x(this.context.workingDirectory,o),r=await w(o);this.assertions.push({description:e??`File does not exist: ${s}`,passed:!r,expected:"file does not exist",actual:r?"file exists":"file does not exist"})}async assertDirectory(t,e){let o=g(t)?t:u(this.context.workingDirectory,t),s=x(this.context.workingDirectory,o),r=await w(o);this.assertions.push({description:e??`Directory exists: ${s}`,passed:r,expected:"directory exists",actual:r?"directory exists":"directory not found"})}assertOutput(t,e,o){let r=(typeof e=="string"?new RegExp(e):e).test(t.output);this.assertions.push({description:o??`Output matches ${e}`,passed:r,expected:`output matching ${e}`,actual:r?"matched":`output: ${t.output.slice(0,200)}`})}assertJson(t,e,o){try{let s=JSON.parse(t.stdout);if(e){let r=e(s);this.assertions.push({description:o??"Output is valid JSON matching validator",passed:r,expected:"valid JSON matching validator",actual:r?"matched":"validator returned false"})}else this.assertions.push({description:o??"Output is valid JSON",passed:!0,expected:"valid JSON",actual:"valid JSON"});return s}catch{this.assertions.push({description:o??"Output is valid JSON",passed:!1,expected:"valid JSON",actual:`invalid JSON: ${t.stdout.slice(0,100)}`});return}}assert(t,e){this.assertions.push({description:e,passed:t,expected:"true",actual:String(t)})}assertEqual(t,e,o){this.assertions.push({description:o,passed:t===e,expected:String(e),actual:String(t)})}hasFailures(){return this.assertions.some(t=>!t.passed)}};var p=class extends m{static description="Tests the theme init command creates a valid theme structure";themeName="";themePath="";tests(){this.test("init creates theme directory",async()=>{this.themeName=`doctor-theme-${C("creative")}`,this.themePath=u(this.context.workingDirectory,this.themeName);let t=await this.runInteractive(`shopify theme init ${this.themeName} --path ${this.context.workingDirectory}`);this.assertSuccess(t),this.context.themeName=this.themeName,this.context.themePath=this.themePath}),this.test("essential theme files exist",async()=>{let t=["layout/theme.liquid","config/settings_schema.json","templates/index.json"];await Promise.all(t.map(e=>this.assertFile(u(this.themePath,e))))}),this.test("theme directories exist",async()=>{let t=["sections","snippets","assets","locales"];await Promise.all(t.map(e=>this.assertDirectory(u(this.themePath,e))))}),this.test("layout/theme.liquid has valid content",async()=>{await this.assertFile(u(this.themePath,"layout/theme.liquid"),/<!doctype html>|<html|{{ content_for_header }}/i,"layout/theme.liquid contains expected Liquid markup")})}};d();var l=class extends m{static description="Tests pushing a theme to the store creates an unpublished theme";static requiresStore=!0;tests(){this.test("push creates unpublished theme",async()=>{if(!this.context.themePath){this.assert(!1,"Theme init did not complete successfully; themePath is missing in context");return}let t=this.context.themeName??"doctor-theme",e=`shopify theme push --unpublished --json --path ${this.context.themePath} -t ${t}`;this.context.environment&&(e+=` -e ${this.context.environment}`),this.context.store&&(e+=` -s ${this.context.store}`),this.context.password&&(e+=` --password ${this.context.password}`);let o=await this.run(e);this.assertSuccess(o);let s=this.assertJson(o,r=>typeof r.theme?.id=="number");s?.theme&&(this.assert(typeof s.theme.id=="number","Theme was created with a valid ID"),this.assertEqual(s.theme.role,"unpublished","Theme role is unpublished"),this.assert(s.theme.editor_url.includes("/admin/themes/"),"Editor URL is provided"),this.assert(s.theme.preview_url.includes("preview_theme_id="),"Preview URL is provided"),this.context.themeId=String(s.theme.id),this.context.data.editorUrl=s.theme.editor_url,this.context.data.previewUrl=s.theme.preview_url)})}};d();function _(i){return{workingDirectory:i.path??y(),environment:i.environment,store:i.store,password:i.password,data:{}}}d();var a=i=>k(i),v;function J(i){v=i}function G(i){if(!v)return i;let t=/\/[^\s,)]+/g;return i.replace(t,e=>T(e,v))}function A(i,t){a(""),a(n.bold(n.cyan(`Suite: ${i}`))),a(n.dim(t))}function j(i){a(n.bold(n.blue(`Running: ${i}`)))}function q(i){let t=`(${(i.duration/1e3).toFixed(2)}s)`;if(i.status==="passed"){a(n.bold(n.green(`PASSED: ${i.name} ${n.dim(t)}`)));for(let e of I(i.assertions))a(e)}else if(i.status==="failed"){a(n.red(`FAILED: ${i.name} ${n.dim(t)}`));for(let e of I(i.assertions))a(e);i.error&&a(n.red(` Error: ${G(i.error.message)}`))}else a(n.yellow(`SKIPPED: ${i.name}`))}function S(i){let t=i.filter(h=>h.status==="passed").length,e=i.filter(h=>h.status==="failed").length,o=i.filter(h=>h.status==="skipped").length,s=i.length,r=i.reduce((h,c)=>h+c.duration,0);a(""),a(n.bold("\u2500".repeat(40))),e>0?a(n.red(n.bold(`Doctor Complete: ${e}/${s} tests failed`))):a(n.green(n.bold(`Doctor Complete: ${t}/${s} tests passed`))),a(` Passed: ${n.green(String(t))}`),a(` Failed: ${n.red(String(e))}`),o>0&&a(` Skipped: ${n.yellow(String(o))}`),a(` Total time: ${n.dim(`${(r/1e3).toFixed(2)}s`)}`)}function I(i){return i.map(t=>{if(t.passed)return n.green(` [OK] ${t.description}`);{let e=` (expected: ${t.expected}, actual: ${t.actual})`;return n.red(` [FAIL] ${t.description}${e}`)}})}var Y=[p,l];async function L(i){let t=[],e=_(i);J(e.workingDirectory);for(let o of Y){let s=new o,r=o.description??"Test suite";A(o.name,r);let h=await s.runSuite(e);for(let c of h)if(j(c.name),q(c),t.push(c),c.status==="failed")return S(t),t}return S(t),t}var f=H(U(),1);var $=class i extends b{static description="Run all theme command doctor-release tests";static hidden=!0;static flags={...E,path:f.Flags.string({char:"p",description:"The path to run tests in. Defaults to current directory.",env:"SHOPIFY_FLAG_PATH",parse:async t=>P(t),default:async()=>y()}),environment:f.Flags.string({char:"e",description:"The environment to use from shopify.theme.toml (required for store-connected tests).",env:"SHOPIFY_FLAG_ENVIRONMENT",required:!0}),store:f.Flags.string({char:"s",description:"Store URL (overrides environment).",env:"SHOPIFY_FLAG_STORE"}),password:f.Flags.string({description:"Password from Theme Access app (overrides environment).",env:"SHOPIFY_FLAG_PASSWORD"})};async run(){if(!R())return;let{flags:t}=await this.parse(i);(await L({path:t.path,environment:t.environment,store:t.store,password:t.password})).some(s=>s.status==="failed")&&(process.exitCode=1)}};export{$ as a};
1
+ import{b}from"./chunk-ZQDDRIBA.js";import{b as E}from"./chunk-Q2SZCZE7.js";import{R as F,S as N}from"./chunk-CZ22VZDA.js";import{S as C,Sa as w,la as O,yb as k}from"./chunk-LWCTKI4Z.js";import{i as n}from"./chunk-B4OMIONW.js";import{k as R}from"./chunk-3A3DZVEJ.js";import{b as U}from"./chunk-YTUUU33R.js";import{c as u,e as P,f as x,g,m as T,p as y}from"./chunk-IWTNUJGY.js";import{e as H,g as d}from"./chunk-VKWPEFWQ.js";d();d();d();d();var m=class{static description="Doctor test suite";context;assertions=[];registeredTests=[];async runSuite(t){this.context=t,this.registeredTests=[];let e=[];this.tests();for(let o of this.registeredTests){this.assertions=[];let s=Date.now();try{await o.fn(),e.push({name:o.name,status:this.hasFailures()?"failed":"passed",duration:Date.now()-s,assertions:[...this.assertions]})}catch(r){e.push({name:o.name,status:"failed",duration:Date.now()-s,assertions:[...this.assertions],error:r instanceof Error?r:new Error(String(r))})}}return e}test(t,e){this.registeredTests.push({name:t,fn:e})}tests(){}async run(t,e){let o=e?.cwd??this.context.workingDirectory,s=await F(t,{cwd:o,env:e?.env});return{command:t,exitCode:s.exitCode,stdout:s.stdout,stderr:s.stderr,output:String(s.stdout)+String(s.stderr),success:s.exitCode===0}}async runInteractive(t,e){let o=e?.cwd??this.context.workingDirectory,s=0;try{await N(t,{cwd:o,env:e?.env,stdin:"inherit"})}catch{s=1}return{command:t,exitCode:s,stdout:"",stderr:"",output:"",success:s===0}}assertSuccess(t,e){this.assertions.push({description:e??`Command succeeded: ${t.command}`,passed:t.success,expected:"exit code 0",actual:`exit code ${t.exitCode}`})}assertError(t,e,o){let s=!t.success;if(e){let h=(typeof e=="string"?new RegExp(e):e).test(t.output),c;s?h?c="matched":c=`output: ${t.output.slice(0,200)}`:c="command succeeded",this.assertions.push({description:o??`Command failed with expected error: ${e}`,passed:s&&h,expected:`failure with error matching ${e}`,actual:c})}else this.assertions.push({description:o??`Command failed: ${t.command}`,passed:s,expected:"non-zero exit code",actual:`exit code ${t.exitCode}`})}async assertFile(t,e,o){let s=g(t)?t:u(this.context.workingDirectory,t),r=x(this.context.workingDirectory,s);if(!await w(s)){this.assertions.push({description:o??`File exists: ${r}`,passed:!1,expected:"file exists",actual:"file not found"});return}if(e){let c=await O(s),D=(typeof e=="string"?new RegExp(e):e).test(c);this.assertions.push({description:o??`File ${r} matches ${e}`,passed:D,expected:`content matching ${e}`,actual:D?"matched":`content: ${c.slice(0,200)}...`})}else this.assertions.push({description:o??`File exists: ${r}`,passed:!0,expected:"file exists",actual:"file exists"})}async assertNoFile(t,e){let o=g(t)?t:u(this.context.workingDirectory,t),s=x(this.context.workingDirectory,o),r=await w(o);this.assertions.push({description:e??`File does not exist: ${s}`,passed:!r,expected:"file does not exist",actual:r?"file exists":"file does not exist"})}async assertDirectory(t,e){let o=g(t)?t:u(this.context.workingDirectory,t),s=x(this.context.workingDirectory,o),r=await w(o);this.assertions.push({description:e??`Directory exists: ${s}`,passed:r,expected:"directory exists",actual:r?"directory exists":"directory not found"})}assertOutput(t,e,o){let r=(typeof e=="string"?new RegExp(e):e).test(t.output);this.assertions.push({description:o??`Output matches ${e}`,passed:r,expected:`output matching ${e}`,actual:r?"matched":`output: ${t.output.slice(0,200)}`})}assertJson(t,e,o){try{let s=JSON.parse(t.stdout);if(e){let r=e(s);this.assertions.push({description:o??"Output is valid JSON matching validator",passed:r,expected:"valid JSON matching validator",actual:r?"matched":"validator returned false"})}else this.assertions.push({description:o??"Output is valid JSON",passed:!0,expected:"valid JSON",actual:"valid JSON"});return s}catch{this.assertions.push({description:o??"Output is valid JSON",passed:!1,expected:"valid JSON",actual:`invalid JSON: ${t.stdout.slice(0,100)}`});return}}assert(t,e){this.assertions.push({description:e,passed:t,expected:"true",actual:String(t)})}assertEqual(t,e,o){this.assertions.push({description:o,passed:t===e,expected:String(e),actual:String(t)})}hasFailures(){return this.assertions.some(t=>!t.passed)}};var p=class extends m{static description="Tests the theme init command creates a valid theme structure";themeName="";themePath="";tests(){this.test("init creates theme directory",async()=>{this.themeName=`doctor-theme-${C("creative")}`,this.themePath=u(this.context.workingDirectory,this.themeName);let t=await this.runInteractive(`shopify theme init ${this.themeName} --path ${this.context.workingDirectory}`);this.assertSuccess(t),this.context.themeName=this.themeName,this.context.themePath=this.themePath}),this.test("essential theme files exist",async()=>{let t=["layout/theme.liquid","config/settings_schema.json","templates/index.json"];await Promise.all(t.map(e=>this.assertFile(u(this.themePath,e))))}),this.test("theme directories exist",async()=>{let t=["sections","snippets","assets","locales"];await Promise.all(t.map(e=>this.assertDirectory(u(this.themePath,e))))}),this.test("layout/theme.liquid has valid content",async()=>{await this.assertFile(u(this.themePath,"layout/theme.liquid"),/<!doctype html>|<html|{{ content_for_header }}/i,"layout/theme.liquid contains expected Liquid markup")})}};d();var l=class extends m{static description="Tests pushing a theme to the store creates an unpublished theme";static requiresStore=!0;tests(){this.test("push creates unpublished theme",async()=>{if(!this.context.themePath){this.assert(!1,"Theme init did not complete successfully; themePath is missing in context");return}let t=this.context.themeName??"doctor-theme",e=`shopify theme push --unpublished --json --path ${this.context.themePath} -t ${t}`;this.context.environment&&(e+=` -e ${this.context.environment}`),this.context.store&&(e+=` -s ${this.context.store}`),this.context.password&&(e+=` --password ${this.context.password}`);let o=await this.run(e);this.assertSuccess(o);let s=this.assertJson(o,r=>typeof r.theme?.id=="number");s?.theme&&(this.assert(typeof s.theme.id=="number","Theme was created with a valid ID"),this.assertEqual(s.theme.role,"unpublished","Theme role is unpublished"),this.assert(s.theme.editor_url.includes("/admin/themes/"),"Editor URL is provided"),this.assert(s.theme.preview_url.includes("preview_theme_id="),"Preview URL is provided"),this.context.themeId=String(s.theme.id),this.context.data.editorUrl=s.theme.editor_url,this.context.data.previewUrl=s.theme.preview_url)})}};d();function _(i){return{workingDirectory:i.path??y(),environment:i.environment,store:i.store,password:i.password,data:{}}}d();var a=i=>k(i),v;function J(i){v=i}function G(i){if(!v)return i;let t=/\/[^\s,)]+/g;return i.replace(t,e=>T(e,v))}function A(i,t){a(""),a(n.bold(n.cyan(`Suite: ${i}`))),a(n.dim(t))}function j(i){a(n.bold(n.blue(`Running: ${i}`)))}function q(i){let t=`(${(i.duration/1e3).toFixed(2)}s)`;if(i.status==="passed"){a(n.bold(n.green(`PASSED: ${i.name} ${n.dim(t)}`)));for(let e of I(i.assertions))a(e)}else if(i.status==="failed"){a(n.red(`FAILED: ${i.name} ${n.dim(t)}`));for(let e of I(i.assertions))a(e);i.error&&a(n.red(` Error: ${G(i.error.message)}`))}else a(n.yellow(`SKIPPED: ${i.name}`))}function S(i){let t=i.filter(h=>h.status==="passed").length,e=i.filter(h=>h.status==="failed").length,o=i.filter(h=>h.status==="skipped").length,s=i.length,r=i.reduce((h,c)=>h+c.duration,0);a(""),a(n.bold("\u2500".repeat(40))),e>0?a(n.red(n.bold(`Doctor Complete: ${e}/${s} tests failed`))):a(n.green(n.bold(`Doctor Complete: ${t}/${s} tests passed`))),a(` Passed: ${n.green(String(t))}`),a(` Failed: ${n.red(String(e))}`),o>0&&a(` Skipped: ${n.yellow(String(o))}`),a(` Total time: ${n.dim(`${(r/1e3).toFixed(2)}s`)}`)}function I(i){return i.map(t=>{if(t.passed)return n.green(` [OK] ${t.description}`);{let e=` (expected: ${t.expected}, actual: ${t.actual})`;return n.red(` [FAIL] ${t.description}${e}`)}})}var Y=[p,l];async function L(i){let t=[],e=_(i);J(e.workingDirectory);for(let o of Y){let s=new o,r=o.description??"Test suite";A(o.name,r);let h=await s.runSuite(e);for(let c of h)if(j(c.name),q(c),t.push(c),c.status==="failed")return S(t),t}return S(t),t}var f=H(U(),1);var $=class i extends b{static description="Run all theme command doctor-release tests";static hidden=!0;static flags={...E,path:f.Flags.string({char:"p",description:"The path to run tests in. Defaults to current directory.",env:"SHOPIFY_FLAG_PATH",parse:async t=>P(t),default:async()=>y()}),environment:f.Flags.string({char:"e",description:"The environment to use from shopify.theme.toml (required for store-connected tests).",env:"SHOPIFY_FLAG_ENVIRONMENT",required:!0}),store:f.Flags.string({char:"s",description:"Store URL (overrides environment).",env:"SHOPIFY_FLAG_STORE"}),password:f.Flags.string({description:"Password from Theme Access app (overrides environment).",env:"SHOPIFY_FLAG_PASSWORD"})};async run(){if(!R())return;let{flags:t}=await this.parse(i);(await L({path:t.path,environment:t.environment,store:t.store,password:t.password})).some(s=>s.status==="failed")&&(process.exitCode=1)}};export{$ as a};
@@ -1,4 +1,4 @@
1
- import{v as xy}from"./chunk-Y3PY5LP7.js";import{A as Iy,B as Ny,C as zy,D as hi,E as Oy,F as zn,G as Ay,H as Ly,I as ja,J as qy,K as $a,L as Wy,M as ls,N as r0,O as Hy,P as Ba,Q as cs,R as ds,S as On,T as Uy,U as ln,V as Va,W as Ga,X as $,Y as i0,Z as o0,b as Y,d as La,da as qu,e as ky,f as Nn,g as Te,h as qa,i as Cy,j as Ty,k as _y,l as Ey,m as Ry,n as as,o as Dy,p as Wa,q as J,r as Ha,s as Fy,t as Ua,u as Jt,v as Py,w as G,x as dt,y as Dr,z as My}from"./chunk-NCRWOW6F.js";import{b as Sy}from"./chunk-NU5WLZ6Y.js";import{a as Vt,b as ee,c as w,d as wy,e as Gt,f as Kt,g as h}from"./chunk-VKWPEFWQ.js";var Ui=w(ht=>{"use strict";h();Object.defineProperty(ht,"__esModule",{value:!0});ht.stringArray=ht.array=ht.func=ht.error=ht.number=ht.string=ht.boolean=void 0;function s0(n){return n===!0||n===!1}ht.boolean=s0;function jy(n){return typeof n=="string"||n instanceof String}ht.string=jy;function a0(n){return typeof n=="number"||n instanceof Number}ht.number=a0;function l0(n){return n instanceof Error}ht.error=l0;function c0(n){return typeof n=="function"}ht.func=c0;function $y(n){return Array.isArray(n)}ht.array=$y;function d0(n){return $y(n)&&n.every(e=>jy(e))}ht.stringArray=d0});var cp=w(B=>{"use strict";h();Object.defineProperty(B,"__esModule",{value:!0});B.Message=B.NotificationType9=B.NotificationType8=B.NotificationType7=B.NotificationType6=B.NotificationType5=B.NotificationType4=B.NotificationType3=B.NotificationType2=B.NotificationType1=B.NotificationType0=B.NotificationType=B.RequestType9=B.RequestType8=B.RequestType7=B.RequestType6=B.RequestType5=B.RequestType4=B.RequestType3=B.RequestType2=B.RequestType1=B.RequestType=B.RequestType0=B.AbstractMessageSignature=B.ParameterStructures=B.ResponseError=B.ErrorCodes=void 0;var ui=Ui(),By;(function(n){n.ParseError=-32700,n.InvalidRequest=-32600,n.MethodNotFound=-32601,n.InvalidParams=-32602,n.InternalError=-32603,n.jsonrpcReservedErrorRangeStart=-32099,n.serverErrorStart=-32099,n.MessageWriteError=-32099,n.MessageReadError=-32098,n.PendingResponseRejected=-32097,n.ConnectionInactive=-32096,n.ServerNotInitialized=-32002,n.UnknownErrorCode=-32001,n.jsonrpcReservedErrorRangeEnd=-32e3,n.serverErrorEnd=-32e3})(By=B.ErrorCodes||(B.ErrorCodes={}));var Wu=class n extends Error{constructor(e,t,r){super(t),this.code=ui.number(e)?e:By.UnknownErrorCode,this.data=r,Object.setPrototypeOf(this,n.prototype)}toJson(){let e={code:this.code,message:this.message};return this.data!==void 0&&(e.data=this.data),e}};B.ResponseError=Wu;var Rt=class n{constructor(e){this.kind=e}static is(e){return e===n.auto||e===n.byName||e===n.byPosition}toString(){return this.kind}};B.ParameterStructures=Rt;Rt.auto=new Rt("auto");Rt.byPosition=new Rt("byPosition");Rt.byName=new Rt("byName");var _e=class{constructor(e,t){this.method=e,this.numberOfParams=t}get parameterStructures(){return Rt.auto}};B.AbstractMessageSignature=_e;var Hu=class extends _e{constructor(e){super(e,0)}};B.RequestType0=Hu;var Uu=class extends _e{constructor(e,t=Rt.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}};B.RequestType=Uu;var ju=class extends _e{constructor(e,t=Rt.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}};B.RequestType1=ju;var $u=class extends _e{constructor(e){super(e,2)}};B.RequestType2=$u;var Bu=class extends _e{constructor(e){super(e,3)}};B.RequestType3=Bu;var Vu=class extends _e{constructor(e){super(e,4)}};B.RequestType4=Vu;var Gu=class extends _e{constructor(e){super(e,5)}};B.RequestType5=Gu;var Ku=class extends _e{constructor(e){super(e,6)}};B.RequestType6=Ku;var Ju=class extends _e{constructor(e){super(e,7)}};B.RequestType7=Ju;var Xu=class extends _e{constructor(e){super(e,8)}};B.RequestType8=Xu;var Yu=class extends _e{constructor(e){super(e,9)}};B.RequestType9=Yu;var Qu=class extends _e{constructor(e,t=Rt.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}};B.NotificationType=Qu;var Zu=class extends _e{constructor(e){super(e,0)}};B.NotificationType0=Zu;var ep=class extends _e{constructor(e,t=Rt.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}};B.NotificationType1=ep;var tp=class extends _e{constructor(e){super(e,2)}};B.NotificationType2=tp;var np=class extends _e{constructor(e){super(e,3)}};B.NotificationType3=np;var rp=class extends _e{constructor(e){super(e,4)}};B.NotificationType4=rp;var ip=class extends _e{constructor(e){super(e,5)}};B.NotificationType5=ip;var op=class extends _e{constructor(e){super(e,6)}};B.NotificationType6=op;var sp=class extends _e{constructor(e){super(e,7)}};B.NotificationType7=sp;var ap=class extends _e{constructor(e){super(e,8)}};B.NotificationType8=ap;var lp=class extends _e{constructor(e){super(e,9)}};B.NotificationType9=lp;var h0;(function(n){function e(i){let o=i;return o&&ui.string(o.method)&&(ui.string(o.id)||ui.number(o.id))}n.isRequest=e;function t(i){let o=i;return o&&ui.string(o.method)&&i.id===void 0}n.isNotification=t;function r(i){let o=i;return o&&(o.result!==void 0||!!o.error)&&(ui.string(o.id)||ui.number(o.id)||o.id===null)}n.isResponse=r})(h0=B.Message||(B.Message={}))});var hp=w(tr=>{"use strict";h();var Vy;Object.defineProperty(tr,"__esModule",{value:!0});tr.LRUCache=tr.LinkedMap=tr.Touch=void 0;var gt;(function(n){n.None=0,n.First=1,n.AsOld=n.First,n.Last=2,n.AsNew=n.Last})(gt=tr.Touch||(tr.Touch={}));var Ka=class{constructor(){this[Vy]="LinkedMap",this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(e){return this._map.has(e)}get(e,t=gt.None){let r=this._map.get(e);if(r)return t!==gt.None&&this.touch(r,t),r.value}set(e,t,r=gt.None){let i=this._map.get(e);if(i)i.value=t,r!==gt.None&&this.touch(i,r);else{switch(i={key:e,value:t,next:void 0,previous:void 0},r){case gt.None:this.addItemLast(i);break;case gt.First:this.addItemFirst(i);break;case gt.Last:this.addItemLast(i);break;default:this.addItemLast(i);break}this._map.set(e,i),this._size++}return this}delete(e){return!!this.remove(e)}remove(e){let t=this._map.get(e);if(t)return this._map.delete(e),this.removeItem(t),this._size--,t.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw new Error("Invalid list");let e=this._head;return this._map.delete(e.key),this.removeItem(e),this._size--,e.value}forEach(e,t){let r=this._state,i=this._head;for(;i;){if(t?e.bind(t)(i.value,i.key,this):e(i.value,i.key,this),this._state!==r)throw new Error("LinkedMap got modified during iteration.");i=i.next}}keys(){let e=this._state,t=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==e)throw new Error("LinkedMap got modified during iteration.");if(t){let i={value:t.key,done:!1};return t=t.next,i}else return{value:void 0,done:!0}}};return r}values(){let e=this._state,t=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==e)throw new Error("LinkedMap got modified during iteration.");if(t){let i={value:t.value,done:!1};return t=t.next,i}else return{value:void 0,done:!0}}};return r}entries(){let e=this._state,t=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==e)throw new Error("LinkedMap got modified during iteration.");if(t){let i={value:[t.key,t.value],done:!1};return t=t.next,i}else return{value:void 0,done:!0}}};return r}[(Vy=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(e){if(e>=this.size)return;if(e===0){this.clear();return}let t=this._head,r=this.size;for(;t&&r>e;)this._map.delete(t.key),t=t.next,r--;this._head=t,this._size=r,t&&(t.previous=void 0),this._state++}addItemFirst(e){if(!this._head&&!this._tail)this._tail=e;else if(this._head)e.next=this._head,this._head.previous=e;else throw new Error("Invalid list");this._head=e,this._state++}addItemLast(e){if(!this._head&&!this._tail)this._head=e;else if(this._tail)e.previous=this._tail,this._tail.next=e;else throw new Error("Invalid list");this._tail=e,this._state++}removeItem(e){if(e===this._head&&e===this._tail)this._head=void 0,this._tail=void 0;else if(e===this._head){if(!e.next)throw new Error("Invalid list");e.next.previous=void 0,this._head=e.next}else if(e===this._tail){if(!e.previous)throw new Error("Invalid list");e.previous.next=void 0,this._tail=e.previous}else{let t=e.next,r=e.previous;if(!t||!r)throw new Error("Invalid list");t.previous=r,r.next=t}e.next=void 0,e.previous=void 0,this._state++}touch(e,t){if(!this._head||!this._tail)throw new Error("Invalid list");if(!(t!==gt.First&&t!==gt.Last)){if(t===gt.First){if(e===this._head)return;let r=e.next,i=e.previous;e===this._tail?(i.next=void 0,this._tail=i):(r.previous=i,i.next=r),e.previous=void 0,e.next=this._head,this._head.previous=e,this._head=e,this._state++}else if(t===gt.Last){if(e===this._tail)return;let r=e.next,i=e.previous;e===this._head?(r.previous=void 0,this._head=r):(r.previous=i,i.next=r),e.next=void 0,e.previous=this._tail,this._tail.next=e,this._tail=e,this._state++}}}toJSON(){let e=[];return this.forEach((t,r)=>{e.push([r,t])}),e}fromJSON(e){this.clear();for(let[t,r]of e)this.set(t,r)}};tr.LinkedMap=Ka;var dp=class extends Ka{constructor(e,t=1){super(),this._limit=e,this._ratio=Math.min(Math.max(0,t),1)}get limit(){return this._limit}set limit(e){this._limit=e,this.checkTrim()}get ratio(){return this._ratio}set ratio(e){this._ratio=Math.min(Math.max(0,e),1),this.checkTrim()}get(e,t=gt.AsNew){return super.get(e,t)}peek(e){return super.get(e,gt.None)}set(e,t){return super.set(e,t,gt.Last),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}};tr.LRUCache=dp});var Gy=w(hs=>{"use strict";h();Object.defineProperty(hs,"__esModule",{value:!0});hs.Disposable=void 0;var u0;(function(n){function e(t){return{dispose:t}}n.create=e})(u0=hs.Disposable||(hs.Disposable={}))});var Fr=w(mp=>{"use strict";h();Object.defineProperty(mp,"__esModule",{value:!0});var up;function pp(){if(up===void 0)throw new Error("No runtime abstraction layer installed");return up}(function(n){function e(t){if(t===void 0)throw new Error("No runtime abstraction layer provided");up=t}n.install=e})(pp||(pp={}));mp.default=pp});var ji=w(pi=>{"use strict";h();Object.defineProperty(pi,"__esModule",{value:!0});pi.Emitter=pi.Event=void 0;var p0=Fr(),m0;(function(n){let e={dispose(){}};n.None=function(){return e}})(m0=pi.Event||(pi.Event={}));var fp=class{add(e,t=null,r){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(e),this._contexts.push(t),Array.isArray(r)&&r.push({dispose:()=>this.remove(e,t)})}remove(e,t=null){if(!this._callbacks)return;let r=!1;for(let i=0,o=this._callbacks.length;i<o;i++)if(this._callbacks[i]===e)if(this._contexts[i]===t){this._callbacks.splice(i,1),this._contexts.splice(i,1);return}else r=!0;if(r)throw new Error("When adding a listener with a context, you should remove it with the same context")}invoke(...e){if(!this._callbacks)return[];let t=[],r=this._callbacks.slice(0),i=this._contexts.slice(0);for(let o=0,s=r.length;o<s;o++)try{t.push(r[o].apply(i[o],e))}catch(a){(0,p0.default)().console.error(a)}return t}isEmpty(){return!this._callbacks||this._callbacks.length===0}dispose(){this._callbacks=void 0,this._contexts=void 0}},Ja=class n{constructor(e){this._options=e}get event(){return this._event||(this._event=(e,t,r)=>{this._callbacks||(this._callbacks=new fp),this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(e,t);let i={dispose:()=>{this._callbacks&&(this._callbacks.remove(e,t),i.dispose=n._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))}};return Array.isArray(r)&&r.push(i),i}),this._event}fire(e){this._callbacks&&this._callbacks.invoke.call(this._callbacks,e)}dispose(){this._callbacks&&(this._callbacks.dispose(),this._callbacks=void 0)}};pi.Emitter=Ja;Ja._noop=function(){}});var Ya=w(mi=>{"use strict";h();Object.defineProperty(mi,"__esModule",{value:!0});mi.CancellationTokenSource=mi.CancellationToken=void 0;var f0=Fr(),g0=Ui(),gp=ji(),bp;(function(n){n.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:gp.Event.None}),n.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:gp.Event.None});function e(t){let r=t;return r&&(r===n.None||r===n.Cancelled||g0.boolean(r.isCancellationRequested)&&!!r.onCancellationRequested)}n.is=e})(bp=mi.CancellationToken||(mi.CancellationToken={}));var b0=Object.freeze(function(n,e){let t=(0,f0.default)().timer.setTimeout(n.bind(e),0);return{dispose(){t.dispose()}}}),Xa=class{constructor(){this._isCancelled=!1}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?b0:(this._emitter||(this._emitter=new gp.Emitter),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=void 0)}},vp=class{get token(){return this._token||(this._token=new Xa),this._token}cancel(){this._token?this._token.cancel():this._token=bp.Cancelled}dispose(){this._token?this._token instanceof Xa&&this._token.dispose():this._token=bp.None}};mi.CancellationTokenSource=vp});var Ky=w($i=>{"use strict";h();Object.defineProperty($i,"__esModule",{value:!0});$i.SharedArrayReceiverStrategy=$i.SharedArraySenderStrategy=void 0;var v0=Ya(),us;(function(n){n.Continue=0,n.Cancelled=1})(us||(us={}));var yp=class{constructor(){this.buffers=new Map}enableCancellation(e){if(e.id===null)return;let t=new SharedArrayBuffer(4),r=new Int32Array(t,0,1);r[0]=us.Continue,this.buffers.set(e.id,t),e.$cancellationData=t}async sendCancellation(e,t){let r=this.buffers.get(t);if(r===void 0)return;let i=new Int32Array(r,0,1);Atomics.store(i,0,us.Cancelled)}cleanup(e){this.buffers.delete(e)}dispose(){this.buffers.clear()}};$i.SharedArraySenderStrategy=yp;var wp=class{constructor(e){this.data=new Int32Array(e,0,1)}get isCancellationRequested(){return Atomics.load(this.data,0)===us.Cancelled}get onCancellationRequested(){throw new Error("Cancellation over SharedArrayBuffer doesn't support cancellation events")}},Sp=class{constructor(e){this.token=new wp(e)}cancel(){}dispose(){}},xp=class{constructor(){this.kind="request"}createCancellationTokenSource(e){let t=e.$cancellationData;return t===void 0?new v0.CancellationTokenSource:new Sp(t)}};$i.SharedArrayReceiverStrategy=xp});var Cp=w(Qa=>{"use strict";h();Object.defineProperty(Qa,"__esModule",{value:!0});Qa.Semaphore=void 0;var y0=Fr(),kp=class{constructor(e=1){if(e<=0)throw new Error("Capacity must be greater than 0");this._capacity=e,this._active=0,this._waiting=[]}lock(e){return new Promise((t,r)=>{this._waiting.push({thunk:e,resolve:t,reject:r}),this.runNext()})}get active(){return this._active}runNext(){this._waiting.length===0||this._active===this._capacity||(0,y0.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;let e=this._waiting.shift();if(this._active++,this._active>this._capacity)throw new Error("To many thunks active");try{let t=e.thunk();t instanceof Promise?t.then(r=>{this._active--,e.resolve(r),this.runNext()},r=>{this._active--,e.reject(r),this.runNext()}):(this._active--,e.resolve(t),this.runNext())}catch(t){this._active--,e.reject(t),this.runNext()}}};Qa.Semaphore=kp});var Jy=w(nr=>{"use strict";h();Object.defineProperty(nr,"__esModule",{value:!0});nr.ReadableStreamMessageReader=nr.AbstractMessageReader=nr.MessageReader=void 0;var _p=Fr(),Bi=Ui(),Tp=ji(),w0=Cp(),S0;(function(n){function e(t){let r=t;return r&&Bi.func(r.listen)&&Bi.func(r.dispose)&&Bi.func(r.onError)&&Bi.func(r.onClose)&&Bi.func(r.onPartialMessage)}n.is=e})(S0=nr.MessageReader||(nr.MessageReader={}));var Za=class{constructor(){this.errorEmitter=new Tp.Emitter,this.closeEmitter=new Tp.Emitter,this.partialMessageEmitter=new Tp.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e){this.errorEmitter.fire(this.asError(e))}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}get onPartialMessage(){return this.partialMessageEmitter.event}firePartialMessage(e){this.partialMessageEmitter.fire(e)}asError(e){return e instanceof Error?e:new Error(`Reader received error. Reason: ${Bi.string(e.message)?e.message:"unknown"}`)}};nr.AbstractMessageReader=Za;var Ep;(function(n){function e(t){let r,i,o,s=new Map,a,l=new Map;if(t===void 0||typeof t=="string")r=t??"utf-8";else{if(r=t.charset??"utf-8",t.contentDecoder!==void 0&&(o=t.contentDecoder,s.set(o.name,o)),t.contentDecoders!==void 0)for(let c of t.contentDecoders)s.set(c.name,c);if(t.contentTypeDecoder!==void 0&&(a=t.contentTypeDecoder,l.set(a.name,a)),t.contentTypeDecoders!==void 0)for(let c of t.contentTypeDecoders)l.set(c.name,c)}return a===void 0&&(a=(0,_p.default)().applicationJson.decoder,l.set(a.name,a)),{charset:r,contentDecoder:o,contentDecoders:s,contentTypeDecoder:a,contentTypeDecoders:l}}n.fromOptions=e})(Ep||(Ep={}));var Rp=class extends Za{constructor(e,t){super(),this.readable=e,this.options=Ep.fromOptions(t),this.buffer=(0,_p.default)().messageBuffer.create(this.options.charset),this._partialMessageTimeout=1e4,this.nextMessageLength=-1,this.messageToken=0,this.readSemaphore=new w0.Semaphore(1)}set partialMessageTimeout(e){this._partialMessageTimeout=e}get partialMessageTimeout(){return this._partialMessageTimeout}listen(e){this.nextMessageLength=-1,this.messageToken=0,this.partialMessageTimer=void 0,this.callback=e;let t=this.readable.onData(r=>{this.onData(r)});return this.readable.onError(r=>this.fireError(r)),this.readable.onClose(()=>this.fireClose()),t}onData(e){for(this.buffer.append(e);;){if(this.nextMessageLength===-1){let r=this.buffer.tryReadHeaders(!0);if(!r)return;let i=r.get("content-length");if(!i){this.fireError(new Error("Header must provide a Content-Length property."));return}let o=parseInt(i);if(isNaN(o)){this.fireError(new Error("Content-Length value must be a number."));return}this.nextMessageLength=o}let t=this.buffer.tryReadBody(this.nextMessageLength);if(t===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{let r=this.options.contentDecoder!==void 0?await this.options.contentDecoder.decode(t):t,i=await this.options.contentTypeDecoder.decode(r,this.options);this.callback(i)}).catch(r=>{this.fireError(r)})}}clearPartialMessageTimer(){this.partialMessageTimer&&(this.partialMessageTimer.dispose(),this.partialMessageTimer=void 0)}setPartialMessageTimer(){this.clearPartialMessageTimer(),!(this._partialMessageTimeout<=0)&&(this.partialMessageTimer=(0,_p.default)().timer.setTimeout((e,t)=>{this.partialMessageTimer=void 0,e===this.messageToken&&(this.firePartialMessage({messageToken:e,waitingTime:t}),this.setPartialMessageTimer())},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout))}};nr.ReadableStreamMessageReader=Rp});var Zy=w(rr=>{"use strict";h();Object.defineProperty(rr,"__esModule",{value:!0});rr.WriteableStreamMessageWriter=rr.AbstractMessageWriter=rr.MessageWriter=void 0;var Xy=Fr(),ps=Ui(),x0=Cp(),Yy=ji(),k0="Content-Length: ",Qy=`\r
1
+ import{v as xy}from"./chunk-DJAZBPYA.js";import{A as Iy,B as Ny,C as zy,D as hi,E as Oy,F as zn,G as Ay,H as Ly,I as ja,J as qy,K as $a,L as Wy,M as ls,N as r0,O as Hy,P as Ba,Q as cs,R as ds,S as On,T as Uy,U as ln,V as Va,W as Ga,X as $,Y as i0,Z as o0,b as Y,d as La,da as qu,e as ky,f as Nn,g as Te,h as qa,i as Cy,j as Ty,k as _y,l as Ey,m as Ry,n as as,o as Dy,p as Wa,q as J,r as Ha,s as Fy,t as Ua,u as Jt,v as Py,w as G,x as dt,y as Dr,z as My}from"./chunk-M5TGCSUK.js";import{b as Sy}from"./chunk-Q2SZCZE7.js";import{a as Vt,b as ee,c as w,d as wy,e as Gt,f as Kt,g as h}from"./chunk-VKWPEFWQ.js";var Ui=w(ht=>{"use strict";h();Object.defineProperty(ht,"__esModule",{value:!0});ht.stringArray=ht.array=ht.func=ht.error=ht.number=ht.string=ht.boolean=void 0;function s0(n){return n===!0||n===!1}ht.boolean=s0;function jy(n){return typeof n=="string"||n instanceof String}ht.string=jy;function a0(n){return typeof n=="number"||n instanceof Number}ht.number=a0;function l0(n){return n instanceof Error}ht.error=l0;function c0(n){return typeof n=="function"}ht.func=c0;function $y(n){return Array.isArray(n)}ht.array=$y;function d0(n){return $y(n)&&n.every(e=>jy(e))}ht.stringArray=d0});var cp=w(B=>{"use strict";h();Object.defineProperty(B,"__esModule",{value:!0});B.Message=B.NotificationType9=B.NotificationType8=B.NotificationType7=B.NotificationType6=B.NotificationType5=B.NotificationType4=B.NotificationType3=B.NotificationType2=B.NotificationType1=B.NotificationType0=B.NotificationType=B.RequestType9=B.RequestType8=B.RequestType7=B.RequestType6=B.RequestType5=B.RequestType4=B.RequestType3=B.RequestType2=B.RequestType1=B.RequestType=B.RequestType0=B.AbstractMessageSignature=B.ParameterStructures=B.ResponseError=B.ErrorCodes=void 0;var ui=Ui(),By;(function(n){n.ParseError=-32700,n.InvalidRequest=-32600,n.MethodNotFound=-32601,n.InvalidParams=-32602,n.InternalError=-32603,n.jsonrpcReservedErrorRangeStart=-32099,n.serverErrorStart=-32099,n.MessageWriteError=-32099,n.MessageReadError=-32098,n.PendingResponseRejected=-32097,n.ConnectionInactive=-32096,n.ServerNotInitialized=-32002,n.UnknownErrorCode=-32001,n.jsonrpcReservedErrorRangeEnd=-32e3,n.serverErrorEnd=-32e3})(By=B.ErrorCodes||(B.ErrorCodes={}));var Wu=class n extends Error{constructor(e,t,r){super(t),this.code=ui.number(e)?e:By.UnknownErrorCode,this.data=r,Object.setPrototypeOf(this,n.prototype)}toJson(){let e={code:this.code,message:this.message};return this.data!==void 0&&(e.data=this.data),e}};B.ResponseError=Wu;var Rt=class n{constructor(e){this.kind=e}static is(e){return e===n.auto||e===n.byName||e===n.byPosition}toString(){return this.kind}};B.ParameterStructures=Rt;Rt.auto=new Rt("auto");Rt.byPosition=new Rt("byPosition");Rt.byName=new Rt("byName");var _e=class{constructor(e,t){this.method=e,this.numberOfParams=t}get parameterStructures(){return Rt.auto}};B.AbstractMessageSignature=_e;var Hu=class extends _e{constructor(e){super(e,0)}};B.RequestType0=Hu;var Uu=class extends _e{constructor(e,t=Rt.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}};B.RequestType=Uu;var ju=class extends _e{constructor(e,t=Rt.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}};B.RequestType1=ju;var $u=class extends _e{constructor(e){super(e,2)}};B.RequestType2=$u;var Bu=class extends _e{constructor(e){super(e,3)}};B.RequestType3=Bu;var Vu=class extends _e{constructor(e){super(e,4)}};B.RequestType4=Vu;var Gu=class extends _e{constructor(e){super(e,5)}};B.RequestType5=Gu;var Ku=class extends _e{constructor(e){super(e,6)}};B.RequestType6=Ku;var Ju=class extends _e{constructor(e){super(e,7)}};B.RequestType7=Ju;var Xu=class extends _e{constructor(e){super(e,8)}};B.RequestType8=Xu;var Yu=class extends _e{constructor(e){super(e,9)}};B.RequestType9=Yu;var Qu=class extends _e{constructor(e,t=Rt.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}};B.NotificationType=Qu;var Zu=class extends _e{constructor(e){super(e,0)}};B.NotificationType0=Zu;var ep=class extends _e{constructor(e,t=Rt.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}};B.NotificationType1=ep;var tp=class extends _e{constructor(e){super(e,2)}};B.NotificationType2=tp;var np=class extends _e{constructor(e){super(e,3)}};B.NotificationType3=np;var rp=class extends _e{constructor(e){super(e,4)}};B.NotificationType4=rp;var ip=class extends _e{constructor(e){super(e,5)}};B.NotificationType5=ip;var op=class extends _e{constructor(e){super(e,6)}};B.NotificationType6=op;var sp=class extends _e{constructor(e){super(e,7)}};B.NotificationType7=sp;var ap=class extends _e{constructor(e){super(e,8)}};B.NotificationType8=ap;var lp=class extends _e{constructor(e){super(e,9)}};B.NotificationType9=lp;var h0;(function(n){function e(i){let o=i;return o&&ui.string(o.method)&&(ui.string(o.id)||ui.number(o.id))}n.isRequest=e;function t(i){let o=i;return o&&ui.string(o.method)&&i.id===void 0}n.isNotification=t;function r(i){let o=i;return o&&(o.result!==void 0||!!o.error)&&(ui.string(o.id)||ui.number(o.id)||o.id===null)}n.isResponse=r})(h0=B.Message||(B.Message={}))});var hp=w(tr=>{"use strict";h();var Vy;Object.defineProperty(tr,"__esModule",{value:!0});tr.LRUCache=tr.LinkedMap=tr.Touch=void 0;var gt;(function(n){n.None=0,n.First=1,n.AsOld=n.First,n.Last=2,n.AsNew=n.Last})(gt=tr.Touch||(tr.Touch={}));var Ka=class{constructor(){this[Vy]="LinkedMap",this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(e){return this._map.has(e)}get(e,t=gt.None){let r=this._map.get(e);if(r)return t!==gt.None&&this.touch(r,t),r.value}set(e,t,r=gt.None){let i=this._map.get(e);if(i)i.value=t,r!==gt.None&&this.touch(i,r);else{switch(i={key:e,value:t,next:void 0,previous:void 0},r){case gt.None:this.addItemLast(i);break;case gt.First:this.addItemFirst(i);break;case gt.Last:this.addItemLast(i);break;default:this.addItemLast(i);break}this._map.set(e,i),this._size++}return this}delete(e){return!!this.remove(e)}remove(e){let t=this._map.get(e);if(t)return this._map.delete(e),this.removeItem(t),this._size--,t.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw new Error("Invalid list");let e=this._head;return this._map.delete(e.key),this.removeItem(e),this._size--,e.value}forEach(e,t){let r=this._state,i=this._head;for(;i;){if(t?e.bind(t)(i.value,i.key,this):e(i.value,i.key,this),this._state!==r)throw new Error("LinkedMap got modified during iteration.");i=i.next}}keys(){let e=this._state,t=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==e)throw new Error("LinkedMap got modified during iteration.");if(t){let i={value:t.key,done:!1};return t=t.next,i}else return{value:void 0,done:!0}}};return r}values(){let e=this._state,t=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==e)throw new Error("LinkedMap got modified during iteration.");if(t){let i={value:t.value,done:!1};return t=t.next,i}else return{value:void 0,done:!0}}};return r}entries(){let e=this._state,t=this._head,r={[Symbol.iterator]:()=>r,next:()=>{if(this._state!==e)throw new Error("LinkedMap got modified during iteration.");if(t){let i={value:[t.key,t.value],done:!1};return t=t.next,i}else return{value:void 0,done:!0}}};return r}[(Vy=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(e){if(e>=this.size)return;if(e===0){this.clear();return}let t=this._head,r=this.size;for(;t&&r>e;)this._map.delete(t.key),t=t.next,r--;this._head=t,this._size=r,t&&(t.previous=void 0),this._state++}addItemFirst(e){if(!this._head&&!this._tail)this._tail=e;else if(this._head)e.next=this._head,this._head.previous=e;else throw new Error("Invalid list");this._head=e,this._state++}addItemLast(e){if(!this._head&&!this._tail)this._head=e;else if(this._tail)e.previous=this._tail,this._tail.next=e;else throw new Error("Invalid list");this._tail=e,this._state++}removeItem(e){if(e===this._head&&e===this._tail)this._head=void 0,this._tail=void 0;else if(e===this._head){if(!e.next)throw new Error("Invalid list");e.next.previous=void 0,this._head=e.next}else if(e===this._tail){if(!e.previous)throw new Error("Invalid list");e.previous.next=void 0,this._tail=e.previous}else{let t=e.next,r=e.previous;if(!t||!r)throw new Error("Invalid list");t.previous=r,r.next=t}e.next=void 0,e.previous=void 0,this._state++}touch(e,t){if(!this._head||!this._tail)throw new Error("Invalid list");if(!(t!==gt.First&&t!==gt.Last)){if(t===gt.First){if(e===this._head)return;let r=e.next,i=e.previous;e===this._tail?(i.next=void 0,this._tail=i):(r.previous=i,i.next=r),e.previous=void 0,e.next=this._head,this._head.previous=e,this._head=e,this._state++}else if(t===gt.Last){if(e===this._tail)return;let r=e.next,i=e.previous;e===this._head?(r.previous=void 0,this._head=r):(r.previous=i,i.next=r),e.next=void 0,e.previous=this._tail,this._tail.next=e,this._tail=e,this._state++}}}toJSON(){let e=[];return this.forEach((t,r)=>{e.push([r,t])}),e}fromJSON(e){this.clear();for(let[t,r]of e)this.set(t,r)}};tr.LinkedMap=Ka;var dp=class extends Ka{constructor(e,t=1){super(),this._limit=e,this._ratio=Math.min(Math.max(0,t),1)}get limit(){return this._limit}set limit(e){this._limit=e,this.checkTrim()}get ratio(){return this._ratio}set ratio(e){this._ratio=Math.min(Math.max(0,e),1),this.checkTrim()}get(e,t=gt.AsNew){return super.get(e,t)}peek(e){return super.get(e,gt.None)}set(e,t){return super.set(e,t,gt.Last),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}};tr.LRUCache=dp});var Gy=w(hs=>{"use strict";h();Object.defineProperty(hs,"__esModule",{value:!0});hs.Disposable=void 0;var u0;(function(n){function e(t){return{dispose:t}}n.create=e})(u0=hs.Disposable||(hs.Disposable={}))});var Fr=w(mp=>{"use strict";h();Object.defineProperty(mp,"__esModule",{value:!0});var up;function pp(){if(up===void 0)throw new Error("No runtime abstraction layer installed");return up}(function(n){function e(t){if(t===void 0)throw new Error("No runtime abstraction layer provided");up=t}n.install=e})(pp||(pp={}));mp.default=pp});var ji=w(pi=>{"use strict";h();Object.defineProperty(pi,"__esModule",{value:!0});pi.Emitter=pi.Event=void 0;var p0=Fr(),m0;(function(n){let e={dispose(){}};n.None=function(){return e}})(m0=pi.Event||(pi.Event={}));var fp=class{add(e,t=null,r){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(e),this._contexts.push(t),Array.isArray(r)&&r.push({dispose:()=>this.remove(e,t)})}remove(e,t=null){if(!this._callbacks)return;let r=!1;for(let i=0,o=this._callbacks.length;i<o;i++)if(this._callbacks[i]===e)if(this._contexts[i]===t){this._callbacks.splice(i,1),this._contexts.splice(i,1);return}else r=!0;if(r)throw new Error("When adding a listener with a context, you should remove it with the same context")}invoke(...e){if(!this._callbacks)return[];let t=[],r=this._callbacks.slice(0),i=this._contexts.slice(0);for(let o=0,s=r.length;o<s;o++)try{t.push(r[o].apply(i[o],e))}catch(a){(0,p0.default)().console.error(a)}return t}isEmpty(){return!this._callbacks||this._callbacks.length===0}dispose(){this._callbacks=void 0,this._contexts=void 0}},Ja=class n{constructor(e){this._options=e}get event(){return this._event||(this._event=(e,t,r)=>{this._callbacks||(this._callbacks=new fp),this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(e,t);let i={dispose:()=>{this._callbacks&&(this._callbacks.remove(e,t),i.dispose=n._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))}};return Array.isArray(r)&&r.push(i),i}),this._event}fire(e){this._callbacks&&this._callbacks.invoke.call(this._callbacks,e)}dispose(){this._callbacks&&(this._callbacks.dispose(),this._callbacks=void 0)}};pi.Emitter=Ja;Ja._noop=function(){}});var Ya=w(mi=>{"use strict";h();Object.defineProperty(mi,"__esModule",{value:!0});mi.CancellationTokenSource=mi.CancellationToken=void 0;var f0=Fr(),g0=Ui(),gp=ji(),bp;(function(n){n.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:gp.Event.None}),n.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:gp.Event.None});function e(t){let r=t;return r&&(r===n.None||r===n.Cancelled||g0.boolean(r.isCancellationRequested)&&!!r.onCancellationRequested)}n.is=e})(bp=mi.CancellationToken||(mi.CancellationToken={}));var b0=Object.freeze(function(n,e){let t=(0,f0.default)().timer.setTimeout(n.bind(e),0);return{dispose(){t.dispose()}}}),Xa=class{constructor(){this._isCancelled=!1}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?b0:(this._emitter||(this._emitter=new gp.Emitter),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=void 0)}},vp=class{get token(){return this._token||(this._token=new Xa),this._token}cancel(){this._token?this._token.cancel():this._token=bp.Cancelled}dispose(){this._token?this._token instanceof Xa&&this._token.dispose():this._token=bp.None}};mi.CancellationTokenSource=vp});var Ky=w($i=>{"use strict";h();Object.defineProperty($i,"__esModule",{value:!0});$i.SharedArrayReceiverStrategy=$i.SharedArraySenderStrategy=void 0;var v0=Ya(),us;(function(n){n.Continue=0,n.Cancelled=1})(us||(us={}));var yp=class{constructor(){this.buffers=new Map}enableCancellation(e){if(e.id===null)return;let t=new SharedArrayBuffer(4),r=new Int32Array(t,0,1);r[0]=us.Continue,this.buffers.set(e.id,t),e.$cancellationData=t}async sendCancellation(e,t){let r=this.buffers.get(t);if(r===void 0)return;let i=new Int32Array(r,0,1);Atomics.store(i,0,us.Cancelled)}cleanup(e){this.buffers.delete(e)}dispose(){this.buffers.clear()}};$i.SharedArraySenderStrategy=yp;var wp=class{constructor(e){this.data=new Int32Array(e,0,1)}get isCancellationRequested(){return Atomics.load(this.data,0)===us.Cancelled}get onCancellationRequested(){throw new Error("Cancellation over SharedArrayBuffer doesn't support cancellation events")}},Sp=class{constructor(e){this.token=new wp(e)}cancel(){}dispose(){}},xp=class{constructor(){this.kind="request"}createCancellationTokenSource(e){let t=e.$cancellationData;return t===void 0?new v0.CancellationTokenSource:new Sp(t)}};$i.SharedArrayReceiverStrategy=xp});var Cp=w(Qa=>{"use strict";h();Object.defineProperty(Qa,"__esModule",{value:!0});Qa.Semaphore=void 0;var y0=Fr(),kp=class{constructor(e=1){if(e<=0)throw new Error("Capacity must be greater than 0");this._capacity=e,this._active=0,this._waiting=[]}lock(e){return new Promise((t,r)=>{this._waiting.push({thunk:e,resolve:t,reject:r}),this.runNext()})}get active(){return this._active}runNext(){this._waiting.length===0||this._active===this._capacity||(0,y0.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;let e=this._waiting.shift();if(this._active++,this._active>this._capacity)throw new Error("To many thunks active");try{let t=e.thunk();t instanceof Promise?t.then(r=>{this._active--,e.resolve(r),this.runNext()},r=>{this._active--,e.reject(r),this.runNext()}):(this._active--,e.resolve(t),this.runNext())}catch(t){this._active--,e.reject(t),this.runNext()}}};Qa.Semaphore=kp});var Jy=w(nr=>{"use strict";h();Object.defineProperty(nr,"__esModule",{value:!0});nr.ReadableStreamMessageReader=nr.AbstractMessageReader=nr.MessageReader=void 0;var _p=Fr(),Bi=Ui(),Tp=ji(),w0=Cp(),S0;(function(n){function e(t){let r=t;return r&&Bi.func(r.listen)&&Bi.func(r.dispose)&&Bi.func(r.onError)&&Bi.func(r.onClose)&&Bi.func(r.onPartialMessage)}n.is=e})(S0=nr.MessageReader||(nr.MessageReader={}));var Za=class{constructor(){this.errorEmitter=new Tp.Emitter,this.closeEmitter=new Tp.Emitter,this.partialMessageEmitter=new Tp.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e){this.errorEmitter.fire(this.asError(e))}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}get onPartialMessage(){return this.partialMessageEmitter.event}firePartialMessage(e){this.partialMessageEmitter.fire(e)}asError(e){return e instanceof Error?e:new Error(`Reader received error. Reason: ${Bi.string(e.message)?e.message:"unknown"}`)}};nr.AbstractMessageReader=Za;var Ep;(function(n){function e(t){let r,i,o,s=new Map,a,l=new Map;if(t===void 0||typeof t=="string")r=t??"utf-8";else{if(r=t.charset??"utf-8",t.contentDecoder!==void 0&&(o=t.contentDecoder,s.set(o.name,o)),t.contentDecoders!==void 0)for(let c of t.contentDecoders)s.set(c.name,c);if(t.contentTypeDecoder!==void 0&&(a=t.contentTypeDecoder,l.set(a.name,a)),t.contentTypeDecoders!==void 0)for(let c of t.contentTypeDecoders)l.set(c.name,c)}return a===void 0&&(a=(0,_p.default)().applicationJson.decoder,l.set(a.name,a)),{charset:r,contentDecoder:o,contentDecoders:s,contentTypeDecoder:a,contentTypeDecoders:l}}n.fromOptions=e})(Ep||(Ep={}));var Rp=class extends Za{constructor(e,t){super(),this.readable=e,this.options=Ep.fromOptions(t),this.buffer=(0,_p.default)().messageBuffer.create(this.options.charset),this._partialMessageTimeout=1e4,this.nextMessageLength=-1,this.messageToken=0,this.readSemaphore=new w0.Semaphore(1)}set partialMessageTimeout(e){this._partialMessageTimeout=e}get partialMessageTimeout(){return this._partialMessageTimeout}listen(e){this.nextMessageLength=-1,this.messageToken=0,this.partialMessageTimer=void 0,this.callback=e;let t=this.readable.onData(r=>{this.onData(r)});return this.readable.onError(r=>this.fireError(r)),this.readable.onClose(()=>this.fireClose()),t}onData(e){for(this.buffer.append(e);;){if(this.nextMessageLength===-1){let r=this.buffer.tryReadHeaders(!0);if(!r)return;let i=r.get("content-length");if(!i){this.fireError(new Error("Header must provide a Content-Length property."));return}let o=parseInt(i);if(isNaN(o)){this.fireError(new Error("Content-Length value must be a number."));return}this.nextMessageLength=o}let t=this.buffer.tryReadBody(this.nextMessageLength);if(t===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{let r=this.options.contentDecoder!==void 0?await this.options.contentDecoder.decode(t):t,i=await this.options.contentTypeDecoder.decode(r,this.options);this.callback(i)}).catch(r=>{this.fireError(r)})}}clearPartialMessageTimer(){this.partialMessageTimer&&(this.partialMessageTimer.dispose(),this.partialMessageTimer=void 0)}setPartialMessageTimer(){this.clearPartialMessageTimer(),!(this._partialMessageTimeout<=0)&&(this.partialMessageTimer=(0,_p.default)().timer.setTimeout((e,t)=>{this.partialMessageTimer=void 0,e===this.messageToken&&(this.firePartialMessage({messageToken:e,waitingTime:t}),this.setPartialMessageTimer())},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout))}};nr.ReadableStreamMessageReader=Rp});var Zy=w(rr=>{"use strict";h();Object.defineProperty(rr,"__esModule",{value:!0});rr.WriteableStreamMessageWriter=rr.AbstractMessageWriter=rr.MessageWriter=void 0;var Xy=Fr(),ps=Ui(),x0=Cp(),Yy=ji(),k0="Content-Length: ",Qy=`\r
2
2
  `,C0;(function(n){function e(t){let r=t;return r&&ps.func(r.dispose)&&ps.func(r.onClose)&&ps.func(r.onError)&&ps.func(r.write)}n.is=e})(C0=rr.MessageWriter||(rr.MessageWriter={}));var el=class{constructor(){this.errorEmitter=new Yy.Emitter,this.closeEmitter=new Yy.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e,t,r){this.errorEmitter.fire([this.asError(e),t,r])}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}asError(e){return e instanceof Error?e:new Error(`Writer received error. Reason: ${ps.string(e.message)?e.message:"unknown"}`)}};rr.AbstractMessageWriter=el;var Dp;(function(n){function e(t){return t===void 0||typeof t=="string"?{charset:t??"utf-8",contentTypeEncoder:(0,Xy.default)().applicationJson.encoder}:{charset:t.charset??"utf-8",contentEncoder:t.contentEncoder,contentTypeEncoder:t.contentTypeEncoder??(0,Xy.default)().applicationJson.encoder}}n.fromOptions=e})(Dp||(Dp={}));var Fp=class extends el{constructor(e,t){super(),this.writable=e,this.options=Dp.fromOptions(t),this.errorCount=0,this.writeSemaphore=new x0.Semaphore(1),this.writable.onError(r=>this.fireError(r)),this.writable.onClose(()=>this.fireClose())}async write(e){return this.writeSemaphore.lock(async()=>this.options.contentTypeEncoder.encode(e,this.options).then(r=>this.options.contentEncoder!==void 0?this.options.contentEncoder.encode(r):r).then(r=>{let i=[];return i.push(k0,r.byteLength.toString(),Qy),i.push(Qy),this.doWrite(e,i,r)},r=>{throw this.fireError(r),r}))}async doWrite(e,t,r){try{return await this.writable.write(t.join(""),"ascii"),this.writable.write(r)}catch(i){return this.handleError(i,e),Promise.reject(i)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){this.writable.end()}};rr.WriteableStreamMessageWriter=Fp});var ew=w(tl=>{"use strict";h();Object.defineProperty(tl,"__esModule",{value:!0});tl.AbstractMessageBuffer=void 0;var T0=13,_0=10,E0=`\r
3
3
  `,Pp=class{constructor(e="utf-8"){this._encoding=e,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(e){let t=typeof e=="string"?this.fromString(e,this._encoding):e;this._chunks.push(t),this._totalLength+=t.byteLength}tryReadHeaders(e=!1){if(this._chunks.length===0)return;let t=0,r=0,i=0,o=0;e:for(;r<this._chunks.length;){let c=this._chunks[r];for(i=0;i<c.length;){switch(c[i]){case T0:switch(t){case 0:t=1;break;case 2:t=3;break;default:t=0}break;case _0:switch(t){case 1:t=2;break;case 3:t=4,i++;break e;default:t=0}break;default:t=0}i++}o+=c.byteLength,r++}if(t!==4)return;let s=this._read(o+i),a=new Map,l=this.toString(s,"ascii").split(E0);if(l.length<2)return a;for(let c=0;c<l.length-2;c++){let d=l[c],p=d.indexOf(":");if(p===-1)throw new Error("Message header must separate key and value using :");let m=d.substr(0,p),g=d.substr(p+1).trim();a.set(e?m.toLowerCase():m,g)}return a}tryReadBody(e){if(!(this._totalLength<e))return this._read(e)}get numberOfBytes(){return this._totalLength}_read(e){if(e===0)return this.emptyBuffer();if(e>this._totalLength)throw new Error("Cannot read so many bytes!");if(this._chunks[0].byteLength===e){let o=this._chunks[0];return this._chunks.shift(),this._totalLength-=e,this.asNative(o)}if(this._chunks[0].byteLength>e){let o=this._chunks[0],s=this.asNative(o,e);return this._chunks[0]=o.slice(e),this._totalLength-=e,s}let t=this.allocNative(e),r=0,i=0;for(;e>0;){let o=this._chunks[i];if(o.byteLength>e){let s=o.slice(0,e);t.set(s,r),r+=e,this._chunks[i]=o.slice(e),this._totalLength-=e,e-=e}else t.set(o,r),r+=o.byteLength,this._chunks.shift(),this._totalLength-=o.byteLength,e-=o.byteLength}return t}};tl.AbstractMessageBuffer=Pp});var aw=w(j=>{"use strict";h();Object.defineProperty(j,"__esModule",{value:!0});j.createMessageConnection=j.ConnectionOptions=j.MessageStrategy=j.CancellationStrategy=j.CancellationSenderStrategy=j.CancellationReceiverStrategy=j.RequestCancellationReceiverStrategy=j.IdCancellationReceiverStrategy=j.ConnectionStrategy=j.ConnectionError=j.ConnectionErrors=j.LogTraceNotification=j.SetTraceNotification=j.TraceFormat=j.TraceValues=j.Trace=j.NullLogger=j.ProgressType=j.ProgressToken=void 0;var tw=Fr(),Me=Ui(),X=cp(),nw=hp(),ms=ji(),Mp=Ya(),gs;(function(n){n.type=new X.NotificationType("$/cancelRequest")})(gs||(gs={}));var rw;(function(n){function e(t){return typeof t=="string"||typeof t=="number"}n.is=e})(rw=j.ProgressToken||(j.ProgressToken={}));var fs;(function(n){n.type=new X.NotificationType("$/progress")})(fs||(fs={}));var Ip=class{constructor(){}};j.ProgressType=Ip;var Np;(function(n){function e(t){return Me.func(t)}n.is=e})(Np||(Np={}));j.NullLogger=Object.freeze({error:()=>{},warn:()=>{},info:()=>{},log:()=>{}});var ge;(function(n){n[n.Off=0]="Off",n[n.Messages=1]="Messages",n[n.Compact=2]="Compact",n[n.Verbose=3]="Verbose"})(ge=j.Trace||(j.Trace={}));var R0;(function(n){n.Off="off",n.Messages="messages",n.Compact="compact",n.Verbose="verbose"})(R0=j.TraceValues||(j.TraceValues={}));(function(n){function e(r){if(!Me.string(r))return n.Off;switch(r=r.toLowerCase(),r){case"off":return n.Off;case"messages":return n.Messages;case"compact":return n.Compact;case"verbose":return n.Verbose;default:return n.Off}}n.fromString=e;function t(r){switch(r){case n.Off:return"off";case n.Messages:return"messages";case n.Compact:return"compact";case n.Verbose:return"verbose";default:return"off"}}n.toString=t})(ge=j.Trace||(j.Trace={}));var cn;(function(n){n.Text="text",n.JSON="json"})(cn=j.TraceFormat||(j.TraceFormat={}));(function(n){function e(t){return Me.string(t)?(t=t.toLowerCase(),t==="json"?n.JSON:n.Text):n.Text}n.fromString=e})(cn=j.TraceFormat||(j.TraceFormat={}));var iw;(function(n){n.type=new X.NotificationType("$/setTrace")})(iw=j.SetTraceNotification||(j.SetTraceNotification={}));var zp;(function(n){n.type=new X.NotificationType("$/logTrace")})(zp=j.LogTraceNotification||(j.LogTraceNotification={}));var nl;(function(n){n[n.Closed=1]="Closed",n[n.Disposed=2]="Disposed",n[n.AlreadyListening=3]="AlreadyListening"})(nl=j.ConnectionErrors||(j.ConnectionErrors={}));var Vi=class n extends Error{constructor(e,t){super(t),this.code=e,Object.setPrototypeOf(this,n.prototype)}};j.ConnectionError=Vi;var ow;(function(n){function e(t){let r=t;return r&&Me.func(r.cancelUndispatched)}n.is=e})(ow=j.ConnectionStrategy||(j.ConnectionStrategy={}));var Lp;(function(n){function e(t){let r=t;return r&&(r.kind===void 0||r.kind==="id")&&Me.func(r.createCancellationTokenSource)&&(r.dispose===void 0||Me.func(r.dispose))}n.is=e})(Lp=j.IdCancellationReceiverStrategy||(j.IdCancellationReceiverStrategy={}));var sw;(function(n){function e(t){let r=t;return r&&r.kind==="request"&&Me.func(r.createCancellationTokenSource)&&(r.dispose===void 0||Me.func(r.dispose))}n.is=e})(sw=j.RequestCancellationReceiverStrategy||(j.RequestCancellationReceiverStrategy={}));var Op;(function(n){n.Message=Object.freeze({createCancellationTokenSource(t){return new Mp.CancellationTokenSource}});function e(t){return Lp.is(t)||sw.is(t)}n.is=e})(Op=j.CancellationReceiverStrategy||(j.CancellationReceiverStrategy={}));var Ap;(function(n){n.Message=Object.freeze({sendCancellation(t,r){return t.sendNotification(gs.type,{id:r})},cleanup(t){}});function e(t){let r=t;return r&&Me.func(r.sendCancellation)&&Me.func(r.cleanup)}n.is=e})(Ap=j.CancellationSenderStrategy||(j.CancellationSenderStrategy={}));var qp;(function(n){n.Message=Object.freeze({receiver:Op.Message,sender:Ap.Message});function e(t){let r=t;return r&&Op.is(r.receiver)&&Ap.is(r.sender)}n.is=e})(qp=j.CancellationStrategy||(j.CancellationStrategy={}));var Wp;(function(n){function e(t){let r=t;return r&&Me.func(r.handleMessage)}n.is=e})(Wp=j.MessageStrategy||(j.MessageStrategy={}));var D0;(function(n){function e(t){let r=t;return r&&(qp.is(r.cancellationStrategy)||ow.is(r.connectionStrategy)||Wp.is(r.messageStrategy))}n.is=e})(D0=j.ConnectionOptions||(j.ConnectionOptions={}));var dn;(function(n){n[n.New=1]="New",n[n.Listening=2]="Listening",n[n.Closed=3]="Closed",n[n.Disposed=4]="Disposed"})(dn||(dn={}));function F0(n,e,t,r){let i=t!==void 0?t:j.NullLogger,o=0,s=0,a=0,l="2.0",c,d=new Map,p,m=new Map,g=new Map,S,F=new nw.LinkedMap,P=new Map,I=new Set,x=new Map,y=ge.Off,R=cn.Text,O,W=dn.New,ke=new ms.Emitter,Fe=new ms.Emitter,jt=new ms.Emitter,Mt=new ms.Emitter,Tt=new ms.Emitter,_t=r&&r.cancellationStrategy?r.cancellationStrategy:qp.Message;function Pn(v){if(v===null)throw new Error("Can't send requests with id null since the response can't be correlated.");return"req-"+v.toString()}function ci(v){return v===null?"res-unknown-"+(++a).toString():"res-"+v.toString()}function $t(){return"not-"+(++s).toString()}function It(v,D){X.Message.isRequest(D)?v.set(Pn(D.id),D):X.Message.isResponse(D)?v.set(ci(D.id),D):v.set($t(),D)}function Er(v){}function Bt(){return W===dn.Listening}function Mn(){return W===dn.Closed}function Ye(){return W===dn.Disposed}function Rr(){(W===dn.New||W===dn.Listening)&&(W=dn.Closed,Fe.fire(void 0))}function is(v){ke.fire([v,void 0,void 0])}function Ai(v){ke.fire(v)}n.onClose(Rr),n.onError(is),e.onClose(Rr),e.onError(Ai);function Li(){S||F.size===0||(S=(0,tw.default)().timer.setImmediate(()=>{S=void 0,Nu()}))}function qi(v){X.Message.isRequest(v)?zu(v):X.Message.isNotification(v)?Au(v):X.Message.isResponse(v)?Ou(v):Aa(v)}function Nu(){if(F.size===0)return;let v=F.shift();try{let D=r?.messageStrategy;Wp.is(D)?D.handleMessage(v,qi):qi(v)}finally{Li()}}let di=v=>{try{if(X.Message.isNotification(v)&&v.method===gs.type.method){let D=v.params.id,z=Pn(D),U=F.get(z);if(X.Message.isRequest(U)){let be=r?.connectionStrategy,ze=be&&be.cancelUndispatched?be.cancelUndispatched(U,Er):void 0;if(ze&&(ze.error!==void 0||ze.result!==void 0)){F.delete(z),x.delete(D),ze.id=U.id,K(ze,v.method,Date.now()),e.write(ze).catch(()=>i.error("Sending response for canceled message failed."));return}}let Ce=x.get(D);if(Ce!==void 0){Ce.cancel(),Et(v);return}else I.add(D)}It(F,v)}finally{Li()}};function zu(v){if(Ye())return;function D(ce,Pe,fe){let Ve={jsonrpc:l,id:v.id};ce instanceof X.ResponseError?Ve.error=ce.toJson():Ve.result=ce===void 0?null:ce,K(Ve,Pe,fe),e.write(Ve).catch(()=>i.error("Sending response failed."))}function z(ce,Pe,fe){let Ve={jsonrpc:l,id:v.id,error:ce.toJson()};K(Ve,Pe,fe),e.write(Ve).catch(()=>i.error("Sending response failed."))}function U(ce,Pe,fe){ce===void 0&&(ce=null);let Ve={jsonrpc:l,id:v.id,result:ce};K(Ve,Pe,fe),e.write(Ve).catch(()=>i.error("Sending response failed."))}De(v);let Ce=d.get(v.method),be,ze;Ce&&(be=Ce.type,ze=Ce.handler);let Ae=Date.now();if(ze||c){let ce=v.id??String(Date.now()),Pe=Lp.is(_t.receiver)?_t.receiver.createCancellationTokenSource(ce):_t.receiver.createCancellationTokenSource(v);v.id!==null&&I.has(v.id)&&Pe.cancel(),v.id!==null&&x.set(ce,Pe);try{let fe;if(ze)if(v.params===void 0){if(be!==void 0&&be.numberOfParams!==0){z(new X.ResponseError(X.ErrorCodes.InvalidParams,`Request ${v.method} defines ${be.numberOfParams} params but received none.`),v.method,Ae);return}fe=ze(Pe.token)}else if(Array.isArray(v.params)){if(be!==void 0&&be.parameterStructures===X.ParameterStructures.byName){z(new X.ResponseError(X.ErrorCodes.InvalidParams,`Request ${v.method} defines parameters by name but received parameters by position`),v.method,Ae);return}fe=ze(...v.params,Pe.token)}else{if(be!==void 0&&be.parameterStructures===X.ParameterStructures.byPosition){z(new X.ResponseError(X.ErrorCodes.InvalidParams,`Request ${v.method} defines parameters by position but received parameters by name`),v.method,Ae);return}fe=ze(v.params,Pe.token)}else c&&(fe=c(v.method,v.params,Pe.token));let Ve=fe;fe?Ve.then?Ve.then(ft=>{x.delete(ce),D(ft,v.method,Ae)},ft=>{x.delete(ce),ft instanceof X.ResponseError?z(ft,v.method,Ae):ft&&Me.string(ft.message)?z(new X.ResponseError(X.ErrorCodes.InternalError,`Request ${v.method} failed with message: ${ft.message}`),v.method,Ae):z(new X.ResponseError(X.ErrorCodes.InternalError,`Request ${v.method} failed unexpectedly without providing any details.`),v.method,Ae)}):(x.delete(ce),D(fe,v.method,Ae)):(x.delete(ce),U(fe,v.method,Ae))}catch(fe){x.delete(ce),fe instanceof X.ResponseError?D(fe,v.method,Ae):fe&&Me.string(fe.message)?z(new X.ResponseError(X.ErrorCodes.InternalError,`Request ${v.method} failed with message: ${fe.message}`),v.method,Ae):z(new X.ResponseError(X.ErrorCodes.InternalError,`Request ${v.method} failed unexpectedly without providing any details.`),v.method,Ae)}}else z(new X.ResponseError(X.ErrorCodes.MethodNotFound,`Unhandled method ${v.method}`),v.method,Ae)}function Ou(v){if(!Ye())if(v.id===null)v.error?i.error(`Received response message without id: Error is:
4
4
  ${JSON.stringify(v.error,void 0,4)}`):i.error("Received response message without id. No further error information provided.");else{let D=v.id,z=P.get(D);if(Z_(v,z),z!==void 0){P.delete(D);try{if(v.error){let U=v.error;z.reject(new X.ResponseError(U.code,U.message,U.data))}else if(v.result!==void 0)z.resolve(v.result);else throw new Error("Should never happen.")}catch(U){U.message?i.error(`Response handler '${z.method}' failed with message: ${U.message}`):i.error(`Response handler '${z.method}' failed unexpectedly.`)}}}}function Au(v){if(Ye())return;let D,z;if(v.method===gs.type.method){let U=v.params.id;I.delete(U),Et(v);return}else{let U=m.get(v.method);U&&(z=U.handler,D=U.type)}if(z||p)try{if(Et(v),z)if(v.params===void 0)D!==void 0&&D.numberOfParams!==0&&D.parameterStructures!==X.ParameterStructures.byName&&i.error(`Notification ${v.method} defines ${D.numberOfParams} params but received none.`),z();else if(Array.isArray(v.params)){let U=v.params;v.method===fs.type.method&&U.length===2&&rw.is(U[0])?z({token:U[0],value:U[1]}):(D!==void 0&&(D.parameterStructures===X.ParameterStructures.byName&&i.error(`Notification ${v.method} defines parameters by name but received parameters by position`),D.numberOfParams!==v.params.length&&i.error(`Notification ${v.method} defines ${D.numberOfParams} params but received ${U.length} arguments`)),z(...U))}else D!==void 0&&D.parameterStructures===X.ParameterStructures.byPosition&&i.error(`Notification ${v.method} defines parameters by position but received parameters by name`),z(v.params);else p&&p(v.method,v.params)}catch(U){U.message?i.error(`Notification handler '${v.method}' failed with message: ${U.message}`):i.error(`Notification handler '${v.method}' failed unexpectedly.`)}else jt.fire(v)}function Aa(v){if(!v){i.error("Received empty message.");return}i.error(`Received message which is neither a response nor a notification message:
@@ -0,0 +1 @@
1
+ import{a as t}from"./chunk-BN7ZXAZJ.js";import{b as e}from"./chunk-FZCGRIOM.js";import{g as n}from"./chunk-VKWPEFWQ.js";n();var o=e.object({url:e.string().url().describe("The requested shopify.dev document URL."),content:e.string().describe("The document in Markdown, with the requested language filter applied.")}).strict(),c=e.object({path:e.string().regex(/^(?:\/|[A-Za-z]:[\\/]|\\\\)/).describe("The absolute native path of the written file."),format:e.literal("markdown").describe("The file contains the original Markdown document, not a JSON wrapper.")}).strict(),u=t({name:"DocFetchResult",schema:e.union([e.object({document:o}).strict(),c]),definitions:{Document:o,DocumentFile:c}}),r=e.object({score:e.number().finite().describe("The relevance score returned by shopify.dev."),content:e.string().describe("The matching documentation chunk."),url:e.string().url().describe("The URL of the matching document."),title:e.string().describe("The title of the matching document."),domain:e.string().nullable().describe("The documentation domain, or null when unavailable.")}).strict(),a=e.object({hasNextPage:e.boolean().nullable().describe("Whether more results are available, or null when unknown.")}).strict(),h=t({name:"DocSearchResult",schema:e.object({results:e.array(r).describe("The top matching chunks from one search request."),pageInfo:a}).strict(),definitions:{DocumentationSearchEntry:r,PageInfo:a}});export{u as a,r as b,h as c};
@@ -1 +1 @@
1
- import{d as l}from"./chunk-LYIXRMQJ.js";import{c as t}from"./chunk-YY6TFARF.js";import{f as i,m,n as w,o as d,r as f}from"./chunk-Y3PY5LP7.js";import{J as n}from"./chunk-47IQIIFX.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();async function y(o,r,P){i()||f({store:r});let e=o??m()??await p(["Enter your",{link:{label:"store password",url:t(r)}}]),s=!1;for(;!await l(e,r,P);)s||(d(),s=!0),e=await p(["Incorrect",{link:{label:"store password",url:t(r)}},{char:"."},"Please try again"]);return w(e),e}async function p(o){return n({message:o,password:!0})}export{y as a};
1
+ import{d as l}from"./chunk-DNMXVMJM.js";import{c as t}from"./chunk-YY6TFARF.js";import{f as i,m,n as w,o as d,r as f}from"./chunk-DJAZBPYA.js";import{K as n}from"./chunk-CZ22VZDA.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();async function y(o,r,P){i()||f({store:r});let e=o??m()??await p(["Enter your",{link:{label:"store password",url:t(r)}}]),s=!1;for(;!await l(e,r,P);)s||(d(),s=!0),e=await p(["Incorrect",{link:{label:"store password",url:t(r)}},{char:"."},"Please try again"]);return w(e),e}async function p(o){return n({message:o,password:!0})}export{y as a};
@@ -1 +1 @@
1
- import{b as n}from"./chunk-4ZNBEMRT.js";import{y as t}from"./chunk-47IQIIFX.js";import{k as r}from"./chunk-UEBUGSBT.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var e=class extends n{static description="Run CLI doctor-release tests";static hidden=!0;async run(){r()&&t({headline:"Shopify CLI Doctor Release.",body:["Available doctor-release commands:",""," shopify doctor-release theme -e <environment> Run all theme command tests","","The -e/--environment flag is required to specify the store configuration.","Use --help with any command for more options."]})}};export{e as a};
1
+ import{b as n}from"./chunk-ZQDDRIBA.js";import{z as t}from"./chunk-CZ22VZDA.js";import{k as r}from"./chunk-3A3DZVEJ.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var e=class extends n{static description="Run CLI doctor-release tests";static hidden=!0;async run(){r()&&t({headline:"Shopify CLI Doctor Release.",body:["Available doctor-release commands:",""," shopify doctor-release theme -e <environment> Run all theme command tests","","The -e/--environment flag is required to specify the store configuration.","Use --help with any command for more options."]})}};export{e as a};
@@ -1,4 +1,4 @@
1
- import{a as p}from"./chunk-UWI76E2L.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();a();a();var j=Symbol("Let zodToJsonSchema decide on which parser to use");var T={name:void 0,$refStrategy:"root",basePath:["#"],effectStrategy:"input",pipeStrategy:"all",dateStrategy:"format:date-time",mapStrategy:"entries",removeAdditionalStrategy:"passthrough",allowedAdditionalProperties:!0,rejectedAdditionalProperties:!1,definitionPath:"definitions",target:"jsonSchema7",strictUnions:!1,definitions:{},errorMessages:!1,markdownDescription:!1,patternStrategy:"escape",applyRegexFlags:!1,emailStrategy:"format:email",base64Strategy:"contentEncoding:base64",nameStrategy:"ref",openAiAnyTypeName:"OpenAiAnyType"},N=e=>typeof e=="string"?{...T,name:e}:{...T,...e};a();var M=e=>{let t=N(e),r=t.name!==void 0?[...t.basePath,t.definitionPath,t.name]:t.basePath;return{...t,flags:{hasReferencedOpenAiAnyType:!1},currentPath:r,propertyPath:void 0,seen:new Map(Object.entries(t.definitions).map(([n,i])=>[i._def,{def:i._def,path:[...t.basePath,t.definitionPath,n],jsonSchema:void 0}]))}};a();function k(e,t,r,n){n?.errorMessages&&r&&(e.errorMessage={...e.errorMessage,[t]:r})}function m(e,t,r,n,i){e[t]=r,k(e,t,n,i)}a();var A=(e,t)=>{let r=0;for(;r<e.length&&r<t.length&&e[r]===t[r];r++);return[(e.length-r).toString(),...t.slice(r)].join("/")};a();a();a();function f(e){if(e.target!=="openAi")return{};let t=[...e.basePath,e.definitionPath,e.openAiAnyTypeName];return e.flags.hasReferencedOpenAiAnyType=!0,{$ref:e.$refStrategy==="relative"?A(t,e.currentPath):t.join("/")}}a();function $(e,t){let r={type:"array"};return e.type?._def&&e.type?._def?.typeName!==p.ZodAny&&(r.items=o(e.type._def,{...t,currentPath:[...t.currentPath,"items"]})),e.minLength&&m(r,"minItems",e.minLength.value,e.minLength.message,t),e.maxLength&&m(r,"maxItems",e.maxLength.value,e.maxLength.message,t),e.exactLength&&(m(r,"minItems",e.exactLength.value,e.exactLength.message,t),m(r,"maxItems",e.exactLength.value,e.exactLength.message,t)),r}a();function w(e,t){let r={type:"integer",format:"int64"};if(!e.checks)return r;for(let n of e.checks)switch(n.kind){case"min":t.target==="jsonSchema7"?n.inclusive?m(r,"minimum",n.value,n.message,t):m(r,"exclusiveMinimum",n.value,n.message,t):(n.inclusive||(r.exclusiveMinimum=!0),m(r,"minimum",n.value,n.message,t));break;case"max":t.target==="jsonSchema7"?n.inclusive?m(r,"maximum",n.value,n.message,t):m(r,"exclusiveMaximum",n.value,n.message,t):(n.inclusive||(r.exclusiveMaximum=!0),m(r,"maximum",n.value,n.message,t));break;case"multipleOf":m(r,"multipleOf",n.value,n.message,t);break}return r}a();function E(){return{type:"boolean"}}a();function v(e,t){return o(e.type._def,t)}a();var z=(e,t)=>o(e.innerType._def,t);a();function _(e,t,r){let n=r??t.dateStrategy;if(Array.isArray(n))return{anyOf:n.map((i,s)=>_(e,t,i))};switch(n){case"string":case"format:date-time":return{type:"string",format:"date-time"};case"format:date":return{type:"string",format:"date"};case"integer":return se(e,t)}}var se=(e,t)=>{let r={type:"integer",format:"unix-time"};if(t.target==="openApi3")return r;for(let n of e.checks)switch(n.kind){case"min":m(r,"minimum",n.value,n.message,t);break;case"max":m(r,"maximum",n.value,n.message,t);break}return r};a();function R(e,t){return{...o(e.innerType._def,t),default:e.defaultValue()}}a();function L(e,t){return t.effectStrategy==="input"?o(e.schema._def,t):f(t)}a();function F(e){return{type:"string",enum:Array.from(e.values)}}a();var pe=e=>"type"in e&&e.type==="string"?!1:"allOf"in e;function I(e,t){let r=[o(e.left._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),o(e.right._def,{...t,currentPath:[...t.currentPath,"allOf","1"]})].filter(s=>!!s),n=t.target==="jsonSchema2019-09"?{unevaluatedProperties:!1}:void 0,i=[];return r.forEach(s=>{if(pe(s))i.push(...s.allOf),s.unevaluatedProperties===void 0&&(n=void 0);else{let c=s;if("additionalProperties"in s&&s.additionalProperties===!1){let{additionalProperties:l,...u}=s;c=u}else n=void 0;i.push(c)}}),i.length?{allOf:i,...n}:void 0}a();function C(e,t){let r=typeof e.value;return r!=="bigint"&&r!=="number"&&r!=="boolean"&&r!=="string"?{type:Array.isArray(e.value)?"array":"object"}:t.target==="openApi3"?{type:r==="bigint"?"integer":r,enum:[e.value]}:{type:r==="bigint"?"integer":r,const:e.value}}a();a();a();var S,g={cuid:/^[cC][^\s-]{8,}$/,cuid2:/^[0-9a-z]+$/,ulid:/^[0-9A-HJKMNP-TV-Z]{26}$/,email:/^(?!\.)(?!.*\.\.)([a-zA-Z0-9_'+\-\.]*)[a-zA-Z0-9_+-]@([a-zA-Z0-9][a-zA-Z0-9\-]*\.)+[a-zA-Z]{2,}$/,emoji:()=>(S===void 0&&(S=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),S),uuid:/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/,ipv4:/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,ipv4Cidr:/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,ipv6:/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,ipv6Cidr:/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,base64:/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,base64url:/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,nanoid:/^[a-zA-Z0-9_-]{21}$/,jwt:/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/};function P(e,t){let r={type:"string"};if(e.checks)for(let n of e.checks)switch(n.kind){case"min":m(r,"minLength",typeof r.minLength=="number"?Math.max(r.minLength,n.value):n.value,n.message,t);break;case"max":m(r,"maxLength",typeof r.maxLength=="number"?Math.min(r.maxLength,n.value):n.value,n.message,t);break;case"email":switch(t.emailStrategy){case"format:email":y(r,"email",n.message,t);break;case"format:idn-email":y(r,"idn-email",n.message,t);break;case"pattern:zod":d(r,g.email,n.message,t);break}break;case"url":y(r,"uri",n.message,t);break;case"uuid":y(r,"uuid",n.message,t);break;case"regex":d(r,n.regex,n.message,t);break;case"cuid":d(r,g.cuid,n.message,t);break;case"cuid2":d(r,g.cuid2,n.message,t);break;case"startsWith":d(r,RegExp(`^${Z(n.value,t)}`),n.message,t);break;case"endsWith":d(r,RegExp(`${Z(n.value,t)}$`),n.message,t);break;case"datetime":y(r,"date-time",n.message,t);break;case"date":y(r,"date",n.message,t);break;case"time":y(r,"time",n.message,t);break;case"duration":y(r,"duration",n.message,t);break;case"length":m(r,"minLength",typeof r.minLength=="number"?Math.max(r.minLength,n.value):n.value,n.message,t),m(r,"maxLength",typeof r.maxLength=="number"?Math.min(r.maxLength,n.value):n.value,n.message,t);break;case"includes":{d(r,RegExp(Z(n.value,t)),n.message,t);break}case"ip":{n.version!=="v6"&&y(r,"ipv4",n.message,t),n.version!=="v4"&&y(r,"ipv6",n.message,t);break}case"base64url":d(r,g.base64url,n.message,t);break;case"jwt":d(r,g.jwt,n.message,t);break;case"cidr":{n.version!=="v6"&&d(r,g.ipv4Cidr,n.message,t),n.version!=="v4"&&d(r,g.ipv6Cidr,n.message,t);break}case"emoji":d(r,g.emoji(),n.message,t);break;case"ulid":{d(r,g.ulid,n.message,t);break}case"base64":{switch(t.base64Strategy){case"format:binary":{y(r,"binary",n.message,t);break}case"contentEncoding:base64":{m(r,"contentEncoding","base64",n.message,t);break}case"pattern:zod":{d(r,g.base64,n.message,t);break}}break}case"nanoid":d(r,g.nanoid,n.message,t);case"toLowerCase":case"toUpperCase":case"trim":break;default:}return r}function Z(e,t){return t.patternStrategy==="escape"?me(e):e}var ue=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function me(e){let t="";for(let r=0;r<e.length;r++)ue.has(e[r])||(t+="\\"),t+=e[r];return t}function y(e,t,r,n){e.format||e.anyOf?.some(i=>i.format)?(e.anyOf||(e.anyOf=[]),e.format&&(e.anyOf.push({format:e.format,...e.errorMessage&&n.errorMessages&&{errorMessage:{format:e.errorMessage.format}}}),delete e.format,e.errorMessage&&(delete e.errorMessage.format,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.anyOf.push({format:t,...r&&n.errorMessages&&{errorMessage:{format:r}}})):m(e,"format",t,r,n)}function d(e,t,r,n){e.pattern||e.allOf?.some(i=>i.pattern)?(e.allOf||(e.allOf=[]),e.pattern&&(e.allOf.push({pattern:e.pattern,...e.errorMessage&&n.errorMessages&&{errorMessage:{pattern:e.errorMessage.pattern}}}),delete e.pattern,e.errorMessage&&(delete e.errorMessage.pattern,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.allOf.push({pattern:U(t,n),...r&&n.errorMessages&&{errorMessage:{pattern:r}}})):m(e,"pattern",U(t,n),r,n)}function U(e,t){if(!t.applyRegexFlags||!e.flags)return e.source;let r={i:e.flags.includes("i"),m:e.flags.includes("m"),s:e.flags.includes("s")},n=r.i?e.source.toLowerCase():e.source,i="",s=!1,c=!1,l=!1;for(let u=0;u<n.length;u++){if(s){i+=n[u],s=!1;continue}if(r.i){if(c){if(n[u].match(/[a-z]/)){l?(i+=n[u],i+=`${n[u-2]}-${n[u]}`.toUpperCase(),l=!1):n[u+1]==="-"&&n[u+2]?.match(/[a-z]/)?(i+=n[u],l=!0):i+=`${n[u]}${n[u].toUpperCase()}`;continue}}else if(n[u].match(/[a-z]/)){i+=`[${n[u]}${n[u].toUpperCase()}]`;continue}}if(r.m){if(n[u]==="^"){i+=`(^|(?<=[\r
1
+ import{a as p}from"./chunk-FZCGRIOM.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();a();a();var j=Symbol("Let zodToJsonSchema decide on which parser to use");var T={name:void 0,$refStrategy:"root",basePath:["#"],effectStrategy:"input",pipeStrategy:"all",dateStrategy:"format:date-time",mapStrategy:"entries",removeAdditionalStrategy:"passthrough",allowedAdditionalProperties:!0,rejectedAdditionalProperties:!1,definitionPath:"definitions",target:"jsonSchema7",strictUnions:!1,definitions:{},errorMessages:!1,markdownDescription:!1,patternStrategy:"escape",applyRegexFlags:!1,emailStrategy:"format:email",base64Strategy:"contentEncoding:base64",nameStrategy:"ref",openAiAnyTypeName:"OpenAiAnyType"},N=e=>typeof e=="string"?{...T,name:e}:{...T,...e};a();var M=e=>{let t=N(e),r=t.name!==void 0?[...t.basePath,t.definitionPath,t.name]:t.basePath;return{...t,flags:{hasReferencedOpenAiAnyType:!1},currentPath:r,propertyPath:void 0,seen:new Map(Object.entries(t.definitions).map(([n,i])=>[i._def,{def:i._def,path:[...t.basePath,t.definitionPath,n],jsonSchema:void 0}]))}};a();function k(e,t,r,n){n?.errorMessages&&r&&(e.errorMessage={...e.errorMessage,[t]:r})}function m(e,t,r,n,i){e[t]=r,k(e,t,n,i)}a();var A=(e,t)=>{let r=0;for(;r<e.length&&r<t.length&&e[r]===t[r];r++);return[(e.length-r).toString(),...t.slice(r)].join("/")};a();a();a();function f(e){if(e.target!=="openAi")return{};let t=[...e.basePath,e.definitionPath,e.openAiAnyTypeName];return e.flags.hasReferencedOpenAiAnyType=!0,{$ref:e.$refStrategy==="relative"?A(t,e.currentPath):t.join("/")}}a();function $(e,t){let r={type:"array"};return e.type?._def&&e.type?._def?.typeName!==p.ZodAny&&(r.items=o(e.type._def,{...t,currentPath:[...t.currentPath,"items"]})),e.minLength&&m(r,"minItems",e.minLength.value,e.minLength.message,t),e.maxLength&&m(r,"maxItems",e.maxLength.value,e.maxLength.message,t),e.exactLength&&(m(r,"minItems",e.exactLength.value,e.exactLength.message,t),m(r,"maxItems",e.exactLength.value,e.exactLength.message,t)),r}a();function w(e,t){let r={type:"integer",format:"int64"};if(!e.checks)return r;for(let n of e.checks)switch(n.kind){case"min":t.target==="jsonSchema7"?n.inclusive?m(r,"minimum",n.value,n.message,t):m(r,"exclusiveMinimum",n.value,n.message,t):(n.inclusive||(r.exclusiveMinimum=!0),m(r,"minimum",n.value,n.message,t));break;case"max":t.target==="jsonSchema7"?n.inclusive?m(r,"maximum",n.value,n.message,t):m(r,"exclusiveMaximum",n.value,n.message,t):(n.inclusive||(r.exclusiveMaximum=!0),m(r,"maximum",n.value,n.message,t));break;case"multipleOf":m(r,"multipleOf",n.value,n.message,t);break}return r}a();function E(){return{type:"boolean"}}a();function v(e,t){return o(e.type._def,t)}a();var z=(e,t)=>o(e.innerType._def,t);a();function _(e,t,r){let n=r??t.dateStrategy;if(Array.isArray(n))return{anyOf:n.map((i,s)=>_(e,t,i))};switch(n){case"string":case"format:date-time":return{type:"string",format:"date-time"};case"format:date":return{type:"string",format:"date"};case"integer":return se(e,t)}}var se=(e,t)=>{let r={type:"integer",format:"unix-time"};if(t.target==="openApi3")return r;for(let n of e.checks)switch(n.kind){case"min":m(r,"minimum",n.value,n.message,t);break;case"max":m(r,"maximum",n.value,n.message,t);break}return r};a();function R(e,t){return{...o(e.innerType._def,t),default:e.defaultValue()}}a();function L(e,t){return t.effectStrategy==="input"?o(e.schema._def,t):f(t)}a();function F(e){return{type:"string",enum:Array.from(e.values)}}a();var pe=e=>"type"in e&&e.type==="string"?!1:"allOf"in e;function I(e,t){let r=[o(e.left._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),o(e.right._def,{...t,currentPath:[...t.currentPath,"allOf","1"]})].filter(s=>!!s),n=t.target==="jsonSchema2019-09"?{unevaluatedProperties:!1}:void 0,i=[];return r.forEach(s=>{if(pe(s))i.push(...s.allOf),s.unevaluatedProperties===void 0&&(n=void 0);else{let c=s;if("additionalProperties"in s&&s.additionalProperties===!1){let{additionalProperties:l,...u}=s;c=u}else n=void 0;i.push(c)}}),i.length?{allOf:i,...n}:void 0}a();function C(e,t){let r=typeof e.value;return r!=="bigint"&&r!=="number"&&r!=="boolean"&&r!=="string"?{type:Array.isArray(e.value)?"array":"object"}:t.target==="openApi3"?{type:r==="bigint"?"integer":r,enum:[e.value]}:{type:r==="bigint"?"integer":r,const:e.value}}a();a();a();var S,g={cuid:/^[cC][^\s-]{8,}$/,cuid2:/^[0-9a-z]+$/,ulid:/^[0-9A-HJKMNP-TV-Z]{26}$/,email:/^(?!\.)(?!.*\.\.)([a-zA-Z0-9_'+\-\.]*)[a-zA-Z0-9_+-]@([a-zA-Z0-9][a-zA-Z0-9\-]*\.)+[a-zA-Z]{2,}$/,emoji:()=>(S===void 0&&(S=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),S),uuid:/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/,ipv4:/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,ipv4Cidr:/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,ipv6:/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,ipv6Cidr:/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,base64:/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,base64url:/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,nanoid:/^[a-zA-Z0-9_-]{21}$/,jwt:/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/};function P(e,t){let r={type:"string"};if(e.checks)for(let n of e.checks)switch(n.kind){case"min":m(r,"minLength",typeof r.minLength=="number"?Math.max(r.minLength,n.value):n.value,n.message,t);break;case"max":m(r,"maxLength",typeof r.maxLength=="number"?Math.min(r.maxLength,n.value):n.value,n.message,t);break;case"email":switch(t.emailStrategy){case"format:email":y(r,"email",n.message,t);break;case"format:idn-email":y(r,"idn-email",n.message,t);break;case"pattern:zod":d(r,g.email,n.message,t);break}break;case"url":y(r,"uri",n.message,t);break;case"uuid":y(r,"uuid",n.message,t);break;case"regex":d(r,n.regex,n.message,t);break;case"cuid":d(r,g.cuid,n.message,t);break;case"cuid2":d(r,g.cuid2,n.message,t);break;case"startsWith":d(r,RegExp(`^${Z(n.value,t)}`),n.message,t);break;case"endsWith":d(r,RegExp(`${Z(n.value,t)}$`),n.message,t);break;case"datetime":y(r,"date-time",n.message,t);break;case"date":y(r,"date",n.message,t);break;case"time":y(r,"time",n.message,t);break;case"duration":y(r,"duration",n.message,t);break;case"length":m(r,"minLength",typeof r.minLength=="number"?Math.max(r.minLength,n.value):n.value,n.message,t),m(r,"maxLength",typeof r.maxLength=="number"?Math.min(r.maxLength,n.value):n.value,n.message,t);break;case"includes":{d(r,RegExp(Z(n.value,t)),n.message,t);break}case"ip":{n.version!=="v6"&&y(r,"ipv4",n.message,t),n.version!=="v4"&&y(r,"ipv6",n.message,t);break}case"base64url":d(r,g.base64url,n.message,t);break;case"jwt":d(r,g.jwt,n.message,t);break;case"cidr":{n.version!=="v6"&&d(r,g.ipv4Cidr,n.message,t),n.version!=="v4"&&d(r,g.ipv6Cidr,n.message,t);break}case"emoji":d(r,g.emoji(),n.message,t);break;case"ulid":{d(r,g.ulid,n.message,t);break}case"base64":{switch(t.base64Strategy){case"format:binary":{y(r,"binary",n.message,t);break}case"contentEncoding:base64":{m(r,"contentEncoding","base64",n.message,t);break}case"pattern:zod":{d(r,g.base64,n.message,t);break}}break}case"nanoid":d(r,g.nanoid,n.message,t);case"toLowerCase":case"toUpperCase":case"trim":break;default:}return r}function Z(e,t){return t.patternStrategy==="escape"?me(e):e}var ue=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function me(e){let t="";for(let r=0;r<e.length;r++)ue.has(e[r])||(t+="\\"),t+=e[r];return t}function y(e,t,r,n){e.format||e.anyOf?.some(i=>i.format)?(e.anyOf||(e.anyOf=[]),e.format&&(e.anyOf.push({format:e.format,...e.errorMessage&&n.errorMessages&&{errorMessage:{format:e.errorMessage.format}}}),delete e.format,e.errorMessage&&(delete e.errorMessage.format,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.anyOf.push({format:t,...r&&n.errorMessages&&{errorMessage:{format:r}}})):m(e,"format",t,r,n)}function d(e,t,r,n){e.pattern||e.allOf?.some(i=>i.pattern)?(e.allOf||(e.allOf=[]),e.pattern&&(e.allOf.push({pattern:e.pattern,...e.errorMessage&&n.errorMessages&&{errorMessage:{pattern:e.errorMessage.pattern}}}),delete e.pattern,e.errorMessage&&(delete e.errorMessage.pattern,Object.keys(e.errorMessage).length===0&&delete e.errorMessage)),e.allOf.push({pattern:U(t,n),...r&&n.errorMessages&&{errorMessage:{pattern:r}}})):m(e,"pattern",U(t,n),r,n)}function U(e,t){if(!t.applyRegexFlags||!e.flags)return e.source;let r={i:e.flags.includes("i"),m:e.flags.includes("m"),s:e.flags.includes("s")},n=r.i?e.source.toLowerCase():e.source,i="",s=!1,c=!1,l=!1;for(let u=0;u<n.length;u++){if(s){i+=n[u],s=!1;continue}if(r.i){if(c){if(n[u].match(/[a-z]/)){l?(i+=n[u],i+=`${n[u-2]}-${n[u]}`.toUpperCase(),l=!1):n[u+1]==="-"&&n[u+2]?.match(/[a-z]/)?(i+=n[u],l=!0):i+=`${n[u]}${n[u].toUpperCase()}`;continue}}else if(n[u].match(/[a-z]/)){i+=`[${n[u]}${n[u].toUpperCase()}]`;continue}}if(r.m){if(n[u]==="^"){i+=`(^|(?<=[\r
2
2
  ]))`;continue}else if(n[u]==="$"){i+=`($|(?=[\r
3
3
  ]))`;continue}}if(r.s&&n[u]==="."){i+=c?`${n[u]}\r
4
4
  `:`[${n[u]}\r
@@ -0,0 +1,16 @@
1
+ import{b as s}from"./chunk-ZQDDRIBA.js";import{e as j}from"./chunk-ZT5WFUKJ.js";import{b as m,c as u}from"./chunk-Q2SZCZE7.js";import{D as F,F as I,z as h}from"./chunk-CZ22VZDA.js";import{a as O}from"./chunk-BN7ZXAZJ.js";import{h as v}from"./chunk-2VSNFOKD.js";import{Bb as W,wb as E}from"./chunk-LWCTKI4Z.js";import{b as S}from"./chunk-FZCGRIOM.js";import{g as n}from"./chunk-VKWPEFWQ.js";n();n();n();n();function b(o=k()){return!!o.get("autocorrectEnabled")}function N(o,r=k()){r.set("autocorrectEnabled",o)}function k(){return D??=new j({projectName:"did-you-mean"}),D}var D;function J(){return{enabled:b()}}function y(o){return N(o),{enabled:o}}n();n();var i=O({name:"AutocorrectResult",schema:S.object({enabled:S.boolean()}).strict()});n();var w={on:"Autocorrect on. The system will automatically run commands even when you mistype them.",off:"Autocorrect off. You'll need to confirm corrections for mistyped commands."};function f(o,r){if(r==="json"){E(i.encode({enabled:o.enabled}));return}h({body:o.enabled?w.on:w.off})}var d=class o extends s{static summary="Enable autocorrect. Off by default.";static descriptionWithMarkdown=`Enable autocorrect. Off by default.
2
+
3
+ When autocorrection is enabled, Shopify CLI automatically runs a corrected version of your command if a correction is available.
4
+
5
+ When autocorrection is disabled, you need to confirm that you want to run corrections for mistyped commands.
6
+ `;static description=this.descriptionForHelp();static flags={...m,...u};static get jsonOutputSchema(){return i}async run(){let{flags:r}=await this.parse(o),e=y(!0);f(e,r.json?"json":"text")}};n();var l=class o extends s{static summary="Disable autocorrect. Off by default.";static descriptionWithMarkdown=`Disable autocorrect. Off by default.
7
+
8
+ When autocorrection is enabled, Shopify CLI automatically runs a corrected version of your command if a correction is available.
9
+
10
+ When autocorrection is disabled, you need to confirm that you want to run corrections for mistyped commands.
11
+ `;static description=this.descriptionForHelp();static flags={...m,...u};static get jsonOutputSchema(){return i}async run(){let{flags:r}=await this.parse(o),e=y(!1);f(e,r.json?"json":"text")}};n();var p=class o extends s{static summary="Check whether autocorrect is enabled or disabled. On by default.";static descriptionWithMarkdown=`Check whether autocorrect is enabled or disabled. On by default.
12
+
13
+ When autocorrection is enabled, Shopify CLI automatically runs a corrected version of your command if a correction is available.
14
+
15
+ When autocorrection is disabled, you need to confirm that you want to run corrections for mistyped commands.
16
+ `;static description=this.descriptionForHelp();static flags={...m,...u};static get jsonOutputSchema(){return i}async run(){let{flags:r}=await this.parse(o),e=J();f(e,r.json?"json":"text")}};n();var A=M(2),jo=M(3);function M(o){if(typeof o!="number"||Number.isNaN(o)||o<1||o===Number.POSITIVE_INFINITY)throw new Error("`"+o+"` is not a valid argument for `n-gram`");return r;function r(e){let a=[];if(e==null)return a;let c=typeof e.slice=="function"?e:String(e),t=c.length-o+1;if(t<1)return a;for(;t--;)a[t]=c.slice(t,t+o);return a}}function x(o){return o.replace(/:/g," ")}function R(o,r){let e=new Map;for(let c of o)e.set(c,(e.get(c)??0)+1);let a=0;for(let c of r){let t=e.get(c)??0;t>0&&(a+=1,e.set(c,t-1))}return a}function H(o){if(o.id.length<2)return;let r=new Set(o.config.commands.filter(t=>t.hidden).map(t=>t.id)),e=Array.from(new Set([...o.config.commandIDs,...o.config.commands.flatMap(t=>t.aliases)].filter(t=>!r.has(t)))),a=A(o.id),c=e.map(t=>{let g=A(t);return{score:R(g,a),cmd:t}}).filter(({score:t})=>t>=2).sort((t,g)=>{let C=g.score-t.score;return C!==0?C:t.cmd.length-g.cmd.length});if(W(`'Did you mean' options: ${JSON.stringify(c)}`),c.length>0){let{cmd:t}=c[0];return t}}async function L(o,r){return b()?(h({body:["Autocorrecting",{command:x(r)},"to",{command:x(o)},{char:"."}]}),!0):I({message:["Command",{command:r},"not found. Did you mean",{command:x(o)},{char:"?"}]})}var Ro={"config:autocorrect:off":l,"config:autocorrect:status":p,"config:autocorrect:on":d},Ho=async function(o){let r=H(o),e=x(o.id);if(o.argv&&(o.argv.includes("-f")||o.argv.includes("--force"))||!r){F(new v(`Command '${e}' not found.`));return}await L(r,e)&&await this.config.runCommand(r,o.argv)};export{H as a,L as b,Ro as c,Ho as d};