shopify 4.9.5 → 5.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (501) hide show
  1. package/dist/analytics-RSUIYNLC.js +1 -0
  2. package/dist/analytics-V2SDYXQJ.js +1 -0
  3. package/dist/assets/hydrogen/starter/CHANGELOG.md +7 -0
  4. package/dist/assets/hydrogen/starter/package.json +2 -2
  5. package/dist/assets/hydrogen/vite/package.json +3 -4
  6. package/dist/assets/hydrogen/vite/vite.config.js +3 -3
  7. package/dist/bootstrap.js +1 -1
  8. package/dist/chunk-2AW3KBTP.js +1 -0
  9. package/dist/{chunk-S6A7TMR4.js → chunk-2CJQQQW4.js} +1 -1
  10. package/dist/{chunk-7LB6DPB6.js → chunk-2M4BKFYF.js} +1 -1
  11. package/dist/chunk-2M535QQJ.js +6 -0
  12. package/dist/chunk-2NZ7GDDR.js +2 -0
  13. package/dist/{chunk-QUO4RD3W.js → chunk-2QQ7EBJD.js} +1 -1
  14. package/dist/chunk-2RFCYZMG.js +47 -0
  15. package/dist/chunk-2S5NPJEJ.js +5 -0
  16. package/dist/chunk-2TPLPZA2.js +3 -0
  17. package/dist/{chunk-ANG44FIF.js → chunk-2YGPWG3I.js} +1 -1
  18. package/dist/chunk-32O27NE3.js +1 -0
  19. package/dist/chunk-335BUVBP.js +1 -0
  20. package/dist/{chunk-MZL6VM3W.js → chunk-364BVGRY.js} +1 -1
  21. package/dist/{chunk-4VS7YD53.js → chunk-36TZ447N.js} +1 -1
  22. package/dist/chunk-37P5YOP2.js +7 -0
  23. package/dist/chunk-3G2PEYPI.js +2 -0
  24. package/dist/{chunk-2II4W4ZF.js → chunk-3JACWBUC.js} +1 -1
  25. package/dist/chunk-43HKFLOU.js +3 -0
  26. package/dist/chunk-46JYM3GH.js +1 -0
  27. package/dist/chunk-4EDE3UH7.js +18 -0
  28. package/dist/{chunk-ND6O6KT6.js → chunk-4GQEXVDT.js} +1 -1
  29. package/dist/{chunk-5XTJ4OL4.js → chunk-4IUXLUFD.js} +1 -1
  30. package/dist/chunk-4QZ6OBXL.js +4 -0
  31. package/dist/{chunk-XVFQ6CNO.js → chunk-4SDCXKYR.js} +9 -6
  32. package/dist/chunk-56GKTWFF.js +5 -0
  33. package/dist/chunk-5AQ5JT2V.js +7 -0
  34. package/dist/{chunk-SUTVPAJF.js → chunk-5AWELO3D.js} +1 -1
  35. package/dist/{chunk-LD6ZCTZ3.js → chunk-5B76DT7X.js} +1 -1
  36. package/dist/chunk-5D4FNAAD.js +3 -0
  37. package/dist/chunk-5TWYJQQO.js +1 -0
  38. package/dist/{chunk-3XAD2E55.js → chunk-5XOEMYEQ.js} +1 -1
  39. package/dist/chunk-5YUDEPEY.js +1 -0
  40. package/dist/chunk-5YXYYQBX.js +1 -0
  41. package/dist/chunk-63UKZLPC.js +1 -0
  42. package/dist/chunk-6JZC6UKY.js +20 -0
  43. package/dist/chunk-6PUU6ZNQ.js +1 -0
  44. package/dist/chunk-6Y6A2QGK.js +3 -0
  45. package/dist/chunk-75LAVRRL.js +274 -0
  46. package/dist/chunk-7AWAOPLA.js +1 -0
  47. package/dist/chunk-7GHSE7SG.js +1 -0
  48. package/dist/{chunk-CEQ5S3HH.js → chunk-7NYCJG2U.js} +1 -1
  49. package/dist/chunk-7U2MTK6I.js +1 -0
  50. package/dist/{chunk-NHE46R6C.js → chunk-7XAEI4XT.js} +1 -1
  51. package/dist/chunk-7Y7AZRL3.js +10 -0
  52. package/dist/chunk-A7LBGXWG.js +1 -0
  53. package/dist/{chunk-SEXH4EP5.js → chunk-ACA2BGAD.js} +1 -1
  54. package/dist/chunk-ADVLRSSO.js +1 -0
  55. package/dist/chunk-AIEVQSI3.js +1 -0
  56. package/dist/chunk-AOBE6HN6.js +31 -0
  57. package/dist/chunk-AQ34X5B3.js +2 -0
  58. package/dist/chunk-B2VE7WOX.js +1 -0
  59. package/dist/chunk-B4ISKIXN.js +5 -0
  60. package/dist/chunk-BAHIL37I.js +1 -0
  61. package/dist/chunk-BB7GAZP6.js +1 -0
  62. package/dist/{chunk-AJMJQA4J.js → chunk-BN7ZXAZJ.js} +1 -1
  63. package/dist/chunk-BNTOGZLY.js +1 -0
  64. package/dist/chunk-BU3JQM3W.js +1 -0
  65. package/dist/chunk-C3LL5CZA.js +1 -0
  66. package/dist/{chunk-PIGERIRY.js → chunk-C4EKNOLY.js} +1 -1
  67. package/dist/{chunk-YN4FSUFF.js → chunk-CFUZ6574.js} +1 -1
  68. package/dist/{chunk-7DSH4CRU.js → chunk-CKVVJ4XO.js} +1 -1
  69. package/dist/chunk-CNPBDSDL.js +1 -0
  70. package/dist/{chunk-BAHM64B4.js → chunk-CWR3IFXD.js} +1 -1
  71. package/dist/{chunk-T3UCIWRH.js → chunk-CX3ANDPI.js} +1 -1
  72. package/dist/chunk-CXPYOLGM.js +4 -0
  73. package/dist/{chunk-MTBABHUB.js → chunk-D4LFWIFE.js} +1 -1
  74. package/dist/chunk-DM7BTMFP.js +2 -0
  75. package/dist/{chunk-WGO2GC6I.js → chunk-DSKAIC7O.js} +1 -1
  76. package/dist/{chunk-WKVFVT3H.js → chunk-DTRENW4Q.js} +1 -1
  77. package/dist/{chunk-G362JEAV.js → chunk-DVW7NDVD.js} +1 -1
  78. package/dist/chunk-E3CTHNQS.js +1 -0
  79. package/dist/chunk-EA5XVQJT.js +1 -0
  80. package/dist/{chunk-K6FH5JSY.js → chunk-EH22T4FI.js} +2 -2
  81. package/dist/{chunk-5NCWBBRW.js → chunk-ETXBF6Q7.js} +1 -1
  82. package/dist/{chunk-5GFVMGAZ.js → chunk-EXTVC33U.js} +1 -1
  83. package/dist/chunk-F3OM2YO6.js +1 -0
  84. package/dist/{chunk-MWWULCLD.js → chunk-FHNJLON5.js} +1 -1
  85. package/dist/chunk-FK5OFLSJ.js +1 -0
  86. package/dist/chunk-FNWXMCSD.js +97 -0
  87. package/dist/chunk-FPOZMNT2.js +2 -0
  88. package/dist/chunk-FS5PZCZ3.js +1 -0
  89. package/dist/chunk-FTHVOIK7.js +4 -0
  90. package/dist/chunk-FVRI7ZKE.js +103 -0
  91. package/dist/chunk-FZCGRIOM.js +1 -0
  92. package/dist/chunk-GCKGQFV7.js +1 -0
  93. package/dist/chunk-GGJUPL4W.js +6 -0
  94. package/dist/{chunk-RW3P3UMU.js → chunk-GHU6YEXH.js} +2 -2
  95. package/dist/chunk-GNPIKPHB.js +1 -0
  96. package/dist/{chunk-PT3OZEBI.js → chunk-GSGCSBRN.js} +1 -1
  97. package/dist/chunk-H57KYDEI.js +16 -0
  98. package/dist/chunk-HF4NDEX3.js +1 -0
  99. package/dist/chunk-HNU6R7RT.js +7 -0
  100. package/dist/{chunk-65GNYRYR.js → chunk-HP2ZAAY7.js} +2 -2
  101. package/dist/chunk-HPT3UXZ5.js +4 -0
  102. package/dist/chunk-HT66BOEC.js +8 -0
  103. package/dist/chunk-HXNGLDMU.js +1 -0
  104. package/dist/chunk-IAL6IQYW.js +16 -0
  105. package/dist/{chunk-PIZDYS7T.js → chunk-IILLQOUC.js} +60 -60
  106. package/dist/chunk-IULZYDCI.js +9 -0
  107. package/dist/chunk-IWTNUJGY.js +2 -0
  108. package/dist/chunk-IWTOC6DG.js +1 -0
  109. package/dist/chunk-IY5EI5V2.js +1 -0
  110. package/dist/{chunk-AODTY2BL.js → chunk-J3UXIC23.js} +4 -4
  111. package/dist/{chunk-EZG5EB7D.js → chunk-J5DUFSR4.js} +1 -1
  112. package/dist/chunk-J7BTC45S.js +1 -0
  113. package/dist/chunk-JMVK2BIB.js +3 -0
  114. package/dist/chunk-JUTULEWW.js +5 -0
  115. package/dist/{chunk-DO5YFMTJ.js → chunk-K3YALQBQ.js} +1 -1
  116. package/dist/{chunk-XPDHT3Z4.js → chunk-KGASGUDQ.js} +1 -1
  117. package/dist/{chunk-JPFHPVIO.js → chunk-KLYGMYXV.js} +1 -1
  118. package/dist/chunk-KNQXCU3Y.js +6 -0
  119. package/dist/{chunk-4BXQTW5G.js → chunk-KOTZSPZA.js} +1 -1
  120. package/dist/chunk-KT5QQOES.js +3 -0
  121. package/dist/chunk-KVF55INC.js +5 -0
  122. package/dist/chunk-L6VONMA2.js +5 -0
  123. package/dist/chunk-LENSEW2F.js +2 -0
  124. package/dist/{chunk-35NTERVR.js → chunk-LGXNXAQA.js} +2 -2
  125. package/dist/{chunk-TQ7URMGS.js → chunk-LQ7ENG4V.js} +1 -1
  126. package/dist/chunk-LR4J4KYJ.js +5 -0
  127. package/dist/chunk-LWMKZJ4M.js +1 -0
  128. package/dist/chunk-M2KX3PXA.js +1 -0
  129. package/dist/{chunk-VSFZEGIK.js → chunk-M73IECPW.js} +1 -1
  130. package/dist/{chunk-Z4DESIR5.js → chunk-M7NLCGCP.js} +1 -1
  131. package/dist/chunk-MHWETFNT.js +1 -0
  132. package/dist/chunk-MMUGP3WP.js +7 -0
  133. package/dist/{chunk-VG5ZDVDQ.js → chunk-MNWT2SQO.js} +86 -200
  134. package/dist/chunk-MS7DTL4U.js +213 -0
  135. package/dist/chunk-MU2X7NGF.js +11 -0
  136. package/dist/chunk-MXXMIPUN.js +8 -0
  137. package/dist/{chunk-XTOOTN4P.js → chunk-MZCIRMZJ.js} +1 -1
  138. package/dist/{chunk-LLNUIGHP.js → chunk-MZWPIFAM.js} +4 -4
  139. package/dist/{chunk-HB4YI2PF.js → chunk-NCPZVARH.js} +118 -118
  140. package/dist/{chunk-LCMDVUVO.js → chunk-NJVNGEOU.js} +30 -30
  141. package/dist/chunk-NMECLRGK.js +11 -0
  142. package/dist/{chunk-VNG2I7NM.js → chunk-NMLLRFZF.js} +1 -1
  143. package/dist/chunk-NPB753M3.js +1 -0
  144. package/dist/chunk-NUCDRKDW.js +5 -0
  145. package/dist/chunk-OH7BQZQ7.js +2 -0
  146. package/dist/chunk-OLKLHVHA.js +22 -0
  147. package/dist/chunk-OPVXPDOQ.js +1 -0
  148. package/dist/chunk-OQUXGAF2.js +1 -0
  149. package/dist/chunk-OUMERKRE.js +10 -0
  150. package/dist/{chunk-PFXDXD5O.js → chunk-OYGIQDME.js} +1 -1
  151. package/dist/{chunk-4IAGBAQD.js → chunk-P5W5RVE6.js} +1 -1
  152. package/dist/chunk-PNZURX3S.js +1 -0
  153. package/dist/chunk-PRKJVU4Y.js +1 -0
  154. package/dist/{chunk-2VGPNRHH.js → chunk-PVASYKSJ.js} +2 -2
  155. package/dist/chunk-PXFPVGWV.js +1 -0
  156. package/dist/chunk-Q2ORJEB2.js +25 -0
  157. package/dist/chunk-QBE6XVU3.js +1 -0
  158. package/dist/chunk-QFWWCZOI.js +1 -0
  159. package/dist/{chunk-TR4OWSEX.js → chunk-QFYLJVJW.js} +1 -1
  160. package/dist/{chunk-Y5VFOLNQ.js → chunk-QGWC23HQ.js} +1 -1
  161. package/dist/chunk-QVVQUJQL.js +2 -0
  162. package/dist/{chunk-762IKULK.js → chunk-QX3T6G5X.js} +1 -1
  163. package/dist/chunk-QYFU363G.js +17 -0
  164. package/dist/chunk-RDXLDCMI.js +3 -0
  165. package/dist/chunk-REDUS6EW.js +1 -0
  166. package/dist/{chunk-KOS53Z7E.js → chunk-RFZNFTVM.js} +1 -1
  167. package/dist/chunk-RIG66DIQ.js +18 -0
  168. package/dist/chunk-RNUEPPVN.js +1 -0
  169. package/dist/chunk-RWTAPWLJ.js +3 -0
  170. package/dist/chunk-T5YVYVSW.js +1 -0
  171. package/dist/{chunk-VTOPYXHO.js → chunk-TTBNFGCW.js} +2 -2
  172. package/dist/chunk-UDPYSL3M.js +4 -0
  173. package/dist/{chunk-EAVD3OH2.js → chunk-ULMNNGGX.js} +1 -1
  174. package/dist/chunk-URCH4ITT.js +1 -0
  175. package/dist/chunk-UU2R56LN.js +12 -0
  176. package/dist/{chunk-YIZAQABE.js → chunk-V2FCZC7U.js} +1 -1
  177. package/dist/chunk-V654BMS7.js +376 -0
  178. package/dist/{chunk-5BGUKF7L.js → chunk-V75WUEFU.js} +1 -1
  179. package/dist/{chunk-5O7JTVO2.js → chunk-V7H7ITCF.js} +1 -1
  180. package/dist/{chunk-EO422KZZ.js → chunk-VG2AESTZ.js} +1 -1
  181. package/dist/chunk-VXD26GIG.js +1 -0
  182. package/dist/chunk-VXL5FBE7.js +3 -0
  183. package/dist/{chunk-RUDHGUIM.js → chunk-W7S6SYBM.js} +1 -1
  184. package/dist/chunk-WAY723TL.js +16 -0
  185. package/dist/{chunk-4TF7ER72.js → chunk-WBJ6ZHYH.js} +1 -1
  186. package/dist/chunk-WFOU5M4H.js +16 -0
  187. package/dist/chunk-WGOSE3RL.js +4 -0
  188. package/dist/chunk-WQ6W725N.js +1 -0
  189. package/dist/{chunk-7BWSN3SG.js → chunk-WQOPLNDH.js} +1 -1
  190. package/dist/chunk-X4A5D3PZ.js +8 -0
  191. package/dist/chunk-X7DCL5LT.js +1 -0
  192. package/dist/{chunk-HY6EXJBZ.js → chunk-XDXHSGDL.js} +1 -1
  193. package/dist/chunk-XKKKMV46.js +6 -0
  194. package/dist/chunk-XRVJJG6W.js +26 -0
  195. package/dist/chunk-XV6XCOTG.js +319 -0
  196. package/dist/chunk-XYFYQWKW.js +1 -0
  197. package/dist/{chunk-BD2L6YE5.js → chunk-XZLM4HLO.js} +1 -1
  198. package/dist/{chunk-YLCYRG2T.js → chunk-YCUEDZDA.js} +1 -1
  199. package/dist/{chunk-MF7IHOM5.js → chunk-YFRI75U4.js} +1 -1
  200. package/dist/chunk-YQ63ZFYT.js +1 -0
  201. package/dist/{chunk-I3J63RFV.js → chunk-YTUUU33R.js} +1 -1
  202. package/dist/chunk-YXIFSIRX.js +1 -0
  203. package/dist/{chunk-QBIYAMSH.js → chunk-ZBVHPC6W.js} +1 -1
  204. package/dist/chunk-ZDQO6CNY.js +1 -0
  205. package/dist/{chunk-LG6DGIFX.js → chunk-ZHHTQRWU.js} +1 -1
  206. package/dist/chunk-ZTZGDZCE.js +7 -0
  207. package/dist/{chunk-MQ4WV4B6.js → chunk-ZVEBXHEY.js} +1 -1
  208. package/dist/cli/commands/app/build.js +1 -1
  209. package/dist/cli/commands/app/bulk/cancel.js +1 -1
  210. package/dist/cli/commands/app/bulk/execute.js +1 -1
  211. package/dist/cli/commands/app/bulk/status.js +1 -1
  212. package/dist/cli/commands/app/config/link.js +1 -1
  213. package/dist/cli/commands/app/config/pull.js +1 -1
  214. package/dist/cli/commands/app/config/use.js +1 -1
  215. package/dist/cli/commands/app/config/validate.js +1 -1
  216. package/dist/cli/commands/app/demo/watcher.js +1 -1
  217. package/dist/cli/commands/app/deploy.js +1 -1
  218. package/dist/cli/commands/app/dev/clean.js +1 -1
  219. package/dist/cli/commands/app/dev.js +1 -1
  220. package/dist/cli/commands/app/env/pull.js +1 -1
  221. package/dist/cli/commands/app/env/show.js +1 -1
  222. package/dist/cli/commands/app/execute.js +1 -1
  223. package/dist/cli/commands/app/function/build.js +1 -1
  224. package/dist/cli/commands/app/function/info.js +1 -1
  225. package/dist/cli/commands/app/function/replay.js +1 -1
  226. package/dist/cli/commands/app/function/run.js +1 -1
  227. package/dist/cli/commands/app/function/schema.js +1 -1
  228. package/dist/cli/commands/app/function/typegen.js +1 -1
  229. package/dist/cli/commands/app/generate/extension.js +1 -1
  230. package/dist/cli/commands/app/graphiql.js +1 -1
  231. package/dist/cli/commands/app/import/channel-config.js +1 -1
  232. package/dist/cli/commands/app/import/custom-data-definitions.js +1 -1
  233. package/dist/cli/commands/app/import/dashboard-extensions.js +1 -1
  234. package/dist/cli/commands/app/import-custom-data-definitions.js +1 -1
  235. package/dist/cli/commands/app/import-extensions.js +1 -1
  236. package/dist/cli/commands/app/info.js +1 -1
  237. package/dist/cli/commands/app/init.js +1 -1
  238. package/dist/cli/commands/app/logs.js +1 -1
  239. package/dist/cli/commands/app/release.js +1 -1
  240. package/dist/cli/commands/app/security/check.js +1 -1
  241. package/dist/cli/commands/app/security/clean.js +1 -1
  242. package/dist/cli/commands/app/security/instructions.js +1 -1
  243. package/dist/cli/commands/app/security/record.js +1 -1
  244. package/dist/cli/commands/app/security/review.js +1 -1
  245. package/dist/cli/commands/app/subscription-migrations/cancel.js +1 -1
  246. package/dist/cli/commands/app/subscription-migrations/list.js +1 -1
  247. package/dist/cli/commands/app/subscription-migrations/schedule.js +1 -1
  248. package/dist/cli/commands/app/subscription-migrations/status.js +1 -1
  249. package/dist/cli/commands/app/subscription-migrations/unschedule.js +1 -1
  250. package/dist/cli/commands/app/versions/list.js +1 -1
  251. package/dist/cli/commands/app/webhook/trigger.js +1 -1
  252. package/dist/cli/commands/auth/login.js +1 -1
  253. package/dist/cli/commands/auth/logout.js +1 -1
  254. package/dist/cli/commands/cache/clear.js +1 -1
  255. package/dist/cli/commands/config/autoupgrade/off.js +1 -1
  256. package/dist/cli/commands/config/autoupgrade/on.js +1 -1
  257. package/dist/cli/commands/config/autoupgrade/status.js +1 -1
  258. package/dist/cli/commands/debug/command-flags.js +1 -1
  259. package/dist/cli/commands/doc/fetch.d.ts +34 -1
  260. package/dist/cli/commands/doc/fetch.js +1 -1
  261. package/dist/cli/commands/doc/search.d.ts +53 -1
  262. package/dist/cli/commands/doc/search.js +1 -1
  263. package/dist/cli/commands/docs/generate.js +1 -1
  264. package/dist/cli/commands/doctor-release/doctor-release.js +1 -1
  265. package/dist/cli/commands/doctor-release/theme/index.js +1 -1
  266. package/dist/cli/commands/help.d.ts +6 -6
  267. package/dist/cli/commands/help.js +1 -1
  268. package/dist/cli/commands/kitchen-sink/async.js +1 -1
  269. package/dist/cli/commands/kitchen-sink/index.js +1 -1
  270. package/dist/cli/commands/kitchen-sink/prompts.js +1 -1
  271. package/dist/cli/commands/kitchen-sink/static.js +1 -1
  272. package/dist/cli/commands/notifications/generate.js +1 -1
  273. package/dist/cli/commands/notifications/list.js +1 -1
  274. package/dist/cli/commands/organization/list.js +1 -1
  275. package/dist/cli/commands/search.js +1 -1
  276. package/dist/cli/commands/send-analytics.js +1 -1
  277. package/dist/cli/commands/theme/check.js +1 -1
  278. package/dist/cli/commands/theme/console.js +1 -1
  279. package/dist/cli/commands/theme/delete.js +1 -1
  280. package/dist/cli/commands/theme/dev.js +1 -1
  281. package/dist/cli/commands/theme/duplicate.js +1 -1
  282. package/dist/cli/commands/theme/info.js +1 -1
  283. package/dist/cli/commands/theme/init.js +1 -1
  284. package/dist/cli/commands/theme/language-server.js +1 -1
  285. package/dist/cli/commands/theme/list.js +1 -1
  286. package/dist/cli/commands/theme/metafields/pull.js +1 -1
  287. package/dist/cli/commands/theme/open.js +1 -1
  288. package/dist/cli/commands/theme/package.js +1 -1
  289. package/dist/cli/commands/theme/preview.js +1 -1
  290. package/dist/cli/commands/theme/profile.js +1 -1
  291. package/dist/cli/commands/theme/publish.js +1 -1
  292. package/dist/cli/commands/theme/pull.js +1 -1
  293. package/dist/cli/commands/theme/push.js +1 -1
  294. package/dist/cli/commands/theme/rename.js +1 -1
  295. package/dist/cli/commands/theme/share.js +1 -1
  296. package/dist/cli/commands/upgrade.d.ts +64 -0
  297. package/dist/cli/commands/upgrade.js +1 -1
  298. package/dist/cli/commands/version.js +1 -1
  299. package/dist/cli/help.js +1 -1
  300. package/dist/cli/services/commands/doc/fetch-result.d.ts +2 -0
  301. package/dist/cli/services/commands/doc/fetch-result.js +22 -0
  302. package/dist/cli/services/commands/doc/fetch.d.ts +2 -1
  303. package/dist/cli/services/commands/doc/fetch.js +2 -15
  304. package/dist/cli/services/commands/doc/search-result.d.ts +2 -0
  305. package/dist/cli/services/commands/doc/search-result.js +14 -0
  306. package/dist/cli/services/commands/doc/search.d.ts +9 -1
  307. package/dist/cli/services/commands/doc/search.js +27 -2
  308. package/dist/cli/services/commands/doc/types.d.ts +107 -0
  309. package/dist/cli/services/commands/doc/types.js +47 -0
  310. package/dist/cli/services/commands/help/types.d.ts +6 -6
  311. package/dist/command-event-context-LFUZ7UCA.js +1 -0
  312. package/dist/command-json-schema-6EGXCM4B.js +1 -0
  313. package/dist/command-registry.js +1 -1
  314. package/dist/conf-store-E7ELDWBA.js +1 -0
  315. package/dist/custom-oclif-loader-FKFZJPHF.js +1 -0
  316. package/dist/deprecations-RNGBHZYB.js +1 -0
  317. package/dist/dist-VHIZZDYK.js +1 -0
  318. package/dist/dist-WXI5YQYP.js +1 -0
  319. package/dist/{environment-RSUK27TA.js → environment-O7ECODHU.js} +1 -1
  320. package/dist/environments-WZJ6MRTH.js +1 -0
  321. package/dist/error-IFB626JA.js +1 -0
  322. package/dist/error-handler-OVJYVIOZ.js +1 -0
  323. package/dist/fs-7UOUHJDO.js +1 -0
  324. package/dist/hooks/did-you-mean.js +1 -1
  325. package/dist/hooks/hydrogen-init.js +1 -1
  326. package/dist/hooks/plugin-plugins.js +1 -1
  327. package/dist/hooks/postrun.js +1 -1
  328. package/dist/hooks/prerun.js +1 -1
  329. package/dist/hooks/public-metadata.js +1 -1
  330. package/dist/hooks/sensitive-metadata.js +1 -1
  331. package/dist/hooks/tunnel-provider.js +1 -1
  332. package/dist/hooks/tunnel-start.js +1 -1
  333. package/dist/index.js +13 -13
  334. package/dist/is-global-XW3CVHLK.js +1 -0
  335. package/dist/json-error-C2U7ZLCG.js +1 -0
  336. package/dist/{lib-TYM5B75S.js → lib-PJHT4MKY.js} +1 -1
  337. package/dist/{lib-55QUD4AJ.js → lib-VKSQ65BQ.js} +1 -1
  338. package/dist/{lib-PH52G55H.js → lib-YEZOHXF3.js} +1 -1
  339. package/dist/{local-ZZGRGYUP.js → local-KA3IWOZ6.js} +1 -1
  340. package/dist/{metadata-YQNVKC2R.js → metadata-6JI7HF5B.js} +1 -1
  341. package/dist/{morph-BABFBRSW.js → morph-CRY35DIK.js} +1 -1
  342. package/dist/node-package-manager-X3QIEMMX.js +1 -0
  343. package/dist/notifications-system-OXGLT2R4.js +1 -0
  344. package/dist/os-NORIEVMI.js +1 -0
  345. package/dist/out-B2GISN65.js +1 -0
  346. package/dist/output-K3JTLRJD.js +1 -0
  347. package/dist/{path-CPAYTWQW.js → path-3L2QRACZ.js} +1 -1
  348. package/dist/system-LTHR2T7L.js +1 -0
  349. package/dist/tsconfig.tsbuildinfo +1 -1
  350. package/dist/ui-MYUBVKCK.js +1 -0
  351. package/dist/upgrade-MFTWBXL3.js +1 -0
  352. package/dist/version-BNGPPAUU.js +1 -0
  353. package/dist/version-RCGFWSB4.js +1 -0
  354. package/dist/workerd-ISSXMKIH.js +18 -0
  355. package/oclif.manifest.json +1669 -429
  356. package/package.json +8 -8
  357. package/dist/analytics-PBZEKUGU.js +0 -1
  358. package/dist/analytics-WVGBNFGK.js +0 -1
  359. package/dist/chunk-2EC5SUGK.js +0 -19
  360. package/dist/chunk-2QENUJVG.js +0 -1
  361. package/dist/chunk-2RONPKOD.js +0 -1
  362. package/dist/chunk-2WDJXERZ.js +0 -25
  363. package/dist/chunk-32NWVYUC.js +0 -1
  364. package/dist/chunk-32RRWGNS.js +0 -1
  365. package/dist/chunk-32VQQ6EU.js +0 -1
  366. package/dist/chunk-34RFTE5T.js +0 -4
  367. package/dist/chunk-35VQQKVX.js +0 -1
  368. package/dist/chunk-3N6NKC2U.js +0 -1
  369. package/dist/chunk-3Q5BAPQK.js +0 -7
  370. package/dist/chunk-42DMJGOW.js +0 -2
  371. package/dist/chunk-4CTTWXUX.js +0 -32
  372. package/dist/chunk-4HBKQUKY.js +0 -1
  373. package/dist/chunk-4MQXMIWQ.js +0 -7
  374. package/dist/chunk-5APLAJCB.js +0 -3
  375. package/dist/chunk-5AQNISGC.js +0 -1
  376. package/dist/chunk-5OM72O4N.js +0 -1
  377. package/dist/chunk-5SLKHURV.js +0 -1
  378. package/dist/chunk-5VRB3FBD.js +0 -6
  379. package/dist/chunk-62GA7XR3.js +0 -18
  380. package/dist/chunk-62LMVFR7.js +0 -1
  381. package/dist/chunk-6IDEDOXW.js +0 -2
  382. package/dist/chunk-72CBJYAG.js +0 -16
  383. package/dist/chunk-7E4MJCVE.js +0 -10
  384. package/dist/chunk-7HZU7CYS.js +0 -1
  385. package/dist/chunk-7Q4EKY3E.js +0 -3
  386. package/dist/chunk-7YXHILW4.js +0 -383
  387. package/dist/chunk-7Z6IX7MU.js +0 -1
  388. package/dist/chunk-A4XREDFZ.js +0 -1
  389. package/dist/chunk-AHNLGCHF.js +0 -5
  390. package/dist/chunk-ARRRFY6S.js +0 -4
  391. package/dist/chunk-BAP2CHI2.js +0 -1
  392. package/dist/chunk-BQWK222Q.js +0 -1
  393. package/dist/chunk-C3PXIZY3.js +0 -8
  394. package/dist/chunk-C6HGU77I.js +0 -1
  395. package/dist/chunk-CBFAU5AF.js +0 -5
  396. package/dist/chunk-COP2Q2YT.js +0 -1
  397. package/dist/chunk-CSWDRG3E.js +0 -1
  398. package/dist/chunk-CVBWEUWX.js +0 -1
  399. package/dist/chunk-D3NVUE65.js +0 -1
  400. package/dist/chunk-DCKRQZLE.js +0 -20
  401. package/dist/chunk-DYH3ZXJS.js +0 -15
  402. package/dist/chunk-EBX6DYDX.js +0 -2
  403. package/dist/chunk-EDRCFY3K.js +0 -16
  404. package/dist/chunk-EEAY7HFW.js +0 -317
  405. package/dist/chunk-EJMLNBZA.js +0 -275
  406. package/dist/chunk-EO3S2TFI.js +0 -2
  407. package/dist/chunk-EOIGDOUD.js +0 -7
  408. package/dist/chunk-EYKXHMEJ.js +0 -6
  409. package/dist/chunk-FHV2H3Z2.js +0 -12
  410. package/dist/chunk-FOAV642V.js +0 -1
  411. package/dist/chunk-FVTP7EO4.js +0 -46
  412. package/dist/chunk-FYIC4JHB.js +0 -26
  413. package/dist/chunk-GF36WNMH.js +0 -5
  414. package/dist/chunk-GJ3QUZO6.js +0 -1
  415. package/dist/chunk-GJZVUEMP.js +0 -11
  416. package/dist/chunk-GP6O7YRO.js +0 -20
  417. package/dist/chunk-GW424AJO.js +0 -7
  418. package/dist/chunk-GXSF6NCR.js +0 -1
  419. package/dist/chunk-GYVQIRBD.js +0 -1
  420. package/dist/chunk-H3ZPYOQV.js +0 -1
  421. package/dist/chunk-H7YSZKZ2.js +0 -1
  422. package/dist/chunk-HILYTMVA.js +0 -1
  423. package/dist/chunk-HMWQOQAQ.js +0 -2
  424. package/dist/chunk-HNSRF4SQ.js +0 -1
  425. package/dist/chunk-HTODXNY6.js +0 -3
  426. package/dist/chunk-IUYVJJKE.js +0 -9
  427. package/dist/chunk-JM2CQP64.js +0 -97
  428. package/dist/chunk-K4AF7A25.js +0 -1
  429. package/dist/chunk-KDV4WR5A.js +0 -4
  430. package/dist/chunk-KF7NL5YM.js +0 -8
  431. package/dist/chunk-KMJTO7CU.js +0 -103
  432. package/dist/chunk-KN3MUEWA.js +0 -4
  433. package/dist/chunk-KYB4JX76.js +0 -5
  434. package/dist/chunk-LJAU6YHF.js +0 -10
  435. package/dist/chunk-LMQOFVRC.js +0 -17
  436. package/dist/chunk-LQSD25YS.js +0 -3
  437. package/dist/chunk-M2HQFHNO.js +0 -1
  438. package/dist/chunk-M5WBYWSQ.js +0 -7
  439. package/dist/chunk-N47RQHEI.js +0 -2
  440. package/dist/chunk-NRG2WPSM.js +0 -1
  441. package/dist/chunk-O2CP7DQE.js +0 -1
  442. package/dist/chunk-O6FXUKI2.js +0 -2
  443. package/dist/chunk-OHJUEUSA.js +0 -1
  444. package/dist/chunk-OOKTWSGP.js +0 -4
  445. package/dist/chunk-OONMCK7X.js +0 -1
  446. package/dist/chunk-OWK2RI4O.js +0 -6
  447. package/dist/chunk-P2UEQJJ4.js +0 -5
  448. package/dist/chunk-QBJ74XPX.js +0 -18
  449. package/dist/chunk-QGFJOTOH.js +0 -4
  450. package/dist/chunk-QLHPTMIH.js +0 -1
  451. package/dist/chunk-RIO5HKD5.js +0 -1
  452. package/dist/chunk-S7EKUSO6.js +0 -3
  453. package/dist/chunk-SJ2ROSXG.js +0 -1
  454. package/dist/chunk-SNTRSP5K.js +0 -359
  455. package/dist/chunk-SYCN2GT2.js +0 -3
  456. package/dist/chunk-TBNEN73P.js +0 -1
  457. package/dist/chunk-TVI7TQ4C.js +0 -16
  458. package/dist/chunk-TYMYIUIQ.js +0 -1
  459. package/dist/chunk-UEQT7TA4.js +0 -1
  460. package/dist/chunk-UUM367NR.js +0 -5
  461. package/dist/chunk-V5FZRNXI.js +0 -1
  462. package/dist/chunk-VE35YELD.js +0 -1
  463. package/dist/chunk-WEICJ4GW.js +0 -1
  464. package/dist/chunk-WJJXJNNP.js +0 -3
  465. package/dist/chunk-XAQUXFN5.js +0 -1
  466. package/dist/chunk-XE6EUHSS.js +0 -2
  467. package/dist/chunk-XFEJS652.js +0 -16
  468. package/dist/chunk-XI4QEULN.js +0 -1
  469. package/dist/chunk-XP63T4KZ.js +0 -5
  470. package/dist/chunk-XRCAUZAZ.js +0 -8
  471. package/dist/chunk-XSRZWJIJ.js +0 -1
  472. package/dist/chunk-YFJELEVH.js +0 -1
  473. package/dist/chunk-YNJIDLI3.js +0 -7
  474. package/dist/chunk-YRX4E67D.js +0 -6
  475. package/dist/chunk-Z2NL6XQK.js +0 -6
  476. package/dist/chunk-Z6Z5DPKS.js +0 -1
  477. package/dist/chunk-ZOE6WXW6.js +0 -1
  478. package/dist/cli/commands/app/app-logs/sources.js +0 -1
  479. package/dist/command-json-schema-3RP5P43D.js +0 -1
  480. package/dist/conf-store-XORTWCKZ.js +0 -1
  481. package/dist/custom-oclif-loader-ZRYPPYIP.js +0 -1
  482. package/dist/deprecations-AZDMCRNN.js +0 -1
  483. package/dist/dist-DTBXLVHF.js +0 -1
  484. package/dist/dist-SOYIDACZ.js +0 -1
  485. package/dist/environments-L42SEHB4.js +0 -1
  486. package/dist/error-H6B5BHYC.js +0 -1
  487. package/dist/error-handler-JB752NKM.js +0 -1
  488. package/dist/fs-XHZY6MNM.js +0 -1
  489. package/dist/is-global-2NBDZWLC.js +0 -1
  490. package/dist/json-error-OHV2KQFY.js +0 -1
  491. package/dist/node-package-manager-LN2Y7FQ2.js +0 -1
  492. package/dist/notifications-system-HWJ3F44U.js +0 -1
  493. package/dist/os-MHOCCDIB.js +0 -1
  494. package/dist/out-53ABAVL7.js +0 -1
  495. package/dist/output-GILH4S6M.js +0 -1
  496. package/dist/system-6WYK24ET.js +0 -1
  497. package/dist/ui-RP6SVJUK.js +0 -1
  498. package/dist/upgrade-5G7FBJJV.js +0 -1
  499. package/dist/version-TOBC7X2C.js +0 -1
  500. package/dist/version-UIRCT6RC.js +0 -1
  501. package/dist/workerd-ARH2OCYL.js +0 -18
