shopify 5.1.0 → 5.2.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 (367) hide show
  1. package/dist/analytics-23GM6KJU.js +1 -0
  2. package/dist/analytics-743FYOAE.js +1 -0
  3. package/dist/bootstrap.js +1 -1
  4. package/dist/{chunk-HSTZV6H7.js → chunk-2EQRXSF6.js} +1 -1
  5. package/dist/{chunk-AY3AAV77.js → chunk-2IXP3IPE.js} +1 -1
  6. package/dist/{chunk-OTMYJWIP.js → chunk-2KACAQJS.js} +1 -1
  7. package/dist/{chunk-24Q6X53V.js → chunk-2OCSYLKZ.js} +1 -1
  8. package/dist/{chunk-QCLE5REL.js → chunk-2PILNMHJ.js} +1 -1
  9. package/dist/{chunk-WPDJVUTY.js → chunk-36S6MFJQ.js} +1 -1
  10. package/dist/{chunk-YNZLLZU2.js → chunk-3DB4EC62.js} +1 -1
  11. package/dist/{chunk-FQLXQ7WN.js → chunk-3GL3IT4K.js} +1 -1
  12. package/dist/{chunk-JALDNBTU.js → chunk-3JRB7Q3T.js} +1 -1
  13. package/dist/{chunk-7A77JCED.js → chunk-3OYMK5X6.js} +1 -1
  14. package/dist/{chunk-ORMXPSJM.js → chunk-422BGHXN.js} +1 -1
  15. package/dist/{chunk-ZMU4EYXT.js → chunk-43C32FUQ.js} +1 -1
  16. package/dist/{chunk-ELR6AZT4.js → chunk-4AN7ECPE.js} +1 -1
  17. package/dist/chunk-4AWVU2OV.js +1 -0
  18. package/dist/chunk-4KBOLN7Q.js +8 -0
  19. package/dist/{chunk-YYWSHRO2.js → chunk-4LJERO23.js} +3 -3
  20. package/dist/{chunk-4FWPOGPQ.js → chunk-4M5WHOZW.js} +1 -1
  21. package/dist/{chunk-OWQEFORZ.js → chunk-4RO35FFQ.js} +1 -1
  22. package/dist/{chunk-6I7DT7QR.js → chunk-4ZS5354G.js} +1 -1
  23. package/dist/{chunk-ZXZWMXXK.js → chunk-55AWBPKU.js} +1 -1
  24. package/dist/{chunk-7PHDEILV.js → chunk-5BUYR23E.js} +1 -1
  25. package/dist/{chunk-AHYI27QL.js → chunk-5EDA7PVE.js} +3 -3
  26. package/dist/{chunk-5C6CXU74.js → chunk-5P6OELKZ.js} +1 -1
  27. package/dist/{chunk-SPJM7RTD.js → chunk-5PVXLQNX.js} +1 -1
  28. package/dist/{chunk-FU7PYW7H.js → chunk-5S2P4MHJ.js} +1 -1
  29. package/dist/{chunk-SBN3ILXO.js → chunk-5TJJVSCI.js} +1 -1
  30. package/dist/{chunk-VE3IIC7H.js → chunk-5TOK5OJS.js} +1 -1
  31. package/dist/{chunk-LGDWE3H3.js → chunk-5ZG2SWU2.js} +1 -1
  32. package/dist/{chunk-DDZYIC76.js → chunk-62F4ZMSC.js} +1 -1
  33. package/dist/{chunk-4NFX7YCT.js → chunk-652NT7OW.js} +1 -1
  34. package/dist/{chunk-5534MHZW.js → chunk-6B5KM3A4.js} +1 -1
  35. package/dist/{chunk-CRQQCT7F.js → chunk-6LCESSY3.js} +1 -1
  36. package/dist/chunk-6QHDMCAA.js +1 -0
  37. package/dist/{chunk-2KUM2RU4.js → chunk-7A4ZE5IS.js} +2 -2
  38. package/dist/{chunk-R6US7F33.js → chunk-7AQZKPJU.js} +1 -1
  39. package/dist/{chunk-HMPRWNGG.js → chunk-7FBOMPO5.js} +2 -2
  40. package/dist/{chunk-DGIIUQH3.js → chunk-7UK565VJ.js} +1 -1
  41. package/dist/{chunk-DOLVBTCB.js → chunk-A5BSUUNQ.js} +1 -1
  42. package/dist/{chunk-SCDGLREP.js → chunk-ADGE7MKB.js} +1 -1
  43. package/dist/{chunk-65NCQJYR.js → chunk-AEWRZ7AE.js} +1 -1
  44. package/dist/chunk-ALDJTWCO.js +1 -0
  45. package/dist/chunk-ARL5WBDK.js +1 -0
  46. package/dist/chunk-AXFEIJC7.js +1 -0
  47. package/dist/{chunk-JNSVKDBY.js → chunk-AYGL6F3P.js} +1 -1
  48. package/dist/{chunk-F6IQWX2F.js → chunk-AYTTE7X5.js} +1 -1
  49. package/dist/{chunk-JIYCZXK5.js → chunk-BDIZUTKC.js} +1 -1
  50. package/dist/{chunk-Z5WFRYVQ.js → chunk-BQKF4SRH.js} +1 -1
  51. package/dist/{chunk-7ART2IKU.js → chunk-C2AOCLEZ.js} +1 -1
  52. package/dist/{chunk-NYMKGE3J.js → chunk-C2SGJ5IG.js} +1 -1
  53. package/dist/{chunk-LPPEAMI6.js → chunk-C3S3UMV3.js} +1 -1
  54. package/dist/{chunk-S3RROJGG.js → chunk-C5DKLOW4.js} +1 -1
  55. package/dist/{chunk-DC7ITY6T.js → chunk-CA3GVT4D.js} +1 -1
  56. package/dist/{chunk-KFR7HWCG.js → chunk-CCLU5ZRK.js} +1 -1
  57. package/dist/{chunk-3FZ4LE6A.js → chunk-CE6XQDAG.js} +2 -2
  58. package/dist/{chunk-RKNVTEO3.js → chunk-CEJ5WS4I.js} +1 -1
  59. package/dist/chunk-CIBBQO2L.js +6 -0
  60. package/dist/{chunk-L2PUDV7Y.js → chunk-CKJXJ6HD.js} +1 -1
  61. package/dist/{chunk-KHZF73BL.js → chunk-COGKVNQB.js} +1 -1
  62. package/dist/{chunk-OY5M52EF.js → chunk-CQPZOXWO.js} +1 -1
  63. package/dist/{chunk-AVJJGQOP.js → chunk-CZYQIWNL.js} +1 -1
  64. package/dist/{chunk-VA2S7W7H.js → chunk-DA5RQFXA.js} +1 -1
  65. package/dist/{chunk-NUBJ2HK7.js → chunk-DESZFFOK.js} +1 -1
  66. package/dist/{chunk-WLYXBQ2M.js → chunk-DKR7562G.js} +1 -1
  67. package/dist/{chunk-KM4LE7K4.js → chunk-DNNTAMC5.js} +1 -1
  68. package/dist/{chunk-V4FC72R6.js → chunk-DUPQUQ2Z.js} +1 -1
  69. package/dist/{chunk-FHKK3QU7.js → chunk-DUTIWCJ2.js} +1 -1
  70. package/dist/chunk-E6JEBSHZ.js +20 -0
  71. package/dist/{chunk-VQSRU5XL.js → chunk-E6KNAPIY.js} +1 -1
  72. package/dist/{chunk-MTT6EAQO.js → chunk-E7XCCLQH.js} +1 -1
  73. package/dist/chunk-EE72PCKT.js +1 -0
  74. package/dist/{chunk-AGTUAQHX.js → chunk-EEYXBKR7.js} +1 -1
  75. package/dist/{chunk-H2KGP2FM.js → chunk-EGLA3WLZ.js} +1 -1
  76. package/dist/{chunk-JMSAHCBU.js → chunk-FDFE3SSG.js} +1 -1
  77. package/dist/{chunk-TSPJAMYB.js → chunk-FI5TQHUA.js} +1 -1
  78. package/dist/{chunk-QKPAB245.js → chunk-FIKZQ4RA.js} +1 -1
  79. package/dist/chunk-FJOVMEPN.js +3 -0
  80. package/dist/{chunk-5PSQFQL6.js → chunk-FLARCZ5F.js} +1 -1
  81. package/dist/{chunk-WE5KY6T6.js → chunk-FOMMPAWZ.js} +1 -1
  82. package/dist/chunk-G3DXNSA2.js +1 -0
  83. package/dist/{chunk-HYCNYUHW.js → chunk-G7JO3W2R.js} +1 -1
  84. package/dist/{chunk-C2HJEGTS.js → chunk-GABIWYY3.js} +1 -1
  85. package/dist/{chunk-OXZR2MB4.js → chunk-GFSEU7PF.js} +1 -1
  86. package/dist/{chunk-AMVWKHNY.js → chunk-GFVUWVEM.js} +1 -1
  87. package/dist/{chunk-D7IMC2G4.js → chunk-GHNSXX7R.js} +1 -1
  88. package/dist/{chunk-7N7KRZOM.js → chunk-GQ3LY7BY.js} +1 -1
  89. package/dist/{chunk-PJZZZNWR.js → chunk-H45S4MGC.js} +1 -1
  90. package/dist/{chunk-OJOF6IYG.js → chunk-HEB4YYM6.js} +4 -4
  91. package/dist/{chunk-I3WRA2LH.js → chunk-HI5FTI3M.js} +1 -1
  92. package/dist/{chunk-WFPVT2IY.js → chunk-HJ24NEP5.js} +1 -1
  93. package/dist/{chunk-LFBFPK22.js → chunk-HQFXVVTB.js} +1 -1
  94. package/dist/{chunk-27JT4NA4.js → chunk-HR6R7JXN.js} +1 -1
  95. package/dist/{chunk-JVY6CCLE.js → chunk-HRHJA5ZP.js} +1 -1
  96. package/dist/{chunk-5HOZDOJ7.js → chunk-HT5JQJMB.js} +1 -1
  97. package/dist/chunk-HT7273V7.js +1 -0
  98. package/dist/{chunk-ONZULPQH.js → chunk-HUB4HDWN.js} +75 -75
  99. package/dist/{chunk-HGZ2HRPO.js → chunk-IATNIWOC.js} +1 -1
  100. package/dist/{chunk-T6C4WC3Z.js → chunk-IHVWDKDV.js} +1 -1
  101. package/dist/{chunk-DMOLPSXF.js → chunk-IKXUYCK7.js} +1 -1
  102. package/dist/{chunk-HP4QYSBQ.js → chunk-IVQN2RUP.js} +1 -1
  103. package/dist/{chunk-FYQE5E6U.js → chunk-J324ZPO6.js} +1 -1
  104. package/dist/{chunk-3MZ7ELHS.js → chunk-JJQ3DJG5.js} +1 -1
  105. package/dist/{chunk-RLOEI6VE.js → chunk-JLAN6JXJ.js} +1 -1
  106. package/dist/{chunk-XRNBCV2B.js → chunk-K2GCCCCV.js} +1 -1
  107. package/dist/{chunk-ASKBYEO7.js → chunk-K4KKSBUW.js} +1 -1
  108. package/dist/{chunk-JC37YZ4I.js → chunk-K5UVCBIP.js} +1 -1
  109. package/dist/{chunk-3C72S6LO.js → chunk-KN2JIDNO.js} +1 -1
  110. package/dist/{chunk-WBJFTCEJ.js → chunk-KORVOCNN.js} +1 -1
  111. package/dist/{chunk-MGWCXTGD.js → chunk-KRQCQ57O.js} +1 -1
  112. package/dist/{chunk-3GD5ESWN.js → chunk-KT2AMFVW.js} +1 -1
  113. package/dist/{chunk-VRIFLMA3.js → chunk-L23Q53FM.js} +1 -1
  114. package/dist/{chunk-OXPEBT4I.js → chunk-L3DTONOI.js} +1 -1
  115. package/dist/{chunk-CEQGOCKX.js → chunk-LRETOC6P.js} +1 -1
  116. package/dist/{chunk-F5QKMDP3.js → chunk-LXFWK3O2.js} +1 -1
  117. package/dist/{chunk-KCAWHJGF.js → chunk-LZ2TN7EZ.js} +1 -1
  118. package/dist/{chunk-EDWIWZWM.js → chunk-MBAPM5HA.js} +1 -1
  119. package/dist/{chunk-IRLYC626.js → chunk-MGZK5EQW.js} +1 -1
  120. package/dist/{chunk-GSFWBFFH.js → chunk-MKUXSM33.js} +1 -1
  121. package/dist/chunk-MQ55QUOJ.js +276 -0
  122. package/dist/{chunk-A2NSORBM.js → chunk-NAQJMRPT.js} +1 -1
  123. package/dist/{chunk-Z5QEXS6F.js → chunk-NMXRDF4T.js} +1 -1
  124. package/dist/{chunk-SODCXZ5U.js → chunk-NOWM3CCG.js} +1 -1
  125. package/dist/{chunk-TXP6KFWO.js → chunk-NVDFXEQ5.js} +1 -1
  126. package/dist/{chunk-TP7CTMMT.js → chunk-OCILF2DD.js} +1 -1
  127. package/dist/{chunk-XWLNCBAG.js → chunk-OGBMFGYC.js} +1 -1
  128. package/dist/{chunk-ZMOW2YZ4.js → chunk-OIQ5NQ5I.js} +3 -3
  129. package/dist/{chunk-YTL45RXR.js → chunk-OKRKVVTK.js} +1 -1
  130. package/dist/{chunk-JQU2BJDH.js → chunk-ONNUEQGR.js} +1 -1
  131. package/dist/chunk-OSASE35V.js +6 -0
  132. package/dist/{chunk-6IMTMS2S.js → chunk-OTMTS5L4.js} +1 -1
  133. package/dist/{chunk-MKFRKNHF.js → chunk-OWPAHXDF.js} +1 -1
  134. package/dist/{chunk-YVPB7OT6.js → chunk-P7HZGJRU.js} +1 -1
  135. package/dist/{chunk-5T3ZT6CC.js → chunk-PIU3GVJ4.js} +1 -1
  136. package/dist/{chunk-DVD7I2TX.js → chunk-PSNCWS3Q.js} +1 -1
  137. package/dist/{chunk-XEZPN5TR.js → chunk-PSREELSQ.js} +4 -4
  138. package/dist/{chunk-SURFUFAZ.js → chunk-Q2CKRCPM.js} +1 -1
  139. package/dist/{chunk-WWCYEZUU.js → chunk-QA2D7DT2.js} +1 -1
  140. package/dist/{chunk-G3EWGBXR.js → chunk-QDMTJKQ3.js} +1 -1
  141. package/dist/{chunk-NY5N4ANL.js → chunk-QIJ7D2JS.js} +1 -1
  142. package/dist/{chunk-7DBKSSDK.js → chunk-QLN6IOOY.js} +1 -1
  143. package/dist/{chunk-A54TADAZ.js → chunk-QU3USVKT.js} +1 -1
  144. package/dist/chunk-R2E6TMBE.js +22 -0
  145. package/dist/chunk-R5COVIJM.js +1 -0
  146. package/dist/{chunk-S4KNPCW3.js → chunk-RFJ2LI64.js} +1 -1
  147. package/dist/chunk-RNF6T6IO.js +5 -0
  148. package/dist/{chunk-DVFVO6ZE.js → chunk-RSNFNZ6F.js} +1 -1
  149. package/dist/{chunk-7BPT5V24.js → chunk-RZ3UGOV4.js} +2 -2
  150. package/dist/{chunk-GGCP2TIK.js → chunk-S23ZG2RG.js} +1 -1
  151. package/dist/{chunk-3PS52ZT4.js → chunk-SAK42CAY.js} +1 -1
  152. package/dist/{chunk-G3RNO2TC.js → chunk-SBX7CMHM.js} +1 -1
  153. package/dist/{chunk-TUSS6PXB.js → chunk-SGQTRKYZ.js} +1 -1
  154. package/dist/{chunk-SQL67BKI.js → chunk-SNPJVVVE.js} +1 -1
  155. package/dist/{chunk-QUPZOBTB.js → chunk-SNRGS3YU.js} +1 -1
  156. package/dist/{chunk-FKKJQGYX.js → chunk-SUTSCIXU.js} +1 -1
  157. package/dist/{chunk-SHOMIS6Q.js → chunk-SWFCT5B7.js} +1 -1
  158. package/dist/{chunk-WZBZ7FWP.js → chunk-SZ64GAVG.js} +1 -1
  159. package/dist/{chunk-DTKGI43P.js → chunk-TDHIOONG.js} +1 -1
  160. package/dist/{chunk-7NRHZG5Y.js → chunk-TLN4BKXJ.js} +1 -1
  161. package/dist/{chunk-XLMKHTJ5.js → chunk-TXMZPF2U.js} +1 -1
  162. package/dist/{chunk-6BYHL3DS.js → chunk-TZOB52QK.js} +1 -1
  163. package/dist/{chunk-HVUMVDUG.js → chunk-U5BKU3OL.js} +1 -1
  164. package/dist/chunk-UK3BDOHR.js +7 -0
  165. package/dist/{chunk-YKDRUAY3.js → chunk-UORSJB4A.js} +90 -90
  166. package/dist/{chunk-Z6ZRS256.js → chunk-UY44O4IZ.js} +1 -1
  167. package/dist/{chunk-JG4FAT2T.js → chunk-V3H6SYK3.js} +1 -1
  168. package/dist/{chunk-AE3IQG7S.js → chunk-VBPMVVLV.js} +1 -1
  169. package/dist/{chunk-SVQDMZJO.js → chunk-VGBCG3I5.js} +1 -1
  170. package/dist/{chunk-MYMBHVC4.js → chunk-VHRUPKWH.js} +1 -1
  171. package/dist/{chunk-CZNUBAAG.js → chunk-VVHJ2AUF.js} +1 -1
  172. package/dist/{chunk-T4ZOTYOY.js → chunk-WB5GRBHW.js} +1 -1
  173. package/dist/{chunk-YNFQBYSL.js → chunk-WBKQSSWW.js} +1 -1
  174. package/dist/{chunk-MU7IVBGI.js → chunk-WDXDT7XY.js} +2 -2
  175. package/dist/{chunk-FAVPTYIR.js → chunk-WHOD5I7N.js} +1 -1
  176. package/dist/{chunk-7CT3NIXI.js → chunk-WL3M63DG.js} +1 -1
  177. package/dist/{chunk-25MYHE4W.js → chunk-WLJDMI7E.js} +1 -1
  178. package/dist/{chunk-VJG7VXFU.js → chunk-WZ3QWPK5.js} +2 -2
  179. package/dist/{chunk-BPKQA2EO.js → chunk-X5V7AGVU.js} +1 -1
  180. package/dist/{chunk-UFY4L5KQ.js → chunk-X76AYO36.js} +1 -1
  181. package/dist/{chunk-WBPP6PO7.js → chunk-XB7H2RYV.js} +1 -1
  182. package/dist/chunk-XHHAVKKV.js +1 -0
  183. package/dist/{chunk-4TCXPHKN.js → chunk-XKNDU62O.js} +1 -1
  184. package/dist/{chunk-7KID5BIR.js → chunk-XVJRGOJA.js} +1 -1
  185. package/dist/{chunk-CDSDQTNB.js → chunk-Y3ZAQZPH.js} +1 -1
  186. package/dist/{chunk-Q2LQJYRK.js → chunk-YGN65N6W.js} +1 -1
  187. package/dist/{chunk-UC4TOM36.js → chunk-YTC367JI.js} +1 -1
  188. package/dist/{chunk-TTAT62N3.js → chunk-Z2FGYMJ6.js} +1 -1
  189. package/dist/chunk-Z3QZNLT5.js +1 -0
  190. package/dist/{chunk-TSVEV2UD.js → chunk-ZC3EDADH.js} +1 -1
  191. package/dist/{chunk-O7HZ3EIP.js → chunk-ZLITAXPT.js} +1 -1
  192. package/dist/{chunk-WWVDZ3GC.js → chunk-ZNEQZV5K.js} +1 -1
  193. package/dist/{chunk-OVJVFB5E.js → chunk-ZOU6SOXW.js} +1 -1
  194. package/dist/{chunk-KFO2JNF5.js → chunk-ZQNGYJKJ.js} +1 -1
  195. package/dist/{chunk-MZDBH4XV.js → chunk-ZRM7ESSS.js} +1 -1
  196. package/dist/{chunk-ORYEDUKM.js → chunk-ZX33FUW3.js} +1 -1
  197. package/dist/cli/commands/app/build.js +1 -1
  198. package/dist/cli/commands/app/bulk/cancel.js +1 -1
  199. package/dist/cli/commands/app/bulk/execute.js +1 -1
  200. package/dist/cli/commands/app/bulk/status.js +1 -1
  201. package/dist/cli/commands/app/config/link.js +1 -1
  202. package/dist/cli/commands/app/config/pull.js +1 -1
  203. package/dist/cli/commands/app/config/use.js +1 -1
  204. package/dist/cli/commands/app/config/validate.js +1 -1
  205. package/dist/cli/commands/app/demo/watcher.js +1 -1
  206. package/dist/cli/commands/app/deploy.js +1 -1
  207. package/dist/cli/commands/app/dev/clean.js +1 -1
  208. package/dist/cli/commands/app/dev.js +1 -1
  209. package/dist/cli/commands/app/env/pull.js +1 -1
  210. package/dist/cli/commands/app/env/show.js +1 -1
  211. package/dist/cli/commands/app/execute.js +1 -1
  212. package/dist/cli/commands/app/function/build.js +1 -1
  213. package/dist/cli/commands/app/function/info.js +1 -1
  214. package/dist/cli/commands/app/function/replay.js +1 -1
  215. package/dist/cli/commands/app/function/run.js +1 -1
  216. package/dist/cli/commands/app/function/schema.js +1 -1
  217. package/dist/cli/commands/app/function/typegen.js +1 -1
  218. package/dist/cli/commands/app/generate/extension.js +1 -1
  219. package/dist/cli/commands/app/graphiql.js +1 -1
  220. package/dist/cli/commands/app/import/channel-config.js +1 -1
  221. package/dist/cli/commands/app/import/custom-data-definitions.js +1 -1
  222. package/dist/cli/commands/app/import/dashboard-extensions.js +1 -1
  223. package/dist/cli/commands/app/import-custom-data-definitions.js +1 -1
  224. package/dist/cli/commands/app/import-extensions.js +1 -1
  225. package/dist/cli/commands/app/info.js +1 -1
  226. package/dist/cli/commands/app/init.js +1 -1
  227. package/dist/cli/commands/app/logs.js +1 -1
  228. package/dist/cli/commands/app/release.js +1 -1
  229. package/dist/cli/commands/app/security/check.js +1 -1
  230. package/dist/cli/commands/app/security/clean.js +1 -1
  231. package/dist/cli/commands/app/security/instructions.js +1 -1
  232. package/dist/cli/commands/app/security/record.js +1 -1
  233. package/dist/cli/commands/app/security/review.js +1 -1
  234. package/dist/cli/commands/app/subscription-migrations/cancel.js +1 -1
  235. package/dist/cli/commands/app/subscription-migrations/list.js +1 -1
  236. package/dist/cli/commands/app/subscription-migrations/schedule.js +1 -1
  237. package/dist/cli/commands/app/subscription-migrations/status.js +1 -1
  238. package/dist/cli/commands/app/subscription-migrations/unschedule.js +1 -1
  239. package/dist/cli/commands/app/versions/list.js +1 -1
  240. package/dist/cli/commands/app/webhook/trigger.js +1 -1
  241. package/dist/cli/commands/auth/login.js +1 -1
  242. package/dist/cli/commands/auth/logout.js +1 -1
  243. package/dist/cli/commands/cache/clear.js +1 -1
  244. package/dist/cli/commands/config/autoupgrade/off.js +1 -1
  245. package/dist/cli/commands/config/autoupgrade/on.js +1 -1
  246. package/dist/cli/commands/config/autoupgrade/status.js +1 -1
  247. package/dist/cli/commands/debug/command-flags.js +1 -1
  248. package/dist/cli/commands/doc/fetch.js +1 -1
  249. package/dist/cli/commands/doc/search.js +1 -1
  250. package/dist/cli/commands/docs/generate.js +1 -1
  251. package/dist/cli/commands/doctor-release/doctor-release.js +1 -1
  252. package/dist/cli/commands/doctor-release/theme/index.js +1 -1
  253. package/dist/cli/commands/help.js +1 -1
  254. package/dist/cli/commands/kitchen-sink/async.js +1 -1
  255. package/dist/cli/commands/kitchen-sink/index.js +1 -1
  256. package/dist/cli/commands/kitchen-sink/prompts.js +1 -1
  257. package/dist/cli/commands/kitchen-sink/static.js +1 -1
  258. package/dist/cli/commands/notifications/generate.js +1 -1
  259. package/dist/cli/commands/notifications/list.js +1 -1
  260. package/dist/cli/commands/organization/list.js +1 -1
  261. package/dist/cli/commands/search.js +1 -1
  262. package/dist/cli/commands/send-analytics.js +1 -1
  263. package/dist/cli/commands/theme/check.js +1 -1
  264. package/dist/cli/commands/theme/console.js +1 -1
  265. package/dist/cli/commands/theme/delete.js +1 -1
  266. package/dist/cli/commands/theme/dev.js +1 -1
  267. package/dist/cli/commands/theme/duplicate.js +1 -1
  268. package/dist/cli/commands/theme/info.js +1 -1
  269. package/dist/cli/commands/theme/init.js +1 -1
  270. package/dist/cli/commands/theme/language-server.js +1 -1
  271. package/dist/cli/commands/theme/list.js +1 -1
  272. package/dist/cli/commands/theme/metafields/pull.js +1 -1
  273. package/dist/cli/commands/theme/open.js +1 -1
  274. package/dist/cli/commands/theme/package.js +1 -1
  275. package/dist/cli/commands/theme/preview.js +1 -1
  276. package/dist/cli/commands/theme/profile.js +1 -1
  277. package/dist/cli/commands/theme/publish.js +1 -1
  278. package/dist/cli/commands/theme/pull.js +1 -1
  279. package/dist/cli/commands/theme/push.js +1 -1
  280. package/dist/cli/commands/theme/rename.js +1 -1
  281. package/dist/cli/commands/theme/share.js +1 -1
  282. package/dist/cli/commands/upgrade.js +1 -1
  283. package/dist/cli/commands/version.js +1 -1
  284. package/dist/cli/help.js +1 -1
  285. package/dist/{cli-version-check-V25AVSZ6.js → cli-version-check-BW2CUMX4.js} +1 -1
  286. package/dist/{command-json-schema-C5UZXP2W.js → command-json-schema-LGR44Q2G.js} +1 -1
  287. package/dist/command-registry.js +1 -1
  288. package/dist/{conf-store-OCGEEV4U.js → conf-store-TODPQ2LC.js} +1 -1
  289. package/dist/configs/all.yml +9 -0
  290. package/dist/configs/recommended.yml +9 -0
  291. package/dist/{custom-oclif-loader-ZVUKMRGH.js → custom-oclif-loader-BPE2TH4B.js} +1 -1
  292. package/dist/data/objects.json +204 -11
  293. package/dist/data/section.json +14 -0
  294. package/dist/data/setting.json +9 -5
  295. package/dist/data/shopify_system_translations.json +84 -21
  296. package/dist/{deprecations-A5AXXKIK.js → deprecations-5CSI24TV.js} +1 -1
  297. package/dist/dist-LPKYTX3M.js +1 -0
  298. package/dist/dist-WT6MPTKJ.js +1 -0
  299. package/dist/{environments-Y5JEI3U3.js → environments-3HTT5CVC.js} +1 -1
  300. package/dist/error-PFOKPWFX.js +1 -0
  301. package/dist/error-handler-23FASAEU.js +1 -0
  302. package/dist/{fs-UOOLPOHJ.js → fs-RA25PWSJ.js} +1 -1
  303. package/dist/hooks/did-you-mean.js +1 -1
  304. package/dist/hooks/hydrogen-init.js +1 -1
  305. package/dist/hooks/plugin-plugins.js +1 -1
  306. package/dist/hooks/postrun.js +1 -1
  307. package/dist/hooks/prerun.js +1 -1
  308. package/dist/hooks/public-metadata.js +1 -1
  309. package/dist/hooks/sensitive-metadata.js +1 -1
  310. package/dist/hooks/tunnel-provider.js +1 -1
  311. package/dist/hooks/tunnel-start.js +1 -1
  312. package/dist/http-EVDTYINS.js +1 -0
  313. package/dist/index.js +12 -12
  314. package/dist/{is-global-CI77T7NE.js → is-global-3DNAMKUU.js} +1 -1
  315. package/dist/{json-error-6PBUR4LQ.js → json-error-HGCRNJRF.js} +1 -1
  316. package/dist/{lib-4JVADMNT.js → lib-4ZA53LTZ.js} +1 -1
  317. package/dist/{lib-L4STV5B2.js → lib-F3MES3XF.js} +1 -1
  318. package/dist/{lib-LEEN55OD.js → lib-XPJABU24.js} +1 -1
  319. package/dist/{local-5NIWPWDS.js → local-LNGPIGLG.js} +1 -1
  320. package/dist/{metadata-IXPNNPNJ.js → metadata-VHLSUKCW.js} +1 -1
  321. package/dist/{node-package-manager-ALFEGGD6.js → node-package-manager-SSFNUVWB.js} +1 -1
  322. package/dist/notifications-system-3NQRYYKW.js +1 -0
  323. package/dist/{os-6TNQTEUN.js → os-KIKVJONE.js} +1 -1
  324. package/dist/{output-LEOB5LAM.js → output-DUJTSURG.js} +1 -1
  325. package/dist/{prettier-VLTY4MIE.js → prettier-NOE3TJJ5.js} +1 -1
  326. package/dist/{system-J4CTESP5.js → system-CGOZSROX.js} +1 -1
  327. package/dist/tsconfig.tsbuildinfo +1 -1
  328. package/dist/{ui-YDUI56E3.js → ui-YMBFS3NG.js} +1 -1
  329. package/dist/upgrade-73RRPDSC.js +1 -0
  330. package/dist/version-AMUEEBIG.js +1 -0
  331. package/dist/{version-2YL4YEQ2.js → version-S4MGCKDO.js} +1 -1
  332. package/dist/{workerd-5UPTEWNI.js → workerd-DRWNY3S4.js} +1 -1
  333. package/oclif.manifest.json +23 -62
  334. package/package.json +7 -7
  335. package/dist/analytics-QFDTQYPM.js +0 -1
  336. package/dist/analytics-XADBBHOH.js +0 -1
  337. package/dist/chunk-2BYW3BYX.js +0 -1
  338. package/dist/chunk-2PD7TNFS.js +0 -275
  339. package/dist/chunk-3Z75BVGJ.js +0 -1
  340. package/dist/chunk-4WBWZIN5.js +0 -6
  341. package/dist/chunk-62NW4EPI.js +0 -17
  342. package/dist/chunk-ALINJ6J2.js +0 -1
  343. package/dist/chunk-BFAOTQGH.js +0 -1
  344. package/dist/chunk-CIGWIKOW.js +0 -1
  345. package/dist/chunk-DXEMSLI6.js +0 -1
  346. package/dist/chunk-H4K3F7PP.js +0 -5
  347. package/dist/chunk-JGLLABZR.js +0 -8
  348. package/dist/chunk-JIY6XWSC.js +0 -1
  349. package/dist/chunk-LXIWMYM4.js +0 -1
  350. package/dist/chunk-MGX7UG44.js +0 -1
  351. package/dist/chunk-QGQWVA7N.js +0 -1
  352. package/dist/chunk-RSZAAN37.js +0 -1
  353. package/dist/chunk-SN3PMWUF.js +0 -6
  354. package/dist/chunk-TD6JBHUS.js +0 -1
  355. package/dist/chunk-TIM4CIXZ.js +0 -22
  356. package/dist/chunk-WNVOEE6T.js +0 -7
  357. package/dist/chunk-YOYPYB4H.js +0 -1
  358. package/dist/cli/commands/app/logs-next.js +0 -1
  359. package/dist/dist-NORLLIHQ.js +0 -1
  360. package/dist/dist-XBM4XZS4.js +0 -1
  361. package/dist/error-GI4DXVDU.js +0 -1
  362. package/dist/error-handler-BS2ZENQV.js +0 -1
  363. package/dist/http-2OXOS2AW.js +0 -1
  364. package/dist/notifications-system-FQW3GKH2.js +0 -1
  365. package/dist/upgrade-LBCZORG2.js +0 -1
  366. package/dist/version-X2CPQVWQ.js +0 -1
  367. /package/dist/{chunk-2S3FHQFS.js → chunk-HVECVOIO.js} +0 -0
