shopify 4.7.0 → 4.7.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 (277) hide show
  1. package/dist/analytics-5SII3GTA.js +1 -0
  2. package/dist/{analytics-6LI5GLWS.js → analytics-F56E2NGH.js} +1 -1
  3. package/dist/bootstrap.js +1 -1
  4. package/dist/{chunk-LDF4PQ3B.js → chunk-22NROZ5X.js} +1 -1
  5. package/dist/{chunk-XHZ5BWXL.js → chunk-22NWEE5U.js} +1 -1
  6. package/dist/{chunk-2CYVZUYT.js → chunk-26DH5P7S.js} +1 -1
  7. package/dist/{chunk-CIH6LPTG.js → chunk-27UEK3FU.js} +1 -1
  8. package/dist/{chunk-7JIQXGDE.js → chunk-2F2DXTRI.js} +1 -1
  9. package/dist/{chunk-TSLQZTXR.js → chunk-2S3GOPRL.js} +1 -1
  10. package/dist/{chunk-LWJA2DQG.js → chunk-3HCWJRL6.js} +1 -1
  11. package/dist/{chunk-OORWOTAP.js → chunk-3KM2GKXH.js} +1 -1
  12. package/dist/{chunk-Q5DQGV3M.js → chunk-3MN3WLA2.js} +1 -1
  13. package/dist/{chunk-RY2SJVWM.js → chunk-3WV7DQMM.js} +3 -3
  14. package/dist/{chunk-JQ2B3VHR.js → chunk-46BKAF3F.js} +1 -1
  15. package/dist/{chunk-YUVE2I3C.js → chunk-4FCS6PJY.js} +1 -1
  16. package/dist/{chunk-L67BU25M.js → chunk-4FI2YBRF.js} +1 -1
  17. package/dist/{chunk-H5KWM27L.js → chunk-4I7TUB3K.js} +1 -1
  18. package/dist/chunk-4NXLDIW5.js +1 -0
  19. package/dist/{chunk-XAOYKECS.js → chunk-4VJ6YK7U.js} +1 -1
  20. package/dist/{chunk-7DOWT5JZ.js → chunk-4WGJUVXS.js} +1 -1
  21. package/dist/{chunk-6WZYX5RO.js → chunk-53IU36CL.js} +1 -1
  22. package/dist/{chunk-LZ3GZ7NS.js → chunk-5JW4JQWZ.js} +1 -1
  23. package/dist/{chunk-SYADOUBB.js → chunk-5MD7GNEY.js} +1 -1
  24. package/dist/chunk-5QZHJCZM.js +1 -0
  25. package/dist/{chunk-XRT2W5Y2.js → chunk-5WGT45CO.js} +1 -1
  26. package/dist/{chunk-V5SC2RYQ.js → chunk-6AV6GX5W.js} +1 -1
  27. package/dist/{chunk-N6YTJXIS.js → chunk-6ELAWKMY.js} +1 -1
  28. package/dist/{chunk-CTRXLZAJ.js → chunk-6G5TDB45.js} +1 -1
  29. package/dist/{chunk-JQISGC7D.js → chunk-6K3AJTNO.js} +1 -1
  30. package/dist/{chunk-QBIVQXUJ.js → chunk-6QJIGFQJ.js} +1 -1
  31. package/dist/{chunk-EW55WWT7.js → chunk-6R62DGJG.js} +1 -1
  32. package/dist/{chunk-ZO74GSWC.js → chunk-6SM4RY3I.js} +1 -1
  33. package/dist/chunk-76NEIDP5.js +1 -0
  34. package/dist/{chunk-5CADTCJE.js → chunk-77AC3OJQ.js} +1 -1
  35. package/dist/{chunk-MLZLDL6B.js → chunk-7EUIO4ZO.js} +1 -1
  36. package/dist/{chunk-YHPBDS52.js → chunk-7JIYJMRN.js} +1 -1
  37. package/dist/{chunk-VRVP2GQL.js → chunk-7S73765P.js} +1 -1
  38. package/dist/{chunk-AGOEROAI.js → chunk-AFT6ABDE.js} +1 -1
  39. package/dist/{chunk-DMXQLI35.js → chunk-AIA7JVSJ.js} +1 -1
  40. package/dist/{chunk-GKOBFX4A.js → chunk-AWHS336T.js} +1 -1
  41. package/dist/{chunk-R2R6JDNH.js → chunk-BI7LE6CZ.js} +1 -1
  42. package/dist/{chunk-WHLGNDRE.js → chunk-CNMJ6QXM.js} +1 -1
  43. package/dist/{chunk-LJM2DUXN.js → chunk-CRP4PQU2.js} +1 -1
  44. package/dist/{chunk-AH2ZGMDM.js → chunk-CUUCRIGC.js} +1 -1
  45. package/dist/{chunk-PWSI275S.js → chunk-DEMZRLX5.js} +1 -1
  46. package/dist/{chunk-HLNJL4B6.js → chunk-DLSUDLXD.js} +1 -1
  47. package/dist/{chunk-PAAKBWSF.js → chunk-DMFEYI4G.js} +1 -1
  48. package/dist/{chunk-4W3UE2ZI.js → chunk-ELSDVDT7.js} +1 -1
  49. package/dist/{chunk-7AALWJAO.js → chunk-EMETQFFJ.js} +1 -1
  50. package/dist/chunk-ESPT6CGE.js +1 -0
  51. package/dist/{chunk-UPJLZHHR.js → chunk-EULSSTWY.js} +1 -1
  52. package/dist/{chunk-E2W5OYYM.js → chunk-EWS2RNM6.js} +1 -1
  53. package/dist/{chunk-6PDR2IUL.js → chunk-FAXNGDWI.js} +1 -1
  54. package/dist/{chunk-2JDCVEFK.js → chunk-FELV7GWY.js} +1 -1
  55. package/dist/{chunk-VKSR6MJG.js → chunk-FQQXU5IN.js} +1 -1
  56. package/dist/{chunk-ACTDYTAV.js → chunk-GFWXVO72.js} +1 -1
  57. package/dist/{chunk-2SZOPJYI.js → chunk-GJ4A4QKE.js} +1 -1
  58. package/dist/{chunk-KK24VGVE.js → chunk-GW4JHUIA.js} +1 -1
  59. package/dist/{chunk-XLURZ6GL.js → chunk-GXOFJIKQ.js} +1 -1
  60. package/dist/{chunk-X4XP2RQJ.js → chunk-HCQABTQL.js} +1 -1
  61. package/dist/{chunk-TY4W7AYX.js → chunk-HOVIGRE4.js} +1 -1
  62. package/dist/{chunk-Y34LWI3S.js → chunk-HQUWYKSJ.js} +3 -3
  63. package/dist/{chunk-MRCWOOSF.js → chunk-HRHNJFAA.js} +1 -1
  64. package/dist/{chunk-U6HYEGAE.js → chunk-HU4GFVEN.js} +1 -1
  65. package/dist/{chunk-JZMRBJH3.js → chunk-I2LNQKIJ.js} +2 -2
  66. package/dist/{chunk-I3N6NPHF.js → chunk-I6XH7XDX.js} +1 -1
  67. package/dist/{chunk-QKGZWOOY.js → chunk-IA3XNJ56.js} +1 -1
  68. package/dist/{chunk-KIYHEMHD.js → chunk-IENBHP2S.js} +2 -2
  69. package/dist/{chunk-D2K2ZBKH.js → chunk-IF6EYTHG.js} +2 -2
  70. package/dist/{chunk-ZCNIR6YU.js → chunk-IQT6LOA2.js} +1 -1
  71. package/dist/{chunk-JJJTPEMD.js → chunk-IX4IGE5H.js} +1 -1
  72. package/dist/{chunk-WCRZJY3P.js → chunk-J2VRPZFC.js} +1 -1
  73. package/dist/{chunk-P5MNNBSO.js → chunk-JJSV7HNM.js} +1 -1
  74. package/dist/{chunk-E5T4YRGW.js → chunk-JNIPCLAF.js} +1 -1
  75. package/dist/{chunk-HZIX3DIT.js → chunk-JNVCCE6M.js} +1 -1
  76. package/dist/{chunk-LQCR4TGH.js → chunk-JQUEW7CB.js} +1 -1
  77. package/dist/{chunk-GSCWZR22.js → chunk-K3VLFPPI.js} +1 -1
  78. package/dist/{chunk-4JY2P2A5.js → chunk-K63FW7Q7.js} +1 -1
  79. package/dist/{chunk-CZJZCJRX.js → chunk-KBBITJSF.js} +1 -1
  80. package/dist/{chunk-4LRG5YBS.js → chunk-KDBKEVCF.js} +1 -1
  81. package/dist/{chunk-FWPJEL6Q.js → chunk-KNVHXIEB.js} +1 -1
  82. package/dist/{chunk-CMYQXGLO.js → chunk-KRLEEYLL.js} +1 -1
  83. package/dist/{chunk-2U4P6UFZ.js → chunk-KT5MDCII.js} +1 -1
  84. package/dist/{chunk-U2Z5NMXV.js → chunk-LBREJXT6.js} +1 -1
  85. package/dist/{chunk-ZRLEAF7M.js → chunk-LKQ3EJ6Z.js} +1 -1
  86. package/dist/{chunk-HHVHVGRT.js → chunk-LKZQSER3.js} +1 -1
  87. package/dist/{chunk-ZSFAURIH.js → chunk-M5Q74UZM.js} +1 -1
  88. package/dist/{chunk-V2HCVJYF.js → chunk-MK7MOLLI.js} +1 -1
  89. package/dist/{chunk-JUKAWTYY.js → chunk-MTTBBZSR.js} +1 -1
  90. package/dist/{chunk-LRQYUWWB.js → chunk-N4KDWHT2.js} +1 -1
  91. package/dist/{chunk-XCBEYRQI.js → chunk-N7425436.js} +1 -1
  92. package/dist/{chunk-5CR5YJTU.js → chunk-NSZHEXZK.js} +1 -1
  93. package/dist/{chunk-RUFQCXBX.js → chunk-O4G6TE26.js} +1 -1
  94. package/dist/{chunk-XUEMMLXK.js → chunk-O4RHWBBM.js} +1 -1
  95. package/dist/{chunk-AMLWPYNA.js → chunk-O53YIDJL.js} +1 -1
  96. package/dist/{chunk-DHU57LKD.js → chunk-OF6CV5R4.js} +1 -1
  97. package/dist/{chunk-QEB3HUQE.js → chunk-OJSJWGP2.js} +1 -1
  98. package/dist/{chunk-QRT4A2RV.js → chunk-OQWMCJLY.js} +1 -1
  99. package/dist/{chunk-7MHANY34.js → chunk-P5OQUFH6.js} +1 -1
  100. package/dist/{chunk-DQCIORGH.js → chunk-P5WLH64A.js} +1 -1
  101. package/dist/{chunk-OE3F7XXU.js → chunk-PE4TV5IJ.js} +1 -1
  102. package/dist/{chunk-CZPGC2E7.js → chunk-PEHLR7XP.js} +1 -1
  103. package/dist/{chunk-YN6A26QL.js → chunk-PK73ZSND.js} +4 -4
  104. package/dist/{chunk-FULWTZS6.js → chunk-PQG7XSQP.js} +1 -1
  105. package/dist/{chunk-3K6VHXC2.js → chunk-PS2UVFHP.js} +1 -1
  106. package/dist/{chunk-T5JXQ7KO.js → chunk-PU3NATV4.js} +1 -1
  107. package/dist/{chunk-6VRXGEIW.js → chunk-PV6T52KB.js} +1 -1
  108. package/dist/{chunk-JQVXH26X.js → chunk-QASOHYDS.js} +1 -1
  109. package/dist/{chunk-MB7E5GEY.js → chunk-QHLY2IID.js} +1 -1
  110. package/dist/{chunk-SJMTETSU.js → chunk-QT367CYF.js} +1 -1
  111. package/dist/{chunk-2WJAAJVX.js → chunk-R2RULBBV.js} +1 -1
  112. package/dist/{chunk-QXHENYJH.js → chunk-R5EGWWZH.js} +1 -1
  113. package/dist/{chunk-KUNDCAQN.js → chunk-RA3WWB2S.js} +1 -1
  114. package/dist/{chunk-GLWQMLUC.js → chunk-RM3B7AFT.js} +1 -1
  115. package/dist/{chunk-UVQL7RUY.js → chunk-RXUOQZ32.js} +1 -1
  116. package/dist/{chunk-GZ64KWHX.js → chunk-RY4MPX5A.js} +1 -1
  117. package/dist/{chunk-5NO5OXYP.js → chunk-RY4YUBG3.js} +1 -1
  118. package/dist/{chunk-DKL6N3L2.js → chunk-S2WUVD7V.js} +1 -1
  119. package/dist/{chunk-SSJGWLCW.js → chunk-SCXL5UQ4.js} +1 -1
  120. package/dist/{chunk-YIZZ5LZN.js → chunk-SGIMJQEM.js} +1 -1
  121. package/dist/{chunk-KCS75ZM4.js → chunk-SJGPJDGH.js} +1 -1
  122. package/dist/{chunk-F5HCSUXC.js → chunk-SPE2D366.js} +1 -1
  123. package/dist/{chunk-CFWHR74L.js → chunk-SYF6LGQB.js} +1 -1
  124. package/dist/{chunk-PIFW2R3S.js → chunk-TP4Z5OZT.js} +1 -1
  125. package/dist/{chunk-6ENBE43F.js → chunk-U3F6GPCE.js} +1 -1
  126. package/dist/{chunk-SEVSMWNX.js → chunk-U46RPVQA.js} +1 -1
  127. package/dist/{chunk-CYOFLJ3Z.js → chunk-UAJBQEGE.js} +1 -1
  128. package/dist/{chunk-QZBSCOJV.js → chunk-UK4WXL4G.js} +1 -1
  129. package/dist/{chunk-CHMEDVDZ.js → chunk-ULR25PTO.js} +1 -1
  130. package/dist/{chunk-7WTNEG2F.js → chunk-USBP7H7J.js} +1 -1
  131. package/dist/{chunk-4HV6A6UH.js → chunk-UZV5H2JI.js} +1 -1
  132. package/dist/{chunk-6EBLULOC.js → chunk-UZVON6GP.js} +1 -1
  133. package/dist/{chunk-Z5K4J7HQ.js → chunk-VI5FF6SW.js} +1 -1
  134. package/dist/{chunk-6VGJVXZI.js → chunk-VPY47DBW.js} +1 -1
  135. package/dist/{chunk-S3P5WWJD.js → chunk-VRH3HWYA.js} +1 -1
  136. package/dist/{chunk-37TEEITE.js → chunk-VXX4EZ7G.js} +1 -1
  137. package/dist/{chunk-WKUGSFTB.js → chunk-VXYABRFY.js} +1 -1
  138. package/dist/{chunk-KOVAFUYN.js → chunk-WEWLPJK2.js} +1 -1
  139. package/dist/{chunk-TTAPXLI5.js → chunk-WMZS3Y4Z.js} +1 -1
  140. package/dist/{chunk-JZXA3H5K.js → chunk-WOIAYH5U.js} +1 -1
  141. package/dist/{chunk-6OFGSZD6.js → chunk-WR6LRE4I.js} +1 -1
  142. package/dist/{chunk-GMTNOCMS.js → chunk-WSCSFFLH.js} +2 -2
  143. package/dist/{chunk-K4KTNINH.js → chunk-WTES5ZXR.js} +1 -1
  144. package/dist/{chunk-BR6DBMQA.js → chunk-WXSDPMIZ.js} +1 -1
  145. package/dist/{chunk-YOO7DLOT.js → chunk-X5JQU6T7.js} +1 -1
  146. package/dist/{chunk-2HK4MFWP.js → chunk-XMJFT4WP.js} +1 -1
  147. package/dist/{chunk-63CIFL36.js → chunk-XMQFQUUK.js} +1 -1
  148. package/dist/{chunk-EOMCXBCS.js → chunk-XTXYS7LB.js} +1 -1
  149. package/dist/{chunk-QPWMD2VR.js → chunk-Y6UZW73M.js} +1 -1
  150. package/dist/{chunk-FCGKO2KY.js → chunk-YCU7ZCIG.js} +1 -1
  151. package/dist/{chunk-TYIGOVRQ.js → chunk-YFKEESYB.js} +1 -1
  152. package/dist/{chunk-U7R6LYPJ.js → chunk-YXDIHVPY.js} +1 -1
  153. package/dist/{chunk-TCTVI6PK.js → chunk-Z66ZSXKB.js} +1 -1
  154. package/dist/{chunk-PANGX7SA.js → chunk-ZBSC2KZ7.js} +1 -1
  155. package/dist/{chunk-5HPBQ6U5.js → chunk-ZDDLEFVO.js} +1 -1
  156. package/dist/{chunk-DQFSKPKL.js → chunk-ZULQKYJ6.js} +1 -1
  157. package/dist/cli/commands/app/app-logs/sources.js +1 -1
  158. package/dist/cli/commands/app/build.js +1 -1
  159. package/dist/cli/commands/app/bulk/cancel.js +1 -1
  160. package/dist/cli/commands/app/bulk/execute.js +1 -1
  161. package/dist/cli/commands/app/bulk/status.js +1 -1
  162. package/dist/cli/commands/app/config/link.js +1 -1
  163. package/dist/cli/commands/app/config/pull.js +1 -1
  164. package/dist/cli/commands/app/config/use.js +1 -1
  165. package/dist/cli/commands/app/config/validate.js +1 -1
  166. package/dist/cli/commands/app/demo/watcher.js +1 -1
  167. package/dist/cli/commands/app/deploy.js +1 -1
  168. package/dist/cli/commands/app/dev/clean.js +1 -1
  169. package/dist/cli/commands/app/dev.js +1 -1
  170. package/dist/cli/commands/app/env/pull.js +1 -1
  171. package/dist/cli/commands/app/env/show.js +1 -1
  172. package/dist/cli/commands/app/execute.js +1 -1
  173. package/dist/cli/commands/app/function/build.js +1 -1
  174. package/dist/cli/commands/app/function/info.js +1 -1
  175. package/dist/cli/commands/app/function/replay.js +1 -1
  176. package/dist/cli/commands/app/function/run.js +1 -1
  177. package/dist/cli/commands/app/function/schema.js +1 -1
  178. package/dist/cli/commands/app/function/typegen.js +1 -1
  179. package/dist/cli/commands/app/generate/extension.js +1 -1
  180. package/dist/cli/commands/app/graphiql.js +1 -1
  181. package/dist/cli/commands/app/import-custom-data-definitions.js +1 -1
  182. package/dist/cli/commands/app/import-extensions.js +1 -1
  183. package/dist/cli/commands/app/info.js +1 -1
  184. package/dist/cli/commands/app/init.js +1 -1
  185. package/dist/cli/commands/app/logs.js +1 -1
  186. package/dist/cli/commands/app/release.js +1 -1
  187. package/dist/cli/commands/app/versions/list.js +1 -1
  188. package/dist/cli/commands/app/webhook/trigger.js +1 -1
  189. package/dist/cli/commands/auth/login.js +1 -1
  190. package/dist/cli/commands/auth/logout.js +1 -1
  191. package/dist/cli/commands/cache/clear.js +1 -1
  192. package/dist/cli/commands/config/autoupgrade/off.js +1 -1
  193. package/dist/cli/commands/config/autoupgrade/on.js +1 -1
  194. package/dist/cli/commands/config/autoupgrade/status.js +1 -1
  195. package/dist/cli/commands/debug/command-flags.js +1 -1
  196. package/dist/cli/commands/doc/fetch.js +1 -1
  197. package/dist/cli/commands/doc/search.js +1 -1
  198. package/dist/cli/commands/docs/generate.js +1 -1
  199. package/dist/cli/commands/doctor-release/doctor-release.js +1 -1
  200. package/dist/cli/commands/doctor-release/theme/index.js +1 -1
  201. package/dist/cli/commands/help.js +1 -1
  202. package/dist/cli/commands/kitchen-sink/async.js +1 -1
  203. package/dist/cli/commands/kitchen-sink/index.js +1 -1
  204. package/dist/cli/commands/kitchen-sink/prompts.js +1 -1
  205. package/dist/cli/commands/kitchen-sink/static.js +1 -1
  206. package/dist/cli/commands/notifications/generate.js +1 -1
  207. package/dist/cli/commands/notifications/list.js +1 -1
  208. package/dist/cli/commands/organization/list.js +1 -1
  209. package/dist/cli/commands/search.js +1 -1
  210. package/dist/cli/commands/send-analytics.js +1 -1
  211. package/dist/cli/commands/theme/check.js +1 -1
  212. package/dist/cli/commands/theme/console.js +1 -1
  213. package/dist/cli/commands/theme/delete.js +1 -1
  214. package/dist/cli/commands/theme/dev.js +1 -1
  215. package/dist/cli/commands/theme/duplicate.js +1 -1
  216. package/dist/cli/commands/theme/info.js +1 -1
  217. package/dist/cli/commands/theme/init.js +1 -1
  218. package/dist/cli/commands/theme/language-server.js +1 -1
  219. package/dist/cli/commands/theme/list.js +1 -1
  220. package/dist/cli/commands/theme/metafields/pull.js +1 -1
  221. package/dist/cli/commands/theme/open.js +1 -1
  222. package/dist/cli/commands/theme/package.js +1 -1
  223. package/dist/cli/commands/theme/preview.js +1 -1
  224. package/dist/cli/commands/theme/profile.js +1 -1
  225. package/dist/cli/commands/theme/publish.js +1 -1
  226. package/dist/cli/commands/theme/pull.js +1 -1
  227. package/dist/cli/commands/theme/push.js +1 -1
  228. package/dist/cli/commands/theme/rename.js +1 -1
  229. package/dist/cli/commands/theme/share.js +1 -1
  230. package/dist/cli/commands/upgrade.js +1 -1
  231. package/dist/cli/commands/version.js +1 -1
  232. package/dist/command-registry.js +1 -1
  233. package/dist/{conf-store-OAGJBITE.js → conf-store-QQ4DOFI3.js} +1 -1
  234. package/dist/{deprecations-K3NPRKBF.js → deprecations-43ZQ5RCE.js} +1 -1
  235. package/dist/dist-E7EGYE4D.js +1 -0
  236. package/dist/dist-WRUROUNV.js +1 -0
  237. package/dist/{environments-ALH2N36U.js → environments-RG64VB5R.js} +1 -1
  238. package/dist/{error-YX56C43A.js → error-26WTDNKZ.js} +1 -1
  239. package/dist/error-handler-XFH47Y75.js +1 -0
  240. package/dist/{fs-SKHQZZTQ.js → fs-Y7I3Y5IR.js} +1 -1
  241. package/dist/hooks/did-you-mean.js +1 -1
  242. package/dist/hooks/hydrogen-init.js +1 -1
  243. package/dist/hooks/postrun.js +1 -1
  244. package/dist/hooks/prerun.js +1 -1
  245. package/dist/hooks/public-metadata.js +1 -1
  246. package/dist/hooks/sensitive-metadata.js +1 -1
  247. package/dist/hooks/tunnel-provider.js +1 -1
  248. package/dist/hooks/tunnel-start.js +1 -1
  249. package/dist/index.js +15 -15
  250. package/dist/{is-global-V5VORI3F.js → is-global-WBIBPIVZ.js} +1 -1
  251. package/dist/{local-GX5AN6ZS.js → local-HF4T3FFE.js} +1 -1
  252. package/dist/{metadata-XUJUTBTB.js → metadata-CSQPNQP2.js} +1 -1
  253. package/dist/{node-package-manager-3WIYU7Y3.js → node-package-manager-CVEU22N7.js} +1 -1
  254. package/dist/notifications-system-L3FMN6EX.js +1 -0
  255. package/dist/os-VLZLRAHR.js +1 -0
  256. package/dist/{output-X47P6ICP.js → output-E6OGPGXL.js} +1 -1
  257. package/dist/{system-SR5G7WEW.js → system-ZETSJRKS.js} +1 -1
  258. package/dist/tsconfig.tsbuildinfo +1 -1
  259. package/dist/{ui-VYWSLAQ6.js → ui-7TVGGEWJ.js} +1 -1
  260. package/dist/upgrade-F77O4ZDT.js +1 -0
  261. package/dist/version-3L3ANUTL.js +1 -0
  262. package/dist/{version-FK4ETQ22.js → version-DL4Y6DRX.js} +1 -1
  263. package/dist/{workerd-NAPS5TA7.js → workerd-EHI5ZCEV.js} +1 -1
  264. package/oclif.manifest.json +1 -1
  265. package/package.json +7 -7
  266. package/dist/analytics-UNRIIG4Y.js +0 -1
  267. package/dist/chunk-5CYJG63I.js +0 -1
  268. package/dist/chunk-NEMPLS7C.js +0 -1
  269. package/dist/chunk-OUZGGWFN.js +0 -1
  270. package/dist/chunk-RZFBGBNA.js +0 -1
  271. package/dist/dist-EXJEE23W.js +0 -1
  272. package/dist/dist-S62Z6IFV.js +0 -1
  273. package/dist/error-handler-FDCH72NH.js +0 -1
  274. package/dist/notifications-system-RHULO564.js +0 -1
  275. package/dist/os-M6X7KOR4.js +0 -1
  276. package/dist/upgrade-PFQ7JMXG.js +0 -1
  277. package/dist/version-U4GM2LNG.js +0 -1