@@ -0,0 +1 @@
1
+ import{pa as a,qa as b,ra as c}from"./chunk-NCPZVARH.js";import"./chunk-ZDF5N422.js";import"./chunk-2M535QQJ.js";import"./chunk-MPW2YJWU.js";import"./chunk-J3UXIC23.js";import"./chunk-MHWETFNT.js";import"./chunk-DSKAIC7O.js";import"./chunk-T7KHS6RF.js";import"./chunk-V654BMS7.js";import"./chunk-7Y7AZRL3.js";import"./chunk-F3OM2YO6.js";import"./chunk-PVASYKSJ.js";import"./chunk-5HBIIYSK.js";import"./chunk-GB3YC4TI.js";import"./chunk-335BUVBP.js";import"./chunk-YRHFPXC3.js";import"./chunk-BN7ZXAZJ.js";import"./chunk-RJ5VF3QY.js";import"./chunk-7UNQOKZW.js";import"./chunk-FHNJLON5.js";import"./chunk-J7BTC45S.js";import"./chunk-636CTEW7.js";import"./chunk-QVVQUJQL.js";import"./chunk-RIG66DIQ.js";import"./chunk-B4OMIONW.js";import"./chunk-BOAGJ6P5.js";import"./chunk-5B76DT7X.js";import"./chunk-JJZNUFPD.js";import"./chunk-FZCGRIOM.js";import"./chunk-GSGCSBRN.js";import"./chunk-46JYM3GH.js";import"./chunk-ZDQO6CNY.js";import"./chunk-YTUUU33R.js";import"./chunk-JD5P5RAJ.js";import"./chunk-IWTNUJGY.js";import"./chunk-QFYLJVJW.js";import"./chunk-ZGASBRSQ.js";import"./chunk-I5A6BPCP.js";import"./chunk-CX5CC6P5.js";import"./chunk-IGE4Y5SE.js";import"./chunk-JFBCE4HN.js";import"./chunk-VKWPEFWQ.js";export{b as getEnvironmentData,c as getSensitiveEnvironmentData,a as startAnalytics};
@@ -0,0 +1 @@
1
+ import{sa as a,ta as b,ua as c,va as d,wa as e,xa as f,ya as g}from"./chunk-NCPZVARH.js";import"./chunk-ZDF5N422.js";import"./chunk-2M535QQJ.js";import"./chunk-MPW2YJWU.js";import"./chunk-J3UXIC23.js";import"./chunk-MHWETFNT.js";import"./chunk-DSKAIC7O.js";import"./chunk-T7KHS6RF.js";import"./chunk-V654BMS7.js";import"./chunk-7Y7AZRL3.js";import"./chunk-F3OM2YO6.js";import"./chunk-PVASYKSJ.js";import"./chunk-5HBIIYSK.js";import"./chunk-GB3YC4TI.js";import"./chunk-335BUVBP.js";import"./chunk-YRHFPXC3.js";import"./chunk-BN7ZXAZJ.js";import"./chunk-RJ5VF3QY.js";import"./chunk-7UNQOKZW.js";import"./chunk-FHNJLON5.js";import"./chunk-J7BTC45S.js";import"./chunk-636CTEW7.js";import"./chunk-QVVQUJQL.js";import"./chunk-RIG66DIQ.js";import"./chunk-B4OMIONW.js";import"./chunk-BOAGJ6P5.js";import"./chunk-5B76DT7X.js";import"./chunk-JJZNUFPD.js";import"./chunk-FZCGRIOM.js";import"./chunk-GSGCSBRN.js";import"./chunk-46JYM3GH.js";import"./chunk-ZDQO6CNY.js";import"./chunk-YTUUU33R.js";import"./chunk-JD5P5RAJ.js";import"./chunk-IWTNUJGY.js";import"./chunk-QFYLJVJW.js";import"./chunk-ZGASBRSQ.js";import"./chunk-I5A6BPCP.js";import"./chunk-CX5CC6P5.js";import"./chunk-IGE4Y5SE.js";import"./chunk-JFBCE4HN.js";import"./chunk-VKWPEFWQ.js";export{g as compileData,d as recordError,f as recordEvent,e as recordRetry,c as recordTiming,b as reportAnalyticsEvent,a as sendAnalyticsEventFromStdin};
@@ -1,5 +1,12 @@
1
1
  # skeleton