@@ -0,0 +1,6 @@
1
+ import{b as R,c as p}from"./chunk-K4QJEQI4.js";import{b as v}from"./chunk-PSREELSQ.js";import{q as y}from"./chunk-UORSJB4A.js";import{b as g,c as w}from"./chunk-IKXUYCK7.js";import{j as i}from"./chunk-FJOVMEPN.js";import{zb as m}from"./chunk-OIQ5NQ5I.js";import{b as d}from"./chunk-3PYDIBTX.js";import{b as I}from"./chunk-VBPMVVLV.js";import{e as P,g as s}from"./chunk-VKWPEFWQ.js";s();s();var O="https://shopify.dev/assistant/search",_="X-Shopify-Surface",j="cli",D=d.array(R.strip().extend({domain:d.string().nullish()}));async function x(t,e,c){let h=new URLSearchParams({query:t});e&&h.append("api_name",e),c&&h.append("api_version",c);let a;try{a=await y(`${O}?${h.toString()}`,{headers:{Accept:"application/json",[_]:j}})}catch{throw new i("Could not reach shopify.dev to run the search.","Check your network connection and try again.")}let n=await a.text();if(!a.ok){let r=`${a.status} ${a.statusText}`;try{let o=JSON.parse(n);o?.error&&(r=o.error)}catch(o){if(!(o instanceof SyntaxError))throw o}throw new i(`Search failed: ${r}`)}let l;try{l=JSON.parse(n)}catch(r){if(!(r instanceof SyntaxError))throw r;return{status:"invalid-response",body:n}}let S=D.safeParse(l);return S.success?{status:"success",results:S.data.map(({score:r,content:o,url:b,title:E,domain:F})=>({score:r,content:o,url:b,title:E,domain:F??null})),pageInfo:{hasNextPage:null},body:n}:{status:"invalid-response",body:n}}s();function A(t,e){if(e==="text"){m(t.body);return}if(t.status==="invalid-response")throw new i("Search returned an invalid documentation response.");m(p.encode({results:t.results,pageInfo:t.pageInfo}))}var u=P(I(),1),f=class t extends v{static descriptionWithMarkdown="Query the shopify.dev vector store and print the most relevant documentation chunks as JSON. Best for programmatic discovery \u2014 surfacing the relevant pieces of documentation for a topic, rather than retrieving a whole document. To download a full document verbatim, use `doc fetch`.";static jsonOutputSchema=p;static description=this.descriptionForHelp();static examples=[`# search shopify.dev for a topic
2
+ shopify doc search --query "subscribe to webhooks"
3
+
4
+ # narrow the search to a specific API and version
5
+ shopify doc search --query "create a product" --api-name admin --api-version latest`,`# return typed documentation results as a JSON object
6
+ shopify doc search --query "subscribe to webhooks" --json`];static flags={...g,...w,query:u.Flags.string({description:"The search query.",env:"SHOPIFY_FLAG_QUERY",required:!0}),"api-name":u.Flags.string({description:"Limit results to a specific API (for example: admin, storefront, hydrogen, functions). Unrecognized values are ignored.",env:"SHOPIFY_FLAG_API_NAME"}),"api-version":u.Flags.string({description:"Limit results to a specific API version (for example: 2025-10, latest, current).",env:"SHOPIFY_FLAG_API_VERSION"})};async run(){let{flags:e}=await this.parse(t),c=await x(e.query,e["api-name"],e["api-version"]);A(c,e.json?"json":"text")}};export{f as a};
@@ -1,4 +1,4 @@
1
- import{a as hS,b as Hp}from"./chunk-LQ7ENG4V.js";import{a as wR}from"./chunk-IWOTLFOY.js";import{a as Pf,b as fS,c as dS,e as Ip,f as Au,g as Pp,i as pS,j as vS,k as OR,l as tc,m as bR,n as mS,p as AR}from"./chunk-7Y7AZRL3.js";import{a as LR}from"./chunk-5HBIIYSK.js";import{a as yS}from"./chunk-AAK376RT.js";import{h as di,i as Zn}from"./chunk-B4OMIONW.js";import{b as DR}from"./chunk-AE3IQG7S.js";import{a as NR,c as pa,e as nn,g as P}from"./chunk-VKWPEFWQ.js";var OS=pa(kt=>{"use strict";P();var Hf=Symbol.for("react.element"),UR=Symbol.for("react.portal"),MR=Symbol.for("react.fragment"),zR=Symbol.for("react.strict_mode"),FR=Symbol.for("react.profiler"),IR=Symbol.for("react.provider"),PR=Symbol.for("react.context"),HR=Symbol.for("react.forward_ref"),jR=Symbol.for("react.suspense"),kR=Symbol.for("react.memo"),BR=Symbol.for("react.lazy"),gS=Symbol.iterator;function VR(s){return s===null||typeof s!="object"?null:(s=gS&&s[gS]||s["@@iterator"],typeof s=="function"?s:null)}var TS={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_S=Object.assign,xS={};function nc(s,o,p){this.props=s,this.context=o,this.refs=xS,this.updater=p||TS}nc.prototype.isReactComponent={};nc.prototype.setState=function(s,o){if(typeof s!="object"&&typeof s!="function"&&s!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,s,o,"setState")};nc.prototype.forceUpdate=function(s){this.updater.enqueueForceUpdate(this,s,"forceUpdate")};function CS(){}CS.prototype=nc.prototype;function Uh(s,o,p){this.props=s,this.context=o,this.refs=xS,this.updater=p||TS}var Mh=Uh.prototype=new CS;Mh.constructor=Uh;_S(Mh,nc.prototype);Mh.isPureReactComponent=!0;var ES=Array.isArray,RS=Object.prototype.hasOwnProperty,zh={current:null},NS={key:!0,ref:!0,__self:!0,__source:!0};function DS(s,o,p){var E,h={},C=null,R=null;if(o!=null)for(E in o.ref!==void 0&&(R=o.ref),o.key!==void 0&&(C=""+o.key),o)RS.call(o,E)&&!NS.hasOwnProperty(E)&&(h[E]=o[E]);var F=arguments.length-2;if(F===1)h.children=p;else if(1<F){for(var A=Array(F),N=0;N<F;N++)A[N]=arguments[N+2];h.children=A}if(s&&s.defaultProps)for(E in F=s.defaultProps,F)h[E]===void 0&&(h[E]=F[E]);return{$$typeof:Hf,type:s,key:C,ref:R,props:h,_owner:zh.current}}function WR(s,o){return{$$typeof:Hf,type:s.type,key:o,ref:s.ref,props:s.props,_owner:s._owner}}function Fh(s){return typeof s=="object"&&s!==null&&s.$$typeof===Hf}function GR(s){var o={"=":"=0",":":"=2"};return"$"+s.replace(/[=:]/g,function(p){return o[p]})}var SS=/\/+/g;function wh(s,o){return typeof s=="object"&&s!==null&&s.key!=null?GR(""+s.key):o.toString(36)}function kp(s,o,p,E,h){var C=typeof s;(C==="undefined"||C==="boolean")&&(s=null);var R=!1;if(s===null)R=!0;else switch(C){case"string":case"number":R=!0;break;case"object":switch(s.$$typeof){case Hf:case UR:R=!0}}if(R)return R=s,h=h(R),s=E===""?"."+wh(R,0):E,ES(h)?(p="",s!=null&&(p=s.replace(SS,"$&/")+"/"),kp(h,o,p,"",function(N){return N})):h!=null&&(Fh(h)&&(h=WR(h,p+(!h.key||R&&R.key===h.key?"":(""+h.key).replace(SS,"$&/")+"/")+s)),o.push(h)),1;if(R=0,E=E===""?".":E+":",ES(s))for(var F=0;F<s.length;F++){C=s[F];var A=E+wh(C,F);R+=kp(C,o,p,A,h)}else if(A=VR(s),typeof A=="function")for(s=A.call(s),F=0;!(C=s.next()).done;)C=C.value,A=E+wh(C,F++),R+=kp(C,o,p,A,h);else if(C==="object")throw o=String(s),Error("Objects are not valid as a React child (found: "+(o==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":o)+"). If you meant to render a collection of children, use an array instead.");return R}function jp(s,o,p){if(s==null)return s;var E=[],h=0;return kp(s,E,"","",function(C){return o.call(p,C,h++)}),E}function YR(s){if(s._status===-1){var o=s._result;o=o(),o.then(function(p){(s._status===0||s._status===-1)&&(s._status=1,s._result=p)},function(p){(s._status===0||s._status===-1)&&(s._status=2,s._result=p)}),s._status===-1&&(s._status=0,s._result=o)}if(s._status===1)return s._result.default;throw s._result}var Ia={current:null},Bp={transition:null},QR={ReactCurrentDispatcher:Ia,ReactCurrentBatchConfig:Bp,ReactCurrentOwner:zh};function LS(){throw Error("act(...) is not supported in production builds of React.")}kt.Children={map:jp,forEach:function(s,o,p){jp(s,function(){o.apply(this,arguments)},p)},count:function(s){var o=0;return jp(s,function(){o++}),o},toArray:function(s){return jp(s,function(o){return o})||[]},only:function(s){if(!Fh(s))throw Error("React.Children.only expected to receive a single React element child.");return s}};kt.Component=nc;kt.Fragment=MR;kt.Profiler=FR;kt.PureComponent=Uh;kt.StrictMode=zR;kt.Suspense=jR;kt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=QR;kt.act=LS;kt.cloneElement=function(s,o,p){if(s==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+s+".");var E=_S({},s.props),h=s.key,C=s.ref,R=s._owner;if(o!=null){if(o.ref!==void 0&&(C=o.ref,R=zh.current),o.key!==void 0&&(h=""+o.key),s.type&&s.type.defaultProps)var F=s.type.defaultProps;for(A in o)RS.call(o,A)&&!NS.hasOwnProperty(A)&&(E[A]=o[A]===void 0&&F!==void 0?F[A]:o[A])}var A=arguments.length-2;if(A===1)E.children=p;else if(1<A){F=Array(A);for(var N=0;N<A;N++)F[N]=arguments[N+2];E.children=F}return{$$typeof:Hf,type:s.type,key:h,ref:C,props:E,_owner:R}};kt.createContext=function(s){return s={$$typeof:PR,_currentValue:s,_currentValue2:s,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},s.Provider={$$typeof:IR,_context:s},s.Consumer=s};kt.createElement=DS;kt.createFactory=function(s){var o=DS.bind(null,s);return o.type=s,o};kt.createRef=function(){return{current:null}};kt.forwardRef=function(s){return{$$typeof:HR,render:s}};kt.isValidElement=Fh;kt.lazy=function(s){return{$$typeof:BR,_payload:{_status:-1,_result:s},_init:YR}};kt.memo=function(s,o){return{$$typeof:kR,type:s,compare:o===void 0?null:o}};kt.startTransition=function(s){var o=Bp.transition;Bp.transition={};try{s()}finally{Bp.transition=o}};kt.unstable_act=LS;kt.useCallback=function(s,o){return Ia.current.useCallback(s,o)};kt.useContext=function(s){return Ia.current.useContext(s)};kt.useDebugValue=function(){};kt.useDeferredValue=function(s){return Ia.current.useDeferredValue(s)};kt.useEffect=function(s,o){return Ia.current.useEffect(s,o)};kt.useId=function(){return Ia.current.useId()};kt.useImperativeHandle=function(s,o,p){return Ia.current.useImperativeHandle(s,o,p)};kt.useInsertionEffect=function(s,o){return Ia.current.useInsertionEffect(s,o)};kt.useLayoutEffect=function(s,o){return Ia.current.useLayoutEffect(s,o)};kt.useMemo=function(s,o){return Ia.current.useMemo(s,o)};kt.useReducer=function(s,o,p){return Ia.current.useReducer(s,o,p)};kt.useRef=function(s){return Ia.current.useRef(s)};kt.useState=function(s){return Ia.current.useState(s)};kt.useSyncExternalStore=function(s,o,p){return Ia.current.useSyncExternalStore(s,o,p)};kt.useTransition=function(){return Ia.current.useTransition()};kt.version="18.3.1"});var bS=pa((Bt,Vp)=>{"use strict";P();process.env.NODE_ENV!=="production"&&(function(){"use strict";typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error);var s="18.3.1",o=Symbol.for("react.element"),p=Symbol.for("react.portal"),E=Symbol.for("react.fragment"),h=Symbol.for("react.strict_mode"),C=Symbol.for("react.profiler"),R=Symbol.for("react.provider"),F=Symbol.for("react.context"),A=Symbol.for("react.forward_ref"),N=Symbol.for("react.suspense"),le=Symbol.for("react.suspense_list"),$=Symbol.for("react.memo"),xe=Symbol.for("react.lazy"),Le=Symbol.for("react.offscreen"),Re=Symbol.iterator,he="@@iterator";function Ee(y){if(y===null||typeof y!="object")return null;var L=Re&&y[Re]||y[he];return typeof L=="function"?L:null}var $e={current:null},st={transition:null},et={current:null,isBatchingLegacy:!1,didScheduleLegacyUpdate:!1},Xe={current:null},Xt={},qe=null;function Ve(y){qe=y}Xt.setExtraStackFrame=function(y){qe=y},Xt.getCurrentStack=null,Xt.getStackAddendum=function(){var y="";qe&&(y+=qe);var L=Xt.getCurrentStack;return L&&(y+=L()||""),y};var rn=!1,We=!1,gt=!1,Me=!1,G=!1,ce={ReactCurrentDispatcher:$e,ReactCurrentBatchConfig:st,ReactCurrentOwner:Xe};ce.ReactDebugCurrentFrame=Xt,ce.ReactCurrentActQueue=et;function Oe(y){{for(var L=arguments.length,B=new Array(L>1?L-1:0),X=1;X<L;X++)B[X-1]=arguments[X];Tt("warn",y,B)}}function oe(y){{for(var L=arguments.length,B=new Array(L>1?L-1:0),X=1;X<L;X++)B[X-1]=arguments[X];Tt("error",y,B)}}function Tt(y,L,B){{var X=ce.ReactDebugCurrentFrame,fe=X.getStackAddendum();fe!==""&&(L+="%s",B=B.concat([fe]));var nt=B.map(function(_e){return String(_e)});nt.unshift("Warning: "+L),Function.prototype.apply.call(console[y],console,nt)}}var je={};function Ct(y,L){{var B=y.constructor,X=B&&(B.displayName||B.name)||"ReactClass",fe=X+"."+L;if(je[fe])return;oe("Can't call %s on a component that is not yet mounted. This is a no-op, but it might indicate a bug in your application. Instead, assign to `this.state` directly or define a `state = {};` class property with the desired state in the %s component.",L,X),je[fe]=!0}}var we={isMounted:function(y){return!1},enqueueForceUpdate:function(y,L,B){Ct(y,"forceUpdate")},enqueueReplaceState:function(y,L,B,X){Ct(y,"replaceState")},enqueueSetState:function(y,L,B,X){Ct(y,"setState")}},_t=Object.assign,rt={};Object.freeze(rt);function Gt(y,L,B){this.props=y,this.context=L,this.refs=rt,this.updater=B||we}Gt.prototype.isReactComponent={},Gt.prototype.setState=function(y,L){if(typeof y!="object"&&typeof y!="function"&&y!=null)throw new Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,y,L,"setState")},Gt.prototype.forceUpdate=function(y){this.updater.enqueueForceUpdate(this,y,"forceUpdate")};{var Je={isMounted:["isMounted","Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks."],replaceState:["replaceState","Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236)."]},bn=function(y,L){Object.defineProperty(Gt.prototype,y,{get:function(){Oe("%s(...) is deprecated in plain JavaScript React classes. %s",L[0],L[1])}})};for(var Kt in Je)Je.hasOwnProperty(Kt)&&bn(Kt,Je[Kt])}function tt(){}tt.prototype=Gt.prototype;function w(y,L,B){this.props=y,this.context=L,this.refs=rt,this.updater=B||we}var J=w.prototype=new tt;J.constructor=w,_t(J,Gt.prototype),J.isPureReactComponent=!0;function Ke(){var y={current:null};return Object.seal(y),y}var Yt=Array.isArray;function vt(y){return Yt(y)}function Dt(y){{var L=typeof Symbol=="function"&&Symbol.toStringTag,B=L&&y[Symbol.toStringTag]||y.constructor.name||"Object";return B}}function Et(y){try{return Qt(y),!1}catch{return!0}}function Qt(y){return""+y}function Nn(y){if(Et(y))return oe("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Dt(y)),Qt(y)}function An(y,L,B){var X=y.displayName;if(X)return X;var fe=L.displayName||L.name||"";return fe!==""?B+"("+fe+")":B}function Bn(y){return y.displayName||"Context"}function gn(y){if(y==null)return null;if(typeof y.tag=="number"&&oe("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof y=="function")return y.displayName||y.name||null;if(typeof y=="string")return y;switch(y){case E:return"Fragment";case p:return"Portal";case C:return"Profiler";case h:return"StrictMode";case N:return"Suspense";case le:return"SuspenseList"}if(typeof y=="object")switch(y.$$typeof){case F:var L=y;return Bn(L)+".Consumer";case R:var B=y;return Bn(B._context)+".Provider";case A:return An(y,y.render,"ForwardRef");case $:var X=y.displayName||null;return X!==null?X:gn(y.type)||"Memo";case xe:{var fe=y,nt=fe._payload,_e=fe._init;try{return gn(_e(nt))}catch{return null}}}return null}var $n=Object.prototype.hasOwnProperty,br={key:!0,ref:!0,__self:!0,__source:!0},ha,on,Ar;Ar={};function ir(y){if($n.call(y,"ref")){var L=Object.getOwnPropertyDescriptor(y,"ref").get;if(L&&L.isReactWarning)return!1}return y.ref!==void 0}function Pa(y){if($n.call(y,"key")){var L=Object.getOwnPropertyDescriptor(y,"key").get;if(L&&L.isReactWarning)return!1}return y.key!==void 0}function Ka(y,L){var B=function(){ha||(ha=!0,oe("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",L))};B.isReactWarning=!0,Object.defineProperty(y,"key",{get:B,configurable:!0})}function ya(y,L){var B=function(){on||(on=!0,oe("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",L))};B.isReactWarning=!0,Object.defineProperty(y,"ref",{get:B,configurable:!0})}function ga(y){if(typeof y.ref=="string"&&Xe.current&&y.__self&&Xe.current.stateNode!==y.__self){var L=gn(Xe.current.type);Ar[L]||(oe('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',L,y.ref),Ar[L]=!0)}}var Ea=function(y,L,B,X,fe,nt,_e){var Ze={$$typeof:o,type:y,key:L,ref:B,props:_e,_owner:nt};return Ze._store={},Object.defineProperty(Ze._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(Ze,"_self",{configurable:!1,enumerable:!1,writable:!1,value:X}),Object.defineProperty(Ze,"_source",{configurable:!1,enumerable:!1,writable:!1,value:fe}),Object.freeze&&(Object.freeze(Ze.props),Object.freeze(Ze)),Ze};function ta(y,L,B){var X,fe={},nt=null,_e=null,Ze=null,St=null;if(L!=null){ir(L)&&(_e=L.ref,ga(L)),Pa(L)&&(Nn(L.key),nt=""+L.key),Ze=L.__self===void 0?null:L.__self,St=L.__source===void 0?null:L.__source;for(X in L)$n.call(L,X)&&!br.hasOwnProperty(X)&&(fe[X]=L[X])}var At=arguments.length-2;if(At===1)fe.children=B;else if(At>1){for(var Pt=Array(At),qt=0;qt<At;qt++)Pt[qt]=arguments[qt+2];Object.freeze&&Object.freeze(Pt),fe.children=Pt}if(y&&y.defaultProps){var mn=y.defaultProps;for(X in mn)fe[X]===void 0&&(fe[X]=mn[X])}if(nt||_e){var _n=typeof y=="function"?y.displayName||y.name||"Unknown":y;nt&&Ka(fe,_n),_e&&ya(fe,_n)}return Ea(y,nt,_e,Ze,St,Xe.current,fe)}function ye(y,L){var B=Ea(y.type,L,y.ref,y._self,y._source,y._owner,y.props);return B}function Ge(y,L,B){if(y==null)throw new Error("React.cloneElement(...): The argument must be a React element, but you passed "+y+".");var X,fe=_t({},y.props),nt=y.key,_e=y.ref,Ze=y._self,St=y._source,At=y._owner;if(L!=null){ir(L)&&(_e=L.ref,At=Xe.current),Pa(L)&&(Nn(L.key),nt=""+L.key);var Pt;y.type&&y.type.defaultProps&&(Pt=y.type.defaultProps);for(X in L)$n.call(L,X)&&!br.hasOwnProperty(X)&&(L[X]===void 0&&Pt!==void 0?fe[X]=Pt[X]:fe[X]=L[X])}var qt=arguments.length-2;if(qt===1)fe.children=B;else if(qt>1){for(var mn=Array(qt),_n=0;_n<qt;_n++)mn[_n]=arguments[_n+2];fe.children=mn}return Ea(y.type,nt,_e,Ze,St,At,fe)}function dt(y){return typeof y=="object"&&y!==null&&y.$$typeof===o}var Ie=".",an=":";function ur(y){var L=/[=:]/g,B={"=":"=0",":":"=2"},X=y.replace(L,function(fe){return B[fe]});return"$"+X}var Pe=!1,ze=/\/+/g;function vn(y){return y.replace(ze,"$&/")}function Zt(y,L){return typeof y=="object"&&y!==null&&y.key!=null?(Nn(y.key),ur(""+y.key)):L.toString(36)}function ut(y,L,B,X,fe){var nt=typeof y;(nt==="undefined"||nt==="boolean")&&(y=null);var _e=!1;if(y===null)_e=!0;else switch(nt){case"string":case"number":_e=!0;break;case"object":switch(y.$$typeof){case o:case p:_e=!0}}if(_e){var Ze=y,St=fe(Ze),At=X===""?Ie+Zt(Ze,0):X;if(vt(St)){var Pt="";At!=null&&(Pt=vn(At)+"/"),ut(St,L,Pt,"",function(Ql){return Ql})}else St!=null&&(dt(St)&&(St.key&&(!Ze||Ze.key!==St.key)&&Nn(St.key),St=ye(St,B+(St.key&&(!Ze||Ze.key!==St.key)?vn(""+St.key)+"/":"")+At)),L.push(St));return 1}var qt,mn,_n=0,On=X===""?Ie:X+an;if(vt(y))for(var Gn=0;Gn<y.length;Gn++)qt=y[Gn],mn=On+Zt(qt,Gn),_n+=ut(qt,L,B,mn,fe);else{var zr=Ee(y);if(typeof zr=="function"){var cn=y;zr===cn.entries&&(Pe||Oe("Using Maps as children is not supported. Use an array of keyed ReactElements instead."),Pe=!0);for(var Si=zr.call(cn),aa,Yo=0;!(aa=Si.next()).done;)qt=aa.value,mn=On+Zt(qt,Yo++),_n+=ut(qt,L,B,mn,fe)}else if(nt==="object"){var Yl=String(y);throw new Error("Objects are not valid as a React child (found: "+(Yl==="[object Object]"?"object with keys {"+Object.keys(y).join(", ")+"}":Yl)+"). If you meant to render a collection of children, use an array instead.")}}return _n}function lr(y,L,B){if(y==null)return y;var X=[],fe=0;return ut(y,X,"","",function(nt){return L.call(B,nt,fe++)}),X}function pi(y){var L=0;return lr(y,function(){L++}),L}function or(y,L,B){lr(y,function(){L.apply(this,arguments)},B)}function Ot(y){return lr(y,function(L){return L})||[]}function wr(y){if(!dt(y))throw new Error("React.Children.only expected to receive a single React element child.");return y}function Ur(y){var L={$$typeof:F,_currentValue:y,_currentValue2:y,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null};L.Provider={$$typeof:R,_context:L};var B=!1,X=!1,fe=!1;{var nt={$$typeof:F,_context:L};Object.defineProperties(nt,{Provider:{get:function(){return X||(X=!0,oe("Rendering <Context.Consumer.Provider> is not supported and will be removed in a future major release. Did you mean to render <Context.Provider> instead?")),L.Provider},set:function(_e){L.Provider=_e}},_currentValue:{get:function(){return L._currentValue},set:function(_e){L._currentValue=_e}},_currentValue2:{get:function(){return L._currentValue2},set:function(_e){L._currentValue2=_e}},_threadCount:{get:function(){return L._threadCount},set:function(_e){L._threadCount=_e}},Consumer:{get:function(){return B||(B=!0,oe("Rendering <Context.Consumer.Consumer> is not supported and will be removed in a future major release. Did you mean to render <Context.Consumer> instead?")),L.Consumer}},displayName:{get:function(){return L.displayName},set:function(_e){fe||(Oe("Setting `displayName` on Context.Consumer has no effect. You should set it directly on the context with Context.displayName = '%s'.",_e),fe=!0)}}}),L.Consumer=nt}return L._currentRenderer=null,L._currentRenderer2=null,L}var sr=-1,Vn=0,Mr=1,Za=2;function $i(y){if(y._status===sr){var L=y._result,B=L();if(B.then(function(nt){if(y._status===Vn||y._status===sr){var _e=y;_e._status=Mr,_e._result=nt}},function(nt){if(y._status===Vn||y._status===sr){var _e=y;_e._status=Za,_e._result=nt}}),y._status===sr){var X=y;X._status=Vn,X._result=B}}if(y._status===Mr){var fe=y._result;return fe===void 0&&oe(`lazy: Expected the result of a dynamic import() call. Instead received: %s
1
+ import{a as hS,b as Hp}from"./chunk-LQ7ENG4V.js";import{a as wR}from"./chunk-IWOTLFOY.js";import{a as Pf,b as fS,c as dS,e as Ip,f as Au,g as Pp,i as pS,j as vS,k as OR,l as tc,m as bR,n as mS,p as AR}from"./chunk-7Y7AZRL3.js";import{a as LR}from"./chunk-5HBIIYSK.js";import{a as yS}from"./chunk-AAK376RT.js";import{h as di,i as Zn}from"./chunk-B4OMIONW.js";import{b as DR}from"./chunk-VBPMVVLV.js";import{a as NR,c as pa,e as nn,g as P}from"./chunk-VKWPEFWQ.js";var OS=pa(kt=>{"use strict";P();var Hf=Symbol.for("react.element"),UR=Symbol.for("react.portal"),MR=Symbol.for("react.fragment"),zR=Symbol.for("react.strict_mode"),FR=Symbol.for("react.profiler"),IR=Symbol.for("react.provider"),PR=Symbol.for("react.context"),HR=Symbol.for("react.forward_ref"),jR=Symbol.for("react.suspense"),kR=Symbol.for("react.memo"),BR=Symbol.for("react.lazy"),gS=Symbol.iterator;function VR(s){return s===null||typeof s!="object"?null:(s=gS&&s[gS]||s["@@iterator"],typeof s=="function"?s:null)}var TS={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_S=Object.assign,xS={};function nc(s,o,p){this.props=s,this.context=o,this.refs=xS,this.updater=p||TS}nc.prototype.isReactComponent={};nc.prototype.setState=function(s,o){if(typeof s!="object"&&typeof s!="function"&&s!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,s,o,"setState")};nc.prototype.forceUpdate=function(s){this.updater.enqueueForceUpdate(this,s,"forceUpdate")};function CS(){}CS.prototype=nc.prototype;function Uh(s,o,p){this.props=s,this.context=o,this.refs=xS,this.updater=p||TS}var Mh=Uh.prototype=new CS;Mh.constructor=Uh;_S(Mh,nc.prototype);Mh.isPureReactComponent=!0;var ES=Array.isArray,RS=Object.prototype.hasOwnProperty,zh={current:null},NS={key:!0,ref:!0,__self:!0,__source:!0};function DS(s,o,p){var E,h={},C=null,R=null;if(o!=null)for(E in o.ref!==void 0&&(R=o.ref),o.key!==void 0&&(C=""+o.key),o)RS.call(o,E)&&!NS.hasOwnProperty(E)&&(h[E]=o[E]);var F=arguments.length-2;if(F===1)h.children=p;else if(1<F){for(var A=Array(F),N=0;N<F;N++)A[N]=arguments[N+2];h.children=A}if(s&&s.defaultProps)for(E in F=s.defaultProps,F)h[E]===void 0&&(h[E]=F[E]);return{$$typeof:Hf,type:s,key:C,ref:R,props:h,_owner:zh.current}}function WR(s,o){return{$$typeof:Hf,type:s.type,key:o,ref:s.ref,props:s.props,_owner:s._owner}}function Fh(s){return typeof s=="object"&&s!==null&&s.$$typeof===Hf}function GR(s){var o={"=":"=0",":":"=2"};return"$"+s.replace(/[=:]/g,function(p){return o[p]})}var SS=/\/+/g;function wh(s,o){return typeof s=="object"&&s!==null&&s.key!=null?GR(""+s.key):o.toString(36)}function kp(s,o,p,E,h){var C=typeof s;(C==="undefined"||C==="boolean")&&(s=null);var R=!1;if(s===null)R=!0;else switch(C){case"string":case"number":R=!0;break;case"object":switch(s.$$typeof){case Hf:case UR:R=!0}}if(R)return R=s,h=h(R),s=E===""?"."+wh(R,0):E,ES(h)?(p="",s!=null&&(p=s.replace(SS,"$&/")+"/"),kp(h,o,p,"",function(N){return N})):h!=null&&(Fh(h)&&(h=WR(h,p+(!h.key||R&&R.key===h.key?"":(""+h.key).replace(SS,"$&/")+"/")+s)),o.push(h)),1;if(R=0,E=E===""?".":E+":",ES(s))for(var F=0;F<s.length;F++){C=s[F];var A=E+wh(C,F);R+=kp(C,o,p,A,h)}else if(A=VR(s),typeof A=="function")for(s=A.call(s),F=0;!(C=s.next()).done;)C=C.value,A=E+wh(C,F++),R+=kp(C,o,p,A,h);else if(C==="object")throw o=String(s),Error("Objects are not valid as a React child (found: "+(o==="[object Object]"?"object with keys {"+Object.keys(s).join(", ")+"}":o)+"). If you meant to render a collection of children, use an array instead.");return R}function jp(s,o,p){if(s==null)return s;var E=[],h=0;return kp(s,E,"","",function(C){return o.call(p,C,h++)}),E}function YR(s){if(s._status===-1){var o=s._result;o=o(),o.then(function(p){(s._status===0||s._status===-1)&&(s._status=1,s._result=p)},function(p){(s._status===0||s._status===-1)&&(s._status=2,s._result=p)}),s._status===-1&&(s._status=0,s._result=o)}if(s._status===1)return s._result.default;throw s._result}var Ia={current:null},Bp={transition:null},QR={ReactCurrentDispatcher:Ia,ReactCurrentBatchConfig:Bp,ReactCurrentOwner:zh};function LS(){throw Error("act(...) is not supported in production builds of React.")}kt.Children={map:jp,forEach:function(s,o,p){jp(s,function(){o.apply(this,arguments)},p)},count:function(s){var o=0;return jp(s,function(){o++}),o},toArray:function(s){return jp(s,function(o){return o})||[]},only:function(s){if(!Fh(s))throw Error("React.Children.only expected to receive a single React element child.");return s}};kt.Component=nc;kt.Fragment=MR;kt.Profiler=FR;kt.PureComponent=Uh;kt.StrictMode=zR;kt.Suspense=jR;kt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=QR;kt.act=LS;kt.cloneElement=function(s,o,p){if(s==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+s+".");var E=_S({},s.props),h=s.key,C=s.ref,R=s._owner;if(o!=null){if(o.ref!==void 0&&(C=o.ref,R=zh.current),o.key!==void 0&&(h=""+o.key),s.type&&s.type.defaultProps)var F=s.type.defaultProps;for(A in o)RS.call(o,A)&&!NS.hasOwnProperty(A)&&(E[A]=o[A]===void 0&&F!==void 0?F[A]:o[A])}var A=arguments.length-2;if(A===1)E.children=p;else if(1<A){F=Array(A);for(var N=0;N<A;N++)F[N]=arguments[N+2];E.children=F}return{$$typeof:Hf,type:s.type,key:h,ref:C,props:E,_owner:R}};kt.createContext=function(s){return s={$$typeof:PR,_currentValue:s,_currentValue2:s,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},s.Provider={$$typeof:IR,_context:s},s.Consumer=s};kt.createElement=DS;kt.createFactory=function(s){var o=DS.bind(null,s);return o.type=s,o};kt.createRef=function(){return{current:null}};kt.forwardRef=function(s){return{$$typeof:HR,render:s}};kt.isValidElement=Fh;kt.lazy=function(s){return{$$typeof:BR,_payload:{_status:-1,_result:s},_init:YR}};kt.memo=function(s,o){return{$$typeof:kR,type:s,compare:o===void 0?null:o}};kt.startTransition=function(s){var o=Bp.transition;Bp.transition={};try{s()}finally{Bp.transition=o}};kt.unstable_act=LS;kt.useCallback=function(s,o){return Ia.current.useCallback(s,o)};kt.useContext=function(s){return Ia.current.useContext(s)};kt.useDebugValue=function(){};kt.useDeferredValue=function(s){return Ia.current.useDeferredValue(s)};kt.useEffect=function(s,o){return Ia.current.useEffect(s,o)};kt.useId=function(){return Ia.current.useId()};kt.useImperativeHandle=function(s,o,p){return Ia.current.useImperativeHandle(s,o,p)};kt.useInsertionEffect=function(s,o){return Ia.current.useInsertionEffect(s,o)};kt.useLayoutEffect=function(s,o){return Ia.current.useLayoutEffect(s,o)};kt.useMemo=function(s,o){return Ia.current.useMemo(s,o)};kt.useReducer=function(s,o,p){return Ia.current.useReducer(s,o,p)};kt.useRef=function(s){return Ia.current.useRef(s)};kt.useState=function(s){return Ia.current.useState(s)};kt.useSyncExternalStore=function(s,o,p){return Ia.current.useSyncExternalStore(s,o,p)};kt.useTransition=function(){return Ia.current.useTransition()};kt.version="18.3.1"});var bS=pa((Bt,Vp)=>{"use strict";P();process.env.NODE_ENV!=="production"&&(function(){"use strict";typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error);var s="18.3.1",o=Symbol.for("react.element"),p=Symbol.for("react.portal"),E=Symbol.for("react.fragment"),h=Symbol.for("react.strict_mode"),C=Symbol.for("react.profiler"),R=Symbol.for("react.provider"),F=Symbol.for("react.context"),A=Symbol.for("react.forward_ref"),N=Symbol.for("react.suspense"),le=Symbol.for("react.suspense_list"),$=Symbol.for("react.memo"),xe=Symbol.for("react.lazy"),Le=Symbol.for("react.offscreen"),Re=Symbol.iterator,he="@@iterator";function Ee(y){if(y===null||typeof y!="object")return null;var L=Re&&y[Re]||y[he];return typeof L=="function"?L:null}var $e={current:null},st={transition:null},et={current:null,isBatchingLegacy:!1,didScheduleLegacyUpdate:!1},Xe={current:null},Xt={},qe=null;function Ve(y){qe=y}Xt.setExtraStackFrame=function(y){qe=y},Xt.getCurrentStack=null,Xt.getStackAddendum=function(){var y="";qe&&(y+=qe);var L=Xt.getCurrentStack;return L&&(y+=L()||""),y};var rn=!1,We=!1,gt=!1,Me=!1,G=!1,ce={ReactCurrentDispatcher:$e,ReactCurrentBatchConfig:st,ReactCurrentOwner:Xe};ce.ReactDebugCurrentFrame=Xt,ce.ReactCurrentActQueue=et;function Oe(y){{for(var L=arguments.length,B=new Array(L>1?L-1:0),X=1;X<L;X++)B[X-1]=arguments[X];Tt("warn",y,B)}}function oe(y){{for(var L=arguments.length,B=new Array(L>1?L-1:0),X=1;X<L;X++)B[X-1]=arguments[X];Tt("error",y,B)}}function Tt(y,L,B){{var X=ce.ReactDebugCurrentFrame,fe=X.getStackAddendum();fe!==""&&(L+="%s",B=B.concat([fe]));var nt=B.map(function(_e){return String(_e)});nt.unshift("Warning: "+L),Function.prototype.apply.call(console[y],console,nt)}}var je={};function Ct(y,L){{var B=y.constructor,X=B&&(B.displayName||B.name)||"ReactClass",fe=X+"."+L;if(je[fe])return;oe("Can't call %s on a component that is not yet mounted. This is a no-op, but it might indicate a bug in your application. Instead, assign to `this.state` directly or define a `state = {};` class property with the desired state in the %s component.",L,X),je[fe]=!0}}var we={isMounted:function(y){return!1},enqueueForceUpdate:function(y,L,B){Ct(y,"forceUpdate")},enqueueReplaceState:function(y,L,B,X){Ct(y,"replaceState")},enqueueSetState:function(y,L,B,X){Ct(y,"setState")}},_t=Object.assign,rt={};Object.freeze(rt);function Gt(y,L,B){this.props=y,this.context=L,this.refs=rt,this.updater=B||we}Gt.prototype.isReactComponent={},Gt.prototype.setState=function(y,L){if(typeof y!="object"&&typeof y!="function"&&y!=null)throw new Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,y,L,"setState")},Gt.prototype.forceUpdate=function(y){this.updater.enqueueForceUpdate(this,y,"forceUpdate")};{var Je={isMounted:["isMounted","Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks."],replaceState:["replaceState","Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236)."]},bn=function(y,L){Object.defineProperty(Gt.prototype,y,{get:function(){Oe("%s(...) is deprecated in plain JavaScript React classes. %s",L[0],L[1])}})};for(var Kt in Je)Je.hasOwnProperty(Kt)&&bn(Kt,Je[Kt])}function tt(){}tt.prototype=Gt.prototype;function w(y,L,B){this.props=y,this.context=L,this.refs=rt,this.updater=B||we}var J=w.prototype=new tt;J.constructor=w,_t(J,Gt.prototype),J.isPureReactComponent=!0;function Ke(){var y={current:null};return Object.seal(y),y}var Yt=Array.isArray;function vt(y){return Yt(y)}function Dt(y){{var L=typeof Symbol=="function"&&Symbol.toStringTag,B=L&&y[Symbol.toStringTag]||y.constructor.name||"Object";return B}}function Et(y){try{return Qt(y),!1}catch{return!0}}function Qt(y){return""+y}function Nn(y){if(Et(y))return oe("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",Dt(y)),Qt(y)}function An(y,L,B){var X=y.displayName;if(X)return X;var fe=L.displayName||L.name||"";return fe!==""?B+"("+fe+")":B}function Bn(y){return y.displayName||"Context"}function gn(y){if(y==null)return null;if(typeof y.tag=="number"&&oe("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof y=="function")return y.displayName||y.name||null;if(typeof y=="string")return y;switch(y){case E:return"Fragment";case p:return"Portal";case C:return"Profiler";case h:return"StrictMode";case N:return"Suspense";case le:return"SuspenseList"}if(typeof y=="object")switch(y.$$typeof){case F:var L=y;return Bn(L)+".Consumer";case R:var B=y;return Bn(B._context)+".Provider";case A:return An(y,y.render,"ForwardRef");case $:var X=y.displayName||null;return X!==null?X:gn(y.type)||"Memo";case xe:{var fe=y,nt=fe._payload,_e=fe._init;try{return gn(_e(nt))}catch{return null}}}return null}var $n=Object.prototype.hasOwnProperty,br={key:!0,ref:!0,__self:!0,__source:!0},ha,on,Ar;Ar={};function ir(y){if($n.call(y,"ref")){var L=Object.getOwnPropertyDescriptor(y,"ref").get;if(L&&L.isReactWarning)return!1}return y.ref!==void 0}function Pa(y){if($n.call(y,"key")){var L=Object.getOwnPropertyDescriptor(y,"key").get;if(L&&L.isReactWarning)return!1}return y.key!==void 0}function Ka(y,L){var B=function(){ha||(ha=!0,oe("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",L))};B.isReactWarning=!0,Object.defineProperty(y,"key",{get:B,configurable:!0})}function ya(y,L){var B=function(){on||(on=!0,oe("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",L))};B.isReactWarning=!0,Object.defineProperty(y,"ref",{get:B,configurable:!0})}function ga(y){if(typeof y.ref=="string"&&Xe.current&&y.__self&&Xe.current.stateNode!==y.__self){var L=gn(Xe.current.type);Ar[L]||(oe('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',L,y.ref),Ar[L]=!0)}}var Ea=function(y,L,B,X,fe,nt,_e){var Ze={$$typeof:o,type:y,key:L,ref:B,props:_e,_owner:nt};return Ze._store={},Object.defineProperty(Ze._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(Ze,"_self",{configurable:!1,enumerable:!1,writable:!1,value:X}),Object.defineProperty(Ze,"_source",{configurable:!1,enumerable:!1,writable:!1,value:fe}),Object.freeze&&(Object.freeze(Ze.props),Object.freeze(Ze)),Ze};function ta(y,L,B){var X,fe={},nt=null,_e=null,Ze=null,St=null;if(L!=null){ir(L)&&(_e=L.ref,ga(L)),Pa(L)&&(Nn(L.key),nt=""+L.key),Ze=L.__self===void 0?null:L.__self,St=L.__source===void 0?null:L.__source;for(X in L)$n.call(L,X)&&!br.hasOwnProperty(X)&&(fe[X]=L[X])}var At=arguments.length-2;if(At===1)fe.children=B;else if(At>1){for(var Pt=Array(At),qt=0;qt<At;qt++)Pt[qt]=arguments[qt+2];Object.freeze&&Object.freeze(Pt),fe.children=Pt}if(y&&y.defaultProps){var mn=y.defaultProps;for(X in mn)fe[X]===void 0&&(fe[X]=mn[X])}if(nt||_e){var _n=typeof y=="function"?y.displayName||y.name||"Unknown":y;nt&&Ka(fe,_n),_e&&ya(fe,_n)}return Ea(y,nt,_e,Ze,St,Xe.current,fe)}function ye(y,L){var B=Ea(y.type,L,y.ref,y._self,y._source,y._owner,y.props);return B}function Ge(y,L,B){if(y==null)throw new Error("React.cloneElement(...): The argument must be a React element, but you passed "+y+".");var X,fe=_t({},y.props),nt=y.key,_e=y.ref,Ze=y._self,St=y._source,At=y._owner;if(L!=null){ir(L)&&(_e=L.ref,At=Xe.current),Pa(L)&&(Nn(L.key),nt=""+L.key);var Pt;y.type&&y.type.defaultProps&&(Pt=y.type.defaultProps);for(X in L)$n.call(L,X)&&!br.hasOwnProperty(X)&&(L[X]===void 0&&Pt!==void 0?fe[X]=Pt[X]:fe[X]=L[X])}var qt=arguments.length-2;if(qt===1)fe.children=B;else if(qt>1){for(var mn=Array(qt),_n=0;_n<qt;_n++)mn[_n]=arguments[_n+2];fe.children=mn}return Ea(y.type,nt,_e,Ze,St,At,fe)}function dt(y){return typeof y=="object"&&y!==null&&y.$$typeof===o}var Ie=".",an=":";function ur(y){var L=/[=:]/g,B={"=":"=0",":":"=2"},X=y.replace(L,function(fe){return B[fe]});return"$"+X}var Pe=!1,ze=/\/+/g;function vn(y){return y.replace(ze,"$&/")}function Zt(y,L){return typeof y=="object"&&y!==null&&y.key!=null?(Nn(y.key),ur(""+y.key)):L.toString(36)}function ut(y,L,B,X,fe){var nt=typeof y;(nt==="undefined"||nt==="boolean")&&(y=null);var _e=!1;if(y===null)_e=!0;else switch(nt){case"string":case"number":_e=!0;break;case"object":switch(y.$$typeof){case o:case p:_e=!0}}if(_e){var Ze=y,St=fe(Ze),At=X===""?Ie+Zt(Ze,0):X;if(vt(St)){var Pt="";At!=null&&(Pt=vn(At)+"/"),ut(St,L,Pt,"",function(Ql){return Ql})}else St!=null&&(dt(St)&&(St.key&&(!Ze||Ze.key!==St.key)&&Nn(St.key),St=ye(St,B+(St.key&&(!Ze||Ze.key!==St.key)?vn(""+St.key)+"/":"")+At)),L.push(St));return 1}var qt,mn,_n=0,On=X===""?Ie:X+an;if(vt(y))for(var Gn=0;Gn<y.length;Gn++)qt=y[Gn],mn=On+Zt(qt,Gn),_n+=ut(qt,L,B,mn,fe);else{var zr=Ee(y);if(typeof zr=="function"){var cn=y;zr===cn.entries&&(Pe||Oe("Using Maps as children is not supported. Use an array of keyed ReactElements instead."),Pe=!0);for(var Si=zr.call(cn),aa,Yo=0;!(aa=Si.next()).done;)qt=aa.value,mn=On+Zt(qt,Yo++),_n+=ut(qt,L,B,mn,fe)}else if(nt==="object"){var Yl=String(y);throw new Error("Objects are not valid as a React child (found: "+(Yl==="[object Object]"?"object with keys {"+Object.keys(y).join(", ")+"}":Yl)+"). If you meant to render a collection of children, use an array instead.")}}return _n}function lr(y,L,B){if(y==null)return y;var X=[],fe=0;return ut(y,X,"","",function(nt){return L.call(B,nt,fe++)}),X}function pi(y){var L=0;return lr(y,function(){L++}),L}function or(y,L,B){lr(y,function(){L.apply(this,arguments)},B)}function Ot(y){return lr(y,function(L){return L})||[]}function wr(y){if(!dt(y))throw new Error("React.Children.only expected to receive a single React element child.");return y}function Ur(y){var L={$$typeof:F,_currentValue:y,_currentValue2:y,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null};L.Provider={$$typeof:R,_context:L};var B=!1,X=!1,fe=!1;{var nt={$$typeof:F,_context:L};Object.defineProperties(nt,{Provider:{get:function(){return X||(X=!0,oe("Rendering <Context.Consumer.Provider> is not supported and will be removed in a future major release. Did you mean to render <Context.Provider> instead?")),L.Provider},set:function(_e){L.Provider=_e}},_currentValue:{get:function(){return L._currentValue},set:function(_e){L._currentValue=_e}},_currentValue2:{get:function(){return L._currentValue2},set:function(_e){L._currentValue2=_e}},_threadCount:{get:function(){return L._threadCount},set:function(_e){L._threadCount=_e}},Consumer:{get:function(){return B||(B=!0,oe("Rendering <Context.Consumer.Consumer> is not supported and will be removed in a future major release. Did you mean to render <Context.Consumer> instead?")),L.Consumer}},displayName:{get:function(){return L.displayName},set:function(_e){fe||(Oe("Setting `displayName` on Context.Consumer has no effect. You should set it directly on the context with Context.displayName = '%s'.",_e),fe=!0)}}}),L.Consumer=nt}return L._currentRenderer=null,L._currentRenderer2=null,L}var sr=-1,Vn=0,Mr=1,Za=2;function $i(y){if(y._status===sr){var L=y._result,B=L();if(B.then(function(nt){if(y._status===Vn||y._status===sr){var _e=y;_e._status=Mr,_e._result=nt}},function(nt){if(y._status===Vn||y._status===sr){var _e=y;_e._status=Za,_e._result=nt}}),y._status===sr){var X=y;X._status=Vn,X._result=B}}if(y._status===Mr){var fe=y._result;return fe===void 0&&oe(`lazy: Expected the result of a dynamic import() call. Instead received: %s
2
2
 
3
3
  Your code should look like:
4
4
  const MyComponent = lazy(() => import('./MyComponent'))
@@ -1,4 +1,4 @@
1
- import{a as _,j as B,n as $}from"./chunk-YTL45RXR.js";import{f as U,g as C}from"./chunk-WPDJVUTY.js";import{e as y}from"./chunk-XLMKHTJ5.js";import{l as v,m as P}from"./chunk-DVFVO6ZE.js";import{Ga as E}from"./chunk-YKDRUAY3.js";import{Eb as m}from"./chunk-ZMOW2YZ4.js";import{g as T}from"./chunk-VKWPEFWQ.js";T();var w=20,L=1024*1024,A=2;function re(t,e,r,s,o={},l){let n=_(r),i=new Map,c=!1,u=a=>{c||=a.success,i.set(a.key,a)},g=a=>a.total===0?"[100%]":`[${Math.round(a.current/a.total*100)}%]`,h=S(t,e,n).then(a=>{a.forEach(u)}),p=Promise.all([s.ready(),h]).then(()=>I(n,s,t,e,u)),d=p.then(a=>a.promise).then(()=>x(n,s,t,e,o,u)),f=o?.deferPartialWork?h:d.then(a=>a.promise);return o?.backgroundWorkCatch&&Promise.all([h,p.then(a=>a.promise),d.then(a=>a.promise)]).catch(o.backgroundWorkCatch),{uploadResults:i,get hasChanges(){return c},workPromise:f,renderThemeSyncProgress:async()=>{if(o?.deferPartialWork)return;let{progress:a,promise:F}=await p,k=o.multiEnvironment?4e3:1e3;await y(b({promise:F,titleGetter:()=>`Uploading files to remote theme ${g(a)}`,updateInterval:k}),l?.stderr,o?.multiEnvironment);let{progress:J,promise:j}=await d;await y(b({promise:j,titleGetter:()=>`Cleaning your remote theme ${g(J)}`,updateInterval:k}),l?.stderr,o?.multiEnvironment),await y([{title:"Theme upload complete",task:async()=>{}}],l?.stderr,o?.multiEnvironment),G(i,o?.environment)}}}function b({promise:t,titleGetter:e,updateInterval:r}){let s=[],o=()=>{s.push({title:e(),task:async(l,n)=>{await Promise.race([t,new Promise(c=>setTimeout(()=>c("timeout"),r))])==="timeout"?o():n.title=e()}})};return o(),s}function x(t,e,r,s,o,l){if(o.nodelete)return{progress:{current:0,total:0},promise:Promise.resolve()};let n=R(t,e),i=D(n),c={current:0,total:i.length};if(i.length===0)return{progress:c,promise:Promise.resolve()};let u=[];for(let h=0;h<i.length;h+=w){let p=i.slice(h,h+w),d=v(r.id,p.map(f=>f.key),s).then(f=>{f.forEach(a=>{if(l(a),!a.success){let F=a.errors?.asset?.map(k=>`-${k}`).join(`
1
+ import{a as _,j as B,n as $}from"./chunk-OKRKVVTK.js";import{f as U,g as C}from"./chunk-36S6MFJQ.js";import{e as y}from"./chunk-TXMZPF2U.js";import{l as v,m as P}from"./chunk-RSNFNZ6F.js";import{Ha as E}from"./chunk-UORSJB4A.js";import{Eb as m}from"./chunk-OIQ5NQ5I.js";import{g as T}from"./chunk-VKWPEFWQ.js";T();var w=20,L=1024*1024,A=2;function re(t,e,r,s,o={},l){let n=_(r),i=new Map,c=!1,u=a=>{c||=a.success,i.set(a.key,a)},g=a=>a.total===0?"[100%]":`[${Math.round(a.current/a.total*100)}%]`,h=S(t,e,n).then(a=>{a.forEach(u)}),p=Promise.all([s.ready(),h]).then(()=>I(n,s,t,e,u)),d=p.then(a=>a.promise).then(()=>x(n,s,t,e,o,u)),f=o?.deferPartialWork?h:d.then(a=>a.promise);return o?.backgroundWorkCatch&&Promise.all([h,p.then(a=>a.promise),d.then(a=>a.promise)]).catch(o.backgroundWorkCatch),{uploadResults:i,get hasChanges(){return c},workPromise:f,renderThemeSyncProgress:async()=>{if(o?.deferPartialWork)return;let{progress:a,promise:F}=await p,k=o.multiEnvironment?4e3:1e3;await y(b({promise:F,titleGetter:()=>`Uploading files to remote theme ${g(a)}`,updateInterval:k}),l?.stderr,o?.multiEnvironment);let{progress:J,promise:j}=await d;await y(b({promise:j,titleGetter:()=>`Cleaning your remote theme ${g(J)}`,updateInterval:k}),l?.stderr,o?.multiEnvironment),await y([{title:"Theme upload complete",task:async()=>{}}],l?.stderr,o?.multiEnvironment),G(i,o?.environment)}}}function b({promise:t,titleGetter:e,updateInterval:r}){let s=[],o=()=>{s.push({title:e(),task:async(l,n)=>{await Promise.race([t,new Promise(c=>setTimeout(()=>c("timeout"),r))])==="timeout"?o():n.title=e()}})};return o(),s}function x(t,e,r,s,o,l){if(o.nodelete)return{progress:{current:0,total:0},promise:Promise.resolve()};let n=R(t,e),i=D(n),c={current:0,total:i.length};if(i.length===0)return{progress:c,promise:Promise.resolve()};let u=[];for(let h=0;h<i.length;h+=w){let p=i.slice(h,h+w),d=v(r.id,p.map(f=>f.key),s).then(f=>{f.forEach(a=>{if(l(a),!a.success){let F=a.errors?.asset?.map(k=>`-${k}`).join(`
2
2
  `);C(a.key,"delete")(new Error(`Failed to delete ${a.key}: ${F}`))}}),c.current+=p.length});u.push(d)}let g=Promise.all(u).then(()=>{c.current=c.total});return{progress:c,promise:g}}function R(t,e){let s=e.applyIgnoreFilters(t).filter(o=>!e.files.has(o.key));return m(`Files to be deleted:
3
3
  ${s.map(o=>`-${o.key}`).join(`
4
4
  `)}`),s}function D(t){let e=$(t);return[...e.contextualizedJsonFiles,...e.templateJsonFiles,...e.sectionJsonFiles,...e.otherJsonFiles,...e.sectionLiquidFiles,...e.blockLiquidFiles,...e.layoutFiles,...e.otherLiquidFiles,...e.configDataFile,...e.configStylesheetFiles,...e.documentationFiles,...e.configSchemaFile,...e.staticAssetFiles]}var q=[{key:"config/settings_schema.json",value:"[]"},{key:"layout/password.liquid",value:"{{ content_for_header }}{{ content_for_layout }}"},{key:"layout/theme.liquid",value:"{{ content_for_header }}{{ content_for_layout }}"}];async function S(t,e,r){let s=new Set(r.map(l=>l.key)),o=q.filter(({key:l})=>!s.has(l));return o.length>0?P(t.id,o,e):[]}function I(t,e,r,s,o){let l=z(e,t);e.unsyncedFileKeys.clear(),l.forEach(d=>e.unsyncedFileKeys.add(d.key));let{independentFiles:n,dependentFiles:i}=K(l),c={current:0,total:l.length},u=d=>d.length===0?Promise.resolve():Promise.all(N(d).map(f=>H(f,e,s,r.id,o).then(()=>{c.current+=f.length,f.forEach(a=>e.unsyncedFileKeys.delete(a.key))}))).then(()=>{}),g=i.reduce((d,f)=>d.then(()=>u(f)),Promise.resolve()),h=Promise.resolve().then(()=>u(n.flat())),p=Promise.all([g,h]).then(()=>{c.current=c.total});return{progress:c,promise:p}}function z(t,e){let r=W(t),s=t.applyIgnoreFilters(r),o=new Map(e.map(n=>[n.key,n])),l=s.filter(n=>{let i=o.get(n.key);return!i||i.checksum!==n.checksum});return m(`Files to be uploaded:
@@ -1,4 +1,4 @@
1
- import{a as r,c as i,d as n}from"./chunk-HYCNYUHW.js";import{b as e}from"./chunk-XEZPN5TR.js";import{b as a,c as s}from"./chunk-DMOLPSXF.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var t=class d extends e{static summary="Check whether auto-upgrade is enabled, disabled, or not yet configured.";static descriptionWithMarkdown=`Check whether auto-upgrade is enabled, disabled, or not yet configured.
1
+ import{a as r,c as i,d as n}from"./chunk-G7JO3W2R.js";import{b as e}from"./chunk-PSREELSQ.js";import{b as a,c as s}from"./chunk-IKXUYCK7.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var t=class d extends e{static summary="Check whether auto-upgrade is enabled, disabled, or not yet configured.";static descriptionWithMarkdown=`Check whether auto-upgrade is enabled, disabled, or not yet configured.
2
2
 
3
3
  When auto-upgrade is enabled, Shopify CLI automatically updates to the latest version after each command.
4
4
 
@@ -1,2 +1,2 @@
1
- import{h as g,j as S,l as s,m as I,o as E}from"./chunk-5534MHZW.js";import{a as p}from"./chunk-JALDNBTU.js";import{x as h,y as l,z as c}from"./chunk-2KUM2RU4.js";import{i as m}from"./chunk-TD6JBHUS.js";import{zb as u}from"./chunk-ZMOW2YZ4.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();a();function f(e){return S.encode(E(e))}function y(e){return g.encode({status:e.outcomes.some(({status:o})=>o==="failed")?"partial":"success",operations:e.outcomes.map(o=>o.status==="success"?{status:o.status,operationGid:o.operationId,operation:s(o.operation)}:{status:o.status,operationGid:o.operationId,operation:o.operation===null?null:s(o.operation),error:"error"in o?p(o.error):{type:"abort",message:o.userErrors.map(({message:i})=>i).join("; "),details:{userErrors:I(o.userErrors)}}})})}function T(e){j(e)}function Y(e,o){if(e.status==="failed"&&e.submission.operations.length===0){let i=["Subscription migration submission failed.",...e.failure.type==="submission"?e.failure.userErrors.map(({message:n})=>n):[]].join(`
1
+ import{h as g,j as S,l as s,m as I,o as E}from"./chunk-6B5KM3A4.js";import{a as p}from"./chunk-3JRB7Q3T.js";import{x as h,y as l,z as c}from"./chunk-7A4ZE5IS.js";import{j as m}from"./chunk-FJOVMEPN.js";import{zb as u}from"./chunk-OIQ5NQ5I.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();a();function f(e){return S.encode(E(e))}function y(e){return g.encode({status:e.outcomes.some(({status:o})=>o==="failed")?"partial":"success",operations:e.outcomes.map(o=>o.status==="success"?{status:o.status,operationGid:o.operationId,operation:s(o.operation)}:{status:o.status,operationGid:o.operationId,operation:o.operation===null?null:s(o.operation),error:"error"in o?p(o.error):{type:"abort",message:o.userErrors.map(({message:i})=>i).join("; "),details:{userErrors:I(o.userErrors)}}})})}function T(e){j(e)}function Y(e,o){if(e.status==="failed"&&e.submission.operations.length===0){let i=["Subscription migration submission failed.",...e.failure.type==="submission"?e.failure.userErrors.map(({message:n})=>n):[]].join(`
2
2
  `),r=new m(i);throw r.details=e.failure.type==="submission"?{batchIndex:e.failure.batchIndex,userErrors:e.failure.userErrors.map(({message:n,field:t})=>({message:n,fieldPath:t}))}:{operationGids:e.failure.operationIds},r}return e.status==="cancelled"?(o.json&&u(f(e)),0):(o.json?u(f(e)):e.status==="failed"?$(e):o.watch?h({headline:"Subscription migration operations.",body:e.submission.operations.map(({operation:i})=>b(i))}):j(e.submission),e.status==="failed"?1:0)}function k(e,o){let i=e.outcomes[0];if(e.outcomes.length===1&&i?.status==="failed"){if("error"in i)throw i.error;let n=new m(i.userErrors.map(({message:t})=>t).join("; "));throw n.details={operationGid:i.operationId,operation:i.operation===null?null:s(i.operation),userErrors:i.userErrors.map(({message:t,field:d})=>({message:t,fieldPath:d}))},n}let r=e.outcomes.some(({status:n})=>n==="failed");return o.json?u(y(e)):r?c({headline:"Some subscription migration operations could not be canceled.",body:M(e.outcomes)}):l({headline:"Subscription migration operations canceled.",body:M(e.outcomes)}),r?1:0}function j(e){let o=e.action==="schedule"?"scheduled":"unscheduled";l({headline:`Subscription migrations ${o}.`,body:[`Shops: ${e.total}`,"Operation IDs:",...e.operations.map(({operation:i})=>i.id),"Save every operation ID. You will need them to check or cancel this submission."]})}function $(e){if(e.failure.type==="operations"){c({headline:"Some subscription migration operations failed.",body:["Failed operation IDs:",...e.failure.operationIds,"Terminal operation outcomes:",...e.submission.operations.map(({operation:i})=>b(i)),"Save every operation ID. You will need them to inspect this submission."]});return}let o=e.submission.operations.map(({operation:i})=>i.id);c({headline:o.length===0?"Subscription migration submission failed.":"Some subscription migration operations were accepted before submission failed.",body:[...o.length===0?["Accepted operation IDs: None."]:["Accepted operation IDs:",...o],`Batch index: ${e.failure.batchIndex}`,"Errors:",...e.failure.userErrors.map(({message:i})=>i),...o.length===0?[]:["Save every accepted operation ID. You will need them to check or cancel accepted operations."]]})}function M(e){let o=e.filter(r=>r.status==="success"),i=e.filter(r=>r.status==="failed");return[...o.length===0?["Canceled operations: None."]:["Canceled operations:",...o.map(({operation:r})=>b(r))],...i.length===0?[]:["Failed operations:",...i.map(r=>{let n=r.operation?` (returned status: ${r.operation.status})`:"",t="error"in r?p(r.error).message:r.userErrors.map(({message:d})=>d).join("; ");return`${r.operationId}: ${t}${n}`})]]}function b(e){return`${e.id}: ${e.status} (${e.results.edges.length}/${e.total} settled)`}export{T as a,Y as b,k as c};
@@ -1,4 +1,4 @@
1
- import{c as Ae}from"./chunk-FAVPTYIR.js";import{a as Pe,c as ke}from"./chunk-VJG7VXFU.js";import{b as Ie}from"./chunk-EDWIWZWM.js";import{a as Ne}from"./chunk-RSZAAN37.js";import{K as Ge,P as ze,a as Re,h as $e,k as je}from"./chunk-HMPRWNGG.js";import{s as Se,x as _e}from"./chunk-JGLLABZR.js";import{R as xe,ba as Ce,da as Fe,fa as Le}from"./chunk-YYWSHRO2.js";import{F as Te,c as ve}from"./chunk-OJOF6IYG.js";import{I as ee}from"./chunk-YKDRUAY3.js";import{B as ne,D as se,E as pe,f as F,g as ie,i as re,p as oe}from"./chunk-4WBWZIN5.js";import{e as J}from"./chunk-3FZ4LE6A.js";import{a as E}from"./chunk-JIY6XWSC.js";import{b as ye,c as we,f as be}from"./chunk-DMOLPSXF.js";import{C as j,G as ue,x as me,y as de,z as fe}from"./chunk-2KUM2RU4.js";import{b as le}from"./chunk-H4K3F7PP.js";import{a as M}from"./chunk-LG3KEHGD.js";import{d as ce}from"./chunk-I3WRA2LH.js";import{i as f}from"./chunk-TD6JBHUS.js";import{Ba as T,Ia as W,Na as B,Sa as x,Ta as C,Ua as Z,Va as Q,_ as q,_a as X,ja as Y,la as K,lb as te,nb as ae,ra as _,ta as $,tb as y,ub as L,va as V,vb as v,zb as ge}from"./chunk-ZMOW2YZ4.js";import{b as h}from"./chunk-3PYDIBTX.js";import{f as he}from"./chunk-DOLVBTCB.js";import{b as Xe}from"./chunk-AE3IQG7S.js";import{c as p,d as R,e as O,o as U,p as H}from"./chunk-IWTNUJGY.js";import{e as Qe,g as l}from"./chunk-VKWPEFWQ.js";l();l();var g={reactRouter:{url:"https://github.com/Shopify/shopify-app-template-react-router",label:"Build a React Router app (recommended)",visible:!0,branches:{prompt:"For your React Router template, which language do you want?",options:{javascript:{branch:"javascript-cli",label:"JavaScript"},typescript:{branch:"main-cli",label:"TypeScript"}}}},remix:{url:"https://github.com/Shopify/shopify-app-template-remix",label:"Build a Remix app",visible:!1,deprecated:{replacement:"reactRouter"},branches:{prompt:"For your Remix template, which language do you want?",options:{javascript:{branch:"javascript",label:"JavaScript"},typescript:{branch:"main",label:"TypeScript"}}}},none:{url:"https://github.com/Shopify/shopify-app-template-extension-only",label:"Build an extension-only app",visible:!0},node:{url:"https://github.com/Shopify/shopify-app-template-node",visible:!1,deprecated:{replacement:"reactRouter"}},ruby:{url:"https://github.com/Shopify/shopify-app-template-ruby",visible:!1}},G=Object.keys(g),S=G.filter(e=>g[e].visible),Je=["reactRouter","none"],et=async e=>{let t=e.template,a=e.flavor,i={template:g.reactRouter.url};t??=await j({choices:Je.map(o=>({label:g[o].label||o,value:o})),message:"Get started building your app:",defaultValue:G.find(o=>g[o].url===i.template)});let r={...e,template:t,templateType:P(t)?t:"custom",globalCLIResult:{install:!1,alreadyInstalled:!1}},n,s;if(r.templateType!=="custom"){let o=g[r.templateType];n=o.url,o.branches&&(a?s=o.branches.options[a]?.branch:s=await j({message:o.branches.prompt||"Choose a flavor:",choices:Object.entries(o.branches.options).map(([d,c])=>({value:c.branch,label:c.label}))}))}return s&&(n=`${n}#${s}`),r.template=n||r.template||i.template,r.globalCLIResult=await ae(),r},De=et;function P(e){return G.includes(e)}function Ee(e){return e!==void 0&&P(e)&&g[e].branches!==void 0}l();l();import{platform as tt}from"os";async function Me({packageJSON:e,local:t,useGlobalCLI:a}){if(e.dependencies=e.dependencies??{},a?delete e.dependencies["@shopify/cli"]:e.dependencies["@shopify/cli"]=E,delete e.dependencies["@shopify/app"],t){let i=await at("cli");e.dependencies["@shopify/cli"]=i;let r={"@shopify/cli":i};e.overrides=e.overrides?{...e.overrides,...r}:r,e.resolutions=e.resolutions?{...e.resolutions,...r}:r}return e}async function at(e){return`file:${await X(`packages/${e}`,{type:"directory",cwd:U(import.meta.url)})}`}async function Oe({from:e,packageManager:t}){let a=tt()==="win32"&&t==="yarn"?["--network-concurrency","1"]:[];return oe({directory:R(e),packageManager:t,args:a})}l();async function z(e,t){let i=(await Q([p(e,"**",".git"),p(e,"**",".github"),p(e,"**",".gitmodules"),p(e,"**",".cli-liquid-bypass"),p(e,"LICENSE*"),p(e,"**","frontend/LICENSE*"),p(e,"package.json.cli2")],{dot:!0,onlyFiles:!1,onlyDirectories:!1,ignore:["**/node_modules/**"]})).map(s=>T(s,{force:!0})),r=new Set(ie[t]),n=F.filter(s=>!r.has(s)).map(s=>{let o=p(e,s);if(C(o))return W(o)});return Promise.all([...i,...n])}async function it(e){let t=e.packageManager,a=q(e.name),i=p(e.directory,a),r=Ae(e.template);await Ue(i,a),await rt(i),me({body:["Initializing project with",{command:t},`
1
+ import{c as Ae}from"./chunk-WHOD5I7N.js";import{a as Pe,c as ke}from"./chunk-WZ3QWPK5.js";import{b as Ie}from"./chunk-MBAPM5HA.js";import{a as Ne}from"./chunk-R5COVIJM.js";import{K as Ge,P as ze,a as Re,h as $e,k as je}from"./chunk-7FBOMPO5.js";import{u as Se,z as _e}from"./chunk-4KBOLN7Q.js";import{R as xe,ba as Ce,da as Fe,fa as Le}from"./chunk-4LJERO23.js";import{F as Te,c as ve}from"./chunk-HEB4YYM6.js";import{I as ee}from"./chunk-UORSJB4A.js";import{B as ne,D as se,E as pe,f as F,g as ie,i as re,p as oe}from"./chunk-OSASE35V.js";import{e as J}from"./chunk-CE6XQDAG.js";import{a as E}from"./chunk-EE72PCKT.js";import{b as ye,c as we,f as be}from"./chunk-IKXUYCK7.js";import{C as j,G as ue,x as me,y as de,z as fe}from"./chunk-7A4ZE5IS.js";import{b as le}from"./chunk-RNF6T6IO.js";import{a as M}from"./chunk-LG3KEHGD.js";import{d as ce}from"./chunk-HI5FTI3M.js";import{j as f}from"./chunk-FJOVMEPN.js";import{Ba as T,Ia as W,Na as B,Sa as x,Ta as C,Ua as Z,Va as Q,_ as q,_a as X,ja as Y,la as K,lb as te,nb as ae,ra as _,ta as $,tb as y,ub as L,va as V,vb as v,zb as ge}from"./chunk-OIQ5NQ5I.js";import{b as h}from"./chunk-3PYDIBTX.js";import{f as he}from"./chunk-A5BSUUNQ.js";import{b as Xe}from"./chunk-VBPMVVLV.js";import{c as p,d as R,e as O,o as U,p as H}from"./chunk-IWTNUJGY.js";import{e as Qe,g as l}from"./chunk-VKWPEFWQ.js";l();l();var g={reactRouter:{url:"https://github.com/Shopify/shopify-app-template-react-router",label:"Build a React Router app (recommended)",visible:!0,branches:{prompt:"For your React Router template, which language do you want?",options:{javascript:{branch:"javascript-cli",label:"JavaScript"},typescript:{branch:"main-cli",label:"TypeScript"}}}},remix:{url:"https://github.com/Shopify/shopify-app-template-remix",label:"Build a Remix app",visible:!1,deprecated:{replacement:"reactRouter"},branches:{prompt:"For your Remix template, which language do you want?",options:{javascript:{branch:"javascript",label:"JavaScript"},typescript:{branch:"main",label:"TypeScript"}}}},none:{url:"https://github.com/Shopify/shopify-app-template-extension-only",label:"Build an extension-only app",visible:!0},node:{url:"https://github.com/Shopify/shopify-app-template-node",visible:!1,deprecated:{replacement:"reactRouter"}},ruby:{url:"https://github.com/Shopify/shopify-app-template-ruby",visible:!1}},G=Object.keys(g),S=G.filter(e=>g[e].visible),Je=["reactRouter","none"],et=async e=>{let t=e.template,a=e.flavor,i={template:g.reactRouter.url};t??=await j({choices:Je.map(o=>({label:g[o].label||o,value:o})),message:"Get started building your app:",defaultValue:G.find(o=>g[o].url===i.template)});let r={...e,template:t,templateType:P(t)?t:"custom",globalCLIResult:{install:!1,alreadyInstalled:!1}},n,s;if(r.templateType!=="custom"){let o=g[r.templateType];n=o.url,o.branches&&(a?s=o.branches.options[a]?.branch:s=await j({message:o.branches.prompt||"Choose a flavor:",choices:Object.entries(o.branches.options).map(([d,c])=>({value:c.branch,label:c.label}))}))}return s&&(n=`${n}#${s}`),r.template=n||r.template||i.template,r.globalCLIResult=await ae(),r},De=et;function P(e){return G.includes(e)}function Ee(e){return e!==void 0&&P(e)&&g[e].branches!==void 0}l();l();import{platform as tt}from"os";async function Me({packageJSON:e,local:t,useGlobalCLI:a}){if(e.dependencies=e.dependencies??{},a?delete e.dependencies["@shopify/cli"]:e.dependencies["@shopify/cli"]=E,delete e.dependencies["@shopify/app"],t){let i=await at("cli");e.dependencies["@shopify/cli"]=i;let r={"@shopify/cli":i};e.overrides=e.overrides?{...e.overrides,...r}:r,e.resolutions=e.resolutions?{...e.resolutions,...r}:r}return e}async function at(e){return`file:${await X(`packages/${e}`,{type:"directory",cwd:U(import.meta.url)})}`}async function Oe({from:e,packageManager:t}){let a=tt()==="win32"&&t==="yarn"?["--network-concurrency","1"]:[];return oe({directory:R(e),packageManager:t,args:a})}l();async function z(e,t){let i=(await Q([p(e,"**",".git"),p(e,"**",".github"),p(e,"**",".gitmodules"),p(e,"**",".cli-liquid-bypass"),p(e,"LICENSE*"),p(e,"**","frontend/LICENSE*"),p(e,"package.json.cli2")],{dot:!0,onlyFiles:!1,onlyDirectories:!1,ignore:["**/node_modules/**"]})).map(s=>T(s,{force:!0})),r=new Set(ie[t]),n=F.filter(s=>!r.has(s)).map(s=>{let o=p(e,s);if(C(o))return W(o)});return Promise.all([...i,...n])}async function it(e){let t=e.packageManager,a=q(e.name),i=p(e.directory,a),r=Ae(e.template);await Ue(i,a),await rt(i),me({body:["Initializing project with",{command:t},`
2
2
  Use the`,{command:"--package-manager"},"flag to select a different package manager."]}),await Y(async o=>{let d=p(o,"download"),c=r.filePath?p(d,r.filePath):d,u=p(o,"app"),A=r.branch?`${r.baseURL}#${r.branch}`:r.baseURL;await V(d);let b=[{title:`Downloading template from ${A}`,task:async()=>{await ke({repoUrl:A,destination:d,shallow:!0})}}];b.push({title:"Parsing liquid",task:async()=>{await Ie(c,u,{dependency_manager:t,app_name:e.name})}},{title:"Updating package.json",task:async()=>{let m=(await ne(u)).content;m.name=a,m.author=await le()??"",m.private=!0;let I=["extensions/*"].concat(ot(u));switch(t){case"npm":case"yarn":case"bun":m.workspaces=I;break;case"pnpm":{await nt(u,I),await _(p(u,".npmrc"),`auto-install-peers=true
3
3
  `);break}case"homebrew":case"unknown":throw new re}await Me({packageJSON:m,local:e.local,directory:u,useGlobalCLI:e.useGlobalCLI}),await se(u,m)}}),e.postCloneActions.removeLockfilesFromGitignore&&b.push({title:"Removing lockfiles from .gitignore",task:async()=>{let m=p(u,".gitignore");if(await x(m)){let I=await K(m);F.forEach(Be=>{let Ze=new RegExp(`^${Be.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}$`,"gm");I=I.replace(Ze,"")}),await $(m,I.trim())}}}),await he()&&b.push({title:"[Shopifolks-only] Configuring the project's NPM registry",task:async()=>{let m=p(u,".npmrc");await _(m,`@shopify:registry=https://registry.npmjs.org
4
4
  `)}});let D=!1;b.push({title:"Preparing project directory",task:async()=>{await Ue(i,a),D=!0,await B(u,i)}}),b.push({title:`Installing dependencies with ${t}`,task:async()=>{await Oe({from:i,packageManager:t})}},{title:"Cleaning up",task:async()=>{await z(i,t)}},{title:"Initializing a Git repository...",task:async()=>{await Pe(i)}});try{await ue(b)}catch(m){throw D&&await T(i).catch(()=>{}),m}});let n;if(e.selectedAppOrNameResult.result==="new"){let o=await xe(i,e.name),d=e.selectedAppOrNameResult.org;n=await e.developerPlatformClient.createApp(d,o)}else n=e.selectedAppOrNameResult.app;return await Ge({directory:i,apiKey:n.apiKey,appId:n.id,organizationId:n.organizationId,configName:"shopify.app.toml",developerPlatformClient:e.developerPlatformClient,isNewApp:!0},!1),{app:(await ze({directory:i,clientId:void 0,forceRelink:!1,userProvidedConfigName:void 0})).app,remoteApp:n,projectName:a,packageManager:t,template:e.template}}async function Ue(e,t){if(await x(e))throw new f(`
@@ -1,2 +1,2 @@
1
- import{a as c}from"./chunk-LG3KEHGD.js";import{l as m}from"./chunk-TD6JBHUS.js";import{zb as u}from"./chunk-ZMOW2YZ4.js";import{b as e}from"./chunk-3PYDIBTX.js";import{b as H}from"./chunk-AE3IQG7S.js";import{e as b,g as n}from"./chunk-VKWPEFWQ.js";n();var p=e.object({id:e.string(),summary:e.string().optional(),hidden:e.boolean().default(!1)}),l=e.object({name:e.string(),description:e.string().optional(),hidden:e.boolean().default(!1)}),g=e.object({name:e.string(),description:e.string().optional(),required:e.boolean().default(!1),hidden:e.boolean().default(!1),options:e.array(e.string()).optional(),default:e.unknown().optional()}),h=e.object({name:e.string(),type:e.enum(["boolean","option"]),char:e.string().optional(),summary:e.string().optional(),description:e.string().optional(),env:e.string().optional(),required:e.boolean().default(!1),hidden:e.boolean().default(!1),options:e.array(e.string()).optional(),default:e.unknown().optional(),multiple:e.boolean().optional(),allowNo:e.boolean().optional(),aliases:e.array(e.string()).optional(),dependsOn:e.array(e.string()).optional(),exclusive:e.array(e.string()).optional(),exactlyOne:e.array(e.string()).optional()}),f=p.extend({description:e.string().optional(),aliases:e.array(e.string()),usage:e.union([e.string(),e.array(e.string())]).optional(),examples:e.array(e.union([e.string(),e.object({description:e.string(),command:e.string()})])).optional(),strict:e.boolean().default(!0),args:e.record(g),flags:e.record(h)}),a={commands:e.array(p),topics:e.array(l)},s=c({name:"HelpResult",schema:e.discriminatedUnion("kind",[e.object({kind:e.literal("root"),...a}),e.object({kind:e.literal("topic"),topic:l,...a}),e.object({kind:e.literal("command"),command:f,...a})]),definitions:{HelpCommandSummary:p,HelpTopic:l,HelpArgument:g,HelpFlag:h,HelpCommand:f}});n();var y=b(H(),1);async function k(r,o,i=!1){let t=new d(r,{all:i});if(await t.showHelp(o),!t.result)throw new m("Oclif did not resolve a help subject.");return t.result}var d=class extends y.Help{result;async showCommandHelp(o){let i=t=>this.opts.all===!0||!t.hidden;this.result=s.validate({kind:"command",command:{...o,args:Object.fromEntries(Object.entries(o.args).filter(([,t])=>i(t))),flags:Object.fromEntries(Object.entries(o.flags).filter(([,t])=>i(t)))},...this.listings(o.id)})}async showRootHelp(){this.result=s.validate({kind:"root",...this.listings()})}async showTopicHelp(o){this.result=s.validate({kind:"topic",topic:o,...this.listings(o.name)})}listings(o){let i=t=>o===void 0?this.opts.all===!0||!t.includes(":"):t.startsWith(`${o}:`)&&t.split(":").length===o.split(":").length+1;return{commands:this.sortedCommands.filter(t=>t.id&&i(t.id)).map(t=>({id:t.id,summary:t.summary??t.description?.split(`
1
+ import{a as c}from"./chunk-LG3KEHGD.js";import{n as m}from"./chunk-FJOVMEPN.js";import{zb as u}from"./chunk-OIQ5NQ5I.js";import{b as e}from"./chunk-3PYDIBTX.js";import{b as H}from"./chunk-VBPMVVLV.js";import{e as b,g as n}from"./chunk-VKWPEFWQ.js";n();var p=e.object({id:e.string(),summary:e.string().optional(),hidden:e.boolean().default(!1)}),l=e.object({name:e.string(),description:e.string().optional(),hidden:e.boolean().default(!1)}),g=e.object({name:e.string(),description:e.string().optional(),required:e.boolean().default(!1),hidden:e.boolean().default(!1),options:e.array(e.string()).optional(),default:e.unknown().optional()}),h=e.object({name:e.string(),type:e.enum(["boolean","option"]),char:e.string().optional(),summary:e.string().optional(),description:e.string().optional(),env:e.string().optional(),required:e.boolean().default(!1),hidden:e.boolean().default(!1),options:e.array(e.string()).optional(),default:e.unknown().optional(),multiple:e.boolean().optional(),allowNo:e.boolean().optional(),aliases:e.array(e.string()).optional(),dependsOn:e.array(e.string()).optional(),exclusive:e.array(e.string()).optional(),exactlyOne:e.array(e.string()).optional()}),f=p.extend({description:e.string().optional(),aliases:e.array(e.string()),usage:e.union([e.string(),e.array(e.string())]).optional(),examples:e.array(e.union([e.string(),e.object({description:e.string(),command:e.string()})])).optional(),strict:e.boolean().default(!0),args:e.record(g),flags:e.record(h)}),a={commands:e.array(p),topics:e.array(l)},s=c({name:"HelpResult",schema:e.discriminatedUnion("kind",[e.object({kind:e.literal("root"),...a}),e.object({kind:e.literal("topic"),topic:l,...a}),e.object({kind:e.literal("command"),command:f,...a})]),definitions:{HelpCommandSummary:p,HelpTopic:l,HelpArgument:g,HelpFlag:h,HelpCommand:f}});n();var y=b(H(),1);async function k(r,o,i=!1){let t=new d(r,{all:i});if(await t.showHelp(o),!t.result)throw new m("Oclif did not resolve a help subject.");return t.result}var d=class extends y.Help{result;async showCommandHelp(o){let i=t=>this.opts.all===!0||!t.hidden;this.result=s.validate({kind:"command",command:{...o,args:Object.fromEntries(Object.entries(o.args).filter(([,t])=>i(t))),flags:Object.fromEntries(Object.entries(o.flags).filter(([,t])=>i(t)))},...this.listings(o.id)})}async showRootHelp(){this.result=s.validate({kind:"root",...this.listings()})}async showTopicHelp(o){this.result=s.validate({kind:"topic",topic:o,...this.listings(o.name)})}listings(o){let i=t=>o===void 0?this.opts.all===!0||!t.includes(":"):t.startsWith(`${o}:`)&&t.split(":").length===o.split(":").length+1;return{commands:this.sortedCommands.filter(t=>t.id&&i(t.id)).map(t=>({id:t.id,summary:t.summary??t.description?.split(`
2
2
  `)[0],hidden:t.hidden??!1})),topics:this.sortedTopics.filter(t=>i(t.name))}}};n();function T(r){u(s.encode(r))}export{s as a,k as b,T as c};
@@ -1 +1 @@
1
- import{z as n}from"./chunk-2KUM2RU4.js";import{g as e}from"./chunk-VKWPEFWQ.js";e();function d({from:o,to:r}){n({headline:[{command:`shopify ${o}`},"has moved."],body:["This command will be removed in a future release. Use",{command:`shopify ${r}`},"instead."]})}export{d as a};
1
+ import{z as n}from"./chunk-7A4ZE5IS.js";import{g as e}from"./chunk-VKWPEFWQ.js";e();function d({from:o,to:r}){n({headline:[{command:`shopify ${o}`},"has moved."],body:["This command will be removed in a future release. Use",{command:`shopify ${r}`},"instead."]})}export{d as a};
@@ -1,4 +1,4 @@
1
- import{c as ae}from"./chunk-VJG7VXFU.js";import{b as P}from"./chunk-EDWIWZWM.js";import{a as fe}from"./chunk-SBN3ILXO.js";import{a as ue}from"./chunk-RSZAAN37.js";import{a as ie}from"./chunk-ASKBYEO7.js";import{a as re}from"./chunk-WE5KY6T6.js";import{P as me}from"./chunk-HMPRWNGG.js";import{Q as pe,V as de,d as ce,e as le}from"./chunk-YYWSHRO2.js";import{u as k,w as oe,x as se}from"./chunk-OJOF6IYG.js";import{a as F}from"./chunk-HVUMVDUG.js";import{C as B,p as O,x as W,y as S}from"./chunk-4WBWZIN5.js";import{b as te,c as ne,f as A}from"./chunk-DMOLPSXF.js";import{C as X,E as K,G as R,I as Q,y as H,z}from"./chunk-2KUM2RU4.js";import{e as b}from"./chunk-QBRRFFMZ.js";import{a as G}from"./chunk-LG3KEHGD.js";import{i as u}from"./chunk-TD6JBHUS.js";import{Na as V,Sa as x,Ta as Y,Va as J,X as h,_ as q,ja as w,pa as U,ub as T,va as v,xa as E,zb as ee}from"./chunk-ZMOW2YZ4.js";import{b as f}from"./chunk-3PYDIBTX.js";import{f as Z}from"./chunk-DOLVBTCB.js";import{b as Re}from"./chunk-AE3IQG7S.js";import{c as d,e as N,g as D,m as L,p as $}from"./chunk-IWTNUJGY.js";import{e as Se,g as p}from"./chunk-VKWPEFWQ.js";p();p();p();async function he(e,t,r,n={}){let{templates:a,groupOrder:i}=await e.templateSpecifications(t,n);return{templates:a.filter(o=>r.includes(o.identifier)||r.includes(o.type)),groupOrder:i}}p();p();async function ye(e,t){let r=e?.path??"",n=d(t,r);if(!await x(n))throw new u(`
1
+ import{c as ae}from"./chunk-WZ3QWPK5.js";import{b as P}from"./chunk-MBAPM5HA.js";import{a as fe}from"./chunk-5TJJVSCI.js";import{a as ue}from"./chunk-R5COVIJM.js";import{a as ie}from"./chunk-K4KKSBUW.js";import{a as re}from"./chunk-FOMMPAWZ.js";import{P as me}from"./chunk-7FBOMPO5.js";import{Q as pe,V as de,d as ce,e as le}from"./chunk-4LJERO23.js";import{u as k,w as oe,x as se}from"./chunk-HEB4YYM6.js";import{a as F}from"./chunk-U5BKU3OL.js";import{C as B,p as O,x as W,y as S}from"./chunk-OSASE35V.js";import{b as te,c as ne,f as A}from"./chunk-IKXUYCK7.js";import{C as X,E as K,G as R,I as Q,y as H,z}from"./chunk-7A4ZE5IS.js";import{e as b}from"./chunk-QBRRFFMZ.js";import{a as G}from"./chunk-LG3KEHGD.js";import{j as u}from"./chunk-FJOVMEPN.js";import{Na as V,Sa as x,Ta as Y,Va as J,X as h,_ as q,ja as w,pa as U,ub as T,va as v,xa as E,zb as ee}from"./chunk-OIQ5NQ5I.js";import{b as f}from"./chunk-3PYDIBTX.js";import{f as Z}from"./chunk-A5BSUUNQ.js";import{b as Re}from"./chunk-VBPMVVLV.js";import{c as d,e as N,g as D,m as L,p as $}from"./chunk-IWTNUJGY.js";import{e as Se,g as p}from"./chunk-VKWPEFWQ.js";p();p();p();async function he(e,t,r,n={}){let{templates:a,groupOrder:i}=await e.templateSpecifications(t,n);return{templates:a.filter(o=>r.includes(o.identifier)||r.includes(o.type)),groupOrder:i}}p();p();async function ye(e,t){let r=e?.path??"",n=d(t,r);if(!await x(n))throw new u(`
2
2
  The extension is not available for ${e?.value}`);return n}async function xe({name:e,app:t}){let r=q(e),n=d(t.directory,se.extensions.directoryName,r);if(await x(n))throw new u(`
3
3
  A directory with this name (${r}) already exists.
4
4
  Choose a new name for your extension.`);return await v(n),await U(d(n,k.lockFile)),n}var ge=["vanilla-js","preact","react","typescript","typescript-react","rust","wasm","liquid","config-only"];function C(e){switch(e){case"vanilla-js":case"preact":case"react":case"typescript":case"typescript-react":return"javascript";case"rust":case"wasm":return e;case void 0:case"liquid":case"config-only":return}}async function we(e){let t=e.extensionChoices.name,r=e.extensionChoices.flavor,n=e.extensionTemplate.supportedFlavors.find(o=>o.value===r),a=await xe({app:e.app,name:t}),i=e.cloneUrl??e.extensionTemplate.url,s={directory:a,url:i,app:e.app,project:e.project,type:e.extensionTemplate.type,name:t,extensionFlavor:n,onGetTemplateRepository:e.onGetTemplateRepository??(async(o,l)=>{await ae({repoUrl:o,destination:l,shallow:!0})})};return await Ae(s),{directory:L(a),extensionTemplate:e.extensionTemplate}}async function Ae(e){try{switch(e.type){case"theme":await Me(e);break;case"function":await je(e);break;default:await Ge(e);break}let t=d(e.directory,k.lockFile);await E(t)}catch(t){throw await Ce(e.directory),e.project.packageManager==="pnpm"&&Ie(t)?new u("Your extension couldn't be generated because pnpm blocked the build scripts of some of its dependencies.",null,[["Run",{command:"pnpm approve-builds"},"in your app directory to approve the build scripts."],["Run",{command:T(e.project.packageManager,"shopify app generate extension")},"again."]]):t}}async function Ce(e){try{await E(e,{maxRetries:10,retryDelay:100})}catch{z({headline:["Couldn't remove",{filePath:e},{char:"."}],body:"Delete this directory manually before generating an extension with the same name."})}}function Ie(e){return e instanceof Error&&e.message.includes("ERR_PNPM_IGNORED_BUILDS")}async function Me({directory:e,url:t,type:r,name:n,extensionFlavor:a,onGetTemplateRepository:i}){return w(async s=>{let o=await I(t,a,s,i);await P(o,e,{name:n,type:r,uid:b(h(n))})})}async function je({directory:e,url:t,app:r,project:n,name:a,extensionFlavor:i,onGetTemplateRepository:s}){let o=C(i?.value),l=[];l.push({title:"Generating function extension",task:async()=>{if(await w(async c=>{let m=await I(t,i,c,s);await P(m,e,{name:a,handle:h(a),flavor:i?.value,uid:b(h(a))})}),o==="javascript"){let c=ve(i?.value??"rust");await Ee(e,c,"!(*.graphql)")}}}),o==="javascript"&&l.push({title:"Installing additional dependencies",task:async()=>{n.usesWorkspaces&&await O({packageManager:n.packageManager,directory:n.directory});let c=Ne(o);await S(c,{packageManager:n.packageManager,type:"prod",directory:n.usesWorkspaces?e:n.directory})}}),o==="javascript"&&l.push({title:"Building GraphQL types",task:async()=>{let c=re();try{await le({directory:e,isJavaScript:!0},{...c,app:r})}finally{c.stdout!==process.stdout&&c.stdout.end(),c.stderr!==process.stderr&&c.stderr.end()}}}),await R(l)}async function Ge({directory:e,url:t,app:r,project:n,name:a,extensionFlavor:i,onGetTemplateRepository:s}){let o=C(i?.value),l=[{title:"Generating extension",task:async()=>{let c=ve(i?.value??"vanilla-js");await w(async m=>{let y=await I(t,i,m,s);await P(y,e,{srcFileExtension:c,name:a,handle:h(a),flavor:i?.value??"",uid:b(h(a))})}),o==="javascript"&&await Ee(e,c)}},{title:"Installing dependencies",task:async()=>{let c=n.packageManager;if(n.usesWorkspaces)C(i?.value)==="javascript"&&await O({packageManager:c,directory:n.directory});else{await De(n.directory,i?.value);let m=d(e,"package.json"),y=await Le(m);await S(y,{packageManager:c,type:"prod",directory:n.directory}),await E(m)}}}];l.push({title:"Update shared type definition",task:async()=>{await de(r)}}),await R(l)}function ve(e){return{"vanilla-js":"js",preact:"jsx",react:"jsx",typescript:"ts","typescript-react":"tsx",rust:"rs",wasm:"wasm",liquid:"liquid","config-only":""}[e]??"js"}function Ne(e){let t=[];return e==="javascript"&&t.push({name:"@shopify/shopify_function",version:`~${ce}.0.0`}),t}async function Ee(e,t,r="*"){let n=await J(d(e,"src",r)),a=[];for(let i of n)a.push(V(i,`${i}.${t}`));await Promise.all(a)}async function De(e,t){t==="typescript-react"&&await B(e,{"@types/react":oe.reactTypes})}async function Le(e){if(!await x(e))return[];let t=await W(e);return Object.entries(t?.dependencies??{}).map(([r,n])=>({name:r,version:n}))}async function I(e,t,r,n){let a=d(r,"download");return await v(a),await n(e,a),ye(t,a)}p();function $e(e,t=[]){let r=[...e.map(a=>({label:a.name,value:a.identifier,group:a.group||"Other",sortPriority:a.sortPriority??Number.MAX_SAFE_INTEGER})),...t.map(a=>({label:`${a.name} (limit reached)`,value:a.identifier,group:a.group||"Other",disabled:!0,sortPriority:a.sortPriority??Number.MAX_SAFE_INTEGER}))],n=(a,i)=>a.sortPriority===i.sortPriority?a.label.localeCompare(i.label):a.sortPriority-i.sortPriority;return r.sort(n)}var qe=async e=>{let t=e.extensionTemplates,r=e.templateType,n=e.extensionFlavor;if(!r){if(n&&(t=t.filter(l=>l.supportedFlavors.map(c=>c.value).includes(n))),t.length===0)throw new u("You have reached the limit for the number of extensions you can create.");r=await K({message:"Type of extension?",choices:$e(t,e.unavailableExtensions),groupOrder:e.groupOrder})}let a=t.find(l=>l.identifier===r),i=e.name||await be(e.directory,a.defaultName),s=e.extensionFlavor??await Ue(a);return{extensionTemplate:a,extensionContent:{name:i,flavor:s}}};async function be(e,t,r=1){let n=t.includes(" ")?" ":"-",a=r<=1?t:`${t}${n}${r}`,i=d(e,h(a));return Y(i)?be(e,t,r+1):Q({message:"Name your extension:",defaultValue:a})}async function Ue(e){if(e.supportedFlavors.length!==0)return e.supportedFlavors.length===1&&e.supportedFlavors[0]?e.supportedFlavors[0].value:X({message:"What would you like to work in?",choices:e.supportedFlavors.map(t=>({label:t.name,value:t.value})),defaultValue:"react"})}var Te=qe;async function Ve(e){let{app:t,developerPlatformClient:r,remoteApp:n,specifications:a,template:i}=e,s=a.map(Oe=>Oe.identifier),{templates:o,groupOrder:l}=await he(r,n,s,{requestedTemplate:i}),c=await Ye(o,l,a,t,e),m=await Te(c);await We(m,i);let y=Be(m,t,e,r),j=await we(y);return{status:"success",extension:{directory:j.directory,extensionTemplate:j.extensionTemplate,name:m.extensionContent.name,flavor:m.extensionContent.flavor},packageManager:e.project.packageManager}}async function Ye(e,t,r,n,a){let i=await ze(a.template,n,e,r);He(i?[i]:e,a.flavor);let{validTemplates:s,templatesOverlimit:o}=Je(e,r,n);return{templateType:i?.identifier,name:a.name,extensionFlavor:a.flavor,directory:d(a.directory,"extensions"),app:n,extensionTemplates:s??[],unavailableExtensions:o??[],reset:a.reset,groupOrder:t}}function Je(e,t,r){return fe(e,a=>!Pe(r,t,a)?"validTemplates":"templatesOverlimit")}function Pe(e,t,r){let n=r.type,a=t.find(s=>s.identifier===n||s.externalIdentifier===n);return e.extensionsForType({identifier:n,externalIdentifier:n}).length>=(a?.registrationLimit??1)}async function We(e,t){let{extensionContent:r}=e;return F.addPublicMetadata(()=>({cmd_scaffold_template_flavor:r.flavor,cmd_scaffold_type:e.extensionTemplate.identifier,cmd_scaffold_used_prompts_for_type:!t}))}function Be(e,t,r,n){return{app:t,project:r.project,cloneUrl:r.cloneUrl,extensionChoices:e.extensionContent,extensionTemplate:e.extensionTemplate,developerPlatformClient:n}}function He(e,t){if(t===void 0)return;let r=[...new Set(e.flatMap(n=>n.supportedFlavors.map(a=>a.value)))];if(!r.includes(t))throw new u("Invalid extension flavor",`Expected flavor to be one of the following: ${r.join(", ")}.`)}async function ze(e,t,r,n){if(!e)return;let a=r.find(i=>i.identifier===e);if(!a){let i=await Z(),s=r.map(l=>l.identifier),o=i?"You might need to enable some flags on your Organization or App":void 0;throw new u(`Unknown extension type: ${e}.
@@ -1 +1 @@
1
- import{b as y,c as S,f as C,g as B}from"./chunk-5T3ZT6CC.js";import{a as x}from"./chunk-ALINJ6J2.js";import{a as b}from"./chunk-ASKBYEO7.js";import{Q as g}from"./chunk-HMPRWNGG.js";import{t as w}from"./chunk-YYWSHRO2.js";import{b as h,c as F}from"./chunk-DMOLPSXF.js";import{w as l,y as d}from"./chunk-2KUM2RU4.js";import{d as p}from"./chunk-25MYHE4W.js";import{a}from"./chunk-LG3KEHGD.js";import{zb as f}from"./chunk-ZMOW2YZ4.js";import{b as s,i as m}from"./chunk-3PYDIBTX.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();o();var j=S.extend({wasmPath:y.nullable().describe("The built Wasm file, or null when the build produced no file.")}).strict(),e=a({name:"FunctionBuildResult",schema:s.object({status:s.literal("success"),function:j}).strict(),definitions:{FunctionBuild:j}});o();function A(n,t){t?f(e.encode(n)):d({headline:"Function built successfully."})}var r=class n extends x{static jsonOutputSchema=e;static summary="Compile a function to wasm.";static descriptionWithMarkdown="Compiles the function in your current directory to WebAssembly (Wasm) for testing purposes.";static description=this.descriptionForHelp();static flags={...h,...b,...C,...F};async run(){let{flags:t}=await this.parse(n),{app:i}=await g({directory:t.path,userProvidedConfigName:t.config}),u=await B(i,t.path),c=async(J,O)=>{let W=await w(u,{app:i,stdout:J,stderr:O,useTasks:!0,environment:"production"});A(W,t.json)};return t.json?await m({outputMode:"json",sink:p},()=>l({processes:[{prefix:u.localIdentifier,action:c}],showTimestamps:!1})):await c(process.stdout,process.stderr),{app:i}}};export{r as a};
1
+ import{b as y,c as S,f as C,g as B}from"./chunk-PIU3GVJ4.js";import{a as x}from"./chunk-HT7273V7.js";import{a as b}from"./chunk-K4KKSBUW.js";import{Q as g}from"./chunk-7FBOMPO5.js";import{t as w}from"./chunk-4LJERO23.js";import{b as h,c as F}from"./chunk-IKXUYCK7.js";import{w as l,y as d}from"./chunk-7A4ZE5IS.js";import{d as p}from"./chunk-WLJDMI7E.js";import{a}from"./chunk-LG3KEHGD.js";import{zb as f}from"./chunk-OIQ5NQ5I.js";import{b as s,i as m}from"./chunk-3PYDIBTX.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();o();var j=S.extend({wasmPath:y.nullable().describe("The built Wasm file, or null when the build produced no file.")}).strict(),e=a({name:"FunctionBuildResult",schema:s.object({status:s.literal("success"),function:j}).strict(),definitions:{FunctionBuild:j}});o();function A(n,t){t?f(e.encode(n)):d({headline:"Function built successfully."})}var r=class n extends x{static jsonOutputSchema=e;static summary="Compile a function to wasm.";static descriptionWithMarkdown="Compiles the function in your current directory to WebAssembly (Wasm) for testing purposes.";static description=this.descriptionForHelp();static flags={...h,...b,...C,...F};async run(){let{flags:t}=await this.parse(n),{app:i}=await g({directory:t.path,userProvidedConfigName:t.config}),u=await B(i,t.path),c=async(J,O)=>{let W=await w(u,{app:i,stdout:J,stderr:O,useTasks:!0,environment:"production"});A(W,t.json)};return t.json?await m({outputMode:"json",sink:p},()=>l({processes:[{prefix:u.localIdentifier,action:c}],showTimestamps:!1})):await c(process.stdout,process.stderr),{app:i}}};export{r as a};
@@ -1 +1 @@
1
- import{b as s}from"./chunk-XEZPN5TR.js";import{g as o}from"./chunk-DMOLPSXF.js";import{g as e}from"./chunk-VKWPEFWQ.js";e();var t=class extends s{static description="Clear the CLI cache, used to store some API responses and handle notifications status";static hidden=!0;async run(){await o()}};export{t as a};
1
+ import{b as s}from"./chunk-PSREELSQ.js";import{g as o}from"./chunk-IKXUYCK7.js";import{g as e}from"./chunk-VKWPEFWQ.js";e();var t=class extends s{static description="Clear the CLI cache, used to store some API responses and handle notifications status";static hidden=!0;async run(){await o()}};export{t as a};
@@ -0,0 +1,20 @@
1
+ import{a as E}from"./chunk-K4KKSBUW.js";import{X}from"./chunk-4LJERO23.js";import{c as Z,ga as ee,ja as te}from"./chunk-HEB4YYM6.js";import{b as x}from"./chunk-PSREELSQ.js";import{B as M,R as _,c as $,j as U,n as V,q as Q,x as j}from"./chunk-UORSJB4A.js";import{b as K,c as B,d as J}from"./chunk-IKXUYCK7.js";import{F as Y}from"./chunk-7A4ZE5IS.js";import{f as H}from"./chunk-2KFYIYLI.js";import{a as D}from"./chunk-LG3KEHGD.js";import{j as b}from"./chunk-FJOVMEPN.js";import{Bb as T,Fb as z,Kb as W,zb as C}from"./chunk-OIQ5NQ5I.js";import{b as a,e as I}from"./chunk-3PYDIBTX.js";import{b as ke}from"./chunk-VBPMVVLV.js";import{p as G}from"./chunk-IWTNUJGY.js";import{e as ve,g as p}from"./chunk-VKWPEFWQ.js";p();p();var w=[{flag:"store",field:"SHOP_MYSHOPIFY_DOMAIN"},{flag:"status",field:"RESULT_STATUS"},{flag:"topic",field:"TOPIC"},{flag:"status-code",field:"STATUS_CODE"},{flag:"operation-type",field:"OPERATION_TYPE"},{flag:"operation-name",field:"OPERATION_NAME"},{flag:"request-id",field:"REQUEST_ID"},{flag:"function-handle",field:"FUNCTION_HANDLE"},{flag:"target",field:"TARGET"},{flag:"event-handle",field:"EVENT_HANDLE"},{flag:"method",field:"METHOD"},{flag:"request-path",field:"REQUEST_PATH"}],ie=["store"],R=[...ie,"status","request-id","status-code"],N=[{name:"webhook",backend:"WEBHOOK",description:"Webhook deliveries.",filters:["status","topic","status-code"]},{name:"graphql",backend:"GRAPHQL_REQUEST",description:"GraphQL API requests.",filters:["status","operation-type","operation-name","request-id"]},{name:"function",backend:"FUNCTION_RUN",description:"Shopify Function runs.",filters:["status","function-handle","target"]},{name:"app-event",backend:"APP_EVENT",description:"Events the app sent with the App Events API.",filters:["event-handle"]},{name:"app-billing-event",backend:"APP_BILLING_EVENT",description:"Billing outcomes of app events.",filters:["status","event-handle"]},{name:"rest",backend:"REST_REQUEST",description:"REST API requests.",filters:["status","status-code","request-id","method","request-path"]},{name:"sidekick",backend:"SIDEKICK_EVENT",description:"Sidekick events.",filters:["status"]},{name:"ui-extension",backend:"UI_EXTENSION",description:"UI extension errors.",filters:["status","target"]}],L=N.map(({name:e})=>e);function ne(e){return N.filter(({filters:t})=>t.some(n=>n===e)).map(({name:t})=>t)}function oe(){let e=N.map(({name:o,description:s,filters:i})=>`- ${o}: ${s} Filters: ${i.map(l=>`--${l}`).join(", ")}.`),t=ie.map(o=>`--${o}`).join(", "),n=R.map(o=>`--${o}`).join(", ");return[`Log types and the filters that apply to each. Every type also accepts ${t}. Without --type, only ${n} apply.`,"",...e].join(`
2
+ `)}var g={defaultLimit:20,defaultSince:"1h",maximumLimit:1e3,maximumLookbackDays:7,maximumWindowDays:1,maximumFutureSkewMinutes:1};function r(e,t,n){let o=new b(n?`${t}
3
+
4
+ Request ID: ${n}`:t);return o.code=e,n&&(o.details={requestId:n}),o}function Te(e){let t=N.find(({name:n})=>n===e);if(!t)throw r("invalid-argument",`Supported log types are ${new Intl.ListFormat("en",{type:"conjunction"}).format(L)}.`);return{name:t.name,backend:t.backend}}function ae(e=L){return[...new Set(typeof e=="string"?[e]:e)].map(Te)}p();var c=ve(ke(),1),re={path:E.path,config:E.config,"client-id":E["client-id"],type:c.Flags.string({description:"Log type; repeat to select multiple. Defaults to all supported types.",options:L,multiple:!0,multipleNonGreedy:!0,helpGroup:"QUERY",env:"SHOPIFY_FLAG_TYPE"}),store:c.Flags.string({description:"Exact store handle or myshopify.com domain/URL.",char:"s",helpGroup:"FILTER",env:"SHOPIFY_FLAG_STORE"}),status:c.Flags.string({description:"Recorded result status; not inferred from HTTP codes or response bodies.",options:["success","failure"],helpGroup:"FILTER",env:"SHOPIFY_FLAG_STATUS"}),topic:c.Flags.string({description:"Exact webhook topic; excludes non-webhook records.",helpGroup:"FILTER",env:"SHOPIFY_FLAG_TOPIC"}),"status-code":c.Flags.string({description:"Exact webhook or REST HTTP status code (100\u2013599); no status classes.",helpGroup:"FILTER",env:"SHOPIFY_FLAG_STATUS_CODE"}),"operation-type":c.Flags.string({description:"Exact GraphQL operation type; excludes non-GraphQL records.",helpGroup:"FILTER",env:"SHOPIFY_FLAG_OPERATION_TYPE"}),"operation-name":c.Flags.string({description:"Exact GraphQL operation name; excludes non-GraphQL records.",helpGroup:"FILTER",env:"SHOPIFY_FLAG_OPERATION_NAME"}),"request-id":c.Flags.string({description:"Exact GraphQL or REST request ID; excludes other record types.",helpGroup:"FILTER",env:"SHOPIFY_FLAG_REQUEST_ID"}),"function-handle":c.Flags.string({description:"Exact Function extension handle; excludes non-Function records.",helpGroup:"FILTER",env:"SHOPIFY_FLAG_FUNCTION_HANDLE"}),target:c.Flags.string({description:"Exact Function execution or UI extension target; excludes other record types.",helpGroup:"FILTER",env:"SHOPIFY_FLAG_TARGET"}),"event-handle":c.Flags.string({description:"Exact app event or app billing event handle; excludes other record types.",helpGroup:"FILTER",env:"SHOPIFY_FLAG_EVENT_HANDLE"}),method:c.Flags.string({description:"Exact REST HTTP method; excludes non-REST records.",helpGroup:"FILTER",env:"SHOPIFY_FLAG_METHOD"}),"request-path":c.Flags.string({description:"Exact REST request path; excludes non-REST records.",helpGroup:"FILTER",env:"SHOPIFY_FLAG_REQUEST_PATH"}),since:c.Flags.string({description:"Inclusive start: positive duration (s/m/h/d) or whole-second RFC 3339 timestamp.",default:"1h",helpGroup:"QUERY",env:"SHOPIFY_FLAG_SINCE"}),until:c.Flags.string({description:"Exclusive whole-second RFC 3339 end; defaults to the current time.",helpGroup:"QUERY",env:"SHOPIFY_FLAG_UNTIL"}),limit:c.Flags.integer({description:"Maximum number of records to return, from 1 through 1000.",default:20,helpGroup:"QUERY",env:"SHOPIFY_FLAG_LIMIT"}),sort:c.Flags.string({description:"Select the oldest/newest matches using server-side sorting. Omit for faster, less-throttled retrieval.",options:["timestamp"],helpGroup:"QUERY",env:"SHOPIFY_FLAG_SORT"}),order:c.Flags.string({description:"Sort direction: asc (oldest first, default with --sort) or desc (newest first).",options:["asc","desc"],dependsOn:["sort"],helpGroup:"QUERY",env:"SHOPIFY_FLAG_ORDER"})};p();p();p();var se={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"LogApp"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"clientId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",alias:{kind:"Name",value:"app"},name:{kind:"Name",value:"appByKey"},arguments:[{kind:"Argument",name:{kind:"Name",value:"key"},value:{kind:"Variable",name:{kind:"Name",value:"clientId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"organizationId"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};var be=a.object({message:a.string(),path:a.array(a.union([a.string(),a.number()])).optional(),extensions:a.record(a.unknown()).optional()}),Ee=a.object({data:a.record(a.unknown()).nullable().optional(),errors:a.array(be.passthrough()).optional(),extensions:a.record(a.unknown()).optional()}),we=new Map([["THROTTLED","rate-limited"],["TIMEOUT","query-timeout"],["SORTED_QUERY_TOO_LARGE","sorted-query-too-large"]]);async function le(e,t){if(H())throw r("authentication-required","Sign in with a user account to retrieve app logs. Automation tokens are not supported.");let n=await j(),{appManagementToken:o}=await _({noPrompt:t}),s=`https://${n}`,i=await te({query:se,token:o,variables:{clientId:e},unauthorizedHandler:{type:"token_refresh",handler:async()=>(o=(await _({noPrompt:t,forceRefresh:!0})).appManagementToken,{token:o})}}),l=a.object({key:a.string(),organizationId:a.string().regex(/^gid:\/\/shopify\/Organization\/\d+$/).transform(Z).pipe(a.string())}).safeParse(i.app);if(!l.success||l.data.key!==e)throw r("forbidden","The selected app was not resolved to an authorized organization.");return{origin:s,token:o,organizationId:l.data.organizationId}}async function me(e,t,n){let o=await Q(`${e.origin}/app_logs/unstable/organizations/${e.organizationId}/graphql`,{method:"POST",redirect:"error",headers:ee(e.token),body:JSON.stringify({query:$(t).query,variables:n})},V("non-blocking")).catch(d=>{throw de(d),d}),s=o.headers.get("x-request-id"),i=await o.json().catch(d=>{if(de(d,s),!!o.ok)throw r("invalid-response","App Logs returned a response that could not be read as JSON.",s)}),l=Ee.safeParse(i),u=l.success?l.data.errors:void 0;if(!o.ok||u?.length){let d=u?.[0]?.extensions?.code,m=typeof d=="string"&&u?.every(({extensions:A})=>A?.code===d)?we.get(d):void 0,f=o.ok?m??"log-query-failed":{401:"authentication-required",403:"forbidden",429:"rate-limited",504:"query-timeout"}[o.status]??"logs-api-unavailable",v=u?.length?u.map(({message:A})=>A).join(`
5
+ `):"Check API availability, access, and authentication.",k=r(f,o.ok?v:`App Logs request failed (HTTP ${o.status}). ${v}`,s),F=o.headers.get("retry-after"),q={...s?{requestId:s}:{},...l.success&&u?.length?{errors:u,...l.data.extensions===void 0?{}:{extensions:l.data.extensions}}:{},...F&&/^\d+$/.test(F)?{retryAfterSeconds:Number(F)}:{}};throw Object.keys(q).length&&(k.details=q),k}if(!l.success||l.data.data===void 0&&l.data.errors===void 0)throw r("invalid-response","App Logs returned an invalid GraphQL response.",s);return{...l.data,requestId:s}}function de(e,t){if(e instanceof Error&&["AbortError","TimeoutError"].includes(e.name))throw r("query-timeout","App Logs request timed out. Check backend availability or use a narrower window or more selective filters.",t);if(e instanceof U&&e.type!=="invalid-json")throw r("logs-api-unavailable",`App Logs request failed: ${e.message}`,t)}p();function ce(e){let t=ae(e.type);if(!t.length)throw r("invalid-argument","Select at least one log type.");let n=e.limit??g.defaultLimit;if(!Number.isInteger(n)||n<1||n>g.maximumLimit)throw r("invalid-argument","--limit must be an integer between 1 and 1000.");if(e.sort!==void 0&&e.sort!=="timestamp")throw r("invalid-argument","--sort accepts timestamp.");if(e.order!==void 0&&!["asc","desc"].includes(e.order))throw r("invalid-argument","--order accepts asc or desc.");if(e.order!==void 0&&e.sort===void 0)throw r("invalid-argument","--order requires --sort.");let o=e.order==="desc"?"timestamp-desc":"timestamp-asc",s=e.sort===void 0?"none":o,i={};for(let d of w){let m=e[d.flag];if(m!==void 0){if(typeof m!="string"||!m.trim())throw r("invalid-argument",`--${d.flag} requires one nonempty value.`);if(Buffer.byteLength(m,"utf8")>1024)throw r("invalid-argument",`--${d.flag} accepts at most 1024 UTF-8 bytes.`);i[d.flag]=m}}if(i.store){let d;try{d=M(/^[a-zA-Z0-9][a-zA-Z0-9-]*$/.test(i.store.trim())?`${i.store.trim()}.myshopify.com`:i.store)}catch(m){throw m instanceof b&&(m.code="invalid-argument"),m}if(!/^[a-z0-9][a-z0-9-]*\.myshopify\.com$/.test(d))throw r("invalid-argument","Historical logs require a myshopify.com store domain.");i.store=d}if(i.status&&!["success","failure"].includes(i.status))throw r("invalid-argument","--status accepts success or failure.");if(i.topic&&!/^[a-zA-Z0-9_.-]+\/[a-zA-Z0-9_./-]+$/.test(i.topic))throw r("invalid-argument","--topic requires an exact slash-form topic, such as orders/create.");if(i["status-code"]&&!/^[1-5]\d{2}$/.test(i["status-code"]))throw r("invalid-argument","--status-code accepts an exact code from 100 to 599, not a status class.");for(let{flag:d}of w){if(e.type!==void 0||i[d]===void 0||R.some(f=>f===d))continue;let m=ne(d).map(f=>`--type ${f}`);throw r("invalid-argument",`--${d} needs a --type it applies to: ${m.join(" or ")}.`)}let l=w.flatMap(({flag:d,field:m})=>{let f=i[d];return f===void 0?[]:[{field:m,operator:"EQUALS",value:d==="status"?f.toUpperCase():f}]}),u=Ne(e);return{types:t,filters:l,limit:n,ordering:s,window:u}}function Ne(e){let t=e.since??g.defaultSince,n=/^(\d+)(s|m|h|d)$/.exec(t),o=new Map([["s",1],["m",60],["h",3600],["d",86400]]),s=n?Number(n[1])*o.get(n[2]):void 0;if(s!==void 0&&(!Number.isSafeInteger(s)||s<=0))throw r("invalid-argument","--since requires a positive integer duration or a whole-second timestamp.");let i=s===void 0?pe(t,"--since"):void 0,l=e.until===void 0?void 0:pe(e.until,"--until");if(i!==void 0&&l!==void 0&&i>=l)throw r("invalid-argument","--since must be earlier than --until.");return{start:i,end:l,durationSeconds:s}}function ue(e){let t=Math.floor(Date.now()/1e3)*1e3,n=e.end??t,o=e.start??n-e.durationSeconds*1e3;if(!Number.isFinite(new Date(o).valueOf()))throw r("invalid-argument","--since produces a timestamp outside the supported date range.");if(o>=n)throw r("invalid-argument","--since must be earlier than --until (the current time by default).");let s=864e5;if(o<t-g.maximumLookbackDays*s)throw r("invalid-argument",`--since must be within the last ${O(g.maximumLookbackDays,"day")}.`);if(n-o>g.maximumWindowDays*s)throw r("invalid-argument",`--since and --until must be at most ${O(g.maximumWindowDays,"day")} apart (--until is the current time by default).`);if(n>t+g.maximumFutureSkewMinutes*6e4)throw r("invalid-argument",`--until must not be more than ${O(g.maximumFutureSkewMinutes,"minute")} in the future.`);return{since:I(new Date(o)),until:I(new Date(n))}}function O(e,t){return`${e} ${e===1?t:`${t}s`}`}function pe(e,t){let n=/^(\d{4}-\d{2}-\d{2})T(\d{2}:\d{2}:\d{2})(Z|[+-]\d{2}:\d{2})$/.exec(e),o=()=>r("invalid-argument",`${t} requires ${t==="--since"?"a positive integer duration (s/m/h/d) or ":""}a whole-second RFC 3339 timestamp with a timezone; fractional input is not supported by the API.`);if(!n)throw o();let s=new Date(`${n[1]}T${n[2]}Z`);if(!Number.isFinite(s.valueOf())||s.toISOString().slice(0,19)!==`${n[1]}T${n[2]}`)throw o();let i=Date.parse(e);if(!Number.isFinite(i))throw o();return i}p();p();var S=a.object({timestamp:a.string().datetime().describe("Native API timestamp; fractional seconds are preserved."),type:a.string().describe("Native API enum, such as WEBHOOK or GRAPHQL_REQUEST."),resultStatus:a.string().nullable().optional(),shopMyshopifyDomain:a.string().nullable()}).passthrough().describe("Native record JSON. All additional approved API fields are preserved without renaming or truncation."),h=D({name:"HistoricalAppLogs",schema:a.object({logs:a.array(S),ordering:a.enum(["subset-timestamp-asc","timestamp-asc","timestamp-desc"]).describe("subset-timestamp-asc sorts only the returned subset in the CLI, not necessarily the oldest or newest matches when the limit is reached. timestamp-asc and timestamp-desc request server sorting before the limit."),limitations:a.array(a.string()).describe("Empty when fewer than the requested limit are returned.")}).strict(),definitions:{AppLogRecord:S}});var fe=a.object({app:a.object({logs:a.object({records:a.array(a.object({json:S}))}).nullable()}).nullable()});p();var ge={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"HistoricalLogs"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"clientId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"types"}},type:{kind:"NonNullType",type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"LogType"}}}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"timestamp"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"TimestampRangeInput"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"limit"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"Int"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"filters"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"LogFilterInput"}}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"sortKey"}},type:{kind:"NamedType",name:{kind:"Name",value:"LogSortKeys"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"reverse"}},type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"app"},arguments:[{kind:"Argument",name:{kind:"Name",value:"clientId"},value:{kind:"Variable",name:{kind:"Name",value:"clientId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"logs"},arguments:[{kind:"Argument",name:{kind:"Name",value:"types"},value:{kind:"Variable",name:{kind:"Name",value:"types"}}},{kind:"Argument",name:{kind:"Name",value:"timestamp"},value:{kind:"Variable",name:{kind:"Name",value:"timestamp"}}},{kind:"Argument",name:{kind:"Name",value:"limit"},value:{kind:"Variable",name:{kind:"Name",value:"limit"}}},{kind:"Argument",name:{kind:"Name",value:"filters"},value:{kind:"Variable",name:{kind:"Name",value:"filters"}}},{kind:"Argument",name:{kind:"Name",value:"sortKey"},value:{kind:"Variable",name:{kind:"Name",value:"sortKey"}}},{kind:"Argument",name:{kind:"Name",value:"reverse"},value:{kind:"Variable",name:{kind:"Name",value:"reverse"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"records"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"json"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};async function he(e){let t=ce(e),n=await Le(e),o=await le(n,e["no-input"]??!1),s=ue(t.window),{data:i,requestId:l}=await me(o,ge,{clientId:n,types:t.types.map(({backend:m})=>m),timestamp:{gte:s.since,lt:s.until},limit:t.limit,filters:t.filters,...t.ordering==="none"?{}:{sortKey:"TIMESTAMP",reverse:t.ordering==="timestamp-desc"}}),u=fe.safeParse(i);if(!u.success||!u.data.app?.logs)throw r("invalid-response","App Logs returned no valid log result.",l);let d=u.data.app.logs.records.map(({json:m})=>m);if(d.length>t.limit||d.some(m=>!t.types.some(({backend:f})=>f===m.type)))throw r("invalid-response","App Logs returned records outside the requested type or limit.",l);return t.ordering==="none"&&d.sort((m,f)=>{let v=m.timestamp.slice(0,-1),k=f.timestamp.slice(0,-1);return v<k?-1:v>k?1:0}),h.validate({logs:d,ordering:t.ordering==="none"?"subset-timestamp-asc":t.ordering,limitations:d.length===t.limit?[`Reached the limit of ${t.limit} ${t.limit===1?"record":"records"}; additional records may match.${t.ordering==="none"?" Fast retrieval does not necessarily select the oldest or newest matches.":""}`]:[]})}async function Le(e){if(e["client-id"]!==void 0){if(!e["client-id"].trim())throw r("invalid-argument","--client-id must not be empty.");return e["client-id"].trim()}let{activeConfig:t}=await X(e.path??G(),e.config,{skipPrompts:e["no-input"]??!1});if(t.file.errors.length)throw r("invalid-argument",t.file.errors.map(({message:o})=>o).join(`
6
+ `));let n=t.file.content.client_id;if(typeof n!="string"||!n.trim())throw r("invalid-argument","Pass --client-id or select an app configuration containing client_id.");return n.trim()}p();function ye(e,t,n){if(t){C(h.encode(e));return}if(!e.logs.length){T("No matching records available at query time.");return}T({"subset-timestamp-asc":"Used fast retrieval: returned records shown oldest first.","timestamp-asc":"Oldest first by timestamp.","timestamp-desc":"Newest first by timestamp."}[e.ordering]);let s=e.logs.some(i=>i.type==="GRAPHQL_REQUEST");Y({rows:e.logs.map(i=>({timestamp:y(i.timestamp),type:y(i.type),result:i.type==="APP_EVENT"?"\u2014":y(i.resultStatus),store:y(i.shopMyshopifyDomain),details:y(Se(i)),...s?{api:i.type==="GRAPHQL_REQUEST"?y(i.api):"\u2014"}:{}})),columns:{timestamp:{header:"Timestamp"},type:{header:"Type"},result:{header:"Result"},store:{header:"Store"},details:{header:"Details"},...s?{api:{header:"API"}}:{}}}),e.logs.length<n&&T(`Returned all ${e.logs.length} matching ${e.logs.length===1?"record":"records"} available at query time.`);for(let i of e.limitations)z(i);T("Use --json for full records.")}function Se(e){switch(e.type){case"WEBHOOK":return e.topic;case"GRAPHQL_REQUEST":return e.operationName;case"FUNCTION_RUN":return e.functionHandle??e.target;case"APP_EVENT":case"APP_BILLING_EVENT":return e.eventHandle;case"REST_REQUEST":return[e.method,e.requestPath].filter(t=>typeof t=="string"&&t.length>0).join(" ")||void 0;case"SIDEKICK_EVENT":case"UI_EXTENSION":return e.target;default:return}}function y(e){let n=Array.from(W(typeof e=="string"?e:"unknown"),i=>/[\p{Cc}\p{Cf}]/u.test(i)?`\\u${i.codePointAt(0).toString(16).padStart(4,"0")}`:i),o=n.join("");if(o.length<=100)return o;let s="";for(let i of n){if(s.length+i.length>99)break;s+=i}return`${s}\u2026`}var P=class e extends x{static baseFlags={...x.baseFlags,...J};static summary="Lists historical app logs.";static descriptionWithMarkdown=`Returns a list of historical app logs and exits. Defaults to all supported log types. Use --type to select a type; repeat it to select multiple.
7
+
8
+ Fast retrieval is the default: leave out --sort. Prefer this mode with a narrow time window and selective filters to consume less throttle capacity. The CLI orders the returned records oldest first, but when the limit is reached they aren't necessarily the oldest or newest matches.
9
+
10
+ Use server-side sorting only when selecting the oldest or newest matching records matters: --sort timestamp selects oldest first; add --order desc for newest first. This sorts before the result limit and is subject to API query limits.
11
+
12
+ When fewer than --limit records are returned, all matching records available at query time were returned. Sorting isn't needed to establish completeness.
13
+
14
+ Different filters combine with AND; each accepts one exact value. Type-specific filters, such as --topic, need a --type they apply to and exclude records without that field; combining --topic and --operation-name returns no records. --store, --status, --request-id and --status-code work without --type.
15
+
16
+ ${oe()}
17
+
18
+ Defaults: preceding hour, 20 records. Maximum: 1-day window within the last 7 days, 1000 records. Time inputs accept whole seconds only.
19
+
20
+ --json preserves native record JSON in logs[], including fractional timestamps, diagnostic fields, bodies, and producer truncation flags.`;static jsonOutputSchema=h;static description=this.descriptionForHelp();static flags={...K,...B,...re};static examples=["<%= config.bin %> <%= command.id %> --client-id APP_CLIENT_ID --type webhook --topic orders/create --status failure --since 30m","<%= config.bin %> <%= command.id %> --type graphql --operation-name MyQuery --json --no-input","<%= config.bin %> <%= command.id %> --since 1h --sort timestamp --order desc"];async run(){let{flags:t}=await this.parse(e);ye(await he(t),t.json,t.limit)}};export{P as a};
@@ -1,4 +1,4 @@
1
- import{a as m}from"./chunk-RSZAAN37.js";import{a as c}from"./chunk-ASKBYEO7.js";import{H as p,J as d,L as l,P as g}from"./chunk-HMPRWNGG.js";import{b as a,c as f,f as s}from"./chunk-DMOLPSXF.js";import{i as r}from"./chunk-TD6JBHUS.js";import{b as I}from"./chunk-AE3IQG7S.js";import{e as v,g as n}from"./chunk-VKWPEFWQ.js";n();var i=v(I(),1);var t=class h extends m{static summary="Fetch your app configuration from the Developer Dashboard.";static descriptionWithMarkdown=`Pulls app configuration from the Developer Dashboard and creates or overwrites a configuration file. You can create a new app with this command to start with a default configuration file.
1
+ import{a as m}from"./chunk-R5COVIJM.js";import{a as c}from"./chunk-K4KKSBUW.js";import{H as p,J as d,L as l,P as g}from"./chunk-7FBOMPO5.js";import{b as a,c as f,f as s}from"./chunk-IKXUYCK7.js";import{j as r}from"./chunk-FJOVMEPN.js";import{b as I}from"./chunk-VBPMVVLV.js";import{e as v,g as n}from"./chunk-VKWPEFWQ.js";n();var i=v(I(),1);var t=class h extends m{static summary="Fetch your app configuration from the Developer Dashboard.";static descriptionWithMarkdown=`Pulls app configuration from the Developer Dashboard and creates or overwrites a configuration file. You can create a new app with this command to start with a default configuration file.
2
2
 
3
3
  For more information on the format of the created TOML configuration file, refer to the [App configuration](https://shopify.dev/docs/apps/tools/cli/configuration) page.
4
4
  `;static jsonOutputSchema=p;static description=this.descriptionForHelp();static flags={...a,...f,...c,config:i.Flags.string({hidden:!1,char:"c",description:"The name of the local app configuration to read and overwrite. Use --file-name instead when specifying --client-id.",env:"SHOPIFY_FLAG_APP_CONFIG"}),"organization-id":i.Flags.string({hidden:!0,env:"SHOPIFY_FLAG_ORGANIZATION_ID",exclusive:["client-id"]}),"client-id":s(i.Flags.string({hidden:!1,description:"The Client ID of the remote app to link. Use --file-name to specify the destination configuration file.",env:"SHOPIFY_FLAG_CLIENT_ID"})),"file-name":i.Flags.string({hidden:!1,description:"The name of the app configuration file to create or overwrite. Requires --force to overwrite an existing file.",env:"SHOPIFY_FLAG_APP_CONFIG_FILE_NAME",exclusive:["config"]}),force:i.Flags.boolean({hidden:!1,description:"Overwrite an existing configuration file without prompting.",env:"SHOPIFY_FLAG_FORCE",dependsOn:["file-name"]})};async run(){let{flags:e}=await this.parse(h);if(e.config!==void 0&&e["client-id"]!==void 0)throw new r("The --config and --client-id flags can't be used together.","Use --file-name instead of --config to choose the configuration file to create or overwrite.");let u={directory:e.path,apiKey:e["client-id"],organizationId:e["organization-id"],configName:e.config,fileName:e["file-name"],force:e.force??!1},o=await l(u),{app:F}=await g({directory:e.path,clientId:void 0,forceRelink:!1,userProvidedConfigName:o.configFileName});return d(o.result,o.packageManager,e.json?"json":"text"),{app:F}}};export{t as a};
@@ -1 +1 @@
1
- import{b as T,c as O,d as R}from"./chunk-FQLXQ7WN.js";import{$ as p,E as v,Q as n,S as P,W as b,a as A,ba as j,ca as k,ia as a,ja as u,ka as h}from"./chunk-A2NSORBM.js";import{b as w}from"./chunk-XEZPN5TR.js";import{b as g,c as I}from"./chunk-DMOLPSXF.js";import{a as f}from"./chunk-LG3KEHGD.js";import{zb as S}from"./chunk-ZMOW2YZ4.js";import{b as o}from"./chunk-3PYDIBTX.js";import{b as _}from"./chunk-AE3IQG7S.js";import{e as d}from"./chunk-IWTNUJGY.js";import{e as C,g as i}from"./chunk-VKWPEFWQ.js";i();i();i();var F=o.object({path:a().describe("The absolute path of the file that the instructions were written to."),format:o.literal("markdown").describe("The file holds the instructions in Markdown, not a JSON result.")}).strict(),c=f({name:"AppSecurityInstructionsResult",schema:o.union([o.object({status:o.literal("success"),app:u,resultsDirectory:a().describe("The absolute path of the results directory that the instructions use. It may not exist yet: the instructions start by running check, which creates it."),instructions:h}).strict(),F]).describe("The instructions and the app they are for. With --write, only the file they were written to."),definitions:{AppSecurityApp:u,AppSecurityInstructions:h,AppSecurityInstructionsFile:F}});function x(r,t,e){if(e==="json"){S(c.encode(W(r,t)));return}R(r,t.delivery)}function W(r,{selection:t,delivery:e}){if(e.writePath)return{path:p(e.writePath),format:"markdown"};let{resultsDirectory:s}=v(t.appDirectory,n(t));return{status:"success",app:j(t),resultsDirectory:p(s),instructions:k(r,e)}}var l=C(_(),1);var m=class r extends w{static summary="Provide app security check instructions to a coding agent.";static descriptionWithMarkdown="Prints the complete workflow that a coding agent should follow to review app security check results.\n\nBy default, the instructions are printed to stdout. Use `--copy` to copy them to the clipboard or `--write` to write them to a file. Standalone instructions always start by running `shopify app security check`; only that invocation's generated review pack is trusted as workflow input.\n\nThe agent records its findings with `shopify app security record`. A suppression in those findings applies only to them, until the next `record`: `record` never changes `shopify.app-security.json`. To save a suppression that you approve to that file, the agent runs `shopify app security review --suppress`. Review and commit the file.";static jsonOutputSchema=c;static description=this.descriptionWithoutMarkdown();static flags={...g,...A,copy:l.Flags.boolean({description:"Copy the instructions to the clipboard instead of printing them. With --json, the result still includes them.",default:!1,exclusive:["write"],env:"SHOPIFY_FLAG_APP_SECURITY_INSTRUCTIONS_COPY"}),write:l.Flags.string({description:"Write the instructions to a file instead of printing them. With --json, stdout contains only the absolute path and Markdown format of the written file.",exclusive:["copy"],parse:async t=>d(t),env:"SHOPIFY_FLAG_APP_SECURITY_INSTRUCTIONS_WRITE"}),...I};async run(){let{flags:t}=await this.parse(r),e=await P({path:t.path,config:t.config,clientId:t["client-id"],withoutAppConfig:t["without-app-config"],allowPrompts:!1}),s=T({appDirectory:e.appDirectory,resultsKey:n(e),commands:b(e,t.path)}),y={copy:t.copy,writePath:t.write};await O(s,y),x(s,{selection:e,delivery:y},t.json?"json":"text")}};export{m as a};
1
+ import{b as T,c as O,d as R}from"./chunk-3GL3IT4K.js";import{$ as p,E as v,Q as n,S as P,W as b,a as A,ba as j,ca as k,ia as a,ja as u,ka as h}from"./chunk-NAQJMRPT.js";import{b as w}from"./chunk-PSREELSQ.js";import{b as g,c as I}from"./chunk-IKXUYCK7.js";import{a as f}from"./chunk-LG3KEHGD.js";import{zb as S}from"./chunk-OIQ5NQ5I.js";import{b as o}from"./chunk-3PYDIBTX.js";import{b as _}from"./chunk-VBPMVVLV.js";import{e as d}from"./chunk-IWTNUJGY.js";import{e as C,g as i}from"./chunk-VKWPEFWQ.js";i();i();i();var F=o.object({path:a().describe("The absolute path of the file that the instructions were written to."),format:o.literal("markdown").describe("The file holds the instructions in Markdown, not a JSON result.")}).strict(),c=f({name:"AppSecurityInstructionsResult",schema:o.union([o.object({status:o.literal("success"),app:u,resultsDirectory:a().describe("The absolute path of the results directory that the instructions use. It may not exist yet: the instructions start by running check, which creates it."),instructions:h}).strict(),F]).describe("The instructions and the app they are for. With --write, only the file they were written to."),definitions:{AppSecurityApp:u,AppSecurityInstructions:h,AppSecurityInstructionsFile:F}});function x(r,t,e){if(e==="json"){S(c.encode(W(r,t)));return}R(r,t.delivery)}function W(r,{selection:t,delivery:e}){if(e.writePath)return{path:p(e.writePath),format:"markdown"};let{resultsDirectory:s}=v(t.appDirectory,n(t));return{status:"success",app:j(t),resultsDirectory:p(s),instructions:k(r,e)}}var l=C(_(),1);var m=class r extends w{static summary="Provide app security check instructions to a coding agent.";static descriptionWithMarkdown="Prints the complete workflow that a coding agent should follow to review app security check results.\n\nBy default, the instructions are printed to stdout. Use `--copy` to copy them to the clipboard or `--write` to write them to a file. Standalone instructions always start by running `shopify app security check`; only that invocation's generated review pack is trusted as workflow input.\n\nThe agent records its findings with `shopify app security record`. A suppression in those findings applies only to them, until the next `record`: `record` never changes `shopify.app-security.json`. To save a suppression that you approve to that file, the agent runs `shopify app security review --suppress`. Review and commit the file.";static jsonOutputSchema=c;static description=this.descriptionWithoutMarkdown();static flags={...g,...A,copy:l.Flags.boolean({description:"Copy the instructions to the clipboard instead of printing them. With --json, the result still includes them.",default:!1,exclusive:["write"],env:"SHOPIFY_FLAG_APP_SECURITY_INSTRUCTIONS_COPY"}),write:l.Flags.string({description:"Write the instructions to a file instead of printing them. With --json, stdout contains only the absolute path and Markdown format of the written file.",exclusive:["copy"],parse:async t=>d(t),env:"SHOPIFY_FLAG_APP_SECURITY_INSTRUCTIONS_WRITE"}),...I};async run(){let{flags:t}=await this.parse(r),e=await P({path:t.path,config:t.config,clientId:t["client-id"],withoutAppConfig:t["without-app-config"],allowPrompts:!1}),s=T({appDirectory:e.appDirectory,resultsKey:n(e),commands:b(e,t.path)}),y={copy:t.copy,writePath:t.write};await O(s,y),x(s,{selection:e,delivery:y},t.json?"json":"text")}};export{m as a};
@@ -0,0 +1 @@
1
+ import{g as I}from"./chunk-VKWPEFWQ.js";I();var o="5.2.0";export{o as a};
@@ -1,4 +1,4 @@
1
- import{a as q}from"./chunk-LXIWMYM4.js";import{a as $}from"./chunk-RSZAAN37.js";import{a as w}from"./chunk-ASKBYEO7.js";import{P as V}from"./chunk-HMPRWNGG.js";import{d as x}from"./chunk-JGLLABZR.js";import{f as L}from"./chunk-2BYW3BYX.js";import{Q as P}from"./chunk-YYWSHRO2.js";import{b as de}from"./chunk-27JT4NA4.js";import{B as D,K as T,Z as A,la as j,ra as O}from"./chunk-YKDRUAY3.js";import{b as M,c as E}from"./chunk-DMOLPSXF.js";import{G as C,H as k,x as R}from"./chunk-2KUM2RU4.js";import{a as g}from"./chunk-LG3KEHGD.js";import{Bb as v,tb as p,vb as c,zb as I}from"./chunk-ZMOW2YZ4.js";import{b as m,c as h}from"./chunk-3PYDIBTX.js";import{b as ae}from"./chunk-AE3IQG7S.js";import{e as _,g as r}from"./chunk-VKWPEFWQ.js";r();r();r();var U={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"metafieldDefinitions"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"ownerType"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"MetafieldOwnerType"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"after"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metafieldDefinitions"},arguments:[{kind:"Argument",name:{kind:"Name",value:"ownerType"},value:{kind:"Variable",name:{kind:"Name",value:"ownerType"}}},{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"30"}},{kind:"Argument",name:{kind:"Name",value:"after"},value:{kind:"Variable",name:{kind:"Name",value:"after"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"pageInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"hasNextPage"}},{kind:"Field",name:{kind:"Name",value:"endCursor"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"MetafieldForImport"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"MetafieldForImport"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"MetafieldDefinition"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"namespace"}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"type"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"name"}}]}},{kind:"Field",name:{kind:"Name",value:"access"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"admin"}},{kind:"Field",name:{kind:"Name",value:"storefront"}},{kind:"Field",name:{kind:"Name",value:"customerAccount"}}]}},{kind:"Field",name:{kind:"Name",value:"capabilities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"adminFilterable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}}]}},{kind:"Field",name:{kind:"Name",value:"validations"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"value"}}]}}]}}]};r();async function oe(i){let n="Admin",e=L(i.storeFqdn,"unstable");return{token:i.token,api:n,url:e}}async function K(i){return O({query:i.query,...await oe(i.session),variables:i.variables,autoRateLimitRestore:i.autoRateLimitRestore})}r();var G={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"metaobjectDefinitions"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"after"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metaobjectDefinitions"},arguments:[{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"10"}},{kind:"Argument",name:{kind:"Name",value:"after"},value:{kind:"Variable",name:{kind:"Name",value:"after"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"pageInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"hasNextPage"}},{kind:"Field",name:{kind:"Name",value:"endCursor"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"MetaobjectForImport"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"MetaobjectForImport"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"MetaobjectDefinition"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"type"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"access"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"admin"}},{kind:"Field",name:{kind:"Name",value:"storefront"}}]}},{kind:"Field",name:{kind:"Name",value:"displayNameKey"}},{kind:"Field",name:{kind:"Name",value:"capabilities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"publishable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}},{kind:"Field",name:{kind:"Name",value:"translatable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}},{kind:"Field",name:{kind:"Name",value:"renderable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}},{kind:"Field",name:{kind:"Name",value:"data"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metaTitleKey"}},{kind:"Field",name:{kind:"Name",value:"metaDescriptionKey"}}]}}]}}]}},{kind:"Field",name:{kind:"Name",value:"fieldDefinitions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"type"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"name"}}]}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"required"}},{kind:"Field",name:{kind:"Name",value:"validations"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"value"}}]}}]}}]}}]};var B=_(de(),1);var se={article:"ARTICLE",blog:"BLOG",collection:"COLLECTION",company:"COMPANY",company_location:"COMPANY_LOCATION",location:"LOCATION",market:"MARKET",order:"ORDER",page:"PAGE",product:"PRODUCT",customer:"CUSTOMER",delivery_customization:"DELIVERY_CUSTOMIZATION",delivery_method:"DELIVERY_METHOD",delivery_option_generator:"DELIVERY_OPTION_GENERATOR",discount:"DISCOUNT",draft_order:"DRAFTORDER",fulfillment_constraint_rule:"FULFILLMENT_CONSTRAINT_RULE",gift_card_transaction:"GIFT_CARD_TRANSACTION",order_routing_location_rule:"ORDER_ROUTING_LOCATION_RULE",payment_customization:"PAYMENT_CUSTOMIZATION",selling_plan:"SELLING_PLAN",shop:"SHOP",validation:"VALIDATION",variant:"PRODUCTVARIANT",cart_transform:"CARTTRANSFORM"};async function Y({query:i,session:n,toNodes:e,toVariables:t,performQuery:d=a=>K({query:i,session:n,variables:a,autoRateLimitRestore:!0})}){let a;try{let o=e(await d(t(a))),s=[];for(s.push(...o.nodes);o.pageInfo.hasNextPage;)a=o.pageInfo.endCursor,o=e(await d(t(a))),s.push(...o.nodes);return{status:"ok",items:s}}catch(o){if(o instanceof Error&&o.message.includes("ACCESS_DENIED"))return{status:"scope_error"};throw o}}function H(i,n){let e="";for(let t of i)e=(0,B.updateTomlValues)(e,t);return`# ${n}
1
+ import{a as q}from"./chunk-Z3QZNLT5.js";import{a as $}from"./chunk-R5COVIJM.js";import{a as w}from"./chunk-K4KKSBUW.js";import{P as V}from"./chunk-7FBOMPO5.js";import{e as x}from"./chunk-4KBOLN7Q.js";import{f as L}from"./chunk-XHHAVKKV.js";import{Q as P}from"./chunk-4LJERO23.js";import{b as de}from"./chunk-HR6R7JXN.js";import{B as D,K as T,Z as A,la as j,sa as O}from"./chunk-UORSJB4A.js";import{b as M,c as E}from"./chunk-IKXUYCK7.js";import{G as C,H as k,x as R}from"./chunk-7A4ZE5IS.js";import{a as g}from"./chunk-LG3KEHGD.js";import{Bb as v,tb as p,vb as c,zb as I}from"./chunk-OIQ5NQ5I.js";import{b as m,c as h}from"./chunk-3PYDIBTX.js";import{b as ae}from"./chunk-VBPMVVLV.js";import{e as _,g as r}from"./chunk-VKWPEFWQ.js";r();r();r();var U={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"metafieldDefinitions"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"ownerType"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"MetafieldOwnerType"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"after"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metafieldDefinitions"},arguments:[{kind:"Argument",name:{kind:"Name",value:"ownerType"},value:{kind:"Variable",name:{kind:"Name",value:"ownerType"}}},{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"30"}},{kind:"Argument",name:{kind:"Name",value:"after"},value:{kind:"Variable",name:{kind:"Name",value:"after"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"pageInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"hasNextPage"}},{kind:"Field",name:{kind:"Name",value:"endCursor"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"MetafieldForImport"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"MetafieldForImport"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"MetafieldDefinition"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"namespace"}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"type"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"name"}}]}},{kind:"Field",name:{kind:"Name",value:"access"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"admin"}},{kind:"Field",name:{kind:"Name",value:"storefront"}},{kind:"Field",name:{kind:"Name",value:"customerAccount"}}]}},{kind:"Field",name:{kind:"Name",value:"capabilities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"adminFilterable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}}]}},{kind:"Field",name:{kind:"Name",value:"validations"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"value"}}]}}]}}]};r();async function oe(i){let n="Admin",e=L(i.storeFqdn,"unstable");return{token:i.token,api:n,url:e}}async function K(i){return O({query:i.query,...await oe(i.session),variables:i.variables,autoRateLimitRestore:i.autoRateLimitRestore})}r();var G={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"metaobjectDefinitions"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"after"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metaobjectDefinitions"},arguments:[{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"10"}},{kind:"Argument",name:{kind:"Name",value:"after"},value:{kind:"Variable",name:{kind:"Name",value:"after"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"pageInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"hasNextPage"}},{kind:"Field",name:{kind:"Name",value:"endCursor"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"MetaobjectForImport"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"MetaobjectForImport"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"MetaobjectDefinition"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"type"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"access"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"admin"}},{kind:"Field",name:{kind:"Name",value:"storefront"}}]}},{kind:"Field",name:{kind:"Name",value:"displayNameKey"}},{kind:"Field",name:{kind:"Name",value:"capabilities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"publishable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}},{kind:"Field",name:{kind:"Name",value:"translatable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}},{kind:"Field",name:{kind:"Name",value:"renderable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}},{kind:"Field",name:{kind:"Name",value:"data"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metaTitleKey"}},{kind:"Field",name:{kind:"Name",value:"metaDescriptionKey"}}]}}]}}]}},{kind:"Field",name:{kind:"Name",value:"fieldDefinitions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"type"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"name"}}]}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"required"}},{kind:"Field",name:{kind:"Name",value:"validations"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"value"}}]}}]}}]}}]};var B=_(de(),1);var se={article:"ARTICLE",blog:"BLOG",collection:"COLLECTION",company:"COMPANY",company_location:"COMPANY_LOCATION",location:"LOCATION",market:"MARKET",order:"ORDER",page:"PAGE",product:"PRODUCT",customer:"CUSTOMER",delivery_customization:"DELIVERY_CUSTOMIZATION",delivery_method:"DELIVERY_METHOD",delivery_option_generator:"DELIVERY_OPTION_GENERATOR",discount:"DISCOUNT",draft_order:"DRAFTORDER",fulfillment_constraint_rule:"FULFILLMENT_CONSTRAINT_RULE",gift_card_transaction:"GIFT_CARD_TRANSACTION",order_routing_location_rule:"ORDER_ROUTING_LOCATION_RULE",payment_customization:"PAYMENT_CUSTOMIZATION",selling_plan:"SELLING_PLAN",shop:"SHOP",validation:"VALIDATION",variant:"PRODUCTVARIANT",cart_transform:"CARTTRANSFORM"};async function Y({query:i,session:n,toNodes:e,toVariables:t,performQuery:d=a=>K({query:i,session:n,variables:a,autoRateLimitRestore:!0})}){let a;try{let o=e(await d(t(a))),s=[];for(s.push(...o.nodes);o.pageInfo.hasNextPage;)a=o.pageInfo.endCursor,o=e(await d(t(a))),s.push(...o.nodes);return{status:"ok",items:s}}catch(o){if(o instanceof Error&&o.message.includes("ACCESS_DENIED"))return{status:"scope_error"};throw o}}function H(i,n){let e="";for(let t of i)e=(0,B.updateTomlValues)(e,t);return`# ${n}
2
2
  ${e}`}function le(i,n){let e=n.map(ke).map(a=>{switch(a.status){case"ok":{let{typeName:o,patches:s}=a;return H(s,`type: $app:${o}`)}case"not_app_reserved":return null}}).filter(a=>a!==null),t=i.flatMap(({items:a,ownerType:o,graphQLOwner:s})=>a.map(l=>({result:fe(l,o),graphQLOwner:s}))).map(({result:a,graphQLOwner:o})=>{switch(a.status){case"ok":{let{namespace:s,key:l,patches:S}=a;return H(S,`namespace: ${s==="app"?"$app":`$app:${s}`} key: ${l} owner_type: ${o}`)}case"not_app_reserved":return null}}).filter(a=>a!==null);return{tomlContent:[...e,...t].join(`
3
3
  `),metafieldCount:t.length,metaobjectCount:e.length}}async function J(i){let n=await pe(i),e=await re(n),t=await me(n),d=e.nodes,a=t.nodes;i.includeExistingDeclaredDefinitions||(d=ce(d,i.appConfiguration),a=ue(a,i.appConfiguration));let{tomlContent:o,metafieldCount:s,metaobjectCount:l}=le(d,a);return{status:"success",storeDomain:n.storeFqdn,metafieldCount:s,metaobjectCount:l,tomlContent:o,skippedSections:[...e.skippedSections,...t.skippedSections]}}async function re(i){let n=[];return await C(Object.entries(se).map(([e,t])=>({title:c`Loading ${p.green(e)} metafields`,task:async()=>{let d=await Y({query:U,session:i,toNodes:a=>a.metafieldDefinitions,toVariables:a=>({ownerType:t,after:a})});n.push({metafields:d,ownerType:e,graphQLOwner:t})}}))),{nodes:n.map(({metafields:e,ownerType:t,graphQLOwner:d})=>e.status==="ok"?{ownerType:t,items:e.items,graphQLOwner:d}:null).filter(e=>e!==null),skippedSections:n.filter(({metafields:e})=>e.status==="scope_error").map(({graphQLOwner:e})=>({type:"metafields",ownerType:e}))}}async function me(i){let n=await k({title:c`Loading ${p.green("metaobjects")}`,task:async()=>Y({query:G,session:i,toNodes:e=>e.metaobjectDefinitions,toVariables:e=>({after:e})})});return n.status==="ok"?{nodes:n.items,skippedSections:[]}:{nodes:[],skippedSections:[{type:"metaobjects"}]}}function ce(i,n){return i.map(e=>{let t=e.items.filter(d=>!W(n,[e.ownerType,"metafields",f(d.namespace)??"",d.key]));return t.length>0?{...e,items:t}:null}).filter(e=>e!==null)}function ue(i,n){return i.filter(e=>!W(n,["metaobjects","app",f(e.type)??""]))}function W(i,n){let e=i;for(let t of n){if(!e[t])return!1;e=e[t]}return!0}async function pe(i){let{remoteApp:n,store:e}=i,t=await x(n);return await A(e.shopDomain,n.apiKey,t)}function f(i){if(!i.match(/^app--\d+/))return null;let n="app";return i.match(/^app--\d+--/)&&(n=i.replace(/^app--\d+--/,"")),n}function fe(i,n){let e=f(i.namespace);if(!e)return{status:"not_app_reserved"};let t=i.key,d=ve(i),a=Ne(d,n,e,t);return{status:"ok",key:t,namespace:e,patches:a}}function ke(i){let n=f(i.type);if(!n)return{status:"not_app_reserved"};let e=be(i,n),t=Se(e,n);return{status:"ok",typeName:n,patches:t}}function ve(i){let n={name:i.name===i.key?void 0:i.name,type:i.type.name,description:i.description??void 0,capabilities:u({admin_filterable:i.capabilities.adminFilterable.enabled||void 0}),access:u({admin:X(i.access.admin),storefront:ee(i.access.storefront),customer_account:ye(i.access.customerAccount)}),validations:Q(i.validations)},{type:e,validations:t}=z(n.type,n.validations);return n.type=e,n.validations=t,n}function be(i,n){return{name:i.name===n?void 0:i.name,description:i.description??void 0,display_name_field:i.displayNameKey??void 0,access:u({admin:X(i.access.admin),storefront:ee(i.access.storefront)}),capabilities:u({translatable:i.capabilities.translatable.enabled||void 0,publishable:i.capabilities.publishable.enabled||void 0,renderable:i.capabilities.renderable?.enabled||void 0,renderable_meta_title_field:i.capabilities.renderable?.data?.metaTitleKey??void 0,renderable_meta_description_field:i.capabilities.renderable?.data?.metaDescriptionKey??void 0}),fields:Object.fromEntries(i.fieldDefinitions.map(e=>{let t={type:e.type.name,description:e.description??void 0,name:e.name===e.key?void 0:e.name,required:e.required||void 0,validations:Q(e.validations)},{type:d,validations:a}=z(t.type,t.validations);return t.type=d,t.validations=a,[e.key,t]}))}}function z(i,n){if(!n)return{type:i,validations:void 0};if(n.metaobject_definition_type&&typeof n.metaobject_definition_type=="string"){let e=f(n.metaobject_definition_type);return{type:`${i}<$app:${e}>`,validations:u({...n,metaobject_definition_type:void 0})}}if(n.metaobject_definition_types&&Array.isArray(n.metaobject_definition_types)&&n.metaobject_definition_types.every(e=>typeof e=="string")){let e=n.metaobject_definition_types.map(t=>f(t));return{type:`${i}<${e.map(t=>`$app:${t}`).join(",")}>`,validations:u({...n,metaobject_definition_types:void 0})}}return{type:i,validations:n}}function Q(i){let n=e=>{try{return JSON.parse(e)}catch{return e}};return u(Object.fromEntries(i.filter(e=>e.value!==void 0&&e.name!=="metaobject_definition_id"&&e.name!=="metaobject_definition_ids").map(e=>[e.name,e.value?n(e.value):void 0])))}function Ne(i,n,e,t){let d=[[[n,"metafields",e,t,"name"],i.name],[[n,"metafields",e,t,"type"],i.type],[[n,"metafields",e,t,"description"],i.description]],a=[[[n,"metafields",e,t,"access","admin"],i.access?.admin],[[n,"metafields",e,t,"access","storefront"],i.access?.storefront],[[n,"metafields",e,t,"access","customer_account"],i.access?.customer_account],[[n,"metafields",e,t,"capabilities","admin_filterable"],i.capabilities?.admin_filterable||void 0]];return i.validations&&Z(i.validations).forEach(({validationKey:s,actualValue:l})=>{d.push([[n,"metafields",e,t,"validations",s],l])}),[b(d),b(a)]}function Se(i,n){let e=[[["metaobjects","app",n,"name"],i.name===n?void 0:i.name],[["metaobjects","app",n,"description"],i.description],[["metaobjects","app",n,"display_name_field"],i.display_name_field]],t=[[["metaobjects","app",n,"access","admin"],i.access?.admin],[["metaobjects","app",n,"access","storefront"],i.access?.storefront]];return i.capabilities?.translatable&&t.push([["metaobjects","app",n,"capabilities","translatable"],!0]),i.capabilities?.publishable&&t.push([["metaobjects","app",n,"capabilities","publishable"],!0]),i.capabilities?.renderable&&(t.push([["metaobjects","app",n,"capabilities","renderable"],!0]),i.capabilities?.renderable_meta_title_field&&t.push([["metaobjects","app",n,"capabilities","renderable_meta_title_field"],i.capabilities.renderable_meta_title_field]),i.capabilities?.renderable_meta_description_field&&t.push([["metaobjects","app",n,"capabilities","renderable_meta_description_field"],i.capabilities.renderable_meta_description_field])),Object.entries(i.fields).forEach(([d,a])=>{if(typeof a=="string")e.push([["metaobjects","app",n,"fields",d],a]);else{let o=Object.fromEntries(Object.entries(a).filter(([s,l])=>l!==void 0));Object.keys(o).length===1?e.push([["metaobjects","app",n,"fields",d],a.type]):(e.push([["metaobjects","app",n,"fields",d,"type"],a.type]),e.push([["metaobjects","app",n,"fields",d,"description"],a.description]),e.push([["metaobjects","app",n,"fields",d,"name"],a.name]),e.push([["metaobjects","app",n,"fields",d,"required"],a.required||void 0]),a.validations&&Z(a.validations).forEach(({validationKey:l,actualValue:S})=>{e.push([["metaobjects","app",n,"fields",d,"validations",l],S])}))}}),[b(e),b(t)]}function Z(i){return Object.entries(i).map(([n,e])=>{let t;return typeof e=="string"||typeof e=="number"||typeof e=="boolean"||Array.isArray(e)&&e.every(d=>typeof d=="string")?t=e:t=JSON.stringify(e),{validationKey:n,actualValue:t}})}function X(i){switch(i){case"MERCHANT_READ_WRITE":return"merchant_read_write";case"MERCHANT_READ":case"PRIVATE":case"PUBLIC_READ":case"PUBLIC_READ_WRITE":case null:case void 0:return}}function ee(i){switch(i){case"PUBLIC_READ":return"public_read";case"NONE":case null:case void 0:return}}function ye(i){switch(i){case"READ":return"read";case"READ_WRITE":return"read_write";case"NONE":case null:case void 0:return}}function u(i){if(i&&!j(i)&&!(typeof i=="object"&&Object.values(i).every(n=>n===void 0)))return i}function b(i){return i.filter(([n,e])=>e!==void 0)}r();var ie=m.object({type:m.literal("metafields"),ownerType:m.string().min(1).describe("The Admin API metafield owner type, such as PRODUCT.")}).strict(),ne=m.object({type:m.literal("metaobjects")}).strict(),N=g({name:"ImportCustomDataDefinitionsResult",schema:m.object({status:m.literal("success"),storeDomain:h.nullable().describe("The full myshopify.com domain of the development store, or null when unavailable."),metafieldCount:m.number().int().nonnegative().describe("The number of available metafields converted to TOML."),metaobjectCount:m.number().int().nonnegative().describe("The number of available metaobjects converted to TOML."),toml:m.string().describe("Suggested native TOML for app-reserved definitions. No file is written."),skippedSections:m.array(m.discriminatedUnion("type",[ie,ne])).describe("Sections skipped because required access scopes are unavailable. An empty array means all requests were authorized.")}).strict(),definitions:{SkippedMetafields:ie,SkippedMetaobjects:ne}});r();function te({status:i,metafieldCount:n,metaobjectCount:e,storeDomain:t,tomlContent:d,skippedSections:a},o=!1){if(o){let s=T(t);I(N.encode({status:i,storeDomain:s?`${s}.myshopify.com`:null,metafieldCount:n,metaobjectCount:e,toml:d,skippedSections:a.map(l=>l.type==="metafields"?{type:l.type,ownerType:l.ownerType}:{type:l.type})}));return}R({headline:"Conversion to TOML complete.",body:["Converted",{warn:`${n} metafields`},"and",{warn:`${e} metaobjects`},"from",{warn:t},"into TOML, ready for you to copy."],orderedNextSteps:!0,nextSteps:["Review the suggested TOML carefully before applying.",["Missing sections? Make sure your app has the required access scopes to load metafields and metaobjects (e.g.",{command:"read_customers"},"to load customer metafields,",{command:"read_metaobject_definitions"},"to load metaobjects.)"],["Missing definitions? Only metafields and metaobjects that are app-reserved (using",{command:"$app"},") will be converted."],["When you're ready, add the generated TOML to your app's configuration file and test out changes with the",{command:"shopify app dev"},"command."]]}),Fe(d)}function Fe(i){let n=i.split(`
4
4
  `);for(let e of n)e.match(/^\s*\[/)?v(c`${p.green(e)}`):e.match(/^\s*#/)?v(c`${p.gray(e)}`):v(c`${e}`)}var y=_(ae(),1);var F=class i extends ${static summary="Import metafield and metaobject definitions.";static descriptionWithMarkdown="Import metafield and metaobject definitions from your development store. [Read more about declarative custom data definitions](https://shopify.dev/docs/apps/build/custom-data/declarative-custom-data-definitions).";static jsonOutputSchema=N;static description=this.descriptionForHelp();static flags={...M,...w,...E,store:y.Flags.string({char:"s",description:"Store URL. Must be an existing development or Shopify Plus sandbox store.",env:"SHOPIFY_FLAG_STORE",parse:async n=>D(n)}),"include-existing":y.Flags.boolean({description:"Include existing declared definitions in the output.",default:!1,env:"SHOPIFY_FLAG_INCLUDE_EXISTING"})};async run(){let{appContextResult:n,json:e,...t}=await k({title:c`Loading application`,task:async()=>{let{flags:a}=await this.parse(i);await P(a.path);let o=await V({directory:a.path,clientId:a["client-id"],forceRelink:a.reset,userProvidedConfigName:a.config}),s=await q({appContextResult:o,storeFqdn:a.store,forceReselectStore:a.reset});return{appContextResult:o,json:a.json,appConfiguration:o.app.configuration,remoteApp:o.remoteApp,store:s,includeExistingDeclaredDefinitions:a["include-existing"]}}}),d=await J(t);return te(d,e),{app:n.app}}};export{F as a};
@@ -1,4 +1,4 @@
1
- import{a as n}from"./chunk-K4QJEQI4.js";import{b as v}from"./chunk-XEZPN5TR.js";import{p as g}from"./chunk-YKDRUAY3.js";import{b as w,c as F}from"./chunk-DMOLPSXF.js";import{i as r}from"./chunk-TD6JBHUS.js";import{Bb as y,ta as u,va as m,zb as c}from"./chunk-ZMOW2YZ4.js";import{b as k}from"./chunk-AE3IQG7S.js";import{e as l,h as f}from"./chunk-IWTNUJGY.js";import{e as O,g as s}from"./chunk-VKWPEFWQ.js";s();s();var D="text/markdown",L="X-Shopify-Surface",R="cli",S=["shopify.dev"];async function x(t,e){let o;try{o=new URL(t)}catch{throw new r(`Invalid URL: ${t}`)}let{hostname:i}=o;if(!S.some(d=>i===d||i.endsWith(`.${d}`)))throw new r(`Only documents from the following hosts can be fetched: ${S.join(", ")}.`);let a=await g(t,{headers:{Accept:D,[L]:R,...e?{"Accept-Language":e}:{}}});if(!a.ok)throw new r(`Failed to fetch ${t}: ${a.status} ${a.statusText}`);return{document:{url:t,content:await a.text()}}}s();async function A(t,e,o){if(o){let i=l(o);await m(f(i)),await u(i,t.document.content),y(`Saved ${t.document.url} to ${i}`),e==="json"&&c(n.encode({path:i,format:"markdown"}))}else e==="json"?c(n.encode(t)):c(t.document.content)}var p=O(k(),1),h=class t extends v{static descriptionWithMarkdown="Download a complete document from shopify.dev. Every page on shopify.dev has a Markdown version, and that is what this tool returns. Use this to pull an entire document verbatim \u2014 for example, a set of instructions an agent follows like a centrally-served skill. Pass `--language` for the language of the app you are building so code examples match your stack. For finding the relevant pieces of content across shopify.dev instead, use `doc search`.";static jsonOutputSchema=n;static description=this.descriptionForHelp();static examples=[`# fetch the Markdown version of a Shopify.dev page
1
+ import{a as n}from"./chunk-K4QJEQI4.js";import{b as v}from"./chunk-PSREELSQ.js";import{p as g}from"./chunk-UORSJB4A.js";import{b as w,c as F}from"./chunk-IKXUYCK7.js";import{j as r}from"./chunk-FJOVMEPN.js";import{Bb as y,ta as u,va as m,zb as c}from"./chunk-OIQ5NQ5I.js";import{b as k}from"./chunk-VBPMVVLV.js";import{e as l,h as f}from"./chunk-IWTNUJGY.js";import{e as O,g as s}from"./chunk-VKWPEFWQ.js";s();s();var D="text/markdown",L="X-Shopify-Surface",R="cli",S=["shopify.dev"];async function x(t,e){let o;try{o=new URL(t)}catch{throw new r(`Invalid URL: ${t}`)}let{hostname:i}=o;if(!S.some(d=>i===d||i.endsWith(`.${d}`)))throw new r(`Only documents from the following hosts can be fetched: ${S.join(", ")}.`);let a=await g(t,{headers:{Accept:D,[L]:R,...e?{"Accept-Language":e}:{}}});if(!a.ok)throw new r(`Failed to fetch ${t}: ${a.status} ${a.statusText}`);return{document:{url:t,content:await a.text()}}}s();async function A(t,e,o){if(o){let i=l(o);await m(f(i)),await u(i,t.document.content),y(`Saved ${t.document.url} to ${i}`),e==="json"&&c(n.encode({path:i,format:"markdown"}))}else e==="json"?c(n.encode(t)):c(t.document.content)}var p=O(k(),1),h=class t extends v{static descriptionWithMarkdown="Download a complete document from shopify.dev. Every page on shopify.dev has a Markdown version, and that is what this tool returns. Use this to pull an entire document verbatim \u2014 for example, a set of instructions an agent follows like a centrally-served skill. Pass `--language` for the language of the app you are building so code examples match your stack. For finding the relevant pieces of content across shopify.dev instead, use `doc search`.";static jsonOutputSchema=n;static description=this.descriptionForHelp();static examples=[`# fetch the Markdown version of a Shopify.dev page
2
2
  shopify doc fetch --url https://shopify.dev/docs/api/shopify-cli`,`# filter code examples to the language of the app you are building
3
3
  shopify doc fetch --url https://shopify.dev/docs/api/shopify-cli --language ruby`,`# save the document to a file instead of printing it
4
4
  shopify doc fetch --url https://shopify.dev/docs/api/shopify-cli --output docs/shopify-cli.md`,`# return a typed document as JSON
@@ -1,4 +1,4 @@
1
- import{a as U,b as F}from"./chunk-YF4AXKM4.js";import{a as at}from"./chunk-KHZF73BL.js";import{c as ct}from"./chunk-WBJFTCEJ.js";import{b as Xe,c as Qe,d as Ze,e as et,f as tt,h as rt,i as ot,l as nt,m as it,o as st}from"./chunk-YTL45RXR.js";import{a as Ue}from"./chunk-YNZLLZU2.js";import{d as je,f as j,p as qe,q as xe}from"./chunk-WPDJVUTY.js";import{c as Je,d as Ve,e as ze}from"./chunk-XLMKHTJ5.js";import{a as Ke}from"./chunk-R6US7F33.js";import{a as Be}from"./chunk-7N7KRZOM.js";import{k as Y,l as Ye,n as T}from"./chunk-DVFVO6ZE.js";import{p as We,s as X,u as M,v as Me}from"./chunk-CZNUBAAG.js";import{a as Ne,b as Ge}from"./chunk-BPKQA2EO.js";import{p as Re,t as De,u as _e,v as $e,x as He}from"./chunk-FDSNRKGQ.js";import{a as Dt}from"./chunk-7DBKSSDK.js";import{a as lt}from"./chunk-KFO2JNF5.js";import{Ca as ye,Ga as W}from"./chunk-YKDRUAY3.js";import{b as Oe,c as Ce,e as Le}from"./chunk-DMOLPSXF.js";import{B as Pe,C as Ee,M as Ae,S as Fe,U as Ie,v as be,x as ke,y as Se,z}from"./chunk-2KUM2RU4.js";import{c as we}from"./chunk-25MYHE4W.js";import{b as H,d as ue}from"./chunk-QBRRFFMZ.js";import{a as le}from"./chunk-LG3KEHGD.js";import{d as ge,e as ve}from"./chunk-I3WRA2LH.js";import{i as k}from"./chunk-TD6JBHUS.js";import{Aa as fe,Ba as he,Bb as B,Eb as S,Kb as Te,gb as N,hb as G,la as ce,tb as R,va as me,vb as K,xa as J,ya as de}from"./chunk-ZMOW2YZ4.js";import{i as I}from"./chunk-B4OMIONW.js";import{b as O,d as ae,e as C,i as pe,k as V}from"./chunk-3PYDIBTX.js";import{b as Rt}from"./chunk-AE3IQG7S.js";import{c as L}from"./chunk-IWTNUJGY.js";import{e as se,g as y}from"./chunk-VKWPEFWQ.js";y();y();y();import{AsyncLocalStorage as _t}from"node:async_hooks";import{Writable as $t}from"node:stream";import{format as Ht}from"node:util";var mt=new _t;async function dt(t,e,o=!1){let r=t.tee(new $t({write:(a,m,d)=>d()}),{stringWritesAreMessages:!0}),n=console.warn,s=!0;console.warn=c;try{return await mt.run(r,()=>N({consoleWarn:l},()=>pe({outputMode:o?"json":"text",sink:(a,m)=>{s&&a.message&&(o||a.type==="progress")&&r.write(a.message),!o&&!m?.alreadyRendered&&we(a)}},e)))}finally{s=!1,i()}function i(){console.warn=n}function c(...a){if(s&&mt.getStore()===r){l(Ht(...a));return}n(...a)}function l(a){if(s&&r.write(a),s&&o)return;(console.warn===c?n:console.warn)(a)}}y();y();y();var ft={workPromise:Promise.resolve()};async function ht(t,e,o,r,n){if(n.signal?.throwIfAborted(),o.length===0)return ft;S("Initiating theme asset reconciliation process");let{filesOnlyPresentLocally:s,filesOnlyPresentOnRemote:i,filesWithConflictingChecksums:c}=Nt(o,r),l=s.length===0&&i.length===0&&c.length===0;if(W(`theme-service:theme-reconciliation:manual:${l}`),l)return S("Local and remote checksums match - no need to reconcile theme assets"),ft;let a=await Yt({filesOnlyPresentLocally:s,filesOnlyPresentOnRemote:i,filesWithConflictingChecksums:c},n);return{workPromise:Mt(t,e,r,a,n.signal)}}function Nt(t,e){let o=new Set,r=[],n=[];for(let i of t){o.add(i.key);let c=e.files.get(i.key);c?i.checksum!==c.checksum&&n.push(i):r.push(i)}let s=Array.from(e.files.values()).filter(i=>!o.has(i.key));return{filesOnlyPresentOnRemote:Q(r,e),filesOnlyPresentLocally:Q(s,e),filesWithConflictingChecksums:Q(n,e)}}function Q(t,e){return e.applyIgnoreFilters(t).filter(r=>r.key.endsWith(".json"))}async function Z(t,e,o,r){if(t.length===0)return;if(r){Gt(t,o,r);return}ke({body:{list:{title:e,items:t.map(s=>s.key)}}}),await Ee({message:"Reconciliation Strategy",choices:[{label:o.remote.label,value:ee},{label:o.local.label,value:ut}]})===ee?o.remote.callback(t):o.local.callback(t)}function Gt(t,e,o){switch(o){case"keep-remote":e.remote.callback(t);break;case"keep-local":e.local.callback(t);break;case"abort":break}}function Wt(t){let e=[{title:"The files listed below are only present locally.",files:t.filesOnlyPresentLocally},{title:"The files listed below are only present on the remote theme.",files:t.filesOnlyPresentOnRemote},{title:"The files listed below differ between the local and remote versions.",files:t.filesWithConflictingChecksums}];throw new k("Theme JSON files need reconciliation.",e.filter(o=>o.files.length>0).map(o=>`${o.title}
1
+ import{a as U,b as F}from"./chunk-YF4AXKM4.js";import{a as at}from"./chunk-COGKVNQB.js";import{c as ct}from"./chunk-KORVOCNN.js";import{b as Xe,c as Qe,d as Ze,e as et,f as tt,h as rt,i as ot,l as nt,m as it,o as st}from"./chunk-OKRKVVTK.js";import{a as Ue}from"./chunk-3DB4EC62.js";import{d as je,f as j,p as qe,q as xe}from"./chunk-36S6MFJQ.js";import{c as Je,d as Ve,e as ze}from"./chunk-TXMZPF2U.js";import{a as Ke}from"./chunk-7AQZKPJU.js";import{a as Be}from"./chunk-GQ3LY7BY.js";import{k as Y,l as Ye,n as T}from"./chunk-RSNFNZ6F.js";import{p as We,s as X,u as M,v as Me}from"./chunk-VVHJ2AUF.js";import{a as Ne,b as Ge}from"./chunk-X5V7AGVU.js";import{p as Re,t as De,u as _e,v as $e,x as He}from"./chunk-FDSNRKGQ.js";import{a as Dt}from"./chunk-QLN6IOOY.js";import{a as lt}from"./chunk-ZQNGYJKJ.js";import{Da as ye,Ha as W}from"./chunk-UORSJB4A.js";import{b as Oe,c as Ce,e as Le}from"./chunk-IKXUYCK7.js";import{B as Pe,C as Ee,M as Ae,S as Fe,U as Ie,v as be,x as ke,y as Se,z}from"./chunk-7A4ZE5IS.js";import{c as we}from"./chunk-WLJDMI7E.js";import{b as H,d as ue}from"./chunk-QBRRFFMZ.js";import{a as le}from"./chunk-LG3KEHGD.js";import{d as ge,e as ve}from"./chunk-HI5FTI3M.js";import{j as k}from"./chunk-FJOVMEPN.js";import{Aa as fe,Ba as he,Bb as B,Eb as S,Kb as Te,gb as N,hb as G,la as ce,tb as R,va as me,vb as K,xa as J,ya as de}from"./chunk-OIQ5NQ5I.js";import{i as I}from"./chunk-B4OMIONW.js";import{b as O,d as ae,e as C,i as pe,k as V}from"./chunk-3PYDIBTX.js";import{b as Rt}from"./chunk-VBPMVVLV.js";import{c as L}from"./chunk-IWTNUJGY.js";import{e as se,g as y}from"./chunk-VKWPEFWQ.js";y();y();y();import{AsyncLocalStorage as _t}from"node:async_hooks";import{Writable as $t}from"node:stream";import{format as Ht}from"node:util";var mt=new _t;async function dt(t,e,o=!1){let r=t.tee(new $t({write:(a,m,d)=>d()}),{stringWritesAreMessages:!0}),n=console.warn,s=!0;console.warn=c;try{return await mt.run(r,()=>N({consoleWarn:l},()=>pe({outputMode:o?"json":"text",sink:(a,m)=>{s&&a.message&&(o||a.type==="progress")&&r.write(a.message),!o&&!m?.alreadyRendered&&we(a)}},e)))}finally{s=!1,i()}function i(){console.warn=n}function c(...a){if(s&&mt.getStore()===r){l(Ht(...a));return}n(...a)}function l(a){if(s&&r.write(a),s&&o)return;(console.warn===c?n:console.warn)(a)}}y();y();y();var ft={workPromise:Promise.resolve()};async function ht(t,e,o,r,n){if(n.signal?.throwIfAborted(),o.length===0)return ft;S("Initiating theme asset reconciliation process");let{filesOnlyPresentLocally:s,filesOnlyPresentOnRemote:i,filesWithConflictingChecksums:c}=Nt(o,r),l=s.length===0&&i.length===0&&c.length===0;if(W(`theme-service:theme-reconciliation:manual:${l}`),l)return S("Local and remote checksums match - no need to reconcile theme assets"),ft;let a=await Yt({filesOnlyPresentLocally:s,filesOnlyPresentOnRemote:i,filesWithConflictingChecksums:c},n);return{workPromise:Mt(t,e,r,a,n.signal)}}function Nt(t,e){let o=new Set,r=[],n=[];for(let i of t){o.add(i.key);let c=e.files.get(i.key);c?i.checksum!==c.checksum&&n.push(i):r.push(i)}let s=Array.from(e.files.values()).filter(i=>!o.has(i.key));return{filesOnlyPresentOnRemote:Q(r,e),filesOnlyPresentLocally:Q(s,e),filesWithConflictingChecksums:Q(n,e)}}function Q(t,e){return e.applyIgnoreFilters(t).filter(r=>r.key.endsWith(".json"))}async function Z(t,e,o,r){if(t.length===0)return;if(r){Gt(t,o,r);return}ke({body:{list:{title:e,items:t.map(s=>s.key)}}}),await Ee({message:"Reconciliation Strategy",choices:[{label:o.remote.label,value:ee},{label:o.local.label,value:ut}]})===ee?o.remote.callback(t):o.local.callback(t)}function Gt(t,e,o){switch(o){case"keep-remote":e.remote.callback(t);break;case"keep-local":e.local.callback(t);break;case"abort":break}}function Wt(t){let e=[{title:"The files listed below are only present locally.",files:t.filesOnlyPresentLocally},{title:"The files listed below are only present on the remote theme.",files:t.filesOnlyPresentOnRemote},{title:"The files listed below differ between the local and remote versions.",files:t.filesWithConflictingChecksums}];throw new k("Theme JSON files need reconciliation.",e.filter(o=>o.files.length>0).map(o=>`${o.title}
2
2
  ${o.files.map(r=>`- ${r.key}`).join(`
3
3
  `)}`).join(`
4
4
 
@@ -1 +1 @@
1
- import{a as d}from"./chunk-5HOZDOJ7.js";import{a as p,b as m}from"./chunk-AVJJGQOP.js";import{d as r,j as c}from"./chunk-5534MHZW.js";import{a as s}from"./chunk-RSZAAN37.js";import{P as a}from"./chunk-HMPRWNGG.js";import{c as n}from"./chunk-DMOLPSXF.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var t=class u extends s{static summary="Schedules manual-billing subscriptions to migrate to Shopify-managed app pricing.";static descriptionWithMarkdown="Schedules manual-billing subscriptions to migrate to Shopify-managed app pricing.\n\nWhen `--input` is omitted, the command reads CSV data from stdin. Use `--input <path>` to read from a file. `--input -` is also supported as an explicit stdin path.\n\n- Required CSV columns: `shop_id`, `target_plan_handle`, and `price_behavior`.\n- Optional CSV column: `notification`.\n- Example header: `shop_id,target_plan_handle,price_behavior,notification`.\n- Example row: `123456789,pro,HONOR_BILLING_PRICE,WHEN_REQUIRED`.\n\n`price_behavior` must be `HONOR_BILLING_PRICE` or `PLAN_PRICE`. `notification` can be `OPT_OUT` or `WHEN_REQUIRED` and defaults to `WHEN_REQUIRED` when omitted or blank.\n\nValidation is atomic: the command submits no operations unless the entire CSV is valid. Valid rows are submitted in batches of 250 shops. Preserve every operation GID printed by the command so you can check or cancel the submitted operations.\n\nRun the command from an app project. By default, it uses the Client ID from the active app configuration. Use `--path` to select an app directory or `--config` to select a configuration. Pass `--client-id` to select a different app within the project. Use `--reset` to relink the app.\n\nUse `--force` to skip confirmation and immediately submit every valid row. With `--watch`, human-readable output shows accepted identifiers before polling begins, then displays operation progress and the final outcome. With `--json --watch`, the command outputs one structured JSON document after every operation reaches a terminal status.";static jsonOutputSchema=c;static description=this.descriptionForHelp();static examples=["<%= config.bin %> <%= command.id %> --input migrations.csv --force","cat migrations.csv | <%= config.bin %> <%= command.id %> --force","<%= config.bin %> <%= command.id %> --input migrations.csv --path ../my-app --config staging --force --json","<%= config.bin %> <%= command.id %> --input migrations.csv --client-id <client-id> --force","<%= config.bin %> <%= command.id %> --input - --force --watch"];static flags={...r,...n};async run(){let{flags:i}=await this.parse(u),{app:l,remoteApp:h}=await a({directory:i.path,clientId:i["client-id"],forceRelink:i.reset,userProvidedConfigName:i.config}),f=await d({action:"schedule",input:i.input??"-",clientId:h.apiKey,skipConfirmation:i.force,watch:i.watch,...i.watch&&!i.json?{onSubmissionAccepted:p}:{}}),e=m(f,{json:i.json,watch:i.watch});return e!==0&&(process.exitCode=e),{app:l}}};export{t as a};
1
+ import{a as d}from"./chunk-HT5JQJMB.js";import{a as p,b as m}from"./chunk-CZYQIWNL.js";import{d as r,j as c}from"./chunk-6B5KM3A4.js";import{a as s}from"./chunk-R5COVIJM.js";import{P as a}from"./chunk-7FBOMPO5.js";import{c as n}from"./chunk-IKXUYCK7.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var t=class u extends s{static summary="Schedules manual-billing subscriptions to migrate to Shopify-managed app pricing.";static descriptionWithMarkdown="Schedules manual-billing subscriptions to migrate to Shopify-managed app pricing.\n\nWhen `--input` is omitted, the command reads CSV data from stdin. Use `--input <path>` to read from a file. `--input -` is also supported as an explicit stdin path.\n\n- Required CSV columns: `shop_id`, `target_plan_handle`, and `price_behavior`.\n- Optional CSV column: `notification`.\n- Example header: `shop_id,target_plan_handle,price_behavior,notification`.\n- Example row: `123456789,pro,HONOR_BILLING_PRICE,WHEN_REQUIRED`.\n\n`price_behavior` must be `HONOR_BILLING_PRICE` or `PLAN_PRICE`. `notification` can be `OPT_OUT` or `WHEN_REQUIRED` and defaults to `WHEN_REQUIRED` when omitted or blank.\n\nValidation is atomic: the command submits no operations unless the entire CSV is valid. Valid rows are submitted in batches of 250 shops. Preserve every operation GID printed by the command so you can check or cancel the submitted operations.\n\nRun the command from an app project. By default, it uses the Client ID from the active app configuration. Use `--path` to select an app directory or `--config` to select a configuration. Pass `--client-id` to select a different app within the project. Use `--reset` to relink the app.\n\nUse `--force` to skip confirmation and immediately submit every valid row. With `--watch`, human-readable output shows accepted identifiers before polling begins, then displays operation progress and the final outcome. With `--json --watch`, the command outputs one structured JSON document after every operation reaches a terminal status.";static jsonOutputSchema=c;static description=this.descriptionForHelp();static examples=["<%= config.bin %> <%= command.id %> --input migrations.csv --force","cat migrations.csv | <%= config.bin %> <%= command.id %> --force","<%= config.bin %> <%= command.id %> --input migrations.csv --path ../my-app --config staging --force --json","<%= config.bin %> <%= command.id %> --input migrations.csv --client-id <client-id> --force","<%= config.bin %> <%= command.id %> --input - --force --watch"];static flags={...r,...n};async run(){let{flags:i}=await this.parse(u),{app:l,remoteApp:h}=await a({directory:i.path,clientId:i["client-id"],forceRelink:i.reset,userProvidedConfigName:i.config}),f=await d({action:"schedule",input:i.input??"-",clientId:h.apiKey,skipConfirmation:i.force,watch:i.watch,...i.watch&&!i.json?{onSubmissionAccepted:p}:{}}),e=m(f,{json:i.json,watch:i.watch});return e!==0&&(process.exitCode=e),{app:l}}};export{t as a};
@@ -1 +1 @@
1
- import{a as d}from"./chunk-5HOZDOJ7.js";import{a as p,b as m}from"./chunk-AVJJGQOP.js";import{d as r,j as c}from"./chunk-5534MHZW.js";import{a as s}from"./chunk-RSZAAN37.js";import{P as a}from"./chunk-HMPRWNGG.js";import{c as n}from"./chunk-DMOLPSXF.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var e=class u extends s{static summary="Reverses app subscription migrations that are still scheduled.";static descriptionWithMarkdown="Reverses scheduled app subscription migrations that have not migrated yet.\n\nWhen `--input` is omitted, the command reads CSV data from stdin. Use `--input <path>` to read from a file. `--input -` is also supported as an explicit stdin path.\n\n- Required CSV header: `shop_id`.\n- Example row: `123456789`.\n\nThe CSV can contain only the `shop_id` header, or it can reuse the complete CSV supplied to `schedule`; schedule-only columns are ignored.\n\nUnscheduling is not a rollback after a subscription has migrated. The command validates the entire CSV before sending any mutation. Use `--force` to skip confirmation and immediately submit every valid row.\n\nOperations are submitted in batches of 250 shops. Preserve every operation GID printed by the command so you can check or cancel the submitted operations. With `--watch`, human-readable output shows accepted identifiers before polling begins, then displays operation progress and the final outcome. With `--json --watch`, the command outputs one structured JSON document after every operation reaches a terminal status.\n\nRun the command from an app project. By default, it uses the Client ID from the active app configuration. Use `--path` to select an app directory or `--config` to select a configuration. Pass `--client-id` to select a different app within the project. Use `--reset` to relink the app.";static jsonOutputSchema=c;static description=this.descriptionForHelp();static examples=["<%= config.bin %> <%= command.id %> --input migrations.csv --force","cat migrations.csv | <%= config.bin %> <%= command.id %> --force","<%= config.bin %> <%= command.id %> --input migrations.csv --path ../my-app --config staging --force --json","<%= config.bin %> <%= command.id %> --input migrations.csv --client-id <client-id> --force","<%= config.bin %> <%= command.id %> --input - --force --watch"];static flags={...r,...n};async run(){let{flags:t}=await this.parse(u),{app:h,remoteApp:l}=await a({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config}),f=await d({action:"unschedule",input:t.input??"-",clientId:l.apiKey,skipConfirmation:t.force,watch:t.watch,...t.watch&&!t.json?{onSubmissionAccepted:p}:{}}),i=m(f,{json:t.json,watch:t.watch});return i!==0&&(process.exitCode=i),{app:h}}};export{e as a};
1
+ import{a as d}from"./chunk-HT5JQJMB.js";import{a as p,b as m}from"./chunk-CZYQIWNL.js";import{d as r,j as c}from"./chunk-6B5KM3A4.js";import{a as s}from"./chunk-R5COVIJM.js";import{P as a}from"./chunk-7FBOMPO5.js";import{c as n}from"./chunk-IKXUYCK7.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var e=class u extends s{static summary="Reverses app subscription migrations that are still scheduled.";static descriptionWithMarkdown="Reverses scheduled app subscription migrations that have not migrated yet.\n\nWhen `--input` is omitted, the command reads CSV data from stdin. Use `--input <path>` to read from a file. `--input -` is also supported as an explicit stdin path.\n\n- Required CSV header: `shop_id`.\n- Example row: `123456789`.\n\nThe CSV can contain only the `shop_id` header, or it can reuse the complete CSV supplied to `schedule`; schedule-only columns are ignored.\n\nUnscheduling is not a rollback after a subscription has migrated. The command validates the entire CSV before sending any mutation. Use `--force` to skip confirmation and immediately submit every valid row.\n\nOperations are submitted in batches of 250 shops. Preserve every operation GID printed by the command so you can check or cancel the submitted operations. With `--watch`, human-readable output shows accepted identifiers before polling begins, then displays operation progress and the final outcome. With `--json --watch`, the command outputs one structured JSON document after every operation reaches a terminal status.\n\nRun the command from an app project. By default, it uses the Client ID from the active app configuration. Use `--path` to select an app directory or `--config` to select a configuration. Pass `--client-id` to select a different app within the project. Use `--reset` to relink the app.";static jsonOutputSchema=c;static description=this.descriptionForHelp();static examples=["<%= config.bin %> <%= command.id %> --input migrations.csv --force","cat migrations.csv | <%= config.bin %> <%= command.id %> --force","<%= config.bin %> <%= command.id %> --input migrations.csv --path ../my-app --config staging --force --json","<%= config.bin %> <%= command.id %> --input migrations.csv --client-id <client-id> --force","<%= config.bin %> <%= command.id %> --input - --force --watch"];static flags={...r,...n};async run(){let{flags:t}=await this.parse(u),{app:h,remoteApp:l}=await a({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config}),f=await d({action:"unschedule",input:t.input??"-",clientId:l.apiKey,skipConfirmation:t.force,watch:t.watch,...t.watch&&!t.json?{onSubmissionAccepted:p}:{}}),i=m(f,{json:t.json,watch:t.watch});return i!==0&&(process.exitCode=i),{app:h}}};export{e as a};