@@ -1,4 +1,4 @@
1
- import{b as vi}from"./chunk-LQ7ENG4V.js";import{$ as ni,A as Wn,Aa as hi,B as k,Ba as gi,C as U,Ca as yi,D as zn,E as ve,F as Zt,G as qe,H as rt,I as xe,Ia as To,J as Jn,Ja as wi,K as Ne,Ka as mr,L as Pe,La as ze,M as Qn,Ma as at,N as er,Na as Pt,O as he,Oa as pr,P as Do,Pa as lt,Q as Kn,Qa as hr,R as ot,Ra as bi,S as nt,Sa as ki,T as Xn,Ta as Ei,U as tr,Ua as gr,V as Zn,Va as Si,W as ei,Wa as xi,X as ti,Xa as Pi,Y as ri,Z as oi,_ as Ye,a as ue,aa as z,b as Et,ba as it,c as Hn,ca as ii,d as Ie,da as si,e as Se,ea as rr,f as Ge,fa as or,g as Mn,ga as ai,h as Un,ha as ge,i as Bn,ia as li,j as ko,ja as ci,k as et,ka as Co,l as St,la as di,m as je,ma as ui,n as Vn,na as fi,o as Qt,oa as nr,p as Eo,pa as ir,q as xt,qa as sr,r as So,ra as mi,s as Gn,sa as ar,t as qn,ta as lr,u as xo,ua as pi,v as Yn,va as cr,w as Po,wa as dr,x as Kt,xa as We,y as Xt,ya as st,z as tt,za as ur}from"./chunk-LDF4PQ3B.js";import{a as yr}from"./chunk-FKIVKNOV.js";import{a as _n}from"./chunk-JLGA3B7P.js";import{a as Di}from"./chunk-AH2ZGMDM.js";import{b as Rn,c as $n,d as Jt,g as An,i as Fn,j as jn,k as Nn}from"./chunk-ZSFAURIH.js";import{a as pl,b as Ln,d as hl}from"./chunk-ZRLEAF7M.js";import{a as fr,b as Io,c as Oo}from"./chunk-LWJA2DQG.js";import{c as On}from"./chunk-F3TMLDLC.js";import{b as O}from"./chunk-RY2SJVWM.js";import{Ca as ul,Da as Dn,Ea as fl,Fa as ml,b as wn,ja as pe,p as vn,q as ae}from"./chunk-YN6A26QL.js";import{B as Pn,l as kn,m as Ee,p as qt,s as En,u as Sn,x as xn}from"./chunk-KK24VGVE.js";import{A as Y,B as Cn,C as Re,D as $e,E as Te,H as ee,S as bo,a as Gt,y as B,z as N}from"./chunk-GMTNOCMS.js";import{h as E,k as Wt}from"./chunk-R2R6JDNH.js";import{a as cl}from"./chunk-CX5CC6P5.js";import{b as dl}from"./chunk-TOLPNBZK.js";import{Ab as In,Bb as V,Ca as yo,Cb as te,Ea as Vt,Ga as gn,Ha as yn,Ka as wo,Oa as vo,Ta as G,U as Ut,Wa as kt,_ as pn,jb as bn,ma as de,mb as Yt,na as hn,pa as Bt,qa as go,qb as we,sb as W,ua as K,ub as Ae,wa as bt,xb as F,ya as ke,yb as Tn,zb as Fe}from"./chunk-Y34LWI3S.js";import{i as H}from"./chunk-B4OMIONW.js";import{r as zt}from"./chunk-XAOYKECS.js";import{d as x,f as T,g as se,i as ho,j as Ze,k as fn,q as mn}from"./chunk-773TIA5M.js";import{a as be,c as ce,e as Q,g as c}from"./chunk-VKWPEFWQ.js";var Ys=ce((Xw,qs)=>{c();qs.exports=Jc;function Jc(e){var t=e._readableState;return t?t.objectMode||typeof e._duplexState=="number"?e.read():e.read(Qc(t)):null}function Qc(e){if(e.buffer.length){var t=e.bufferIndex||0;if(e.buffer.head)return e.buffer.head.data.length;if(e.buffer.length-t>0&&e.buffer[t])return e.buffer[t].length}return e.length}});var qo=ce((ev,Qs)=>{c();var Yr=Ln(),Ws=Dn(),Kc=On(),Xc=Ys(),zs=Buffer.from&&Buffer.from!==Uint8Array.from?Buffer.from([0]):new Buffer([0]),Go=function(e,t){e._corked?e.once("uncork",t):t()},Zc=function(e,t){e._autoDestroy&&e.destroy(t)},Js=function(e,t){return function(r){r?Zc(e,r.message==="premature close"?null:r):t&&!e._ended&&e.end()}},ed=function(e,t){if(!e||e._writableState&&e._writableState.finished)return t();if(e._writableState)return e.end(t);e.end(),t()},td=function(e){return new Yr.Readable({objectMode:!0,highWaterMark:16}).wrap(e)},X=function(e,t,r){if(!(this instanceof X))return new X(e,t,r);Yr.Duplex.call(this,r),this._writable=null,this._readable=null,this._readable2=null,this._autoDestroy=!r||r.autoDestroy!==!1,this._forwardDestroy=!r||r.destroy!==!1,this._forwardEnd=!r||r.end!==!1,this._corked=1,this._ondrain=null,this._drained=!1,this._forwarding=!1,this._unwrite=null,this._unread=null,this._ended=!1,this.destroyed=!1,e&&this.setWritable(e),t&&this.setReadable(t)};Kc(X,Yr.Duplex);X.obj=function(e,t,r){return r||(r={}),r.objectMode=!0,r.highWaterMark=16,new X(e,t,r)};X.prototype.cork=function(){++this._corked===1&&this.emit("cork")};X.prototype.uncork=function(){this._corked&&--this._corked===0&&this.emit("uncork")};X.prototype.setWritable=function(e){if(this._unwrite&&this._unwrite(),this.destroyed){e&&e.destroy&&e.destroy();return}if(e===null||e===!1){this.end();return}var t=this,r=Ws(e,{writable:!0,readable:!1},Js(this,this._forwardEnd)),o=function(){var i=t._ondrain;t._ondrain=null,i&&i()},n=function(){t._writable.removeListener("drain",o),r()};this._unwrite&&process.nextTick(o),this._writable=e,this._writable.on("drain",o),this._unwrite=n,this.uncork()};X.prototype.setReadable=function(e){if(this._unread&&this._unread(),this.destroyed){e&&e.destroy&&e.destroy();return}if(e===null||e===!1){this.push(null),this.resume();return}var t=this,r=Ws(e,{writable:!1,readable:!0},Js(this)),o=function(){t._forward()},n=function(){t.push(null)},i=function(){t._readable2.removeListener("readable",o),t._readable2.removeListener("end",n),r()};this._drained=!0,this._readable=e,this._readable2=e._readableState?e:td(e),this._readable2.on("readable",o),this._readable2.on("end",n),this._unread=i,this._forward()};X.prototype._read=function(){this._drained=!0,this._forward()};X.prototype._forward=function(){if(!(this._forwarding||!this._readable2||!this._drained)){this._forwarding=!0;for(var e;this._drained&&(e=Xc(this._readable2))!==null;)this.destroyed||(this._drained=this.push(e));this._forwarding=!1}};X.prototype.destroy=function(e){if(!this.destroyed){this.destroyed=!0;var t=this;process.nextTick(function(){t._destroy(e)})}};X.prototype._destroy=function(e){if(e){var t=this._ondrain;this._ondrain=null,t?t(e):this.emit("error",e)}this._forwardDestroy&&(this._readable&&this._readable.destroy&&this._readable.destroy(),this._writable&&this._writable.destroy&&this._writable.destroy()),this.emit("close")};X.prototype._write=function(e,t,r){if(this.destroyed)return r();if(this._corked)return Go(this,this._write.bind(this,e,t,r));if(e===zs)return this._finish(r);if(!this._writable)return r();this._writable.write(e)===!1?this._ondrain=r:r()};X.prototype._finish=function(e){var t=this;this.emit("preend"),Go(this,function(){ed(t._forwardEnd&&t._writable,function(){t._writableState.prefinished===!1&&(t._writableState.prefinished=!0),t.emit("prefinish"),Go(t,e)})})};X.prototype.end=function(e,t,r){return typeof e=="function"?this.end(null,null,e):typeof t=="function"?this.end(e,null,t):(this._ended=!0,e&&this.write(e),this._writableState.ending||this.write(zs),Yr.Writable.prototype.end.call(this,r))};Qs.exports=X});var Xs=ce((rv,Ks)=>{c();Ks.exports=od;var rd=Object.prototype.hasOwnProperty;function od(){for(var e={},t=0;t<arguments.length;t++){var r=arguments[t];for(var o in r)rd.call(r,o)&&(e[o]=r[o])}return e}});var Wo=ce((nv,Wr)=>{c();var Zs=Ln().Transform,ea=be("util").inherits,ta=Xs();function gt(e){Zs.call(this,e),this._destroyed=!1}ea(gt,Zs);gt.prototype.destroy=function(e){if(!this._destroyed){this._destroyed=!0;var t=this;process.nextTick(function(){e&&t.emit("error",e),t.emit("close")})}};function nd(e,t,r){r(null,e)}function Yo(e){return function(t,r,o){return typeof t=="function"&&(o=r,r=t,t={}),typeof r!="function"&&(r=nd),typeof o!="function"&&(o=null),e(t,r,o)}}Wr.exports=Yo(function(e,t,r){var o=new gt(e);return o._transform=t,r&&(o._flush=r),o});Wr.exports.ctor=Yo(function(e,t,r){function o(n){if(!(this instanceof o))return new o(n);this.options=ta(e,n),gt.call(this,this.options)}return ea(o,gt),o.prototype._transform=t,r&&(o.prototype._flush=r),o});Wr.exports.obj=Yo(function(e,t,r){var o=new gt(ta({objectMode:!0,highWaterMark:16},e));return o._transform=t,r&&(o._flush=r),o})});var na=ce((sv,oa)=>{c();var id=qo(),sd=Wo(),ad=dl(),ld=function(e){return!Buffer.isBuffer(e)&&typeof e!="string"},ra=function(e,t){if(typeof e=="number"&&(e={maxBuffer:e}),typeof e=="function")return ra(null,e);e||(e={});var r=typeof e.maxBuffer=="number"?e.maxBuffer:65535,o=e.strict,n=e.newline!==!1,i=[],s=0,a=id.obj(),l=sd.obj({highWaterMark:1},function(m,f,p){if(ld(m))return u(m,null,p);if(Buffer.isBuffer(m)||(m=ad(m)),n){var h=Array.prototype.indexOf.call(m,10);if(h>0&&m[h-1]===13&&h--,h>-1)return i.push(m.slice(0,h)),u(Buffer.concat(i),m.slice(h),p)}if(i.push(m),s+=m.length,s<r)return p();if(o)return p(new Error("No newline found"));u(Buffer.concat(i),null,p)}),d=function(){if(o)return a.destroy(new Error("No newline found"));a.cork(),u(Buffer.concat(i),null,function(m){if(m)return a.destroy(m);a.uncork()})},u=function(m,f,p){a.removeListener("preend",d),t(m,function(h,b){if(h)return p(h);a.setWritable(b),a.setReadable(b),m&&b.write(m),f&&b.write(f),f=i=l=null,p()})};return a.on("preend",d),a.setWritable(l),a};oa.exports=ra});var aa=ce((lv,sa)=>{c();var cd=ul(),dd=Dn(),zo=be("fs"),Ft=function(){},ud=/^v?\.0/.test(process.version),zr=function(e){return typeof e=="function"},fd=function(e){return!ud||!zo?!1:(e instanceof(zo.ReadStream||Ft)||e instanceof(zo.WriteStream||Ft))&&zr(e.close)},md=function(e){return e.setHeader&&zr(e.abort)},pd=function(e,t,r,o){o=cd(o);var n=!1;e.on("close",function(){n=!0}),dd(e,{readable:t,writable:r},function(s){if(s)return o(s);n=!0,o()});var i=!1;return function(s){if(!n&&!i){if(i=!0,fd(e))return e.close(Ft);if(md(e))return e.abort();if(zr(e.destroy))return e.destroy();o(s||new Error("stream was destroyed"))}}},ia=function(e){e()},hd=function(e,t){return e.pipe(t)},gd=function(){var e=Array.prototype.slice.call(arguments),t=zr(e[e.length-1]||Ft)&&e.pop()||Ft;if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new Error("pump requires two streams per minimum");var r,o=e.map(function(n,i){var s=i<e.length-1,a=i>0;return pd(n,s,a,function(l){r||(r=l),l&&o.forEach(ia),!s&&(o.forEach(ia),t(r))})});e.reduce(hd)};sa.exports=gd});var da=ce((dv,Jr)=>{c();var yd=aa(),wd=On(),la=qo(),ca=function(e){return e.length?Array.isArray(e[0])?e[0]:Array.prototype.slice.call(e):[]},Jo=function(e){var t=function(){var r=ca(arguments);if(!(this instanceof t))return new t(r);la.call(this,null,null,e),r.length&&this.setPipeline(r)};return wd(t,la),t.prototype.setPipeline=function(){var r=ca(arguments),o=this,n=!1,i=r[0],s=r[r.length-1];s=s.readable?s:null,i=i.writable?i:null;var a=function(){r[0].emit("error",new Error("stream was destroyed"))};if(this.on("close",a),this.on("prefinish",function(){n||o.cork()}),yd(r,function(l){if(o.removeListener("close",a),l)return o.destroy(l.message==="premature close"?null:l);n=!0,o._autoDestroy===!1&&(o._autoDestroy=!0),o.uncork()}),this.destroyed)return a();this.setWritable(i),this.setReadable(s)},t};Jr.exports=Jo({autoDestroy:!1,destroy:!1});Jr.exports.obj=Jo({autoDestroy:!1,destroy:!1,objectMode:!0,highWaterMark:16});Jr.exports.ctor=Jo});var fa=ce((fv,ua)=>{"use strict";c();ua.exports=function(e){return!e||e.length<3?!1:e[0]===31&&e[1]===139&&e[2]===8}});var pa=ce((pv,ma)=>{"use strict";c();ma.exports=function(e){return!e||e.length<2?!1:e[0]===120&&(e[1]===1||e[1]===156||e[1]===218)}});var wa=ce((gv,ya)=>{c();var ha=be("zlib"),vd=na(),bd=Wo(),ga=da(),kd=fa(),Ed=pa(),Sd=function(e){return kd(e)?1:Ed(e)?2:0},Qo=function(e){return e===void 0&&(e=3),vd({newline:!1,maxBuffer:10},function(t,r){if(e<0)return r(new Error("Maximum recursion reached"));switch(Sd(t)){case 1:r(null,ga(ha.createGunzip(),Qo(e-1)));break;case 2:r(null,ga(ha.createInflate(),Qo(e-1)));break;default:r(null,bd())}})};ya.exports=Qo});var Pa=ce((wv,xa)=>{"use strict";c();var ye=be("fs"),Ke=be("path"),xd=ye.lchown?"lchown":"chown",Pd=ye.lchownSync?"lchownSync":"chownSync",ba=ye.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),va=(e,t,r)=>{try{return ye[Pd](e,t,r)}catch(o){if(o.code!=="ENOENT")throw o}},Dd=(e,t,r)=>{try{return ye.chownSync(e,t,r)}catch(o){if(o.code!=="ENOENT")throw o}},Cd=ba?(e,t,r,o)=>n=>{!n||n.code!=="EISDIR"?o(n):ye.chown(e,t,r,o)}:(e,t,r,o)=>o,Ko=ba?(e,t,r)=>{try{return va(e,t,r)}catch(o){if(o.code!=="EISDIR")throw o;Dd(e,t,r)}}:(e,t,r)=>va(e,t,r),Td=process.version,ka=(e,t,r)=>ye.readdir(e,t,r),Id=(e,t)=>ye.readdirSync(e,t);/^v4\./.test(Td)&&(ka=(e,t,r)=>ye.readdir(e,r));var Qr=(e,t,r,o)=>{ye[xd](e,t,r,Cd(e,t,r,n=>{o(n&&n.code!=="ENOENT"?n:null)}))},Ea=(e,t,r,o,n)=>{if(typeof t=="string")return ye.lstat(Ke.resolve(e,t),(i,s)=>{if(i)return n(i.code!=="ENOENT"?i:null);s.name=t,Ea(e,s,r,o,n)});if(t.isDirectory())Xo(Ke.resolve(e,t.name),r,o,i=>{if(i)return n(i);let s=Ke.resolve(e,t.name);Qr(s,r,o,n)});else{let i=Ke.resolve(e,t.name);Qr(i,r,o,n)}},Xo=(e,t,r,o)=>{ka(e,{withFileTypes:!0},(n,i)=>{if(n){if(n.code==="ENOENT")return o();if(n.code!=="ENOTDIR"&&n.code!=="ENOTSUP")return o(n)}if(n||!i.length)return Qr(e,t,r,o);let s=i.length,a=null,l=d=>{if(!a){if(d)return o(a=d);if(--s===0)return Qr(e,t,r,o)}};i.forEach(d=>Ea(e,d,t,r,l))})},Od=(e,t,r,o)=>{if(typeof t=="string")try{let n=ye.lstatSync(Ke.resolve(e,t));n.name=t,t=n}catch(n){if(n.code==="ENOENT")return;throw n}t.isDirectory()&&Sa(Ke.resolve(e,t.name),r,o),Ko(Ke.resolve(e,t.name),r,o)},Sa=(e,t,r)=>{let o;try{o=Id(e,{withFileTypes:!0})}catch(n){if(n.code==="ENOENT")return;if(n.code==="ENOTDIR"||n.code==="ENOTSUP")return Ko(e,t,r);throw n}return o&&o.length&&o.forEach(n=>Od(e,n,t,r)),Ko(e,t,r)};xa.exports=Xo;Xo.sync=Sa});var Ia=ce((bv,Ta)=>{c();var Kr=be("path"),Da=be("fs"),Ca=parseInt("0777",8);Ta.exports=yt.mkdirp=yt.mkdirP=yt;function yt(e,t,r,o){typeof t=="function"?(r=t,t={}):(!t||typeof t!="object")&&(t={mode:t});var n=t.mode,i=t.fs||Da;n===void 0&&(n=Ca&~process.umask()),o||(o=null);var s=r||function(){};e=Kr.resolve(e),i.mkdir(e,n,function(a){if(!a)return o=o||e,s(null,o);a.code==="ENOENT"?yt(Kr.dirname(e),t,function(l,d){l?s(l,d):yt(e,t,s,d)}):i.stat(e,function(l,d){l||!d.isDirectory()?s(a,o):s(null,o)})})}yt.sync=function e(t,r,o){(!r||typeof r!="object")&&(r={mode:r});var n=r.mode,i=r.fs||Da;n===void 0&&(n=Ca&~process.umask()),o||(o=null),t=Kr.resolve(t);try{i.mkdirSync(t,n),o=o||t}catch(a){switch(a.code){case"ENOENT":o=e(Kr.dirname(t),r,o),e(t,r,o);break;default:var s;try{s=i.statSync(t)}catch{throw a}if(!s.isDirectory())throw a;break}}return o}});var La=ce(tn=>{c();var _d=Pa(),Ra=hl(),$a=fl(),Rd=Ia(),Aa=be("fs"),Z=be("path"),$d=be("os"),jt=$d.platform()==="win32",Nt=function(){},en=function(e){return e},Zo=jt?function(e){return e.replace(/\\/g,"/").replace(/[:?<>|]/g,"_")}:en,Ad=function(e,t,r,o,n,i){var s=n||["."];return function(l){if(!s.length)return l();var d=s.shift(),u=Z.join(r,d);t.call(e,u,function(m,f){if(m)return l(m);if(!f.isDirectory())return l(null,d,f);e.readdir(u,function(p,h){if(p)return l(p);i&&h.sort();for(var b=0;b<h.length;b++)o(Z.join(r,d,h[b]))||s.push(Z.join(d,h[b]));l(null,d,f)})})}},Fa=function(e,t){return function(r){r.name=r.name.split("/").slice(t).join("/");var o=r.linkname;return o&&(r.type==="link"||Z.isAbsolute(o))&&(r.linkname=o.split("/").slice(t).join("/")),e(r)}};tn.pack=function(e,t){e||(e="."),t||(t={});var r=t.fs||Aa,o=t.ignore||t.filter||Nt,n=t.map||Nt,i=t.mapStream||en,s=Ad(r,t.dereference?r.stat:r.lstat,e,o,t.entries,t.sort),a=t.strict!==!1,l=typeof t.umask=="number"?~t.umask:~ja(),d=typeof t.dmode=="number"?t.dmode:0,u=typeof t.fmode=="number"?t.fmode:0,m=t.pack||Ra.pack(),f=t.finish||Nt;t.strip&&(n=Fa(n,t.strip)),t.readable&&(d|=parseInt(555,8),u|=parseInt(444,8)),t.writable&&(d|=parseInt(333,8),u|=parseInt(222,8));var p=function(w,g){r.readlink(Z.join(e,w),function(y,v){if(y)return m.destroy(y);g.linkname=Zo(v),m.entry(g,b)})},h=function(w,g,y){if(w)return m.destroy(w);if(!g)return t.finalize!==!1&&m.finalize(),f(m);if(y.isSocket())return b();var v={name:Zo(g),mode:(y.mode|(y.isDirectory()?d:u))&l,mtime:y.mtime,size:y.size,type:"file",uid:y.uid,gid:y.gid};if(y.isDirectory())return v.size=0,v.type="directory",v=n(v)||v,m.entry(v,b);if(y.isSymbolicLink())return v.size=0,v.type="symlink",v=n(v)||v,p(g,v);if(v=n(v)||v,!y.isFile())return a?m.destroy(new Error("unsupported type for "+g)):b();var S=m.entry(v,b);if(S){var P=i(r.createReadStream(Z.join(e,g),{start:0,end:v.size>0?v.size-1:v.size}),v);P.on("error",function(C){S.destroy(C)}),$a(P,S)}},b=function(w){if(w)return m.destroy(w);s(h)};return b(),m};var Fd=function(e){return e.length?e[e.length-1]:null},jd=function(){return process.getuid?process.getuid():-1},ja=function(){return process.umask?process.umask():0};tn.extract=function(e,t){e||(e="."),t||(t={});var r=t.fs||Aa,o=t.ignore||t.filter||Nt,n=t.map||Nt,i=t.mapStream||en,s=t.chown!==!1&&!jt&&jd()===0,a=t.extract||Ra.extract(),l=[],d=new Date,u=typeof t.umask=="number"?~t.umask:~ja(),m=typeof t.dmode=="number"?t.dmode:0,f=typeof t.fmode=="number"?t.fmode:0,p=t.strict!==!1;t.strip&&(n=Fa(n,t.strip)),t.readable&&(m|=parseInt(555,8),f|=parseInt(444,8)),t.writable&&(m|=parseInt(333,8),f|=parseInt(222,8));var h=function(g,y){for(var v;(v=Fd(l))&&g.slice(0,v[0].length)!==v[0];)l.pop();if(!v)return y();r.utimes(v[0],d,v[1],y)},b=function(g,y,v){if(t.utimes===!1)return v();if(y.type==="directory")return r.utimes(g,d,y.mtime,v);if(y.type==="symlink")return h(g,v);r.utimes(g,d,y.mtime,function(S){if(S)return v(S);h(g,v)})},w=function(g,y,v){var S=y.type==="symlink",P=S?r.lchmod:r.chmod,C=S?r.lchown:r.chown;if(!P)return v();var D=(y.mode|(y.type==="directory"?m:f))&u;C&&s?C.call(r,g,y.uid,y.gid,R):R(null);function R($){if($)return v($);if(!P)return v();P.call(r,g,D,v)}};return a.on("entry",function(g,y,v){g=n(g)||g,g.name=Zo(g.name);var S=Z.join(e,Z.join("/",g.name));if(o(S,g))return y.resume(),v();var P=function(I){if(I)return v(I);b(S,g,function(_){if(_)return v(_);if(jt)return v();w(S,g,v)})},C=function(){if(jt)return v();r.unlink(S,function(){var I=Z.resolve(Z.dirname(S),g.linkname);if(!_a(I,e))return v(new Error(S+" is not a valid symlink"));r.symlink(g.linkname,S,P)})},D=function(){if(jt)return v();r.unlink(S,function(){var I=Z.join(e,Z.join("/",g.linkname));r.realpath(I,function(_,L){if(_||!_a(L,e))return v(new Error(S+" is not a valid hardlink"));r.link(L,S,function(j){if(j&&j.code==="EPERM"&&t.hardlinkAsFilesFallback)return y=r.createReadStream(I),R();P(j)})})})},R=function(){var I=r.createWriteStream(S),_=i(y,g);I.on("error",function(L){_.destroy(L)}),$a(_,I,function(L){if(L)return v(L);I.on("close",P)})};if(g.type==="directory")return l.push([S,g.mtime]),Oa(S,{fs:r,own:s,uid:g.uid,gid:g.gid},P);var $=Z.dirname(S);Na(r,$,Z.join(e,"."),function(I,_){if(I)return v(I);if(!_)return v(new Error($+" is not a valid path"));Oa($,{fs:r,own:s,uid:g.uid,gid:g.gid},function(L){if(L)return v(L);switch(g.type){case"file":return R();case"link":return D();case"symlink":return C()}if(p)return v(new Error("unsupported type for "+S+" ("+g.type+")"));y.resume(),v()})})}),t.finish&&a.on("finish",t.finish),a};function Na(e,t,r,o){if(t===r)return o(null,!0);e.lstat(t,function(n,i){if(n&&n.code!=="ENOENT")return o(n);if(n||i.isDirectory())return Na(e,Z.join(t,".."),r,o);o(null,!1)})}function Oa(e,t,r){Rd(e,{fs:t.fs},function(o,n){!o&&n&&t.own?_d(n,t.uid,t.gid,r):r(o)})}function _a(e,t){return t=Z.resolve(t),t===e||e.startsWith(t+Z.sep)}});c();c();var xr=Q(ue(),1);c();c();var wr=[{name:"npm",lockfile:"package-lock.json",alternativeLockfiles:["npm-shrinkwrap.json"],installCommand:"npm ci"},{name:"yarn",lockfile:"yarn.lock",installCommand:"yarn install --frozen-lockfile"},{name:"pnpm",lockfile:"pnpm-lock.yaml",installCommand:"pnpm install --frozen-lockfile"},{name:"bun",lockfile:"bun.lockb",alternativeLockfiles:["bun.lock"],installCommand:"bun install --frozen-lockfile"}];function gl(e){let t="No lockfile found",r="If you don\u2019t commit a lockfile, then your app might install the wrong package versions when deploying. To avoid versioning issues, generate a new lockfile and commit it to your repository.",o=[["Generate a lockfile. Run",{command:"npm|yarn|pnpm install"}],"Commit the new file to your repository"];if(e)throw new E(t,r,o);Y({headline:t,body:r,nextSteps:o})}function yl(e,t){let r=e.map(({packageManager:s,foundLockfile:a})=>`${a} (created by ${s.name})`),o="Multiple lockfiles found",n=[`Your project contains more than one lockfile. This can cause version conflicts when installing and deploying your app. The following lockfiles were detected:
1
+ import{b as vi}from"./chunk-LQ7ENG4V.js";import{$ as ni,A as Wn,Aa as hi,B as k,Ba as gi,C as U,Ca as yi,D as zn,E as ve,F as Zt,G as qe,H as rt,I as xe,Ia as To,J as Jn,Ja as wi,K as Ne,Ka as mr,L as Pe,La as ze,M as Qn,Ma as at,N as er,Na as Pt,O as he,Oa as pr,P as Do,Pa as lt,Q as Kn,Qa as hr,R as ot,Ra as bi,S as nt,Sa as ki,T as Xn,Ta as Ei,U as tr,Ua as gr,V as Zn,Va as Si,W as ei,Wa as xi,X as ti,Xa as Pi,Y as ri,Z as oi,_ as Ye,a as ue,aa as z,b as Et,ba as it,c as Hn,ca as ii,d as Ie,da as si,e as Se,ea as rr,f as Ge,fa as or,g as Mn,ga as ai,h as Un,ha as ge,i as Bn,ia as li,j as ko,ja as ci,k as et,ka as Co,l as St,la as di,m as je,ma as ui,n as Vn,na as fi,o as Qt,oa as nr,p as Eo,pa as ir,q as xt,qa as sr,r as So,ra as mi,s as Gn,sa as ar,t as qn,ta as lr,u as xo,ua as pi,v as Yn,va as cr,w as Po,wa as dr,x as Kt,xa as We,y as Xt,ya as st,z as tt,za as ur}from"./chunk-22NROZ5X.js";import{a as yr}from"./chunk-FKIVKNOV.js";import{a as _n}from"./chunk-JLGA3B7P.js";import{a as Di}from"./chunk-CUUCRIGC.js";import{b as Rn,c as $n,d as Jt,g as An,i as Fn,j as jn,k as Nn}from"./chunk-M5Q74UZM.js";import{a as pl,b as Ln,d as hl}from"./chunk-LKQ3EJ6Z.js";import{a as fr,b as Io,c as Oo}from"./chunk-3HCWJRL6.js";import{c as On}from"./chunk-F3TMLDLC.js";import{b as O}from"./chunk-3WV7DQMM.js";import{Ca as ul,Da as Dn,Ea as fl,Fa as ml,b as wn,ja as pe,p as vn,q as ae}from"./chunk-PK73ZSND.js";import{B as Pn,l as kn,m as Ee,p as qt,s as En,u as Sn,x as xn}from"./chunk-GW4JHUIA.js";import{A as Y,B as Cn,C as Re,D as $e,E as Te,H as ee,S as bo,a as Gt,y as B,z as N}from"./chunk-WSCSFFLH.js";import{h as E,k as Wt}from"./chunk-BI7LE6CZ.js";import{a as cl}from"./chunk-CX5CC6P5.js";import{b as dl}from"./chunk-TOLPNBZK.js";import{Ab as In,Bb as V,Ca as yo,Cb as te,Ea as Vt,Ga as gn,Ha as yn,Ka as wo,Oa as vo,Ta as G,U as Ut,Wa as kt,_ as pn,jb as bn,ma as de,mb as Yt,na as hn,pa as Bt,qa as go,qb as we,sb as W,ua as K,ub as Ae,wa as bt,xb as F,ya as ke,yb as Tn,zb as Fe}from"./chunk-HQUWYKSJ.js";import{i as H}from"./chunk-B4OMIONW.js";import{r as zt}from"./chunk-4VJ6YK7U.js";import{d as x,f as T,g as se,i as ho,j as Ze,k as fn,q as mn}from"./chunk-773TIA5M.js";import{a as be,c as ce,e as Q,g as c}from"./chunk-VKWPEFWQ.js";var Ys=ce((Xw,qs)=>{c();qs.exports=Jc;function Jc(e){var t=e._readableState;return t?t.objectMode||typeof e._duplexState=="number"?e.read():e.read(Qc(t)):null}function Qc(e){if(e.buffer.length){var t=e.bufferIndex||0;if(e.buffer.head)return e.buffer.head.data.length;if(e.buffer.length-t>0&&e.buffer[t])return e.buffer[t].length}return e.length}});var qo=ce((ev,Qs)=>{c();var Yr=Ln(),Ws=Dn(),Kc=On(),Xc=Ys(),zs=Buffer.from&&Buffer.from!==Uint8Array.from?Buffer.from([0]):new Buffer([0]),Go=function(e,t){e._corked?e.once("uncork",t):t()},Zc=function(e,t){e._autoDestroy&&e.destroy(t)},Js=function(e,t){return function(r){r?Zc(e,r.message==="premature close"?null:r):t&&!e._ended&&e.end()}},ed=function(e,t){if(!e||e._writableState&&e._writableState.finished)return t();if(e._writableState)return e.end(t);e.end(),t()},td=function(e){return new Yr.Readable({objectMode:!0,highWaterMark:16}).wrap(e)},X=function(e,t,r){if(!(this instanceof X))return new X(e,t,r);Yr.Duplex.call(this,r),this._writable=null,this._readable=null,this._readable2=null,this._autoDestroy=!r||r.autoDestroy!==!1,this._forwardDestroy=!r||r.destroy!==!1,this._forwardEnd=!r||r.end!==!1,this._corked=1,this._ondrain=null,this._drained=!1,this._forwarding=!1,this._unwrite=null,this._unread=null,this._ended=!1,this.destroyed=!1,e&&this.setWritable(e),t&&this.setReadable(t)};Kc(X,Yr.Duplex);X.obj=function(e,t,r){return r||(r={}),r.objectMode=!0,r.highWaterMark=16,new X(e,t,r)};X.prototype.cork=function(){++this._corked===1&&this.emit("cork")};X.prototype.uncork=function(){this._corked&&--this._corked===0&&this.emit("uncork")};X.prototype.setWritable=function(e){if(this._unwrite&&this._unwrite(),this.destroyed){e&&e.destroy&&e.destroy();return}if(e===null||e===!1){this.end();return}var t=this,r=Ws(e,{writable:!0,readable:!1},Js(this,this._forwardEnd)),o=function(){var i=t._ondrain;t._ondrain=null,i&&i()},n=function(){t._writable.removeListener("drain",o),r()};this._unwrite&&process.nextTick(o),this._writable=e,this._writable.on("drain",o),this._unwrite=n,this.uncork()};X.prototype.setReadable=function(e){if(this._unread&&this._unread(),this.destroyed){e&&e.destroy&&e.destroy();return}if(e===null||e===!1){this.push(null),this.resume();return}var t=this,r=Ws(e,{writable:!1,readable:!0},Js(this)),o=function(){t._forward()},n=function(){t.push(null)},i=function(){t._readable2.removeListener("readable",o),t._readable2.removeListener("end",n),r()};this._drained=!0,this._readable=e,this._readable2=e._readableState?e:td(e),this._readable2.on("readable",o),this._readable2.on("end",n),this._unread=i,this._forward()};X.prototype._read=function(){this._drained=!0,this._forward()};X.prototype._forward=function(){if(!(this._forwarding||!this._readable2||!this._drained)){this._forwarding=!0;for(var e;this._drained&&(e=Xc(this._readable2))!==null;)this.destroyed||(this._drained=this.push(e));this._forwarding=!1}};X.prototype.destroy=function(e){if(!this.destroyed){this.destroyed=!0;var t=this;process.nextTick(function(){t._destroy(e)})}};X.prototype._destroy=function(e){if(e){var t=this._ondrain;this._ondrain=null,t?t(e):this.emit("error",e)}this._forwardDestroy&&(this._readable&&this._readable.destroy&&this._readable.destroy(),this._writable&&this._writable.destroy&&this._writable.destroy()),this.emit("close")};X.prototype._write=function(e,t,r){if(this.destroyed)return r();if(this._corked)return Go(this,this._write.bind(this,e,t,r));if(e===zs)return this._finish(r);if(!this._writable)return r();this._writable.write(e)===!1?this._ondrain=r:r()};X.prototype._finish=function(e){var t=this;this.emit("preend"),Go(this,function(){ed(t._forwardEnd&&t._writable,function(){t._writableState.prefinished===!1&&(t._writableState.prefinished=!0),t.emit("prefinish"),Go(t,e)})})};X.prototype.end=function(e,t,r){return typeof e=="function"?this.end(null,null,e):typeof t=="function"?this.end(e,null,t):(this._ended=!0,e&&this.write(e),this._writableState.ending||this.write(zs),Yr.Writable.prototype.end.call(this,r))};Qs.exports=X});var Xs=ce((rv,Ks)=>{c();Ks.exports=od;var rd=Object.prototype.hasOwnProperty;function od(){for(var e={},t=0;t<arguments.length;t++){var r=arguments[t];for(var o in r)rd.call(r,o)&&(e[o]=r[o])}return e}});var Wo=ce((nv,Wr)=>{c();var Zs=Ln().Transform,ea=be("util").inherits,ta=Xs();function gt(e){Zs.call(this,e),this._destroyed=!1}ea(gt,Zs);gt.prototype.destroy=function(e){if(!this._destroyed){this._destroyed=!0;var t=this;process.nextTick(function(){e&&t.emit("error",e),t.emit("close")})}};function nd(e,t,r){r(null,e)}function Yo(e){return function(t,r,o){return typeof t=="function"&&(o=r,r=t,t={}),typeof r!="function"&&(r=nd),typeof o!="function"&&(o=null),e(t,r,o)}}Wr.exports=Yo(function(e,t,r){var o=new gt(e);return o._transform=t,r&&(o._flush=r),o});Wr.exports.ctor=Yo(function(e,t,r){function o(n){if(!(this instanceof o))return new o(n);this.options=ta(e,n),gt.call(this,this.options)}return ea(o,gt),o.prototype._transform=t,r&&(o.prototype._flush=r),o});Wr.exports.obj=Yo(function(e,t,r){var o=new gt(ta({objectMode:!0,highWaterMark:16},e));return o._transform=t,r&&(o._flush=r),o})});var na=ce((sv,oa)=>{c();var id=qo(),sd=Wo(),ad=dl(),ld=function(e){return!Buffer.isBuffer(e)&&typeof e!="string"},ra=function(e,t){if(typeof e=="number"&&(e={maxBuffer:e}),typeof e=="function")return ra(null,e);e||(e={});var r=typeof e.maxBuffer=="number"?e.maxBuffer:65535,o=e.strict,n=e.newline!==!1,i=[],s=0,a=id.obj(),l=sd.obj({highWaterMark:1},function(m,f,p){if(ld(m))return u(m,null,p);if(Buffer.isBuffer(m)||(m=ad(m)),n){var h=Array.prototype.indexOf.call(m,10);if(h>0&&m[h-1]===13&&h--,h>-1)return i.push(m.slice(0,h)),u(Buffer.concat(i),m.slice(h),p)}if(i.push(m),s+=m.length,s<r)return p();if(o)return p(new Error("No newline found"));u(Buffer.concat(i),null,p)}),d=function(){if(o)return a.destroy(new Error("No newline found"));a.cork(),u(Buffer.concat(i),null,function(m){if(m)return a.destroy(m);a.uncork()})},u=function(m,f,p){a.removeListener("preend",d),t(m,function(h,b){if(h)return p(h);a.setWritable(b),a.setReadable(b),m&&b.write(m),f&&b.write(f),f=i=l=null,p()})};return a.on("preend",d),a.setWritable(l),a};oa.exports=ra});var aa=ce((lv,sa)=>{c();var cd=ul(),dd=Dn(),zo=be("fs"),Ft=function(){},ud=/^v?\.0/.test(process.version),zr=function(e){return typeof e=="function"},fd=function(e){return!ud||!zo?!1:(e instanceof(zo.ReadStream||Ft)||e instanceof(zo.WriteStream||Ft))&&zr(e.close)},md=function(e){return e.setHeader&&zr(e.abort)},pd=function(e,t,r,o){o=cd(o);var n=!1;e.on("close",function(){n=!0}),dd(e,{readable:t,writable:r},function(s){if(s)return o(s);n=!0,o()});var i=!1;return function(s){if(!n&&!i){if(i=!0,fd(e))return e.close(Ft);if(md(e))return e.abort();if(zr(e.destroy))return e.destroy();o(s||new Error("stream was destroyed"))}}},ia=function(e){e()},hd=function(e,t){return e.pipe(t)},gd=function(){var e=Array.prototype.slice.call(arguments),t=zr(e[e.length-1]||Ft)&&e.pop()||Ft;if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new Error("pump requires two streams per minimum");var r,o=e.map(function(n,i){var s=i<e.length-1,a=i>0;return pd(n,s,a,function(l){r||(r=l),l&&o.forEach(ia),!s&&(o.forEach(ia),t(r))})});e.reduce(hd)};sa.exports=gd});var da=ce((dv,Jr)=>{c();var yd=aa(),wd=On(),la=qo(),ca=function(e){return e.length?Array.isArray(e[0])?e[0]:Array.prototype.slice.call(e):[]},Jo=function(e){var t=function(){var r=ca(arguments);if(!(this instanceof t))return new t(r);la.call(this,null,null,e),r.length&&this.setPipeline(r)};return wd(t,la),t.prototype.setPipeline=function(){var r=ca(arguments),o=this,n=!1,i=r[0],s=r[r.length-1];s=s.readable?s:null,i=i.writable?i:null;var a=function(){r[0].emit("error",new Error("stream was destroyed"))};if(this.on("close",a),this.on("prefinish",function(){n||o.cork()}),yd(r,function(l){if(o.removeListener("close",a),l)return o.destroy(l.message==="premature close"?null:l);n=!0,o._autoDestroy===!1&&(o._autoDestroy=!0),o.uncork()}),this.destroyed)return a();this.setWritable(i),this.setReadable(s)},t};Jr.exports=Jo({autoDestroy:!1,destroy:!1});Jr.exports.obj=Jo({autoDestroy:!1,destroy:!1,objectMode:!0,highWaterMark:16});Jr.exports.ctor=Jo});var fa=ce((fv,ua)=>{"use strict";c();ua.exports=function(e){return!e||e.length<3?!1:e[0]===31&&e[1]===139&&e[2]===8}});var pa=ce((pv,ma)=>{"use strict";c();ma.exports=function(e){return!e||e.length<2?!1:e[0]===120&&(e[1]===1||e[1]===156||e[1]===218)}});var wa=ce((gv,ya)=>{c();var ha=be("zlib"),vd=na(),bd=Wo(),ga=da(),kd=fa(),Ed=pa(),Sd=function(e){return kd(e)?1:Ed(e)?2:0},Qo=function(e){return e===void 0&&(e=3),vd({newline:!1,maxBuffer:10},function(t,r){if(e<0)return r(new Error("Maximum recursion reached"));switch(Sd(t)){case 1:r(null,ga(ha.createGunzip(),Qo(e-1)));break;case 2:r(null,ga(ha.createInflate(),Qo(e-1)));break;default:r(null,bd())}})};ya.exports=Qo});var Pa=ce((wv,xa)=>{"use strict";c();var ye=be("fs"),Ke=be("path"),xd=ye.lchown?"lchown":"chown",Pd=ye.lchownSync?"lchownSync":"chownSync",ba=ye.lchown&&!process.version.match(/v1[1-9]+\./)&&!process.version.match(/v10\.[6-9]/),va=(e,t,r)=>{try{return ye[Pd](e,t,r)}catch(o){if(o.code!=="ENOENT")throw o}},Dd=(e,t,r)=>{try{return ye.chownSync(e,t,r)}catch(o){if(o.code!=="ENOENT")throw o}},Cd=ba?(e,t,r,o)=>n=>{!n||n.code!=="EISDIR"?o(n):ye.chown(e,t,r,o)}:(e,t,r,o)=>o,Ko=ba?(e,t,r)=>{try{return va(e,t,r)}catch(o){if(o.code!=="EISDIR")throw o;Dd(e,t,r)}}:(e,t,r)=>va(e,t,r),Td=process.version,ka=(e,t,r)=>ye.readdir(e,t,r),Id=(e,t)=>ye.readdirSync(e,t);/^v4\./.test(Td)&&(ka=(e,t,r)=>ye.readdir(e,r));var Qr=(e,t,r,o)=>{ye[xd](e,t,r,Cd(e,t,r,n=>{o(n&&n.code!=="ENOENT"?n:null)}))},Ea=(e,t,r,o,n)=>{if(typeof t=="string")return ye.lstat(Ke.resolve(e,t),(i,s)=>{if(i)return n(i.code!=="ENOENT"?i:null);s.name=t,Ea(e,s,r,o,n)});if(t.isDirectory())Xo(Ke.resolve(e,t.name),r,o,i=>{if(i)return n(i);let s=Ke.resolve(e,t.name);Qr(s,r,o,n)});else{let i=Ke.resolve(e,t.name);Qr(i,r,o,n)}},Xo=(e,t,r,o)=>{ka(e,{withFileTypes:!0},(n,i)=>{if(n){if(n.code==="ENOENT")return o();if(n.code!=="ENOTDIR"&&n.code!=="ENOTSUP")return o(n)}if(n||!i.length)return Qr(e,t,r,o);let s=i.length,a=null,l=d=>{if(!a){if(d)return o(a=d);if(--s===0)return Qr(e,t,r,o)}};i.forEach(d=>Ea(e,d,t,r,l))})},Od=(e,t,r,o)=>{if(typeof t=="string")try{let n=ye.lstatSync(Ke.resolve(e,t));n.name=t,t=n}catch(n){if(n.code==="ENOENT")return;throw n}t.isDirectory()&&Sa(Ke.resolve(e,t.name),r,o),Ko(Ke.resolve(e,t.name),r,o)},Sa=(e,t,r)=>{let o;try{o=Id(e,{withFileTypes:!0})}catch(n){if(n.code==="ENOENT")return;if(n.code==="ENOTDIR"||n.code==="ENOTSUP")return Ko(e,t,r);throw n}return o&&o.length&&o.forEach(n=>Od(e,n,t,r)),Ko(e,t,r)};xa.exports=Xo;Xo.sync=Sa});var Ia=ce((bv,Ta)=>{c();var Kr=be("path"),Da=be("fs"),Ca=parseInt("0777",8);Ta.exports=yt.mkdirp=yt.mkdirP=yt;function yt(e,t,r,o){typeof t=="function"?(r=t,t={}):(!t||typeof t!="object")&&(t={mode:t});var n=t.mode,i=t.fs||Da;n===void 0&&(n=Ca&~process.umask()),o||(o=null);var s=r||function(){};e=Kr.resolve(e),i.mkdir(e,n,function(a){if(!a)return o=o||e,s(null,o);a.code==="ENOENT"?yt(Kr.dirname(e),t,function(l,d){l?s(l,d):yt(e,t,s,d)}):i.stat(e,function(l,d){l||!d.isDirectory()?s(a,o):s(null,o)})})}yt.sync=function e(t,r,o){(!r||typeof r!="object")&&(r={mode:r});var n=r.mode,i=r.fs||Da;n===void 0&&(n=Ca&~process.umask()),o||(o=null),t=Kr.resolve(t);try{i.mkdirSync(t,n),o=o||t}catch(a){switch(a.code){case"ENOENT":o=e(Kr.dirname(t),r,o),e(t,r,o);break;default:var s;try{s=i.statSync(t)}catch{throw a}if(!s.isDirectory())throw a;break}}return o}});var La=ce(tn=>{c();var _d=Pa(),Ra=hl(),$a=fl(),Rd=Ia(),Aa=be("fs"),Z=be("path"),$d=be("os"),jt=$d.platform()==="win32",Nt=function(){},en=function(e){return e},Zo=jt?function(e){return e.replace(/\\/g,"/").replace(/[:?<>|]/g,"_")}:en,Ad=function(e,t,r,o,n,i){var s=n||["."];return function(l){if(!s.length)return l();var d=s.shift(),u=Z.join(r,d);t.call(e,u,function(m,f){if(m)return l(m);if(!f.isDirectory())return l(null,d,f);e.readdir(u,function(p,h){if(p)return l(p);i&&h.sort();for(var b=0;b<h.length;b++)o(Z.join(r,d,h[b]))||s.push(Z.join(d,h[b]));l(null,d,f)})})}},Fa=function(e,t){return function(r){r.name=r.name.split("/").slice(t).join("/");var o=r.linkname;return o&&(r.type==="link"||Z.isAbsolute(o))&&(r.linkname=o.split("/").slice(t).join("/")),e(r)}};tn.pack=function(e,t){e||(e="."),t||(t={});var r=t.fs||Aa,o=t.ignore||t.filter||Nt,n=t.map||Nt,i=t.mapStream||en,s=Ad(r,t.dereference?r.stat:r.lstat,e,o,t.entries,t.sort),a=t.strict!==!1,l=typeof t.umask=="number"?~t.umask:~ja(),d=typeof t.dmode=="number"?t.dmode:0,u=typeof t.fmode=="number"?t.fmode:0,m=t.pack||Ra.pack(),f=t.finish||Nt;t.strip&&(n=Fa(n,t.strip)),t.readable&&(d|=parseInt(555,8),u|=parseInt(444,8)),t.writable&&(d|=parseInt(333,8),u|=parseInt(222,8));var p=function(w,g){r.readlink(Z.join(e,w),function(y,v){if(y)return m.destroy(y);g.linkname=Zo(v),m.entry(g,b)})},h=function(w,g,y){if(w)return m.destroy(w);if(!g)return t.finalize!==!1&&m.finalize(),f(m);if(y.isSocket())return b();var v={name:Zo(g),mode:(y.mode|(y.isDirectory()?d:u))&l,mtime:y.mtime,size:y.size,type:"file",uid:y.uid,gid:y.gid};if(y.isDirectory())return v.size=0,v.type="directory",v=n(v)||v,m.entry(v,b);if(y.isSymbolicLink())return v.size=0,v.type="symlink",v=n(v)||v,p(g,v);if(v=n(v)||v,!y.isFile())return a?m.destroy(new Error("unsupported type for "+g)):b();var S=m.entry(v,b);if(S){var P=i(r.createReadStream(Z.join(e,g),{start:0,end:v.size>0?v.size-1:v.size}),v);P.on("error",function(C){S.destroy(C)}),$a(P,S)}},b=function(w){if(w)return m.destroy(w);s(h)};return b(),m};var Fd=function(e){return e.length?e[e.length-1]:null},jd=function(){return process.getuid?process.getuid():-1},ja=function(){return process.umask?process.umask():0};tn.extract=function(e,t){e||(e="."),t||(t={});var r=t.fs||Aa,o=t.ignore||t.filter||Nt,n=t.map||Nt,i=t.mapStream||en,s=t.chown!==!1&&!jt&&jd()===0,a=t.extract||Ra.extract(),l=[],d=new Date,u=typeof t.umask=="number"?~t.umask:~ja(),m=typeof t.dmode=="number"?t.dmode:0,f=typeof t.fmode=="number"?t.fmode:0,p=t.strict!==!1;t.strip&&(n=Fa(n,t.strip)),t.readable&&(m|=parseInt(555,8),f|=parseInt(444,8)),t.writable&&(m|=parseInt(333,8),f|=parseInt(222,8));var h=function(g,y){for(var v;(v=Fd(l))&&g.slice(0,v[0].length)!==v[0];)l.pop();if(!v)return y();r.utimes(v[0],d,v[1],y)},b=function(g,y,v){if(t.utimes===!1)return v();if(y.type==="directory")return r.utimes(g,d,y.mtime,v);if(y.type==="symlink")return h(g,v);r.utimes(g,d,y.mtime,function(S){if(S)return v(S);h(g,v)})},w=function(g,y,v){var S=y.type==="symlink",P=S?r.lchmod:r.chmod,C=S?r.lchown:r.chown;if(!P)return v();var D=(y.mode|(y.type==="directory"?m:f))&u;C&&s?C.call(r,g,y.uid,y.gid,R):R(null);function R($){if($)return v($);if(!P)return v();P.call(r,g,D,v)}};return a.on("entry",function(g,y,v){g=n(g)||g,g.name=Zo(g.name);var S=Z.join(e,Z.join("/",g.name));if(o(S,g))return y.resume(),v();var P=function(I){if(I)return v(I);b(S,g,function(_){if(_)return v(_);if(jt)return v();w(S,g,v)})},C=function(){if(jt)return v();r.unlink(S,function(){var I=Z.resolve(Z.dirname(S),g.linkname);if(!_a(I,e))return v(new Error(S+" is not a valid symlink"));r.symlink(g.linkname,S,P)})},D=function(){if(jt)return v();r.unlink(S,function(){var I=Z.join(e,Z.join("/",g.linkname));r.realpath(I,function(_,L){if(_||!_a(L,e))return v(new Error(S+" is not a valid hardlink"));r.link(L,S,function(j){if(j&&j.code==="EPERM"&&t.hardlinkAsFilesFallback)return y=r.createReadStream(I),R();P(j)})})})},R=function(){var I=r.createWriteStream(S),_=i(y,g);I.on("error",function(L){_.destroy(L)}),$a(_,I,function(L){if(L)return v(L);I.on("close",P)})};if(g.type==="directory")return l.push([S,g.mtime]),Oa(S,{fs:r,own:s,uid:g.uid,gid:g.gid},P);var $=Z.dirname(S);Na(r,$,Z.join(e,"."),function(I,_){if(I)return v(I);if(!_)return v(new Error($+" is not a valid path"));Oa($,{fs:r,own:s,uid:g.uid,gid:g.gid},function(L){if(L)return v(L);switch(g.type){case"file":return R();case"link":return D();case"symlink":return C()}if(p)return v(new Error("unsupported type for "+S+" ("+g.type+")"));y.resume(),v()})})}),t.finish&&a.on("finish",t.finish),a};function Na(e,t,r,o){if(t===r)return o(null,!0);e.lstat(t,function(n,i){if(n&&n.code!=="ENOENT")return o(n);if(n||i.isDirectory())return Na(e,Z.join(t,".."),r,o);o(null,!1)})}function Oa(e,t,r){Rd(e,{fs:t.fs},function(o,n){!o&&n&&t.own?_d(n,t.uid,t.gid,r):r(o)})}function _a(e,t){return t=Z.resolve(t),t===e||e.startsWith(t+Z.sep)}});c();c();var xr=Q(ue(),1);c();c();var wr=[{name:"npm",lockfile:"package-lock.json",alternativeLockfiles:["npm-shrinkwrap.json"],installCommand:"npm ci"},{name:"yarn",lockfile:"yarn.lock",installCommand:"yarn install --frozen-lockfile"},{name:"pnpm",lockfile:"pnpm-lock.yaml",installCommand:"pnpm install --frozen-lockfile"},{name:"bun",lockfile:"bun.lockb",alternativeLockfiles:["bun.lock"],installCommand:"bun install --frozen-lockfile"}];function gl(e){let t="No lockfile found",r="If you don\u2019t commit a lockfile, then your app might install the wrong package versions when deploying. To avoid versioning issues, generate a new lockfile and commit it to your repository.",o=[["Generate a lockfile. Run",{command:"npm|yarn|pnpm install"}],"Commit the new file to your repository"];if(e)throw new E(t,r,o);Y({headline:t,body:r,nextSteps:o})}function yl(e,t){let r=e.map(({packageManager:s,foundLockfile:a})=>`${a} (created by ${s.name})`),o="Multiple lockfiles found",n=[`Your project contains more than one lockfile. This can cause version conflicts when installing and deploying your app. The following lockfiles were detected:
2
2
  `,{list:{items:r}}],i=["Delete any unneeded lockfiles","Commit the change to your repository"];if(t)throw new E(o,n,i);Y({headline:o,body:n,nextSteps:i})}function wl(e){let t="Lockfile ignored by Git",r="Your project\u2019s lockfile isn\u2019t being tracked by Git. If you don\u2019t commit a lockfile, then your app might install the wrong package versions when deploying.",o=[`In your project\u2019s .gitignore file, delete any references to ${e}`,"Commit the change to your repository"];Y({headline:t,body:r,nextSteps:o})}async function Ci(e,t=!1){if(Ie&&!process.env.SHOPIFY_UNIT_TEST)return;let r=[];for(let i of wr){let s=[i.lockfile,...i.alternativeLockfiles||[]];for(let a of s)if(await G(T(e,a))){r.push({packageManager:i,foundLockfile:a});break}}if(r.length===0)return gl(t);if(r.length>1)return yl(r,t);let o=r[0].foundLockfile;(await Rn(e,[o]).catch(()=>[])).length>0&&wl(o)}c();var vl=["^cdn/","^_t/"];function vr(e){let t=new Set;return Object.values(e.routes).filter(r=>vl.some(o=>new RegExp(o).test(r.path??""))).forEach(r=>{r.path&&t.add(r.path)}),[...t]}var bl=["","cart","products/:productHandle","collections","collections/:collectionHandle","sitemap.xml","robots.txt","pages/:pageHandle","policies/:policyHandle","search","account","account/login","account/orders/:orderId","account/authorize"];function br(e,t=bl){let r=Object.values(e.routes),o=new Set(t);for(let n of t)for(let i of r)if(!n&&!i.path)o.delete(n);else if(n&&i.path){let s={path:i.path,parentId:i.parentId};for(;s.parentId&&s.parentId!=="root";){let d=r.find(u=>u.id===s.parentId);if(!d)break;s.path=d.path==null?s.path:`${d.path}/${s.path}`,s.parentId=d.parentId}let a=":?[^\\/\\?]+\\?",l=`^(${a}\\/)?`+n.replaceAll(".","\\.").replace(/\//g,`\\/(${a}\\/)?`).replace(/:[^/)?]+/g,"(:[^\\/]+|\\*)")+`(\\/${a})?$`;new RegExp(l).test(s.path)&&o.delete(n)}return[...o]}var Le=100;function Ti(e){e.length?Y({headline:"Standard Shopify routes missing",body:`Your Hydrogen project is missing ${e.length} standard Shopify route${e.length>1?"s":""}.
3
3
  Including these routes improves compatibility with Shopify\u2019s platform:
4
4
 
@@ -249,7 +249,7 @@ Skip the flag or provide the name of a template or example in the Hydrogen repos
249
249
  }
250
250
  }