2
2
 
3
+ ## 2026.4.9
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [[`e4622144c83e9d9838b5c9336a4d9a021bbe0727`](https://github.com/Shopify/hydrogen/commit/e4622144c83e9d9838b5c9336a4d9a021bbe0727), [`e4622144c83e9d9838b5c9336a4d9a021bbe0727`](https://github.com/Shopify/hydrogen/commit/e4622144c83e9d9838b5c9336a4d9a021bbe0727), [`e4622144c83e9d9838b5c9336a4d9a021bbe0727`](https://github.com/Shopify/hydrogen/commit/e4622144c83e9d9838b5c9336a4d9a021bbe0727)]:
8
+ - @shopify/hydrogen@2026.4.8
9
+
3
10
  ## 2026.4.8
4
11
 
5
12
  ### Patch Changes
@@ -2,7 +2,7 @@
2
2
  "name": "skeleton",
3
3
  "private": true,
4
4
  "sideEffects": false,
5
- "version": "2026.4.8",
5
+ "version": "2026.4.9",
6
6
  "type": "module",
7
7
  "scripts": {
8
8
  "build": "shopify hydrogen build --codegen",
@@ -14,7 +14,7 @@
14
14
  },
15
15
  "prettier": "@shopify/prettier-config",
16
16
  "dependencies": {
17
- "@shopify/hydrogen": "2026.4.7",
17
+ "@shopify/hydrogen": "2026.4.8",
18
18
  "graphql": "^16.10.0",
19
19
  "graphql-tag": "^2.12.6",
20
20
  "isbot": "^5.1.22",
@@ -4,10 +4,9 @@
4
4
  "build": "shopify hydrogen build --codegen",
5
5
  "dev": "shopify hydrogen dev --codegen"
6
6
  },
7
- "dependencies": {
8
- "isbot": "^5.1.21"
9
- },
10
7
  "devDependencies": {
11
- "vite": "^8.0.1"
8
+ "@shopify/mini-oxygen": "3.1.1",
9
+ "vite": "^5.4.21",
10
+ "vite-tsconfig-paths": "5.1.4"
12
11
  }
13
12
  }
@@ -1,13 +1,13 @@
1
1
  import {defineConfig} from 'vite';
2
+ import {realpathSync} from 'node:fs';
2
3
  import {hydrogen} from '@shopify/hydrogen/vite';
3
4
  import {oxygen} from '@shopify/mini-oxygen/vite';
4
5
  import {vitePlugin as remix} from '@remix-run/dev';
6
+ import tsconfigPaths from 'vite-tsconfig-paths';
5
7
 
6
8
  export default defineConfig({
7
- resolve: {
8
- tsconfigPaths: true,
9
- },
10
9
  plugins: [
10
+ tsconfigPaths({root: realpathSync(new URL('.', import.meta.url))}),
11
11
  hydrogen(),
12
12
  oxygen(),
13
13
  remix({
package/dist/bootstrap.js CHANGED
@@ -1 +1 @@
1
- import{a as r,b as c}from"./chunk-VTOPYXHO.js";import{a as n}from"./chunk-SUTVPAJF.js";import{a as t}from"./chunk-COP2Q2YT.js";import"./chunk-T7KHS6RF.js";import"./chunk-QLHPTMIH.js";import"./chunk-FOAV642V.js";import"./chunk-I3J63RFV.js";import"./chunk-JD5P5RAJ.js";import"./chunk-6IDEDOXW.js";import"./chunk-TR4OWSEX.js";import"./chunk-ZGASBRSQ.js";import"./chunk-I5A6BPCP.js";import"./chunk-CX5CC6P5.js";import"./chunk-IGE4Y5SE.js";import"./chunk-JFBCE4HN.js";import{e as i,g as e}from"./chunk-VKWPEFWQ.js";e();var s=i(c(),1);(0,s.createGlobalProxyAgent)({environmentVariableNamespace:"SHOPIFY_",forceGlobalAgent:!0,socketConnectionTimeout:6e4});process.on("uncaughtException",async o=>{await r(o),process.exit(1)});var m=["SIGINT","SIGTERM","SIGQUIT"];m.forEach(o=>{process.on(o,()=>{process.exit(1)})});var a=Number(process.env.SHOPIFY_CLI_COLUMNS);isNaN(a)||(process.stdout.columns=a);async function p({development:o}){await n({moduleURL:import.meta.url,development:o,lazyCommandLoader:t})}var I=p;export{I as default};
1
+ import{a as r,b as m}from"./chunk-TTBNFGCW.js";import{a as s}from"./chunk-5YUDEPEY.js";import{a as n}from"./chunk-5AWELO3D.js";import"./chunk-T7KHS6RF.js";import"./chunk-46JYM3GH.js";import"./chunk-ZDQO6CNY.js";import"./chunk-YTUUU33R.js";import"./chunk-JD5P5RAJ.js";import"./chunk-IWTNUJGY.js";import"./chunk-QFYLJVJW.js";import"./chunk-ZGASBRSQ.js";import"./chunk-I5A6BPCP.js";import"./chunk-CX5CC6P5.js";import"./chunk-IGE4Y5SE.js";import"./chunk-JFBCE4HN.js";import{e as c,g as t}from"./chunk-VKWPEFWQ.js";t();var a=c(m(),1);(0,a.createGlobalProxyAgent)({environmentVariableNamespace:"SHOPIFY_",forceGlobalAgent:!0,socketConnectionTimeout:6e4});process.on("uncaughtException",async o=>{await r(o),process.exit(1)});var p=process,e=!1,u=["SIGINT","SIGTERM","SIGQUIT"];u.forEach(o=>{process.on(o,()=>{e||(e=p.emit("shopify:signal",o),e||process.exit(1))})});var i=Number(process.env.SHOPIFY_CLI_COLUMNS);isNaN(i)||(process.stdout.columns=i);async function f({development:o}){await n({moduleURL:import.meta.url,development:o,lazyCommandLoader:s})}var S=f;export{S as default};
@@ -0,0 +1 @@
1
+ import{a as b}from"./chunk-NPB753M3.js";import{a as O}from"./chunk-D4LFWIFE.js";import{Da as R,Ea as l,Fa as x,Ka as j,La as v,Ma as F}from"./chunk-XV6XCOTG.js";import{b as A,c as S}from"./chunk-5AWELO3D.js";import{A as P}from"./chunk-V654BMS7.js";import{a as y}from"./chunk-BN7ZXAZJ.js";import{h as k}from"./chunk-J7BTC45S.js";import{wb as w}from"./chunk-RIG66DIQ.js";import{e as C,i as p}from"./chunk-IWTNUJGY.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();o();async function m(i){let{directory:t,configName:n,configPath:s,configuration:a,remoteApp:e}=i;if(!a.client_id)throw new k("The selected configuration is not linked to a remote app.","Run `shopify app config link` first to link this configuration to a Shopify app.");let c=e.developerPlatformClient,d=await R({developerPlatformClient:c,app:e}),g=e.flags,N={directory:t,configName:n,developerPlatformClient:c,apiKey:a.client_id},f=await j(N,d,g,e.apiKey),h=p(s),L=await v({remoteApp:e,developerPlatformClient:c,specifications:d,flags:g,configFileName:h,appDirectory:f.appDirectory??t,localAppOptions:f});return x({path:C(f.appDirectory??t,h),appName:L.name,app:e})}o();var r=y({name:"AppConfigPullResult",schema:l.schema,definitions:l.definitions});o();function J(i,t){if(t==="json"){w(r.encode(i));return}P({headline:`Pulled latest configuration for "${i.app.name}"`,body:`Updated ${p(i.path)} with the remote data.`})}var u=class i extends b{static summary="Refresh an already-linked app configuration without prompts.";static descriptionWithMarkdown="Pulls the latest configuration from the already-linked Shopify app and updates the selected configuration file.\n\nThis command reuses the existing linked app and organization and skips all interactive prompts. Use `--config` to target a specific configuration file, or omit it to use the default one.";static get jsonOutputSchema(){return r}static description=this.descriptionForHelp();static flags={...A,...S,...O};async run(){let{flags:t}=await this.parse(i),{app:n,remoteApp:s}=await F({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config}),a=await m({directory:t.path,configName:t.config,configPath:n.configPath,configuration:n.configuration,remoteApp:s});return J(a,t.json?"json":"text"),{app:n}}};export{u as a};
@@ -1 +1 @@
1
- import{d as l}from"./chunk-FVTP7EO4.js";import{c as t}from"./chunk-YY6TFARF.js";import{f as i,m,n as w,o as d,r as f}from"./chunk-LQSD25YS.js";import{J as n}from"./chunk-7YXHILW4.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();async function y(o,r,P){i()||f({store:r});let e=o??m()??await p(["Enter your",{link:{label:"store password",url:t(r)}}]),s=!1;for(;!await l(e,r,P);)s||(d(),s=!0),e=await p(["Incorrect",{link:{label:"store password",url:t(r)}},{char:"."},"Please try again"]);return w(e),e}async function p(o){return n({message:o,password:!0})}export{y as a};
1
+ import{d as l}from"./chunk-2RFCYZMG.js";import{c as t}from"./chunk-YY6TFARF.js";import{f as i,m,n as w,o as d,r as f}from"./chunk-KT5QQOES.js";import{K as n}from"./chunk-V654BMS7.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();async function y(o,r,P){i()||f({store:r});let e=o??m()??await p(["Enter your",{link:{label:"store password",url:t(r)}}]),s=!1;for(;!await l(e,r,P);)s||(d(),s=!0),e=await p(["Incorrect",{link:{label:"store password",url:t(r)}},{char:"."},"Please try again"]);return w(e),e}async function p(o){return n({message:o,password:!0})}export{y as a};
@@ -1 +1 @@
1
- import{a as s}from"./chunk-Y5VFOLNQ.js";import{g as r,h as n,i as h}from"./chunk-LQSD25YS.js";import{i as m}from"./chunk-4HBKQUKY.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var c=t=>`Development theme #${t} could not be found. Please create a new development theme.`,E="No development theme ID has been set. Please create a development theme first.",p=class extends s{context="Development";constructor(e){super(e),this.themeId=r()}async find(){let e=await this.fetch();if(!e)throw new m(this.themeId?c(this.themeId):E);return e}setTheme(e){n(e)}removeTheme(){h()}};export{p as a};
1
+ import{a as s}from"./chunk-QGWC23HQ.js";import{g as r,h as n,i as h}from"./chunk-KT5QQOES.js";import{h as m}from"./chunk-J7BTC45S.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var c=t=>`Development theme #${t} could not be found. Please create a new development theme.`,E="No development theme ID has been set. Please create a development theme first.",p=class extends s{context="Development";constructor(e){super(e),this.themeId=r()}async find(){let e=await this.fetch();if(!e)throw new m(this.themeId?c(this.themeId):E);return e}setTheme(e){n(e)}removeTheme(){h()}};export{p as a};
@@ -0,0 +1,6 @@
1
+ import{l as O,n as W}from"./chunk-J3UXIC23.js";import{T as v,a as S}from"./chunk-V654BMS7.js";import{f as y}from"./chunk-FHNJLON5.js";import{h as u,k as L}from"./chunk-J7BTC45S.js";import{Bb as d,Sa as w,Ta as i,Va as D,_a as F,la as x,lb as B,qb as c,sb as s,ta as _}from"./chunk-RIG66DIQ.js";import{c as r,h as k}from"./chunk-IWTNUJGY.js";import{a as I}from"./chunk-CX5CC6P5.js";import{e as R,g as f}from"./chunk-VKWPEFWQ.js";f();f();function b(e,n){try{return JSON.parse(e)}catch(a){let t=a instanceof Error?a.message:String(a),o=n?` from ${n}`:"";throw new u(`Failed to parse JSON${o}.
2
+ ${t}`)}}var l=R(I()),N="yarn.lock",j="package-lock.json",$="pnpm-lock.yaml",C="bun.lockb",J="bun.lock",T="pnpm-workspace.yaml",we=[N,$,j,C,J],ye={yarn:[N],npm:[j],pnpm:[$],bun:[C,J],homebrew:[],unknown:[]},E=["yarn","npm","pnpm","bun","homebrew","unknown"],M=class extends u{constructor(){super("Unknown package manager")}},h=class extends u{constructor(n){super(s`The directory ${c.path(n)} doesn't have a package.json.`)}},P=class extends L{constructor(n){super(s`Couldn't find a a package.json traversing directories from ${c.path(n)}`)}};function V(e=process.env){let n=e.npm_config_user_agent;return["yarn","pnpm","bun","npm"].find(a=>n?.includes(a))??"unknown"}function U(e){return i(r(e,C))||i(r(e,J))}function G(e){switch(e){case"yarn":case"npm":case"pnpm":case"bun":return e;case"homebrew":case"unknown":return"npm"}}function K(e,n,...a){switch(e){case"npm":return{command:"npm",args:["exec","--",n,...a]};case"pnpm":return{command:"pnpm",args:["exec",n,...a]};case"yarn":return{command:"yarn",args:["run",n,...a]};case"bun":return{command:"bun",args:["x",n,...a]}}}async function A(e){let n=e;for(d(s`Looking for a lockfile in ${c.path(n)}...`);;){if(i(r(n,N)))return"yarn";if(i(r(n,$))||i(r(n,T)))return"pnpm";if(U(n))return"bun";if(i(r(n,j)))return"npm";let t=k(n);if(t===n)break;n=t}let a=V();return a!=="unknown"?a:"npm"}async function he(e,n,...a){let t=G(await A(e));return K(t,n,...a)}async function xe(e){let n=await D(r(e.directory,"**/package.json"),{ignore:[r(e.directory,"node_modules/**/package.json")],cwd:e.directory,onlyFiles:!0,deep:e.deep}),a=new S;try{await Promise.all(n.map(async t=>{let o=k(t);await z({directory:o,packageManager:e.packageManager,stdout:void 0,stderr:void 0,signal:a.signal,args:[]})}))}catch(t){throw a.abort(),t}}async function z(e){let n={cwd:e.directory,stdin:void 0,stdout:e.stdout,stderr:e.stderr,signal:e.signal},a=["install"];e.args&&(a=a.concat(e.args)),await y("cmd_all_timing_network_ms")(async()=>{await v(e.packageManager,a,n)})}async function ve(e){return(await m(e)).name}async function be(e){return(await m(e)).version}async function H(e){let n=await m(e),a=n.dependencies??{},t=n.devDependencies??{};return{...a,...t}}async function Me(e){let n=r(e,"package.json"),a=await m(n),t=r(e,T);return!!a.workspaces||w(t)}async function Pe(e,n,{cacheExpiryInHours:a=0}={}){let t=async()=>(d(s`Checking if there's a version of ${e} newer than ${n}`),ne(e)),o=`npm-package-${e}`,p;try{p=await O(o,t,a*3600*1e3)}catch{return}if(p&&new l.SemVer(n).compare(p)<0)return p}function Ne(e,n){let a=`npm-package-${e}`,t=W(a)?.value;if(t&&new l.SemVer(n).compare(t)<0)return t}function je(e,n){return(0,l.satisfies)(e,n)}async function m(e){if(!await w(e))throw new h(k(e));return b(await x(e),e)}async function Y(e,n){d(s`Adding the following dependencies if needed:
3
+ ${c.json(e)}
4
+ With options:
5
+ ${c.json(n)}
6
+ `);let a=r(n.directory,"package.json");if(!await w(a))throw new h(n.directory);let t=Object.keys(await H(a)),o=e.filter(p=>!t.includes(p.name));o.length!==0&&await q(o,n)}async function q(e,n){let a=e.map(t=>t.version?`${t.name}@${t.version}`:t.name);switch(n.stdout?.write(`Installing ${a.join(" ")} with ${n.packageManager}`),n.packageManager){case"npm":for(let t of a)await g(n,Q(t,n.type));break;case"yarn":await g(n,X(a,n.type,!!n.addToRootDirectory));break;case"pnpm":await g(n,Z(a,n.type,!!n.addToRootDirectory));break;case"bun":await g(n,ee(a,n.type)),await g(n,["install"]);break;case"homebrew":throw new u("Homebrew can't be used to install project dependencies. Use npm, yarn, pnpm, or bun.");case"unknown":throw new M}}async function g(e,n){return y("cmd_all_timing_network_ms")(async()=>v(e.packageManager,n,{cwd:e.directory,stdout:e.stdout,stderr:e.stderr,signal:e.signal}))}async function $e(e,n){await Y(e.map(a=>({name:a,version:void 0})),n)}function Q(e,n){let t=["install",e,{dev:"--save-dev",peer:"--save-peer",prod:"--save-prod"}[n]];return e.match(/@\d/g)&&t.push("--save-exact"),t}function X(e,n,a=!1){let t={dev:"--dev",peer:"--peer",prod:"--prod"};return["add",...a?["-W"]:[],...e,t[n]]}function Z(e,n,a=!1){let t={dev:"--save-dev",peer:"--save-peer",prod:"--save-prod"};return["add",...a?["-w"]:[],...e,t[n]]}function ee(e,n){let t={dev:"--development",peer:"--optional"}[n];return["add",...e,...t?[t]:[]]}async function Ce(e){let n=await F("package.json",{cwd:e,type:"file"});if(n){let a=b(await x(n),n);return{path:n,content:a}}else throw new P(e)}async function Je(e,n){let a=await A(e),t=await m(r(e,"package.json")),o=a==="yarn"?"resolutions":"overrides";t[o]={...t[o],...n},await ae(e,t)}async function ne(e){return d(s`Getting the latest version of NPM package: ${c.raw(e)}`),y("cmd_all_timing_network_ms")(async()=>{let{default:n}=await import("./latest-version-LDWU5F7A.js");return n(e)})}async function ae(e,n){d(s`JSON-encoding and writing content to package.json at ${c.path(e)}...`);let a=r(e,"package.json");await _(a,JSON.stringify(n,null,2))}function _e(e,n=process.env){if(e&&E.includes(e))return e;let a=V(n);if(a!=="unknown")return a;let t=B();return t!=="unknown"?t:"npm"}export{N as a,j as b,$ as c,C as d,T as e,we as f,ye as g,E as h,M as i,h as j,P as k,V as l,A as m,he as n,xe as o,z as p,ve as q,be as r,H as s,Me as t,Pe as u,Ne as v,je as w,m as x,Y as y,q as z,$e as A,Ce as B,Je as C,ae as D,_e as E};
@@ -0,0 +1,2 @@
1
+ import{b as T}from"./chunk-7AWAOPLA.js";import{ga as D,p as C,ua as E,va as k,xa as o}from"./chunk-NCPZVARH.js";import{A as U,K as B,M as L,N as q,O as R,X as P,z as O}from"./chunk-V654BMS7.js";import{h as c}from"./chunk-J7BTC45S.js";import{Bb as _,S as I}from"./chunk-RIG66DIQ.js";import{j as A}from"./chunk-FZCGRIOM.js";import{g as l}from"./chunk-VKWPEFWQ.js";l();var de=/gid:\/\/shopify\/\w*\/(\d+)/,w="development",Fe="live",ge="unpublished";function be(e){return e.role===w}async function Te(e){let n=await I("creative");return B({message:e,defaultValue:n})}function S(e){return`gid://shopify/OnlineStoreTheme/${e}`}function N(e){let n=de.exec(e);if(n&&n[1]!==void 0)return parseInt(n[1],10);throw new Error(`Invalid GID: ${e}`)}l();l();var F;(function(e){e.Delete="DELETE",e.Upload="UPLOAD"})(F||(F={}));l();function y(e){if(!e)return;e.processing??=!1,e.createdAtRuntime??=!1;let{id:n,name:i,role:a,processing:t,createdAtRuntime:d}=e;return{id:n,name:i,processing:t,createdAtRuntime:d,role:a==="main"?"live":a}}function Ve(e){if(!e)return;let{key:n,checksum:i,attachment:a,value:t}=e,d={size:(t||a||"").length,mtime:Date.now()};return{key:n,checksum:i,attachment:a,value:t,stats:d}}l();var G={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"themeUpdate"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"id"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"input"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"OnlineStoreThemeInput"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"themeUpdate"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"id"}}},{kind:"Argument",name:{kind:"Name",value:"input"},value:{kind:"Variable",name:{kind:"Name",value:"input"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"theme"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"role"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var M={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"themeDelete"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"id"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"themeDelete"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"id"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"deletedThemeId"}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var $={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"themeDuplicate"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"id"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"name"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"themeDuplicate"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"id"}}},{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"Variable",name:{kind:"Name",value:"name"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"newTheme"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"role"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var H={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"themePublish"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"id"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"themePublish"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"id"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"theme"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"role"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var z={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"themeCreate"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"name"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"source"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"URL"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"role"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ThemeRole"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"themeCreate"},arguments:[{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"Variable",name:{kind:"Name",value:"name"}}},{kind:"Argument",name:{kind:"Name",value:"source"},value:{kind:"Variable",name:{kind:"Name",value:"source"}}},{kind:"Argument",name:{kind:"Name",value:"role"},value:{kind:"Variable",name:{kind:"Name",value:"role"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"theme"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"role"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var j={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"getThemeFileBodies"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"id"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"after"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"filenames"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"theme"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"id"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"files"},arguments:[{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"250"}},{kind:"Argument",name:{kind:"Name",value:"after"},value:{kind:"Variable",name:{kind:"Name",value:"after"}}},{kind:"Argument",name:{kind:"Name",value:"filenames"},value:{kind:"Variable",name:{kind:"Name",value:"filenames"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"filename"}},{kind:"Field",name:{kind:"Name",value:"size"}},{kind:"Field",name:{kind:"Name",value:"checksumMd5"}},{kind:"Field",name:{kind:"Name",value:"body"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"__typename"}},{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"OnlineStoreThemeFileBodyText"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"content"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"OnlineStoreThemeFileBodyBase64"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"contentBase64"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"InlineFragment",typeCondition:{kind:"NamedType",name:{kind:"Name",value:"OnlineStoreThemeFileBodyUrl"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"url"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"filename"}},{kind:"Field",name:{kind:"Name",value:"code"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{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:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var Q={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"getThemeFileChecksums"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"id"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}},{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:"theme"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"id"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"files"},arguments:[{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"250"}},{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:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"filename"}},{kind:"Field",name:{kind:"Name",value:"size"}},{kind:"Field",name:{kind:"Name",value:"checksumMd5"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"filename"}},{kind:"Field",name:{kind:"Name",value:"code"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{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:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var K={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"themeFilesUpsert"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"files"}},type:{kind:"NonNullType",type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"OnlineStoreThemeFilesUpsertFileInput"}}}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"themeId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"themeFilesUpsert"},arguments:[{kind:"Argument",name:{kind:"Name",value:"files"},value:{kind:"Variable",name:{kind:"Name",value:"files"}}},{kind:"Argument",name:{kind:"Name",value:"themeId"},value:{kind:"Variable",name:{kind:"Name",value:"themeId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"upsertedThemeFiles"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"filename"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"filename"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var X={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"themeFilesDelete"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"themeId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"files"}},type:{kind:"NonNullType",type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"themeFilesDelete"},arguments:[{kind:"Argument",name:{kind:"Name",value:"themeId"},value:{kind:"Variable",name:{kind:"Name",value:"themeId"}}},{kind:"Argument",name:{kind:"Name",value:"files"},value:{kind:"Variable",name:{kind:"Name",value:"files"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"deletedThemeFiles"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"filename"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"filename"}},{kind:"Field",name:{kind:"Name",value:"code"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var Y={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"metafieldDefinitionsByOwnerType"},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:"250"}},{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:"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:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var W={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"getThemes"},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:"themes"},arguments:[{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"50"}},{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:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"role"}},{kind:"Field",name:{kind:"Name",value:"processing"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{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:"__typename"}}]}}]}}]};l();var Z={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"getTheme"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"id"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"theme"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"id"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"role"}},{kind:"Field",name:{kind:"Name",value:"processing"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var J={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"findDevelopmentThemeByName"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"name"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"themes"},arguments:[{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"2"}},{kind:"Argument",name:{kind:"Name",value:"names"},value:{kind:"ListValue",values:[{kind:"Variable",name:{kind:"Name",value:"name"}}]}},{kind:"Argument",name:{kind:"Name",value:"roles"},value:{kind:"ListValue",values:[{kind:"EnumValue",value:"DEVELOPMENT"}]}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"role"}},{kind:"Field",name:{kind:"Name",value:"processing"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var ee={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"OnlineStorePasswordProtection"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"onlineStore"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"passwordProtection"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};l();var le="CHALLENGE_REQUIRED",me=["\r",`
2
+ `," "],b=class extends c{},g,V=0;async function ie(e){g&&await g;let n=V,i=await ne(e);if(!i.challenged)return i.result;let a=V>n;(g||!a)&&await se(i.challengeUrl);let t=await ne(e);if(!t.challenged)return t.result;throw o("theme-api:trust-challenge:retry-challenged"),new b("Shopify still needs to verify your identity before it can continue.",void 0,[["Complete the verification at",{link:{url:t.challengeUrl}},"then run the command again."]])}async function ne(e){try{return{challenged:!1,result:await e()}}catch(n){let i=await oe(n);if(!i)throw n;return{challenged:!0,challengeUrl:i}}}async function oe(e){let i=D(e).find(a=>a.extensions?.code===le)?.extensions?.redirect_to;if(typeof i=="string"){if(!await re(i)){_(`Ignoring trust challenge with an unexpected URL host: ${i}`);return}return i}}async function re(e){try{let n=new URL(e);return n.protocol==="https:"&&n.hostname===await C()}catch{return!1}}async function se(e){return g??=ue(e).then(()=>{V+=1}).finally(()=>{g=void 0}),g}async function ue(e){if(o("theme-api:trust-challenge:required"),P()||!q()||A()==="json")throw o("theme-api:trust-challenge:non-interactive"),new b("Shopify needs to verify your identity before it can continue.",void 0,[["Open",{link:{url:e}},"in a browser where you're logged in to Shopify with the same account you use in Shopify CLI, complete the verification, then run the command again."]]);let n=await R(e);o(n?"theme-api:trust-challenge:browser-opened":"theme-api:trust-challenge:browser-not-opened"),O({headline:"Verify your identity to continue.",body:n?"A verification page opened in your browser.":"Shopify needs to verify your identity before it can continue.",link:n?void 0:{label:"Open the verification page",url:e},nextSteps:[["Complete the verification in your browser, logged in with the same account you use in Shopify CLI."],["Press",{userInput:"Enter"},"here once you have completed it."]],orderedNextSteps:!0}),await L(process.stdin,void 0,{keys:me}),o("theme-api:trust-challenge:acknowledged"),U({headline:"Continuing."})}var ke="https://cdn.shopify.com/static/online-store/theme-skeleton.zip",p={useNetworkLevelRetry:!0,useAbortSignal:!1,maxRetryTimeMs:90*1e3,recordCommandRetries:!0},ae="the required theme access scope";async function Pn(e,n){let i=S(e);o("theme-api:fetch-theme");try{let{theme:a}=await T({query:Z,session:n,variables:{id:i},responseOptions:{handleErrors:!1},preferredBehaviour:p});if(a)return y({id:N(a.id),processing:a.processing,role:a.role.toLowerCase(),name:a.name})}catch(a){te(a),k(a),_(`Error fetching theme with ID: ${e}`)}}async function Gn(e){let n=[],i=null;for(o("theme-api:fetch-themes");;){let a=await h({query:W,session:e,variables:{after:i},responseOptions:{handleErrors:!1},preferredBehaviour:p});a.themes||s("Failed to fetch themes");let{nodes:t,pageInfo:d}=a.themes;if(t.forEach(m=>{let r=y({id:N(m.id),processing:m.processing,role:m.role.toLowerCase(),name:m.name});r&&n.push(r)}),!d.hasNextPage)return n;i=d.endCursor}}async function Mn(e,n){o("theme-api:find-development-theme-by-name");let{themes:i}=await h({query:J,session:n,variables:{name:e},responseOptions:{handleErrors:!1},preferredBehaviour:p});if(i||s("Failed to fetch themes"),i.nodes.length>1)throw k(new c(`More than one development theme is named "${e}"`));if(i.nodes.length===1){let{id:a,processing:t,role:d,name:m}=i.nodes[0];return y({id:N(a),processing:t,role:d.toLowerCase(),name:m})}}async function $n(e,n){let i=e.src??ke;o("theme-api:create-theme");let{themeCreate:a}=await h({query:z,session:n,variables:{name:e.name??"",source:i,role:(e.role??w).toUpperCase()},responseOptions:{handleErrors:!1},preferredBehaviour:p});a||s("Failed to create theme");let{theme:t,userErrors:d}=a;if(d.length){let m=a.userErrors.map(r=>r.message).join(", ");throw k(new c(m))}return t||s("Failed to create theme"),y({id:N(t.id),name:t.name,role:t.role.toLowerCase()})}async function Hn(e,n,i){let a=[],t=null;for(o("theme-api:fetch-assets");;){let d=await h({query:j,session:i,variables:{id:x(e),filenames:n,after:t},responseOptions:{handleErrors:!1},preferredBehaviour:p});if(!d.theme?.files?.nodes||!d.theme?.files?.pageInfo){let u=d.theme?.files?.userErrors.map(f=>f.filename).join(", ");s(`Error fetching assets: ${u}`)}let{nodes:m,pageInfo:r}=d.theme.files;if(a.push(...await Promise.all(m.map(async u=>{let{attachment:f,value:v}=await Ne(u.body);return{attachment:f,key:u.filename,checksum:u.checksumMd5,value:v}}))),!r.hasNextPage)return a;t=r.endCursor}}async function zn(e,n,i){let t=[];o("theme-api:delete-assets");for(let d=0;d<n.length;d+=50){let m=n.slice(d,d+50),{themeFilesDelete:r}=await h({query:X,session:i,variables:{themeId:S(e),files:m},preferredBehaviour:p});r||s("Failed to delete theme assets");let{deletedThemeFiles:u,userErrors:f}=r;u&&u.forEach(v=>{t.push({key:v.filename,success:!0,operation:F.Delete})}),f.length>0&&f.forEach(v=>{v.filename?(k(`Asset deletion failed for ${v.filename}: ${v.message}`),t.push({key:v.filename,success:!1,operation:F.Delete,errors:{asset:[v.message]}})):s(`Failed to delete theme assets: ${v.message}`)})}return t}async function jn(e,n,i){let a=[];o("theme-api:bulk-upload-assets");for(let t=0;t<n.length;t+=50){let d=n.slice(t,t+50),m=ce(d);E("theme-api:upload-files");let r=await pe(e,m,i);E("theme-api:upload-files"),a.push(...he(r))}return a}function ce(e){return e.map(n=>n.attachment?{filename:n.key,body:{type:"BASE64",value:n.attachment}}:{filename:n.key,body:{type:"TEXT",value:n.value??""}})}async function pe(e,n,i){return h({query:K,session:i,variables:{themeId:x(e),files:n},preferredBehaviour:p})}function he(e){let{themeFilesUpsert:n}=e;n||s("Failed to upload theme files");let{upsertedThemeFiles:i,userErrors:a}=n,t=[];return i?.forEach(d=>{t.push({key:d.filename,success:!0,operation:F.Upload})}),a.forEach(d=>{d.filename||s(`Error uploading theme files: ${d.message}`),k(`Asset upload failed for ${d.filename}: ${d.message}`),t.push({key:d.filename,success:!1,operation:F.Upload,errors:{asset:[d.message]}})}),t}async function Qn(e,n){let i=[],a=null;for(o("theme-api:fetch-checksums");;){let t=await h({query:Q,session:n,variables:{id:x(e),after:a},responseOptions:{handleErrors:!1},preferredBehaviour:p});if(!t?.theme?.files?.nodes||!t?.theme?.files?.pageInfo){let r=t.theme?.files?.userErrors.map(u=>u.filename).join(", ");throw k(new c(`Failed to fetch checksums for: ${r}`))}let{nodes:d,pageInfo:m}=t.theme.files;if(i.push(...d.map(r=>({key:r.filename,checksum:r.checksumMd5}))),!m.hasNextPage)return i;a=m.endCursor}}async function Kn(e,n,i){let a=n.name,t={};a&&(t.name=a),o("theme-api:update-theme");let{themeUpdate:d}=await h({query:G,session:i,variables:{id:S(e),input:t},preferredBehaviour:p});d||s("Failed to update theme");let{theme:m,userErrors:r}=d;if(r.length){let u=d.userErrors.map(f=>f.message).join(", ");throw k(new c(u))}return m||s("Failed to update theme"),y({id:N(m.id),name:m.name,role:m.role.toLowerCase()})}async function Xn(e,n){o("theme-api:publish-theme");let{themePublish:i}=await h({query:H,session:n,variables:{id:S(e)},preferredBehaviour:p});i||s("Failed to update theme");let{theme:a,userErrors:t}=i;if(t.length){let d=i.userErrors.map(m=>m.message).join(", ");throw k(new c(d))}return a||s("Failed to update theme"),y({id:N(a.id),name:a.name,role:a.role.toLowerCase()})}async function Yn(e,n){o("theme-api:delete-theme");let{themeDelete:i}=await h({query:M,session:n,variables:{id:S(e)},preferredBehaviour:p});i||s("Failed to update theme");let{deletedThemeId:a,userErrors:t}=i;if(t.length){let d=i.userErrors.map(m=>m.message).join(", ");throw k(new c(d))}return a||s("Failed to update theme"),!0}async function Wn(e,n,i){let a;o("theme-api:duplicate-theme");let{themeDuplicate:t}=await h({query:$,session:i,variables:{id:S(e),name:n},preferredBehaviour:p,responseOptions:{onResponse:u=>{a=u.headers.get("x-request-id")??void 0}}});if(!t)return k("Failed to duplicate theme"),{theme:void 0,userErrors:[{message:"Failed to duplicate theme"}],requestId:a};let{newTheme:d,userErrors:m}=t;return m.length>0?{theme:void 0,userErrors:m,requestId:a}:d?{theme:y({id:N(d.id),name:d.name,role:d.role.toLowerCase()}),userErrors:[],requestId:a}:{theme:void 0,userErrors:[{message:"Failed to duplicate theme"}],requestId:a}}async function Zn(e,n){o("theme-api:fetch-metafield-definitions");let i=[],a=null;for(;;){let{metafieldDefinitions:t}=await T({query:Y,session:n,variables:{ownerType:e,after:a}});if(i.push(...t.nodes),!t.pageInfo.hasNextPage)break;let d=t.pageInfo.endCursor;(!d||d===a)&&s("Failed to paginate metafield definitions"),a=d}return i.map(t=>({key:t.key,namespace:t.namespace,name:t.name,description:t.description,type:{name:t.type.name,category:t.type.category}}))}async function Jn(e){o("theme-api:check-password-protection");let{onlineStore:n}=await T({query:ee,session:e});n||s("Unable to get details about the storefront's password protection");let{passwordProtection:i}=n;return i.enabled}function s(e){throw k(new c(e))}function ei(e){return e instanceof b}async function h(e){try{return await ie(()=>T(e))}catch(n){throw te(n),n}}function te(e){let n=ve(e);if(!n)return;let i=[["If you authenticated with an Admin API access token, update the app or integration that issued the token to include the required theme access scopes, then reauthorize it or generate a new token."],["For",{command:"theme pull"},{char:","},{command:"theme list"},{char:","},"and",{command:"theme info"},{char:","},"add the",{command:"read_themes"},"scope",{char:"."}],["For",{command:"theme push"},{char:","},{command:"theme dev"},{char:","},{command:"theme publish"},{char:","},{command:"theme delete"},{char:","},{command:"theme rename"},{char:","},"and",{command:"theme duplicate"},{char:","},"add both the",{command:"read_themes"},"and",{command:"write_themes"},"scopes",{char:"."}],["If you authenticated with your Shopify account, make sure your staff or collaborator account can access Online Store themes, then run",{command:"shopify auth logout"},"and try again",{char:"."}],["See",{link:{label:"Shopify access scopes",url:"https://shopify.dev/api/usage/access-scopes"}},{char:"."}]];throw k(new c(`The authenticated account or access token is missing ${n}.`,void 0,i))}function ve(e){let n=D(e).find(a=>a.extensions?.code==="ACCESS_DENIED");if(!n)return;let i=n.extensions?.requiredAccess;return typeof i!="string"?ae:fe(i)}function fe(e){return e.trim().replace(/\.$/,"").replace(/^The user needs\s+/i,"")||ae}function x(e){return`gid://shopify/OnlineStoreTheme/${e}`}async function Ne(e){switch(e.__typename){case"OnlineStoreThemeFileBodyText":return{value:e.content};case"OnlineStoreThemeFileBodyBase64":return{attachment:e.contentBase64};case"OnlineStoreThemeFileBodyUrl":try{let i=await(await fetch(e.url)).arrayBuffer();return{attachment:Buffer.from(i).toString("base64")}}catch{throw k(new c(`Error downloading content from URL: ${e.url}`))}}}export{Ve as a,w as b,Fe as c,ge as d,be as e,Te as f,Pn as g,Gn as h,Mn as i,$n as j,Hn as k,zn as l,jn as m,Qn as n,Kn as o,Xn as p,Yn as q,Wn as r,Zn as s,Jn as t,ei as u};
@@ -1 +1 @@
1
- import{o as n}from"./chunk-5VRB3FBD.js";import{H as s}from"./chunk-7YXHILW4.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();async function c(e){await s([{title:"Installing dependencies",task:async()=>{await n({packageManager:e.packageManager,directory:e.directory,deep:3})}}])}export{c as a};
1
+ import{o as n}from"./chunk-2M535QQJ.js";import{I as s}from"./chunk-V654BMS7.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();async function c(e){await s([{title:"Installing dependencies",task:async()=>{await n({packageManager:e.packageManager,directory:e.directory,deep:3})}}])}export{c as a};
@@ -0,0 +1,47 @@
1
+ import{k as G,t as B}from"./chunk-2NZ7GDDR.js";import{a as j}from"./chunk-Q7BOSHWX.js";import{a as C}from"./chunk-7AWAOPLA.js";import{L as q,N as L,j as I,k as w,va as f,xa as h}from"./chunk-NCPZVARH.js";import{a as x}from"./chunk-MHWETFNT.js";import{C as O,D as P,U as N}from"./chunk-V654BMS7.js";import{h as l,j as U}from"./chunk-J7BTC45S.js";import{Bb as c,qb as _,sb as D}from"./chunk-RIG66DIQ.js";import{i as H,j as v}from"./chunk-FZCGRIOM.js";import{u as F}from"./chunk-GSGCSBRN.js";import{g as p}from"./chunk-VKWPEFWQ.js";p();p();function M(e){let t=new URLSearchParams;for(let[r,o]of Object.entries(e.replaceTemplates??[]))t.append(`replace_templates[${r}]`,o);for(let[r,o]of Object.entries(e.replaceExtensionTemplates??[])){let s=r.split("/")[0];t.append(`replace_extension_templates[${s}][${r}]`,o)}return t.append("_method",e.method),t}function S(){return{"User-Agent":`Shopify CLI; v=${x}`}}function k(e){return delete e.cookie,delete e.authorization,e}p();function E(e){let t={};return e.split(";").forEach(r=>{let o=r.match(/(.*?)=(.*)$/)??[],s=o[1]?.trim(),n=o[2]?.trim()??"";s&&(t[s]=n)}),t}function y(e){return Object.entries(e).map(([t,r])=>`${t}=${r}`).join("; ")}var $=class extends l{};async function Pe(e){return B(e)}async function Ue(e,t,r){let o=Y(t),s=new URLSearchParams;s.append("form_type","storefront_password"),s.append("utf8","\u2713"),s.append("password",e??""),h("theme-service:storefront-session:check-storefront-password");let n={"cache-control":"no-cache","content-type":"application/x-www-form-urlencoded",...r},a=await w(`${o}/password`,{headers:n,body:s.toString(),method:"POST",redirect:"manual"});if(a.status===429)throw f(new l(`Too many incorrect password attempts. Please try again after ${a.headers.get("retry-after")} seconds.`));return V(a,o)}async function z(e,t,r,o,s={}){let n={},a=await W(e,r,s),i=Y(t);if(n._shopify_essential=a,h(`theme-service:storefront-session:is-password-protected:${!!o}`),!o)return n;let u=await ae(a,e,i,o,s);return{...n,...u}}var se=1;async function W(e,t,r,o=1){let s=new URLSearchParams({preview_theme_id:t,_fd:"0",pb:"0"}),n=`${e}?${s}`;h("theme-service:storefront-session:get-session-essential-cookie");let a={...r,...S()},i=await w(n,{method:"HEAD",redirect:"manual",headers:a}),u=i.headers.raw()["set-cookie"]??[],d=R(u,"_shopify_essential");if(!d){if(c(`Failed to obtain _shopify_essential cookie.
2
+
3
+ -Request ID: ${i.headers.get("x-request-id")??"unknown"}
4
+
5
+ -Body: ${await i.text()}
6
+
7
+ -Status: ${i.status}
8
+ `),o>3)throw f(new $('Your development session could not be created because the "_shopify_essential" could not be defined. Please, check your internet connection.'));return c("Retrying to obtain the _shopify_essential cookie..."),await N(o),W(e,t,r,o+1)}return X(i,n,d,a)}async function X(e,t,r,o,s=0){let n=e.headers.get("location");if(!n||s>=se)return r;let a=new URL(n,t);if(a.origin!==new URL(t).origin||!a.searchParams.has("preview_theme_id"))return r;let i=await w(a.toString(),{method:"HEAD",redirect:"manual",headers:{...o,Cookie:y({_shopify_essential:r})}}),u=i.headers.raw()["set-cookie"]??[],d=R(u,"_shopify_essential");return d||c(`Preview redirect to ${a.pathname} did not set a new _shopify_essential cookie; keeping the previous one.`),X(i,a.toString(),d??r,o,s+1)}async function ae(e,t,r,o,s){let n=new URLSearchParams({password:o}),a={...s,...S(),Cookie:y({_shopify_essential:e})},i=await w(`${t}/password`,{method:"POST",redirect:"manual",body:n,headers:a});if(!V(i,r))throw f(new l("Your development session could not be created because the store password is invalid. Please, retry with a different password."));let u=i.headers.raw()["set-cookie"]??[],d=R(u,"storefront_digest"),m=R(u,"_shopify_essential"),g={};return d&&(g.storefront_digest=d),m&&(g._shopify_essential=m),g}function V(e,t){let r=e.headers.get("location")??"",o;try{o=new URL(r,t)}catch(n){if(n instanceof TypeError)return!1;throw n}let s=new URL(t).origin;return e.status===302&&o.origin===s}function R(e,t){let r=e.find(s=>E(s)[t]);return r?E(r)[t]:void 0}function Y(e){return`https://${e}`}p();p();function ie(e,t){if(!(t instanceof U)){if(f(t),v()==="json"){H({type:"diagnostic",level:"error",message:`${e}
9
+ ${t.message}`});return}t instanceof l?(t.message=`${e}
10
+ ${t.message}`,P(t)):(O({headline:e,body:t.message}),c(`${e}
11
+ ${t.stack??t.message}`))}}function We(e,t){let r={delete:`Failed to delete file "${e}" from remote theme.`,upload:`Failed to upload file "${e}" to remote theme.`,default:e}[t??"default"]??e;return o=>{ie(r,o)}}function T(e,t){return j({status:e.status??502,statusText:e.statusText??"Bad Gateway",cause:e,data:{url:(t??e.url)?.toString(),requestId:e.headers?.get("x-request-id")??void 0}})}function Xe(e,t="Unexpected error during fetch"){let r=e,o=r.statusCode??502,s=r.statusMessage??"Bad Gateway",n=`${t.replace(/\.$/,"")} with status ${o} (${s}).`;r.data?.requestId&&(n+=`
12
+ Request ID: ${r.data.requestId}`),r.data?.url&&(n+=`
13
+ URL: ${r.data.url}`);let a=r.cause??e;return{headline:n,body:a.stack??r.stack??r.message??s,status:o,statusText:s,cause:a,requestId:r.data?.requestId,url:r.data?.url}}var ce={_fd:"0",pb:"0"},ue=/^(?:\/[a-z]{2,3}(?:-[a-zA-Z0-9]{2,})?)?\/url\/?$/;async function ot(e,t){let r=he(e,t),s={...await pe(e,t),...S()},n,a=Object.keys({...t.replaceTemplates,...t.replaceExtensionTemplates});if(de(t))c(`\u2192 Rendering ${r} (exit page)...`),n=await fe(r,s).catch(m=>{throw T(f(m),r)});else if(a.length>0){c(`\u2192 Rendering ${r} (with ${a})...`);let m=M(t);n=await fetch(r,{method:"POST",body:m,redirect:"manual",headers:s}).catch(g=>{throw T(f(g),r)})}else c(`\u2192 Rendering ${r}...`),n=await fetch(r,{method:t.method,redirect:"manual",headers:s}).catch(m=>{throw T(f(m),r)});let i=n.headers.get("x-request-id");c(`\u2190 ${n.status} (request_id: ${i})`);let d=n.headers.get("Content-Type")?.includes("application/json");return n=new Response(n.body,n),d||n.headers.delete("Content-Type"),n}function de({method:e,path:t}){return e.toUpperCase()==="GET"&&ue.test(t)}async function fe(e,t){let r=await I(e,{method:"GET",redirect:"manual",headers:t},"slow-request"),o=new Headers;for(let[n,a]of Object.entries(r.headers.raw()))for(let i of a)o.append(n,i);let s=[101,103,204,205,304].includes(r.status);return new Response(s?null:await r.arrayBuffer(),{status:r.status,statusText:r.statusText,headers:o})}async function pe(e,t){return Q(e)?me(e,t):le(e,t)}async function le(e,t){let r=await K(e,t),o=e.storefrontToken;return k({...t.headers,...e.crawlerSignatureHeaders,Authorization:`Bearer ${o}`,Cookie:r})}async function me(e,t){let r=await K(e,t),o=e.storefrontToken,s={},n=["ACCEPT","CONTENT-TYPE","CONTENT-LENGTH"];for(let[a,i]of Object.entries(t.headers))n.includes(a.toUpperCase())&&(s[a]=i);return k({...s,...ge(e),...e.crawlerSignatureHeaders,Authorization:`Bearer ${o}`,Cookie:r})}function K(e,t){let r=E(t.headers.cookie??t.headers.Cookie??""),o=e.sessionCookies??{};return y({...r,...o})}function he(e,{path:t,sectionId:r,appBlockId:o,query:s}){let a=`${A(e)}${t}`,i=new URLSearchParams(ce);for(let[u,d]of s)i.append(u,d);return r?i.append("section_id",r):o&&i.append("app_block_id",o),`${a}?${i}`}function A(e){return Q(e)?`https://${F()}/cli/sfr`:`https://${e.storeFqdn}`}function Q(e){return e.token.startsWith("shptka_")}function ge(e){return{"X-Shopify-Shop":e.storeFqdn,"X-Shopify-Access-Token":e.token}}p();var b="Shopify CLI",we=720*60*60,J=["Signature","Signature-Input","Signature-Agent"],Z="unstable",Se=`
14
+ query StorefrontCrawlerSignatures($first: Int!, $expired: Boolean, $cli: Boolean, $domain: String) {
15
+ storefrontCrawlerSignatures(first: $first, expired: $expired, cli: $cli, domain: $domain) {
16
+ edges {
17
+ node {
18
+ id
19
+ name
20
+ domainHost
21
+ signature
22
+ signatureInput
23
+ signatureAgent
24
+ expiresAt
25
+ }
26
+ }
27
+ }
28
+ }
29
+ `,Ee=`
30
+ mutation StorefrontCrawlerSignatureGenerate($timeToLive: Int!, $name: String!, $domainHost: String!, $cli: Boolean) {
31
+ storefrontCrawlerSignatureGenerate(timeToLive: $timeToLive, name: $name, domainHost: $domainHost, cli: $cli) {
32
+ id
33
+ signature
34
+ signatureInput
35
+ signatureAgent
36
+ name
37
+ expiresAt
38
+ domainHost
39
+ userErrors {
40
+ field
41
+ message
42
+ code
43
+ }
44
+ }
45
+ }
46
+ `;async function re(e,t=e.storeFqdn){try{let o=(await C(Se,e,{first:1,expired:!1,cli:!0,domain:t},Z)).storefrontCrawlerSignatures;if(!o)throw f(new l("Could not fetch Shopify CLI crawler signatures."));let s=o.edges[0]?.node;if(s){h("theme-service:crawler-signature:reused");let u=te(s);return c(`Reusing crawler signature "${b}" for ${s.domainHost} (${ee(u)}).`),u}let a=(await C(Ee,e,{timeToLive:we,name:b,domainHost:t,cli:!0},Z)).storefrontCrawlerSignatureGenerate;if(!a)throw f(new l("Could not create a Shopify CLI crawler signature."));if(a.userErrors.length>0){let u=a.userErrors.map(d=>{let m=d.field?.join(".");return m?`${m}: ${d.message}`:d.message}).join(`
47
+ `);throw f(new l("Could not create a Shopify CLI crawler signature.",u))}h("theme-service:crawler-signature:created");let i=te(a);return c(`Created crawler signature "${b}" for ${a.domainHost} expiring at ${a.expiresAt} (${ee(i)}).`),i}catch(r){let o=r instanceof Error?r.message:String(r);c(`Could not obtain crawler signature headers; continuing without them. ${o}`);return}}function ee(e){let t=Object.keys(e),r=J.filter(s=>t.some(n=>n.toLowerCase()===s.toLowerCase())),o=J.filter(s=>!r.includes(s));return`present: ${r.join(", ")||"none"}; missing: ${o.join(", ")||"none"}`}function te(e){if(!e.signature||!e.signatureInput||!e.signatureAgent)throw f(new l("The Shopify CLI crawler signature response did not include all required headers."));return{Signature:e.signature,"Signature-Input":e.signatureInput,"Signature-Agent":e.signatureAgent}}p();var ye=1800*1e3,oe=["layout/theme.liquid","config/settings_schema.json"];async function yt(e,t,r,o,s){let n=await ne(e,t,r,o,s);return n.refresh=async()=>{c("Refreshing theme session...");let a=await ne(e,t,r,o,n.crawlerSignatureHeaders);return h("theme-service:session:refreshed"),Object.assign(n,a),a},setInterval(()=>{n.refresh&&n.refresh().then(()=>c("Refreshed theme session via auto-refresher...")).catch(()=>c("Session could not be refreshed."))},ye),n}async function ne(e,t,r,o,s){let n=A(t),a=s??await re(t),i=await L(t.storeFqdn,r,[],{forceRefresh:!1,noPrompt:!0}),u=await q([],r,{forceRefresh:!1,noPrompt:!0}),d=await $e(n,e,t,u,o,a);return{...i,sessionCookies:d,storefrontToken:u,crawlerSignatureHeaders:a}}async function $e(e,t,r,o,s,n){try{return await z(e,r.storeFqdn,t,s,{"X-Shopify-Shop":r.storeFqdn,"X-Shopify-Access-Token":r.token,Authorization:`Bearer ${o}`,...n})}catch(a){throw a instanceof $&&await Re(t,r),a}}async function Re(e,t){if(c(`Verifying if theme with id ${e} has required files...`),(await G(Number(e),oe,t)).length!==oe.length)throw f(new l(D`Theme ${_.cyan(e)} is missing required files. Run ${_.cyan(`shopify theme delete -t ${e}`)} to delete it, then try your command again.`.value));c(`Theme with id ${e} has required files.`)}export{S as a,k as b,Pe as c,Ue as d,ie as e,We as f,T as g,Xe as h,ce as i,ot as j,de as k,pe as l,K as m,A as n,re as o,yt as p,ne as q};
@@ -0,0 +1,5 @@
1
+ import{a as F}from"./chunk-NMLLRFZF.js";import{a as D}from"./chunk-NPB753M3.js";import{a as y}from"./chunk-D4LFWIFE.js";import{Ma as S}from"./chunk-XV6XCOTG.js";import{D as f,u}from"./chunk-NCPZVARH.js";import{b as g,c as C}from"./chunk-5AWELO3D.js";import{A as v}from"./chunk-V654BMS7.js";import{a as h}from"./chunk-BN7ZXAZJ.js";import{h as c}from"./chunk-J7BTC45S.js";import{wb as w}from"./chunk-RIG66DIQ.js";import{b as n}from"./chunk-FZCGRIOM.js";import{b as j}from"./chunk-YTUUU33R.js";import{e as I,g as s}from"./chunk-VKWPEFWQ.js";s();s();async function x(t){let e=t.appContextResult.developerPlatformClient,o=t.appContextResult.remoteApp,i=await e.devSessionDelete({shopFqdn:t.store.shopDomain,appId:o.id}),r=i?.devSessionDelete?.userErrors;if(!Array.isArray(r)||r.some(a=>typeof a?.message!="string")){let a=new c("Failed to stop the dev preview: the server returned an invalid response.");throw a.details={data:i},a}if(r.length){let a=r.map(b=>b.message).join(`
2
+ `),l=new c(`Failed to stop the dev preview: ${a}`);throw l.details={userErrors:r},l}return{status:"success",app:{name:o.title,clientId:o.apiKey},storeHostname:t.store.shopDomain}}s();var A=n.object({name:n.string(),clientId:n.string().min(1)}).strict(),p=h({name:"AppDevCleanResult",schema:n.object({status:n.literal("success"),app:A,storeDomain:n.string().nullable().describe("The canonical *.myshopify.com hostname, or null when unknown.")}).strict(),definitions:{AppDevCleanApp:A}});s();function R(t,e){if(e==="json"){let o={status:t.status,app:t.app,storeDomain:f(t.storeHostname)?t.storeHostname:null};w(p.encode(o));return}v({headline:"Dev preview stopped.",body:[`The dev preview has been stopped on ${t.storeHostname} and the app's active version has been restored.`,"You can start it again with",{command:"shopify app dev"}]})}var m=I(j(),1);var d=class t extends D{static summary="Cleans up the dev preview from the selected store.";static descriptionWithMarkdown=`Stop the dev preview that was started with \`shopify app dev\`.
3
+
4
+ It restores the app's active version to the selected development store.
5
+ `;static jsonOutputSchema=p;static description=this.descriptionForHelp();static flags={...g,...y,...C,"client-id":m.Flags.string({hidden:!1,description:"The Client ID of your app. Use with --config to clean up the dev preview for a different app than the one it is linked to.",env:"SHOPIFY_FLAG_CLIENT_ID"}),store:m.Flags.string({hidden:!1,char:"s",description:"Store URL. Must be an existing development store.",env:"SHOPIFY_FLAG_STORE",parse:async e=>u(e)})};async run(){let{flags:e}=await this.parse(t),o=await S({directory:e.path,clientId:e["client-id"],forceRelink:e.reset,userProvidedConfigName:e.config}),i=await F({appContextResult:o,storeFqdn:e.store,forceReselectStore:e.reset}),r=await x({appContextResult:o,store:i});return R(r,e.json?"json":"text"),{app:o.app}}};export{d as a};
@@ -0,0 +1,3 @@
1
+ import{b as D}from"./chunk-6JZC6UKY.js";import{a as ee}from"./chunk-QYFU363G.js";import{k as K,l as Q,m as X,o as Z}from"./chunk-FVRI7ZKE.js";import{a as re}from"./chunk-P5W5RVE6.js";import{a as q,c as z}from"./chunk-AQ34X5B3.js";import{a as W}from"./chunk-2M4BKFYF.js";import{a as V,b as Y}from"./chunk-YY6TFARF.js";import{a as G}from"./chunk-63UKZLPC.js";import{d as R,e as $,g as M,h as J}from"./chunk-QFWWCZOI.js";import{b as F,c as N,d as A,f as U,j as I,n as H,p as B}from"./chunk-2NZ7GDDR.js";import{r as g}from"./chunk-KT5QQOES.js";import{da as me}from"./chunk-DTRENW4Q.js";import{N as E,ua as P,va as _}from"./chunk-NCPZVARH.js";import{A as k,B as O,F as L}from"./chunk-V654BMS7.js";import{h as v}from"./chunk-J7BTC45S.js";import{wb as y}from"./chunk-RIG66DIQ.js";import{b as t,i as j}from"./chunk-FZCGRIOM.js";import{e as x,g as C,p as f}from"./chunk-IWTNUJGY.js";import{e as ie,g as d}from"./chunk-VKWPEFWQ.js";d();import{resolve as ae}from"node:path";var he=t.object({id:t.number(),name:t.string(),role:t.string(),shop:t.string(),editor_url:t.string(),preview_url:t.string()}),T=t.object({environment:t.string().optional(),directory:t.string().optional(),sourcePaths:t.record(t.string()).optional(),changed:t.boolean().optional(),theme:he,published:t.boolean(),hasErrors:t.boolean(),errors:t.record(t.array(t.string()))}),te=t.object({status:t.enum(["success","partial"]),changed:t.boolean(),theme:R,issues:t.array(t.object({filePath:t.string().refine(C,"Expected an absolute filesystem path."),message:t.string()}).strict())}).strict(),oe=t.object({status:t.literal("skipped"),reason:t.literal("unsafe-directory")}).strict();function w(e){let{theme:o,hasErrors:r,errors:s}=e;return{status:r?"partial":"success",changed:e.changed??!0,theme:{...J(o),storeDomain:M(o.shop),editorUrl:o.editor_url||null,previewUrl:o.preview_url||null},issues:Object.entries(s).flatMap(([m,i])=>i.map(n=>({filePath:ae(e.directory??f(),e.sourcePaths?.[m]??m),message:n})))}}var S=$({name:"ThemePushJsonResult",schema:t.union([te,oe]),definitions:{ThemePushTheme:R},project:e=>oe.safeParse(e).success||te.safeParse(e).success?e:w(T.parse(e))});d();var b=ie(me(),1);function se(e,o){if(o==="json"){y(S.encode(w(e)));return}let{environment:r,theme:s,hasErrors:m,published:i}=e,n=r?[{subdued:`Environment: ${r}
2
+
3
+ `}]:[],a=m?O:k;if(i){a({body:[...n,m?`Your theme was published with errors and is now live at https://${s.shop}`:`Your theme is now live at https://${s.shop}`]});return}a({body:[...n,"The theme",...q(s),m?"was pushed with errors":"was pushed successfully."],nextSteps:[[{link:{label:"View your theme",url:s.preview_url}}],[{link:{label:"Customize your theme at the theme editor",url:s.editor_url}}]]})}async function ne(e,o=!1){if(!e.strict)return;let r=e.environment?.[0],s=o?"json":"silent",m=e.json?s:"text",{offenses:i}=await D(e.path??f(),m);if(e.json&&!o)for(let n of i)j({type:"diagnostic",level:{[b.Severity.ERROR]:"error",[b.Severity.WARNING]:"warning",[b.Severity.INFO]:"info"}[n.severity],code:n.check,message:`${r?`[${r}] `:""}${n.uri}: ${n.message}`});if(i.some(n=>n.severity===b.Severity.ERROR))throw _(new v(`${r?`[${r}] `:""}Theme check failed. Please fix the errors before pushing.`))}function _e(e){let o=e.map(r=>{if("error"in r)return r;let s=r.result??{status:"skipped",reason:"unsafe-directory"};return T.safeParse(s).data?.hasErrors&&(process.exitCode=1),{...r,result:s}});y(S.encode({environments:o}))}d();async function ue(e,o,r,s){let m=e.environment?.[0],i=o??await E(g({store:e.store}),e.password);P("theme-service:push:setup"),re({verbose:e.verbose,noColor:e.noColor});let n=e.force??!1,a=e.path?x(e.path):f();if(!await Z(a)&&!await z(n,void 0,m,r))return;e.listing&&await Q(a,e.listing);let l=await le(i,e,r);if(l)return P("theme-service:push:setup"),ce(l,i,{allowLive:e.allowLive??!1,environment:m,force:n,ignore:e.ignore??[],multiEnvironment:r,nodelete:e.nodelete??!1,only:e.only??[],path:a,publish:e.publish??!1,listing:e.listing},s)}async function ce(e,o,r,s){P("theme-service:push:file-system");let m=await H(e.id,o),i=X(r.path,{filters:r,listing:r.listing});P("theme-service:push:file-system");let n;if(r.listing){let c=r.listing;await i.ready(),n=Object.fromEntries(await Promise.all([...i.files.keys()].map(async p=>[p,await K(r.path,c,p)??p])))}let a=ee(e,o,m,i,r,s);await a.renderThemeSyncProgress();let{uploadResults:l}=a;r.publish&&await B(e.id,o);let h={};for(let[c,p]of l)p.success||(h[c]=p.errors?.asset?.length?p.errors.asset:["File upload failed"]);let u=T.parse({environment:r.environment,directory:r.path,...n&&{sourcePaths:n},changed:e.createdAtRuntime===!0||r.publish===!0||a.hasChanges,theme:{id:e.id,name:e.name,role:e.role,shop:o.storeFqdn,editor_url:Y(e,o),preview_url:V(e,o)},published:r.publish??!1,hasErrors:[...l.values()].some(c=>!c.success),errors:h});if(u.hasErrors&&!u.changed){let c=new v(`The theme '${e.name}' could not be pushed.`);throw c.details={themeId:String(e.id),issues:w(u).issues},c}return u}async function le(e,o,r){let{live:s,development:m,unpublished:i,theme:n,environment:a,developmentContext:l}=o;if(m)return new W(e).findOrCreate(l,F);if(i){let h=n??await U("Name of the new theme"),u=await I({name:h,role:A},e);return u?{...u,createdAtRuntime:!0}:void 0}else{let h=await G(e,{create:!0,header:"Select a theme to push to:",filter:{live:s,theme:n}});return await pe(h.role,o.allowLive,e.storeFqdn,a,r)?h:void 0}}async function pe(e,o,r,s,m){if(e===N){if(o)return!0;if(m)throw new v(`Can't push theme files to the live theme on ${r}. Use the --allow-live flag.`);let i={message:`Push theme files to the ${e} theme on ${r}?`,confirmationMessage:"Yes, confirm changes",cancellationMessage:"Cancel"};return L(i)}return!0}async function Qe(e,o,r,s){let m=o??await E(g({store:e.store}),e.password);await ne(e,!0);let i=await ue(e,m,r,s);i&&se(i,e.json?"json":"text")}export{T as a,w as b,S as c,se as d,ne as e,_e as f,ue as g,Qe as h};
@@ -1,4 +1,4 @@
1
- import{b as m}from"./chunk-DCKRQZLE.js";import{G as f}from"./chunk-7YXHILW4.js";import{Ib as c}from"./chunk-62GA7XR3.js";import{b as N}from"./chunk-I3J63RFV.js";import{e as v,g}from"./chunk-VKWPEFWQ.js";g();var d=v(N(),1),i=class h extends m{static description="View all the available command flags";static hidden=!0;static flags={csv:d.Flags.boolean({description:"Output as CSV",env:"SHOPIFY_FLAG_OUTPUT_CSV",default:!1})};async run(){let{flags:p}=await this.parse(h),s=[];for(let[t,a]of this.config.plugins)for(let o of a.commands){let l=await o.load(),n;a.name.startsWith("@shopify")?n=a.name.substring(9):n=a.name.startsWith("@oclif")?a.name.substring(7):a.name;let e=l.flags;if(e)for(let[u,r]of Object.entries(e))s.push({pluginName:n,command:o.id,flagName:`--${u}`,flagChar:r.char?`-${r.char}`:"",flagEnv:r.env})}if(p.csv){let t=["pluginName","command","flagName","flagChar","flagEnv"],a=`${t.join(",")}
1
+ import{b as m}from"./chunk-OLKLHVHA.js";import{H as f}from"./chunk-V654BMS7.js";import{wb as c}from"./chunk-RIG66DIQ.js";import{b as N}from"./chunk-YTUUU33R.js";import{e as v,g}from"./chunk-VKWPEFWQ.js";g();var d=v(N(),1),i=class h extends m{static description="View all the available command flags";static hidden=!0;static flags={csv:d.Flags.boolean({description:"Output as CSV",env:"SHOPIFY_FLAG_OUTPUT_CSV",default:!1})};async run(){let{flags:p}=await this.parse(h),s=[];for(let[t,a]of this.config.plugins)for(let o of a.commands){let l=await o.load(),n;a.name.startsWith("@shopify")?n=a.name.substring(9):n=a.name.startsWith("@oclif")?a.name.substring(7):a.name;let e=l.flags;if(e)for(let[u,r]of Object.entries(e))s.push({pluginName:n,command:o.id,flagName:`--${u}`,flagChar:r.char?`-${r.char}`:"",flagEnv:r.env})}if(p.csv){let t=["pluginName","command","flagName","flagChar","flagEnv"],a=`${t.join(",")}
2
2
  `,o=s.map(n=>t.map(e=>n[e]).join(",")).join(`
3
3
  `),l=`${a}${o}
4
4
  `;c(l)}else f({rows:s,columns:{pluginName:{header:"plugin",color:"red"},command:{},flagName:{header:"long flag",color:"green"},flagChar:{header:"short flag",color:"green"},flagEnv:{header:"env variable",color:"blueBright"}}})}};export{i as a};
@@ -0,0 +1 @@
1
+ import{a as f,b as h}from"./chunk-AIEVQSI3.js";import{f as d,k as u,r as l}from"./chunk-FNWXMCSD.js";import{a as m}from"./chunk-NPB753M3.js";import{Ma as c}from"./chunk-XV6XCOTG.js";import{c as p}from"./chunk-5AWELO3D.js";import{h as s}from"./chunk-J7BTC45S.js";import{g as e}from"./chunk-VKWPEFWQ.js";e();e();async function g({clientId:a,operationIds:t,getOperation:n=l}){return Promise.all(t.map(async i=>{let o=await n({clientId:a,operationId:i});if(!o)throw new s(`Migration operation not found: ${i}`);return o}))}var r=class a extends m{static summary="Checks the status of app subscription migration operations.";static descriptionWithMarkdown="Checks app subscription migration operation status.\n\nRepeat `--id` for every operation GID returned by a multi-batch submission. With `--watch`, the command displays the current state while polling and outputs the final state after all requested operations reach a terminal status.\n\n`RUNNING` means an operation is still processing. `COMPLETED` means processing finished, but you must inspect the per-shop results to confirm each outcome. `FAILED` means the operation failed, and `CANCELED` means cancellation stopped further processing.\n\nUse `--json` to output every operation and its per-shop results as structured JSON.\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 description=this.descriptionForHelp();static examples=["<%= config.bin %> <%= command.id %> --id <operation-id>","<%= config.bin %> <%= command.id %> --path ../my-app --config staging --id <operation-id-1> --id <operation-id-2> --watch","<%= config.bin %> <%= command.id %> --client-id <client-id> --id <operation-id> --json"];static flags={...d,...p};static get jsonOutputSchema(){return u}async run(){let{flags:t}=await this.parse(a),{app:n,remoteApp:i}=await c({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config}),o=t.watch?await h({clientId:i.apiKey,operationIds:t.id}):await g({clientId:i.apiKey,operationIds:t.id});return f(o,t.json),{app:n}}};export{r as a};
@@ -0,0 +1 @@
1
+ import{b as t,d as l}from"./chunk-ZDQO6CNY.js";import{a as c}from"./chunk-JD5P5RAJ.js";import{r as m}from"./chunk-IWTNUJGY.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();o();import i from"crypto";function h(e){return i.createHash("sha256").update(e).digest()}function T(e){return i.createHash("sha1").update(e).digest("hex")}function y(e){return i.createHash("md5").update(e).digest("hex")}function N(){return i.randomUUID()}function g(e){return i.createHash("sha1").update(Buffer.from("6ba7b810-9dad-11d1-80b4-00c04fd430c8".replace(/-/g,""),"hex")).update(e).digest().toString("hex").replace(/(.{8})(.{4})(.{4})(.{4})(.{12})/,"$1-$2-$3-$4-$5")}o();var a=t.serviceAccountToken,f=t.appAutomationToken,p=t.partnersToken;function s(e=process.env){return[a,f,p].find(n=>e[n]!==void 0)}function V(e=process.env){return s(e)===a?"service_account_token":"partners_token"}function R(e=process.env){if(d(e))return;let n=s(e);return n===f||n===p?n:void 0}function d(e=process.env){if(e[a]!==void 0){let u=[f,p].filter(b=>e[b]!==void 0);if(u.length>0)return{message:`${a} can't be set together with ${u.join(" or ")}.`,tryMessage:`Unset ${u.join(" and ")}, or unset ${a}.`}}let n=s(e);if(n&&e[n]==="")return{message:`${n} is set but empty.`,tryMessage:"Set it to an automation token, or unset it to log in with your Shopify account."}}function r(){return process.env}function H(){let e=r();if(d(e))return;let n=s(e);return n?e[n]:void 0}function O(){return r()[t.organization]}function x(e){if(e&&!isNaN(Number(e)))return Number(e)}function B(){return x(r()[l.backendPort])}function C(){let e=r()[t.identityToken],n=r()[t.refreshToken];if(!(!e||!n))return{accessToken:e,refreshToken:n,userId:g(e)}}function j(e=r(),n=process.argv){return m(n)||c(e[t.json])}function D(e=r()){return c(e[t.skipNetworkLevelRetry])}function M(e=r()){return x(e[t.maxRequestTimeForNetworkCalls])??30*1e3}export{h as a,T as b,y as c,N as d,g as e,s as f,V as g,R as h,d as i,r as j,H as k,O as l,B as m,C as n,j as o,D as p,M as q};
@@ -1 +1 @@
1
- import{a as n}from"./chunk-RUDHGUIM.js";import{b as i}from"./chunk-DCKRQZLE.js";import{g as e}from"./chunk-VKWPEFWQ.js";e();var t=class extends i{static description="Generate a notifications.json file for the the CLI, appending a new notification to the current file.";static hidden=!0;async run(){await n()}};export{t as a};
1
+ import{a as n}from"./chunk-W7S6SYBM.js";import{b as i}from"./chunk-OLKLHVHA.js";import{g as e}from"./chunk-VKWPEFWQ.js";e();var t=class extends i{static description="Generate a notifications.json file for the the CLI, appending a new notification to the current file.";static hidden=!0;async run(){await n()}};export{t as a};
@@ -1 +1 @@
1
- import{b as n}from"./chunk-DCKRQZLE.js";import{y as t}from"./chunk-7YXHILW4.js";import{k as r}from"./chunk-PT3OZEBI.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var e=class extends n{static description="Run CLI doctor-release tests";static hidden=!0;async run(){r()&&t({headline:"Shopify CLI Doctor Release.",body:["Available doctor-release commands:",""," shopify doctor-release theme -e <environment> Run all theme command tests","","The -e/--environment flag is required to specify the store configuration.","Use --help with any command for more options."]})}};export{e as a};
1
+ import{b as n}from"./chunk-OLKLHVHA.js";import{z as t}from"./chunk-V654BMS7.js";import{k as r}from"./chunk-GSGCSBRN.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var e=class extends n{static description="Run CLI doctor-release tests";static hidden=!0;async run(){r()&&t({headline:"Shopify CLI Doctor Release.",body:["Available doctor-release commands:",""," shopify doctor-release theme -e <environment> Run all theme command tests","","The -e/--environment flag is required to specify the store configuration.","Use --help with any command for more options."]})}};export{e as a};
@@ -0,0 +1,7 @@
1
+ import{a as L,b as w,c as P}from"./chunk-HF4NDEX3.js";import{a as g,b as x}from"./chunk-AQ34X5B3.js";import{a as A}from"./chunk-2M4BKFYF.js";import{a as q,c as J}from"./chunk-63UKZLPC.js";import{e as R}from"./chunk-QFWWCZOI.js";import{e as Y,q as H}from"./chunk-2NZ7GDDR.js";import{i as _,p as $,v as C}from"./chunk-KT5QQOES.js";import{b as O,c as E,f as M}from"./chunk-5AWELO3D.js";import{A as b,B as D,F}from"./chunk-V654BMS7.js";import{g as I,h as S}from"./chunk-J7BTC45S.js";import{Cb as j,U as T,wb as u}from"./chunk-RIG66DIQ.js";import{b as o}from"./chunk-FZCGRIOM.js";import{b as U}from"./chunk-YTUUU33R.js";import{e as z,g as c}from"./chunk-VKWPEFWQ.js";c();c();var N=o.object({status:o.enum(["success","partial"]),themes:o.array(L),errors:o.array(o.object({themeId:o.number(),message:o.string()})).optional()}),p=R({name:"ThemeDeleteResult",schema:o.object({status:o.enum(["success","partial"]),changed:o.boolean(),themes:o.array(w),errors:o.array(o.object({themeId:o.string().regex(/^\d+$/),error:o.object({type:o.literal("abort"),message:o.string()}).strict()}).strict()).optional()}).strict(),definitions:{Theme:w},project(t){let e=N.parse(t);return{status:e.status,changed:e.themes.length>0,themes:e.themes.map(P),...e.errors?{errors:e.errors.map(n=>({themeId:String(n.themeId),error:{type:"abort",message:n.message}}))}:{}}}});c();function k(t,e,n){if(e==="json"){u(p.encode(t));return}let s=n.environment?[{subdued:`Environment: ${n.environment}
2
+
3
+ `}]:[];(t.status==="partial"?D:b)({body:T(t.themes,m=>[...s,`The following themes were deleted from ${n.store}:`,x(m)],m=>[...s,"The theme",...g(m),`was deleted from ${n.store}.`]),...t.errors?{nextSteps:t.errors.map(m=>[`Theme #${m.themeId}: ${m.message}`])}:{}})}c();async function G(t,e,n){let s=e.themes;e.development&&(s=[(await new A(t).find()).id.toString()]);let i=t.storeFqdn,m=await B(t,{...e,themes:s,development:!1});if(!e.force&&!n&&!await V(m,i))return;let f=await Promise.allSettled(m.map(async r=>(await H(r.id,t),{...r,shop:i}))),d=f.flatMap(r=>r.status==="fulfilled"?[r.value]:[]);for(let r of d)if(Y(r))try{_()}catch(l){let a=l instanceof Error?l.message:String(l);j(`Theme #${r.id} was deleted, but its local development theme reference could not be removed: ${a}`)}let h=f.flatMap((r,l)=>{if(r.status==="fulfilled")return[];let a=r.reason;return[{themeId:m[l].id,message:a instanceof Error?a.message:String(a)}]});if(h.length>0&&d.length===0){let r=f.find(a=>a.status==="rejected")?.reason;if(r instanceof I)throw r;let l=new S(h[0].message);throw l.details={errors:h.map(({themeId:a,message:W})=>({themeId:String(a),message:W}))},l}return{status:h.length>0?"partial":"success",themes:d,...h.length>0?{errors:h}:{}}}async function B(t,e){if(e.selectTheme||e.themes.length>0)return J(t,e);let n=t.storeFqdn;return[await q(t,{header:`Select a theme to delete from ${n}`,filter:{development:e.development}})]}async function V(t,e){let s={message:T(t,i=>[`Delete the following themes from ${e}?`],i=>["Delete",...g(i),`from ${e}?`]),confirmationMessage:"Yes, confirm changes",cancellationMessage:"Cancel"};return t.length>1&&(s.infoTable={"":t.map(g)}),F(s)}var v=z(U(),1);var y=class extends C{static get jsonOutputSchema(){return p}static summary="Delete remote themes from the connected store. This command can't be undone.";static descriptionWithMarkdown=`Deletes a theme from your store.
4
+
5
+ You can specify multiple themes by ID. If no theme is specified, then you're prompted to select the theme that you want to delete from the list of themes in your store.
6
+
7
+ You're asked to confirm that you want to delete the specified themes before they are deleted. You can skip this confirmation using the \`--force\` flag.`;static description=this.descriptionForHelp();static flags={...O,...E,...$,development:v.Flags.boolean({char:"d",description:"Delete your development theme. Use --show-all, --development, or --theme in non-interactive environments.",env:"SHOPIFY_FLAG_DEVELOPMENT"}),"show-all":v.Flags.boolean({char:"a",description:"Include other development themes in the theme list. Use --show-all, --development, or --theme in non-interactive environments.",env:"SHOPIFY_FLAG_SHOW_ALL"}),force:M(v.Flags.boolean({char:"f",description:"Skip confirmation.",env:"SHOPIFY_FLAG_FORCE"})),theme:v.Flags.string({char:"t",description:"Theme ID or name of the remote theme. Use --show-all, --development, or --theme in non-interactive environments.",env:"SHOPIFY_FLAG_THEME_ID",multiple:!0})};static multiEnvironmentsFlags=["store","password",["development","theme","show-all"]];static nonTTYFlagRequirements(){return[{flags:["theme","development","show-all"]}]}async command(e,n,s){let{environment:i,development:m,force:f,theme:d}=e,h=d??[],r=await G(n,{selectTheme:e["show-all"],development:m,themes:h,force:f},s);if(!r){e.json&&!s&&u(p.encode({status:"cancelled"}));return}if(r.status==="partial"&&(process.exitCode=1),e.json&&s)return r;k(r,e.json?"json":"text",{store:n.storeFqdn,environment:i})}renderEnvironmentResults(e){u(p.encode({environments:e}))}};export{y as a};
@@ -0,0 +1,2 @@
1
+ import{a as c}from"./chunk-BN7ZXAZJ.js";import{k as m}from"./chunk-J7BTC45S.js";import{wb as u}from"./chunk-RIG66DIQ.js";import{b as e}from"./chunk-FZCGRIOM.js";import{b as H}from"./chunk-YTUUU33R.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
+ `)[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{H as m,I as d,x as c}from"./chunk-7YXHILW4.js";import{Bb as w,Cb as n,Eb as a}from"./chunk-62GA7XR3.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();async function P(){let r,l=new Promise(function(e,i){r=e});await c({processes:[{prefix:"backend",action:async(e,i,s)=>{e.write("first backend message"),await new Promise(t=>setTimeout(t,1e3)),e.write("second backend message"),await new Promise(t=>setTimeout(t,1e3)),e.write("third backend message"),await new Promise(t=>setTimeout(t,1e3)),r()}},{prefix:"frontend",action:async(e,i,s)=>{await l,e.write("first frontend message"),await new Promise(t=>setTimeout(t,1e3)),e.write("second frontend message"),await new Promise(t=>setTimeout(t,1e3)),e.write("third frontend message")}}]}),await m([{title:"Installing dependencies",task:async()=>{await new Promise(e=>setTimeout(e,2e3))}},{title:"Downloading assets",task:async()=>{await new Promise(e=>setTimeout(e,2e3))}}]),await d({title:new w("Importing data"),task:async e=>{for(let i=1;i<=10;i++){await new Promise(t=>setTimeout(t,500));let s=a`Importing data ${n.italic(a`(${n.green(i.toString())} complete)`)}`;e(s)}return"completed"}})}export{P as a};
1
+ import{I as m,J as d,y as c}from"./chunk-V654BMS7.js";import{pb as w,qb as n,sb as a}from"./chunk-RIG66DIQ.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();async function P(){let r,l=new Promise(function(e,i){r=e});await c({processes:[{prefix:"backend",action:async(e,i,s)=>{e.write("first backend message"),await new Promise(t=>setTimeout(t,1e3)),e.write("second backend message"),await new Promise(t=>setTimeout(t,1e3)),e.write("third backend message"),await new Promise(t=>setTimeout(t,1e3)),r()}},{prefix:"frontend",action:async(e,i,s)=>{await l,e.write("first frontend message"),await new Promise(t=>setTimeout(t,1e3)),e.write("second frontend message"),await new Promise(t=>setTimeout(t,1e3)),e.write("third frontend message")}}]}),await m([{title:"Installing dependencies",task:async()=>{await new Promise(e=>setTimeout(e,2e3))}},{title:"Downloading assets",task:async()=>{await new Promise(e=>setTimeout(e,2e3))}}]),await d({title:new w("Importing data"),task:async e=>{for(let i=1;i<=10;i++){await new Promise(t=>setTimeout(t,500));let s=a`Importing data ${n.italic(a`(${n.green(i.toString())} complete)`)}`;e(s)}return"completed"}})}export{P as a};
@@ -0,0 +1,3 @@
1
+ import{a as R,b as T,c as m,d as F,g as v}from"./chunk-2TPLPZA2.js";import{p as S,v as w}from"./chunk-KT5QQOES.js";import{ua as h}from"./chunk-NCPZVARH.js";import{b as l,c as f}from"./chunk-5AWELO3D.js";import{a as c}from"./chunk-BN7ZXAZJ.js";import{S as d,wb as n}from"./chunk-RIG66DIQ.js";import{b as P}from"./chunk-YTUUU33R.js";import{e as O,g as r}from"./chunk-VKWPEFWQ.js";r();r();var j=c({name:"ThemeShareResult",schema:m.schema,definitions:m.definitions}),o={...j,encode:m.encode};r();function g(s,e){e==="json"?n(o.encode(T(s))):F(s,"text")}function x(s){let e=s.map(t=>"error"in t?t:(R.safeParse(t.result).data?.hasErrors&&(process.exitCode=1),{...t,result:t.result??{status:"skipped",reason:"unsafe-directory"}}));n(o.encode({environments:e}))}var u=O(P(),1);var p=class extends w{static get jsonOutputSchema(){return o}static summary="Creates a shareable, unpublished, and new theme on your theme library with a randomized name.";static descriptionWithMarkdown=`Uploads your theme as a new, unpublished theme in your theme library. The theme is given a randomized name.
2
+
3
+ This command returns a [preview link](https://help.shopify.com/manual/online-store/themes/adding-themes#share-a-theme-preview-with-others) that you can share with others.`;static description=this.descriptionForHelp();static flags={...l,...f,...S,force:u.Flags.boolean({hidden:!0,char:"f",description:"Proceed without confirmation, if current directory does not seem to be theme directory.",env:"SHOPIFY_FLAG_FORCE"}),listing:u.Flags.string({description:"The listing preset to use for multi-preset themes. Applies preset files from listings/[preset-name] directory.",env:"SHOPIFY_FLAG_LISTING"})};static multiEnvironmentsFlags=["store","password","path"];async command(e,t,a,C,y){let b={environment:e.environment,force:e.force,noColor:e["no-color"],password:e.password,path:e.path,store:e.store,theme:d("creative"),unpublished:!0,listing:e.listing};h("theme-command:share");let i=await v(b,t,a,y);return i?.hasErrors&&(process.exitCode=1),e.json&&a||(i?g(i,e.json?"json":"text"):e.json&&n(o.encode({status:"cancelled"}))),h("theme-command:share"),i??(e.json&&a?{status:"skipped",reason:"unsafe-directory"}:void 0)}renderEnvironmentResults(e){x(e)}};export{p as a};
@@ -0,0 +1 @@
1
+ import{b as s}from"./chunk-YTUUU33R.js";import{a as o}from"./chunk-JD5P5RAJ.js";import{e as i,g as n}from"./chunk-VKWPEFWQ.js";n();var t=i(s()),a={"no-input":t.Flags.boolean({description:"Disable interactive prompts and browser authentication.",env:"SHOPIFY_FLAG_NO_INPUT"})};function u(r=process.argv,e=process.env){return r.includes("--no-input")||o(e.SHOPIFY_FLAG_NO_INPUT)}export{a,u as b};
@@ -0,0 +1,18 @@
1
+ import{d as le,h as pe,i as de,j as ce}from"./chunk-DM7BTMFP.js";import{a as ie,c as se,d as ae,e as re}from"./chunk-BB7GAZP6.js";import{a as M}from"./chunk-ACA2BGAD.js";import{b as D}from"./chunk-YFRI75U4.js";import{a as oe}from"./chunk-NPB753M3.js";import{a as q}from"./chunk-D4LFWIFE.js";import{Ma as ne,N as X,Q as ee,fa as te,g as Z}from"./chunk-XV6XCOTG.js";import{a as Q}from"./chunk-ZHHTQRWU.js";import{b as W,c as J}from"./chunk-5AWELO3D.js";import{A as T,F as Y,I as z,N as K,y as N,z as G}from"./chunk-V654BMS7.js";import{a as U}from"./chunk-BN7ZXAZJ.js";import{d as $}from"./chunk-FHNJLON5.js";import{h as y,j as E}from"./chunk-J7BTC45S.js";import{Ba as V,Db as k,L as B,rb as C,va as S,wb as H,yb as R}from"./chunk-RIG66DIQ.js";import{b as d}from"./chunk-FZCGRIOM.js";import{b as Ie}from"./chunk-YTUUU33R.js";import{c as _,h as j}from"./chunk-IWTNUJGY.js";import{e as Ee,g as m}from"./chunk-VKWPEFWQ.js";m();m();m();async function ue(e){let t,o;e.bundlePath&&(t=await re(e.developerPlatformClient,{id:e.apiKey,apiKey:e.apiKey,organizationId:e.organizationId}),await ae(t,e.bundlePath));let n={appManifest:e.appManifest,appId:e.appId,apiKey:e.apiKey,name:e.name,organizationId:e.organizationId,skipPublish:!e.release,message:e.message,versionTag:e.version,commitReference:e.commitReference};t&&(n.bundleUrl=t),e.appModules.length>0&&(n.appModules=e.appModules);let i=await e.developerPlatformClient.deploy(n);if(!i.appDeploy.appVersion){let a=_e(i.appDeploy.userErrors??[],e.appModuleRegistrationIds,e.appModules,{version:e.version});throw new y({bold:"Version couldn't be created."},null,[],a)}return i.appDeploy.userErrors?.length>0&&(o=i.appDeploy.userErrors.map(a=>a.message).join(", ")||"The app version could not be released."),{validationErrors:i.appDeploy.appVersion.appModuleVersions.filter(a=>a.validationErrors.length>0).map(a=>({uuid:a.registrationUuid,errors:a.validationErrors})),versionGid:i.appDeploy.appVersion.uuid,versionTag:i.appDeploy.appVersion.versionTag,location:i.appDeploy.appVersion.location,message:i.appDeploy.appVersion.message,deployError:o}}var x=`
2
+ Validation errors`,O=`
3
+ `;function _e(e,t,o,n={}){let i=l=>l.details?.some(v=>v.extension_id)??!1,s=(l,v)=>{let w=l.details?.find(F=>typeof F.extension_id<"u")?.extension_id??"";return Object.values(v).includes(w.toString())},a=l=>{let v=l.on?l.on[0]:void 0;return o.some(w=>w.uid===v?.user_identifier)},[c,u]=D(e,l=>a(l)),[h,p]=D(u,l=>i(l)),[g,r]=D(h,l=>s(l,t));return[...Se(p,{version:n.version}),...De(g,t),...Me(r),...Ae(c,o)]}function Se(e,t={}){return e.length>0?e.filter(o=>o.field&&o.field.includes("version_tag")&&o.message==="has already been taken").length>0&&t.version?[{body:["An app version with the name",{userInput:t.version},"already exists. Deploy again with a different version name."]}]:e.length===1?[{body:e[0]?.message??""}]:[{body:{list:{items:e.map(o=>o.message)}}}]:[]}function De(e,t){return e.reduce((o,n)=>{let i=(n.field??["unknown"]).join(".").replace("extension_points","extensions.targeting"),s=i==="base"?n.message:`${i}: ${n.message}`,a=n.details.find(r=>typeof r.extension_title<"u")?.extension_title,c=n.details.find(r=>typeof r.specification_identifier<"u")?.specification_identifier,u=n.details.find(r=>typeof r.extension_id<"u")?.extension_id?.toString(),p=Object.keys(t).find(r=>t[r]===u)??a;c==="webhook_subscription"&&(p="Webhook Subscription");let g=o.find(r=>r.title===p);if(g){let r=g.body,f=n.category==="invalid"?r.find(l=>l.list.title===x):r.find(l=>l.list.title===O);f?f.list.items.includes(s)||f.list.items.push(s):r.push({list:{title:n.category==="invalid"?x:O,items:[s]}})}else o.push({title:p,body:[{list:{title:n.category==="invalid"?x:O,items:[s]}}]});return o.forEach(r=>{r.body.sort((f,l)=>f.list.title===x?1:l.list.title===x?-1:0)}),o},[])}function Ae(e,t){return e.reduce((o,n)=>{let s=(n.on?n.on[0]:void 0)?.user_identifier,a=t.find(r=>r.uid===s),c=s?`Extension with uid: ${s}`:"Unknown Extension",u=a?.handle??c,p=`${(n.field??["unknown"]).join(".")}: ${n.message}`,g=o.find(r=>r.title===u);if(g){let f=g.body.find(l=>l.list.title===x);f&&(f.list.items.includes(p)||f.list.items.push(p))}else o.push({title:u,body:[{list:{title:x,items:[p]}}]});return o},[])}function Me(e){return e.reduce((t,o)=>{let n=o.details.find(s=>typeof s.extension_title<"u")?.extension_title,i=t.find(s=>s.title===n);return i?i.errorCount+=1:t.push({title:n,errorCount:1}),t},[]).map(t=>({title:t.title,body:`
4
+ ${t.errorCount} error${t.errorCount>1?"s":""} found in your extensions. Fix these issues and try deploying again.`}))}m();async function me(e){let t=_(e.app.directory,".shopify","deploy-bundle");await V(t,{force:!0}),await S(t),await ie(e.appManifest,t),e.skipBuild||await Z(e.app);let o=e.app.allExtensions.map(i=>({prefix:i.localIdentifier,action:async(s,a,c)=>{await i.buildForBundle({stderr:a,stdout:s,signal:c,app:e.app,environment:"production",skipBuild:e.skipBuild},t)}}));if(await N({processes:o,showTimestamps:!1}),e.app.allExtensions.some(i=>i.hasDeploySteps))return await se(t,e.bundlePath),e.bundlePath}async function Te(e){let{app:t,remoteApp:o,developerPlatformClient:n,noRelease:i,allowUpdates:s,allowDeletes:a,extensions:c}=e,u=[i,s,a].some(Boolean),h=[`App can't be deployed until Partner Dashboard managed extensions are added to your version or removed from your app:
5
+ `,c.map(f=>` - ${f.title}`).join(`
6
+ `)],p=[`
7
+
8
+ Run `,{command:"shopify app import dashboard-extensions"}," to add legacy extensions."];if(u||!K())throw new y(h,p);let g=[`
9
+
10
+ Run `,{command:"shopify app import dashboard-extensions"}," to add legacy extensions now?"];if(await Y({message:[...h,...g],confirmationMessage:"Yes, add legacy extensions and deploy",cancellationMessage:"No, don't add legacy extensions"}))return await de({app:t,remoteApp:o,developerPlatformClient:n,extensions:c}),X(t);throw new E}async function Ce(e){let{app:t,remoteApp:o,developerPlatformClient:n}=e,i=await ce({developerPlatformClient:n,apiKey:o.apiKey,organizationId:o.organizationId,extensionTypes:le,onlyDashboardManaged:!0}),s=pe(e.app,i);return s.length===0?t:Te({...e,extensions:s})}async function fe(e){let{remoteApp:t,developerPlatformClient:o,noRelease:n,allowUpdates:i,allowDeletes:s}=e,a,c;try{a=await Ce({app:e.app,remoteApp:t,developerPlatformClient:o,noRelease:n,allowUpdates:i,allowDeletes:s}),c=await te({...e,app:a,developerPlatformClient:o,allowUpdates:i,allowDeletes:s})}catch(I){if(!(I instanceof E))throw I;return{status:"cancelled",app:e.app}}let{deployIdentifiers:u,didMigrateExtensionsToDevDash:h}=c,p=!n,g=t.apiKey;k(),p?R(`Releasing a new app version as part of ${t.title}`):R(`Creating a new app version as part of ${t.title}`),k();let r,f=_(e.app.directory,".shopify",`deploy-bundle.${o.bundleFormat}`);await S(j(f));let l=await a.manifest(Re(a,u.appModuleUuids)),v=await me({app:a,appManifest:l,bundlePath:f,skipBuild:e.skipBuild}),w;return p?w="Releasing an app version":w="Creating an app version",await z([{title:"Running validation",task:async()=>{await a.preDeployValidation()}},{title:w,task:async()=>{let I=await Promise.all(a.allExtensions.flatMap(xe=>xe.bundleConfig({appModuleUuids:u.appModuleUuids,developerPlatformClient:o,apiKey:g,appConfiguration:a.configuration})));r=await ue({appManifest:l,appId:t.id,apiKey:g,name:a.name,organizationId:t.organizationId,bundlePath:v,appModules:B(I),release:p,developerPlatformClient:o,appModuleRegistrationIds:u.appModuleRegistrationIds,message:e.message,version:e.version,commitReference:e.commitReference})}}]),{status:p&&r.deployError?"partial":"success",app:a,release:p,uploadExtensionsBundleResult:r,didMigrateExtensionsToDevDash:h}}function Re(e,t){return Object.fromEntries(e.allExtensions.filter(o=>o.isUUIDStrategyExtension).map(o=>[o.localIdentifier,t[o.localIdentifier]]))}m();var ge=d.object({name:d.string(),clientId:d.string().min(1).describe("The client ID of the app receiving the deployment.")}).strict(),ye=d.object({gid:d.string().regex(/^gid:\/\/shopify\/Version\/\d+$/).describe("The Shopify app version GID."),name:d.string().min(1).nullable().describe("The version tag, or null when no tag is available."),message:d.string().min(1).nullable().describe("The version message, or null when no message is available."),url:d.string().url().describe("The Developer Dashboard URL for this version.")}).strict(),P=d.object({released:d.boolean().describe("Whether this command released the version to users."),version:ye}).strict(),he={app:ge,deployment:P},A=U({name:"AppDeployResult",schema:d.discriminatedUnion("status",[d.object({status:d.literal("success"),...he}).strict(),d.object({status:d.literal("partial"),...he,deployment:P.extend({released:d.literal(!1)}),errors:d.array(M).min(1)}).strict(),d.object({status:d.literal("cancelled")}).strict()]),definitions:{JsonAbortError:M,App:ge,AppDeployment:P,AppDeploymentVersion:ye}});m();async function be(e,t,o,n){if(n==="json"){let i=ke(e,t);if(H(A.encode(i)),i.status==="cancelled")throw Object.assign(new E,{oclif:{exit:0}});i.status==="partial"&&(process.exitCode=1);return}if(e.status==="cancelled")throw new E;await Oe({...e,project:o})}function ke(e,t){if(e.status==="cancelled")return{status:"cancelled"};let{release:o,uploadExtensionsBundleResult:n}=e,i={app:{name:t.title,clientId:t.apiKey},deployment:{released:o&&!n.deployError,version:{gid:n.versionGid,name:n.versionTag===""?null:n.versionTag??null,message:n.message===""?null:n.message??null,url:n.location}}};return o&&n.deployError?{...i,deployment:{...i.deployment,released:!1},status:"partial",errors:[{type:"abort",message:n.deployError}]}:{...i,status:"success"}}async function Oe({app:e,project:t,release:o,uploadExtensionsBundleResult:n,didMigrateExtensionsToDevDash:i}){let s=[{link:{label:n.versionTag??"version",url:n.location}},n.message?`
11
+ ${n.message}`:""],a=[];if(i){let c=await ee(e.directory),u=Object.values(c).filter(p=>p!==c[e.configuration.client_id]),h=[];u.length>0&&h.push("\u2022 Map extension IDs to other copies of your app by running",{command:C(t.packageManager,"shopify app deploy")},"for: ",{list:{items:u}}),h.push("\u2022 Commit to source control to ensure your extension IDs aren't regenerated on the next deploy."),a=[{title:"Next steps",body:h},{title:"Reference",body:["\u2022 ",{link:{label:"Migrating from the Partner Dashboard",url:"https://shopify.dev/docs/apps/build/dev-dashboard/migrate-from-partners"}}]}]}return o?n.deployError?G({headline:"New version created, but not released.",body:[...s,`
12
+
13
+ ${n.deployError}`],customSections:a}):T({headline:"New version released to users.",body:s,customSections:a}):T({headline:"New version created.",body:s,customSections:a,nextSteps:[["Run",{command:C(t.packageManager,"shopify app release",`--version=${n.versionTag}`)},"to release this version to users."]]})}m();function ve(e){if(typeof e>"u")return;let t=["Invalid version name:",{userInput:e}],o=100;if(e.length>o)throw new y(t,`Version name must be ${o} characters or less.`);let n=[".",".."];if(n.find(s=>e===s))throw new y(t,`Version name may not be any of: ${n.map(s=>`'${s}'`).join(" , ")}`);let i=/^[a-zA-Z0-9.\-_]+$/;if(!e.match(i))throw new y(t,["Version name can only contain alphanumeric characters, periods, hyphens, and underscores"])}m();function we(e){if(typeof e>"u")return;let t=["Invalid message:",{userInput:e}],o=200;if(e.length>o)throw new y(t,`Message name must be ${o} characters or less.`)}var b=Ee(Ie(),1);var L=class e extends oe{static summary="Deploy your Shopify app.";static descriptionWithMarkdown=`[Builds the app](https://shopify.dev/docs/api/shopify-cli/app/app-build), then deploys your app configuration and extensions.
14
+
15
+ This command creates an app version, which is a snapshot of your app configuration and all extensions. This version is then released to users.
16
+
17
+ This command doesn't deploy your [web app](https://shopify.dev/docs/apps/tools/cli/structure#web-components). You need to [deploy your web app](https://shopify.dev/docs/apps/deployment/web) to your own hosting solution.
18
+ `;static get jsonOutputSchema(){return A}static description=this.descriptionForHelp();static flags={...W,...q,...J,"client-id":b.Flags.string({hidden:!1,description:"The Client ID of your app. Use with --config to deploy that configuration to a different app than the one it is linked to.",env:"SHOPIFY_FLAG_CLIENT_ID"}),"allow-updates":b.Flags.boolean({hidden:!1,description:"Allows adding and updating extensions and configuration without requiring user confirmation. Recommended option for CI/CD environments. In non-interactive environments, provide this flag, --allow-deletes, or --no-release.",env:"SHOPIFY_FLAG_ALLOW_UPDATES"}),"allow-deletes":b.Flags.boolean({hidden:!1,description:"Allows removing extensions and configuration without requiring user confirmation. For CI/CD environments, the recommended flag is --allow-updates. In non-interactive environments, provide this flag, --allow-updates, or --no-release.",env:"SHOPIFY_FLAG_ALLOW_DELETES"}),"no-release":b.Flags.boolean({hidden:!1,description:"Creates a version but doesn't release it - it's not made available to merchants. With this flag, a user confirmation is not required. In non-interactive environments, provide this flag, --allow-updates, or --allow-deletes.",env:"SHOPIFY_FLAG_NO_RELEASE",default:!1,exclusive:["allow-updates","allow-deletes"]}),"no-build":b.Flags.boolean({description:"Use with caution: Skips building any elements of the app that require building. You should ensure your app has been prepared in advance, such as by running `shopify app build` or by caching build artifacts.",env:"SHOPIFY_FLAG_NO_BUILD",default:!1}),message:b.Flags.string({hidden:!1,description:"Optional message that will be associated with this version. This is for internal use only and won't be available externally.",env:"SHOPIFY_FLAG_MESSAGE"}),version:b.Flags.string({hidden:!1,description:"Optional version tag that will be associated with this app version. If not provided, an auto-generated identifier will be generated for this app version.",env:"SHOPIFY_FLAG_VERSION"}),"source-control-url":b.Flags.string({hidden:!1,description:"URL associated with the new app version.",env:"SHOPIFY_FLAG_SOURCE_CONTROL_URL"})};static nonTTYFlagRequirements(){return[{flags:["allow-updates","allow-deletes","no-release"]}]}async run(){let{flags:t}=await this.parse(e);await Q.addPublicMetadata(()=>({cmd_deploy_flag_message_used:!!t.message,cmd_deploy_flag_version_used:!!t.version,cmd_deploy_flag_source_url_used:!!t["source-control-url"]})),ve(t.version),we(t.message);let o=t["client-id"];await $(()=>({cmd_app_reset_used:t.reset}));let{app:n,project:i,remoteApp:s,developerPlatformClient:a,organization:c}=await ne({directory:t.path,clientId:o,forceRelink:t.reset,userProvidedConfigName:t.config}),u=t["no-release"]||t["allow-updates"],h=t["no-release"]||t["allow-deletes"],p=await fe({app:n,project:i,remoteApp:s,organization:c,developerPlatformClient:a,reset:t.reset,allowUpdates:u,allowDeletes:h,noRelease:t["no-release"],message:t.message,version:t.version,commitReference:t["source-control-url"],skipBuild:t["no-build"]});return await be(p,s,i,t.json?"json":"text"),{app:p.app}}};export{L as a};
@@ -1 +1 @@
1
- import{b as f,c as r,d as h}from"./chunk-YRX4E67D.js";import{a as l}from"./chunk-5SLKHURV.js";import{a as c}from"./chunk-MTBABHUB.js";import{Ha as m}from"./chunk-EEAY7HFW.js";import{b as d}from"./chunk-SUTVPAJF.js";import{Kb as e}from"./chunk-62GA7XR3.js";import{i as n}from"./chunk-B4OMIONW.js";import{g as p}from"./chunk-VKWPEFWQ.js";p();var s=class g extends l{static summary="Watch and prints out changes to an app.";static hidden=!0;static flags={...d,...c};async run(){let{flags:t}=await this.parse(g),{app:o}=await m({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config}),i=new h(o);return await i.start(),e(`Watching for changes in ${o.name}...`),i.onEvent(async({app:y,extensionEvents:u,startTime:w,path:x})=>{e(`\u{1F195} Event [${f(w)}ms]`),e(` \u{1F4C2} ${x}`),u.forEach(a=>{switch(a.type){case r.Created:e(` \u2705 Extension created - ${n.green(a.extension.handle)}`);break;case r.Deleted:e(` \u274C Extension deleted: ${n.red(a.extension.handle)}`);break;case r.Updated:e(` \u{1F504} Updated: ${n.yellow(a.extension.handle)}`);break}})}),setInterval(()=>{},1<<30),{app:o}}};export{s as a};
1
+ import{b as f,c as r,d as h}from"./chunk-GGJUPL4W.js";import{a as l}from"./chunk-NPB753M3.js";import{a as c}from"./chunk-D4LFWIFE.js";import{Ma as m}from"./chunk-XV6XCOTG.js";import{b as d}from"./chunk-5AWELO3D.js";import{yb as e}from"./chunk-RIG66DIQ.js";import{i as n}from"./chunk-B4OMIONW.js";import{g as p}from"./chunk-VKWPEFWQ.js";p();var s=class g extends l{static summary="Watch and prints out changes to an app.";static hidden=!0;static flags={...d,...c};async run(){let{flags:t}=await this.parse(g),{app:o}=await m({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config}),i=new h(o);return await i.start(),e(`Watching for changes in ${o.name}...`),i.onEvent(async({app:y,extensionEvents:u,startTime:w,path:x})=>{e(`\u{1F195} Event [${f(w)}ms]`),e(` \u{1F4C2} ${x}`),u.forEach(a=>{switch(a.type){case r.Created:e(` \u2705 Extension created - ${n.green(a.extension.handle)}`);break;case r.Deleted:e(` \u274C Extension deleted: ${n.red(a.extension.handle)}`);break;case r.Updated:e(` \u{1F504} Updated: ${n.yellow(a.extension.handle)}`);break}})}),setInterval(()=>{},1<<30),{app:o}}};export{s as a};
@@ -1,4 +1,4 @@
1
- import{b as s,c as i,d as p}from"./chunk-3N6NKC2U.js";import{b as e,c as r}from"./chunk-SUTVPAJF.js";import{b as o}from"./chunk-DCKRQZLE.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();var t=class n extends o{static summary="Enable automatic upgrades for Shopify CLI.";static descriptionWithMarkdown=`Enable automatic upgrades for Shopify CLI.
1
+ import{b as s,c as i,d as p}from"./chunk-IY5EI5V2.js";import{b as o}from"./chunk-OLKLHVHA.js";import{b as e,c as r}from"./chunk-5AWELO3D.js";import{g as a}from"./chunk-VKWPEFWQ.js";a();var t=class n extends o{static summary="Enable automatic upgrades for Shopify CLI.";static descriptionWithMarkdown=`Enable automatic upgrades for Shopify CLI.
2
2
 
3
3
  When auto-upgrade is enabled, Shopify CLI automatically updates to the latest version once per day. Major version upgrades are skipped and must be done manually.
4
4
 
@@ -0,0 +1,4 @@
1
+ import{a as D}from"./chunk-NPB753M3.js";import{a as T}from"./chunk-D4LFWIFE.js";import{$ as j,Ma as y,aa as k,ca as V}from"./chunk-XV6XCOTG.js";import{ca as F}from"./chunk-WFOU5M4H.js";import{b as I,c as S}from"./chunk-5AWELO3D.js";import{A as R,C as b,I as A}from"./chunk-V654BMS7.js";import{a as h}from"./chunk-BN7ZXAZJ.js";import{d as w}from"./chunk-FHNJLON5.js";import{h as v,j as E}from"./chunk-J7BTC45S.js";import{wb as x}from"./chunk-RIG66DIQ.js";import{b as n}from"./chunk-FZCGRIOM.js";import{b as U}from"./chunk-YTUUU33R.js";import{e as M,g as i}from"./chunk-VKWPEFWQ.js";i();i();async function O(e){let{developerPlatformClient:s,app:a,remoteApp:r}=e,{extensionIdentifiersBreakdown:o,versionDetails:t}=await j(s,r,e.version),p=k({localApp:a,versionAppModules:t.appModuleVersions,activeAppVersion:await s.activeAppVersion(r)});if(!await V({configExtensionIdentifiersBreakdown:p,extensionIdentifiersBreakdown:o,appTitle:r.title,release:!0,allowUpdates:e.force||e.allowUpdates,allowDeletes:e.force||e.allowDeletes}))return{status:"cancelled"};let m=[{title:"Releasing version",task:async f=>{f.appRelease=await s.release({app:r,version:{versionId:t.uuid,appVersionId:t.id}})}}],{appRelease:{appRelease:l}}=await A(m);return l.userErrors&&l.userErrors.length>0?{status:"failed",version:t,userErrors:l.userErrors}:{status:"success",version:t}}i();var C=n.object({name:n.string(),clientId:n.string().min(1).describe("The client ID of the app receiving the release.")}).strict(),P=n.object({gid:n.string().regex(/^gid:\/\/shopify\/Version\/\d+$/).describe("The Shopify app version GID."),name:n.string().min(1).nullable().describe("The version tag, or null when no tag is available."),message:n.string().min(1).nullable().describe("The version message, or null when no message is available."),url:n.string().url().describe("The Developer Dashboard URL for this version.")}).strict(),L=n.object({version:P}).strict(),d=h({name:"AppReleaseResult",schema:n.discriminatedUnion("status",[n.object({status:n.literal("success"),app:C,release:L}).strict(),n.object({status:n.literal("cancelled")}).strict()]),definitions:{App:C,AppRelease:L,AppReleaseVersion:P}});i();function _(e,s){throw s==="text"&&e instanceof F?new v({bold:"Version couldn't be released."},["Version",{userInput:e.versionTag},"could not be found."]):e}function q(e,s,a){if(a==="json"){if(e.status==="failed"){let o=new v("Version couldn't be released.");throw o.details={userErrors:e.userErrors},o}x(d.encode(B(e,s)));return}if(e.status==="cancelled")throw new E;let r=[{link:{label:e.version.versionTag??void 0,url:e.version.location}},e.version.message?`
2
+ ${e.version.message}`:""];if(e.status==="failed"){let o=e.userErrors.map(t=>t.message).join(", ");b({headline:"Version couldn't be released.",body:[...r,`${r.length>0?`
3
+
4
+ `:""}${o}`]})}else R({headline:"Version released to users.",body:r})}function B(e,s){return e.status==="cancelled"?{status:"cancelled"}:{status:"success",app:{name:s.title,clientId:s.apiKey},release:{version:{gid:e.version.uuid,name:e.version.versionTag===""?null:e.version.versionTag??null,message:e.version.message===""?null:e.version.message??null,url:e.version.location}}}}var c=M(U(),1);var g=class e extends D{static summary="Release an app version.";static usage="app release --version <version>";static descriptionWithMarkdown="Releases an existing app version. Pass the name of the version that you want to release using the `--version` flag.";static get jsonOutputSchema(){return d}static description=this.descriptionForHelp();static flags={...I,...T,...S,"allow-updates":c.Flags.boolean({hidden:!1,description:"Allows adding and updating extensions and configuration without requiring user confirmation. Recommended option for CI/CD environments. Required in non-interactive environments unless --allow-deletes is provided.",env:"SHOPIFY_FLAG_ALLOW_UPDATES"}),"allow-deletes":c.Flags.boolean({hidden:!1,description:"Allows removing extensions and configuration without requiring user confirmation. For CI/CD environments, the recommended flag is --allow-updates. Required in non-interactive environments unless --allow-updates is provided.",env:"SHOPIFY_FLAG_ALLOW_DELETES"}),version:c.Flags.string({hidden:!1,description:"The name of the app version to release.",env:"SHOPIFY_FLAG_VERSION",required:!0})};static nonTTYFlagRequirements(){return[{flags:["allow-updates","allow-deletes"]}]}async run(){let{flags:s}=await this.parse(e),a=s["client-id"];await w(()=>({cmd_app_reset_used:s.reset}));let r=s["allow-updates"],o=s["allow-deletes"],t=!!(r&&o),{app:p,remoteApp:u,developerPlatformClient:m}=await y({directory:s.path,clientId:a,forceRelink:s.reset,userProvidedConfigName:s.config}),l=await O({app:p,remoteApp:u,developerPlatformClient:m,force:t,allowUpdates:r,allowDeletes:o,version:s.version}).catch(f=>_(f,s.json?"json":"text"));return q(l,u,s.json?"json":"text"),{app:p}}};export{g as a};
@@ -1,4 +1,4 @@
1
- import{a}from"./chunk-XP63T4KZ.js";import{p as n,q as m,v as l}from"./chunk-LQSD25YS.js";import{b as s,c as h}from"./chunk-SUTVPAJF.js";import{oa as o}from"./chunk-HB4YI2PF.js";import{b as v}from"./chunk-I3J63RFV.js";import{e as u,g as r}from"./chunk-VKWPEFWQ.js";r();var e=u(v(),1);var i=class extends l{static summary="Uploads your local theme files to the connected store, overwriting the remote version if specified.";static usage=["theme push","theme push --unpublished --json"];static descriptionWithMarkdown=`Uploads your local theme files to Shopify, overwriting the remote version if specified.
1
+ import{c as r,d as c,e as v,f,g as y}from"./chunk-2TPLPZA2.js";import{p as s,q as p,v as u}from"./chunk-KT5QQOES.js";import{ua as i}from"./chunk-NCPZVARH.js";import{b as a,c as d}from"./chunk-5AWELO3D.js";import{wb as l}from"./chunk-RIG66DIQ.js";import{b}from"./chunk-YTUUU33R.js";import{e as _,g as m}from"./chunk-VKWPEFWQ.js";m();var t=_(b(),1);var h=class extends u{static get jsonOutputSchema(){return r}static summary="Uploads your local theme files to the connected store, overwriting the remote version if specified.";static usage=["theme push","theme push --unpublished --json"];static descriptionWithMarkdown=`Uploads your local theme files to Shopify, overwriting the remote version if specified.
2
2
 
3
3
  If no theme is specified, then you're prompted to select the theme to overwrite from the list of the themes in your store.
4
4
 
@@ -15,14 +15,17 @@ import{a}from"./chunk-XP63T4KZ.js";import{p as n,q as m,v as l}from"./chunk-LQSD
15
15
 
16
16
  \`\`\`json
17
17
  {
18
+ "status": "success",
19
+ "changed": true,
20
+ "issues": [],
18
21
  "theme": {
19
- "id": 108267175958,
22
+ "id": "108267175958",
20
23
  "name": "MyTheme",
21
24
  "role": "unpublished",
22
- "shop": "mystore.myshopify.com",
23
- "editor_url": "https://mystore.myshopify.com/admin/themes/108267175958/editor",
24
- "preview_url": "https://mystore.myshopify.com/?preview_theme_id=108267175958"
25
+ "storeDomain": "mystore.myshopify.com",
26
+ "editorUrl": "https://mystore.myshopify.com/admin/themes/108267175958/editor",
27
+ "previewUrl": "https://mystore.myshopify.com/?preview_theme_id=108267175958"
25
28
  }
26
29
  }
27
30
  \`\`\`
28
- `;static description=this.descriptionForHelp();static flags={...s,...n,...m("upload"),...h,theme:e.Flags.string({char:"t",description:"Theme ID or name of the remote theme. Use --development, --live, --theme, or --unpublished in non-interactive environments. When using --unpublished without --development, use --theme to provide the new theme name.",env:"SHOPIFY_FLAG_THEME_ID"}),development:e.Flags.boolean({char:"d",description:"Push theme files from your remote development theme. Use --development, --live, --theme, or --unpublished in non-interactive environments.",env:"SHOPIFY_FLAG_DEVELOPMENT"}),"development-context":e.Flags.string({char:"c",description:"Unique identifier for a development theme context (e.g., PR number, branch name). Reuses an existing development theme with this context name, or creates one if none exists.",env:"SHOPIFY_FLAG_DEVELOPMENT_CONTEXT",dependsOn:["development"],exclusive:["theme"]}),live:e.Flags.boolean({char:"l",description:"Push theme files from your remote live theme. Use --development, --live, --theme, or --unpublished in non-interactive environments.",env:"SHOPIFY_FLAG_LIVE"}),unpublished:e.Flags.boolean({char:"u",description:"Create a new unpublished theme and push to it. Use --development, --live, --theme, or --unpublished in non-interactive environments. When using --unpublished without --development, use --theme to provide the new theme name.",env:"SHOPIFY_FLAG_UNPUBLISHED"}),nodelete:e.Flags.boolean({char:"n",description:"Prevent deleting remote files that don't exist locally.",env:"SHOPIFY_FLAG_NODELETE"}),"allow-live":e.Flags.boolean({char:"a",description:"Allow push to a live theme. Required in non-interactive environments when targeting the live theme.",env:"SHOPIFY_FLAG_ALLOW_LIVE"}),publish:e.Flags.boolean({char:"p",description:"Publish as the live theme after uploading.",env:"SHOPIFY_FLAG_PUBLISH"}),force:e.Flags.boolean({hidden:!0,char:"f",description:"Proceed without confirmation, if current directory does not seem to be theme directory.",env:"SHOPIFY_FLAG_FORCE"}),strict:e.Flags.boolean({description:"Require theme check to pass without errors before pushing. Warnings are allowed.",env:"SHOPIFY_FLAG_STRICT_PUSH"}),listing:e.Flags.string({description:"The listing preset to use for multi-preset themes. Applies preset files from listings/[preset-name] directory.",env:"SHOPIFY_FLAG_LISTING"}),environment:n.environment};static multiEnvironmentsFlags=["store","password","path",["live","development","theme"]];static nonTTYFlagRequirements(){return[{flags:["theme","development","live","unpublished"]},{flags:["theme"],when:t=>!!(t.unpublished&&!t.development)},{flags:["allow-live"],when:t=>!!t.live}]}async command(t,p,d,g,c){o("theme-command:push"),await a({...t,allowLive:t["allow-live"],noColor:t["no-color"],developmentContext:t["development-context"]},p,d,c),o("theme-command:push")}storeAuthScopes(){return["read_themes","write_themes"]}};export{i as a};
31
+ `;static description=this.descriptionForHelp();static flags={...a,...s,...p("upload"),...d,theme:t.Flags.string({char:"t",description:"Theme ID or name of the remote theme. Use --development, --live, --theme, or --unpublished in non-interactive environments. When using --unpublished without --development, use --theme to provide the new theme name.",env:"SHOPIFY_FLAG_THEME_ID"}),development:t.Flags.boolean({char:"d",description:"Push theme files from your remote development theme. Use --development, --live, --theme, or --unpublished in non-interactive environments.",env:"SHOPIFY_FLAG_DEVELOPMENT"}),"development-context":t.Flags.string({char:"c",description:"Unique identifier for a development theme context (e.g., PR number, branch name). Reuses an existing development theme with this context name, or creates one if none exists.",env:"SHOPIFY_FLAG_DEVELOPMENT_CONTEXT",dependsOn:["development"],exclusive:["theme"]}),live:t.Flags.boolean({char:"l",description:"Push theme files from your remote live theme. Use --development, --live, --theme, or --unpublished in non-interactive environments.",env:"SHOPIFY_FLAG_LIVE"}),unpublished:t.Flags.boolean({char:"u",description:"Create a new unpublished theme and push to it. Use --development, --live, --theme, or --unpublished in non-interactive environments. When using --unpublished without --development, use --theme to provide the new theme name.",env:"SHOPIFY_FLAG_UNPUBLISHED"}),nodelete:t.Flags.boolean({char:"n",description:"Prevent deleting remote files that don't exist locally.",env:"SHOPIFY_FLAG_NODELETE"}),"allow-live":t.Flags.boolean({char:"a",description:"Allow push to a live theme. Required in non-interactive environments when targeting the live theme.",env:"SHOPIFY_FLAG_ALLOW_LIVE"}),publish:t.Flags.boolean({char:"p",description:"Publish as the live theme after uploading.",env:"SHOPIFY_FLAG_PUBLISH"}),force:t.Flags.boolean({hidden:!0,char:"f",description:"Proceed without confirmation, if current directory does not seem to be theme directory.",env:"SHOPIFY_FLAG_FORCE"}),strict:t.Flags.boolean({description:"Require theme check to pass without errors before pushing. Warnings are allowed.",env:"SHOPIFY_FLAG_STRICT_PUSH"}),listing:t.Flags.string({description:"The listing preset to use for multi-preset themes. Applies preset files from listings/[preset-name] directory.",env:"SHOPIFY_FLAG_LISTING"}),environment:s.environment};static multiEnvironmentsFlags=["store","password","path",["live","development","theme"]];static nonTTYFlagRequirements(){return[{flags:["theme","development","live","unpublished"]},{flags:["theme"],when:e=>!!(e.unpublished&&!e.development)},{flags:["allow-live"],when:e=>!!e.live}]}async command(e,w,n,P,g){i("theme-command:push"),await v(e);let o=await y({...e,allowLive:e["allow-live"],noColor:e["no-color"],developmentContext:e["development-context"]},w,n,g);return o?.hasErrors&&(process.exitCode=1),e.json&&n||(o?c(o,e.json?"json":"text"):e.json&&l(r.encode({status:"cancelled"}))),i("theme-command:push"),o??(e.json&&n?{status:"skipped",reason:"unsafe-directory"}:void 0)}renderEnvironmentResults(e){f(e)}storeAuthScopes(){return["read_themes","write_themes"]}};export{h as a};