251
251
  }
252
- `;async function za(e){let{hydrogenStorefronts:t}=await ot(qd,e);return t.map(r=>({...r,parsedId:nt(r.id)}))}var Zr=class e extends O{static descriptionWithMarkdown="Lists all remote Hydrogen storefronts available to link to your local development environment.";static description="Returns a list of Hydrogen storefronts available on a given shop.";static flags={...k.path};async run(){let{flags:t}=await this.parse(e);await Yd(t)}};async function Yd({path:e=process.cwd()}){let{session:t}=await ge(e),r=await za(t);r.length>0?(te(),F(Jd({storefronts:r,shop:t.storeFqdn}).toString()),r.forEach(({currentProductionDeployment:o,id:n,productionUrl:i,title:s})=>{te(),F(W`${H.whiteBright(s)} ${H.dim(`(id: ${nt(n)})`)}`.value),i&&F(W` ${H.whiteBright(i)}`.value),o&&F(W` ${H.dim(zd(o))}`.value)})):B({headline:"Hydrogen storefronts",body:"There are no Hydrogen storefronts on your Shop.",nextSteps:[`Ensure you are logged in to the correct shop (currently: ${t.storeFqdn})`,`Create a new Hydrogen storefront: Run \`${await z(e)} link\` or visit ${bs(t)}`]})}var Wd=new Intl.DateTimeFormat("default",{year:"numeric",month:"numeric",day:"numeric"});function zd(e){let t="";if(!e)return t;if(t+=Wd.format(new Date(e.createdAt)),e.commitMessage){let r=e.commitMessage.split(/\n/)[0];t+=`, ${r}`}return t}var Jd=({storefronts:e,shop:t})=>Ut(e,r=>`Showing ${r.length} Hydrogen storefronts for the store ${t}`,r=>`Showing 1 Hydrogen storefront for the store ${t}`);c();var eo=class e extends O{static descriptionWithMarkdown="Logs in to the specified shop and saves the shop domain to the project.";static description="Login to your Shopify account.";static flags={...k.path,...k.shop};async run(){let{flags:t}=await this.parse(e);await Qd(t)}};async function Qd({path:e=process.cwd(),shop:t}){te(),ii(!0);let{config:r}=await ge(e,t??!0);li(r)}c();var to=class e extends O{static descriptionWithMarkdown="Log out from the current shop.";static description="Logout of your local session.";static flags={...k.path};async run(){let{flags:t}=await this.parse(e);await Kd(t)}};async function Kd({path:e=process.cwd()}){te(),await ai(e),N({body:"You are logged out from Shopify."})}c();var rn=Q(ue(),1);c();async function Ja(e){let{startWorkerdServer:t}=await import("./workerd-NAPS5TA7.js");return t(e)}var ro=class e extends O{static descriptionWithMarkdown="Runs a server in your local development environment that serves your Hydrogen app's production build. Requires running the [build](https://shopify.dev/docs/api/shopify-cli/hydrogen/hydrogen-build) command first.";static description="Runs a Hydrogen storefront in an Oxygen worker for production.";static flags={...k.path,...k.port,...k.env,...k.envBranch,...k.envFile,...k.inspectorPort,...k.debug,...k.verbose,build:rn.Flags.boolean({description:"Builds the app before starting the preview server."}),watch:rn.Flags.boolean({description:"Watches for changes and rebuilds the project.",dependsOn:["build"]}),...ve(k.entry,{entry:{dependsOn:["build"]}}),...ve(k.codegen,{codegen:{dependsOn:["build"]}})};async run(){let{flags:t}=await this.parse(e),r=t.path?T(t.path):process.cwd(),{close:o}=await Xd({...U(t),directory:r});He(async()=>{await o()})}};async function Xd({port:e,directory:t,env:r,envBranch:o,inspectorPort:n,debug:i,verbose:s,build:a=!1,watch:l=!1,codegen:d=!1,codegenConfigPath:u,entry:m,envFile:f}){process.env.NODE_ENV||(process.env.NODE_ENV=l?"development":"production"),s&&rr(),or()||it();let{root:p,buildPath:h,buildPathWorkerFile:b,buildPathClient:w}=xe(t),g=await rt(p);if(g)throw new E(Pe);let y,v=Tt(),P=a?await Je({...{directory:p,entry:m,disableRouteWarning:!1,lockfileCheck:!1,sourcemap:!0,bundleStats:!1,useCodegen:d,codegenConfigPath:u},watch:l,async onServerBuildFinish(){v.state==="pending"?v.resolve():F("\u{1F3D7}\uFE0F Project rebuilt. Reloading server..."),await y?.reload()}}):v.resolve();g||(b=(await he(p).catch(()=>null))?.serverOutFile??x(h,"server","index.js"));let{shop:C,storefront:D}=await tr(p),R=!!C&&!!D?.id,{allVariables:$,logInjectedVariables:I}=await hr({root:p,fetchRemote:R,envBranch:o,envHandle:r,envFile:f});e||(e=await pt(tt));let _=await pt(e+100);return await v.promise,I(),y=await Ja({root:p,appPort:e,assetsPort:_,env:$,buildPathClient:w,buildPathWorkerFile:b,inspectorPort:n,debug:i,watch:l}),y.showBanner({mode:"preview",headlinePrefix:l?"Watching for changes. ":""}),{async close(){await Promise.allSettled([y.close(),P?.close()])}}}c();var oo=class e extends O{static description="Scaffold routes and core functionality.";static flags={...k.path,...k.force,...k.markets,...k.shortcut,...ve(k.installDeps,{"install-deps":{default:!0}})};async run(){let{flags:t}=await this.parse(e),r=t.path?T(t.path):process.cwd();await Zd({...U(t),directory:r})}};async function Zd(e){let t=new Gt,{rootDirectory:r,appDirectory:o}=await Ne(e.directory),n=Ze(r),i=z(),s=Promise.resolve(),a=[{title:"Setting up project",task:async()=>{await s}}],l=e.markets?e.markets:await Xt({abortSignal:t.signal,extraChoices:{none:"Set up later"}}),d=l==="none"?void 0:l,{setupRoutes:u}=nr(t),m,f=await Mn(".."),[p,h]=await Promise.all([G(x(r,"tsconfig.json")),kt("*.d.ts",{cwd:f})]);s=s.then(()=>Promise.all([...h.map(y=>Bt(x(f,y),T(r,y))),ir({rootDirectory:r,appDirectory:o,typescript:p})])).then(async()=>{m=await u(r,p?"ts":"js",{i18nStrategy:d,overwriteFileDeps:!0})}),d&&(s=s.then(()=>Kt(d,{rootDirectory:r})));let b=await Promise.resolve(i),{createShortcut:w,showShortcutBanner:g}=await sr(t,b,e.shortcut);!d&&!w||(w&&(s=s.then(async()=>{await w()&&(b=Ye)}),g()),await ee(a),await st({location:n,name:n,directory:r},{cliCommand:b,depsInstalled:!0,packageManager:"npm",i18n:d,routes:m}))}c();var Qa=Q(ue(),1);var no=class e extends O{static descriptionWithMarkdown="Adds support for certain CSS strategies to your project.";static description="Setup CSS strategies for your project.";static flags={...k.path,...k.force,...ve(k.installDeps,{"install-deps":{default:!0}})};static args={strategy:Qa.Args.string({name:"strategy",description:`The CSS strategy to setup. One of ${ko.join()}`,options:ko})};async run(){let{flags:t,args:r}=await this.parse(e),o=t.path?T(t.path):process.cwd();await eu({...U(t),strategy:r.strategy,directory:o})}};async function eu({strategy:e,directory:t,force:r=!1,installDeps:o=!0}){let n=await he(t).catch(()=>null);if(!n)throw new E("No Vite config found. This command is only supported in Vite projects.");let{remixConfig:i}=n,s=e||await qn();if(s==="css-modules"||s==="postcss"){N({headline:`Vite works out of the box with ${xt[s]}.`,body:`See the Vite documentation for more information:
252
+ `;async function za(e){let{hydrogenStorefronts:t}=await ot(qd,e);return t.map(r=>({...r,parsedId:nt(r.id)}))}var Zr=class e extends O{static descriptionWithMarkdown="Lists all remote Hydrogen storefronts available to link to your local development environment.";static description="Returns a list of Hydrogen storefronts available on a given shop.";static flags={...k.path};async run(){let{flags:t}=await this.parse(e);await Yd(t)}};async function Yd({path:e=process.cwd()}){let{session:t}=await ge(e),r=await za(t);r.length>0?(te(),F(Jd({storefronts:r,shop:t.storeFqdn}).toString()),r.forEach(({currentProductionDeployment:o,id:n,productionUrl:i,title:s})=>{te(),F(W`${H.whiteBright(s)} ${H.dim(`(id: ${nt(n)})`)}`.value),i&&F(W` ${H.whiteBright(i)}`.value),o&&F(W` ${H.dim(zd(o))}`.value)})):B({headline:"Hydrogen storefronts",body:"There are no Hydrogen storefronts on your Shop.",nextSteps:[`Ensure you are logged in to the correct shop (currently: ${t.storeFqdn})`,`Create a new Hydrogen storefront: Run \`${await z(e)} link\` or visit ${bs(t)}`]})}var Wd=new Intl.DateTimeFormat("default",{year:"numeric",month:"numeric",day:"numeric"});function zd(e){let t="";if(!e)return t;if(t+=Wd.format(new Date(e.createdAt)),e.commitMessage){let r=e.commitMessage.split(/\n/)[0];t+=`, ${r}`}return t}var Jd=({storefronts:e,shop:t})=>Ut(e,r=>`Showing ${r.length} Hydrogen storefronts for the store ${t}`,r=>`Showing 1 Hydrogen storefront for the store ${t}`);c();var eo=class e extends O{static descriptionWithMarkdown="Logs in to the specified shop and saves the shop domain to the project.";static description="Login to your Shopify account.";static flags={...k.path,...k.shop};async run(){let{flags:t}=await this.parse(e);await Qd(t)}};async function Qd({path:e=process.cwd(),shop:t}){te(),ii(!0);let{config:r}=await ge(e,t??!0);li(r)}c();var to=class e extends O{static descriptionWithMarkdown="Log out from the current shop.";static description="Logout of your local session.";static flags={...k.path};async run(){let{flags:t}=await this.parse(e);await Kd(t)}};async function Kd({path:e=process.cwd()}){te(),await ai(e),N({body:"You are logged out from Shopify."})}c();var rn=Q(ue(),1);c();async function Ja(e){let{startWorkerdServer:t}=await import("./workerd-EHI5ZCEV.js");return t(e)}var ro=class e extends O{static descriptionWithMarkdown="Runs a server in your local development environment that serves your Hydrogen app's production build. Requires running the [build](https://shopify.dev/docs/api/shopify-cli/hydrogen/hydrogen-build) command first.";static description="Runs a Hydrogen storefront in an Oxygen worker for production.";static flags={...k.path,...k.port,...k.env,...k.envBranch,...k.envFile,...k.inspectorPort,...k.debug,...k.verbose,build:rn.Flags.boolean({description:"Builds the app before starting the preview server."}),watch:rn.Flags.boolean({description:"Watches for changes and rebuilds the project.",dependsOn:["build"]}),...ve(k.entry,{entry:{dependsOn:["build"]}}),...ve(k.codegen,{codegen:{dependsOn:["build"]}})};async run(){let{flags:t}=await this.parse(e),r=t.path?T(t.path):process.cwd(),{close:o}=await Xd({...U(t),directory:r});He(async()=>{await o()})}};async function Xd({port:e,directory:t,env:r,envBranch:o,inspectorPort:n,debug:i,verbose:s,build:a=!1,watch:l=!1,codegen:d=!1,codegenConfigPath:u,entry:m,envFile:f}){process.env.NODE_ENV||(process.env.NODE_ENV=l?"development":"production"),s&&rr(),or()||it();let{root:p,buildPath:h,buildPathWorkerFile:b,buildPathClient:w}=xe(t),g=await rt(p);if(g)throw new E(Pe);let y,v=Tt(),P=a?await Je({...{directory:p,entry:m,disableRouteWarning:!1,lockfileCheck:!1,sourcemap:!0,bundleStats:!1,useCodegen:d,codegenConfigPath:u},watch:l,async onServerBuildFinish(){v.state==="pending"?v.resolve():F("\u{1F3D7}\uFE0F Project rebuilt. Reloading server..."),await y?.reload()}}):v.resolve();g||(b=(await he(p).catch(()=>null))?.serverOutFile??x(h,"server","index.js"));let{shop:C,storefront:D}=await tr(p),R=!!C&&!!D?.id,{allVariables:$,logInjectedVariables:I}=await hr({root:p,fetchRemote:R,envBranch:o,envHandle:r,envFile:f});e||(e=await pt(tt));let _=await pt(e+100);return await v.promise,I(),y=await Ja({root:p,appPort:e,assetsPort:_,env:$,buildPathClient:w,buildPathWorkerFile:b,inspectorPort:n,debug:i,watch:l}),y.showBanner({mode:"preview",headlinePrefix:l?"Watching for changes. ":""}),{async close(){await Promise.allSettled([y.close(),P?.close()])}}}c();var oo=class e extends O{static description="Scaffold routes and core functionality.";static flags={...k.path,...k.force,...k.markets,...k.shortcut,...ve(k.installDeps,{"install-deps":{default:!0}})};async run(){let{flags:t}=await this.parse(e),r=t.path?T(t.path):process.cwd();await Zd({...U(t),directory:r})}};async function Zd(e){let t=new Gt,{rootDirectory:r,appDirectory:o}=await Ne(e.directory),n=Ze(r),i=z(),s=Promise.resolve(),a=[{title:"Setting up project",task:async()=>{await s}}],l=e.markets?e.markets:await Xt({abortSignal:t.signal,extraChoices:{none:"Set up later"}}),d=l==="none"?void 0:l,{setupRoutes:u}=nr(t),m,f=await Mn(".."),[p,h]=await Promise.all([G(x(r,"tsconfig.json")),kt("*.d.ts",{cwd:f})]);s=s.then(()=>Promise.all([...h.map(y=>Bt(x(f,y),T(r,y))),ir({rootDirectory:r,appDirectory:o,typescript:p})])).then(async()=>{m=await u(r,p?"ts":"js",{i18nStrategy:d,overwriteFileDeps:!0})}),d&&(s=s.then(()=>Kt(d,{rootDirectory:r})));let b=await Promise.resolve(i),{createShortcut:w,showShortcutBanner:g}=await sr(t,b,e.shortcut);!d&&!w||(w&&(s=s.then(async()=>{await w()&&(b=Ye)}),g()),await ee(a),await st({location:n,name:n,directory:r},{cliCommand:b,depsInstalled:!0,packageManager:"npm",i18n:d,routes:m}))}c();var Qa=Q(ue(),1);var no=class e extends O{static descriptionWithMarkdown="Adds support for certain CSS strategies to your project.";static description="Setup CSS strategies for your project.";static flags={...k.path,...k.force,...ve(k.installDeps,{"install-deps":{default:!0}})};static args={strategy:Qa.Args.string({name:"strategy",description:`The CSS strategy to setup. One of ${ko.join()}`,options:ko})};async run(){let{flags:t,args:r}=await this.parse(e),o=t.path?T(t.path):process.cwd();await eu({...U(t),strategy:r.strategy,directory:o})}};async function eu({strategy:e,directory:t,force:r=!1,installDeps:o=!0}){let n=await he(t).catch(()=>null);if(!n)throw new E("No Vite config found. This command is only supported in Vite projects.");let{remixConfig:i}=n,s=e||await qn();if(s==="css-modules"||s==="postcss"){N({headline:`Vite works out of the box with ${xt[s]}.`,body:`See the Vite documentation for more information:
253
253
  ${So[s]}`});return}let a=await Gn(s,i,r);if(!a)return;let{workPromise:l,generatedAssets:d,needsInstallDeps:u}=a,m=[{title:"Updating files",task:async()=>{await l}}],f=!1;if(o&&u){let p=Ee(i.rootDirectory);m.push({title:"Installing new dependencies",task:async()=>{let h=await p;f=h==="npm"||h==="unknown",await qt({directory:i.rootDirectory,packageManager:h,args:[]})}})}await ee(m),N({headline:`${xt[s]} setup complete.`,body:(d.length>0?`You can now modify CSS configuration in the following files:
254
254
  `+d.map(p=>` - ${p}`).join(`
255
255
  `)+`
@@ -1 +1 @@
1
- import{h as l}from"./chunk-4JY2P2A5.js";import{S as c}from"./chunk-YN6A26QL.js";import{h as u}from"./chunk-R2R6JDNH.js";import{g as i}from"./chunk-VKWPEFWQ.js";i();var s=["live","unpublished","development"];async function x(e,r){let t=await c(e,r);return p(t)}async function p(e){let r=e.storeFqdn,t=(await l(e)).filter(d);if(t.length===0)throw new u(`There are no themes in the ${r} store`);return t.sort(w)}function d(e){return s.includes(e.role)}function w(e,r){return s.indexOf(e.role)-s.indexOf(r.role)}i();function b(e,r,t){return y(e,r,t)??T(e,r,t)}function y(e,r,t){let o=t.role;if(!o)return;let n=`No themes on the store ${e} match the role "${o}"`;return m(r,h=>h.role===o).orThrow(n)}function T(e,r,t){return t.themeIdentifiers.flatMap(n=>{let h=`No themes on the store ${e} match the ID or name "${n}"`;return m(r,f=>`${f.id}`===n||f.name.toLowerCase()===n.toLowerCase()?!0:L(f.name.toLowerCase(),n.toLowerCase())).orThrow(h)})}function m(e,r){let t=e.filter(r);return t.length>0?{orThrow:o=>t}:{orThrow:o=>{throw new u(o)}}}var a=class{queryProps;constructor(r){this.queryProps=r}get role(){for(let r of s)if(this.queryProps[r])return r}get themeIdentifiers(){return[this.queryProps.theme,this.queryProps.themes].flat().filter(t=>!!t)}any(){return Object.values(this.queryProps).some(r=>r?.length!==void 0?r.length>0:!!r)}};function L(e,r){let t=r.replace(/(^\*)|(\*$)/g,"");return r.startsWith("*")&&r.endsWith("*")?e.includes(t):r.startsWith("*")?e.endsWith(t):r.endsWith("*")?e.startsWith(t):!1}export{s as a,x as b,p as c,b as d,a as e};
1
+ import{h as l}from"./chunk-K63FW7Q7.js";import{S as c}from"./chunk-PK73ZSND.js";import{h as u}from"./chunk-BI7LE6CZ.js";import{g as i}from"./chunk-VKWPEFWQ.js";i();var s=["live","unpublished","development"];async function x(e,r){let t=await c(e,r);return p(t)}async function p(e){let r=e.storeFqdn,t=(await l(e)).filter(d);if(t.length===0)throw new u(`There are no themes in the ${r} store`);return t.sort(w)}function d(e){return s.includes(e.role)}function w(e,r){return s.indexOf(e.role)-s.indexOf(r.role)}i();function b(e,r,t){return y(e,r,t)??T(e,r,t)}function y(e,r,t){let o=t.role;if(!o)return;let n=`No themes on the store ${e} match the role "${o}"`;return m(r,h=>h.role===o).orThrow(n)}function T(e,r,t){return t.themeIdentifiers.flatMap(n=>{let h=`No themes on the store ${e} match the ID or name "${n}"`;return m(r,f=>`${f.id}`===n||f.name.toLowerCase()===n.toLowerCase()?!0:L(f.name.toLowerCase(),n.toLowerCase())).orThrow(h)})}function m(e,r){let t=e.filter(r);return t.length>0?{orThrow:o=>t}:{orThrow:o=>{throw new u(o)}}}var a=class{queryProps;constructor(r){this.queryProps=r}get role(){for(let r of s)if(this.queryProps[r])return r}get themeIdentifiers(){return[this.queryProps.theme,this.queryProps.themes].flat().filter(t=>!!t)}any(){return Object.values(this.queryProps).some(r=>r?.length!==void 0?r.length>0:!!r)}};function L(e,r){let t=r.replace(/(^\*)|(\*$)/g,"");return r.startsWith("*")&&r.endsWith("*")?e.includes(t):r.startsWith("*")?e.endsWith(t):r.endsWith("*")?e.startsWith(t):!1}export{s as a,x as b,p as c,b as d,a as e};
@@ -1 +1 @@
1
- import{a as I}from"./chunk-CTNBSUVU.js";import{b as l}from"./chunk-DPNZWBT5.js";import{a as c}from"./chunk-JD5P5RAJ.js";import{e as h,g as s}from"./chunk-VKWPEFWQ.js";s();s();import{fileURLToPath as L}from"node:url";async function m(e){let{isDevelopment:o}=await import("./local-GX5AN6ZS.js"),{ShopifyConfig:n}=await import("./custom-oclif-loader-BWAMUFQ4.js"),t=await import("./lib-2BR2WN7L.js"),{run:i,flush:p,Errors:d,settings:f}=t.default??t;o()&&(f.debug=!0);try{let r=new n({root:L(e.moduleURL)});await r.load(),e.lazyCommandLoader&&r.setLazyCommandLoader(e.lazyCommandLoader),await i(e.argv,r),await p()}catch(r){let{errorHandler:u}=await import("./error-handler-FDCH72NH.js");return await u(r),d.handle(r)}}var a=h(I());async function C(e=process.versions){let o=e.node,n=Number(o.split(".")[0]);if(n<22){let{renderError:i}=await import("./ui-VYWSLAQ6.js");i({headline:"Upgrade to a supported Node version now.",body:[`Node ${n} has reached end-of-life and poses security risks. When you upgrade to a`,{link:{url:"https://nodejs.dev/en/about/previous-releases",label:"supported version"}},{char:","},"you'll be able to use Shopify CLI without interruption."]}),process.exit(1)}}function y(e,o=process.argv,n=process.env){o.includes("--verbose")&&(n.DEBUG=n.DEBUG??"*"),e.development&&(n.SHOPIFY_CLI_ENV=n.SHOPIFY_CLI_ENV??"development")}function b(e=process.argv,o=process.env){(e.includes("--no-color")||e.includes("--json")||e.includes("-j")||c(o.NO_COLOR)||c(o.SHOPIFY_FLAG_NO_COLOR)||c(o[l.json])||o.TERM==="dumb")&&(o.FORCE_COLOR="0")}async function F(e,o=m,n=process.argv,t=process.env,i=process.versions){return y(e,n,t),e.runInCreateMode&&await g(e,n),b(n,t),await C(i),o({moduleURL:e.moduleURL,lazyCommandLoader:e.lazyCommandLoader})}async function g(e,o=process.argv){let{findUpAndReadPackageJson:n}=await import("./node-package-manager-3WIYU7Y3.js"),{moduleDirectory:t}=await import("./path-MBXP7ZIC.js"),d=(await n(t(e.moduleURL))).content.name.replace("@shopify/create-","");if(o.findIndex(r=>r.includes("init"))===-1){let r=o.findIndex(u=>u.match(new RegExp(`bin(\\/|\\\\)+(create-${d}|dev|run)`)))+1;o.splice(r,0,"init")}}var R={"no-color":a.Flags.boolean({hidden:!1,description:"Disable color output.",env:"SHOPIFY_FLAG_NO_COLOR"}),verbose:a.Flags.boolean({hidden:!1,description:"Increase the verbosity of the output. May include sensitive data.",env:"SHOPIFY_FLAG_VERBOSE"})},S={json:a.Flags.boolean({char:"j",description:"Output the result as JSON. Automatically disables color output.",hidden:!1,default:!1,env:l.json})},E={"auth-alias":a.Flags.string({description:"Alias of the Shopify account to use for authentication.",env:"SHOPIFY_FLAG_AUTH_ALIAS"})},A=(e={})=>{let o=[e.description,"Must be between 1 and 65535."].filter(Boolean).join(" ");return a.Flags.integer({min:1,max:65535,...e,description:o})};function j(e){let o=e.description?.trimEnd(),t=[o&&!o.endsWith(".")?`${o}.`:o,"Required if non interactive."].filter(Boolean).join(" ");return{...e,description:t,requiredIfNonInteractive:!0}}async function U(){let{cacheClear:e}=await import("./conf-store-OAGJBITE.js");e()}export{F as a,R as b,S as c,E as d,A as e,j as f,U as g};
1
+ import{a as I}from"./chunk-CTNBSUVU.js";import{b as l}from"./chunk-DPNZWBT5.js";import{a as c}from"./chunk-JD5P5RAJ.js";import{e as h,g as s}from"./chunk-VKWPEFWQ.js";s();s();import{fileURLToPath as L}from"node:url";async function m(e){let{isDevelopment:o}=await import("./local-HF4T3FFE.js"),{ShopifyConfig:n}=await import("./custom-oclif-loader-BWAMUFQ4.js"),t=await import("./lib-2BR2WN7L.js"),{run:i,flush:p,Errors:d,settings:f}=t.default??t;o()&&(f.debug=!0);try{let r=new n({root:L(e.moduleURL)});await r.load(),e.lazyCommandLoader&&r.setLazyCommandLoader(e.lazyCommandLoader),await i(e.argv,r),await p()}catch(r){let{errorHandler:u}=await import("./error-handler-XFH47Y75.js");return await u(r),d.handle(r)}}var a=h(I());async function C(e=process.versions){let o=e.node,n=Number(o.split(".")[0]);if(n<22){let{renderError:i}=await import("./ui-7TVGGEWJ.js");i({headline:"Upgrade to a supported Node version now.",body:[`Node ${n} has reached end-of-life and poses security risks. When you upgrade to a`,{link:{url:"https://nodejs.dev/en/about/previous-releases",label:"supported version"}},{char:","},"you'll be able to use Shopify CLI without interruption."]}),process.exit(1)}}function y(e,o=process.argv,n=process.env){o.includes("--verbose")&&(n.DEBUG=n.DEBUG??"*"),e.development&&(n.SHOPIFY_CLI_ENV=n.SHOPIFY_CLI_ENV??"development")}function b(e=process.argv,o=process.env){(e.includes("--no-color")||e.includes("--json")||e.includes("-j")||c(o.NO_COLOR)||c(o.SHOPIFY_FLAG_NO_COLOR)||c(o[l.json])||o.TERM==="dumb")&&(o.FORCE_COLOR="0")}async function F(e,o=m,n=process.argv,t=process.env,i=process.versions){return y(e,n,t),e.runInCreateMode&&await g(e,n),b(n,t),await C(i),o({moduleURL:e.moduleURL,lazyCommandLoader:e.lazyCommandLoader})}async function g(e,o=process.argv){let{findUpAndReadPackageJson:n}=await import("./node-package-manager-CVEU22N7.js"),{moduleDirectory:t}=await import("./path-MBXP7ZIC.js"),d=(await n(t(e.moduleURL))).content.name.replace("@shopify/create-","");if(o.findIndex(r=>r.includes("init"))===-1){let r=o.findIndex(u=>u.match(new RegExp(`bin(\\/|\\\\)+(create-${d}|dev|run)`)))+1;o.splice(r,0,"init")}}var R={"no-color":a.Flags.boolean({hidden:!1,description:"Disable color output.",env:"SHOPIFY_FLAG_NO_COLOR"}),verbose:a.Flags.boolean({hidden:!1,description:"Increase the verbosity of the output. May include sensitive data.",env:"SHOPIFY_FLAG_VERBOSE"})},S={json:a.Flags.boolean({char:"j",description:"Output the result as JSON. Automatically disables color output.",hidden:!1,default:!1,env:l.json})},E={"auth-alias":a.Flags.string({description:"Alias of the Shopify account to use for authentication.",env:"SHOPIFY_FLAG_AUTH_ALIAS"})},A=(e={})=>{let o=[e.description,"Must be between 1 and 65535."].filter(Boolean).join(" ");return a.Flags.integer({min:1,max:65535,...e,description:o})};function j(e){let o=e.description?.trimEnd(),t=[o&&!o.endsWith(".")?`${o}.`:o,"Required if non interactive."].filter(Boolean).join(" ");return{...e,description:t,requiredIfNonInteractive:!0}}async function U(){let{cacheClear:e}=await import("./conf-store-QQ4DOFI3.js");e()}export{F as a,R as b,S as c,E as d,A as e,j as f,U as g};
@@ -1,4 +1,4 @@
1
- import{A as n,B as i,C as t,G as s,y as e,z as o}from"./chunk-GMTNOCMS.js";import{h as d,k as l}from"./chunk-R2R6JDNH.js";import{g as r}from"./chunk-VKWPEFWQ.js";r();async function u(){e({headline:"CLI update available.",body:["Run",{command:"npm run shopify upgrade"},{char:"."}]}),e({headline:["To connect this project to your shopify store cd into:",{filePath:"/my-store/hydrogen.config.js"},{char:"."}],body:["You can also try the following steps:",{list:{items:[["Run",{command:"shopify project connect"}],["Run",{command:"hydrogen start"}]]}}]}),e({headline:"About your app.",customSections:[{body:{tabularData:[["Configuration file",{filePath:"shopify.app.scalable-transaction-app.toml"}],["App name",{userInput:"scalable-transaction-app"}],["Access scopes","read_products,write_products"]],firstColumnSubdued:!0}}]}),e({headline:[{userInput:"my-app"},"initialized and ready to build."],nextSteps:[["Run",{command:"cd verification-app"}],["To preview your project, run",{command:"npm app dev"}],["To add extensions, run",{command:"npm generate extension"}]],reference:[["Run",{command:"npm shopify help"}],{link:{label:"Dev docs",url:"https://shopify.dev"}}],customSections:[{title:"Custom section",body:{list:{items:[{link:{label:"Item 1",url:"https://shopify.com"}},"Item 2",{link:{url:"https://community.shopify.com/"}}]}}},{title:"Custom section 2",body:{list:{items:["Item 1","Item 2","Item 3"]}}}]}),o({headline:"CLI updated.",body:"You are now running version 3.47."}),o({headline:"Deployment successful.",body:"Your extensions have been uploaded to your Shopify Partners Dashboard.",nextSteps:[{link:{label:"See your deployment and set it live",url:"https://partners.shopify.com/1797046/apps/4523695/deployments"}}]}),n({headline:"You have reached your limit of checkout extensions for this app.",body:"You can free up space for a new one by deleting an existing one."}),n({headline:"Required access scope update.",body:"The deadline for re-selecting your app scopes is May 1, 2022.",reference:[{link:{label:"Dev docs",url:"https://shopify.dev/app/scopes"}}]});let a=new l("Something went wrong.");a.stack=`
1
+ import{A as n,B as i,C as t,G as s,y as e,z as o}from"./chunk-WSCSFFLH.js";import{h as d,k as l}from"./chunk-BI7LE6CZ.js";import{g as r}from"./chunk-VKWPEFWQ.js";r();async function u(){e({headline:"CLI update available.",body:["Run",{command:"npm run shopify upgrade"},{char:"."}]}),e({headline:["To connect this project to your shopify store cd into:",{filePath:"/my-store/hydrogen.config.js"},{char:"."}],body:["You can also try the following steps:",{list:{items:[["Run",{command:"shopify project connect"}],["Run",{command:"hydrogen start"}]]}}]}),e({headline:"About your app.",customSections:[{body:{tabularData:[["Configuration file",{filePath:"shopify.app.scalable-transaction-app.toml"}],["App name",{userInput:"scalable-transaction-app"}],["Access scopes","read_products,write_products"]],firstColumnSubdued:!0}}]}),e({headline:[{userInput:"my-app"},"initialized and ready to build."],nextSteps:[["Run",{command:"cd verification-app"}],["To preview your project, run",{command:"npm app dev"}],["To add extensions, run",{command:"npm generate extension"}]],reference:[["Run",{command:"npm shopify help"}],{link:{label:"Dev docs",url:"https://shopify.dev"}}],customSections:[{title:"Custom section",body:{list:{items:[{link:{label:"Item 1",url:"https://shopify.com"}},"Item 2",{link:{url:"https://community.shopify.com/"}}]}}},{title:"Custom section 2",body:{list:{items:["Item 1","Item 2","Item 3"]}}}]}),o({headline:"CLI updated.",body:"You are now running version 3.47."}),o({headline:"Deployment successful.",body:"Your extensions have been uploaded to your Shopify Partners Dashboard.",nextSteps:[{link:{label:"See your deployment and set it live",url:"https://partners.shopify.com/1797046/apps/4523695/deployments"}}]}),n({headline:"You have reached your limit of checkout extensions for this app.",body:"You can free up space for a new one by deleting an existing one."}),n({headline:"Required access scope update.",body:"The deadline for re-selecting your app scopes is May 1, 2022.",reference:[{link:{label:"Dev docs",url:"https://shopify.dev/app/scopes"}}]});let a=new l("Something went wrong.");a.stack=`
2
2
  Error: Unexpected error
3
3
  at Module._compile (internal/modules/cjs/loader.js:1137:30)
4
4
  at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
@@ -1 +1 @@
1
- import{a as d,b as f,c as g,d as x,g as C}from"./chunk-V5SC2RYQ.js";import{a as c}from"./chunk-NEMPLS7C.js";import{a as l}from"./chunk-KUNDCAQN.js";import{sa as m}from"./chunk-ACTDYTAV.js";import{b as p}from"./chunk-JJJTPEMD.js";import{z as s}from"./chunk-GMTNOCMS.js";import{a as I}from"./chunk-CTNBSUVU.js";import{e as y,g as r}from"./chunk-VKWPEFWQ.js";r();var h=y(I(),1);var o=class u extends c{static description="Import dashboard-managed extensions into your app.";static flags={...p,...l,"client-id":h.Flags.string({hidden:!1,description:"The Client ID of your app.",env:"SHOPIFY_FLAG_CLIENT_ID",exclusive:["config"]})};async run(){let{flags:i}=await this.parse(u),e=await m({directory:i.path,clientId:i["client-id"],forceRelink:i.reset,userProvidedConfigName:i.config}),t=await C({developerPlatformClient:e.developerPlatformClient,apiKey:e.remoteApp.apiKey,organizationId:e.remoteApp.organizationId,extensionTypes:g}),n=d(t);if(n.length===0)s({headline:["No extensions to migrate."]});else{let a=await f(n);await x({...e,extensions:t,extensionTypes:a.extensionTypes,buildExtensionConfig:a.buildExtensionConfig})}return{app:e.app}}};export{o as a};
1
+ import{a as d,b as f,c as g,d as x,g as C}from"./chunk-6AV6GX5W.js";import{a as c}from"./chunk-ESPT6CGE.js";import{a as l}from"./chunk-RA3WWB2S.js";import{sa as m}from"./chunk-GFWXVO72.js";import{b as p}from"./chunk-IX4IGE5H.js";import{z as s}from"./chunk-WSCSFFLH.js";import{a as I}from"./chunk-CTNBSUVU.js";import{e as y,g as r}from"./chunk-VKWPEFWQ.js";r();var h=y(I(),1);var o=class u extends c{static description="Import dashboard-managed extensions into your app.";static flags={...p,...l,"client-id":h.Flags.string({hidden:!1,description:"The Client ID of your app.",env:"SHOPIFY_FLAG_CLIENT_ID",exclusive:["config"]})};async run(){let{flags:i}=await this.parse(u),e=await m({directory:i.path,clientId:i["client-id"],forceRelink:i.reset,userProvidedConfigName:i.config}),t=await C({developerPlatformClient:e.developerPlatformClient,apiKey:e.remoteApp.apiKey,organizationId:e.remoteApp.organizationId,extensionTypes:g}),n=d(t);if(n.length===0)s({headline:["No extensions to migrate."]});else{let a=await f(n);await x({...e,extensions:t,extensionTypes:a.extensionTypes,buildExtensionConfig:a.buildExtensionConfig})}return{app:e.app}}};export{o as a};
@@ -1 +1 @@
1
- import{a as u}from"./chunk-U2Z5NMXV.js";import{g as d}from"./chunk-VKWPEFWQ.js";d();var m=!1;function v(){return m}function y(){let t=0,e=!1,i=setInterval(()=>{if(!e){if(v()||t>=12e4){e=!0,clearInterval(i),u(process.pid,"SIGINT",!1,()=>{process.exit(0)});return}t+=100}},100)}var k=async({config:a,Command:o})=>{await I(o);let t=await import("./metadata-XUJUTBTB.js"),{commandStartOptions:e}=t.getAllSensitiveMetadata();e&&await t.addSensitiveMetadata(()=>({commandStartOptions:{...e,endTime:new Date().getTime()}}));let{postrun:i}=await import("./deprecations-K3NPRKBF.js");i(o);let{outputDebug:n}=await import("./output-X47P6ICP.js"),r=o.id.replace(/:/g," ");n(`Completed command ${r}`),!r.includes("notifications")&&!r.includes("upgrade")&&!r.includes("send-analytics")&&await M();let{reportAnalyticsEvent:c}=await import("./analytics-6LI5GLWS.js");await c({config:a,exitMode:"ok"}),m=!0};async function M(){let{versionToAutoUpgrade:a,warnIfUpgradeAvailable:o}=await import("./upgrade-PFQ7JMXG.js"),t=a();if(!t){await o();return}if(process.env.SHOPIFY_CLI_FORCE_AUTO_UPGRADE==="1")await l(t);else{let{runAtMinimumInterval:i}=await import("./conf-store-OAGJBITE.js");await i("auto-upgrade",{days:1},async()=>{await l(t)})}}async function l(a){let[{CLI_KIT_VERSION:o},{isMajorVersionChange:t},{outputWarn:e,outputDebug:i},{getOutputUpdateCLIReminder:n,runCLIUpgrade:r,hasBlockingAutoUpgradeNotification:c},s]=await Promise.all([import("./version-U4GM2LNG.js"),import("./version-FK4ETQ22.js"),import("./output-X47P6ICP.js"),import("./upgrade-PFQ7JMXG.js"),import("./metadata-XUJUTBTB.js")]);if(t(o,a)){e(n(a,!0)),await s.addPublicMetadata(()=>({env_auto_upgrade_skipped_reason:"major_version"}));return}if(await c()){await s.addPublicMetadata(()=>({env_auto_upgrade_skipped_reason:"blocked_by_notification"}));return}try{await r({autoupgrade:!0}),await s.addPublicMetadata(()=>({env_auto_upgrade_success:!0}))}catch(f){let p=`Auto-upgrade failed: ${f}`;i(p),e(n(a)),await s.addPublicMetadata(()=>({env_auto_upgrade_success:!1}));let[{sendErrorToBugsnag:g},{inferPackageManagerForGlobalCLI:w}]=await Promise.all([import("./error-handler-FDCH72NH.js"),import("./is-global-V5VORI3F.js")]),_=Object.assign(new Error(p),{packageManager:w(),platform:process.platform,cliVersion:o});await g(_,"expected_error")}}async function I(a){let o=new Date().getTime();if(a&&"analyticsStopCommand"in a&&typeof a.analyticsStopCommand=="function"){let t=a.analyticsStopCommand();if(t){let e=await import("./metadata-XUJUTBTB.js"),{commandStartOptions:i}=e.getAllSensitiveMetadata();if(!i)return;await e.addSensitiveMetadata(()=>({commandStartOptions:{...i,startTime:o,startCommand:t}}))}}}export{y as a,k as b};
1
+ import{a as u}from"./chunk-LBREJXT6.js";import{g as d}from"./chunk-VKWPEFWQ.js";d();var m=!1;function v(){return m}function y(){let t=0,e=!1,i=setInterval(()=>{if(!e){if(v()||t>=12e4){e=!0,clearInterval(i),u(process.pid,"SIGINT",!1,()=>{process.exit(0)});return}t+=100}},100)}var k=async({config:a,Command:o})=>{await I(o);let t=await import("./metadata-CSQPNQP2.js"),{commandStartOptions:e}=t.getAllSensitiveMetadata();e&&await t.addSensitiveMetadata(()=>({commandStartOptions:{...e,endTime:new Date().getTime()}}));let{postrun:i}=await import("./deprecations-43ZQ5RCE.js");i(o);let{outputDebug:n}=await import("./output-E6OGPGXL.js"),r=o.id.replace(/:/g," ");n(`Completed command ${r}`),!r.includes("notifications")&&!r.includes("upgrade")&&!r.includes("send-analytics")&&await M();let{reportAnalyticsEvent:c}=await import("./analytics-F56E2NGH.js");await c({config:a,exitMode:"ok"}),m=!0};async function M(){let{versionToAutoUpgrade:a,warnIfUpgradeAvailable:o}=await import("./upgrade-F77O4ZDT.js"),t=a();if(!t){await o();return}if(process.env.SHOPIFY_CLI_FORCE_AUTO_UPGRADE==="1")await l(t);else{let{runAtMinimumInterval:i}=await import("./conf-store-QQ4DOFI3.js");await i("auto-upgrade",{days:1},async()=>{await l(t)})}}async function l(a){let[{CLI_KIT_VERSION:o},{isMajorVersionChange:t},{outputWarn:e,outputDebug:i},{getOutputUpdateCLIReminder:n,runCLIUpgrade:r,hasBlockingAutoUpgradeNotification:c},s]=await Promise.all([import("./version-3L3ANUTL.js"),import("./version-DL4Y6DRX.js"),import("./output-E6OGPGXL.js"),import("./upgrade-F77O4ZDT.js"),import("./metadata-CSQPNQP2.js")]);if(t(o,a)){e(n(a,!0)),await s.addPublicMetadata(()=>({env_auto_upgrade_skipped_reason:"major_version"}));return}if(await c()){await s.addPublicMetadata(()=>({env_auto_upgrade_skipped_reason:"blocked_by_notification"}));return}try{await r({autoupgrade:!0}),await s.addPublicMetadata(()=>({env_auto_upgrade_success:!0}))}catch(f){let p=`Auto-upgrade failed: ${f}`;i(p),e(n(a)),await s.addPublicMetadata(()=>({env_auto_upgrade_success:!1}));let[{sendErrorToBugsnag:g},{inferPackageManagerForGlobalCLI:w}]=await Promise.all([import("./error-handler-XFH47Y75.js"),import("./is-global-WBIBPIVZ.js")]),_=Object.assign(new Error(p),{packageManager:w(),platform:process.platform,cliVersion:o});await g(_,"expected_error")}}async function I(a){let o=new Date().getTime();if(a&&"analyticsStopCommand"in a&&typeof a.analyticsStopCommand=="function"){let t=a.analyticsStopCommand();if(t){let e=await import("./metadata-CSQPNQP2.js"),{commandStartOptions:i}=e.getAllSensitiveMetadata();if(!i)return;await e.addSensitiveMetadata(()=>({commandStartOptions:{...i,startTime:o,startCommand:t}}))}}}export{y as a,k as b};
@@ -1 +1 @@
1
- import{H as m,I as d,x as c}from"./chunk-GMTNOCMS.js";import{pb as w,qb as n,sb as a}from"./chunk-Y34LWI3S.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{H as m,I as d,x as c}from"./chunk-WSCSFFLH.js";import{pb as w,qb as n,sb as a}from"./chunk-HQUWYKSJ.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,3 +1,3 @@
1
- import{b as R}from"./chunk-J3JPJCWP.js";import{a as O}from"./chunk-CZPGC2E7.js";import{a as M}from"./chunk-DQCIORGH.js";import{a as x,l as H,n as Y}from"./chunk-MLZLDL6B.js";import{a as U}from"./chunk-QPWMD2VR.js";import{a as G,c as p}from"./chunk-KOVAFUYN.js";import{a as S,b as L}from"./chunk-YY6TFARF.js";import{k as A,n as I}from"./chunk-4JY2P2A5.js";import{p as D,q as E,r as P,u as _,v as C}from"./chunk-OORWOTAP.js";import{h as $,k as V}from"./chunk-ZSFAURIH.js";import{b}from"./chunk-JJJTPEMD.js";import{S as g,wa as m}from"./chunk-YN6A26QL.js";import{H as F,z as k}from"./chunk-GMTNOCMS.js";import{a as z}from"./chunk-CTNBSUVU.js";import{Wa as T}from"./chunk-Y34LWI3S.js";import{q as f}from"./chunk-773TIA5M.js";import{e as j,g as c}from"./chunk-VKWPEFWQ.js";c();c();c();async function B(e,t,o,n,r,l){let i=Q(o,n,r),a=X(o,e,n,t),s=[...i,...a,{title:"Theme download complete",task:async()=>{}}];s.length>0&&await F(s,{renderOptions:{stdout:l?.stdout??process.stdout},noProgressBar:r.multiEnvironment})}function Q(e,t,o){if(o.nodelete)return[];let n=new Set(e.map(i=>i.key));return t.applyIgnoreFilters([...t.files.values()]).map(({key:i})=>i).filter(i=>!n.has(i)).map(i=>({title:`Cleaning your local directory (removing ${i})`,task:async()=>t.delete(i)}))}function X(e,t,o,n){let r=o.applyIgnoreFilters(e);r=r.filter(s=>{let h=s.checksum;return o.files.get(s.key)?.checksum!==h});let l=r.map(s=>s.key),i=s=>s.total===0?"[100%]":`[${Math.round(s.current/s.total*100)}%]`;return R(l,_,(s,h)=>({title:`Downloading files from remote theme ${i({current:h,total:l.length})}`,task:async()=>J(t,o,s,n)}))}async function J(e,t,o,n){let r=await A(e.id,o,n);r&&await Promise.all(r.map(l=>t.write(l)))}async function K(e,t,o,n){m("theme-service:pull:setup"),U({verbose:e.verbose,noColor:e.noColor});let r=t??await g(P({store:e.store}),e.password),l=new O(r),i=await(e.development?l.find():l.fetch()),{path:a,nodelete:s,live:h,development:u,only:q,ignore:N,force:y,environment:w}=e;if(!await te(a??f(),y??!1,w?.[0],o))return;let W=await M(r,{header:"Select a theme to open",filter:{live:h,theme:u?`${i?.id}`:e.theme}});m("theme-service:pull:setup"),await Z(W,r,{environment:w?.[0],force:y??!1,ignore:N??[],multiEnvironment:o,nodelete:s??!1,only:q??[],path:a??f()},n)}async function Z(e,t,o,n){m("theme-service:pull:file-system");let r=H(o.path,{filters:o}),[l]=await Promise.all([I(e.id,t),r.ready()]),i=x(l);m("theme-service:pull:file-system"),await B(e,t,i,r,o,n);let a=o.environment?`Environment: ${o.environment}`:"";k({headline:a,body:["The theme",...G(e),"has been pulled."],nextSteps:[[{link:{label:"View your theme",url:S(e,t)}}],[{link:{label:"Customize your theme at the theme editor",url:L(e,t)}}]]})}async function ee(e){return(await T("*",{cwd:e,deep:1,onlyFiles:!1})).length===0}async function te(e,t,o,n){return t?!0:!(!await ee(e)&&!await Y(e)&&!await p(t,void 0,o,n)||await $(e)&&!await V(e)&&!await p(t,"The current Git directory has uncommitted changes.",o,n))}var d=j(z(),1);var v=class extends C{static summary="Download your remote theme files locally.";static descriptionWithMarkdown=`Retrieves theme files from Shopify.
1
+ import{b as R}from"./chunk-J3JPJCWP.js";import{a as O}from"./chunk-PEHLR7XP.js";import{a as M}from"./chunk-P5WLH64A.js";import{a as x,l as H,n as Y}from"./chunk-7EUIO4ZO.js";import{a as U}from"./chunk-Y6UZW73M.js";import{a as G,c as p}from"./chunk-WEWLPJK2.js";import{a as S,b as L}from"./chunk-YY6TFARF.js";import{k as A,n as I}from"./chunk-K63FW7Q7.js";import{p as D,q as E,r as P,u as _,v as C}from"./chunk-3KM2GKXH.js";import{h as $,k as V}from"./chunk-M5Q74UZM.js";import{b}from"./chunk-IX4IGE5H.js";import{S as g,wa as m}from"./chunk-PK73ZSND.js";import{H as F,z as k}from"./chunk-WSCSFFLH.js";import{a as z}from"./chunk-CTNBSUVU.js";import{Wa as T}from"./chunk-HQUWYKSJ.js";import{q as f}from"./chunk-773TIA5M.js";import{e as j,g as c}from"./chunk-VKWPEFWQ.js";c();c();c();async function B(e,t,o,n,r,l){let i=Q(o,n,r),a=X(o,e,n,t),s=[...i,...a,{title:"Theme download complete",task:async()=>{}}];s.length>0&&await F(s,{renderOptions:{stdout:l?.stdout??process.stdout},noProgressBar:r.multiEnvironment})}function Q(e,t,o){if(o.nodelete)return[];let n=new Set(e.map(i=>i.key));return t.applyIgnoreFilters([...t.files.values()]).map(({key:i})=>i).filter(i=>!n.has(i)).map(i=>({title:`Cleaning your local directory (removing ${i})`,task:async()=>t.delete(i)}))}function X(e,t,o,n){let r=o.applyIgnoreFilters(e);r=r.filter(s=>{let h=s.checksum;return o.files.get(s.key)?.checksum!==h});let l=r.map(s=>s.key),i=s=>s.total===0?"[100%]":`[${Math.round(s.current/s.total*100)}%]`;return R(l,_,(s,h)=>({title:`Downloading files from remote theme ${i({current:h,total:l.length})}`,task:async()=>J(t,o,s,n)}))}async function J(e,t,o,n){let r=await A(e.id,o,n);r&&await Promise.all(r.map(l=>t.write(l)))}async function K(e,t,o,n){m("theme-service:pull:setup"),U({verbose:e.verbose,noColor:e.noColor});let r=t??await g(P({store:e.store}),e.password),l=new O(r),i=await(e.development?l.find():l.fetch()),{path:a,nodelete:s,live:h,development:u,only:q,ignore:N,force:y,environment:w}=e;if(!await te(a??f(),y??!1,w?.[0],o))return;let W=await M(r,{header:"Select a theme to open",filter:{live:h,theme:u?`${i?.id}`:e.theme}});m("theme-service:pull:setup"),await Z(W,r,{environment:w?.[0],force:y??!1,ignore:N??[],multiEnvironment:o,nodelete:s??!1,only:q??[],path:a??f()},n)}async function Z(e,t,o,n){m("theme-service:pull:file-system");let r=H(o.path,{filters:o}),[l]=await Promise.all([I(e.id,t),r.ready()]),i=x(l);m("theme-service:pull:file-system"),await B(e,t,i,r,o,n);let a=o.environment?`Environment: ${o.environment}`:"";k({headline:a,body:["The theme",...G(e),"has been pulled."],nextSteps:[[{link:{label:"View your theme",url:S(e,t)}}],[{link:{label:"Customize your theme at the theme editor",url:L(e,t)}}]]})}async function ee(e){return(await T("*",{cwd:e,deep:1,onlyFiles:!1})).length===0}async function te(e,t,o,n){return t?!0:!(!await ee(e)&&!await Y(e)&&!await p(t,void 0,o,n)||await $(e)&&!await V(e)&&!await p(t,"The current Git directory has uncommitted changes.",o,n))}var d=j(z(),1);var v=class extends C{static summary="Download your remote theme files locally.";static descriptionWithMarkdown=`Retrieves theme files from Shopify.
2
2
 
3
3
  If no theme is specified, then you're prompted to select the theme to pull from the list of the themes in your store.`;static description=this.descriptionWithoutMarkdown();static flags={...b,...D,...E("download"),theme:d.Flags.string({char:"t",description:"Theme ID or name of the remote theme. Use --development, --live, or --theme in non-interactive environments.",env:"SHOPIFY_FLAG_THEME_ID"}),development:d.Flags.boolean({char:"d",description:"Pull theme files from your remote development theme. Use --development, --live, or --theme in non-interactive environments.",env:"SHOPIFY_FLAG_DEVELOPMENT"}),live:d.Flags.boolean({char:"l",description:"Pull theme files from your remote live theme. Use --development, --live, or --theme in non-interactive environments.",env:"SHOPIFY_FLAG_LIVE"}),nodelete:d.Flags.boolean({char:"n",description:"Prevent deleting local files that don't exist remotely.",env:"SHOPIFY_FLAG_NODELETE"}),force:d.Flags.boolean({hidden:!0,char:"f",description:"Proceed without confirmation, if current directory does not seem to be theme directory.",env:"SHOPIFY_FLAG_FORCE"})};static multiEnvironmentsFlags=["store","password","path",["live","development","theme"]];static nonTTYFlagRequirements(){return[{flags:["theme","development","live"]}]}async command(t,o,n,r,l){m("theme-command:pull"),await K({...t,noColor:t["no-color"]},o,n,l),m("theme-command:pull")}storeAuthScopes(){return["read_themes"]}};export{K as a,v as b};
@@ -1 +1 @@
1
- import{b as o,c as l,f as m}from"./chunk-ACTDYTAV.js";import{A as a,S as h}from"./chunk-GMTNOCMS.js";import{Ta as f,na as c}from"./chunk-Y34LWI3S.js";import{d as s}from"./chunk-773TIA5M.js";import{g as u}from"./chunk-VKWPEFWQ.js";u();async function d(n){if(n.features.includes("function")&&n.isJavaScript){let e=await m(n);return o(e.functionRunner)}return o()}function p(n){return n.configuration.build?.path?s(n.directory,n.configuration.build.path):n.outputPath}async function y(n,e){try{if(!await f(e))return;let i=c(e);if(!WebAssembly.validate(i))return;let t=new WebAssembly.Module(i);if(WebAssembly.Module.customSections(t,"name").length>0)return;if(n.isJavaScript){a({headline:"The profile won't contain names for your function.",body:"JavaScript functions built with Javy don't include a WebAssembly function name section, regardless of the wasm_opt setting. Function names will appear as <unknown> in the profile."});return}a({headline:"The profile won't contain names for your function.",body:["The built WebAssembly module doesn't contain a function name section. The default wasm-opt step removes this section, and the function compiler can also omit it. To preserve function names, set ",{userInput:"wasm_opt = false"}," under ",{userInput:"[extensions.build]"}," in shopify.extension.toml, configure the compiler to emit function names, and rebuild the function."]})}catch{}}async function W(n){let e=n.functionExtension,i=await d(e);await l(i);let t=[];n.inputPath&&t.push("--input",n.inputPath),n.export&&t.push("--export",n.export),n.json&&t.push("--json"),n.profile&&t.push("--profile"),n.schemaPath&&n.queryPath&&(t.push("--schema-path",n.schemaPath),t.push("--query-path",n.queryPath));let r=p(e);return n.profile&&await y(e,r),h(i.path,["-f",r,...t],{cwd:n.functionExtension.directory,stdin:n.stdin,stdout:n.stdout??"inherit",stderr:n.stderr??"inherit",input:n.input})}export{W as a};
1
+ import{b as o,c as l,f as m}from"./chunk-GFWXVO72.js";import{A as a,S as h}from"./chunk-WSCSFFLH.js";import{Ta as f,na as c}from"./chunk-HQUWYKSJ.js";import{d as s}from"./chunk-773TIA5M.js";import{g as u}from"./chunk-VKWPEFWQ.js";u();async function d(n){if(n.features.includes("function")&&n.isJavaScript){let e=await m(n);return o(e.functionRunner)}return o()}function p(n){return n.configuration.build?.path?s(n.directory,n.configuration.build.path):n.outputPath}async function y(n,e){try{if(!await f(e))return;let i=c(e);if(!WebAssembly.validate(i))return;let t=new WebAssembly.Module(i);if(WebAssembly.Module.customSections(t,"name").length>0)return;if(n.isJavaScript){a({headline:"The profile won't contain names for your function.",body:"JavaScript functions built with Javy don't include a WebAssembly function name section, regardless of the wasm_opt setting. Function names will appear as <unknown> in the profile."});return}a({headline:"The profile won't contain names for your function.",body:["The built WebAssembly module doesn't contain a function name section. The default wasm-opt step removes this section, and the function compiler can also omit it. To preserve function names, set ",{userInput:"wasm_opt = false"}," under ",{userInput:"[extensions.build]"}," in shopify.extension.toml, configure the compiler to emit function names, and rebuild the function."]})}catch{}}async function W(n){let e=n.functionExtension,i=await d(e);await l(i);let t=[];n.inputPath&&t.push("--input",n.inputPath),n.export&&t.push("--export",n.export),n.json&&t.push("--json"),n.profile&&t.push("--profile"),n.schemaPath&&n.queryPath&&(t.push("--schema-path",n.schemaPath),t.push("--query-path",n.queryPath));let r=p(e);return n.profile&&await y(e,r),h(i.path,["-f",r,...t],{cwd:n.functionExtension.directory,stdin:n.stdin,stdout:n.stdout??"inherit",stderr:n.stderr??"inherit",input:n.input})}export{W as a};
@@ -1 +1 @@
1
- import{b as p}from"./chunk-CTRXLZAJ.js";import{k as E,wa as b,xa as k,za as s}from"./chunk-YN6A26QL.js";import{J as w}from"./chunk-GMTNOCMS.js";import{h as N}from"./chunk-R2R6JDNH.js";import{Ab as V,S as _}from"./chunk-Y34LWI3S.js";import{g as l}from"./chunk-VKWPEFWQ.js";l();var j=/gid:\/\/shopify\/\w*\/(\d+)/,g="development",ie="live",ae="unpublished";function te(e){return e.role===g}async function de(e){let n=await _("creative");return w({message:e,defaultValue:n})}function S(e){return`gid://shopify/OnlineStoreTheme/${e}`}function f(e){let n=j.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:a,role:i,processing:t,createdAtRuntime:d}=e;return{id:n,name:a,processing:t,createdAtRuntime:d,role:i==="main"?"live":i}}function se(e){if(!e)return;let{key:n,checksum:a,attachment:i,value:t}=e,d={size:(t||i||"").length,mtime:Date.now()};return{key:n,checksum:a,attachment:i,value:t,stats:d}}l();var A={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 x={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 I={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 O={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 B={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 C={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 P={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 U={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 L={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"}}}}],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"}}],selectionSet:{kind:"SelectionSet",selections:[{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 R={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 M={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 G={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 $={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"}}]}}]}}]};var Q="https://cdn.shopify.com/static/online-store/theme-skeleton.zip",c={useNetworkLevelRetry:!0,useAbortSignal:!1,maxRetryTimeMs:90*1e3,recordCommandRetries:!0},z="the required theme access scope";async function sn(e,n){let a=S(e);s("theme-api:fetch-theme");try{let{theme:i}=await p({query:M,session:n,variables:{id:a},responseOptions:{handleErrors:!1},preferredBehaviour:c});if(i)return y({id:f(i.id),processing:i.processing,role:i.role.toLowerCase(),name:i.name})}catch(i){H(i),k(i),V(`Error fetching theme with ID: ${e}`)}}async function un(e){let n=[],a=null;for(s("theme-api:fetch-themes");;){let i=await T({query:R,session:e,variables:{after:a},responseOptions:{handleErrors:!1},preferredBehaviour:c});i.themes||r("Failed to fetch themes");let{nodes:t,pageInfo:d}=i.themes;if(t.forEach(m=>{let o=y({id:f(m.id),processing:m.processing,role:m.role.toLowerCase(),name:m.name});o&&n.push(o)}),!d.hasNextPage)return n;a=d.endCursor}}async function kn(e,n){s("theme-api:find-development-theme-by-name");let{themes:a}=await T({query:G,session:n,variables:{name:e},responseOptions:{handleErrors:!1},preferredBehaviour:c});if(a||r("Failed to fetch themes"),a.nodes.length>1)throw k(new N(`More than one development theme is named "${e}"`));if(a.nodes.length===1){let{id:i,processing:t,role:d,name:m}=a.nodes[0];return y({id:f(i),processing:t,role:d.toLowerCase(),name:m})}}async function cn(e,n){let a=e.src??Q;s("theme-api:create-theme");let{themeCreate:i}=await T({query:B,session:n,variables:{name:e.name??"",source:a,role:(e.role??g).toUpperCase()},responseOptions:{handleErrors:!1},preferredBehaviour:c});i||r("Failed to create theme");let{theme:t,userErrors:d}=i;if(d.length){let m=i.userErrors.map(o=>o.message).join(", ");throw k(new N(m))}return t||r("Failed to create theme"),y({id:f(t.id),name:t.name,role:t.role.toLowerCase()})}async function pn(e,n,a){let i=[],t=null;for(s("theme-api:fetch-assets");;){let d=await T({query:C,session:a,variables:{id:D(e),filenames:n,after:t},responseOptions:{handleErrors:!1},preferredBehaviour:c});if(!d.theme?.files?.nodes||!d.theme?.files?.pageInfo){let u=d.theme?.files?.userErrors.map(h=>h.filename).join(", ");r(`Error fetching assets: ${u}`)}let{nodes:m,pageInfo:o}=d.theme.files;if(i.push(...await Promise.all(m.map(async u=>{let{attachment:h,value:v}=await J(u.body);return{attachment:h,key:u.filename,checksum:u.checksumMd5,value:v}}))),!o.hasNextPage)return i;t=o.endCursor}}async function vn(e,n,a){let t=[];s("theme-api:delete-assets");for(let d=0;d<n.length;d+=50){let m=n.slice(d,d+50),{themeFilesDelete:o}=await p({query:U,session:a,variables:{themeId:S(e),files:m},preferredBehaviour:c});o||r("Failed to delete theme assets");let{deletedThemeFiles:u,userErrors:h}=o;u&&u.forEach(v=>{t.push({key:v.filename,success:!0,operation:F.Delete})}),h.length>0&&h.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]}})):r(`Failed to delete theme assets: ${v.message}`)})}return t}async function Nn(e,n,a){let i=[];s("theme-api:bulk-upload-assets");for(let t=0;t<n.length;t+=50){let d=n.slice(t,t+50),m=X(d);b("theme-api:upload-files");let o=await K(e,m,a);b("theme-api:upload-files"),i.push(...W(o))}return i}function X(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 K(e,n,a){return p({query:P,session:a,variables:{themeId:D(e),files:n},preferredBehaviour:c})}function W(e){let{themeFilesUpsert:n}=e;n||r("Failed to upload theme files");let{upsertedThemeFiles:a,userErrors:i}=n,t=[];return a?.forEach(d=>{t.push({key:d.filename,success:!0,operation:F.Upload})}),i.forEach(d=>{d.filename||r(`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 hn(e,n){let a=[],i=null;for(s("theme-api:fetch-checksums");;){let t=await T({query:q,session:n,variables:{id:D(e),after:i},responseOptions:{handleErrors:!1},preferredBehaviour:c});if(!t?.theme?.files?.nodes||!t?.theme?.files?.pageInfo){let o=t.theme?.files?.userErrors.map(u=>u.filename).join(", ");throw k(new N(`Failed to fetch checksums for: ${o}`))}let{nodes:d,pageInfo:m}=t.theme.files;if(a.push(...d.map(o=>({key:o.filename,checksum:o.checksumMd5}))),!m.hasNextPage)return a;i=m.endCursor}}async function fn(e,n,a){let i=n.name,t={};i&&(t.name=i),s("theme-api:update-theme");let{themeUpdate:d}=await p({query:A,session:a,variables:{id:S(e),input:t},preferredBehaviour:c});d||r("Failed to update theme");let{theme:m,userErrors:o}=d;if(o.length){let u=d.userErrors.map(h=>h.message).join(", ");throw k(new N(u))}return m||r("Failed to update theme"),y({id:f(m.id),name:m.name,role:m.role.toLowerCase()})}async function yn(e,n){s("theme-api:publish-theme");let{themePublish:a}=await p({query:O,session:n,variables:{id:S(e)},preferredBehaviour:c});a||r("Failed to update theme");let{theme:i,userErrors:t}=a;if(t.length){let d=a.userErrors.map(m=>m.message).join(", ");throw k(new N(d))}return i||r("Failed to update theme"),y({id:f(i.id),name:i.name,role:i.role.toLowerCase()})}async function Sn(e,n){s("theme-api:delete-theme");let{themeDelete:a}=await p({query:x,session:n,variables:{id:S(e)},preferredBehaviour:c});a||r("Failed to update theme");let{deletedThemeId:i,userErrors:t}=a;if(t.length){let d=a.userErrors.map(m=>m.message).join(", ");throw k(new N(d))}return i||r("Failed to update theme"),!0}async function Fn(e,n,a){let i;s("theme-api:duplicate-theme");let{themeDuplicate:t}=await p({query:I,session:a,variables:{id:S(e),name:n},preferredBehaviour:c,responseOptions:{onResponse:u=>{i=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:i};let{newTheme:d,userErrors:m}=t;return m.length>0?{theme:void 0,userErrors:m,requestId:i}:d?{theme:y({id:f(d.id),name:d.name,role:d.role.toLowerCase()}),userErrors:[],requestId:i}:{theme:void 0,userErrors:[{message:"Failed to duplicate theme"}],requestId:i}}async function Tn(e,n){s("theme-api:fetch-metafield-definitions");let{metafieldDefinitions:a}=await p({query:L,session:n,variables:{ownerType:e}});return a.nodes.map(i=>({key:i.key,namespace:i.namespace,name:i.name,description:i.description,type:{name:i.type.name,category:i.type.category}}))}async function bn(e){s("theme-api:check-password-protection");let{onlineStore:n}=await p({query:$,session:e});n||r("Unable to get details about the storefront's password protection");let{passwordProtection:a}=n;return a.enabled}function r(e){throw k(new N(e))}async function T(e){try{return await p(e)}catch(n){throw H(n),n}}function H(e){if(!(e instanceof E))return;let n=Y(e);if(!n)return;let a=[["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"},"and",{command:"theme dev"},{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 N(`The authenticated account or access token is missing ${n}.`,void 0,a))}function Y(e){let n=e.response.errors;if(!Array.isArray(n))return;let a=n.find(t=>t.extensions?.code==="ACCESS_DENIED");if(!a)return;let i=a.extensions?.requiredAccess;return typeof i!="string"?z:Z(i)}function Z(e){return e.trim().replace(/\.$/,"").replace(/^The user needs\s+/i,"")||z}function D(e){return`gid://shopify/OnlineStoreTheme/${e}`}async function J(e){switch(e.__typename){case"OnlineStoreThemeFileBodyText":return{value:e.content};case"OnlineStoreThemeFileBodyBase64":return{attachment:e.contentBase64};case"OnlineStoreThemeFileBodyUrl":try{let a=await(await fetch(e.url)).arrayBuffer();return{attachment:Buffer.from(a).toString("base64")}}catch{throw k(new N(`Error downloading content from URL: ${e.url}`))}}}export{se as a,g as b,ie as c,ae as d,te as e,de as f,sn as g,un as h,kn as i,cn as j,pn as k,vn as l,Nn as m,hn as n,fn as o,yn as p,Sn as q,Fn as r,Tn as s,bn as t};
1
+ import{b as p}from"./chunk-6G5TDB45.js";import{k as E,wa as b,xa as k,za as s}from"./chunk-PK73ZSND.js";import{J as w}from"./chunk-WSCSFFLH.js";import{h as N}from"./chunk-BI7LE6CZ.js";import{Ab as V,S as _}from"./chunk-HQUWYKSJ.js";import{g as l}from"./chunk-VKWPEFWQ.js";l();var j=/gid:\/\/shopify\/\w*\/(\d+)/,g="development",ie="live",ae="unpublished";function te(e){return e.role===g}async function de(e){let n=await _("creative");return w({message:e,defaultValue:n})}function S(e){return`gid://shopify/OnlineStoreTheme/${e}`}function f(e){let n=j.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:a,role:i,processing:t,createdAtRuntime:d}=e;return{id:n,name:a,processing:t,createdAtRuntime:d,role:i==="main"?"live":i}}function se(e){if(!e)return;let{key:n,checksum:a,attachment:i,value:t}=e,d={size:(t||i||"").length,mtime:Date.now()};return{key:n,checksum:a,attachment:i,value:t,stats:d}}l();var A={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 x={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 I={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 O={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 B={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 C={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 P={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 U={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 L={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"}}}}],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"}}],selectionSet:{kind:"SelectionSet",selections:[{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 R={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 M={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 G={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 $={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"}}]}}]}}]};var Q="https://cdn.shopify.com/static/online-store/theme-skeleton.zip",c={useNetworkLevelRetry:!0,useAbortSignal:!1,maxRetryTimeMs:90*1e3,recordCommandRetries:!0},z="the required theme access scope";async function sn(e,n){let a=S(e);s("theme-api:fetch-theme");try{let{theme:i}=await p({query:M,session:n,variables:{id:a},responseOptions:{handleErrors:!1},preferredBehaviour:c});if(i)return y({id:f(i.id),processing:i.processing,role:i.role.toLowerCase(),name:i.name})}catch(i){H(i),k(i),V(`Error fetching theme with ID: ${e}`)}}async function un(e){let n=[],a=null;for(s("theme-api:fetch-themes");;){let i=await T({query:R,session:e,variables:{after:a},responseOptions:{handleErrors:!1},preferredBehaviour:c});i.themes||r("Failed to fetch themes");let{nodes:t,pageInfo:d}=i.themes;if(t.forEach(m=>{let o=y({id:f(m.id),processing:m.processing,role:m.role.toLowerCase(),name:m.name});o&&n.push(o)}),!d.hasNextPage)return n;a=d.endCursor}}async function kn(e,n){s("theme-api:find-development-theme-by-name");let{themes:a}=await T({query:G,session:n,variables:{name:e},responseOptions:{handleErrors:!1},preferredBehaviour:c});if(a||r("Failed to fetch themes"),a.nodes.length>1)throw k(new N(`More than one development theme is named "${e}"`));if(a.nodes.length===1){let{id:i,processing:t,role:d,name:m}=a.nodes[0];return y({id:f(i),processing:t,role:d.toLowerCase(),name:m})}}async function cn(e,n){let a=e.src??Q;s("theme-api:create-theme");let{themeCreate:i}=await T({query:B,session:n,variables:{name:e.name??"",source:a,role:(e.role??g).toUpperCase()},responseOptions:{handleErrors:!1},preferredBehaviour:c});i||r("Failed to create theme");let{theme:t,userErrors:d}=i;if(d.length){let m=i.userErrors.map(o=>o.message).join(", ");throw k(new N(m))}return t||r("Failed to create theme"),y({id:f(t.id),name:t.name,role:t.role.toLowerCase()})}async function pn(e,n,a){let i=[],t=null;for(s("theme-api:fetch-assets");;){let d=await T({query:C,session:a,variables:{id:D(e),filenames:n,after:t},responseOptions:{handleErrors:!1},preferredBehaviour:c});if(!d.theme?.files?.nodes||!d.theme?.files?.pageInfo){let u=d.theme?.files?.userErrors.map(h=>h.filename).join(", ");r(`Error fetching assets: ${u}`)}let{nodes:m,pageInfo:o}=d.theme.files;if(i.push(...await Promise.all(m.map(async u=>{let{attachment:h,value:v}=await J(u.body);return{attachment:h,key:u.filename,checksum:u.checksumMd5,value:v}}))),!o.hasNextPage)return i;t=o.endCursor}}async function vn(e,n,a){let t=[];s("theme-api:delete-assets");for(let d=0;d<n.length;d+=50){let m=n.slice(d,d+50),{themeFilesDelete:o}=await p({query:U,session:a,variables:{themeId:S(e),files:m},preferredBehaviour:c});o||r("Failed to delete theme assets");let{deletedThemeFiles:u,userErrors:h}=o;u&&u.forEach(v=>{t.push({key:v.filename,success:!0,operation:F.Delete})}),h.length>0&&h.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]}})):r(`Failed to delete theme assets: ${v.message}`)})}return t}async function Nn(e,n,a){let i=[];s("theme-api:bulk-upload-assets");for(let t=0;t<n.length;t+=50){let d=n.slice(t,t+50),m=X(d);b("theme-api:upload-files");let o=await K(e,m,a);b("theme-api:upload-files"),i.push(...W(o))}return i}function X(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 K(e,n,a){return p({query:P,session:a,variables:{themeId:D(e),files:n},preferredBehaviour:c})}function W(e){let{themeFilesUpsert:n}=e;n||r("Failed to upload theme files");let{upsertedThemeFiles:a,userErrors:i}=n,t=[];return a?.forEach(d=>{t.push({key:d.filename,success:!0,operation:F.Upload})}),i.forEach(d=>{d.filename||r(`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 hn(e,n){let a=[],i=null;for(s("theme-api:fetch-checksums");;){let t=await T({query:q,session:n,variables:{id:D(e),after:i},responseOptions:{handleErrors:!1},preferredBehaviour:c});if(!t?.theme?.files?.nodes||!t?.theme?.files?.pageInfo){let o=t.theme?.files?.userErrors.map(u=>u.filename).join(", ");throw k(new N(`Failed to fetch checksums for: ${o}`))}let{nodes:d,pageInfo:m}=t.theme.files;if(a.push(...d.map(o=>({key:o.filename,checksum:o.checksumMd5}))),!m.hasNextPage)return a;i=m.endCursor}}async function fn(e,n,a){let i=n.name,t={};i&&(t.name=i),s("theme-api:update-theme");let{themeUpdate:d}=await p({query:A,session:a,variables:{id:S(e),input:t},preferredBehaviour:c});d||r("Failed to update theme");let{theme:m,userErrors:o}=d;if(o.length){let u=d.userErrors.map(h=>h.message).join(", ");throw k(new N(u))}return m||r("Failed to update theme"),y({id:f(m.id),name:m.name,role:m.role.toLowerCase()})}async function yn(e,n){s("theme-api:publish-theme");let{themePublish:a}=await p({query:O,session:n,variables:{id:S(e)},preferredBehaviour:c});a||r("Failed to update theme");let{theme:i,userErrors:t}=a;if(t.length){let d=a.userErrors.map(m=>m.message).join(", ");throw k(new N(d))}return i||r("Failed to update theme"),y({id:f(i.id),name:i.name,role:i.role.toLowerCase()})}async function Sn(e,n){s("theme-api:delete-theme");let{themeDelete:a}=await p({query:x,session:n,variables:{id:S(e)},preferredBehaviour:c});a||r("Failed to update theme");let{deletedThemeId:i,userErrors:t}=a;if(t.length){let d=a.userErrors.map(m=>m.message).join(", ");throw k(new N(d))}return i||r("Failed to update theme"),!0}async function Fn(e,n,a){let i;s("theme-api:duplicate-theme");let{themeDuplicate:t}=await p({query:I,session:a,variables:{id:S(e),name:n},preferredBehaviour:c,responseOptions:{onResponse:u=>{i=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:i};let{newTheme:d,userErrors:m}=t;return m.length>0?{theme:void 0,userErrors:m,requestId:i}:d?{theme:y({id:f(d.id),name:d.name,role:d.role.toLowerCase()}),userErrors:[],requestId:i}:{theme:void 0,userErrors:[{message:"Failed to duplicate theme"}],requestId:i}}async function Tn(e,n){s("theme-api:fetch-metafield-definitions");let{metafieldDefinitions:a}=await p({query:L,session:n,variables:{ownerType:e}});return a.nodes.map(i=>({key:i.key,namespace:i.namespace,name:i.name,description:i.description,type:{name:i.type.name,category:i.type.category}}))}async function bn(e){s("theme-api:check-password-protection");let{onlineStore:n}=await p({query:$,session:e});n||r("Unable to get details about the storefront's password protection");let{passwordProtection:a}=n;return a.enabled}function r(e){throw k(new N(e))}async function T(e){try{return await p(e)}catch(n){throw H(n),n}}function H(e){if(!(e instanceof E))return;let n=Y(e);if(!n)return;let a=[["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"},"and",{command:"theme dev"},{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 N(`The authenticated account or access token is missing ${n}.`,void 0,a))}function Y(e){let n=e.response.errors;if(!Array.isArray(n))return;let a=n.find(t=>t.extensions?.code==="ACCESS_DENIED");if(!a)return;let i=a.extensions?.requiredAccess;return typeof i!="string"?z:Z(i)}function Z(e){return e.trim().replace(/\.$/,"").replace(/^The user needs\s+/i,"")||z}function D(e){return`gid://shopify/OnlineStoreTheme/${e}`}async function J(e){switch(e.__typename){case"OnlineStoreThemeFileBodyText":return{value:e.content};case"OnlineStoreThemeFileBodyBase64":return{attachment:e.contentBase64};case"OnlineStoreThemeFileBodyUrl":try{let a=await(await fetch(e.url)).arrayBuffer();return{attachment:Buffer.from(a).toString("base64")}}catch{throw k(new N(`Error downloading content from URL: ${e.url}`))}}}export{se as a,g as b,ie as c,ae as d,te as e,de as f,sn as g,un as h,kn as i,cn as j,pn as k,vn as l,Nn as m,hn as n,fn as o,yn as p,Sn as q,Fn as r,Tn as s,bn as t};
@@ -1 +1 @@
1
- import{X as B}from"./chunk-YN6A26QL.js";import{u as O}from"./chunk-GMTNOCMS.js";import{F as w,f as m}from"./chunk-Y34LWI3S.js";import{c as g,e as s,g as o}from"./chunk-VKWPEFWQ.js";var f=g((Q,c)=>{o();function j(r,e,t,n){for(var a=-1,i=r==null?0:r.length;++a<i;){var u=r[a];e(n,u,t(u),r)}return n}c.exports=j});var A=g((S,h)=>{o();var l=O();function E(r,e,t,n){return l(r,function(a,i,u){e(n,a,t(a),u)}),n}h.exports=E});var p=g((U,q)=>{o();var G=f(),I=A(),V=w(),C=m();function D(r,e){return function(t,n){var a=C(t)?G:I,i=e?e():{};return a(t,r,V(n,2),i)}}q.exports=D});var x=g((X,v)=>{o();var F=B(),H=p(),J=Object.prototype,K=J.hasOwnProperty,L=H(function(r,e,t){K.call(r,t)?r[t].push(e):F(r,t,[e])});v.exports=L});var y=g((Z,b)=>{o();var M=p(),N=M(function(r,e,t){r[t?0:1].push(e)},function(){return[[],[]]});b.exports=N});o();var P=s(x()),d=s(y());function $(r,e){return(0,P.default)(r,e)}function k(r,e){return(0,d.default)(r,e)}export{$ as a,k as b};
1
+ import{X as B}from"./chunk-PK73ZSND.js";import{u as O}from"./chunk-WSCSFFLH.js";import{F as w,f as m}from"./chunk-HQUWYKSJ.js";import{c as g,e as s,g as o}from"./chunk-VKWPEFWQ.js";var f=g((Q,c)=>{o();function j(r,e,t,n){for(var a=-1,i=r==null?0:r.length;++a<i;){var u=r[a];e(n,u,t(u),r)}return n}c.exports=j});var A=g((S,h)=>{o();var l=O();function E(r,e,t,n){return l(r,function(a,i,u){e(n,a,t(a),u)}),n}h.exports=E});var p=g((U,q)=>{o();var G=f(),I=A(),V=w(),C=m();function D(r,e){return function(t,n){var a=C(t)?G:I,i=e?e():{};return a(t,r,V(n,2),i)}}q.exports=D});var x=g((X,v)=>{o();var F=B(),H=p(),J=Object.prototype,K=J.hasOwnProperty,L=H(function(r,e,t){K.call(r,t)?r[t].push(e):F(r,t,[e])});v.exports=L});var y=g((Z,b)=>{o();var M=p(),N=M(function(r,e,t){r[t?0:1].push(e)},function(){return[[],[]]});b.exports=N});o();var P=s(x()),d=s(y());function $(r,e){return(0,P.default)(r,e)}function k(r,e){return(0,d.default)(r,e)}export{$ as a,k as b};
@@ -1,3 +1,3 @@
1
- import{a}from"./chunk-QZBSCOJV.js";import{p as i,v as s}from"./chunk-OORWOTAP.js";import{b as r}from"./chunk-JJJTPEMD.js";import{a as c}from"./chunk-CTNBSUVU.js";import{e as d,g as e}from"./chunk-VKWPEFWQ.js";e();var m=d(c(),1),t=class extends s{static summary="Download metafields definitions from your shop into a local file.";static descriptionWithMarkdown=`Retrieves metafields from Shopify Admin.
1
+ import{a}from"./chunk-UK4WXL4G.js";import{p as i,v as s}from"./chunk-3KM2GKXH.js";import{b as r}from"./chunk-IX4IGE5H.js";import{a as c}from"./chunk-CTNBSUVU.js";import{e as d,g as e}from"./chunk-VKWPEFWQ.js";e();var m=d(c(),1),t=class extends s{static summary="Download metafields definitions from your shop into a local file.";static descriptionWithMarkdown=`Retrieves metafields from Shopify Admin.
2
2
 
3
3
  If the metafields file already exists, it will be overwritten.`;static description=this.descriptionWithoutMarkdown();static flags={...r,...i,force:m.Flags.boolean({hidden:!0,char:"f",description:"Proceed without confirmation, if current directory does not seem to be theme directory.",env:"SHOPIFY_FLAG_FORCE"})};static multiEnvironmentsFlags=null;async command(o){let n={path:o.path,password:o.password,store:o.store,force:o.force,verbose:o.verbose,noColor:o["no-color"]};await a(n)}};export{t as a};
@@ -1,3 +1,3 @@
1
- import{a as M}from"./chunk-NEMPLS7C.js";import{a as b}from"./chunk-KUNDCAQN.js";import{A as x,sa as V,w as S,x as A,z as C}from"./chunk-ACTDYTAV.js";import{a as f}from"./chunk-U6HYEGAE.js";import{b as j,c as E}from"./chunk-JJJTPEMD.js";import{B as u,z as v}from"./chunk-GMTNOCMS.js";import{h as g,j as n}from"./chunk-R2R6JDNH.js";import{Db as w,Gb as h,wb as l}from"./chunk-Y34LWI3S.js";import{j as p}from"./chunk-773TIA5M.js";import{g as m}from"./chunk-VKWPEFWQ.js";m();m();async function N(s,t){let e=new Set(t.map(r=>r.file)).size;await f.addPublicMetadata(()=>({cmd_app_validate_valid:s,cmd_app_validate_issue_count:t.length,cmd_app_validate_file_count:e}))}async function P(s,t={json:!1}){let e=s.errors;if(!e||e.isEmpty()){if(await N(!0,[]),t.json){l(JSON.stringify({valid:!0,issues:[]},null,2));return}v({headline:`App configuration '${p(s.configPath)}' is valid.`});return}let r=e.getErrors();if(await N(!1,r),t.json){let d=r.map(({file:c,message:a,path:i,code:o})=>({file:c,message:a,path:i,code:o}));throw l(JSON.stringify({valid:!1,issues:d},null,2)),new n}throw u({headline:"Validation errors found.",body:r.map(d=>`\u2022 ${x(d)}`).join(`
1
+ import{a as M}from"./chunk-ESPT6CGE.js";import{a as b}from"./chunk-RA3WWB2S.js";import{A as x,sa as V,w as S,x as A,z as C}from"./chunk-GFWXVO72.js";import{a as f}from"./chunk-HU4GFVEN.js";import{b as j,c as E}from"./chunk-IX4IGE5H.js";import{B as u,z as v}from"./chunk-WSCSFFLH.js";import{h as g,j as n}from"./chunk-BI7LE6CZ.js";import{Db as w,Gb as h,wb as l}from"./chunk-HQUWYKSJ.js";import{j as p}from"./chunk-773TIA5M.js";import{g as m}from"./chunk-VKWPEFWQ.js";m();m();async function N(s,t){let e=new Set(t.map(r=>r.file)).size;await f.addPublicMetadata(()=>({cmd_app_validate_valid:s,cmd_app_validate_issue_count:t.length,cmd_app_validate_file_count:e}))}async function P(s,t={json:!1}){let e=s.errors;if(!e||e.isEmpty()){if(await N(!0,[]),t.json){l(JSON.stringify({valid:!0,issues:[]},null,2));return}v({headline:`App configuration '${p(s.configPath)}' is valid.`});return}let r=e.getErrors();if(await N(!1,r),t.json){let d=r.map(({file:c,message:a,path:i,code:o})=>({file:c,message:a,path:i,code:o}));throw l(JSON.stringify({valid:!1,issues:d},null,2)),new n}throw u({headline:"Validation errors found.",body:r.map(d=>`\u2022 ${x(d)}`).join(`
2
2
  `)}),new n}async function _(s,t){await f.addPublicMetadata(()=>({cmd_app_validate_valid:!1,cmd_app_validate_issue_count:s,cmd_app_validate_file_count:t}))}var y=class s extends M{static summary="Validate your app configuration and extensions.";static descriptionWithMarkdown="Validates the selected app configuration file and all extension configurations against their schemas and reports any errors found.";static description=this.descriptionWithoutMarkdown();static flags={...j,...b,...E};async run(){let{flags:t}=await this.parse(s);await f.addPublicMetadata(()=>({cmd_app_validate_json:t.json}));let e;try{e=await S.load(t.path)}catch(a){if(a instanceof g&&t.json){await _(1,1);let i=h(w(a.message)).trim();throw l(JSON.stringify({valid:!1,issues:[{message:i}]},null,2)),new n}throw a}let r;try{r=await C(e,t.config,{clientId:t["client-id"],skipPrompts:!!t["client-id"]})}catch(a){if(a instanceof g&&t.json){await _(1,1);let i=h(w(a.message)).trim();throw l(JSON.stringify({valid:!1,issues:[{message:i}]},null,2)),new n}throw a}let d=A(e,r.file);if(d.length>0){let a=d.map(o=>({file:o.path,message:o.message})),i=new Set(d.map(o=>o.path)).size;throw await _(a.length,i),t.json?(l(JSON.stringify({valid:!1,issues:a},null,2)),new n):(u({headline:"Validation errors found.",body:a.map(o=>`\u2022 ${o.message}`).join(`
3
3
  `)}),new n)}let c;try{c=(await V({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config??(t["client-id"]?p(r.file.path):void 0),unsafeTolerateErrors:!0})).app}catch(a){let i=a instanceof g?h(w(a.message)).trim():"";throw i.startsWith("Validation errors in ")&&t.json?(await _(1,1),l(JSON.stringify({valid:!1,issues:[{message:i}]},null,2)),new n):a}return await P(c,{json:t.json}),{app:c}}};export{y as a};
@@ -1 +1 @@
1
- import{b as c}from"./chunk-RY2SJVWM.js";import{U as r}from"./chunk-YN6A26QL.js";import{yb as a}from"./chunk-Y34LWI3S.js";import{g as t}from"./chunk-VKWPEFWQ.js";t();var o=class extends c{static description="Logs you out of the Shopify account or Partner account and store.";async run(){await r(),a("Logged out from all the accounts")}};export{o as a};
1
+ import{b as c}from"./chunk-3WV7DQMM.js";import{U as r}from"./chunk-PK73ZSND.js";import{yb as a}from"./chunk-HQUWYKSJ.js";import{g as t}from"./chunk-VKWPEFWQ.js";t();var o=class extends c{static description="Logs you out of the Shopify account or Partner account and store.";async run(){await r(),a("Logged out from all the accounts")}};export{o as a};
@@ -1,4 +1,4 @@
1
- import{b as l}from"./chunk-JJJTPEMD.js";import{b as u}from"./chunk-RY2SJVWM.js";import{r as f}from"./chunk-YN6A26QL.js";import{h as n}from"./chunk-R2R6JDNH.js";import{a as g}from"./chunk-CTNBSUVU.js";import{wb as m}from"./chunk-Y34LWI3S.js";import{e as v,g as o}from"./chunk-VKWPEFWQ.js";o();o();var S="https://shopify.dev/assistant/search",w="X-Shopify-Surface",A="cli";async function y(s,e,p){let i=new URLSearchParams({query:s});e&&i.append("api_name",e),p&&i.append("api_version",p);let r;try{r=await f(`${S}?${i.toString()}`,{headers:{Accept:"application/json",[w]:A}})}catch{throw new n("Could not reach shopify.dev to run the search.","Check your network connection and try again.")}let h=await r.text();if(!r.ok){let d=`${r.status} ${r.statusText}`;try{let t=JSON.parse(h);t?.error&&(d=t.error)}catch(t){if(!(t instanceof SyntaxError))throw t}throw new n(`Search failed: ${d}`)}m(h)}var a=v(g(),1),c=class s extends u{static description="Query the shopify.dev vector store and print the most relevant documentation chunks as JSON. Best for programmatic discovery \u2014 surfacing the relevant pieces of documentation for a topic, rather than retrieving a whole document. To download a full document verbatim, use `doc fetch`.";static examples=[`# search shopify.dev for a topic
1
+ import{b as l}from"./chunk-IX4IGE5H.js";import{b as u}from"./chunk-3WV7DQMM.js";import{r as f}from"./chunk-PK73ZSND.js";import{h as n}from"./chunk-BI7LE6CZ.js";import{a as g}from"./chunk-CTNBSUVU.js";import{wb as m}from"./chunk-HQUWYKSJ.js";import{e as v,g as o}from"./chunk-VKWPEFWQ.js";o();o();var S="https://shopify.dev/assistant/search",w="X-Shopify-Surface",A="cli";async function y(s,e,p){let i=new URLSearchParams({query:s});e&&i.append("api_name",e),p&&i.append("api_version",p);let r;try{r=await f(`${S}?${i.toString()}`,{headers:{Accept:"application/json",[w]:A}})}catch{throw new n("Could not reach shopify.dev to run the search.","Check your network connection and try again.")}let h=await r.text();if(!r.ok){let d=`${r.status} ${r.statusText}`;try{let t=JSON.parse(h);t?.error&&(d=t.error)}catch(t){if(!(t instanceof SyntaxError))throw t}throw new n(`Search failed: ${d}`)}m(h)}var a=v(g(),1),c=class s extends u{static description="Query the shopify.dev vector store and print the most relevant documentation chunks as JSON. Best for programmatic discovery \u2014 surfacing the relevant pieces of documentation for a topic, rather than retrieving a whole document. To download a full document verbatim, use `doc fetch`.";static examples=[`# search shopify.dev for a topic
2
2
  shopify doc search --query "subscribe to webhooks"
3
3
 
4
4
  # narrow the search to a specific API and version
@@ -1,2 +1,2 @@
1
- import{Ab as d}from"./chunk-Y34LWI3S.js";import{g as p}from"./chunk-VKWPEFWQ.js";p();import{spawn as m}from"child_process";function b(n=process.pid,s="SIGTERM",e=!0,i){$(n,s,e,i??(t=>{t&&d(`Failed to kill process ${n}: ${t}`)}))}function $(n,s,e,i){let o=typeof n=="number"?n.toString():n;if(!/^\d+$/.test(o)){i(new Error("pid must be a number"));return}let t={};t[o]=[];let r=new Set;switch(r.add(o),process.platform){case"win32":{m("taskkill",["/pid",o,"/T","/F"]).on("close",f=>{f===0?i():i(new Error(`taskkill exited with code ${f}`))});break}case"darwin":h(o,t,r,function(c){return m("pgrep",["-lfP",c])},function(){k(t,s,o,e,i)});break;default:h(o,t,r,function(c){return m("ps",["-o","pid command","--no-headers","--ppid",c])},function(){k(t,s,o,e,i)});break}}function k(n,s,e,i,o){let t=new Set;try{Object.keys(n).forEach(function(r){n[r].forEach(function(c){t.has(c)||(w(c,s),t.add(c))}),r===e&&i&&!t.has(r)&&(w(r,s),t.add(r))})}catch(r){o(r);return}o()}function w(n,s){try{process.kill(parseInt(n,10),s)}catch(e){if(e.code!=="ESRCH")throw e}}function h(n,s,e,i,o){let t=i(n),r="";t.stdout?.on("data",function(f){let a=f.toString("ascii");r+=a});let c=f=>{if(e.delete(n),f!==0){if(e.size===0){o();return}return}r.trim().split(`
1
+ import{Ab as d}from"./chunk-HQUWYKSJ.js";import{g as p}from"./chunk-VKWPEFWQ.js";p();import{spawn as m}from"child_process";function b(n=process.pid,s="SIGTERM",e=!0,i){$(n,s,e,i??(t=>{t&&d(`Failed to kill process ${n}: ${t}`)}))}function $(n,s,e,i){let o=typeof n=="number"?n.toString():n;if(!/^\d+$/.test(o)){i(new Error("pid must be a number"));return}let t={};t[o]=[];let r=new Set;switch(r.add(o),process.platform){case"win32":{m("taskkill",["/pid",o,"/T","/F"]).on("close",f=>{f===0?i():i(new Error(`taskkill exited with code ${f}`))});break}case"darwin":h(o,t,r,function(c){return m("pgrep",["-lfP",c])},function(){k(t,s,o,e,i)});break;default:h(o,t,r,function(c){return m("ps",["-o","pid command","--no-headers","--ppid",c])},function(){k(t,s,o,e,i)});break}}function k(n,s,e,i,o){let t=new Set;try{Object.keys(n).forEach(function(r){n[r].forEach(function(c){t.has(c)||(w(c,s),t.add(c))}),r===e&&i&&!t.has(r)&&(w(r,s),t.add(r))})}catch(r){o(r);return}o()}function w(n,s){try{process.kill(parseInt(n,10),s)}catch(e){if(e.code!=="ESRCH")throw e}}function h(n,s,e,i,o){let t=i(n),r="";t.stdout?.on("data",function(f){let a=f.toString("ascii");r+=a});let c=f=>{if(e.delete(n),f!==0){if(e.size===0){o();return}return}r.trim().split(`
2
2
  `).forEach(function(a){let l=a.match(/^(\d+)\s(.*)$/);if(l){let u=l[1],E=l[2];s[n].push(u),s[u]=[],d(`Killing process ${u}: ${E}`),e.add(u),h(u,s,e,i,o)}})};t.on("close",c)}export{b as a};